Skip to main content

Surfaces

There are three levels of surfaces used to organize the UI hierarchy, often combined with shadows. All palette colors are tested to provide sufficient contrast against these surfaces.

Example

.element {
background: var(--dwc-surface-2);
}

Variables

VariableUsageExample
--dwc-surface-1The darkest surface. Used for body background.
--dwc-surface-2Used for components (e.g. cards).
--dwc-surface-3The lightest and highest surface. Used for menus, popovers, dialogs ...