Overview
The stroke
attribute is a presentation attribute defining the color (or any SVG paint servers like gradients or patterns) used to paint the outline of the shape.
Colors
Use color
please refer to Colors.
stroke:fade-60
stroke:gray-60
stroke:brown-60
stroke:orange-60
stroke:gold-60/.4
stroke:yellow-60/.4
stroke:grass-60/.4
stroke:green-60/.4
stroke:beryl-60/.3
stroke:teal-60/.3
stroke:cyan-60/.3
stroke:sky-60/.3
stroke:blue-60/.2
stroke:indigo-60/.2
stroke:violet-60/.2
stroke:purple-60/.2
stroke:fuchsia-60/.1
stroke:pink-60/.1
stroke:crimson-60/.1
stroke:red-60/.1
Hex
stroke:rgb(135,141,159)
stroke:rgb(141,141,143)
stroke:rgb(175,131,110)
stroke:rgb(213,115,30)
stroke:rgb(192,128,0)
stroke:rgb(172,138,0)
stroke:rgb(104,156,19)
stroke:rgb(8,163,69)
stroke:rgb(0,161,112)
stroke:rgb(0,159,148)
stroke:rgb(0,153,193)
stroke:rgb(11,146,238)
stroke:rgb(83,140,238)
stroke:rgb(125,132,232)
stroke:rgb(158,119,245)
stroke:rgb(181,108,236)
stroke:rgb(224,78,229)
stroke:rgb(238,82,163)
stroke:rgb(234,91,130)
stroke:rgb(235,95,99)
RGB
stroke:rgb(135,141,159)
stroke:rgb(141,141,143)
stroke:rgb(175,131,110)
stroke:rgb(213,115,30)
stroke:rgb(192,128,0)
stroke:rgb(172,138,0)
stroke:rgb(104,156,19)
stroke:rgb(8,163,69)
stroke:rgb(0,161,112)
stroke:rgb(0,159,148)
stroke:rgb(0,153,193)
stroke:rgb(11,146,238)
stroke:rgb(83,140,238)
stroke:rgb(125,132,232)
stroke:rgb(158,119,245)
stroke:rgb(181,108,236)
stroke:rgb(224,78,229)
stroke:rgb(238,82,163)
stroke:rgb(234,91,130)
stroke:rgb(235,95,99)
Applying with functions
<div class="stroke:$(color)">...</div>
Master supports native CSS variables and functions, just add var(--key)
or use shorthand$(key)
for variables.
You can also use calc(expression)
, env(expression)
and other CSS functions if the property supports it.
To learn more, see the Functions documentation.
Conditionally apply
States and selectors
<div class="stroke:blue-60:hover">...</div>
Master supports all native CSS selectors, just add :hover
, :disabled
, chaining, combinators and other CSS selectors as usual.
To learn more, see the Selectors documentation.
Responsive breakpoints
<div class="stroke:blue-60@sm">...</div>
Responsive breakpoints can be applied to all styles. Some available breakpoints are 3xs
, 2xs
, xs
, sm
,md
, lg
, xl
, 2xl
, 3xl
, 4xl
. Arbitrary breakpoints can be specified through comparison operators >
, >=
, <
, <=
.
To learn more, see the Breakpoints documentation.
Print format and media queries
<div class="stroke:blue-60@print">...</div>
Master supports media types like print
, screen
, speech
, all
, and other media queries.
To learn more, see the Media Queries documentation.
Dark mode and color schemes
<div class="stroke:blue-60@dark">...</div>
Master uses the selector html.dark
to support color schemes. Now, you can easily fine-tune your style for the color schemes.
To learn more, see the Color Schemes documentation.