Skip to main content

Backdrop

Implementation#

import { Backdrop } from "slipstream-ui";
const Example = () => <Backdrop />;

Default#

<Backdrop>...</Backdrop>

Duration#

Speed up or slow down the transition with the duration attribute

<Backdrop duration="100">...</Backdrop>

Props#

AttributeTypeValueDefault ValueDescription
isOpenbooleantrue/falseTriggers the visibility of the backdrop
togglefunctionControl open state in your parent component state when the backdrop is clicked
usePortalbooleantrue/falsefalseRender component to the document body
zIndexnumbere.g. 99999999Specify, if needed, the z-index of the backdrop component
durationstring/number100/200/300/400/500
600/700/800/900/1000
500Specify transition speed at which the backdrop enters and leaves
custombooleantrue/falseRemove centering css logic for children elements