Skip to content

Commit

Permalink
feat(Others): add binding for Portal Component
Browse files Browse the repository at this point in the history
  • Loading branch information
r17x committed Jun 28, 2021
1 parent 762108e commit 68e9679
Show file tree
Hide file tree
Showing 5 changed files with 23 additions and 10 deletions.
4 changes: 2 additions & 2 deletions .yarnrc.yml
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
yarnPath: ".yarn/releases/yarn-berry.cjs"
nodeLinker: "node-modules"
nodeLinker: node-modules
yarnPath: .yarn/releases/yarn-berry.cjs
11 changes: 7 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -185,8 +185,6 @@ All of Style Props implementation is write in File:[Chakra__MakeProps.res](https
- [ ] Toast

### Typography
- [ ] Text
- [ ] Heading
- [x] Text
- [x] Heading

Expand Down Expand Up @@ -214,8 +212,13 @@ All of Style Props implementation is write in File:[Chakra__MakeProps.res](https
- [x] Image

### Others
- [ ] Portal
- [ ] Transitions
- [x] Portal
- [x] Transitions
- [x] Fade
- [x] ScaleFade
- [x] Slide
- [x] SlideFade
- [x] Collapse

### Hooks
- [ ] useBoolean
Expand Down
7 changes: 7 additions & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,13 @@
"name": "rescript-chakra",
"version": "1.2.0-next.1",
"description": "⚡️ ReScript bindings for @chakra-ui/react",
"keywords": [
"rescript",
"react",
"chakra-ui",
"ui-component",
"bindings"
],
"author": "ri7nz <hi@rin.rocks>",
"license": "MIT",
"homepage": "https://rescript-chakra.vercel.app/",
Expand Down
5 changes: 1 addition & 4 deletions src/Chakra.res
Original file line number Diff line number Diff line change
Expand Up @@ -103,10 +103,7 @@ module Icon = Chakra__Icon
module Image = Chakra__Image

// ### Others
// TODO Others
// module Portal = Chakra__Portal;
// module Transitions = Chakra__Transitions;

module Portal = Chakra__Portal
include Chakra__Transitions
// ### Hooks
// TODO Hooks
Expand Down
6 changes: 6 additions & 0 deletions src/Components/Chakra__Portal.res
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
@react.component @module("@chakra-ui/react")
external make: (
~children: React.element,
~appendToParentPortal: bool=?,
~containerRef: ReactDOM.domRef=?,
) => React.element = "Portal"

0 comments on commit 68e9679

Please sign in to comment.