asheeui 0.7.0 → 1.1.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 +61 -166
- package/dist/AsheeUIProvider.d.ts.map +1 -1
- package/dist/AsheeUIProvider.js +22 -15
- package/dist/components/accordion/Accordion.d.ts.map +1 -1
- package/dist/components/accordion/Accordion.js +9 -7
- package/dist/components/alert/Alert.d.ts +88 -0
- package/dist/components/alert/Alert.d.ts.map +1 -0
- package/dist/components/alert/Alert.js +61 -0
- package/dist/components/alert/alert-config.d.ts +56 -0
- package/dist/components/alert/alert-config.d.ts.map +1 -0
- package/dist/components/alert/alert-config.js +14 -0
- package/dist/components/alert/alert-styles.d.ts +32 -0
- package/dist/components/alert/alert-styles.d.ts.map +1 -0
- package/dist/components/alert/alert-styles.js +20 -0
- package/dist/components/alert/index.d.ts +3 -0
- package/dist/components/alert/index.d.ts.map +1 -0
- package/dist/components/alert/index.js +3 -0
- package/dist/components/auth-layout/AuthLayout.d.ts +79 -0
- package/dist/components/auth-layout/AuthLayout.d.ts.map +1 -0
- package/dist/components/auth-layout/AuthLayout.js +54 -0
- package/dist/components/auth-layout/auth-layout-config.d.ts +41 -0
- package/dist/components/auth-layout/auth-layout-config.d.ts.map +1 -0
- package/dist/components/auth-layout/auth-layout-config.js +18 -0
- package/dist/components/auth-layout/auth-layout-styles.d.ts +25 -0
- package/dist/components/auth-layout/auth-layout-styles.d.ts.map +1 -0
- package/dist/components/auth-layout/auth-layout-styles.js +11 -0
- package/dist/components/auth-layout/index.d.ts +3 -0
- package/dist/components/auth-layout/index.d.ts.map +1 -0
- package/dist/components/auth-layout/index.js +3 -0
- package/dist/components/autocomplete/Autocomplete.d.ts +6 -6
- package/dist/components/autocomplete/Autocomplete.d.ts.map +1 -1
- package/dist/components/autocomplete/Autocomplete.js +94 -58
- package/dist/components/autocomplete/autocomplete-config.d.ts +1 -1
- package/dist/components/autocomplete/autocomplete-config.d.ts.map +1 -1
- package/dist/components/avatar/Avatar.d.ts +87 -0
- package/dist/components/avatar/Avatar.d.ts.map +1 -0
- package/dist/components/avatar/Avatar.js +43 -0
- package/dist/components/avatar/avatar-config.d.ts +48 -0
- package/dist/components/avatar/avatar-config.d.ts.map +1 -0
- package/dist/components/avatar/avatar-config.js +14 -0
- package/dist/components/avatar/avatar-styles.d.ts +21 -0
- package/dist/components/avatar/avatar-styles.d.ts.map +1 -0
- package/dist/components/avatar/avatar-styles.js +13 -0
- package/dist/components/avatar/avatar.helpers.d.ts +19 -0
- package/dist/components/avatar/avatar.helpers.d.ts.map +1 -0
- package/dist/components/avatar/avatar.helpers.js +11 -0
- package/dist/components/avatar/index.d.ts +3 -0
- package/dist/components/avatar/index.d.ts.map +1 -0
- package/dist/components/avatar/index.js +4 -0
- package/dist/components/badge/Badge.d.ts +69 -0
- package/dist/components/badge/Badge.d.ts.map +1 -0
- package/dist/components/badge/Badge.js +39 -0
- package/dist/components/badge/badge-config.d.ts +63 -0
- package/dist/components/badge/badge-config.d.ts.map +1 -0
- package/dist/components/badge/badge-config.js +15 -0
- package/dist/components/badge/badge-styles.d.ts +27 -0
- package/dist/components/badge/badge-styles.d.ts.map +1 -0
- package/dist/components/badge/badge-styles.js +25 -0
- package/dist/components/badge/index.d.ts +3 -0
- package/dist/components/badge/index.d.ts.map +1 -0
- package/dist/components/badge/index.js +3 -0
- package/dist/components/breadcrumb/Breadcrumb.d.ts +106 -0
- package/dist/components/breadcrumb/Breadcrumb.d.ts.map +1 -0
- package/dist/components/breadcrumb/Breadcrumb.js +52 -0
- package/dist/components/breadcrumb/breadcrumb-config.d.ts +41 -0
- package/dist/components/breadcrumb/breadcrumb-config.d.ts.map +1 -0
- package/dist/components/breadcrumb/breadcrumb-config.js +10 -0
- package/dist/components/breadcrumb/breadcrumb-styles.d.ts +28 -0
- package/dist/components/breadcrumb/breadcrumb-styles.d.ts.map +1 -0
- package/dist/components/breadcrumb/breadcrumb-styles.js +17 -0
- package/dist/components/breadcrumb/index.d.ts +3 -0
- package/dist/components/breadcrumb/index.d.ts.map +1 -0
- package/dist/components/breadcrumb/index.js +3 -0
- package/dist/components/button/Button.d.ts.map +1 -1
- package/dist/components/button/Button.js +10 -7
- package/dist/components/{date-picker/DatePicker.d.ts → calendar/Calendar.d.ts} +21 -21
- package/dist/components/calendar/Calendar.d.ts.map +1 -0
- package/dist/components/{date-picker/DatePicker.js → calendar/Calendar.js} +12 -12
- package/dist/components/{date-picker/Calendar.d.ts → calendar/DateGrid.d.ts} +7 -7
- package/dist/components/calendar/DateGrid.d.ts.map +1 -0
- package/dist/components/calendar/DateGrid.js +194 -0
- package/dist/components/calendar/TimeSpinner.d.ts.map +1 -0
- package/dist/components/{date-picker → calendar}/TimeSpinner.js +3 -3
- package/dist/components/{date-picker/date-picker-config.d.ts → calendar/calendar-config.d.ts} +17 -17
- package/dist/components/calendar/calendar-config.d.ts.map +1 -0
- package/dist/components/{date-picker/date-picker-config.js → calendar/calendar-config.js} +3 -3
- package/dist/components/{date-picker/date-picker-styles.d.ts → calendar/calendar-styles.d.ts} +1 -1
- package/dist/components/calendar/calendar-styles.d.ts.map +1 -0
- package/dist/components/{date-picker/date-picker-styles.js → calendar/calendar-styles.js} +1 -1
- package/dist/components/{date-picker/date-picker.helpers.d.ts → calendar/calendar.helpers.d.ts} +9 -9
- package/dist/components/calendar/calendar.helpers.d.ts.map +1 -0
- package/dist/components/{date-picker/date-picker.helpers.js → calendar/calendar.helpers.js} +4 -4
- package/dist/components/calendar/index.d.ts +3 -0
- package/dist/components/calendar/index.d.ts.map +1 -0
- package/dist/components/calendar/index.js +6 -0
- package/dist/components/card/Card.d.ts +6 -6
- package/dist/components/card/Card.d.ts.map +1 -1
- package/dist/components/card/Card.js +8 -8
- package/dist/components/carousel/Carousel.d.ts.map +1 -1
- package/dist/components/carousel/Carousel.js +85 -83
- package/dist/components/carousel/carousel-styles.d.ts +1 -20
- package/dist/components/carousel/carousel-styles.d.ts.map +1 -1
- package/dist/components/chip/Chip.js +5 -5
- package/dist/components/clipboard/Clipboard.d.ts +75 -0
- package/dist/components/clipboard/Clipboard.d.ts.map +1 -0
- package/dist/components/clipboard/Clipboard.js +53 -0
- package/dist/components/clipboard/CopyButton.d.ts +64 -0
- package/dist/components/clipboard/CopyButton.d.ts.map +1 -0
- package/dist/components/clipboard/CopyButton.js +44 -0
- package/dist/components/clipboard/clipboard-config.d.ts +42 -0
- package/dist/components/clipboard/clipboard-config.d.ts.map +1 -0
- package/dist/components/clipboard/clipboard-config.js +23 -0
- package/dist/components/clipboard/clipboard-styles.d.ts +11 -0
- package/dist/components/clipboard/clipboard-styles.d.ts.map +1 -0
- package/dist/components/clipboard/clipboard-styles.js +5 -0
- package/dist/components/clipboard/index.d.ts +4 -0
- package/dist/components/clipboard/index.d.ts.map +1 -0
- package/dist/components/clipboard/index.js +4 -0
- package/dist/components/container/Container.d.ts +51 -0
- package/dist/components/container/Container.d.ts.map +1 -0
- package/dist/components/container/Container.js +21 -0
- package/dist/components/container/container-config.d.ts +61 -0
- package/dist/components/container/container-config.d.ts.map +1 -0
- package/dist/components/container/container-config.js +16 -0
- package/dist/components/container/container-styles.d.ts +18 -0
- package/dist/components/container/container-styles.d.ts.map +1 -0
- package/dist/components/container/container-styles.js +12 -0
- package/dist/components/container/index.d.ts +3 -0
- package/dist/components/container/index.d.ts.map +1 -0
- package/dist/components/container/index.js +3 -0
- package/dist/components/cta/CTA.d.ts +81 -0
- package/dist/components/cta/CTA.d.ts.map +1 -0
- package/dist/components/cta/CTA.js +60 -0
- package/dist/components/cta/cta-config.d.ts +69 -0
- package/dist/components/cta/cta-config.d.ts.map +1 -0
- package/dist/components/cta/cta-config.js +22 -0
- package/dist/components/cta/cta-styles.d.ts +8 -0
- package/dist/components/cta/cta-styles.d.ts.map +1 -0
- package/dist/components/cta/cta-styles.js +9 -0
- package/dist/components/cta/index.d.ts +3 -0
- package/dist/components/cta/index.d.ts.map +1 -0
- package/dist/components/cta/index.js +3 -0
- package/dist/components/drawer/Drawer.d.ts +8 -4
- package/dist/components/drawer/Drawer.d.ts.map +1 -1
- package/dist/components/drawer/Drawer.js +54 -38
- package/dist/components/{select/Select.d.ts → dropmenu/Dropmenu.d.ts} +21 -21
- package/dist/components/{select/Select.d.ts.map → dropmenu/Dropmenu.d.ts.map} +1 -1
- package/dist/components/dropmenu/Dropmenu.js +102 -0
- package/dist/components/{select/select-config.d.ts → dropmenu/dropmenu-config.d.ts} +8 -8
- package/dist/components/dropmenu/dropmenu-config.d.ts.map +1 -0
- package/dist/components/{select/select-config.js → dropmenu/dropmenu-config.js} +3 -3
- package/dist/components/{select/select-styles.d.ts → dropmenu/dropmenu-styles.d.ts} +1 -1
- package/dist/components/dropmenu/dropmenu-styles.d.ts.map +1 -0
- package/dist/components/{select/select-styles.js → dropmenu/dropmenu-styles.js} +1 -1
- package/dist/components/dropmenu/index.d.ts +3 -0
- package/dist/components/dropmenu/index.d.ts.map +1 -0
- package/dist/components/dropmenu/index.js +3 -0
- package/dist/components/empty-state/EmptyState.d.ts +77 -0
- package/dist/components/empty-state/EmptyState.d.ts.map +1 -0
- package/dist/components/empty-state/EmptyState.js +46 -0
- package/dist/components/empty-state/empty-state-config.d.ts +44 -0
- package/dist/components/empty-state/empty-state-config.d.ts.map +1 -0
- package/dist/components/empty-state/empty-state-config.js +16 -0
- package/dist/components/empty-state/empty-state-styles.d.ts +13 -0
- package/dist/components/empty-state/empty-state-styles.d.ts.map +1 -0
- package/dist/components/empty-state/empty-state-styles.js +18 -0
- package/dist/components/empty-state/index.d.ts +3 -0
- package/dist/components/empty-state/index.d.ts.map +1 -0
- package/dist/components/empty-state/index.js +3 -0
- package/dist/components/feature-grid/FeatureGrid.d.ts +107 -0
- package/dist/components/feature-grid/FeatureGrid.d.ts.map +1 -0
- package/dist/components/feature-grid/FeatureGrid.js +94 -0
- package/dist/components/feature-grid/feature-grid-config.d.ts +80 -0
- package/dist/components/feature-grid/feature-grid-config.d.ts.map +1 -0
- package/dist/components/feature-grid/feature-grid-config.js +28 -0
- package/dist/components/feature-grid/feature-grid-styles.d.ts +11 -0
- package/dist/components/feature-grid/feature-grid-styles.d.ts.map +1 -0
- package/dist/components/feature-grid/feature-grid-styles.js +5 -0
- package/dist/components/feature-grid/index.d.ts +3 -0
- package/dist/components/feature-grid/index.d.ts.map +1 -0
- package/dist/components/feature-grid/index.js +3 -0
- package/dist/components/field/FieldShell.d.ts +13 -1
- package/dist/components/field/FieldShell.d.ts.map +1 -1
- package/dist/components/field/FieldShell.js +16 -15
- package/dist/components/footer/Footer.d.ts +73 -0
- package/dist/components/footer/Footer.d.ts.map +1 -0
- package/dist/components/footer/Footer.js +112 -0
- package/dist/components/footer/footer-config.d.ts +40 -0
- package/dist/components/footer/footer-config.d.ts.map +1 -0
- package/dist/components/footer/footer-config.js +18 -0
- package/dist/components/footer/footer-styles.d.ts +22 -0
- package/dist/components/footer/footer-styles.d.ts.map +1 -0
- package/dist/components/footer/footer-styles.js +9 -0
- package/dist/components/footer/index.d.ts +3 -0
- package/dist/components/footer/index.d.ts.map +1 -0
- package/dist/components/footer/index.js +3 -0
- package/dist/components/form/Form.d.ts +109 -0
- package/dist/components/form/Form.d.ts.map +1 -0
- package/dist/components/form/Form.js +42 -0
- package/dist/components/form/form-config.d.ts +57 -0
- package/dist/components/form/form-config.d.ts.map +1 -0
- package/dist/components/form/form-config.js +12 -0
- package/dist/components/form/form-styles.d.ts +27 -0
- package/dist/components/form/form-styles.d.ts.map +1 -0
- package/dist/components/form/form-styles.js +5 -0
- package/dist/components/form/index.d.ts +3 -0
- package/dist/components/form/index.d.ts.map +1 -0
- package/dist/components/form/index.js +3 -0
- package/dist/components/grid/Grid.d.ts +71 -0
- package/dist/components/grid/Grid.d.ts.map +1 -0
- package/dist/components/grid/Grid.js +23 -0
- package/dist/components/grid/grid-config.d.ts +63 -0
- package/dist/components/grid/grid-config.d.ts.map +1 -0
- package/dist/components/grid/grid-config.js +16 -0
- package/dist/components/grid/grid-styles.d.ts +12 -0
- package/dist/components/grid/grid-styles.d.ts.map +1 -0
- package/dist/components/grid/grid-styles.js +31 -0
- package/dist/components/grid/index.d.ts +3 -0
- package/dist/components/grid/index.d.ts.map +1 -0
- package/dist/components/grid/index.js +3 -0
- package/dist/components/hero/Hero.d.ts +90 -0
- package/dist/components/hero/Hero.d.ts.map +1 -0
- package/dist/components/hero/Hero.js +63 -0
- package/dist/components/hero/hero-config.d.ts +71 -0
- package/dist/components/hero/hero-config.d.ts.map +1 -0
- package/dist/components/hero/hero-config.js +22 -0
- package/dist/components/hero/hero-styles.d.ts +19 -0
- package/dist/components/hero/hero-styles.d.ts.map +1 -0
- package/dist/components/hero/hero-styles.js +5 -0
- package/dist/components/hero/index.d.ts +3 -0
- package/dist/components/hero/index.d.ts.map +1 -0
- package/dist/components/hero/index.js +3 -0
- package/dist/components/image/Image.d.ts +4 -5
- package/dist/components/image/Image.d.ts.map +1 -1
- package/dist/components/image/Image.js +5 -5
- package/dist/components/input/Input.js +5 -5
- package/dist/components/link/Link.d.ts +12 -10
- package/dist/components/link/Link.d.ts.map +1 -1
- package/dist/components/link/Link.js +1 -1
- package/dist/components/marquee/Marquee.d.ts.map +1 -1
- package/dist/components/marquee/Marquee.js +36 -33
- package/dist/components/{select-menu/SelectMenu.d.ts → menu/Menu.d.ts} +52 -19
- package/dist/components/menu/Menu.d.ts.map +1 -0
- package/dist/components/menu/Menu.js +161 -0
- package/dist/components/menu/index.d.ts +5 -0
- package/dist/components/menu/index.d.ts.map +1 -0
- package/dist/components/menu/index.js +4 -0
- package/dist/components/{select-menu/select-menu-config.d.ts → menu/menu-config.d.ts} +5 -5
- package/dist/components/menu/menu-config.d.ts.map +1 -0
- package/dist/components/{select-menu/select-menu-config.js → menu/menu-config.js} +2 -2
- package/dist/components/menu/menu-navigation.d.ts +38 -0
- package/dist/components/menu/menu-navigation.d.ts.map +1 -0
- package/dist/components/menu/menu-navigation.js +20 -0
- package/dist/components/{select-menu/use-select-floating.d.ts → menu/use-menu-floating.d.ts} +10 -10
- package/dist/components/menu/use-menu-floating.d.ts.map +1 -0
- package/dist/components/{select-menu/use-select-floating.js → menu/use-menu-floating.js} +2 -2
- package/dist/components/modal/Modal.d.ts +6 -1
- package/dist/components/modal/Modal.d.ts.map +1 -1
- package/dist/components/modal/Modal.js +62 -45
- package/dist/components/multi-select/MultiSelect.d.ts +11 -10
- package/dist/components/multi-select/MultiSelect.d.ts.map +1 -1
- package/dist/components/multi-select/MultiSelect.js +99 -86
- package/dist/components/multi-select/multi-select-config.d.ts +1 -1
- package/dist/components/multi-select/multi-select-config.d.ts.map +1 -1
- package/dist/components/navbar/Navbar.d.ts +87 -0
- package/dist/components/navbar/Navbar.d.ts.map +1 -0
- package/dist/components/navbar/Navbar.js +117 -0
- package/dist/components/navbar/index.d.ts +3 -0
- package/dist/components/navbar/index.d.ts.map +1 -0
- package/dist/components/navbar/index.js +3 -0
- package/dist/components/navbar/navbar-config.d.ts +52 -0
- package/dist/components/navbar/navbar-config.d.ts.map +1 -0
- package/dist/components/navbar/navbar-config.js +20 -0
- package/dist/components/navbar/navbar-styles.d.ts +28 -0
- package/dist/components/navbar/navbar-styles.d.ts.map +1 -0
- package/dist/components/navbar/navbar-styles.js +9 -0
- package/dist/components/page/Page.d.ts +166 -0
- package/dist/components/page/Page.d.ts.map +1 -0
- package/dist/components/page/Page.js +90 -0
- package/dist/components/page/index.d.ts +3 -0
- package/dist/components/page/index.d.ts.map +1 -0
- package/dist/components/page/index.js +3 -0
- package/dist/components/page/page-config.d.ts +57 -0
- package/dist/components/page/page-config.d.ts.map +1 -0
- package/dist/components/page/page-config.js +20 -0
- package/dist/components/page/page-styles.d.ts +25 -0
- package/dist/components/page/page-styles.d.ts.map +1 -0
- package/dist/components/page/page-styles.js +5 -0
- package/dist/components/pagination/Pagination.d.ts +91 -0
- package/dist/components/pagination/Pagination.d.ts.map +1 -0
- package/dist/components/pagination/Pagination.js +66 -0
- package/dist/components/pagination/index.d.ts +3 -0
- package/dist/components/pagination/index.d.ts.map +1 -0
- package/dist/components/pagination/index.js +4 -0
- package/dist/components/pagination/pagination-config.d.ts +66 -0
- package/dist/components/pagination/pagination-config.d.ts.map +1 -0
- package/dist/components/pagination/pagination-config.js +19 -0
- package/dist/components/pagination/pagination-styles.d.ts +19 -0
- package/dist/components/pagination/pagination-styles.d.ts.map +1 -0
- package/dist/components/pagination/pagination-styles.js +5 -0
- package/dist/components/pagination/pagination.helpers.d.ts +26 -0
- package/dist/components/pagination/pagination.helpers.d.ts.map +1 -0
- package/dist/components/pagination/pagination.helpers.js +12 -0
- package/dist/components/pin-input/PinInput.d.ts +109 -0
- package/dist/components/pin-input/PinInput.d.ts.map +1 -0
- package/dist/components/pin-input/PinInput.js +124 -0
- package/dist/components/pin-input/index.d.ts +3 -0
- package/dist/components/pin-input/index.d.ts.map +1 -0
- package/dist/components/pin-input/index.js +3 -0
- package/dist/components/pin-input/pin-input-config.d.ts +82 -0
- package/dist/components/pin-input/pin-input-config.d.ts.map +1 -0
- package/dist/components/pin-input/pin-input-config.js +23 -0
- package/dist/components/pin-input/pin-input-styles.d.ts +16 -0
- package/dist/components/pin-input/pin-input-styles.d.ts.map +1 -0
- package/dist/components/pin-input/pin-input-styles.js +9 -0
- package/dist/components/pricing-card/PricingCard.d.ts +87 -0
- package/dist/components/pricing-card/PricingCard.d.ts.map +1 -0
- package/dist/components/pricing-card/PricingCard.js +79 -0
- package/dist/components/pricing-card/index.d.ts +3 -0
- package/dist/components/pricing-card/index.d.ts.map +1 -0
- package/dist/components/pricing-card/index.js +3 -0
- package/dist/components/pricing-card/pricing-card-config.d.ts +35 -0
- package/dist/components/pricing-card/pricing-card-config.d.ts.map +1 -0
- package/dist/components/pricing-card/pricing-card-config.js +16 -0
- package/dist/components/pricing-card/pricing-card-styles.d.ts +21 -0
- package/dist/components/pricing-card/pricing-card-styles.d.ts.map +1 -0
- package/dist/components/pricing-card/pricing-card-styles.js +5 -0
- package/dist/components/radio/Radio.d.ts +53 -107
- package/dist/components/radio/Radio.d.ts.map +1 -1
- package/dist/components/radio/Radio.js +50 -36
- package/dist/components/radio/RadioGroup.d.ts +107 -53
- package/dist/components/radio/RadioGroup.d.ts.map +1 -1
- package/dist/components/radio/RadioGroup.js +43 -49
- package/dist/components/radio/index.d.ts +0 -1
- package/dist/components/radio/index.d.ts.map +1 -1
- package/dist/components/resizable-screen/ResizableScreen.d.ts +4 -4
- package/dist/components/scrollbar/index.js +1 -0
- package/dist/components/scrollbar/scrollbar-config.js +13 -0
- package/dist/components/section/Section.d.ts +56 -0
- package/dist/components/section/Section.d.ts.map +1 -0
- package/dist/components/section/Section.js +27 -0
- package/dist/components/section/index.d.ts +3 -0
- package/dist/components/section/index.d.ts.map +1 -0
- package/dist/components/section/index.js +3 -0
- package/dist/components/section/section-config.d.ts +64 -0
- package/dist/components/section/section-config.d.ts.map +1 -0
- package/dist/components/section/section-config.js +20 -0
- package/dist/components/section/section-styles.d.ts +8 -0
- package/dist/components/section/section-styles.d.ts.map +1 -0
- package/dist/components/section/section-styles.js +9 -0
- package/dist/components/section-kit/ActionGroup.d.ts +47 -0
- package/dist/components/section-kit/ActionGroup.d.ts.map +1 -0
- package/dist/components/section-kit/ActionGroup.js +35 -0
- package/dist/components/section-kit/SectionHeading.d.ts +65 -0
- package/dist/components/section-kit/SectionHeading.d.ts.map +1 -0
- package/dist/components/section-kit/SectionHeading.js +34 -0
- package/dist/components/section-kit/index.d.ts +12 -0
- package/dist/components/section-kit/index.d.ts.map +1 -0
- package/dist/components/section-kit/index.js +2 -0
- package/dist/components/sidebar/Sidebar.d.ts.map +1 -1
- package/dist/components/sidebar/Sidebar.js +92 -90
- package/dist/components/sidebar-layout/SidebarLayout.d.ts +67 -0
- package/dist/components/sidebar-layout/SidebarLayout.d.ts.map +1 -0
- package/dist/components/sidebar-layout/SidebarLayout.js +40 -0
- package/dist/components/sidebar-layout/index.d.ts +3 -0
- package/dist/components/sidebar-layout/index.d.ts.map +1 -0
- package/dist/components/sidebar-layout/index.js +3 -0
- package/dist/components/sidebar-layout/sidebar-layout-config.d.ts +49 -0
- package/dist/components/sidebar-layout/sidebar-layout-config.d.ts.map +1 -0
- package/dist/components/sidebar-layout/sidebar-layout-config.js +16 -0
- package/dist/components/sidebar-layout/sidebar-layout-styles.d.ts +21 -0
- package/dist/components/sidebar-layout/sidebar-layout-styles.d.ts.map +1 -0
- package/dist/components/sidebar-layout/sidebar-layout-styles.js +9 -0
- package/dist/components/skeleton/Skeleton.d.ts +65 -0
- package/dist/components/skeleton/Skeleton.d.ts.map +1 -0
- package/dist/components/skeleton/Skeleton.js +29 -0
- package/dist/components/skeleton/index.d.ts +3 -0
- package/dist/components/skeleton/index.d.ts.map +1 -0
- package/dist/components/skeleton/index.js +3 -0
- package/dist/components/skeleton/skeleton-config.d.ts +40 -0
- package/dist/components/skeleton/skeleton-config.d.ts.map +1 -0
- package/dist/components/skeleton/skeleton-config.js +13 -0
- package/dist/components/skeleton/skeleton-styles.d.ts +19 -0
- package/dist/components/skeleton/skeleton-styles.d.ts.map +1 -0
- package/dist/components/skeleton/skeleton-styles.js +5 -0
- package/dist/components/stack/Stack.d.ts +107 -0
- package/dist/components/stack/Stack.d.ts.map +1 -0
- package/dist/components/stack/Stack.js +36 -0
- package/dist/components/stack/index.d.ts +3 -0
- package/dist/components/stack/index.d.ts.map +1 -0
- package/dist/components/stack/index.js +3 -0
- package/dist/components/stack/stack-config.d.ts +68 -0
- package/dist/components/stack/stack-config.d.ts.map +1 -0
- package/dist/components/stack/stack-config.js +20 -0
- package/dist/components/stack/stack-styles.d.ts +10 -0
- package/dist/components/stack/stack-styles.d.ts.map +1 -0
- package/dist/components/stack/stack-styles.js +21 -0
- package/dist/components/switch/Switch.d.ts.map +1 -1
- package/dist/components/switch/Switch.js +7 -5
- package/dist/components/table/Table.js +3 -3
- package/dist/components/tabs/Tabs.js +3 -3
- package/dist/components/testimonials/Testimonials.d.ts +78 -0
- package/dist/components/testimonials/Testimonials.d.ts.map +1 -0
- package/dist/components/testimonials/Testimonials.js +96 -0
- package/dist/components/testimonials/index.d.ts +3 -0
- package/dist/components/testimonials/index.d.ts.map +1 -0
- package/dist/components/testimonials/index.js +3 -0
- package/dist/components/testimonials/testimonials-config.d.ts +44 -0
- package/dist/components/testimonials/testimonials-config.d.ts.map +1 -0
- package/dist/components/testimonials/testimonials-config.js +28 -0
- package/dist/components/testimonials/testimonials-styles.d.ts +11 -0
- package/dist/components/testimonials/testimonials-styles.d.ts.map +1 -0
- package/dist/components/testimonials/testimonials-styles.js +5 -0
- package/dist/components/textarea/Textarea.d.ts +10 -10
- package/dist/components/textarea/Textarea.js +7 -7
- package/dist/components/textarea/textarea-config.d.ts +2 -2
- package/dist/components/toast/ToastItem.d.ts.map +1 -1
- package/dist/components/toast/ToastItem.js +8 -7
- package/dist/components/tooltip/Tooltip.js +5 -5
- package/dist/components/typography/Typography.d.ts +60 -0
- package/dist/components/typography/Typography.d.ts.map +1 -0
- package/dist/components/typography/Typography.js +28 -0
- package/dist/components/typography/index.d.ts +3 -0
- package/dist/components/typography/index.d.ts.map +1 -0
- package/dist/components/typography/index.js +3 -0
- package/dist/components/typography/typography-config.d.ts +54 -0
- package/dist/components/typography/typography-config.d.ts.map +1 -0
- package/dist/components/typography/typography-config.js +12 -0
- package/dist/components/typography/typography-styles.d.ts +21 -0
- package/dist/components/typography/typography-styles.d.ts.map +1 -0
- package/dist/components/typography/typography-styles.js +19 -0
- package/dist/config/default-config.d.ts.map +1 -1
- package/dist/config/default-config.js +2 -2
- package/dist/config/index.js +1 -0
- package/dist/config/validate-config.d.ts +34 -0
- package/dist/config/validate-config.d.ts.map +1 -0
- package/dist/config/validate-config.js +190 -0
- package/dist/icons/CopyIcon.d.ts +3 -0
- package/dist/icons/CopyIcon.d.ts.map +1 -0
- package/dist/icons/CopyIcon.js +24 -0
- package/dist/index.d.ts +33 -18
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +110 -61
- package/dist/libs/index.js +3 -0
- package/dist/libs/use-body-scroll-lock.d.ts +21 -0
- package/dist/libs/use-body-scroll-lock.d.ts.map +1 -0
- package/dist/libs/use-body-scroll-lock.js +27 -0
- package/dist/libs/use-dialog-overlay.d.ts +21 -0
- package/dist/libs/use-dialog-overlay.d.ts.map +1 -0
- package/dist/libs/use-dialog-overlay.js +21 -0
- package/dist/libs/use-prefers-reduced-motion.d.ts +23 -0
- package/dist/libs/use-prefers-reduced-motion.d.ts.map +1 -0
- package/dist/libs/use-prefers-reduced-motion.js +19 -0
- package/dist/puck/adapters.d.ts +41 -0
- package/dist/puck/adapters.d.ts.map +1 -0
- package/dist/puck/adapters.js +30 -0
- package/dist/puck/blocks/content.d.ts +32 -0
- package/dist/puck/blocks/content.d.ts.map +1 -0
- package/dist/puck/blocks/content.js +54 -0
- package/dist/puck/blocks/layout.d.ts +44 -0
- package/dist/puck/blocks/layout.d.ts.map +1 -0
- package/dist/puck/blocks/layout.js +69 -0
- package/dist/puck/blocks/navigation.d.ts +66 -0
- package/dist/puck/blocks/navigation.d.ts.map +1 -0
- package/dist/puck/blocks/navigation.js +122 -0
- package/dist/puck/blocks/sections.d.ts +134 -0
- package/dist/puck/blocks/sections.d.ts.map +1 -0
- package/dist/puck/blocks/sections.js +232 -0
- package/dist/puck/blocks/utility.d.ts +22 -0
- package/dist/puck/blocks/utility.d.ts.map +1 -0
- package/dist/puck/blocks/utility.js +49 -0
- package/dist/puck/config.d.ts +63 -0
- package/dist/puck/config.d.ts.map +1 -0
- package/dist/puck/config.js +79 -0
- package/dist/puck/fields.d.ts +94 -0
- package/dist/puck/fields.d.ts.map +1 -0
- package/dist/puck/fields.js +116 -0
- package/dist/puck/index.d.ts +21 -0
- package/dist/puck/index.d.ts.map +1 -0
- package/dist/puck/index.js +10 -0
- package/dist/scripts/AsheeThemeScript.js +43 -8
- package/dist/shared/action.d.ts +52 -0
- package/dist/shared/action.d.ts.map +1 -0
- package/dist/shared/index.d.ts +3 -0
- package/dist/shared/index.d.ts.map +1 -1
- package/dist/shared/spacing.d.ts +38 -0
- package/dist/shared/spacing.d.ts.map +1 -0
- package/dist/shared/spacing.js +29 -0
- package/dist/shared/typography.d.ts +81 -0
- package/dist/shared/typography.d.ts.map +1 -0
- package/dist/shared/typography.js +137 -0
- package/dist/utils/resolve-token.d.ts +32 -7
- package/dist/utils/resolve-token.d.ts.map +1 -1
- package/dist/utils/resolve-token.js +9 -1
- package/dist/utils/stacking.d.ts +2 -2
- package/dist/utils/stacking.d.ts.map +1 -1
- package/package.json +26 -7
- package/dist/components/date-picker/Calendar.d.ts.map +0 -1
- package/dist/components/date-picker/Calendar.js +0 -143
- package/dist/components/date-picker/DatePicker.d.ts.map +0 -1
- package/dist/components/date-picker/TimeSpinner.d.ts.map +0 -1
- package/dist/components/date-picker/date-picker-config.d.ts.map +0 -1
- package/dist/components/date-picker/date-picker-styles.d.ts.map +0 -1
- package/dist/components/date-picker/date-picker.helpers.d.ts.map +0 -1
- package/dist/components/date-picker/index.d.ts +0 -3
- package/dist/components/date-picker/index.d.ts.map +0 -1
- package/dist/components/date-picker/index.js +0 -6
- package/dist/components/select/Select.js +0 -98
- package/dist/components/select/index.d.ts +0 -3
- package/dist/components/select/index.d.ts.map +0 -1
- package/dist/components/select/index.js +0 -3
- package/dist/components/select/select-config.d.ts.map +0 -1
- package/dist/components/select/select-styles.d.ts.map +0 -1
- package/dist/components/select-menu/SelectMenu.d.ts.map +0 -1
- package/dist/components/select-menu/SelectMenu.js +0 -104
- package/dist/components/select-menu/index.d.ts +0 -4
- package/dist/components/select-menu/index.d.ts.map +0 -1
- package/dist/components/select-menu/index.js +0 -3
- package/dist/components/select-menu/select-menu-config.d.ts.map +0 -1
- package/dist/components/select-menu/use-select-floating.d.ts.map +0 -1
- /package/dist/components/{date-picker → calendar}/TimeSpinner.d.ts +0 -0
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"FieldShell.d.ts","sourceRoot":"","sources":["../../../src/components/field/FieldShell.tsx"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAGvC,OAAO,KAAK,EAAE,WAAW,EAAE,UAAU,EAAE,MAAM,gBAAgB,CAAC;AAuB9D;;;GAGG;AACH,MAAM,WAAW,eAAe;IAC9B;;;OAGG;IACH,EAAE,EAAE,MAAM,CAAC;IAEX;;OAEG;IACH,KAAK,CAAC,EAAE,MAAM,CAAC;IAEf;;;OAGG;IACH,UAAU,CAAC,EAAE,UAAU,CAAC;IAExB;;OAEG;IACH,WAAW,CAAC,EAAE,MAAM,CAAC;IAErB;;;OAGG;IACH,aAAa,CAAC,EAAE,MAAM,CAAC;IAEvB;;OAEG;IACH,OAAO,CAAC,EAAE,MAAM,CAAC;IAEjB;;;OAGG;IACH,SAAS,CAAC,EAAE,MAAM,CAAC;IAEnB;;;;OAIG;IACH,MAAM,CAAC,EAAE,WAAW,CAAC;IAErB;;;;OAIG;IACH,QAAQ,CAAC,EAAE,OAAO,CAAC;IAEnB;;;;OAIG;IACH,SAAS,CAAC,EAAE,OAAO,CAAC;IAEpB;;;OAGG;IACH,QAAQ,EAAE,SAAS,CAAC;CACrB;AAED;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAqCG;AACH,wBAAgB,UAAU,CAAC,EACzB,EAAE,EACF,KAAK,EACL,UAAmB,EACnB,WAAW,EACX,aAAa,EACb,OAAO,EACP,SAAS,EACT,MAAkB,EAClB,QAAQ,EACR,SAAS,EACT,QAAQ,GACT,EAAE,eAAe,+
|
|
1
|
+
{"version":3,"file":"FieldShell.d.ts","sourceRoot":"","sources":["../../../src/components/field/FieldShell.tsx"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAGvC,OAAO,KAAK,EAAE,WAAW,EAAE,UAAU,EAAE,MAAM,gBAAgB,CAAC;AAuB9D;;;GAGG;AACH,MAAM,WAAW,eAAe;IAC9B;;;OAGG;IACH,EAAE,EAAE,MAAM,CAAC;IAEX;;;;OAIG;IACH,OAAO,CAAC,EAAE,MAAM,CAAC;IAEjB;;;;OAIG;IACH,OAAO,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IAExB;;OAEG;IACH,KAAK,CAAC,EAAE,MAAM,CAAC;IAEf;;;OAGG;IACH,UAAU,CAAC,EAAE,UAAU,CAAC;IAExB;;OAEG;IACH,WAAW,CAAC,EAAE,MAAM,CAAC;IAErB;;;OAGG;IACH,aAAa,CAAC,EAAE,MAAM,CAAC;IAEvB;;OAEG;IACH,OAAO,CAAC,EAAE,MAAM,CAAC;IAEjB;;;OAGG;IACH,SAAS,CAAC,EAAE,MAAM,CAAC;IAEnB;;;;OAIG;IACH,MAAM,CAAC,EAAE,WAAW,CAAC;IAErB;;;;OAIG;IACH,QAAQ,CAAC,EAAE,OAAO,CAAC;IAEnB;;;;OAIG;IACH,SAAS,CAAC,EAAE,OAAO,CAAC;IAEpB;;;OAGG;IACH,QAAQ,EAAE,SAAS,CAAC;CACrB;AAED;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAqCG;AACH,wBAAgB,UAAU,CAAC,EACzB,EAAE,EACF,OAAO,EACP,OAAO,EACP,KAAK,EACL,UAAmB,EACnB,WAAW,EACX,aAAa,EACb,OAAO,EACP,SAAS,EACT,MAAkB,EAClB,QAAQ,EACR,SAAS,EACT,QAAQ,GACT,EAAE,eAAe,+BAwCjB"}
|
|
@@ -13,37 +13,38 @@ var i = {
|
|
|
13
13
|
warning: "text-warning",
|
|
14
14
|
success: "text-success"
|
|
15
15
|
};
|
|
16
|
-
function o({ id: o,
|
|
16
|
+
function o({ id: o, labelId: s, htmlFor: c, label: l, labelAlign: u = "left", description: d, descriptionId: f, message: p, messageId: m, status: h = "default", required: g, isLoading: _, children: v }) {
|
|
17
17
|
return /* @__PURE__ */ r("div", {
|
|
18
18
|
className: "flex flex-col gap-1.5",
|
|
19
19
|
children: [
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
20
|
+
l && /* @__PURE__ */ n("label", {
|
|
21
|
+
id: s,
|
|
22
|
+
htmlFor: c === null ? void 0 : c ?? o,
|
|
23
|
+
className: e("text-sm font-medium text-foreground", i[u]),
|
|
23
24
|
children: /* @__PURE__ */ r("span", {
|
|
24
25
|
className: "inline-flex items-center gap-1.5",
|
|
25
26
|
children: [
|
|
26
|
-
|
|
27
|
-
|
|
27
|
+
l,
|
|
28
|
+
g && /* @__PURE__ */ n("span", {
|
|
28
29
|
"aria-hidden": "true",
|
|
29
30
|
className: "text-danger",
|
|
30
31
|
children: "*"
|
|
31
32
|
}),
|
|
32
|
-
|
|
33
|
+
_ && /* @__PURE__ */ n(t, { size: "sm" })
|
|
33
34
|
]
|
|
34
35
|
})
|
|
35
36
|
}),
|
|
36
|
-
l && /* @__PURE__ */ n("p", {
|
|
37
|
-
id: u,
|
|
38
|
-
className: e("text-sm text-foreground/60"),
|
|
39
|
-
children: l
|
|
40
|
-
}),
|
|
41
|
-
g,
|
|
42
37
|
d && /* @__PURE__ */ n("p", {
|
|
43
38
|
id: f,
|
|
44
|
-
|
|
45
|
-
className: e("text-sm", a[p]),
|
|
39
|
+
className: e("text-sm text-foreground/60"),
|
|
46
40
|
children: d
|
|
41
|
+
}),
|
|
42
|
+
v,
|
|
43
|
+
p && /* @__PURE__ */ n("p", {
|
|
44
|
+
id: m,
|
|
45
|
+
role: h === "error" ? "alert" : void 0,
|
|
46
|
+
className: e("text-sm", a[h]),
|
|
47
|
+
children: p
|
|
47
48
|
})
|
|
48
49
|
]
|
|
49
50
|
});
|
|
@@ -0,0 +1,73 @@
|
|
|
1
|
+
import { ElementType, HTMLAttributes, ReactNode } from 'react';
|
|
2
|
+
import { FooterConfig } from './footer-config';
|
|
3
|
+
/**
|
|
4
|
+
* One link in the footer.
|
|
5
|
+
*/
|
|
6
|
+
export interface FooterLinkItem {
|
|
7
|
+
/** Stable identifier for the link. Defaults to its position in the list. */
|
|
8
|
+
id?: string | number;
|
|
9
|
+
/** Visible name of the link. */
|
|
10
|
+
label: ReactNode;
|
|
11
|
+
/** Destination of the link. */
|
|
12
|
+
href?: string;
|
|
13
|
+
/** Content before the label, typically an icon or a social mark. */
|
|
14
|
+
icon?: ReactNode;
|
|
15
|
+
/** Whether the link leaves the site, which marks the anchor accordingly. */
|
|
16
|
+
isExternal?: boolean;
|
|
17
|
+
/** Component that replaces the anchor for this link only. */
|
|
18
|
+
component?: ElementType;
|
|
19
|
+
/** Additional props for that component. */
|
|
20
|
+
componentProps?: Record<string, unknown>;
|
|
21
|
+
}
|
|
22
|
+
/**
|
|
23
|
+
* One column of footer navigation.
|
|
24
|
+
*/
|
|
25
|
+
export interface FooterGroup {
|
|
26
|
+
/** Stable identifier for the group. Defaults to its position in the list. */
|
|
27
|
+
id?: string | number;
|
|
28
|
+
/** Title of the column, which also names its navigation landmark. */
|
|
29
|
+
title: string;
|
|
30
|
+
/** The links in the column. */
|
|
31
|
+
links: FooterLinkItem[];
|
|
32
|
+
}
|
|
33
|
+
/**
|
|
34
|
+
* Substitution applied to every link in the footer.
|
|
35
|
+
*/
|
|
36
|
+
export interface FooterLink {
|
|
37
|
+
/** Component that replaces the anchor, such as a framework router link. */
|
|
38
|
+
component?: ElementType;
|
|
39
|
+
/** Additional props for that component. */
|
|
40
|
+
props?: Record<string, unknown>;
|
|
41
|
+
}
|
|
42
|
+
type BaseFooterProps = FooterConfig & Omit<HTMLAttributes<HTMLElement>, "color" | "title">;
|
|
43
|
+
/**
|
|
44
|
+
* Props for the Footer component.
|
|
45
|
+
*/
|
|
46
|
+
export interface FooterProps extends BaseFooterProps {
|
|
47
|
+
/** Brand content, typically a logo and a product name. */
|
|
48
|
+
brand?: ReactNode;
|
|
49
|
+
/** Short description under the brand. */
|
|
50
|
+
description?: ReactNode;
|
|
51
|
+
/** The navigation groups. */
|
|
52
|
+
groups?: FooterGroup[];
|
|
53
|
+
/** Social links, rendered as a row of icon links under the groups. */
|
|
54
|
+
social?: FooterLinkItem[];
|
|
55
|
+
/** Legal links, rendered beside the copyright line. */
|
|
56
|
+
legal?: FooterLinkItem[];
|
|
57
|
+
/** The copyright line. */
|
|
58
|
+
copyright?: ReactNode;
|
|
59
|
+
/** Action area in the brand column, typically a newsletter signup. */
|
|
60
|
+
newsletter?: ReactNode;
|
|
61
|
+
/** Substitution applied to every link the footer renders. */
|
|
62
|
+
link?: FooterLink;
|
|
63
|
+
/**
|
|
64
|
+
* Element to render the footer as.
|
|
65
|
+
* Defaults to `footer`, which is the contentinfo landmark.
|
|
66
|
+
*
|
|
67
|
+
* @default "footer"
|
|
68
|
+
*/
|
|
69
|
+
as?: ElementType;
|
|
70
|
+
}
|
|
71
|
+
export declare const Footer: import('react').ForwardRefExoticComponent<FooterProps & import('react').RefAttributes<HTMLElement>>;
|
|
72
|
+
export {};
|
|
73
|
+
//# sourceMappingURL=Footer.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Footer.d.ts","sourceRoot":"","sources":["../../../src/components/footer/Footer.tsx"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AAIH,OAAO,EACL,KAAK,WAAW,EAEhB,KAAK,cAAc,EACnB,KAAK,SAAS,EACf,MAAM,OAAO,CAAC;AAQf,OAAO,EAA0B,KAAK,YAAY,EAAE,MAAM,iBAAiB,CAAC;AAc5E;;GAEG;AACH,MAAM,WAAW,cAAc;IAC7B,4EAA4E;IAC5E,EAAE,CAAC,EAAE,MAAM,GAAG,MAAM,CAAC;IAErB,gCAAgC;IAChC,KAAK,EAAE,SAAS,CAAC;IAEjB,+BAA+B;IAC/B,IAAI,CAAC,EAAE,MAAM,CAAC;IAEd,oEAAoE;IACpE,IAAI,CAAC,EAAE,SAAS,CAAC;IAEjB,4EAA4E;IAC5E,UAAU,CAAC,EAAE,OAAO,CAAC;IAErB,6DAA6D;IAC7D,SAAS,CAAC,EAAE,WAAW,CAAC;IAExB,2CAA2C;IAC3C,cAAc,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;CAC1C;AAED;;GAEG;AACH,MAAM,WAAW,WAAW;IAC1B,6EAA6E;IAC7E,EAAE,CAAC,EAAE,MAAM,GAAG,MAAM,CAAC;IAErB,qEAAqE;IACrE,KAAK,EAAE,MAAM,CAAC;IAEd,+BAA+B;IAC/B,KAAK,EAAE,cAAc,EAAE,CAAC;CACzB;AAED;;GAEG;AACH,MAAM,WAAW,UAAU;IACzB,2EAA2E;IAC3E,SAAS,CAAC,EAAE,WAAW,CAAC;IAExB,2CAA2C;IAC3C,KAAK,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;CACjC;AAED,KAAK,eAAe,GAAG,YAAY,GACjC,IAAI,CAAC,cAAc,CAAC,WAAW,CAAC,EAAE,OAAO,GAAG,OAAO,CAAC,CAAC;AAEvD;;GAEG;AACH,MAAM,WAAW,WAAY,SAAQ,eAAe;IAClD,0DAA0D;IAC1D,KAAK,CAAC,EAAE,SAAS,CAAC;IAElB,yCAAyC;IACzC,WAAW,CAAC,EAAE,SAAS,CAAC;IAExB,6BAA6B;IAC7B,MAAM,CAAC,EAAE,WAAW,EAAE,CAAC;IAEvB,sEAAsE;IACtE,MAAM,CAAC,EAAE,cAAc,EAAE,CAAC;IAE1B,uDAAuD;IACvD,KAAK,CAAC,EAAE,cAAc,EAAE,CAAC;IAEzB,0BAA0B;IAC1B,SAAS,CAAC,EAAE,SAAS,CAAC;IAEtB,sEAAsE;IACtE,UAAU,CAAC,EAAE,SAAS,CAAC;IAEvB,6DAA6D;IAC7D,IAAI,CAAC,EAAE,UAAU,CAAC;IAElB;;;;;OAKG;IACH,EAAE,CAAC,EAAE,WAAW,CAAC;CAClB;AA6ED,eAAO,MAAM,MAAM,qGAiIlB,CAAC"}
|
|
@@ -0,0 +1,112 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
"use client";
|
|
3
|
+
import { cn as e } from "../../utils/cn.js";
|
|
4
|
+
import { SPACE_PADDING_Y_CLASS as t } from "../../shared/spacing.js";
|
|
5
|
+
import { useAsheeConfig as n } from "../../libs/context.js";
|
|
6
|
+
import { resolveConfigCascade as r } from "../../utils/resolve-token.js";
|
|
7
|
+
import { Typography as i } from "../typography/Typography.js";
|
|
8
|
+
import { Link as a } from "../link/Link.js";
|
|
9
|
+
import { Container as o } from "../container/Container.js";
|
|
10
|
+
import { FALLBACK_FOOTER_CONFIG as s } from "./footer-config.js";
|
|
11
|
+
import { FOOTER_LINK_CLASS as c, FOOTER_VARIANT_CLASS as l } from "./footer-styles.js";
|
|
12
|
+
import { forwardRef as u } from "react";
|
|
13
|
+
import { Fragment as d, jsx as f, jsxs as p } from "react/jsx-runtime";
|
|
14
|
+
//#region src/components/footer/Footer.tsx
|
|
15
|
+
function m({ links: e, link: t, className: n }) {
|
|
16
|
+
return /* @__PURE__ */ f("ul", {
|
|
17
|
+
className: n,
|
|
18
|
+
children: e.map((e, n) => /* @__PURE__ */ f("li", { children: /* @__PURE__ */ f(a, {
|
|
19
|
+
href: e.href,
|
|
20
|
+
startIcon: e.icon,
|
|
21
|
+
isExternal: e.isExternal,
|
|
22
|
+
component: e.component ?? t?.component,
|
|
23
|
+
componentProps: {
|
|
24
|
+
...t?.props,
|
|
25
|
+
...e.componentProps
|
|
26
|
+
},
|
|
27
|
+
className: c,
|
|
28
|
+
children: e.label
|
|
29
|
+
}) }, e.id ?? n))
|
|
30
|
+
});
|
|
31
|
+
}
|
|
32
|
+
var h = u(({ brand: a, description: c, groups: u, social: h, legal: g, copyright: _, newsletter: v, link: y, variant: b, spacing: x, contained: S, containerSize: C, as: w, className: T, children: E, ...D }, O) => {
|
|
33
|
+
let k = n(), A = r({
|
|
34
|
+
variant: b,
|
|
35
|
+
spacing: x,
|
|
36
|
+
contained: S,
|
|
37
|
+
containerSize: C
|
|
38
|
+
}, k.components?.footer, s), j = w ?? "footer", M = !!(a || c || v), N = !!(_ || g || h), P = /* @__PURE__ */ p(d, { children: [
|
|
39
|
+
(M || u && u.length > 0) && /* @__PURE__ */ p("div", {
|
|
40
|
+
className: "flex flex-col gap-10 lg:flex-row lg:items-start lg:justify-between",
|
|
41
|
+
children: [M && /* @__PURE__ */ p("div", {
|
|
42
|
+
className: "flex max-w-sm flex-col gap-3",
|
|
43
|
+
children: [
|
|
44
|
+
a && /* @__PURE__ */ f(i, {
|
|
45
|
+
as: "span",
|
|
46
|
+
role: "heading-sm",
|
|
47
|
+
children: a
|
|
48
|
+
}),
|
|
49
|
+
c && /* @__PURE__ */ f(i, {
|
|
50
|
+
role: "body-sm",
|
|
51
|
+
tone: "muted",
|
|
52
|
+
children: c
|
|
53
|
+
}),
|
|
54
|
+
v
|
|
55
|
+
]
|
|
56
|
+
}), u && u.length > 0 && /* @__PURE__ */ f("div", {
|
|
57
|
+
className: "flex flex-wrap gap-10",
|
|
58
|
+
children: u.map((e, t) => /* @__PURE__ */ p("nav", {
|
|
59
|
+
"aria-label": e.title,
|
|
60
|
+
className: "flex min-w-32 flex-col gap-3",
|
|
61
|
+
children: [/* @__PURE__ */ f(i, {
|
|
62
|
+
as: "h2",
|
|
63
|
+
role: "label",
|
|
64
|
+
children: e.title
|
|
65
|
+
}), /* @__PURE__ */ f(m, {
|
|
66
|
+
links: e.links,
|
|
67
|
+
link: y,
|
|
68
|
+
className: "flex flex-col gap-2"
|
|
69
|
+
})]
|
|
70
|
+
}, e.id ?? t))
|
|
71
|
+
})]
|
|
72
|
+
}),
|
|
73
|
+
N && /* @__PURE__ */ p("div", {
|
|
74
|
+
className: "mt-10 flex flex-col gap-4 border-t border-border pt-6 sm:flex-row sm:items-center sm:justify-between",
|
|
75
|
+
children: [_ && /* @__PURE__ */ f(i, {
|
|
76
|
+
role: "caption",
|
|
77
|
+
tone: "muted",
|
|
78
|
+
children: _
|
|
79
|
+
}), /* @__PURE__ */ p("div", {
|
|
80
|
+
className: "flex flex-wrap items-center gap-4",
|
|
81
|
+
children: [g && g.length > 0 && /* @__PURE__ */ f("nav", {
|
|
82
|
+
"aria-label": "Legal",
|
|
83
|
+
children: /* @__PURE__ */ f(m, {
|
|
84
|
+
links: g,
|
|
85
|
+
link: y,
|
|
86
|
+
className: "flex flex-wrap items-center gap-4"
|
|
87
|
+
})
|
|
88
|
+
}), h && h.length > 0 && /* @__PURE__ */ f("nav", {
|
|
89
|
+
"aria-label": "Social",
|
|
90
|
+
children: /* @__PURE__ */ f(m, {
|
|
91
|
+
links: h,
|
|
92
|
+
link: y,
|
|
93
|
+
className: "flex items-center gap-3"
|
|
94
|
+
})
|
|
95
|
+
})]
|
|
96
|
+
})]
|
|
97
|
+
}),
|
|
98
|
+
E
|
|
99
|
+
] });
|
|
100
|
+
return /* @__PURE__ */ f(j, {
|
|
101
|
+
ref: O,
|
|
102
|
+
className: e(l[A.variant], t[A.spacing], T),
|
|
103
|
+
...D,
|
|
104
|
+
children: A.contained ? /* @__PURE__ */ f(o, {
|
|
105
|
+
size: A.containerSize,
|
|
106
|
+
children: P
|
|
107
|
+
}) : P
|
|
108
|
+
});
|
|
109
|
+
});
|
|
110
|
+
h.displayName = "Footer";
|
|
111
|
+
//#endregion
|
|
112
|
+
export { h as Footer };
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
import { Space } from '../../shared';
|
|
2
|
+
import { ContainerSize } from '../container/container-config';
|
|
3
|
+
/**
|
|
4
|
+
* Surface treatment of the footer.
|
|
5
|
+
*
|
|
6
|
+
* - `solid`: the page background, so the footer reads as part of the page.
|
|
7
|
+
* - `muted`: a subdued band.
|
|
8
|
+
* - `bordered`: the page background with a separator above it.
|
|
9
|
+
*/
|
|
10
|
+
export type FooterVariant = "solid" | "muted" | "bordered";
|
|
11
|
+
/**
|
|
12
|
+
* Theme configuration options for the Footer component.
|
|
13
|
+
*
|
|
14
|
+
* Set under `components.footer` in the AsheeUI config. Values feed the
|
|
15
|
+
* component-level fallback tier of the theme cascade.
|
|
16
|
+
*/
|
|
17
|
+
export interface FooterConfig {
|
|
18
|
+
/** Surface treatment. @default "bordered" */
|
|
19
|
+
variant?: FooterVariant;
|
|
20
|
+
/** Vertical padding of the footer. @default "lg" */
|
|
21
|
+
spacing?: Space;
|
|
22
|
+
/** Whether the footer wraps its content in a `Container`. @default true */
|
|
23
|
+
contained?: boolean;
|
|
24
|
+
/** Maximum content width of the footer. @default "lg" */
|
|
25
|
+
containerSize?: ContainerSize;
|
|
26
|
+
}
|
|
27
|
+
/**
|
|
28
|
+
* Default config values registered for the Footer component.
|
|
29
|
+
*/
|
|
30
|
+
export declare const defaultFooterConfig: FooterConfig;
|
|
31
|
+
declare module "../../libs/registry" {
|
|
32
|
+
interface ComponentTypeConfigRegistry {
|
|
33
|
+
footer: FooterConfig;
|
|
34
|
+
}
|
|
35
|
+
}
|
|
36
|
+
/**
|
|
37
|
+
* Hard fallback values used when no config tier provides a value.
|
|
38
|
+
*/
|
|
39
|
+
export declare const FALLBACK_FOOTER_CONFIG: Required<FooterConfig>;
|
|
40
|
+
//# sourceMappingURL=footer-config.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"footer-config.d.ts","sourceRoot":"","sources":["../../../src/components/footer/footer-config.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAGH,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,cAAc,CAAC;AAC1C,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,+BAA+B,CAAC;AAEnE;;;;;;GAMG;AACH,MAAM,MAAM,aAAa,GAAG,OAAO,GAAG,OAAO,GAAG,UAAU,CAAC;AAE3D;;;;;GAKG;AACH,MAAM,WAAW,YAAY;IAC3B,6CAA6C;IAC7C,OAAO,CAAC,EAAE,aAAa,CAAC;IAExB,oDAAoD;IACpD,OAAO,CAAC,EAAE,KAAK,CAAC;IAEhB,2EAA2E;IAC3E,SAAS,CAAC,EAAE,OAAO,CAAC;IAEpB,yDAAyD;IACzD,aAAa,CAAC,EAAE,aAAa,CAAC;CAC/B;AAED;;GAEG;AACH,eAAO,MAAM,mBAAmB,EAAE,YAKjC,CAAC;AAEF,OAAO,QAAQ,qBAAqB,CAAC;IACnC,UAAU,2BAA2B;QACnC,MAAM,EAAE,YAAY,CAAC;KACtB;CACF;AAID;;GAEG;AACH,eAAO,MAAM,sBAAsB,EAAE,QAAQ,CAAC,YAAY,CAKzD,CAAC"}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
import { registerComponentDefaults as e } from "../../libs/registry.js";
|
|
3
|
+
//#region src/components/footer/footer-config.ts
|
|
4
|
+
var t = {
|
|
5
|
+
variant: "bordered",
|
|
6
|
+
spacing: "lg",
|
|
7
|
+
contained: !0,
|
|
8
|
+
containerSize: "lg"
|
|
9
|
+
};
|
|
10
|
+
e("footer", t);
|
|
11
|
+
var n = {
|
|
12
|
+
variant: "bordered",
|
|
13
|
+
spacing: "lg",
|
|
14
|
+
contained: !0,
|
|
15
|
+
containerSize: "lg"
|
|
16
|
+
};
|
|
17
|
+
//#endregion
|
|
18
|
+
export { n as FALLBACK_FOOTER_CONFIG, t as defaultFooterConfig };
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import { FooterVariant } from './footer-config';
|
|
2
|
+
/** Surface treatment classes. */
|
|
3
|
+
export declare const FOOTER_VARIANT_CLASS: Record<FooterVariant, string>;
|
|
4
|
+
/** The upper region: the brand column beside the navigation groups. */
|
|
5
|
+
export declare const FOOTER_TOP_CLASS = "flex flex-col gap-10 lg:flex-row lg:items-start lg:justify-between";
|
|
6
|
+
/** The brand column. */
|
|
7
|
+
export declare const FOOTER_BRAND_COLUMN_CLASS = "flex max-w-sm flex-col gap-3";
|
|
8
|
+
/** The navigation groups. */
|
|
9
|
+
export declare const FOOTER_GROUPS_CLASS = "flex flex-wrap gap-10";
|
|
10
|
+
/** One navigation group. */
|
|
11
|
+
export declare const FOOTER_GROUP_CLASS = "flex min-w-32 flex-col gap-3";
|
|
12
|
+
/** A list inside the footer. */
|
|
13
|
+
export declare const FOOTER_LIST_CLASS = "flex flex-col gap-2";
|
|
14
|
+
/** One link inside the footer. */
|
|
15
|
+
export declare const FOOTER_LINK_CLASS = "text-sm text-foreground/70 transition-colors hover:text-foreground";
|
|
16
|
+
/** The lower region: copyright, legal links and social links. */
|
|
17
|
+
export declare const FOOTER_BOTTOM_CLASS = "mt-10 flex flex-col gap-4 border-t border-border pt-6 sm:flex-row sm:items-center sm:justify-between";
|
|
18
|
+
/** The legal and social link rows. */
|
|
19
|
+
export declare const FOOTER_BOTTOM_LINKS_CLASS = "flex flex-wrap items-center gap-4";
|
|
20
|
+
/** The row of icon links. */
|
|
21
|
+
export declare const FOOTER_SOCIAL_ROW_CLASS = "flex items-center gap-3";
|
|
22
|
+
//# sourceMappingURL=footer-styles.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"footer-styles.d.ts","sourceRoot":"","sources":["../../../src/components/footer/footer-styles.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,iBAAiB,CAAC;AAErD,iCAAiC;AACjC,eAAO,MAAM,oBAAoB,EAAE,MAAM,CAAC,aAAa,EAAE,MAAM,CAI9D,CAAC;AAEF,uEAAuE;AACvE,eAAO,MAAM,gBAAgB,uEACyC,CAAC;AAEvE,wBAAwB;AACxB,eAAO,MAAM,yBAAyB,iCAAiC,CAAC;AAExE,6BAA6B;AAC7B,eAAO,MAAM,mBAAmB,0BAA0B,CAAC;AAE3D,4BAA4B;AAC5B,eAAO,MAAM,kBAAkB,iCAAiC,CAAC;AAEjE,gCAAgC;AAChC,eAAO,MAAM,iBAAiB,wBAAwB,CAAC;AAEvD,kCAAkC;AAClC,eAAO,MAAM,iBAAiB,uEACwC,CAAC;AAEvE,iEAAiE;AACjE,eAAO,MAAM,mBAAmB,yGACwE,CAAC;AAEzG,sCAAsC;AACtC,eAAO,MAAM,yBAAyB,sCAAsC,CAAC;AAE7E,6BAA6B;AAC7B,eAAO,MAAM,uBAAuB,4BAA4B,CAAC"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
//#region src/components/footer/footer-styles.ts
|
|
3
|
+
var e = {
|
|
4
|
+
solid: "bg-background",
|
|
5
|
+
muted: "bg-secondary/50",
|
|
6
|
+
bordered: "bg-background border-t border-border"
|
|
7
|
+
}, t = "flex flex-col gap-10 lg:flex-row lg:items-start lg:justify-between", n = "flex max-w-sm flex-col gap-3", r = "flex flex-wrap gap-10", i = "flex min-w-32 flex-col gap-3", a = "flex flex-col gap-2", o = "text-sm text-foreground/70 transition-colors hover:text-foreground", s = "mt-10 flex flex-col gap-4 border-t border-border pt-6 sm:flex-row sm:items-center sm:justify-between", c = "flex flex-wrap items-center gap-4", l = "flex items-center gap-3";
|
|
8
|
+
//#endregion
|
|
9
|
+
export { s as FOOTER_BOTTOM_CLASS, c as FOOTER_BOTTOM_LINKS_CLASS, n as FOOTER_BRAND_COLUMN_CLASS, r as FOOTER_GROUPS_CLASS, i as FOOTER_GROUP_CLASS, o as FOOTER_LINK_CLASS, a as FOOTER_LIST_CLASS, l as FOOTER_SOCIAL_ROW_CLASS, t as FOOTER_TOP_CLASS, e as FOOTER_VARIANT_CLASS };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/footer/index.ts"],"names":[],"mappings":"AAAA,cAAc,UAAU,CAAC;AACzB,cAAc,iBAAiB,CAAC"}
|
|
@@ -0,0 +1,109 @@
|
|
|
1
|
+
import { ElementType, FormHTMLAttributes, ReactNode } from 'react';
|
|
2
|
+
import { FormConfig } from './form-config';
|
|
3
|
+
type BaseFormProps = FormConfig & Omit<FormHTMLAttributes<HTMLFormElement>, "color" | "children">;
|
|
4
|
+
/**
|
|
5
|
+
* Configuration options for the Form component.
|
|
6
|
+
*/
|
|
7
|
+
export interface FormProps extends BaseFormProps {
|
|
8
|
+
/**
|
|
9
|
+
* The fields and other content of the form.
|
|
10
|
+
*/
|
|
11
|
+
children?: ReactNode;
|
|
12
|
+
/**
|
|
13
|
+
* Legend that groups the fields.
|
|
14
|
+
* When it is given the fields are wrapped in a `fieldset` with that legend,
|
|
15
|
+
* which is how a form tells assistive technology which set of controls it is
|
|
16
|
+
* describing. A form whose fields are already grouped by other landmarks
|
|
17
|
+
* omits it and names itself with `aria-label` or `aria-labelledby`.
|
|
18
|
+
*/
|
|
19
|
+
legend?: string;
|
|
20
|
+
/**
|
|
21
|
+
* Label of the submit control.
|
|
22
|
+
* When it is given the component renders an AsheeUI `Button` as the form's
|
|
23
|
+
* submit control, so no consumer has to rebuild one. Without it the
|
|
24
|
+
* consumer places its own control.
|
|
25
|
+
*/
|
|
26
|
+
submitLabel?: string;
|
|
27
|
+
/**
|
|
28
|
+
* Whether a submission is in progress.
|
|
29
|
+
* While it is true the submit control is disabled and busy, which is how a
|
|
30
|
+
* consumer shows a pending submission without bespoke markup.
|
|
31
|
+
*
|
|
32
|
+
* @default false
|
|
33
|
+
*/
|
|
34
|
+
isPending?: boolean;
|
|
35
|
+
/**
|
|
36
|
+
* Component that replaces the native `form` element, such as a framework
|
|
37
|
+
* form primitive.
|
|
38
|
+
*
|
|
39
|
+
* The substitution API is shared with `Link` and `Image`: `component` names
|
|
40
|
+
* the component and `componentProps` carries the props it needs.
|
|
41
|
+
*/
|
|
42
|
+
component?: ElementType;
|
|
43
|
+
/**
|
|
44
|
+
* Additional props for `component`.
|
|
45
|
+
*/
|
|
46
|
+
componentProps?: Record<string, unknown>;
|
|
47
|
+
}
|
|
48
|
+
/**
|
|
49
|
+
* A framework-native form element.
|
|
50
|
+
*
|
|
51
|
+
* Form wraps the native `form` element the way `Link` wraps the anchor and
|
|
52
|
+
* `Image` wraps the picture, so form-level improvements have one home without
|
|
53
|
+
* the framework taking responsibility for form state. It preserves native
|
|
54
|
+
* submission and validation: `action`, `method`, `encType`, `target`,
|
|
55
|
+
* `noValidate` and the submit event all pass through untouched, and the
|
|
56
|
+
* forwarded ref reaches the element itself.
|
|
57
|
+
*
|
|
58
|
+
* It is deliberately thin, because a consumer's form state belongs to the
|
|
59
|
+
* consumer or to a form library. There is no AsheeUI field registry, no
|
|
60
|
+
* validation schema, and no submission state: `onSubmit` is the native event,
|
|
61
|
+
* so a form library binds to it exactly as it binds to a plain form.
|
|
62
|
+
*
|
|
63
|
+
* Fields keep their own presentation through the framework's field
|
|
64
|
+
* components, and the component renders an AsheeUI `Button` as the submit
|
|
65
|
+
* control when a label is given for it. Page layout stays with the consumer's
|
|
66
|
+
* Tailwind classes.
|
|
67
|
+
*
|
|
68
|
+
* The form never moves focus, on mount or on a rejected submission: where a
|
|
69
|
+
* consumer sends focus after a failed validation is a consumer decision.
|
|
70
|
+
*
|
|
71
|
+
* The form element itself can be replaced, the way `Link` replaces the anchor
|
|
72
|
+
* and `Image` replaces the picture: pass `component` to name a form component
|
|
73
|
+
* and `componentProps` for the props it needs.
|
|
74
|
+
*
|
|
75
|
+
* @param props - Form configuration options and native form attributes.
|
|
76
|
+
* @param props.children - The fields and other content of the form.
|
|
77
|
+
* @param props.legend - Legend that groups the fields.
|
|
78
|
+
* @param props.submitLabel - Label of the submit control the component renders.
|
|
79
|
+
* @param props.isPending - Whether a submission is in progress. Defaults to false.
|
|
80
|
+
* @param props.component - Component that replaces the native form element.
|
|
81
|
+
* @param props.componentProps - Additional props for that component.
|
|
82
|
+
* @param props.submitVariant - Style of the submit control. Defaults to the configured value.
|
|
83
|
+
* @param props.submitColor - Colour of the submit control. Defaults to the configured value.
|
|
84
|
+
* @param props.submitSize - Size of the submit control. Defaults to "md".
|
|
85
|
+
* @param props.submitRadius - Corner rounding of the submit control. Defaults to "md".
|
|
86
|
+
* @param props.className - Extra classes applied last.
|
|
87
|
+
*
|
|
88
|
+
* @example
|
|
89
|
+
* ```tsx
|
|
90
|
+
* <Form legend="Invoice details" submitLabel="Save" onSubmit={handleSubmit}>
|
|
91
|
+
* <Input label="Reference" name="reference" />
|
|
92
|
+
* <Textarea label="Notes" name="notes" />
|
|
93
|
+
* </Form>
|
|
94
|
+
* ```
|
|
95
|
+
*
|
|
96
|
+
* @example
|
|
97
|
+
* ```tsx
|
|
98
|
+
* // A form library binds to the native submit event, unchanged.
|
|
99
|
+
* <Form onSubmit={form.handleSubmit(save)}>
|
|
100
|
+
* <Input label="Email" name="email" />
|
|
101
|
+
* </Form>
|
|
102
|
+
* ```
|
|
103
|
+
*
|
|
104
|
+
* @see FormConfig - The configuration type for component defaults.
|
|
105
|
+
* @see Button - The submit control the component renders.
|
|
106
|
+
*/
|
|
107
|
+
export declare const Form: import('react').ForwardRefExoticComponent<FormProps & import('react').RefAttributes<HTMLFormElement>>;
|
|
108
|
+
export {};
|
|
109
|
+
//# sourceMappingURL=Form.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Form.d.ts","sourceRoot":"","sources":["../../../src/components/form/Form.tsx"],"names":[],"mappings":"AAAA;;;;GAIG;AAIH,OAAO,EACL,KAAK,WAAW,EAChB,KAAK,kBAAkB,EAEvB,KAAK,SAAS,EACf,MAAM,OAAO,CAAC;AAMf,OAAO,EAAwB,KAAK,UAAU,EAAE,MAAM,eAAe,CAAC;AAQtE,KAAK,aAAa,GAAG,UAAU,GAC7B,IAAI,CAAC,kBAAkB,CAAC,eAAe,CAAC,EAAE,OAAO,GAAG,UAAU,CAAC,CAAC;AAElE;;GAEG;AACH,MAAM,WAAW,SAAU,SAAQ,aAAa;IAC9C;;OAEG;IACH,QAAQ,CAAC,EAAE,SAAS,CAAC;IAErB;;;;;;OAMG;IACH,MAAM,CAAC,EAAE,MAAM,CAAC;IAEhB;;;;;OAKG;IACH,WAAW,CAAC,EAAE,MAAM,CAAC;IAErB;;;;;;OAMG;IACH,SAAS,CAAC,EAAE,OAAO,CAAC;IAEpB;;;;;;OAMG;IACH,SAAS,CAAC,EAAE,WAAW,CAAC;IAExB;;OAEG;IACH,cAAc,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;CAC1C;AAED;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA0DG;AACH,eAAO,MAAM,IAAI,uGAyFhB,CAAC"}
|
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
"use client";
|
|
3
|
+
import { cn as e } from "../../utils/cn.js";
|
|
4
|
+
import { useAsheeConfig as t } from "../../libs/context.js";
|
|
5
|
+
import { resolveCascade as n, resolveRadiusKey as r } from "../../utils/resolve-token.js";
|
|
6
|
+
import { Button as i } from "../button/Button.js";
|
|
7
|
+
import { FALLBACK_FORM_CONFIG as a } from "./form-config.js";
|
|
8
|
+
import { FORM_BASE_CLASS as o, FORM_FIELD_GROUP_CLASS as s, FORM_LEGEND_CLASS as c } from "./form-styles.js";
|
|
9
|
+
import { forwardRef as l } from "react";
|
|
10
|
+
import { Fragment as u, jsx as d, jsxs as f } from "react/jsx-runtime";
|
|
11
|
+
//#region src/components/form/Form.tsx
|
|
12
|
+
var p = l(({ children: l, legend: p, submitLabel: m, isPending: h = !1, component: g, componentProps: _, submitVariant: v, submitColor: y, submitSize: b, submitRadius: x, className: S, ...C }, w) => {
|
|
13
|
+
let T = t(), E = T.components?.form, D = n(v, E?.submitVariant, T.defaultVariant, a.submitVariant), O = n(y, E?.submitColor, T.defaultColor, a.submitColor), k = n(b, E?.submitSize, void 0, a.submitSize), A = r(x, E?.submitRadius, T.defaultRadius, a.submitRadius), j = /* @__PURE__ */ f(u, { children: [l, m && /* @__PURE__ */ d("div", {
|
|
14
|
+
className: "flex items-center gap-2 mt-4",
|
|
15
|
+
children: /* @__PURE__ */ d(i, {
|
|
16
|
+
type: "submit",
|
|
17
|
+
variant: D,
|
|
18
|
+
color: O,
|
|
19
|
+
size: k,
|
|
20
|
+
radius: A,
|
|
21
|
+
isLoading: h,
|
|
22
|
+
isDisabled: h,
|
|
23
|
+
children: m
|
|
24
|
+
})
|
|
25
|
+
})] });
|
|
26
|
+
return /* @__PURE__ */ d(g || "form", {
|
|
27
|
+
ref: w,
|
|
28
|
+
className: e(o, S),
|
|
29
|
+
...C,
|
|
30
|
+
..._,
|
|
31
|
+
children: p ? /* @__PURE__ */ f("fieldset", {
|
|
32
|
+
className: s,
|
|
33
|
+
children: [/* @__PURE__ */ d("legend", {
|
|
34
|
+
className: c,
|
|
35
|
+
children: p
|
|
36
|
+
}), j]
|
|
37
|
+
}) : j
|
|
38
|
+
});
|
|
39
|
+
});
|
|
40
|
+
p.displayName = "Form";
|
|
41
|
+
//#endregion
|
|
42
|
+
export { p as Form };
|
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
import { Color, Radius, Size, Variant } from '../../shared';
|
|
2
|
+
/**
|
|
3
|
+
* Theme configuration options for the Form component.
|
|
4
|
+
*
|
|
5
|
+
* Set under `components.form` in the AsheeUI config. Values feed the
|
|
6
|
+
* component-level fallback tier of the theme cascade.
|
|
7
|
+
*
|
|
8
|
+
* The form element itself carries no visual treatment: it is a grouping and
|
|
9
|
+
* submission element, and the fields inside it style themselves. These options
|
|
10
|
+
* describe the submit control the component renders when a label is given for
|
|
11
|
+
* it.
|
|
12
|
+
*/
|
|
13
|
+
export interface FormConfig {
|
|
14
|
+
/**
|
|
15
|
+
* Visual style variant of the submit control.
|
|
16
|
+
*
|
|
17
|
+
* @default "solid"
|
|
18
|
+
*/
|
|
19
|
+
submitVariant?: Variant;
|
|
20
|
+
/**
|
|
21
|
+
* Theme accent colour of the submit control.
|
|
22
|
+
*
|
|
23
|
+
* @default "primary"
|
|
24
|
+
*/
|
|
25
|
+
submitColor?: Color;
|
|
26
|
+
/**
|
|
27
|
+
* Size of the submit control.
|
|
28
|
+
*
|
|
29
|
+
* @default "md"
|
|
30
|
+
*/
|
|
31
|
+
submitSize?: Size;
|
|
32
|
+
/**
|
|
33
|
+
* Corner rounding of the submit control.
|
|
34
|
+
*
|
|
35
|
+
* @default "md"
|
|
36
|
+
*/
|
|
37
|
+
submitRadius?: Radius;
|
|
38
|
+
}
|
|
39
|
+
/**
|
|
40
|
+
* Default config values registered for the Form component.
|
|
41
|
+
*
|
|
42
|
+
* The visual tokens are intentionally absent so they inherit from the global
|
|
43
|
+
* defaults and the built-in fallback.
|
|
44
|
+
*/
|
|
45
|
+
export declare const defaultFormConfig: FormConfig;
|
|
46
|
+
/**
|
|
47
|
+
* Hard fallback values used when no config tier provides a value.
|
|
48
|
+
* These values are used when instance props, component config,
|
|
49
|
+
* and global defaults are all undefined.
|
|
50
|
+
*/
|
|
51
|
+
export declare const FALLBACK_FORM_CONFIG: Required<FormConfig>;
|
|
52
|
+
declare module "../../libs/registry" {
|
|
53
|
+
interface ComponentTypeConfigRegistry {
|
|
54
|
+
form: FormConfig;
|
|
55
|
+
}
|
|
56
|
+
}
|
|
57
|
+
//# sourceMappingURL=form-config.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"form-config.d.ts","sourceRoot":"","sources":["../../../src/components/form/form-config.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAGH,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,EAAE,IAAI,EAAE,OAAO,EAAE,MAAM,cAAc,CAAC;AAEjE;;;;;;;;;;GAUG;AACH,MAAM,WAAW,UAAU;IACzB;;;;OAIG;IACH,aAAa,CAAC,EAAE,OAAO,CAAC;IAExB;;;;OAIG;IACH,WAAW,CAAC,EAAE,KAAK,CAAC;IAEpB;;;;OAIG;IACH,UAAU,CAAC,EAAE,IAAI,CAAC;IAElB;;;;OAIG;IACH,YAAY,CAAC,EAAE,MAAM,CAAC;CACvB;AAED;;;;;GAKG;AACH,eAAO,MAAM,iBAAiB,EAAE,UAE/B,CAAC;AAEF;;;;GAIG;AACH,eAAO,MAAM,oBAAoB,EAAE,QAAQ,CAAC,UAAU,CAK5C,CAAC;AAEX,OAAO,QAAQ,qBAAqB,CAAC;IACnC,UAAU,2BAA2B;QACnC,IAAI,EAAE,UAAU,CAAC;KAClB;CACF"}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
import { registerComponentDefaults as e } from "../../libs/registry.js";
|
|
3
|
+
//#region src/components/form/form-config.ts
|
|
4
|
+
var t = { submitRadius: "md" }, n = {
|
|
5
|
+
submitVariant: "solid",
|
|
6
|
+
submitColor: "primary",
|
|
7
|
+
submitSize: "md",
|
|
8
|
+
submitRadius: "md"
|
|
9
|
+
};
|
|
10
|
+
e("form", t);
|
|
11
|
+
//#endregion
|
|
12
|
+
export { n as FALLBACK_FORM_CONFIG, t as defaultFormConfig };
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Form component styles for AsheeUI.
|
|
3
|
+
* This file provides the static classes the Form component is built from.
|
|
4
|
+
*
|
|
5
|
+
* The list is deliberately short: a form groups and submits, and page layout
|
|
6
|
+
* belongs to the consumer's Tailwind classes. Nothing here styles
|
|
7
|
+
* a field, because fields are the framework's field components.
|
|
8
|
+
*/
|
|
9
|
+
/**
|
|
10
|
+
* Base classes for the form element.
|
|
11
|
+
*/
|
|
12
|
+
export declare const FORM_BASE_CLASS = "w-full";
|
|
13
|
+
/**
|
|
14
|
+
* Classes for the group that wraps the fields when the consumer names them.
|
|
15
|
+
* The browser's default fieldset frame is removed, because the grouping is
|
|
16
|
+
* semantic rather than visual.
|
|
17
|
+
*/
|
|
18
|
+
export declare const FORM_FIELD_GROUP_CLASS = "border-0 p-0 m-0 min-w-0";
|
|
19
|
+
/**
|
|
20
|
+
* Classes for the legend of that group.
|
|
21
|
+
*/
|
|
22
|
+
export declare const FORM_LEGEND_CLASS = "p-0 mb-2 text-sm font-medium text-foreground";
|
|
23
|
+
/**
|
|
24
|
+
* Classes for the row that holds the submit control.
|
|
25
|
+
*/
|
|
26
|
+
export declare const FORM_SUBMIT_ROW_CLASS = "flex items-center gap-2 mt-4";
|
|
27
|
+
//# sourceMappingURL=form-styles.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"form-styles.d.ts","sourceRoot":"","sources":["../../../src/components/form/form-styles.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AAEH;;GAEG;AACH,eAAO,MAAM,eAAe,WAAW,CAAC;AAExC;;;;GAIG;AACH,eAAO,MAAM,sBAAsB,6BAA6B,CAAC;AAEjE;;GAEG;AACH,eAAO,MAAM,iBAAiB,iDAAiD,CAAC;AAEhF;;GAEG;AACH,eAAO,MAAM,qBAAqB,iCAAiC,CAAC"}
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
//#region src/components/form/form-styles.ts
|
|
3
|
+
var e = "w-full", t = "border-0 p-0 m-0 min-w-0", n = "p-0 mb-2 text-sm font-medium text-foreground", r = "flex items-center gap-2 mt-4";
|
|
4
|
+
//#endregion
|
|
5
|
+
export { e as FORM_BASE_CLASS, t as FORM_FIELD_GROUP_CLASS, n as FORM_LEGEND_CLASS, r as FORM_SUBMIT_ROW_CLASS };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/form/index.ts"],"names":[],"mappings":"AAAA,cAAc,QAAQ,CAAC;AACvB,cAAc,eAAe,CAAC"}
|