Skip to content
This repository has been archived by the owner on Jun 5, 2024. It is now read-only.

fix: fix TextTab binding to emit correct export #91

Merged
merged 2 commits into from
Dec 12, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions .changeset/eleven-walls-enjoy.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
---
"@greenlabs/formula-components": patch
"@greenlabs/rescript-formula-components": patch
---

fix: fix TextTab binding to emit correct export
12 changes: 6 additions & 6 deletions packages/components-rescript/src/Formula__TextTab.res
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
module List = {
@module("@greenlabs/formula-components") @react.component
@module("@greenlabs/formula-components") @scope("TextTab") @react.component
external make: (
~props: {..}=?,
~rootProps: {..}=?, // TODO: RadixUI props
Expand All @@ -8,7 +8,7 @@ module List = {
~onValueChange: string => unit=?,
~children: React.element,
~ref: ReactDOM.Ref.t=?,
) => React.element = "TextTab"
) => React.element = "List"
}

module Trigger = {
Expand All @@ -17,21 +17,21 @@ module Trigger = {
value?: int,
}

@module("@greenlabs/formula-components") @react.component
@module("@greenlabs/formula-components") @scope("TextTab") @react.component
external make: (
~icon: React.componentLike<{..}, React.element>=?, // FIXME: Icon component type
~title: string=?,
~badge: badgeType=?,
~value: string,
~children: React.element=?,
) => React.element = "TextTab"
) => React.element = "Trigger"
}

module Content = {
@module("@greenlabs/formula-components") @react.component
@module("@greenlabs/formula-components") @scope("TextTab") @react.component
external make: (
~value: string,
~children: React.element=?,
~props: ReactDOM.domProps=?,
) => React.element = "TextTab"
) => React.element = "Content"
}
4 changes: 2 additions & 2 deletions packages/components/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -74,8 +74,8 @@
"storybook": "start-storybook -p 6006",
"build:js": "rollup -c",
"build:types": "tsc -b",
"build:css": "cat ./dist/cjs/assets/**/*.css > ./dist/cjs/formula.css && cat ./dist/esm/assets/**/*.css > ./dist/esm/formula.css",
"build": "yarn clean && yarn build:js && yarn build:types && yarn build:css",
"build:css": "concurrently \"cat ./dist/cjs/assets/**/*.css > ./dist/cjs/formula.css\" \"cat ./dist/esm/assets/**/*.css > ./dist/esm/formula.css\"",
"build": "yarn clean && concurrently \"yarn build:js && yarn build:css\" \"yarn build:types\"",
"clean": "rm -rf ./dist",
"start": "concurrently -g -n re,storybook \"yarn re:watch\" \"yarn storybook\"",
"build:ts-icons": "cd src/Icon && yarn dlx @svgr/cli svgs --no-index && node ./templates/export-generator.js",
Expand Down