@momo-webplatform/mobase-next 1.0.1
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 +136 -0
- package/dist/chunk-7LRQ2WLZ.mjs +1 -0
- package/dist/components/blocks/BlogSection/BlogSection.d.mts +17 -0
- package/dist/components/blocks/BlogSection/BlogSection.mjs +1 -0
- package/dist/components/blocks/BlogSection/BlogSectionTemplate.d.mts +15 -0
- package/dist/components/blocks/BlogSection/BlogSectionTemplate.mjs +1 -0
- package/dist/components/blocks/BlogSection/index.d.mts +14 -0
- package/dist/components/blocks/BlogSection/index.mjs +1 -0
- package/dist/components/blocks/BlogSection/templates/BlogSectionTemplateOne.d.mts +17 -0
- package/dist/components/blocks/BlogSection/templates/BlogSectionTemplateOne.mjs +1 -0
- package/dist/components/blocks/BlogSection/templates/BlogSectionTemplateTwo.d.mts +17 -0
- package/dist/components/blocks/BlogSection/templates/BlogSectionTemplateTwo.mjs +1 -0
- package/dist/components/blocks/BlogSection/utils.d.mts +49 -0
- package/dist/components/blocks/BlogSection/utils.mjs +0 -0
- package/dist/components/blocks/CTASection/CTASection.d.mts +17 -0
- package/dist/components/blocks/CTASection/CTASection.mjs +1 -0
- package/dist/components/blocks/CTASection/CTASectionTemplate.d.mts +18 -0
- package/dist/components/blocks/CTASection/CTASectionTemplate.mjs +1 -0
- package/dist/components/blocks/CTASection/index.d.mts +14 -0
- package/dist/components/blocks/CTASection/index.mjs +1 -0
- package/dist/components/blocks/CTASection/utils.d.mts +60 -0
- package/dist/components/blocks/CTASection/utils.mjs +0 -0
- package/dist/components/blocks/FAQSection/FAQSection.d.mts +17 -0
- package/dist/components/blocks/FAQSection/FAQSection.mjs +1 -0
- package/dist/components/blocks/FAQSection/FAQTemplate.d.mts +18 -0
- package/dist/components/blocks/FAQSection/FAQTemplate.mjs +1 -0
- package/dist/components/blocks/FAQSection/index.d.mts +14 -0
- package/dist/components/blocks/FAQSection/index.mjs +1 -0
- package/dist/components/blocks/FAQSection/utils.d.mts +36 -0
- package/dist/components/blocks/FAQSection/utils.mjs +0 -0
- package/dist/components/blocks/FeatureSection/FeatureSection.d.mts +17 -0
- package/dist/components/blocks/FeatureSection/FeatureSection.mjs +1 -0
- package/dist/components/blocks/FeatureSection/FeatureTemlates.d.mts +29 -0
- package/dist/components/blocks/FeatureSection/FeatureTemlates.mjs +1 -0
- package/dist/components/blocks/FeatureSection/index.d.mts +14 -0
- package/dist/components/blocks/FeatureSection/index.mjs +1 -0
- package/dist/components/blocks/FeatureSection/utils.d.mts +77 -0
- package/dist/components/blocks/FeatureSection/utils.mjs +0 -0
- package/dist/components/blocks/GiftListSection/GiftListSection.d.mts +17 -0
- package/dist/components/blocks/GiftListSection/GiftListSection.mjs +1 -0
- package/dist/components/blocks/GiftListSection/GiftListSectionTemplate.d.mts +17 -0
- package/dist/components/blocks/GiftListSection/GiftListSectionTemplate.mjs +1 -0
- package/dist/components/blocks/GiftListSection/index.d.mts +14 -0
- package/dist/components/blocks/GiftListSection/index.mjs +1 -0
- package/dist/components/blocks/GiftListSection/utils.d.mts +81 -0
- package/dist/components/blocks/GiftListSection/utils.mjs +0 -0
- package/dist/components/blocks/HeroSection/HeroSection.d.mts +18 -0
- package/dist/components/blocks/HeroSection/HeroSection.mjs +1 -0
- package/dist/components/blocks/HeroSection/HeroSectionFeatures.d.mts +31 -0
- package/dist/components/blocks/HeroSection/HeroSectionFeatures.mjs +1 -0
- package/dist/components/blocks/HeroSection/HeroSectionMedia.d.mts +17 -0
- package/dist/components/blocks/HeroSection/HeroSectionMedia.mjs +1 -0
- package/dist/components/blocks/HeroSection/HeroSectionStats.d.mts +19 -0
- package/dist/components/blocks/HeroSection/HeroSectionStats.mjs +1 -0
- package/dist/components/blocks/HeroSection/HeroSectionTemplate.d.mts +19 -0
- package/dist/components/blocks/HeroSection/HeroSectionTemplate.mjs +1 -0
- package/dist/components/blocks/HeroSection/index.d.mts +14 -0
- package/dist/components/blocks/HeroSection/index.mjs +1 -0
- package/dist/components/blocks/HeroSection/utils.d.mts +84 -0
- package/dist/components/blocks/HeroSection/utils.mjs +1 -0
- package/dist/components/blocks/HowItWorksSection/HowItWorksSection.d.mts +17 -0
- package/dist/components/blocks/HowItWorksSection/HowItWorksSection.mjs +1 -0
- package/dist/components/blocks/HowItWorksSection/HowItWorksSectionTemplate.d.mts +19 -0
- package/dist/components/blocks/HowItWorksSection/HowItWorksSectionTemplate.mjs +1 -0
- package/dist/components/blocks/HowItWorksSection/index.d.mts +14 -0
- package/dist/components/blocks/HowItWorksSection/index.mjs +1 -0
- package/dist/components/blocks/HowItWorksSection/utils.d.mts +47 -0
- package/dist/components/blocks/HowItWorksSection/utils.mjs +0 -0
- package/dist/components/blocks/MetricsSection/MetricsSection.d.mts +17 -0
- package/dist/components/blocks/MetricsSection/MetricsSection.mjs +1 -0
- package/dist/components/blocks/MetricsSection/MetricsSectionTemplate.d.mts +15 -0
- package/dist/components/blocks/MetricsSection/MetricsSectionTemplate.mjs +1 -0
- package/dist/components/blocks/MetricsSection/index.d.mts +14 -0
- package/dist/components/blocks/MetricsSection/index.mjs +1 -0
- package/dist/components/blocks/MetricsSection/template/MetricsSectionTemplateOne.d.mts +17 -0
- package/dist/components/blocks/MetricsSection/template/MetricsSectionTemplateOne.mjs +1 -0
- package/dist/components/blocks/MetricsSection/template/MetricsSectionTemplateTwo.d.mts +17 -0
- package/dist/components/blocks/MetricsSection/template/MetricsSectionTemplateTwo.mjs +1 -0
- package/dist/components/blocks/MetricsSection/utils.d.mts +38 -0
- package/dist/components/blocks/MetricsSection/utils.mjs +0 -0
- package/dist/components/blocks/NewsSection/NewsSection.d.mts +17 -0
- package/dist/components/blocks/NewsSection/NewsSection.mjs +1 -0
- package/dist/components/blocks/NewsSection/NewsSectionTemplate.d.mts +17 -0
- package/dist/components/blocks/NewsSection/NewsSectionTemplate.mjs +1 -0
- package/dist/components/blocks/NewsSection/index.d.mts +14 -0
- package/dist/components/blocks/NewsSection/index.mjs +1 -0
- package/dist/components/blocks/NewsSection/utils.d.mts +64 -0
- package/dist/components/blocks/NewsSection/utils.mjs +0 -0
- package/dist/components/blocks/SocialProofSection/SocialProofSection.d.mts +17 -0
- package/dist/components/blocks/SocialProofSection/SocialProofSection.mjs +1 -0
- package/dist/components/blocks/SocialProofSection/SocialProofTemplates.d.mts +17 -0
- package/dist/components/blocks/SocialProofSection/SocialProofTemplates.mjs +1 -0
- package/dist/components/blocks/SocialProofSection/index.d.mts +14 -0
- package/dist/components/blocks/SocialProofSection/index.mjs +1 -0
- package/dist/components/blocks/SocialProofSection/templates/SocialProofTemplate1.d.mts +17 -0
- package/dist/components/blocks/SocialProofSection/templates/SocialProofTemplate1.mjs +1 -0
- package/dist/components/blocks/SocialProofSection/templates/SocialProofTemplate2.d.mts +17 -0
- package/dist/components/blocks/SocialProofSection/templates/SocialProofTemplate2.mjs +1 -0
- package/dist/components/blocks/SocialProofSection/templates/SocialProofTemplate3.d.mts +17 -0
- package/dist/components/blocks/SocialProofSection/templates/SocialProofTemplate3.mjs +1 -0
- package/dist/components/blocks/SocialProofSection/templates/SocialProofTemplate4.d.mts +17 -0
- package/dist/components/blocks/SocialProofSection/templates/SocialProofTemplate4.mjs +18 -0
- package/dist/components/blocks/SocialProofSection/utils.d.mts +31 -0
- package/dist/components/blocks/SocialProofSection/utils.mjs +0 -0
- package/dist/components/blocks/TestimonialSection/TestimonialSection.d.mts +17 -0
- package/dist/components/blocks/TestimonialSection/TestimonialSection.mjs +1 -0
- package/dist/components/blocks/TestimonialSection/index.d.mts +14 -0
- package/dist/components/blocks/TestimonialSection/index.mjs +1 -0
- package/dist/components/blocks/TestimonialSection/shared.d.mts +29 -0
- package/dist/components/blocks/TestimonialSection/shared.mjs +1 -0
- package/dist/components/blocks/TestimonialSection/templates/TestimonialTemplateOne.d.mts +17 -0
- package/dist/components/blocks/TestimonialSection/templates/TestimonialTemplateOne.mjs +1 -0
- package/dist/components/blocks/TestimonialSection/templates/TestimonialTemplateThree.d.mts +17 -0
- package/dist/components/blocks/TestimonialSection/templates/TestimonialTemplateThree.mjs +1 -0
- package/dist/components/blocks/TestimonialSection/templates/TestimonialTemplateTwo.d.mts +17 -0
- package/dist/components/blocks/TestimonialSection/templates/TestimonialTemplateTwo.mjs +5 -0
- package/dist/components/blocks/TestimonialSection/utils.d.mts +37 -0
- package/dist/components/blocks/TestimonialSection/utils.mjs +1 -0
- package/dist/components/blocks/action-button/action-button.d.mts +15 -0
- package/dist/components/blocks/action-button/action-button.mjs +1 -0
- package/dist/components/blocks/action-button/index.d.mts +12 -0
- package/dist/components/blocks/action-button/index.mjs +1 -0
- package/dist/components/blocks/action-button/utils.d.mts +40 -0
- package/dist/components/blocks/action-button/utils.mjs +1 -0
- package/dist/components/blocks/common-blocks/common-blocks.d.mts +18 -0
- package/dist/components/blocks/common-blocks/common-blocks.mjs +1 -0
- package/dist/components/blocks/common-blocks/index.d.mts +13 -0
- package/dist/components/blocks/common-blocks/index.mjs +1 -0
- package/dist/components/blocks/common-blocks/utils.d.mts +90 -0
- package/dist/components/blocks/common-blocks/utils.mjs +0 -0
- package/dist/components/blocks/dialog-qr/DialogQr.d.mts +42 -0
- package/dist/components/blocks/dialog-qr/DialogQr.mjs +70 -0
- package/dist/components/blocks/dialog-qr/index.d.mts +8 -0
- package/dist/components/blocks/dialog-qr/index.mjs +1 -0
- package/dist/components/blocks/footer/defaults.d.mts +39 -0
- package/dist/components/blocks/footer/defaults.mjs +1 -0
- package/dist/components/blocks/footer/footer-content.d.mts +6 -0
- package/dist/components/blocks/footer/footer-content.mjs +5 -0
- package/dist/components/blocks/footer/footer.d.mts +6 -0
- package/dist/components/blocks/footer/footer.mjs +1 -0
- package/dist/components/blocks/footer/index.d.mts +5 -0
- package/dist/components/blocks/footer/index.mjs +1 -0
- package/dist/components/blocks/footer/types.d.mts +27 -0
- package/dist/components/blocks/footer/types.mjs +0 -0
- package/dist/components/blocks/header-navigation/header-navigation.d.mts +7 -0
- package/dist/components/blocks/header-navigation/header-navigation.mjs +5 -0
- package/dist/components/blocks/header-navigation/index.d.mts +4 -0
- package/dist/components/blocks/header-navigation/index.mjs +1 -0
- package/dist/components/blocks/header-navigation/list-item-mobile.d.mts +14 -0
- package/dist/components/blocks/header-navigation/list-item-mobile.mjs +1 -0
- package/dist/components/blocks/header-navigation/list-item.d.mts +14 -0
- package/dist/components/blocks/header-navigation/list-item.mjs +1 -0
- package/dist/components/blocks/header-navigation/mobile-menu.d.mts +11 -0
- package/dist/components/blocks/header-navigation/mobile-menu.mjs +1 -0
- package/dist/components/blocks/header-navigation/nav-items-mobile.d.mts +10 -0
- package/dist/components/blocks/header-navigation/nav-items-mobile.mjs +1 -0
- package/dist/components/blocks/header-navigation/nav-items.d.mts +11 -0
- package/dist/components/blocks/header-navigation/nav-items.mjs +1 -0
- package/dist/components/blocks/header-navigation/types.d.mts +44 -0
- package/dist/components/blocks/header-navigation/types.mjs +0 -0
- package/dist/components/blocks/heading-group/HeadingGroup.d.mts +97 -0
- package/dist/components/blocks/heading-group/HeadingGroup.mjs +1 -0
- package/dist/components/blocks/heading-group/index.d.mts +3 -0
- package/dist/components/blocks/heading-group/index.mjs +1 -0
- package/dist/components/mobase/accordion.d.mts +9 -0
- package/dist/components/mobase/accordion.mjs +1 -0
- package/dist/components/mobase/alert-dialog.d.mts +24 -0
- package/dist/components/mobase/alert-dialog.mjs +1 -0
- package/dist/components/mobase/alert.d.mts +14 -0
- package/dist/components/mobase/alert.mjs +1 -0
- package/dist/components/mobase/aspect-ratio.d.mts +8 -0
- package/dist/components/mobase/aspect-ratio.mjs +1 -0
- package/dist/components/mobase/autocomplete.d.mts +34 -0
- package/dist/components/mobase/autocomplete.mjs +1 -0
- package/dist/components/mobase/avatar.d.mts +14 -0
- package/dist/components/mobase/avatar.mjs +1 -0
- package/dist/components/mobase/badge.d.mts +15 -0
- package/dist/components/mobase/badge.mjs +1 -0
- package/dist/components/mobase/breadcrumb.d.mts +13 -0
- package/dist/components/mobase/breadcrumb.mjs +1 -0
- package/dist/components/mobase/button-group.d.mts +16 -0
- package/dist/components/mobase/button-group.mjs +1 -0
- package/dist/components/mobase/button.d.mts +22 -0
- package/dist/components/mobase/button.mjs +1 -0
- package/dist/components/mobase/calendar.d.mts +16 -0
- package/dist/components/mobase/calendar.mjs +1 -0
- package/dist/components/mobase/card.d.mts +14 -0
- package/dist/components/mobase/card.mjs +1 -0
- package/dist/components/mobase/carousel.d.mts +37 -0
- package/dist/components/mobase/carousel.mjs +1 -0
- package/dist/components/mobase/checkbox.d.mts +7 -0
- package/dist/components/mobase/checkbox.mjs +1 -0
- package/dist/components/mobase/close-button.d.mts +17 -0
- package/dist/components/mobase/close-button.mjs +1 -0
- package/dist/components/mobase/combobox.d.mts +29 -0
- package/dist/components/mobase/combobox.mjs +1 -0
- package/dist/components/mobase/command.d.mts +31 -0
- package/dist/components/mobase/command.mjs +1 -0
- package/dist/components/mobase/date-picker.d.mts +46 -0
- package/dist/components/mobase/date-picker.mjs +1 -0
- package/dist/components/mobase/dialog.d.mts +41 -0
- package/dist/components/mobase/dialog.mjs +1 -0
- package/dist/components/mobase/drawer.d.mts +46 -0
- package/dist/components/mobase/drawer.mjs +1 -0
- package/dist/components/mobase/dropdown-menu.d.mts +33 -0
- package/dist/components/mobase/dropdown-menu.mjs +1 -0
- package/dist/components/mobase/empty.d.mts +20 -0
- package/dist/components/mobase/empty.mjs +1 -0
- package/dist/components/mobase/field.d.mts +30 -0
- package/dist/components/mobase/field.mjs +1 -0
- package/dist/components/mobase/form.d.mts +7 -0
- package/dist/components/mobase/form.mjs +1 -0
- package/dist/components/mobase/hitbox.d.mts +19 -0
- package/dist/components/mobase/hitbox.mjs +1 -0
- package/dist/components/mobase/horizontal-scroll.d.mts +24 -0
- package/dist/components/mobase/horizontal-scroll.mjs +1 -0
- package/dist/components/mobase/infinite-slider.d.mts +19 -0
- package/dist/components/mobase/infinite-slider.mjs +1 -0
- package/dist/components/mobase/input-group.d.mts +27 -0
- package/dist/components/mobase/input-group.mjs +1 -0
- package/dist/components/mobase/input-search.d.mts +8 -0
- package/dist/components/mobase/input-search.mjs +1 -0
- package/dist/components/mobase/input.d.mts +34 -0
- package/dist/components/mobase/input.mjs +1 -0
- package/dist/components/mobase/item.d.mts +27 -0
- package/dist/components/mobase/item.mjs +1 -0
- package/dist/components/mobase/kbd.d.mts +6 -0
- package/dist/components/mobase/kbd.mjs +1 -0
- package/dist/components/mobase/label.d.mts +6 -0
- package/dist/components/mobase/label.mjs +1 -0
- package/dist/components/mobase/logo.d.mts +26 -0
- package/dist/components/mobase/logo.mjs +1 -0
- package/dist/components/mobase/logos-carousel.d.mts +15 -0
- package/dist/components/mobase/logos-carousel.mjs +27 -0
- package/dist/components/mobase/marquee.d.mts +16 -0
- package/dist/components/mobase/marquee.mjs +1 -0
- package/dist/components/mobase/native-select.d.mts +11 -0
- package/dist/components/mobase/native-select.mjs +1 -0
- package/dist/components/mobase/navigation-menu.d.mts +15 -0
- package/dist/components/mobase/navigation-menu.mjs +1 -0
- package/dist/components/mobase/pagination.d.mts +23 -0
- package/dist/components/mobase/pagination.mjs +1 -0
- package/dist/components/mobase/popover.d.mts +12 -0
- package/dist/components/mobase/popover.mjs +1 -0
- package/dist/components/mobase/progress.d.mts +10 -0
- package/dist/components/mobase/progress.mjs +1 -0
- package/dist/components/mobase/radio-group.d.mts +10 -0
- package/dist/components/mobase/radio-group.mjs +1 -0
- package/dist/components/mobase/scroll-area.d.mts +11 -0
- package/dist/components/mobase/scroll-area.mjs +1 -0
- package/dist/components/mobase/select.d.mts +21 -0
- package/dist/components/mobase/select.mjs +1 -0
- package/dist/components/mobase/separator.d.mts +6 -0
- package/dist/components/mobase/separator.mjs +1 -0
- package/dist/components/mobase/skeleton.d.mts +5 -0
- package/dist/components/mobase/skeleton.mjs +1 -0
- package/dist/components/mobase/slider.d.mts +6 -0
- package/dist/components/mobase/slider.mjs +1 -0
- package/dist/components/mobase/sliding-number.d.mts +10 -0
- package/dist/components/mobase/sliding-number.mjs +1 -0
- package/dist/components/mobase/spinner.d.mts +12 -0
- package/dist/components/mobase/spinner.mjs +1 -0
- package/dist/components/mobase/switch.d.mts +8 -0
- package/dist/components/mobase/switch.mjs +1 -0
- package/dist/components/mobase/table.d.mts +13 -0
- package/dist/components/mobase/table.mjs +1 -0
- package/dist/components/mobase/tabs.d.mts +14 -0
- package/dist/components/mobase/tabs.mjs +1 -0
- package/dist/components/mobase/text-effect.d.mts +30 -0
- package/dist/components/mobase/text-effect.mjs +2 -0
- package/dist/components/mobase/textarea.d.mts +10 -0
- package/dist/components/mobase/textarea.mjs +1 -0
- package/dist/components/mobase/toast.d.mts +14 -0
- package/dist/components/mobase/toast.mjs +1 -0
- package/dist/components/mobase/tooltip.d.mts +9 -0
- package/dist/components/mobase/tooltip.mjs +1 -0
- package/dist/hooks/use-click-outside.d.mts +6 -0
- package/dist/hooks/use-click-outside.mjs +1 -0
- package/dist/hooks/use-copy-to-clipboard.d.mts +9 -0
- package/dist/hooks/use-copy-to-clipboard.mjs +1 -0
- package/dist/hooks/use-event-callback.d.mts +19 -0
- package/dist/hooks/use-event-callback.mjs +1 -0
- package/dist/hooks/use-event-listener.d.mts +8 -0
- package/dist/hooks/use-event-listener.mjs +1 -0
- package/dist/hooks/use-is-client.d.mts +3 -0
- package/dist/hooks/use-is-client.mjs +1 -0
- package/dist/hooks/use-is-momo-app.d.mts +3 -0
- package/dist/hooks/use-is-momo-app.mjs +1 -0
- package/dist/hooks/use-is-touch-device.d.mts +7 -0
- package/dist/hooks/use-is-touch-device.mjs +1 -0
- package/dist/hooks/use-isomorphic-layout-effect.d.mts +5 -0
- package/dist/hooks/use-isomorphic-layout-effect.mjs +1 -0
- package/dist/hooks/use-local-storage.d.mts +5 -0
- package/dist/hooks/use-local-storage.mjs +1 -0
- package/dist/hooks/use-mobile.d.mts +3 -0
- package/dist/hooks/use-mobile.mjs +1 -0
- package/dist/hooks/use-window-size.d.mts +11 -0
- package/dist/hooks/use-window-size.mjs +1 -0
- package/dist/index.d.mts +137 -0
- package/dist/index.mjs +1 -0
- package/dist/lib/legacy-button-variant.d.mts +13 -0
- package/dist/lib/legacy-button-variant.mjs +1 -0
- package/dist/lib/media-ratio.d.mts +6 -0
- package/dist/lib/media-ratio.mjs +1 -0
- package/dist/lib/plain-text-from-html.d.mts +6 -0
- package/dist/lib/plain-text-from-html.mjs +1 -0
- package/dist/lib/qr-image-url.d.mts +13 -0
- package/dist/lib/qr-image-url.mjs +1 -0
- package/dist/lib/scroll-to-selector.d.mts +9 -0
- package/dist/lib/scroll-to-selector.mjs +1 -0
- package/dist/lib/testimonial-avatar.d.mts +6 -0
- package/dist/lib/testimonial-avatar.mjs +1 -0
- package/dist/lib/utils.d.mts +5 -0
- package/dist/lib/utils.mjs +1 -0
- package/package.json +68 -0
- package/src/styles/globals.css +456 -0
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{a as s,b as p,c as o}from"../../chunk-7LRQ2WLZ.mjs";import{jsx as n,jsxs as C}from"react/jsx-runtime";import{mergeProps as c}from"@base-ui/react/merge-props";import{useRender as l}from"@base-ui/react/use-render";import{cn as m}from"../../lib/utils";import{ChevronRightIcon as u,MoreHorizontalIcon as d}from"lucide-react";function b(t){var e=t,{className:r}=e,a=o(e,["className"]);return n("nav",s({"aria-label":"breadcrumb","data-slot":"breadcrumb",className:m(r)},a))}function f(t){var e=t,{className:r}=e,a=o(e,["className"]);return n("ol",s({"data-slot":"breadcrumb-list",className:m("flex flex-wrap items-center gap-1.5 text-sm wrap-break-word text-muted-foreground sm:gap-2.5",r)},a))}function g(t){var e=t,{className:r}=e,a=o(e,["className"]);return n("li",s({"data-slot":"breadcrumb-item",className:m("inline-flex items-center gap-1.5",r)},a))}function R(e){var i=e,{className:r,render:a}=i,t=o(i,["className","render"]);return l({defaultTagName:"a",props:c({className:m("transition-colors hover:text-foreground",r)},t),render:a,state:{slot:"breadcrumb-link"}})}function N(t){var e=t,{className:r}=e,a=o(e,["className"]);return n("span",s({"data-slot":"breadcrumb-page",role:"link","aria-disabled":"true","aria-current":"page",className:m("font-normal text-foreground",r)},a))}function P(e){var i=e,{children:r,className:a}=i,t=o(i,["children","className"]);return n("li",p(s({"data-slot":"breadcrumb-separator",role:"presentation","aria-hidden":"true",className:m("[&>svg]:size-3.5",a)},t),{children:r!=null?r:n(u,{})}))}function x(t){var e=t,{className:r}=e,a=o(e,["className"]);return C("span",p(s({"data-slot":"breadcrumb-ellipsis",role:"presentation","aria-hidden":"true",className:m("flex size-5 items-center justify-center [&>svg]:size-4",r)},a),{children:[n(d,{}),n("span",{className:"sr-only",children:"More"})]}))}export{b as Breadcrumb,x as BreadcrumbEllipsis,g as BreadcrumbItem,R as BreadcrumbLink,f as BreadcrumbList,N as BreadcrumbPage,P as BreadcrumbSeparator};
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import * as React$1 from 'react';
|
|
2
|
+
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
3
|
+
import * as class_variance_authority_types from 'class-variance-authority/types';
|
|
4
|
+
import { useRender } from '@base-ui/react/use-render';
|
|
5
|
+
import { VariantProps } from 'class-variance-authority';
|
|
6
|
+
import { Separator } from './separator.mjs';
|
|
7
|
+
import '@base-ui/react/separator';
|
|
8
|
+
|
|
9
|
+
declare const buttonGroupVariants: (props?: ({
|
|
10
|
+
orientation?: "horizontal" | "vertical" | null | undefined;
|
|
11
|
+
} & class_variance_authority_types.ClassProp) | undefined) => string;
|
|
12
|
+
declare function ButtonGroup({ className, orientation, ...props }: React.ComponentProps<"div"> & VariantProps<typeof buttonGroupVariants>): react_jsx_runtime.JSX.Element;
|
|
13
|
+
declare function ButtonGroupText({ className, render, ...props }: useRender.ComponentProps<"div">): React$1.ReactElement<unknown, string | React$1.JSXElementConstructor<any>>;
|
|
14
|
+
declare function ButtonGroupSeparator({ className, orientation, ...props }: React.ComponentProps<typeof Separator>): react_jsx_runtime.JSX.Element;
|
|
15
|
+
|
|
16
|
+
export { ButtonGroup, ButtonGroupSeparator, ButtonGroupText, buttonGroupVariants };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{a as n,c as r}from"../../chunk-7LRQ2WLZ.mjs";import{jsx as i}from"react/jsx-runtime";import{mergeProps as u}from"@base-ui/react/merge-props";import{useRender as p}from"@base-ui/react/use-render";import{cva as c}from"class-variance-authority";import{cn as s}from"../../lib/utils";import{Separator as m}from"./separator";const d=c("flex w-fit items-stretch *:focus-visible:relative *:focus-visible:z-10 has-[>[data-slot=button-group]]:gap-2 has-[select[aria-hidden=true]:last-child]:[&>[data-slot=select-trigger]:last-of-type]:rounded-r-4xl [&>[data-slot=select-trigger]:not([class*='w-'])]:w-fit [&>input]:flex-1",{variants:{orientation:{horizontal:"*:data-slot:rounded-r-none [&>[data-slot]:not(:has(~[data-slot]))]:rounded-r-4xl! [&>[data-slot]~[data-slot]]:rounded-l-none [&>[data-slot]~[data-slot]]:border-l-0",vertical:"flex-col *:data-slot:rounded-b-none [&>[data-slot]:not(:has(~[data-slot]))]:rounded-b-4xl! [&>[data-slot]~[data-slot]]:rounded-t-none [&>[data-slot]~[data-slot]]:border-t-0"}},defaultVariants:{orientation:"horizontal"}});function f(l){var t=l,{className:a,orientation:o}=t,e=r(t,["className","orientation"]);return i("div",n({role:"group","data-slot":"button-group","data-orientation":o,className:s(d({orientation:o}),a)},e))}function v(l){var t=l,{className:a,render:o}=t,e=r(t,["className","render"]);return p({defaultTagName:"div",props:u({className:s("flex items-center gap-2 rounded-4xl border bg-muted px-2.5 text-sm font-medium [&_svg]:pointer-events-none [&_svg:not([class*='size-'])]:size-4",a)},e),render:o,state:{slot:"button-group-text"}})}function g(l){var t=l,{className:a,orientation:o="vertical"}=t,e=r(t,["className","orientation"]);return i(m,n({"data-slot":"button-group-separator",orientation:o,className:s("relative self-stretch bg-input data-horizontal:mx-px data-horizontal:w-auto data-vertical:my-px data-vertical:h-auto",a)},e))}export{f as ButtonGroup,g as ButtonGroupSeparator,v as ButtonGroupText,d as buttonGroupVariants};
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
|
+
import * as class_variance_authority_types from 'class-variance-authority/types';
|
|
3
|
+
import { Button as Button$1 } from '@base-ui/react/button';
|
|
4
|
+
import { VariantProps } from 'class-variance-authority';
|
|
5
|
+
import { ReactNode } from 'react';
|
|
6
|
+
|
|
7
|
+
type ButtonShape = "rounded" | "square";
|
|
8
|
+
declare const buttonVariants: (props?: ({
|
|
9
|
+
variant?: "link" | "default" | "outline" | "secondary" | "tertiary" | "ghost" | "destructive" | null | undefined;
|
|
10
|
+
size?: "xs" | "sm" | "default" | "lg" | "icon" | "icon-xs" | "icon-sm" | "icon-lg" | null | undefined;
|
|
11
|
+
} & class_variance_authority_types.ClassProp) | undefined) => string;
|
|
12
|
+
type ButtonProps = Omit<Button$1.Props, "prefix" | "suffix"> & VariantProps<typeof buttonVariants> & {
|
|
13
|
+
loading?: boolean;
|
|
14
|
+
shape?: ButtonShape;
|
|
15
|
+
/** Renders before children (e.g. icon). Use for leading icon: `<Button prefix={<ArrowLeft />}>Upload</Button>` */
|
|
16
|
+
prefix?: ReactNode;
|
|
17
|
+
/** Renders after children (e.g. icon). Use for trailing icon. */
|
|
18
|
+
suffix?: ReactNode;
|
|
19
|
+
};
|
|
20
|
+
declare function Button({ loading, prefix, suffix, variant, size, shape, className, children, disabled, ...props }: ButtonProps): react_jsx_runtime.JSX.Element;
|
|
21
|
+
|
|
22
|
+
export { Button, type ButtonProps, buttonVariants };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use client";import{a as d,b as u,c as l}from"../../chunk-7LRQ2WLZ.mjs";import{jsx as o,jsxs as k}from"react/jsx-runtime";import{Button as y}from"@base-ui/react/button";import{cva as B}from"class-variance-authority";import{cn as S}from"../../lib/utils";import{Spinner as z}from"./spinner";const p=B("group/button inline-flex shrink-0 items-center justify-center rounded-4xl border border-transparent bg-clip-padding text-sm font-medium whitespace-nowrap transition-all outline-none select-none gap-0 [&_svg:not([class*='size-'])]:size-4.5 focus-visible:border-ring focus-visible:ring-[1px] focus-visible:ring-ring active:translate-y-px disabled:pointer-events-none disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-[1px] aria-invalid:ring-destructive/20 [&_svg]:pointer-events-none [&_svg]:shrink-0 gap-1.5 ",{variants:{variant:{default:"bg-primary text-white hover:bg-primary/80",outline:"border border-border bg-background-1 hover:bg-input/50 hover:text-foreground aria-expanded:bg-muted aria-expanded:text-foreground",secondary:"bg-secondary text-secondary-foreground hover:bg-input aria-expanded:bg-secondary aria-expanded:text-secondary-foreground",tertiary:"bg-primary-foreground/70 text-primary hover:bg-primary-foreground aria-expanded:bg-primary-foreground aria-expanded:text-primary",ghost:"hover:bg-muted hover:text-foreground aria-expanded:bg-muted aria-expanded:text-foreground",destructive:"bg-destructive/10 text-destructive hover:bg-destructive/20 focus-visible:border-destructive/40 focus-visible:ring-destructive/20",link:"text-primary underline-offset-4 hover:underline"},size:{xs:"h-6 px-2.5 text-xs [&_svg:not([class*='size-'])]:size-4",default:"h-9 px-4",sm:"h-8 px-3",lg:"h-10 px-4 text-base",icon:"size-9","icon-xs":"size-6 [&_svg:not([class*='size-'])]:size-4","icon-sm":"size-8","icon-lg":"size-10"}},defaultVariants:{variant:"default",size:"default"}}),P={rounded:{},square:{default:"rounded-lg",xs:"rounded-md",sm:"rounded-lg",lg:"rounded-lg",icon:"rounded-lg","icon-xs":"rounded-lg","icon-sm":"rounded-lg","icon-lg":"rounded-lg"}};function V(e){return e==="icon-xs"||e==="xs"?"xs":"sm"}function N(R){var s=R,{loading:e=!1,prefix:i,suffix:a,variant:t,size:r,shape:c="rounded",className:g,children:f,disabled:b}=s,m=l(s,["loading","prefix","suffix","variant","size","shape","className","children","disabled"]);const x=t!=null?t:"default",n=r!=null?r:"default",v=i!==void 0,h=a!==void 0;return k(y,u(d({"data-slot":"button",disabled:e||b,className:S(p({variant:x,size:n}),P[c][n],g)},m),{children:[v?o("span",{className:"shrink-0 -ml-1","data-slot":"button-prefix",children:i}):null,e?o(z,{className:"-ml-1 shrink-0",size:V(n)}):null,f,h?o("span",{className:"shrink-0 -mr-1","data-slot":"button-suffix",children:a}):null]}))}export{N as Button,p as buttonVariants};
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
|
+
import * as React from 'react';
|
|
3
|
+
import { DayPicker, DayButton, Locale } from 'react-day-picker';
|
|
4
|
+
import { Button } from './button.mjs';
|
|
5
|
+
import 'class-variance-authority/types';
|
|
6
|
+
import '@base-ui/react/button';
|
|
7
|
+
import 'class-variance-authority';
|
|
8
|
+
|
|
9
|
+
declare function Calendar({ className, classNames, showOutsideDays, captionLayout, buttonVariant, locale, formatters, components, ...props }: React.ComponentProps<typeof DayPicker> & {
|
|
10
|
+
buttonVariant?: React.ComponentProps<typeof Button>["variant"];
|
|
11
|
+
}): react_jsx_runtime.JSX.Element;
|
|
12
|
+
declare function CalendarDayButton({ className, day, modifiers, locale, ...props }: React.ComponentProps<typeof DayButton> & {
|
|
13
|
+
locale?: Partial<Locale>;
|
|
14
|
+
}): react_jsx_runtime.JSX.Element;
|
|
15
|
+
|
|
16
|
+
export { Calendar, CalendarDayButton };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use client";import{a,b as v,c as l}from"../../chunk-7LRQ2WLZ.mjs";import{jsx as d}from"react/jsx-runtime";import*as _ from"react";import{vi as z}from"date-fns/locale";import{DayPicker as N,getDefaultClassNames as k}from"react-day-picker";import{cn as e}from"../../lib/utils";import{Button as B,buttonVariants as C}from"./button";import{ChevronLeftIcon as R,ChevronRightIcon as L,ChevronDownIcon as P}from"lucide-react";function S(h){var i=h,{className:x,classNames:y,showOutsideDays:r=!0,captionLayout:s="label",buttonVariant:f="ghost",locale:g=z,formatters:m,components:w}=i,p=l(i,["className","classNames","showOutsideDays","captionLayout","buttonVariant","locale","formatters","components"]);const t=k();return d(N,a({showOutsideDays:r,className:e("group/calendar p-2.5 [--cell-radius:var(--radius-4xl)] [--cell-size:--spacing(8)] in-data-[slot=card-content]:bg-transparent in-data-[slot=popover-content]:bg-transparent",String.raw`rtl:**:[.rdp-button\_next>svg]:rotate-180`,String.raw`rtl:**:[.rdp-button\_previous>svg]:rotate-180`,x),captionLayout:s,locale:g,formatters:a({formatMonthDropdown:n=>n.toLocaleString(g.code,{month:"short"})},m),classNames:a({root:e("w-fit",t.root),months:e("relative flex flex-col gap-4 md:flex-row",t.months),month:e("flex w-full flex-col gap-4",t.month),nav:e("absolute inset-x-0 top-1 flex w-full items-center justify-end gap-0",t.nav),button_previous:e(C({variant:f,size:"icon-xs"}),t.button_previous,"p-0 select-none aria-disabled:opacity-50 text-primary hover:text-primary"),button_next:e(C({variant:f,size:"icon-xs"}),t.button_next," p-0 select-none aria-disabled:opacity-50 text-primary hover:text-primary"),month_caption:e("flex h-8 w-full items-center justify-start px-1.5",t.month_caption),dropdowns:e("flex h-8 w-full items-center justify-start gap-1.5 text-tiny font-medium",t.dropdowns),dropdown_root:e("relative rounded-(--cell-radius)",t.dropdown_root),dropdown:e("absolute inset-0 bg-popover opacity-0",t.dropdown),caption_label:e("font-medium select-none",s==="label"?"text-sm":"flex items-center gap-1 rounded-(--cell-radius) text-sm [&>svg]:size-3.5 [&>svg]:text-muted-foreground",t.caption_label),table:"w-full border-collapse",weekdays:e("flex",t.weekdays),weekday:e("flex-1 rounded-(--cell-radius) text-[0.75rem] font-normal text-muted-foreground select-none",t.weekday),week:e("mt-2 flex w-full",t.week),week_number_header:e("w-(--cell-size) select-none",t.week_number_header),week_number:e("text-[0.8rem] text-muted-foreground select-none",t.week_number),day:e("group/day relative aspect-square h-full w-full rounded-(--cell-radius) p-0 text-center select-none [&:last-child[data-selected=true]_button]:rounded-r-(--cell-radius) ",p.showWeekNumber?"[&:nth-child(2)[data-selected=true]_button]:rounded-l-(--cell-radius)":"[&:first-child[data-selected=true]_button]:rounded-l-(--cell-radius)",t.day),range_start:e("relative isolate z-0 rounded-l-(--cell-radius) bg-muted after:absolute after:inset-y-0 after:right-0 after:w-4 after:bg-muted",t.range_start),range_middle:e("rounded-none",t.range_middle),range_end:e("relative isolate z-0 rounded-r-(--cell-radius) bg-muted after:absolute after:inset-y-0 after:left-0 after:w-4 after:bg-muted",t.range_end),today:e("rounded-(--cell-radius) text-primary ",t.today),outside:e("text-subtle-foreground aria-selected:text-subtle-foreground ",t.outside),disabled:e("text-muted-foreground opacity-50",t.disabled),hidden:e("invisible",t.hidden)},y),components:a({Root:b=>{var c=b,{className:n,rootRef:o}=c,u=l(c,["className","rootRef"]);return d("div",a({"data-slot":"calendar",ref:o,className:e(n)},u))},Chevron:b=>{var c=b,{className:n,orientation:o}=c,u=l(c,["className","orientation"]);return o==="left"?d(R,a({className:e("size-4",n)},u)):o==="right"?d(L,a({className:e("size-4",n)},u)):d(P,a({className:e("size-4",n)},u))},DayButton:o=>{var n=l(o,[]);return d(D,a({locale:g},n))},WeekNumber:u=>{var b=u,{children:n}=b,o=l(b,["children"]);return d("td",v(a({},o),{children:d("div",{className:"flex size-(--cell-size) items-center justify-center text-center",children:n})}))}},w)},p))}function D(g){var m=g,{className:x,day:y,modifiers:r,locale:s}=m,f=l(m,["className","day","modifiers","locale"]);var h;const w=k(),p=_.useRef(null);return _.useEffect(()=>{var i;r.focused&&((i=p.current)==null||i.focus())},[r.focused]),d(B,a({variant:"ghost",size:"icon","data-day":y.date.toLocaleDateString((h=s==null?void 0:s.code)!=null?h:z.code),"data-selected-single":r.selected&&!r.range_start&&!r.range_end?!r.range_middle:null,"data-range-start":r.range_start,"data-range-end":r.range_end,"data-range-middle":r.range_middle,className:e("relative isolate z-10 flex aspect-square size-auto w-full min-w-(--cell-size) flex-col gap-1 border-0 leading-none group-data-[focused=true]/day:relative group-data-[focused=true]/day:z-10 group-data-[focused=true]/day:border-ring data-[range-end=true]:rounded-(--cell-radius) data-[range-end=true]:rounded-r-(--cell-radius) data-[range-end=true]:bg-primary data-[range-end=true]:text-white data-[range-middle=true]:rounded-none data-[range-middle=true]:bg-muted data-[range-middle=true]:text-foreground data-[range-start=true]:rounded-(--cell-radius) data-[range-start=true]:rounded-l-(--cell-radius) data-[range-start=true]:bg-primary data-[range-start=true]:text-white data-[selected-single=true]:bg-primary data-[selected-single=true]:text-white dark:hover:text-foreground ",w.day,x)},f))}export{S as Calendar,D as CalendarDayButton};
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
|
+
import * as React from 'react';
|
|
3
|
+
|
|
4
|
+
declare function Card({ className, size, ...props }: React.ComponentProps<"div"> & {
|
|
5
|
+
size?: "default" | "sm";
|
|
6
|
+
}): react_jsx_runtime.JSX.Element;
|
|
7
|
+
declare function CardHeader({ className, ...props }: React.ComponentProps<"div">): react_jsx_runtime.JSX.Element;
|
|
8
|
+
declare function CardTitle({ className, ...props }: React.ComponentProps<"div">): react_jsx_runtime.JSX.Element;
|
|
9
|
+
declare function CardDescription({ className, ...props }: React.ComponentProps<"div">): react_jsx_runtime.JSX.Element;
|
|
10
|
+
declare function CardAction({ className, ...props }: React.ComponentProps<"div">): react_jsx_runtime.JSX.Element;
|
|
11
|
+
declare function CardContent({ className, ...props }: React.ComponentProps<"div">): react_jsx_runtime.JSX.Element;
|
|
12
|
+
declare function CardFooter({ className, ...props }: React.ComponentProps<"div">): react_jsx_runtime.JSX.Element;
|
|
13
|
+
|
|
14
|
+
export { Card, CardAction, CardContent, CardDescription, CardFooter, CardHeader, CardTitle };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{a as d,c as o}from"../../chunk-7LRQ2WLZ.mjs";import{jsx as n}from"react/jsx-runtime";import{cn as s}from"../../lib/utils";function c(t){var i=t,{className:a,size:r="default"}=i,e=o(i,["className","size"]);return n("div",d({"data-slot":"card","data-size":r,className:s("group/card flex flex-col gap-6 overflow-hidden rounded-2xl bg-card py-6 text-sm text-card-foreground ring-1 ring-foreground/10 has-[>img:first-child]:pt-0 data-[size=sm]:gap-4 data-[size=sm]:py-4 *:[img:first-child]:rounded-t-xl *:[img:last-child]:rounded-b-xl",a)},e))}function p(e){var t=e,{className:a}=t,r=o(t,["className"]);return n("div",d({"data-slot":"card-header",className:s("group/card-header @container/card-header grid auto-rows-min items-start gap-2 rounded-t-xl px-6 group-data-[size=sm]/card:px-4 has-data-[slot=card-action]:grid-cols-[1fr_auto] has-data-[slot=card-description]:grid-rows-[auto_auto] [.border-b]:pb-6 group-data-[size=sm]/card:[.border-b]:pb-4",a)},r))}function l(e){var t=e,{className:a}=t,r=o(t,["className"]);return n("div",d({"data-slot":"card-title",className:s("font-heading text-base font-medium",a)},r))}function u(e){var t=e,{className:a}=t,r=o(t,["className"]);return n("div",d({"data-slot":"card-description",className:s("text-sm text-muted-foreground",a)},r))}function m(e){var t=e,{className:a}=t,r=o(t,["className"]);return n("div",d({"data-slot":"card-action",className:s("col-start-2 row-span-2 row-start-1 self-start justify-self-end",a)},r))}function f(e){var t=e,{className:a}=t,r=o(t,["className"]);return n("div",d({"data-slot":"card-content",className:s("px-6 group-data-[size=sm]/card:px-4",a)},r))}function g(e){var t=e,{className:a}=t,r=o(t,["className"]);return n("div",d({"data-slot":"card-footer",className:s("flex items-center rounded-b-xl px-6 group-data-[size=sm]/card:px-4 [.border-t]:pt-6 group-data-[size=sm]/card:[.border-t]:pt-4",a)},r))}export{c as Card,m as CardAction,f as CardContent,u as CardDescription,g as CardFooter,p as CardHeader,l as CardTitle};
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
|
+
import * as React from 'react';
|
|
3
|
+
import useEmblaCarousel, { UseEmblaCarouselType } from 'embla-carousel-react';
|
|
4
|
+
import { Button } from './button.mjs';
|
|
5
|
+
import 'class-variance-authority/types';
|
|
6
|
+
import '@base-ui/react/button';
|
|
7
|
+
import 'class-variance-authority';
|
|
8
|
+
|
|
9
|
+
type CarouselApi = UseEmblaCarouselType[1];
|
|
10
|
+
type UseCarouselParameters = Parameters<typeof useEmblaCarousel>;
|
|
11
|
+
type CarouselOptions = UseCarouselParameters[0];
|
|
12
|
+
type CarouselPlugin = UseCarouselParameters[1];
|
|
13
|
+
interface CarouselProps {
|
|
14
|
+
opts?: CarouselOptions;
|
|
15
|
+
plugins?: CarouselPlugin;
|
|
16
|
+
orientation?: "horizontal" | "vertical";
|
|
17
|
+
setApi?: (api: CarouselApi) => void;
|
|
18
|
+
}
|
|
19
|
+
type CarouselContextProps = {
|
|
20
|
+
carouselRef: ReturnType<typeof useEmblaCarousel>[0];
|
|
21
|
+
api: ReturnType<typeof useEmblaCarousel>[1];
|
|
22
|
+
scrollPrev: () => void;
|
|
23
|
+
scrollNext: () => void;
|
|
24
|
+
canScrollPrev: boolean;
|
|
25
|
+
canScrollNext: boolean;
|
|
26
|
+
} & CarouselProps;
|
|
27
|
+
declare function useCarousel(): CarouselContextProps;
|
|
28
|
+
declare function Carousel({ orientation, opts, setApi, plugins, className, children, ...props }: React.ComponentProps<"div"> & CarouselProps): react_jsx_runtime.JSX.Element;
|
|
29
|
+
declare function CarouselContent({ className, classNameContent, ...props }: React.ComponentProps<"div"> & {
|
|
30
|
+
classNameContent?: string;
|
|
31
|
+
}): react_jsx_runtime.JSX.Element;
|
|
32
|
+
declare function CarouselItem({ className, ...props }: React.ComponentProps<"div">): react_jsx_runtime.JSX.Element;
|
|
33
|
+
declare function CarouselPrevious({ className, variant, size, ...props }: React.ComponentProps<typeof Button>): react_jsx_runtime.JSX.Element;
|
|
34
|
+
declare function CarouselNext({ className, variant, size, ...props }: React.ComponentProps<typeof Button>): react_jsx_runtime.JSX.Element;
|
|
35
|
+
declare function CarouselDots({ className }: React.ComponentProps<"div">): react_jsx_runtime.JSX.Element | null;
|
|
36
|
+
|
|
37
|
+
export { Carousel, type CarouselApi, CarouselContent, CarouselDots, CarouselItem, CarouselNext, CarouselPrevious, useCarousel };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use client";import{a as C,b as P,c as m}from"../../chunk-7LRQ2WLZ.mjs";import{jsx as c,jsxs as S}from"react/jsx-runtime";import*as a from"react";import A from"embla-carousel-react";import{cn as p}from"../../lib/utils";import{Button as h}from"./button";import{ChevronLeftIcon as D,ChevronRightIcon as I}from"lucide-react";const N=a.createContext(null);function v(){const t=a.useContext(N);if(!t)throw new Error("useCarousel must be used within a <Carousel />");return t}function T(i){var d=i,{orientation:t="horizontal",opts:e,setApi:r,plugins:s,className:n,children:u}=d,l=m(d,["orientation","opts","setApi","plugins","className","children"]);const[g,o]=A(P(C({},e),{axis:t==="horizontal"?"x":"y"}),s),[R,E]=a.useState(!1),[k,w]=a.useState(!1),y=a.useCallback(f=>{f&&(E(f.canScrollPrev()),w(f.canScrollNext()))},[]),b=a.useCallback(()=>{o==null||o.scrollPrev()},[o]),x=a.useCallback(()=>{o==null||o.scrollNext()},[o]),z=a.useCallback(f=>{f.key==="ArrowLeft"?(f.preventDefault(),b()):f.key==="ArrowRight"&&(f.preventDefault(),x())},[b,x]);return a.useEffect(()=>{!o||!r||r(o)},[o,r]),a.useEffect(()=>{if(o)return y(o),o.on("reInit",y),o.on("select",y),()=>{o.off("select",y)}},[o,y]),c(N.Provider,{value:{carouselRef:g,api:o,opts:e,orientation:t||((e==null?void 0:e.axis)==="y"?"vertical":"horizontal"),scrollPrev:b,scrollNext:x,canScrollPrev:R,canScrollNext:k},children:c("div",P(C({onKeyDownCapture:z,className:p("relative",n),role:"region","aria-roledescription":"carousel","data-slot":"carousel"},l),{children:u}))})}function B(s){var n=s,{className:t,classNameContent:e=""}=n,r=m(n,["className","classNameContent"]);const{carouselRef:u,orientation:l}=v();return c("div",{ref:u,className:p("overflow-hidden",e),"data-slot":"carousel-content",children:c("div",C({className:p("flex",l==="horizontal"?"-ml-4":"-mt-4 flex-col",t)},r))})}function U(r){var s=r,{className:t}=s,e=m(s,["className"]);const{orientation:n}=v();return c("div",C({role:"group","aria-roledescription":"slide","data-slot":"carousel-item",className:p("min-w-0 shrink-0 grow-0 basis-full",n==="horizontal"?"pl-4":"pt-4",t)},e))}function L(n){var u=n,{className:t,variant:e="outline",size:r="icon-sm"}=u,s=m(u,["className","variant","size"]);const{orientation:l,scrollPrev:i,canScrollPrev:d}=v();return S(h,P(C({"data-slot":"carousel-previous",variant:e,size:r,className:p("absolute touch-manipulation rounded-full",l==="horizontal"?"top-1/2 -left-12 -translate-y-1/2":"-top-12 left-1/2 -translate-x-1/2 rotate-90",t),disabled:!d,onClick:i},s),{children:[c(D,{}),c("span",{className:"sr-only",children:"Previous slide"})]}))}function K(n){var u=n,{className:t,variant:e="outline",size:r="icon-sm"}=u,s=m(u,["className","variant","size"]);const{orientation:l,scrollNext:i,canScrollNext:d}=v();return S(h,P(C({"data-slot":"carousel-next",variant:e,size:r,className:p("absolute touch-manipulation rounded-full",l==="horizontal"?"top-1/2 -right-12 -translate-y-1/2":"-bottom-12 left-1/2 -translate-x-1/2 rotate-90",t),disabled:!d,onClick:i},s),{children:[c(I,{}),c("span",{className:"sr-only",children:"Next slide"})]}))}function O({className:t}){const{api:e}=v(),[r,s]=a.useState(0),[n,u]=a.useState(0);return a.useEffect(()=>{if(!e)return;u(e.scrollSnapList().length),s(e.selectedScrollSnap());const l=()=>{s(e.selectedScrollSnap())};return e.on("reInit",l),e.on("select",l),()=>{e.off("select",l),e.off("reInit",l)}},[e]),n<=1?null:c("div",{"data-slot":"carousel-dots",className:p("flex flex-wrap justify-center gap-2",t),role:"tablist","aria-label":"Carousel slides",children:Array.from({length:n},(l,i)=>c("button",{type:"button",role:"tab","aria-selected":i===r,"aria-label":`Go to slide ${i+1}`,className:p("size-2.5 rounded-full transition-colors",i===r?"bg-primary":"bg-muted-foreground/30 hover:bg-muted-foreground/50"),onClick:()=>e==null?void 0:e.scrollTo(i)},i))})}export{T as Carousel,B as CarouselContent,O as CarouselDots,U as CarouselItem,K as CarouselNext,L as CarouselPrevious,v as useCarousel};
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
|
+
import { Checkbox as Checkbox$1 } from '@base-ui/react/checkbox';
|
|
3
|
+
|
|
4
|
+
type CheckboxProps = Checkbox$1.Root.Props;
|
|
5
|
+
declare function Checkbox({ className, ...props }: CheckboxProps): react_jsx_runtime.JSX.Element;
|
|
6
|
+
|
|
7
|
+
export { Checkbox, type CheckboxProps };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use client";import{a as i,b as o,c as t}from"../../chunk-7LRQ2WLZ.mjs";import{jsx as e}from"react/jsx-runtime";import{Checkbox as a}from"@base-ui/react/checkbox";import{CheckIcon as n}from"lucide-react";import{cn as s}from"../../lib/utils";function b(l){var r=l,{className:c}=r,d=t(r,["className"]);return e(a.Root,o(i({"data-slot":"checkbox",className:s("peer relative flex size-4 shrink-0 items-center justify-center rounded-md border border-input transition-colors outline-none","group-has-disabled/field:opacity-50 after:absolute after:-inset-x-3 after:-inset-y-2","focus-visible:border-ring focus-visible:ring-[1px] focus-visible:ring-ring","disabled:cursor-not-allowed disabled:opacity-50","aria-invalid:border-destructive aria-invalid:ring-[1px] aria-invalid:ring-destructive/20 aria-invalid:aria-checked:border-primary","dark:bg-input/30 dark:aria-invalid:border-destructive/50 dark:aria-invalid:ring-destructive/40","data-checked:border-primary data-checked:bg-primary data-checked:text-primary-foreground dark:data-checked:bg-primary",c)},d),{children:e(a.Indicator,{"data-slot":"checkbox-indicator",className:"grid place-content-center text-current transition-none [&>svg]:size-3.5",children:e(n,{strokeWidth:3})})}))}export{b as Checkbox};
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
|
+
import { ComponentProps, ReactNode } from 'react';
|
|
3
|
+
import { Button } from './button.mjs';
|
|
4
|
+
import 'class-variance-authority/types';
|
|
5
|
+
import '@base-ui/react/button';
|
|
6
|
+
import 'class-variance-authority';
|
|
7
|
+
|
|
8
|
+
type CloseButtonSize = "xs" | "sm" | "default" | "lg";
|
|
9
|
+
type CloseButtonProps = Omit<ComponentProps<typeof Button>, "variant" | "size"> & {
|
|
10
|
+
/** Hit target / icon scale; maps to icon button sizes in the design system. */
|
|
11
|
+
size?: CloseButtonSize;
|
|
12
|
+
/** Replaces the default X icon. */
|
|
13
|
+
children?: ReactNode;
|
|
14
|
+
};
|
|
15
|
+
declare function CloseButton({ className, size, children, "aria-label": ariaLabel, type, ...props }: CloseButtonProps): react_jsx_runtime.JSX.Element;
|
|
16
|
+
|
|
17
|
+
export { CloseButton, type CloseButtonProps, type CloseButtonSize };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use client";import{a as e,b as s,c as n}from"../../chunk-7LRQ2WLZ.mjs";import{jsx as i}from"react/jsx-runtime";import{XIcon as m}from"lucide-react";import{Button as B}from"./button";const c={xs:"icon-xs",sm:"icon-sm",default:"icon",lg:"icon-lg"};function C(z){var t=z,{className:a,size:p="xs",children:o,"aria-label":l="Close",type:u="button"}=t,r=n(t,["className","size","children","aria-label","type"]);return i(B,s(e({type:u,variant:"secondary",size:c[p],"data-slot":"close-button","aria-label":l,className:a},r),{children:o!=null?o:i(m,{})}))}export{C as CloseButton};
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
|
+
import * as React from 'react';
|
|
3
|
+
import { Combobox as Combobox$1 } from '@base-ui/react';
|
|
4
|
+
import { InputSize } from './input.mjs';
|
|
5
|
+
|
|
6
|
+
declare const Combobox: typeof Combobox$1.Root;
|
|
7
|
+
declare function ComboboxValue({ ...props }: Combobox$1.Value.Props): react_jsx_runtime.JSX.Element;
|
|
8
|
+
declare function ComboboxTrigger({ className, children, ...props }: Combobox$1.Trigger.Props): react_jsx_runtime.JSX.Element;
|
|
9
|
+
declare function ComboboxInput({ size, className, children, disabled, showTrigger, showClear, ...props }: Omit<Combobox$1.Input.Props, "size"> & {
|
|
10
|
+
showTrigger?: boolean;
|
|
11
|
+
showClear?: boolean;
|
|
12
|
+
size?: InputSize;
|
|
13
|
+
}): react_jsx_runtime.JSX.Element;
|
|
14
|
+
declare function ComboboxContent({ className, side, sideOffset, align, alignOffset, anchor, ...props }: Combobox$1.Popup.Props & Pick<Combobox$1.Positioner.Props, "side" | "align" | "sideOffset" | "alignOffset" | "anchor">): react_jsx_runtime.JSX.Element;
|
|
15
|
+
declare function ComboboxList({ className, ...props }: Combobox$1.List.Props): react_jsx_runtime.JSX.Element;
|
|
16
|
+
declare function ComboboxItem({ className, children, ...props }: Combobox$1.Item.Props): react_jsx_runtime.JSX.Element;
|
|
17
|
+
declare function ComboboxGroup({ className, ...props }: Combobox$1.Group.Props): react_jsx_runtime.JSX.Element;
|
|
18
|
+
declare function ComboboxLabel({ className, ...props }: Combobox$1.GroupLabel.Props): react_jsx_runtime.JSX.Element;
|
|
19
|
+
declare function ComboboxCollection({ ...props }: Combobox$1.Collection.Props): react_jsx_runtime.JSX.Element;
|
|
20
|
+
declare function ComboboxEmpty({ className, ...props }: Combobox$1.Empty.Props): react_jsx_runtime.JSX.Element;
|
|
21
|
+
declare function ComboboxSeparator({ className, ...props }: Combobox$1.Separator.Props): react_jsx_runtime.JSX.Element;
|
|
22
|
+
declare function ComboboxChips({ className, ...props }: React.ComponentPropsWithRef<typeof Combobox$1.Chips> & Combobox$1.Chips.Props): react_jsx_runtime.JSX.Element;
|
|
23
|
+
declare function ComboboxChip({ className, children, showRemove, ...props }: Combobox$1.Chip.Props & {
|
|
24
|
+
showRemove?: boolean;
|
|
25
|
+
}): react_jsx_runtime.JSX.Element;
|
|
26
|
+
declare function ComboboxChipsInput({ className, ...props }: Combobox$1.Input.Props): react_jsx_runtime.JSX.Element;
|
|
27
|
+
declare function useComboboxAnchor(): React.RefObject<HTMLDivElement | null>;
|
|
28
|
+
|
|
29
|
+
export { Combobox, ComboboxChip, ComboboxChips, ComboboxChipsInput, ComboboxCollection, ComboboxContent, ComboboxEmpty, ComboboxGroup, ComboboxInput, ComboboxItem, ComboboxLabel, ComboboxList, ComboboxSeparator, ComboboxTrigger, ComboboxValue, useComboboxAnchor };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use client";import{a as n,b as d,c as s}from"../../chunk-7LRQ2WLZ.mjs";import{jsx as i,jsxs as c}from"react/jsx-runtime";import*as v from"react";import{Combobox as a}from"@base-ui/react";import{cn as l}from"../../lib/utils";import{Button as C}from"./button";import{InputGroup as P,InputGroupAddon as w,InputGroupButton as x,InputGroupInput as I}from"./input-group";import{ChevronDownIcon as y,XIcon as g,CheckIcon as N}from"lucide-react";const z=a.Root;function G(e){var t=s(e,[]);return i(a.Value,n({"data-slot":"combobox-value"},t))}function h(o){var m=o,{className:t,children:e}=m,r=s(m,["className","children"]);return c(a.Trigger,d(n({"data-slot":"combobox-trigger",className:l("[&_svg:not([class*='size-'])]:size-4",t)},r),{children:[e,i(y,{className:"pointer-events-none size-4 text-muted-foreground"})]}))}function R(r){var o=r,{className:t}=o,e=s(o,["className"]);return i(a.Clear,d(n({"data-slot":"combobox-clear",render:i(x,{variant:"secondary",size:"icon-xs"}),className:l(t)},e),{children:i(g,{className:"pointer-events-none"})}))}function L(f){var p=f,{size:t="default",className:e,children:r,disabled:o=!1,showTrigger:m=!0,showClear:b=!1}=p,u=s(p,["size","className","children","disabled","showTrigger","showClear"]);return c(P,{className:l("w-auto",e),size:t,children:[i(a.Input,n({render:i(I,{disabled:o,size:t})},u)),c(w,{align:"inline-end",children:[m?i(x,{size:"icon-xs",variant:"ghost",render:i(h,{}),"data-slot":"input-group-button",className:"group-has-data-[slot=combobox-clear]/input-group:hidden data-pressed:bg-transparent",disabled:o}):null,b?i(R,{disabled:o}):null]}),r]})}function k(f){var p=f,{className:t,side:e="bottom",sideOffset:r=6,align:o="start",alignOffset:m=0,anchor:b}=p,u=s(p,["className","side","sideOffset","align","alignOffset","anchor"]);return i(a.Portal,{children:i(a.Positioner,{side:e,sideOffset:r,align:o,alignOffset:m,anchor:b,className:"isolate z-50",children:i(a.Popup,n({"data-slot":"combobox-content","data-chips":!!b,className:l("group/combobox-content relative max-h-(--available-height) w-(--anchor-width) max-w-(--available-width) min-w-[calc(var(--anchor-width)+--spacing(7))] origin-(--transform-origin) overflow-hidden rounded-2xl bg-popover text-popover-foreground shadow-large ring-1 ring-foreground/5 duration-100 data-[chips=true]:min-w-(--anchor-width) data-[side=bottom]:slide-in-from-top-2 data-[side=inline-end]:slide-in-from-left-2 data-[side=inline-start]:slide-in-from-right-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 *:data-[slot=input-group]:m-1 *:data-[slot=input-group]:mb-0 *:data-[slot=input-group]:h-9 *:data-[slot=input-group]:border-none *:data-[slot=input-group]:bg-input/30 *:data-[slot=input-group]:shadow-none 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",t)},u))})})}function T(r){var o=r,{className:t}=o,e=s(o,["className"]);return i(a.List,n({"data-slot":"combobox-list",className:l("no-scrollbar max-h-[min(calc(--spacing(72)---spacing(9)),calc(var(--available-height)---spacing(9)))] scroll-py-1 overflow-y-auto overscroll-contain p-1 data-empty:p-0",t)},e))}function O(o){var m=o,{className:t,children:e}=m,r=s(m,["className","children"]);return c(a.Item,d(n({"data-slot":"combobox-item",className:l("relative flex w-full cursor-default items-center gap-2.5 rounded-xl py-2 pr-8 pl-3 text-sm outline-hidden select-none data-highlighted:bg-accent data-highlighted:text-accent-foreground not-data-[variant=destructive]:data-highlighted:**:text-accent-foreground data-disabled:pointer-events-none data-disabled:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",t)},r),{children:[e,i(a.ItemIndicator,{render:i("span",{className:"pointer-events-none absolute right-2 flex size-4 items-center justify-center"}),children:i(N,{className:"pointer-events-none"})})]}))}function S(r){var o=r,{className:t}=o,e=s(o,["className"]);return i(a.Group,n({"data-slot":"combobox-group",className:l(t)},e))}function E(r){var o=r,{className:t}=o,e=s(o,["className"]);return i(a.GroupLabel,n({"data-slot":"combobox-label",className:l("px-3.5 py-2.5 text-xs text-muted-foreground",t)},e))}function _(e){var t=s(e,[]);return i(a.Collection,n({"data-slot":"combobox-collection"},t))}function A(r){var o=r,{className:t}=o,e=s(o,["className"]);return i(a.Empty,n({"data-slot":"combobox-empty",className:l("hidden w-full justify-center py-2 text-center text-sm text-muted-foreground group-data-empty/combobox-content:flex",t)},e))}function B(r){var o=r,{className:t}=o,e=s(o,["className"]);return i(a.Separator,n({"data-slot":"combobox-separator",className:l("-mx-1 my-1 h-px bg-border/50",t)},e))}function V(r){var o=r,{className:t}=o,e=s(o,["className"]);return i(a.Chips,n({"data-slot":"combobox-chips",className:l("group/input-group relative flex min-h-9 w-full min-w-0 flex-wrap items-center gap-1.5 rounded-lg border border-input bg-background-1 px-3 py-1 text-sm transition-colors outline-none","in-data-[slot=combobox-content]:focus-within:border-inherit in-data-[slot=combobox-content]:focus-within:ring-0","has-data-[align=block-end]:rounded-lg has-data-[align=block-start]:rounded-lg","has-[[data-slot=combobox-chip-input]:focus-visible]:border-ring has-[[data-slot=combobox-chip-input]:focus-visible]:ring-[1px] has-[[data-slot=combobox-chip-input]:focus-visible]:ring-ring","has-[[data-slot][aria-invalid=true]]:border-destructive has-[[data-slot][aria-invalid=true]]:ring-[1px] has-[[data-slot][aria-invalid=true]]:ring-destructive/20 ","hover:border-gray-6 has-data-[slot=combobox-chip]:px-1.5",t)},e))}function j(m){var b=m,{className:t,children:e,showRemove:r=!0}=b,o=s(b,["className","children","showRemove"]);return c(a.Chip,d(n({"data-slot":"combobox-chip",className:l("flex h-[calc(--spacing(5.5))] w-fit items-center justify-center gap-1 rounded-4xl bg-muted-foreground/10 px-2 text-xs font-medium whitespace-nowrap text-foreground has-disabled:pointer-events-none has-disabled:cursor-not-allowed has-disabled:opacity-50 has-data-[slot=combobox-chip-remove]:pr-0",t)},o),{children:[e,r?i(a.ChipRemove,{render:i(C,{variant:"ghost",size:"icon-xs"}),className:"-ml-1 opacity-50 hover:opacity-100","data-slot":"combobox-chip-remove",children:i(g,{className:"pointer-events-none"})}):null]}))}function D(r){var o=r,{className:t}=o,e=s(o,["className"]);return i(a.Input,n({"data-slot":"combobox-chip-input",className:l("min-w-16 flex-1 outline-none",t)},e))}function H(){return v.useRef(null)}export{z as Combobox,j as ComboboxChip,V as ComboboxChips,D as ComboboxChipsInput,_ as ComboboxCollection,k as ComboboxContent,A as ComboboxEmpty,S as ComboboxGroup,L as ComboboxInput,O as ComboboxItem,E as ComboboxLabel,T as ComboboxList,B as ComboboxSeparator,h as ComboboxTrigger,G as ComboboxValue,H as useComboboxAnchor};
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
import { Dialog } from '@base-ui/react/dialog';
|
|
2
|
+
export { Dialog as CommandDialogPrimitive } from '@base-ui/react/dialog';
|
|
3
|
+
import * as React from 'react';
|
|
4
|
+
import { Autocomplete, AutocompleteInput, AutocompleteList, AutocompleteEmpty, AutocompleteGroup, AutocompleteGroupLabel, AutocompleteCollection, AutocompleteItem, AutocompleteSeparator } from './autocomplete.mjs';
|
|
5
|
+
import 'react/jsx-runtime';
|
|
6
|
+
import '@base-ui/react/autocomplete';
|
|
7
|
+
import './input.mjs';
|
|
8
|
+
|
|
9
|
+
declare const CommandDialog: typeof Dialog.Root;
|
|
10
|
+
declare const CommandDialogPortal: typeof Dialog.Portal;
|
|
11
|
+
declare const CommandCreateHandle: typeof Dialog.createHandle;
|
|
12
|
+
declare function CommandDialogTrigger(props: Dialog.Trigger.Props): React.ReactElement;
|
|
13
|
+
declare function CommandDialogBackdrop({ className, ...props }: Dialog.Backdrop.Props): React.ReactElement;
|
|
14
|
+
declare function CommandDialogViewport({ className, ...props }: Dialog.Viewport.Props): React.ReactElement;
|
|
15
|
+
declare function CommandDialogPopup({ className, children, portalProps, ...props }: Dialog.Popup.Props & {
|
|
16
|
+
portalProps?: Dialog.Portal.Props;
|
|
17
|
+
}): React.ReactElement;
|
|
18
|
+
declare function Command({ autoHighlight, keepHighlight, ...props }: React.ComponentProps<typeof Autocomplete>): React.ReactElement;
|
|
19
|
+
declare function CommandInput({ className, placeholder, ...props }: React.ComponentProps<typeof AutocompleteInput>): React.ReactElement;
|
|
20
|
+
declare function CommandList({ className, ...props }: React.ComponentProps<typeof AutocompleteList>): React.ReactElement;
|
|
21
|
+
declare function CommandEmpty({ className, ...props }: React.ComponentProps<typeof AutocompleteEmpty>): React.ReactElement;
|
|
22
|
+
declare function CommandPanel({ className, ...props }: React.ComponentProps<"div">): React.ReactElement;
|
|
23
|
+
declare function CommandGroup({ className, ...props }: React.ComponentProps<typeof AutocompleteGroup>): React.ReactElement;
|
|
24
|
+
declare function CommandGroupLabel({ className, ...props }: React.ComponentProps<typeof AutocompleteGroupLabel>): React.ReactElement;
|
|
25
|
+
declare function CommandCollection({ ...props }: React.ComponentProps<typeof AutocompleteCollection>): React.ReactElement;
|
|
26
|
+
declare function CommandItem({ className, ...props }: React.ComponentProps<typeof AutocompleteItem>): React.ReactElement;
|
|
27
|
+
declare function CommandSeparator({ className, ...props }: React.ComponentProps<typeof AutocompleteSeparator>): React.ReactElement;
|
|
28
|
+
declare function CommandShortcut({ className, ...props }: React.ComponentProps<"kbd">): React.ReactElement;
|
|
29
|
+
declare function CommandFooter({ className, ...props }: React.ComponentProps<"div">): React.ReactElement;
|
|
30
|
+
|
|
31
|
+
export { Command, CommandCollection, CommandCreateHandle, CommandDialog, CommandDialogBackdrop, CommandDialogPopup, CommandDialogPortal, CommandDialogTrigger, CommandDialogViewport, CommandEmpty, CommandFooter, CommandGroup, CommandGroupLabel, CommandInput, CommandItem, CommandList, CommandPanel, CommandSeparator, CommandShortcut };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use client";import{a as n,b as i,c as m}from"../../chunk-7LRQ2WLZ.mjs";import{jsx as a,jsxs as A}from"react/jsx-runtime";import{Dialog as p}from"@base-ui/react/dialog";import{SearchIcon as s}from"lucide-react";import{cn as l}from"../../lib/utils";import{Autocomplete as u,AutocompleteCollection as g,AutocompleteEmpty as f,AutocompleteGroup as x,AutocompleteGroupLabel as y,AutocompleteInput as C,AutocompleteItem as R,AutocompleteList as b,AutocompleteSeparator as v}from"./autocomplete";const I=p.Root,P=p.Portal,G=p.createHandle;function L(e){return a(p.Trigger,n({"data-slot":"command-dialog-trigger"},e))}function h(r){var t=r,{className:e}=t,o=m(t,["className"]);return a(p.Backdrop,n({className:l("fixed inset-0 z-50 bg-black/32 backdrop-blur-sm transition-all duration-200 data-ending-style:opacity-0 data-starting-style:opacity-0",e),"data-slot":"command-dialog-backdrop"},o))}function w(r){var t=r,{className:e}=t,o=m(t,["className"]);return a(p.Viewport,n({className:l("fixed inset-0 z-50 flex flex-col items-center px-4 py-[max(--spacing(4),4vh)] sm:py-[10vh]",e),"data-slot":"command-dialog-viewport"},o))}function H(c){var d=c,{className:e,children:o,portalProps:r}=d,t=m(d,["className","children","portalProps"]);return A(P,i(n({},r),{children:[a(h,{}),a(w,{children:a(p.Popup,i(n({className:l("relative row-start-2 flex max-h-105 min-h-0 w-full min-w-0 max-w-xl -translate-y-[calc(1.25rem*var(--nested-dialogs))] scale-[calc(1-0.1*var(--nested-dialogs))] flex-col rounded-2xl border bg-popover bg-clip-padding text-popover-foreground opacity-[calc(1-0.1*var(--nested-dialogs))] shadow-lg/5 outline-none transition-[scale,opacity,translate] duration-200 ease-in-out will-change-transform before:pointer-events-none before:absolute before:inset-0 before:rounded-[calc(var(--radius-2xl)-1px)] before:bg-background-2 before:shadow-[0_1px_--theme(--color-black/4%)] data-nested:data-ending-style:translate-y-8 data-nested:data-starting-style:translate-y-8 data-nested-dialog-open:origin-top data-ending-style:scale-98 data-starting-style:scale-98 data-ending-style:opacity-0 data-starting-style:opacity-0 **:data-[slot=scroll-area-viewport]:data-has-overflow-y:pe-1",e),"data-slot":"command-dialog-popup"},t),{children:o}))})]}))}function S(t){var c=t,{autoHighlight:e="always",keepHighlight:o=!0}=c,r=m(c,["autoHighlight","keepHighlight"]);return a(u,n({autoHighlight:e,inline:!0,keepHighlight:o,open:!0},r))}function z(t){var c=t,{className:e,placeholder:o=void 0}=c,r=m(c,["className","placeholder"]);return a("div",{className:"px-2.5 py-1.5",children:a(C,n({autoFocus:!0,className:l("border-transparent! bg-transparent! before:hidden has-focus-visible:ring-0 !shadow-none",e),placeholder:o,size:"lg",startAddon:a(s,{})},r))})}function V(r){var t=r,{className:e}=t,o=m(t,["className"]);return a(b,n({className:l("not-empty:scroll-py-2 not-empty:p-2",e),"data-slot":"command-list"},o))}function B(r){var t=r,{className:e}=t,o=m(t,["className"]);return a(f,n({className:l("not-empty:py-6",e),"data-slot":"command-empty"},o))}function T(r){var t=r,{className:e}=t,o=m(t,["className"]);return a("div",n({className:l("relative -mx-px not-has-[+[data-slot=command-footer]]:-mb-px min-h-0 rounded-t-xl not-has-[+[data-slot=command-footer]]:rounded-b-2xl border border-b-0 bg-popover bg-clip-padding shadow-xs/5 [clip-path:inset(0_1px)] not-has-[+[data-slot=command-footer]]:[clip-path:inset(0_1px_1px_1px_round_0_0_calc(var(--radius-2xl)-1px)_calc(var(--radius-2xl)-1px))] before:pointer-events-none before:absolute before:inset-0 before:rounded-t-[calc(var(--radius-xl)-1px)] **:data-[slot=scroll-area-scrollbar]:mt-2",e)},o))}function F(r){var t=r,{className:e}=t,o=m(t,["className"]);return a(x,n({className:e,"data-slot":"command-group"},o))}function j(r){var t=r,{className:e}=t,o=m(t,["className"]);return a(y,n({className:e,"data-slot":"command-group-label"},o))}function q(o){var e=m(o,[]);return a(g,n({"data-slot":"command-collection"},e))}function J(r){var t=r,{className:e}=t,o=m(t,["className"]);return a(R,n({className:l("py-1.5",e),"data-slot":"command-item"},o))}function K(r){var t=r,{className:e}=t,o=m(t,["className"]);return a(v,n({className:l("my-2",e),"data-slot":"command-separator"},o))}function M(r){var t=r,{className:e}=t,o=m(t,["className"]);return a("kbd",n({className:l("ms-auto font-medium font-sans text-muted-foreground/72 text-xs tracking-widest",e),"data-slot":"command-shortcut"},o))}function O(r){var t=r,{className:e}=t,o=m(t,["className"]);return a("div",n({className:l("flex items-center justify-between gap-2 rounded-b-[calc(var(--radius-2xl)-1px)] border-t px-5 py-3 text-muted-foreground text-xs z-1 relative",e),"data-slot":"command-footer"},o))}export{S as Command,q as CommandCollection,G as CommandCreateHandle,I as CommandDialog,h as CommandDialogBackdrop,H as CommandDialogPopup,P as CommandDialogPortal,p as CommandDialogPrimitive,L as CommandDialogTrigger,w as CommandDialogViewport,B as CommandEmpty,O as CommandFooter,F as CommandGroup,j as CommandGroupLabel,z as CommandInput,J as CommandItem,V as CommandList,T as CommandPanel,K as CommandSeparator,M as CommandShortcut};
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
|
+
import * as React from 'react';
|
|
3
|
+
import { Locale, DateRange } from 'react-day-picker';
|
|
4
|
+
import { Calendar } from './calendar.mjs';
|
|
5
|
+
import './button.mjs';
|
|
6
|
+
import 'class-variance-authority/types';
|
|
7
|
+
import '@base-ui/react/button';
|
|
8
|
+
import 'class-variance-authority';
|
|
9
|
+
|
|
10
|
+
/** Trigger scale; maps to Mobase `Button` `size` (`sm` / `default` / `lg`). */
|
|
11
|
+
type DatePickerSize = "sm" | "default" | "lg";
|
|
12
|
+
type CalendarProps = React.ComponentProps<typeof Calendar>;
|
|
13
|
+
type OmitSelectionProps = Omit<CalendarProps, "mode" | "selected" | "onSelect" | "required">;
|
|
14
|
+
interface DatePickerPreset {
|
|
15
|
+
label: string;
|
|
16
|
+
date: Date;
|
|
17
|
+
}
|
|
18
|
+
type DatePickerProps = OmitSelectionProps & {
|
|
19
|
+
className?: string;
|
|
20
|
+
placeholder?: string;
|
|
21
|
+
value?: Date;
|
|
22
|
+
defaultValue?: Date;
|
|
23
|
+
onValueChange?: (date: Date | undefined) => void;
|
|
24
|
+
presets?: DatePickerPreset[];
|
|
25
|
+
locale?: Locale;
|
|
26
|
+
/** Trigger height; `Button` `size`: `sm`, `default`, or `lg`. */
|
|
27
|
+
size?: DatePickerSize;
|
|
28
|
+
/** `date-fns` format string for the trigger label. Default: MMMM dd, yyyy */
|
|
29
|
+
dateFormat?: string;
|
|
30
|
+
};
|
|
31
|
+
declare function DatePicker({ className, placeholder, value, defaultValue, onValueChange, presets, locale, disabled, size, dateFormat, captionLayout, ...calendarProps }: DatePickerProps): react_jsx_runtime.JSX.Element;
|
|
32
|
+
type DateRangePickerProps = OmitSelectionProps & {
|
|
33
|
+
className?: string;
|
|
34
|
+
placeholder?: string;
|
|
35
|
+
value?: DateRange;
|
|
36
|
+
defaultValue?: DateRange;
|
|
37
|
+
onValueChange?: (range: DateRange | undefined) => void;
|
|
38
|
+
locale?: Locale;
|
|
39
|
+
/** Trigger height; `Button` `size`: `sm`, `default`, or `lg`. */
|
|
40
|
+
size?: DatePickerSize;
|
|
41
|
+
/** `date-fns` format string for each boundary in the trigger. Default: MMMM dd, yyyy */
|
|
42
|
+
dateFormat?: string;
|
|
43
|
+
};
|
|
44
|
+
declare function DateRangePicker({ className, placeholder, value, defaultValue, onValueChange, locale, disabled, size, dateFormat, captionLayout, ...calendarProps }: DateRangePickerProps): react_jsx_runtime.JSX.Element;
|
|
45
|
+
|
|
46
|
+
export { DatePicker, type DatePickerPreset, type DatePickerProps, type DatePickerSize, DateRangePicker, type DateRangePickerProps };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use client";import{a as C,b as w,c as N}from"../../chunk-7LRQ2WLZ.mjs";import{jsx as o,jsxs as z}from"react/jsx-runtime";import*as l from"react";import{format as P,isBefore as _,isSameDay as F}from"date-fns";import{vi as I}from"date-fns/locale";import{CalendarDaysIcon as G,CalendarRangeIcon as H}from"lucide-react";import{cn as b}from"../../lib/utils";import{Button as O}from"./button";import{Calendar as M}from"./calendar";import{Popover as q,PopoverContent as T,PopoverTrigger as E}from"./popover";function J(e,a,t){const n=t!==void 0,[m,i]=l.useState(a),s=n?e:m,c=l.useCallback(r=>{n||i(r),t==null||t(r)},[n,t]);return[s,c]}function K(e,a,t){const n=t!==void 0,[m,i]=l.useState(a),s=n?e:m,c=l.useCallback(r=>{n||i(r),t==null||t(r)},[n,t]);return[s,c]}function Q(e,a){const t=a==null?void 0:a.from,n=a==null?void 0:a.to;return t?n?{from:e,to:void 0}:F(t,e)?{from:t,to:e}:_(e,t)?{from:e,to:t}:{from:t,to:e}:{from:e,to:void 0}}function U(e){return!!(e!=null&&e.from)&&!!(e!=null&&e.to)}function W(R){var D=R,{className:e,placeholder:a="Pick a date",value:t,defaultValue:n,onValueChange:m,presets:i,locale:s=I,disabled:c,size:r,dateFormat:y="dd/MM/yyyy",captionLayout:v="dropdown"}=D,L=N(D,["className","placeholder","value","defaultValue","onValueChange","presets","locale","disabled","size","dateFormat","captionLayout"]);const f=c===!0,[g,d]=l.useState(!1),[u,k]=J(t,n,m);return o("div",{"data-slot":"date-picker",className:b("inline-flex",e),children:z(q,{open:g,onOpenChange:d,children:[o(E,{disabled:f,"data-slot":"date-picker-trigger",render:o(O,{type:"button",variant:"outline",size:r,"data-slot":"date-picker-trigger-button",prefix:o(G,{}),shape:"square","data-empty":!u,disabled:f,className:b("w-full min-w-48 justify-start text-left border","data-[empty=true]:text-muted-foreground")}),children:u?P(u,y,{locale:s}):o("span",{children:a})}),z(T,{"data-slot":"date-picker-content",className:"p-0 bg-background-1 w-auto gap-0",align:"start",side:"bottom",collisionAvoidance:{side:"shift",align:"shift",fallbackAxisSide:"none"},children:[o(M,w(C({},L),{"data-slot":"date-picker-calendar",mode:"single",locale:s,selected:u,captionLayout:v,disabled:c,onSelect:p=>{k(p),d(!1)}})),i!=null&&i.length?o("div",{"data-slot":"date-picker-presets",className:"flex flex-wrap gap-1 border-t border-border p-2.5",children:i.map(p=>o(O,{type:"button",size:"sm",variant:"outline",disabled:f,onClick:()=>{k(p.date),d(!1)},children:p.label},p.label))}):null]})]})})}function X(e,a,t){return e!=null&&e.from?e.to?`${P(e.from,a,{locale:t})} \u2013 ${P(e.to,a,{locale:t})}`:P(e.from,a,{locale:t}):null}function Y(L){var R=L,{className:e,placeholder:a="Pick a date range",value:t,defaultValue:n,onValueChange:m,locale:i=I,disabled:s,size:c,dateFormat:r="dd/MM/yyyy",captionLayout:y="dropdown"}=R,v=N(R,["className","placeholder","value","defaultValue","onValueChange","locale","disabled","size","dateFormat","captionLayout"]);const D=s===!0,[f,g]=l.useState(!1),[d,u]=K(t,n,m),[k,p]=l.useState(void 0),A=l.useRef(!1);l.useEffect(()=>{f&&!A.current&&p(d),A.current=f},[f,d]);const B=X(d,r,i),$=!(d!=null&&d.from);return o("div",{"data-slot":"date-range-picker",className:b("inline-flex",e),children:z(q,{open:f,onOpenChange:g,children:[o(E,{disabled:D,"data-slot":"date-picker-trigger",render:o(O,{type:"button",variant:"outline",size:c,shape:"square","data-slot":"date-picker-trigger-button",prefix:o(H,{}),"data-empty":$,disabled:D,className:b("w-full min-w-[12rem] justify-start text-left border","data-[empty=true]:text-muted-foreground")}),children:B?o("span",{children:B}):o("span",{children:a})}),o(T,{"data-slot":"date-picker-content",className:"p-0 bg-background-1 w-auto gap-0",align:"start",side:"bottom",collisionAvoidance:{side:"shift",align:"shift",fallbackAxisSide:"none"},children:o(M,w(C({},v),{"data-slot":"date-picker-calendar",mode:"range",locale:i,selected:k,captionLayout:y,disabled:s,onSelect:(Z,h)=>{let S;p(j=>{const x=Q(h,j);return U(x)&&(S=x),x}),S&&(u(S),g(!1))}}))})]})})}export{W as DatePicker,Y as DateRangePicker};
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
import * as class_variance_authority_types from 'class-variance-authority/types';
|
|
2
|
+
import { Dialog as Dialog$1 } from '@base-ui/react/dialog';
|
|
3
|
+
export { Dialog as DialogPrimitive } from '@base-ui/react/dialog';
|
|
4
|
+
import { useRender } from '@base-ui/react/use-render';
|
|
5
|
+
import { VariantProps } from 'class-variance-authority';
|
|
6
|
+
import React__default from 'react';
|
|
7
|
+
|
|
8
|
+
declare const DialogCreateHandle: typeof Dialog$1.createHandle;
|
|
9
|
+
declare const Dialog: typeof Dialog$1.Root;
|
|
10
|
+
declare const DialogPortal: typeof Dialog$1.Portal;
|
|
11
|
+
declare function DialogTrigger(props: Dialog$1.Trigger.Props): React__default.ReactElement;
|
|
12
|
+
declare function DialogClose(props: Dialog$1.Close.Props): React__default.ReactElement;
|
|
13
|
+
declare function DialogBackdrop({ className, ...props }: Dialog$1.Backdrop.Props): React__default.ReactElement;
|
|
14
|
+
declare const dialogPopupSizeVariants: (props?: ({
|
|
15
|
+
size?: "xs" | "sm" | "lg" | "xl" | "md" | "full" | "cover" | "2xl" | "3xl" | "4xl" | "5xl" | null | undefined;
|
|
16
|
+
} & class_variance_authority_types.ClassProp) | undefined) => string;
|
|
17
|
+
type DialogPopupSize = NonNullable<VariantProps<typeof dialogPopupSizeVariants>["size"]>;
|
|
18
|
+
declare const dialogViewportPlacementVariants: (props?: ({
|
|
19
|
+
placement?: "bottom" | "top" | "center" | "auto" | null | undefined;
|
|
20
|
+
} & class_variance_authority_types.ClassProp) | undefined) => string;
|
|
21
|
+
type DialogViewportPlacement = NonNullable<VariantProps<typeof dialogViewportPlacementVariants>["placement"]>;
|
|
22
|
+
declare function DialogViewport({ className, placement, ...props }: Dialog$1.Viewport.Props & {
|
|
23
|
+
placement?: DialogViewportPlacement;
|
|
24
|
+
}): React__default.ReactElement;
|
|
25
|
+
declare function DialogPopup({ className, children, showCloseButton, bottomStickOnMobile, placement, size, closeProps, portalProps, ...props }: Dialog$1.Popup.Props & {
|
|
26
|
+
showCloseButton?: boolean;
|
|
27
|
+
bottomStickOnMobile?: boolean;
|
|
28
|
+
placement?: DialogViewportPlacement;
|
|
29
|
+
size?: DialogPopupSize;
|
|
30
|
+
closeProps?: Dialog$1.Close.Props;
|
|
31
|
+
portalProps?: Dialog$1.Portal.Props;
|
|
32
|
+
}): React__default.ReactElement;
|
|
33
|
+
declare function DialogHeader({ className, render, ...props }: useRender.ComponentProps<"div">): React__default.ReactElement;
|
|
34
|
+
declare function DialogFooter({ className, render, ...props }: useRender.ComponentProps<"div">): React__default.ReactElement;
|
|
35
|
+
declare function DialogTitle({ className, ...props }: Dialog$1.Title.Props): React__default.ReactElement;
|
|
36
|
+
declare function DialogDescription({ className, ...props }: Dialog$1.Description.Props): React__default.ReactElement;
|
|
37
|
+
declare function DialogPanel({ className, scrollFade, render, ...props }: useRender.ComponentProps<"div"> & {
|
|
38
|
+
scrollFade?: boolean;
|
|
39
|
+
}): React__default.ReactElement;
|
|
40
|
+
|
|
41
|
+
export { Dialog, DialogBackdrop, DialogClose, DialogPopup as DialogContent, DialogCreateHandle, DialogDescription, DialogFooter, DialogHeader, DialogBackdrop as DialogOverlay, DialogPanel, DialogPopup, type DialogPopupSize, DialogPortal, DialogTitle, DialogTrigger, DialogViewport, type DialogViewportPlacement };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use client";import{a as s,b as c,c as p}from"../../chunk-7LRQ2WLZ.mjs";import{jsx as n,jsxs as w}from"react/jsx-runtime";import{Dialog as l}from"@base-ui/react/dialog";import{mergeProps as g}from"@base-ui/react/merge-props";import{useRender as u}from"@base-ui/react/use-render";import{cva as x}from"class-variance-authority";import{cn as d}from"../../lib/utils";import{CloseButton as b}from"./close-button";import{ScrollArea as R}from"./scroll-area";const O=l.createHandle,q=l.Root,y=l.Portal;function G(a){return n(l.Trigger,s({"data-slot":"dialog-trigger"},a))}function I(a){return n(l.Close,s({"data-slot":"dialog-close"},a))}function P(t){var o=t,{className:a}=o,e=p(o,["className"]);return n(l.Backdrop,s({className:d("fixed inset-0 z-50 bg-black/32 backdrop-blur-sm transition-all duration-200 data-ending-style:opacity-0 data-starting-style:opacity-0",a),"data-slot":"dialog-backdrop"},e))}const h=x("",{variants:{size:{xs:"max-w-xs",sm:"max-w-sm",md:"max-w-md",lg:"max-w-lg",xl:"max-w-xl","2xl":"max-w-2xl","3xl":"max-w-3xl","4xl":"max-w-4xl","5xl":"max-w-5xl",cover:"w-full max-w-[calc(100vw-4rem)] h-[calc(100dvh-4rem)] ",full:"max-w-none w-full h-[100dvh] rounded-none before:rounded-none "}},defaultVariants:{size:"lg"}}),V=x("fixed inset-0 z-50 grid justify-items-center p-4",{variants:{placement:{auto:"grid-rows-[1fr_auto_3fr]",top:"grid-rows-[auto_1fr] content-start",center:"grid-rows-[1fr_auto_1fr]",bottom:"grid-rows-[1fr_auto] content-end"}},defaultVariants:{placement:"center"}}),N=x("",{variants:{placement:{auto:"row-start-2",top:"row-start-1",center:"row-start-2",bottom:"row-start-2"}},defaultVariants:{placement:"auto"}});function C(o){var r=o,{className:a,placement:e}=r,t=p(r,["className","placement"]);return n(l.Viewport,s({className:d(V({placement:e}),a),"data-placement":e!=null?e:"auto","data-slot":"dialog-viewport"},t))}function _(E){var f=E,{className:a,children:e,showCloseButton:t=!0,bottomStickOnMobile:o=!0,placement:r,size:i,closeProps:m,portalProps:v}=f,D=p(f,["className","children","showCloseButton","bottomStickOnMobile","placement","size","closeProps","portalProps"]);return w(y,c(s({},v),{children:[n(P,{}),n(C,{className:d(o&&"max-sm:grid-rows-[1fr_auto] max-sm:p-0 max-sm:pt-12 max-sm:content-end"),placement:r,children:w(l.Popup,c(s({className:d("relative flex max-h-full min-h-0 w-full min-w-0 origin-center flex-col rounded-3xl bg-popover not-dark:bg-clip-padding text-popover-foreground opacity-[calc(1-var(--nested-dialogs))] shadow-lg/5 outline-none transition-[scale,opacity,translate] duration-200 ease-in-out will-change-transform before:pointer-events-none before:absolute before:inset-0 before:rounded-[calc(var(--radius-2xl)-1px)] before:shadow-[0_1px_--theme(--color-black/4%)] data-ending-style:opacity-0 data-starting-style:opacity-0 sm:scale-[calc(1-0.1*var(--nested-dialogs))] sm:data-ending-style:scale-98 sm:data-starting-style:scale-98 dark:before:shadow-[0_-1px_--theme(--color-white/6%)]",N({placement:r}),h({size:i}),o&&"max-sm:max-w-none max-sm:origin-bottom max-sm:rounded-none max-sm:border-x-0 max-sm:border-t max-sm:border-b-0 max-sm:data-ending-style:translate-y-4 max-sm:data-starting-style:translate-y-4 max-sm:before:hidden max-sm:before:rounded-none",a),"data-size":i!=null?i:"lg","data-slot":"dialog-popup"},D),{children:[e,t?n(l.Close,s({"aria-label":"Close",className:"absolute end-3 top-3",render:n(b,{size:"sm"})},m)):null]}))})]}))}function J(o){var r=o,{className:a,render:e}=r,t=p(r,["className","render"]);const i={className:d("flex flex-col gap-1 p-6 in-[[data-slot=dialog-popup]:has([data-slot=dialog-panel])]:pb-4 max-sm:pb-4",a),"data-slot":"dialog-header"};return u({defaultTagName:"div",props:g(i,t),render:e})}function K(o){var r=o,{className:a,render:e}=r,t=p(r,["className","render"]);const i={className:d("flex flex-col-reverse gap-2 px-6 pt-4 pb-6 sm:flex-row sm:justify-end sm:rounded-b-[calc(var(--radius-2xl)-1px)] in-[[data-slot=dialog-popup]:has([data-slot=dialog-panel])]:pt-4",a),"data-slot":"dialog-footer"};return u({defaultTagName:"div",props:g(i,t),render:e})}function L(t){var o=t,{className:a}=o,e=p(o,["className"]);return n(l.Title,s({className:d("font-heading font-semibold text-base leading-none",a),"data-slot":"dialog-title"},e))}function M(t){var o=t,{className:a}=o,e=p(o,["className"]);return n(l.Description,s({className:d("text-muted-foreground text-sm",a),"data-slot":"dialog-description"},e))}function Q(r){var i=r,{className:a,scrollFade:e=!0,render:t}=i,o=p(i,["className","scrollFade","render"]);const m={className:d("p-6 in-[[data-slot=dialog-popup]:has([data-slot=dialog-header])]:pt-2 in-[[data-slot=dialog-popup]:has([data-slot=dialog-footer])]:pb-2",a),"data-slot":"dialog-panel"};return n(R,{scrollFade:e,children:u({defaultTagName:"div",props:g(m,o),render:t})})}export{q as Dialog,P as DialogBackdrop,I as DialogClose,_ as DialogContent,O as DialogCreateHandle,M as DialogDescription,K as DialogFooter,J as DialogHeader,P as DialogOverlay,Q as DialogPanel,_ as DialogPopup,y as DialogPortal,l as DialogPrimitive,L as DialogTitle,G as DialogTrigger,C as DialogViewport};
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
import { Drawer as Drawer$1 } from '@base-ui/react/drawer';
|
|
2
|
+
export { Drawer as DrawerPrimitive } from '@base-ui/react/drawer';
|
|
3
|
+
import { useRender } from '@base-ui/react/use-render';
|
|
4
|
+
import React__default from 'react';
|
|
5
|
+
|
|
6
|
+
type DrawerPosition = "right" | "left" | "top" | "bottom";
|
|
7
|
+
declare const DrawerCreateHandle: typeof Drawer$1.createHandle;
|
|
8
|
+
declare function Drawer({ swipeDirection, position, ...props }: Drawer$1.Root.Props & {
|
|
9
|
+
position?: DrawerPosition;
|
|
10
|
+
}): React__default.ReactElement;
|
|
11
|
+
declare const DrawerPortal: typeof Drawer$1.Portal;
|
|
12
|
+
declare function DrawerTrigger(props: Drawer$1.Trigger.Props): React__default.ReactElement;
|
|
13
|
+
declare function DrawerClose(props: Drawer$1.Close.Props): React__default.ReactElement;
|
|
14
|
+
declare function DrawerSwipeArea({ className, position: positionProp, ...props }: Drawer$1.SwipeArea.Props & {
|
|
15
|
+
position?: DrawerPosition;
|
|
16
|
+
}): React__default.ReactElement;
|
|
17
|
+
declare function DrawerBackdrop({ className, ...props }: Drawer$1.Backdrop.Props): React__default.ReactElement;
|
|
18
|
+
declare function DrawerViewport({ className, position, variant, ...props }: Drawer$1.Viewport.Props & {
|
|
19
|
+
position?: DrawerPosition;
|
|
20
|
+
variant?: "default" | "straight" | "inset";
|
|
21
|
+
}): React__default.ReactElement;
|
|
22
|
+
declare function DrawerPopup({ className, children, showCloseButton, position: positionProp, variant, showBar, ...props }: Drawer$1.Popup.Props & {
|
|
23
|
+
showCloseButton?: boolean;
|
|
24
|
+
position?: DrawerPosition;
|
|
25
|
+
variant?: "default" | "straight" | "inset";
|
|
26
|
+
showBar?: boolean;
|
|
27
|
+
}): React__default.ReactElement;
|
|
28
|
+
declare function DrawerHeader({ className, allowSelection, render, ...props }: useRender.ComponentProps<"div"> & {
|
|
29
|
+
allowSelection?: boolean;
|
|
30
|
+
}): React__default.ReactElement;
|
|
31
|
+
declare function DrawerFooter({ className, allowSelection, render, ...props }: useRender.ComponentProps<"div"> & {
|
|
32
|
+
allowSelection?: boolean;
|
|
33
|
+
}): React__default.ReactElement;
|
|
34
|
+
declare function DrawerTitle({ className, ...props }: Drawer$1.Title.Props): React__default.ReactElement;
|
|
35
|
+
declare function DrawerDescription({ className, ...props }: Drawer$1.Description.Props): React__default.ReactElement;
|
|
36
|
+
declare function DrawerPanel({ className, scrollFade, scrollable, allowSelection, render, ...props }: useRender.ComponentProps<"div"> & {
|
|
37
|
+
scrollFade?: boolean;
|
|
38
|
+
scrollable?: boolean;
|
|
39
|
+
allowSelection?: boolean;
|
|
40
|
+
}): React__default.ReactElement;
|
|
41
|
+
declare function DrawerBar({ className, position: positionProp, render, ...props }: useRender.ComponentProps<"div"> & {
|
|
42
|
+
position?: DrawerPosition;
|
|
43
|
+
}): React__default.ReactElement;
|
|
44
|
+
declare const DrawerContent: typeof Drawer$1.Content;
|
|
45
|
+
|
|
46
|
+
export { Drawer, DrawerBackdrop, DrawerBar, DrawerClose, DrawerContent, DrawerCreateHandle, DrawerDescription, DrawerFooter, DrawerHeader, DrawerPanel, DrawerPopup, DrawerPortal, DrawerSwipeArea, DrawerTitle, DrawerTrigger, DrawerViewport };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use client";import{a as m,b as D,c as p}from"../../chunk-7LRQ2WLZ.mjs";import{jsx as n,jsxs as P}from"react/jsx-runtime";import{Drawer as l}from"@base-ui/react/drawer";import{mergeProps as v}from"@base-ui/react/merge-props";import{useRender as b}from"@base-ui/react/use-render";import{createContext as y,useContext as x}from"react";import{cn as c}from"../../lib/utils";import{ScrollArea as R}from"./scroll-area";import{CloseButton as k}from"./close-button";const g=y({position:"bottom"}),C={bottom:"down",left:"left",right:"right",top:"up"},j=l.createHandle;function F(r){var s=r,{swipeDirection:t,position:e="bottom"}=s,a=p(s,["swipeDirection","position"]);return n(g.Provider,{value:{position:e},children:n(l.Root,m({swipeDirection:t!=null?t:C[e]},a))})}const _=l.Portal;function M(t){return n(l.Trigger,m({"data-slot":"drawer-trigger"},t))}function q(t){return n(l.Close,m({"data-slot":"drawer-close"},t))}function G(r){var s=r,{className:t,position:e}=s,a=p(s,["className","position"]);const{position:i}=x(g),d=e!=null?e:i;return n(l.SwipeArea,m({className:c("fixed z-50 touch-none",d==="bottom"&&"inset-x-0 bottom-0 h-8",d==="top"&&"inset-x-0 top-0 h-8",d==="left"&&"inset-y-0 left-0 w-8",d==="right"&&"inset-y-0 right-0 w-8",t),"data-slot":"drawer-swipe-area"},a))}function N(a){var r=a,{className:t}=r,e=p(r,["className"]);return n(l.Backdrop,m({className:c("fixed inset-0 z-50 bg-[color-mix(in_srgb,var(--color-gray-10-value)_32%,transparent)] opacity-[calc(1-var(--drawer-swipe-progress))] backdrop-blur-sm transition-opacity duration-450 ease-[cubic-bezier(0.32,0.72,0,1)] data-ending-style:opacity-0 data-starting-style:opacity-0 data-ending-style:duration-[calc(var(--drawer-swipe-strength)*400ms)] data-swiping:duration-0 supports-[-webkit-touch-callout:none]:absolute",t),"data-slot":"drawer-backdrop"},e))}function E(s){var i=s,{className:t,position:e,variant:a="default"}=i,r=p(i,["className","position","variant"]);return n(l.Viewport,m({className:c("fixed inset-0 z-50 [--bleed:--spacing(12)] [--inset:--spacing(0)]","touch-none",e==="bottom"&&"grid grid-rows-[1fr_auto] pt-12",e==="top"&&"grid grid-rows-[auto_1fr] pb-12",e==="left"&&"flex justify-start",e==="right"&&"flex justify-end",a==="inset"&&"px-(--inset) sm:[--inset:--spacing(4)]",a==="inset"&&e!=="bottom"&&"pt-(--inset)",a==="inset"&&e!=="top"&&"pb-(--inset)",t),"data-slot":"drawer-viewport"},r))}function I(f){var u=f,{className:t,children:e,showCloseButton:a=!1,position:r,variant:s="default",showBar:i=!1}=u,d=p(u,["className","children","showCloseButton","position","variant","showBar"]);const{position:w}=x(g),o=r!=null?r:w;return P(_,{children:[n(N,{}),n(E,{position:o,variant:s,children:P(l.Popup,D(m({className:c("relative flex max-h-full min-h-0 w-full min-w-0 flex-col bg-popover not-dark:bg-clip-padding text-popover-foreground shadow-lg/5 outline-none transition-[transform,box-shadow,height,background-color] duration-450 ease-[cubic-bezier(0.32,0.72,0,1)] will-change-transform [--peek:calc(--spacing(6)-1px)] [--scale-base:calc(max(0,1-(var(--nested-drawers)*var(--stack-step))))] [--scale:clamp(0,calc(var(--scale-base)+(var(--stack-step)*var(--stack-progress))),1)] [--shrink:calc(1-var(--scale))] [--stack-peek-offset:max(0px,calc((var(--nested-drawers)-var(--stack-progress))*var(--peek)))] [--stack-progress:clamp(0,var(--drawer-swipe-progress),1)] [--stack-step:0.05] before:pointer-events-none before:absolute before:inset-0 before:shadow-[0_1px_0_color-mix(in_srgb,var(--foreground),transparent_88%)] after:pointer-events-none after:absolute after:bg-popover data-swiping:select-none data-nested-drawer-open:overflow-hidden data-nested-drawer-open:bg-[color-mix(in_srgb,var(--popover),var(--background)_calc(4%*(var(--nested-drawers)-var(--stack-progress))))] data-ending-style:shadow-transparent data-starting-style:shadow-transparent data-ending-style:duration-[calc(var(--drawer-swipe-strength)*400ms)]","touch-none",o==="bottom"&&"transform-[translateY(calc(var(--drawer-snap-point-offset)+var(--drawer-swipe-movement-y)))] data-ending-style:transform-[translateY(calc(100%+env(safe-area-inset-bottom,0px)+var(--inset)))] data-starting-style:transform-[translateY(calc(100%+env(safe-area-inset-bottom,0px)+var(--inset)))] row-start-2 -mb-[max(0px,calc(var(--drawer-snap-point-offset,0px)+clamp(0,1,var(--drawer-snap-point-offset,0px)/1px)*var(--drawer-swipe-movement-y,0px)))] border-t pb-[max(0px,calc(env(safe-area-inset-bottom,0px)+var(--drawer-snap-point-offset,0px)+clamp(0,1,var(--drawer-snap-point-offset,0px)/1px)*var(--drawer-swipe-movement-y,0px)))] not-data-starting-style:not-data-ending-style:transition-[transform,box-shadow,height,background-color,margin,padding] after:inset-x-0 after:top-full after:h-(--bleed) has-data-[slot=drawer-bar]:pt-2 data-ending-style:mb-0 data-starting-style:mb-0 data-ending-style:pb-0 data-starting-style:pb-0",o==="top"&&"data-starting-style:transform-[translateY(calc(-100%-var(--inset)))] data-ending-style:transform-[translateY(calc(-100%-var(--inset)))] transform-[translateY(var(--drawer-swipe-movement-y))] border-b after:inset-x-0 after:bottom-full after:h-(--bleed) has-data-[slot=drawer-bar]:pb-2",o==="left"&&"data-starting-style:transform-[translateX(calc(-100%-var(--inset)))] data-ending-style:transform-[translateX(calc(-100%-var(--inset)))] transform-[translateX(var(--drawer-swipe-movement-x))] w-[calc(100%-(--spacing(12)))] max-w-md border-e after:inset-y-0 after:end-full after:w-(--bleed) has-data-[slot=drawer-bar]:pe-2",o==="right"&&"transform-[translateX(var(--drawer-swipe-movement-x))] data-ending-style:transform-[translateX(calc(100%+var(--inset)))] data-starting-style:transform-[translateX(calc(100%+var(--inset)))] col-start-2 w-[calc(100%-(--spacing(12)))] max-w-md border-s after:inset-y-0 after:start-full after:w-(--bleed) has-data-[slot=drawer-bar]:ps-2",s!=="straight"&&c(o==="bottom"&&"rounded-t-2xl",o==="top"&&"rounded-b-2xl **:data-[slot=drawer-footer]:rounded-b-[calc(var(--radius-2xl)-1px)]",o==="left"&&"rounded-e-2xl **:data-[slot=drawer-footer]:rounded-ee-[calc(var(--radius-2xl)-1px)]",o==="right"&&"rounded-s-2xl **:data-[slot=drawer-footer]:rounded-es-[calc(var(--radius-2xl)-1px)]"),s==="default"&&c(o==="bottom"&&"before:rounded-t-[calc(var(--radius-2xl)-1px)]",o==="top"&&"before:rounded-b-[calc(var(--radius-2xl)-1px)]",o==="left"&&"before:rounded-e-[calc(var(--radius-2xl)-1px)]",o==="right"&&"before:rounded-s-[calc(var(--radius-2xl)-1px)]"),s==="inset"&&"before:hidden sm:rounded-2xl sm:after:bg-transparent sm:before:rounded-[calc(var(--radius-2xl)-1px)] sm:**:data-[slot=drawer-footer]:rounded-b-[calc(var(--radius-2xl)-1px)]",s==="straight"&&"[--stack-step:0]",(o==="bottom"||o==="top")&&"h-(--drawer-height,auto) [--height:max(0px,calc(var(--drawer-frontmost-height,var(--drawer-height))))] data-nested-drawer-open:h-(--height)",o==="bottom"&&"data-nested-drawer-open:transform-[translateY(calc(var(--drawer-swipe-movement-y)-var(--stack-peek-offset)-(var(--shrink)*var(--height))))_scale(var(--scale))] origin-[50%_calc(100%-var(--inset))]",o==="top"&&"data-nested-drawer-open:transform-[translateY(calc(var(--drawer-swipe-movement-y)+var(--stack-peek-offset)+(var(--shrink)*var(--height))))_scale(var(--scale))] origin-[50%_var(--inset)]",o==="left"&&"data-nested-drawer-open:transform-[translateX(calc(var(--drawer-swipe-movement-x)+var(--stack-peek-offset)))_scale(var(--scale))] origin-right",o==="right"&&"data-nested-drawer-open:transform-[translateX(calc(var(--drawer-swipe-movement-x)-var(--stack-peek-offset)))_scale(var(--scale))] origin-left",t),"data-slot":"drawer-popup"},d),{children:[e,a?n(l.Close,{"aria-label":"Close",className:"absolute end-3 top-3 z-10",render:n(k,{size:"sm"})}):null,i?n(T,{}):null]}))})]})}function J(s){var i=s,{className:t,allowSelection:e=!1,render:a}=i,r=p(i,["className","allowSelection","render"]);const d={className:c("flex flex-col gap-2 p-6 in-[[data-slot=drawer-popup]:has([data-slot=drawer-panel])]:pb-3 max-sm:pb-4",!e&&"cursor-default",t),"data-slot":"drawer-header"};return b({defaultTagName:"div",props:v(d,r),render:e?n(h,{render:a}):a})}function K(s){var i=s,{className:t,allowSelection:e=!0,render:a}=i,r=p(i,["className","allowSelection","render"]);const d={className:c("flex flex-col-reverse gap-2 px-6 pb-(--safe-area-inset-bottom,0px) sm:flex-row sm:justify-end",!e&&"cursor-default","in-[[data-slot=drawer-popup]:has([data-slot=drawer-panel])]:pt-4 pt-4 pb-[calc(env(safe-area-inset-bottom,0px)+--spacing(4))]",t),"data-slot":"drawer-footer"};return b({defaultTagName:"div",props:v(d,r),render:e?n(h,{render:a}):a})}function L(a){var r=a,{className:t}=r,e=p(r,["className"]);return n(l.Title,m({className:c("font-heading font-semibold text-base leading-none text-popover-foreground",t),"data-slot":"drawer-title"},e))}function O(a){var r=a,{className:t}=r,e=p(r,["className"]);return n(l.Description,m({className:c("text-muted-foreground text-sm",t),"data-slot":"drawer-description"},e))}function Q(d){var f=d,{className:t,scrollFade:e=!0,scrollable:a=!0,allowSelection:r=!0,render:s}=f,i=p(f,["className","scrollFade","scrollable","allowSelection","render"]);const u={className:c("p-6 in-[[data-slot=drawer-popup]:has([data-slot=drawer-header])]:pt-1 in-[[data-slot=drawer-popup]:has([data-slot=drawer-footer]:not(.border-t))]:pb-1",!r&&"cursor-default",t),"data-slot":"drawer-panel"},w=b({defaultTagName:"div",props:v(u,i),render:r?n(h,{render:s}):s});return a?n(R,{className:"touch-auto",scrollFade:e,children:w}):w}function T(s){var i=s,{className:t,position:e,render:a}=i,r=p(i,["className","position","render"]);const{position:d}=x(g),f=e!=null?e:d,w={"aria-hidden":!0,className:c("absolute flex touch-none items-center justify-center p-3.5 before:rounded-full before:bg-input",f==="left"||f==="right"?"inset-y-0 before:h-12 before:w-1":"inset-x-0 before:h-1 before:w-12",f==="top"&&"bottom-0",f==="bottom"&&"top-0",f==="left"&&"right-0",f==="right"&&"left-0",t),"data-slot":"drawer-bar"};return b({defaultTagName:"div",props:v(w,r),render:a})}const h=l.Content;export{F as Drawer,N as DrawerBackdrop,T as DrawerBar,q as DrawerClose,h as DrawerContent,j as DrawerCreateHandle,O as DrawerDescription,K as DrawerFooter,J as DrawerHeader,Q as DrawerPanel,I as DrawerPopup,_ as DrawerPortal,l as DrawerPrimitive,G as DrawerSwipeArea,L as DrawerTitle,M as DrawerTrigger,E as DrawerViewport};
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
|
+
import { ComponentProps } from 'react';
|
|
3
|
+
import { Menu } from '@base-ui/react/menu';
|
|
4
|
+
|
|
5
|
+
declare function DropdownMenu({ ...props }: Menu.Root.Props): react_jsx_runtime.JSX.Element;
|
|
6
|
+
declare function DropdownMenuPortal({ ...props }: Menu.Portal.Props): react_jsx_runtime.JSX.Element;
|
|
7
|
+
declare function DropdownMenuTrigger({ ...props }: Menu.Trigger.Props): react_jsx_runtime.JSX.Element;
|
|
8
|
+
declare function DropdownMenuContent({ align, alignOffset, side, sideOffset, className, ...props }: Menu.Popup.Props & Pick<Menu.Positioner.Props, "align" | "alignOffset" | "side" | "sideOffset">): react_jsx_runtime.JSX.Element;
|
|
9
|
+
declare function DropdownMenuGroup({ ...props }: Menu.Group.Props): react_jsx_runtime.JSX.Element;
|
|
10
|
+
/** Must be used inside `DropdownMenuGroup` — Base UI `GroupLabel` requires `Menu.Group` context. */
|
|
11
|
+
declare function DropdownMenuLabel({ className, inset, ...props }: Menu.GroupLabel.Props & {
|
|
12
|
+
inset?: boolean;
|
|
13
|
+
}): react_jsx_runtime.JSX.Element;
|
|
14
|
+
declare function DropdownMenuItem({ className, inset, variant, ...props }: Menu.Item.Props & {
|
|
15
|
+
inset?: boolean;
|
|
16
|
+
variant?: "default" | "destructive";
|
|
17
|
+
}): react_jsx_runtime.JSX.Element;
|
|
18
|
+
declare function DropdownMenuSub({ ...props }: Menu.SubmenuRoot.Props): react_jsx_runtime.JSX.Element;
|
|
19
|
+
declare function DropdownMenuSubTrigger({ className, inset, children, ...props }: Menu.SubmenuTrigger.Props & {
|
|
20
|
+
inset?: boolean;
|
|
21
|
+
}): react_jsx_runtime.JSX.Element;
|
|
22
|
+
declare function DropdownMenuSubContent({ align, alignOffset, side, sideOffset, className, ...props }: ComponentProps<typeof DropdownMenuContent>): react_jsx_runtime.JSX.Element;
|
|
23
|
+
declare function DropdownMenuCheckboxItem({ className, children, checked, inset, ...props }: Menu.CheckboxItem.Props & {
|
|
24
|
+
inset?: boolean;
|
|
25
|
+
}): react_jsx_runtime.JSX.Element;
|
|
26
|
+
declare function DropdownMenuRadioGroup({ ...props }: Menu.RadioGroup.Props): react_jsx_runtime.JSX.Element;
|
|
27
|
+
declare function DropdownMenuRadioItem({ className, children, inset, ...props }: Menu.RadioItem.Props & {
|
|
28
|
+
inset?: boolean;
|
|
29
|
+
}): react_jsx_runtime.JSX.Element;
|
|
30
|
+
declare function DropdownMenuSeparator({ className, ...props }: Menu.Separator.Props): react_jsx_runtime.JSX.Element;
|
|
31
|
+
declare function DropdownMenuShortcut({ className, ...props }: ComponentProps<"span">): react_jsx_runtime.JSX.Element;
|
|
32
|
+
|
|
33
|
+
export { DropdownMenu, DropdownMenuCheckboxItem, DropdownMenuContent, DropdownMenuGroup, DropdownMenuItem, DropdownMenuLabel, DropdownMenuPortal, DropdownMenuRadioGroup, DropdownMenuRadioItem, DropdownMenuSeparator, DropdownMenuShortcut, DropdownMenuSub, DropdownMenuSubContent, DropdownMenuSubTrigger, DropdownMenuTrigger };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use client";import{a,b as m,c as i}from"../../chunk-7LRQ2WLZ.mjs";import{jsx as o,jsxs as f}from"react/jsx-runtime";import{Menu as r}from"@base-ui/react/menu";import{ChevronRightIcon as b,CheckIcon as g}from"lucide-react";import{cn as c}from"../../lib/utils";function x(t){var e=i(t,[]);return o(r.Root,a({"data-slot":"dropdown-menu"},e))}function P(t){var e=i(t,[]);return o(r.Portal,a({"data-slot":"dropdown-menu-portal"},e))}function w(t){var e=i(t,[]);return o(r.Trigger,a({"data-slot":"dropdown-menu-trigger"},e))}function v(l){var p=l,{align:e="start",alignOffset:t=0,side:d="bottom",sideOffset:n=4,className:u}=p,s=i(p,["align","alignOffset","side","sideOffset","className"]);return o(r.Portal,{children:o(r.Positioner,{className:"isolate z-50 outline-none",align:e,alignOffset:t,side:d,sideOffset:n,children:o(r.Popup,a({"data-slot":"dropdown-menu-content",className:c("z-50 max-h-(--available-height) w-(--anchor-width) min-w-48 origin-(--transform-origin) overflow-x-hidden overflow-y-auto rounded-xl bg-popover p-1 text-popover-foreground shadow-large ring-1 ring-border/50 duration-100 outline-none","data-[side=bottom]:slide-in-from-top-2 data-[side=inline-end]:slide-in-from-left-2 data-[side=inline-start]:slide-in-from-right-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2","data-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:overflow-hidden data-closed:fade-out-0 data-closed:zoom-out-95",u)},s))})})}function M(t){var e=i(t,[]);return o(r.Group,a({"data-slot":"dropdown-menu-group"},e))}function h(n){var u=n,{className:e,inset:t}=u,d=i(u,["className","inset"]);return o(r.GroupLabel,a({"data-slot":"dropdown-menu-label","data-inset":t,className:c("px-3 py-2.5 text-xs text-muted-foreground data-inset:pl-9.5",e)},d))}function I(u){var s=u,{className:e,inset:t,variant:d="default"}=s,n=i(s,["className","inset","variant"]);return o(r.Item,a({"data-slot":"dropdown-menu-item","data-inset":t,"data-variant":d,className:c("group/dropdown-menu-item relative flex cursor-default items-center gap-2.5 rounded-xl px-3 py-2 text-sm outline-hidden select-none focus:bg-accent focus:text-accent-foreground not-data-[variant=destructive]:focus:**:text-accent-foreground data-inset:pl-9.5 data-[variant=destructive]:text-destructive data-[variant=destructive]:focus:bg-destructive/10 data-[variant=destructive]:focus:text-destructive dark:data-[variant=destructive]:focus:bg-destructive/20 data-disabled:pointer-events-none data-disabled:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4 data-[variant=destructive]:*:[svg]:text-destructive",e)},n))}function k(t){var e=i(t,[]);return o(r.SubmenuRoot,a({"data-slot":"dropdown-menu-sub"},e))}function D(u){var s=u,{className:e,inset:t,children:d}=s,n=i(s,["className","inset","children"]);return f(r.SubmenuTrigger,m(a({"data-slot":"dropdown-menu-sub-trigger","data-inset":t,className:c("flex cursor-default items-center gap-2 rounded-xl px-3 py-2 text-sm outline-hidden select-none focus:bg-accent focus:text-accent-foreground not-data-[variant=destructive]:focus:**:text-accent-foreground data-inset:pl-9.5 data-popup-open:bg-accent data-popup-open:text-accent-foreground data-open:bg-accent data-open:text-accent-foreground [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",e)},n),{children:[d,o(b,{className:"ml-auto"})]}))}function y(l){var p=l,{align:e="start",alignOffset:t=-3,side:d="right",sideOffset:n=0,className:u}=p,s=i(p,["align","alignOffset","side","sideOffset","className"]);return o(v,a({"data-slot":"dropdown-menu-sub-content",className:c("w-auto min-w-36",u),align:e,alignOffset:t,side:d,sideOffset:n},s))}function C(s){var l=s,{className:e,children:t,checked:d,inset:n}=l,u=i(l,["className","children","checked","inset"]);return f(r.CheckboxItem,m(a({"data-slot":"dropdown-menu-checkbox-item","data-inset":n,className:c("relative flex cursor-default items-center gap-2.5 rounded-xl py-2 pr-8 pl-3 text-sm outline-hidden select-none focus:bg-accent focus:text-accent-foreground focus:**:text-accent-foreground data-inset:pl-9.5 data-disabled:pointer-events-none data-disabled:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",e),checked:d},u),{children:[o("span",{className:"pointer-events-none absolute right-2 flex items-center justify-center","data-slot":"dropdown-menu-checkbox-item-indicator",children:o(r.CheckboxItemIndicator,{children:o(g,{})})}),t]}))}function R(t){var e=i(t,[]);return o(r.RadioGroup,a({"data-slot":"dropdown-menu-radio-group"},e))}function N(u){var s=u,{className:e,children:t,inset:d}=s,n=i(s,["className","children","inset"]);return f(r.RadioItem,m(a({"data-slot":"dropdown-menu-radio-item","data-inset":d,className:c("relative flex cursor-default items-center gap-2.5 rounded-xl py-2 pr-8 pl-3 text-sm outline-hidden select-none focus:bg-accent focus:text-accent-foreground focus:**:text-accent-foreground data-inset:pl-9.5 data-disabled:pointer-events-none data-disabled:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",e)},n),{children:[o("span",{className:"pointer-events-none absolute right-2 flex items-center justify-center","data-slot":"dropdown-menu-radio-item-indicator",children:o(r.RadioItemIndicator,{children:o(g,{})})}),t]}))}function z(d){var n=d,{className:e}=n,t=i(n,["className"]);return o(r.Separator,a({"data-slot":"dropdown-menu-separator",className:c("-mx-1 my-1 h-px bg-border/50",e)},t))}function S(d){var n=d,{className:e}=n,t=i(n,["className"]);return o("span",a({"data-slot":"dropdown-menu-shortcut",className:c("ml-auto text-xs tracking-widest text-muted-foreground group-focus/dropdown-menu-item:text-accent-foreground",e)},t))}export{x as DropdownMenu,C as DropdownMenuCheckboxItem,v as DropdownMenuContent,M as DropdownMenuGroup,I as DropdownMenuItem,h as DropdownMenuLabel,P as DropdownMenuPortal,R as DropdownMenuRadioGroup,N as DropdownMenuRadioItem,z as DropdownMenuSeparator,S as DropdownMenuShortcut,k as DropdownMenuSub,y as DropdownMenuSubContent,D as DropdownMenuSubTrigger,w as DropdownMenuTrigger};
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
|
+
import * as class_variance_authority_types from 'class-variance-authority/types';
|
|
3
|
+
import { ComponentProps } from 'react';
|
|
4
|
+
import { VariantProps } from 'class-variance-authority';
|
|
5
|
+
|
|
6
|
+
declare const emptyVariants: (props?: ({
|
|
7
|
+
variant?: "default" | "outline" | "plain" | null | undefined;
|
|
8
|
+
} & class_variance_authority_types.ClassProp) | undefined) => string;
|
|
9
|
+
type EmptyProps = ComponentProps<"div"> & VariantProps<typeof emptyVariants>;
|
|
10
|
+
declare function Empty({ className, variant, ...props }: EmptyProps): react_jsx_runtime.JSX.Element;
|
|
11
|
+
declare function EmptyHeader({ className, ...props }: ComponentProps<"div">): react_jsx_runtime.JSX.Element;
|
|
12
|
+
declare const emptyMediaVariants: (props?: ({
|
|
13
|
+
variant?: "default" | "icon" | null | undefined;
|
|
14
|
+
} & class_variance_authority_types.ClassProp) | undefined) => string;
|
|
15
|
+
declare function EmptyMedia({ className, variant, ...props }: ComponentProps<"div"> & VariantProps<typeof emptyMediaVariants>): react_jsx_runtime.JSX.Element;
|
|
16
|
+
declare function EmptyTitle({ className, ...props }: ComponentProps<"div">): react_jsx_runtime.JSX.Element;
|
|
17
|
+
declare function EmptyDescription({ className, ...props }: ComponentProps<"p">): react_jsx_runtime.JSX.Element;
|
|
18
|
+
declare function EmptyContent({ className, ...props }: ComponentProps<"div">): react_jsx_runtime.JSX.Element;
|
|
19
|
+
|
|
20
|
+
export { Empty, EmptyContent, EmptyDescription, EmptyHeader, EmptyMedia, type EmptyProps, EmptyTitle, emptyVariants };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use client";import{a as n,c as o}from"../../chunk-7LRQ2WLZ.mjs";import{jsx as p}from"react/jsx-runtime";import{cva as m}from"class-variance-authority";import{cn as s}from"../../lib/utils";const d=m("flex w-full min-w-0 flex-1 flex-col items-center justify-center gap-4 text-center text-balance",{variants:{variant:{default:"gap-6 rounded-2xl border border-border/50 bg-muted/25 py-14 px-6 dark:bg-muted/15",outline:"gap-4 rounded-lg border-dashed border-border bg-transparent p-12",plain:"gap-6 rounded-2xl border-0 bg-transparent py-12 px-4"}},defaultVariants:{variant:"default"}});function l(t){var i=t,{className:r,variant:e}=i,a=o(i,["className","variant"]);return p("div",n({"data-slot":"empty",className:s(d({variant:e}),r)},a))}function u(a){var t=a,{className:r}=t,e=o(t,["className"]);return p("div",n({"data-slot":"empty-header",className:s("flex max-w-sm flex-col items-center gap-2 max-w-md gap-3",r)},e))}const f=m("mb-2 flex shrink-0 items-center justify-center [&_svg]:pointer-events-none [&_svg]:shrink-0",{variants:{variant:{default:"bg-transparent",icon:"mb-3 size-11 rounded-full border-0 bg-muted/70 p-0 text-muted-foreground dark:bg-muted/50 [&_svg:not([class*='size-'])]:size-5"}},defaultVariants:{variant:"default"}});function c(t){var i=t,{className:r,variant:e="default"}=i,a=o(i,["className","variant"]);return p("div",n({"data-slot":"empty-icon","data-variant":e,className:s(f({variant:e}),r)},a))}function y(a){var t=a,{className:r}=t,e=o(t,["className"]);return p("div",n({"data-slot":"empty-title",className:s("text-base font-semibold tracking-tight text-foreground sm:text-[1.0625rem]",r)},e))}function x(a){var t=a,{className:r}=t,e=o(t,["className"]);return p("div",n({"data-slot":"empty-description",className:s("max-w-sm text-pretty text-sm leading-6 text-muted-foreground [&>a]:underline [&>a]:underline-offset-4 [&>a:hover]:text-primary",r)},e))}function g(a){var t=a,{className:r}=t,e=o(t,["className"]);return p("div",n({"data-slot":"empty-content",className:s("max-w-md flex-col gap-3 sm:flex-row sm:flex-wrap sm:items-center sm:justify-center sm:gap-x-3 sm:gap-y-2",r)},e))}export{l as Empty,g as EmptyContent,x as EmptyDescription,u as EmptyHeader,c as EmptyMedia,y as EmptyTitle,d as emptyVariants};
|