Portal
Renders its children above the rest of the window, outside the parent's clipping.
Import
import { Portal } from "@tarve/core";Usage
import { Badge, Portal, View } from "@tarve/core";
<Portal>
<View style={{ position: "absolute", right: 16, bottom: 16 }}>
<Badge>Rendered above everything</Badge>
</View>
</Portal>Props
Portal has no props of its own beyond the inherited and common props below.
Inherited from ViewProps 11 props
| Prop | Type | Default |
|---|---|---|
align | Style["align"] | — |
dismissOnOutside | boolean | — |
dragRegion | boolean | — |
flex | number | — |
focusable | boolean | — |
gap | number | — |
justify | Style["justify"] | — |
onOutsideClick | () => void | — |
padding | Style["padding"] | — |
portal | boolean | — |
windowAction | "minimize" | "toggleMaximize" | "close" | — |
Common props
Shared by every component. See descriptions →
childrenhighlightidkeymotionFromonHighlightonPasteonTransitionEndrovingGroupstyle