Skip to main content

Border

The border properties are used to control the component border style and width. See available border styles.

Example

.element {
border: var(--dwc-border-width) var(--dwc-border-style) red;
}

Variables

VariableDefault Value
--dwc-border-width1px
--dwc-border-stylesolid

Border radius

Border radius variables define how rounded the corners of a component are. All values are defined in em, so they scale with the font size.

EM Unit

em is a relative unit that scales with the font size of the parent.

Example

.element {
border-radius: var(--dwc-border-radius-m);
}

Variables

VariableDefault ValueExample
--dwc-border-radius-2xs0.071em
--dwc-border-radius-xs0.125em
--dwc-border-radius-s0.25em
--dwc-border-radius-m0.375em
--dwc-border-radius-l0.5em
--dwc-border-radius-xl0.75em
--dwc-border-radius-2xl1em
--dwc-border-radius-round50%
--dwc-border-radius-pill9999px
--dwc-border-radiusvar(--dwc-border-radius-s)