@panneau/ui 5.0.0-alpha.1 → 5.0.0-alpha.10
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/README.md +370 -14
- package/bin/check-theme.js +5 -0
- package/dist/alert/Alert.css +28 -42
- package/dist/alert/Alert.d.ts +19 -5
- package/dist/alert/Alert.d.ts.map +1 -1
- package/dist/alert/Alert.js +110 -41
- package/dist/alert/Alert.js.map +1 -1
- package/dist/alert/Alert.module.js +14 -16
- package/dist/alert/Alert.module.js.map +1 -1
- package/dist/alert/tokens.d.ts +3 -0
- package/dist/alert/tokens.d.ts.map +1 -0
- package/dist/alert/tokens.js +21 -0
- package/dist/alert/tokens.js.map +1 -0
- package/dist/badge/Badge.css +24 -36
- package/dist/badge/Badge.d.ts +18 -3
- package/dist/badge/Badge.d.ts.map +1 -1
- package/dist/badge/Badge.js +35 -6
- package/dist/badge/Badge.js.map +1 -1
- package/dist/badge/Badge.module.js +9 -13
- package/dist/badge/Badge.module.js.map +1 -1
- package/dist/badge/tokens.d.ts +3 -0
- package/dist/badge/tokens.d.ts.map +1 -0
- package/dist/badge/tokens.js +23 -0
- package/dist/badge/tokens.js.map +1 -0
- package/dist/button/Button.css +58 -42
- package/dist/button/Button.d.ts +32 -5
- package/dist/button/Button.d.ts.map +1 -1
- package/dist/button/Button.js +136 -17
- package/dist/button/Button.js.map +1 -1
- package/dist/button/Button.module.js +14 -14
- package/dist/button/Button.module.js.map +1 -1
- package/dist/button/tokens.d.ts +3 -0
- package/dist/button/tokens.d.ts.map +1 -0
- package/dist/button/tokens.js +25 -0
- package/dist/button/tokens.js.map +1 -0
- package/dist/card/Card.css +27 -20
- package/dist/card/Card.js +76 -23
- package/dist/card/Card.js.map +1 -1
- package/dist/card/Card.module.js +5 -5
- package/dist/card/Card.module.js.map +1 -1
- package/dist/card/tokens.d.ts +3 -0
- package/dist/card/tokens.d.ts.map +1 -0
- package/dist/card/tokens.js +31 -0
- package/dist/card/tokens.js.map +1 -0
- package/dist/checkbox/Checkbox.css +22 -21
- package/dist/checkbox/Checkbox.d.ts +1 -1
- package/dist/checkbox/Checkbox.d.ts.map +1 -1
- package/dist/checkbox/Checkbox.js +87 -25
- package/dist/checkbox/Checkbox.js.map +1 -1
- package/dist/checkbox/Checkbox.module.js +6 -6
- package/dist/checkbox/Checkbox.module.js.map +1 -1
- package/dist/checkbox/ChoiceChrome.d.ts +3 -1
- package/dist/checkbox/ChoiceChrome.d.ts.map +1 -1
- package/dist/checkbox/ChoiceChrome.js +82 -21
- package/dist/checkbox/ChoiceChrome.js.map +1 -1
- package/dist/checkbox/tokens.d.ts +3 -0
- package/dist/checkbox/tokens.d.ts.map +1 -0
- package/dist/checkbox/tokens.js +21 -0
- package/dist/checkbox/tokens.js.map +1 -0
- package/dist/combo-box/ComboBox.css +4 -4
- package/dist/combo-box/ComboBox.d.ts +1 -1
- package/dist/combo-box/ComboBox.js +291 -79
- package/dist/combo-box/ComboBox.js.map +1 -1
- package/dist/combo-box/ComboBox.module.js +3 -3
- package/dist/command-palette/CommandPalette.css +299 -0
- package/dist/command-palette/CommandPalette.d.ts +37 -0
- package/dist/command-palette/CommandPalette.d.ts.map +1 -0
- package/dist/command-palette/CommandPalette.js +497 -0
- package/dist/command-palette/CommandPalette.js.map +1 -0
- package/dist/command-palette/CommandPalette.module.js +62 -0
- package/dist/command-palette/CommandPalette.module.js.map +1 -0
- package/dist/command-palette/match.d.ts +39 -0
- package/dist/command-palette/match.d.ts.map +1 -0
- package/dist/command-palette/match.js +44 -0
- package/dist/command-palette/match.js.map +1 -0
- package/dist/command-palette/tokens.d.ts +3 -0
- package/dist/command-palette/tokens.d.ts.map +1 -0
- package/dist/command-palette/tokens.js +23 -0
- package/dist/command-palette/tokens.js.map +1 -0
- package/dist/command-palette/useCommandShortcut.d.ts +12 -0
- package/dist/command-palette/useCommandShortcut.d.ts.map +1 -0
- package/dist/command-palette/useCommandShortcut.js +48 -0
- package/dist/command-palette/useCommandShortcut.js.map +1 -0
- package/dist/container/Container.css +32 -0
- package/dist/container/Container.d.ts +15 -0
- package/dist/container/Container.d.ts.map +1 -0
- package/dist/container/Container.js +61 -0
- package/dist/container/Container.js.map +1 -0
- package/dist/container/Container.module.js +20 -0
- package/dist/container/Container.module.js.map +1 -0
- package/dist/container/tokens.d.ts +3 -0
- package/dist/container/tokens.d.ts.map +1 -0
- package/dist/container/tokens.js +19 -0
- package/dist/container/tokens.js.map +1 -0
- package/dist/date-picker/DatePicker.css +70 -30
- package/dist/date-picker/DatePicker.d.ts +3 -2
- package/dist/date-picker/DatePicker.d.ts.map +1 -1
- package/dist/date-picker/DatePicker.js +279 -72
- package/dist/date-picker/DatePicker.js.map +1 -1
- package/dist/date-picker/DatePicker.module.js +16 -12
- package/dist/date-picker/DatePicker.module.js.map +1 -1
- package/dist/date-picker/calendarTokens.d.ts +3 -0
- package/dist/date-picker/calendarTokens.d.ts.map +1 -0
- package/dist/date-picker/calendarTokens.js +17 -0
- package/dist/date-picker/calendarTokens.js.map +1 -0
- package/dist/dialog/Dialog.css +80 -37
- package/dist/dialog/Dialog.d.ts +15 -3
- package/dist/dialog/Dialog.d.ts.map +1 -1
- package/dist/dialog/Dialog.js +159 -30
- package/dist/dialog/Dialog.js.map +1 -1
- package/dist/dialog/Dialog.module.js +21 -13
- package/dist/dialog/Dialog.module.js.map +1 -1
- package/dist/dialog/tokens.d.ts +3 -0
- package/dist/dialog/tokens.d.ts.map +1 -0
- package/dist/dialog/tokens.js +31 -0
- package/dist/dialog/tokens.js.map +1 -0
- package/dist/disclosure/Disclosure.css +12 -12
- package/dist/disclosure/Disclosure.d.ts.map +1 -1
- package/dist/disclosure/Disclosure.js +132 -28
- package/dist/disclosure/Disclosure.js.map +1 -1
- package/dist/disclosure/Disclosure.module.js +7 -7
- package/dist/disclosure/Disclosure.module.js.map +1 -1
- package/dist/disclosure/tokens.d.ts +3 -0
- package/dist/disclosure/tokens.d.ts.map +1 -0
- package/dist/disclosure/tokens.js +15 -0
- package/dist/disclosure/tokens.js.map +1 -0
- package/dist/divider/Divider.css +17 -0
- package/dist/divider/Divider.d.ts +8 -0
- package/dist/divider/Divider.d.ts.map +1 -0
- package/dist/divider/Divider.js +65 -0
- package/dist/divider/Divider.js.map +1 -0
- package/dist/divider/Divider.module.js +12 -0
- package/dist/divider/Divider.module.js.map +1 -0
- package/dist/divider/tokens.d.ts +3 -0
- package/dist/divider/tokens.d.ts.map +1 -0
- package/dist/divider/tokens.js +13 -0
- package/dist/divider/tokens.js.map +1 -0
- package/dist/field/Field.css +49 -37
- package/dist/field/Field.module.js +11 -11
- package/dist/field/Field.module.js.map +1 -1
- package/dist/field/FieldParts.d.ts +1 -1
- package/dist/field/FieldParts.js +69 -15
- package/dist/field/FieldParts.js.map +1 -1
- package/dist/field/Fieldset.js +99 -32
- package/dist/field/Fieldset.js.map +1 -1
- package/dist/field/inputTokens.d.ts +3 -0
- package/dist/field/inputTokens.d.ts.map +1 -0
- package/dist/field/inputTokens.js +21 -0
- package/dist/field/inputTokens.js.map +1 -0
- package/dist/field/tokens.d.ts +3 -0
- package/dist/field/tokens.d.ts.map +1 -0
- package/dist/field/tokens.js +15 -0
- package/dist/field/tokens.js.map +1 -0
- package/dist/grid/Grid.css +174 -0
- package/dist/grid/Grid.d.ts +28 -0
- package/dist/grid/Grid.d.ts.map +1 -0
- package/dist/grid/Grid.js +140 -0
- package/dist/grid/Grid.js.map +1 -0
- package/dist/grid/Grid.module.js +12 -0
- package/dist/grid/Grid.module.js.map +1 -0
- package/dist/grid/GridItem.css +59 -0
- package/dist/grid/GridItem.module.js +7 -0
- package/dist/grid/GridItem.module.js.map +1 -0
- package/dist/grid/tokens.d.ts +3 -0
- package/dist/grid/tokens.d.ts.map +1 -0
- package/dist/grid/tokens.js +10 -0
- package/dist/grid/tokens.js.map +1 -0
- package/dist/heading/Heading.css +52 -0
- package/dist/heading/Heading.d.ts +17 -0
- package/dist/heading/Heading.d.ts.map +1 -0
- package/dist/heading/Heading.js +52 -0
- package/dist/heading/Heading.js.map +1 -0
- package/dist/heading/Heading.module.js +16 -0
- package/dist/heading/Heading.module.js.map +1 -0
- package/dist/heading/tokens.d.ts +6 -0
- package/dist/heading/tokens.d.ts.map +1 -0
- package/dist/heading/tokens.js +66 -0
- package/dist/heading/tokens.js.map +1 -0
- package/dist/icon/Icon.css +1 -1
- package/dist/icon/Icon.js +36 -11
- package/dist/icon/Icon.js.map +1 -1
- package/dist/icon/Icon.module.js +1 -1
- package/dist/icon/lucideIconLoader.d.ts +9 -0
- package/dist/icon/lucideIconLoader.d.ts.map +1 -0
- package/dist/icon/lucideIconLoader.js +22 -0
- package/dist/icon/lucideIconLoader.js.map +1 -0
- package/dist/icon/namedIcons.d.ts +16 -9
- package/dist/icon/namedIcons.d.ts.map +1 -1
- package/dist/icon/namedIcons.js +121 -46
- package/dist/icon/namedIcons.js.map +1 -1
- package/dist/icon-button/IconButton.css +2 -2
- package/dist/icon-button/IconButton.d.ts +3 -3
- package/dist/icon-button/IconButton.d.ts.map +1 -1
- package/dist/icon-button/IconButton.js +70 -13
- package/dist/icon-button/IconButton.js.map +1 -1
- package/dist/icon-button/IconButton.module.js +2 -2
- package/dist/index.d.ts +61 -32
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +32 -5
- package/dist/inline/Inline.css +142 -0
- package/dist/inline/Inline.d.ts +17 -0
- package/dist/inline/Inline.d.ts.map +1 -0
- package/dist/inline/Inline.js +79 -0
- package/dist/inline/Inline.js.map +1 -0
- package/dist/inline/Inline.module.js +12 -0
- package/dist/inline/Inline.module.js.map +1 -0
- package/dist/inline/tokens.d.ts +3 -0
- package/dist/inline/tokens.d.ts.map +1 -0
- package/dist/inline/tokens.js +10 -0
- package/dist/inline/tokens.js.map +1 -0
- package/dist/intl/usePanneauIntl.js.map +1 -1
- package/dist/layout/responsive.d.ts +38 -0
- package/dist/layout/responsive.d.ts.map +1 -0
- package/dist/layout/responsive.js +49 -0
- package/dist/layout/responsive.js.map +1 -0
- package/dist/locales/index.js.map +1 -1
- package/dist/menu/Menu.css +84 -0
- package/dist/menu/Menu.d.ts +34 -7
- package/dist/menu/Menu.d.ts.map +1 -1
- package/dist/menu/Menu.js +243 -32
- package/dist/menu/Menu.js.map +1 -1
- package/dist/menu/Menu.module.js +22 -0
- package/dist/menu/Menu.module.js.map +1 -0
- package/dist/menu/tokens.d.ts +3 -0
- package/dist/menu/tokens.d.ts.map +1 -0
- package/dist/menu/tokens.js +31 -0
- package/dist/menu/tokens.js.map +1 -0
- package/dist/named-icons/index.d.ts +2 -0
- package/dist/named-icons/index.d.ts.map +1 -0
- package/dist/named-icons/index.js +1 -0
- package/dist/number-input/NumberInput.css +30 -12
- package/dist/number-input/NumberInput.d.ts +1 -1
- package/dist/number-input/NumberInput.js +232 -60
- package/dist/number-input/NumberInput.js.map +1 -1
- package/dist/number-input/NumberInput.module.js +7 -5
- package/dist/number-input/NumberInput.module.js.map +1 -1
- package/dist/number-input/tokens.d.ts +3 -0
- package/dist/number-input/tokens.d.ts.map +1 -0
- package/dist/number-input/tokens.js +10 -0
- package/dist/number-input/tokens.js.map +1 -0
- package/dist/pill-trigger/PillTrigger.css +104 -0
- package/dist/pill-trigger/PillTrigger.d.ts +20 -0
- package/dist/pill-trigger/PillTrigger.d.ts.map +1 -0
- package/dist/pill-trigger/PillTrigger.js +94 -0
- package/dist/pill-trigger/PillTrigger.js.map +1 -0
- package/dist/pill-trigger/PillTrigger.module.js +18 -0
- package/dist/pill-trigger/PillTrigger.module.js.map +1 -0
- package/dist/pill-trigger/tokens.d.ts +3 -0
- package/dist/pill-trigger/tokens.d.ts.map +1 -0
- package/dist/pill-trigger/tokens.js +37 -0
- package/dist/pill-trigger/tokens.js.map +1 -0
- package/dist/popover/Popover.css +18 -12
- package/dist/popover/Popover.d.ts.map +1 -1
- package/dist/popover/Popover.js +116 -20
- package/dist/popover/Popover.js.map +1 -1
- package/dist/popover/Popover.module.js +7 -5
- package/dist/popover/Popover.module.js.map +1 -1
- package/dist/popover/tokens.d.ts +3 -0
- package/dist/popover/tokens.d.ts.map +1 -0
- package/dist/popover/tokens.js +19 -0
- package/dist/popover/tokens.js.map +1 -0
- package/dist/prose/Prose.css +141 -0
- package/dist/prose/Prose.d.ts +11 -0
- package/dist/prose/Prose.d.ts.map +1 -0
- package/dist/prose/Prose.js +49 -0
- package/dist/prose/Prose.js.map +1 -0
- package/dist/prose/Prose.module.js +8 -0
- package/dist/prose/Prose.module.js.map +1 -0
- package/dist/prose/tokens.d.ts +3 -0
- package/dist/prose/tokens.d.ts.map +1 -0
- package/dist/prose/tokens.js +33 -0
- package/dist/prose/tokens.js.map +1 -0
- package/dist/radio-group/RadioGroup.css +111 -20
- package/dist/radio-group/RadioGroup.d.ts +24 -5
- package/dist/radio-group/RadioGroup.d.ts.map +1 -1
- package/dist/radio-group/RadioGroup.js +214 -43
- package/dist/radio-group/RadioGroup.js.map +1 -1
- package/dist/radio-group/RadioGroup.module.js +18 -8
- package/dist/radio-group/RadioGroup.module.js.map +1 -1
- package/dist/radio-group/tokens.d.ts +3 -0
- package/dist/radio-group/tokens.d.ts.map +1 -0
- package/dist/radio-group/tokens.js +39 -0
- package/dist/radio-group/tokens.js.map +1 -0
- package/dist/root/PanneauRoot.css +243 -20
- package/dist/root/PanneauRoot.d.ts +57 -4
- package/dist/root/PanneauRoot.d.ts.map +1 -1
- package/dist/root/PanneauRoot.js +325 -46
- package/dist/root/PanneauRoot.js.map +1 -1
- package/dist/root/PanneauRoot.module.js +11 -3
- package/dist/root/PanneauRoot.module.js.map +1 -1
- package/dist/root/ThemeScope.d.ts +24 -0
- package/dist/root/ThemeScope.d.ts.map +1 -0
- package/dist/root/ThemeScope.js +132 -0
- package/dist/root/ThemeScope.js.map +1 -0
- package/dist/segmented-control/SegmentedControl.css +83 -0
- package/dist/segmented-control/SegmentedControl.d.ts +35 -0
- package/dist/segmented-control/SegmentedControl.d.ts.map +1 -0
- package/dist/segmented-control/SegmentedControl.js +142 -0
- package/dist/segmented-control/SegmentedControl.js.map +1 -0
- package/dist/segmented-control/SegmentedControl.module.js +16 -0
- package/dist/segmented-control/SegmentedControl.module.js.map +1 -0
- package/dist/segmented-control/tokens.d.ts +3 -0
- package/dist/segmented-control/tokens.d.ts.map +1 -0
- package/dist/segmented-control/tokens.js +29 -0
- package/dist/segmented-control/tokens.js.map +1 -0
- package/dist/select/ListBox.css +46 -23
- package/dist/select/ListBox.module.js +13 -13
- package/dist/select/ListBox.module.js.map +1 -1
- package/dist/select/Select.d.ts +1 -1
- package/dist/select/Select.js +298 -92
- package/dist/select/Select.js.map +1 -1
- package/dist/select/listBoxTokens.d.ts +3 -0
- package/dist/select/listBoxTokens.d.ts.map +1 -0
- package/dist/select/listBoxTokens.js +21 -0
- package/dist/select/listBoxTokens.js.map +1 -0
- package/dist/skeleton/LoadingRegion.d.ts +16 -0
- package/dist/skeleton/LoadingRegion.d.ts.map +1 -0
- package/dist/skeleton/LoadingRegion.js +65 -0
- package/dist/skeleton/LoadingRegion.js.map +1 -0
- package/dist/skeleton/Skeleton.css +62 -0
- package/dist/skeleton/Skeleton.d.ts +25 -0
- package/dist/skeleton/Skeleton.d.ts.map +1 -0
- package/dist/skeleton/Skeleton.js +106 -0
- package/dist/skeleton/Skeleton.js.map +1 -0
- package/dist/skeleton/Skeleton.module.js +22 -0
- package/dist/skeleton/Skeleton.module.js.map +1 -0
- package/dist/skeleton/tokens.d.ts +3 -0
- package/dist/skeleton/tokens.d.ts.map +1 -0
- package/dist/skeleton/tokens.js +15 -0
- package/dist/skeleton/tokens.js.map +1 -0
- package/dist/slider/Slider.css +84 -0
- package/dist/slider/Slider.d.ts +20 -0
- package/dist/slider/Slider.d.ts.map +1 -0
- package/dist/slider/Slider.js +248 -0
- package/dist/slider/Slider.js.map +1 -0
- package/dist/slider/Slider.module.js +20 -0
- package/dist/slider/Slider.module.js.map +1 -0
- package/dist/spinner/Spinner.css +8 -8
- package/dist/spinner/Spinner.js +49 -9
- package/dist/spinner/Spinner.js.map +1 -1
- package/dist/spinner/Spinner.module.js +5 -5
- package/dist/spinner/Spinner.module.js.map +1 -1
- package/dist/spinner/tokens.d.ts +3 -0
- package/dist/spinner/tokens.d.ts.map +1 -0
- package/dist/spinner/tokens.js +10 -0
- package/dist/spinner/tokens.js.map +1 -0
- package/dist/stack/Stack.css +135 -0
- package/dist/stack/Stack.d.ts +15 -0
- package/dist/stack/Stack.d.ts.map +1 -0
- package/dist/stack/Stack.js +74 -0
- package/dist/stack/Stack.js.map +1 -0
- package/dist/stack/Stack.module.js +8 -0
- package/dist/stack/Stack.module.js.map +1 -0
- package/dist/stack/tokens.d.ts +3 -0
- package/dist/stack/tokens.d.ts.map +1 -0
- package/dist/stack/tokens.js +10 -0
- package/dist/stack/tokens.js.map +1 -0
- package/dist/switch/Switch.css +34 -25
- package/dist/switch/Switch.d.ts +1 -1
- package/dist/switch/Switch.d.ts.map +1 -1
- package/dist/switch/Switch.js +69 -11
- package/dist/switch/Switch.js.map +1 -1
- package/dist/switch/Switch.module.js +6 -5
- package/dist/switch/Switch.module.js.map +1 -1
- package/dist/switch/tokens.d.ts +3 -0
- package/dist/switch/tokens.d.ts.map +1 -0
- package/dist/switch/tokens.js +25 -0
- package/dist/switch/tokens.js.map +1 -0
- package/dist/tabs/Tabs.css +24 -23
- package/dist/tabs/Tabs.js +5 -5
- package/dist/tabs/Tabs.js.map +1 -1
- package/dist/tabs/Tabs.module.js +4 -4
- package/dist/tabs/Tabs.module.js.map +1 -1
- package/dist/tabs/tokens.d.ts +3 -0
- package/dist/tabs/tokens.d.ts.map +1 -0
- package/dist/tabs/tokens.js +25 -0
- package/dist/tabs/tokens.js.map +1 -0
- package/dist/tags-input/TagsInput.css +60 -0
- package/dist/tags-input/TagsInput.d.ts +32 -0
- package/dist/tags-input/TagsInput.d.ts.map +1 -0
- package/dist/tags-input/TagsInput.js +316 -0
- package/dist/tags-input/TagsInput.js.map +1 -0
- package/dist/tags-input/TagsInput.module.js +20 -0
- package/dist/tags-input/TagsInput.module.js.map +1 -0
- package/dist/text/Text.css +74 -0
- package/dist/text/Text.d.ts +27 -0
- package/dist/text/Text.d.ts.map +1 -0
- package/dist/text/Text.js +81 -0
- package/dist/text/Text.js.map +1 -0
- package/dist/text/Text.module.js +30 -0
- package/dist/text/Text.module.js.map +1 -0
- package/dist/text/tokens.d.ts +3 -0
- package/dist/text/tokens.d.ts.map +1 -0
- package/dist/text/tokens.js +10 -0
- package/dist/text/tokens.js.map +1 -0
- package/dist/text-area/TextArea.css +1 -1
- package/dist/text-area/TextArea.d.ts +1 -1
- package/dist/text-area/TextArea.js +135 -28
- package/dist/text-area/TextArea.js.map +1 -1
- package/dist/text-area/TextArea.module.js +3 -3
- package/dist/text-area/TextArea.module.js.map +1 -1
- package/dist/text-input/TextInput.d.ts +1 -1
- package/dist/text-input/TextInput.d.ts.map +1 -1
- package/dist/text-input/TextInput.js +164 -47
- package/dist/text-input/TextInput.js.map +1 -1
- package/dist/theme/Tone.css +70 -0
- package/dist/theme/Tone.module.js +20 -0
- package/dist/theme/Tone.module.js.map +1 -0
- package/dist/theme/bootstrap.d.ts +11 -1
- package/dist/theme/bootstrap.d.ts.map +1 -1
- package/dist/theme/bootstrap.js +48 -5
- package/dist/theme/bootstrap.js.map +1 -1
- package/dist/theme/chartColors.d.ts +23 -0
- package/dist/theme/chartColors.d.ts.map +1 -0
- package/dist/theme/chartColors.js +27 -0
- package/dist/theme/chartColors.js.map +1 -0
- package/dist/theme/checkTheme.d.ts +39 -0
- package/dist/theme/checkTheme.d.ts.map +1 -0
- package/dist/theme/checkTheme.js +132 -0
- package/dist/theme/checkTheme.js.map +1 -0
- package/dist/theme/cli.d.ts +14 -0
- package/dist/theme/cli.d.ts.map +1 -0
- package/dist/theme/cli.js +61 -0
- package/dist/theme/cli.js.map +1 -0
- package/dist/theme/color.d.ts +30 -0
- package/dist/theme/color.d.ts.map +1 -0
- package/dist/theme/color.js +94 -0
- package/dist/theme/color.js.map +1 -0
- package/dist/theme/colorVision.d.ts +23 -0
- package/dist/theme/colorVision.d.ts.map +1 -0
- package/dist/theme/colorVision.js +140 -0
- package/dist/theme/colorVision.js.map +1 -0
- package/dist/theme/componentTokens.d.ts +24 -0
- package/dist/theme/componentTokens.d.ts.map +1 -0
- package/dist/theme/componentTokens.js +20 -0
- package/dist/theme/componentTokens.js.map +1 -0
- package/dist/theme/components.d.ts +43 -0
- package/dist/theme/components.d.ts.map +1 -0
- package/dist/theme/components.js +75 -0
- package/dist/theme/components.js.map +1 -0
- package/dist/theme/defineTheme.d.ts +85 -0
- package/dist/theme/defineTheme.d.ts.map +1 -0
- package/dist/theme/defineTheme.js +130 -0
- package/dist/theme/defineTheme.js.map +1 -0
- package/dist/theme/fonts.d.ts +32 -0
- package/dist/theme/fonts.d.ts.map +1 -0
- package/dist/theme/fonts.js +36 -0
- package/dist/theme/fonts.js.map +1 -0
- package/dist/theme/index.d.ts +13 -0
- package/dist/theme/index.d.ts.map +1 -0
- package/dist/theme/index.js +10 -0
- package/dist/theme/semanticTokens.d.ts +9 -0
- package/dist/theme/semanticTokens.d.ts.map +1 -0
- package/dist/theme/semanticTokens.js +110 -0
- package/dist/theme/semanticTokens.js.map +1 -0
- package/dist/theme/theme.d.ts +61 -7
- package/dist/theme/theme.d.ts.map +1 -1
- package/dist/theme/theme.js +100 -10
- package/dist/theme/theme.js.map +1 -1
- package/dist/theme/toneClass.d.ts +8 -0
- package/dist/theme/toneClass.d.ts.map +1 -0
- package/dist/theme/toneClass.js +15 -0
- package/dist/theme/toneClass.js.map +1 -0
- package/dist/theme/tones.d.ts +89 -0
- package/dist/theme/tones.d.ts.map +1 -0
- package/dist/theme/tones.js +127 -0
- package/dist/theme/tones.js.map +1 -0
- package/dist/time-input/TimeInput.d.ts +1 -1
- package/dist/time-input/TimeInput.js +138 -31
- package/dist/time-input/TimeInput.js.map +1 -1
- package/dist/toast/Toast.css +22 -44
- package/dist/toast/Toast.d.ts +5 -3
- package/dist/toast/Toast.d.ts.map +1 -1
- package/dist/toast/Toast.js +5 -4
- package/dist/toast/Toast.js.map +1 -1
- package/dist/toast/Toast.module.js +10 -16
- package/dist/toast/Toast.module.js.map +1 -1
- package/dist/toast/tokens.d.ts +3 -0
- package/dist/toast/tokens.d.ts.map +1 -0
- package/dist/toast/tokens.js +21 -0
- package/dist/toast/tokens.js.map +1 -0
- package/dist/tooltip/Tooltip.css +12 -11
- package/dist/tooltip/Tooltip.js +38 -8
- package/dist/tooltip/Tooltip.js.map +1 -1
- package/dist/tooltip/Tooltip.module.js +2 -2
- package/dist/tooltip/Tooltip.module.js.map +1 -1
- package/dist/tooltip/tokens.d.ts +3 -0
- package/dist/tooltip/tokens.d.ts.map +1 -0
- package/dist/tooltip/tokens.js +21 -0
- package/dist/tooltip/tokens.js.map +1 -0
- package/dist/utils/cx.d.ts +1 -1
- package/dist/utils/cx.d.ts.map +1 -1
- package/dist/utils/cx.js +2 -2
- package/dist/utils/cx.js.map +1 -1
- package/dist/utils/events.d.ts +4 -0
- package/dist/utils/events.d.ts.map +1 -0
- package/dist/utils/events.js +9 -0
- package/dist/utils/events.js.map +1 -0
- package/package.json +22 -5
package/dist/field/Field.css
CHANGED
|
@@ -1,31 +1,31 @@
|
|
|
1
1
|
/* Shared look of labelled controls: label, description, errors and the control itself. */
|
|
2
2
|
|
|
3
|
-
.panneau-field
|
|
3
|
+
.panneau-field {
|
|
4
4
|
display: flex;
|
|
5
5
|
flex-direction: column;
|
|
6
|
-
gap: var(--panneau-space-1);
|
|
6
|
+
gap: var(--panneau-field-gap, var(--panneau-space-1));
|
|
7
7
|
min-width: 0;
|
|
8
8
|
}
|
|
9
9
|
|
|
10
|
-
.panneau-label
|
|
11
|
-
font-size: var(--panneau-font-size-md);
|
|
12
|
-
font-weight: var(--panneau-font-weight-medium);
|
|
10
|
+
.panneau-field-label {
|
|
11
|
+
font-size: var(--panneau-field-label-font-size, var(--panneau-font-size-md));
|
|
12
|
+
font-weight: var(--panneau-field-label-font-weight, var(--panneau-font-weight-medium));
|
|
13
13
|
line-height: var(--panneau-line-height-tight);
|
|
14
14
|
color: var(--panneau-color-text);
|
|
15
15
|
overflow-wrap: anywhere;
|
|
16
16
|
}
|
|
17
17
|
|
|
18
|
-
.panneau-required
|
|
18
|
+
.panneau-field-required {
|
|
19
19
|
margin-inline-start: 0.2em;
|
|
20
20
|
color: var(--panneau-color-danger);
|
|
21
21
|
}
|
|
22
22
|
|
|
23
|
-
.panneau-description
|
|
23
|
+
.panneau-field-description {
|
|
24
24
|
font-size: var(--panneau-font-size-sm);
|
|
25
25
|
color: var(--panneau-color-text-muted);
|
|
26
26
|
}
|
|
27
27
|
|
|
28
|
-
.panneau-errors
|
|
28
|
+
.panneau-field-errors {
|
|
29
29
|
display: flex;
|
|
30
30
|
flex-direction: column;
|
|
31
31
|
gap: var(--panneau-space-1);
|
|
@@ -33,70 +33,71 @@
|
|
|
33
33
|
color: var(--panneau-color-danger);
|
|
34
34
|
}
|
|
35
35
|
|
|
36
|
-
.panneau-error
|
|
36
|
+
.panneau-field-error {
|
|
37
37
|
display: block;
|
|
38
38
|
}
|
|
39
39
|
|
|
40
|
-
.panneau-control
|
|
40
|
+
.panneau-field-control {
|
|
41
41
|
display: flex;
|
|
42
42
|
align-items: center;
|
|
43
43
|
width: 100%;
|
|
44
44
|
min-width: 0;
|
|
45
45
|
min-height: var(--panneau-control-height);
|
|
46
|
-
padding: 0 var(--panneau-
|
|
46
|
+
padding: 0 var(--panneau-input-padding-x, var(--panneau-control-padding-x));
|
|
47
47
|
font-size: var(--panneau-font-size-control);
|
|
48
48
|
line-height: var(--panneau-line-height-tight);
|
|
49
49
|
color: var(--panneau-color-text);
|
|
50
|
-
background-color: var(--panneau-color-surface);
|
|
51
|
-
border: var(--panneau-border-width
|
|
52
|
-
|
|
50
|
+
background-color: var(--panneau-input-bg, var(--panneau-color-surface));
|
|
51
|
+
border: var(--panneau-input-border-width, var(--panneau-border-width)) solid
|
|
52
|
+
var(--panneau-input-border-color, var(--panneau-color-border-control));
|
|
53
|
+
border-radius: var(--panneau-input-radius, var(--panneau-radius-md));
|
|
53
54
|
transition:
|
|
54
55
|
border-color var(--panneau-duration),
|
|
55
56
|
box-shadow var(--panneau-duration);
|
|
56
57
|
}
|
|
57
58
|
|
|
58
|
-
.panneau-control
|
|
59
|
+
.panneau-field-control::placeholder {
|
|
59
60
|
color: var(--panneau-color-text-muted);
|
|
60
61
|
opacity: 1;
|
|
61
62
|
}
|
|
62
63
|
|
|
63
|
-
.panneau-control
|
|
64
|
-
.panneau-control
|
|
65
|
-
border-color: var(--panneau-color-text-muted);
|
|
64
|
+
.panneau-field-control[data-hovered],
|
|
65
|
+
.panneau-field-control:hover {
|
|
66
|
+
border-color: var(--panneau-input-border-color-hover, var(--panneau-color-text-muted));
|
|
66
67
|
}
|
|
67
68
|
|
|
68
|
-
.panneau-control
|
|
69
|
-
.panneau-control
|
|
70
|
-
.panneau-control
|
|
71
|
-
.panneau-control
|
|
69
|
+
.panneau-field-control[data-focused],
|
|
70
|
+
.panneau-field-control[data-focus-within],
|
|
71
|
+
.panneau-field-control[data-focus-visible],
|
|
72
|
+
.panneau-field-control:focus-within {
|
|
72
73
|
border-color: var(--panneau-color-focus);
|
|
73
74
|
outline: none;
|
|
74
75
|
box-shadow: 0 0 0 1px var(--panneau-color-focus);
|
|
75
76
|
}
|
|
76
77
|
|
|
77
|
-
.panneau-control
|
|
78
|
+
.panneau-field-control[data-invalid] {
|
|
78
79
|
border-color: var(--panneau-color-danger);
|
|
79
80
|
}
|
|
80
81
|
|
|
81
|
-
.panneau-control
|
|
82
|
-
.panneau-control
|
|
83
|
-
.panneau-control
|
|
82
|
+
.panneau-field-control[data-invalid][data-focused],
|
|
83
|
+
.panneau-field-control[data-invalid][data-focus-within],
|
|
84
|
+
.panneau-field-control[data-invalid]:focus-within {
|
|
84
85
|
box-shadow: 0 0 0 1px var(--panneau-color-danger);
|
|
85
86
|
}
|
|
86
87
|
|
|
87
|
-
.panneau-control
|
|
88
|
+
.panneau-field-control[data-disabled] {
|
|
88
89
|
cursor: not-allowed;
|
|
89
90
|
opacity: 0.6;
|
|
90
91
|
background-color: var(--panneau-color-surface-sunken);
|
|
91
92
|
}
|
|
92
93
|
|
|
93
|
-
.panneau-control
|
|
94
|
-
.panneau-control
|
|
94
|
+
.panneau-field-control[data-readonly],
|
|
95
|
+
.panneau-field-control[readonly] {
|
|
95
96
|
background-color: var(--panneau-color-surface-sunken);
|
|
96
97
|
}
|
|
97
98
|
|
|
98
99
|
/* An input inside a control (with adornments, segments or buttons): the control draws the box. */
|
|
99
|
-
.panneau-bare
|
|
100
|
+
.panneau-field-bare {
|
|
100
101
|
flex: 1 1 auto;
|
|
101
102
|
min-width: 0;
|
|
102
103
|
height: 100%;
|
|
@@ -109,12 +110,12 @@
|
|
|
109
110
|
outline: none;
|
|
110
111
|
}
|
|
111
112
|
|
|
112
|
-
.panneau-bare
|
|
113
|
+
.panneau-field-bare::placeholder {
|
|
113
114
|
color: var(--panneau-color-text-muted);
|
|
114
115
|
opacity: 1;
|
|
115
116
|
}
|
|
116
117
|
|
|
117
|
-
.panneau-adornment
|
|
118
|
+
.panneau-field-adornment {
|
|
118
119
|
display: inline-flex;
|
|
119
120
|
flex: 0 0 auto;
|
|
120
121
|
align-items: center;
|
|
@@ -123,23 +124,34 @@
|
|
|
123
124
|
white-space: nowrap;
|
|
124
125
|
}
|
|
125
126
|
|
|
126
|
-
.panneau-adornment
|
|
127
|
+
.panneau-field-adornment:first-child {
|
|
127
128
|
margin-inline-end: var(--panneau-space-2);
|
|
128
129
|
}
|
|
129
130
|
|
|
130
|
-
.panneau-adornment
|
|
131
|
+
.panneau-field-adornment:last-child {
|
|
131
132
|
margin-inline-start: var(--panneau-space-2);
|
|
132
133
|
}
|
|
133
134
|
|
|
134
|
-
|
|
135
|
+
/* A text before or after the value reads with it, as one URL or one amount: `/pages/home`. */
|
|
136
|
+
.panneau-field-adornment[data-text]:first-child {
|
|
137
|
+
margin-inline-end: 0;
|
|
138
|
+
}
|
|
139
|
+
|
|
140
|
+
.panneau-field-adornment[data-text]:last-child {
|
|
141
|
+
margin-inline-start: 0;
|
|
142
|
+
}
|
|
143
|
+
|
|
144
|
+
.panneau-field-fieldset {
|
|
135
145
|
display: flex;
|
|
136
146
|
flex-direction: column;
|
|
137
147
|
gap: var(--panneau-space-2);
|
|
138
148
|
min-width: 0;
|
|
139
149
|
}
|
|
140
150
|
|
|
141
|
-
.panneau-legend
|
|
151
|
+
.panneau-field-legend {
|
|
142
152
|
display: block;
|
|
153
|
+
float: none;
|
|
143
154
|
width: 100%;
|
|
144
|
-
margin
|
|
155
|
+
margin: 0 0 var(--panneau-space-1);
|
|
156
|
+
padding: 0;
|
|
145
157
|
}
|
|
@@ -1,16 +1,16 @@
|
|
|
1
1
|
import "./Field.css";
|
|
2
2
|
//#region src/field/Field.module.css
|
|
3
|
-
var field = "panneau-field
|
|
4
|
-
var label = "panneau-label
|
|
5
|
-
var required = "panneau-required
|
|
6
|
-
var description = "panneau-description
|
|
7
|
-
var errors = "panneau-errors
|
|
8
|
-
var error = "panneau-error
|
|
9
|
-
var control = "panneau-control
|
|
10
|
-
var bare = "panneau-bare
|
|
11
|
-
var adornment = "panneau-adornment
|
|
12
|
-
var fieldset = "panneau-fieldset
|
|
13
|
-
var legend = "panneau-legend
|
|
3
|
+
var field = "panneau-field";
|
|
4
|
+
var label = "panneau-field-label";
|
|
5
|
+
var required = "panneau-field-required";
|
|
6
|
+
var description = "panneau-field-description";
|
|
7
|
+
var errors = "panneau-field-errors";
|
|
8
|
+
var error = "panneau-field-error";
|
|
9
|
+
var control = "panneau-field-control";
|
|
10
|
+
var bare = "panneau-field-bare";
|
|
11
|
+
var adornment = "panneau-field-adornment";
|
|
12
|
+
var fieldset = "panneau-field-fieldset";
|
|
13
|
+
var legend = "panneau-field-legend";
|
|
14
14
|
var Field_module_default = {
|
|
15
15
|
field,
|
|
16
16
|
label,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Field.module.js","names":[],"sources":["../../src/field/Field.module.css"],"sourcesContent":["/* Shared look of labelled controls: label, description, errors and the control itself. */\n\n.field {\n display: flex;\n flex-direction: column;\n gap: var(--panneau-space-1);\n min-width: 0;\n}\n\n.label {\n font-size: var(--panneau-font-size-md);\n font-weight: var(--panneau-font-weight-medium);\n line-height: var(--panneau-line-height-tight);\n color: var(--panneau-color-text);\n overflow-wrap: anywhere;\n}\n\n.required {\n margin-inline-start: 0.2em;\n color: var(--panneau-color-danger);\n}\n\n.description {\n font-size: var(--panneau-font-size-sm);\n color: var(--panneau-color-text-muted);\n}\n\n.errors {\n display: flex;\n flex-direction: column;\n gap: var(--panneau-space-1);\n font-size: var(--panneau-font-size-sm);\n color: var(--panneau-color-danger);\n}\n\n.error {\n display: block;\n}\n\n.control {\n display: flex;\n align-items: center;\n width: 100%;\n min-width: 0;\n min-height: var(--panneau-control-height);\n padding: 0 var(--panneau-
|
|
1
|
+
{"version":3,"file":"Field.module.js","names":[],"sources":["../../src/field/Field.module.css"],"sourcesContent":["/* Shared look of labelled controls: label, description, errors and the control itself. */\n\n.field {\n display: flex;\n flex-direction: column;\n gap: var(--panneau-field-gap, var(--panneau-space-1));\n min-width: 0;\n}\n\n.label {\n font-size: var(--panneau-field-label-font-size, var(--panneau-font-size-md));\n font-weight: var(--panneau-field-label-font-weight, var(--panneau-font-weight-medium));\n line-height: var(--panneau-line-height-tight);\n color: var(--panneau-color-text);\n overflow-wrap: anywhere;\n}\n\n.required {\n margin-inline-start: 0.2em;\n color: var(--panneau-color-danger);\n}\n\n.description {\n font-size: var(--panneau-font-size-sm);\n color: var(--panneau-color-text-muted);\n}\n\n.errors {\n display: flex;\n flex-direction: column;\n gap: var(--panneau-space-1);\n font-size: var(--panneau-font-size-sm);\n color: var(--panneau-color-danger);\n}\n\n.error {\n display: block;\n}\n\n.control {\n display: flex;\n align-items: center;\n width: 100%;\n min-width: 0;\n min-height: var(--panneau-control-height);\n padding: 0 var(--panneau-input-padding-x, var(--panneau-control-padding-x));\n font-size: var(--panneau-font-size-control);\n line-height: var(--panneau-line-height-tight);\n color: var(--panneau-color-text);\n background-color: var(--panneau-input-bg, var(--panneau-color-surface));\n border: var(--panneau-input-border-width, var(--panneau-border-width)) solid\n var(--panneau-input-border-color, var(--panneau-color-border-control));\n border-radius: var(--panneau-input-radius, var(--panneau-radius-md));\n transition:\n border-color var(--panneau-duration),\n box-shadow var(--panneau-duration);\n}\n\n.control::placeholder {\n color: var(--panneau-color-text-muted);\n opacity: 1;\n}\n\n.control[data-hovered],\n.control:hover {\n border-color: var(--panneau-input-border-color-hover, var(--panneau-color-text-muted));\n}\n\n.control[data-focused],\n.control[data-focus-within],\n.control[data-focus-visible],\n.control:focus-within {\n border-color: var(--panneau-color-focus);\n outline: none;\n box-shadow: 0 0 0 1px var(--panneau-color-focus);\n}\n\n.control[data-invalid] {\n border-color: var(--panneau-color-danger);\n}\n\n.control[data-invalid][data-focused],\n.control[data-invalid][data-focus-within],\n.control[data-invalid]:focus-within {\n box-shadow: 0 0 0 1px var(--panneau-color-danger);\n}\n\n.control[data-disabled] {\n cursor: not-allowed;\n opacity: 0.6;\n background-color: var(--panneau-color-surface-sunken);\n}\n\n.control[data-readonly],\n.control[readonly] {\n background-color: var(--panneau-color-surface-sunken);\n}\n\n/* An input inside a control (with adornments, segments or buttons): the control draws the box. */\n.bare {\n flex: 1 1 auto;\n min-width: 0;\n height: 100%;\n min-height: calc(var(--panneau-control-height) - 2 * var(--panneau-border-width));\n padding: 0;\n font: inherit;\n color: inherit;\n background: transparent;\n border: 0;\n outline: none;\n}\n\n.bare::placeholder {\n color: var(--panneau-color-text-muted);\n opacity: 1;\n}\n\n.adornment {\n display: inline-flex;\n flex: 0 0 auto;\n align-items: center;\n gap: var(--panneau-space-1);\n color: var(--panneau-color-text-muted);\n white-space: nowrap;\n}\n\n.adornment:first-child {\n margin-inline-end: var(--panneau-space-2);\n}\n\n.adornment:last-child {\n margin-inline-start: var(--panneau-space-2);\n}\n\n/* A text before or after the value reads with it, as one URL or one amount: `/pages/home`. */\n.adornment[data-text]:first-child {\n margin-inline-end: 0;\n}\n\n.adornment[data-text]:last-child {\n margin-inline-start: 0;\n}\n\n.fieldset {\n display: flex;\n flex-direction: column;\n gap: var(--panneau-space-2);\n min-width: 0;\n}\n\n.legend {\n display: block;\n float: none;\n width: 100%;\n margin: 0 0 var(--panneau-space-1);\n padding: 0;\n}\n"],"mappings":""}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { type ReactNode } from 'react';
|
|
2
|
-
|
|
2
|
+
declare const styles: Readonly<Record<string, string>>;
|
|
3
3
|
/** Props that every labelled control of `@panneau/ui` accepts. */
|
|
4
4
|
export interface FieldChromeProps {
|
|
5
5
|
/** Visible label. Without one, pass `aria-label`. */
|
package/dist/field/FieldParts.js
CHANGED
|
@@ -1,20 +1,43 @@
|
|
|
1
1
|
import { cx } from "../utils/cx.js";
|
|
2
2
|
import Field_module_default from "./Field.module.js";
|
|
3
|
+
import { c } from "react/compiler-runtime";
|
|
3
4
|
import { FieldError, Label, Text } from "react-aria-components";
|
|
4
5
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
5
6
|
import { Fragment as Fragment$1 } from "react";
|
|
6
|
-
import { c } from "react/compiler-runtime";
|
|
7
7
|
//#region src/field/FieldParts.tsx
|
|
8
|
-
function FieldLabel(
|
|
8
|
+
function FieldLabel(t0) {
|
|
9
|
+
const $ = c(8);
|
|
10
|
+
const { children, isRequired: t1, className } = t0;
|
|
11
|
+
const isRequired = t1 === void 0 ? false : t1;
|
|
9
12
|
if (children === void 0 || children === null) return null;
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
+
let t2;
|
|
14
|
+
if ($[0] !== className) {
|
|
15
|
+
t2 = cx(Field_module_default.label, className);
|
|
16
|
+
$[0] = className;
|
|
17
|
+
$[1] = t2;
|
|
18
|
+
} else t2 = $[1];
|
|
19
|
+
let t3;
|
|
20
|
+
if ($[2] !== isRequired) {
|
|
21
|
+
t3 = isRequired ? /* @__PURE__ */ jsx("span", {
|
|
13
22
|
className: Field_module_default.required,
|
|
14
23
|
"aria-hidden": "true",
|
|
15
24
|
children: "*"
|
|
16
|
-
}) : null
|
|
17
|
-
|
|
25
|
+
}) : null;
|
|
26
|
+
$[2] = isRequired;
|
|
27
|
+
$[3] = t3;
|
|
28
|
+
} else t3 = $[3];
|
|
29
|
+
let t4;
|
|
30
|
+
if ($[4] !== children || $[5] !== t2 || $[6] !== t3) {
|
|
31
|
+
t4 = /* @__PURE__ */ jsxs(Label, {
|
|
32
|
+
className: t2,
|
|
33
|
+
children: [children, t3]
|
|
34
|
+
});
|
|
35
|
+
$[4] = children;
|
|
36
|
+
$[5] = t2;
|
|
37
|
+
$[6] = t3;
|
|
38
|
+
$[7] = t4;
|
|
39
|
+
} else t4 = $[7];
|
|
40
|
+
return t4;
|
|
18
41
|
}
|
|
19
42
|
function FieldDescription(t0) {
|
|
20
43
|
const $ = c(5);
|
|
@@ -40,15 +63,46 @@ function FieldDescription(t0) {
|
|
|
40
63
|
return t2;
|
|
41
64
|
}
|
|
42
65
|
/** Error messages of a React Aria field. They show when the field is invalid. */
|
|
43
|
-
function FieldErrors(
|
|
66
|
+
function FieldErrors(t0) {
|
|
67
|
+
const $ = c(9);
|
|
68
|
+
const { errors: t1, className } = t0;
|
|
69
|
+
let t2;
|
|
70
|
+
if ($[0] !== t1) {
|
|
71
|
+
t2 = t1 === void 0 ? [] : t1;
|
|
72
|
+
$[0] = t1;
|
|
73
|
+
$[1] = t2;
|
|
74
|
+
} else t2 = $[1];
|
|
75
|
+
const errors = t2;
|
|
44
76
|
if (errors.length === 0) return null;
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
77
|
+
let t3;
|
|
78
|
+
if ($[2] !== className) {
|
|
79
|
+
t3 = cx(Field_module_default.errors, className);
|
|
80
|
+
$[2] = className;
|
|
81
|
+
$[3] = t3;
|
|
82
|
+
} else t3 = $[3];
|
|
83
|
+
let t4;
|
|
84
|
+
if ($[4] !== errors) {
|
|
85
|
+
t4 = errors.map(_temp);
|
|
86
|
+
$[4] = errors;
|
|
87
|
+
$[5] = t4;
|
|
88
|
+
} else t4 = $[5];
|
|
89
|
+
let t5;
|
|
90
|
+
if ($[6] !== t3 || $[7] !== t4) {
|
|
91
|
+
t5 = /* @__PURE__ */ jsx(FieldError, {
|
|
92
|
+
className: t3,
|
|
93
|
+
children: t4
|
|
94
|
+
});
|
|
95
|
+
$[6] = t3;
|
|
96
|
+
$[7] = t4;
|
|
97
|
+
$[8] = t5;
|
|
98
|
+
} else t5 = $[8];
|
|
99
|
+
return t5;
|
|
100
|
+
}
|
|
101
|
+
function _temp(error, index) {
|
|
102
|
+
return /* @__PURE__ */ jsxs(Fragment$1, { children: [index > 0 ? " " : null, /* @__PURE__ */ jsx("span", {
|
|
103
|
+
className: Field_module_default.error,
|
|
104
|
+
children: error
|
|
105
|
+
})] }, index);
|
|
52
106
|
}
|
|
53
107
|
//#endregion
|
|
54
108
|
export { FieldDescription, FieldErrors, FieldLabel, Field_module_default as fieldStyles };
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"FieldParts.js","names":["
|
|
1
|
+
{"version":3,"file":"FieldParts.js","names":["Fragment","ReactNode","FieldError","Label","Text","cx","styles","FieldChromeProps","label","description","errors","className","labelClassName","descriptionClassName","errorsClassName","FieldLabel","t0","$","_c","children","isRequired","t1","undefined","t2","t3","required","t4","FieldDescription","FieldErrors","length","map","_temp","t5","error","index","fieldStyles","_c","styles","Fragment"],"sources":["../../src/field/FieldParts.tsx"],"sourcesContent":["import { Fragment, type ReactNode } from 'react';\nimport { FieldError, Label, Text } from 'react-aria-components';\n\nimport { cx } from '../utils/cx';\nimport styles from './Field.module.css';\n\n/** Props that every labelled control of `@panneau/ui` accepts. */\nexport interface FieldChromeProps {\n /** Visible label. Without one, pass `aria-label`. */\n label?: ReactNode;\n /** Help text under the control. */\n description?: ReactNode;\n /** Error messages. Any message makes the control invalid. */\n errors?: readonly string[];\n /** Class name of the outer element. */\n className?: string;\n labelClassName?: string;\n descriptionClassName?: string;\n errorsClassName?: string;\n}\n\nexport function FieldLabel({\n children,\n isRequired = false,\n className,\n}: {\n children?: ReactNode;\n isRequired?: boolean;\n className?: string | undefined;\n}) {\n if (children === undefined || children === null) {\n return null;\n }\n return (\n <Label className={cx(styles.label, className)}>\n {children}\n {isRequired ? (\n <span className={styles.required} aria-hidden=\"true\">\n *\n </span>\n ) : null}\n </Label>\n );\n}\n\nexport function FieldDescription({\n children,\n className,\n}: {\n children?: ReactNode;\n className?: string | undefined;\n}) {\n if (children === undefined || children === null) {\n return null;\n }\n return (\n <Text slot=\"description\" className={cx(styles.description, className)}>\n {children}\n </Text>\n );\n}\n\n/** Error messages of a React Aria field. They show when the field is invalid. */\nexport function FieldErrors({\n errors = [],\n className,\n}: {\n errors?: readonly string[] | undefined;\n className?: string | undefined;\n}) {\n if (errors.length === 0) {\n return null;\n }\n return (\n <FieldError className={cx(styles.errors, className)}>\n {errors.map((error, index) => (\n <Fragment key={index}>\n {/* A space between messages, for assistive technologies. */}\n {index > 0 ? ' ' : null}\n <span className={styles.error}>{error}</span>\n </Fragment>\n ))}\n </FieldError>\n );\n}\n\nexport { styles as fieldStyles };\n"],"mappings":"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"}
|
package/dist/field/Fieldset.js
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { cx } from "../utils/cx.js";
|
|
2
2
|
import Field_module_default from "./Field.module.js";
|
|
3
|
+
import { c } from "react/compiler-runtime";
|
|
3
4
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
4
5
|
import { Fragment as Fragment$1, useId } from "react";
|
|
5
6
|
//#region src/field/Fieldset.tsx
|
|
@@ -8,41 +9,107 @@ import { Fragment as Fragment$1, useId } from "react";
|
|
|
8
9
|
* (a group of fields, a list of blocks, a value per locale). The description and the errors
|
|
9
10
|
* describe the group for assistive technologies.
|
|
10
11
|
*/
|
|
11
|
-
function Fieldset(
|
|
12
|
+
function Fieldset(t0) {
|
|
13
|
+
const $ = c(28);
|
|
14
|
+
const { legend, description, errors: t1, isRequired: t2, isDisabled: t3, children, className, legendClassName, descriptionClassName, errorsClassName } = t0;
|
|
15
|
+
let t4;
|
|
16
|
+
if ($[0] !== t1) {
|
|
17
|
+
t4 = t1 === void 0 ? [] : t1;
|
|
18
|
+
$[0] = t1;
|
|
19
|
+
$[1] = t4;
|
|
20
|
+
} else t4 = $[1];
|
|
21
|
+
const errors = t4;
|
|
22
|
+
const isRequired = t2 === void 0 ? false : t2;
|
|
23
|
+
const isDisabled = t3 === void 0 ? false : t3;
|
|
12
24
|
const id = useId();
|
|
13
25
|
const descriptionId = description !== void 0 ? `${id}-description` : null;
|
|
14
26
|
const errorsId = errors.length > 0 ? `${id}-errors` : null;
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
children,
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
]
|
|
45
|
-
}
|
|
27
|
+
let t5;
|
|
28
|
+
if ($[2] !== descriptionId || $[3] !== errorsId) {
|
|
29
|
+
t5 = [descriptionId, errorsId].filter(Boolean);
|
|
30
|
+
$[2] = descriptionId;
|
|
31
|
+
$[3] = errorsId;
|
|
32
|
+
$[4] = t5;
|
|
33
|
+
} else t5 = $[4];
|
|
34
|
+
const describedBy = t5.join(" ");
|
|
35
|
+
let t6;
|
|
36
|
+
if ($[5] !== className) {
|
|
37
|
+
t6 = cx("panneau-fieldset", Field_module_default.fieldset, className);
|
|
38
|
+
$[5] = className;
|
|
39
|
+
$[6] = t6;
|
|
40
|
+
} else t6 = $[6];
|
|
41
|
+
const t7 = describedBy !== "" ? describedBy : void 0;
|
|
42
|
+
const t8 = errors.length > 0 ? true : void 0;
|
|
43
|
+
let t9;
|
|
44
|
+
if ($[7] !== isRequired || $[8] !== legend || $[9] !== legendClassName) {
|
|
45
|
+
t9 = legend !== void 0 && legend !== null ? /* @__PURE__ */ jsxs("legend", {
|
|
46
|
+
className: cx(Field_module_default.legend, Field_module_default.label, legendClassName),
|
|
47
|
+
children: [legend, isRequired ? /* @__PURE__ */ jsx("span", {
|
|
48
|
+
className: Field_module_default.required,
|
|
49
|
+
"aria-hidden": "true",
|
|
50
|
+
children: "*"
|
|
51
|
+
}) : null]
|
|
52
|
+
}) : null;
|
|
53
|
+
$[7] = isRequired;
|
|
54
|
+
$[8] = legend;
|
|
55
|
+
$[9] = legendClassName;
|
|
56
|
+
$[10] = t9;
|
|
57
|
+
} else t9 = $[10];
|
|
58
|
+
let t10;
|
|
59
|
+
if ($[11] !== description || $[12] !== descriptionClassName || $[13] !== descriptionId) {
|
|
60
|
+
t10 = descriptionId !== null ? /* @__PURE__ */ jsx("div", {
|
|
61
|
+
id: descriptionId,
|
|
62
|
+
className: cx(Field_module_default.description, descriptionClassName),
|
|
63
|
+
children: description
|
|
64
|
+
}) : null;
|
|
65
|
+
$[11] = description;
|
|
66
|
+
$[12] = descriptionClassName;
|
|
67
|
+
$[13] = descriptionId;
|
|
68
|
+
$[14] = t10;
|
|
69
|
+
} else t10 = $[14];
|
|
70
|
+
let t11;
|
|
71
|
+
if ($[15] !== errors || $[16] !== errorsClassName || $[17] !== errorsId) {
|
|
72
|
+
t11 = errorsId !== null ? /* @__PURE__ */ jsx("div", {
|
|
73
|
+
id: errorsId,
|
|
74
|
+
className: cx(Field_module_default.errors, errorsClassName),
|
|
75
|
+
children: errors.map(_temp)
|
|
76
|
+
}) : null;
|
|
77
|
+
$[15] = errors;
|
|
78
|
+
$[16] = errorsClassName;
|
|
79
|
+
$[17] = errorsId;
|
|
80
|
+
$[18] = t11;
|
|
81
|
+
} else t11 = $[18];
|
|
82
|
+
let t12;
|
|
83
|
+
if ($[19] !== children || $[20] !== isDisabled || $[21] !== t10 || $[22] !== t11 || $[23] !== t6 || $[24] !== t7 || $[25] !== t8 || $[26] !== t9) {
|
|
84
|
+
t12 = /* @__PURE__ */ jsxs("fieldset", {
|
|
85
|
+
className: t6,
|
|
86
|
+
"aria-describedby": t7,
|
|
87
|
+
"aria-invalid": t8,
|
|
88
|
+
disabled: isDisabled,
|
|
89
|
+
children: [
|
|
90
|
+
t9,
|
|
91
|
+
t10,
|
|
92
|
+
children,
|
|
93
|
+
t11
|
|
94
|
+
]
|
|
95
|
+
});
|
|
96
|
+
$[19] = children;
|
|
97
|
+
$[20] = isDisabled;
|
|
98
|
+
$[21] = t10;
|
|
99
|
+
$[22] = t11;
|
|
100
|
+
$[23] = t6;
|
|
101
|
+
$[24] = t7;
|
|
102
|
+
$[25] = t8;
|
|
103
|
+
$[26] = t9;
|
|
104
|
+
$[27] = t12;
|
|
105
|
+
} else t12 = $[27];
|
|
106
|
+
return t12;
|
|
107
|
+
}
|
|
108
|
+
function _temp(error, index) {
|
|
109
|
+
return /* @__PURE__ */ jsxs(Fragment$1, { children: [index > 0 ? " " : null, /* @__PURE__ */ jsx("span", {
|
|
110
|
+
className: Field_module_default.error,
|
|
111
|
+
children: error
|
|
112
|
+
})] }, index);
|
|
46
113
|
}
|
|
47
114
|
//#endregion
|
|
48
115
|
export { Fieldset };
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Fieldset.js","names":["styles","Fragment"],"sources":["../../src/field/Fieldset.tsx"],"sourcesContent":["import { Fragment, type ReactNode, useId } from 'react';\n\nimport { cx } from '../utils/cx';\nimport styles from './Field.module.css';\n\nexport interface FieldsetProps {\n /** Title of the group of controls. */\n legend?: ReactNode;\n description?: ReactNode;\n /** Errors of the group as a whole. */\n errors?: readonly string[];\n isRequired?: boolean;\n isDisabled?: boolean;\n children?: ReactNode;\n className?: string;\n legendClassName?: string;\n descriptionClassName?: string;\n errorsClassName?: string;\n}\n\n/**\n * Groups related controls under a legend, with a description and errors: for composite values\n * (a group of fields, a list of blocks, a value per locale). The description and the errors\n * describe the group for assistive technologies.\n */\nexport function Fieldset({\n legend,\n description,\n errors = [],\n isRequired = false,\n isDisabled = false,\n children,\n className,\n legendClassName,\n descriptionClassName,\n errorsClassName,\n}: FieldsetProps) {\n const id = useId();\n const descriptionId = description !== undefined ? `${id}-description` : null;\n const errorsId = errors.length > 0 ? `${id}-errors` : null;\n const describedBy = [descriptionId, errorsId].filter(Boolean).join(' ');\n return (\n <fieldset\n className={cx(styles.fieldset, className)}\n aria-describedby={describedBy !== '' ? describedBy : undefined}\n aria-invalid={errors.length > 0 ? true : undefined}\n disabled={isDisabled}\n >\n {legend !== undefined && legend !== null ? (\n <legend className={cx(styles.legend, styles.label, legendClassName)}>\n {legend}\n {isRequired ? (\n <span className={styles.required} aria-hidden=\"true\">\n *\n </span>\n ) : null}\n </legend>\n ) : null}\n {descriptionId !== null ? (\n <div id={descriptionId} className={cx(styles.description, descriptionClassName)}>\n {description}\n </div>\n ) : null}\n {children}\n {errorsId !== null ? (\n <div id={errorsId} className={cx(styles.errors, errorsClassName)}>\n {errors.map((error, index) => (\n <Fragment key={index}>\n {/* A space between messages, for assistive technologies. */}\n {index > 0 ? ' ' : null}\n <span className={styles.error}>{error}</span>\n </Fragment>\n ))}\n </div>\n ) : null}\n </fieldset>\n );\n}\n"],"mappings":"
|
|
1
|
+
{"version":3,"file":"Fieldset.js","names":["Fragment","ReactNode","useId","cx","styles","FieldsetProps","legend","description","errors","isRequired","isDisabled","children","className","legendClassName","descriptionClassName","errorsClassName","Fieldset","t0","$","_c","t1","t2","t3","t4","undefined","id","descriptionId","errorsId","length","t5","filter","Boolean","describedBy","join","t6","fieldset","t7","t8","t9","label","required","t10","t11","map","_temp","t12","error","index","_c","styles","Fragment"],"sources":["../../src/field/Fieldset.tsx"],"sourcesContent":["import { Fragment, type ReactNode, useId } from 'react';\n\nimport { cx } from '../utils/cx';\nimport styles from './Field.module.css';\n\nexport interface FieldsetProps {\n /** Title of the group of controls. */\n legend?: ReactNode;\n description?: ReactNode;\n /** Errors of the group as a whole. */\n errors?: readonly string[];\n isRequired?: boolean;\n isDisabled?: boolean;\n children?: ReactNode;\n className?: string;\n legendClassName?: string;\n descriptionClassName?: string;\n errorsClassName?: string;\n}\n\n/**\n * Groups related controls under a legend, with a description and errors: for composite values\n * (a group of fields, a list of blocks, a value per locale). The description and the errors\n * describe the group for assistive technologies.\n */\nexport function Fieldset({\n legend,\n description,\n errors = [],\n isRequired = false,\n isDisabled = false,\n children,\n className,\n legendClassName,\n descriptionClassName,\n errorsClassName,\n}: FieldsetProps) {\n const id = useId();\n const descriptionId = description !== undefined ? `${id}-description` : null;\n const errorsId = errors.length > 0 ? `${id}-errors` : null;\n const describedBy = [descriptionId, errorsId].filter(Boolean).join(' ');\n return (\n <fieldset\n className={cx('panneau-fieldset', styles.fieldset, className)}\n aria-describedby={describedBy !== '' ? describedBy : undefined}\n aria-invalid={errors.length > 0 ? true : undefined}\n disabled={isDisabled}\n >\n {legend !== undefined && legend !== null ? (\n <legend className={cx(styles.legend, styles.label, legendClassName)}>\n {legend}\n {isRequired ? (\n <span className={styles.required} aria-hidden=\"true\">\n *\n </span>\n ) : null}\n </legend>\n ) : null}\n {descriptionId !== null ? (\n <div id={descriptionId} className={cx(styles.description, descriptionClassName)}>\n {description}\n </div>\n ) : null}\n {children}\n {errorsId !== null ? (\n <div id={errorsId} className={cx(styles.errors, errorsClassName)}>\n {errors.map((error, index) => (\n <Fragment key={index}>\n {/* A space between messages, for assistive technologies. */}\n {index > 0 ? ' ' : null}\n <span className={styles.error}>{error}</span>\n </Fragment>\n ))}\n </div>\n ) : null}\n </fieldset>\n );\n}\n"],"mappings":"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"}
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
/** Tokens of the input box of text inputs, text areas, selects, combo boxes, number inputs, date pickers and time inputs. */
|
|
2
|
+
export declare const inputTokens: import("../index.js").ComponentTokens<"input", "panneau-input-radius" | "panneau-input-padding-x" | "panneau-input-border-width" | "panneau-input-bg" | "panneau-input-border-color" | "panneau-input-border-color-hover">;
|
|
3
|
+
//# sourceMappingURL=inputTokens.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"inputTokens.d.ts","sourceRoot":"","sources":["../../src/field/inputTokens.ts"],"names":[],"mappings":"AAEA,6HAA6H;AAC7H,eAAO,MAAM,WAAW,mNAatB,CAAC"}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { defineComponentTokens } from "../theme/componentTokens.js";
|
|
2
|
+
//#region src/field/inputTokens.ts
|
|
3
|
+
/** Tokens of the input box of text inputs, text areas, selects, combo boxes, number inputs, date pickers and time inputs. */
|
|
4
|
+
var inputTokens = defineComponentTokens("input", {
|
|
5
|
+
/** Horizontal padding. */
|
|
6
|
+
"padding-x": "var(--panneau-control-padding-x)",
|
|
7
|
+
/** Background. */
|
|
8
|
+
bg: "var(--panneau-color-surface)",
|
|
9
|
+
/** Width of the border. */
|
|
10
|
+
"border-width": "var(--panneau-border-width)",
|
|
11
|
+
/** Border color. */
|
|
12
|
+
"border-color": "var(--panneau-color-border-control)",
|
|
13
|
+
/** Corner radius. */
|
|
14
|
+
radius: "var(--panneau-radius-md)",
|
|
15
|
+
/** Border color of a hovered input. */
|
|
16
|
+
"border-color-hover": "var(--panneau-color-text-muted)"
|
|
17
|
+
});
|
|
18
|
+
//#endregion
|
|
19
|
+
export { inputTokens };
|
|
20
|
+
|
|
21
|
+
//# sourceMappingURL=inputTokens.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"inputTokens.js","names":["defineComponentTokens","inputTokens","bg","radius"],"sources":["../../src/field/inputTokens.ts"],"sourcesContent":["import { defineComponentTokens } from '../theme/componentTokens';\n\n/** Tokens of the input box of text inputs, text areas, selects, combo boxes, number inputs, date pickers and time inputs. */\nexport const inputTokens = defineComponentTokens('input', {\n /** Horizontal padding. */\n 'padding-x': 'var(--panneau-control-padding-x)',\n /** Background. */\n bg: 'var(--panneau-color-surface)',\n /** Width of the border. */\n 'border-width': 'var(--panneau-border-width)',\n /** Border color. */\n 'border-color': 'var(--panneau-color-border-control)',\n /** Corner radius. */\n radius: 'var(--panneau-radius-md)',\n /** Border color of a hovered input. */\n 'border-color-hover': 'var(--panneau-color-text-muted)',\n});\n"],"mappings":";;;AAGA,IAAaC,cAAcD,sBAAsB,SAAS;;CAEtD,aAAa;;CAEbE,IAAI;;CAEJ,gBAAgB;;CAEhB,gBAAgB;;CAEhBC,QAAQ;;CAER,sBAAsB;AAC1B,CAAC"}
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
/** Tokens of the label, description and errors around inputs. */
|
|
2
|
+
export declare const fieldTokens: import("../index.js").ComponentTokens<"field", "panneau-field-gap" | "panneau-field-label-font-size" | "panneau-field-label-font-weight">;
|
|
3
|
+
//# sourceMappingURL=tokens.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"tokens.d.ts","sourceRoot":"","sources":["../../src/field/tokens.ts"],"names":[],"mappings":"AAEA,iEAAiE;AACjE,eAAO,MAAM,WAAW,kIAOtB,CAAC"}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { defineComponentTokens } from "../theme/componentTokens.js";
|
|
2
|
+
//#region src/field/tokens.ts
|
|
3
|
+
/** Tokens of the label, description and errors around inputs. */
|
|
4
|
+
var fieldTokens = defineComponentTokens("field", {
|
|
5
|
+
/** Space between the label, the input, the description and the errors. */
|
|
6
|
+
gap: "var(--panneau-space-1)",
|
|
7
|
+
/** Font size of the label. */
|
|
8
|
+
"label-font-size": "var(--panneau-font-size-md)",
|
|
9
|
+
/** Font weight of the label. */
|
|
10
|
+
"label-font-weight": "var(--panneau-font-weight-medium)"
|
|
11
|
+
});
|
|
12
|
+
//#endregion
|
|
13
|
+
export { fieldTokens };
|
|
14
|
+
|
|
15
|
+
//# sourceMappingURL=tokens.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"tokens.js","names":["defineComponentTokens","fieldTokens","gap"],"sources":["../../src/field/tokens.ts"],"sourcesContent":["import { defineComponentTokens } from '../theme/componentTokens';\n\n/** Tokens of the label, description and errors around inputs. */\nexport const fieldTokens = defineComponentTokens('field', {\n /** Space between the label, the input, the description and the errors. */\n gap: 'var(--panneau-space-1)',\n /** Font size of the label. */\n 'label-font-size': 'var(--panneau-font-size-md)',\n /** Font weight of the label. */\n 'label-font-weight': 'var(--panneau-font-weight-medium)',\n});\n"],"mappings":";;;AAGA,IAAaC,cAAcD,sBAAsB,SAAS;;CAEtDE,KAAK;;CAEL,mBAAmB;;CAEnB,qBAAqB;AACzB,CAAC"}
|