@dashforge/tw 0.1.0-beta
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.swcrc +29 -0
- package/CHANGELOG.md +131 -0
- package/LICENSE +21 -0
- package/README.md +244 -0
- package/dist/components/AppShell/AppShell.d.ts +32 -0
- package/dist/components/AppShell/AppShell.d.ts.map +1 -0
- package/dist/components/AppShell/appShell.types.d.ts +62 -0
- package/dist/components/AppShell/appShell.types.d.ts.map +1 -0
- package/dist/components/AppShell/appShell.variants.d.ts +65 -0
- package/dist/components/AppShell/appShell.variants.d.ts.map +1 -0
- package/dist/components/Autocomplete/Autocomplete.d.ts +32 -0
- package/dist/components/Autocomplete/Autocomplete.d.ts.map +1 -0
- package/dist/components/Autocomplete/autocomplete.types.d.ts +214 -0
- package/dist/components/Autocomplete/autocomplete.types.d.ts.map +1 -0
- package/dist/components/Autocomplete/autocomplete.variants.d.ts +214 -0
- package/dist/components/Autocomplete/autocomplete.variants.d.ts.map +1 -0
- package/dist/components/Breadcrumbs/Breadcrumbs.d.ts +23 -0
- package/dist/components/Breadcrumbs/Breadcrumbs.d.ts.map +1 -0
- package/dist/components/Breadcrumbs/breadcrumbs.types.d.ts +98 -0
- package/dist/components/Breadcrumbs/breadcrumbs.types.d.ts.map +1 -0
- package/dist/components/Breadcrumbs/breadcrumbs.variants.d.ts +85 -0
- package/dist/components/Breadcrumbs/breadcrumbs.variants.d.ts.map +1 -0
- package/dist/components/Button/Button.d.ts +44 -0
- package/dist/components/Button/Button.d.ts.map +1 -0
- package/dist/components/Button/button.types.d.ts +66 -0
- package/dist/components/Button/button.types.d.ts.map +1 -0
- package/dist/components/Button/button.variants.d.ts +104 -0
- package/dist/components/Button/button.variants.d.ts.map +1 -0
- package/dist/components/Checkbox/Checkbox.d.ts +31 -0
- package/dist/components/Checkbox/Checkbox.d.ts.map +1 -0
- package/dist/components/Checkbox/checkbox.types.d.ts +86 -0
- package/dist/components/Checkbox/checkbox.types.d.ts.map +1 -0
- package/dist/components/Checkbox/checkbox.variants.d.ts +109 -0
- package/dist/components/Checkbox/checkbox.variants.d.ts.map +1 -0
- package/dist/components/ConfirmDialog/ConfirmDialog.d.ts +38 -0
- package/dist/components/ConfirmDialog/ConfirmDialog.d.ts.map +1 -0
- package/dist/components/ConfirmDialog/confirmDialog.types.d.ts +80 -0
- package/dist/components/ConfirmDialog/confirmDialog.types.d.ts.map +1 -0
- package/dist/components/ConfirmDialog/confirmDialog.variants.d.ts +90 -0
- package/dist/components/ConfirmDialog/confirmDialog.variants.d.ts.map +1 -0
- package/dist/components/DateTimePicker/DateTimePicker.d.ts +49 -0
- package/dist/components/DateTimePicker/DateTimePicker.d.ts.map +1 -0
- package/dist/components/DateTimePicker/dateTimePicker.types.d.ts +95 -0
- package/dist/components/DateTimePicker/dateTimePicker.types.d.ts.map +1 -0
- package/dist/components/DateTimePicker/dateTimePicker.variants.d.ts +165 -0
- package/dist/components/DateTimePicker/dateTimePicker.variants.d.ts.map +1 -0
- package/dist/components/LeftNav/LeftNav.d.ts +34 -0
- package/dist/components/LeftNav/LeftNav.d.ts.map +1 -0
- package/dist/components/LeftNav/leftNav.types.d.ts +136 -0
- package/dist/components/LeftNav/leftNav.types.d.ts.map +1 -0
- package/dist/components/LeftNav/leftNav.variants.d.ts +143 -0
- package/dist/components/LeftNav/leftNav.variants.d.ts.map +1 -0
- package/dist/components/NumberField/NumberField.d.ts +18 -0
- package/dist/components/NumberField/NumberField.d.ts.map +1 -0
- package/dist/components/NumberField/numberField.types.d.ts +79 -0
- package/dist/components/NumberField/numberField.types.d.ts.map +1 -0
- package/dist/components/NumberField/numberField.variants.d.ts +169 -0
- package/dist/components/NumberField/numberField.variants.d.ts.map +1 -0
- package/dist/components/OTPField/OTPField.d.ts +25 -0
- package/dist/components/OTPField/OTPField.d.ts.map +1 -0
- package/dist/components/OTPField/otpField.types.d.ts +74 -0
- package/dist/components/OTPField/otpField.types.d.ts.map +1 -0
- package/dist/components/OTPField/otpField.variants.d.ts +105 -0
- package/dist/components/OTPField/otpField.variants.d.ts.map +1 -0
- package/dist/components/RadioGroup/RadioGroup.d.ts +35 -0
- package/dist/components/RadioGroup/RadioGroup.d.ts.map +1 -0
- package/dist/components/RadioGroup/radioGroup.types.d.ts +103 -0
- package/dist/components/RadioGroup/radioGroup.types.d.ts.map +1 -0
- package/dist/components/RadioGroup/radioGroup.variants.d.ts +166 -0
- package/dist/components/RadioGroup/radioGroup.variants.d.ts.map +1 -0
- package/dist/components/Snackbar/Snackbar.d.ts +37 -0
- package/dist/components/Snackbar/Snackbar.d.ts.map +1 -0
- package/dist/components/Snackbar/snackbar.types.d.ts +86 -0
- package/dist/components/Snackbar/snackbar.types.d.ts.map +1 -0
- package/dist/components/Snackbar/snackbar.variants.d.ts +153 -0
- package/dist/components/Snackbar/snackbar.variants.d.ts.map +1 -0
- package/dist/components/Switch/Switch.d.ts +15 -0
- package/dist/components/Switch/Switch.d.ts.map +1 -0
- package/dist/components/Switch/switch.types.d.ts +47 -0
- package/dist/components/Switch/switch.types.d.ts.map +1 -0
- package/dist/components/Switch/switch.variants.d.ts +105 -0
- package/dist/components/Switch/switch.variants.d.ts.map +1 -0
- package/dist/components/TextField/TextField.d.ts +25 -0
- package/dist/components/TextField/TextField.d.ts.map +1 -0
- package/dist/components/TextField/textField.types.d.ts +72 -0
- package/dist/components/TextField/textField.types.d.ts.map +1 -0
- package/dist/components/TextField/textField.variants.d.ts +160 -0
- package/dist/components/TextField/textField.variants.d.ts.map +1 -0
- package/dist/components/Textarea/Textarea.d.ts +16 -0
- package/dist/components/Textarea/Textarea.d.ts.map +1 -0
- package/dist/components/Textarea/textarea.types.d.ts +63 -0
- package/dist/components/Textarea/textarea.types.d.ts.map +1 -0
- package/dist/components/Textarea/textarea.variants.d.ts +197 -0
- package/dist/components/Textarea/textarea.variants.d.ts.map +1 -0
- package/dist/components/TopBar/TopBar.d.ts +33 -0
- package/dist/components/TopBar/TopBar.d.ts.map +1 -0
- package/dist/components/TopBar/topBar.types.d.ts +49 -0
- package/dist/components/TopBar/topBar.types.d.ts.map +1 -0
- package/dist/components/TopBar/topBar.variants.d.ts +79 -0
- package/dist/components/TopBar/topBar.variants.d.ts.map +1 -0
- package/dist/components/_shared/resolveValidationState.d.ts +42 -0
- package/dist/components/_shared/resolveValidationState.d.ts.map +1 -0
- package/dist/hooks/useAccessState.d.ts +37 -0
- package/dist/hooks/useAccessState.d.ts.map +1 -0
- package/dist/index.d.ts +82 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.esm.js +4958 -0
- package/dist/src/components/AppShell/AppShell.d.ts +32 -0
- package/dist/src/components/AppShell/AppShell.d.ts.map +1 -0
- package/dist/src/components/AppShell/appShell.types.d.ts +62 -0
- package/dist/src/components/AppShell/appShell.types.d.ts.map +1 -0
- package/dist/src/components/AppShell/appShell.variants.d.ts +65 -0
- package/dist/src/components/AppShell/appShell.variants.d.ts.map +1 -0
- package/dist/src/components/Autocomplete/Autocomplete.d.ts +32 -0
- package/dist/src/components/Autocomplete/Autocomplete.d.ts.map +1 -0
- package/dist/src/components/Autocomplete/autocomplete.types.d.ts +214 -0
- package/dist/src/components/Autocomplete/autocomplete.types.d.ts.map +1 -0
- package/dist/src/components/Autocomplete/autocomplete.variants.d.ts +214 -0
- package/dist/src/components/Autocomplete/autocomplete.variants.d.ts.map +1 -0
- package/dist/src/components/Breadcrumbs/Breadcrumbs.d.ts +23 -0
- package/dist/src/components/Breadcrumbs/Breadcrumbs.d.ts.map +1 -0
- package/dist/src/components/Breadcrumbs/breadcrumbs.types.d.ts +98 -0
- package/dist/src/components/Breadcrumbs/breadcrumbs.types.d.ts.map +1 -0
- package/dist/src/components/Breadcrumbs/breadcrumbs.variants.d.ts +85 -0
- package/dist/src/components/Breadcrumbs/breadcrumbs.variants.d.ts.map +1 -0
- package/dist/src/components/Button/Button.d.ts +44 -0
- package/dist/src/components/Button/Button.d.ts.map +1 -0
- package/dist/src/components/Button/button.types.d.ts +66 -0
- package/dist/src/components/Button/button.types.d.ts.map +1 -0
- package/dist/src/components/Button/button.variants.d.ts +104 -0
- package/dist/src/components/Button/button.variants.d.ts.map +1 -0
- package/dist/src/components/Checkbox/Checkbox.d.ts +31 -0
- package/dist/src/components/Checkbox/Checkbox.d.ts.map +1 -0
- package/dist/src/components/Checkbox/checkbox.types.d.ts +86 -0
- package/dist/src/components/Checkbox/checkbox.types.d.ts.map +1 -0
- package/dist/src/components/Checkbox/checkbox.variants.d.ts +109 -0
- package/dist/src/components/Checkbox/checkbox.variants.d.ts.map +1 -0
- package/dist/src/components/ConfirmDialog/ConfirmDialog.d.ts +38 -0
- package/dist/src/components/ConfirmDialog/ConfirmDialog.d.ts.map +1 -0
- package/dist/src/components/ConfirmDialog/confirmDialog.types.d.ts +80 -0
- package/dist/src/components/ConfirmDialog/confirmDialog.types.d.ts.map +1 -0
- package/dist/src/components/ConfirmDialog/confirmDialog.variants.d.ts +90 -0
- package/dist/src/components/ConfirmDialog/confirmDialog.variants.d.ts.map +1 -0
- package/dist/src/components/DateTimePicker/DateTimePicker.d.ts +49 -0
- package/dist/src/components/DateTimePicker/DateTimePicker.d.ts.map +1 -0
- package/dist/src/components/DateTimePicker/dateTimePicker.types.d.ts +95 -0
- package/dist/src/components/DateTimePicker/dateTimePicker.types.d.ts.map +1 -0
- package/dist/src/components/DateTimePicker/dateTimePicker.variants.d.ts +165 -0
- package/dist/src/components/DateTimePicker/dateTimePicker.variants.d.ts.map +1 -0
- package/dist/src/components/LeftNav/LeftNav.d.ts +34 -0
- package/dist/src/components/LeftNav/LeftNav.d.ts.map +1 -0
- package/dist/src/components/LeftNav/leftNav.types.d.ts +136 -0
- package/dist/src/components/LeftNav/leftNav.types.d.ts.map +1 -0
- package/dist/src/components/LeftNav/leftNav.variants.d.ts +143 -0
- package/dist/src/components/LeftNav/leftNav.variants.d.ts.map +1 -0
- package/dist/src/components/NumberField/NumberField.d.ts +18 -0
- package/dist/src/components/NumberField/NumberField.d.ts.map +1 -0
- package/dist/src/components/NumberField/numberField.types.d.ts +79 -0
- package/dist/src/components/NumberField/numberField.types.d.ts.map +1 -0
- package/dist/src/components/NumberField/numberField.variants.d.ts +169 -0
- package/dist/src/components/NumberField/numberField.variants.d.ts.map +1 -0
- package/dist/src/components/OTPField/OTPField.d.ts +25 -0
- package/dist/src/components/OTPField/OTPField.d.ts.map +1 -0
- package/dist/src/components/OTPField/otpField.types.d.ts +74 -0
- package/dist/src/components/OTPField/otpField.types.d.ts.map +1 -0
- package/dist/src/components/OTPField/otpField.variants.d.ts +105 -0
- package/dist/src/components/OTPField/otpField.variants.d.ts.map +1 -0
- package/dist/src/components/RadioGroup/RadioGroup.d.ts +35 -0
- package/dist/src/components/RadioGroup/RadioGroup.d.ts.map +1 -0
- package/dist/src/components/RadioGroup/radioGroup.types.d.ts +103 -0
- package/dist/src/components/RadioGroup/radioGroup.types.d.ts.map +1 -0
- package/dist/src/components/RadioGroup/radioGroup.variants.d.ts +166 -0
- package/dist/src/components/RadioGroup/radioGroup.variants.d.ts.map +1 -0
- package/dist/src/components/Snackbar/Snackbar.d.ts +37 -0
- package/dist/src/components/Snackbar/Snackbar.d.ts.map +1 -0
- package/dist/src/components/Snackbar/snackbar.types.d.ts +86 -0
- package/dist/src/components/Snackbar/snackbar.types.d.ts.map +1 -0
- package/dist/src/components/Snackbar/snackbar.variants.d.ts +153 -0
- package/dist/src/components/Snackbar/snackbar.variants.d.ts.map +1 -0
- package/dist/src/components/Switch/Switch.d.ts +15 -0
- package/dist/src/components/Switch/Switch.d.ts.map +1 -0
- package/dist/src/components/Switch/switch.types.d.ts +47 -0
- package/dist/src/components/Switch/switch.types.d.ts.map +1 -0
- package/dist/src/components/Switch/switch.variants.d.ts +105 -0
- package/dist/src/components/Switch/switch.variants.d.ts.map +1 -0
- package/dist/src/components/TextField/TextField.d.ts +25 -0
- package/dist/src/components/TextField/TextField.d.ts.map +1 -0
- package/dist/src/components/TextField/textField.types.d.ts +72 -0
- package/dist/src/components/TextField/textField.types.d.ts.map +1 -0
- package/dist/src/components/TextField/textField.variants.d.ts +160 -0
- package/dist/src/components/TextField/textField.variants.d.ts.map +1 -0
- package/dist/src/components/Textarea/Textarea.d.ts +16 -0
- package/dist/src/components/Textarea/Textarea.d.ts.map +1 -0
- package/dist/src/components/Textarea/textarea.types.d.ts +63 -0
- package/dist/src/components/Textarea/textarea.types.d.ts.map +1 -0
- package/dist/src/components/Textarea/textarea.variants.d.ts +197 -0
- package/dist/src/components/Textarea/textarea.variants.d.ts.map +1 -0
- package/dist/src/components/TopBar/TopBar.d.ts +33 -0
- package/dist/src/components/TopBar/TopBar.d.ts.map +1 -0
- package/dist/src/components/TopBar/topBar.types.d.ts +49 -0
- package/dist/src/components/TopBar/topBar.types.d.ts.map +1 -0
- package/dist/src/components/TopBar/topBar.variants.d.ts +79 -0
- package/dist/src/components/TopBar/topBar.variants.d.ts.map +1 -0
- package/dist/src/components/_shared/resolveValidationState.d.ts +42 -0
- package/dist/src/components/_shared/resolveValidationState.d.ts.map +1 -0
- package/dist/src/hooks/useAccessState.d.ts +37 -0
- package/dist/src/hooks/useAccessState.d.ts.map +1 -0
- package/dist/src/index.d.ts +82 -0
- package/dist/src/index.d.ts.map +1 -0
- package/dist/src/utils/cn.d.ts +26 -0
- package/dist/src/utils/cn.d.ts.map +1 -0
- package/dist/tsconfig.lib.tsbuildinfo +1 -0
- package/dist/utils/cn.d.ts +26 -0
- package/dist/utils/cn.d.ts.map +1 -0
- package/eslint.config.mjs +47 -0
- package/package.json +37 -0
- package/project.json +15 -0
- package/rollup.config.cjs +16 -0
- package/src/components/AppShell/AppShell.test.tsx +223 -0
- package/src/components/AppShell/AppShell.tsx +114 -0
- package/src/components/AppShell/appShell.types.ts +49 -0
- package/src/components/AppShell/appShell.variants.ts +48 -0
- package/src/components/Autocomplete/Autocomplete.perf.test.tsx +225 -0
- package/src/components/Autocomplete/Autocomplete.test.tsx +556 -0
- package/src/components/Autocomplete/Autocomplete.tsx +996 -0
- package/src/components/Autocomplete/autocomplete.types.ts +198 -0
- package/src/components/Autocomplete/autocomplete.variants.ts +135 -0
- package/src/components/Breadcrumbs/Breadcrumbs.perf.test.tsx +125 -0
- package/src/components/Breadcrumbs/Breadcrumbs.test.tsx +231 -0
- package/src/components/Breadcrumbs/Breadcrumbs.tsx +203 -0
- package/src/components/Breadcrumbs/breadcrumbs.types.ts +87 -0
- package/src/components/Breadcrumbs/breadcrumbs.variants.ts +49 -0
- package/src/components/Button/Button.test.tsx +183 -0
- package/src/components/Button/Button.tsx +139 -0
- package/src/components/Button/button.types.ts +74 -0
- package/src/components/Button/button.variants.ts +159 -0
- package/src/components/Checkbox/Checkbox.test.tsx +146 -0
- package/src/components/Checkbox/Checkbox.tsx +228 -0
- package/src/components/Checkbox/checkbox.types.ts +88 -0
- package/src/components/Checkbox/checkbox.variants.ts +68 -0
- package/src/components/ConfirmDialog/ConfirmDialog.perf.test.tsx +172 -0
- package/src/components/ConfirmDialog/ConfirmDialog.test.tsx +311 -0
- package/src/components/ConfirmDialog/ConfirmDialog.tsx +252 -0
- package/src/components/ConfirmDialog/confirmDialog.types.ts +70 -0
- package/src/components/ConfirmDialog/confirmDialog.variants.ts +76 -0
- package/src/components/DateTimePicker/DateTimePicker.perf.test.tsx +153 -0
- package/src/components/DateTimePicker/DateTimePicker.test.tsx +204 -0
- package/src/components/DateTimePicker/DateTimePicker.tsx +319 -0
- package/src/components/DateTimePicker/dateTimePicker.types.ts +83 -0
- package/src/components/DateTimePicker/dateTimePicker.variants.ts +84 -0
- package/src/components/LeftNav/LeftNav.perf.test.tsx +172 -0
- package/src/components/LeftNav/LeftNav.test.tsx +302 -0
- package/src/components/LeftNav/LeftNav.tsx +330 -0
- package/src/components/LeftNav/leftNav.types.ts +120 -0
- package/src/components/LeftNav/leftNav.variants.ts +96 -0
- package/src/components/NumberField/NumberField.test.tsx +83 -0
- package/src/components/NumberField/NumberField.tsx +293 -0
- package/src/components/NumberField/numberField.types.ts +72 -0
- package/src/components/NumberField/numberField.variants.ts +94 -0
- package/src/components/OTPField/OTPField.test.tsx +121 -0
- package/src/components/OTPField/OTPField.tsx +250 -0
- package/src/components/OTPField/otpField.types.ts +58 -0
- package/src/components/OTPField/otpField.variants.ts +72 -0
- package/src/components/RadioGroup/RadioGroup.test.tsx +140 -0
- package/src/components/RadioGroup/RadioGroup.tsx +261 -0
- package/src/components/RadioGroup/radioGroup.types.ts +85 -0
- package/src/components/RadioGroup/radioGroup.variants.ts +87 -0
- package/src/components/Snackbar/Snackbar.perf.test.tsx +144 -0
- package/src/components/Snackbar/Snackbar.test.tsx +327 -0
- package/src/components/Snackbar/Snackbar.tsx +298 -0
- package/src/components/Snackbar/snackbar.types.ts +83 -0
- package/src/components/Snackbar/snackbar.variants.ts +72 -0
- package/src/components/Switch/Switch.test.tsx +131 -0
- package/src/components/Switch/Switch.tsx +158 -0
- package/src/components/Switch/switch.types.ts +36 -0
- package/src/components/Switch/switch.variants.ts +65 -0
- package/src/components/TextField/TextField.test.tsx +194 -0
- package/src/components/TextField/TextField.tsx +216 -0
- package/src/components/TextField/textField.types.ts +70 -0
- package/src/components/TextField/textField.variants.ts +87 -0
- package/src/components/Textarea/Textarea.test.tsx +75 -0
- package/src/components/Textarea/Textarea.tsx +190 -0
- package/src/components/Textarea/textarea.types.ts +60 -0
- package/src/components/Textarea/textarea.variants.ts +85 -0
- package/src/components/TopBar/TopBar.test.tsx +129 -0
- package/src/components/TopBar/TopBar.tsx +66 -0
- package/src/components/TopBar/topBar.types.ts +42 -0
- package/src/components/TopBar/topBar.variants.ts +38 -0
- package/src/components/_shared/resolveValidationState.ts +60 -0
- package/src/hooks/useAccessState.spec.tsx +161 -0
- package/src/hooks/useAccessState.ts +81 -0
- package/src/index.ts +191 -0
- package/src/utils/cn.spec.ts +16 -0
- package/src/utils/cn.ts +29 -0
- package/tsconfig.json +13 -0
- package/tsconfig.lib.json +55 -0
- package/tsconfig.spec.json +34 -0
- package/vite.config.ts +25 -0
- package/vitest.config.mts +22 -0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,SAAS,CAAC;IACvB,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,KAAK,CAAC,EAAE,OAAO,CAAC;IAChB,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,wEAAwE;IACxE,WAAW,CAAC,EAAE,CAAC,MAAM,EAAE,MAAM,KAAK,OAAO,CAAC;IAC1C,mEAAmE;IACnE,MAAM,CAAC,EAAE,iBAAiB,CAAC;IAC3B,oEAAoE;IACpE,EAAE,CAAC,EAAE,MAAM,CAAC;IACZ,oCAAoC;IACpC,SAAS,CAAC,EAAE,iBAAiB,CAAC;IAC9B,qEAAqE;IACrE,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,0DAA0D;IAC1D,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,kEAAkE;IAClE,QAAQ,CAAC,EAAE,kBAAkB,CAAC,mBAAmB,CAAC,CAAC;IACnD,kEAAkE;IAClE,MAAM,CAAC,EAAE,iBAAiB,CAAC,mBAAmB,CAAC,CAAC;IAChD,8DAA8D;IAC9D,IAAI,CAAC,EAAE,MAAM,CAAC;CACf"}
|
|
@@ -0,0 +1,197 @@
|
|
|
1
|
+
import { type VariantProps } from 'tailwind-variants';
|
|
2
|
+
/**
|
|
3
|
+
* Tailwind-variants recipe for `<Textarea>` with 7 slots.
|
|
4
|
+
*
|
|
5
|
+
* Sibling of `<TextField>` but renders a multi-line `<textarea>` element
|
|
6
|
+
* instead of a single-line `<input>`. Shares the same slot taxonomy +
|
|
7
|
+
* variant axes so consumers can swap the two without rewriting overrides.
|
|
8
|
+
*/
|
|
9
|
+
export declare const textareaVariants: import("tailwind-variants").TVReturnType<{
|
|
10
|
+
size: {
|
|
11
|
+
sm: {
|
|
12
|
+
inputWrapper: string;
|
|
13
|
+
input: string;
|
|
14
|
+
};
|
|
15
|
+
md: {
|
|
16
|
+
inputWrapper: string;
|
|
17
|
+
input: string;
|
|
18
|
+
};
|
|
19
|
+
lg: {
|
|
20
|
+
inputWrapper: string;
|
|
21
|
+
input: string;
|
|
22
|
+
};
|
|
23
|
+
};
|
|
24
|
+
layout: {
|
|
25
|
+
stacked: {
|
|
26
|
+
root: string;
|
|
27
|
+
};
|
|
28
|
+
inline: {
|
|
29
|
+
root: string;
|
|
30
|
+
label: string;
|
|
31
|
+
};
|
|
32
|
+
};
|
|
33
|
+
error: {
|
|
34
|
+
true: {
|
|
35
|
+
inputWrapper: string;
|
|
36
|
+
};
|
|
37
|
+
};
|
|
38
|
+
fullWidth: {
|
|
39
|
+
true: {
|
|
40
|
+
root: string;
|
|
41
|
+
inputWrapper: string;
|
|
42
|
+
};
|
|
43
|
+
};
|
|
44
|
+
disabled: {
|
|
45
|
+
true: {
|
|
46
|
+
inputWrapper: string;
|
|
47
|
+
};
|
|
48
|
+
};
|
|
49
|
+
resize: {
|
|
50
|
+
none: {
|
|
51
|
+
input: string;
|
|
52
|
+
};
|
|
53
|
+
vertical: {
|
|
54
|
+
input: string;
|
|
55
|
+
};
|
|
56
|
+
horizontal: {
|
|
57
|
+
input: string;
|
|
58
|
+
};
|
|
59
|
+
both: {
|
|
60
|
+
input: string;
|
|
61
|
+
};
|
|
62
|
+
};
|
|
63
|
+
}, {
|
|
64
|
+
root: string;
|
|
65
|
+
label: string;
|
|
66
|
+
requiredMark: string;
|
|
67
|
+
inputWrapper: string[];
|
|
68
|
+
input: string[];
|
|
69
|
+
helperText: string;
|
|
70
|
+
errorText: string;
|
|
71
|
+
}, undefined, {
|
|
72
|
+
size: {
|
|
73
|
+
sm: {
|
|
74
|
+
inputWrapper: string;
|
|
75
|
+
input: string;
|
|
76
|
+
};
|
|
77
|
+
md: {
|
|
78
|
+
inputWrapper: string;
|
|
79
|
+
input: string;
|
|
80
|
+
};
|
|
81
|
+
lg: {
|
|
82
|
+
inputWrapper: string;
|
|
83
|
+
input: string;
|
|
84
|
+
};
|
|
85
|
+
};
|
|
86
|
+
layout: {
|
|
87
|
+
stacked: {
|
|
88
|
+
root: string;
|
|
89
|
+
};
|
|
90
|
+
inline: {
|
|
91
|
+
root: string;
|
|
92
|
+
label: string;
|
|
93
|
+
};
|
|
94
|
+
};
|
|
95
|
+
error: {
|
|
96
|
+
true: {
|
|
97
|
+
inputWrapper: string;
|
|
98
|
+
};
|
|
99
|
+
};
|
|
100
|
+
fullWidth: {
|
|
101
|
+
true: {
|
|
102
|
+
root: string;
|
|
103
|
+
inputWrapper: string;
|
|
104
|
+
};
|
|
105
|
+
};
|
|
106
|
+
disabled: {
|
|
107
|
+
true: {
|
|
108
|
+
inputWrapper: string;
|
|
109
|
+
};
|
|
110
|
+
};
|
|
111
|
+
resize: {
|
|
112
|
+
none: {
|
|
113
|
+
input: string;
|
|
114
|
+
};
|
|
115
|
+
vertical: {
|
|
116
|
+
input: string;
|
|
117
|
+
};
|
|
118
|
+
horizontal: {
|
|
119
|
+
input: string;
|
|
120
|
+
};
|
|
121
|
+
both: {
|
|
122
|
+
input: string;
|
|
123
|
+
};
|
|
124
|
+
};
|
|
125
|
+
}, {
|
|
126
|
+
root: string;
|
|
127
|
+
label: string;
|
|
128
|
+
requiredMark: string;
|
|
129
|
+
inputWrapper: string[];
|
|
130
|
+
input: string[];
|
|
131
|
+
helperText: string;
|
|
132
|
+
errorText: string;
|
|
133
|
+
}, import("tailwind-variants").TVReturnType<{
|
|
134
|
+
size: {
|
|
135
|
+
sm: {
|
|
136
|
+
inputWrapper: string;
|
|
137
|
+
input: string;
|
|
138
|
+
};
|
|
139
|
+
md: {
|
|
140
|
+
inputWrapper: string;
|
|
141
|
+
input: string;
|
|
142
|
+
};
|
|
143
|
+
lg: {
|
|
144
|
+
inputWrapper: string;
|
|
145
|
+
input: string;
|
|
146
|
+
};
|
|
147
|
+
};
|
|
148
|
+
layout: {
|
|
149
|
+
stacked: {
|
|
150
|
+
root: string;
|
|
151
|
+
};
|
|
152
|
+
inline: {
|
|
153
|
+
root: string;
|
|
154
|
+
label: string;
|
|
155
|
+
};
|
|
156
|
+
};
|
|
157
|
+
error: {
|
|
158
|
+
true: {
|
|
159
|
+
inputWrapper: string;
|
|
160
|
+
};
|
|
161
|
+
};
|
|
162
|
+
fullWidth: {
|
|
163
|
+
true: {
|
|
164
|
+
root: string;
|
|
165
|
+
inputWrapper: string;
|
|
166
|
+
};
|
|
167
|
+
};
|
|
168
|
+
disabled: {
|
|
169
|
+
true: {
|
|
170
|
+
inputWrapper: string;
|
|
171
|
+
};
|
|
172
|
+
};
|
|
173
|
+
resize: {
|
|
174
|
+
none: {
|
|
175
|
+
input: string;
|
|
176
|
+
};
|
|
177
|
+
vertical: {
|
|
178
|
+
input: string;
|
|
179
|
+
};
|
|
180
|
+
horizontal: {
|
|
181
|
+
input: string;
|
|
182
|
+
};
|
|
183
|
+
both: {
|
|
184
|
+
input: string;
|
|
185
|
+
};
|
|
186
|
+
};
|
|
187
|
+
}, {
|
|
188
|
+
root: string;
|
|
189
|
+
label: string;
|
|
190
|
+
requiredMark: string;
|
|
191
|
+
inputWrapper: string[];
|
|
192
|
+
input: string[];
|
|
193
|
+
helperText: string;
|
|
194
|
+
errorText: string;
|
|
195
|
+
}, undefined, unknown, unknown, undefined>>;
|
|
196
|
+
export type TextareaVariants = VariantProps<typeof textareaVariants>;
|
|
197
|
+
//# sourceMappingURL=textarea.variants.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"textarea.variants.d.ts","sourceRoot":"","sources":["../../../../src/components/Textarea/textarea.variants.ts"],"names":[],"mappings":"AAAA,OAAO,EAAM,KAAK,YAAY,EAAE,MAAM,mBAAmB,CAAC;AAE1D;;;;;;GAMG;AACH,eAAO,MAAM,gBAAgB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2CAyE3B,CAAC;AAEH,MAAM,MAAM,gBAAgB,GAAG,YAAY,CAAC,OAAO,gBAAgB,CAAC,CAAC"}
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
import type { TopBarProps } from './topBar.types.js';
|
|
2
|
+
/**
|
|
3
|
+
* Dashforge TW TopBar — sticky header with 3 named slots.
|
|
4
|
+
*
|
|
5
|
+
* Pure composition. Three regions arranged horizontally:
|
|
6
|
+
*
|
|
7
|
+
* ┌──────────────────────────────────────────────────────────┐
|
|
8
|
+
* │ start │ center │ end │
|
|
9
|
+
* └──────────────────────────────────────────────────────────┘
|
|
10
|
+
*
|
|
11
|
+
* - `start` and `end` shrink to content.
|
|
12
|
+
* - `center` grows to fill remaining space.
|
|
13
|
+
* - If you pass `children` instead of `center`, those children render
|
|
14
|
+
* in the center region — handy for terse JSX:
|
|
15
|
+
*
|
|
16
|
+
* ```tsx
|
|
17
|
+
* <TopBar start={<Logo />} end={<UserMenu />}>
|
|
18
|
+
* <Breadcrumbs items={trail} />
|
|
19
|
+
* </TopBar>
|
|
20
|
+
* ```
|
|
21
|
+
*
|
|
22
|
+
* Default renders as `<header role="banner">` (implicit from
|
|
23
|
+
* `<header>` as a top-level landmark). Pass `asDiv` for cases where
|
|
24
|
+
* you don't want the banner role (e.g., nested inside another header).
|
|
25
|
+
*
|
|
26
|
+
* **A11y**:
|
|
27
|
+
* - `<header>` is a banner landmark — only one per page; if you put
|
|
28
|
+
* multiple TopBars on a page, use `asDiv` on the secondary ones.
|
|
29
|
+
* - Slots are agnostic about ARIA — wrap your slot content with
|
|
30
|
+
* appropriate roles (`<nav>`, `<search>`, etc.) where needed.
|
|
31
|
+
*/
|
|
32
|
+
export declare function TopBar(props: TopBarProps): import("react/jsx-runtime").JSX.Element;
|
|
33
|
+
//# sourceMappingURL=TopBar.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"TopBar.d.ts","sourceRoot":"","sources":["../../../../src/components/TopBar/TopBar.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,mBAAmB,CAAC;AAErD;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA6BG;AACH,wBAAgB,MAAM,CAAC,KAAK,EAAE,WAAW,2CA+BxC"}
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
import type { ReactNode } from 'react';
|
|
2
|
+
import type { TopBarVariants } from './topBar.variants.js';
|
|
3
|
+
export interface TopBarSlotProps {
|
|
4
|
+
root?: {
|
|
5
|
+
className?: string;
|
|
6
|
+
};
|
|
7
|
+
start?: {
|
|
8
|
+
className?: string;
|
|
9
|
+
};
|
|
10
|
+
center?: {
|
|
11
|
+
className?: string;
|
|
12
|
+
};
|
|
13
|
+
end?: {
|
|
14
|
+
className?: string;
|
|
15
|
+
};
|
|
16
|
+
}
|
|
17
|
+
/**
|
|
18
|
+
* Props for `<TopBar>`.
|
|
19
|
+
*
|
|
20
|
+
* Pure composition container with 3 named slots — `start`, `center`,
|
|
21
|
+
* `end` — that fill a sticky horizontal bar.
|
|
22
|
+
*
|
|
23
|
+
* Typical patterns:
|
|
24
|
+
*
|
|
25
|
+
* - **start**: mobile menu toggle, brand/logo
|
|
26
|
+
* - **center**: Breadcrumbs, page title, global search
|
|
27
|
+
* - **end**: notifications icon, user menu, theme toggle
|
|
28
|
+
*
|
|
29
|
+
* The component is intentionally minimal: it just lays out the three
|
|
30
|
+
* regions. All semantics (e.g., `<header role="banner">`) come for
|
|
31
|
+
* free from rendering as an HTML `<header>` element.
|
|
32
|
+
*/
|
|
33
|
+
export interface TopBarProps extends TopBarVariants {
|
|
34
|
+
/** Left-aligned slot (mobile menu, brand). */
|
|
35
|
+
start?: ReactNode;
|
|
36
|
+
/** Center slot (breadcrumbs, title). Grows to fill remaining space. */
|
|
37
|
+
center?: ReactNode;
|
|
38
|
+
/** Right-aligned slot (actions, user menu). */
|
|
39
|
+
end?: ReactNode;
|
|
40
|
+
/** Convenience: render the bar as a plain `<div>` (no banner role). */
|
|
41
|
+
asDiv?: boolean;
|
|
42
|
+
/** Root className shortcut. */
|
|
43
|
+
sx?: string;
|
|
44
|
+
/** Per-slot className overrides. */
|
|
45
|
+
slotProps?: TopBarSlotProps;
|
|
46
|
+
/** Children render between `start` and `end` when no `center` is set. */
|
|
47
|
+
children?: ReactNode;
|
|
48
|
+
}
|
|
49
|
+
//# sourceMappingURL=topBar.types.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"topBar.types.d.ts","sourceRoot":"","sources":["../../../../src/components/TopBar/topBar.types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AACvC,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,sBAAsB,CAAC;AAE3D,MAAM,WAAW,eAAe;IAC9B,IAAI,CAAC,EAAE;QAAE,SAAS,CAAC,EAAE,MAAM,CAAA;KAAE,CAAC;IAC9B,KAAK,CAAC,EAAE;QAAE,SAAS,CAAC,EAAE,MAAM,CAAA;KAAE,CAAC;IAC/B,MAAM,CAAC,EAAE;QAAE,SAAS,CAAC,EAAE,MAAM,CAAA;KAAE,CAAC;IAChC,GAAG,CAAC,EAAE;QAAE,SAAS,CAAC,EAAE,MAAM,CAAA;KAAE,CAAC;CAC9B;AAED;;;;;;;;;;;;;;;GAeG;AACH,MAAM,WAAW,WAAY,SAAQ,cAAc;IACjD,8CAA8C;IAC9C,KAAK,CAAC,EAAE,SAAS,CAAC;IAClB,uEAAuE;IACvE,MAAM,CAAC,EAAE,SAAS,CAAC;IACnB,+CAA+C;IAC/C,GAAG,CAAC,EAAE,SAAS,CAAC;IAChB,uEAAuE;IACvE,KAAK,CAAC,EAAE,OAAO,CAAC;IAChB,+BAA+B;IAC/B,EAAE,CAAC,EAAE,MAAM,CAAC;IACZ,oCAAoC;IACpC,SAAS,CAAC,EAAE,eAAe,CAAC;IAC5B,yEAAyE;IACzE,QAAQ,CAAC,EAAE,SAAS,CAAC;CACtB"}
|
|
@@ -0,0 +1,79 @@
|
|
|
1
|
+
import { type VariantProps } from 'tailwind-variants';
|
|
2
|
+
/**
|
|
3
|
+
* Tailwind-variants recipe for `<TopBar>`.
|
|
4
|
+
*
|
|
5
|
+
* Slots:
|
|
6
|
+
* - `root` — outer `<header>` (or `<div>` with `asDiv`)
|
|
7
|
+
* - `start` — left region (shrink-to-content)
|
|
8
|
+
* - `center` — middle region (grows to fill)
|
|
9
|
+
* - `end` — right region (shrink-to-content)
|
|
10
|
+
*/
|
|
11
|
+
export declare const topBarVariants: import("tailwind-variants").TVReturnType<{
|
|
12
|
+
height: {
|
|
13
|
+
sm: {
|
|
14
|
+
root: string;
|
|
15
|
+
};
|
|
16
|
+
md: {
|
|
17
|
+
root: string;
|
|
18
|
+
};
|
|
19
|
+
lg: {
|
|
20
|
+
root: string;
|
|
21
|
+
};
|
|
22
|
+
};
|
|
23
|
+
sticky: {
|
|
24
|
+
true: {
|
|
25
|
+
root: string;
|
|
26
|
+
};
|
|
27
|
+
};
|
|
28
|
+
}, {
|
|
29
|
+
root: string[];
|
|
30
|
+
start: string;
|
|
31
|
+
center: string;
|
|
32
|
+
end: string;
|
|
33
|
+
}, undefined, {
|
|
34
|
+
height: {
|
|
35
|
+
sm: {
|
|
36
|
+
root: string;
|
|
37
|
+
};
|
|
38
|
+
md: {
|
|
39
|
+
root: string;
|
|
40
|
+
};
|
|
41
|
+
lg: {
|
|
42
|
+
root: string;
|
|
43
|
+
};
|
|
44
|
+
};
|
|
45
|
+
sticky: {
|
|
46
|
+
true: {
|
|
47
|
+
root: string;
|
|
48
|
+
};
|
|
49
|
+
};
|
|
50
|
+
}, {
|
|
51
|
+
root: string[];
|
|
52
|
+
start: string;
|
|
53
|
+
center: string;
|
|
54
|
+
end: string;
|
|
55
|
+
}, import("tailwind-variants").TVReturnType<{
|
|
56
|
+
height: {
|
|
57
|
+
sm: {
|
|
58
|
+
root: string;
|
|
59
|
+
};
|
|
60
|
+
md: {
|
|
61
|
+
root: string;
|
|
62
|
+
};
|
|
63
|
+
lg: {
|
|
64
|
+
root: string;
|
|
65
|
+
};
|
|
66
|
+
};
|
|
67
|
+
sticky: {
|
|
68
|
+
true: {
|
|
69
|
+
root: string;
|
|
70
|
+
};
|
|
71
|
+
};
|
|
72
|
+
}, {
|
|
73
|
+
root: string[];
|
|
74
|
+
start: string;
|
|
75
|
+
center: string;
|
|
76
|
+
end: string;
|
|
77
|
+
}, undefined, unknown, unknown, undefined>>;
|
|
78
|
+
export type TopBarVariants = VariantProps<typeof topBarVariants>;
|
|
79
|
+
//# sourceMappingURL=topBar.variants.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"topBar.variants.d.ts","sourceRoot":"","sources":["../../../../src/components/TopBar/topBar.variants.ts"],"names":[],"mappings":"AAAA,OAAO,EAAM,KAAK,YAAY,EAAE,MAAM,mBAAmB,CAAC;AAE1D;;;;;;;;GAQG;AACH,eAAO,MAAM,cAAc;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2CAwBzB,CAAC;AAEH,MAAM,MAAM,cAAc,GAAG,YAAY,CAAC,OAAO,cAAc,CAAC,CAAC"}
|
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
import type { ReactNode } from 'react';
|
|
2
|
+
import type { DashFormBridge } from '@dashforge/ui-core';
|
|
3
|
+
/**
|
|
4
|
+
* Resolved validation state for a bridge-managed field.
|
|
5
|
+
*
|
|
6
|
+
* Returned by `resolveValidationState`, this is consumed by all form
|
|
7
|
+
* components that surface error + helper text (TextField, Checkbox,
|
|
8
|
+
* Switch, …) to derive their final render state.
|
|
9
|
+
*/
|
|
10
|
+
export interface ValidationState {
|
|
11
|
+
error: boolean;
|
|
12
|
+
helperText: ReactNode;
|
|
13
|
+
}
|
|
14
|
+
/**
|
|
15
|
+
* Compute `error` + `helperText` for a bridge-managed field.
|
|
16
|
+
*
|
|
17
|
+
* **Renderer-agnostic** — copy of the MUI-side
|
|
18
|
+
* `textField.validation.ts`. Promoted to a `_shared/` directory inside
|
|
19
|
+
* `@dashforge/tw` so all form components (TextField + Checkbox +
|
|
20
|
+
* Switch) reuse the same precedence logic without depending on a
|
|
21
|
+
* specific component folder.
|
|
22
|
+
*
|
|
23
|
+
* Precedence rules (matches MUI side byte-for-byte):
|
|
24
|
+
*
|
|
25
|
+
* 1. **Explicit props win.** If the user passed `error` / `helperText`
|
|
26
|
+
* explicitly, those values are used as-is.
|
|
27
|
+
* 2. **Auto values are gated by interaction.** The bridge's error is
|
|
28
|
+
* surfaced only when the field is `touched` OR the form has been
|
|
29
|
+
* submitted at least once (`submitCount > 0`). This prevents the
|
|
30
|
+
* "error spam while typing" anti-pattern.
|
|
31
|
+
* 3. **`error === false` explicitly clears the bridge's error message
|
|
32
|
+
* text.** Useful for forcing a "valid" visual state regardless of
|
|
33
|
+
* bridge state.
|
|
34
|
+
*
|
|
35
|
+
* @param name field name registered with the bridge
|
|
36
|
+
* @param bridge active `DashFormBridge` (guaranteed non-null at
|
|
37
|
+
* call sites by the surrounding `if (bridge)`)
|
|
38
|
+
* @param explicitError `error` prop from the consumer
|
|
39
|
+
* @param explicitHelperText `helperText` prop from the consumer
|
|
40
|
+
*/
|
|
41
|
+
export declare function resolveValidationState(name: string, bridge: DashFormBridge, explicitError: boolean | undefined, explicitHelperText: ReactNode | undefined): ValidationState;
|
|
42
|
+
//# sourceMappingURL=resolveValidationState.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"resolveValidationState.d.ts","sourceRoot":"","sources":["../../../../src/components/_shared/resolveValidationState.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AACvC,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,oBAAoB,CAAC;AAEzD;;;;;;GAMG;AACH,MAAM,WAAW,eAAe;IAC9B,KAAK,EAAE,OAAO,CAAC;IACf,UAAU,EAAE,SAAS,CAAC;CACvB;AAED;;;;;;;;;;;;;;;;;;;;;;;;;;GA0BG;AACH,wBAAgB,sBAAsB,CACpC,IAAI,EAAE,MAAM,EACZ,MAAM,EAAE,cAAc,EACtB,aAAa,EAAE,OAAO,GAAG,SAAS,EAClC,kBAAkB,EAAE,SAAS,GAAG,SAAS,GACxC,eAAe,CAYjB"}
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
import type { AccessRequirement, AccessState } from '@dashforge/rbac';
|
|
2
|
+
/**
|
|
3
|
+
* Hook to resolve RBAC access state for a UI component.
|
|
4
|
+
*
|
|
5
|
+
* **TW-side copy of the MUI implementation** in `@dashforge/ui/src/hooks/useAccessState.ts`.
|
|
6
|
+
* Per the architecture plan v2 (2026-05-15) the two ecosystems share
|
|
7
|
+
* only the bridge layer (`@dashforge/forms` + `@dashforge/ui-core` +
|
|
8
|
+
* `@dashforge/rbac`); UI-side hooks are duplicated intentionally so
|
|
9
|
+
* the MUI and TW ecosystems remain fully isolated.
|
|
10
|
+
*
|
|
11
|
+
* The behaviour is byte-equivalent to the MUI side:
|
|
12
|
+
*
|
|
13
|
+
* - If `access` is undefined → returns `DEFAULT_ACCESS_STATE`.
|
|
14
|
+
* - If `access` is supplied but no `RbacProvider` is mounted → returns
|
|
15
|
+
* `DEFAULT_ACCESS_STATE` and emits a dev-only `console.warn` so the
|
|
16
|
+
* developer notices the missing provider. Failing **open** is the
|
|
17
|
+
* safer default (RBAC silently denying everything would be a hidden
|
|
18
|
+
* regression in development).
|
|
19
|
+
* - Otherwise → evaluates the requirement against the active
|
|
20
|
+
* `rbac.engine` + `rbac.subject` via `resolveAccessState`.
|
|
21
|
+
*
|
|
22
|
+
* The memo dependency list is `[access, rbac]` — a stable RBAC
|
|
23
|
+
* context + identical access requirement re-uses the same result
|
|
24
|
+
* object so downstream `useMemo` / `React.memo` comparisons stay
|
|
25
|
+
* cheap.
|
|
26
|
+
*
|
|
27
|
+
* @example
|
|
28
|
+
* ```tsx
|
|
29
|
+
* function MyComponent({ access }: { access?: AccessRequirement }) {
|
|
30
|
+
* const accessState = useAccessState(access);
|
|
31
|
+
* if (!accessState.visible) return null;
|
|
32
|
+
* return <input disabled={accessState.disabled} readOnly={accessState.readonly} />;
|
|
33
|
+
* }
|
|
34
|
+
* ```
|
|
35
|
+
*/
|
|
36
|
+
export declare function useAccessState(access: AccessRequirement | undefined): AccessState;
|
|
37
|
+
//# sourceMappingURL=useAccessState.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"useAccessState.d.ts","sourceRoot":"","sources":["../../../src/hooks/useAccessState.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,iBAAiB,EAAE,WAAW,EAAE,MAAM,iBAAiB,CAAC;AAetE;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAiCG;AACH,wBAAgB,cAAc,CAC5B,MAAM,EAAE,iBAAiB,GAAG,SAAS,GACpC,WAAW,CA2Bb"}
|
|
@@ -0,0 +1,82 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @dashforge/tw
|
|
3
|
+
*
|
|
4
|
+
* Tailwind-rendered UI components for the Dashforge ecosystem.
|
|
5
|
+
*
|
|
6
|
+
* Architectural contract (plan v2 — 2026-05-15):
|
|
7
|
+
* - **Props-driven**: each Tailwind utility that matters for the public
|
|
8
|
+
* API becomes a typed prop. `sx` + `slotProps` are escape hatches.
|
|
9
|
+
* - **Tokens as source of truth**: components reference colors /
|
|
10
|
+
* spacing / radius / fontSize through `@dashforge/tw-tokens` via the
|
|
11
|
+
* `dashforgePreset()` from `@dashforge/tw-theme`.
|
|
12
|
+
* - **Shared bridge with MUI side**: both ecosystems consume
|
|
13
|
+
* `@dashforge/forms` + `@dashforge/ui-core` + `@dashforge/rbac`.
|
|
14
|
+
* No styling code is shared.
|
|
15
|
+
* - **Variant API**: `tailwind-variants` (TV) with `slots` +
|
|
16
|
+
* `compoundVariants`.
|
|
17
|
+
*
|
|
18
|
+
* F3 surface (tier-1, this release):
|
|
19
|
+
* - `<Button>` (action, RBAC only, `asChild` polymorphism)
|
|
20
|
+
* - `<TextField>` (bridge-integrated, 7 slots)
|
|
21
|
+
* - `<Checkbox>` (bridge-integrated, Radix Checkbox primitive)
|
|
22
|
+
* - `<Switch>` (bridge-integrated, Radix Switch primitive)
|
|
23
|
+
*
|
|
24
|
+
* @module @dashforge/tw
|
|
25
|
+
*/
|
|
26
|
+
export { Button } from './components/Button/Button.js';
|
|
27
|
+
export type { ButtonProps } from './components/Button/button.types.js';
|
|
28
|
+
export { buttonVariants } from './components/Button/button.variants.js';
|
|
29
|
+
export { TextField } from './components/TextField/TextField.js';
|
|
30
|
+
export type { TextFieldProps, TextFieldSlotProps, } from './components/TextField/textField.types.js';
|
|
31
|
+
export { textFieldVariants } from './components/TextField/textField.variants.js';
|
|
32
|
+
export { Checkbox } from './components/Checkbox/Checkbox.js';
|
|
33
|
+
export type { CheckboxProps, CheckboxSlotProps, } from './components/Checkbox/checkbox.types.js';
|
|
34
|
+
export { checkboxVariants } from './components/Checkbox/checkbox.variants.js';
|
|
35
|
+
export { Switch } from './components/Switch/Switch.js';
|
|
36
|
+
export type { SwitchProps, SwitchSlotProps, } from './components/Switch/switch.types.js';
|
|
37
|
+
export { switchVariants } from './components/Switch/switch.variants.js';
|
|
38
|
+
export { RadioGroup } from './components/RadioGroup/RadioGroup.js';
|
|
39
|
+
export type { RadioGroupProps, RadioGroupOption, RadioGroupSlotProps, } from './components/RadioGroup/radioGroup.types.js';
|
|
40
|
+
export { radioGroupVariants } from './components/RadioGroup/radioGroup.variants.js';
|
|
41
|
+
export { Textarea } from './components/Textarea/Textarea.js';
|
|
42
|
+
export type { TextareaProps, TextareaSlotProps, } from './components/Textarea/textarea.types.js';
|
|
43
|
+
export { textareaVariants } from './components/Textarea/textarea.variants.js';
|
|
44
|
+
export { NumberField } from './components/NumberField/NumberField.js';
|
|
45
|
+
export type { NumberFieldProps, NumberFieldSlotProps, } from './components/NumberField/numberField.types.js';
|
|
46
|
+
export { numberFieldVariants } from './components/NumberField/numberField.variants.js';
|
|
47
|
+
export { OTPField } from './components/OTPField/OTPField.js';
|
|
48
|
+
export type { OTPFieldProps, OTPFieldSlotProps, OTPFieldMode, } from './components/OTPField/otpField.types.js';
|
|
49
|
+
export { otpFieldVariants } from './components/OTPField/otpField.variants.js';
|
|
50
|
+
export { Autocomplete } from './components/Autocomplete/Autocomplete.js';
|
|
51
|
+
export type { AutocompleteProps, AutocompleteOption, AutocompleteSlotProps, AutocompleteValue, } from './components/Autocomplete/autocomplete.types.js';
|
|
52
|
+
export { autocompleteVariants } from './components/Autocomplete/autocomplete.variants.js';
|
|
53
|
+
export { DateTimePicker, isoToInputValue, } from './components/DateTimePicker/DateTimePicker.js';
|
|
54
|
+
export type { DateTimePickerProps, DateTimePickerMode, DateTimePickerSlotProps, } from './components/DateTimePicker/dateTimePicker.types.js';
|
|
55
|
+
export { dateTimePickerVariants } from './components/DateTimePicker/dateTimePicker.variants.js';
|
|
56
|
+
export { Breadcrumbs } from './components/Breadcrumbs/Breadcrumbs.js';
|
|
57
|
+
export type { BreadcrumbsProps, BreadcrumbItem, BreadcrumbsSlotProps, BreadcrumbLinkComponent, } from './components/Breadcrumbs/breadcrumbs.types.js';
|
|
58
|
+
export { breadcrumbsVariants } from './components/Breadcrumbs/breadcrumbs.variants.js';
|
|
59
|
+
export { LeftNav } from './components/LeftNav/LeftNav.js';
|
|
60
|
+
export type { LeftNavProps, LeftNavNode, LeftNavItem, LeftNavGroup, LeftNavSlotProps, LeftNavLinkComponent, } from './components/LeftNav/leftNav.types.js';
|
|
61
|
+
export { leftNavVariants } from './components/LeftNav/leftNav.variants.js';
|
|
62
|
+
export { TopBar } from './components/TopBar/TopBar.js';
|
|
63
|
+
export type { TopBarProps, TopBarSlotProps, } from './components/TopBar/topBar.types.js';
|
|
64
|
+
export { topBarVariants } from './components/TopBar/topBar.variants.js';
|
|
65
|
+
export { AppShell } from './components/AppShell/AppShell.js';
|
|
66
|
+
export type { AppShellProps, AppShellSlotProps, } from './components/AppShell/appShell.types.js';
|
|
67
|
+
export { appShellVariants } from './components/AppShell/appShell.variants.js';
|
|
68
|
+
export { ConfirmDialogProvider, useConfirm, } from './components/ConfirmDialog/ConfirmDialog.js';
|
|
69
|
+
export type { ConfirmDialogProviderProps, ConfirmDialogSlotProps, ConfirmFn, ConfirmOptions, ConfirmSeverity, } from './components/ConfirmDialog/confirmDialog.types.js';
|
|
70
|
+
export { confirmDialogVariants } from './components/ConfirmDialog/confirmDialog.variants.js';
|
|
71
|
+
export { SnackbarProvider, useSnackbar, } from './components/Snackbar/Snackbar.js';
|
|
72
|
+
export type { SnackbarProviderProps, SnackbarApi, SnackbarOptions, SnackbarRecord, SnackbarSeverity, SnackbarPosition, SnackbarSlotProps, } from './components/Snackbar/snackbar.types.js';
|
|
73
|
+
export { snackbarVariants } from './components/Snackbar/snackbar.variants.js';
|
|
74
|
+
export { useAccessState } from './hooks/useAccessState.js';
|
|
75
|
+
export { cn } from './utils/cn.js';
|
|
76
|
+
export { tv } from 'tailwind-variants';
|
|
77
|
+
export type { VariantProps } from 'tailwind-variants';
|
|
78
|
+
/**
|
|
79
|
+
* Package version (synced with `package.json` at publish time).
|
|
80
|
+
*/
|
|
81
|
+
export declare const VERSION = "0.1.0-beta";
|
|
82
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;GAwBG;AAGH,OAAO,EAAE,MAAM,EAAE,MAAM,+BAA+B,CAAC;AACvD,YAAY,EAAE,WAAW,EAAE,MAAM,qCAAqC,CAAC;AACvE,OAAO,EAAE,cAAc,EAAE,MAAM,wCAAwC,CAAC;AAExE,OAAO,EAAE,SAAS,EAAE,MAAM,qCAAqC,CAAC;AAChE,YAAY,EACV,cAAc,EACd,kBAAkB,GACn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,CAAC;AAE7F,OAAO,EACL,gBAAgB,EAChB,WAAW,GACZ,MAAM,mCAAmC,CAAC;AAC3C,YAAY,EACV,qBAAqB,EACrB,WAAW,EACX,eAAe,EACf,cAAc,EACd,gBAAgB,EAChB,gBAAgB,EAChB,iBAAiB,GAClB,MAAM,yCAAyC,CAAC;AACjD,OAAO,EAAE,gBAAgB,EAAE,MAAM,4CAA4C,CAAC;AAG9E,OAAO,EAAE,cAAc,EAAE,MAAM,2BAA2B,CAAC;AAG3D,OAAO,EAAE,EAAE,EAAE,MAAM,eAAe,CAAC;AAInC,OAAO,EAAE,EAAE,EAAE,MAAM,mBAAmB,CAAC;AACvC,YAAY,EAAE,YAAY,EAAE,MAAM,mBAAmB,CAAC;AAEtD;;GAEG;AACH,eAAO,MAAM,OAAO,eAAe,CAAC"}
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
import { type ClassValue } from 'clsx';
|
|
2
|
+
/**
|
|
3
|
+
* className composition helper for Dashforge TW components.
|
|
4
|
+
*
|
|
5
|
+
* Wraps `clsx` (for boolean / object / array compaction) with
|
|
6
|
+
* `tailwind-merge` (for last-wins conflict resolution between
|
|
7
|
+
* conflicting Tailwind utilities). This is the override contract
|
|
8
|
+
* that powers `sx` and `slotProps`:
|
|
9
|
+
*
|
|
10
|
+
* ```tsx
|
|
11
|
+
* cn(buttonVariants({ variant: 'solid', color: 'primary' }), sx)
|
|
12
|
+
* // sx="bg-red-500" beats the variant's `bg-primary-500`.
|
|
13
|
+
* ```
|
|
14
|
+
*
|
|
15
|
+
* Without `tailwind-merge`, Tailwind's stylesheet output order decides
|
|
16
|
+
* who wins, which is unpredictable for consumers and breaks the
|
|
17
|
+
* documented "override always wins" semantics.
|
|
18
|
+
*
|
|
19
|
+
* @example
|
|
20
|
+
* ```tsx
|
|
21
|
+
* <button className={cn('px-4 py-2', isPrimary && 'bg-primary-500')}>
|
|
22
|
+
* cn(['inline-flex', { 'opacity-50': disabled }], extra);
|
|
23
|
+
* ```
|
|
24
|
+
*/
|
|
25
|
+
export declare function cn(...inputs: ClassValue[]): string;
|
|
26
|
+
//# sourceMappingURL=cn.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"cn.d.ts","sourceRoot":"","sources":["../../../src/utils/cn.ts"],"names":[],"mappings":"AAAA,OAAa,EAAE,KAAK,UAAU,EAAE,MAAM,MAAM,CAAC;AAG7C;;;;;;;;;;;;;;;;;;;;;;GAsBG;AACH,wBAAgB,EAAE,CAAC,GAAG,MAAM,EAAE,UAAU,EAAE,GAAG,MAAM,CAElD"}
|