useOverlayStacking
Import
import { useOverlayStacking } from '@dynatrace/strato-components-preview/core';
Use cases
Nest overlays
Use the OverlayStackingProvider
to nest overlays. The provider is increasing
the nesting level whenever a new overlay is opened. Doing this, nested overlays
will be rendered on top of the parent overlay again.
Offset overlays
As the first argument, you can pass an offset to the hook that will be used as the top offset in the returned styles, allowing you to adjust the containers position.
Still have questions?
Find answers in the Dynatrace Community