@xerobi/ui 0.0.0-stage → 0.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/CHANGELOG.md +20 -0
- package/LICENSE +21 -0
- package/README.md +164 -2
- package/dist/blocks/data-table/grid/data-grid.d.ts +6 -0
- package/dist/blocks/data-table/grid/data-grid.js +147 -0
- package/dist/blocks/data-table/grid/index.d.ts +2 -0
- package/dist/blocks/data-table/grid/index.js +1 -0
- package/dist/blocks/data-table/grid/types.d.ts +47 -0
- package/dist/blocks/data-table/grid/types.js +1 -0
- package/dist/blocks/data-table/index.d.ts +3 -0
- package/dist/blocks/data-table/index.js +3 -0
- package/dist/blocks/data-table/table/index.d.ts +7 -0
- package/dist/blocks/data-table/table/index.js +7 -0
- package/dist/blocks/data-table/table/table-empty-rows.d.ts +5 -0
- package/dist/blocks/data-table/table/table-empty-rows.js +8 -0
- package/dist/blocks/data-table/table/table-head-custom.d.ts +18 -0
- package/dist/blocks/data-table/table/table-head-custom.js +13 -0
- package/dist/blocks/data-table/table/table-no-data.d.ts +7 -0
- package/dist/blocks/data-table/table/table-no-data.js +8 -0
- package/dist/blocks/data-table/table/table-pagination-custom.d.ts +16 -0
- package/dist/blocks/data-table/table/table-pagination-custom.js +13 -0
- package/dist/blocks/data-table/table/table-selected-action.d.ts +11 -0
- package/dist/blocks/data-table/table/table-selected-action.js +9 -0
- package/dist/blocks/data-table/table/table-skeleton.d.ts +5 -0
- package/dist/blocks/data-table/table/table-skeleton.js +7 -0
- package/dist/blocks/data-table/table/utils.d.ts +1 -0
- package/dist/blocks/data-table/table/utils.js +3 -0
- package/dist/blocks/data-table/tanstack.d.ts +2 -0
- package/dist/blocks/data-table/tanstack.js +1 -0
- package/dist/blocks/filters-result/filters-block.d.ts +7 -0
- package/dist/blocks/filters-result/filters-block.js +8 -0
- package/dist/blocks/filters-result/filters-result.d.ts +16 -0
- package/dist/blocks/filters-result/filters-result.js +10 -0
- package/dist/blocks/filters-result/index.d.ts +2 -0
- package/dist/blocks/filters-result/index.js +2 -0
- package/dist/blocks/form/field-autocomplete.d.ts +18 -0
- package/dist/blocks/form/field-autocomplete.js +27 -0
- package/dist/blocks/form/field-checkbox.d.ts +25 -0
- package/dist/blocks/form/field-checkbox.js +23 -0
- package/dist/blocks/form/field-code.d.ts +8 -0
- package/dist/blocks/form/field-code.js +8 -0
- package/dist/blocks/form/field-controller.d.ts +23 -0
- package/dist/blocks/form/field-controller.js +32 -0
- package/dist/blocks/form/field-country-select.d.ts +5 -0
- package/dist/blocks/form/field-country-select.js +9 -0
- package/dist/blocks/form/field-date-picker.d.ts +14 -0
- package/dist/blocks/form/field-date-picker.js +40 -0
- package/dist/blocks/form/field-editor.d.ts +5 -0
- package/dist/blocks/form/field-editor.js +7 -0
- package/dist/blocks/form/field-number-input.d.ts +5 -0
- package/dist/blocks/form/field-number-input.js +7 -0
- package/dist/blocks/form/field-phone.d.ts +5 -0
- package/dist/blocks/form/field-phone.js +7 -0
- package/dist/blocks/form/field-radio-group.d.ts +12 -0
- package/dist/blocks/form/field-radio-group.js +15 -0
- package/dist/blocks/form/field-rating.d.ts +6 -0
- package/dist/blocks/form/field-rating.js +8 -0
- package/dist/blocks/form/field-select.d.ts +21 -0
- package/dist/blocks/form/field-select.js +24 -0
- package/dist/blocks/form/field-slider.d.ts +6 -0
- package/dist/blocks/form/field-slider.js +8 -0
- package/dist/blocks/form/field-switch.d.ts +25 -0
- package/dist/blocks/form/field-switch.js +23 -0
- package/dist/blocks/form/field-text.d.ts +8 -0
- package/dist/blocks/form/field-text.js +28 -0
- package/dist/blocks/form/field-upload.d.ts +7 -0
- package/dist/blocks/form/field-upload.js +17 -0
- package/dist/blocks/form/fields.d.ts +38 -0
- package/dist/blocks/form/fields.js +39 -0
- package/dist/blocks/form/form-context.d.ts +13 -0
- package/dist/blocks/form/form-context.js +18 -0
- package/dist/blocks/form/form-provider.d.ts +6 -0
- package/dist/blocks/form/form-provider.js +10 -0
- package/dist/blocks/form/help-text.d.ts +6 -0
- package/dist/blocks/form/help-text.js +8 -0
- package/dist/blocks/form/index.d.ts +23 -0
- package/dist/blocks/form/index.js +22 -0
- package/dist/blocks/form/schema-helper.d.ts +38 -0
- package/dist/blocks/form/schema-helper.js +80 -0
- package/dist/blocks/index.d.ts +9 -0
- package/dist/blocks/index.js +9 -0
- package/dist/blocks/mega-menu/classes.d.ts +31 -0
- package/dist/blocks/mega-menu/classes.js +12 -0
- package/dist/blocks/mega-menu/components.d.ts +37 -0
- package/dist/blocks/mega-menu/components.js +78 -0
- package/dist/blocks/mega-menu/horizontal.d.ts +2 -0
- package/dist/blocks/mega-menu/horizontal.js +9 -0
- package/dist/blocks/mega-menu/index.d.ts +5 -0
- package/dist/blocks/mega-menu/index.js +4 -0
- package/dist/blocks/mega-menu/mega-nav-list.d.ts +7 -0
- package/dist/blocks/mega-menu/mega-nav-list.js +25 -0
- package/dist/blocks/mega-menu/mobile.d.ts +16 -0
- package/dist/blocks/mega-menu/mobile.js +27 -0
- package/dist/blocks/mega-menu/types.d.ts +65 -0
- package/dist/blocks/mega-menu/types.js +1 -0
- package/dist/blocks/mega-menu/vertical.d.ts +2 -0
- package/dist/blocks/mega-menu/vertical.js +9 -0
- package/dist/blocks/nav-basic/classes.d.ts +26 -0
- package/dist/blocks/nav-basic/classes.js +7 -0
- package/dist/blocks/nav-basic/desktop.d.ts +2 -0
- package/dist/blocks/nav-basic/desktop.js +26 -0
- package/dist/blocks/nav-basic/index.d.ts +4 -0
- package/dist/blocks/nav-basic/index.js +3 -0
- package/dist/blocks/nav-basic/mobile.d.ts +2 -0
- package/dist/blocks/nav-basic/mobile.js +20 -0
- package/dist/blocks/nav-basic/types.d.ts +14 -0
- package/dist/blocks/nav-basic/types.js +1 -0
- package/dist/blocks/nav-core/elements.d.ts +32 -0
- package/dist/blocks/nav-core/elements.js +37 -0
- package/dist/blocks/nav-core/index.d.ts +6 -0
- package/dist/blocks/nav-core/index.js +6 -0
- package/dist/blocks/nav-core/link.d.ts +12 -0
- package/dist/blocks/nav-core/link.js +16 -0
- package/dist/blocks/nav-core/nav-dropdown.d.ts +19 -0
- package/dist/blocks/nav-core/nav-dropdown.js +9 -0
- package/dist/blocks/nav-core/nav-item.d.ts +13 -0
- package/dist/blocks/nav-core/nav-item.js +36 -0
- package/dist/blocks/nav-core/types.d.ts +38 -0
- package/dist/blocks/nav-core/types.js +1 -0
- package/dist/blocks/nav-core/utils.d.ts +4 -0
- package/dist/blocks/nav-core/utils.js +17 -0
- package/dist/blocks/nav-section/classes.d.ts +27 -0
- package/dist/blocks/nav-section/classes.js +8 -0
- package/dist/blocks/nav-section/horizontal.d.ts +2 -0
- package/dist/blocks/nav-section/horizontal.js +12 -0
- package/dist/blocks/nav-section/hover-list.d.ts +13 -0
- package/dist/blocks/nav-section/hover-list.js +27 -0
- package/dist/blocks/nav-section/index.d.ts +5 -0
- package/dist/blocks/nav-section/index.js +4 -0
- package/dist/blocks/nav-section/mini.d.ts +2 -0
- package/dist/blocks/nav-section/mini.js +12 -0
- package/dist/blocks/nav-section/types.d.ts +20 -0
- package/dist/blocks/nav-section/types.js +1 -0
- package/dist/blocks/nav-section/vertical.d.ts +2 -0
- package/dist/blocks/nav-section/vertical.js +28 -0
- package/dist/blocks/settings/index.d.ts +5 -0
- package/dist/blocks/settings/index.js +4 -0
- package/dist/blocks/settings/settings-button.d.ts +1 -0
- package/dist/blocks/settings/settings-button.js +9 -0
- package/dist/blocks/settings/settings-config.d.ts +5 -0
- package/dist/blocks/settings/settings-config.js +14 -0
- package/dist/blocks/settings/settings-context.d.ts +7 -0
- package/dist/blocks/settings/settings-context.js +51 -0
- package/dist/blocks/settings/settings-drawer.d.ts +2 -0
- package/dist/blocks/settings/settings-drawer.js +61 -0
- package/dist/blocks/settings/types.d.ts +34 -0
- package/dist/blocks/settings/types.js +1 -0
- package/dist/blocks/sidebar/index.d.ts +1 -0
- package/dist/blocks/sidebar/index.js +1 -0
- package/dist/blocks/sidebar/sidebar.d.ts +63 -0
- package/dist/blocks/sidebar/sidebar.js +256 -0
- package/dist/components/accordion/accordion.d.ts +6 -0
- package/dist/components/accordion/accordion.js +18 -0
- package/dist/components/accordion/index.d.ts +1 -0
- package/dist/components/accordion/index.js +1 -0
- package/dist/components/alert/alert.d.ts +10 -0
- package/dist/components/alert/alert.js +33 -0
- package/dist/components/alert/index.d.ts +1 -0
- package/dist/components/alert/index.js +1 -0
- package/dist/components/alert-dialog/alert-dialog.d.ts +18 -0
- package/dist/components/alert-dialog/alert-dialog.js +42 -0
- package/dist/components/alert-dialog/index.d.ts +1 -0
- package/dist/components/alert-dialog/index.js +1 -0
- package/dist/components/animate/animate-border.d.ts +31 -0
- package/dist/components/animate/animate-border.js +77 -0
- package/dist/components/animate/animate-count-up.d.ts +12 -0
- package/dist/components/animate/animate-count-up.js +33 -0
- package/dist/components/animate/animate-logo.d.ts +10 -0
- package/dist/components/animate/animate-logo.js +20 -0
- package/dist/components/animate/animate-text.d.ts +19 -0
- package/dist/components/animate/animate-text.js +44 -0
- package/dist/components/animate/features.d.ts +2 -0
- package/dist/components/animate/features.js +2 -0
- package/dist/components/animate/index.d.ts +9 -0
- package/dist/components/animate/index.js +9 -0
- package/dist/components/animate/motion-container.d.ts +8 -0
- package/dist/components/animate/motion-container.js +7 -0
- package/dist/components/animate/motion-lazy.d.ts +4 -0
- package/dist/components/animate/motion-lazy.js +7 -0
- package/dist/components/animate/motion-viewport.d.ts +7 -0
- package/dist/components/animate/motion-viewport.js +24 -0
- package/dist/components/animate/scroll-progress/index.d.ts +2 -0
- package/dist/components/animate/scroll-progress/index.js +2 -0
- package/dist/components/animate/scroll-progress/scroll-progress.d.ts +22 -0
- package/dist/components/animate/scroll-progress/scroll-progress.js +37 -0
- package/dist/components/animate/scroll-progress/use-scroll-progress.d.ts +10 -0
- package/dist/components/animate/scroll-progress/use-scroll-progress.js +9 -0
- package/dist/components/animate/variants/actions.d.ts +9 -0
- package/dist/components/animate/variants/actions.js +17 -0
- package/dist/components/animate/variants/background.d.ts +6 -0
- package/dist/components/animate/variants/background.js +110 -0
- package/dist/components/animate/variants/bounce.d.ts +8 -0
- package/dist/components/animate/variants/bounce.js +92 -0
- package/dist/components/animate/variants/container.d.ts +7 -0
- package/dist/components/animate/variants/container.js +16 -0
- package/dist/components/animate/variants/fade.d.ts +9 -0
- package/dist/components/animate/variants/fade.js +77 -0
- package/dist/components/animate/variants/flip.d.ts +9 -0
- package/dist/components/animate/variants/flip.js +28 -0
- package/dist/components/animate/variants/index.d.ts +12 -0
- package/dist/components/animate/variants/index.js +12 -0
- package/dist/components/animate/variants/path.d.ts +2 -0
- package/dist/components/animate/variants/path.js +12 -0
- package/dist/components/animate/variants/rotate.d.ts +9 -0
- package/dist/components/animate/variants/rotate.js +20 -0
- package/dist/components/animate/variants/scale.d.ts +8 -0
- package/dist/components/animate/variants/scale.js +37 -0
- package/dist/components/animate/variants/slide.d.ts +9 -0
- package/dist/components/animate/variants/slide.js +51 -0
- package/dist/components/animate/variants/transition.d.ts +3 -0
- package/dist/components/animate/variants/transition.js +10 -0
- package/dist/components/animate/variants/zoom.d.ts +9 -0
- package/dist/components/animate/variants/zoom.js +120 -0
- package/dist/components/aspect-ratio/aspect-ratio.d.ts +4 -0
- package/dist/components/aspect-ratio/aspect-ratio.js +9 -0
- package/dist/components/aspect-ratio/index.d.ts +1 -0
- package/dist/components/aspect-ratio/index.js +1 -0
- package/dist/components/avatar/avatar.d.ts +11 -0
- package/dist/components/avatar/avatar.js +23 -0
- package/dist/components/avatar/index.d.ts +1 -0
- package/dist/components/avatar/index.js +1 -0
- package/dist/components/badge/badge.d.ts +15 -0
- package/dist/components/badge/badge.js +79 -0
- package/dist/components/badge/index.d.ts +1 -0
- package/dist/components/badge/index.js +1 -0
- package/dist/components/breadcrumb/breadcrumb.d.ts +10 -0
- package/dist/components/breadcrumb/breadcrumb.js +37 -0
- package/dist/components/breadcrumb/index.d.ts +1 -0
- package/dist/components/breadcrumb/index.js +1 -0
- package/dist/components/button/button.d.ts +20 -0
- package/dist/components/button/button.js +120 -0
- package/dist/components/button/index.d.ts +1 -0
- package/dist/components/button/index.js +1 -0
- package/dist/components/button-group/button-group.d.ts +10 -0
- package/dist/components/button-group/button-group.js +37 -0
- package/dist/components/button-group/index.d.ts +1 -0
- package/dist/components/button-group/index.js +1 -0
- package/dist/components/calendar/calendar.d.ts +10 -0
- package/dist/components/calendar/calendar.js +76 -0
- package/dist/components/calendar/index.d.ts +1 -0
- package/dist/components/calendar/index.js +1 -0
- package/dist/components/card/card.d.ts +11 -0
- package/dist/components/card/card.js +25 -0
- package/dist/components/card/index.d.ts +1 -0
- package/dist/components/card/index.js +1 -0
- package/dist/components/carousel/breakpoints.d.ts +7 -0
- package/dist/components/carousel/breakpoints.js +7 -0
- package/dist/components/carousel/carousel.d.ts +2 -0
- package/dist/components/carousel/carousel.js +13 -0
- package/dist/components/carousel/classes.d.ts +31 -0
- package/dist/components/carousel/classes.js +32 -0
- package/dist/components/carousel/components/arrow-button.d.ts +2 -0
- package/dist/components/carousel/components/arrow-button.js +10 -0
- package/dist/components/carousel/components/carousel-arrow-buttons.d.ts +4 -0
- package/dist/components/carousel/components/carousel-arrow-buttons.js +15 -0
- package/dist/components/carousel/components/carousel-dot-buttons.d.ts +2 -0
- package/dist/components/carousel/components/carousel-dot-buttons.js +19 -0
- package/dist/components/carousel/components/carousel-progress-bar.d.ts +2 -0
- package/dist/components/carousel/components/carousel-progress-bar.js +9 -0
- package/dist/components/carousel/components/carousel-slide.d.ts +2 -0
- package/dist/components/carousel/components/carousel-slide.js +16 -0
- package/dist/components/carousel/components/carousel-thumb.d.ts +2 -0
- package/dist/components/carousel/components/carousel-thumb.js +7 -0
- package/dist/components/carousel/components/carousel-thumbs.d.ts +2 -0
- package/dist/components/carousel/components/carousel-thumbs.js +15 -0
- package/dist/components/carousel/components/index.d.ts +7 -0
- package/dist/components/carousel/components/index.js +7 -0
- package/dist/components/carousel/hooks/index.d.ts +7 -0
- package/dist/components/carousel/hooks/index.js +7 -0
- package/dist/components/carousel/hooks/use-carousel-arrows.d.ts +3 -0
- package/dist/components/carousel/hooks/use-carousel-arrows.js +33 -0
- package/dist/components/carousel/hooks/use-carousel-auto-play.d.ts +3 -0
- package/dist/components/carousel/hooks/use-carousel-auto-play.js +31 -0
- package/dist/components/carousel/hooks/use-carousel-auto-scroll.d.ts +3 -0
- package/dist/components/carousel/hooks/use-carousel-auto-scroll.js +31 -0
- package/dist/components/carousel/hooks/use-carousel-dots.d.ts +3 -0
- package/dist/components/carousel/hooks/use-carousel-dots.js +34 -0
- package/dist/components/carousel/hooks/use-carousel-parallax.d.ts +3 -0
- package/dist/components/carousel/hooks/use-carousel-parallax.js +62 -0
- package/dist/components/carousel/hooks/use-carousel-progress.d.ts +3 -0
- package/dist/components/carousel/hooks/use-carousel-progress.js +17 -0
- package/dist/components/carousel/hooks/use-carousel.d.ts +3 -0
- package/dist/components/carousel/hooks/use-carousel.js +56 -0
- package/dist/components/carousel/hooks/use-thumbs.d.ts +3 -0
- package/dist/components/carousel/hooks/use-thumbs.js +35 -0
- package/dist/components/carousel/hooks/use-viewport-width.d.ts +1 -0
- package/dist/components/carousel/hooks/use-viewport-width.js +9 -0
- package/dist/components/carousel/index.d.ts +6 -0
- package/dist/components/carousel/index.js +5 -0
- package/dist/components/carousel/types.d.ts +104 -0
- package/dist/components/carousel/types.js +1 -0
- package/dist/components/carousel/utils.d.ts +5 -0
- package/dist/components/carousel/utils.js +30 -0
- package/dist/components/chart/chart.d.ts +2 -0
- package/dist/components/chart/chart.js +14 -0
- package/dist/components/chart/classes.d.ts +15 -0
- package/dist/components/chart/classes.js +16 -0
- package/dist/components/chart/components/chart-legends.d.ts +16 -0
- package/dist/components/chart/components/chart-legends.js +7 -0
- package/dist/components/chart/components/chart-loading.d.ts +3 -0
- package/dist/components/chart/components/chart-loading.js +9 -0
- package/dist/components/chart/components/chart-select.d.ts +6 -0
- package/dist/components/chart/components/chart-select.js +14 -0
- package/dist/components/chart/components/index.d.ts +3 -0
- package/dist/components/chart/components/index.js +3 -0
- package/dist/components/chart/index.d.ts +5 -0
- package/dist/components/chart/index.js +4 -0
- package/dist/components/chart/types.d.ts +7 -0
- package/dist/components/chart/types.js +1 -0
- package/dist/components/chart/use-chart.d.ts +6 -0
- package/dist/components/chart/use-chart.js +129 -0
- package/dist/components/checkbox/checkbox.d.ts +7 -0
- package/dist/components/checkbox/checkbox.js +18 -0
- package/dist/components/checkbox/index.d.ts +1 -0
- package/dist/components/checkbox/index.js +1 -0
- package/dist/components/chip/chip.d.ts +23 -0
- package/dist/components/chip/chip.js +74 -0
- package/dist/components/chip/index.d.ts +1 -0
- package/dist/components/chip/index.js +1 -0
- package/dist/components/collapsible/collapsible.d.ts +5 -0
- package/dist/components/collapsible/collapsible.js +13 -0
- package/dist/components/collapsible/index.d.ts +1 -0
- package/dist/components/collapsible/index.js +1 -0
- package/dist/components/color-utils/classes.d.ts +13 -0
- package/dist/components/color-utils/classes.js +14 -0
- package/dist/components/color-utils/color-picker.d.ts +16 -0
- package/dist/components/color-utils/color-picker.js +40 -0
- package/dist/components/color-utils/color-preview.d.ts +12 -0
- package/dist/components/color-utils/color-preview.js +15 -0
- package/dist/components/color-utils/index.d.ts +3 -0
- package/dist/components/color-utils/index.js +3 -0
- package/dist/components/combobox/combobox.d.ts +24 -0
- package/dist/components/combobox/combobox.js +58 -0
- package/dist/components/combobox/index.d.ts +1 -0
- package/dist/components/combobox/index.js +1 -0
- package/dist/components/command/command.d.ts +19 -0
- package/dist/components/command/command.js +35 -0
- package/dist/components/command/index.d.ts +1 -0
- package/dist/components/command/index.js +1 -0
- package/dist/components/context-menu/context-menu.d.ts +29 -0
- package/dist/components/context-menu/context-menu.js +51 -0
- package/dist/components/context-menu/index.d.ts +1 -0
- package/dist/components/context-menu/index.js +1 -0
- package/dist/components/country-select/countries.d.ts +6 -0
- package/dist/components/country-select/countries.js +250 -0
- package/dist/components/country-select/country-select.d.ts +16 -0
- package/dist/components/country-select/country-select.js +37 -0
- package/dist/components/country-select/index.d.ts +3 -0
- package/dist/components/country-select/index.js +2 -0
- package/dist/components/custom-breadcrumbs/back-link.d.ts +7 -0
- package/dist/components/custom-breadcrumbs/back-link.js +12 -0
- package/dist/components/custom-breadcrumbs/breadcrumb-link.d.ts +11 -0
- package/dist/components/custom-breadcrumbs/breadcrumb-link.js +10 -0
- package/dist/components/custom-breadcrumbs/custom-breadcrumbs.d.ts +25 -0
- package/dist/components/custom-breadcrumbs/custom-breadcrumbs.js +13 -0
- package/dist/components/custom-breadcrumbs/index.d.ts +5 -0
- package/dist/components/custom-breadcrumbs/index.js +4 -0
- package/dist/components/custom-breadcrumbs/link.d.ts +4 -0
- package/dist/components/custom-breadcrumbs/link.js +6 -0
- package/dist/components/custom-breadcrumbs/more-links.d.ts +5 -0
- package/dist/components/custom-breadcrumbs/more-links.js +6 -0
- package/dist/components/custom-date-range-picker/custom-date-range-picker.d.ts +16 -0
- package/dist/components/custom-date-range-picker/custom-date-range-picker.js +31 -0
- package/dist/components/custom-date-range-picker/index.d.ts +2 -0
- package/dist/components/custom-date-range-picker/index.js +2 -0
- package/dist/components/custom-date-range-picker/use-date-range-picker.d.ts +18 -0
- package/dist/components/custom-date-range-picker/use-date-range-picker.js +33 -0
- package/dist/components/custom-dialog/confirm-dialog.d.ts +11 -0
- package/dist/components/custom-dialog/confirm-dialog.js +7 -0
- package/dist/components/custom-dialog/index.d.ts +1 -0
- package/dist/components/custom-dialog/index.js +1 -0
- package/dist/components/custom-popover/arrow.d.ts +10 -0
- package/dist/components/custom-popover/arrow.js +52 -0
- package/dist/components/custom-popover/custom-popover.d.ts +10 -0
- package/dist/components/custom-popover/custom-popover.js +25 -0
- package/dist/components/custom-popover/index.d.ts +2 -0
- package/dist/components/custom-popover/index.js +1 -0
- package/dist/components/custom-popover/placement.d.ts +8 -0
- package/dist/components/custom-popover/placement.js +11 -0
- package/dist/components/custom-popover/types.d.ts +20 -0
- package/dist/components/custom-popover/types.js +2 -0
- package/dist/components/custom-tabs/custom-tabs.d.ts +8 -0
- package/dist/components/custom-tabs/custom-tabs.js +11 -0
- package/dist/components/custom-tabs/index.d.ts +1 -0
- package/dist/components/custom-tabs/index.js +1 -0
- package/dist/components/dialog/dialog.d.ts +18 -0
- package/dist/components/dialog/dialog.js +40 -0
- package/dist/components/dialog/index.d.ts +1 -0
- package/dist/components/dialog/index.js +1 -0
- package/dist/components/direction/direction.d.ts +1 -0
- package/dist/components/direction/direction.js +2 -0
- package/dist/components/direction/index.d.ts +1 -0
- package/dist/components/direction/index.js +1 -0
- package/dist/components/drawer/drawer.d.ts +16 -0
- package/dist/components/drawer/drawer.js +75 -0
- package/dist/components/drawer/index.d.ts +1 -0
- package/dist/components/drawer/index.js +1 -0
- package/dist/components/dropdown-menu/dropdown-menu.d.ts +29 -0
- package/dist/components/dropdown-menu/dropdown-menu.js +51 -0
- package/dist/components/dropdown-menu/index.d.ts +1 -0
- package/dist/components/dropdown-menu/index.js +1 -0
- package/dist/components/editor/classes.d.ts +43 -0
- package/dist/components/editor/classes.js +44 -0
- package/dist/components/editor/components/code-highlight-block.d.ts +2 -0
- package/dist/components/editor/components/code-highlight-block.js +7 -0
- package/dist/components/editor/components/heading-block.d.ts +3 -0
- package/dist/components/editor/components/heading-block.js +22 -0
- package/dist/components/editor/components/image-block.d.ts +2 -0
- package/dist/components/editor/components/image-block.js +13 -0
- package/dist/components/editor/components/link-block.d.ts +2 -0
- package/dist/components/editor/components/link-block.js +16 -0
- package/dist/components/editor/components/toolbar-item.d.ts +6 -0
- package/dist/components/editor/components/toolbar-item.js +10 -0
- package/dist/components/editor/components/url-popover.d.ts +7 -0
- package/dist/components/editor/components/url-popover.js +19 -0
- package/dist/components/editor/editor.d.ts +13 -0
- package/dist/components/editor/editor.js +90 -0
- package/dist/components/editor/icons.d.ts +27 -0
- package/dist/components/editor/icons.js +26 -0
- package/dist/components/editor/index.d.ts +3 -0
- package/dist/components/editor/index.js +2 -0
- package/dist/components/editor/toolbar.d.ts +2 -0
- package/dist/components/editor/toolbar.js +20 -0
- package/dist/components/editor/types.d.ts +26 -0
- package/dist/components/editor/types.js +1 -0
- package/dist/components/empty-content/default-image.d.ts +2 -0
- package/dist/components/empty-content/default-image.js +2 -0
- package/dist/components/empty-content/empty-content.d.ts +15 -0
- package/dist/components/empty-content/empty-content.js +7 -0
- package/dist/components/empty-content/index.d.ts +2 -0
- package/dist/components/empty-content/index.js +2 -0
- package/dist/components/file-thumbnail/action-buttons.d.ts +2 -0
- package/dist/components/file-thumbnail/action-buttons.js +10 -0
- package/dist/components/file-thumbnail/classes.d.ts +7 -0
- package/dist/components/file-thumbnail/classes.js +8 -0
- package/dist/components/file-thumbnail/file-thumbnail.d.ts +2 -0
- package/dist/components/file-thumbnail/file-thumbnail.js +22 -0
- package/dist/components/file-thumbnail/icons.d.ts +2 -0
- package/dist/components/file-thumbnail/icons.js +39 -0
- package/dist/components/file-thumbnail/index.d.ts +6 -0
- package/dist/components/file-thumbnail/index.js +5 -0
- package/dist/components/file-thumbnail/types.d.ts +18 -0
- package/dist/components/file-thumbnail/types.js +1 -0
- package/dist/components/file-thumbnail/utils.d.ts +21 -0
- package/dist/components/file-thumbnail/utils.js +50 -0
- package/dist/components/flag-icon/classes.d.ts +4 -0
- package/dist/components/flag-icon/classes.js +5 -0
- package/dist/components/flag-icon/flag-icon.d.ts +8 -0
- package/dist/components/flag-icon/flag-icon.js +12 -0
- package/dist/components/flag-icon/index.d.ts +2 -0
- package/dist/components/flag-icon/index.js +2 -0
- package/dist/components/form-label/form-label.d.ts +3 -0
- package/dist/components/form-label/form-label.js +7 -0
- package/dist/components/form-label/index.d.ts +1 -0
- package/dist/components/form-label/index.js +1 -0
- package/dist/components/hover-card/hover-card.d.ts +5 -0
- package/dist/components/hover-card/hover-card.js +14 -0
- package/dist/components/hover-card/index.d.ts +1 -0
- package/dist/components/hover-card/index.js +1 -0
- package/dist/components/image/classes.d.ts +9 -0
- package/dist/components/image/classes.js +8 -0
- package/dist/components/image/image.d.ts +28 -0
- package/dist/components/image/image.js +58 -0
- package/dist/components/image/index.d.ts +2 -0
- package/dist/components/image/index.js +2 -0
- package/dist/components/image/placeholder.d.ts +1 -0
- package/dist/components/image/placeholder.js +1 -0
- package/dist/components/index.d.ts +84 -0
- package/dist/components/index.js +84 -0
- package/dist/components/input/index.d.ts +1 -0
- package/dist/components/input/index.js +1 -0
- package/dist/components/input/input.d.ts +3 -0
- package/dist/components/input/input.js +8 -0
- package/dist/components/input-group/index.d.ts +1 -0
- package/dist/components/input-group/index.js +1 -0
- package/dist/components/input-group/input-group.d.ts +18 -0
- package/dist/components/input-group/input-group.js +57 -0
- package/dist/components/input-otp/index.d.ts +1 -0
- package/dist/components/input-otp/index.js +1 -0
- package/dist/components/input-otp/input-otp.d.ts +11 -0
- package/dist/components/input-otp/input-otp.js +21 -0
- package/dist/components/item/index.d.ts +1 -0
- package/dist/components/item/index.js +1 -0
- package/dist/components/item/item.d.ts +22 -0
- package/dist/components/item/item.js +79 -0
- package/dist/components/kbd/index.d.ts +1 -0
- package/dist/components/kbd/index.js +1 -0
- package/dist/components/kbd/kbd.d.ts +3 -0
- package/dist/components/kbd/kbd.js +10 -0
- package/dist/components/label/classes.d.ts +4 -0
- package/dist/components/label/classes.js +5 -0
- package/dist/components/label/index.d.ts +2 -0
- package/dist/components/label/index.js +2 -0
- package/dist/components/label/label.d.ts +13 -0
- package/dist/components/label/label.js +10 -0
- package/dist/components/lightbox/classes.d.ts +3 -0
- package/dist/components/lightbox/classes.js +4 -0
- package/dist/components/lightbox/index.d.ts +4 -0
- package/dist/components/lightbox/index.js +3 -0
- package/dist/components/lightbox/lightbox.d.ts +2 -0
- package/dist/components/lightbox/lightbox.js +40 -0
- package/dist/components/lightbox/types.d.ts +11 -0
- package/dist/components/lightbox/types.js +1 -0
- package/dist/components/lightbox/use-light-box.d.ts +9 -0
- package/dist/components/lightbox/use-light-box.js +21 -0
- package/dist/components/lightbox/utils.d.ts +3 -0
- package/dist/components/lightbox/utils.js +22 -0
- package/dist/components/loading-screen/index.d.ts +2 -0
- package/dist/components/loading-screen/index.js +2 -0
- package/dist/components/loading-screen/loading-screen.d.ts +6 -0
- package/dist/components/loading-screen/loading-screen.js +8 -0
- package/dist/components/loading-screen/splash-screen.d.ts +7 -0
- package/dist/components/loading-screen/splash-screen.js +9 -0
- package/dist/components/logo/classes.d.ts +3 -0
- package/dist/components/logo/classes.js +4 -0
- package/dist/components/logo/index.d.ts +2 -0
- package/dist/components/logo/index.js +2 -0
- package/dist/components/logo/logo.d.ts +14 -0
- package/dist/components/logo/logo.js +22 -0
- package/dist/components/map/index.d.ts +4 -0
- package/dist/components/map/index.js +4 -0
- package/dist/components/map/map-controls.d.ts +14 -0
- package/dist/components/map/map-controls.js +6 -0
- package/dist/components/map/map-marker.d.ts +2 -0
- package/dist/components/map/map-marker.js +10 -0
- package/dist/components/map/map-popup.d.ts +3 -0
- package/dist/components/map/map-popup.js +6 -0
- package/dist/components/map/map.d.ts +5 -0
- package/dist/components/map/map.js +13 -0
- package/dist/components/markdown/classes.d.ts +10 -0
- package/dist/components/markdown/classes.js +11 -0
- package/dist/components/markdown/html-tags.d.ts +4 -0
- package/dist/components/markdown/html-tags.js +171 -0
- package/dist/components/markdown/html-to-markdown.d.ts +2 -0
- package/dist/components/markdown/html-to-markdown.js +28 -0
- package/dist/components/markdown/index.d.ts +4 -0
- package/dist/components/markdown/index.js +3 -0
- package/dist/components/markdown/markdown.d.ts +2 -0
- package/dist/components/markdown/markdown.js +35 -0
- package/dist/components/markdown/types.d.ts +8 -0
- package/dist/components/markdown/types.js +1 -0
- package/dist/components/menubar/index.d.ts +1 -0
- package/dist/components/menubar/index.js +1 -0
- package/dist/components/menubar/menubar.d.ts +29 -0
- package/dist/components/menubar/menubar.js +56 -0
- package/dist/components/native-select/index.d.ts +1 -0
- package/dist/components/native-select/index.js +1 -0
- package/dist/components/native-select/native-select.d.ts +8 -0
- package/dist/components/native-select/native-select.js +14 -0
- package/dist/components/navigation-menu/index.d.ts +1 -0
- package/dist/components/navigation-menu/index.js +1 -0
- package/dist/components/navigation-menu/navigation-menu.d.ts +11 -0
- package/dist/components/navigation-menu/navigation-menu.js +32 -0
- package/dist/components/number-input/index.d.ts +1 -0
- package/dist/components/number-input/index.js +1 -0
- package/dist/components/number-input/number-input.d.ts +29 -0
- package/dist/components/number-input/number-input.js +34 -0
- package/dist/components/organizational-chart/index.d.ts +2 -0
- package/dist/components/organizational-chart/index.js +1 -0
- package/dist/components/organizational-chart/organizational-chart.d.ts +2 -0
- package/dist/components/organizational-chart/organizational-chart.js +21 -0
- package/dist/components/organizational-chart/types.d.ts +15 -0
- package/dist/components/organizational-chart/types.js +1 -0
- package/dist/components/pagination/index.d.ts +1 -0
- package/dist/components/pagination/index.js +1 -0
- package/dist/components/pagination/pagination.d.ts +17 -0
- package/dist/components/pagination/pagination.js +27 -0
- package/dist/components/phone-input/index.d.ts +2 -0
- package/dist/components/phone-input/index.js +1 -0
- package/dist/components/phone-input/list-popover.d.ts +2 -0
- package/dist/components/phone-input/list-popover.js +33 -0
- package/dist/components/phone-input/phone-input.d.ts +2 -0
- package/dist/components/phone-input/phone-input.js +34 -0
- package/dist/components/phone-input/types.d.ts +28 -0
- package/dist/components/phone-input/types.js +1 -0
- package/dist/components/popover/index.d.ts +1 -0
- package/dist/components/popover/index.js +1 -0
- package/dist/components/popover/popover.d.ts +9 -0
- package/dist/components/popover/popover.js +23 -0
- package/dist/components/progress/index.d.ts +1 -0
- package/dist/components/progress/index.js +1 -0
- package/dist/components/progress/progress.d.ts +7 -0
- package/dist/components/progress/progress.js +20 -0
- package/dist/components/progress-bar/index.d.ts +1 -0
- package/dist/components/progress-bar/index.js +1 -0
- package/dist/components/progress-bar/progress-bar.d.ts +20 -0
- package/dist/components/progress-bar/progress-bar.js +51 -0
- package/dist/components/radio-group/index.d.ts +1 -0
- package/dist/components/radio-group/index.js +1 -0
- package/dist/components/radio-group/radio-group.d.ts +5 -0
- package/dist/components/radio-group/radio-group.js +12 -0
- package/dist/components/rating/index.d.ts +1 -0
- package/dist/components/rating/index.js +1 -0
- package/dist/components/rating/rating.d.ts +13 -0
- package/dist/components/rating/rating.js +25 -0
- package/dist/components/resizable/index.d.ts +1 -0
- package/dist/components/resizable/index.js +1 -0
- package/dist/components/resizable/resizable.d.ts +7 -0
- package/dist/components/resizable/resizable.js +14 -0
- package/dist/components/ripple/index.d.ts +1 -0
- package/dist/components/ripple/index.js +1 -0
- package/dist/components/ripple/ripple.d.ts +13 -0
- package/dist/components/ripple/ripple.js +113 -0
- package/dist/components/scroll-area/index.d.ts +1 -0
- package/dist/components/scroll-area/index.js +1 -0
- package/dist/components/scroll-area/scroll-area.d.ts +5 -0
- package/dist/components/scroll-area/scroll-area.js +11 -0
- package/dist/components/scrollbar/classes.d.ts +3 -0
- package/dist/components/scrollbar/classes.js +4 -0
- package/dist/components/scrollbar/index.d.ts +2 -0
- package/dist/components/scrollbar/index.js +2 -0
- package/dist/components/scrollbar/scrollbar.d.ts +12 -0
- package/dist/components/scrollbar/scrollbar.js +9 -0
- package/dist/components/search-not-found/index.d.ts +1 -0
- package/dist/components/search-not-found/index.js +1 -0
- package/dist/components/search-not-found/search-not-found.d.ts +16 -0
- package/dist/components/search-not-found/search-not-found.js +16 -0
- package/dist/components/select/index.d.ts +1 -0
- package/dist/components/select/index.js +1 -0
- package/dist/components/select/select.d.ts +15 -0
- package/dist/components/select/select.js +34 -0
- package/dist/components/separator/index.d.ts +1 -0
- package/dist/components/separator/index.js +1 -0
- package/dist/components/separator/separator.d.ts +3 -0
- package/dist/components/separator/separator.js +8 -0
- package/dist/components/sheet/index.d.ts +1 -0
- package/dist/components/sheet/index.js +1 -0
- package/dist/components/sheet/sheet.d.ts +14 -0
- package/dist/components/sheet/sheet.js +37 -0
- package/dist/components/skeleton/index.d.ts +1 -0
- package/dist/components/skeleton/index.js +1 -0
- package/dist/components/skeleton/skeleton.d.ts +2 -0
- package/dist/components/skeleton/skeleton.js +7 -0
- package/dist/components/slider/index.d.ts +1 -0
- package/dist/components/slider/index.js +1 -0
- package/dist/components/slider/slider.d.ts +3 -0
- package/dist/components/slider/slider.js +13 -0
- package/dist/components/snackbar/classes.d.ts +18 -0
- package/dist/components/snackbar/classes.js +19 -0
- package/dist/components/snackbar/index.d.ts +3 -0
- package/dist/components/snackbar/index.js +3 -0
- package/dist/components/snackbar/snackbar.d.ts +8 -0
- package/dist/components/snackbar/snackbar.js +39 -0
- package/dist/components/spinner/index.d.ts +1 -0
- package/dist/components/spinner/index.js +1 -0
- package/dist/components/spinner/spinner.d.ts +2 -0
- package/dist/components/spinner/spinner.js +8 -0
- package/dist/components/svg-color/classes.d.ts +3 -0
- package/dist/components/svg-color/classes.js +4 -0
- package/dist/components/svg-color/index.d.ts +2 -0
- package/dist/components/svg-color/index.js +2 -0
- package/dist/components/svg-color/svg-color.d.ts +7 -0
- package/dist/components/svg-color/svg-color.js +12 -0
- package/dist/components/switch/index.d.ts +1 -0
- package/dist/components/switch/index.js +1 -0
- package/dist/components/switch/switch.d.ts +8 -0
- package/dist/components/switch/switch.js +17 -0
- package/dist/components/table/index.d.ts +1 -0
- package/dist/components/table/index.js +1 -0
- package/dist/components/table/table.d.ts +10 -0
- package/dist/components/table/table.js +28 -0
- package/dist/components/tabs/index.d.ts +1 -0
- package/dist/components/tabs/index.js +1 -0
- package/dist/components/tabs/tabs.d.ts +10 -0
- package/dist/components/tabs/tabs.js +31 -0
- package/dist/components/textarea/index.d.ts +1 -0
- package/dist/components/textarea/index.js +1 -0
- package/dist/components/textarea/textarea.d.ts +3 -0
- package/dist/components/textarea/textarea.js +7 -0
- package/dist/components/theme-provider/index.d.ts +1 -0
- package/dist/components/theme-provider/index.js +1 -0
- package/dist/components/theme-provider/theme-provider.d.ts +31 -0
- package/dist/components/theme-provider/theme-provider.js +92 -0
- package/dist/components/toggle/index.d.ts +1 -0
- package/dist/components/toggle/index.js +1 -0
- package/dist/components/toggle/toggle.d.ts +8 -0
- package/dist/components/toggle/toggle.js +27 -0
- package/dist/components/toggle-group/index.d.ts +1 -0
- package/dist/components/toggle-group/index.js +1 -0
- package/dist/components/toggle-group/toggle-group.d.ts +11 -0
- package/dist/components/toggle-group/toggle-group.js +24 -0
- package/dist/components/tooltip/index.d.ts +1 -0
- package/dist/components/tooltip/index.js +1 -0
- package/dist/components/tooltip/tooltip.d.ts +6 -0
- package/dist/components/tooltip/tooltip.js +17 -0
- package/dist/components/upload/classes.d.ts +8 -0
- package/dist/components/upload/classes.js +9 -0
- package/dist/components/upload/components/placeholder.d.ts +9 -0
- package/dist/components/upload/components/placeholder.js +21 -0
- package/dist/components/upload/components/preview-multi-file.d.ts +2 -0
- package/dist/components/upload/components/preview-multi-file.js +19 -0
- package/dist/components/upload/components/preview-single-file.d.ts +3 -0
- package/dist/components/upload/components/preview-single-file.js +19 -0
- package/dist/components/upload/components/rejection-files.d.ts +6 -0
- package/dist/components/upload/components/rejection-files.js +12 -0
- package/dist/components/upload/components/upload-illustration.d.ts +3 -0
- package/dist/components/upload/components/upload-illustration.js +5 -0
- package/dist/components/upload/index.d.ts +9 -0
- package/dist/components/upload/index.js +8 -0
- package/dist/components/upload/types.d.ts +35 -0
- package/dist/components/upload/types.js +1 -0
- package/dist/components/upload/upload-avatar.d.ts +2 -0
- package/dist/components/upload/upload-avatar.js +32 -0
- package/dist/components/upload/upload-box.d.ts +2 -0
- package/dist/components/upload/upload-box.js +14 -0
- package/dist/components/upload/upload.d.ts +2 -0
- package/dist/components/upload/upload.js +23 -0
- package/dist/components/walktour/index.d.ts +4 -0
- package/dist/components/walktour/index.js +3 -0
- package/dist/components/walktour/types.d.ts +27 -0
- package/dist/components/walktour/types.js +1 -0
- package/dist/components/walktour/use-walktour.d.ts +2 -0
- package/dist/components/walktour/use-walktour.js +11 -0
- package/dist/components/walktour/walktour-tooltip.d.ts +2 -0
- package/dist/components/walktour/walktour-tooltip.js +15 -0
- package/dist/components/walktour/walktour.d.ts +2 -0
- package/dist/components/walktour/walktour.js +30 -0
- package/dist/hooks/index.d.ts +7 -0
- package/dist/hooks/index.js +7 -0
- package/dist/hooks/use-boolean.d.ts +9 -0
- package/dist/hooks/use-boolean.js +9 -0
- package/dist/hooks/use-client-rect.d.ts +6 -0
- package/dist/hooks/use-client-rect.js +18 -0
- package/dist/hooks/use-is-client.d.ts +2 -0
- package/dist/hooks/use-is-client.js +7 -0
- package/dist/hooks/use-local-storage.d.ts +10 -0
- package/dist/hooks/use-local-storage.js +39 -0
- package/dist/hooks/use-mobile.d.ts +1 -0
- package/dist/hooks/use-mobile.js +16 -0
- package/dist/hooks/use-popover-hover.d.ts +25 -0
- package/dist/hooks/use-popover-hover.js +33 -0
- package/dist/hooks/use-popover.d.ts +10 -0
- package/dist/hooks/use-popover.js +9 -0
- package/dist/index.d.ts +11 -0
- package/dist/index.js +11 -0
- package/dist/lib/brand.d.ts +14 -0
- package/dist/lib/brand.js +31 -0
- package/dist/lib/create-classes.d.ts +1 -0
- package/dist/lib/create-classes.js +4 -0
- package/dist/lib/date.d.ts +10 -0
- package/dist/lib/date.js +32 -0
- package/dist/lib/format.d.ts +2 -0
- package/dist/lib/format.js +10 -0
- package/dist/lib/link.d.ts +5 -0
- package/dist/lib/link.js +5 -0
- package/dist/lib/path.d.ts +6 -0
- package/dist/lib/path.js +24 -0
- package/dist/lib/theme-script.d.ts +11 -0
- package/dist/lib/theme-script.js +8 -0
- package/dist/lib/utils.d.ts +1 -0
- package/dist/lib/utils.js +1 -0
- package/dist/styles/chart.css +56 -0
- package/dist/styles/components.css +30 -0
- package/dist/styles/editor.css +199 -0
- package/dist/styles/globals.css +184 -0
- package/dist/styles/lightbox.css +42 -0
- package/dist/styles/map.css +62 -0
- package/dist/styles/markdown.css +177 -0
- package/dist/styles/nav.css +513 -0
- package/dist/styles/org-chart.css +82 -0
- package/dist/styles/scrollbar.css +9 -0
- package/dist/styles/settings.css +7 -0
- package/dist/styles/snackbar.css +68 -0
- package/dist/styles/theme.css +52 -0
- package/dist/styles/variants.css +84 -0
- package/docs/compliance-report.md +104 -0
- package/docs/frameworks.md +63 -0
- package/docs/publishing.md +23 -0
- package/docs/theming.md +40 -0
- package/package.json +518 -4
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
3
|
+
import { cva } from "class-variance-authority";
|
|
4
|
+
import { cn } from "cn";
|
|
5
|
+
const alertVariants = /* @__PURE__ */ cva("group/alert relative grid w-full gap-0.5 rounded-md px-4 py-3 text-left text-body2 has-data-[slot=alert-action]:relative has-data-[slot=alert-action]:pr-18 has-[>svg]:grid-cols-[auto_1fr] has-[>svg]:gap-x-3 *:[svg]:row-span-2 *:[svg:not([class*='size-'])]:size-6", {
|
|
6
|
+
variants: {
|
|
7
|
+
variant: {
|
|
8
|
+
default: "bg-card text-card-foreground border border-border",
|
|
9
|
+
destructive: "bg-error-lighter text-error-darker dark:bg-error-darker dark:text-error-lighter *:[svg]:text-error dark:*:[svg]:text-error-light",
|
|
10
|
+
info: "bg-info-lighter text-info-darker dark:bg-info-darker dark:text-info-lighter *:[svg]:text-info dark:*:[svg]:text-info-light",
|
|
11
|
+
success: "bg-success-lighter text-success-darker dark:bg-success-darker dark:text-success-lighter *:[svg]:text-success dark:*:[svg]:text-success-light",
|
|
12
|
+
warning: "bg-warning-lighter text-warning-darker dark:bg-warning-darker dark:text-warning-lighter *:[svg]:text-warning dark:*:[svg]:text-warning-light",
|
|
13
|
+
"outlined-info": "border border-info/16 bg-info/8 text-info-dark dark:text-info-light *:[svg]:text-info",
|
|
14
|
+
"outlined-success": "border border-success/16 bg-success/8 text-success-dark dark:text-success-light *:[svg]:text-success",
|
|
15
|
+
"outlined-warning": "border border-warning/16 bg-warning/8 text-warning-dark dark:text-warning-light *:[svg]:text-warning",
|
|
16
|
+
"outlined-error": "border border-error/16 bg-error/8 text-error-dark dark:text-error-light *:[svg]:text-error",
|
|
17
|
+
},
|
|
18
|
+
},
|
|
19
|
+
defaultVariants: { variant: "default" },
|
|
20
|
+
});
|
|
21
|
+
function Alert({ className, variant, ...props }) {
|
|
22
|
+
return (_jsx("div", { "data-slot": "alert", role: "alert", className: cn(alertVariants({ variant }), className), ...props }));
|
|
23
|
+
}
|
|
24
|
+
function AlertTitle({ className, ...props }) {
|
|
25
|
+
return (_jsx("div", { "data-slot": "alert-title", className: cn("mb-0.5 font-semibold group-has-[>svg]/alert:col-start-2 [&_a]:underline [&_a]:underline-offset-3", className), ...props }));
|
|
26
|
+
}
|
|
27
|
+
function AlertDescription({ className, ...props }) {
|
|
28
|
+
return (_jsx("div", { "data-slot": "alert-description", className: cn("text-body2 text-pretty opacity-90 group-has-[>svg]/alert:col-start-2 [&_a]:underline [&_a]:underline-offset-3 [&_p:not(:last-child)]:mb-4", className), ...props }));
|
|
29
|
+
}
|
|
30
|
+
function AlertAction({ className, ...props }) {
|
|
31
|
+
return (_jsx("div", { "data-slot": "alert-action", className: cn("absolute top-3 right-3", className), ...props }));
|
|
32
|
+
}
|
|
33
|
+
export { Alert, AlertTitle, AlertDescription, AlertAction };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from "./alert.js";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from "./alert.js";
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import type * as React from "react";
|
|
2
|
+
import { AlertDialog as AlertDialogPrimitive } from "@base-ui/react/alert-dialog";
|
|
3
|
+
import { Button } from "../button/index.js";
|
|
4
|
+
declare function AlertDialog({ ...props }: AlertDialogPrimitive.Root.Props): React.JSX.Element;
|
|
5
|
+
declare function AlertDialogTrigger({ ...props }: AlertDialogPrimitive.Trigger.Props): React.JSX.Element;
|
|
6
|
+
declare function AlertDialogPortal({ ...props }: AlertDialogPrimitive.Portal.Props): React.JSX.Element;
|
|
7
|
+
declare function AlertDialogOverlay({ className, ...props }: AlertDialogPrimitive.Backdrop.Props): React.JSX.Element;
|
|
8
|
+
declare function AlertDialogContent({ className, size, ...props }: AlertDialogPrimitive.Popup.Props & {
|
|
9
|
+
size?: "default" | "sm";
|
|
10
|
+
}): React.JSX.Element;
|
|
11
|
+
declare function AlertDialogHeader({ className, ...props }: React.ComponentProps<"div">): React.JSX.Element;
|
|
12
|
+
declare function AlertDialogFooter({ className, ...props }: React.ComponentProps<"div">): React.JSX.Element;
|
|
13
|
+
declare function AlertDialogMedia({ className, ...props }: React.ComponentProps<"div">): React.JSX.Element;
|
|
14
|
+
declare function AlertDialogTitle({ className, ...props }: React.ComponentProps<typeof AlertDialogPrimitive.Title>): React.JSX.Element;
|
|
15
|
+
declare function AlertDialogDescription({ className, ...props }: React.ComponentProps<typeof AlertDialogPrimitive.Description>): React.JSX.Element;
|
|
16
|
+
declare function AlertDialogAction({ className, ...props }: React.ComponentProps<typeof Button>): React.JSX.Element;
|
|
17
|
+
declare function AlertDialogCancel({ className, variant, size, ...props }: AlertDialogPrimitive.Close.Props & Pick<React.ComponentProps<typeof Button>, "variant" | "size">): React.JSX.Element;
|
|
18
|
+
export { AlertDialog, AlertDialogAction, AlertDialogCancel, AlertDialogContent, AlertDialogDescription, AlertDialogFooter, AlertDialogHeader, AlertDialogMedia, AlertDialogOverlay, AlertDialogPortal, AlertDialogTitle, AlertDialogTrigger, };
|
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
3
|
+
import { AlertDialog as AlertDialogPrimitive } from "@base-ui/react/alert-dialog";
|
|
4
|
+
import { cn } from "cn";
|
|
5
|
+
import { Button } from "../button/index.js";
|
|
6
|
+
function AlertDialog({ ...props }) {
|
|
7
|
+
return _jsx(AlertDialogPrimitive.Root, { "data-slot": "alert-dialog", ...props });
|
|
8
|
+
}
|
|
9
|
+
function AlertDialogTrigger({ ...props }) {
|
|
10
|
+
return (_jsx(AlertDialogPrimitive.Trigger, { "data-slot": "alert-dialog-trigger", ...props }));
|
|
11
|
+
}
|
|
12
|
+
function AlertDialogPortal({ ...props }) {
|
|
13
|
+
return (_jsx(AlertDialogPrimitive.Portal, { "data-slot": "alert-dialog-portal", ...props }));
|
|
14
|
+
}
|
|
15
|
+
function AlertDialogOverlay({ className, ...props }) {
|
|
16
|
+
return (_jsx(AlertDialogPrimitive.Backdrop, { "data-slot": "alert-dialog-overlay", className: cn("fixed inset-0 isolate z-modal bg-grey-800/48 duration-150 data-open:animate-in data-open:fade-in-0 data-closed:animate-out data-closed:fade-out-0", className), ...props }));
|
|
17
|
+
}
|
|
18
|
+
function AlertDialogContent({ className, size = "default", ...props }) {
|
|
19
|
+
return (_jsxs(AlertDialogPortal, { children: [_jsx(AlertDialogOverlay, {}), _jsx(AlertDialogPrimitive.Popup, { "data-slot": "alert-dialog-content", "data-size": size, className: cn("group/alert-dialog-content fixed top-1/2 left-1/2 z-modal grid w-full -translate-x-1/2 -translate-y-1/2 gap-0 rounded-2xl bg-popover p-0 text-body2 text-popover-foreground shadow-dialog duration-150 outline-none data-[size=default]:max-w-[calc(100%-2rem)] data-[size=sm]:max-w-xs data-[size=default]:sm:max-w-[444px] data-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:fade-out-0 data-closed:zoom-out-95", className), ...props })] }));
|
|
20
|
+
}
|
|
21
|
+
function AlertDialogHeader({ className, ...props }) {
|
|
22
|
+
return (_jsx("div", { "data-slot": "alert-dialog-header", className: cn("grid grid-rows-[auto_1fr] place-items-center gap-1 p-6 text-center has-data-[slot=alert-dialog-media]:grid-rows-[auto_auto_1fr] has-data-[slot=alert-dialog-media]:gap-x-4 sm:group-data-[size=default]/alert-dialog-content:place-items-start sm:group-data-[size=default]/alert-dialog-content:text-left sm:group-data-[size=default]/alert-dialog-content:has-data-[slot=alert-dialog-media]:grid-rows-[auto_1fr]", className), ...props }));
|
|
23
|
+
}
|
|
24
|
+
function AlertDialogFooter({ className, ...props }) {
|
|
25
|
+
return (_jsx("div", { "data-slot": "alert-dialog-footer", className: cn("flex flex-col-reverse gap-3 p-6 group-data-[size=sm]/alert-dialog-content:grid group-data-[size=sm]/alert-dialog-content:grid-cols-2 sm:flex-row sm:justify-end", className), ...props }));
|
|
26
|
+
}
|
|
27
|
+
function AlertDialogMedia({ className, ...props }) {
|
|
28
|
+
return (_jsx("div", { "data-slot": "alert-dialog-media", className: cn("mb-2 inline-flex size-10 items-center justify-center rounded-md bg-neutral sm:group-data-[size=default]/alert-dialog-content:row-span-2 *:[svg:not([class*='size-'])]:size-6", className), ...props }));
|
|
29
|
+
}
|
|
30
|
+
function AlertDialogTitle({ className, ...props }) {
|
|
31
|
+
return (_jsx(AlertDialogPrimitive.Title, { "data-slot": "alert-dialog-title", className: cn("text-h6 text-foreground sm:group-data-[size=default]/alert-dialog-content:group-has-data-[slot=alert-dialog-media]/alert-dialog-content:col-start-2", className), ...props }));
|
|
32
|
+
}
|
|
33
|
+
function AlertDialogDescription({ className, ...props }) {
|
|
34
|
+
return (_jsx(AlertDialogPrimitive.Description, { "data-slot": "alert-dialog-description", className: cn("text-body2 text-balance text-text-secondary md:text-pretty *:[a]:underline *:[a]:underline-offset-3 *:[a]:hover:text-foreground", className), ...props }));
|
|
35
|
+
}
|
|
36
|
+
function AlertDialogAction({ className, ...props }) {
|
|
37
|
+
return (_jsx(Button, { "data-slot": "alert-dialog-action", className: cn(className), ...props }));
|
|
38
|
+
}
|
|
39
|
+
function AlertDialogCancel({ className, variant = "outline", size = "default", ...props }) {
|
|
40
|
+
return (_jsx(AlertDialogPrimitive.Close, { "data-slot": "alert-dialog-cancel", className: cn(className), render: _jsx(Button, { variant: variant, size: size }), ...props }));
|
|
41
|
+
}
|
|
42
|
+
export { AlertDialog, AlertDialogAction, AlertDialogCancel, AlertDialogContent, AlertDialogDescription, AlertDialogFooter, AlertDialogHeader, AlertDialogMedia, AlertDialogOverlay, AlertDialogPortal, AlertDialogTitle, AlertDialogTrigger, };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from "./alert-dialog.js";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from "./alert-dialog.js";
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
import * as React from "react";
|
|
2
|
+
export declare const animateBorderClasses: {
|
|
3
|
+
root: string;
|
|
4
|
+
primaryBorder: string;
|
|
5
|
+
secondaryBorder: string;
|
|
6
|
+
svgWrapper: string;
|
|
7
|
+
movingShape: string;
|
|
8
|
+
};
|
|
9
|
+
type BorderStyleProps = {
|
|
10
|
+
/** Ring thickness, any CSS length. */
|
|
11
|
+
width?: string;
|
|
12
|
+
/** Size (px) of the glowing dot that travels around the border. */
|
|
13
|
+
size?: number;
|
|
14
|
+
className?: string;
|
|
15
|
+
};
|
|
16
|
+
export type AnimateBorderProps = React.ComponentProps<"div"> & {
|
|
17
|
+
/** Seconds for one lap. */
|
|
18
|
+
duration?: number;
|
|
19
|
+
slotProps?: {
|
|
20
|
+
primaryBorder?: BorderStyleProps;
|
|
21
|
+
secondaryBorder?: BorderStyleProps;
|
|
22
|
+
/** Static ring drawn under the moving highlights. */
|
|
23
|
+
outlineColor?: string;
|
|
24
|
+
svgSettings?: {
|
|
25
|
+
rx?: string;
|
|
26
|
+
ry?: string;
|
|
27
|
+
};
|
|
28
|
+
};
|
|
29
|
+
};
|
|
30
|
+
export declare function AnimateBorder({ children, duration, slotProps, className, style, ...props }: AnimateBorderProps): React.JSX.Element;
|
|
31
|
+
export {};
|
|
@@ -0,0 +1,77 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
3
|
+
import * as React from "react";
|
|
4
|
+
import { m, useAnimationFrame, useMotionTemplate, useMotionValue, useTransform } from "framer-motion";
|
|
5
|
+
import { cn } from "cn";
|
|
6
|
+
import { createClasses } from "../../lib/create-classes.js";
|
|
7
|
+
export const animateBorderClasses = {
|
|
8
|
+
root: /* @__PURE__ */ createClasses("border__animation__root"),
|
|
9
|
+
primaryBorder: /* @__PURE__ */ createClasses("border__animation__primary"),
|
|
10
|
+
secondaryBorder: /* @__PURE__ */ createClasses("border__animation__secondary"),
|
|
11
|
+
svgWrapper: /* @__PURE__ */ createClasses("border__animation__svg__wrapper"),
|
|
12
|
+
movingShape: /* @__PURE__ */ createClasses("border__animation__moving__shape"),
|
|
13
|
+
};
|
|
14
|
+
export function AnimateBorder({ children, duration, slotProps, className, style, ...props }) {
|
|
15
|
+
const rootRef = React.useRef(null);
|
|
16
|
+
const primaryRef = React.useRef(null);
|
|
17
|
+
const [isHidden, setIsHidden] = React.useState(false);
|
|
18
|
+
const mirrored = useMirroredStyles(primaryRef);
|
|
19
|
+
React.useEffect(() => {
|
|
20
|
+
const check = () => {
|
|
21
|
+
if (rootRef.current)
|
|
22
|
+
setIsHidden(getComputedStyle(rootRef.current).display === "none");
|
|
23
|
+
};
|
|
24
|
+
check();
|
|
25
|
+
window.addEventListener("resize", check);
|
|
26
|
+
return () => window.removeEventListener("resize", check);
|
|
27
|
+
}, []);
|
|
28
|
+
const shared = { duration, isHidden, rx: slotProps?.svgSettings?.rx, ry: slotProps?.svgSettings?.ry };
|
|
29
|
+
const ringVars = (width, color) => ({ "--border-gradient-padding": width, "--border-gradient-color": color });
|
|
30
|
+
return (_jsxs("div", { dir: "ltr", ref: rootRef, className: cn(animateBorderClasses.root, "relative w-fit overflow-hidden before:border-gradient", children ? "" : "min-h-10 min-w-10", className), style: { ...ringVars(slotProps?.primaryBorder?.width, slotProps?.outlineColor), ...style }, ...props, children: [_jsx(MovingBorder, { ...shared, ref: primaryRef, size: slotProps?.primaryBorder?.size, className: cn(animateBorderClasses.primaryBorder, "border-gradient", slotProps?.primaryBorder?.className), style: ringVars(slotProps?.primaryBorder?.width) }), slotProps?.secondaryBorder ? (_jsx(MovingBorder, { ...shared, size: slotProps.secondaryBorder.size ?? slotProps.primaryBorder?.size, className: cn(animateBorderClasses.secondaryBorder, "border-gradient -scale-100", slotProps.secondaryBorder.className), style: {
|
|
31
|
+
...ringVars(slotProps.secondaryBorder.width ?? mirrored.padding),
|
|
32
|
+
borderRadius: mirrored.borderRadius,
|
|
33
|
+
} })) : null, children] }));
|
|
34
|
+
}
|
|
35
|
+
const MovingBorder = /* @__PURE__ */ React.forwardRef(({ rx = "30%", ry = "30%", size, duration = 8, isHidden, className, ...props }, ref) => {
|
|
36
|
+
const rectRef = React.useRef(null);
|
|
37
|
+
const progress = useMotionValue(0);
|
|
38
|
+
useAnimationFrame((time) => {
|
|
39
|
+
if (isHidden || !rectRef.current)
|
|
40
|
+
return;
|
|
41
|
+
try {
|
|
42
|
+
const length = rectRef.current.getTotalLength();
|
|
43
|
+
progress.set((time * (length / (duration * 1000))) % length);
|
|
44
|
+
}
|
|
45
|
+
catch {
|
|
46
|
+
/* getTotalLength is unavailable until the rect is laid out */
|
|
47
|
+
}
|
|
48
|
+
});
|
|
49
|
+
const point = (val) => {
|
|
50
|
+
try {
|
|
51
|
+
return rectRef.current?.getPointAtLength(val) ?? { x: 0, y: 0 };
|
|
52
|
+
}
|
|
53
|
+
catch {
|
|
54
|
+
return { x: 0, y: 0 };
|
|
55
|
+
}
|
|
56
|
+
};
|
|
57
|
+
const x = useTransform(progress, (v) => point(v).x);
|
|
58
|
+
const y = useTransform(progress, (v) => point(v).y);
|
|
59
|
+
const transform = useMotionTemplate `translateX(${x}px) translateY(${y}px) translateX(-50%) translateY(-50%)`;
|
|
60
|
+
return (_jsxs("span", { ref: ref, className: cn("text-start", className), ...props, children: [_jsx("svg", { xmlns: "http://www.w3.org/2000/svg", preserveAspectRatio: "none", width: "100%", height: "100%", className: cn(animateBorderClasses.svgWrapper, "absolute"), children: _jsx("rect", { ref: rectRef, fill: "none", width: "100%", height: "100%", rx: rx, ry: ry }) }), _jsx(m.span, { style: { transform, width: size, height: size }, className: cn(animateBorderClasses.movingShape, "absolute bg-[radial-gradient(currentColor_40%,transparent_80%)] blur-[8px]") })] }));
|
|
61
|
+
});
|
|
62
|
+
MovingBorder.displayName = "MovingBorder";
|
|
63
|
+
/* The secondary ring is the primary one turned 180 degrees, so its padding and radii are swapped. */
|
|
64
|
+
function useMirroredStyles(ref) {
|
|
65
|
+
const [styles, setStyles] = React.useState(null);
|
|
66
|
+
React.useEffect(() => {
|
|
67
|
+
if (ref.current)
|
|
68
|
+
setStyles(getComputedStyle(ref.current));
|
|
69
|
+
}, [ref]);
|
|
70
|
+
if (!styles)
|
|
71
|
+
return { padding: undefined, borderRadius: undefined };
|
|
72
|
+
const rtl = typeof document !== "undefined" && document.dir === "rtl";
|
|
73
|
+
return {
|
|
74
|
+
padding: `${styles.paddingBottom} ${rtl ? styles.paddingRight : styles.paddingLeft} ${styles.paddingTop} ${rtl ? styles.paddingLeft : styles.paddingRight}`,
|
|
75
|
+
borderRadius: `${styles.borderBottomRightRadius} ${styles.borderBottomLeftRadius} ${styles.borderTopLeftRadius} ${styles.borderTopRightRadius}`,
|
|
76
|
+
};
|
|
77
|
+
}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import type { UseInViewOptions } from "framer-motion";
|
|
2
|
+
export type AnimateCountUpProps = Omit<React.ComponentProps<"p">, "to"> & {
|
|
3
|
+
to: number;
|
|
4
|
+
from?: number;
|
|
5
|
+
toFixed?: number;
|
|
6
|
+
duration?: number;
|
|
7
|
+
unit?: "k" | "m" | "b" | (string & {});
|
|
8
|
+
once?: UseInViewOptions["once"];
|
|
9
|
+
amount?: UseInViewOptions["amount"];
|
|
10
|
+
render?: React.ElementType;
|
|
11
|
+
};
|
|
12
|
+
export declare function AnimateCountUp({ to, from, toFixed, once, duration, amount, unit: unitProp, render: Component, className, ...other }: AnimateCountUpProps): import("react").JSX.Element;
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
3
|
+
import { useRef, useEffect } from "react";
|
|
4
|
+
import { m, animate, useInView, useTransform, useMotionValue } from "framer-motion";
|
|
5
|
+
import { cn } from "../../lib/utils.js";
|
|
6
|
+
export function AnimateCountUp({ to, from = 0, toFixed = 0, once = true, duration = 2, amount = 0.5, unit: unitProp, render: Component = "p", className, ...other }) {
|
|
7
|
+
const countRef = useRef(null);
|
|
8
|
+
const shortNumber = shortenNumber(to);
|
|
9
|
+
const startCount = useMotionValue(from);
|
|
10
|
+
const endCount = shortNumber ? shortNumber.value : to;
|
|
11
|
+
const unit = unitProp ?? shortNumber?.unit;
|
|
12
|
+
const inView = useInView(countRef, { once, amount });
|
|
13
|
+
const rounded = useTransform(startCount, (latest) => latest.toFixed(isFloat(latest) ? toFixed : 0));
|
|
14
|
+
useEffect(() => {
|
|
15
|
+
if (inView) {
|
|
16
|
+
const controls = animate(startCount, endCount, { duration });
|
|
17
|
+
return () => controls.stop();
|
|
18
|
+
}
|
|
19
|
+
}, [duration, endCount, inView, startCount]);
|
|
20
|
+
return (_jsxs(Component, { className: cn("m-0 inline-flex p-0", className), ...other, children: [_jsx(m.span, { ref: countRef, children: rounded }), unit] }));
|
|
21
|
+
}
|
|
22
|
+
function isFloat(n) {
|
|
23
|
+
return typeof n === "number" && !Number.isInteger(n);
|
|
24
|
+
}
|
|
25
|
+
function shortenNumber(value) {
|
|
26
|
+
if (value >= 1e9)
|
|
27
|
+
return { unit: "b", value: value / 1e9 };
|
|
28
|
+
if (value >= 1e6)
|
|
29
|
+
return { unit: "m", value: value / 1e6 };
|
|
30
|
+
if (value >= 1e3)
|
|
31
|
+
return { unit: "k", value: value / 1e3 };
|
|
32
|
+
return undefined;
|
|
33
|
+
}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import * as React from "react";
|
|
2
|
+
import { type LogoProps } from "../logo/index.js";
|
|
3
|
+
export type AnimateLogoProps = React.ComponentProps<"div"> & {
|
|
4
|
+
logo?: React.ReactNode;
|
|
5
|
+
slotProps?: {
|
|
6
|
+
logo?: LogoProps;
|
|
7
|
+
};
|
|
8
|
+
};
|
|
9
|
+
export declare const AnimateLogoZoom: React.ForwardRefExoticComponent<Omit<AnimateLogoProps, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
10
|
+
export declare const AnimateLogoRotate: React.ForwardRefExoticComponent<Omit<AnimateLogoProps, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
3
|
+
import * as React from "react";
|
|
4
|
+
import { m } from "framer-motion";
|
|
5
|
+
import { cn } from "cn";
|
|
6
|
+
import { Logo } from "../logo/index.js";
|
|
7
|
+
export const AnimateLogoZoom = /* @__PURE__ */ React.forwardRef(({ logo, slotProps, className, ...props }, ref) => (_jsxs("div", { ref: ref, className: cn("relative inline-flex size-30 items-center justify-center", className), ...props, children: [_jsx(m.span, { animate: { scale: [1, 0.9, 0.9, 1, 1], opacity: [1, 0.48, 0.48, 1, 1] }, transition: { duration: 2, repeatDelay: 1, repeat: Infinity, ease: "easeInOut" }, children: logo ?? _jsx(Logo, { disabled: true, ...slotProps?.logo, className: cn("size-16", slotProps?.logo?.className) }) }), _jsx(m.span, { className: "absolute size-[calc(100%-20px)] border-[3px] border-solid border-primary-dark/24", animate: {
|
|
8
|
+
scale: [1.6, 1, 1, 1.6, 1.6],
|
|
9
|
+
rotate: [270, 0, 0, 270, 270],
|
|
10
|
+
opacity: [0.25, 1, 1, 1, 0.25],
|
|
11
|
+
borderRadius: ["25%", "25%", "50%", "50%", "25%"],
|
|
12
|
+
}, transition: { ease: "linear", duration: 3.2, repeat: Infinity } }), _jsx(m.span, { className: "absolute size-full border-8 border-solid border-primary-dark/24", animate: {
|
|
13
|
+
scale: [1, 1.2, 1.2, 1, 1],
|
|
14
|
+
rotate: [0, 270, 270, 0, 0],
|
|
15
|
+
opacity: [1, 0.25, 0.25, 0.25, 1],
|
|
16
|
+
borderRadius: ["25%", "25%", "50%", "50%", "25%"],
|
|
17
|
+
}, transition: { ease: "linear", duration: 3.2, repeat: Infinity } })] })));
|
|
18
|
+
AnimateLogoZoom.displayName = "AnimateLogoZoom";
|
|
19
|
+
export const AnimateLogoRotate = /* @__PURE__ */ React.forwardRef(({ logo, slotProps, className, ...props }, ref) => (_jsxs("div", { ref: ref, className: cn("relative inline-flex size-24 items-center justify-center", className), ...props, children: [logo ?? _jsx(Logo, { ...slotProps?.logo, className: cn("z-9 size-10", slotProps?.logo?.className) }), _jsx(m.span, { className: "absolute size-full rounded-full bg-[linear-gradient(135deg,transparent_50%,var(--primary-main)_100%)] opacity-16 transition-opacity duration-200", animate: { rotate: 360 }, transition: { duration: 10, ease: "linear", repeat: Infinity } })] })));
|
|
20
|
+
AnimateLogoRotate.displayName = "AnimateLogoRotate";
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import type { Variants, UseInViewOptions } from "framer-motion";
|
|
2
|
+
export declare const animateTextClasses: {
|
|
3
|
+
root: string;
|
|
4
|
+
lines: string;
|
|
5
|
+
line: string;
|
|
6
|
+
word: string;
|
|
7
|
+
char: string;
|
|
8
|
+
space: string;
|
|
9
|
+
srOnly: string;
|
|
10
|
+
};
|
|
11
|
+
export type AnimateTextProps = Omit<React.ComponentProps<"p">, "children"> & {
|
|
12
|
+
variants?: Variants;
|
|
13
|
+
repeatDelayMs?: number;
|
|
14
|
+
textContent: string | string[];
|
|
15
|
+
once?: UseInViewOptions["once"];
|
|
16
|
+
amount?: UseInViewOptions["amount"];
|
|
17
|
+
render?: React.ElementType;
|
|
18
|
+
};
|
|
19
|
+
export declare function AnimateText({ variants, className, textContent, once, amount, render: Component, repeatDelayMs, ...other }: AnimateTextProps): import("react").JSX.Element;
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
3
|
+
import { useRef, useMemo, useEffect } from "react";
|
|
4
|
+
import { m, useInView, useAnimation } from "framer-motion";
|
|
5
|
+
import { cn } from "../../lib/utils.js";
|
|
6
|
+
import { createClasses } from "../../lib/create-classes.js";
|
|
7
|
+
import { varFade, varContainer } from "./variants/index.js";
|
|
8
|
+
export const animateTextClasses = {
|
|
9
|
+
root: /* @__PURE__ */ createClasses("animate__text__root"),
|
|
10
|
+
lines: /* @__PURE__ */ createClasses("animate__text__lines"),
|
|
11
|
+
line: /* @__PURE__ */ createClasses("animate__text__line"),
|
|
12
|
+
word: /* @__PURE__ */ createClasses("animate__text__word"),
|
|
13
|
+
char: /* @__PURE__ */ createClasses("animate__text__char"),
|
|
14
|
+
space: /* @__PURE__ */ createClasses("animate__text__space"),
|
|
15
|
+
srOnly: "sr-only",
|
|
16
|
+
};
|
|
17
|
+
export function AnimateText({ variants, className, textContent, once = true, amount = 1 / 3, render: Component = "p", repeatDelayMs = 100, ...other }) {
|
|
18
|
+
const textRef = useRef(null);
|
|
19
|
+
const animationControls = useAnimation();
|
|
20
|
+
const textArray = useMemo(() => (Array.isArray(textContent) ? textContent : [textContent]), [textContent]);
|
|
21
|
+
const isInView = useInView(textRef, { once, amount });
|
|
22
|
+
useEffect(() => {
|
|
23
|
+
let timeout;
|
|
24
|
+
if (isInView) {
|
|
25
|
+
if (repeatDelayMs) {
|
|
26
|
+
timeout = setTimeout(async () => {
|
|
27
|
+
await animationControls.start("initial");
|
|
28
|
+
animationControls.start("animate");
|
|
29
|
+
}, repeatDelayMs);
|
|
30
|
+
}
|
|
31
|
+
else {
|
|
32
|
+
animationControls.start("animate");
|
|
33
|
+
}
|
|
34
|
+
}
|
|
35
|
+
else {
|
|
36
|
+
animationControls.start("initial");
|
|
37
|
+
}
|
|
38
|
+
return () => clearTimeout(timeout);
|
|
39
|
+
}, [animationControls, isInView, repeatDelayMs]);
|
|
40
|
+
return (_jsxs(Component, { className: cn(animateTextClasses.root, "m-0 p-0", className), ...other, children: [_jsx("span", { className: animateTextClasses.srOnly, children: textArray.join(" ") }), _jsx(m.span, { ref: textRef, initial: "initial", animate: animationControls, exit: "exit", variants: varContainer(), "aria-hidden": true, className: animateTextClasses.lines, children: textArray.map((line, lineIndex) => {
|
|
41
|
+
const words = line.split(" ");
|
|
42
|
+
return (_jsx("span", { "data-index": lineIndex, className: cn(animateTextClasses.line, "block"), children: words.map((word, wordIndex) => (_jsxs("span", { "data-index": wordIndex, className: cn(animateTextClasses.word, "inline-block"), children: [word.split("").map((char, charIndex) => (_jsx(m.span, { variants: variants ?? varFade("in"), "data-index": charIndex, className: cn(animateTextClasses.char, "inline-block"), children: char }, `${char}-${charIndex}`))), wordIndex < words.length - 1 && (_jsx("span", { className: cn(animateTextClasses.space, "inline-block"), children: "\u00A0" }))] }, `${word}-${wordIndex}`))) }, `${line}-${lineIndex}`));
|
|
43
|
+
}) })] }));
|
|
44
|
+
}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
export * from "./variants/index.js";
|
|
2
|
+
export * from "./animate-text.js";
|
|
3
|
+
export * from "./animate-logo.js";
|
|
4
|
+
export * from "./animate-border.js";
|
|
5
|
+
export * from "./motion-viewport.js";
|
|
6
|
+
export * from "./scroll-progress/index.js";
|
|
7
|
+
export * from "./animate-count-up.js";
|
|
8
|
+
export * from "./motion-container.js";
|
|
9
|
+
export * from "./motion-lazy.js";
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
export * from "./variants/index.js";
|
|
2
|
+
export * from "./animate-text.js";
|
|
3
|
+
export * from "./animate-logo.js";
|
|
4
|
+
export * from "./animate-border.js";
|
|
5
|
+
export * from "./motion-viewport.js";
|
|
6
|
+
export * from "./scroll-progress/index.js";
|
|
7
|
+
export * from "./animate-count-up.js";
|
|
8
|
+
export * from "./motion-container.js";
|
|
9
|
+
export * from "./motion-lazy.js";
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import type { HTMLMotionProps } from "framer-motion";
|
|
2
|
+
export type MotionContainerProps = HTMLMotionProps<"div"> & {
|
|
3
|
+
animate?: boolean;
|
|
4
|
+
action?: boolean;
|
|
5
|
+
};
|
|
6
|
+
export declare function MotionContainer({ animate, action, children, ...other }: MotionContainerProps & {
|
|
7
|
+
ref?: React.Ref<HTMLDivElement>;
|
|
8
|
+
}): import("react").JSX.Element;
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
3
|
+
import { m } from "framer-motion";
|
|
4
|
+
import { varContainer } from "./variants/index.js";
|
|
5
|
+
export function MotionContainer({ animate, action = false, children, ...other }) {
|
|
6
|
+
return (_jsx(m.div, { variants: varContainer(), initial: action ? false : "initial", animate: action ? (animate ? "animate" : "exit") : "animate", exit: action ? undefined : "exit", ...other, children: children }));
|
|
7
|
+
}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
'use client';
|
|
2
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
3
|
+
import { LazyMotion } from 'framer-motion';
|
|
4
|
+
const loadFeaturesAsync = async () => import('./features.js').then((res) => res.default);
|
|
5
|
+
export function MotionLazy({ children }) {
|
|
6
|
+
return (_jsx(LazyMotion, { strict: true, features: loadFeaturesAsync, children: children }));
|
|
7
|
+
}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import type { HTMLMotionProps } from "framer-motion";
|
|
2
|
+
export type MotionViewportProps = HTMLMotionProps<"div"> & {
|
|
3
|
+
disableAnimate?: boolean;
|
|
4
|
+
};
|
|
5
|
+
export declare function MotionViewport({ children, viewport, disableAnimate, ...other }: MotionViewportProps & {
|
|
6
|
+
ref?: React.Ref<HTMLDivElement>;
|
|
7
|
+
}): import("react").JSX.Element;
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
3
|
+
import { m } from "framer-motion";
|
|
4
|
+
import { useEffect, useState } from "react";
|
|
5
|
+
import { varContainer } from "./variants/index.js";
|
|
6
|
+
const SMALL_SCREEN_QUERY = "(max-width: 639px)";
|
|
7
|
+
function useSmallScreen() {
|
|
8
|
+
const [matches, setMatches] = useState(false);
|
|
9
|
+
useEffect(() => {
|
|
10
|
+
const query = window.matchMedia(SMALL_SCREEN_QUERY);
|
|
11
|
+
const update = () => setMatches(query.matches);
|
|
12
|
+
update();
|
|
13
|
+
query.addEventListener("change", update);
|
|
14
|
+
return () => query.removeEventListener("change", update);
|
|
15
|
+
}, []);
|
|
16
|
+
return matches;
|
|
17
|
+
}
|
|
18
|
+
export function MotionViewport({ children, viewport, disableAnimate = true, ...other }) {
|
|
19
|
+
const smallScreen = useSmallScreen();
|
|
20
|
+
if (smallScreen && disableAnimate) {
|
|
21
|
+
return (_jsx("div", { ...other, children: children }));
|
|
22
|
+
}
|
|
23
|
+
return (_jsx(m.div, { initial: "initial", whileInView: "animate", variants: varContainer(), viewport: { once: true, amount: 0.3, ...viewport }, ...other, children: children }));
|
|
24
|
+
}
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import * as React from "react";
|
|
2
|
+
import { type MotionValue } from "framer-motion";
|
|
3
|
+
export declare const scrollProgressClasses: {
|
|
4
|
+
circular: string;
|
|
5
|
+
linear: string;
|
|
6
|
+
};
|
|
7
|
+
type Color = "inherit" | "primary" | "secondary" | "info" | "success" | "warning" | "error";
|
|
8
|
+
export type ScrollProgressProps = {
|
|
9
|
+
/** From `useScrollProgress()`. */
|
|
10
|
+
progress: MotionValue<number>;
|
|
11
|
+
variant: "linear" | "circular";
|
|
12
|
+
size?: number;
|
|
13
|
+
thickness?: number;
|
|
14
|
+
portal?: boolean;
|
|
15
|
+
/** Axis being tracked; matters for right-to-left layouts. */
|
|
16
|
+
whenScroll?: "x" | "y";
|
|
17
|
+
color?: Color;
|
|
18
|
+
className?: string;
|
|
19
|
+
wrapperClassName?: string;
|
|
20
|
+
};
|
|
21
|
+
export declare function ScrollProgress({ size, portal, variant, className, wrapperClassName, thickness, whenScroll, color, progress: progressProp, }: ScrollProgressProps): React.JSX.Element;
|
|
22
|
+
export {};
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
3
|
+
import { createPortal } from "react-dom";
|
|
4
|
+
import { m, useSpring, useTransform } from "framer-motion";
|
|
5
|
+
import { cn } from "cn";
|
|
6
|
+
import { createClasses } from "../../../lib/create-classes.js";
|
|
7
|
+
export const scrollProgressClasses = {
|
|
8
|
+
circular: /* @__PURE__ */ createClasses("scroll__progress__circular"),
|
|
9
|
+
linear: /* @__PURE__ */ createClasses("scroll__progress__linear"),
|
|
10
|
+
};
|
|
11
|
+
const linearGradient = {
|
|
12
|
+
primary: "bg-[linear-gradient(135deg,var(--primary-light),var(--primary-main))]",
|
|
13
|
+
secondary: "bg-[linear-gradient(135deg,var(--secondary-light),var(--secondary-main))]",
|
|
14
|
+
info: "bg-[linear-gradient(135deg,var(--info-light),var(--info-main))]",
|
|
15
|
+
success: "bg-[linear-gradient(135deg,var(--success-light),var(--success-main))]",
|
|
16
|
+
warning: "bg-[linear-gradient(135deg,var(--warning-light),var(--warning-main))]",
|
|
17
|
+
error: "bg-[linear-gradient(135deg,var(--error-light),var(--error-main))]",
|
|
18
|
+
};
|
|
19
|
+
const circularColor = {
|
|
20
|
+
primary: "text-primary",
|
|
21
|
+
secondary: "text-brand-secondary",
|
|
22
|
+
info: "text-info",
|
|
23
|
+
success: "text-success",
|
|
24
|
+
warning: "text-warning",
|
|
25
|
+
error: "text-error",
|
|
26
|
+
};
|
|
27
|
+
export function ScrollProgress({ size, portal, variant, className, wrapperClassName, thickness = 3.6, whenScroll = "y", color = "primary", progress: progressProp, }) {
|
|
28
|
+
const rtl = typeof document !== "undefined" && document.dir === "rtl";
|
|
29
|
+
const flipped = useTransform(progressProp, [0, -1], [0, 1]);
|
|
30
|
+
const progress = rtl && whenScroll === "x" ? flipped : progressProp;
|
|
31
|
+
const scaleX = useSpring(progress, { stiffness: 100, damping: 30, restDelta: 0.001 });
|
|
32
|
+
const dimension = variant === "circular" ? (size ?? 64) : (size ?? 3);
|
|
33
|
+
const radius = dimension / 2 - thickness - 4;
|
|
34
|
+
const node = variant === "circular" ? (_jsxs(m.svg, { viewBox: `0 0 ${dimension} ${dimension}`, xmlns: "http://www.w3.org/2000/svg", width: dimension, height: dimension, className: cn(scrollProgressClasses.circular, "-rotate-90 text-text-primary [&_circle]:fill-none [&_circle]:stroke-current", color !== "inherit" && circularColor[color], className), children: [_jsx("circle", { cx: dimension / 2, cy: dimension / 2, r: radius, strokeWidth: thickness, strokeOpacity: 0.2 }), _jsx(m.circle, { cx: dimension / 2, cy: dimension / 2, r: radius, strokeWidth: thickness, style: { pathLength: progress } })] })) : (_jsx(m.div, { className: cn(scrollProgressClasses.linear, "inset-x-0 top-0 origin-left bg-text-primary", color !== "inherit" && linearGradient[color], className), style: { height: dimension, scaleX } }));
|
|
35
|
+
const wrapped = _jsx("div", { className: wrapperClassName, children: node });
|
|
36
|
+
return portal && typeof document !== "undefined" ? createPortal(wrapped, document.body) : wrapped;
|
|
37
|
+
}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import * as React from "react";
|
|
2
|
+
import { type MotionValue } from "framer-motion";
|
|
3
|
+
export type UseScrollProgressReturn = {
|
|
4
|
+
scrollXProgress: MotionValue<number>;
|
|
5
|
+
scrollYProgress: MotionValue<number>;
|
|
6
|
+
elementRef: React.RefObject<HTMLDivElement | null>;
|
|
7
|
+
};
|
|
8
|
+
export type UseScrollProgress = "document" | "container";
|
|
9
|
+
/** Scroll progress of the page, or of the element you attach `elementRef` to. */
|
|
10
|
+
export declare function useScrollProgress(target?: UseScrollProgress): UseScrollProgressReturn;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
import * as React from "react";
|
|
3
|
+
import { useScroll } from "framer-motion";
|
|
4
|
+
/** Scroll progress of the page, or of the element you attach `elementRef` to. */
|
|
5
|
+
export function useScrollProgress(target = "document") {
|
|
6
|
+
const elementRef = React.useRef(null);
|
|
7
|
+
const { scrollYProgress, scrollXProgress } = useScroll(target === "container" ? { container: elementRef } : undefined);
|
|
8
|
+
return React.useMemo(() => ({ elementRef, scrollXProgress, scrollYProgress }), [scrollXProgress, scrollYProgress]);
|
|
9
|
+
}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import type { Transition } from 'framer-motion';
|
|
2
|
+
export declare const varHover: (value?: number) => {
|
|
3
|
+
scale: number;
|
|
4
|
+
};
|
|
5
|
+
export declare const varTap: (value?: number) => {
|
|
6
|
+
scale: number;
|
|
7
|
+
};
|
|
8
|
+
export declare const transitionTap: (props?: Transition) => Transition;
|
|
9
|
+
export declare const transitionHover: (props?: Transition) => Transition;
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
export const varHover = (value = 1.09) => ({
|
|
2
|
+
scale: value,
|
|
3
|
+
});
|
|
4
|
+
export const varTap = (value = 0.9) => ({
|
|
5
|
+
scale: value,
|
|
6
|
+
});
|
|
7
|
+
export const transitionTap = (props) => ({
|
|
8
|
+
type: 'spring',
|
|
9
|
+
stiffness: 400,
|
|
10
|
+
damping: 18,
|
|
11
|
+
...props,
|
|
12
|
+
});
|
|
13
|
+
export const transitionHover = (props) => ({
|
|
14
|
+
duration: 0.32,
|
|
15
|
+
ease: [0.43, 0.13, 0.23, 0.96],
|
|
16
|
+
...props,
|
|
17
|
+
});
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import type { Variants, TargetAndTransition } from 'framer-motion';
|
|
2
|
+
type Direction = 'top' | 'bottom' | 'left' | 'right';
|
|
3
|
+
export declare const varBgColor: (colors: string[], options?: TargetAndTransition) => Variants;
|
|
4
|
+
export declare const varBgKenburns: (direction: Direction, options?: TargetAndTransition) => Variants;
|
|
5
|
+
export declare const varBgPan: (direction: Direction, colors: string[], options?: TargetAndTransition) => Variants;
|
|
6
|
+
export {};
|