@slipstream-ui/core 0.6.0 → 0.7.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.d.mts +337 -17
- package/dist/index.d.ts +337 -17
- package/dist/index.js +719 -226
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +713 -226
- package/dist/index.mjs.map +1 -1
- package/dist/manifests/accordion.manifest.json +1 -1
- package/dist/manifests/alert.manifest.json +1 -1
- package/dist/manifests/announcement-bar.manifest.json +1 -1
- package/dist/manifests/app-shell.manifest.json +1 -1
- package/dist/manifests/applied-filters.manifest.json +1 -1
- package/dist/manifests/article-card.manifest.json +1 -1
- package/dist/manifests/auth-layout.manifest.json +1 -1
- package/dist/manifests/autocomplete.manifest.json +1 -1
- package/dist/manifests/avatar.manifest.json +1 -1
- package/dist/manifests/badge.manifest.json +1 -1
- package/dist/manifests/block.manifest.json +1 -1
- package/dist/manifests/breadcrumb.manifest.json +1 -1
- package/dist/manifests/button-group.manifest.json +1 -1
- package/dist/manifests/button.manifest.json +1 -1
- package/dist/manifests/card.manifest.json +1 -1
- package/dist/manifests/checkbox.manifest.json +1 -1
- package/dist/manifests/comparison-table.manifest.json +1 -1
- package/dist/manifests/confirm-dialog.manifest.json +1 -1
- package/dist/manifests/contact-strip.manifest.json +1 -1
- package/dist/manifests/container.manifest.json +1 -1
- package/dist/manifests/cta-section.manifest.json +1 -1
- package/dist/manifests/data-table.manifest.json +1 -1
- package/dist/manifests/date-picker.manifest.json +1 -1
- package/dist/manifests/date-range-picker.manifest.json +1 -1
- package/dist/manifests/deal-card.manifest.json +158 -0
- package/dist/manifests/dialog.manifest.json +1 -1
- package/dist/manifests/document-card.manifest.json +108 -0
- package/dist/manifests/drawer.manifest.json +1 -1
- package/dist/manifests/empty-state.manifest.json +1 -1
- package/dist/manifests/entity-card.manifest.json +114 -0
- package/dist/manifests/feature-grid.manifest.json +1 -1
- package/dist/manifests/feature-row.manifest.json +1 -1
- package/dist/manifests/fieldset.manifest.json +1 -1
- package/dist/manifests/file-upload.manifest.json +1 -1
- package/dist/manifests/filter-bar.manifest.json +1 -1
- package/dist/manifests/filter-chips.manifest.json +1 -1
- package/dist/manifests/filter-panel.manifest.json +1 -1
- package/dist/manifests/flex.manifest.json +1 -1
- package/dist/manifests/form-field.manifest.json +1 -1
- package/dist/manifests/form-layout.manifest.json +1 -1
- package/dist/manifests/form.manifest.json +1 -1
- package/dist/manifests/grid.manifest.json +1 -1
- package/dist/manifests/heading.manifest.json +1 -1
- package/dist/manifests/hero.manifest.json +40 -8
- package/dist/manifests/input-group.manifest.json +1 -1
- package/dist/manifests/input.manifest.json +1 -1
- package/dist/manifests/label.manifest.json +1 -1
- package/dist/manifests/link-tabs.manifest.json +1 -1
- package/dist/manifests/link.manifest.json +1 -1
- package/dist/manifests/list.manifest.json +1 -1
- package/dist/manifests/load-more.manifest.json +88 -0
- package/dist/manifests/logo-cloud.manifest.json +1 -1
- package/dist/manifests/menu.manifest.json +1 -1
- package/dist/manifests/metric-card.manifest.json +1 -1
- package/dist/manifests/multi-select.manifest.json +1 -1
- package/dist/manifests/newsletter.manifest.json +1 -1
- package/dist/manifests/page-header.manifest.json +1 -1
- package/dist/manifests/pagination.manifest.json +1 -1
- package/dist/manifests/password-input.manifest.json +1 -1
- package/dist/manifests/popover.manifest.json +1 -1
- package/dist/manifests/process-steps.manifest.json +1 -1
- package/dist/manifests/progress.manifest.json +1 -1
- package/dist/manifests/prose.manifest.json +1 -1
- package/dist/manifests/radio.manifest.json +1 -1
- package/dist/manifests/range-slider.manifest.json +1 -1
- package/dist/manifests/search.manifest.json +1 -1
- package/dist/manifests/section-heading.manifest.json +1 -1
- package/dist/manifests/section.manifest.json +1 -1
- package/dist/manifests/segmented-control.manifest.json +1 -1
- package/dist/manifests/select-menu.manifest.json +2 -2
- package/dist/manifests/select.manifest.json +1 -1
- package/dist/manifests/separator.manifest.json +1 -1
- package/dist/manifests/site-footer.manifest.json +1 -1
- package/dist/manifests/site-header.manifest.json +1 -1
- package/dist/manifests/skeleton.manifest.json +1 -1
- package/dist/manifests/spinner.manifest.json +1 -1
- package/dist/manifests/stat-band.manifest.json +1 -1
- package/dist/manifests/stepper.manifest.json +69 -5
- package/dist/manifests/switch.manifest.json +1 -1
- package/dist/manifests/table-card.manifest.json +1 -1
- package/dist/manifests/table-of-contents.manifest.json +26 -5
- package/dist/manifests/table.manifest.json +1 -1
- package/dist/manifests/tabs.manifest.json +1 -1
- package/dist/manifests/testimonial.manifest.json +1 -1
- package/dist/manifests/text.manifest.json +1 -1
- package/dist/manifests/textarea.manifest.json +1 -1
- package/dist/manifests/theme-toggle.manifest.json +1 -1
- package/dist/manifests/time-picker.manifest.json +1 -1
- package/dist/manifests/timeline.manifest.json +1 -1
- package/dist/manifests/toast.manifest.json +1 -1
- package/dist/manifests/tombstone-card.manifest.json +97 -0
- package/dist/manifests/tooltip.manifest.json +1 -1
- package/dist/src/components/date-picker/DatePicker.js +1 -1
- package/dist/src/components/date-picker/DatePicker.js.map +1 -1
- package/dist/src/components/date-picker/DatePicker.mjs +1 -1
- package/dist/src/components/date-picker/DatePicker.mjs.map +1 -1
- package/dist/src/components/deal-card/DealCard.d.ts +72 -0
- package/dist/src/components/deal-card/DealCard.js +108 -0
- package/dist/src/components/deal-card/DealCard.js.map +1 -0
- package/dist/src/components/deal-card/DealCard.mjs +74 -0
- package/dist/src/components/deal-card/DealCard.mjs.map +1 -0
- package/dist/src/components/deal-card/index.d.ts +2 -0
- package/dist/src/components/deal-card/index.js +29 -0
- package/dist/src/components/deal-card/index.js.map +1 -0
- package/dist/src/components/deal-card/index.mjs +5 -0
- package/dist/src/components/deal-card/index.mjs.map +1 -0
- package/dist/src/components/document-card/DocumentCard.d.ts +42 -0
- package/dist/src/components/document-card/DocumentCard.js +84 -0
- package/dist/src/components/document-card/DocumentCard.js.map +1 -0
- package/dist/src/components/document-card/DocumentCard.mjs +50 -0
- package/dist/src/components/document-card/DocumentCard.mjs.map +1 -0
- package/dist/src/components/document-card/index.d.ts +2 -0
- package/dist/src/components/document-card/index.js +29 -0
- package/dist/src/components/document-card/index.js.map +1 -0
- package/dist/src/components/document-card/index.mjs +5 -0
- package/dist/src/components/document-card/index.mjs.map +1 -0
- package/dist/src/components/entity-card/EntityCard.d.ts +78 -0
- package/dist/src/components/entity-card/EntityCard.js +95 -0
- package/dist/src/components/entity-card/EntityCard.js.map +1 -0
- package/dist/src/components/entity-card/EntityCard.mjs +60 -0
- package/dist/src/components/entity-card/EntityCard.mjs.map +1 -0
- package/dist/src/components/entity-card/index.d.ts +2 -0
- package/dist/src/components/entity-card/index.js +31 -0
- package/dist/src/components/entity-card/index.js.map +1 -0
- package/dist/src/components/entity-card/index.mjs +6 -0
- package/dist/src/components/entity-card/index.mjs.map +1 -0
- package/dist/src/components/hero/Hero.d.ts +25 -13
- package/dist/src/components/hero/Hero.js +116 -12
- package/dist/src/components/hero/Hero.js.map +1 -1
- package/dist/src/components/hero/Hero.mjs +116 -12
- package/dist/src/components/hero/Hero.mjs.map +1 -1
- package/dist/src/components/load-more/LoadMore.d.ts +34 -0
- package/dist/src/components/load-more/LoadMore.js +55 -0
- package/dist/src/components/load-more/LoadMore.js.map +1 -0
- package/dist/src/components/load-more/LoadMore.mjs +21 -0
- package/dist/src/components/load-more/LoadMore.mjs.map +1 -0
- package/dist/src/components/load-more/index.d.ts +2 -0
- package/dist/src/components/load-more/index.js +29 -0
- package/dist/src/components/load-more/index.js.map +1 -0
- package/dist/src/components/load-more/index.mjs +5 -0
- package/dist/src/components/load-more/index.mjs.map +1 -0
- package/dist/src/components/range-slider/RangeSlider.js +6 -6
- package/dist/src/components/range-slider/RangeSlider.js.map +1 -1
- package/dist/src/components/range-slider/RangeSlider.mjs +6 -6
- package/dist/src/components/range-slider/RangeSlider.mjs.map +1 -1
- package/dist/src/components/select-menu/SelectMenu.js +2 -0
- package/dist/src/components/select-menu/SelectMenu.js.map +1 -1
- package/dist/src/components/select-menu/SelectMenu.mjs +2 -0
- package/dist/src/components/select-menu/SelectMenu.mjs.map +1 -1
- package/dist/src/components/separator/Separator.js +1 -1
- package/dist/src/components/separator/Separator.js.map +1 -1
- package/dist/src/components/separator/Separator.mjs +1 -1
- package/dist/src/components/separator/Separator.mjs.map +1 -1
- package/dist/src/components/stepper/Stepper.d.ts +35 -0
- package/dist/src/components/stepper/Stepper.js +118 -25
- package/dist/src/components/stepper/Stepper.js.map +1 -1
- package/dist/src/components/stepper/Stepper.mjs +118 -25
- package/dist/src/components/stepper/Stepper.mjs.map +1 -1
- package/dist/src/components/table-of-contents/TableOfContents.d.ts +10 -2
- package/dist/src/components/table-of-contents/TableOfContents.js +13 -0
- package/dist/src/components/table-of-contents/TableOfContents.js.map +1 -1
- package/dist/src/components/table-of-contents/TableOfContents.mjs +13 -0
- package/dist/src/components/table-of-contents/TableOfContents.mjs.map +1 -1
- package/dist/src/components/tabs/Tabs.js +43 -3
- package/dist/src/components/tabs/Tabs.js.map +1 -1
- package/dist/src/components/tabs/Tabs.mjs +43 -3
- package/dist/src/components/tabs/Tabs.mjs.map +1 -1
- package/dist/src/components/time-picker/TimePicker.js +1 -1
- package/dist/src/components/time-picker/TimePicker.js.map +1 -1
- package/dist/src/components/time-picker/TimePicker.mjs +1 -1
- package/dist/src/components/time-picker/TimePicker.mjs.map +1 -1
- package/dist/src/components/timeline/Timeline.js +2 -2
- package/dist/src/components/timeline/Timeline.js.map +1 -1
- package/dist/src/components/timeline/Timeline.mjs +2 -2
- package/dist/src/components/timeline/Timeline.mjs.map +1 -1
- package/dist/src/components/tombstone-card/TombstoneCard.d.ts +39 -0
- package/dist/src/components/tombstone-card/TombstoneCard.js +86 -0
- package/dist/src/components/tombstone-card/TombstoneCard.js.map +1 -0
- package/dist/src/components/tombstone-card/TombstoneCard.mjs +52 -0
- package/dist/src/components/tombstone-card/TombstoneCard.mjs.map +1 -0
- package/dist/src/components/tombstone-card/index.d.ts +2 -0
- package/dist/src/components/tombstone-card/index.js +29 -0
- package/dist/src/components/tombstone-card/index.js.map +1 -0
- package/dist/src/components/tombstone-card/index.mjs +5 -0
- package/dist/src/components/tombstone-card/index.mjs.map +1 -0
- package/dist/src/index.d.ts +5 -0
- package/dist/src/utils/modal-layer.js +3 -2
- package/dist/src/utils/modal-layer.js.map +1 -1
- package/dist/src/utils/modal-layer.mjs +3 -2
- package/dist/src/utils/modal-layer.mjs.map +1 -1
- package/dist/styles-full.css +1 -1
- package/dist/styles.css +1 -1
- package/package.json +4 -4
- package/src/components/date-picker/DatePicker.tsx +1 -1
- package/src/components/deal-card/DealCard.test.tsx +54 -0
- package/src/components/deal-card/DealCard.tsx +138 -0
- package/src/components/deal-card/index.ts +2 -0
- package/src/components/document-card/DocumentCard.test.tsx +41 -0
- package/src/components/document-card/DocumentCard.tsx +82 -0
- package/src/components/document-card/index.ts +2 -0
- package/src/components/entity-card/EntityCard.test.tsx +38 -0
- package/src/components/entity-card/EntityCard.tsx +133 -0
- package/src/components/entity-card/index.ts +2 -0
- package/src/components/hero/Hero.test.tsx +14 -0
- package/src/components/hero/Hero.tsx +111 -19
- package/src/components/load-more/LoadMore.test.tsx +28 -0
- package/src/components/load-more/LoadMore.tsx +53 -0
- package/src/components/load-more/index.ts +2 -0
- package/src/components/range-slider/RangeSlider.test.tsx +8 -0
- package/src/components/range-slider/RangeSlider.tsx +10 -6
- package/src/components/select-menu/SelectMenu.test.tsx +20 -10
- package/src/components/select-menu/SelectMenu.tsx +2 -0
- package/src/components/separator/Separator.test.tsx +9 -1
- package/src/components/separator/Separator.tsx +1 -1
- package/src/components/stepper/Stepper.test.tsx +19 -0
- package/src/components/stepper/Stepper.tsx +169 -37
- package/src/components/table-of-contents/TableOfContents.test.tsx +12 -1
- package/src/components/table-of-contents/TableOfContents.tsx +25 -1
- package/src/components/tabs/Tabs.test.tsx +12 -0
- package/src/components/tabs/Tabs.tsx +48 -4
- package/src/components/time-picker/TimePicker.tsx +1 -1
- package/src/components/timeline/Timeline.tsx +2 -2
- package/src/components/tombstone-card/TombstoneCard.test.tsx +26 -0
- package/src/components/tombstone-card/TombstoneCard.tsx +77 -0
- package/src/components/tombstone-card/index.ts +2 -0
- package/src/index.ts +5 -0
- package/src/manifests/accordion.manifest.json +1 -1
- package/src/manifests/alert.manifest.json +1 -1
- package/src/manifests/announcement-bar.manifest.json +1 -1
- package/src/manifests/app-shell.manifest.json +1 -1
- package/src/manifests/applied-filters.manifest.json +1 -1
- package/src/manifests/article-card.manifest.json +1 -1
- package/src/manifests/auth-layout.manifest.json +1 -1
- package/src/manifests/autocomplete.manifest.json +1 -1
- package/src/manifests/avatar.manifest.json +1 -1
- package/src/manifests/badge.manifest.json +1 -1
- package/src/manifests/block.manifest.json +1 -1
- package/src/manifests/breadcrumb.manifest.json +1 -1
- package/src/manifests/button-group.manifest.json +1 -1
- package/src/manifests/button.manifest.json +1 -1
- package/src/manifests/card.manifest.json +1 -1
- package/src/manifests/checkbox.manifest.json +1 -1
- package/src/manifests/comparison-table.manifest.json +1 -1
- package/src/manifests/confirm-dialog.manifest.json +1 -1
- package/src/manifests/contact-strip.manifest.json +1 -1
- package/src/manifests/container.manifest.json +1 -1
- package/src/manifests/cta-section.manifest.json +1 -1
- package/src/manifests/data-table.manifest.json +1 -1
- package/src/manifests/date-picker.manifest.json +1 -1
- package/src/manifests/date-range-picker.manifest.json +1 -1
- package/src/manifests/deal-card.manifest.json +158 -0
- package/src/manifests/dialog.manifest.json +1 -1
- package/src/manifests/document-card.manifest.json +108 -0
- package/src/manifests/drawer.manifest.json +1 -1
- package/src/manifests/empty-state.manifest.json +1 -1
- package/src/manifests/entity-card.manifest.json +114 -0
- package/src/manifests/feature-grid.manifest.json +1 -1
- package/src/manifests/feature-row.manifest.json +1 -1
- package/src/manifests/fieldset.manifest.json +1 -1
- package/src/manifests/file-upload.manifest.json +1 -1
- package/src/manifests/filter-bar.manifest.json +1 -1
- package/src/manifests/filter-chips.manifest.json +1 -1
- package/src/manifests/filter-panel.manifest.json +1 -1
- package/src/manifests/flex.manifest.json +1 -1
- package/src/manifests/form-field.manifest.json +1 -1
- package/src/manifests/form-layout.manifest.json +1 -1
- package/src/manifests/form.manifest.json +1 -1
- package/src/manifests/grid.manifest.json +1 -1
- package/src/manifests/heading.manifest.json +1 -1
- package/src/manifests/hero.manifest.json +40 -8
- package/src/manifests/input-group.manifest.json +1 -1
- package/src/manifests/input.manifest.json +1 -1
- package/src/manifests/label.manifest.json +1 -1
- package/src/manifests/link-tabs.manifest.json +1 -1
- package/src/manifests/link.manifest.json +1 -1
- package/src/manifests/list.manifest.json +1 -1
- package/src/manifests/load-more.manifest.json +88 -0
- package/src/manifests/logo-cloud.manifest.json +1 -1
- package/src/manifests/menu.manifest.json +1 -1
- package/src/manifests/metric-card.manifest.json +1 -1
- package/src/manifests/multi-select.manifest.json +1 -1
- package/src/manifests/newsletter.manifest.json +1 -1
- package/src/manifests/page-header.manifest.json +1 -1
- package/src/manifests/pagination.manifest.json +1 -1
- package/src/manifests/password-input.manifest.json +1 -1
- package/src/manifests/popover.manifest.json +1 -1
- package/src/manifests/process-steps.manifest.json +1 -1
- package/src/manifests/progress.manifest.json +1 -1
- package/src/manifests/prose.manifest.json +1 -1
- package/src/manifests/radio.manifest.json +1 -1
- package/src/manifests/range-slider.manifest.json +1 -1
- package/src/manifests/search.manifest.json +1 -1
- package/src/manifests/section-heading.manifest.json +1 -1
- package/src/manifests/section.manifest.json +1 -1
- package/src/manifests/segmented-control.manifest.json +1 -1
- package/src/manifests/select-menu.manifest.json +2 -2
- package/src/manifests/select.manifest.json +1 -1
- package/src/manifests/separator.manifest.json +1 -1
- package/src/manifests/site-footer.manifest.json +1 -1
- package/src/manifests/site-header.manifest.json +1 -1
- package/src/manifests/skeleton.manifest.json +1 -1
- package/src/manifests/spinner.manifest.json +1 -1
- package/src/manifests/stat-band.manifest.json +1 -1
- package/src/manifests/stepper.manifest.json +69 -5
- package/src/manifests/switch.manifest.json +1 -1
- package/src/manifests/table-card.manifest.json +1 -1
- package/src/manifests/table-of-contents.manifest.json +26 -5
- package/src/manifests/table.manifest.json +1 -1
- package/src/manifests/tabs.manifest.json +1 -1
- package/src/manifests/testimonial.manifest.json +1 -1
- package/src/manifests/text.manifest.json +1 -1
- package/src/manifests/textarea.manifest.json +1 -1
- package/src/manifests/theme-toggle.manifest.json +1 -1
- package/src/manifests/time-picker.manifest.json +1 -1
- package/src/manifests/timeline.manifest.json +1 -1
- package/src/manifests/toast.manifest.json +1 -1
- package/src/manifests/tombstone-card.manifest.json +97 -0
- package/src/manifests/tooltip.manifest.json +1 -1
- package/src/test/jest-axe.d.ts +6 -1
- package/src/utils/modal-layer.ts +3 -2
package/dist/index.js
CHANGED
|
@@ -68,6 +68,7 @@ __export(index_exports, {
|
|
|
68
68
|
DataTable: () => DataTable,
|
|
69
69
|
DatePicker: () => DatePicker,
|
|
70
70
|
DateRangePicker: () => DateRangePicker,
|
|
71
|
+
DealCard: () => DealCard,
|
|
71
72
|
Dialog: () => Dialog,
|
|
72
73
|
DialogBody: () => DialogBody,
|
|
73
74
|
DialogDescription: () => DialogDescription,
|
|
@@ -75,8 +76,10 @@ __export(index_exports, {
|
|
|
75
76
|
DialogHeader: () => DialogHeader,
|
|
76
77
|
DialogTitle: () => DialogTitle,
|
|
77
78
|
Divider: () => Divider,
|
|
79
|
+
DocumentCard: () => DocumentCard,
|
|
78
80
|
Drawer: () => Drawer,
|
|
79
81
|
EmptyState: () => EmptyState,
|
|
82
|
+
EntityCard: () => EntityCard,
|
|
80
83
|
FeatureGrid: () => FeatureGrid,
|
|
81
84
|
FeatureRow: () => FeatureRow,
|
|
82
85
|
Fieldset: () => Fieldset,
|
|
@@ -101,6 +104,7 @@ __export(index_exports, {
|
|
|
101
104
|
LinkTabs: () => LinkTabs,
|
|
102
105
|
List: () => List,
|
|
103
106
|
ListItem: () => ListItem,
|
|
107
|
+
LoadMore: () => LoadMore,
|
|
104
108
|
LogoCloud: () => LogoCloud,
|
|
105
109
|
Menu: () => Menu,
|
|
106
110
|
MenuContent: () => MenuContent,
|
|
@@ -118,6 +122,7 @@ __export(index_exports, {
|
|
|
118
122
|
PopoverContent: () => PopoverContent,
|
|
119
123
|
PopoverTrigger: () => PopoverTrigger,
|
|
120
124
|
ProcessSteps: () => ProcessSteps,
|
|
125
|
+
ProfileCard: () => ProfileCard,
|
|
121
126
|
Progress: () => Progress,
|
|
122
127
|
Prose: () => Prose,
|
|
123
128
|
Radio: () => Radio,
|
|
@@ -163,6 +168,7 @@ __export(index_exports, {
|
|
|
163
168
|
Timeline: () => Timeline,
|
|
164
169
|
ToastProvider: () => ToastProvider,
|
|
165
170
|
Toaster: () => Toaster,
|
|
171
|
+
TombstoneCard: () => TombstoneCard,
|
|
166
172
|
Tooltip: () => Tooltip,
|
|
167
173
|
alertVariants: () => alertVariants,
|
|
168
174
|
badgeVariants: () => badgeVariants,
|
|
@@ -243,8 +249,9 @@ var restoreScroll = null;
|
|
|
243
249
|
function useModalLayer(open) {
|
|
244
250
|
const id = React2.useRef(/* @__PURE__ */ Symbol("modal-layer"));
|
|
245
251
|
React2.useEffect(() => {
|
|
252
|
+
const layerId = id.current;
|
|
246
253
|
if (!open) return;
|
|
247
|
-
layers.push(
|
|
254
|
+
layers.push(layerId);
|
|
248
255
|
if (layers.length === 1) {
|
|
249
256
|
const previousOverflow = document.body.style.overflow;
|
|
250
257
|
document.body.style.overflow = "hidden";
|
|
@@ -253,7 +260,7 @@ function useModalLayer(open) {
|
|
|
253
260
|
};
|
|
254
261
|
}
|
|
255
262
|
return () => {
|
|
256
|
-
const index = layers.indexOf(
|
|
263
|
+
const index = layers.indexOf(layerId);
|
|
257
264
|
if (index >= 0) layers.splice(index, 1);
|
|
258
265
|
if (layers.length === 0) {
|
|
259
266
|
restoreScroll?.();
|
|
@@ -1586,6 +1593,7 @@ var SelectMenu = React17.forwardRef(function SelectMenu2({
|
|
|
1586
1593
|
{
|
|
1587
1594
|
ref: setTriggerRef,
|
|
1588
1595
|
type: "button",
|
|
1596
|
+
role: "combobox",
|
|
1589
1597
|
"aria-haspopup": "listbox",
|
|
1590
1598
|
"aria-expanded": open,
|
|
1591
1599
|
"aria-controls": open ? listboxId : void 0,
|
|
@@ -1614,6 +1622,7 @@ var SelectMenu = React17.forwardRef(function SelectMenu2({
|
|
|
1614
1622
|
ref: listRef,
|
|
1615
1623
|
id: listboxId,
|
|
1616
1624
|
role: "listbox",
|
|
1625
|
+
tabIndex: -1,
|
|
1617
1626
|
"aria-labelledby": labelId,
|
|
1618
1627
|
"aria-multiselectable": multiple || void 0,
|
|
1619
1628
|
style: {
|
|
@@ -2647,7 +2656,7 @@ var Separator = React32.forwardRef(
|
|
|
2647
2656
|
ref,
|
|
2648
2657
|
role: label ? "separator" : "none",
|
|
2649
2658
|
"aria-label": label,
|
|
2650
|
-
"aria-orientation": orientation === "vertical" ? "vertical" : void 0,
|
|
2659
|
+
"aria-orientation": label && orientation === "vertical" ? "vertical" : void 0,
|
|
2651
2660
|
className: cn(separatorVariants({ orientation }), className),
|
|
2652
2661
|
...props
|
|
2653
2662
|
}
|
|
@@ -2734,13 +2743,35 @@ var TabsContext = React35.createContext({
|
|
|
2734
2743
|
},
|
|
2735
2744
|
baseId: "",
|
|
2736
2745
|
variant: "default",
|
|
2737
|
-
size: "md"
|
|
2746
|
+
size: "md",
|
|
2747
|
+
panels: /* @__PURE__ */ new Set(),
|
|
2748
|
+
registerPanel: () => {
|
|
2749
|
+
},
|
|
2750
|
+
unregisterPanel: () => {
|
|
2751
|
+
}
|
|
2738
2752
|
});
|
|
2739
2753
|
var Tabs = React35.forwardRef(
|
|
2740
2754
|
({ value, defaultValue, onValueChange, variant = "default", size = "md", className, children }, ref) => {
|
|
2741
2755
|
const [internalValue, setInternalValue] = React35.useState(defaultValue ?? "");
|
|
2742
2756
|
const current = value ?? internalValue;
|
|
2743
2757
|
const baseId = React35.useId();
|
|
2758
|
+
const [panels, setPanels] = React35.useState(() => /* @__PURE__ */ new Set());
|
|
2759
|
+
const registerPanel = React35.useCallback((panelValue) => {
|
|
2760
|
+
setPanels((previous) => {
|
|
2761
|
+
if (previous.has(panelValue)) return previous;
|
|
2762
|
+
const next = new Set(previous);
|
|
2763
|
+
next.add(panelValue);
|
|
2764
|
+
return next;
|
|
2765
|
+
});
|
|
2766
|
+
}, []);
|
|
2767
|
+
const unregisterPanel = React35.useCallback((panelValue) => {
|
|
2768
|
+
setPanels((previous) => {
|
|
2769
|
+
if (!previous.has(panelValue)) return previous;
|
|
2770
|
+
const next = new Set(previous);
|
|
2771
|
+
next.delete(panelValue);
|
|
2772
|
+
return next;
|
|
2773
|
+
});
|
|
2774
|
+
}, []);
|
|
2744
2775
|
const setValue = React35.useCallback(
|
|
2745
2776
|
(next) => {
|
|
2746
2777
|
if (value === void 0) setInternalValue(next);
|
|
@@ -2748,7 +2779,20 @@ var Tabs = React35.forwardRef(
|
|
|
2748
2779
|
},
|
|
2749
2780
|
[value, onValueChange]
|
|
2750
2781
|
);
|
|
2751
|
-
|
|
2782
|
+
const contextValue = React35.useMemo(
|
|
2783
|
+
() => ({
|
|
2784
|
+
value: current,
|
|
2785
|
+
setValue,
|
|
2786
|
+
baseId,
|
|
2787
|
+
variant,
|
|
2788
|
+
size,
|
|
2789
|
+
panels,
|
|
2790
|
+
registerPanel,
|
|
2791
|
+
unregisterPanel
|
|
2792
|
+
}),
|
|
2793
|
+
[current, setValue, baseId, variant, size, panels, registerPanel, unregisterPanel]
|
|
2794
|
+
);
|
|
2795
|
+
return /* @__PURE__ */ (0, import_jsx_runtime33.jsx)("div", { ref, className, "data-value": current, "data-variant": variant, children: /* @__PURE__ */ (0, import_jsx_runtime33.jsx)(TabsContext.Provider, { value: contextValue, children }) });
|
|
2752
2796
|
}
|
|
2753
2797
|
);
|
|
2754
2798
|
Tabs.displayName = "Tabs";
|
|
@@ -2833,7 +2877,7 @@ var TabsTrigger = React35.forwardRef(
|
|
|
2833
2877
|
role: "tab",
|
|
2834
2878
|
id: `${ctx.baseId}-tab-${value}`,
|
|
2835
2879
|
"aria-selected": active,
|
|
2836
|
-
"aria-controls": `${ctx.baseId}-panel-${value}
|
|
2880
|
+
"aria-controls": ctx.panels.has(value) ? `${ctx.baseId}-panel-${value}` : void 0,
|
|
2837
2881
|
"data-state": active ? "active" : "inactive",
|
|
2838
2882
|
tabIndex: active ? 0 : -1,
|
|
2839
2883
|
onClick: () => ctx.setValue(value),
|
|
@@ -2874,7 +2918,12 @@ TabsTrigger.displayName = "TabsTrigger";
|
|
|
2874
2918
|
var TabsContent = React35.forwardRef(
|
|
2875
2919
|
({ value, className, ...props }, ref) => {
|
|
2876
2920
|
const ctx = React35.useContext(TabsContext);
|
|
2921
|
+
const { registerPanel, unregisterPanel } = ctx;
|
|
2877
2922
|
const active = ctx.value === value;
|
|
2923
|
+
React35.useEffect(() => {
|
|
2924
|
+
registerPanel(value);
|
|
2925
|
+
return () => unregisterPanel(value);
|
|
2926
|
+
}, [registerPanel, unregisterPanel, value]);
|
|
2878
2927
|
return /* @__PURE__ */ (0, import_jsx_runtime33.jsx)(
|
|
2879
2928
|
"div",
|
|
2880
2929
|
{
|
|
@@ -3150,6 +3199,7 @@ function TableOfContents({
|
|
|
3150
3199
|
ariaLabel,
|
|
3151
3200
|
labelClassName,
|
|
3152
3201
|
sticky = true,
|
|
3202
|
+
onNavigate,
|
|
3153
3203
|
className,
|
|
3154
3204
|
...props
|
|
3155
3205
|
}) {
|
|
@@ -3168,6 +3218,7 @@ function TableOfContents({
|
|
|
3168
3218
|
{
|
|
3169
3219
|
href: `#${heading.id}`,
|
|
3170
3220
|
"aria-current": active ? "location" : void 0,
|
|
3221
|
+
onClick: () => onNavigate?.(heading.id),
|
|
3171
3222
|
className: cn(
|
|
3172
3223
|
"-ml-px block border-l py-1 pl-3 no-underline transition-colors",
|
|
3173
3224
|
active ? "border-primary font-medium text-primary underline" : "border-transparent text-muted-foreground hover:border-border hover:text-foreground"
|
|
@@ -3199,6 +3250,17 @@ function useScrollSpy(ids, options) {
|
|
|
3199
3250
|
elements.forEach((element) => observer.observe(element));
|
|
3200
3251
|
return () => observer.disconnect();
|
|
3201
3252
|
}, [idKey, rootMargin]);
|
|
3253
|
+
React40.useEffect(() => {
|
|
3254
|
+
if (typeof window === "undefined") return;
|
|
3255
|
+
const ids2 = idKey.split("|").filter(Boolean);
|
|
3256
|
+
const syncFromHash = () => {
|
|
3257
|
+
const id = window.location.hash.replace(/^#/, "");
|
|
3258
|
+
if (id && ids2.includes(id)) setActiveId(id);
|
|
3259
|
+
};
|
|
3260
|
+
syncFromHash();
|
|
3261
|
+
window.addEventListener("hashchange", syncFromHash);
|
|
3262
|
+
return () => window.removeEventListener("hashchange", syncFromHash);
|
|
3263
|
+
}, [idKey]);
|
|
3202
3264
|
return activeId;
|
|
3203
3265
|
}
|
|
3204
3266
|
|
|
@@ -4554,7 +4616,7 @@ var DatePicker = React58.forwardRef(function DatePicker2({ value, defaultValue,
|
|
|
4554
4616
|
type: "button",
|
|
4555
4617
|
onClick: () => commit(""),
|
|
4556
4618
|
"aria-label": clearLabel,
|
|
4557
|
-
className: "absolute right-
|
|
4619
|
+
className: "absolute right-1.5 inline-flex h-6 w-6 items-center justify-center rounded text-muted-foreground hover:text-foreground focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring",
|
|
4558
4620
|
children: "\u2715"
|
|
4559
4621
|
}
|
|
4560
4622
|
)
|
|
@@ -4592,7 +4654,7 @@ var TimePicker = React59.forwardRef(function TimePicker2({ value, defaultValue,
|
|
|
4592
4654
|
type: "button",
|
|
4593
4655
|
onClick: () => commit(""),
|
|
4594
4656
|
"aria-label": clearLabel,
|
|
4595
|
-
className: "absolute right-
|
|
4657
|
+
className: "absolute right-1.5 inline-flex h-6 w-6 items-center justify-center rounded text-muted-foreground hover:text-foreground focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring",
|
|
4596
4658
|
children: "\u2715"
|
|
4597
4659
|
}
|
|
4598
4660
|
)
|
|
@@ -4602,52 +4664,145 @@ var TimePicker = React59.forwardRef(function TimePicker2({ value, defaultValue,
|
|
|
4602
4664
|
// src/components/stepper/Stepper.tsx
|
|
4603
4665
|
var React60 = __toESM(require("react"));
|
|
4604
4666
|
var import_jsx_runtime59 = require("react/jsx-runtime");
|
|
4605
|
-
var Stepper = React60.forwardRef(function Stepper2({
|
|
4667
|
+
var Stepper = React60.forwardRef(function Stepper2({
|
|
4668
|
+
steps,
|
|
4669
|
+
current,
|
|
4670
|
+
orientation = "horizontal",
|
|
4671
|
+
variant = "numbered",
|
|
4672
|
+
size = "md",
|
|
4673
|
+
labelPlacement = "inline",
|
|
4674
|
+
alignTitles = "center",
|
|
4675
|
+
onStepClick,
|
|
4676
|
+
className,
|
|
4677
|
+
...props
|
|
4678
|
+
}, ref) {
|
|
4679
|
+
const vertical = orientation === "vertical";
|
|
4680
|
+
const interactive = Boolean(onStepClick);
|
|
4681
|
+
const markerSizeClass = size === "sm" ? "h-6 w-6 text-[11px]" : "h-7 w-7 text-xs";
|
|
4682
|
+
const dotSizeClass = size === "sm" ? "h-2 w-2" : "h-2.5 w-2.5";
|
|
4683
|
+
const labelSizeClass = size === "sm" ? "text-xs" : "text-sm";
|
|
4684
|
+
const descriptionSizeClass = size === "sm" ? "text-[11px]" : "text-xs";
|
|
4685
|
+
const gapClass = size === "sm" ? "gap-1.5" : "gap-2";
|
|
4686
|
+
const verticalTitlePad = size === "sm" ? "pt-0.5" : "pt-1";
|
|
4687
|
+
const connectorTop = variant === "dots" ? size === "sm" ? "mt-1" : "mt-[5px]" : size === "sm" ? "mt-3" : "mt-3.5";
|
|
4688
|
+
const focusClass = "rounded-md focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 focus-visible:ring-offset-background";
|
|
4606
4689
|
return /* @__PURE__ */ (0, import_jsx_runtime59.jsx)(
|
|
4607
4690
|
"ol",
|
|
4608
4691
|
{
|
|
4609
4692
|
ref,
|
|
4610
4693
|
className: cn(
|
|
4611
|
-
"flex gap-4",
|
|
4612
|
-
orientation === "vertical" ? "flex-col" : "flex-wrap items-start",
|
|
4694
|
+
vertical ? "flex flex-col" : "flex flex-wrap items-start gap-4",
|
|
4613
4695
|
className
|
|
4614
4696
|
),
|
|
4615
4697
|
...props,
|
|
4616
4698
|
children: steps.map((step, index) => {
|
|
4617
4699
|
const state = index < current ? "complete" : index === current ? "current" : "upcoming";
|
|
4618
|
-
const
|
|
4619
|
-
const
|
|
4700
|
+
const isLast = index === steps.length - 1;
|
|
4701
|
+
const titleCentered = alignTitles === "center" && !step.description;
|
|
4702
|
+
const below = !vertical && labelPlacement === "below";
|
|
4703
|
+
const marker = /* @__PURE__ */ (0, import_jsx_runtime59.jsx)(
|
|
4704
|
+
"span",
|
|
4705
|
+
{
|
|
4706
|
+
"aria-hidden": "true",
|
|
4707
|
+
className: cn(
|
|
4708
|
+
"flex shrink-0 items-center justify-center",
|
|
4709
|
+
variant === "dots" ? cn(
|
|
4710
|
+
"rounded-full",
|
|
4711
|
+
dotSizeClass,
|
|
4712
|
+
state === "upcoming" ? "bg-border" : "bg-primary",
|
|
4713
|
+
state === "current" && "ring-2 ring-primary/30 ring-offset-2 ring-offset-background"
|
|
4714
|
+
) : cn(
|
|
4715
|
+
"rounded-full border font-medium",
|
|
4716
|
+
markerSizeClass,
|
|
4717
|
+
state === "complete" && "border-primary bg-primary text-primary-foreground",
|
|
4718
|
+
state === "current" && "border-primary text-primary",
|
|
4719
|
+
state === "upcoming" && "border-border text-muted-foreground"
|
|
4720
|
+
)
|
|
4721
|
+
),
|
|
4722
|
+
children: variant === "numbered" ? state === "complete" ? "\u2713" : index + 1 : null
|
|
4723
|
+
}
|
|
4724
|
+
);
|
|
4725
|
+
const label = /* @__PURE__ */ (0, import_jsx_runtime59.jsxs)("span", { className: "min-w-0", children: [
|
|
4620
4726
|
/* @__PURE__ */ (0, import_jsx_runtime59.jsx)(
|
|
4621
4727
|
"span",
|
|
4622
4728
|
{
|
|
4623
|
-
"aria-hidden": "true",
|
|
4624
4729
|
className: cn(
|
|
4625
|
-
"
|
|
4626
|
-
|
|
4627
|
-
|
|
4628
|
-
state === "upcoming"
|
|
4730
|
+
"block leading-5",
|
|
4731
|
+
labelSizeClass,
|
|
4732
|
+
below && "text-center",
|
|
4733
|
+
state === "upcoming" ? "text-muted-foreground" : "font-medium"
|
|
4629
4734
|
),
|
|
4630
|
-
children:
|
|
4735
|
+
children: step.label
|
|
4631
4736
|
}
|
|
4632
4737
|
),
|
|
4633
|
-
/* @__PURE__ */ (0, import_jsx_runtime59.
|
|
4634
|
-
|
|
4635
|
-
|
|
4636
|
-
|
|
4637
|
-
|
|
4738
|
+
step.description && /* @__PURE__ */ (0, import_jsx_runtime59.jsx)(
|
|
4739
|
+
"span",
|
|
4740
|
+
{
|
|
4741
|
+
className: cn(
|
|
4742
|
+
"mt-0.5 block leading-4 text-muted-foreground",
|
|
4743
|
+
descriptionSizeClass,
|
|
4744
|
+
below && "text-center"
|
|
4745
|
+
),
|
|
4746
|
+
children: step.description
|
|
4747
|
+
}
|
|
4748
|
+
),
|
|
4749
|
+
/* @__PURE__ */ (0, import_jsx_runtime59.jsx)("span", { className: "sr-only", children: state === "complete" ? " (completed)" : state === "current" ? " (current step)" : " (upcoming)" })
|
|
4638
4750
|
] });
|
|
4751
|
+
const renderRow = (children, rowClassName) => interactive ? /* @__PURE__ */ (0, import_jsx_runtime59.jsx)(
|
|
4752
|
+
"button",
|
|
4753
|
+
{
|
|
4754
|
+
type: "button",
|
|
4755
|
+
onClick: () => onStepClick?.(index),
|
|
4756
|
+
"aria-current": state === "current" ? "step" : void 0,
|
|
4757
|
+
className: cn(rowClassName, focusClass),
|
|
4758
|
+
children
|
|
4759
|
+
}
|
|
4760
|
+
) : /* @__PURE__ */ (0, import_jsx_runtime59.jsx)("div", { "aria-current": state === "current" ? "step" : void 0, className: rowClassName, children });
|
|
4761
|
+
if (vertical) {
|
|
4762
|
+
return /* @__PURE__ */ (0, import_jsx_runtime59.jsx)("li", { className: "flex", children: renderRow(
|
|
4763
|
+
/* @__PURE__ */ (0, import_jsx_runtime59.jsxs)(import_jsx_runtime59.Fragment, { children: [
|
|
4764
|
+
/* @__PURE__ */ (0, import_jsx_runtime59.jsxs)("div", { className: "flex flex-col items-center", children: [
|
|
4765
|
+
marker,
|
|
4766
|
+
!isLast && /* @__PURE__ */ (0, import_jsx_runtime59.jsx)("span", { "aria-hidden": "true", className: "my-1 w-px flex-1 rounded-full bg-border" })
|
|
4767
|
+
] }),
|
|
4768
|
+
/* @__PURE__ */ (0, import_jsx_runtime59.jsx)("div", { className: cn("min-w-0 pb-6", titleCentered && verticalTitlePad), children: label })
|
|
4769
|
+
] }),
|
|
4770
|
+
"flex w-full items-stretch gap-3 text-left"
|
|
4771
|
+
) }, step.label);
|
|
4772
|
+
}
|
|
4773
|
+
if (below) {
|
|
4774
|
+
return /* @__PURE__ */ (0, import_jsx_runtime59.jsxs)("li", { className: "flex min-w-0 flex-1 items-start gap-2", children: [
|
|
4775
|
+
renderRow(
|
|
4776
|
+
/* @__PURE__ */ (0, import_jsx_runtime59.jsxs)(import_jsx_runtime59.Fragment, { children: [
|
|
4777
|
+
marker,
|
|
4778
|
+
label
|
|
4779
|
+
] }),
|
|
4780
|
+
"flex min-w-0 flex-1 flex-col items-center gap-2 text-center"
|
|
4781
|
+
),
|
|
4782
|
+
!isLast && /* @__PURE__ */ (0, import_jsx_runtime59.jsx)(
|
|
4783
|
+
"span",
|
|
4784
|
+
{
|
|
4785
|
+
"aria-hidden": "true",
|
|
4786
|
+
className: cn("h-px min-w-4 flex-1 bg-border", connectorTop)
|
|
4787
|
+
}
|
|
4788
|
+
)
|
|
4789
|
+
] }, step.label);
|
|
4790
|
+
}
|
|
4639
4791
|
return /* @__PURE__ */ (0, import_jsx_runtime59.jsxs)("li", { className: "flex min-w-0 items-start gap-2", children: [
|
|
4640
|
-
|
|
4641
|
-
|
|
4792
|
+
renderRow(
|
|
4793
|
+
/* @__PURE__ */ (0, import_jsx_runtime59.jsxs)(import_jsx_runtime59.Fragment, { children: [
|
|
4794
|
+
marker,
|
|
4795
|
+
label
|
|
4796
|
+
] }),
|
|
4797
|
+
cn("flex min-w-0 text-left", gapClass, titleCentered ? "items-center" : "items-start")
|
|
4798
|
+
),
|
|
4799
|
+
!isLast && /* @__PURE__ */ (0, import_jsx_runtime59.jsx)(
|
|
4800
|
+
"span",
|
|
4642
4801
|
{
|
|
4643
|
-
|
|
4644
|
-
|
|
4645
|
-
"aria-current": state === "current" ? "step" : void 0,
|
|
4646
|
-
className: "flex items-start gap-2 rounded-md text-left focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring",
|
|
4647
|
-
children: content
|
|
4802
|
+
"aria-hidden": "true",
|
|
4803
|
+
className: cn("h-px w-6 shrink-0 bg-border sm:w-8", connectorTop)
|
|
4648
4804
|
}
|
|
4649
|
-
)
|
|
4650
|
-
orientation === "horizontal" && index < steps.length - 1 && /* @__PURE__ */ (0, import_jsx_runtime59.jsx)("span", { "aria-hidden": "true", className: "mt-3.5 hidden h-px w-8 bg-border sm:block" })
|
|
4805
|
+
)
|
|
4651
4806
|
] }, step.label);
|
|
4652
4807
|
})
|
|
4653
4808
|
}
|
|
@@ -4788,9 +4943,9 @@ var Timeline = React62.forwardRef(function Timeline2({ items, className, ...prop
|
|
|
4788
4943
|
),
|
|
4789
4944
|
index < items.length - 1 && /* @__PURE__ */ (0, import_jsx_runtime61.jsx)("span", { "aria-hidden": "true", className: "mt-1 w-px flex-1 bg-border" })
|
|
4790
4945
|
] }),
|
|
4791
|
-
/* @__PURE__ */ (0, import_jsx_runtime61.jsxs)("div", { className:
|
|
4946
|
+
/* @__PURE__ */ (0, import_jsx_runtime61.jsxs)("div", { className: "min-w-0 pb-1", children: [
|
|
4792
4947
|
item.period && /* @__PURE__ */ (0, import_jsx_runtime61.jsx)("p", { className: "text-xs font-medium uppercase tracking-wide text-muted-foreground", children: item.period }),
|
|
4793
|
-
/* @__PURE__ */ (0, import_jsx_runtime61.jsx)("p", { className: "text-sm font-semibold", children: item.title }),
|
|
4948
|
+
/* @__PURE__ */ (0, import_jsx_runtime61.jsx)("p", { className: cn("text-sm font-semibold", item.muted && "text-muted-foreground"), children: item.title }),
|
|
4794
4949
|
item.description && /* @__PURE__ */ (0, import_jsx_runtime61.jsx)("p", { className: "mt-1 text-sm text-muted-foreground", children: item.description }),
|
|
4795
4950
|
item.icon && /* @__PURE__ */ (0, import_jsx_runtime61.jsx)("div", { className: "mt-1 text-muted-foreground [&_svg]:size-4", children: item.icon })
|
|
4796
4951
|
] })
|
|
@@ -5102,8 +5257,8 @@ var Section = React67.forwardRef(function Section2({
|
|
|
5102
5257
|
var React68 = __toESM(require("react"));
|
|
5103
5258
|
var import_jsx_runtime67 = require("react/jsx-runtime");
|
|
5104
5259
|
var titleSizes = {
|
|
5105
|
-
md: "text-
|
|
5106
|
-
lg: "text-4xl sm:text-5xl
|
|
5260
|
+
md: "text-3xl sm:text-4xl md:text-5xl",
|
|
5261
|
+
lg: "text-4xl sm:text-5xl md:text-6xl lg:leading-[1.05]"
|
|
5107
5262
|
};
|
|
5108
5263
|
var Hero = React68.forwardRef(function Hero2({
|
|
5109
5264
|
title,
|
|
@@ -5122,6 +5277,7 @@ var Hero = React68.forwardRef(function Hero2({
|
|
|
5122
5277
|
descriptionClassName,
|
|
5123
5278
|
eyebrowClassName,
|
|
5124
5279
|
badgeClassName,
|
|
5280
|
+
mediaClassName,
|
|
5125
5281
|
className,
|
|
5126
5282
|
...props
|
|
5127
5283
|
}, ref) {
|
|
@@ -5129,28 +5285,131 @@ var Hero = React68.forwardRef(function Hero2({
|
|
|
5129
5285
|
const layout = variant ?? (media ? "split" : "centered");
|
|
5130
5286
|
const Heading2 = `h${level}`;
|
|
5131
5287
|
const centered = layout === "centered" || align === "center";
|
|
5132
|
-
const
|
|
5133
|
-
|
|
5134
|
-
|
|
5135
|
-
|
|
5136
|
-
|
|
5137
|
-
|
|
5138
|
-
|
|
5288
|
+
const overlay = layout === "overlay";
|
|
5289
|
+
const copy = /* @__PURE__ */ (0, import_jsx_runtime67.jsxs)(
|
|
5290
|
+
"div",
|
|
5291
|
+
{
|
|
5292
|
+
className: cn(
|
|
5293
|
+
"min-w-0",
|
|
5294
|
+
centered && "mx-auto flex max-w-3xl flex-col items-center text-center",
|
|
5295
|
+
overlay && "max-w-2xl"
|
|
5296
|
+
),
|
|
5297
|
+
children: [
|
|
5298
|
+
badge && /* @__PURE__ */ (0, import_jsx_runtime67.jsx)(
|
|
5299
|
+
"div",
|
|
5300
|
+
{
|
|
5301
|
+
className: cn(
|
|
5302
|
+
"mb-5 inline-flex rounded-full border px-3 py-1 text-xs font-medium",
|
|
5303
|
+
overlay ? "border-background/30 bg-background/10 text-background" : "border-primary/30 bg-primary/10 text-primary",
|
|
5304
|
+
badgeClassName
|
|
5305
|
+
),
|
|
5306
|
+
children: badge
|
|
5307
|
+
}
|
|
5308
|
+
),
|
|
5309
|
+
eyebrow && /* @__PURE__ */ (0, import_jsx_runtime67.jsx)(
|
|
5310
|
+
"p",
|
|
5311
|
+
{
|
|
5312
|
+
className: cn(
|
|
5313
|
+
"mb-3 text-xs font-semibold uppercase tracking-widest",
|
|
5314
|
+
overlay ? "text-background/90" : "text-primary",
|
|
5315
|
+
eyebrowClassName
|
|
5316
|
+
),
|
|
5317
|
+
children: eyebrow
|
|
5318
|
+
}
|
|
5319
|
+
),
|
|
5320
|
+
/* @__PURE__ */ (0, import_jsx_runtime67.jsx)(
|
|
5321
|
+
Heading2,
|
|
5322
|
+
{
|
|
5323
|
+
className: cn(
|
|
5324
|
+
"font-semibold tracking-tight text-balance",
|
|
5325
|
+
titleSizes[size],
|
|
5326
|
+
overlay && "text-background",
|
|
5327
|
+
titleClassName
|
|
5328
|
+
),
|
|
5329
|
+
children: title
|
|
5330
|
+
}
|
|
5331
|
+
),
|
|
5332
|
+
description && /* @__PURE__ */ (0, import_jsx_runtime67.jsx)(
|
|
5333
|
+
"p",
|
|
5334
|
+
{
|
|
5335
|
+
className: cn(
|
|
5336
|
+
"mt-5 text-base leading-relaxed sm:text-lg",
|
|
5337
|
+
overlay ? "text-background/80" : "text-muted-foreground",
|
|
5338
|
+
centered ? "max-w-2xl" : "max-w-xl",
|
|
5339
|
+
descriptionClassName
|
|
5340
|
+
),
|
|
5341
|
+
children: description
|
|
5342
|
+
}
|
|
5343
|
+
),
|
|
5344
|
+
actions && /* @__PURE__ */ (0, import_jsx_runtime67.jsx)(
|
|
5345
|
+
"div",
|
|
5346
|
+
{
|
|
5347
|
+
className: cn(
|
|
5348
|
+
"mt-8 flex flex-wrap items-center gap-3",
|
|
5349
|
+
centered && "justify-center"
|
|
5350
|
+
),
|
|
5351
|
+
children: actions
|
|
5352
|
+
}
|
|
5353
|
+
)
|
|
5354
|
+
]
|
|
5355
|
+
}
|
|
5356
|
+
);
|
|
5357
|
+
if (overlay) {
|
|
5358
|
+
return /* @__PURE__ */ (0, import_jsx_runtime67.jsxs)(
|
|
5359
|
+
Tag,
|
|
5360
|
+
{
|
|
5361
|
+
ref,
|
|
5362
|
+
className: cn(
|
|
5363
|
+
"relative isolate flex min-h-[22rem] w-full items-center overflow-hidden rounded-lg py-12 sm:min-h-[26rem] sm:py-16 lg:min-h-[32rem] lg:py-20",
|
|
5364
|
+
className
|
|
5365
|
+
),
|
|
5366
|
+
...props,
|
|
5367
|
+
children: [
|
|
5368
|
+
media && /* @__PURE__ */ (0, import_jsx_runtime67.jsx)(
|
|
5369
|
+
"div",
|
|
5370
|
+
{
|
|
5371
|
+
className: cn(
|
|
5372
|
+
"absolute inset-0 -z-20 [&>*]:h-full [&>*]:w-full [&>*]:object-cover",
|
|
5373
|
+
mediaClassName
|
|
5374
|
+
),
|
|
5375
|
+
children: media
|
|
5376
|
+
}
|
|
5377
|
+
),
|
|
5378
|
+
/* @__PURE__ */ (0, import_jsx_runtime67.jsx)("div", { "aria-hidden": "true", className: "absolute inset-0 -z-10 bg-foreground/60" }),
|
|
5379
|
+
/* @__PURE__ */ (0, import_jsx_runtime67.jsx)("div", { className: "relative w-full px-4 sm:px-6 lg:px-10", children: copy })
|
|
5380
|
+
]
|
|
5381
|
+
}
|
|
5382
|
+
);
|
|
5383
|
+
}
|
|
5139
5384
|
if (layout === "centered") {
|
|
5140
5385
|
return /* @__PURE__ */ (0, import_jsx_runtime67.jsxs)(Tag, { ref, className: cn("w-full", className), ...props, children: [
|
|
5141
5386
|
copy,
|
|
5142
|
-
media && /* @__PURE__ */ (0, import_jsx_runtime67.jsx)("div", { className: "mt-12", children: media })
|
|
5387
|
+
media && /* @__PURE__ */ (0, import_jsx_runtime67.jsx)("div", { className: cn("mt-12 min-w-0", mediaClassName), children: media })
|
|
5143
5388
|
] });
|
|
5144
5389
|
}
|
|
5390
|
+
if (layout === "stacked") {
|
|
5391
|
+
return /* @__PURE__ */ (0, import_jsx_runtime67.jsxs)(
|
|
5392
|
+
Tag,
|
|
5393
|
+
{
|
|
5394
|
+
ref,
|
|
5395
|
+
className: cn("flex w-full flex-col gap-10 lg:gap-14", className),
|
|
5396
|
+
...props,
|
|
5397
|
+
children: [
|
|
5398
|
+
copy,
|
|
5399
|
+
media && /* @__PURE__ */ (0, import_jsx_runtime67.jsx)("div", { className: cn("min-w-0 w-full", mediaClassName), children: media })
|
|
5400
|
+
]
|
|
5401
|
+
}
|
|
5402
|
+
);
|
|
5403
|
+
}
|
|
5145
5404
|
return /* @__PURE__ */ (0, import_jsx_runtime67.jsxs)(
|
|
5146
5405
|
Tag,
|
|
5147
5406
|
{
|
|
5148
5407
|
ref,
|
|
5149
|
-
className: cn("grid w-full items-center gap-10 lg:grid-cols-2 lg:gap-16", className),
|
|
5408
|
+
className: cn("grid w-full items-center gap-10 lg:grid-cols-2 lg:gap-16 xl:gap-20", className),
|
|
5150
5409
|
...props,
|
|
5151
5410
|
children: [
|
|
5152
5411
|
/* @__PURE__ */ (0, import_jsx_runtime67.jsx)("div", { className: cn(mediaPosition === "left" && "lg:order-2"), children: copy }),
|
|
5153
|
-
media && /* @__PURE__ */ (0, import_jsx_runtime67.jsx)("div", { className: cn("min-w-0", mediaPosition === "left" && "lg:order-1"), children: media })
|
|
5412
|
+
media && /* @__PURE__ */ (0, import_jsx_runtime67.jsx)("div", { className: cn("min-w-0", mediaPosition === "left" && "lg:order-1", mediaClassName), children: media })
|
|
5154
5413
|
]
|
|
5155
5414
|
}
|
|
5156
5415
|
);
|
|
@@ -5715,15 +5974,243 @@ var AnnouncementBar = React80.forwardRef(
|
|
|
5715
5974
|
}
|
|
5716
5975
|
);
|
|
5717
5976
|
|
|
5718
|
-
// src/components/
|
|
5977
|
+
// src/components/deal-card/DealCard.tsx
|
|
5719
5978
|
var React81 = __toESM(require("react"));
|
|
5720
5979
|
var import_jsx_runtime80 = require("react/jsx-runtime");
|
|
5980
|
+
var statusConfig = {
|
|
5981
|
+
available: { label: "Available", variant: "success" },
|
|
5982
|
+
"under-nda": { label: "Under NDA", variant: "info" },
|
|
5983
|
+
closed: { label: "Closed", variant: "secondary" },
|
|
5984
|
+
draft: { label: "Draft", variant: "outline" }
|
|
5985
|
+
};
|
|
5986
|
+
var DealCard = React81.forwardRef(function DealCard2({
|
|
5987
|
+
title,
|
|
5988
|
+
sector,
|
|
5989
|
+
location,
|
|
5990
|
+
description,
|
|
5991
|
+
metrics,
|
|
5992
|
+
status = "available",
|
|
5993
|
+
ndaAvailable,
|
|
5994
|
+
cimAvailable,
|
|
5995
|
+
href,
|
|
5996
|
+
linkComponent,
|
|
5997
|
+
saved = false,
|
|
5998
|
+
onSave,
|
|
5999
|
+
saveLabel = "Save",
|
|
6000
|
+
onRequestAccess,
|
|
6001
|
+
requestLabel = "Request access",
|
|
6002
|
+
className,
|
|
6003
|
+
...props
|
|
6004
|
+
}, ref) {
|
|
6005
|
+
const Link3 = linkComponent ?? "a";
|
|
6006
|
+
const statusInfo = statusConfig[status];
|
|
6007
|
+
return /* @__PURE__ */ (0, import_jsx_runtime80.jsxs)(Card, { ref, className: cn("flex h-full flex-col overflow-hidden", className), ...props, children: [
|
|
6008
|
+
/* @__PURE__ */ (0, import_jsx_runtime80.jsxs)(CardHeader, { className: "gap-2 p-5 pb-3", children: [
|
|
6009
|
+
/* @__PURE__ */ (0, import_jsx_runtime80.jsxs)("div", { className: "flex items-start justify-between gap-2", children: [
|
|
6010
|
+
/* @__PURE__ */ (0, import_jsx_runtime80.jsx)("p", { className: "text-xs font-semibold uppercase tracking-widest text-primary", children: sector }),
|
|
6011
|
+
/* @__PURE__ */ (0, import_jsx_runtime80.jsx)(Badge, { variant: statusInfo.variant, children: statusInfo.label })
|
|
6012
|
+
] }),
|
|
6013
|
+
/* @__PURE__ */ (0, import_jsx_runtime80.jsx)("h3", { className: "text-lg font-semibold leading-snug tracking-tight", children: href ? /* @__PURE__ */ (0, import_jsx_runtime80.jsx)(Link3, { href, className: "rounded-sm hover:text-primary focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring", children: title }) : title }),
|
|
6014
|
+
location && /* @__PURE__ */ (0, import_jsx_runtime80.jsx)("p", { className: "text-xs text-muted-foreground", children: location })
|
|
6015
|
+
] }),
|
|
6016
|
+
/* @__PURE__ */ (0, import_jsx_runtime80.jsxs)(CardContent, { className: "flex-1 px-5 pb-3", children: [
|
|
6017
|
+
description && /* @__PURE__ */ (0, import_jsx_runtime80.jsx)("p", { className: "line-clamp-2 text-sm leading-relaxed text-muted-foreground", children: description }),
|
|
6018
|
+
/* @__PURE__ */ (0, import_jsx_runtime80.jsx)("dl", { className: "mt-4 grid grid-cols-3 gap-3", children: metrics.map((metric) => /* @__PURE__ */ (0, import_jsx_runtime80.jsxs)("div", { className: "min-w-0", children: [
|
|
6019
|
+
/* @__PURE__ */ (0, import_jsx_runtime80.jsx)("dt", { className: "text-xs text-muted-foreground", children: metric.label }),
|
|
6020
|
+
/* @__PURE__ */ (0, import_jsx_runtime80.jsx)("dd", { className: "mt-0.5 truncate text-sm font-semibold tabular-nums", children: metric.value })
|
|
6021
|
+
] }, metric.label)) }),
|
|
6022
|
+
(ndaAvailable || cimAvailable) && /* @__PURE__ */ (0, import_jsx_runtime80.jsxs)("div", { className: "mt-4 flex flex-wrap gap-1.5", children: [
|
|
6023
|
+
ndaAvailable && /* @__PURE__ */ (0, import_jsx_runtime80.jsx)(Badge, { variant: "info", children: "NDA available" }),
|
|
6024
|
+
cimAvailable && /* @__PURE__ */ (0, import_jsx_runtime80.jsx)(Badge, { variant: "secondary", children: "CIM available" })
|
|
6025
|
+
] })
|
|
6026
|
+
] }),
|
|
6027
|
+
/* @__PURE__ */ (0, import_jsx_runtime80.jsxs)(CardFooter, { className: "flex flex-wrap items-center gap-2 border-t border-border px-5 py-3", children: [
|
|
6028
|
+
onRequestAccess && /* @__PURE__ */ (0, import_jsx_runtime80.jsx)(Button, { type: "button", size: "sm", onClick: onRequestAccess, children: requestLabel }),
|
|
6029
|
+
onSave && /* @__PURE__ */ (0, import_jsx_runtime80.jsx)(
|
|
6030
|
+
Button,
|
|
6031
|
+
{
|
|
6032
|
+
type: "button",
|
|
6033
|
+
size: "sm",
|
|
6034
|
+
variant: "ghost",
|
|
6035
|
+
"aria-pressed": saved,
|
|
6036
|
+
onClick: onSave,
|
|
6037
|
+
className: "ml-auto",
|
|
6038
|
+
children: saved ? "Saved" : saveLabel
|
|
6039
|
+
}
|
|
6040
|
+
)
|
|
6041
|
+
] })
|
|
6042
|
+
] });
|
|
6043
|
+
});
|
|
6044
|
+
|
|
6045
|
+
// src/components/entity-card/EntityCard.tsx
|
|
6046
|
+
var React82 = __toESM(require("react"));
|
|
6047
|
+
var import_jsx_runtime81 = require("react/jsx-runtime");
|
|
6048
|
+
function initials(name) {
|
|
6049
|
+
return name.split(/\s+/).filter(Boolean).slice(0, 2).map((part) => part[0]?.toUpperCase() ?? "").join("");
|
|
6050
|
+
}
|
|
6051
|
+
var EntityCard = React82.forwardRef(function EntityCard2({
|
|
6052
|
+
name,
|
|
6053
|
+
entityType,
|
|
6054
|
+
location,
|
|
6055
|
+
description,
|
|
6056
|
+
logo,
|
|
6057
|
+
stats,
|
|
6058
|
+
tags,
|
|
6059
|
+
href,
|
|
6060
|
+
linkComponent,
|
|
6061
|
+
actions,
|
|
6062
|
+
className,
|
|
6063
|
+
...props
|
|
6064
|
+
}, ref) {
|
|
6065
|
+
const Link3 = linkComponent ?? "a";
|
|
6066
|
+
return /* @__PURE__ */ (0, import_jsx_runtime81.jsxs)(Card, { ref, className: cn("flex h-full flex-col", className), ...props, children: [
|
|
6067
|
+
/* @__PURE__ */ (0, import_jsx_runtime81.jsxs)(CardHeader, { className: "flex-row items-start gap-3 p-5 pb-3", children: [
|
|
6068
|
+
/* @__PURE__ */ (0, import_jsx_runtime81.jsx)("div", { className: "shrink-0", children: logo ?? /* @__PURE__ */ (0, import_jsx_runtime81.jsx)(Avatar, { children: /* @__PURE__ */ (0, import_jsx_runtime81.jsx)(AvatarFallback, { children: initials(name) }) }) }),
|
|
6069
|
+
/* @__PURE__ */ (0, import_jsx_runtime81.jsxs)("div", { className: "min-w-0 flex-1", children: [
|
|
6070
|
+
/* @__PURE__ */ (0, import_jsx_runtime81.jsx)("h3", { className: "truncate text-base font-semibold tracking-tight", children: href ? /* @__PURE__ */ (0, import_jsx_runtime81.jsx)(Link3, { href, className: "rounded-sm hover:text-primary focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring", children: name }) : name }),
|
|
6071
|
+
/* @__PURE__ */ (0, import_jsx_runtime81.jsx)("p", { className: "mt-0.5 truncate text-xs text-muted-foreground", children: entityType }),
|
|
6072
|
+
location && /* @__PURE__ */ (0, import_jsx_runtime81.jsx)("p", { className: "mt-0.5 truncate text-xs text-muted-foreground", children: location })
|
|
6073
|
+
] })
|
|
6074
|
+
] }),
|
|
6075
|
+
/* @__PURE__ */ (0, import_jsx_runtime81.jsxs)(CardContent, { className: "flex-1 px-5 pb-3", children: [
|
|
6076
|
+
description && /* @__PURE__ */ (0, import_jsx_runtime81.jsx)("p", { className: "line-clamp-3 text-sm leading-relaxed text-muted-foreground", children: description }),
|
|
6077
|
+
tags && tags.length > 0 && /* @__PURE__ */ (0, import_jsx_runtime81.jsx)("div", { className: "mt-3 flex flex-wrap gap-1.5", children: tags.map((tag) => /* @__PURE__ */ (0, import_jsx_runtime81.jsx)(Badge, { variant: "secondary", children: tag }, tag)) }),
|
|
6078
|
+
stats && stats.length > 0 && /* @__PURE__ */ (0, import_jsx_runtime81.jsx)("dl", { className: "mt-4 grid grid-cols-2 gap-3", children: stats.map((stat) => /* @__PURE__ */ (0, import_jsx_runtime81.jsxs)("div", { className: "min-w-0", children: [
|
|
6079
|
+
/* @__PURE__ */ (0, import_jsx_runtime81.jsx)("dt", { className: "text-xs text-muted-foreground", children: stat.label }),
|
|
6080
|
+
/* @__PURE__ */ (0, import_jsx_runtime81.jsx)("dd", { className: "mt-0.5 truncate text-sm font-semibold tabular-nums", children: stat.value })
|
|
6081
|
+
] }, stat.label)) })
|
|
6082
|
+
] }),
|
|
6083
|
+
(href || actions) && /* @__PURE__ */ (0, import_jsx_runtime81.jsxs)(CardFooter, { className: "flex flex-wrap items-center gap-2 border-t border-border px-5 py-3", children: [
|
|
6084
|
+
href && /* @__PURE__ */ (0, import_jsx_runtime81.jsx)(
|
|
6085
|
+
Link3,
|
|
6086
|
+
{
|
|
6087
|
+
href,
|
|
6088
|
+
className: "text-sm font-medium text-primary underline-offset-4 hover:underline focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring",
|
|
6089
|
+
children: "View profile"
|
|
6090
|
+
}
|
|
6091
|
+
),
|
|
6092
|
+
actions && /* @__PURE__ */ (0, import_jsx_runtime81.jsx)("div", { className: "ml-auto flex items-center gap-2", children: actions })
|
|
6093
|
+
] })
|
|
6094
|
+
] });
|
|
6095
|
+
});
|
|
6096
|
+
var ProfileCard = EntityCard;
|
|
6097
|
+
|
|
6098
|
+
// src/components/tombstone-card/TombstoneCard.tsx
|
|
6099
|
+
var React83 = __toESM(require("react"));
|
|
6100
|
+
var import_jsx_runtime82 = require("react/jsx-runtime");
|
|
6101
|
+
var statusConfig2 = {
|
|
6102
|
+
archived: { label: "Archived", variant: "secondary" },
|
|
6103
|
+
unavailable: { label: "Unavailable", variant: "warning" },
|
|
6104
|
+
closed: { label: "Closed", variant: "outline" }
|
|
6105
|
+
};
|
|
6106
|
+
var TombstoneCard = React83.forwardRef(function TombstoneCard2({
|
|
6107
|
+
title,
|
|
6108
|
+
reason,
|
|
6109
|
+
status = "unavailable",
|
|
6110
|
+
logo,
|
|
6111
|
+
href,
|
|
6112
|
+
actionLabel = "View details",
|
|
6113
|
+
linkComponent,
|
|
6114
|
+
className,
|
|
6115
|
+
...props
|
|
6116
|
+
}, ref) {
|
|
6117
|
+
const Link3 = linkComponent ?? "a";
|
|
6118
|
+
const statusInfo = statusConfig2[status];
|
|
6119
|
+
return /* @__PURE__ */ (0, import_jsx_runtime82.jsx)(
|
|
6120
|
+
Card,
|
|
6121
|
+
{
|
|
6122
|
+
ref,
|
|
6123
|
+
className: cn("flex h-full flex-col border-dashed bg-muted/30 shadow-none", className),
|
|
6124
|
+
...props,
|
|
6125
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime82.jsxs)(CardContent, { className: "flex flex-1 flex-col gap-3 p-5", children: [
|
|
6126
|
+
/* @__PURE__ */ (0, import_jsx_runtime82.jsxs)("div", { className: "flex items-start justify-between gap-2", children: [
|
|
6127
|
+
logo && /* @__PURE__ */ (0, import_jsx_runtime82.jsx)("div", { className: "min-w-0 opacity-70", children: logo }),
|
|
6128
|
+
/* @__PURE__ */ (0, import_jsx_runtime82.jsx)(Badge, { variant: statusInfo.variant, children: statusInfo.label })
|
|
6129
|
+
] }),
|
|
6130
|
+
/* @__PURE__ */ (0, import_jsx_runtime82.jsx)("h3", { className: "text-base font-semibold tracking-tight text-foreground/80", children: title }),
|
|
6131
|
+
reason && /* @__PURE__ */ (0, import_jsx_runtime82.jsx)("p", { className: "text-sm leading-relaxed text-muted-foreground", children: reason }),
|
|
6132
|
+
href && /* @__PURE__ */ (0, import_jsx_runtime82.jsx)(
|
|
6133
|
+
Link3,
|
|
6134
|
+
{
|
|
6135
|
+
href,
|
|
6136
|
+
className: "mt-auto text-sm font-medium text-primary underline-offset-4 hover:underline focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring",
|
|
6137
|
+
children: actionLabel
|
|
6138
|
+
}
|
|
6139
|
+
)
|
|
6140
|
+
] })
|
|
6141
|
+
}
|
|
6142
|
+
);
|
|
6143
|
+
});
|
|
6144
|
+
|
|
6145
|
+
// src/components/document-card/DocumentCard.tsx
|
|
6146
|
+
var React84 = __toESM(require("react"));
|
|
6147
|
+
var import_jsx_runtime83 = require("react/jsx-runtime");
|
|
6148
|
+
var statusConfig3 = {
|
|
6149
|
+
available: { label: "Available", variant: "success" },
|
|
6150
|
+
restricted: { label: "Restricted", variant: "warning" },
|
|
6151
|
+
pending: { label: "Pending", variant: "info" }
|
|
6152
|
+
};
|
|
6153
|
+
var DocumentCard = React84.forwardRef(function DocumentCard2({
|
|
6154
|
+
name,
|
|
6155
|
+
fileType,
|
|
6156
|
+
size,
|
|
6157
|
+
updatedAt,
|
|
6158
|
+
status = "available",
|
|
6159
|
+
onDownload,
|
|
6160
|
+
downloadLabel = "Download",
|
|
6161
|
+
icon,
|
|
6162
|
+
className,
|
|
6163
|
+
...props
|
|
6164
|
+
}, ref) {
|
|
6165
|
+
const statusInfo = statusConfig3[status];
|
|
6166
|
+
const meta = [fileType, size, updatedAt].filter(Boolean).join(" \xB7 ");
|
|
6167
|
+
return /* @__PURE__ */ (0, import_jsx_runtime83.jsx)(Card, { ref, className: cn("w-full", className), ...props, children: /* @__PURE__ */ (0, import_jsx_runtime83.jsxs)(CardContent, { className: "flex items-center gap-3 p-4", children: [
|
|
6168
|
+
/* @__PURE__ */ (0, import_jsx_runtime83.jsx)("span", { className: "flex h-10 w-10 shrink-0 items-center justify-center rounded-lg bg-primary/10 text-primary [&_svg]:size-5", children: icon ?? /* @__PURE__ */ (0, import_jsx_runtime83.jsx)("span", { className: "text-[10px] font-bold uppercase tracking-wide", children: fileType }) }),
|
|
6169
|
+
/* @__PURE__ */ (0, import_jsx_runtime83.jsxs)("div", { className: "min-w-0 flex-1", children: [
|
|
6170
|
+
/* @__PURE__ */ (0, import_jsx_runtime83.jsx)("p", { className: "truncate text-sm font-medium", children: name }),
|
|
6171
|
+
meta && /* @__PURE__ */ (0, import_jsx_runtime83.jsx)("p", { className: "mt-0.5 truncate text-xs text-muted-foreground", children: meta })
|
|
6172
|
+
] }),
|
|
6173
|
+
/* @__PURE__ */ (0, import_jsx_runtime83.jsx)(Badge, { variant: statusInfo.variant, children: statusInfo.label }),
|
|
6174
|
+
onDownload && /* @__PURE__ */ (0, import_jsx_runtime83.jsx)(
|
|
6175
|
+
Button,
|
|
6176
|
+
{
|
|
6177
|
+
type: "button",
|
|
6178
|
+
variant: "outline",
|
|
6179
|
+
size: "sm",
|
|
6180
|
+
onClick: onDownload,
|
|
6181
|
+
disabled: status !== "available",
|
|
6182
|
+
"aria-label": `${downloadLabel} ${name}`,
|
|
6183
|
+
children: downloadLabel
|
|
6184
|
+
}
|
|
6185
|
+
)
|
|
6186
|
+
] }) });
|
|
6187
|
+
});
|
|
6188
|
+
|
|
6189
|
+
// src/components/load-more/LoadMore.tsx
|
|
6190
|
+
var React85 = __toESM(require("react"));
|
|
6191
|
+
var import_jsx_runtime84 = require("react/jsx-runtime");
|
|
6192
|
+
var LoadMore = React85.forwardRef(function LoadMore2({
|
|
6193
|
+
hasMore,
|
|
6194
|
+
onLoadMore,
|
|
6195
|
+
loading = false,
|
|
6196
|
+
loadLabel = "Load more",
|
|
6197
|
+
loadingLabel = "Loading...",
|
|
6198
|
+
endLabel = "You're all caught up.",
|
|
6199
|
+
className,
|
|
6200
|
+
...props
|
|
6201
|
+
}, ref) {
|
|
6202
|
+
return /* @__PURE__ */ (0, import_jsx_runtime84.jsx)("div", { ref, "aria-live": "polite", className: cn("flex w-full justify-center py-4", className), ...props, children: hasMore ? /* @__PURE__ */ (0, import_jsx_runtime84.jsx)(Button, { type: "button", variant: "outline", onClick: onLoadMore, loading, children: loading ? loadingLabel : loadLabel }) : /* @__PURE__ */ (0, import_jsx_runtime84.jsx)("p", { role: "status", className: "text-sm text-muted-foreground", children: endLabel }) });
|
|
6203
|
+
});
|
|
6204
|
+
|
|
6205
|
+
// src/components/segmented-control/SegmentedControl.tsx
|
|
6206
|
+
var React86 = __toESM(require("react"));
|
|
6207
|
+
var import_jsx_runtime85 = require("react/jsx-runtime");
|
|
5721
6208
|
var sizeClasses10 = {
|
|
5722
6209
|
sm: "h-8 px-2.5 text-xs",
|
|
5723
6210
|
md: "h-9 px-3 text-sm",
|
|
5724
6211
|
lg: "h-10 px-4 text-sm"
|
|
5725
6212
|
};
|
|
5726
|
-
var SegmentedControl =
|
|
6213
|
+
var SegmentedControl = React86.forwardRef(
|
|
5727
6214
|
function SegmentedControl2({
|
|
5728
6215
|
options,
|
|
5729
6216
|
value,
|
|
@@ -5737,12 +6224,12 @@ var SegmentedControl = React81.forwardRef(
|
|
|
5737
6224
|
...props
|
|
5738
6225
|
}, ref) {
|
|
5739
6226
|
const isControlled = value !== void 0;
|
|
5740
|
-
const [internal, setInternal] =
|
|
6227
|
+
const [internal, setInternal] = React86.useState(
|
|
5741
6228
|
() => multiple ? Array.isArray(defaultValue) ? defaultValue : [] : typeof defaultValue === "string" ? defaultValue : ""
|
|
5742
6229
|
);
|
|
5743
6230
|
const current = isControlled ? value : internal;
|
|
5744
6231
|
const selected = multiple ? Array.isArray(current) ? current : [] : typeof current === "string" ? current : "";
|
|
5745
|
-
const refs =
|
|
6232
|
+
const refs = React86.useRef([]);
|
|
5746
6233
|
const commit = (next) => {
|
|
5747
6234
|
if (!isControlled) setInternal(next);
|
|
5748
6235
|
onValueChange?.(next);
|
|
@@ -5792,7 +6279,7 @@ var SegmentedControl = React81.forwardRef(
|
|
|
5792
6279
|
moveFocus("last");
|
|
5793
6280
|
}
|
|
5794
6281
|
};
|
|
5795
|
-
return /* @__PURE__ */ (0,
|
|
6282
|
+
return /* @__PURE__ */ (0, import_jsx_runtime85.jsx)(
|
|
5796
6283
|
"div",
|
|
5797
6284
|
{
|
|
5798
6285
|
ref,
|
|
@@ -5808,7 +6295,7 @@ var SegmentedControl = React81.forwardRef(
|
|
|
5808
6295
|
const active = multiple ? Array.isArray(selected) && selected.includes(option.value) : selected === option.value;
|
|
5809
6296
|
const firstEnabled = options.findIndex((entry) => !entry.disabled);
|
|
5810
6297
|
const focusable = multiple || active || !selected && index === firstEnabled;
|
|
5811
|
-
return /* @__PURE__ */ (0,
|
|
6298
|
+
return /* @__PURE__ */ (0, import_jsx_runtime85.jsxs)(
|
|
5812
6299
|
"button",
|
|
5813
6300
|
{
|
|
5814
6301
|
ref: (node) => {
|
|
@@ -5831,8 +6318,8 @@ var SegmentedControl = React81.forwardRef(
|
|
|
5831
6318
|
active ? "bg-background text-foreground shadow-sm" : "text-muted-foreground hover:text-foreground"
|
|
5832
6319
|
),
|
|
5833
6320
|
children: [
|
|
5834
|
-
option.icon && /* @__PURE__ */ (0,
|
|
5835
|
-
/* @__PURE__ */ (0,
|
|
6321
|
+
option.icon && /* @__PURE__ */ (0, import_jsx_runtime85.jsx)("span", { className: "shrink-0 [&_svg]:size-4", children: option.icon }),
|
|
6322
|
+
/* @__PURE__ */ (0, import_jsx_runtime85.jsx)("span", { className: "truncate", children: option.label })
|
|
5836
6323
|
]
|
|
5837
6324
|
},
|
|
5838
6325
|
option.value
|
|
@@ -5844,18 +6331,18 @@ var SegmentedControl = React81.forwardRef(
|
|
|
5844
6331
|
);
|
|
5845
6332
|
|
|
5846
6333
|
// src/components/range-slider/RangeSlider.tsx
|
|
5847
|
-
var
|
|
5848
|
-
var
|
|
6334
|
+
var React87 = __toESM(require("react"));
|
|
6335
|
+
var import_jsx_runtime86 = require("react/jsx-runtime");
|
|
5849
6336
|
var rangeInputClass = cn(
|
|
5850
|
-
"pointer-events-none absolute inset-x-0 top-1/2 h-
|
|
5851
|
-
"[&::-webkit-slider-runnable-track]:h-1 [&::-webkit-slider-runnable-track]:bg-transparent",
|
|
5852
|
-
"[&::-webkit-slider-thumb]:pointer-events-auto [&::-webkit-slider-thumb]:h-4 [&::-webkit-slider-thumb]:w-4 [&::-webkit-slider-thumb]:appearance-none [&::-webkit-slider-thumb]:rounded-full [&::-webkit-slider-thumb]:border-2 [&::-webkit-slider-thumb]:border-primary [&::-webkit-slider-thumb]:bg-background [&::-webkit-slider-thumb]:shadow",
|
|
5853
|
-
"[&::-moz-range-track]:h-1 [&::-moz-range-track]:bg-transparent",
|
|
5854
|
-
"[&::-moz-range-thumb]:pointer-events-auto [&::-moz-range-thumb]:h-4 [&::-moz-range-thumb]:w-4 [&::-moz-range-thumb]:rounded-full [&::-moz-range-thumb]:border-2 [&::-moz-range-thumb]:border-primary [&::-moz-range-thumb]:bg-background [&::-moz-range-thumb]:shadow",
|
|
6337
|
+
"pointer-events-none absolute inset-x-0 top-1/2 h-6 w-full -translate-y-1/2 appearance-none bg-transparent",
|
|
6338
|
+
"[&::-webkit-slider-runnable-track]:h-1 [&::-webkit-slider-runnable-track]:rounded-full [&::-webkit-slider-runnable-track]:bg-transparent",
|
|
6339
|
+
"[&::-webkit-slider-thumb]:pointer-events-auto [&::-webkit-slider-thumb]:mt-[-6px] [&::-webkit-slider-thumb]:h-4 [&::-webkit-slider-thumb]:w-4 [&::-webkit-slider-thumb]:cursor-grab [&::-webkit-slider-thumb]:appearance-none [&::-webkit-slider-thumb]:rounded-full [&::-webkit-slider-thumb]:border-2 [&::-webkit-slider-thumb]:border-primary [&::-webkit-slider-thumb]:bg-background [&::-webkit-slider-thumb]:shadow",
|
|
6340
|
+
"[&::-moz-range-track]:h-1 [&::-moz-range-track]:rounded-full [&::-moz-range-track]:bg-transparent",
|
|
6341
|
+
"[&::-moz-range-thumb]:pointer-events-auto [&::-moz-range-thumb]:h-4 [&::-moz-range-thumb]:w-4 [&::-moz-range-thumb]:cursor-grab [&::-moz-range-thumb]:rounded-full [&::-moz-range-thumb]:border-2 [&::-moz-range-thumb]:border-primary [&::-moz-range-thumb]:bg-background [&::-moz-range-thumb]:shadow",
|
|
5855
6342
|
"focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 focus-visible:ring-offset-background",
|
|
5856
6343
|
"disabled:cursor-not-allowed disabled:opacity-50"
|
|
5857
6344
|
);
|
|
5858
|
-
var RangeSlider =
|
|
6345
|
+
var RangeSlider = React87.forwardRef(function RangeSlider2({
|
|
5859
6346
|
value,
|
|
5860
6347
|
defaultValue,
|
|
5861
6348
|
onValueChange,
|
|
@@ -5871,7 +6358,7 @@ var RangeSlider = React82.forwardRef(function RangeSlider2({
|
|
|
5871
6358
|
...props
|
|
5872
6359
|
}, ref) {
|
|
5873
6360
|
const clamp = (entry) => Math.min(Math.max(entry, min), max);
|
|
5874
|
-
const [internal, setInternal] =
|
|
6361
|
+
const [internal, setInternal] = React87.useState(() => {
|
|
5875
6362
|
const initial = defaultValue ?? [min, max];
|
|
5876
6363
|
return [clamp(initial[0]), clamp(initial[1])];
|
|
5877
6364
|
});
|
|
@@ -5885,21 +6372,21 @@ var RangeSlider = React82.forwardRef(function RangeSlider2({
|
|
|
5885
6372
|
const span = max - min || 1;
|
|
5886
6373
|
const lowPercent = (low - min) / span * 100;
|
|
5887
6374
|
const highPercent = (high - min) / span * 100;
|
|
5888
|
-
return /* @__PURE__ */ (0,
|
|
5889
|
-
showValues && /* @__PURE__ */ (0,
|
|
5890
|
-
/* @__PURE__ */ (0,
|
|
5891
|
-
/* @__PURE__ */ (0,
|
|
6375
|
+
return /* @__PURE__ */ (0, import_jsx_runtime86.jsxs)("div", { ref, className: cn("w-full", className), ...props, children: [
|
|
6376
|
+
showValues && /* @__PURE__ */ (0, import_jsx_runtime86.jsxs)("div", { className: "mb-2 flex items-center justify-between text-sm font-medium tabular-nums", children: [
|
|
6377
|
+
/* @__PURE__ */ (0, import_jsx_runtime86.jsx)("span", { children: formatValue(low) }),
|
|
6378
|
+
/* @__PURE__ */ (0, import_jsx_runtime86.jsx)("span", { children: formatValue(high) })
|
|
5892
6379
|
] }),
|
|
5893
|
-
/* @__PURE__ */ (0,
|
|
5894
|
-
/* @__PURE__ */ (0,
|
|
5895
|
-
/* @__PURE__ */ (0,
|
|
6380
|
+
/* @__PURE__ */ (0, import_jsx_runtime86.jsxs)("div", { className: "relative h-6 w-full", children: [
|
|
6381
|
+
/* @__PURE__ */ (0, import_jsx_runtime86.jsx)("div", { className: "absolute inset-x-0 top-1/2 h-1 -translate-y-1/2 rounded-full bg-muted" }),
|
|
6382
|
+
/* @__PURE__ */ (0, import_jsx_runtime86.jsx)(
|
|
5896
6383
|
"div",
|
|
5897
6384
|
{
|
|
5898
6385
|
className: "absolute top-1/2 h-1 -translate-y-1/2 rounded-full bg-primary",
|
|
5899
6386
|
style: { left: `${lowPercent}%`, right: `${100 - highPercent}%` }
|
|
5900
6387
|
}
|
|
5901
6388
|
),
|
|
5902
|
-
/* @__PURE__ */ (0,
|
|
6389
|
+
/* @__PURE__ */ (0, import_jsx_runtime86.jsx)(
|
|
5903
6390
|
"input",
|
|
5904
6391
|
{
|
|
5905
6392
|
type: "range",
|
|
@@ -5914,7 +6401,7 @@ var RangeSlider = React82.forwardRef(function RangeSlider2({
|
|
|
5914
6401
|
className: cn(rangeInputClass, "z-10")
|
|
5915
6402
|
}
|
|
5916
6403
|
),
|
|
5917
|
-
/* @__PURE__ */ (0,
|
|
6404
|
+
/* @__PURE__ */ (0, import_jsx_runtime86.jsx)(
|
|
5918
6405
|
"input",
|
|
5919
6406
|
{
|
|
5920
6407
|
type: "range",
|
|
@@ -5934,9 +6421,9 @@ var RangeSlider = React82.forwardRef(function RangeSlider2({
|
|
|
5934
6421
|
});
|
|
5935
6422
|
|
|
5936
6423
|
// src/components/filter-chips/FilterChips.tsx
|
|
5937
|
-
var
|
|
5938
|
-
var
|
|
5939
|
-
var FilterChips =
|
|
6424
|
+
var React88 = __toESM(require("react"));
|
|
6425
|
+
var import_jsx_runtime87 = require("react/jsx-runtime");
|
|
6426
|
+
var FilterChips = React88.forwardRef(function FilterChips2({
|
|
5940
6427
|
filters,
|
|
5941
6428
|
onClearAll,
|
|
5942
6429
|
clearLabel = "Clear all",
|
|
@@ -5946,9 +6433,9 @@ var FilterChips = React83.forwardRef(function FilterChips2({
|
|
|
5946
6433
|
...props
|
|
5947
6434
|
}, ref) {
|
|
5948
6435
|
if (filters.length === 0) {
|
|
5949
|
-
return emptyLabel ? /* @__PURE__ */ (0,
|
|
6436
|
+
return emptyLabel ? /* @__PURE__ */ (0, import_jsx_runtime87.jsx)("div", { ref, className: cn("text-sm text-muted-foreground", className), ...props, children: emptyLabel }) : null;
|
|
5950
6437
|
}
|
|
5951
|
-
return /* @__PURE__ */ (0,
|
|
6438
|
+
return /* @__PURE__ */ (0, import_jsx_runtime87.jsxs)(
|
|
5952
6439
|
"div",
|
|
5953
6440
|
{
|
|
5954
6441
|
ref,
|
|
@@ -5957,34 +6444,34 @@ var FilterChips = React83.forwardRef(function FilterChips2({
|
|
|
5957
6444
|
className: cn("flex flex-wrap items-center gap-2", className),
|
|
5958
6445
|
...props,
|
|
5959
6446
|
children: [
|
|
5960
|
-
filters.map((filter) => /* @__PURE__ */ (0,
|
|
6447
|
+
filters.map((filter) => /* @__PURE__ */ (0, import_jsx_runtime87.jsxs)(
|
|
5961
6448
|
"span",
|
|
5962
6449
|
{
|
|
5963
6450
|
className: "inline-flex max-w-full items-center gap-1.5 rounded-full border border-border bg-muted/60 py-1 pl-3 pr-1 text-sm",
|
|
5964
6451
|
children: [
|
|
5965
|
-
/* @__PURE__ */ (0,
|
|
5966
|
-
/* @__PURE__ */ (0,
|
|
6452
|
+
/* @__PURE__ */ (0, import_jsx_runtime87.jsxs)("span", { className: "truncate", children: [
|
|
6453
|
+
/* @__PURE__ */ (0, import_jsx_runtime87.jsxs)("span", { className: "text-muted-foreground", children: [
|
|
5967
6454
|
filter.label,
|
|
5968
6455
|
":"
|
|
5969
6456
|
] }),
|
|
5970
6457
|
" ",
|
|
5971
|
-
/* @__PURE__ */ (0,
|
|
6458
|
+
/* @__PURE__ */ (0, import_jsx_runtime87.jsx)("span", { className: "font-medium", children: filter.value ?? "Any" })
|
|
5972
6459
|
] }),
|
|
5973
|
-
filter.onRemove && /* @__PURE__ */ (0,
|
|
6460
|
+
filter.onRemove && /* @__PURE__ */ (0, import_jsx_runtime87.jsx)(
|
|
5974
6461
|
"button",
|
|
5975
6462
|
{
|
|
5976
6463
|
type: "button",
|
|
5977
6464
|
onClick: filter.onRemove,
|
|
5978
6465
|
"aria-label": `Remove ${filter.label}${filter.value ? `: ${filter.value}` : ""}`,
|
|
5979
6466
|
className: "rounded-full p-1 text-muted-foreground transition-colors hover:bg-background hover:text-foreground focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring",
|
|
5980
|
-
children: /* @__PURE__ */ (0,
|
|
6467
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime87.jsx)("svg", { "aria-hidden": "true", viewBox: "0 0 20 20", className: "h-3.5 w-3.5", fill: "none", stroke: "currentColor", strokeWidth: "2", strokeLinecap: "round", children: /* @__PURE__ */ (0, import_jsx_runtime87.jsx)("path", { d: "m5 5 10 10M15 5 5 15" }) })
|
|
5981
6468
|
}
|
|
5982
6469
|
)
|
|
5983
6470
|
]
|
|
5984
6471
|
},
|
|
5985
6472
|
filter.key
|
|
5986
6473
|
)),
|
|
5987
|
-
onClearAll && /* @__PURE__ */ (0,
|
|
6474
|
+
onClearAll && /* @__PURE__ */ (0, import_jsx_runtime87.jsx)(
|
|
5988
6475
|
"button",
|
|
5989
6476
|
{
|
|
5990
6477
|
type: "button",
|
|
@@ -5999,13 +6486,13 @@ var FilterChips = React83.forwardRef(function FilterChips2({
|
|
|
5999
6486
|
});
|
|
6000
6487
|
|
|
6001
6488
|
// src/components/multi-select/MultiSelect.tsx
|
|
6002
|
-
var
|
|
6489
|
+
var React90 = __toESM(require("react"));
|
|
6003
6490
|
|
|
6004
6491
|
// src/components/popover/Popover.tsx
|
|
6005
|
-
var
|
|
6492
|
+
var React89 = __toESM(require("react"));
|
|
6006
6493
|
var import_react_dom7 = require("react-dom");
|
|
6007
|
-
var
|
|
6008
|
-
var PopoverContext =
|
|
6494
|
+
var import_jsx_runtime88 = require("react/jsx-runtime");
|
|
6495
|
+
var PopoverContext = React89.createContext({
|
|
6009
6496
|
open: false,
|
|
6010
6497
|
setOpen: () => {
|
|
6011
6498
|
},
|
|
@@ -6013,14 +6500,14 @@ var PopoverContext = React84.createContext({
|
|
|
6013
6500
|
contentId: "",
|
|
6014
6501
|
wrapperRef: { current: null }
|
|
6015
6502
|
});
|
|
6016
|
-
var Popover =
|
|
6503
|
+
var Popover = React89.forwardRef(
|
|
6017
6504
|
({ open, onOpenChange, className, children }, ref) => {
|
|
6018
|
-
const [internalOpen, setInternalOpen] =
|
|
6505
|
+
const [internalOpen, setInternalOpen] = React89.useState(false);
|
|
6019
6506
|
const current = open ?? internalOpen;
|
|
6020
|
-
const triggerId =
|
|
6021
|
-
const contentId =
|
|
6022
|
-
const wrapperRef =
|
|
6023
|
-
const setRefs =
|
|
6507
|
+
const triggerId = React89.useId();
|
|
6508
|
+
const contentId = React89.useId();
|
|
6509
|
+
const wrapperRef = React89.useRef(null);
|
|
6510
|
+
const setRefs = React89.useCallback(
|
|
6024
6511
|
(node) => {
|
|
6025
6512
|
wrapperRef.current = node;
|
|
6026
6513
|
if (typeof ref === "function") ref(node);
|
|
@@ -6028,14 +6515,14 @@ var Popover = React84.forwardRef(
|
|
|
6028
6515
|
},
|
|
6029
6516
|
[ref]
|
|
6030
6517
|
);
|
|
6031
|
-
const setOpen =
|
|
6518
|
+
const setOpen = React89.useCallback(
|
|
6032
6519
|
(next) => {
|
|
6033
6520
|
if (open === void 0) setInternalOpen(next);
|
|
6034
6521
|
onOpenChange?.(next);
|
|
6035
6522
|
},
|
|
6036
6523
|
[open, onOpenChange]
|
|
6037
6524
|
);
|
|
6038
|
-
return /* @__PURE__ */ (0,
|
|
6525
|
+
return /* @__PURE__ */ (0, import_jsx_runtime88.jsx)("div", { ref: setRefs, className: cn("relative inline-block", className), children: /* @__PURE__ */ (0, import_jsx_runtime88.jsx)(
|
|
6039
6526
|
PopoverContext.Provider,
|
|
6040
6527
|
{
|
|
6041
6528
|
value: { open: current, setOpen, triggerId, contentId, wrapperRef },
|
|
@@ -6045,10 +6532,10 @@ var Popover = React84.forwardRef(
|
|
|
6045
6532
|
}
|
|
6046
6533
|
);
|
|
6047
6534
|
Popover.displayName = "Popover";
|
|
6048
|
-
var PopoverTrigger =
|
|
6535
|
+
var PopoverTrigger = React89.forwardRef(
|
|
6049
6536
|
({ className, children, onClick, ...props }, ref) => {
|
|
6050
|
-
const { open, setOpen, triggerId, contentId } =
|
|
6051
|
-
return /* @__PURE__ */ (0,
|
|
6537
|
+
const { open, setOpen, triggerId, contentId } = React89.useContext(PopoverContext);
|
|
6538
|
+
return /* @__PURE__ */ (0, import_jsx_runtime88.jsx)(
|
|
6052
6539
|
"button",
|
|
6053
6540
|
{
|
|
6054
6541
|
ref,
|
|
@@ -6073,12 +6560,12 @@ var PopoverTrigger = React84.forwardRef(
|
|
|
6073
6560
|
}
|
|
6074
6561
|
);
|
|
6075
6562
|
PopoverTrigger.displayName = "PopoverTrigger";
|
|
6076
|
-
var PopoverContent =
|
|
6563
|
+
var PopoverContent = React89.forwardRef(
|
|
6077
6564
|
({ className, children, onKeyDown, ...props }, ref) => {
|
|
6078
|
-
const { open, setOpen, triggerId, contentId, wrapperRef } =
|
|
6079
|
-
const contentRef =
|
|
6080
|
-
const [pos, setPos] =
|
|
6081
|
-
|
|
6565
|
+
const { open, setOpen, triggerId, contentId, wrapperRef } = React89.useContext(PopoverContext);
|
|
6566
|
+
const contentRef = React89.useRef(null);
|
|
6567
|
+
const [pos, setPos] = React89.useState(null);
|
|
6568
|
+
React89.useLayoutEffect(() => {
|
|
6082
6569
|
if (!open) {
|
|
6083
6570
|
setPos(null);
|
|
6084
6571
|
return;
|
|
@@ -6098,7 +6585,7 @@ var PopoverContent = React84.forwardRef(
|
|
|
6098
6585
|
window.removeEventListener("resize", measure);
|
|
6099
6586
|
};
|
|
6100
6587
|
}, [open, setOpen, wrapperRef]);
|
|
6101
|
-
|
|
6588
|
+
React89.useEffect(() => {
|
|
6102
6589
|
if (!open) return;
|
|
6103
6590
|
function onPointerDown(event) {
|
|
6104
6591
|
if (!contentRef.current?.contains(event.target)) setOpen(false);
|
|
@@ -6106,14 +6593,14 @@ var PopoverContent = React84.forwardRef(
|
|
|
6106
6593
|
document.addEventListener("pointerdown", onPointerDown);
|
|
6107
6594
|
return () => document.removeEventListener("pointerdown", onPointerDown);
|
|
6108
6595
|
}, [open, setOpen]);
|
|
6109
|
-
|
|
6596
|
+
React89.useEffect(() => {
|
|
6110
6597
|
if (open && pos && contentRef.current) {
|
|
6111
6598
|
contentRef.current.focus();
|
|
6112
6599
|
}
|
|
6113
6600
|
}, [open, pos]);
|
|
6114
6601
|
if (!open || !pos || typeof document === "undefined") return null;
|
|
6115
6602
|
return (0, import_react_dom7.createPortal)(
|
|
6116
|
-
/* @__PURE__ */ (0,
|
|
6603
|
+
/* @__PURE__ */ (0, import_jsx_runtime88.jsx)(
|
|
6117
6604
|
"div",
|
|
6118
6605
|
{
|
|
6119
6606
|
ref: (node) => {
|
|
@@ -6148,8 +6635,8 @@ var PopoverContent = React84.forwardRef(
|
|
|
6148
6635
|
PopoverContent.displayName = "PopoverContent";
|
|
6149
6636
|
|
|
6150
6637
|
// src/components/multi-select/MultiSelect.tsx
|
|
6151
|
-
var
|
|
6152
|
-
var MultiSelect =
|
|
6638
|
+
var import_jsx_runtime89 = require("react/jsx-runtime");
|
|
6639
|
+
var MultiSelect = React90.forwardRef(function MultiSelect2({
|
|
6153
6640
|
options,
|
|
6154
6641
|
value,
|
|
6155
6642
|
defaultValue,
|
|
@@ -6163,10 +6650,10 @@ var MultiSelect = React85.forwardRef(function MultiSelect2({
|
|
|
6163
6650
|
className,
|
|
6164
6651
|
...props
|
|
6165
6652
|
}, ref) {
|
|
6166
|
-
const labelId =
|
|
6167
|
-
const [internal, setInternal] =
|
|
6168
|
-
const [query, setQuery] =
|
|
6169
|
-
const [open, setOpen] =
|
|
6653
|
+
const labelId = React90.useId();
|
|
6654
|
+
const [internal, setInternal] = React90.useState(defaultValue ?? []);
|
|
6655
|
+
const [query, setQuery] = React90.useState("");
|
|
6656
|
+
const [open, setOpen] = React90.useState(false);
|
|
6170
6657
|
const selected = value ?? internal;
|
|
6171
6658
|
const commit = (next) => {
|
|
6172
6659
|
if (value === void 0) setInternal(next);
|
|
@@ -6183,7 +6670,7 @@ var MultiSelect = React85.forwardRef(function MultiSelect2({
|
|
|
6183
6670
|
const q = query.trim().toLowerCase();
|
|
6184
6671
|
return option.label.toLowerCase().includes(q) || option.value.toLowerCase().includes(q) || option.description?.toLowerCase().includes(q) || option.group?.toLowerCase().includes(q);
|
|
6185
6672
|
}) : options;
|
|
6186
|
-
const groups =
|
|
6673
|
+
const groups = React90.useMemo(() => {
|
|
6187
6674
|
let last;
|
|
6188
6675
|
return filtered.map((option) => {
|
|
6189
6676
|
const heading = option.group && option.group !== last ? option.group : void 0;
|
|
@@ -6193,16 +6680,16 @@ var MultiSelect = React85.forwardRef(function MultiSelect2({
|
|
|
6193
6680
|
}, [filtered]);
|
|
6194
6681
|
const visibleChips = selectedOptions.slice(0, maxDisplay);
|
|
6195
6682
|
const hiddenCount = selectedOptions.length - visibleChips.length;
|
|
6196
|
-
return /* @__PURE__ */ (0,
|
|
6197
|
-
label && /* @__PURE__ */ (0,
|
|
6198
|
-
visibleChips.length > 0 && /* @__PURE__ */ (0,
|
|
6199
|
-
visibleChips.map((option) => /* @__PURE__ */ (0,
|
|
6683
|
+
return /* @__PURE__ */ (0, import_jsx_runtime89.jsxs)("div", { ref, className: cn("flex flex-col gap-2", className), ...props, children: [
|
|
6684
|
+
label && /* @__PURE__ */ (0, import_jsx_runtime89.jsx)("span", { id: labelId, className: "text-sm font-medium", children: label }),
|
|
6685
|
+
visibleChips.length > 0 && /* @__PURE__ */ (0, import_jsx_runtime89.jsxs)("div", { className: "flex flex-wrap gap-1.5", children: [
|
|
6686
|
+
visibleChips.map((option) => /* @__PURE__ */ (0, import_jsx_runtime89.jsxs)(
|
|
6200
6687
|
"span",
|
|
6201
6688
|
{
|
|
6202
6689
|
className: "inline-flex max-w-full items-center gap-1 rounded-full border border-border bg-muted/60 py-0.5 pl-2.5 pr-1 text-xs",
|
|
6203
6690
|
children: [
|
|
6204
|
-
/* @__PURE__ */ (0,
|
|
6205
|
-
/* @__PURE__ */ (0,
|
|
6691
|
+
/* @__PURE__ */ (0, import_jsx_runtime89.jsx)("span", { className: "truncate", children: option.label }),
|
|
6692
|
+
/* @__PURE__ */ (0, import_jsx_runtime89.jsx)(
|
|
6206
6693
|
"button",
|
|
6207
6694
|
{
|
|
6208
6695
|
type: "button",
|
|
@@ -6210,26 +6697,26 @@ var MultiSelect = React85.forwardRef(function MultiSelect2({
|
|
|
6210
6697
|
disabled,
|
|
6211
6698
|
"aria-label": `Remove ${option.label}`,
|
|
6212
6699
|
className: "rounded-full p-1 text-muted-foreground hover:bg-background hover:text-foreground focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring disabled:pointer-events-none",
|
|
6213
|
-
children: /* @__PURE__ */ (0,
|
|
6700
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime89.jsx)("svg", { "aria-hidden": "true", viewBox: "0 0 20 20", className: "h-3 w-3", fill: "none", stroke: "currentColor", strokeWidth: "2", strokeLinecap: "round", children: /* @__PURE__ */ (0, import_jsx_runtime89.jsx)("path", { d: "m5 5 10 10M15 5 5 15" }) })
|
|
6214
6701
|
}
|
|
6215
6702
|
)
|
|
6216
6703
|
]
|
|
6217
6704
|
},
|
|
6218
6705
|
option.value
|
|
6219
6706
|
)),
|
|
6220
|
-
hiddenCount > 0 && /* @__PURE__ */ (0,
|
|
6707
|
+
hiddenCount > 0 && /* @__PURE__ */ (0, import_jsx_runtime89.jsxs)("span", { className: "self-center text-xs text-muted-foreground", children: [
|
|
6221
6708
|
"+",
|
|
6222
6709
|
hiddenCount,
|
|
6223
6710
|
" more"
|
|
6224
6711
|
] })
|
|
6225
6712
|
] }),
|
|
6226
|
-
/* @__PURE__ */ (0,
|
|
6227
|
-
/* @__PURE__ */ (0,
|
|
6228
|
-
/* @__PURE__ */ (0,
|
|
6229
|
-
/* @__PURE__ */ (0,
|
|
6713
|
+
/* @__PURE__ */ (0, import_jsx_runtime89.jsxs)(Popover, { open, onOpenChange: setOpen, children: [
|
|
6714
|
+
/* @__PURE__ */ (0, import_jsx_runtime89.jsxs)(PopoverTrigger, { "aria-labelledby": label ? labelId : void 0, disabled, className: "w-full justify-between", children: [
|
|
6715
|
+
/* @__PURE__ */ (0, import_jsx_runtime89.jsx)("span", { children: selected.length > 0 ? `${selected.length} selected` : triggerLabel }),
|
|
6716
|
+
/* @__PURE__ */ (0, import_jsx_runtime89.jsx)("span", { "aria-hidden": "true", className: "text-muted-foreground", children: "\u2304" })
|
|
6230
6717
|
] }),
|
|
6231
|
-
/* @__PURE__ */ (0,
|
|
6232
|
-
/* @__PURE__ */ (0,
|
|
6718
|
+
/* @__PURE__ */ (0, import_jsx_runtime89.jsxs)(PopoverContent, { className: "w-80 p-0", children: [
|
|
6719
|
+
/* @__PURE__ */ (0, import_jsx_runtime89.jsx)("div", { className: "border-b border-border p-3", children: /* @__PURE__ */ (0, import_jsx_runtime89.jsx)(
|
|
6233
6720
|
Input,
|
|
6234
6721
|
{
|
|
6235
6722
|
type: "search",
|
|
@@ -6240,9 +6727,9 @@ var MultiSelect = React85.forwardRef(function MultiSelect2({
|
|
|
6240
6727
|
autoFocus: true
|
|
6241
6728
|
}
|
|
6242
6729
|
) }),
|
|
6243
|
-
/* @__PURE__ */ (0,
|
|
6244
|
-
heading && /* @__PURE__ */ (0,
|
|
6245
|
-
/* @__PURE__ */ (0,
|
|
6730
|
+
/* @__PURE__ */ (0, import_jsx_runtime89.jsx)("div", { className: "max-h-64 overflow-y-auto p-1", children: groups.length === 0 ? /* @__PURE__ */ (0, import_jsx_runtime89.jsx)("p", { className: "px-3 py-3 text-sm text-muted-foreground", children: emptyText }) : groups.map(({ option, heading }) => /* @__PURE__ */ (0, import_jsx_runtime89.jsxs)(React90.Fragment, { children: [
|
|
6731
|
+
heading && /* @__PURE__ */ (0, import_jsx_runtime89.jsx)("p", { className: "px-3 pb-1 pt-2 text-xs font-medium uppercase tracking-wide text-muted-foreground", children: heading }),
|
|
6732
|
+
/* @__PURE__ */ (0, import_jsx_runtime89.jsxs)(
|
|
6246
6733
|
"label",
|
|
6247
6734
|
{
|
|
6248
6735
|
className: cn(
|
|
@@ -6250,7 +6737,7 @@ var MultiSelect = React85.forwardRef(function MultiSelect2({
|
|
|
6250
6737
|
option.disabled && "cursor-not-allowed opacity-50"
|
|
6251
6738
|
),
|
|
6252
6739
|
children: [
|
|
6253
|
-
/* @__PURE__ */ (0,
|
|
6740
|
+
/* @__PURE__ */ (0, import_jsx_runtime89.jsx)(
|
|
6254
6741
|
Checkbox,
|
|
6255
6742
|
{
|
|
6256
6743
|
checked: selected.includes(option.value),
|
|
@@ -6259,16 +6746,16 @@ var MultiSelect = React85.forwardRef(function MultiSelect2({
|
|
|
6259
6746
|
className: "mt-0.5"
|
|
6260
6747
|
}
|
|
6261
6748
|
),
|
|
6262
|
-
/* @__PURE__ */ (0,
|
|
6263
|
-
/* @__PURE__ */ (0,
|
|
6264
|
-
option.description && /* @__PURE__ */ (0,
|
|
6749
|
+
/* @__PURE__ */ (0, import_jsx_runtime89.jsxs)("span", { className: "min-w-0", children: [
|
|
6750
|
+
/* @__PURE__ */ (0, import_jsx_runtime89.jsx)("span", { className: "block", children: option.label }),
|
|
6751
|
+
option.description && /* @__PURE__ */ (0, import_jsx_runtime89.jsx)("span", { className: "mt-0.5 block text-xs text-muted-foreground", children: option.description })
|
|
6265
6752
|
] })
|
|
6266
6753
|
]
|
|
6267
6754
|
}
|
|
6268
6755
|
)
|
|
6269
6756
|
] }, option.value)) }),
|
|
6270
|
-
/* @__PURE__ */ (0,
|
|
6271
|
-
/* @__PURE__ */ (0,
|
|
6757
|
+
/* @__PURE__ */ (0, import_jsx_runtime89.jsxs)("div", { className: "flex items-center justify-between gap-2 border-t border-border p-2", children: [
|
|
6758
|
+
/* @__PURE__ */ (0, import_jsx_runtime89.jsx)(
|
|
6272
6759
|
Button,
|
|
6273
6760
|
{
|
|
6274
6761
|
type: "button",
|
|
@@ -6278,7 +6765,7 @@ var MultiSelect = React85.forwardRef(function MultiSelect2({
|
|
|
6278
6765
|
children: "Select all"
|
|
6279
6766
|
}
|
|
6280
6767
|
),
|
|
6281
|
-
/* @__PURE__ */ (0,
|
|
6768
|
+
/* @__PURE__ */ (0, import_jsx_runtime89.jsx)(Button, { type: "button", variant: "ghost", size: "sm", onClick: () => commit([]), children: "Clear" })
|
|
6282
6769
|
] })
|
|
6283
6770
|
] })
|
|
6284
6771
|
] })
|
|
@@ -6286,9 +6773,9 @@ var MultiSelect = React85.forwardRef(function MultiSelect2({
|
|
|
6286
6773
|
});
|
|
6287
6774
|
|
|
6288
6775
|
// src/components/filter-panel/FilterPanel.tsx
|
|
6289
|
-
var
|
|
6290
|
-
var
|
|
6291
|
-
var FilterPanel =
|
|
6776
|
+
var React91 = __toESM(require("react"));
|
|
6777
|
+
var import_jsx_runtime90 = require("react/jsx-runtime");
|
|
6778
|
+
var FilterPanel = React91.forwardRef(function FilterPanel2({
|
|
6292
6779
|
sections,
|
|
6293
6780
|
title = "Filters",
|
|
6294
6781
|
description,
|
|
@@ -6304,7 +6791,7 @@ var FilterPanel = React86.forwardRef(function FilterPanel2({
|
|
|
6304
6791
|
...props
|
|
6305
6792
|
}, ref) {
|
|
6306
6793
|
const Tag = as;
|
|
6307
|
-
const [open, setOpen] =
|
|
6794
|
+
const [open, setOpen] = React91.useState(
|
|
6308
6795
|
defaultOpen ?? sections.filter((section) => section.defaultOpen).map((section) => section.title)
|
|
6309
6796
|
);
|
|
6310
6797
|
const isOpen = (section) => !collapsible || open.includes(section.title);
|
|
@@ -6314,15 +6801,15 @@ var FilterPanel = React86.forwardRef(function FilterPanel2({
|
|
|
6314
6801
|
(current) => current.includes(section.title) ? current.filter((title2) => title2 !== section.title) : [...current, section.title]
|
|
6315
6802
|
);
|
|
6316
6803
|
};
|
|
6317
|
-
return /* @__PURE__ */ (0,
|
|
6318
|
-
(title || description) && /* @__PURE__ */ (0,
|
|
6319
|
-
title && /* @__PURE__ */ (0,
|
|
6320
|
-
description && /* @__PURE__ */ (0,
|
|
6804
|
+
return /* @__PURE__ */ (0, import_jsx_runtime90.jsxs)(Tag, { ref, className: cn("w-full rounded-xl border border-border bg-card", className), ...props, children: [
|
|
6805
|
+
(title || description) && /* @__PURE__ */ (0, import_jsx_runtime90.jsxs)("div", { className: "border-b border-border px-4 py-3", children: [
|
|
6806
|
+
title && /* @__PURE__ */ (0, import_jsx_runtime90.jsx)("h2", { className: "text-sm font-semibold", children: title }),
|
|
6807
|
+
description && /* @__PURE__ */ (0, import_jsx_runtime90.jsx)("p", { className: "mt-1 text-xs text-muted-foreground", children: description })
|
|
6321
6808
|
] }),
|
|
6322
|
-
/* @__PURE__ */ (0,
|
|
6809
|
+
/* @__PURE__ */ (0, import_jsx_runtime90.jsx)("div", { className: "divide-y divide-border", children: sections.map((section) => {
|
|
6323
6810
|
const expanded = isOpen(section);
|
|
6324
|
-
return /* @__PURE__ */ (0,
|
|
6325
|
-
/* @__PURE__ */ (0,
|
|
6811
|
+
return /* @__PURE__ */ (0, import_jsx_runtime90.jsxs)("div", { className: "px-4 py-3", children: [
|
|
6812
|
+
/* @__PURE__ */ (0, import_jsx_runtime90.jsx)("h3", { children: /* @__PURE__ */ (0, import_jsx_runtime90.jsxs)(
|
|
6326
6813
|
"button",
|
|
6327
6814
|
{
|
|
6328
6815
|
type: "button",
|
|
@@ -6335,28 +6822,28 @@ var FilterPanel = React86.forwardRef(function FilterPanel2({
|
|
|
6335
6822
|
collapsible && "rounded-sm focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring"
|
|
6336
6823
|
),
|
|
6337
6824
|
children: [
|
|
6338
|
-
/* @__PURE__ */ (0,
|
|
6825
|
+
/* @__PURE__ */ (0, import_jsx_runtime90.jsxs)("span", { children: [
|
|
6339
6826
|
section.title,
|
|
6340
|
-
section.description && /* @__PURE__ */ (0,
|
|
6827
|
+
section.description && /* @__PURE__ */ (0, import_jsx_runtime90.jsx)("span", { className: "mt-0.5 block text-xs font-normal text-muted-foreground", children: section.description })
|
|
6341
6828
|
] }),
|
|
6342
|
-
collapsible && /* @__PURE__ */ (0,
|
|
6829
|
+
collapsible && /* @__PURE__ */ (0, import_jsx_runtime90.jsx)("span", { "aria-hidden": "true", className: cn("text-muted-foreground transition-transform", expanded && "rotate-180"), children: "\u2304" })
|
|
6343
6830
|
]
|
|
6344
6831
|
}
|
|
6345
6832
|
) }),
|
|
6346
|
-
expanded && /* @__PURE__ */ (0,
|
|
6833
|
+
expanded && /* @__PURE__ */ (0, import_jsx_runtime90.jsx)("div", { id: `filter-section-${section.title.replace(/\s+/g, "-").toLowerCase()}`, className: "mt-3", children: section.content })
|
|
6347
6834
|
] }, section.title);
|
|
6348
6835
|
}) }),
|
|
6349
|
-
(onReset || onApply || actions) && /* @__PURE__ */ (0,
|
|
6836
|
+
(onReset || onApply || actions) && /* @__PURE__ */ (0, import_jsx_runtime90.jsxs)("div", { className: "flex flex-wrap items-center gap-2 border-t border-border px-4 py-3", children: [
|
|
6350
6837
|
actions,
|
|
6351
|
-
onReset && /* @__PURE__ */ (0,
|
|
6352
|
-
onApply && /* @__PURE__ */ (0,
|
|
6838
|
+
onReset && /* @__PURE__ */ (0, import_jsx_runtime90.jsx)(Button, { type: "button", variant: "ghost", size: "sm", onClick: onReset, className: "ml-auto", children: resetLabel }),
|
|
6839
|
+
onApply && /* @__PURE__ */ (0, import_jsx_runtime90.jsx)(Button, { type: "button", size: "sm", onClick: onApply, children: applyLabel })
|
|
6353
6840
|
] })
|
|
6354
6841
|
] });
|
|
6355
6842
|
});
|
|
6356
6843
|
|
|
6357
6844
|
// src/components/date-range-picker/DateRangePicker.tsx
|
|
6358
|
-
var
|
|
6359
|
-
var
|
|
6845
|
+
var React92 = __toESM(require("react"));
|
|
6846
|
+
var import_jsx_runtime91 = require("react/jsx-runtime");
|
|
6360
6847
|
var DEFAULT_PRESETS = [
|
|
6361
6848
|
{ label: "7 days", days: 7 },
|
|
6362
6849
|
{ label: "30 days", days: 30 },
|
|
@@ -6369,7 +6856,7 @@ function toIsoDate(date) {
|
|
|
6369
6856
|
const day = String(date.getDate()).padStart(2, "0");
|
|
6370
6857
|
return `${year}-${month}-${day}`;
|
|
6371
6858
|
}
|
|
6372
|
-
var DateRangePicker =
|
|
6859
|
+
var DateRangePicker = React92.forwardRef(
|
|
6373
6860
|
function DateRangePicker2({
|
|
6374
6861
|
value,
|
|
6375
6862
|
defaultValue,
|
|
@@ -6382,9 +6869,9 @@ var DateRangePicker = React87.forwardRef(
|
|
|
6382
6869
|
className,
|
|
6383
6870
|
...props
|
|
6384
6871
|
}, ref) {
|
|
6385
|
-
const startId =
|
|
6386
|
-
const endId =
|
|
6387
|
-
const [internal, setInternal] =
|
|
6872
|
+
const startId = React92.useId();
|
|
6873
|
+
const endId = React92.useId();
|
|
6874
|
+
const [internal, setInternal] = React92.useState(defaultValue ?? {});
|
|
6388
6875
|
const current = value ?? internal;
|
|
6389
6876
|
const commit = (next) => {
|
|
6390
6877
|
if (value === void 0) setInternal(next);
|
|
@@ -6408,8 +6895,8 @@ var DateRangePicker = React87.forwardRef(
|
|
|
6408
6895
|
}
|
|
6409
6896
|
commit({ start: toIsoDate(start), end: toIsoDate(end) });
|
|
6410
6897
|
};
|
|
6411
|
-
return /* @__PURE__ */ (0,
|
|
6412
|
-
showPresets && presets.length > 0 && /* @__PURE__ */ (0,
|
|
6898
|
+
return /* @__PURE__ */ (0, import_jsx_runtime91.jsxs)("div", { ref, className: cn("flex flex-col gap-3", className), ...props, children: [
|
|
6899
|
+
showPresets && presets.length > 0 && /* @__PURE__ */ (0, import_jsx_runtime91.jsx)("div", { className: "flex flex-wrap gap-2", children: presets.map((preset) => /* @__PURE__ */ (0, import_jsx_runtime91.jsx)(
|
|
6413
6900
|
Button,
|
|
6414
6901
|
{
|
|
6415
6902
|
type: "button",
|
|
@@ -6421,10 +6908,10 @@ var DateRangePicker = React87.forwardRef(
|
|
|
6421
6908
|
},
|
|
6422
6909
|
preset.label
|
|
6423
6910
|
)) }),
|
|
6424
|
-
/* @__PURE__ */ (0,
|
|
6425
|
-
/* @__PURE__ */ (0,
|
|
6426
|
-
/* @__PURE__ */ (0,
|
|
6427
|
-
/* @__PURE__ */ (0,
|
|
6911
|
+
/* @__PURE__ */ (0, import_jsx_runtime91.jsxs)("div", { className: "grid gap-3 sm:grid-cols-2", children: [
|
|
6912
|
+
/* @__PURE__ */ (0, import_jsx_runtime91.jsxs)("div", { children: [
|
|
6913
|
+
/* @__PURE__ */ (0, import_jsx_runtime91.jsx)("label", { htmlFor: startId, className: "mb-1 block text-xs font-medium text-muted-foreground", children: startLabel }),
|
|
6914
|
+
/* @__PURE__ */ (0, import_jsx_runtime91.jsx)(
|
|
6428
6915
|
DatePicker,
|
|
6429
6916
|
{
|
|
6430
6917
|
id: startId,
|
|
@@ -6436,9 +6923,9 @@ var DateRangePicker = React87.forwardRef(
|
|
|
6436
6923
|
}
|
|
6437
6924
|
)
|
|
6438
6925
|
] }),
|
|
6439
|
-
/* @__PURE__ */ (0,
|
|
6440
|
-
/* @__PURE__ */ (0,
|
|
6441
|
-
/* @__PURE__ */ (0,
|
|
6926
|
+
/* @__PURE__ */ (0, import_jsx_runtime91.jsxs)("div", { children: [
|
|
6927
|
+
/* @__PURE__ */ (0, import_jsx_runtime91.jsx)("label", { htmlFor: endId, className: "mb-1 block text-xs font-medium text-muted-foreground", children: endLabel }),
|
|
6928
|
+
/* @__PURE__ */ (0, import_jsx_runtime91.jsx)(
|
|
6442
6929
|
DatePicker,
|
|
6443
6930
|
{
|
|
6444
6931
|
id: endId,
|
|
@@ -6456,9 +6943,9 @@ var DateRangePicker = React87.forwardRef(
|
|
|
6456
6943
|
);
|
|
6457
6944
|
|
|
6458
6945
|
// src/components/applied-filters/AppliedFilters.tsx
|
|
6459
|
-
var
|
|
6460
|
-
var
|
|
6461
|
-
var AppliedFilters =
|
|
6946
|
+
var React93 = __toESM(require("react"));
|
|
6947
|
+
var import_jsx_runtime92 = require("react/jsx-runtime");
|
|
6948
|
+
var AppliedFilters = React93.forwardRef(
|
|
6462
6949
|
function AppliedFilters2({
|
|
6463
6950
|
filters,
|
|
6464
6951
|
onClearAll,
|
|
@@ -6471,9 +6958,9 @@ var AppliedFilters = React88.forwardRef(
|
|
|
6471
6958
|
}, ref) {
|
|
6472
6959
|
const summary = label ?? `${filters.length} active`;
|
|
6473
6960
|
if (filters.length === 0) {
|
|
6474
|
-
return emptyLabel ? /* @__PURE__ */ (0,
|
|
6961
|
+
return emptyLabel ? /* @__PURE__ */ (0, import_jsx_runtime92.jsx)("div", { ref, className: cn("text-sm text-muted-foreground", className), ...props, children: emptyLabel }) : null;
|
|
6475
6962
|
}
|
|
6476
|
-
return /* @__PURE__ */ (0,
|
|
6963
|
+
return /* @__PURE__ */ (0, import_jsx_runtime92.jsxs)(
|
|
6477
6964
|
"div",
|
|
6478
6965
|
{
|
|
6479
6966
|
ref,
|
|
@@ -6481,9 +6968,9 @@ var AppliedFilters = React88.forwardRef(
|
|
|
6481
6968
|
className: cn("flex flex-wrap items-center gap-2", className),
|
|
6482
6969
|
...props,
|
|
6483
6970
|
children: [
|
|
6484
|
-
/* @__PURE__ */ (0,
|
|
6485
|
-
/* @__PURE__ */ (0,
|
|
6486
|
-
onEdit && /* @__PURE__ */ (0,
|
|
6971
|
+
/* @__PURE__ */ (0, import_jsx_runtime92.jsx)("span", { className: "text-xs font-medium uppercase tracking-wide text-muted-foreground", children: summary }),
|
|
6972
|
+
/* @__PURE__ */ (0, import_jsx_runtime92.jsx)(FilterChips, { filters, onClearAll }),
|
|
6973
|
+
onEdit && /* @__PURE__ */ (0, import_jsx_runtime92.jsx)(Button, { type: "button", variant: "ghost", size: "sm", onClick: onEdit, children: editLabel })
|
|
6487
6974
|
]
|
|
6488
6975
|
}
|
|
6489
6976
|
);
|
|
@@ -6491,11 +6978,11 @@ var AppliedFilters = React88.forwardRef(
|
|
|
6491
6978
|
);
|
|
6492
6979
|
|
|
6493
6980
|
// src/components/menu/Menu.tsx
|
|
6494
|
-
var
|
|
6981
|
+
var React94 = __toESM(require("react"));
|
|
6495
6982
|
var import_react_dom8 = require("react-dom");
|
|
6496
6983
|
var import_react_slot5 = require("@radix-ui/react-slot");
|
|
6497
|
-
var
|
|
6498
|
-
var MenuContext =
|
|
6984
|
+
var import_jsx_runtime93 = require("react/jsx-runtime");
|
|
6985
|
+
var MenuContext = React94.createContext({
|
|
6499
6986
|
open: false,
|
|
6500
6987
|
setOpen: () => {
|
|
6501
6988
|
},
|
|
@@ -6504,13 +6991,13 @@ var MenuContext = React89.createContext({
|
|
|
6504
6991
|
},
|
|
6505
6992
|
wrapperRef: { current: null }
|
|
6506
6993
|
});
|
|
6507
|
-
var Menu =
|
|
6994
|
+
var Menu = React94.forwardRef(
|
|
6508
6995
|
({ open, onOpenChange, className, children }, ref) => {
|
|
6509
|
-
const [internalOpen, setInternalOpen] =
|
|
6510
|
-
const [activeIndex, setActiveIndex] =
|
|
6996
|
+
const [internalOpen, setInternalOpen] = React94.useState(false);
|
|
6997
|
+
const [activeIndex, setActiveIndex] = React94.useState(-1);
|
|
6511
6998
|
const current = open ?? internalOpen;
|
|
6512
|
-
const wrapperRef =
|
|
6513
|
-
const setRefs =
|
|
6999
|
+
const wrapperRef = React94.useRef(null);
|
|
7000
|
+
const setRefs = React94.useCallback(
|
|
6514
7001
|
(node) => {
|
|
6515
7002
|
wrapperRef.current = node;
|
|
6516
7003
|
if (typeof ref === "function") ref(node);
|
|
@@ -6518,7 +7005,7 @@ var Menu = React89.forwardRef(
|
|
|
6518
7005
|
},
|
|
6519
7006
|
[ref]
|
|
6520
7007
|
);
|
|
6521
|
-
const setOpen =
|
|
7008
|
+
const setOpen = React94.useCallback(
|
|
6522
7009
|
(next) => {
|
|
6523
7010
|
if (open === void 0) setInternalOpen(next);
|
|
6524
7011
|
onOpenChange?.(next);
|
|
@@ -6526,7 +7013,7 @@ var Menu = React89.forwardRef(
|
|
|
6526
7013
|
},
|
|
6527
7014
|
[open, onOpenChange]
|
|
6528
7015
|
);
|
|
6529
|
-
return /* @__PURE__ */ (0,
|
|
7016
|
+
return /* @__PURE__ */ (0, import_jsx_runtime93.jsx)("div", { ref: setRefs, className: cn("relative inline-block", className), children: /* @__PURE__ */ (0, import_jsx_runtime93.jsx)(
|
|
6530
7017
|
MenuContext.Provider,
|
|
6531
7018
|
{
|
|
6532
7019
|
value: { open: current, setOpen, activeIndex, setActiveIndex, wrapperRef },
|
|
@@ -6536,10 +7023,10 @@ var Menu = React89.forwardRef(
|
|
|
6536
7023
|
}
|
|
6537
7024
|
);
|
|
6538
7025
|
Menu.displayName = "Menu";
|
|
6539
|
-
var MenuTrigger =
|
|
7026
|
+
var MenuTrigger = React94.forwardRef(
|
|
6540
7027
|
({ className, children, ...props }, ref) => {
|
|
6541
|
-
const { open, setOpen } =
|
|
6542
|
-
return /* @__PURE__ */ (0,
|
|
7028
|
+
const { open, setOpen } = React94.useContext(MenuContext);
|
|
7029
|
+
return /* @__PURE__ */ (0, import_jsx_runtime93.jsx)(
|
|
6543
7030
|
"button",
|
|
6544
7031
|
{
|
|
6545
7032
|
ref,
|
|
@@ -6559,13 +7046,13 @@ var MenuTrigger = React89.forwardRef(
|
|
|
6559
7046
|
}
|
|
6560
7047
|
);
|
|
6561
7048
|
MenuTrigger.displayName = "MenuTrigger";
|
|
6562
|
-
var MenuContent =
|
|
7049
|
+
var MenuContent = React94.forwardRef(
|
|
6563
7050
|
({ className, children, ...props }, ref) => {
|
|
6564
|
-
const { open, setOpen, activeIndex, setActiveIndex, wrapperRef } =
|
|
6565
|
-
const contentRef =
|
|
6566
|
-
const [pos, setPos] =
|
|
6567
|
-
const itemsRef =
|
|
6568
|
-
|
|
7051
|
+
const { open, setOpen, activeIndex, setActiveIndex, wrapperRef } = React94.useContext(MenuContext);
|
|
7052
|
+
const contentRef = React94.useRef(null);
|
|
7053
|
+
const [pos, setPos] = React94.useState(null);
|
|
7054
|
+
const itemsRef = React94.useRef([]);
|
|
7055
|
+
React94.useLayoutEffect(() => {
|
|
6569
7056
|
if (!open) {
|
|
6570
7057
|
setPos(null);
|
|
6571
7058
|
return;
|
|
@@ -6585,7 +7072,7 @@ var MenuContent = React89.forwardRef(
|
|
|
6585
7072
|
window.removeEventListener("resize", measure);
|
|
6586
7073
|
};
|
|
6587
7074
|
}, [open, setOpen, wrapperRef]);
|
|
6588
|
-
|
|
7075
|
+
React94.useEffect(() => {
|
|
6589
7076
|
if (!open) return;
|
|
6590
7077
|
function onPointerDown(event) {
|
|
6591
7078
|
if (!contentRef.current?.contains(event.target)) setOpen(false);
|
|
@@ -6593,7 +7080,7 @@ var MenuContent = React89.forwardRef(
|
|
|
6593
7080
|
document.addEventListener("pointerdown", onPointerDown);
|
|
6594
7081
|
return () => document.removeEventListener("pointerdown", onPointerDown);
|
|
6595
7082
|
}, [open, setOpen]);
|
|
6596
|
-
|
|
7083
|
+
React94.useEffect(() => {
|
|
6597
7084
|
if (open && pos && contentRef.current) {
|
|
6598
7085
|
itemsRef.current = Array.from(
|
|
6599
7086
|
contentRef.current.querySelectorAll('[role="menuitem"]:not([disabled])')
|
|
@@ -6629,7 +7116,7 @@ var MenuContent = React89.forwardRef(
|
|
|
6629
7116
|
};
|
|
6630
7117
|
if (!open || !pos || typeof document === "undefined") return null;
|
|
6631
7118
|
return (0, import_react_dom8.createPortal)(
|
|
6632
|
-
/* @__PURE__ */ (0,
|
|
7119
|
+
/* @__PURE__ */ (0, import_jsx_runtime93.jsx)(
|
|
6633
7120
|
"div",
|
|
6634
7121
|
{
|
|
6635
7122
|
ref: (node) => {
|
|
@@ -6653,12 +7140,12 @@ var MenuContent = React89.forwardRef(
|
|
|
6653
7140
|
}
|
|
6654
7141
|
);
|
|
6655
7142
|
MenuContent.displayName = "MenuContent";
|
|
6656
|
-
var MenuItem =
|
|
7143
|
+
var MenuItem = React94.forwardRef(
|
|
6657
7144
|
({ className, destructive, asChild = false, onClick, ...props }, ref) => {
|
|
6658
|
-
const { setOpen } =
|
|
7145
|
+
const { setOpen } = React94.useContext(MenuContext);
|
|
6659
7146
|
const Comp = asChild ? import_react_slot5.Slot : "button";
|
|
6660
7147
|
const typeProp = asChild ? {} : { type: "button" };
|
|
6661
|
-
return /* @__PURE__ */ (0,
|
|
7148
|
+
return /* @__PURE__ */ (0, import_jsx_runtime93.jsx)(
|
|
6662
7149
|
Comp,
|
|
6663
7150
|
{
|
|
6664
7151
|
ref,
|
|
@@ -6680,12 +7167,12 @@ var MenuItem = React89.forwardRef(
|
|
|
6680
7167
|
}
|
|
6681
7168
|
);
|
|
6682
7169
|
MenuItem.displayName = "MenuItem";
|
|
6683
|
-
var MenuSeparator =
|
|
6684
|
-
({ className, ...props }, ref) => /* @__PURE__ */ (0,
|
|
7170
|
+
var MenuSeparator = React94.forwardRef(
|
|
7171
|
+
({ className, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime93.jsx)("div", { ref, role: "separator", className: cn("-mx-1 my-1 h-px bg-border", className), ...props })
|
|
6685
7172
|
);
|
|
6686
7173
|
MenuSeparator.displayName = "MenuSeparator";
|
|
6687
|
-
var MenuLabel =
|
|
6688
|
-
({ className, ...props }, ref) => /* @__PURE__ */ (0,
|
|
7174
|
+
var MenuLabel = React94.forwardRef(
|
|
7175
|
+
({ className, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime93.jsx)(
|
|
6689
7176
|
"div",
|
|
6690
7177
|
{
|
|
6691
7178
|
ref,
|
|
@@ -6697,9 +7184,9 @@ var MenuLabel = React89.forwardRef(
|
|
|
6697
7184
|
MenuLabel.displayName = "MenuLabel";
|
|
6698
7185
|
|
|
6699
7186
|
// src/components/alert/Alert.tsx
|
|
6700
|
-
var
|
|
7187
|
+
var React95 = __toESM(require("react"));
|
|
6701
7188
|
var import_class_variance_authority8 = require("class-variance-authority");
|
|
6702
|
-
var
|
|
7189
|
+
var import_jsx_runtime94 = require("react/jsx-runtime");
|
|
6703
7190
|
var alertVariants = (0, import_class_variance_authority8.cva)(
|
|
6704
7191
|
"relative w-full rounded-lg border px-4 py-3 text-sm [&>svg+div]:translate-y-[-3px] [&>svg]:absolute [&>svg]:left-4 [&>svg]:top-4 [&>svg]:text-foreground [&>svg~*]:pl-7",
|
|
6705
7192
|
{
|
|
@@ -6719,8 +7206,8 @@ var alertVariants = (0, import_class_variance_authority8.cva)(
|
|
|
6719
7206
|
}
|
|
6720
7207
|
}
|
|
6721
7208
|
);
|
|
6722
|
-
var Alert =
|
|
6723
|
-
({ className, variant, ...props }, ref) => /* @__PURE__ */ (0,
|
|
7209
|
+
var Alert = React95.forwardRef(
|
|
7210
|
+
({ className, variant, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime94.jsx)(
|
|
6724
7211
|
"div",
|
|
6725
7212
|
{
|
|
6726
7213
|
ref,
|
|
@@ -6731,8 +7218,8 @@ var Alert = React90.forwardRef(
|
|
|
6731
7218
|
)
|
|
6732
7219
|
);
|
|
6733
7220
|
Alert.displayName = "Alert";
|
|
6734
|
-
var AlertTitle =
|
|
6735
|
-
({ className, ...props }, ref) => /* @__PURE__ */ (0,
|
|
7221
|
+
var AlertTitle = React95.forwardRef(
|
|
7222
|
+
({ className, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime94.jsx)(
|
|
6736
7223
|
"h5",
|
|
6737
7224
|
{
|
|
6738
7225
|
ref,
|
|
@@ -6742,8 +7229,8 @@ var AlertTitle = React90.forwardRef(
|
|
|
6742
7229
|
)
|
|
6743
7230
|
);
|
|
6744
7231
|
AlertTitle.displayName = "AlertTitle";
|
|
6745
|
-
var AlertDescription =
|
|
6746
|
-
({ className, ...props }, ref) => /* @__PURE__ */ (0,
|
|
7232
|
+
var AlertDescription = React95.forwardRef(
|
|
7233
|
+
({ className, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime94.jsx)(
|
|
6747
7234
|
"div",
|
|
6748
7235
|
{
|
|
6749
7236
|
ref,
|
|
@@ -6755,23 +7242,23 @@ var AlertDescription = React90.forwardRef(
|
|
|
6755
7242
|
AlertDescription.displayName = "AlertDescription";
|
|
6756
7243
|
|
|
6757
7244
|
// src/components/breadcrumb/Breadcrumb.tsx
|
|
6758
|
-
var
|
|
6759
|
-
var
|
|
6760
|
-
var Breadcrumb =
|
|
7245
|
+
var React96 = __toESM(require("react"));
|
|
7246
|
+
var import_jsx_runtime95 = require("react/jsx-runtime");
|
|
7247
|
+
var Breadcrumb = React96.forwardRef(
|
|
6761
7248
|
({ items, label = "Breadcrumb", separator = "/", onItemClick, linkComponent, linkHrefProp = "href", truncateCurrent = false, className, ...props }, ref) => {
|
|
6762
7249
|
const LinkEl = linkComponent ?? "a";
|
|
6763
|
-
return /* @__PURE__ */ (0,
|
|
7250
|
+
return /* @__PURE__ */ (0, import_jsx_runtime95.jsx)(
|
|
6764
7251
|
"nav",
|
|
6765
7252
|
{
|
|
6766
7253
|
ref,
|
|
6767
7254
|
"aria-label": label,
|
|
6768
7255
|
className: cn("flex items-center space-x-1.5 text-sm text-muted-foreground", className),
|
|
6769
7256
|
...props,
|
|
6770
|
-
children: /* @__PURE__ */ (0,
|
|
7257
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime95.jsx)("ol", { className: "flex flex-wrap items-center space-x-1.5", children: items.map((item, index) => {
|
|
6771
7258
|
const isLast = index === items.length - 1;
|
|
6772
|
-
return /* @__PURE__ */ (0,
|
|
6773
|
-
index > 0 && /* @__PURE__ */ (0,
|
|
6774
|
-
item.href && !isLast ? /* @__PURE__ */ (0,
|
|
7259
|
+
return /* @__PURE__ */ (0, import_jsx_runtime95.jsxs)("li", { className: cn("flex items-center space-x-1.5", truncateCurrent && isLast && "min-w-0"), children: [
|
|
7260
|
+
index > 0 && /* @__PURE__ */ (0, import_jsx_runtime95.jsx)("span", { "aria-hidden": "true", className: "text-muted-foreground/50", children: separator }),
|
|
7261
|
+
item.href && !isLast ? /* @__PURE__ */ (0, import_jsx_runtime95.jsx)(
|
|
6775
7262
|
LinkEl,
|
|
6776
7263
|
{
|
|
6777
7264
|
...linkHrefProp === "to" ? { to: item.href } : { href: item.href },
|
|
@@ -6782,7 +7269,7 @@ var Breadcrumb = React91.forwardRef(
|
|
|
6782
7269
|
} : void 0,
|
|
6783
7270
|
children: item.label
|
|
6784
7271
|
}
|
|
6785
|
-
) : /* @__PURE__ */ (0,
|
|
7272
|
+
) : /* @__PURE__ */ (0, import_jsx_runtime95.jsx)(
|
|
6786
7273
|
"span",
|
|
6787
7274
|
{
|
|
6788
7275
|
"aria-current": isLast ? "page" : void 0,
|
|
@@ -6838,6 +7325,7 @@ Breadcrumb.displayName = "Breadcrumb";
|
|
|
6838
7325
|
DataTable,
|
|
6839
7326
|
DatePicker,
|
|
6840
7327
|
DateRangePicker,
|
|
7328
|
+
DealCard,
|
|
6841
7329
|
Dialog,
|
|
6842
7330
|
DialogBody,
|
|
6843
7331
|
DialogDescription,
|
|
@@ -6845,8 +7333,10 @@ Breadcrumb.displayName = "Breadcrumb";
|
|
|
6845
7333
|
DialogHeader,
|
|
6846
7334
|
DialogTitle,
|
|
6847
7335
|
Divider,
|
|
7336
|
+
DocumentCard,
|
|
6848
7337
|
Drawer,
|
|
6849
7338
|
EmptyState,
|
|
7339
|
+
EntityCard,
|
|
6850
7340
|
FeatureGrid,
|
|
6851
7341
|
FeatureRow,
|
|
6852
7342
|
Fieldset,
|
|
@@ -6871,6 +7361,7 @@ Breadcrumb.displayName = "Breadcrumb";
|
|
|
6871
7361
|
LinkTabs,
|
|
6872
7362
|
List,
|
|
6873
7363
|
ListItem,
|
|
7364
|
+
LoadMore,
|
|
6874
7365
|
LogoCloud,
|
|
6875
7366
|
Menu,
|
|
6876
7367
|
MenuContent,
|
|
@@ -6888,6 +7379,7 @@ Breadcrumb.displayName = "Breadcrumb";
|
|
|
6888
7379
|
PopoverContent,
|
|
6889
7380
|
PopoverTrigger,
|
|
6890
7381
|
ProcessSteps,
|
|
7382
|
+
ProfileCard,
|
|
6891
7383
|
Progress,
|
|
6892
7384
|
Prose,
|
|
6893
7385
|
Radio,
|
|
@@ -6933,6 +7425,7 @@ Breadcrumb.displayName = "Breadcrumb";
|
|
|
6933
7425
|
Timeline,
|
|
6934
7426
|
ToastProvider,
|
|
6935
7427
|
Toaster,
|
|
7428
|
+
TombstoneCard,
|
|
6936
7429
|
Tooltip,
|
|
6937
7430
|
alertVariants,
|
|
6938
7431
|
badgeVariants,
|