UNPKG

@atlaskit/portal

Version:

A wrapper for rendering components in React portals.

77 lines (54 loc) 1.65 kB
<!-- API Report Version: 2.3 --> ## API Report File for "@atlaskit/portal" > Do not edit this file. This report is auto-generated using > [API Extractor](https://api-extractor.com/). > [Learn more about API reports](https://hello.atlassian.net/wiki/spaces/UR/pages/1825484529/Package+API+Reports) ### Table of contents - [Main Entry Types](#main-entry-types) - [Peer Dependencies](#peer-dependencies) ### Main Entry Types <!--SECTION START: Main Entry Types--> ```ts /// <reference types="react" /> import type { Layers } from '@atlaskit/theme/types'; import { default as React_2 } from 'react'; // @public type LayerName = keyof Layers; // @public (undocumented) type MountStrategy = 'effect' | 'layoutEffect'; // @public (undocumented) function Portal({ zIndex, children, mountStrategy }: PortalProps): JSX.Element | null; export default Portal; // @public (undocumented) export const PORTAL_MOUNT_EVENT = 'akPortalMount'; // @public (undocumented) export const PORTAL_UNMOUNT_EVENT = 'akPortalUnmount'; // @public export type PortalEvent = CustomEvent<PortalEventDetail>; // @public interface PortalEventDetail { // (undocumented) layer: LayerName | null; // (undocumented) zIndex: number; } // @public export interface PortalProps { // (undocumented) children: React_2.ReactNode; mountStrategy?: MountStrategy; // (undocumented) zIndex?: number | string; } // (No @packageDocumentation comment for this package) ``` <!--SECTION END: Main Entry Types--> ### Peer Dependencies <!--SECTION START: Peer Dependencies--> ```json { "react": "^16.8.0", "react-dom": "^16.8.0" } ``` <!--SECTION END: Peer Dependencies-->