Skip to main content

Outline Style

Set the style for an element's outline.

View as Markdown
baselinewidely
ClassCSS
os:noneoutline-style: none;
os:doutline-style: dashed;
os:soutline-style: solid;

Variants

Prefix any class with a variant to apply it only under that condition. Variants stack, as in @md:h:os:d.

Breakpoints

Apply a class from a viewport width up. Each breakpoint covers its width & every width above it.

@xs:os:dFrom 32rem up.
@sm:os:dFrom 40rem up.
@md:os:dFrom 48rem up.
@lg:os:dFrom 64rem up.
@xl:os:dFrom 80rem up.
@xxl:os:dFrom 96rem up.

Containers

Apply a class from a container's width up, not the viewport's. Mark the parent with ct:is first.

@c:xs:os:dContainer from 32rem up.
@c:sm:os:dContainer from 40rem up.
@c:md:os:dContainer from 48rem up.
@c:lg:os:dContainer from 64rem up.
@c:xl:os:dContainer from 80rem up.
@c:xxl:os:dContainer from 96rem up.

Media

Apply a class when the device or the page matches a condition, or on the first frame an element renders.

@pc:os:dOn a touch screen.
@prm:os:dWith reduced motion on.
@st:os:dOn the first frame.

States

Apply a class only while the element is in a state, such as hovered, focused or checked.

h:os:dOn :hover.
f:os:dOn :focus.
fv:os:dOn :focus-visible.
a:os:dOn :active.
d:os:dOn :disabled.
fc:os:dOn :first-child.
c:os:dOn :checked.
e:os:dOn :empty.
fw:os:dOn :focus-within.
i:os:dOn :invalid.
in:os:dOn :indeterminate.
lc:os:dOn :last-child.
nc:os:dOn :nth-child.
r:os:dOn :required.
ro:os:dOn :read-only.
v:os:dOn :valid.

Pseudo Elements

Style a part of the element rather than the element itself, such as its placeholder or the selected text.

a::os:dOn ::after.
b::os:dOn ::before.
p::os:dOn ::placeholder.
s::os:dOn ::selection.