@stridge/noctis 1.0.0-beta.0
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 +60 -0
- package/dist/_virtual/_rolldown/runtime.js +27 -0
- package/dist/components/accordion/accordion.context.js +15 -0
- package/dist/components/accordion/accordion.d.ts +136 -0
- package/dist/components/accordion/accordion.js +132 -0
- package/dist/components/accordion/accordion.props.d.ts +45 -0
- package/dist/components/accordion/accordion.props.js +53 -0
- package/dist/components/accordion/accordion.slots.d.ts +24 -0
- package/dist/components/accordion/accordion.slots.js +39 -0
- package/dist/components/accordion/accordion.types.d.ts +11 -0
- package/dist/components/accordion/index.d.ts +3 -0
- package/dist/components/alert-dialog/alert-dialog.context.js +16 -0
- package/dist/components/alert-dialog/alert-dialog.d.ts +324 -0
- package/dist/components/alert-dialog/alert-dialog.js +279 -0
- package/dist/components/alert-dialog/alert-dialog.props.d.ts +85 -0
- package/dist/components/alert-dialog/alert-dialog.props.js +84 -0
- package/dist/components/alert-dialog/alert-dialog.slots.d.ts +29 -0
- package/dist/components/alert-dialog/alert-dialog.slots.js +52 -0
- package/dist/components/alert-dialog/alert-dialog.types.d.ts +22 -0
- package/dist/components/alert-dialog/index.d.ts +3 -0
- package/dist/components/autocomplete/autocomplete.context.d.ts +5 -0
- package/dist/components/autocomplete/autocomplete.context.js +13 -0
- package/dist/components/autocomplete/autocomplete.d.ts +364 -0
- package/dist/components/autocomplete/autocomplete.js +373 -0
- package/dist/components/autocomplete/autocomplete.props.d.ts +83 -0
- package/dist/components/autocomplete/autocomplete.props.js +63 -0
- package/dist/components/autocomplete/autocomplete.slots.d.ts +32 -0
- package/dist/components/autocomplete/autocomplete.slots.js +61 -0
- package/dist/components/autocomplete/index.d.ts +3 -0
- package/dist/components/avatar/avatar.context.js +21 -0
- package/dist/components/avatar/avatar.d.ts +235 -0
- package/dist/components/avatar/avatar.js +208 -0
- package/dist/components/avatar/avatar.props.d.ts +86 -0
- package/dist/components/avatar/avatar.props.js +78 -0
- package/dist/components/avatar/avatar.slots.d.ts +35 -0
- package/dist/components/avatar/avatar.slots.js +49 -0
- package/dist/components/avatar/avatar.types.d.ts +28 -0
- package/dist/components/avatar/index.d.ts +2 -0
- package/dist/components/button/button.d.ts +91 -0
- package/dist/components/button/button.js +82 -0
- package/dist/components/button/button.props.d.ts +48 -0
- package/dist/components/button/button.props.js +25 -0
- package/dist/components/button/button.slots.d.ts +30 -0
- package/dist/components/button/button.slots.js +40 -0
- package/dist/components/button/button.types.d.ts +12 -0
- package/dist/components/button/index.d.ts +2 -0
- package/dist/components/button-group/button-group.context.js +15 -0
- package/dist/components/button-group/button-group.d.ts +60 -0
- package/dist/components/button-group/button-group.js +50 -0
- package/dist/components/button-group/button-group.props.d.ts +22 -0
- package/dist/components/button-group/button-group.props.js +33 -0
- package/dist/components/button-group/button-group.slots.d.ts +12 -0
- package/dist/components/button-group/button-group.slots.js +18 -0
- package/dist/components/button-group/index.d.ts +2 -0
- package/dist/components/checkbox/checkbox-group.d.ts +46 -0
- package/dist/components/checkbox/checkbox-group.js +31 -0
- package/dist/components/checkbox/checkbox.context.js +15 -0
- package/dist/components/checkbox/checkbox.d.ts +130 -0
- package/dist/components/checkbox/checkbox.js +117 -0
- package/dist/components/checkbox/checkbox.props.d.ts +84 -0
- package/dist/components/checkbox/checkbox.props.js +49 -0
- package/dist/components/checkbox/checkbox.slots.d.ts +27 -0
- package/dist/components/checkbox/checkbox.slots.js +40 -0
- package/dist/components/checkbox/index.d.ts +3 -0
- package/dist/components/code-block/brand-logo.d.ts +37 -0
- package/dist/components/code-block/brand-logo.js +212 -0
- package/dist/components/code-block/code-block.context.js +13 -0
- package/dist/components/code-block/code-block.d.ts +190 -0
- package/dist/components/code-block/code-block.js +267 -0
- package/dist/components/code-block/code-block.props.d.ts +42 -0
- package/dist/components/code-block/code-block.props.js +51 -0
- package/dist/components/code-block/code-block.slots.d.ts +16 -0
- package/dist/components/code-block/code-block.slots.js +31 -0
- package/dist/components/code-block/index.d.ts +3 -0
- package/dist/components/code-block/language-label.js +43 -0
- package/dist/components/collapsible/collapsible.context.js +18 -0
- package/dist/components/collapsible/collapsible.d.ts +167 -0
- package/dist/components/collapsible/collapsible.js +182 -0
- package/dist/components/collapsible/collapsible.props.d.ts +33 -0
- package/dist/components/collapsible/collapsible.props.js +44 -0
- package/dist/components/collapsible/collapsible.slots.d.ts +25 -0
- package/dist/components/collapsible/collapsible.slots.js +40 -0
- package/dist/components/collapsible/collapsible.types.d.ts +23 -0
- package/dist/components/collapsible/index.d.ts +2 -0
- package/dist/components/color-picker/area.d.ts +11 -0
- package/dist/components/color-picker/area.js +148 -0
- package/dist/components/color-picker/color-picker.d.ts +110 -0
- package/dist/components/color-picker/color-picker.js +149 -0
- package/dist/components/color-picker/color-picker.props.d.ts +69 -0
- package/dist/components/color-picker/color-picker.props.js +74 -0
- package/dist/components/color-picker/color-picker.slots.js +21 -0
- package/dist/components/color-picker/color.d.ts +18 -0
- package/dist/components/color-picker/color.js +224 -0
- package/dist/components/color-picker/context.d.ts +25 -0
- package/dist/components/color-picker/context.js +23 -0
- package/dist/components/color-picker/eyedropper.d.ts +14 -0
- package/dist/components/color-picker/eyedropper.js +50 -0
- package/dist/components/color-picker/format-tabs.d.ts +11 -0
- package/dist/components/color-picker/format-tabs.js +35 -0
- package/dist/components/color-picker/index.d.ts +3 -0
- package/dist/components/color-picker/inputs.d.ts +16 -0
- package/dist/components/color-picker/inputs.js +61 -0
- package/dist/components/color-picker/sliders.d.ts +17 -0
- package/dist/components/color-picker/sliders.js +94 -0
- package/dist/components/color-picker/store.js +48 -0
- package/dist/components/color-picker/swatch.d.ts +15 -0
- package/dist/components/color-picker/swatch.js +25 -0
- package/dist/components/color-swatch/color-swatch-picker.d.ts +87 -0
- package/dist/components/color-swatch/color-swatch-picker.js +73 -0
- package/dist/components/color-swatch/color-swatch.context.js +8 -0
- package/dist/components/color-swatch/color-swatch.d.ts +55 -0
- package/dist/components/color-swatch/color-swatch.js +48 -0
- package/dist/components/color-swatch/color-swatch.props.d.ts +54 -0
- package/dist/components/color-swatch/color-swatch.props.js +32 -0
- package/dist/components/color-swatch/color-swatch.slots.js +13 -0
- package/dist/components/color-swatch/index.d.ts +2 -0
- package/dist/components/combobox/combobox.context.js +13 -0
- package/dist/components/combobox/combobox.d.ts +328 -0
- package/dist/components/combobox/combobox.js +315 -0
- package/dist/components/combobox/combobox.props.d.ts +85 -0
- package/dist/components/combobox/combobox.props.js +79 -0
- package/dist/components/combobox/combobox.slots.d.ts +28 -0
- package/dist/components/combobox/combobox.slots.js +63 -0
- package/dist/components/combobox/index.d.ts +2 -0
- package/dist/components/context-menu/context-menu.d.ts +254 -0
- package/dist/components/context-menu/context-menu.js +150 -0
- package/dist/components/context-menu/context-menu.props.d.ts +22 -0
- package/dist/components/context-menu/context-menu.props.js +32 -0
- package/dist/components/context-menu/context-menu.slots.d.ts +24 -0
- package/dist/components/context-menu/context-menu.slots.js +42 -0
- package/dist/components/context-menu/index.d.ts +2 -0
- package/dist/components/copy-button/copy-button.d.ts +56 -0
- package/dist/components/copy-button/copy-button.js +88 -0
- package/dist/components/copy-button/copy-button.props.d.ts +27 -0
- package/dist/components/copy-button/copy-button.props.js +51 -0
- package/dist/components/copy-button/copy-button.slots.d.ts +20 -0
- package/dist/components/copy-button/copy-button.slots.js +36 -0
- package/dist/components/copy-button/index.d.ts +2 -0
- package/dist/components/dialog/dialog.context.js +15 -0
- package/dist/components/dialog/dialog.d.ts +299 -0
- package/dist/components/dialog/dialog.js +263 -0
- package/dist/components/dialog/dialog.props.d.ts +71 -0
- package/dist/components/dialog/dialog.props.js +75 -0
- package/dist/components/dialog/dialog.slots.d.ts +26 -0
- package/dist/components/dialog/dialog.slots.js +46 -0
- package/dist/components/dialog/dialog.types.d.ts +16 -0
- package/dist/components/dialog/index.d.ts +3 -0
- package/dist/components/field/field.d.ts +221 -0
- package/dist/components/field/field.js +192 -0
- package/dist/components/field/field.props.d.ts +66 -0
- package/dist/components/field/field.props.js +65 -0
- package/dist/components/field/field.slots.d.ts +35 -0
- package/dist/components/field/field.slots.js +54 -0
- package/dist/components/field/field.types.d.ts +5 -0
- package/dist/components/field/index.d.ts +4 -0
- package/dist/components/inline-code/index.d.ts +1 -0
- package/dist/components/inline-code/inline-code.d.ts +46 -0
- package/dist/components/inline-code/inline-code.js +36 -0
- package/dist/components/inline-code/inline-code.props.d.ts +17 -0
- package/dist/components/inline-code/inline-code.props.js +27 -0
- package/dist/components/inline-code/inline-code.slots.js +8 -0
- package/dist/components/input/index.d.ts +3 -0
- package/dist/components/input/input.context.js +13 -0
- package/dist/components/input/input.d.ts +161 -0
- package/dist/components/input/input.js +117 -0
- package/dist/components/input/input.props.d.ts +51 -0
- package/dist/components/input/input.props.js +50 -0
- package/dist/components/input/input.slots.d.ts +35 -0
- package/dist/components/input/input.slots.js +46 -0
- package/dist/components/input/input.types.d.ts +12 -0
- package/dist/components/kbd/glyphs.js +45 -0
- package/dist/components/kbd/index.d.ts +1 -0
- package/dist/components/kbd/kbd.d.ts +61 -0
- package/dist/components/kbd/kbd.js +233 -0
- package/dist/components/kbd/kbd.props.d.ts +30 -0
- package/dist/components/kbd/kbd.props.js +39 -0
- package/dist/components/kbd/kbd.slots.js +14 -0
- package/dist/components/kbd/use-apple-platform.js +25 -0
- package/dist/components/menu/index.d.ts +2 -0
- package/dist/components/menu/menu.d.ts +355 -0
- package/dist/components/menu/menu.js +263 -0
- package/dist/components/menu/menu.props.d.ts +92 -0
- package/dist/components/menu/menu.props.js +97 -0
- package/dist/components/menu/menu.slots.d.ts +32 -0
- package/dist/components/menu/menu.slots.js +60 -0
- package/dist/components/menubar/index.d.ts +2 -0
- package/dist/components/menubar/menubar.context.js +13 -0
- package/dist/components/menubar/menubar.d.ts +162 -0
- package/dist/components/menubar/menubar.js +122 -0
- package/dist/components/menubar/menubar.props.d.ts +41 -0
- package/dist/components/menubar/menubar.props.js +45 -0
- package/dist/components/menubar/menubar.slots.d.ts +26 -0
- package/dist/components/menubar/menubar.slots.js +40 -0
- package/dist/components/meter/index.d.ts +2 -0
- package/dist/components/meter/meter.context.d.ts +9 -0
- package/dist/components/meter/meter.context.js +13 -0
- package/dist/components/meter/meter.d.ts +163 -0
- package/dist/components/meter/meter.js +121 -0
- package/dist/components/meter/meter.props.d.ts +50 -0
- package/dist/components/meter/meter.props.js +33 -0
- package/dist/components/meter/meter.slots.d.ts +18 -0
- package/dist/components/meter/meter.slots.js +31 -0
- package/dist/components/navigation-menu/index.d.ts +2 -0
- package/dist/components/navigation-menu/navigation-menu.d.ts +328 -0
- package/dist/components/navigation-menu/navigation-menu.js +274 -0
- package/dist/components/navigation-menu/navigation-menu.props.d.ts +98 -0
- package/dist/components/navigation-menu/navigation-menu.props.js +90 -0
- package/dist/components/navigation-menu/navigation-menu.slots.d.ts +34 -0
- package/dist/components/navigation-menu/navigation-menu.slots.js +60 -0
- package/dist/components/number-field/index.d.ts +2 -0
- package/dist/components/number-field/number-field.context.d.ts +13 -0
- package/dist/components/number-field/number-field.context.js +13 -0
- package/dist/components/number-field/number-field.d.ts +197 -0
- package/dist/components/number-field/number-field.js +187 -0
- package/dist/components/number-field/number-field.props.d.ts +66 -0
- package/dist/components/number-field/number-field.props.js +50 -0
- package/dist/components/number-field/number-field.slots.d.ts +31 -0
- package/dist/components/number-field/number-field.slots.js +48 -0
- package/dist/components/otp-field/index.d.ts +3 -0
- package/dist/components/otp-field/otp-field.context.js +13 -0
- package/dist/components/otp-field/otp-field.d.ts +99 -0
- package/dist/components/otp-field/otp-field.js +76 -0
- package/dist/components/otp-field/otp-field.props.d.ts +48 -0
- package/dist/components/otp-field/otp-field.props.js +43 -0
- package/dist/components/otp-field/otp-field.slots.d.ts +28 -0
- package/dist/components/otp-field/otp-field.slots.js +39 -0
- package/dist/components/popover/index.d.ts +2 -0
- package/dist/components/popover/popover.d.ts +192 -0
- package/dist/components/popover/popover.js +152 -0
- package/dist/components/popover/popover.props.d.ts +34 -0
- package/dist/components/popover/popover.props.js +44 -0
- package/dist/components/popover/popover.slots.d.ts +22 -0
- package/dist/components/popover/popover.slots.js +42 -0
- package/dist/components/preview-card/index.d.ts +2 -0
- package/dist/components/preview-card/preview-card.d.ts +182 -0
- package/dist/components/preview-card/preview-card.js +146 -0
- package/dist/components/preview-card/preview-card.props.d.ts +37 -0
- package/dist/components/preview-card/preview-card.props.js +48 -0
- package/dist/components/preview-card/preview-card.slots.d.ts +22 -0
- package/dist/components/preview-card/preview-card.slots.js +39 -0
- package/dist/components/progress/index.d.ts +3 -0
- package/dist/components/progress/progress.context.d.ts +9 -0
- package/dist/components/progress/progress.context.js +13 -0
- package/dist/components/progress/progress.d.ts +139 -0
- package/dist/components/progress/progress.js +92 -0
- package/dist/components/progress/progress.props.d.ts +56 -0
- package/dist/components/progress/progress.props.js +38 -0
- package/dist/components/progress/progress.slots.d.ts +24 -0
- package/dist/components/progress/progress.slots.js +37 -0
- package/dist/components/radio/index.d.ts +2 -0
- package/dist/components/radio/radio.context.js +5 -0
- package/dist/components/radio/radio.d.ts +205 -0
- package/dist/components/radio/radio.js +168 -0
- package/dist/components/radio/radio.props.d.ts +106 -0
- package/dist/components/radio/radio.props.js +65 -0
- package/dist/components/radio/radio.slots.d.ts +29 -0
- package/dist/components/radio/radio.slots.js +44 -0
- package/dist/components/rail/index.d.ts +3 -0
- package/dist/components/rail/rail.context.d.ts +17 -0
- package/dist/components/rail/rail.context.js +23 -0
- package/dist/components/rail/rail.d.ts +232 -0
- package/dist/components/rail/rail.js +254 -0
- package/dist/components/rail/rail.props.d.ts +98 -0
- package/dist/components/rail/rail.props.js +64 -0
- package/dist/components/rail/rail.slots.d.ts +20 -0
- package/dist/components/rail/rail.slots.js +40 -0
- package/dist/components/scroll-area/index.d.ts +2 -0
- package/dist/components/scroll-area/scroll-area.context.js +15 -0
- package/dist/components/scroll-area/scroll-area.d.ts +217 -0
- package/dist/components/scroll-area/scroll-area.js +153 -0
- package/dist/components/scroll-area/scroll-area.props.d.ts +73 -0
- package/dist/components/scroll-area/scroll-area.props.js +64 -0
- package/dist/components/scroll-area/scroll-area.slots.d.ts +40 -0
- package/dist/components/scroll-area/scroll-area.slots.js +54 -0
- package/dist/components/scroll-area/scroll-area.types.d.ts +24 -0
- package/dist/components/search-dialog/index.d.ts +3 -0
- package/dist/components/search-dialog/parts/input.d.ts +24 -0
- package/dist/components/search-dialog/parts/input.js +53 -0
- package/dist/components/search-dialog/parts/messages.d.ts +80 -0
- package/dist/components/search-dialog/parts/messages.js +75 -0
- package/dist/components/search-dialog/parts/results.d.ts +43 -0
- package/dist/components/search-dialog/parts/results.js +63 -0
- package/dist/components/search-dialog/parts/root.d.ts +54 -0
- package/dist/components/search-dialog/parts/root.js +99 -0
- package/dist/components/search-dialog/search-dialog.context.d.ts +15 -0
- package/dist/components/search-dialog/search-dialog.context.js +20 -0
- package/dist/components/search-dialog/search-dialog.d.ts +84 -0
- package/dist/components/search-dialog/search-dialog.js +43 -0
- package/dist/components/search-dialog/search-dialog.props.d.ts +45 -0
- package/dist/components/search-dialog/search-dialog.props.js +49 -0
- package/dist/components/search-dialog/search-dialog.slots.d.ts +16 -0
- package/dist/components/search-dialog/search-dialog.slots.js +32 -0
- package/dist/components/select/index.d.ts +2 -0
- package/dist/components/select/select.context.js +17 -0
- package/dist/components/select/select.d.ts +356 -0
- package/dist/components/select/select.js +314 -0
- package/dist/components/select/select.props.d.ts +110 -0
- package/dist/components/select/select.props.js +103 -0
- package/dist/components/select/select.slots.d.ts +38 -0
- package/dist/components/select/select.slots.js +67 -0
- package/dist/components/separator/index.d.ts +2 -0
- package/dist/components/separator/separator.d.ts +69 -0
- package/dist/components/separator/separator.js +44 -0
- package/dist/components/separator/separator.props.d.ts +30 -0
- package/dist/components/separator/separator.props.js +30 -0
- package/dist/components/separator/separator.slots.d.ts +22 -0
- package/dist/components/separator/separator.slots.js +21 -0
- package/dist/components/separator/separator.types.d.ts +5 -0
- package/dist/components/sheet/index.d.ts +3 -0
- package/dist/components/sheet/sheet-stack.d.ts +106 -0
- package/dist/components/sheet/sheet-stack.js +146 -0
- package/dist/components/sheet/sheet.d.ts +279 -0
- package/dist/components/sheet/sheet.js +264 -0
- package/dist/components/sheet/sheet.props.d.ts +74 -0
- package/dist/components/sheet/sheet.props.js +77 -0
- package/dist/components/sheet/sheet.slots.js +22 -0
- package/dist/components/sheet/sheet.types.d.ts +12 -0
- package/dist/components/slider/index.d.ts +3 -0
- package/dist/components/slider/slider.context.d.ts +5 -0
- package/dist/components/slider/slider.context.js +29 -0
- package/dist/components/slider/slider.d.ts +230 -0
- package/dist/components/slider/slider.js +274 -0
- package/dist/components/slider/slider.props.d.ts +72 -0
- package/dist/components/slider/slider.props.js +59 -0
- package/dist/components/slider/slider.slots.d.ts +30 -0
- package/dist/components/slider/slider.slots.js +50 -0
- package/dist/components/surface/index.d.ts +1 -0
- package/dist/components/surface/surface.d.ts +84 -0
- package/dist/components/surface/surface.js +48 -0
- package/dist/components/surface/surface.props.d.ts +35 -0
- package/dist/components/surface/surface.props.js +26 -0
- package/dist/components/surface/surface.slots.js +9 -0
- package/dist/components/surface/surface.types.d.ts +14 -0
- package/dist/components/switch/index.d.ts +2 -0
- package/dist/components/switch/switch.context.js +14 -0
- package/dist/components/switch/switch.d.ts +110 -0
- package/dist/components/switch/switch.js +92 -0
- package/dist/components/switch/switch.props.d.ts +68 -0
- package/dist/components/switch/switch.props.js +41 -0
- package/dist/components/switch/switch.slots.d.ts +23 -0
- package/dist/components/switch/switch.slots.js +35 -0
- package/dist/components/table/index.d.ts +1 -0
- package/dist/components/table/table.d.ts +104 -0
- package/dist/components/table/table.js +92 -0
- package/dist/components/table/table.props.d.ts +38 -0
- package/dist/components/table/table.props.js +49 -0
- package/dist/components/table/table.slots.js +17 -0
- package/dist/components/tabs/index.d.ts +2 -0
- package/dist/components/tabs/tabs.context.d.ts +9 -0
- package/dist/components/tabs/tabs.context.js +13 -0
- package/dist/components/tabs/tabs.d.ts +139 -0
- package/dist/components/tabs/tabs.js +118 -0
- package/dist/components/tabs/tabs.props.d.ts +59 -0
- package/dist/components/tabs/tabs.props.js +39 -0
- package/dist/components/tabs/tabs.slots.d.ts +20 -0
- package/dist/components/tabs/tabs.slots.js +33 -0
- package/dist/components/textarea/index.d.ts +3 -0
- package/dist/components/textarea/textarea.context.js +13 -0
- package/dist/components/textarea/textarea.d.ts +142 -0
- package/dist/components/textarea/textarea.js +129 -0
- package/dist/components/textarea/textarea.props.d.ts +44 -0
- package/dist/components/textarea/textarea.props.js +32 -0
- package/dist/components/textarea/textarea.slots.d.ts +23 -0
- package/dist/components/textarea/textarea.slots.js +33 -0
- package/dist/components/textarea/textarea.types.d.ts +5 -0
- package/dist/components/toast/index.d.ts +4 -0
- package/dist/components/toast/toast.d.ts +241 -0
- package/dist/components/toast/toast.js +193 -0
- package/dist/components/toast/toast.manager.d.ts +76 -0
- package/dist/components/toast/toast.manager.js +71 -0
- package/dist/components/toast/toast.props.d.ts +66 -0
- package/dist/components/toast/toast.props.js +74 -0
- package/dist/components/toast/toast.slots.d.ts +30 -0
- package/dist/components/toast/toast.slots.js +49 -0
- package/dist/components/toast/toast.types.d.ts +19 -0
- package/dist/components/toggle/index.d.ts +2 -0
- package/dist/components/toggle/toggle.context.d.ts +11 -0
- package/dist/components/toggle/toggle.context.js +14 -0
- package/dist/components/toggle/toggle.d.ts +136 -0
- package/dist/components/toggle/toggle.js +101 -0
- package/dist/components/toggle/toggle.props.d.ts +51 -0
- package/dist/components/toggle/toggle.props.js +29 -0
- package/dist/components/toggle/toggle.slots.d.ts +26 -0
- package/dist/components/toggle/toggle.slots.js +36 -0
- package/dist/components/toolbar/index.d.ts +3 -0
- package/dist/components/toolbar/toolbar.context.js +23 -0
- package/dist/components/toolbar/toolbar.d.ts +218 -0
- package/dist/components/toolbar/toolbar.js +197 -0
- package/dist/components/toolbar/toolbar.props.d.ts +54 -0
- package/dist/components/toolbar/toolbar.props.js +55 -0
- package/dist/components/toolbar/toolbar.slots.d.ts +24 -0
- package/dist/components/toolbar/toolbar.slots.js +37 -0
- package/dist/components/toolbar/toolbar.types.d.ts +15 -0
- package/dist/components/tooltip/index.d.ts +2 -0
- package/dist/components/tooltip/tooltip.d.ts +170 -0
- package/dist/components/tooltip/tooltip.js +143 -0
- package/dist/components/tooltip/tooltip.props.d.ts +36 -0
- package/dist/components/tooltip/tooltip.props.js +42 -0
- package/dist/components/tooltip/tooltip.slots.d.ts +26 -0
- package/dist/components/tooltip/tooltip.slots.js +42 -0
- package/dist/core/derive-threshold-tone.js +35 -0
- package/dist/core/merge-class-name.d.ts +17 -0
- package/dist/core/merge-class-name.js +16 -0
- package/dist/core/noctis-provider.d.ts +38 -0
- package/dist/core/noctis-provider.js +44 -0
- package/dist/core/primitive/index.d.ts +1 -0
- package/dist/core/primitive/primitive.d.ts +44 -0
- package/dist/core/primitive/primitive.js +27 -0
- package/dist/core/radius-scope/index.d.ts +2 -0
- package/dist/core/radius-scope/radius-scope.d.ts +43 -0
- package/dist/core/radius-scope/radius-scope.js +36 -0
- package/dist/core/radius-scope/radius-scope.styles.d.ts +13 -0
- package/dist/core/radius-scope/radius-scope.styles.js +11 -0
- package/dist/core/render.d.ts +24 -0
- package/dist/core/render.js +12 -0
- package/dist/core/use-copy.d.ts +13 -0
- package/dist/core/use-copy.js +30 -0
- package/dist/core/use-injected-labels.js +55 -0
- package/dist/core/use-reduced-motion.d.ts +9 -0
- package/dist/core/use-reduced-motion.js +26 -0
- package/dist/core/visually-hidden/index.d.ts +1 -0
- package/dist/core/visually-hidden/visually-hidden.d.ts +24 -0
- package/dist/core/visually-hidden/visually-hidden.js +19 -0
- package/dist/i18n/default-messages.d.ts +12 -0
- package/dist/i18n/default-messages.js +10 -0
- package/dist/i18n/index.d.ts +2 -0
- package/dist/i18n/index.js +2 -0
- package/dist/i18n/messages/index.d.ts +2 -0
- package/dist/i18n/messages/index.js +2 -0
- package/dist/icons/glyphs.d.ts +2 -0
- package/dist/icons/glyphs.js +2 -0
- package/dist/icons/icon.d.ts +40 -0
- package/dist/icons/icon.js +26 -0
- package/dist/icons/icon.styles.d.ts +9 -0
- package/dist/icons/index.d.ts +3 -0
- package/dist/index.d.ts +126 -0
- package/dist/index.js +112 -0
- package/dist/primitives/accordion.d.ts +7 -0
- package/dist/primitives/accordion.js +8 -0
- package/dist/primitives/alert-dialog.d.ts +7 -0
- package/dist/primitives/alert-dialog.js +8 -0
- package/dist/primitives/autocomplete/autocomplete.d.ts +58 -0
- package/dist/primitives/autocomplete/autocomplete.js +58 -0
- package/dist/primitives/autocomplete/index.d.ts +1 -0
- package/dist/primitives/autocomplete.d.ts +2 -0
- package/dist/primitives/autocomplete.js +2 -0
- package/dist/primitives/avatar.d.ts +7 -0
- package/dist/primitives/avatar.js +8 -0
- package/dist/primitives/button.d.ts +7 -0
- package/dist/primitives/button.js +8 -0
- package/dist/primitives/checkbox-group.d.ts +7 -0
- package/dist/primitives/checkbox-group.js +8 -0
- package/dist/primitives/checkbox.d.ts +7 -0
- package/dist/primitives/checkbox.js +8 -0
- package/dist/primitives/collapsible.d.ts +7 -0
- package/dist/primitives/collapsible.js +8 -0
- package/dist/primitives/combobox/combobox.d.ts +71 -0
- package/dist/primitives/combobox/combobox.js +66 -0
- package/dist/primitives/combobox/index.d.ts +1 -0
- package/dist/primitives/combobox.d.ts +2 -0
- package/dist/primitives/combobox.js +2 -0
- package/dist/primitives/context-menu.d.ts +7 -0
- package/dist/primitives/context-menu.js +8 -0
- package/dist/primitives/csp-provider.d.ts +1 -0
- package/dist/primitives/csp-provider.js +2 -0
- package/dist/primitives/dialog.d.ts +7 -0
- package/dist/primitives/dialog.js +8 -0
- package/dist/primitives/direction-provider.d.ts +1 -0
- package/dist/primitives/direction-provider.js +8 -0
- package/dist/primitives/drawer.d.ts +1 -0
- package/dist/primitives/drawer.js +2 -0
- package/dist/primitives/field.d.ts +7 -0
- package/dist/primitives/field.js +8 -0
- package/dist/primitives/fieldset.d.ts +7 -0
- package/dist/primitives/fieldset.js +8 -0
- package/dist/primitives/form.d.ts +7 -0
- package/dist/primitives/form.js +8 -0
- package/dist/primitives/index.d.ts +79 -0
- package/dist/primitives/index.js +113 -0
- package/dist/primitives/input.d.ts +7 -0
- package/dist/primitives/input.js +8 -0
- package/dist/primitives/menu.d.ts +7 -0
- package/dist/primitives/menu.js +8 -0
- package/dist/primitives/menubar.d.ts +7 -0
- package/dist/primitives/menubar.js +8 -0
- package/dist/primitives/meter/index.d.ts +1 -0
- package/dist/primitives/meter/meter.d.ts +56 -0
- package/dist/primitives/meter/meter.js +59 -0
- package/dist/primitives/meter.d.ts +2 -0
- package/dist/primitives/meter.js +2 -0
- package/dist/primitives/navigation-menu.d.ts +7 -0
- package/dist/primitives/navigation-menu.js +8 -0
- package/dist/primitives/number-field/context.d.ts +13 -0
- package/dist/primitives/number-field/context.js +36 -0
- package/dist/primitives/number-field/index.d.ts +2 -0
- package/dist/primitives/number-field/number-field.d.ts +90 -0
- package/dist/primitives/number-field/number-field.js +107 -0
- package/dist/primitives/number-field.d.ts +3 -0
- package/dist/primitives/number-field.js +2 -0
- package/dist/primitives/otp-field.d.ts +7 -0
- package/dist/primitives/otp-field.js +8 -0
- package/dist/primitives/popover.d.ts +7 -0
- package/dist/primitives/popover.js +8 -0
- package/dist/primitives/preview-card.d.ts +7 -0
- package/dist/primitives/preview-card.js +8 -0
- package/dist/primitives/progress/index.d.ts +1 -0
- package/dist/primitives/progress/progress.d.ts +56 -0
- package/dist/primitives/progress/progress.js +59 -0
- package/dist/primitives/progress.d.ts +2 -0
- package/dist/primitives/progress.js +2 -0
- package/dist/primitives/radio-group.d.ts +7 -0
- package/dist/primitives/radio-group.js +8 -0
- package/dist/primitives/radio.d.ts +7 -0
- package/dist/primitives/radio.js +8 -0
- package/dist/primitives/scroll-area.d.ts +7 -0
- package/dist/primitives/scroll-area.js +8 -0
- package/dist/primitives/select.d.ts +7 -0
- package/dist/primitives/select.js +8 -0
- package/dist/primitives/separator.d.ts +7 -0
- package/dist/primitives/separator.js +8 -0
- package/dist/primitives/slider/context.d.ts +12 -0
- package/dist/primitives/slider/context.js +18 -0
- package/dist/primitives/slider/index.d.ts +2 -0
- package/dist/primitives/slider/slider.d.ts +83 -0
- package/dist/primitives/slider/slider.js +99 -0
- package/dist/primitives/slider.d.ts +3 -0
- package/dist/primitives/slider.js +2 -0
- package/dist/primitives/switch.d.ts +1 -0
- package/dist/primitives/switch.js +2 -0
- package/dist/primitives/tabs.d.ts +7 -0
- package/dist/primitives/tabs.js +8 -0
- package/dist/primitives/toast/context.d.ts +11 -0
- package/dist/primitives/toast/context.js +18 -0
- package/dist/primitives/toast/index.d.ts +2 -0
- package/dist/primitives/toast/toast.d.ts +122 -0
- package/dist/primitives/toast/toast.js +133 -0
- package/dist/primitives/toast.d.ts +3 -0
- package/dist/primitives/toast.js +2 -0
- package/dist/primitives/toggle-group.d.ts +7 -0
- package/dist/primitives/toggle-group.js +8 -0
- package/dist/primitives/toggle.d.ts +7 -0
- package/dist/primitives/toggle.js +8 -0
- package/dist/primitives/toolbar.d.ts +7 -0
- package/dist/primitives/toolbar.js +8 -0
- package/dist/primitives/tooltip.d.ts +7 -0
- package/dist/primitives/tooltip.js +8 -0
- package/dist/props.d.ts +46 -0
- package/dist/props.js +46 -0
- package/dist/styles.css +11513 -0
- package/dist/tailwind/cn.d.ts +33 -0
- package/dist/tailwind/cn.js +42 -0
- package/dist/tailwind/index.d.ts +3 -0
- package/dist/tailwind/index.js +3 -0
- package/dist/tailwind/tv.d.ts +20 -0
- package/dist/tailwind/tv.js +11 -0
- package/dist/tailwind.css +485 -0
- package/dist/theme/react.d.ts +1 -0
- package/dist/theme/react.js +1 -0
- package/dist/theme.d.ts +1 -0
- package/dist/theme.js +1 -0
- package/dist/tokens/react.d.ts +1 -0
- package/dist/tokens/react.js +1 -0
- package/dist/tokens.d.ts +1 -0
- package/dist/tokens.js +1 -0
- package/package.json +121 -0
|
@@ -0,0 +1,98 @@
|
|
|
1
|
+
//#region src/components/navigation-menu/navigation-menu.props.d.ts
|
|
2
|
+
/** A spreadable data-attribute prop bag — the shape every `NavigationMenu.*.props()` returns. */
|
|
3
|
+
type NavigationMenuPartProps = {
|
|
4
|
+
/** The slot value the matching `navigation-menu.css` rules anchor on. */"data-slot": string; /** Forwarded verbatim — styling is attribute-driven, so this is an optional consumer passthrough. */
|
|
5
|
+
className?: string; /** A data-attribute present (empty string) or absent (`undefined`); never `false`. */
|
|
6
|
+
[attr: `data-${string}`]: string | undefined;
|
|
7
|
+
};
|
|
8
|
+
/** Common shape: every part's `.props()` accepts an optional `className` passthrough. */
|
|
9
|
+
interface BasePropsArgs {
|
|
10
|
+
/** Forwarded verbatim onto the returned prop bag. */
|
|
11
|
+
className?: string;
|
|
12
|
+
}
|
|
13
|
+
/** Argument to `NavigationMenu.Trigger.props(...)` — the states the CSS keys the bar item's look off. */
|
|
14
|
+
interface NavigationMenuTriggerPropsArgs extends BasePropsArgs {
|
|
15
|
+
/** Whether this trigger's flyout is open (drives the lit look via `data-popup-open`). */
|
|
16
|
+
open?: boolean;
|
|
17
|
+
/** Whether this trigger owns the current section — keeps the fill when closed (`data-current`). */
|
|
18
|
+
current?: boolean;
|
|
19
|
+
/** Whether this trigger is disabled — dims it and drops the hover/open fill (`data-disabled`). */
|
|
20
|
+
disabled?: boolean;
|
|
21
|
+
}
|
|
22
|
+
/** Argument to `NavigationMenu.Link.props(...)` — the states the CSS keys the link's marks off. */
|
|
23
|
+
interface NavigationMenuLinkPropsArgs extends BasePropsArgs {
|
|
24
|
+
/** Whether this link marks the current page (drives the active look via `data-active`). */
|
|
25
|
+
active?: boolean;
|
|
26
|
+
/** Whether this bar link owns the current section — keeps the fill when closed (`data-current`). */
|
|
27
|
+
current?: boolean;
|
|
28
|
+
/** Whether this link is disabled — dims it and drops the hover fill (`data-disabled`). */
|
|
29
|
+
disabled?: boolean;
|
|
30
|
+
}
|
|
31
|
+
/** Argument to `NavigationMenu.Root.props(...)` — the bar's control density. */
|
|
32
|
+
interface NavigationMenuRootPropsArgs extends BasePropsArgs {
|
|
33
|
+
/** The bar's control density; re-points the bar item metrics via `data-size`. */
|
|
34
|
+
size?: "md" | "sm";
|
|
35
|
+
}
|
|
36
|
+
/** Argument to a stateless part's `.props(...)` — no state of its own. */
|
|
37
|
+
type NavigationMenuStatelessPropsArgs = BasePropsArgs;
|
|
38
|
+
/** Root prop bag: slot anchor plus the `data-size` density stamp. */
|
|
39
|
+
declare function rootProps({
|
|
40
|
+
size,
|
|
41
|
+
className
|
|
42
|
+
}?: NavigationMenuRootPropsArgs): NavigationMenuPartProps;
|
|
43
|
+
/** List prop bag: just the slot anchor. */
|
|
44
|
+
declare function listProps({
|
|
45
|
+
className
|
|
46
|
+
}?: NavigationMenuStatelessPropsArgs): NavigationMenuPartProps;
|
|
47
|
+
/** Item prop bag: just the slot anchor. */
|
|
48
|
+
declare function itemProps({
|
|
49
|
+
className
|
|
50
|
+
}?: NavigationMenuStatelessPropsArgs): NavigationMenuPartProps;
|
|
51
|
+
/** Trigger prop bag: slot anchor plus the lit (`data-popup-open`), current (`data-current`), and disabled marks. */
|
|
52
|
+
declare function triggerProps({
|
|
53
|
+
open,
|
|
54
|
+
current,
|
|
55
|
+
disabled,
|
|
56
|
+
className
|
|
57
|
+
}?: NavigationMenuTriggerPropsArgs): NavigationMenuPartProps;
|
|
58
|
+
/** Content prop bag: just the slot anchor. */
|
|
59
|
+
declare function contentProps({
|
|
60
|
+
className
|
|
61
|
+
}?: NavigationMenuStatelessPropsArgs): NavigationMenuPartProps;
|
|
62
|
+
/** Link prop bag: slot anchor plus the active-page (`data-active`), current-section (`data-current`), and disabled marks. */
|
|
63
|
+
declare function linkProps({
|
|
64
|
+
active,
|
|
65
|
+
current,
|
|
66
|
+
disabled,
|
|
67
|
+
className
|
|
68
|
+
}?: NavigationMenuLinkPropsArgs): NavigationMenuPartProps;
|
|
69
|
+
/** Link title prop bag: just the slot anchor (the bold first line of a two-line panel link). */
|
|
70
|
+
declare function linkTitleProps({
|
|
71
|
+
className
|
|
72
|
+
}?: NavigationMenuStatelessPropsArgs): NavigationMenuPartProps;
|
|
73
|
+
/** Link description prop bag: just the slot anchor (the muted supporting line of a two-line panel link). */
|
|
74
|
+
declare function linkDescriptionProps({
|
|
75
|
+
className
|
|
76
|
+
}?: NavigationMenuStatelessPropsArgs): NavigationMenuPartProps;
|
|
77
|
+
/** Section prop bag: just the slot anchor (a titled column group inside a panel). */
|
|
78
|
+
declare function sectionProps({
|
|
79
|
+
className
|
|
80
|
+
}?: NavigationMenuStatelessPropsArgs): NavigationMenuPartProps;
|
|
81
|
+
/** Section title prop bag: just the slot anchor (a section's heading label). */
|
|
82
|
+
declare function sectionTitleProps({
|
|
83
|
+
className
|
|
84
|
+
}?: NavigationMenuStatelessPropsArgs): NavigationMenuPartProps;
|
|
85
|
+
/** Separator prop bag: just the slot anchor (a sharp divider between panel groups). */
|
|
86
|
+
declare function separatorProps({
|
|
87
|
+
className
|
|
88
|
+
}?: NavigationMenuStatelessPropsArgs): NavigationMenuPartProps;
|
|
89
|
+
/** Footer prop bag: just the slot anchor (a panel's pinned "view all"/CTA row). */
|
|
90
|
+
declare function footerProps({
|
|
91
|
+
className
|
|
92
|
+
}?: NavigationMenuStatelessPropsArgs): NavigationMenuPartProps;
|
|
93
|
+
/** Viewport prop bag: just the slot anchor. */
|
|
94
|
+
declare function viewportProps({
|
|
95
|
+
className
|
|
96
|
+
}?: NavigationMenuStatelessPropsArgs): NavigationMenuPartProps;
|
|
97
|
+
//#endregion
|
|
98
|
+
export { NavigationMenuLinkPropsArgs, NavigationMenuPartProps, NavigationMenuRootPropsArgs, NavigationMenuTriggerPropsArgs, contentProps, footerProps, itemProps, linkDescriptionProps, linkProps, linkTitleProps, listProps, rootProps, sectionProps, sectionTitleProps, separatorProps, triggerProps, viewportProps };
|
|
@@ -0,0 +1,90 @@
|
|
|
1
|
+
import { NAVIGATION_MENU_SLOTS } from "./navigation-menu.slots.js";
|
|
2
|
+
//#region src/components/navigation-menu/navigation-menu.props.ts
|
|
3
|
+
/**
|
|
4
|
+
* The D12 unified variant contract for NavigationMenu — a per-part set of `props(...)` builders that
|
|
5
|
+
* each return a **spreadable props object** of the form
|
|
6
|
+
* `{ "data-slot": "noctis-navigation-menu-<part>", ...dataAttrs }`, derived from the part's state.
|
|
7
|
+
*
|
|
8
|
+
* Under the single-`data-slot` anchor model the `data-slot` is the only styling hook needed —
|
|
9
|
+
* `navigation-menu.css` keys every rule off it — so spreading a part's `props()` onto a *foreign*
|
|
10
|
+
* element styles it as that part:
|
|
11
|
+
*
|
|
12
|
+
* <a {...NavigationMenu.Link.props({ active: true })}>Docs</a>
|
|
13
|
+
* // → <a data-slot="noctis-navigation-menu-link" data-active="">
|
|
14
|
+
*
|
|
15
|
+
* The escape hatch carries no className (styling is attribute-driven); an optional `className`
|
|
16
|
+
* passthrough is accepted and forwarded verbatim.
|
|
17
|
+
*/
|
|
18
|
+
/** Stamp a boolean state as a bare data-attribute: present (`""`) when on, absent (`undefined`) when off. */
|
|
19
|
+
const flag = (on) => on ? "" : void 0;
|
|
20
|
+
const withClassName = (bag, className) => className === void 0 ? bag : {
|
|
21
|
+
...bag,
|
|
22
|
+
className
|
|
23
|
+
};
|
|
24
|
+
/** Root prop bag: slot anchor plus the `data-size` density stamp. */
|
|
25
|
+
function rootProps({ size, className } = {}) {
|
|
26
|
+
return withClassName({
|
|
27
|
+
"data-slot": NAVIGATION_MENU_SLOTS.root,
|
|
28
|
+
"data-size": size
|
|
29
|
+
}, className);
|
|
30
|
+
}
|
|
31
|
+
/** List prop bag: just the slot anchor. */
|
|
32
|
+
function listProps({ className } = {}) {
|
|
33
|
+
return withClassName({ "data-slot": NAVIGATION_MENU_SLOTS.list }, className);
|
|
34
|
+
}
|
|
35
|
+
/** Item prop bag: just the slot anchor. */
|
|
36
|
+
function itemProps({ className } = {}) {
|
|
37
|
+
return withClassName({ "data-slot": NAVIGATION_MENU_SLOTS.item }, className);
|
|
38
|
+
}
|
|
39
|
+
/** Trigger prop bag: slot anchor plus the lit (`data-popup-open`), current (`data-current`), and disabled marks. */
|
|
40
|
+
function triggerProps({ open, current, disabled, className } = {}) {
|
|
41
|
+
return withClassName({
|
|
42
|
+
"data-slot": NAVIGATION_MENU_SLOTS.trigger,
|
|
43
|
+
"data-popup-open": flag(open),
|
|
44
|
+
"data-current": flag(current),
|
|
45
|
+
"data-disabled": flag(disabled)
|
|
46
|
+
}, className);
|
|
47
|
+
}
|
|
48
|
+
/** Content prop bag: just the slot anchor. */
|
|
49
|
+
function contentProps({ className } = {}) {
|
|
50
|
+
return withClassName({ "data-slot": NAVIGATION_MENU_SLOTS.content }, className);
|
|
51
|
+
}
|
|
52
|
+
/** Link prop bag: slot anchor plus the active-page (`data-active`), current-section (`data-current`), and disabled marks. */
|
|
53
|
+
function linkProps({ active, current, disabled, className } = {}) {
|
|
54
|
+
return withClassName({
|
|
55
|
+
"data-slot": NAVIGATION_MENU_SLOTS.link,
|
|
56
|
+
"data-active": flag(active),
|
|
57
|
+
"data-current": flag(current),
|
|
58
|
+
"data-disabled": flag(disabled)
|
|
59
|
+
}, className);
|
|
60
|
+
}
|
|
61
|
+
/** Link title prop bag: just the slot anchor (the bold first line of a two-line panel link). */
|
|
62
|
+
function linkTitleProps({ className } = {}) {
|
|
63
|
+
return withClassName({ "data-slot": NAVIGATION_MENU_SLOTS.linkTitle }, className);
|
|
64
|
+
}
|
|
65
|
+
/** Link description prop bag: just the slot anchor (the muted supporting line of a two-line panel link). */
|
|
66
|
+
function linkDescriptionProps({ className } = {}) {
|
|
67
|
+
return withClassName({ "data-slot": NAVIGATION_MENU_SLOTS.linkDescription }, className);
|
|
68
|
+
}
|
|
69
|
+
/** Section prop bag: just the slot anchor (a titled column group inside a panel). */
|
|
70
|
+
function sectionProps({ className } = {}) {
|
|
71
|
+
return withClassName({ "data-slot": NAVIGATION_MENU_SLOTS.section }, className);
|
|
72
|
+
}
|
|
73
|
+
/** Section title prop bag: just the slot anchor (a section's heading label). */
|
|
74
|
+
function sectionTitleProps({ className } = {}) {
|
|
75
|
+
return withClassName({ "data-slot": NAVIGATION_MENU_SLOTS.sectionTitle }, className);
|
|
76
|
+
}
|
|
77
|
+
/** Separator prop bag: just the slot anchor (a sharp divider between panel groups). */
|
|
78
|
+
function separatorProps({ className } = {}) {
|
|
79
|
+
return withClassName({ "data-slot": NAVIGATION_MENU_SLOTS.separator }, className);
|
|
80
|
+
}
|
|
81
|
+
/** Footer prop bag: just the slot anchor (a panel's pinned "view all"/CTA row). */
|
|
82
|
+
function footerProps({ className } = {}) {
|
|
83
|
+
return withClassName({ "data-slot": NAVIGATION_MENU_SLOTS.footer }, className);
|
|
84
|
+
}
|
|
85
|
+
/** Viewport prop bag: just the slot anchor. */
|
|
86
|
+
function viewportProps({ className } = {}) {
|
|
87
|
+
return withClassName({ "data-slot": NAVIGATION_MENU_SLOTS.viewport }, className);
|
|
88
|
+
}
|
|
89
|
+
//#endregion
|
|
90
|
+
export { contentProps, footerProps, itemProps, linkDescriptionProps, linkProps, linkTitleProps, listProps, rootProps, sectionProps, sectionTitleProps, separatorProps, triggerProps, viewportProps };
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
//#region src/components/navigation-menu/navigation-menu.slots.d.ts
|
|
2
|
+
/**
|
|
3
|
+
* The `data-*` hooks `NavigationMenu` stamps on its parts, for host-side styling and tests. Slot
|
|
4
|
+
* values mark each rendered element; the state attributes are emitted by Base UI's NavigationMenu —
|
|
5
|
+
* pair a slot with a state to target, say, the trigger only while its flyout is open.
|
|
6
|
+
*/
|
|
7
|
+
declare enum NavigationMenuDataAttributes {
|
|
8
|
+
/** The root navigation element. */
|
|
9
|
+
slot = "data-slot",
|
|
10
|
+
/** Present on the popup, positioner, and content while the flyout is open. */
|
|
11
|
+
open = "data-open",
|
|
12
|
+
/** Present on a trigger while its flyout is open — drives the lit look and the chevron rotation. */
|
|
13
|
+
popupOpen = "data-popup-open",
|
|
14
|
+
/** Present on the trigger/bar-link of the section the current page lives under — the persistent "you are here" at the top level (fill survives panel close). */
|
|
15
|
+
current = "data-current",
|
|
16
|
+
/** Present on a disabled trigger/bar-link — dims it and suppresses the hover/open fill. */
|
|
17
|
+
disabled = "data-disabled",
|
|
18
|
+
/** The bar's control density (`md`/`sm`), stamped on the root to re-point the bar item metrics. */
|
|
19
|
+
size = "data-size",
|
|
20
|
+
/** Present on the link that marks the current page. */
|
|
21
|
+
active = "data-active",
|
|
22
|
+
/** The side of the anchor the popup actually rendered on (`bottom`, `top`, …). */
|
|
23
|
+
side = "data-side",
|
|
24
|
+
/** The direction the active content slid in from when switching panels (`left`/`right`/`up`/`down`). */
|
|
25
|
+
activationDirection = "data-activation-direction",
|
|
26
|
+
/** Present on the popup/content for the first frame after mount — the transition's start state. */
|
|
27
|
+
startingStyle = "data-starting-style",
|
|
28
|
+
/** Present on the popup/content while it transitions out before unmounting. */
|
|
29
|
+
endingStyle = "data-ending-style",
|
|
30
|
+
/** The orientation of the navigation bar (`horizontal`/`vertical`). */
|
|
31
|
+
orientation = "data-orientation"
|
|
32
|
+
}
|
|
33
|
+
//#endregion
|
|
34
|
+
export { NavigationMenuDataAttributes };
|
|
@@ -0,0 +1,60 @@
|
|
|
1
|
+
//#region src/components/navigation-menu/navigation-menu.slots.ts
|
|
2
|
+
/**
|
|
3
|
+
* The slot vocabulary every `NavigationMenu` part stamps as its `data-slot`. The authored source the
|
|
4
|
+
* orchestration file reads from, prefixed `noctis-{component}-{part}` (the precompiled
|
|
5
|
+
* `navigation-menu.css` keys every rule off these anchors); SLOTS.md still generates from the
|
|
6
|
+
* token-graph declaration.
|
|
7
|
+
*/
|
|
8
|
+
const NAVIGATION_MENU_SLOTS = {
|
|
9
|
+
root: "noctis-navigation-menu",
|
|
10
|
+
list: "noctis-navigation-menu-list",
|
|
11
|
+
item: "noctis-navigation-menu-item",
|
|
12
|
+
trigger: "noctis-navigation-menu-trigger",
|
|
13
|
+
icon: "noctis-navigation-menu-icon",
|
|
14
|
+
content: "noctis-navigation-menu-content",
|
|
15
|
+
link: "noctis-navigation-menu-link",
|
|
16
|
+
linkTitle: "noctis-navigation-menu-link-title",
|
|
17
|
+
linkDescription: "noctis-navigation-menu-link-description",
|
|
18
|
+
section: "noctis-navigation-menu-section",
|
|
19
|
+
sectionTitle: "noctis-navigation-menu-section-title",
|
|
20
|
+
separator: "noctis-navigation-menu-separator",
|
|
21
|
+
footer: "noctis-navigation-menu-footer",
|
|
22
|
+
positioner: "noctis-navigation-menu-positioner",
|
|
23
|
+
popup: "noctis-navigation-menu-popup",
|
|
24
|
+
backdrop: "noctis-navigation-menu-backdrop",
|
|
25
|
+
viewport: "noctis-navigation-menu-viewport"
|
|
26
|
+
};
|
|
27
|
+
/**
|
|
28
|
+
* The `data-*` hooks `NavigationMenu` stamps on its parts, for host-side styling and tests. Slot
|
|
29
|
+
* values mark each rendered element; the state attributes are emitted by Base UI's NavigationMenu —
|
|
30
|
+
* pair a slot with a state to target, say, the trigger only while its flyout is open.
|
|
31
|
+
*/
|
|
32
|
+
let NavigationMenuDataAttributes = /* @__PURE__ */ function(NavigationMenuDataAttributes) {
|
|
33
|
+
/** The root navigation element. */
|
|
34
|
+
NavigationMenuDataAttributes["slot"] = "data-slot";
|
|
35
|
+
/** Present on the popup, positioner, and content while the flyout is open. */
|
|
36
|
+
NavigationMenuDataAttributes["open"] = "data-open";
|
|
37
|
+
/** Present on a trigger while its flyout is open — drives the lit look and the chevron rotation. */
|
|
38
|
+
NavigationMenuDataAttributes["popupOpen"] = "data-popup-open";
|
|
39
|
+
/** Present on the trigger/bar-link of the section the current page lives under — the persistent "you are here" at the top level (fill survives panel close). */
|
|
40
|
+
NavigationMenuDataAttributes["current"] = "data-current";
|
|
41
|
+
/** Present on a disabled trigger/bar-link — dims it and suppresses the hover/open fill. */
|
|
42
|
+
NavigationMenuDataAttributes["disabled"] = "data-disabled";
|
|
43
|
+
/** The bar's control density (`md`/`sm`), stamped on the root to re-point the bar item metrics. */
|
|
44
|
+
NavigationMenuDataAttributes["size"] = "data-size";
|
|
45
|
+
/** Present on the link that marks the current page. */
|
|
46
|
+
NavigationMenuDataAttributes["active"] = "data-active";
|
|
47
|
+
/** The side of the anchor the popup actually rendered on (`bottom`, `top`, …). */
|
|
48
|
+
NavigationMenuDataAttributes["side"] = "data-side";
|
|
49
|
+
/** The direction the active content slid in from when switching panels (`left`/`right`/`up`/`down`). */
|
|
50
|
+
NavigationMenuDataAttributes["activationDirection"] = "data-activation-direction";
|
|
51
|
+
/** Present on the popup/content for the first frame after mount — the transition's start state. */
|
|
52
|
+
NavigationMenuDataAttributes["startingStyle"] = "data-starting-style";
|
|
53
|
+
/** Present on the popup/content while it transitions out before unmounting. */
|
|
54
|
+
NavigationMenuDataAttributes["endingStyle"] = "data-ending-style";
|
|
55
|
+
/** The orientation of the navigation bar (`horizontal`/`vertical`). */
|
|
56
|
+
NavigationMenuDataAttributes["orientation"] = "data-orientation";
|
|
57
|
+
return NavigationMenuDataAttributes;
|
|
58
|
+
}({});
|
|
59
|
+
//#endregion
|
|
60
|
+
export { NAVIGATION_MENU_SLOTS, NavigationMenuDataAttributes };
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
//#region src/components/number-field/number-field.context.d.ts
|
|
2
|
+
/** Control height and type — `md` or `lg`. */
|
|
3
|
+
type NumberFieldSize = "md" | "lg";
|
|
4
|
+
/**
|
|
5
|
+
* Stepper layout — where the increment/decrement buttons sit.
|
|
6
|
+
* - `end` (default): a horizontal decrement/increment pair grouped at the inline end.
|
|
7
|
+
* - `split`: decrement at the inline start, increment at the inline end, flanking the value.
|
|
8
|
+
* - `stacked`: both stacked as a sharp block at the inline end (increment top, decrement bottom).
|
|
9
|
+
* - `none`: no stepper buttons — the input only (arrow keys and scrubbing still step the value).
|
|
10
|
+
*/
|
|
11
|
+
type NumberFieldSteppers = "end" | "split" | "stacked" | "none";
|
|
12
|
+
//#endregion
|
|
13
|
+
export { NumberFieldSize, NumberFieldSteppers };
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
import { createContext, use } from "react";
|
|
3
|
+
//#region src/components/number-field/number-field.context.ts
|
|
4
|
+
const NumberFieldContext = createContext(null);
|
|
5
|
+
const NumberFieldProvider = NumberFieldContext.Provider;
|
|
6
|
+
/** Read the field context, throwing a named error when a part renders outside `NumberField.Root`. */
|
|
7
|
+
function useNumberFieldContext(part) {
|
|
8
|
+
const context = use(NumberFieldContext);
|
|
9
|
+
if (context === null) throw new Error(`NumberField.${part} must be rendered inside <NumberField.Root>.`);
|
|
10
|
+
return context;
|
|
11
|
+
}
|
|
12
|
+
//#endregion
|
|
13
|
+
export { NumberFieldProvider, useNumberFieldContext };
|
|
@@ -0,0 +1,197 @@
|
|
|
1
|
+
import { NumberField as NumberField$1 } from "../../primitives/number-field/number-field.js";
|
|
2
|
+
import { NumberFieldSize, NumberFieldSteppers } from "./number-field.context.js";
|
|
3
|
+
import { NumberFieldPartProps, NumberFieldRootPropsArgs, decrementProps, groupProps, incrementProps, inputProps, prefixProps, rootProps, scrubAreaCursorProps, scrubAreaProps, suffixProps } from "./number-field.props.js";
|
|
4
|
+
import { ComponentProps, ReactElement, ReactNode } from "react";
|
|
5
|
+
|
|
6
|
+
//#region src/components/number-field/number-field.d.ts
|
|
7
|
+
/**
|
|
8
|
+
* Owns the numeric value and shares the control `size` with the field's parts. Works controlled
|
|
9
|
+
* (`value` + `onValueChange`) or uncontrolled (`defaultValue`). The wrapped primitive auto-injects the
|
|
10
|
+
* active locale (so the value formats for the reader — Persian numerals under `fa`, grouping per
|
|
11
|
+
* locale) and the translated assistive labels; pass `locale` or `labels` to override. Compose
|
|
12
|
+
* `NumberField.Group` holding the `NumberField.Input` and the `NumberField.Decrement` /
|
|
13
|
+
* `NumberField.Increment` steppers.
|
|
14
|
+
*/
|
|
15
|
+
declare function NumberFieldRoot({
|
|
16
|
+
size,
|
|
17
|
+
steppers,
|
|
18
|
+
className,
|
|
19
|
+
children,
|
|
20
|
+
...props
|
|
21
|
+
}: NumberField.Root.Props): ReactElement;
|
|
22
|
+
/**
|
|
23
|
+
* The bordered field shell wrapping the input, affixes, and steppers — wears the field look and carries
|
|
24
|
+
* the stepper layout (`data-steppers`) the CSS branches off, inherited from the root's `steppers`.
|
|
25
|
+
*/
|
|
26
|
+
declare function NumberFieldGroup({
|
|
27
|
+
className,
|
|
28
|
+
...props
|
|
29
|
+
}: NumberField.Group.Props): ReactElement;
|
|
30
|
+
/** The numeric input — borderless inside the shell, carrying the field type and derived mobile keypad. */
|
|
31
|
+
declare function NumberFieldInput({
|
|
32
|
+
className,
|
|
33
|
+
...props
|
|
34
|
+
}: NumberField.Input.Props): ReactElement;
|
|
35
|
+
/**
|
|
36
|
+
* A leading affix — a quiet, non-interactive unit hint (`$`, `€`) seated inside the shell before the
|
|
37
|
+
* value. Visual chrome only: it never changes the committed value (that is `format`'s job).
|
|
38
|
+
*/
|
|
39
|
+
declare function NumberFieldPrefix({
|
|
40
|
+
className,
|
|
41
|
+
...props
|
|
42
|
+
}: NumberField.Prefix.Props): ReactElement;
|
|
43
|
+
/**
|
|
44
|
+
* A trailing affix — a quiet, non-interactive unit hint (`px`, `kg`, `%`) seated inside the shell after
|
|
45
|
+
* the value. Visual chrome only: it never changes the committed value (that is `format`'s job).
|
|
46
|
+
*/
|
|
47
|
+
declare function NumberFieldSuffix({
|
|
48
|
+
className,
|
|
49
|
+
...props
|
|
50
|
+
}: NumberField.Suffix.Props): ReactElement;
|
|
51
|
+
/**
|
|
52
|
+
* The up stepper — a ghost icon button whose placement follows the `steppers` layout. Defaults to a plus
|
|
53
|
+
* glyph; pass `children` to replace it. The accessible name comes from the translated `increase` label.
|
|
54
|
+
*/
|
|
55
|
+
declare function NumberFieldIncrement({
|
|
56
|
+
className,
|
|
57
|
+
children,
|
|
58
|
+
...props
|
|
59
|
+
}: NumberField.Increment.Props): ReactElement;
|
|
60
|
+
/**
|
|
61
|
+
* The down stepper — a ghost icon button whose placement follows the `steppers` layout. Defaults to a
|
|
62
|
+
* minus glyph; pass `children` to replace it. The accessible name comes from the translated `decrease` label.
|
|
63
|
+
*/
|
|
64
|
+
declare function NumberFieldDecrement({
|
|
65
|
+
className,
|
|
66
|
+
children,
|
|
67
|
+
...props
|
|
68
|
+
}: NumberField.Decrement.Props): ReactElement;
|
|
69
|
+
/**
|
|
70
|
+
* A draggable region that scrubs the value by horizontal pointer movement — wrap a label or icon to make
|
|
71
|
+
* it the drag handle. Pointer-precision is opt-in via Base UI's `pixelSensitivity` / `direction`.
|
|
72
|
+
*/
|
|
73
|
+
declare function NumberFieldScrubArea({
|
|
74
|
+
className,
|
|
75
|
+
...props
|
|
76
|
+
}: NumberField.ScrubArea.Props): ReactElement;
|
|
77
|
+
/**
|
|
78
|
+
* The virtual cursor that follows the pointer while scrubbing — a small inverse block (the Resolve/Figma
|
|
79
|
+
* feel). Render it inside a `NumberField.ScrubArea`; Base UI shows it only during the drag and tracks the
|
|
80
|
+
* pointer 1:1. Pair with `pixelSensitivity` on the scrub area to tune the drag-to-value ratio.
|
|
81
|
+
*/
|
|
82
|
+
declare function NumberFieldScrubAreaCursor({
|
|
83
|
+
className,
|
|
84
|
+
...props
|
|
85
|
+
}: NumberField.ScrubAreaCursor.Props): ReactElement;
|
|
86
|
+
/**
|
|
87
|
+
* A numeric input with stepper buttons, keyboard arrows, and pointer scrubbing, built on Base UI's
|
|
88
|
+
* NumberField. The field shell wears the field look (`bg-field` / `border-field`, focus ring on the
|
|
89
|
+
* shell), the input is borderless inside it, and the steppers are ghost icon buttons that compose the
|
|
90
|
+
* {@link Button} look. The wrapper injects the active locale (so the value formats for the reader) and
|
|
91
|
+
* translates the steppers' and input's assistive text; per-instance `labels` / `aria-label` always win.
|
|
92
|
+
* Two sizes (`md` / `lg`) share the control rhythm. RTL-aware and respects `prefers-reduced-motion`.
|
|
93
|
+
*
|
|
94
|
+
* Compose from parts: `NumberField.Root` owns the value, the shared `size`, and the `steppers` layout
|
|
95
|
+
* (`end` by default — a horizontal −/+ pair at the inline end; `split` flanks the value; `stacked` blocks
|
|
96
|
+
* them in a column; `none` drops them). `NumberField.Group` is the bordered shell holding the optional `NumberField.Prefix` /
|
|
97
|
+
* `NumberField.Suffix` affixes, the `NumberField.Input`, and the `NumberField.Decrement` /
|
|
98
|
+
* `NumberField.Increment` steppers. The runtime compound is a plain object (kept tree-shakeable);
|
|
99
|
+
* per-part prop and state types are exposed through the matching `NumberField` namespace —
|
|
100
|
+
* e.g. `NumberField.Input.Props`.
|
|
101
|
+
*/
|
|
102
|
+
declare const NumberField: {
|
|
103
|
+
/** Owns the value, the shared size, and the stepper layout. `NumberField.Root.props({ size })` → its spreadable prop bag. */Root: typeof NumberFieldRoot & {
|
|
104
|
+
props: typeof rootProps;
|
|
105
|
+
}; /** The bordered field shell. `NumberField.Group.props({ steppers })` → its spreadable prop bag. */
|
|
106
|
+
Group: typeof NumberFieldGroup & {
|
|
107
|
+
props: typeof groupProps;
|
|
108
|
+
}; /** The numeric input. `NumberField.Input.props()` → its spreadable prop bag. */
|
|
109
|
+
Input: typeof NumberFieldInput & {
|
|
110
|
+
props: typeof inputProps;
|
|
111
|
+
}; /** A leading unit-hint affix. `NumberField.Prefix.props()` → its spreadable prop bag. */
|
|
112
|
+
Prefix: typeof NumberFieldPrefix & {
|
|
113
|
+
props: typeof prefixProps;
|
|
114
|
+
}; /** A trailing unit-hint affix. `NumberField.Suffix.props()` → its spreadable prop bag. */
|
|
115
|
+
Suffix: typeof NumberFieldSuffix & {
|
|
116
|
+
props: typeof suffixProps;
|
|
117
|
+
}; /** The down stepper. `NumberField.Decrement.props()` → its spreadable prop bag. */
|
|
118
|
+
Decrement: typeof NumberFieldDecrement & {
|
|
119
|
+
props: typeof decrementProps;
|
|
120
|
+
}; /** The up stepper. `NumberField.Increment.props()` → its spreadable prop bag. */
|
|
121
|
+
Increment: typeof NumberFieldIncrement & {
|
|
122
|
+
props: typeof incrementProps;
|
|
123
|
+
}; /** The pointer-scrub region. `NumberField.ScrubArea.props()` → its spreadable prop bag. */
|
|
124
|
+
ScrubArea: typeof NumberFieldScrubArea & {
|
|
125
|
+
props: typeof scrubAreaProps;
|
|
126
|
+
}; /** The virtual scrub cursor. `NumberField.ScrubAreaCursor.props()` → its spreadable prop bag. */
|
|
127
|
+
ScrubAreaCursor: typeof NumberFieldScrubAreaCursor & {
|
|
128
|
+
props: typeof scrubAreaCursorProps;
|
|
129
|
+
};
|
|
130
|
+
};
|
|
131
|
+
/**
|
|
132
|
+
* Per-part prop and state types, mirroring Base UI's `Component.Part.Props` convention. Types-only — it
|
|
133
|
+
* emits no runtime code and merges with the `NumberField` object above, so `NumberField.Input` is the
|
|
134
|
+
* component value while `NumberField.Input.Props` is its prop type.
|
|
135
|
+
*/
|
|
136
|
+
declare namespace NumberField {
|
|
137
|
+
/** Control height and type — `md` or `lg`. */
|
|
138
|
+
type Size = NumberFieldSize;
|
|
139
|
+
/** Stepper layout — `end` (default), `split`, `stacked`, or `none`. */
|
|
140
|
+
type Steppers = NumberFieldSteppers;
|
|
141
|
+
/** The spreadable data-attribute prop bag every `NumberField.*.props()` returns (D12). */
|
|
142
|
+
type PartProps = NumberFieldPartProps;
|
|
143
|
+
namespace Root {
|
|
144
|
+
type Props = Omit<NumberField$1.Root.Props, "className" | "children"> & {
|
|
145
|
+
/**
|
|
146
|
+
* Control height and type.
|
|
147
|
+
* @default "md"
|
|
148
|
+
*/
|
|
149
|
+
size?: NumberFieldSize;
|
|
150
|
+
/**
|
|
151
|
+
* Where the increment/decrement steppers sit — `end` (a horizontal −/+ pair at the inline
|
|
152
|
+
* end), `split` (flanking the value), `stacked` (a sharp block stacked at the inline end), or
|
|
153
|
+
* `none` (no buttons; arrows and scrubbing still step).
|
|
154
|
+
* @default "end"
|
|
155
|
+
*/
|
|
156
|
+
steppers?: NumberFieldSteppers; /** `NumberField.Group` (the shell) and any scrub label. */
|
|
157
|
+
children?: ReactNode; /** Classes merged onto the root. */
|
|
158
|
+
className?: string;
|
|
159
|
+
};
|
|
160
|
+
/** Argument to the `NumberField.Root.props(...)` escape-hatch helper. */
|
|
161
|
+
type PropsArgs = NumberFieldRootPropsArgs;
|
|
162
|
+
}
|
|
163
|
+
namespace Group {
|
|
164
|
+
type Props = NumberField$1.Group.Props;
|
|
165
|
+
type State = NumberField$1.Group.State;
|
|
166
|
+
}
|
|
167
|
+
namespace Input {
|
|
168
|
+
type Props = NumberField$1.Input.Props;
|
|
169
|
+
type State = NumberField$1.Input.State;
|
|
170
|
+
}
|
|
171
|
+
namespace Prefix {
|
|
172
|
+
/** A leading affix is a plain inline element — any `<span>` props. */
|
|
173
|
+
type Props = ComponentProps<"span">;
|
|
174
|
+
}
|
|
175
|
+
namespace Suffix {
|
|
176
|
+
/** A trailing affix is a plain inline element — any `<span>` props. */
|
|
177
|
+
type Props = ComponentProps<"span">;
|
|
178
|
+
}
|
|
179
|
+
namespace Increment {
|
|
180
|
+
type Props = NumberField$1.Increment.Props;
|
|
181
|
+
type State = NumberField$1.Increment.State;
|
|
182
|
+
}
|
|
183
|
+
namespace Decrement {
|
|
184
|
+
type Props = NumberField$1.Decrement.Props;
|
|
185
|
+
type State = NumberField$1.Decrement.State;
|
|
186
|
+
}
|
|
187
|
+
namespace ScrubArea {
|
|
188
|
+
type Props = NumberField$1.ScrubArea.Props;
|
|
189
|
+
type State = NumberField$1.ScrubArea.State;
|
|
190
|
+
}
|
|
191
|
+
namespace ScrubAreaCursor {
|
|
192
|
+
type Props = NumberField$1.ScrubAreaCursor.Props;
|
|
193
|
+
type State = NumberField$1.ScrubAreaCursor.State;
|
|
194
|
+
}
|
|
195
|
+
}
|
|
196
|
+
//#endregion
|
|
197
|
+
export { NumberField };
|