@sdxc/ui 2026.10.30 → 2026.11.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +187 -113
- package/dist/app/app-shell-toggle.d.ts +31 -0
- package/dist/app/app-shell-toggle.js +43 -0
- package/dist/app/app-shell.d.ts +131 -0
- package/dist/app/app-shell.js +542 -0
- package/dist/app/auto-refresh.d.ts +104 -0
- package/dist/app/auto-refresh.js +126 -0
- package/dist/{behaviors → app/behaviors}/drag-session.js +1 -1
- package/dist/app/behaviors/refresh-schedule.d.ts +53 -0
- package/dist/app/behaviors/refresh-schedule.js +95 -0
- package/dist/app/behaviors/shortcuts.d.ts +175 -0
- package/dist/app/behaviors/shortcuts.js +401 -0
- package/dist/{behaviors → app/behaviors}/toaster.d.ts +31 -2
- package/dist/{behaviors → app/behaviors}/toaster.js +63 -6
- package/dist/{components → app}/chart.d.ts +63 -9
- package/dist/{components → app}/chart.js +222 -40
- package/dist/app/command-palette.d.ts +132 -0
- package/dist/app/command-palette.js +181 -0
- package/dist/{components → app}/context-menu.d.ts +2 -2
- package/dist/{components → app}/context-menu.js +8 -7
- package/dist/app/danger-zone.d.ts +66 -0
- package/dist/app/danger-zone.js +66 -0
- package/dist/app/detail-sheet.d.ts +119 -0
- package/dist/app/detail-sheet.js +173 -0
- package/dist/{components → app}/drop-indicator.js +3 -3
- package/dist/{components → app}/drop-zone.d.ts +2 -1
- package/dist/{components → app}/drop-zone.js +7 -4
- package/dist/app/editor-layout.d.ts +69 -0
- package/dist/app/editor-layout.js +143 -0
- package/dist/app/empty.d.ts +128 -0
- package/dist/app/empty.js +248 -0
- package/dist/{components → app}/file-trigger.js +2 -2
- package/dist/app/filter-bar.d.ts +169 -0
- package/dist/app/filter-bar.js +346 -0
- package/dist/{components → app}/grid-list.d.ts +1 -1
- package/dist/{components → app}/grid-list.js +16 -18
- package/dist/app/index.d.ts +92 -0
- package/dist/app/index.js +92 -0
- package/dist/app/keyboard-help.d.ts +66 -0
- package/dist/app/keyboard-help.js +56 -0
- package/dist/{components → app}/menubar.js +5 -7
- package/dist/app/mixins/app-shell-controls.d.ts +46 -0
- package/dist/app/mixins/app-shell-controls.js +131 -0
- package/dist/app/mixins/auto-refresh.d.ts +29 -0
- package/dist/app/mixins/auto-refresh.js +66 -0
- package/dist/app/mixins/command-palette.d.ts +56 -0
- package/dist/app/mixins/command-palette.js +297 -0
- package/dist/app/mixins/copy-permalink.d.ts +26 -0
- package/dist/app/mixins/copy-permalink.js +54 -0
- package/dist/app/mixins/detail-sheet-keys.d.ts +28 -0
- package/dist/app/mixins/detail-sheet-keys.js +88 -0
- package/dist/{mixins → app/mixins}/drag-reorder.js +1 -1
- package/dist/{mixins → app/mixins}/drop-zone.js +1 -1
- package/dist/app/mixins/escape-link.d.ts +17 -0
- package/dist/app/mixins/escape-link.js +35 -0
- package/dist/{mixins → app/mixins}/grid-list-keys.js +2 -2
- package/dist/app/mixins/keyboard-help.d.ts +38 -0
- package/dist/app/mixins/keyboard-help.js +51 -0
- package/dist/{mixins → app/mixins}/menubar-keys.js +2 -2
- package/dist/app/mixins/optimistic-toggle-sync.d.ts +80 -0
- package/dist/app/mixins/optimistic-toggle-sync.js +153 -0
- package/dist/app/mixins/range-picker-keys.d.ts +18 -0
- package/dist/app/mixins/range-picker-keys.js +94 -0
- package/dist/{mixins → app/mixins}/resize-handle.js +3 -3
- package/dist/app/mixins/row-navigation.d.ts +85 -0
- package/dist/app/mixins/row-navigation.js +208 -0
- package/dist/app/mixins/save-bar-sync.d.ts +27 -0
- package/dist/app/mixins/save-bar-sync.js +106 -0
- package/dist/app/mixins/save-shortcut.d.ts +47 -0
- package/dist/app/mixins/save-shortcut.js +101 -0
- package/dist/app/mixins/save-status-sync.d.ts +77 -0
- package/dist/app/mixins/save-status-sync.js +159 -0
- package/dist/app/mixins/selection-bar-sync.d.ts +32 -0
- package/dist/app/mixins/selection-bar-sync.js +151 -0
- package/dist/app/mixins/split-view.d.ts +66 -0
- package/dist/app/mixins/split-view.js +319 -0
- package/dist/app/mixins/status-strip-keys.d.ts +17 -0
- package/dist/app/mixins/status-strip-keys.js +79 -0
- package/dist/app/mixins/submit-on-change.d.ts +16 -0
- package/dist/app/mixins/submit-on-change.js +28 -0
- package/dist/app/mixins/table-selection.d.ts +39 -0
- package/dist/app/mixins/table-selection.js +272 -0
- package/dist/app/mixins/toast-queue.d.ts +36 -0
- package/dist/app/mixins/toast-queue.js +77 -0
- package/dist/app/mixins/toast-stack.d.ts +20 -0
- package/dist/app/mixins/toast-stack.js +55 -0
- package/dist/{mixins/treeKeys.js → app/mixins/tree-keys.js} +2 -2
- package/dist/app/optimistic-toggle.d.ts +48 -0
- package/dist/app/optimistic-toggle.js +38 -0
- package/dist/app/page-header.d.ts +71 -0
- package/dist/app/page-header.js +249 -0
- package/dist/app/range-picker.d.ts +102 -0
- package/dist/app/range-picker.js +118 -0
- package/dist/{components → app}/resizable.js +7 -10
- package/dist/app/save-bar.d.ts +54 -0
- package/dist/app/save-bar.js +64 -0
- package/dist/app/save-status.d.ts +50 -0
- package/dist/app/save-status.js +54 -0
- package/dist/app/selection-bar.d.ts +101 -0
- package/dist/app/selection-bar.js +157 -0
- package/dist/app/settings-layout.d.ts +70 -0
- package/dist/app/settings-layout.js +112 -0
- package/dist/app/settings-section.d.ts +140 -0
- package/dist/app/settings-section.js +182 -0
- package/dist/{components → app}/shortcut-list.js +4 -3
- package/dist/app/skeleton.d.ts +79 -0
- package/dist/app/skeleton.js +185 -0
- package/dist/app/sparkline.d.ts +61 -0
- package/dist/app/sparkline.js +145 -0
- package/dist/app/split-view.d.ts +154 -0
- package/dist/app/split-view.js +272 -0
- package/dist/app/stat-card.d.ts +109 -0
- package/dist/app/stat-card.js +379 -0
- package/dist/app/status-strip.d.ts +70 -0
- package/dist/app/status-strip.js +155 -0
- package/dist/app/styles/action-row.d.ts +41 -0
- package/dist/app/styles/action-row.js +59 -0
- package/dist/{styles → app/styles}/chart-palette.d.ts +1 -1
- package/dist/{styles → app/styles}/graphic-host.d.ts +1 -1
- package/dist/{styles → app/styles}/legend-toggle.d.ts +1 -1
- package/dist/app/styles/stat-delta.d.ts +29 -0
- package/dist/app/styles/stat-delta.js +36 -0
- package/dist/app/styles/toast-stack.d.ts +21 -0
- package/dist/app/styles/toast-stack.js +54 -0
- package/dist/app/table.d.ts +327 -0
- package/dist/app/table.js +839 -0
- package/dist/{components → app}/toast.d.ts +105 -5
- package/dist/{components → app}/toast.js +101 -35
- package/dist/app/toasts.d.ts +49 -0
- package/dist/app/toasts.js +103 -0
- package/dist/{components → app}/toolbar.js +3 -3
- package/dist/{components → app}/tree.d.ts +1 -1
- package/dist/{components → app}/tree.js +10 -14
- package/dist/app/utils/app-shell-cookie.d.ts +21 -0
- package/dist/app/utils/app-shell-cookie.js +33 -0
- package/dist/{utils → app/utils}/chart-marker-indices.d.ts +9 -5
- package/dist/{utils → app/utils}/chart-marker-indices.js +9 -8
- package/dist/{utils → app/utils}/chart-path.d.ts +15 -11
- package/dist/{utils → app/utils}/chart-path.js +48 -20
- package/dist/{utils → app/utils}/chart-scale.js +1 -1
- package/dist/app/utils/edited-time.d.ts +19 -0
- package/dist/app/utils/edited-time.js +35 -0
- package/dist/app/utils/key-target.d.ts +23 -0
- package/dist/app/utils/key-target.js +48 -0
- package/dist/app/utils/search-params.d.ts +69 -0
- package/dist/app/utils/search-params.js +132 -0
- package/dist/app/utils/shortcut-groups.d.ts +21 -0
- package/dist/app/utils/shortcut-groups.js +53 -0
- package/dist/app/utils/split-view-layout.d.ts +48 -0
- package/dist/app/utils/split-view-layout.js +71 -0
- package/dist/app/view-options.d.ts +99 -0
- package/dist/app/view-options.js +182 -0
- package/dist/behaviors/index.d.ts +0 -5
- package/dist/behaviors/index.js +0 -5
- package/dist/{components → chat}/attachment.d.ts +1 -1
- package/dist/{components → chat}/attachment.js +17 -23
- package/dist/{behaviors → chat/behaviors}/scroll-follow-model.js +1 -1
- package/dist/{components → chat}/bubble.js +14 -14
- package/dist/chat/index.d.ts +16 -0
- package/dist/chat/index.js +16 -0
- package/dist/{components → chat}/marker.js +6 -8
- package/dist/{components → chat}/message-scroller.d.ts +1 -1
- package/dist/{components → chat}/message-scroller.js +12 -18
- package/dist/{components → chat}/message.js +10 -12
- package/dist/{mixins → chat/mixins}/message-follow.js +2 -2
- package/dist/{components → color}/color-area.js +7 -10
- package/dist/{components → color}/color-field.js +7 -6
- package/dist/{components → color}/color-picker.d.ts +1 -1
- package/dist/{components → color}/color-picker.js +9 -12
- package/dist/{components → color}/color-slider.js +10 -13
- package/dist/{components → color}/color-swatch-picker.js +4 -5
- package/dist/{components → color}/color-swatch.js +3 -4
- package/dist/{components → color}/color-wheel.js +5 -6
- package/dist/color/index.d.ts +21 -0
- package/dist/color/index.js +21 -0
- package/dist/{mixins → color/mixins}/color-area-drag.d.ts +1 -1
- package/dist/{mixins → color/mixins}/color-area-drag.js +2 -2
- package/dist/{mixins → color/mixins}/color-preview.js +1 -1
- package/dist/{mixins → color/mixins}/color-wheel-drag.js +1 -1
- package/dist/{styles → color/styles}/rtl-aware-gradient-direction.d.ts +1 -1
- package/dist/components/accordion.d.ts +3 -3
- package/dist/components/accordion.js +19 -15
- package/dist/components/alert-dialog.js +5 -4
- package/dist/components/alert.js +10 -20
- package/dist/components/aspect-ratio.js +3 -4
- package/dist/components/avatar.d.ts +6 -6
- package/dist/components/avatar.js +56 -8
- package/dist/components/badge.js +11 -9
- package/dist/components/banner.d.ts +61 -0
- package/dist/components/banner.js +101 -0
- package/dist/components/breadcrumbs.js +7 -9
- package/dist/components/button.d.ts +8 -6
- package/dist/components/button.js +22 -14
- package/dist/components/calendar.js +13 -24
- package/dist/components/card.js +9 -11
- package/dist/components/carousel.d.ts +1 -1
- package/dist/components/carousel.js +12 -20
- package/dist/components/checkbox-group.js +3 -3
- package/dist/components/checkbox.js +2 -2
- package/dist/components/combobox.js +6 -6
- package/dist/components/command.js +10 -14
- package/dist/components/confirm.d.ts +54 -5
- package/dist/components/confirm.js +44 -5
- package/dist/components/cta-group.d.ts +30 -14
- package/dist/components/cta-group.js +29 -10
- package/dist/components/date-field.js +2 -1
- package/dist/components/date-picker.js +4 -5
- package/dist/components/date-range-picker.js +3 -2
- package/dist/components/description.js +2 -1
- package/dist/components/dialog-dismiss.d.ts +18 -0
- package/dist/components/dialog-dismiss.js +15 -0
- package/dist/components/dialog.js +11 -15
- package/dist/components/disclosure.js +10 -14
- package/dist/components/drawer.js +3 -4
- package/dist/components/field-error.js +3 -3
- package/dist/components/form.js +2 -1
- package/dist/components/group.d.ts +14 -0
- package/dist/components/group.js +68 -13
- package/dist/components/header.js +3 -3
- package/dist/components/heading-scope.js +2 -1
- package/dist/components/heading.d.ts +4 -4
- package/dist/components/heading.js +7 -7
- package/dist/components/highlight.js +17 -12
- package/dist/components/hover-card.js +6 -8
- package/dist/components/image-placeholder.js +13 -19
- package/dist/components/index.d.ts +11 -38
- package/dist/components/index.js +11 -38
- package/dist/components/input.js +12 -7
- package/dist/components/item.js +10 -19
- package/dist/components/keyboard.js +3 -3
- package/dist/components/label.js +2 -1
- package/dist/components/link-button.d.ts +7 -5
- package/dist/components/link-button.js +24 -13
- package/dist/components/link.js +3 -4
- package/dist/components/listbox.js +6 -11
- package/dist/components/menu.js +5 -6
- package/dist/components/meter.js +5 -6
- package/dist/components/modal.js +9 -11
- package/dist/components/nav-link.d.ts +1 -1
- package/dist/components/nav-link.js +3 -4
- package/dist/components/navigation-menu.js +17 -23
- package/dist/components/number-field.js +8 -10
- package/dist/components/otp-field.js +2 -1
- package/dist/components/overlay-arrow.js +3 -4
- package/dist/components/pagination.js +8 -10
- package/dist/components/popover.js +3 -4
- package/dist/components/progress-bar.js +5 -5
- package/dist/components/property-list.d.ts +76 -0
- package/dist/components/property-list.js +175 -0
- package/dist/components/radio-group.js +5 -7
- package/dist/components/range-calendar.js +3 -3
- package/dist/components/relative-time.d.ts +72 -0
- package/dist/components/relative-time.js +45 -0
- package/dist/components/scroll-area.js +4 -5
- package/dist/components/search-field.js +8 -11
- package/dist/components/section.js +2 -1
- package/dist/components/select.js +10 -22
- package/dist/components/selection-indicator.js +3 -3
- package/dist/components/sentinel-row.js +3 -3
- package/dist/components/separator.js +3 -3
- package/dist/components/shared-element.js +2 -1
- package/dist/components/sheet.js +6 -7
- package/dist/components/sidebar.js +48 -76
- package/dist/components/slider.js +8 -10
- package/dist/components/spinner.js +3 -3
- package/dist/components/status-dot.d.ts +62 -0
- package/dist/components/status-dot.js +99 -0
- package/dist/components/switch.js +3 -3
- package/dist/components/tabs.js +9 -12
- package/dist/components/tag-group.js +7 -9
- package/dist/components/text-field.d.ts +17 -2
- package/dist/components/text-field.js +14 -4
- package/dist/components/text.js +2 -1
- package/dist/components/textarea.js +3 -4
- package/dist/components/time-field.js +2 -1
- package/dist/components/timeline.d.ts +67 -0
- package/dist/components/timeline.js +159 -0
- package/dist/components/toggle-button.js +5 -7
- package/dist/components/tooltip.js +3 -3
- package/dist/components/typeset.d.ts +2 -1
- package/dist/components/typeset.js +131 -123
- package/dist/components/youtube-embed.js +2 -1
- package/dist/docs/anchor-heading.d.ts +41 -0
- package/dist/docs/anchor-heading.js +62 -0
- package/dist/docs/callout.d.ts +46 -0
- package/dist/docs/callout.js +61 -0
- package/dist/docs/code-block.d.ts +74 -0
- package/dist/docs/code-block.js +322 -0
- package/dist/docs/code-tabs-sync.d.ts +26 -0
- package/dist/docs/code-tabs-sync.js +12 -0
- package/dist/docs/code-tabs.d.ts +53 -0
- package/dist/docs/code-tabs.js +102 -0
- package/dist/docs/copy-button.d.ts +31 -0
- package/dist/docs/copy-button.js +49 -0
- package/dist/docs/docs-feedback.d.ts +67 -0
- package/dist/docs/docs-feedback.js +74 -0
- package/dist/docs/docs-footer.d.ts +40 -0
- package/dist/docs/docs-footer.js +45 -0
- package/dist/docs/docs-hub.d.ts +93 -0
- package/dist/docs/docs-hub.js +142 -0
- package/dist/docs/docs-layout.d.ts +90 -0
- package/dist/docs/docs-layout.js +166 -0
- package/dist/docs/docs-nav-tools.d.ts +25 -0
- package/dist/docs/docs-nav-tools.js +14 -0
- package/dist/docs/docs-nav.d.ts +57 -0
- package/dist/docs/docs-nav.js +76 -0
- package/dist/docs/docs-not-found.d.ts +68 -0
- package/dist/docs/docs-not-found.js +100 -0
- package/dist/docs/docs-page-header.d.ts +55 -0
- package/dist/docs/docs-page-header.js +54 -0
- package/dist/docs/docs-pager.d.ts +50 -0
- package/dist/docs/docs-pager.js +75 -0
- package/dist/docs/file-tree.d.ts +57 -0
- package/dist/docs/file-tree.js +142 -0
- package/dist/docs/index.d.ts +38 -0
- package/dist/docs/index.js +38 -0
- package/dist/docs/install-command.d.ts +54 -0
- package/dist/docs/install-command.js +33 -0
- package/dist/docs/mixins/code-tabs-sync.d.ts +47 -0
- package/dist/docs/mixins/code-tabs-sync.js +137 -0
- package/dist/docs/mixins/copy-feedback.d.ts +25 -0
- package/dist/docs/mixins/copy-feedback.js +49 -0
- package/dist/docs/mixins/copy-from-url.d.ts +27 -0
- package/dist/docs/mixins/copy-from-url.js +95 -0
- package/dist/docs/mixins/docs-nav-tools.d.ts +27 -0
- package/dist/docs/mixins/docs-nav-tools.js +124 -0
- package/dist/docs/mixins/toc-spy.d.ts +30 -0
- package/dist/docs/mixins/toc-spy.js +165 -0
- package/dist/docs/next-steps.d.ts +45 -0
- package/dist/docs/next-steps.js +80 -0
- package/dist/docs/page-actions.d.ts +77 -0
- package/dist/docs/page-actions.js +78 -0
- package/dist/docs/plan-notice.d.ts +28 -0
- package/dist/docs/plan-notice.js +33 -0
- package/dist/docs/props-table.d.ts +64 -0
- package/dist/docs/props-table.js +147 -0
- package/dist/docs/steps.d.ts +51 -0
- package/dist/docs/steps.js +112 -0
- package/dist/docs/table-of-contents.d.ts +49 -0
- package/dist/docs/table-of-contents.js +139 -0
- package/dist/docs/ui-label.d.ts +51 -0
- package/dist/docs/ui-label.js +64 -0
- package/dist/docs/utils/docs-tree.d.ts +81 -0
- package/dist/docs/utils/docs-tree.js +57 -0
- package/dist/docs/utils/reveal-in-scroller.d.ts +19 -0
- package/dist/docs/utils/reveal-in-scroller.js +43 -0
- package/dist/landing/accent-text.d.ts +47 -0
- package/dist/landing/accent-text.js +107 -0
- package/dist/landing/animations/entrance.d.ts +40 -0
- package/dist/landing/animations/entrance.js +52 -0
- package/dist/landing/announcement-chip.d.ts +45 -0
- package/dist/landing/announcement-chip.js +36 -0
- package/dist/landing/author-band.d.ts +78 -0
- package/dist/landing/author-band.js +190 -0
- package/dist/landing/bento.d.ts +99 -0
- package/dist/landing/bento.js +138 -0
- package/dist/landing/changelog-strip.d.ts +74 -0
- package/dist/landing/changelog-strip.js +201 -0
- package/dist/{patterns → landing}/check-row.js +5 -7
- package/dist/{patterns → landing}/closing-cta.d.ts +4 -4
- package/dist/{patterns → landing}/closing-cta.js +8 -8
- package/dist/landing/code-stage.d.ts +93 -0
- package/dist/landing/code-stage.js +434 -0
- package/dist/landing/crosshair.d.ts +44 -0
- package/dist/landing/crosshair.js +48 -0
- package/dist/landing/curriculum.d.ts +79 -0
- package/dist/landing/curriculum.js +194 -0
- package/dist/landing/drawn-chart.d.ts +74 -0
- package/dist/landing/drawn-chart.js +377 -0
- package/dist/landing/event-ticker.d.ts +71 -0
- package/dist/landing/event-ticker.js +331 -0
- package/dist/landing/fan-out-diagram.d.ts +70 -0
- package/dist/landing/fan-out-diagram.js +481 -0
- package/dist/{patterns → landing}/faq-band.d.ts +5 -5
- package/dist/{patterns → landing}/faq-band.js +13 -14
- package/dist/landing/feature-band.d.ts +108 -0
- package/dist/landing/feature-band.js +67 -0
- package/dist/landing/feature.d.ts +148 -0
- package/dist/landing/feature.js +219 -0
- package/dist/landing/flow-diagram.d.ts +62 -0
- package/dist/landing/flow-diagram.js +240 -0
- package/dist/{patterns → landing}/icon-well.d.ts +17 -7
- package/dist/landing/icon-well.js +31 -0
- package/dist/landing/index.d.ts +52 -0
- package/dist/landing/index.js +52 -0
- package/dist/{patterns → landing}/install-tabs.js +4 -5
- package/dist/landing/landing-header.d.ts +103 -0
- package/dist/landing/landing-header.js +110 -0
- package/dist/landing/landing-hero.d.ts +119 -0
- package/dist/landing/landing-hero.js +172 -0
- package/dist/{components/marketing-section.d.ts → landing/landing-section.d.ts} +38 -15
- package/dist/landing/landing-section.js +183 -0
- package/dist/landing/logo-cloud.d.ts +56 -0
- package/dist/landing/logo-cloud.js +160 -0
- package/dist/landing/logo-sentence.d.ts +38 -0
- package/dist/landing/logo-sentence.js +51 -0
- package/dist/landing/marquee.d.ts +44 -0
- package/dist/landing/marquee.js +97 -0
- package/dist/landing/motion-loop.d.ts +43 -0
- package/dist/landing/motion-loop.js +42 -0
- package/dist/landing/pricing-band.d.ts +94 -0
- package/dist/landing/pricing-band.js +151 -0
- package/dist/landing/product-frame.d.ts +108 -0
- package/dist/landing/product-frame.js +202 -0
- package/dist/{patterns → landing}/proof-strip.d.ts +4 -4
- package/dist/{patterns → landing}/proof-strip.js +3 -3
- package/dist/landing/rails.d.ts +45 -0
- package/dist/landing/rails.js +69 -0
- package/dist/landing/rotating-text.d.ts +44 -0
- package/dist/landing/rotating-text.js +67 -0
- package/dist/landing/segmented-stage.d.ts +75 -0
- package/dist/landing/segmented-stage.js +141 -0
- package/dist/landing/sequence-diagram.d.ts +65 -0
- package/dist/landing/sequence-diagram.js +348 -0
- package/dist/landing/site-footer.d.ts +100 -0
- package/dist/landing/site-footer.js +274 -0
- package/dist/landing/site-header.d.ts +126 -0
- package/dist/landing/site-header.js +595 -0
- package/dist/{components → landing}/split.d.ts +12 -5
- package/dist/{components → landing}/split.js +26 -18
- package/dist/landing/sponsor-wall.d.ts +81 -0
- package/dist/landing/sponsor-wall.js +241 -0
- package/dist/{components → landing}/stat-strip.d.ts +31 -7
- package/dist/landing/stat-strip.js +105 -0
- package/dist/landing/step-list.d.ts +73 -0
- package/dist/landing/step-list.js +182 -0
- package/dist/landing/styles/card-grid.d.ts +115 -0
- package/dist/landing/styles/card-grid.js +295 -0
- package/dist/{patterns → landing}/tabbed-stage.d.ts +26 -8
- package/dist/landing/tabbed-stage.js +233 -0
- package/dist/landing/testimonial-band.d.ts +110 -0
- package/dist/landing/testimonial-band.js +164 -0
- package/dist/landing/typed-terminal.d.ts +62 -0
- package/dist/landing/typed-terminal.js +233 -0
- package/dist/landing/utils/pause-toggle.d.ts +37 -0
- package/dist/landing/utils/pause-toggle.js +71 -0
- package/dist/mixins/confirm-phrase.d.ts +19 -0
- package/dist/mixins/confirm-phrase.js +56 -0
- package/dist/mixins/copy-to-clipboard.d.ts +6 -0
- package/dist/mixins/copy-to-clipboard.js +17 -1
- package/dist/mixins/dialog-dismiss.d.ts +21 -0
- package/dist/mixins/dialog-dismiss.js +62 -0
- package/dist/mixins/index.d.ts +4 -15
- package/dist/mixins/index.js +4 -15
- package/dist/mixins/viewer-time.d.ts +20 -0
- package/dist/mixins/viewer-time.js +40 -0
- package/dist/styles/index.d.ts +3 -5
- package/dist/styles/index.js +3 -5
- package/dist/styles/landing.d.ts +200 -0
- package/dist/styles/landing.js +516 -0
- package/dist/styles/segmented-control.d.ts +49 -0
- package/dist/styles/segmented-control.js +71 -0
- package/dist/styles/surface-control.d.ts +18 -0
- package/dist/styles/surface-control.js +31 -0
- package/dist/test/table.d.ts +65 -0
- package/dist/test/table.js +108 -0
- package/dist/utils/eyebrow.d.ts +39 -0
- package/dist/utils/eyebrow.js +21 -0
- package/dist/utils/index.d.ts +2 -5
- package/dist/utils/index.js +2 -5
- package/dist/utils/relative-time.d.ts +44 -0
- package/dist/utils/relative-time.js +69 -0
- package/package.json +16 -6
- package/src/theme.css +87 -22
- package/dist/components/empty.d.ts +0 -91
- package/dist/components/empty.js +0 -151
- package/dist/components/feature.d.ts +0 -102
- package/dist/components/feature.js +0 -150
- package/dist/components/logo-cloud.d.ts +0 -42
- package/dist/components/logo-cloud.js +0 -41
- package/dist/components/marketing-header.d.ts +0 -71
- package/dist/components/marketing-header.js +0 -81
- package/dist/components/marketing-section.js +0 -117
- package/dist/components/skeleton.d.ts +0 -36
- package/dist/components/skeleton.js +0 -38
- package/dist/components/stat-strip.js +0 -65
- package/dist/components/table.d.ts +0 -152
- package/dist/components/table.js +0 -238
- package/dist/patterns/accent-text.d.ts +0 -30
- package/dist/patterns/accent-text.js +0 -17
- package/dist/patterns/announcement-chip.d.ts +0 -41
- package/dist/patterns/announcement-chip.js +0 -49
- package/dist/patterns/bento.d.ts +0 -68
- package/dist/patterns/bento.js +0 -94
- package/dist/patterns/code-stage.d.ts +0 -63
- package/dist/patterns/code-stage.js +0 -82
- package/dist/patterns/feature-band.d.ts +0 -85
- package/dist/patterns/feature-band.js +0 -50
- package/dist/patterns/icon-well.js +0 -38
- package/dist/patterns/index.d.ts +0 -23
- package/dist/patterns/index.js +0 -23
- package/dist/patterns/landing-hero.d.ts +0 -93
- package/dist/patterns/landing-hero.js +0 -126
- package/dist/patterns/product-frame.d.ts +0 -60
- package/dist/patterns/product-frame.js +0 -70
- package/dist/patterns/step-list.d.ts +0 -47
- package/dist/patterns/step-list.js +0 -85
- package/dist/patterns/tabbed-stage.js +0 -77
- package/dist/styles/marketing.d.ts +0 -120
- package/dist/styles/marketing.js +0 -225
- package/dist/utils/semantic-color-panel.d.ts +0 -35
- package/dist/utils/semantic-color-panel.js +0 -28
- /package/dist/{behaviors → app/behaviors}/drag-session.d.ts +0 -0
- /package/dist/{behaviors → app/behaviors}/resize-session.d.ts +0 -0
- /package/dist/{behaviors → app/behaviors}/resize-session.js +0 -0
- /package/dist/{behaviors → app/behaviors}/selection-model.d.ts +0 -0
- /package/dist/{behaviors → app/behaviors}/selection-model.js +0 -0
- /package/dist/{components → app}/drop-indicator.d.ts +0 -0
- /package/dist/{components → app}/file-trigger.d.ts +0 -0
- /package/dist/{components → app}/menubar.d.ts +0 -0
- /package/dist/{mixins → app/mixins}/chart-tooltip.d.ts +0 -0
- /package/dist/{mixins → app/mixins}/chart-tooltip.js +0 -0
- /package/dist/{mixins → app/mixins}/context-menu.d.ts +0 -0
- /package/dist/{mixins → app/mixins}/context-menu.js +0 -0
- /package/dist/{mixins → app/mixins}/drag-reorder.d.ts +0 -0
- /package/dist/{mixins → app/mixins}/drop-zone.d.ts +0 -0
- /package/dist/{mixins → app/mixins}/grid-list-keys.d.ts +0 -0
- /package/dist/{mixins → app/mixins}/menubar-keys.d.ts +0 -0
- /package/dist/{mixins → app/mixins}/resize-handle.d.ts +0 -0
- /package/dist/{mixins/treeKeys.d.ts → app/mixins/tree-keys.d.ts} +0 -0
- /package/dist/{components → app}/resizable.d.ts +0 -0
- /package/dist/{components → app}/shortcut-list.d.ts +0 -0
- /package/dist/{styles → app/styles}/chart-palette.js +0 -0
- /package/dist/{styles → app/styles}/graphic-host.js +0 -0
- /package/dist/{styles → app/styles}/legend-toggle.js +0 -0
- /package/dist/{components → app}/toolbar.d.ts +0 -0
- /package/dist/{utils → app/utils}/chart-scale.d.ts +0 -0
- /package/dist/{behaviors → chat/behaviors}/scroll-follow-model.d.ts +0 -0
- /package/dist/{components → chat}/bubble.d.ts +0 -0
- /package/dist/{components → chat}/marker.d.ts +0 -0
- /package/dist/{components → chat}/message.d.ts +0 -0
- /package/dist/{mixins → chat/mixins}/attachment-trigger.d.ts +0 -0
- /package/dist/{mixins → chat/mixins}/attachment-trigger.js +0 -0
- /package/dist/{mixins → chat/mixins}/message-follow.d.ts +0 -0
- /package/dist/{components → color}/color-area.d.ts +0 -0
- /package/dist/{components → color}/color-field.d.ts +0 -0
- /package/dist/{components → color}/color-slider.d.ts +0 -0
- /package/dist/{components → color}/color-swatch-picker.d.ts +0 -0
- /package/dist/{components → color}/color-swatch.d.ts +0 -0
- /package/dist/{components → color}/color-wheel.d.ts +0 -0
- /package/dist/{mixins → color/mixins}/color-channel-sync.d.ts +0 -0
- /package/dist/{mixins → color/mixins}/color-channel-sync.js +0 -0
- /package/dist/{mixins → color/mixins}/color-preview.d.ts +0 -0
- /package/dist/{mixins → color/mixins}/color-wheel-drag.d.ts +0 -0
- /package/dist/{styles → color/styles}/rtl-aware-gradient-direction.js +0 -0
- /package/dist/{utils → color/utils}/hue-spectrum.d.ts +0 -0
- /package/dist/{utils → color/utils}/hue-spectrum.js +0 -0
- /package/dist/{patterns → landing}/check-row.d.ts +0 -0
- /package/dist/{patterns → landing}/install-tabs.d.ts +0 -0
|
@@ -1,6 +1,10 @@
|
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "remix/component/jsx-runtime";
|
|
2
|
-
import { flex, flexCol, gap } from "@sdxc/u/layout";
|
|
2
|
+
import { flex, flexCol, gap, vstack } from "@sdxc/u/layout";
|
|
3
|
+
import { clientEntry } from "remix/component";
|
|
4
|
+
import { confirmPhrase } from "../mixins/confirm-phrase.js";
|
|
3
5
|
import { AlertDialog } from "./alert-dialog.js";
|
|
6
|
+
import { Input } from "./input.js";
|
|
7
|
+
import { Label } from "./label.js";
|
|
4
8
|
/** Semantic color role {@link Confirm} falls back to when `color` is omitted. */
|
|
5
9
|
const DEFAULT_COLOR = "danger";
|
|
6
10
|
/** HTTP method a submitting {@link Confirm} falls back to when `form.method` is omitted. */
|
|
@@ -11,10 +15,12 @@ const DEFAULT_METHOD = "post";
|
|
|
11
15
|
* without this the header and footer would lose their spacing.
|
|
12
16
|
*/
|
|
13
17
|
const PANEL_GAP = 6;
|
|
18
|
+
/** Characters a `pattern` (compiled with the `v` flag) reads as syntax, escaped to match literally. */
|
|
19
|
+
const PATTERN_SYNTAX = /[\\^$.*+?()[\]{}|/]/g;
|
|
14
20
|
/**
|
|
15
21
|
* Composes {@link AlertDialog} into a confirmation prompt, wiring title and
|
|
16
|
-
* description ids to `aria-labelledby`/`aria-describedby`.
|
|
17
|
-
*
|
|
22
|
+
* description ids to `aria-labelledby`/`aria-describedby`. Focus opens on Cancel, or
|
|
23
|
+
* on the phrase field with `typeToConfirm`; pass `form` to submit a real `<form>`.
|
|
18
24
|
*
|
|
19
25
|
* @param handle Runtime handle carrying the panel's props and this instance's stable identifier.
|
|
20
26
|
* @returns The render function producing the confirmation prompt's markup.
|
|
@@ -43,14 +49,47 @@ const PANEL_GAP = 6;
|
|
|
43
49
|
* cancelLabel={t("actions.cancel")}
|
|
44
50
|
* form={{ action: revokeUrl, fields: <input type="hidden" name="csrf" value={token} /> }}
|
|
45
51
|
* />
|
|
52
|
+
* @example
|
|
53
|
+
* <Confirm
|
|
54
|
+
* id="delete-team"
|
|
55
|
+
* title="Delete team?"
|
|
56
|
+
* description="Acme, its 12 monitors and their history are deleted."
|
|
57
|
+
* confirmLabel="Delete team"
|
|
58
|
+
* cancelLabel="Cancel"
|
|
59
|
+
* typeToConfirm={{ value: "acme", label: 'Type "acme" to confirm', name: "confirmation" }}
|
|
60
|
+
* form={{ action: "/teams/acme/delete" }}
|
|
61
|
+
* />
|
|
46
62
|
*/
|
|
47
63
|
export function Confirm(handle) {
|
|
48
64
|
return () => {
|
|
49
|
-
let { id, title, description, confirmLabel, cancelLabel, color, form, "aria-labelledby": ariaLabelledByProp, "aria-describedby": ariaDescribedByProp, parts, mix, ...rest } = handle.props;
|
|
65
|
+
let { id, title, description, confirmLabel, cancelLabel, color, form, typeToConfirm, "aria-labelledby": ariaLabelledByProp, "aria-describedby": ariaDescribedByProp, parts, mix, ...rest } = handle.props;
|
|
50
66
|
let resolvedColor = color ?? DEFAULT_COLOR;
|
|
51
67
|
let titleId = `${handle.id}-title`;
|
|
52
68
|
let descriptionId = description ? `${handle.id}-description` : undefined;
|
|
53
|
-
let content = (_jsxs(_Fragment, { children: [_jsxs(AlertDialog.Header, { mix: parts?.header, children: [_jsx(AlertDialog.Title, { id: titleId, mix: parts?.title, children: title }), description ? (_jsx(AlertDialog.Description, { id: descriptionId, mix: parts?.description, children: description })) : null] }), _jsxs(AlertDialog.Footer, { mix: parts?.footer, children: [_jsx(AlertDialog.Cancel, { commandfor: id, mix: parts?.cancel, children: cancelLabel }), _jsx(AlertDialog.Action, { type: form ? "submit" : undefined, commandfor: form ? undefined : id, color: resolvedColor, mix: parts?.action, children: confirmLabel })] })] }));
|
|
69
|
+
let content = (_jsxs(_Fragment, { children: [_jsxs(AlertDialog.Header, { mix: parts?.header, children: [_jsx(AlertDialog.Title, { id: titleId, mix: parts?.title, children: title }), description ? (_jsx(AlertDialog.Description, { id: descriptionId, mix: parts?.description, children: description })) : null] }), typeToConfirm ? (_jsx(ConfirmPhrase, { id: `${handle.id}-phrase`, value: typeToConfirm.value, label: typeToConfirm.label, name: typeToConfirm.name })) : null, _jsxs(AlertDialog.Footer, { mix: parts?.footer, children: [_jsx(AlertDialog.Cancel, { commandfor: id, autofocus: typeToConfirm ? undefined : true, mix: parts?.cancel, children: cancelLabel }), _jsx(AlertDialog.Action, { "data-confirm-action": "", type: form ? "submit" : undefined, commandfor: form ? undefined : id, color: resolvedColor, mix: parts?.action, children: confirmLabel })] })] }));
|
|
54
70
|
return (_jsx(AlertDialog, { ...rest, id: id, "aria-labelledby": ariaLabelledByProp ?? titleId, "aria-describedby": ariaDescribedByProp ?? descriptionId, mix: mix, children: form ? (_jsxs("form", { action: form.action, method: form.method ?? DEFAULT_METHOD, mix: [flex(), flexCol(), gap(PANEL_GAP), parts?.form], children: [form.fields, content] })) : (content) }));
|
|
55
71
|
};
|
|
56
72
|
}
|
|
73
|
+
/**
|
|
74
|
+
* Turns a phrase into a `pattern` that matches only that phrase.
|
|
75
|
+
*
|
|
76
|
+
* @param value The phrase to match literally.
|
|
77
|
+
* @returns The phrase with every pattern syntax character escaped.
|
|
78
|
+
*/
|
|
79
|
+
function escapePattern(value) {
|
|
80
|
+
return value.replace(PATTERN_SYNTAX, "\\$&");
|
|
81
|
+
}
|
|
82
|
+
/**
|
|
83
|
+
* Client island: the field a type-to-confirm prompt holds. It disables the dialog's
|
|
84
|
+
* confirming control until the typed text matches and clears itself when the dialog
|
|
85
|
+
* closes, so every opening starts locked; without script, `pattern` blocks the submit.
|
|
86
|
+
*
|
|
87
|
+
* @example
|
|
88
|
+
* <ConfirmPhrase id="delete-team-phrase" value="acme" label='Type "acme" to confirm' />
|
|
89
|
+
*/
|
|
90
|
+
export const ConfirmPhrase = clientEntry("@sdxc/ui/confirm#ConfirmPhrase", function ConfirmPhrase(handle) {
|
|
91
|
+
return () => {
|
|
92
|
+
let { id, label, name, value } = handle.props;
|
|
93
|
+
return (_jsxs("div", { "data-slot": "confirm-phrase", mix: [vstack({ gap: 1.5, align: "stretch" })], children: [_jsx(Label, { htmlFor: id, children: label }), _jsx(Input, { id: id, name: name, required: true, autofocus: true, autocomplete: "off", spellcheck: false, pattern: escapePattern(value), mix: [confirmPhrase(value)] })] }));
|
|
94
|
+
};
|
|
95
|
+
});
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* A horizontal cluster of primary and secondary
|
|
2
|
+
* A horizontal cluster of primary and secondary landing actions that wraps
|
|
3
3
|
* onto a second row when the container is narrow. Children are the page's own
|
|
4
|
-
* {@link Button} / {@link LinkButton} instances
|
|
5
|
-
*
|
|
4
|
+
* {@link Button} / {@link LinkButton} instances, and an action that names no
|
|
5
|
+
* size of its own takes the group's, so a hero row sizes every CTA at once.
|
|
6
6
|
*
|
|
7
7
|
* @author [Sergio Xalambrí](https://sergiodxa.com)
|
|
8
8
|
* @copyright Sergio Xalambrí 2026
|
|
@@ -12,34 +12,50 @@ import type { Handle, Props as TagProps, RemixNode } from "remix/component";
|
|
|
12
12
|
* Prop types for {@link CtaGroup}.
|
|
13
13
|
*/
|
|
14
14
|
export declare namespace CtaGroup {
|
|
15
|
+
/** Size every action without a `size` of its own renders at. */
|
|
16
|
+
type Size = "sm" | "md" | "lg";
|
|
17
|
+
/**
|
|
18
|
+
* When the actions stack into full-width rows: never, or on a phone-width
|
|
19
|
+
* container (36rem and below), where two side-by-side CTAs would wrap unevenly.
|
|
20
|
+
*/
|
|
21
|
+
type Stack = "never" | "phone";
|
|
22
|
+
/** What the group shares with the actions inside it. */
|
|
23
|
+
interface Context {
|
|
24
|
+
/** Size an action without its own `size` renders at. */
|
|
25
|
+
size: Size;
|
|
26
|
+
}
|
|
15
27
|
/**
|
|
16
28
|
* Props accepted by {@link CtaGroup}.
|
|
17
29
|
*/
|
|
18
30
|
interface Props extends TagProps<"div"> {
|
|
31
|
+
/** Size handed to every action without its own. Defaults to {@link DEFAULT_SIZE}. */
|
|
32
|
+
size?: Size;
|
|
33
|
+
/** When the actions stack full width. Defaults to `"never"`. */
|
|
34
|
+
stack?: Stack;
|
|
19
35
|
/**
|
|
20
36
|
* Action controls — typically a solid primary {@link Button} or
|
|
21
|
-
* {@link LinkButton} beside
|
|
22
|
-
* invent buttons of its own.
|
|
37
|
+
* {@link LinkButton} beside a `surface` or outline secondary. The group
|
|
38
|
+
* does not invent buttons of its own.
|
|
23
39
|
*/
|
|
24
40
|
children: RemixNode;
|
|
25
41
|
}
|
|
26
42
|
}
|
|
27
43
|
/**
|
|
28
44
|
* Lays action children in a wrapping inline-flex row with a compact gap so a
|
|
29
|
-
* primary and secondary CTA read as one cluster
|
|
30
|
-
* buttons; override `--ui-
|
|
31
|
-
*
|
|
45
|
+
* primary and secondary CTA read as one cluster, and publishes its size to them.
|
|
46
|
+
* Radius stays on the buttons; override `--ui-landing-cta-radius` per brand for
|
|
47
|
+
* pill vs soft-rect corners through `landingCtaChrome()`.
|
|
32
48
|
*
|
|
33
49
|
* @param handle Runtime handle carrying the host `<div>`'s props.
|
|
34
50
|
* @returns The render function producing the group's markup.
|
|
35
51
|
* @example
|
|
36
|
-
* <CtaGroup>
|
|
37
|
-
* <Button
|
|
38
|
-
* <LinkButton href={docs}
|
|
52
|
+
* <CtaGroup stack="phone">
|
|
53
|
+
* <Button color="brand">{t("hero.cta")}</Button>
|
|
54
|
+
* <LinkButton href={docs} variant="surface">{t("hero.docs")}</LinkButton>
|
|
39
55
|
* </CtaGroup>
|
|
40
56
|
* @example
|
|
41
|
-
* <CtaGroup>
|
|
42
|
-
* <LinkButton href={signin}
|
|
57
|
+
* <CtaGroup size="sm">
|
|
58
|
+
* <LinkButton href={signin}>{t("nav.signin")}</LinkButton>
|
|
43
59
|
* </CtaGroup>
|
|
44
60
|
*/
|
|
45
|
-
export declare function CtaGroup(handle: Handle<CtaGroup.Props>): () => import("remix/component").RemixElement;
|
|
61
|
+
export declare function CtaGroup(handle: Handle<CtaGroup.Props, CtaGroup.Context>): () => import("remix/component").RemixElement;
|
|
@@ -1,26 +1,45 @@
|
|
|
1
1
|
import { jsx as _jsx } from "remix/component/jsx-runtime";
|
|
2
|
+
import { raw, mergeMix } from "@sdxc/u/general";
|
|
2
3
|
import { flexWrap, gap, inlineFlex, items } from "@sdxc/u/layout";
|
|
4
|
+
import { atMax } from "@sdxc/u/responsive";
|
|
5
|
+
import { when } from "@sdxc/u/state";
|
|
6
|
+
/** Size the group hands its actions when `size` is omitted: the 40px landing CTA. */
|
|
7
|
+
const DEFAULT_SIZE = "md";
|
|
3
8
|
/**
|
|
4
9
|
* Lays action children in a wrapping inline-flex row with a compact gap so a
|
|
5
|
-
* primary and secondary CTA read as one cluster
|
|
6
|
-
* buttons; override `--ui-
|
|
7
|
-
*
|
|
10
|
+
* primary and secondary CTA read as one cluster, and publishes its size to them.
|
|
11
|
+
* Radius stays on the buttons; override `--ui-landing-cta-radius` per brand for
|
|
12
|
+
* pill vs soft-rect corners through `landingCtaChrome()`.
|
|
8
13
|
*
|
|
9
14
|
* @param handle Runtime handle carrying the host `<div>`'s props.
|
|
10
15
|
* @returns The render function producing the group's markup.
|
|
11
16
|
* @example
|
|
12
|
-
* <CtaGroup>
|
|
13
|
-
* <Button
|
|
14
|
-
* <LinkButton href={docs}
|
|
17
|
+
* <CtaGroup stack="phone">
|
|
18
|
+
* <Button color="brand">{t("hero.cta")}</Button>
|
|
19
|
+
* <LinkButton href={docs} variant="surface">{t("hero.docs")}</LinkButton>
|
|
15
20
|
* </CtaGroup>
|
|
16
21
|
* @example
|
|
17
|
-
* <CtaGroup>
|
|
18
|
-
* <LinkButton href={signin}
|
|
22
|
+
* <CtaGroup size="sm">
|
|
23
|
+
* <LinkButton href={signin}>{t("nav.signin")}</LinkButton>
|
|
19
24
|
* </CtaGroup>
|
|
20
25
|
*/
|
|
21
26
|
export function CtaGroup(handle) {
|
|
22
27
|
return () => {
|
|
23
|
-
let { mix, ...rest } = handle.props;
|
|
24
|
-
|
|
28
|
+
let { mix, size, stack, ...rest } = handle.props;
|
|
29
|
+
let resolvedSize = size ?? DEFAULT_SIZE;
|
|
30
|
+
handle.context.set({ size: resolvedSize });
|
|
31
|
+
return (_jsx("div", { ...rest, "data-slot": "cta-group", "data-size": resolvedSize, "data-stack": stack === "phone" ? "phone" : undefined, mix: mergeMix([
|
|
32
|
+
inlineFlex(),
|
|
33
|
+
items("center"),
|
|
34
|
+
flexWrap(),
|
|
35
|
+
gap(3),
|
|
36
|
+
stack === "phone"
|
|
37
|
+
? atMax("md", [
|
|
38
|
+
raw({ display: "flex", flexDirection: "column", alignItems: "stretch" }),
|
|
39
|
+
raw({ inlineSize: "100%" }),
|
|
40
|
+
when("& > *", raw({ inlineSize: "100%" })),
|
|
41
|
+
])
|
|
42
|
+
: [],
|
|
43
|
+
], mix) }));
|
|
25
44
|
};
|
|
26
45
|
}
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs } from "remix/component/jsx-runtime";
|
|
2
|
+
import { mergeMix } from "@sdxc/u/general";
|
|
2
3
|
import { tabularNums } from "@sdxc/u/typography";
|
|
3
4
|
import { fieldStackLayout } from "../styles/field-stack-layout.js";
|
|
4
5
|
import { resolveFieldWiring } from "../utils/resolve-field-wiring.js";
|
|
@@ -43,7 +44,7 @@ export function DateField(handle) {
|
|
|
43
44
|
description,
|
|
44
45
|
ariaInvalid: ariaInvalidProp,
|
|
45
46
|
});
|
|
46
|
-
return (_jsxs("div", { ...rest, "data-slot": "date-field", mix:
|
|
47
|
+
return (_jsxs("div", { ...rest, "data-slot": "date-field", mix: mergeMix(fieldStackLayout(), mix), children: [_jsx(Label, { htmlFor: handle.id, mix: parts?.label, children: label }), _jsx(Input, { id: handle.id, type: "date", name: name, value: value, defaultValue: defaultValue, min: min, max: max, step: step, required: required, disabled: disabled, readOnly: readOnly, autoComplete: autoComplete,
|
|
47
48
|
// oxlint-disable-next-line jsx-a11y/no-autofocus -- Not a focus grab on page load: this only ever resolves true for the first field an enclosing Form reports as invalid, so a failed submit lands the user on the problem instead of leaving them to hunt for it.
|
|
48
49
|
autoFocus: resolvedAutoFocus, "aria-invalid": resolvedInvalid, "aria-describedby": describedBy, color: resolvedColor, mix: [tabularNums(), parts?.input] }), description ? (_jsx(Description, { id: descriptionId, mix: parts?.description, children: description })) : null, errorMessage ? (_jsx(FieldError, { id: errorId, mix: parts?.error, children: errorMessage })) : null] }));
|
|
49
50
|
};
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { jsx as _jsx } from "remix/component/jsx-runtime";
|
|
2
2
|
import { outline } from "@sdxc/u/color";
|
|
3
3
|
import { roundedCorner } from "@sdxc/u/effects";
|
|
4
|
-
import { raw } from "@sdxc/u/general";
|
|
4
|
+
import { raw, mergeMix } from "@sdxc/u/general";
|
|
5
5
|
import { flex, flexCol, gap, items } from "@sdxc/u/layout";
|
|
6
6
|
import { mis } from "@sdxc/u/size";
|
|
7
7
|
import { z } from "@sdxc/u/stacking";
|
|
@@ -34,7 +34,7 @@ export function DatePicker(handle) {
|
|
|
34
34
|
if (!children) {
|
|
35
35
|
return (_jsx(DateField, { ...rest, color: color, label: label, description: description, errorMessage: errorMessage, name: name, value: value, defaultValue: defaultValue, min: min, max: max, step: step, required: required, disabled: disabled, readOnly: readOnly, autoComplete: autoComplete, parts: parts, mix: mix }));
|
|
36
36
|
}
|
|
37
|
-
return (_jsx("div", { ...rest, "data-slot": "date-picker", mix: [flex(), flexCol(), gap(1), mix
|
|
37
|
+
return (_jsx("div", { ...rest, "data-slot": "date-picker", mix: mergeMix([flex(), flexCol(), gap(1)], mix), children: children }));
|
|
38
38
|
};
|
|
39
39
|
}
|
|
40
40
|
/**
|
|
@@ -53,7 +53,7 @@ export function DatePicker(handle) {
|
|
|
53
53
|
DatePicker.Group = function DatePickerGroup(handle) {
|
|
54
54
|
return () => {
|
|
55
55
|
let { mix, ...rest } = handle.props;
|
|
56
|
-
return (_jsx("div", { ...rest, "data-slot": "group", mix: [
|
|
56
|
+
return (_jsx("div", { ...rest, "data-slot": "group", mix: mergeMix([
|
|
57
57
|
flex(),
|
|
58
58
|
items("center"),
|
|
59
59
|
/**
|
|
@@ -87,7 +87,6 @@ DatePicker.Group = function DatePickerGroup(handle) {
|
|
|
87
87
|
* shows its own focus ring.
|
|
88
88
|
*/
|
|
89
89
|
raw({ outline: "none !important" })),
|
|
90
|
-
|
|
91
|
-
] }));
|
|
90
|
+
], mix) }));
|
|
92
91
|
};
|
|
93
92
|
};
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs } from "remix/component/jsx-runtime";
|
|
2
|
+
import { mergeMix } from "@sdxc/u/general";
|
|
2
3
|
import { flex, flexCol, gap, items } from "@sdxc/u/layout";
|
|
3
4
|
import { attrs } from "remix/component";
|
|
4
5
|
import { DateField } from "./date-field.js";
|
|
@@ -41,9 +42,9 @@ export function DateRangePicker(handle) {
|
|
|
41
42
|
}
|
|
42
43
|
}
|
|
43
44
|
if (!children) {
|
|
44
|
-
return (_jsxs("div", { ...rest, "data-slot": "fields", mix: [attrs({ role: "group" }), flex(), gap(2), items("start"), mix
|
|
45
|
+
return (_jsxs("div", { ...rest, "data-slot": "fields", mix: mergeMix([attrs({ role: "group" }), flex(), gap(2), items("start")], mix), children: [_jsx(DateField, { color: color, label: startLabel, description: startDescription, errorMessage: startErrorMessage, name: startName, value: startValue, defaultValue: startDefaultValue, min: min, max: max, step: step, required: required, disabled: disabled, readOnly: readOnly, autoComplete: autoComplete, parts: parts?.start }), _jsx(DateField, { color: color, label: endLabel, description: endDescription, errorMessage: endErrorMessage, name: endName, value: endValue, defaultValue: endDefaultValue, min: min, max: max, step: step, required: required, disabled: disabled, readOnly: readOnly, autoComplete: autoComplete, parts: parts?.end })] }));
|
|
45
46
|
}
|
|
46
|
-
return (_jsx("div", { ...rest, "data-slot": "date-range-picker", mix: [flex(), flexCol(), gap(1), mix
|
|
47
|
+
return (_jsx("div", { ...rest, "data-slot": "date-range-picker", mix: mergeMix([flex(), flexCol(), gap(1)], mix), children: children }));
|
|
47
48
|
};
|
|
48
49
|
}
|
|
49
50
|
/**
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { jsx as _jsx } from "remix/component/jsx-runtime";
|
|
2
2
|
import { fg } from "@sdxc/u/color";
|
|
3
|
+
import { mergeMix } from "@sdxc/u/general";
|
|
3
4
|
import { pretty, text } from "@sdxc/u/typography";
|
|
4
5
|
/**
|
|
5
6
|
* Renders its children inside a `<p>` sized and colored as a small run of
|
|
@@ -16,6 +17,6 @@ import { pretty, text } from "@sdxc/u/typography";
|
|
|
16
17
|
export function Description(handle) {
|
|
17
18
|
return () => {
|
|
18
19
|
let { mix, ...rest } = handle.props;
|
|
19
|
-
return _jsx("p", { ...rest, mix: [fg("neutral.muted"), text("sm"), pretty(), mix
|
|
20
|
+
return _jsx("p", { ...rest, mix: mergeMix([fg("neutral.muted"), text("sm"), pretty()], mix) });
|
|
20
21
|
};
|
|
21
22
|
}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Client island that closes the modal `<dialog>` it renders inside on a backdrop press or a
|
|
3
|
+
* followed link, for a navigation sheet or drawer whose links include same-page anchors.
|
|
4
|
+
* It owns no visible markup, so it drops into any dialog's content.
|
|
5
|
+
*
|
|
6
|
+
* @author [Sergio Xalambrí](https://sergiodxa.com)
|
|
7
|
+
* @copyright Sergio Xalambrí 2026
|
|
8
|
+
*/
|
|
9
|
+
import type { EntryComponent } from "remix/component";
|
|
10
|
+
/**
|
|
11
|
+
* Renders a hidden marker carrying {@link dialogDismiss}. The island loads from the bare
|
|
12
|
+
* `@sdxc/ui/dialog-dismiss` specifier, which the app's browser entry maps to a dynamic
|
|
13
|
+
* import. A page restored from the back-forward cache returns with the dialog closed.
|
|
14
|
+
*
|
|
15
|
+
* @example
|
|
16
|
+
* <SiteHeader brand={<Logo />} items={items} sheet={<DialogDismiss />} />
|
|
17
|
+
*/
|
|
18
|
+
export declare const DialogDismiss: EntryComponent<Record<never, never>>;
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { jsx as _jsx } from "remix/component/jsx-runtime";
|
|
2
|
+
import { hidden } from "@sdxc/u/layout";
|
|
3
|
+
import { clientEntry } from "remix/component";
|
|
4
|
+
import { dialogDismiss } from "../mixins/dialog-dismiss.js";
|
|
5
|
+
/**
|
|
6
|
+
* Renders a hidden marker carrying {@link dialogDismiss}. The island loads from the bare
|
|
7
|
+
* `@sdxc/ui/dialog-dismiss` specifier, which the app's browser entry maps to a dynamic
|
|
8
|
+
* import. A page restored from the back-forward cache returns with the dialog closed.
|
|
9
|
+
*
|
|
10
|
+
* @example
|
|
11
|
+
* <SiteHeader brand={<Logo />} items={items} sheet={<DialogDismiss />} />
|
|
12
|
+
*/
|
|
13
|
+
export const DialogDismiss = clientEntry("@sdxc/ui/dialog-dismiss#DialogDismiss", function DialogDismiss() {
|
|
14
|
+
return () => _jsx("span", { mix: [hidden(), dialogDismiss()] });
|
|
15
|
+
});
|
|
@@ -2,7 +2,7 @@ import { jsx as _jsx } from "remix/component/jsx-runtime";
|
|
|
2
2
|
import { XIcon } from "@sdxc/icons";
|
|
3
3
|
import { bg, border, fg, outline } from "@sdxc/u/color";
|
|
4
4
|
import { backdropBlur, backdropSaturate, opacity, rounded, shadow, transition, transitionBehavior, } from "@sdxc/u/effects";
|
|
5
|
-
import { raw, vars } from "@sdxc/u/general";
|
|
5
|
+
import { raw, vars, mergeMix } from "@sdxc/u/general";
|
|
6
6
|
import { absolute, container, fixed, flex, flexCol, flexColReverse, flexRow, gap, inset, justify, relative, } from "@sdxc/u/layout";
|
|
7
7
|
import { overflow } from "@sdxc/u/overflow";
|
|
8
8
|
import { at, media, startingStyle, supports } from "@sdxc/u/responsive";
|
|
@@ -62,7 +62,7 @@ export function Dialog(handle) {
|
|
|
62
62
|
if (import.meta.env?.DEV && !id) {
|
|
63
63
|
console.warn('Dialog rendered without an "id" — "commandfor" on a trigger or close control has nothing to target.');
|
|
64
64
|
}
|
|
65
|
-
return (_jsx("dialog", { ...rest, id: id, "data-slot": "dialog", mix: [
|
|
65
|
+
return (_jsx("dialog", { ...rest, id: id, "data-slot": "dialog", mix: mergeMix([
|
|
66
66
|
/**
|
|
67
67
|
* Establishes the containing block {@link Dialog.Close} pins itself to while
|
|
68
68
|
* the panel sits in the page's flow, which a dialog opened through its `open`
|
|
@@ -114,8 +114,7 @@ export function Dialog(handle) {
|
|
|
114
114
|
vars({ "ui-box-shadow-ring": SHADOW_RING }),
|
|
115
115
|
/** `overscrollBehavior` has no matching utility. */
|
|
116
116
|
raw({ overscrollBehavior: "contain" }),
|
|
117
|
-
|
|
118
|
-
], children: children }));
|
|
117
|
+
], mix), children: children }));
|
|
119
118
|
};
|
|
120
119
|
}
|
|
121
120
|
/**
|
|
@@ -134,14 +133,13 @@ export function Dialog(handle) {
|
|
|
134
133
|
Dialog.Header = function DialogHeader(handle) {
|
|
135
134
|
return () => {
|
|
136
135
|
let { mix, ...rest } = handle.props;
|
|
137
|
-
return (_jsx("div", { ...rest, "data-slot": "header", mix: [
|
|
136
|
+
return (_jsx("div", { ...rest, "data-slot": "header", mix: mergeMix([
|
|
138
137
|
flex(),
|
|
139
138
|
flexCol(),
|
|
140
139
|
gap(1.5),
|
|
141
140
|
textAlign("center"),
|
|
142
141
|
at(COMFORTABLE_WIDTH, CONTAINER_NAME, textAlign("start")),
|
|
143
|
-
|
|
144
|
-
] }));
|
|
142
|
+
], mix) }));
|
|
145
143
|
};
|
|
146
144
|
};
|
|
147
145
|
/**
|
|
@@ -159,15 +157,14 @@ Dialog.Title = function DialogTitle(handle) {
|
|
|
159
157
|
let { mix, ...rest } = handle.props;
|
|
160
158
|
let resolved = resolveHeadingLevel(handle);
|
|
161
159
|
let Tag = TAG_BY_LEVEL[resolved];
|
|
162
|
-
return (_jsx(Tag, { ...rest, "data-slot": "title", mix: [
|
|
160
|
+
return (_jsx(Tag, { ...rest, "data-slot": "title", mix: mergeMix([
|
|
163
161
|
fg("neutral.emphasis"),
|
|
164
162
|
weight("semibold"),
|
|
165
163
|
tracking("tight"),
|
|
166
164
|
fontSize("lg"),
|
|
167
165
|
leading(1),
|
|
168
166
|
balance(),
|
|
169
|
-
|
|
170
|
-
], children: rest.children }));
|
|
167
|
+
], mix), children: rest.children }));
|
|
171
168
|
};
|
|
172
169
|
};
|
|
173
170
|
/**
|
|
@@ -183,7 +180,7 @@ Dialog.Title = function DialogTitle(handle) {
|
|
|
183
180
|
Dialog.Description = function DialogDescription(handle) {
|
|
184
181
|
return () => {
|
|
185
182
|
let { mix, ...rest } = handle.props;
|
|
186
|
-
return (_jsx("p", { ...rest, "data-slot": "description", mix: [fg("neutral.muted"), fontSize("sm"), pretty(), mix
|
|
183
|
+
return (_jsx("p", { ...rest, "data-slot": "description", mix: mergeMix([fg("neutral.muted"), fontSize("sm"), pretty()], mix), children: rest.children }));
|
|
187
184
|
};
|
|
188
185
|
};
|
|
189
186
|
/**
|
|
@@ -202,13 +199,12 @@ Dialog.Description = function DialogDescription(handle) {
|
|
|
202
199
|
Dialog.Footer = function DialogFooter(handle) {
|
|
203
200
|
return () => {
|
|
204
201
|
let { mix, ...rest } = handle.props;
|
|
205
|
-
return (_jsx("div", { ...rest, "data-slot": "footer", mix: [
|
|
202
|
+
return (_jsx("div", { ...rest, "data-slot": "footer", mix: mergeMix([
|
|
206
203
|
flex(),
|
|
207
204
|
gap(2),
|
|
208
205
|
flexColReverse(),
|
|
209
206
|
at(COMFORTABLE_WIDTH, CONTAINER_NAME, [flexRow(), justify("end")]),
|
|
210
|
-
|
|
211
|
-
] }));
|
|
207
|
+
], mix) }));
|
|
212
208
|
};
|
|
213
209
|
};
|
|
214
210
|
/**
|
|
@@ -225,6 +221,6 @@ Dialog.Close = function DialogClose(handle) {
|
|
|
225
221
|
return () => {
|
|
226
222
|
let { commandfor, command, mix, ...rest } = handle.props;
|
|
227
223
|
let resolvedCommand = command ?? DEFAULT_CLOSE_COMMAND;
|
|
228
|
-
return (_jsx(Button, { ...rest, type: "button", variant: "ghost", color: "neutral", size: "sm", commandfor: commandfor, command: resolvedCommand, "data-slot": "close", mix: [absolute(), inset(4, 4, "auto", "auto"), mix
|
|
224
|
+
return (_jsx(Button, { ...rest, type: "button", variant: "ghost", color: "neutral", size: "sm", commandfor: commandfor, command: resolvedCommand, "data-slot": "close", mix: mergeMix([absolute(), inset(4, 4, "auto", "auto")], mix), children: _jsx(XIcon, { size: 16 }) }));
|
|
229
225
|
};
|
|
230
226
|
};
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { jsx as _jsx } from "remix/component/jsx-runtime";
|
|
2
2
|
import { bg, borderEdge, fg, outline } from "@sdxc/u/color";
|
|
3
3
|
import { opacity, roundedCorner, rounded, transition, transitionDuration } from "@sdxc/u/effects";
|
|
4
|
-
import { cursor, listStyle, pointerEvents, raw } from "@sdxc/u/general";
|
|
4
|
+
import { cursor, listStyle, pointerEvents, raw, mergeMix } from "@sdxc/u/general";
|
|
5
5
|
import { flex, flexCol, gap, hidden, interpolateSize, items, shrink } from "@sdxc/u/layout";
|
|
6
6
|
import { overflow } from "@sdxc/u/overflow";
|
|
7
7
|
import { media } from "@sdxc/u/responsive";
|
|
@@ -39,7 +39,7 @@ import { resolveHeadingLevel, TAG_BY_LEVEL } from "./heading-scope.js";
|
|
|
39
39
|
export function Disclosure(handle) {
|
|
40
40
|
return () => {
|
|
41
41
|
let { children, mix, ...rest } = handle.props;
|
|
42
|
-
return (_jsx("details", { ...rest, mix: [
|
|
42
|
+
return (_jsx("details", { ...rest, mix: mergeMix([
|
|
43
43
|
panelChrome(),
|
|
44
44
|
interpolateSize(),
|
|
45
45
|
detailsContent([
|
|
@@ -63,8 +63,7 @@ export function Disclosure(handle) {
|
|
|
63
63
|
detailsContent(transitionDuration("0s")),
|
|
64
64
|
when('& summary [data-slot="icon"]', transitionDuration("0s")),
|
|
65
65
|
]),
|
|
66
|
-
|
|
67
|
-
], children: children }));
|
|
66
|
+
], mix), children: children }));
|
|
68
67
|
};
|
|
69
68
|
}
|
|
70
69
|
/**
|
|
@@ -84,7 +83,7 @@ Disclosure.Header = function DisclosureHeader(handle) {
|
|
|
84
83
|
let { children, mix, ...rest } = handle.props;
|
|
85
84
|
let resolved = resolveHeadingLevel(handle);
|
|
86
85
|
let Tag = TAG_BY_LEVEL[resolved];
|
|
87
|
-
return (_jsx(Tag, { ...rest, "data-heading-level": resolved, mix: [m(0), balance(), mix
|
|
86
|
+
return (_jsx(Tag, { ...rest, "data-heading-level": resolved, mix: mergeMix([m(0), balance()], mix), children: children }));
|
|
88
87
|
};
|
|
89
88
|
};
|
|
90
89
|
/**
|
|
@@ -111,7 +110,7 @@ Disclosure.Trigger = function DisclosureTrigger(handle) {
|
|
|
111
110
|
* and it holds before any script runs.
|
|
112
111
|
*/
|
|
113
112
|
let disabled = rest["aria-disabled"] === "true";
|
|
114
|
-
return (_jsx("summary", { ...rest, tabIndex: disabled ? -1 : rest.tabIndex, mix: [
|
|
113
|
+
return (_jsx("summary", { ...rest, tabIndex: disabled ? -1 : rest.tabIndex, mix: mergeMix([
|
|
115
114
|
when("&:focus-visible", outline({ color: "brand.ring", offset: 2 })),
|
|
116
115
|
flex(),
|
|
117
116
|
is("full"),
|
|
@@ -137,8 +136,7 @@ Disclosure.Trigger = function DisclosureTrigger(handle) {
|
|
|
137
136
|
when('& [data-slot="icon"]', [is(4), bs(4), shrink()]),
|
|
138
137
|
transition("color, background-color, border-color, outline-color, text-decoration-color, fill, stroke"),
|
|
139
138
|
when('&[aria-disabled="true"]', cursor("not-allowed")),
|
|
140
|
-
|
|
141
|
-
], children: children }));
|
|
139
|
+
], mix), children: children }));
|
|
142
140
|
};
|
|
143
141
|
};
|
|
144
142
|
/**
|
|
@@ -156,7 +154,7 @@ Disclosure.Trigger = function DisclosureTrigger(handle) {
|
|
|
156
154
|
Disclosure.Panel = function DisclosurePanel(handle) {
|
|
157
155
|
return () => {
|
|
158
156
|
let { children, mix, ...rest } = handle.props;
|
|
159
|
-
return (_jsx("div", { ...rest, mix: [
|
|
157
|
+
return (_jsx("div", { ...rest, mix: mergeMix([
|
|
160
158
|
overflow(),
|
|
161
159
|
/**
|
|
162
160
|
* The panel is inset to the line the trigger's label sits on, so the section reads as
|
|
@@ -165,8 +163,7 @@ Disclosure.Panel = function DisclosurePanel(handle) {
|
|
|
165
163
|
*/
|
|
166
164
|
pi(3),
|
|
167
165
|
pbe(3),
|
|
168
|
-
|
|
169
|
-
], children: children }));
|
|
166
|
+
], mix), children: children }));
|
|
170
167
|
};
|
|
171
168
|
};
|
|
172
169
|
/**
|
|
@@ -195,7 +192,7 @@ Disclosure.Panel = function DisclosurePanel(handle) {
|
|
|
195
192
|
Disclosure.Group = function DisclosureGroup(handle) {
|
|
196
193
|
return () => {
|
|
197
194
|
let { children, mix, ...rest } = handle.props;
|
|
198
|
-
return (_jsx("div", { ...rest, mix: [
|
|
195
|
+
return (_jsx("div", { ...rest, mix: mergeMix([
|
|
199
196
|
flex(),
|
|
200
197
|
flexCol(),
|
|
201
198
|
when("& > details", [
|
|
@@ -213,7 +210,6 @@ Disclosure.Group = function DisclosureGroup(handle) {
|
|
|
213
210
|
roundedCorner("end-end", "lg"),
|
|
214
211
|
]),
|
|
215
212
|
]),
|
|
216
|
-
|
|
217
|
-
], children: children }));
|
|
213
|
+
], mix), children: children }));
|
|
218
214
|
};
|
|
219
215
|
};
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsx as _jsx } from "remix/component/jsx-runtime";
|
|
2
2
|
import { rounded } from "@sdxc/u/effects";
|
|
3
|
-
import { vars, willChange } from "@sdxc/u/general";
|
|
3
|
+
import { vars, willChange, mergeMix } from "@sdxc/u/general";
|
|
4
4
|
import { fixed, insBe, insBs, insIe, insIs, insLeft, insRight } from "@sdxc/u/layout";
|
|
5
5
|
import { bs, is, m, maxBs, maxIs } from "@sdxc/u/size";
|
|
6
6
|
import { data } from "@sdxc/u/state";
|
|
@@ -48,7 +48,7 @@ export function Drawer(handle) {
|
|
|
48
48
|
return () => {
|
|
49
49
|
let { placement, mix, ...rest } = handle.props;
|
|
50
50
|
let resolvedPlacement = placement ?? DEFAULT_PLACEMENT;
|
|
51
|
-
return (_jsx(Dialog, { ...rest, "data-placement": resolvedPlacement, mix: [
|
|
51
|
+
return (_jsx(Dialog, { ...rest, "data-placement": resolvedPlacement, mix: mergeMix([
|
|
52
52
|
fixed(),
|
|
53
53
|
m(0),
|
|
54
54
|
rounded("none"),
|
|
@@ -122,8 +122,7 @@ export function Drawer(handle) {
|
|
|
122
122
|
"ui-drawer-exit-offset": `${EXIT_DISTANCE} 0`,
|
|
123
123
|
}),
|
|
124
124
|
]),
|
|
125
|
-
|
|
126
|
-
] }));
|
|
125
|
+
], mix) }));
|
|
127
126
|
};
|
|
128
127
|
}
|
|
129
128
|
/**
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { jsx as _jsx } from "remix/component/jsx-runtime";
|
|
2
2
|
import { fg } from "@sdxc/u/color";
|
|
3
|
+
import { mergeMix } from "@sdxc/u/general";
|
|
3
4
|
import { pretty, text, weight } from "@sdxc/u/typography";
|
|
4
5
|
import { attrs } from "remix/component";
|
|
5
6
|
/**
|
|
@@ -25,13 +26,12 @@ const DEFAULT_FIELD_ERROR_ATTRIBUTE = true;
|
|
|
25
26
|
export function FieldError(handle) {
|
|
26
27
|
return () => {
|
|
27
28
|
let { id, mix, ...rest } = handle.props;
|
|
28
|
-
return (_jsx("span", { id: id ?? handle.id, ...rest, mix: [
|
|
29
|
+
return (_jsx("span", { id: id ?? handle.id, ...rest, mix: mergeMix([
|
|
29
30
|
attrs({ "data-field-error": DEFAULT_FIELD_ERROR_ATTRIBUTE }),
|
|
30
31
|
fg("danger"),
|
|
31
32
|
weight("medium"),
|
|
32
33
|
text("sm"),
|
|
33
34
|
pretty(),
|
|
34
|
-
|
|
35
|
-
] }));
|
|
35
|
+
], mix) }));
|
|
36
36
|
};
|
|
37
37
|
}
|
package/dist/components/form.js
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs } from "remix/component/jsx-runtime";
|
|
2
|
+
import { mergeMix } from "@sdxc/u/general";
|
|
2
3
|
import { flex, flexCol, gap } from "@sdxc/u/layout";
|
|
3
4
|
import { Alert } from "./alert.js";
|
|
4
5
|
/** {@link Form.Props.issues} fallback for a first, not-yet-submitted render. */
|
|
@@ -78,7 +79,7 @@ export function Form(handle) {
|
|
|
78
79
|
return formIssues;
|
|
79
80
|
},
|
|
80
81
|
});
|
|
81
|
-
return (_jsxs("form", { ...rest, mix: [flex(), flexCol(), gap(4), mix
|
|
82
|
+
return (_jsxs("form", { ...rest, mix: mergeMix([flex(), flexCol(), gap(4)], mix), children: [formIssues.length > 0 && (_jsx(Alert, { color: "danger", "data-slot": "form-issues", children: _jsx(Alert.Description, { children: formIssues.map((issue) => issue.message).join(" ") }) })), children] }));
|
|
82
83
|
};
|
|
83
84
|
}
|
|
84
85
|
/**
|
|
@@ -10,6 +10,7 @@
|
|
|
10
10
|
* @copyright Sergio Xalambrí 2026
|
|
11
11
|
*/
|
|
12
12
|
import type { Handle, Props as TagProps } from "remix/component";
|
|
13
|
+
import type { RemixNode } from "remix/component";
|
|
13
14
|
/**
|
|
14
15
|
* Prop types for {@link Group}.
|
|
15
16
|
*/
|
|
@@ -21,6 +22,16 @@ export declare namespace Group {
|
|
|
21
22
|
*/
|
|
22
23
|
interface Props extends TagProps<"div"> {
|
|
23
24
|
}
|
|
25
|
+
/**
|
|
26
|
+
* Native `<label>` attributes plus `mix`. Set `htmlFor` to the control's `id` so a
|
|
27
|
+
* click on the addon focuses it, and `id` to list the addon in the control's
|
|
28
|
+
* `aria-describedby`; give the control its name through `aria-label` or
|
|
29
|
+
* `aria-labelledby`, which keeps the addon's text out of that name.
|
|
30
|
+
*/
|
|
31
|
+
interface TextProps extends TagProps<"label"> {
|
|
32
|
+
/** The addon's static text: a currency, a unit, a domain. */
|
|
33
|
+
children: RemixNode;
|
|
34
|
+
}
|
|
24
35
|
}
|
|
25
36
|
/**
|
|
26
37
|
* Lays children out in a centered flex row with no border, background, or gap, joining
|
|
@@ -43,3 +54,6 @@ export declare namespace Group {
|
|
|
43
54
|
* </Group>
|
|
44
55
|
*/
|
|
45
56
|
export declare function Group(handle: Handle<Group.Props>): () => import("remix/component").RemixElement;
|
|
57
|
+
export declare namespace Group {
|
|
58
|
+
var Text: (handle: Handle<Group.TextProps>) => () => import("remix/component").RemixElement;
|
|
59
|
+
}
|