@sdxc/ui 2026.10.29 → 2026.11.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +187 -113
- package/dist/{behaviors → app/behaviors}/drag-session.js +1 -1
- package/dist/{behaviors → app/behaviors}/toaster.js +1 -1
- package/dist/{components → app}/chart.d.ts +1 -1
- package/dist/{components → app}/chart.js +18 -34
- package/dist/{components → app}/context-menu.d.ts +2 -2
- package/dist/{components → app}/context-menu.js +8 -7
- package/dist/{components → app}/drop-indicator.js +3 -3
- package/dist/{components → app}/drop-zone.js +3 -3
- package/dist/{components → app}/empty.d.ts +1 -1
- package/dist/{components → app}/empty.js +11 -21
- package/dist/{components → app}/file-trigger.js +2 -2
- 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 +41 -0
- package/dist/app/index.js +41 -0
- package/dist/{components → app}/menubar.js +5 -7
- package/dist/{mixins → app/mixins}/drag-reorder.js +1 -1
- package/dist/{mixins → app/mixins}/drop-zone.js +1 -1
- package/dist/{mixins → app/mixins}/grid-list-keys.js +2 -2
- package/dist/{mixins → app/mixins}/menubar-keys.js +2 -2
- package/dist/{mixins → app/mixins}/resize-handle.js +3 -3
- package/dist/{mixins/treeKeys.js → app/mixins/tree-keys.js} +2 -2
- package/dist/{components → app}/resizable.js +7 -10
- package/dist/{components → app}/shortcut-list.js +4 -3
- package/dist/{components → app}/skeleton.js +3 -3
- 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/{components → app}/table.js +12 -15
- package/dist/{components → app}/toast.js +18 -24
- 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/{utils → app/utils}/chart-path.d.ts +1 -1
- package/dist/{utils → app/utils}/chart-path.js +2 -2
- package/dist/{utils → app/utils}/chart-scale.js +1 -1
- 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/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/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.js +3 -3
- 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 +6 -38
- package/dist/components/index.js +6 -38
- package/dist/components/input.js +3 -4
- 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 +16 -11
- 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/radio-group.js +5 -7
- package/dist/components/range-calendar.js +3 -3
- 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/switch.js +3 -3
- package/dist/components/tabs.js +9 -12
- package/dist/components/tag-group.js +7 -9
- package/dist/components/text-field.js +2 -1
- 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/toggle-button.js +5 -7
- package/dist/components/tooltip.js +3 -3
- package/dist/components/typeset.js +128 -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 +55 -0
- package/dist/docs/docs-feedback.js +72 -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 +53 -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 +46 -0
- package/dist/docs/docs-pager.js +74 -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 +97 -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 +79 -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 +7 -5
- package/dist/{patterns → landing}/faq-band.js +11 -12
- 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/landing/landing-section.d.ts +110 -0
- 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 +14 -4
- package/dist/{components → landing}/split.js +30 -21
- 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 -4
- 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/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 +2 -15
- package/dist/mixins/index.js +2 -15
- package/dist/styles/index.d.ts +2 -5
- package/dist/styles/index.js +2 -5
- package/dist/styles/landing.d.ts +200 -0
- package/dist/styles/landing.js +516 -0
- package/dist/styles/surface-control.d.ts +18 -0
- package/dist/styles/surface-control.js +31 -0
- package/dist/utils/eyebrow.d.ts +39 -0
- package/dist/utils/eyebrow.js +21 -0
- package/dist/utils/index.d.ts +1 -5
- package/dist/utils/index.js +1 -5
- package/package.json +14 -4
- package/src/theme.css +87 -22
- package/dist/components/feature.d.ts +0 -102
- package/dist/components/feature.js +0 -151
- 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.d.ts +0 -81
- package/dist/components/marketing-section.js +0 -103
- package/dist/components/stat-strip.js +0 -64
- 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 -67
- package/dist/patterns/bento.js +0 -95
- 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 -45
- package/dist/patterns/step-list.js +0 -84
- 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/{behaviors → app/behaviors}/toaster.d.ts +0 -0
- /package/dist/{components → app}/drop-indicator.d.ts +0 -0
- /package/dist/{components → app}/drop-zone.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/{components → app}/skeleton.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}/table.d.ts +0 -0
- /package/dist/{components → app}/toast.d.ts +0 -0
- /package/dist/{components → app}/toolbar.d.ts +0 -0
- /package/dist/{utils → app/utils}/chart-marker-indices.d.ts +0 -0
- /package/dist/{utils → app/utils}/chart-marker-indices.js +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
|
@@ -2,7 +2,7 @@ import { jsx as _jsx, jsxs as _jsxs } from "remix/component/jsx-runtime";
|
|
|
2
2
|
import { visuallyHidden } from "@sdxc/u/a11y";
|
|
3
3
|
import { bg, fg, outline } from "@sdxc/u/color";
|
|
4
4
|
import { opacity, rounded } from "@sdxc/u/effects";
|
|
5
|
-
import { cursor } from "@sdxc/u/general";
|
|
5
|
+
import { cursor, mergeMix } from "@sdxc/u/general";
|
|
6
6
|
import { flex, gap, items } from "@sdxc/u/layout";
|
|
7
7
|
import { overflow } from "@sdxc/u/overflow";
|
|
8
8
|
import { maxBs, pb, pi } from "@sdxc/u/size";
|
|
@@ -48,14 +48,13 @@ export function ListBox(handle) {
|
|
|
48
48
|
let resolvedName = name ?? handle.id;
|
|
49
49
|
let resolvedMultiple = multiple ?? DEFAULT_MULTIPLE;
|
|
50
50
|
handle.context.set({ name: resolvedName, multiple: resolvedMultiple });
|
|
51
|
-
return (_jsx("div", { ...rest, mix: [
|
|
51
|
+
return (_jsx("div", { ...rest, mix: mergeMix([
|
|
52
52
|
attrs({ role: resolvedMultiple ? "group" : "radiogroup" }),
|
|
53
53
|
maxBs(60),
|
|
54
54
|
overflow("auto"),
|
|
55
55
|
surfaceInset(),
|
|
56
56
|
outline("none"),
|
|
57
|
-
|
|
58
|
-
] }));
|
|
57
|
+
], mix) }));
|
|
59
58
|
};
|
|
60
59
|
}
|
|
61
60
|
/**
|
|
@@ -79,7 +78,7 @@ ListBox.Item = function ListBoxItem(handle) {
|
|
|
79
78
|
let resolvedName = name ?? context.name;
|
|
80
79
|
let type = context.multiple ? "checkbox" : "radio";
|
|
81
80
|
warnIfNoAccessibleName(handle.props, children, "ListBox.Item: an option with no visible text needs an `aria-label` describing it — assistive technology has no accessible name to announce otherwise.");
|
|
82
|
-
return (_jsxs("label", { ...rest, mix: [
|
|
81
|
+
return (_jsxs("label", { ...rest, mix: mergeMix([
|
|
83
82
|
interactiveTransition(),
|
|
84
83
|
flex(),
|
|
85
84
|
items("center"),
|
|
@@ -95,10 +94,7 @@ ListBox.Item = function ListBoxItem(handle) {
|
|
|
95
94
|
* The row the keyboard is on is where the next Enter lands, so it is shown before it is
|
|
96
95
|
* chosen. The tint stops at the selected row, which keeps its stronger fill while walked past.
|
|
97
96
|
*/
|
|
98
|
-
when('&[data-highlighted="true"]:not(:has(input:checked)):not([aria-selected="true"])', [
|
|
99
|
-
bg("brand.bg-tint-pressed"),
|
|
100
|
-
fg("brand.emphasis"),
|
|
101
|
-
]),
|
|
97
|
+
when('&[data-highlighted="true"]:not(:has(input:checked)):not([aria-selected="true"])', [bg("brand.bg-tint-pressed"), fg("brand.emphasis")]),
|
|
102
98
|
when('&:has(input:checked), &[aria-selected="true"]', [
|
|
103
99
|
bg("brand.solid"),
|
|
104
100
|
fg("brand.onSolid"),
|
|
@@ -107,8 +103,7 @@ ListBox.Item = function ListBoxItem(handle) {
|
|
|
107
103
|
cursor("default"),
|
|
108
104
|
text("sm"),
|
|
109
105
|
outline("none"),
|
|
110
|
-
|
|
111
|
-
], children: [_jsx("input", { type: type, value: value, name: resolvedName, checked: checked, defaultChecked: defaultChecked, disabled: disabled, required: required, mix: [visuallyHidden(), parts?.input] }), children] }));
|
|
106
|
+
], mix), children: [_jsx("input", { type: type, value: value, name: resolvedName, checked: checked, defaultChecked: defaultChecked, disabled: disabled, required: required, mix: [visuallyHidden(), parts?.input] }), children] }));
|
|
112
107
|
};
|
|
113
108
|
};
|
|
114
109
|
/**
|
package/dist/components/menu.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { jsx as _jsx } from "remix/component/jsx-runtime";
|
|
2
2
|
import { bg, fg, outline } from "@sdxc/u/color";
|
|
3
3
|
import { rounded, opacity } from "@sdxc/u/effects";
|
|
4
|
-
import { cursor } from "@sdxc/u/general";
|
|
4
|
+
import { cursor, mergeMix } from "@sdxc/u/general";
|
|
5
5
|
import { flex, gap, items, shrink } from "@sdxc/u/layout";
|
|
6
6
|
import { bs, is, minIs, mb, pb, pi } from "@sdxc/u/size";
|
|
7
7
|
import { active, disabled, focusVisible, hover, when } from "@sdxc/u/state";
|
|
@@ -64,7 +64,7 @@ export function Menu(handle) {
|
|
|
64
64
|
return () => {
|
|
65
65
|
let { placement, children, mix, ...rest } = handle.props;
|
|
66
66
|
let resolvedPlacement = placement ?? DEFAULT_PLACEMENT;
|
|
67
|
-
return (_jsx(Popover, { ...rest, placement: resolvedPlacement, mix: [attrs({ role: DEFAULT_ROLE }), minIs("10rem"), surfaceInset(), outline("none"), mix
|
|
67
|
+
return (_jsx(Popover, { ...rest, placement: resolvedPlacement, mix: mergeMix([attrs({ role: DEFAULT_ROLE }), minIs("10rem"), surfaceInset(), outline("none")], mix), children: children }));
|
|
68
68
|
};
|
|
69
69
|
}
|
|
70
70
|
/**
|
|
@@ -85,7 +85,7 @@ Menu.Item = function MenuItem(handle) {
|
|
|
85
85
|
return () => {
|
|
86
86
|
let { href, target, rel, type, danger, children, mix, ...rest } = handle.props;
|
|
87
87
|
warnIfNoAccessibleName(handle.props, children, "Menu.Item: a row with no visible text needs an `aria-label` describing it — assistive technology has no accessible name to announce otherwise.");
|
|
88
|
-
let itemMix = [
|
|
88
|
+
let itemMix = mergeMix([
|
|
89
89
|
interactiveTransition(),
|
|
90
90
|
attrs({ role: DEFAULT_ITEM_ROLE }),
|
|
91
91
|
flex(),
|
|
@@ -118,8 +118,7 @@ Menu.Item = function MenuItem(handle) {
|
|
|
118
118
|
textDecoration("none"),
|
|
119
119
|
text("sm"),
|
|
120
120
|
textAlign("start"),
|
|
121
|
-
|
|
122
|
-
];
|
|
121
|
+
], mix);
|
|
123
122
|
if (href) {
|
|
124
123
|
/**
|
|
125
124
|
* `rest`'s fields (aria-*, data-*, id, event props, …) are all valid
|
|
@@ -147,6 +146,6 @@ Menu.Item = function MenuItem(handle) {
|
|
|
147
146
|
Menu.Separator = function MenuSeparator(handle) {
|
|
148
147
|
return () => {
|
|
149
148
|
let { mix, ...rest } = handle.props;
|
|
150
|
-
return _jsx(Separator, { ...rest, mix:
|
|
149
|
+
return _jsx(Separator, { ...rest, mix: mergeMix(mb(1), mix) });
|
|
151
150
|
};
|
|
152
151
|
};
|
package/dist/components/meter.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { jsx as _jsx } from "remix/component/jsx-runtime";
|
|
2
2
|
import { bg, border, fg } from "@sdxc/u/color";
|
|
3
3
|
import { rounded, transition } from "@sdxc/u/effects";
|
|
4
|
-
import { raw } from "@sdxc/u/general";
|
|
4
|
+
import { raw, mergeMix } from "@sdxc/u/general";
|
|
5
5
|
import { appearance, block, vstack } from "@sdxc/u/layout";
|
|
6
6
|
import { overflow } from "@sdxc/u/overflow";
|
|
7
7
|
import { media } from "@sdxc/u/responsive";
|
|
@@ -47,7 +47,7 @@ const FILL_SELECTORS = [
|
|
|
47
47
|
export function Meter(handle) {
|
|
48
48
|
return () => {
|
|
49
49
|
let { mix, ...rest } = handle.props;
|
|
50
|
-
return _jsx("div", { ...rest, mix:
|
|
50
|
+
return _jsx("div", { ...rest, mix: mergeMix(vstack({ gap: "0.25rem" }), mix) });
|
|
51
51
|
};
|
|
52
52
|
}
|
|
53
53
|
/**
|
|
@@ -78,7 +78,7 @@ Meter.Indicator = function MeterIndicator(handle) {
|
|
|
78
78
|
let resolvedColor = color ?? DEFAULT_COLOR;
|
|
79
79
|
let resolvedMax = max ?? DEFAULT_MAX;
|
|
80
80
|
warnIfNoAccessibleLabel(handle.props, "Meter.Indicator: a meter with no `aria-label` or `aria-labelledby` needs one describing what it measures — assistive technology has no accessible name to announce otherwise.");
|
|
81
|
-
return (_jsx("meter", { "data-color": resolvedColor, max: resolvedMax, ...rest, mix: [
|
|
81
|
+
return (_jsx("meter", { "data-color": resolvedColor, max: resolvedMax, ...rest, mix: mergeMix([
|
|
82
82
|
appearance(),
|
|
83
83
|
is("full"),
|
|
84
84
|
bs("var(--ui-meter-track-block-size, 0.5rem)"),
|
|
@@ -97,8 +97,7 @@ Meter.Indicator = function MeterIndicator(handle) {
|
|
|
97
97
|
data("color", "warning", FILL_SELECTORS.map((selector) => when(selector, bg("warning.solid")))),
|
|
98
98
|
data("color", "danger", FILL_SELECTORS.map((selector) => when(selector, bg("danger.solid")))),
|
|
99
99
|
media("(prefers-reduced-motion: reduce)", FILL_SELECTORS.map((selector) => when(selector, raw({ transitionDuration: "0s" })))),
|
|
100
|
-
|
|
101
|
-
] }));
|
|
100
|
+
], mix) }));
|
|
102
101
|
};
|
|
103
102
|
};
|
|
104
103
|
/**
|
|
@@ -114,6 +113,6 @@ Meter.Indicator = function MeterIndicator(handle) {
|
|
|
114
113
|
Meter.ValueLabel = function MeterValueLabel(handle) {
|
|
115
114
|
return () => {
|
|
116
115
|
let { mix, ...rest } = handle.props;
|
|
117
|
-
return _jsx("span", { ...rest, mix: [text("sm"), tabularNums(), fg("neutral"), mix
|
|
116
|
+
return _jsx("span", { ...rest, mix: mergeMix([text("sm"), tabularNums(), fg("neutral")], mix) });
|
|
118
117
|
};
|
|
119
118
|
};
|
package/dist/components/modal.js
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { jsx as _jsx } from "remix/component/jsx-runtime";
|
|
2
|
+
import { mergeMix } from "@sdxc/u/general";
|
|
2
3
|
import { durations, easings } from "../animations/tokens.js";
|
|
3
4
|
import { enterExit } from "../animations/transitions.js";
|
|
4
5
|
import { Dialog } from "./dialog.js";
|
|
@@ -37,17 +38,14 @@ const PANEL_EXIT_BLUR_PX = 2;
|
|
|
37
38
|
export function Modal(handle) {
|
|
38
39
|
return () => {
|
|
39
40
|
let { mix, ...rest } = handle.props;
|
|
40
|
-
return (_jsx(Dialog, { ...rest, mix:
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
}),
|
|
49
|
-
mix,
|
|
50
|
-
] }));
|
|
41
|
+
return (_jsx(Dialog, { ...rest, mix: mergeMix(enterExit({
|
|
42
|
+
opacity: 0,
|
|
43
|
+
scale: PANEL_ENTRY_SCALE,
|
|
44
|
+
duration: durations.normal,
|
|
45
|
+
easing: easings.standard,
|
|
46
|
+
exit: { scale: PANEL_EXIT_SCALE, blur: PANEL_EXIT_BLUR_PX },
|
|
47
|
+
exitDuration: durations.fast,
|
|
48
|
+
}), mix) }));
|
|
51
49
|
};
|
|
52
50
|
}
|
|
53
51
|
/**
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
* role and underlined to read as a link among surrounding prose. Its
|
|
4
4
|
* current-page state comes straight from `aria-current` set on the host
|
|
5
5
|
* server-side, rendering the emphasized, non-underlined treatment directly
|
|
6
|
-
* from that attribute.
|
|
6
|
+
* from that attribute. Landing sticky headers usually mix `text("sm")`
|
|
7
7
|
* (~13–15px) and a quiet hover so the bar stays dense beside the brand.
|
|
8
8
|
*
|
|
9
9
|
* @author [Sergio Xalambrí](https://sergiodxa.com)
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { jsx as _jsx, Fragment as _Fragment, jsxs as _jsxs } from "remix/component/jsx-runtime";
|
|
2
2
|
import { colorMix, fg, outline } from "@sdxc/u/color";
|
|
3
3
|
import { rounded } from "@sdxc/u/effects";
|
|
4
|
-
import { cursor, raw } from "@sdxc/u/general";
|
|
4
|
+
import { cursor, raw, mergeMix } from "@sdxc/u/general";
|
|
5
5
|
import { data, hover, when } from "@sdxc/u/state";
|
|
6
6
|
import { textDecoration, weight } from "@sdxc/u/typography";
|
|
7
7
|
import { interactiveTransition } from "../styles/interactive-transition.js";
|
|
@@ -29,7 +29,7 @@ export function NavLink(handle) {
|
|
|
29
29
|
let { color, hasBackground, prefetch, mix, ...rest } = handle.props;
|
|
30
30
|
let resolvedColor = color ?? DEFAULT_COLOR;
|
|
31
31
|
let resolvedPrefetch = prefetch ?? DEFAULT_PREFETCH;
|
|
32
|
-
return (_jsxs(_Fragment, { children: [_jsx("a", { ...rest, "data-color": resolvedColor, "data-has-background": hasBackground || undefined, "data-rmx-prefetch": prefetchAttribute(resolvedPrefetch), mix: [
|
|
32
|
+
return (_jsxs(_Fragment, { children: [_jsx("a", { ...rest, "data-color": resolvedColor, "data-has-background": hasBackground || undefined, "data-rmx-prefetch": prefetchAttribute(resolvedPrefetch), mix: mergeMix([
|
|
33
33
|
interactiveTransition(),
|
|
34
34
|
rounded("sm"),
|
|
35
35
|
when("&:focus-visible", outline({ color: "brand.ring", offset: 2 })),
|
|
@@ -81,7 +81,6 @@ export function NavLink(handle) {
|
|
|
81
81
|
]),
|
|
82
82
|
data("has-background", textDecoration("none")),
|
|
83
83
|
when('&[data-has-background]:hover, &[data-has-background][aria-current]:not([aria-current="false"])', textDecoration("none")),
|
|
84
|
-
|
|
85
|
-
] }), rendersPrefetchHint(resolvedPrefetch, rest.href) && (_jsx("link", { rel: "prefetch", href: rest.href }))] }));
|
|
84
|
+
], mix) }), rendersPrefetchHint(resolvedPrefetch, rest.href) && (_jsx("link", { rel: "prefetch", href: rest.href }))] }));
|
|
86
85
|
};
|
|
87
86
|
}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { jsx as _jsx, Fragment as _Fragment, jsxs as _jsxs } from "remix/component/jsx-runtime";
|
|
2
2
|
import { bg, fg, outline, outlineStyle } from "@sdxc/u/color";
|
|
3
3
|
import { opacity, rounded, transition, transitionBehavior, transitionProperty, } from "@sdxc/u/effects";
|
|
4
|
-
import { cursor, raw, userSelect } from "@sdxc/u/general";
|
|
4
|
+
import { cursor, raw, userSelect, mergeMix } from "@sdxc/u/general";
|
|
5
5
|
import { container, flex, flexCol, gap, grid, gridTemplate, inlineFlex, items, justify, relative, } from "@sdxc/u/layout";
|
|
6
6
|
import { overflow } from "@sdxc/u/overflow";
|
|
7
7
|
import { at, media, startingStyle } from "@sdxc/u/responsive";
|
|
@@ -77,7 +77,7 @@ const DEFAULT_PREFETCH = "none";
|
|
|
77
77
|
export function NavigationMenu(handle) {
|
|
78
78
|
return () => {
|
|
79
79
|
let { mix, ...rest } = handle.props;
|
|
80
|
-
return _jsx("nav", { ...rest, mix:
|
|
80
|
+
return _jsx("nav", { ...rest, mix: mergeMix(relative(), mix) });
|
|
81
81
|
};
|
|
82
82
|
}
|
|
83
83
|
/**
|
|
@@ -104,14 +104,13 @@ NavigationMenu.List = function NavigationMenuList(handle) {
|
|
|
104
104
|
return () => {
|
|
105
105
|
let { orientation, mix, ...rest } = handle.props;
|
|
106
106
|
let resolvedOrientation = orientation ?? DEFAULT_ORIENTATION;
|
|
107
|
-
return (_jsx("ul", { "data-orientation": resolvedOrientation, ...rest, mix: [
|
|
107
|
+
return (_jsx("ul", { "data-orientation": resolvedOrientation, ...rest, mix: mergeMix([
|
|
108
108
|
attrs({ role: DEFAULT_LIST_ROLE }),
|
|
109
109
|
flex(),
|
|
110
110
|
items("center"),
|
|
111
111
|
gap(1),
|
|
112
112
|
when('&[data-orientation="vertical"]', [flexCol(), items("start")]),
|
|
113
|
-
|
|
114
|
-
] }));
|
|
113
|
+
], mix) }));
|
|
115
114
|
};
|
|
116
115
|
};
|
|
117
116
|
/**
|
|
@@ -136,7 +135,7 @@ NavigationMenu.Item = function NavigationMenuItem(handle) {
|
|
|
136
135
|
return () => {
|
|
137
136
|
let { mix, ...rest } = handle.props;
|
|
138
137
|
handle.context.set({ contentId: handle.id });
|
|
139
|
-
return _jsx("li", { ...rest, mix: [relative(), flex(), items("center"), mix
|
|
138
|
+
return _jsx("li", { ...rest, mix: mergeMix([relative(), flex(), items("center")], mix) });
|
|
140
139
|
};
|
|
141
140
|
};
|
|
142
141
|
/**
|
|
@@ -158,7 +157,7 @@ NavigationMenu.Trigger = function NavigationMenuTrigger(handle) {
|
|
|
158
157
|
let resolvedType = type ?? DEFAULT_TRIGGER_TYPE;
|
|
159
158
|
let resolvedCommandfor = commandfor ?? context.contentId;
|
|
160
159
|
let resolvedCommand = command ?? DEFAULT_TRIGGER_COMMAND;
|
|
161
|
-
return (_jsx("button", { type: resolvedType, commandfor: resolvedCommandfor, command: resolvedCommand, ...rest, mix: [
|
|
160
|
+
return (_jsx("button", { type: resolvedType, commandfor: resolvedCommandfor, command: resolvedCommand, ...rest, mix: mergeMix([
|
|
162
161
|
interactiveTransition(),
|
|
163
162
|
when("&:focus-visible", outline({ color: "brand.ring", offset: 2 })),
|
|
164
163
|
inlineFlex(),
|
|
@@ -174,8 +173,7 @@ NavigationMenu.Trigger = function NavigationMenuTrigger(handle) {
|
|
|
174
173
|
when('&[aria-expanded="true"]', [bg("neutral.bg-tint-hover"), fg("neutral.emphasis")]),
|
|
175
174
|
disabled(cursor("not-allowed")),
|
|
176
175
|
text("sm"),
|
|
177
|
-
|
|
178
|
-
] }));
|
|
176
|
+
], mix) }));
|
|
179
177
|
};
|
|
180
178
|
};
|
|
181
179
|
/**
|
|
@@ -210,7 +208,7 @@ NavigationMenu.Content = function NavigationMenuContent(handle) {
|
|
|
210
208
|
let resolvedId = id ?? context.contentId;
|
|
211
209
|
let resolvedPlacement = placement ?? DEFAULT_CONTENT_PLACEMENT;
|
|
212
210
|
let resolvedSize = size ?? DEFAULT_CONTENT_SIZE;
|
|
213
|
-
return (_jsx(Popover, { id: resolvedId, placement: resolvedPlacement, "data-size": resolvedSize, ...rest, mix: [
|
|
211
|
+
return (_jsx(Popover, { id: resolvedId, placement: resolvedPlacement, "data-size": resolvedSize, ...rest, mix: mergeMix([
|
|
214
212
|
when("&:focus-visible", outline({ color: "brand.ring", offset: 2 })),
|
|
215
213
|
is("max-content"),
|
|
216
214
|
minIs("11rem"),
|
|
@@ -233,8 +231,7 @@ NavigationMenu.Content = function NavigationMenuContent(handle) {
|
|
|
233
231
|
scaleProperty("none"),
|
|
234
232
|
transitionProperty("opacity, display, overlay"),
|
|
235
233
|
]),
|
|
236
|
-
|
|
237
|
-
] }));
|
|
234
|
+
], mix) }));
|
|
238
235
|
};
|
|
239
236
|
};
|
|
240
237
|
/**
|
|
@@ -257,7 +254,7 @@ NavigationMenu.Link = function NavigationMenuLink(handle) {
|
|
|
257
254
|
return () => {
|
|
258
255
|
let { prefetch, mix, ...rest } = handle.props;
|
|
259
256
|
let resolvedPrefetch = prefetch ?? DEFAULT_PREFETCH;
|
|
260
|
-
let anchor = (_jsx("a", { "data-slot": "link", "data-rmx-prefetch": prefetchAttribute(resolvedPrefetch), ...rest, mix: [
|
|
257
|
+
let anchor = (_jsx("a", { "data-slot": "link", "data-rmx-prefetch": prefetchAttribute(resolvedPrefetch), ...rest, mix: mergeMix([
|
|
261
258
|
interactiveTransition(),
|
|
262
259
|
when("&:focus-visible", outline({ color: "brand.ring", offset: 2 })),
|
|
263
260
|
inlineFlex(),
|
|
@@ -278,8 +275,7 @@ NavigationMenu.Link = function NavigationMenuLink(handle) {
|
|
|
278
275
|
userSelect(),
|
|
279
276
|
textDecoration("none"),
|
|
280
277
|
fontSize("sm"),
|
|
281
|
-
|
|
282
|
-
] }));
|
|
278
|
+
], mix) }));
|
|
283
279
|
if (!rendersPrefetchHint(resolvedPrefetch, rest.href))
|
|
284
280
|
return anchor;
|
|
285
281
|
return (_jsxs(_Fragment, { children: [anchor, _jsx("link", { rel: "prefetch", href: rest.href })] }));
|
|
@@ -298,7 +294,7 @@ NavigationMenu.Link = function NavigationMenuLink(handle) {
|
|
|
298
294
|
NavigationMenu.Viewport = function NavigationMenuViewport(handle) {
|
|
299
295
|
return () => {
|
|
300
296
|
let { mix, ...rest } = handle.props;
|
|
301
|
-
return (_jsx("div", { ...rest, mix: [
|
|
297
|
+
return (_jsx("div", { ...rest, mix: mergeMix([
|
|
302
298
|
floatingSurface(),
|
|
303
299
|
raw({ borderRadius: concentricRadius(surfacePadding(2)) }),
|
|
304
300
|
relative(),
|
|
@@ -318,8 +314,7 @@ NavigationMenu.Viewport = function NavigationMenuViewport(handle) {
|
|
|
318
314
|
scaleProperty("none"),
|
|
319
315
|
transitionProperty("inline-size, block-size, opacity"),
|
|
320
316
|
]),
|
|
321
|
-
|
|
322
|
-
] }));
|
|
317
|
+
], mix) }));
|
|
323
318
|
};
|
|
324
319
|
};
|
|
325
320
|
/**
|
|
@@ -338,7 +333,7 @@ NavigationMenu.Viewport = function NavigationMenuViewport(handle) {
|
|
|
338
333
|
NavigationMenu.ContentList = function NavigationMenuContentList(handle) {
|
|
339
334
|
return () => {
|
|
340
335
|
let { mix, ...rest } = handle.props;
|
|
341
|
-
return _jsx("div", { ...rest, mix: [grid(), gap(1), mix
|
|
336
|
+
return _jsx("div", { ...rest, mix: mergeMix([grid(), gap(1)], mix) });
|
|
342
337
|
};
|
|
343
338
|
};
|
|
344
339
|
/**
|
|
@@ -363,12 +358,11 @@ NavigationMenu.ContentList = function NavigationMenuContentList(handle) {
|
|
|
363
358
|
NavigationMenu.ContentGrid = function NavigationMenuContentGrid(handle) {
|
|
364
359
|
return () => {
|
|
365
360
|
let { mix, ...rest } = handle.props;
|
|
366
|
-
return (_jsx("div", { ...rest, mix: [
|
|
361
|
+
return (_jsx("div", { ...rest, mix: mergeMix([
|
|
367
362
|
grid(),
|
|
368
363
|
gap(4),
|
|
369
364
|
at("40rem", CONTAINER_NAME, gridTemplate({ columns: "repeat(2, minmax(0, 1fr))" })),
|
|
370
|
-
|
|
371
|
-
] }));
|
|
365
|
+
], mix) }));
|
|
372
366
|
};
|
|
373
367
|
};
|
|
374
368
|
/**
|
|
@@ -386,6 +380,6 @@ NavigationMenu.ContentGrid = function NavigationMenuContentGrid(handle) {
|
|
|
386
380
|
NavigationMenu.ContentColumn = function NavigationMenuContentColumn(handle) {
|
|
387
381
|
return () => {
|
|
388
382
|
let { mix, ...rest } = handle.props;
|
|
389
|
-
return _jsx("div", { ...rest, mix: [grid(), gap(1), mix
|
|
383
|
+
return _jsx("div", { ...rest, mix: mergeMix([grid(), gap(1)], mix) });
|
|
390
384
|
};
|
|
391
385
|
};
|
|
@@ -2,7 +2,7 @@ import { jsx as _jsx } from "remix/component/jsx-runtime";
|
|
|
2
2
|
import { MinusIcon, PlusIcon } from "@sdxc/icons";
|
|
3
3
|
import { bg, border, borderEdge, fg, outline, outlineWidth } from "@sdxc/u/color";
|
|
4
4
|
import { opacity, rounded } from "@sdxc/u/effects";
|
|
5
|
-
import { cursor, raw } from "@sdxc/u/general";
|
|
5
|
+
import { cursor, raw, mergeMix } from "@sdxc/u/general";
|
|
6
6
|
import { basis, flex, grow, inlineFlex, items, justify, shrink } from "@sdxc/u/layout";
|
|
7
7
|
import { bs, is } from "@sdxc/u/size";
|
|
8
8
|
import { active, focusVisible, hover, invalid, when } from "@sdxc/u/state";
|
|
@@ -70,7 +70,7 @@ function stepperButtonMix(dividerEdge) {
|
|
|
70
70
|
export function NumberField(handle) {
|
|
71
71
|
return () => {
|
|
72
72
|
let { mix, ...rest } = handle.props;
|
|
73
|
-
return _jsx("div", { ...rest, "data-slot": "number-field", mix:
|
|
73
|
+
return _jsx("div", { ...rest, "data-slot": "number-field", mix: mergeMix(fieldStackLayout(), mix) });
|
|
74
74
|
};
|
|
75
75
|
}
|
|
76
76
|
/**
|
|
@@ -90,7 +90,7 @@ export function NumberField(handle) {
|
|
|
90
90
|
NumberField.Group = function NumberFieldGroup(handle) {
|
|
91
91
|
return () => {
|
|
92
92
|
let { mix, ...rest } = handle.props;
|
|
93
|
-
return (_jsx("div", { ...rest, "data-slot": "group", mix: [
|
|
93
|
+
return (_jsx("div", { ...rest, "data-slot": "group", mix: mergeMix([
|
|
94
94
|
attrs({ role: DEFAULT_ROLE }),
|
|
95
95
|
inlineFlex(),
|
|
96
96
|
items("stretch"),
|
|
@@ -109,8 +109,7 @@ NumberField.Group = function NumberFieldGroup(handle) {
|
|
|
109
109
|
outline({ color: "brand.ring", offset: 2 }),
|
|
110
110
|
border("neutral.border-hover"),
|
|
111
111
|
]),
|
|
112
|
-
|
|
113
|
-
] }));
|
|
112
|
+
], mix) }));
|
|
114
113
|
};
|
|
115
114
|
};
|
|
116
115
|
/**
|
|
@@ -128,7 +127,7 @@ NumberField.Group = function NumberFieldGroup(handle) {
|
|
|
128
127
|
NumberField.Input = function NumberFieldInput(handle) {
|
|
129
128
|
return () => {
|
|
130
129
|
let { mix, ...rest } = handle.props;
|
|
131
|
-
return (_jsx(Input, { type: "number", ...rest, mix: [
|
|
130
|
+
return (_jsx(Input, { type: "number", ...rest, mix: mergeMix([
|
|
132
131
|
textAlign("center"),
|
|
133
132
|
tabularNums(),
|
|
134
133
|
rounded("none"),
|
|
@@ -148,8 +147,7 @@ NumberField.Input = function NumberFieldInput(handle) {
|
|
|
148
147
|
when("&:disabled", bg("transparent")),
|
|
149
148
|
focusVisible(outlineWidth("0")),
|
|
150
149
|
invalid([outlineWidth("0"), fg("danger")]),
|
|
151
|
-
|
|
152
|
-
] }));
|
|
150
|
+
], mix) }));
|
|
153
151
|
};
|
|
154
152
|
};
|
|
155
153
|
/**
|
|
@@ -170,7 +168,7 @@ NumberField.DecrementButton = function NumberFieldDecrementButton(handle) {
|
|
|
170
168
|
if (import.meta.env?.DEV && !handle.props["aria-label"] && !handle.props["aria-labelledby"]) {
|
|
171
169
|
console.warn("NumberField.DecrementButton: needs an `aria-label` describing what it does — its content is a decorative glyph with no accessible name of its own.");
|
|
172
170
|
}
|
|
173
|
-
return (_jsx("button", { type: type ?? DEFAULT_BUTTON_TYPE, ...rest, "data-slot": "decrement", mix:
|
|
171
|
+
return (_jsx("button", { type: type ?? DEFAULT_BUTTON_TYPE, ...rest, "data-slot": "decrement", mix: mergeMix(stepperButtonMix("end"), mix), children: _jsx(MinusIcon, {}) }));
|
|
174
172
|
};
|
|
175
173
|
};
|
|
176
174
|
/**
|
|
@@ -191,6 +189,6 @@ NumberField.IncrementButton = function NumberFieldIncrementButton(handle) {
|
|
|
191
189
|
if (import.meta.env?.DEV && !handle.props["aria-label"] && !handle.props["aria-labelledby"]) {
|
|
192
190
|
console.warn("NumberField.IncrementButton: needs an `aria-label` describing what it does — its content is a decorative glyph with no accessible name of its own.");
|
|
193
191
|
}
|
|
194
|
-
return (_jsx("button", { type: type ?? DEFAULT_BUTTON_TYPE, ...rest, "data-slot": "increment", mix:
|
|
192
|
+
return (_jsx("button", { type: type ?? DEFAULT_BUTTON_TYPE, ...rest, "data-slot": "increment", mix: mergeMix(stepperButtonMix("start"), mix), children: _jsx(PlusIcon, {}) }));
|
|
195
193
|
};
|
|
196
194
|
};
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { jsx as _jsx } from "remix/component/jsx-runtime";
|
|
2
|
+
import { mergeMix } from "@sdxc/u/general";
|
|
2
3
|
import { tabularNums, text, textAlign, weight } from "@sdxc/u/typography";
|
|
3
4
|
import { Input } from "./input.js";
|
|
4
5
|
/** Maximum code length {@link OtpField} falls back to when `length` is omitted. */
|
|
@@ -41,6 +42,6 @@ export function OtpField(handle) {
|
|
|
41
42
|
let resolvedLength = length ?? DEFAULT_LENGTH;
|
|
42
43
|
let resolvedInputMode = inputMode ?? DEFAULT_INPUT_MODE;
|
|
43
44
|
let resolvedAutoComplete = autoComplete ?? DEFAULT_AUTO_COMPLETE;
|
|
44
|
-
return (_jsx(Input, { ...rest, type: "text", inputMode: resolvedInputMode, autoComplete: resolvedAutoComplete, maxLength: resolvedLength, "data-slot": "otp-field", mix: [textAlign("center"), weight(500), tabularNums(), text("base"), mix
|
|
45
|
+
return (_jsx(Input, { ...rest, type: "text", inputMode: resolvedInputMode, autoComplete: resolvedAutoComplete, maxLength: resolvedLength, "data-slot": "otp-field", mix: mergeMix([textAlign("center"), weight(500), tabularNums(), text("base")], mix) }));
|
|
45
46
|
};
|
|
46
47
|
}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsx as _jsx } from "remix/component/jsx-runtime";
|
|
2
2
|
import { fill } from "@sdxc/u/color";
|
|
3
|
-
import { calc, pointerEvents, var as varUtility } from "@sdxc/u/general";
|
|
3
|
+
import { calc, pointerEvents, var as varUtility, mergeMix } from "@sdxc/u/general";
|
|
4
4
|
import { absolute, flex, insBe, insBs, insIe, insIs, insLeft, insRight, items, justify, } from "@sdxc/u/layout";
|
|
5
5
|
import { is, mb, mi } from "@sdxc/u/size";
|
|
6
6
|
import { when } from "@sdxc/u/state";
|
|
@@ -39,7 +39,7 @@ export function OverlayArrow(handle) {
|
|
|
39
39
|
return () => {
|
|
40
40
|
let { placement, mix, ...rest } = handle.props;
|
|
41
41
|
let resolvedPlacement = placement ?? DEFAULT_PLACEMENT;
|
|
42
|
-
return (_jsx("div", { "data-placement": resolvedPlacement, ...rest, mix: [
|
|
42
|
+
return (_jsx("div", { "data-placement": resolvedPlacement, ...rest, mix: mergeMix([
|
|
43
43
|
attrs({ "aria-hidden": DEFAULT_ARIA_HIDDEN }),
|
|
44
44
|
absolute(),
|
|
45
45
|
/**
|
|
@@ -85,7 +85,6 @@ export function OverlayArrow(handle) {
|
|
|
85
85
|
insBe("0"),
|
|
86
86
|
is("max-content"),
|
|
87
87
|
]),
|
|
88
|
-
|
|
89
|
-
] }));
|
|
88
|
+
], mix) }));
|
|
90
89
|
};
|
|
91
90
|
}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { jsx as _jsx, Fragment as _Fragment, jsxs as _jsxs } from "remix/component/jsx-runtime";
|
|
2
2
|
import { bg, fg, outline } from "@sdxc/u/color";
|
|
3
3
|
import { opacity, rounded } from "@sdxc/u/effects";
|
|
4
|
-
import { cursor, listStyle, pointerEvents } from "@sdxc/u/general";
|
|
4
|
+
import { cursor, listStyle, pointerEvents, mergeMix } from "@sdxc/u/general";
|
|
5
5
|
import { flex, gap, inlineFlex, items, justify } from "@sdxc/u/layout";
|
|
6
6
|
import { bs, m, minIs, p, pi } from "@sdxc/u/size";
|
|
7
7
|
import { active, hover, when } from "@sdxc/u/state";
|
|
@@ -36,7 +36,7 @@ export function Pagination(handle) {
|
|
|
36
36
|
return () => {
|
|
37
37
|
let { mix, ...rest } = handle.props;
|
|
38
38
|
warnIfNoAccessibleLabel(handle.props, 'Pagination: needs an "aria-label" or "aria-labelledby" identifying which set of results it paginates for assistive technology.');
|
|
39
|
-
return _jsx("nav", { ...rest, "data-slot": "pagination", mix: [flex(), items("center"), mix
|
|
39
|
+
return _jsx("nav", { ...rest, "data-slot": "pagination", mix: mergeMix([flex(), items("center")], mix) });
|
|
40
40
|
};
|
|
41
41
|
}
|
|
42
42
|
/**
|
|
@@ -59,7 +59,7 @@ export function Pagination(handle) {
|
|
|
59
59
|
Pagination.List = function PaginationList(handle) {
|
|
60
60
|
return () => {
|
|
61
61
|
let { mix, ...rest } = handle.props;
|
|
62
|
-
return (_jsx("ul", { ...rest, "data-slot": "list", mix: [flex(), items("center"), gap("0.25rem"), m("0"), p("0"), listStyle(), mix
|
|
62
|
+
return (_jsx("ul", { ...rest, "data-slot": "list", mix: mergeMix([flex(), items("center"), gap("0.25rem"), m("0"), p("0"), listStyle()], mix) }));
|
|
63
63
|
};
|
|
64
64
|
};
|
|
65
65
|
/**
|
|
@@ -77,7 +77,7 @@ Pagination.List = function PaginationList(handle) {
|
|
|
77
77
|
Pagination.Item = function PaginationItem(handle) {
|
|
78
78
|
return () => {
|
|
79
79
|
let { mix, ...rest } = handle.props;
|
|
80
|
-
return _jsx("li", { ...rest, "data-slot": "item", mix: [flex(), items("center"), mix
|
|
80
|
+
return _jsx("li", { ...rest, "data-slot": "item", mix: mergeMix([flex(), items("center")], mix) });
|
|
81
81
|
};
|
|
82
82
|
};
|
|
83
83
|
/**
|
|
@@ -98,7 +98,7 @@ Pagination.Link = function PaginationLink(handle) {
|
|
|
98
98
|
return () => {
|
|
99
99
|
let { prefetch, mix, ...rest } = handle.props;
|
|
100
100
|
let resolvedPrefetch = prefetch ?? DEFAULT_PREFETCH;
|
|
101
|
-
let anchor = (_jsx("a", { "data-rmx-prefetch": prefetchAttribute(resolvedPrefetch), ...rest, "data-slot": "link", mix: [
|
|
101
|
+
let anchor = (_jsx("a", { "data-rmx-prefetch": prefetchAttribute(resolvedPrefetch), ...rest, "data-slot": "link", mix: mergeMix([
|
|
102
102
|
interactiveTransition(),
|
|
103
103
|
inlineFlex(),
|
|
104
104
|
items("center"),
|
|
@@ -120,8 +120,7 @@ Pagination.Link = function PaginationLink(handle) {
|
|
|
120
120
|
tabularNums(),
|
|
121
121
|
textDecoration("none"),
|
|
122
122
|
when('&[aria-disabled="true"]', [cursor("not-allowed"), pointerEvents()]),
|
|
123
|
-
|
|
124
|
-
] }));
|
|
123
|
+
], mix) }));
|
|
125
124
|
if (!rendersPrefetchHint(resolvedPrefetch, rest.href))
|
|
126
125
|
return anchor;
|
|
127
126
|
return (_jsxs(_Fragment, { children: [anchor, _jsx("link", { rel: "prefetch", href: rest.href })] }));
|
|
@@ -149,7 +148,7 @@ Pagination.Button = function PaginationButton(handle) {
|
|
|
149
148
|
let isInvoker = rest.command !== undefined || rest.commandfor !== undefined;
|
|
150
149
|
let resolvedType = type ?? (isInvoker ? INVOKER_TYPE : undefined);
|
|
151
150
|
warnIfNoAccessibleName(handle.props, children, 'Pagination.Button: an icon-only control needs an "aria-label" describing what it does — assistive technology has no accessible text to announce otherwise.');
|
|
152
|
-
return (_jsx("button", { type: resolvedType, ...rest, "data-slot": "button", mix: [
|
|
151
|
+
return (_jsx("button", { type: resolvedType, ...rest, "data-slot": "button", mix: mergeMix([
|
|
153
152
|
interactiveTransition(),
|
|
154
153
|
inlineFlex(),
|
|
155
154
|
items("center"),
|
|
@@ -167,7 +166,6 @@ Pagination.Button = function PaginationButton(handle) {
|
|
|
167
166
|
text("sm"),
|
|
168
167
|
tabularNums(),
|
|
169
168
|
when("&:disabled", cursor("not-allowed")),
|
|
170
|
-
|
|
171
|
-
], children: children }));
|
|
169
|
+
], mix), children: children }));
|
|
172
170
|
};
|
|
173
171
|
};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { jsx as _jsx } from "remix/component/jsx-runtime";
|
|
2
|
-
import { raw } from "@sdxc/u/general";
|
|
2
|
+
import { raw, mergeMix } from "@sdxc/u/general";
|
|
3
3
|
import { inset, positionArea, positionTryFallbacks } from "@sdxc/u/layout";
|
|
4
4
|
import { m, marginLeft, marginRight, mbe, mbs } from "@sdxc/u/size";
|
|
5
5
|
import { data, when } from "@sdxc/u/state";
|
|
@@ -42,7 +42,7 @@ export function Popover(handle) {
|
|
|
42
42
|
let { id, popover, placement, children, mix, ...rest } = handle.props;
|
|
43
43
|
let resolvedMode = popover ?? DEFAULT_MODE;
|
|
44
44
|
let resolvedPlacement = placement ?? DEFAULT_PLACEMENT;
|
|
45
|
-
return (_jsx("div", { id: id, popover: resolvedMode, "data-placement": resolvedPlacement, ...rest, mix: [
|
|
45
|
+
return (_jsx("div", { id: id, popover: resolvedMode, "data-placement": resolvedPlacement, ...rest, mix: mergeMix([
|
|
46
46
|
floatingSurface(),
|
|
47
47
|
m("0"),
|
|
48
48
|
inset("auto"),
|
|
@@ -73,7 +73,6 @@ export function Popover(handle) {
|
|
|
73
73
|
* reveals itself from CSS state on its trigger, so it keeps its own hidden state.
|
|
74
74
|
*/
|
|
75
75
|
when('&:not(:popover-open):not([popover="hint"])', raw({ display: "none !important" })),
|
|
76
|
-
|
|
77
|
-
], children: children }));
|
|
76
|
+
], mix), children: children }));
|
|
78
77
|
};
|
|
79
78
|
}
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { jsx as _jsx } from "remix/component/jsx-runtime";
|
|
2
2
|
import { bg, border, fg } from "@sdxc/u/color";
|
|
3
3
|
import { rounded, transition, transitionDuration } from "@sdxc/u/effects";
|
|
4
|
+
import { mergeMix } from "@sdxc/u/general";
|
|
4
5
|
import { appearance, block, flex, flexCol, gap } from "@sdxc/u/layout";
|
|
5
6
|
import { overflow } from "@sdxc/u/overflow";
|
|
6
7
|
import { media } from "@sdxc/u/responsive";
|
|
@@ -26,7 +27,7 @@ const DEFAULT_MAX = 100;
|
|
|
26
27
|
export function ProgressBar(handle) {
|
|
27
28
|
return () => {
|
|
28
29
|
let { mix, ...rest } = handle.props;
|
|
29
|
-
return _jsx("div", { ...rest, mix: [flex(), flexCol(), gap("0.25rem"), mix
|
|
30
|
+
return _jsx("div", { ...rest, mix: mergeMix([flex(), flexCol(), gap("0.25rem")], mix) });
|
|
30
31
|
};
|
|
31
32
|
}
|
|
32
33
|
/**
|
|
@@ -46,7 +47,7 @@ ProgressBar.Indicator = function ProgressBarIndicator(handle) {
|
|
|
46
47
|
let { mix, max, ...rest } = handle.props;
|
|
47
48
|
let resolvedMax = max ?? DEFAULT_MAX;
|
|
48
49
|
warnIfNoAccessibleLabel(handle.props, "ProgressBar.Indicator: a progress indicator with no `aria-label` or `aria-labelledby` needs one describing what it tracks — assistive technology has no accessible name to announce otherwise.");
|
|
49
|
-
return (_jsx("progress", { max: resolvedMax, ...rest, mix: [
|
|
50
|
+
return (_jsx("progress", { max: resolvedMax, ...rest, mix: mergeMix([
|
|
50
51
|
appearance(),
|
|
51
52
|
block(),
|
|
52
53
|
is("full"),
|
|
@@ -68,8 +69,7 @@ ProgressBar.Indicator = function ProgressBarIndicator(handle) {
|
|
|
68
69
|
when("&::-webkit-progress-value", transitionDuration("0s")),
|
|
69
70
|
when("&::-moz-progress-bar", transitionDuration("0s")),
|
|
70
71
|
]),
|
|
71
|
-
|
|
72
|
-
] }));
|
|
72
|
+
], mix) }));
|
|
73
73
|
};
|
|
74
74
|
};
|
|
75
75
|
/**
|
|
@@ -85,6 +85,6 @@ ProgressBar.Indicator = function ProgressBarIndicator(handle) {
|
|
|
85
85
|
ProgressBar.ValueLabel = function ProgressBarValueLabel(handle) {
|
|
86
86
|
return () => {
|
|
87
87
|
let { mix, ...rest } = handle.props;
|
|
88
|
-
return _jsx("span", { ...rest, mix: [fg("neutral"), text("sm"), tabularNums(), mix
|
|
88
|
+
return _jsx("span", { ...rest, mix: mergeMix([fg("neutral"), text("sm"), tabularNums()], mix) });
|
|
89
89
|
};
|
|
90
90
|
};
|