-
Notifications
You must be signed in to change notification settings - Fork 85
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(portal): add ts type definitions
- Loading branch information
1 parent
c127258
commit c769de8
Showing
2 changed files
with
15 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
export { default } from "./portal"; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
import * as React from "react"; | ||
|
||
export interface PortalProps { | ||
/** The content of the portal. */ | ||
children?: React.ReactNode; | ||
className?: string; | ||
id?: string; | ||
/** Callback function triggered when parent element is scrolled or window resized. */ | ||
onReposition?: () => void; | ||
} | ||
|
||
declare function Portal(props: PortalProps): JSX.Element; | ||
|
||
export default Portal; |