Skip to main content

BoxShadows

Box shadows are used to create the impression of elements being elevated above the background.

import BoxShadows from '@dynatrace/strato-design-tokens/box-shadows';

BoxShadows.Surface.Flat

Surfaces are flat by default and do not have any shadow.

SampleToken NameValueDescription
LightDarkLightDark
BoxShadows.Surface.Flat.RestnonenoneUse as the default level of elevation.
BoxShadows.Surface.Flat.Hover0px 0px 0px 1px #2d2e4e08, 0px 1px 2px #2d2e4e0d, 0px 4px 8px -2px #2d2e4e120px 0px 0px 1px #f0f0f51f, 0px 1px 2px #112, 0px 4px 8px #112cUse as the default level of elevation when a user's pointer is over an interactive surface.
BoxShadows.Surface.Flat.ActivenonenoneUse as the default level of elevation when the user is pressing an interactive surface.
BoxShadows.Surface.Flat.Drag0px 0px 0px 1px #2d2e4e08, 0px 1px 2px #2d2e4e0d, 0px 7px 17px -2px #2d2e4e520px 0px 0px 1px #f0f0f51f, 0px 1px 2px #112, 0px 13px 8px #112cUse as the default level of elevation when moving a surface, on drag-and-drop interaction.

BoxShadows.Surface.Raised

Raised surfaces have a subtle shadow, and are used to draw attention to an element.

SampleToken NameValueDescription
LightDarkLightDark
BoxShadows.Surface.Raised.Rest0px 0px 0px 1px #2d2e4e08, 0px 1px 2px #2d2e4e0d, 0px 4px 8px -2px #2d2e4e120px 0px 0px 1px #f0f0f51f, 0px 1px 2px #112, 0px 4px 8px #112cUse for raised surfaces.
BoxShadows.Surface.Raised.Hover0px 0px 0px 1px #2d2e4e08, 0px 1px 2px #2d2e4e0d, 0px 5px 11px -2px #2d2e4e290px 0px 0px 1px #f0f0f51f, 0px 1px 2px #112, 0px 7px 8px #112cUse when a user's pointer is over an interactive raised surface.
BoxShadows.Surface.Raised.Active0px 0px 0px 1px #2d2e4e08, 0px 1px 2px #2d2e4e0d, 0px 4px 8px -2px #2d2e4e120px 0px 0px 1px #f0f0f51f, 0px 1px 2px #112, 0px 4px 8px #112cUse when the user is pressing an interactive raised surface.
BoxShadows.Surface.Raised.Drag0px 0px 0px 1px #2d2e4e08, 0px 1px 2px #2d2e4e0d, 0px 7px 17px -2px #2d2e4e520px 0px 0px 1px #f0f0f51f, 0px 1px 2px #112, 0px 13px 8px #112cUse when moving a raised surface, on drag-and-drop interaction.

BoxShadows.Surface.Floating

Floating surfaces have a noticeable shadow, and are used in elements that overlay other content.

SampleToken NameValueDescription
LightDarkLightDark
BoxShadows.Surface.Floating.Rest0px 0px 0px 1px #2d2e4e08, 0px 1px 2px #2d2e4e0d, 0px 5px 11px -2px #2d2e4e290px 0px 0px 1px #f0f0f51f, 0px 1px 2px #112, 0px 7px 8px #112cUse for floating surfaces.
BoxShadows.Surface.Floating.Hover0px 0px 0px 1px #2d2e4e08, 0px 1px 2px #2d2e4e0d, 0px 6px 14px -2px #2d2e4e3d0px 0px 0px 1px #f0f0f51f, 0px 1px 2px #112, 0px 10px 8px #112cUse when a user's pointer is over an interactive floating surface.
BoxShadows.Surface.Floating.Active0px 0px 0px 1px #2d2e4e08, 0px 1px 2px #2d2e4e0d, 0px 5px 11px -2px #2d2e4e290px 0px 0px 1px #f0f0f51f, 0px 1px 2px #112, 0px 7px 8px #112cUse when the user is pressing an interactive floating surface.
BoxShadows.Surface.Floating.Drag0px 0px 0px 1px #2d2e4e08, 0px 1px 2px #2d2e4e0d, 0px 7px 17px -2px #2d2e4e520px 0px 0px 1px #f0f0f51f, 0px 1px 2px #112, 0px 13px 8px #112cUse when moving a floating surface, on drag-and-drop interaction.
Still have questions?
Find answers in the Dynatrace Community