@slipstream-ui/core 0.12.1 → 0.14.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 +208 -4
- package/dist/index.d.ts +208 -4
- package/dist/index.js +471 -11
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +463 -11
- 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/bottom-nav.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/calendar.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/consent-banner.manifest.json +1 -1
- package/dist/manifests/contact-strip.manifest.json +1 -1
- package/dist/manifests/container.manifest.json +1 -1
- package/dist/manifests/cover-image.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-popover.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 +1 -1
- package/dist/manifests/dialog.manifest.json +1 -1
- package/dist/manifests/document-card.manifest.json +1 -1
- package/dist/manifests/drawer.manifest.json +1 -1
- package/dist/manifests/empty-state.manifest.json +1 -1
- package/dist/manifests/entity-card.manifest.json +1 -1
- 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/figure.manifest.json +105 -0
- 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 +1 -1
- package/dist/manifests/icon-button.manifest.json +101 -0
- package/dist/manifests/icon-tile.manifest.json +107 -0
- package/dist/manifests/icon.manifest.json +119 -0
- package/dist/manifests/image.manifest.json +1 -1
- 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-toolbar.manifest.json +1 -1
- package/dist/manifests/list.manifest.json +1 -1
- package/dist/manifests/load-more.manifest.json +1 -1
- package/dist/manifests/logo-cloud.manifest.json +1 -1
- package/dist/manifests/media-card.manifest.json +1 -1
- package/dist/manifests/media.manifest.json +142 -0
- package/dist/manifests/menu.manifest.json +1 -1
- package/dist/manifests/metric-card.manifest.json +1 -1
- package/dist/manifests/month-schedule.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 +1 -1
- 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/social-links.manifest.json +120 -0
- package/dist/manifests/spinner.manifest.json +1 -1
- package/dist/manifests/stat-band.manifest.json +1 -1
- package/dist/manifests/stepper.manifest.json +1 -1
- 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 +1 -1
- 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 +49 -6
- package/dist/manifests/timeline.manifest.json +1 -1
- package/dist/manifests/toast.manifest.json +1 -1
- package/dist/manifests/tombstone-card.manifest.json +1 -1
- package/dist/manifests/tooltip.manifest.json +1 -1
- package/dist/src/components/figure/Figure.d.ts +23 -0
- package/dist/src/components/figure/Figure.js +60 -0
- package/dist/src/components/figure/Figure.js.map +1 -0
- package/dist/src/components/figure/Figure.mjs +26 -0
- package/dist/src/components/figure/Figure.mjs.map +1 -0
- package/dist/src/components/figure/index.d.ts +2 -0
- package/dist/src/components/figure/index.js +29 -0
- package/dist/src/components/figure/index.js.map +1 -0
- package/dist/src/components/figure/index.mjs +5 -0
- package/dist/src/components/figure/index.mjs.map +1 -0
- package/dist/src/components/icon/Icon.d.ts +33 -0
- package/dist/src/components/icon/Icon.js +82 -0
- package/dist/src/components/icon/Icon.js.map +1 -0
- package/dist/src/components/icon/Icon.mjs +47 -0
- package/dist/src/components/icon/Icon.mjs.map +1 -0
- package/dist/src/components/icon/index.d.ts +2 -0
- package/dist/src/components/icon/index.js +31 -0
- package/dist/src/components/icon/index.js.map +1 -0
- package/dist/src/components/icon/index.mjs +6 -0
- package/dist/src/components/icon/index.mjs.map +1 -0
- package/dist/src/components/icon-button/IconButton.d.ts +25 -0
- package/dist/src/components/icon-button/IconButton.js +60 -0
- package/dist/src/components/icon-button/IconButton.js.map +1 -0
- package/dist/src/components/icon-button/IconButton.mjs +26 -0
- package/dist/src/components/icon-button/IconButton.mjs.map +1 -0
- package/dist/src/components/icon-button/index.d.ts +2 -0
- package/dist/src/components/icon-button/index.js +29 -0
- package/dist/src/components/icon-button/index.js.map +1 -0
- package/dist/src/components/icon-button/index.mjs +5 -0
- package/dist/src/components/icon-button/index.mjs.map +1 -0
- package/dist/src/components/icon-tile/IconTile.d.ts +23 -0
- package/dist/src/components/icon-tile/IconTile.js +75 -0
- package/dist/src/components/icon-tile/IconTile.js.map +1 -0
- package/dist/src/components/icon-tile/IconTile.mjs +40 -0
- package/dist/src/components/icon-tile/IconTile.mjs.map +1 -0
- package/dist/src/components/icon-tile/index.d.ts +2 -0
- package/dist/src/components/icon-tile/index.js +31 -0
- package/dist/src/components/icon-tile/index.js.map +1 -0
- package/dist/src/components/icon-tile/index.mjs +6 -0
- package/dist/src/components/icon-tile/index.mjs.map +1 -0
- package/dist/src/components/media/Media.d.ts +48 -0
- package/dist/src/components/media/Media.js +97 -0
- package/dist/src/components/media/Media.js.map +1 -0
- package/dist/src/components/media/Media.mjs +63 -0
- package/dist/src/components/media/Media.mjs.map +1 -0
- package/dist/src/components/media/index.d.ts +2 -0
- package/dist/src/components/media/index.js +29 -0
- package/dist/src/components/media/index.js.map +1 -0
- package/dist/src/components/media/index.mjs +5 -0
- package/dist/src/components/media/index.mjs.map +1 -0
- package/dist/src/components/social-links/SocialLinks.d.ts +34 -0
- package/dist/src/components/social-links/SocialLinks.js +69 -0
- package/dist/src/components/social-links/SocialLinks.js.map +1 -0
- package/dist/src/components/social-links/SocialLinks.mjs +35 -0
- package/dist/src/components/social-links/SocialLinks.mjs.map +1 -0
- package/dist/src/components/social-links/index.d.ts +2 -0
- package/dist/src/components/social-links/index.js +29 -0
- package/dist/src/components/social-links/index.js.map +1 -0
- package/dist/src/components/social-links/index.mjs +5 -0
- package/dist/src/components/social-links/index.mjs.map +1 -0
- package/dist/src/components/time-picker/TimePicker.d.ts +31 -2
- package/dist/src/components/time-picker/TimePicker.js +244 -11
- package/dist/src/components/time-picker/TimePicker.js.map +1 -1
- package/dist/src/components/time-picker/TimePicker.mjs +244 -11
- package/dist/src/components/time-picker/TimePicker.mjs.map +1 -1
- package/dist/src/index.d.ts +6 -0
- package/dist/styles-full.css +1 -1
- package/dist/styles.css +1 -1
- package/package.json +4 -4
- package/src/components/figure/Figure.test.tsx +54 -0
- package/src/components/figure/Figure.tsx +38 -0
- package/src/components/figure/index.ts +2 -0
- package/src/components/icon/Icon.test.tsx +70 -0
- package/src/components/icon/Icon.tsx +61 -0
- package/src/components/icon/index.ts +2 -0
- package/src/components/icon-button/IconButton.test.tsx +76 -0
- package/src/components/icon-button/IconButton.tsx +38 -0
- package/src/components/icon-button/index.ts +2 -0
- package/src/components/icon-tile/IconTile.test.tsx +63 -0
- package/src/components/icon-tile/IconTile.tsx +55 -0
- package/src/components/icon-tile/index.ts +2 -0
- package/src/components/media/Media.test.tsx +53 -0
- package/src/components/media/Media.tsx +92 -0
- package/src/components/media/index.ts +2 -0
- package/src/components/social-links/SocialLinks.test.tsx +59 -0
- package/src/components/social-links/SocialLinks.tsx +73 -0
- package/src/components/social-links/index.ts +2 -0
- package/src/components/time-picker/TimePicker.test.tsx +77 -0
- package/src/components/time-picker/TimePicker.tsx +315 -12
- package/src/index.ts +6 -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/bottom-nav.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/calendar.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/consent-banner.manifest.json +1 -1
- package/src/manifests/contact-strip.manifest.json +1 -1
- package/src/manifests/container.manifest.json +1 -1
- package/src/manifests/cover-image.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-popover.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 +1 -1
- package/src/manifests/dialog.manifest.json +1 -1
- package/src/manifests/document-card.manifest.json +1 -1
- package/src/manifests/drawer.manifest.json +1 -1
- package/src/manifests/empty-state.manifest.json +1 -1
- package/src/manifests/entity-card.manifest.json +1 -1
- 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/figure.manifest.json +105 -0
- 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 +1 -1
- package/src/manifests/icon-button.manifest.json +101 -0
- package/src/manifests/icon-tile.manifest.json +107 -0
- package/src/manifests/icon.manifest.json +119 -0
- package/src/manifests/image.manifest.json +1 -1
- 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-toolbar.manifest.json +1 -1
- package/src/manifests/list.manifest.json +1 -1
- package/src/manifests/load-more.manifest.json +1 -1
- package/src/manifests/logo-cloud.manifest.json +1 -1
- package/src/manifests/media-card.manifest.json +1 -1
- package/src/manifests/media.manifest.json +142 -0
- package/src/manifests/menu.manifest.json +1 -1
- package/src/manifests/metric-card.manifest.json +1 -1
- package/src/manifests/month-schedule.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 +1 -1
- 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/social-links.manifest.json +120 -0
- package/src/manifests/spinner.manifest.json +1 -1
- package/src/manifests/stat-band.manifest.json +1 -1
- package/src/manifests/stepper.manifest.json +1 -1
- 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 +1 -1
- 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 +49 -6
- package/src/manifests/timeline.manifest.json +1 -1
- package/src/manifests/toast.manifest.json +1 -1
- package/src/manifests/tombstone-card.manifest.json +1 -1
- package/src/manifests/tooltip.manifest.json +1 -1
package/dist/index.js
CHANGED
|
@@ -89,6 +89,7 @@ __export(index_exports, {
|
|
|
89
89
|
FeatureGrid: () => FeatureGrid,
|
|
90
90
|
FeatureRow: () => FeatureRow,
|
|
91
91
|
Fieldset: () => Fieldset,
|
|
92
|
+
Figure: () => Figure,
|
|
92
93
|
FileUpload: () => FileUpload,
|
|
93
94
|
FilterBar: () => FilterBar,
|
|
94
95
|
FilterChips: () => FilterChips,
|
|
@@ -102,6 +103,9 @@ __export(index_exports, {
|
|
|
102
103
|
GridItem: () => GridItem,
|
|
103
104
|
Heading: () => Heading,
|
|
104
105
|
Hero: () => Hero,
|
|
106
|
+
Icon: () => Icon,
|
|
107
|
+
IconButton: () => IconButton,
|
|
108
|
+
IconTile: () => IconTile,
|
|
105
109
|
Image: () => Image2,
|
|
106
110
|
Input: () => Input,
|
|
107
111
|
InputGroup: () => InputGroup,
|
|
@@ -114,6 +118,7 @@ __export(index_exports, {
|
|
|
114
118
|
ListToolbar: () => ListToolbar,
|
|
115
119
|
LoadMore: () => LoadMore,
|
|
116
120
|
LogoCloud: () => LogoCloud,
|
|
121
|
+
Media: () => Media,
|
|
117
122
|
MediaCard: () => MediaCard,
|
|
118
123
|
Menu: () => Menu,
|
|
119
124
|
MenuContent: () => MenuContent,
|
|
@@ -153,6 +158,7 @@ __export(index_exports, {
|
|
|
153
158
|
SiteFooter: () => SiteFooter,
|
|
154
159
|
SiteHeader: () => SiteHeader,
|
|
155
160
|
Skeleton: () => Skeleton,
|
|
161
|
+
SocialLinks: () => SocialLinks,
|
|
156
162
|
Spinner: () => Spinner,
|
|
157
163
|
StatBand: () => StatBand,
|
|
158
164
|
Stepper: () => Stepper,
|
|
@@ -186,6 +192,8 @@ __export(index_exports, {
|
|
|
186
192
|
buttonVariants: () => buttonVariants,
|
|
187
193
|
cn: () => cn,
|
|
188
194
|
documentHead: () => documentHead,
|
|
195
|
+
iconTileVariants: () => iconTileVariants,
|
|
196
|
+
iconVariants: () => iconVariants,
|
|
189
197
|
isComponentManifest: () => isComponentManifest,
|
|
190
198
|
resolveGap: () => resolveGap,
|
|
191
199
|
separatorVariants: () => separatorVariants,
|
|
@@ -6377,13 +6385,108 @@ DatePickerPopover.displayName = "DatePickerPopover";
|
|
|
6377
6385
|
// src/components/time-picker/TimePicker.tsx
|
|
6378
6386
|
var React66 = __toESM(require("react"));
|
|
6379
6387
|
var import_jsx_runtime67 = require("react/jsx-runtime");
|
|
6380
|
-
var
|
|
6388
|
+
var pad2 = (n) => String(n).padStart(2, "0");
|
|
6389
|
+
function toMinutes(value) {
|
|
6390
|
+
if (!value) return null;
|
|
6391
|
+
const match = /^(\d{1,2}):(\d{2})/.exec(value.trim());
|
|
6392
|
+
if (!match) return null;
|
|
6393
|
+
const minutes = Number(match[1]) * 60 + Number(match[2]);
|
|
6394
|
+
return minutes >= 0 && minutes <= 1439 ? minutes : null;
|
|
6395
|
+
}
|
|
6396
|
+
function fromMinutes(total) {
|
|
6397
|
+
return `${pad2(Math.floor(total / 60))}:${pad2(total % 60)}`;
|
|
6398
|
+
}
|
|
6399
|
+
function minuteChoices(step) {
|
|
6400
|
+
const out = [];
|
|
6401
|
+
for (let m = 0; m < 60; m += step) out.push(m);
|
|
6402
|
+
return out;
|
|
6403
|
+
}
|
|
6404
|
+
function allowedMinutes(hour24, minBound, maxBound, step) {
|
|
6405
|
+
const base = hour24 * 60;
|
|
6406
|
+
return minuteChoices(step).filter((m) => {
|
|
6407
|
+
const total = base + m;
|
|
6408
|
+
return total >= minBound && total <= maxBound;
|
|
6409
|
+
});
|
|
6410
|
+
}
|
|
6411
|
+
function hourHasValidMinute(hour24, minBound, maxBound, step) {
|
|
6412
|
+
return allowedMinutes(hour24, minBound, maxBound, step).length > 0;
|
|
6413
|
+
}
|
|
6414
|
+
function to12(hour24, minute) {
|
|
6415
|
+
const period = hour24 >= 12 ? "PM" : "AM";
|
|
6416
|
+
const hour12 = hour24 % 12 === 0 ? 12 : hour24 % 12;
|
|
6417
|
+
return { hour12, minute, period };
|
|
6418
|
+
}
|
|
6419
|
+
function from12(hour12, minute, period) {
|
|
6420
|
+
const hour24 = hour12 % 12 + (period === "PM" ? 12 : 0);
|
|
6421
|
+
return hour24 * 60 + minute;
|
|
6422
|
+
}
|
|
6423
|
+
function format12(value) {
|
|
6424
|
+
const total = toMinutes(value);
|
|
6425
|
+
if (total === null) return "";
|
|
6426
|
+
const { hour12, minute, period } = to12(Math.floor(total / 60), total % 60);
|
|
6427
|
+
return `${hour12}:${pad2(minute)} ${period}`;
|
|
6428
|
+
}
|
|
6429
|
+
var PERIODS = ["AM", "PM"];
|
|
6430
|
+
var TimePicker = React66.forwardRef(function TimePicker2({
|
|
6431
|
+
value,
|
|
6432
|
+
defaultValue,
|
|
6433
|
+
onValueChange,
|
|
6434
|
+
onChange,
|
|
6435
|
+
clearable = false,
|
|
6436
|
+
clearLabel = "Clear time",
|
|
6437
|
+
format = "24h",
|
|
6438
|
+
minuteStep = 1,
|
|
6439
|
+
min,
|
|
6440
|
+
max,
|
|
6441
|
+
placeholder,
|
|
6442
|
+
className,
|
|
6443
|
+
name,
|
|
6444
|
+
id,
|
|
6445
|
+
disabled,
|
|
6446
|
+
required,
|
|
6447
|
+
"aria-label": ariaLabel,
|
|
6448
|
+
"aria-describedby": ariaDescribedBy,
|
|
6449
|
+
"aria-invalid": ariaInvalid,
|
|
6450
|
+
...props
|
|
6451
|
+
}, ref) {
|
|
6381
6452
|
const [internal, setInternal] = React66.useState(defaultValue ?? "");
|
|
6382
6453
|
const current = value ?? internal;
|
|
6454
|
+
const step = Math.min(60, Math.max(1, Math.floor(minuteStep)));
|
|
6383
6455
|
const commit = (next) => {
|
|
6384
6456
|
if (value === void 0) setInternal(next);
|
|
6385
6457
|
onValueChange?.(next);
|
|
6386
6458
|
};
|
|
6459
|
+
const clearButton = clearable && current ? /* @__PURE__ */ (0, import_jsx_runtime67.jsx)(
|
|
6460
|
+
"button",
|
|
6461
|
+
{
|
|
6462
|
+
type: "button",
|
|
6463
|
+
onClick: () => commit(""),
|
|
6464
|
+
"aria-label": clearLabel,
|
|
6465
|
+
className: "absolute right-1.5 top-1/2 z-10 inline-flex h-6 w-6 -translate-y-1/2 items-center justify-center rounded text-muted-foreground hover:text-foreground focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring",
|
|
6466
|
+
children: "\u2715"
|
|
6467
|
+
}
|
|
6468
|
+
) : null;
|
|
6469
|
+
if (format === "12h") {
|
|
6470
|
+
return /* @__PURE__ */ (0, import_jsx_runtime67.jsx)(
|
|
6471
|
+
TimePicker12h,
|
|
6472
|
+
{
|
|
6473
|
+
current,
|
|
6474
|
+
commit,
|
|
6475
|
+
clearButton,
|
|
6476
|
+
step,
|
|
6477
|
+
min,
|
|
6478
|
+
max,
|
|
6479
|
+
placeholder: placeholder ?? "Pick a time",
|
|
6480
|
+
className,
|
|
6481
|
+
name,
|
|
6482
|
+
id,
|
|
6483
|
+
disabled,
|
|
6484
|
+
ariaLabel,
|
|
6485
|
+
ariaDescribedBy,
|
|
6486
|
+
ariaInvalid
|
|
6487
|
+
}
|
|
6488
|
+
);
|
|
6489
|
+
}
|
|
6387
6490
|
return /* @__PURE__ */ (0, import_jsx_runtime67.jsxs)("div", { className: cn("relative flex items-center", className), children: [
|
|
6388
6491
|
/* @__PURE__ */ (0, import_jsx_runtime67.jsx)(
|
|
6389
6492
|
Input,
|
|
@@ -6391,6 +6494,17 @@ var TimePicker = React66.forwardRef(function TimePicker2({ value, defaultValue,
|
|
|
6391
6494
|
ref,
|
|
6392
6495
|
type: "time",
|
|
6393
6496
|
value: current,
|
|
6497
|
+
min,
|
|
6498
|
+
max,
|
|
6499
|
+
step: step * 60,
|
|
6500
|
+
placeholder,
|
|
6501
|
+
name,
|
|
6502
|
+
id,
|
|
6503
|
+
disabled,
|
|
6504
|
+
required,
|
|
6505
|
+
"aria-label": ariaLabel,
|
|
6506
|
+
"aria-describedby": ariaDescribedBy,
|
|
6507
|
+
"aria-invalid": ariaInvalid,
|
|
6394
6508
|
onChange: (event) => {
|
|
6395
6509
|
commit(event.target.value);
|
|
6396
6510
|
onChange?.(event);
|
|
@@ -6399,18 +6513,143 @@ var TimePicker = React66.forwardRef(function TimePicker2({ value, defaultValue,
|
|
|
6399
6513
|
...props
|
|
6400
6514
|
}
|
|
6401
6515
|
),
|
|
6402
|
-
|
|
6403
|
-
"button",
|
|
6404
|
-
{
|
|
6405
|
-
type: "button",
|
|
6406
|
-
onClick: () => commit(""),
|
|
6407
|
-
"aria-label": clearLabel,
|
|
6408
|
-
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",
|
|
6409
|
-
children: "\u2715"
|
|
6410
|
-
}
|
|
6411
|
-
)
|
|
6516
|
+
clearButton
|
|
6412
6517
|
] });
|
|
6413
6518
|
});
|
|
6519
|
+
TimePicker.displayName = "TimePicker";
|
|
6520
|
+
function TimePicker12h({
|
|
6521
|
+
current,
|
|
6522
|
+
commit,
|
|
6523
|
+
clearButton,
|
|
6524
|
+
step,
|
|
6525
|
+
min,
|
|
6526
|
+
max,
|
|
6527
|
+
placeholder,
|
|
6528
|
+
className,
|
|
6529
|
+
name,
|
|
6530
|
+
id,
|
|
6531
|
+
disabled,
|
|
6532
|
+
ariaLabel,
|
|
6533
|
+
ariaDescribedBy,
|
|
6534
|
+
ariaInvalid
|
|
6535
|
+
}) {
|
|
6536
|
+
const [open, setOpen] = React66.useState(false);
|
|
6537
|
+
const total = toMinutes(current);
|
|
6538
|
+
const minBound = toMinutes(min) ?? 0;
|
|
6539
|
+
const maxBound = toMinutes(max) ?? 1439;
|
|
6540
|
+
const draft = React66.useMemo(() => {
|
|
6541
|
+
if (total !== null) {
|
|
6542
|
+
const hour242 = Math.floor(total / 60);
|
|
6543
|
+
const { hour12: hour122, minute: minute2, period: period2 } = to12(hour242, total % 60);
|
|
6544
|
+
return { hour12: hour122, minute: minute2, period: period2 };
|
|
6545
|
+
}
|
|
6546
|
+
const anchor = minBound;
|
|
6547
|
+
const hour24 = Math.floor(anchor / 60);
|
|
6548
|
+
const { hour12, minute, period } = to12(hour24, anchor % 60);
|
|
6549
|
+
return { hour12, minute, period };
|
|
6550
|
+
}, [total, minBound]);
|
|
6551
|
+
const minutesFor = (hour12, period) => {
|
|
6552
|
+
const hour24 = hour12 % 12 + (period === "PM" ? 12 : 0);
|
|
6553
|
+
return allowedMinutes(hour24, minBound, maxBound, step);
|
|
6554
|
+
};
|
|
6555
|
+
const hours12 = Array.from({ length: 12 }, (_, i) => i + 1);
|
|
6556
|
+
const hour24Of = (h12, p) => h12 % 12 + (p === "PM" ? 12 : 0);
|
|
6557
|
+
const isHourEnabled = (h12) => minutesFor(h12, draft.period).length > 0;
|
|
6558
|
+
const isPeriodEnabled = (p) => hours12.some((h) => hourHasValidMinute(hour24Of(h, p), minBound, maxBound, step));
|
|
6559
|
+
const minuteOptions = minutesFor(draft.hour12, draft.period);
|
|
6560
|
+
const validMinute = minuteOptions.includes(draft.minute) ? draft.minute : minuteOptions[0];
|
|
6561
|
+
const emit2 = (h12, minute, p) => {
|
|
6562
|
+
commit(fromMinutes(from12(h12, minute, p)));
|
|
6563
|
+
};
|
|
6564
|
+
const onHour = (h12) => {
|
|
6565
|
+
const options = minutesFor(h12, draft.period);
|
|
6566
|
+
if (options.length === 0) return;
|
|
6567
|
+
const minute = options.includes(draft.minute) ? draft.minute : options[0];
|
|
6568
|
+
emit2(h12, minute, draft.period);
|
|
6569
|
+
};
|
|
6570
|
+
const onPeriod = (p) => {
|
|
6571
|
+
let hour = draft.hour12;
|
|
6572
|
+
let options = minutesFor(hour, p);
|
|
6573
|
+
if (options.length === 0) {
|
|
6574
|
+
hour = hours12.find((h) => minutesFor(h, p).length > 0) ?? hour;
|
|
6575
|
+
options = minutesFor(hour, p);
|
|
6576
|
+
if (options.length === 0) return;
|
|
6577
|
+
}
|
|
6578
|
+
const minute = options.includes(draft.minute) ? draft.minute : options[0];
|
|
6579
|
+
emit2(hour, minute, p);
|
|
6580
|
+
};
|
|
6581
|
+
const label = total !== null ? format12(current) : placeholder;
|
|
6582
|
+
return /* @__PURE__ */ (0, import_jsx_runtime67.jsxs)("div", { className: cn("relative flex items-center", className), children: [
|
|
6583
|
+
/* @__PURE__ */ (0, import_jsx_runtime67.jsxs)(Popover, { open, onOpenChange: setOpen, children: [
|
|
6584
|
+
/* @__PURE__ */ (0, import_jsx_runtime67.jsxs)(
|
|
6585
|
+
PopoverTrigger,
|
|
6586
|
+
{
|
|
6587
|
+
id,
|
|
6588
|
+
type: "button",
|
|
6589
|
+
disabled,
|
|
6590
|
+
"aria-label": ariaLabel,
|
|
6591
|
+
"aria-describedby": ariaDescribedBy,
|
|
6592
|
+
"aria-invalid": ariaInvalid,
|
|
6593
|
+
className: cn(
|
|
6594
|
+
"flex h-10 w-full items-center justify-between rounded-md border border-input bg-background px-3 py-2 text-left text-sm",
|
|
6595
|
+
"hover:bg-muted/50 focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring disabled:cursor-not-allowed disabled:opacity-50",
|
|
6596
|
+
total === null && "text-muted-foreground",
|
|
6597
|
+
clearButton && "pr-9"
|
|
6598
|
+
),
|
|
6599
|
+
children: [
|
|
6600
|
+
/* @__PURE__ */ (0, import_jsx_runtime67.jsx)("span", { children: label }),
|
|
6601
|
+
/* @__PURE__ */ (0, import_jsx_runtime67.jsx)("span", { "aria-hidden": "true", className: "text-muted-foreground", children: "\u25BE" })
|
|
6602
|
+
]
|
|
6603
|
+
}
|
|
6604
|
+
),
|
|
6605
|
+
/* @__PURE__ */ (0, import_jsx_runtime67.jsx)(PopoverContent, { side: "bottom", align: "start", matchTriggerWidth: true, className: "p-3", children: /* @__PURE__ */ (0, import_jsx_runtime67.jsxs)("div", { className: "flex items-end gap-2", children: [
|
|
6606
|
+
/* @__PURE__ */ (0, import_jsx_runtime67.jsx)(
|
|
6607
|
+
Select,
|
|
6608
|
+
{
|
|
6609
|
+
label: "Hour",
|
|
6610
|
+
labelHidden: true,
|
|
6611
|
+
className: "flex-1",
|
|
6612
|
+
value: String(draft.hour12),
|
|
6613
|
+
onValueChange: (v) => onHour(Number(Array.isArray(v) ? v[0] : v)),
|
|
6614
|
+
options: hours12.map((h) => ({
|
|
6615
|
+
value: String(h),
|
|
6616
|
+
label: pad2(h),
|
|
6617
|
+
disabled: !isHourEnabled(h)
|
|
6618
|
+
}))
|
|
6619
|
+
}
|
|
6620
|
+
),
|
|
6621
|
+
/* @__PURE__ */ (0, import_jsx_runtime67.jsx)(
|
|
6622
|
+
Select,
|
|
6623
|
+
{
|
|
6624
|
+
label: "Minute",
|
|
6625
|
+
labelHidden: true,
|
|
6626
|
+
className: "flex-1",
|
|
6627
|
+
value: String(validMinute),
|
|
6628
|
+
onValueChange: (v) => emit2(draft.hour12, Number(Array.isArray(v) ? v[0] : v), draft.period),
|
|
6629
|
+
options: minuteOptions.map((m) => ({ value: String(m), label: pad2(m) }))
|
|
6630
|
+
}
|
|
6631
|
+
),
|
|
6632
|
+
/* @__PURE__ */ (0, import_jsx_runtime67.jsx)(
|
|
6633
|
+
Select,
|
|
6634
|
+
{
|
|
6635
|
+
label: "AM or PM",
|
|
6636
|
+
labelHidden: true,
|
|
6637
|
+
className: "flex-1",
|
|
6638
|
+
value: draft.period,
|
|
6639
|
+
onValueChange: (v) => onPeriod(Array.isArray(v) ? v[0] : v),
|
|
6640
|
+
options: PERIODS.map((p) => ({
|
|
6641
|
+
value: p,
|
|
6642
|
+
label: p,
|
|
6643
|
+
disabled: !isPeriodEnabled(p)
|
|
6644
|
+
}))
|
|
6645
|
+
}
|
|
6646
|
+
)
|
|
6647
|
+
] }) })
|
|
6648
|
+
] }),
|
|
6649
|
+
clearButton,
|
|
6650
|
+
name ? /* @__PURE__ */ (0, import_jsx_runtime67.jsx)("input", { type: "hidden", name, value: current }) : null
|
|
6651
|
+
] });
|
|
6652
|
+
}
|
|
6414
6653
|
|
|
6415
6654
|
// src/components/stepper/Stepper.tsx
|
|
6416
6655
|
var React67 = __toESM(require("react"));
|
|
@@ -9101,6 +9340,219 @@ var Breadcrumb = React103.forwardRef(
|
|
|
9101
9340
|
}
|
|
9102
9341
|
);
|
|
9103
9342
|
Breadcrumb.displayName = "Breadcrumb";
|
|
9343
|
+
|
|
9344
|
+
// src/components/icon/Icon.tsx
|
|
9345
|
+
var React104 = __toESM(require("react"));
|
|
9346
|
+
var import_class_variance_authority9 = require("class-variance-authority");
|
|
9347
|
+
var import_jsx_runtime105 = require("react/jsx-runtime");
|
|
9348
|
+
var iconVariants = (0, import_class_variance_authority9.cva)("inline-flex shrink-0 items-center justify-center [&_svg]:shrink-0", {
|
|
9349
|
+
variants: {
|
|
9350
|
+
size: {
|
|
9351
|
+
sm: "[&_svg]:h-3.5 [&_svg]:w-3.5",
|
|
9352
|
+
md: "[&_svg]:h-4 [&_svg]:w-4",
|
|
9353
|
+
lg: "[&_svg]:h-5 [&_svg]:w-5",
|
|
9354
|
+
xl: "[&_svg]:h-6 [&_svg]:w-6"
|
|
9355
|
+
},
|
|
9356
|
+
tone: {
|
|
9357
|
+
default: "text-foreground",
|
|
9358
|
+
muted: "text-muted-foreground",
|
|
9359
|
+
primary: "text-primary-ink",
|
|
9360
|
+
success: "text-success-ink",
|
|
9361
|
+
warning: "text-warning-ink",
|
|
9362
|
+
info: "text-info-ink",
|
|
9363
|
+
destructive: "text-destructive"
|
|
9364
|
+
}
|
|
9365
|
+
},
|
|
9366
|
+
defaultVariants: {
|
|
9367
|
+
size: "md",
|
|
9368
|
+
tone: "default"
|
|
9369
|
+
}
|
|
9370
|
+
});
|
|
9371
|
+
var Icon = React104.forwardRef(
|
|
9372
|
+
({ className, size, tone, icon: IconComponent, label, children, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime105.jsx)(
|
|
9373
|
+
"span",
|
|
9374
|
+
{
|
|
9375
|
+
ref,
|
|
9376
|
+
role: label ? "img" : void 0,
|
|
9377
|
+
"aria-label": label,
|
|
9378
|
+
"aria-hidden": label ? void 0 : true,
|
|
9379
|
+
className: cn(iconVariants({ size, tone }), className),
|
|
9380
|
+
...props,
|
|
9381
|
+
children: IconComponent ? /* @__PURE__ */ (0, import_jsx_runtime105.jsx)(IconComponent, { "aria-hidden": "true", focusable: "false" }) : children
|
|
9382
|
+
}
|
|
9383
|
+
)
|
|
9384
|
+
);
|
|
9385
|
+
Icon.displayName = "Icon";
|
|
9386
|
+
|
|
9387
|
+
// src/components/icon-button/IconButton.tsx
|
|
9388
|
+
var React105 = __toESM(require("react"));
|
|
9389
|
+
var import_jsx_runtime106 = require("react/jsx-runtime");
|
|
9390
|
+
var sizeClasses11 = {
|
|
9391
|
+
sm: "h-8 w-8",
|
|
9392
|
+
md: void 0,
|
|
9393
|
+
lg: "h-11 w-11"
|
|
9394
|
+
};
|
|
9395
|
+
var IconButton = React105.forwardRef(
|
|
9396
|
+
({ className, label, size = "md", ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime106.jsx)(
|
|
9397
|
+
Button,
|
|
9398
|
+
{
|
|
9399
|
+
ref,
|
|
9400
|
+
size: "icon",
|
|
9401
|
+
"aria-label": label,
|
|
9402
|
+
className: cn(sizeClasses11[size], className),
|
|
9403
|
+
...props
|
|
9404
|
+
}
|
|
9405
|
+
)
|
|
9406
|
+
);
|
|
9407
|
+
IconButton.displayName = "IconButton";
|
|
9408
|
+
|
|
9409
|
+
// src/components/icon-tile/IconTile.tsx
|
|
9410
|
+
var React106 = __toESM(require("react"));
|
|
9411
|
+
var import_class_variance_authority10 = require("class-variance-authority");
|
|
9412
|
+
var import_jsx_runtime107 = require("react/jsx-runtime");
|
|
9413
|
+
var iconTileVariants = (0, import_class_variance_authority10.cva)(
|
|
9414
|
+
"relative inline-flex shrink-0 items-center justify-center rounded-lg [&_svg]:shrink-0",
|
|
9415
|
+
{
|
|
9416
|
+
variants: {
|
|
9417
|
+
tone: {
|
|
9418
|
+
default: "bg-muted text-muted-foreground",
|
|
9419
|
+
primary: "bg-primary/10 text-primary-ink",
|
|
9420
|
+
success: "bg-success/10 text-success-ink",
|
|
9421
|
+
warning: "bg-warning/10 text-warning-ink",
|
|
9422
|
+
info: "bg-info/10 text-info-ink",
|
|
9423
|
+
destructive: "bg-destructive/10 text-destructive"
|
|
9424
|
+
},
|
|
9425
|
+
size: {
|
|
9426
|
+
sm: "h-8 w-8 [&_svg]:h-4 [&_svg]:w-4",
|
|
9427
|
+
md: "h-10 w-10 [&_svg]:h-5 [&_svg]:w-5",
|
|
9428
|
+
lg: "h-12 w-12 [&_svg]:h-6 [&_svg]:w-6"
|
|
9429
|
+
}
|
|
9430
|
+
},
|
|
9431
|
+
defaultVariants: {
|
|
9432
|
+
tone: "default",
|
|
9433
|
+
size: "md"
|
|
9434
|
+
}
|
|
9435
|
+
}
|
|
9436
|
+
);
|
|
9437
|
+
var IconTile = React106.forwardRef(
|
|
9438
|
+
({ className, tone, size, badge, children, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime107.jsxs)("span", { ref, className: cn(iconTileVariants({ tone, size }), className), ...props, children: [
|
|
9439
|
+
children,
|
|
9440
|
+
badge !== void 0 && badge !== null && /* @__PURE__ */ (0, import_jsx_runtime107.jsx)("span", { className: "absolute -right-1.5 -top-1.5 flex h-4 min-w-4 items-center justify-center rounded-full bg-primary px-1 text-[10px] font-semibold leading-none text-primary-foreground", children: badge })
|
|
9441
|
+
] })
|
|
9442
|
+
);
|
|
9443
|
+
IconTile.displayName = "IconTile";
|
|
9444
|
+
|
|
9445
|
+
// src/components/social-links/SocialLinks.tsx
|
|
9446
|
+
var React107 = __toESM(require("react"));
|
|
9447
|
+
var import_jsx_runtime108 = require("react/jsx-runtime");
|
|
9448
|
+
function isElement(icon) {
|
|
9449
|
+
return React107.isValidElement(icon);
|
|
9450
|
+
}
|
|
9451
|
+
var SocialLinks = React107.forwardRef(
|
|
9452
|
+
({ className, links, label = "Social links", iconSize = "md", iconTone = "muted", ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime108.jsx)("nav", { ref, "aria-label": label, className: cn("flex items-center gap-1", className), ...props, children: /* @__PURE__ */ (0, import_jsx_runtime108.jsx)("ul", { className: "flex items-center gap-1", children: links.map((link) => /* @__PURE__ */ (0, import_jsx_runtime108.jsx)("li", { children: /* @__PURE__ */ (0, import_jsx_runtime108.jsx)(
|
|
9453
|
+
"a",
|
|
9454
|
+
{
|
|
9455
|
+
href: link.href,
|
|
9456
|
+
target: "_blank",
|
|
9457
|
+
rel: "noopener noreferrer",
|
|
9458
|
+
"aria-label": link.icon ? link.label : void 0,
|
|
9459
|
+
className: cn(
|
|
9460
|
+
"inline-flex items-center justify-center rounded-md text-muted-foreground transition-colors hover:bg-accent hover:text-accent-foreground focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring",
|
|
9461
|
+
link.icon ? "h-9 w-9" : "px-3 py-1.5 text-sm"
|
|
9462
|
+
),
|
|
9463
|
+
children: link.icon ? isElement(link.icon) ? /* @__PURE__ */ (0, import_jsx_runtime108.jsx)(Icon, { size: iconSize, tone: iconTone, children: link.icon }) : /* @__PURE__ */ (0, import_jsx_runtime108.jsx)(
|
|
9464
|
+
Icon,
|
|
9465
|
+
{
|
|
9466
|
+
size: iconSize,
|
|
9467
|
+
tone: iconTone,
|
|
9468
|
+
icon: link.icon
|
|
9469
|
+
}
|
|
9470
|
+
) : link.label
|
|
9471
|
+
}
|
|
9472
|
+
) }, link.href)) }) })
|
|
9473
|
+
);
|
|
9474
|
+
SocialLinks.displayName = "SocialLinks";
|
|
9475
|
+
|
|
9476
|
+
// src/components/figure/Figure.tsx
|
|
9477
|
+
var React108 = __toESM(require("react"));
|
|
9478
|
+
var import_jsx_runtime109 = require("react/jsx-runtime");
|
|
9479
|
+
var Figure = React108.forwardRef(
|
|
9480
|
+
({ className, caption, credit, align = "left", children, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime109.jsxs)("figure", { ref, className: cn("m-0", className), ...props, children: [
|
|
9481
|
+
children,
|
|
9482
|
+
(caption || credit) && /* @__PURE__ */ (0, import_jsx_runtime109.jsxs)(
|
|
9483
|
+
"figcaption",
|
|
9484
|
+
{
|
|
9485
|
+
className: cn(
|
|
9486
|
+
"mt-2 text-xs text-muted-foreground",
|
|
9487
|
+
align === "center" && "text-center"
|
|
9488
|
+
),
|
|
9489
|
+
children: [
|
|
9490
|
+
caption,
|
|
9491
|
+
credit && /* @__PURE__ */ (0, import_jsx_runtime109.jsx)("span", { className: "mt-0.5 block text-muted-foreground/80", children: credit })
|
|
9492
|
+
]
|
|
9493
|
+
}
|
|
9494
|
+
)
|
|
9495
|
+
] })
|
|
9496
|
+
);
|
|
9497
|
+
Figure.displayName = "Figure";
|
|
9498
|
+
|
|
9499
|
+
// src/components/media/Media.tsx
|
|
9500
|
+
var React109 = __toESM(require("react"));
|
|
9501
|
+
var import_jsx_runtime110 = require("react/jsx-runtime");
|
|
9502
|
+
var aspectClasses2 = {
|
|
9503
|
+
video: "aspect-video",
|
|
9504
|
+
square: "aspect-square",
|
|
9505
|
+
wide: "aspect-[2/1]"
|
|
9506
|
+
};
|
|
9507
|
+
var Media = React109.forwardRef(
|
|
9508
|
+
({
|
|
9509
|
+
className,
|
|
9510
|
+
aspect = "video",
|
|
9511
|
+
src,
|
|
9512
|
+
alt = "",
|
|
9513
|
+
sizes,
|
|
9514
|
+
priority = false,
|
|
9515
|
+
fallback,
|
|
9516
|
+
caption,
|
|
9517
|
+
credit,
|
|
9518
|
+
align,
|
|
9519
|
+
children,
|
|
9520
|
+
...props
|
|
9521
|
+
}, ref) => {
|
|
9522
|
+
const preset = aspectClasses2[aspect];
|
|
9523
|
+
const aspectStyle = preset === void 0 && typeof aspect === "string" ? { aspectRatio: aspect } : void 0;
|
|
9524
|
+
return /* @__PURE__ */ (0, import_jsx_runtime110.jsx)(
|
|
9525
|
+
Figure,
|
|
9526
|
+
{
|
|
9527
|
+
ref,
|
|
9528
|
+
caption,
|
|
9529
|
+
credit,
|
|
9530
|
+
align,
|
|
9531
|
+
className,
|
|
9532
|
+
...props,
|
|
9533
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime110.jsx)(
|
|
9534
|
+
"div",
|
|
9535
|
+
{
|
|
9536
|
+
className: cn("relative overflow-hidden rounded-lg bg-muted", preset),
|
|
9537
|
+
style: aspectStyle,
|
|
9538
|
+
children: src ? /* @__PURE__ */ (0, import_jsx_runtime110.jsx)(
|
|
9539
|
+
Image2,
|
|
9540
|
+
{
|
|
9541
|
+
src,
|
|
9542
|
+
alt,
|
|
9543
|
+
priority,
|
|
9544
|
+
sizes,
|
|
9545
|
+
fallback,
|
|
9546
|
+
className: "h-full w-full object-cover"
|
|
9547
|
+
}
|
|
9548
|
+
) : children ?? fallback
|
|
9549
|
+
}
|
|
9550
|
+
)
|
|
9551
|
+
}
|
|
9552
|
+
);
|
|
9553
|
+
}
|
|
9554
|
+
);
|
|
9555
|
+
Media.displayName = "Media";
|
|
9104
9556
|
// Annotate the CommonJS export names for ESM import in node:
|
|
9105
9557
|
0 && (module.exports = {
|
|
9106
9558
|
Accordion,
|
|
@@ -9162,6 +9614,7 @@ Breadcrumb.displayName = "Breadcrumb";
|
|
|
9162
9614
|
FeatureGrid,
|
|
9163
9615
|
FeatureRow,
|
|
9164
9616
|
Fieldset,
|
|
9617
|
+
Figure,
|
|
9165
9618
|
FileUpload,
|
|
9166
9619
|
FilterBar,
|
|
9167
9620
|
FilterChips,
|
|
@@ -9175,6 +9628,9 @@ Breadcrumb.displayName = "Breadcrumb";
|
|
|
9175
9628
|
GridItem,
|
|
9176
9629
|
Heading,
|
|
9177
9630
|
Hero,
|
|
9631
|
+
Icon,
|
|
9632
|
+
IconButton,
|
|
9633
|
+
IconTile,
|
|
9178
9634
|
Image,
|
|
9179
9635
|
Input,
|
|
9180
9636
|
InputGroup,
|
|
@@ -9187,6 +9643,7 @@ Breadcrumb.displayName = "Breadcrumb";
|
|
|
9187
9643
|
ListToolbar,
|
|
9188
9644
|
LoadMore,
|
|
9189
9645
|
LogoCloud,
|
|
9646
|
+
Media,
|
|
9190
9647
|
MediaCard,
|
|
9191
9648
|
Menu,
|
|
9192
9649
|
MenuContent,
|
|
@@ -9226,6 +9683,7 @@ Breadcrumb.displayName = "Breadcrumb";
|
|
|
9226
9683
|
SiteFooter,
|
|
9227
9684
|
SiteHeader,
|
|
9228
9685
|
Skeleton,
|
|
9686
|
+
SocialLinks,
|
|
9229
9687
|
Spinner,
|
|
9230
9688
|
StatBand,
|
|
9231
9689
|
Stepper,
|
|
@@ -9259,6 +9717,8 @@ Breadcrumb.displayName = "Breadcrumb";
|
|
|
9259
9717
|
buttonVariants,
|
|
9260
9718
|
cn,
|
|
9261
9719
|
documentHead,
|
|
9720
|
+
iconTileVariants,
|
|
9721
|
+
iconVariants,
|
|
9262
9722
|
isComponentManifest,
|
|
9263
9723
|
resolveGap,
|
|
9264
9724
|
separatorVariants,
|