@espressif/dashboard-ui-components 1.11.1 → 1.12.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.claude/rules/dashboard-ui-consumption.md +176 -5
- package/.cursor/rules/dashboard-ui-consumption.mdc +163 -4
- package/CHANGELOG.md +1020 -0
- package/README.md +240 -7
- package/THIRD-PARTY-NOTICES.md +2 -1
- package/dist/alert.props-CcKo49Rb.d.ts +44 -0
- package/dist/animation/index.d.ts +3 -0
- package/dist/animation/index.js +3 -0
- package/dist/avatar.props-2q5BsX-R.d.ts +29 -0
- package/dist/button-BK-DIR_L.d.ts +21 -0
- package/dist/button-BxJ7s6sR.d.ts +76 -0
- package/dist/calendar.props-BtCzuWH1.d.ts +12 -0
- package/dist/carousel/index.d.ts +2 -0
- package/dist/carousel/index.js +2 -0
- package/dist/charts/index.d.ts +5 -0
- package/dist/charts/index.js +9 -0
- package/dist/common/app-logo/app-logo.js +1 -1
- package/dist/common/index.d.ts +9 -20
- package/dist/common/my-account-menu/my-account-menu.js +45 -13
- package/dist/common/profile-card/profile-card.js +3 -2
- package/dist/components/accordion/accordion.js +14 -5
- package/dist/components/accordion/index.d.ts +36 -0
- package/dist/components/accordion/index.js +2 -0
- package/dist/components/advanced-search-box/advanced-search-box.js +8 -2
- package/dist/components/advanced-search-box/index.d.ts +29 -0
- package/dist/components/advanced-search-box/index.js +2 -0
- package/dist/components/alert/alert.js +2 -1
- package/dist/components/alert/index.d.ts +12 -0
- package/dist/components/alert/index.js +2 -0
- package/dist/components/anchored-panel/anchored-panel.js +83 -0
- package/dist/components/anchored-panel/index.d.ts +31 -0
- package/dist/components/anchored-panel/index.js +2 -0
- package/dist/components/animated-containers/index.d.ts +13 -0
- package/dist/components/animated-containers/index.js +2 -0
- package/dist/components/async-multi-select/async-multi-select.js +48 -7
- package/dist/components/async-multi-select/index.d.ts +63 -0
- package/dist/components/async-multi-select/index.js +2 -0
- package/dist/components/avatar/avatar.js +11 -4
- package/dist/components/avatar/index.d.ts +8 -0
- package/dist/components/avatar/index.js +2 -0
- package/dist/components/avatar-group/avatar-group.js +35 -0
- package/dist/components/avatar-group/index.d.ts +31 -0
- package/dist/components/avatar-group/index.js +2 -0
- package/dist/components/badge/index.d.ts +14 -0
- package/dist/components/badge/index.js +2 -0
- package/dist/components/breadcrumb/index.d.ts +21 -0
- package/dist/components/breadcrumb/index.js +2 -0
- package/dist/components/bubble/bubble.js +18 -0
- package/dist/components/bubble/index.d.ts +19 -0
- package/dist/components/bubble/index.js +2 -0
- package/dist/components/button/button.js +87 -25
- package/dist/components/button/flash-button.js +9 -3
- package/dist/components/button/index.d.ts +56 -0
- package/dist/components/button/index.js +6 -0
- package/dist/components/button-group/index.d.ts +16 -0
- package/dist/components/button-group/index.js +2 -0
- package/dist/components/calendar/calendar.js +5 -5
- package/dist/components/calendar/index.d.ts +11 -0
- package/dist/components/calendar/index.js +2 -0
- package/dist/components/card/index.d.ts +11 -0
- package/dist/components/card/index.js +2 -0
- package/dist/components/card-rail/card-rail.js +50 -0
- package/dist/components/card-rail/index.d.ts +30 -0
- package/dist/components/card-rail/index.js +2 -0
- package/dist/components/cards/collapsible-card.js +5 -2
- package/dist/components/cards/index.d.ts +16200 -0
- package/dist/components/cards/index.js +8 -0
- package/dist/components/cards/section-card.js +133 -8
- package/dist/components/cards/simple-card.js +5 -2
- package/dist/components/carousel/carousel.js +137 -49
- package/dist/components/carousel/index.d.ts +130 -0
- package/dist/components/carousel/index.js +2 -0
- package/dist/components/category-card/category-card.js +111 -0
- package/dist/components/category-card/index.d.ts +55 -0
- package/dist/components/category-card/index.js +2 -0
- package/dist/components/chart/area-chart.js +95 -85
- package/dist/components/chart/bar-chart.js +123 -60
- package/dist/components/chart/chart.js +127 -3
- package/dist/components/chart/composed-chart.js +109 -98
- package/dist/components/chart/donut-chart.js +23 -5
- package/dist/components/chart/index.d.ts +732 -0
- package/dist/components/chart/index.js +9 -0
- package/dist/components/chart/line-chart.js +93 -83
- package/dist/components/chart/treemap-chart.js +71 -58
- package/dist/components/check-badge/check-badge.js +25 -0
- package/dist/components/check-badge/index.d.ts +13 -0
- package/dist/components/check-badge/index.js +2 -0
- package/dist/components/checkbox/index.d.ts +8 -0
- package/dist/components/checkbox/index.js +2 -0
- package/dist/components/choice-card/choice-card.js +99 -0
- package/dist/components/choice-card/index.d.ts +41 -0
- package/dist/components/choice-card/index.js +2 -0
- package/dist/components/circular-progress/circular-progress.js +5 -2
- package/dist/components/circular-progress/index.d.ts +23 -0
- package/dist/components/circular-progress/index.js +2 -0
- package/dist/components/code/index.d.ts +40 -0
- package/dist/components/code/index.js +2 -0
- package/dist/components/code-editor/code-editor.js +9 -3
- package/dist/components/code-editor/index.d.ts +82 -0
- package/dist/components/code-editor/index.js +2 -0
- package/dist/components/collapsible/index.d.ts +42 -0
- package/dist/components/collapsible/index.js +2 -0
- package/dist/components/column-panel/column-panel.js +38 -0
- package/dist/components/column-panel/index.d.ts +37 -0
- package/dist/components/column-panel/index.js +3 -0
- package/dist/components/column-panel/use-panel-flag.js +27 -0
- package/dist/components/combobox/index.d.ts +28 -0
- package/dist/components/combobox/index.js +2 -0
- package/dist/components/confirmation-dialog/confirmation-dialog.js +1 -1
- package/dist/components/confirmation-dialog/index.d.ts +40 -0
- package/dist/components/confirmation-dialog/index.js +3 -0
- package/dist/components/content-container/index.d.ts +16 -0
- package/dist/components/content-container/index.js +2 -0
- package/dist/components/copiable-text/index.d.ts +33 -0
- package/dist/components/copiable-text/index.js +2 -0
- package/dist/components/coverflow/_constants/coverflow-poses.js +23 -0
- package/dist/components/coverflow/_constants/coverflow-shapes.js +23 -0
- package/dist/components/coverflow/_hooks/use-coverflow.js +90 -0
- package/dist/components/coverflow/_utils/ring.js +24 -0
- package/dist/components/coverflow/coverflow.js +198 -0
- package/dist/components/coverflow/index.d.ts +105 -0
- package/dist/components/coverflow/index.js +2 -0
- package/dist/components/data-table/data-table.js +9 -2
- package/dist/components/data-table/index.d.ts +120 -0
- package/dist/components/data-table/index.js +3 -0
- package/dist/components/date-picker/date-picker.js +5 -2
- package/dist/components/date-picker/index.d.ts +50 -0
- package/dist/components/date-picker/index.js +2 -0
- package/dist/components/date-range-picker/date-range-picker.js +11 -2
- package/dist/components/date-range-picker/index.d.ts +100 -0
- package/dist/components/date-range-picker/index.js +3 -0
- package/dist/components/date-time-picker/date-time-picker.js +5 -2
- package/dist/components/date-time-picker/index.d.ts +79 -0
- package/dist/components/date-time-picker/index.js +2 -0
- package/dist/components/device-icon/index.d.ts +17 -0
- package/dist/components/device-icon/index.js +2 -0
- package/dist/components/dialog/index.d.ts +38 -0
- package/dist/components/dialog/index.js +2 -0
- package/dist/components/dropdown-menu/index.d.ts +57 -0
- package/dist/components/dropdown-menu/index.js +2 -0
- package/dist/components/dynamic-list/dynamic-list.js +4 -4
- package/dist/components/dynamic-list/index.d.ts +74 -0
- package/dist/components/dynamic-list/index.js +2 -0
- package/dist/components/error-display/index.d.ts +17 -0
- package/dist/components/error-display/index.js +3 -0
- package/dist/components/expandable-text/expandable-text-overlay.js +78 -0
- package/dist/components/expandable-text/expandable-text.js +73 -0
- package/dist/components/expandable-text/index.d.ts +39 -0
- package/dist/components/expandable-text/index.js +2 -0
- package/dist/components/expandable-text/use-clamped.js +23 -0
- package/dist/components/facet-filters/_hooks/use-filter-group.js +51 -0
- package/dist/components/facet-filters/active-filters.js +31 -0
- package/dist/components/facet-filters/filter-group.js +110 -0
- package/dist/components/facet-filters/filters-panel.js +59 -0
- package/dist/components/facet-filters/filters-pill.js +40 -0
- package/dist/components/facet-filters/index.d.ts +104 -0
- package/dist/components/facet-filters/index.js +6 -0
- package/dist/components/facet-filters/use-filters-collapsed.js +21 -0
- package/dist/components/feature-grid/feature-grid.js +115 -0
- package/dist/components/feature-grid/index.d.ts +53 -0
- package/dist/components/feature-grid/index.js +2 -0
- package/dist/components/file-input/file-input.js +9 -3
- package/dist/components/file-input/index.d.ts +78 -0
- package/dist/components/file-input/index.js +2 -0
- package/dist/components/file-upload/file-upload.js +10 -5
- package/dist/components/file-upload/index.d.ts +38 -0
- package/dist/components/file-upload/index.js +2 -0
- package/dist/components/filters-bar/filters-bar.js +5 -1
- package/dist/components/filters-bar/index.d.ts +26 -0
- package/dist/components/filters-bar/index.js +2 -0
- package/dist/components/flip-card/flip-card.js +147 -0
- package/dist/components/flip-card/index.d.ts +43 -0
- package/dist/components/flip-card/index.js +2 -0
- package/dist/components/floating-window/_hooks/use-drag-move.js +76 -0
- package/dist/components/floating-window/floating-window.js +97 -0
- package/dist/components/floating-window/index.d.ts +45 -0
- package/dist/components/floating-window/index.js +2 -0
- package/dist/components/form/index.d.ts +28 -0
- package/dist/components/form/index.js +2 -0
- package/dist/components/fullscreen-dialog/fullscreen-dialog.js +6 -2
- package/dist/components/fullscreen-dialog/index.d.ts +38 -0
- package/dist/components/fullscreen-dialog/index.js +2 -0
- package/dist/components/horizontal-stepper/horizontal-stepper.js +122 -0
- package/dist/components/horizontal-stepper/index.d.ts +70 -0
- package/dist/components/horizontal-stepper/index.js +2 -0
- package/dist/components/icon-avatar/index.d.ts +9 -0
- package/dist/components/icon-avatar/index.js +2 -0
- package/dist/components/icon-text-action-card/icon-text-action-card.js +9 -5
- package/dist/components/icon-text-action-card/index.d.ts +11 -0
- package/dist/components/icon-text-action-card/index.js +2 -0
- package/dist/components/identicon/identicon.js +33 -0
- package/dist/components/identicon/index.d.ts +26 -0
- package/dist/components/identicon/index.js +2 -0
- package/dist/components/illustration/index.d.ts +37 -0
- package/dist/components/illustration/index.js +3 -0
- package/dist/components/index.d.ts +177 -19529
- package/dist/components/index.js +61 -10
- package/dist/components/input/index.d.ts +15 -0
- package/dist/components/input/index.js +3 -0
- package/dist/components/input-group/index.d.ts +35 -0
- package/dist/components/input-group/index.js +2 -0
- package/dist/components/input-group/input-group.js +41 -0
- package/dist/components/input-otp/index.d.ts +63 -0
- package/dist/components/input-otp/index.js +2 -0
- package/dist/components/key-value-manager/index.d.ts +63 -0
- package/dist/components/key-value-manager/index.js +2 -0
- package/dist/components/key-value-manager/key-value-manager-table.js +7 -5
- package/dist/components/label/index.d.ts +8 -0
- package/dist/components/label/index.js +2 -0
- package/dist/components/link/index.d.ts +33 -0
- package/dist/components/link/index.js +2 -0
- package/dist/components/list/index.d.ts +9 -0
- package/dist/components/list/index.js +3 -0
- package/dist/components/list/list-item.utils.js +1 -1
- package/dist/components/list/list.js +3 -1
- package/dist/components/list-details/index.d.ts +51 -0
- package/dist/components/list-details/index.js +2 -0
- package/dist/components/list-details/list-details.js +5 -2
- package/dist/components/lottie-animation-container/index.d.ts +10 -0
- package/dist/components/lottie-animation-container/index.js +2 -0
- package/dist/components/lottie-animation-container/lottie-animation-container.js +22 -3
- package/dist/components/lottie-animations/index.d.ts +8 -0
- package/dist/components/lottie-animations/index.js +2 -0
- package/dist/components/markdown-content/index.d.ts +32 -0
- package/dist/components/markdown-content/index.js +2 -0
- package/dist/components/media-card/index.d.ts +125 -0
- package/dist/components/media-card/index.js +4 -0
- package/dist/components/media-card/media-card-image.js +59 -0
- package/dist/components/media-card/media-card-reveal.js +76 -0
- package/dist/components/media-card/media-card.classes.js +37 -0
- package/dist/components/media-card/media-card.js +91 -0
- package/dist/components/media-stage/index.d.ts +41 -0
- package/dist/components/media-stage/index.js +2 -0
- package/dist/components/media-stage/media-stage.js +48 -0
- package/dist/components/menu/index.d.ts +14 -0
- package/dist/components/menu/index.js +2 -0
- package/dist/components/message-scroller/_hooks/use-follow-bottom.js +85 -0
- package/dist/components/message-scroller/index.d.ts +29 -0
- package/dist/components/message-scroller/index.js +2 -0
- package/dist/components/message-scroller/message-scroller.js +65 -0
- package/dist/components/mini-bar-chart/index.d.ts +40 -0
- package/dist/components/mini-bar-chart/index.js +2 -0
- package/dist/components/mini-bar-chart/mini-bar-chart.js +93 -0
- package/dist/components/monospace-content/index.d.ts +43 -0
- package/dist/components/monospace-content/index.js +2 -0
- package/dist/components/monospace-content/monospace-content.js +1 -1
- package/dist/components/nav-bar/index.d.ts +148 -0
- package/dist/components/nav-bar/index.js +2 -0
- package/dist/components/nav-bar/nav-bar-details-panel.js +158 -44
- package/dist/components/nav-bar/nav-bar-mobile-menu.js +93 -27
- package/dist/components/nav-bar/nav-bar.js +256 -138
- package/dist/components/nav-bar/use-nav-bar-hover-details.js +80 -0
- package/dist/components/nav-bar/use-nav-bar-overflow.js +5 -5
- package/dist/components/notice-strip/index.d.ts +32 -0
- package/dist/components/notice-strip/index.js +2 -0
- package/dist/components/notice-strip/notice-strip.js +57 -0
- package/dist/components/option-card-group/index.d.ts +50 -0
- package/dist/components/option-card-group/index.js +2 -0
- package/dist/components/option-card-group/option-card-group.js +76 -0
- package/dist/components/overflow-badge-list/index.d.ts +63 -0
- package/dist/components/overflow-badge-list/index.js +2 -0
- package/dist/components/overflow-badge-list/overflow-badge-list.js +78 -19
- package/dist/components/page-banner/index.d.ts +33 -0
- package/dist/components/page-banner/index.js +2 -0
- package/dist/components/page-banner/page-banner.js +56 -0
- package/dist/components/page-container/index.d.ts +20 -0
- package/dist/components/page-container/index.js +3 -0
- package/dist/components/page-container/page-container.js +5 -5
- package/dist/components/pagination/index.d.ts +31 -0
- package/dist/components/pagination/index.js +3 -0
- package/dist/components/popover/index.d.ts +60 -0
- package/dist/components/popover/index.js +3 -0
- package/dist/components/preview-card/index.d.ts +24 -0
- package/dist/components/preview-card/index.js +2 -0
- package/dist/components/progress-bar/index.d.ts +32 -0
- package/dist/components/progress-bar/index.js +2 -0
- package/dist/components/progress-bar/progress-bar.js +22 -6
- package/dist/components/radio-group/index.d.ts +24 -0
- package/dist/components/radio-group/index.js +2 -0
- package/dist/components/rank-numeral/index.d.ts +30 -0
- package/dist/components/rank-numeral/index.js +2 -0
- package/dist/components/rank-numeral/rank-numeral.js +26 -0
- package/dist/components/reaction-button/index.d.ts +32 -0
- package/dist/components/reaction-button/index.js +2 -0
- package/dist/components/reaction-button/reaction-button.js +50 -0
- package/dist/components/readout/index.d.ts +31 -0
- package/dist/components/readout/index.js +2 -0
- package/dist/components/readout/readout.js +63 -0
- package/dist/components/requirement-list/index.d.ts +52 -0
- package/dist/components/requirement-list/index.js +2 -0
- package/dist/components/requirement-list/requirement-list.js +29 -8
- package/dist/components/resizable/index.d.ts +31 -0
- package/dist/components/resizable/index.js +4 -0
- package/dist/components/resizable/resizable-group.js +23 -0
- package/dist/components/resizable/resizable-panel.js +28 -0
- package/dist/components/resizable/resizable-separator.js +24 -0
- package/dist/components/reveal/index.d.ts +23 -0
- package/dist/components/reveal/index.js +2 -0
- package/dist/components/reveal/reveal.js +24 -0
- package/dist/components/scroll-area/index.d.ts +27 -0
- package/dist/components/scroll-area/index.js +2 -0
- package/dist/components/scrollable-sections/index.d.ts +58 -0
- package/dist/components/scrollable-sections/index.js +2 -0
- package/dist/components/scrollable-sections/scrollable-sections.js +11 -3
- package/dist/components/search-box/index.d.ts +32 -0
- package/dist/components/search-box/index.js +2 -0
- package/dist/components/search-box/search-box.js +18 -3
- package/dist/components/search-field-shell.js +1 -1
- package/dist/components/select/index.d.ts +44 -0
- package/dist/components/select/index.js +2 -0
- package/dist/components/selectable-card-list/checkbox-card-list.js +5 -3
- package/dist/components/selectable-card-list/index.d.ts +76 -0
- package/dist/components/selectable-card-list/index.js +2 -0
- package/dist/components/selectable-card-list/radio-card-list.js +12 -6
- package/dist/components/selectable-card-list/selectable-card-list-shared.js +24 -12
- package/dist/components/selectable-card-list/selectable-card-list.js +12 -3
- package/dist/components/separator/index.d.ts +24 -0
- package/dist/components/separator/index.js +2 -0
- package/dist/components/share-menu/index.d.ts +55 -0
- package/dist/components/share-menu/index.js +2 -0
- package/dist/components/share-menu/share-marks.js +31 -0
- package/dist/components/share-menu/share-menu.js +140 -0
- package/dist/components/share-menu/share-urls.js +15 -0
- package/dist/components/sheet/index.d.ts +41 -0
- package/dist/components/sheet/index.js +2 -0
- package/dist/components/showcase-card/index.d.ts +53 -0
- package/dist/components/showcase-card/index.js +2 -0
- package/dist/components/showcase-card/showcase-card.js +75 -0
- package/dist/components/sidebar/index.d.ts +109 -0
- package/dist/components/sidebar/index.js +4 -0
- package/dist/components/sidebar/sidebar.js +56 -40
- package/dist/components/simple-clickable-card/index.d.ts +11 -0
- package/dist/components/simple-clickable-card/index.js +2 -0
- package/dist/components/simple-clickable-card/simple-clickable-card-shared.js +2 -2
- package/dist/components/simple-clickable-card/simple-clickable-card.js +5 -2
- package/dist/components/simple-info-card/index.d.ts +25 -0
- package/dist/components/simple-info-card/index.js +2 -0
- package/dist/components/simple-info-card/simple-info-card.js +6 -3
- package/dist/components/simple-list/index.d.ts +63 -0
- package/dist/components/simple-list/index.js +2 -0
- package/dist/components/simple-list/simple-list.js +3 -1
- package/dist/components/simple-paginated-list/index.d.ts +20 -0
- package/dist/components/simple-paginated-list/index.js +2 -0
- package/dist/components/simplified-date/index.d.ts +18 -0
- package/dist/components/simplified-date/index.js +2 -0
- package/dist/components/skeleton/index.d.ts +5 -0
- package/dist/components/skeleton/index.js +2 -0
- package/dist/components/skeletons/index.d.ts +11 -0
- package/dist/components/skeletons/index.js +2 -0
- package/dist/components/sort-menu/index.d.ts +34 -0
- package/dist/components/sort-menu/index.js +2 -0
- package/dist/components/sort-menu/sort-menu.js +39 -0
- package/dist/components/spinner/index.d.ts +15 -0
- package/dist/components/spinner/index.js +2 -0
- package/dist/components/stat-card/index.d.ts +43 -0
- package/dist/components/stat-card/index.js +2 -0
- package/dist/components/stat-card/stat-card.js +31 -12
- package/dist/components/status-badge/index.d.ts +24 -0
- package/dist/components/status-badge/index.js +2 -0
- package/dist/components/status-badge/status-badge.js +3 -2
- package/dist/components/status-card-list/index.d.ts +24 -0
- package/dist/components/status-card-list/index.js +2 -0
- package/dist/components/status-card-list/status-card-list.js +8 -4
- package/dist/components/step-tabs/index.d.ts +94 -0
- package/dist/components/step-tabs/index.js +2 -0
- package/dist/components/step-tabs/step-tabs.js +202 -0
- package/dist/components/style-scope/index.d.ts +32 -0
- package/dist/components/style-scope/index.js +2 -0
- package/dist/components/style-scope/style-scope.js +49 -0
- package/dist/components/switch/index.d.ts +15 -0
- package/dist/components/switch/index.js +2 -0
- package/dist/components/table/index.d.ts +18 -0
- package/dist/components/table/index.js +2 -0
- package/dist/components/tabs/index.d.ts +103 -0
- package/dist/components/tabs/index.js +2 -0
- package/dist/components/tag/index.d.ts +31 -0
- package/dist/components/tag/index.js +2 -0
- package/dist/components/tag/tag.js +79 -28
- package/dist/components/tag-input/index.d.ts +36 -0
- package/dist/components/tag-input/index.js +2 -0
- package/dist/components/tag-input/tag-input.js +10 -4
- package/dist/components/text-effects/index.d.ts +53 -0
- package/dist/components/text-effects/index.js +6 -0
- package/dist/components/textarea/index.d.ts +16 -0
- package/dist/components/textarea/index.js +2 -0
- package/dist/components/thumbnail-strip/index.d.ts +42 -0
- package/dist/components/thumbnail-strip/index.js +2 -0
- package/dist/components/thumbnail-strip/thumbnail-strip.js +124 -0
- package/dist/components/thumbnail-strip/use-scroll-edges.js +41 -0
- package/dist/components/time-picker/index.d.ts +13 -0
- package/dist/components/time-picker/index.js +2 -0
- package/dist/components/timeline/index.d.ts +39 -0
- package/dist/components/timeline/index.js +2 -0
- package/dist/components/timeline/timeline.js +85 -0
- package/dist/components/toast/index.d.ts +56 -0
- package/dist/components/toast/index.js +2 -0
- package/dist/components/toast/toast.js +42 -32
- package/dist/components/togglable-items-list/index.d.ts +28 -0
- package/dist/components/togglable-items-list/index.js +2 -0
- package/dist/components/toggle-group/index.d.ts +35 -0
- package/dist/components/toggle-group/index.js +2 -0
- package/dist/components/toolbar/index.d.ts +58 -0
- package/dist/components/toolbar/index.js +3 -0
- package/dist/components/toolbar/toolbar-button.js +40 -0
- package/dist/components/toolbar/toolbar.js +56 -0
- package/dist/components/tooltip/index.d.ts +29 -0
- package/dist/components/tooltip/index.js +3 -0
- package/dist/components/tooltip/tooltip.js +12 -2
- package/dist/components/transfer-list/index.d.ts +36 -0
- package/dist/components/transfer-list/index.js +2 -0
- package/dist/components/transfer-list/transfer-list.js +1 -1
- package/dist/components/truncated-line-with-tooltip/index.d.ts +22 -0
- package/dist/components/truncated-line-with-tooltip/index.js +2 -0
- package/dist/components/truncated-line-with-tooltip/truncated-line-with-tooltip.js +26 -8
- package/dist/components/typography/index.d.ts +19 -0
- package/dist/components/typography/index.js +3 -0
- package/dist/components/use-mobile/index.d.ts +3 -0
- package/dist/components/use-mobile/index.js +2 -0
- package/dist/components/user-type-badge/index.d.ts +39 -0
- package/dist/components/user-type-badge/index.js +3 -0
- package/dist/components/user-type-badge/user-type-badge.js +2 -1
- package/dist/components/vertical-stepper/index.d.ts +7 -0
- package/dist/components/vertical-stepper/index.js +2 -0
- package/dist/components/vertical-stepper/vertical-stepper.js +33 -6
- package/dist/components/view-toggle/index.d.ts +38 -0
- package/dist/components/view-toggle/index.js +2 -0
- package/dist/components/view-toggle/view-toggle.js +56 -0
- package/dist/core/animate-ui/components/animate/code.js +83 -9
- package/dist/core/animate-ui/components/animate/tabs.js +234 -19
- package/dist/core/animate-ui/components/animate/tooltip.js +10 -2
- package/dist/core/animate-ui/components/base/preview-card.js +20 -3
- package/dist/core/animate-ui/components/buttons/copy.js +12 -6
- package/dist/core/animate-ui/components/radix/dialog.js +17 -3
- package/dist/core/animate-ui/components/radix/dropdown-menu.js +26 -9
- package/dist/core/animate-ui/components/radix/sheet.js +20 -4
- package/dist/core/animate-ui/components/radix/sidebar.js +9 -9
- package/dist/core/animate-ui/components/radix/toggle-group.js +103 -13
- package/dist/core/animate-ui/components/radix/toggle.js +5 -5
- package/dist/core/animate-ui/primitives/animate/code-block.js +31 -4
- package/dist/core/animate-ui/primitives/animate/shiki-highlighter.js +5 -2
- package/dist/core/animate-ui/primitives/animate/tabs.js +7 -4
- package/dist/core/animate-ui/primitives/animate/tooltip.js +10 -3
- package/dist/core/animate-ui/primitives/base/preview-card.js +2 -2
- package/dist/core/animate-ui/primitives/base/progress.js +1 -1
- package/dist/core/animate-ui/primitives/base/radio.js +3 -3
- package/dist/core/animate-ui/primitives/effects/highlight.js +1 -0
- package/dist/core/animate-ui/primitives/radix/accordion.js +1 -1
- package/dist/core/animate-ui/primitives/radix/dialog.js +6 -3
- package/dist/core/animate-ui/primitives/radix/dropdown-menu.js +2 -2
- package/dist/core/animate-ui/primitives/radix/sheet.js +7 -3
- package/dist/core/animate-ui/primitives/radix/switch.js +2 -2
- package/dist/core/animate-ui/primitives/radix/toggle-group.js +2 -2
- package/dist/core/badge.js +5 -2
- package/dist/core/breadcrumb.js +1 -1
- package/dist/core/button/button.js +8 -8
- package/dist/core/button/craft-button.js +8 -2
- package/dist/core/button.js +17 -7
- package/dist/core/card.js +23 -5
- package/dist/core/combobox/combobox.js +8 -2
- package/dist/core/command.js +3 -3
- package/dist/core/form.js +1 -1
- package/dist/core/hooks/use-nested-layer-press-guard.js +46 -0
- package/dist/core/hooks/use-on-screen.js +33 -0
- package/dist/core/hooks/use-prefers-reduced-motion.js +19 -0
- package/dist/core/hooks/use-scroll-overflow.js +20 -0
- package/dist/core/index.d.ts +30 -5
- package/dist/core/index.js +5 -2
- package/dist/core/input/input-password.js +13 -9
- package/dist/core/input/input.js +38 -12
- package/dist/core/input-otp/input-otp.js +9 -5
- package/dist/core/popover-group.js +48 -0
- package/dist/core/popover-hover.js +127 -0
- package/dist/core/popover.js +75 -6
- package/dist/core/select.js +50 -19
- package/dist/core/table.js +5 -3
- package/dist/core/textarea/textarea.js +11 -3
- package/dist/data-table/index.d.ts +4 -0
- package/dist/data-table/index.js +3 -0
- package/dist/date/index.d.ts +11 -0
- package/dist/date/index.js +7 -0
- package/dist/forms/index.d.ts +4 -0
- package/dist/forms/index.js +2 -0
- package/dist/icon-avatar.props-RYtw2eSW.d.ts +31 -0
- package/dist/icon-text-action-card.props-B2ggncUK.d.ts +53 -0
- package/dist/index.d.ts +169 -15
- package/dist/index.js +63 -10
- package/dist/input-CYI1hhGc.d.ts +38 -0
- package/dist/layouts/index.d.ts +132 -8
- package/dist/layouts/index.js +3 -1
- package/dist/layouts/minimal-workspace-layout/minimal-workspace-layout-context.js +5 -0
- package/dist/layouts/minimal-workspace-layout/minimal-workspace-layout.js +404 -0
- package/dist/layouts/minimal-workspace-layout/rail-logo.js +90 -0
- package/dist/layouts/minimal-workspace-layout/sidebar-trigger.js +42 -0
- package/dist/layouts/shared/account-menu-props.js +21 -0
- package/dist/layouts/shared/footer-branding.js +34 -0
- package/dist/layouts/shared/sidebar-logo.js +59 -0
- package/dist/layouts/workspace-layout/account-menu/account-menu.js +9 -3
- package/dist/layouts/workspace-layout/footer/footer.js +1 -1
- package/dist/layouts/workspace-layout/header/header.js +1 -1
- package/dist/layouts/workspace-layout/workspace-layout.js +28 -80
- package/dist/{list.props-x1j3CbcF.d.ts → list.props-DP_xPTqU.d.ts} +2 -1
- package/dist/markdown/index.d.ts +11 -0
- package/dist/markdown/index.js +5 -0
- package/dist/my-account-menu.props-C7DK71WC.d.ts +67 -0
- package/dist/page-container.props-JutTvKFq.d.ts +48 -0
- package/dist/resizable.props-RxFY5tm_.d.ts +44 -0
- package/dist/section-card-B7c5uc08.d.ts +84 -0
- package/dist/simple-clickable-card.props-BrPCw7CR.d.ts +51 -0
- package/dist/slot-DGErA9zi.d.ts +10 -0
- package/dist/status-badge.props-lKlEOfRt.d.ts +32 -0
- package/dist/style-axes-DSQ2DGc5.d.ts +133 -0
- package/dist/toast/index.d.ts +6 -0
- package/dist/toast/index.js +2 -0
- package/dist/tooltip-C0bYa8a3.d.ts +37 -0
- package/dist/{types-DtUxK-Am.d.ts → types-CkXflqg7.d.ts} +31 -1
- package/dist/utils/cn.js +6 -1
- package/dist/utils/color.js +35 -10
- package/dist/utils/index.d.ts +18 -2
- package/dist/utils/index.js +4 -1
- package/dist/utils/silver-shine.js +16 -1
- package/dist/utils/style-axes.js +227 -0
- package/dist/utils/variant.js +104 -8
- package/dist/utils/view-transition.js +21 -0
- package/dist/variant-D81RhpbR.d.ts +104 -0
- package/dist/vertical-stepper.props-BXYcbW70.d.ts +29 -0
- package/package.json +52 -6
- package/src/styles/colors.css +100 -4
- package/src/styles/globals.css +8 -131
- package/src/styles/style-axes.css +21 -0
- package/src/styles/theme.css +696 -0
- package/dist/app-logo.props-Ct7QBdTd.d.ts +0 -40
- package/dist/popover-ByLD3-Qv.d.ts +0 -204
|
@@ -1,17 +1,79 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
import { cn } from "../../../../utils/cn.js";
|
|
3
|
+
import { useStyleAxes } from "../../../../utils/style-axes.js";
|
|
3
4
|
import { CodeBlock } from "../../primitives/animate/code-block.js";
|
|
4
5
|
import { CodeHeader } from "./code-header.js";
|
|
5
6
|
import * as React$1 from "react";
|
|
6
7
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
7
8
|
//#region src/core/animate-ui/components/animate/code.tsx
|
|
8
|
-
|
|
9
|
+
/** Where each marked line sits in the block, measured from its `data-line` element whenever the block's lines change. */
|
|
10
|
+
function useLinePlaces(blockRef, lines) {
|
|
11
|
+
const [places, setPlaces] = React$1.useState({});
|
|
12
|
+
React$1.useLayoutEffect(() => {
|
|
13
|
+
const block = blockRef.current;
|
|
14
|
+
if (!block || !lines) {
|
|
15
|
+
setPlaces({});
|
|
16
|
+
return;
|
|
17
|
+
}
|
|
18
|
+
const measure = () => {
|
|
19
|
+
const next = {};
|
|
20
|
+
for (const line of lines.split(",")) {
|
|
21
|
+
const el = block.querySelector(`[data-line="${line}"]`);
|
|
22
|
+
if (el) next[Number(line)] = {
|
|
23
|
+
top: el.offsetTop,
|
|
24
|
+
height: el.offsetHeight
|
|
25
|
+
};
|
|
26
|
+
}
|
|
27
|
+
setPlaces((prev) => JSON.stringify(prev) === JSON.stringify(next) ? prev : next);
|
|
28
|
+
};
|
|
29
|
+
measure();
|
|
30
|
+
const mutations = new MutationObserver(measure);
|
|
31
|
+
mutations.observe(block, {
|
|
32
|
+
childList: true,
|
|
33
|
+
subtree: true
|
|
34
|
+
});
|
|
35
|
+
const resize = typeof ResizeObserver === "undefined" ? null : new ResizeObserver(measure);
|
|
36
|
+
resize?.observe(block);
|
|
37
|
+
return () => {
|
|
38
|
+
mutations.disconnect();
|
|
39
|
+
resize?.disconnect();
|
|
40
|
+
};
|
|
41
|
+
}, [blockRef, lines]);
|
|
42
|
+
return places;
|
|
43
|
+
}
|
|
44
|
+
/** The marks layer: each mark on its line's row, in the left padding. */
|
|
45
|
+
function LineMarks({ blockRef, marks }) {
|
|
46
|
+
const places = useLinePlaces(blockRef, Object.keys(marks).join(","));
|
|
47
|
+
return /* @__PURE__ */ jsx("div", {
|
|
48
|
+
"data-slot": "code-line-marks",
|
|
49
|
+
className: "pointer-events-none absolute top-0 left-0",
|
|
50
|
+
children: Object.entries(marks).map(([line, mark]) => {
|
|
51
|
+
const place = places[Number(line)];
|
|
52
|
+
return place ? /* @__PURE__ */ jsx("div", {
|
|
53
|
+
"data-line-mark": line,
|
|
54
|
+
className: "pointer-events-auto absolute left-0.5 flex w-3.5 items-center justify-center",
|
|
55
|
+
style: {
|
|
56
|
+
top: place.top,
|
|
57
|
+
height: place.height
|
|
58
|
+
},
|
|
59
|
+
children: mark
|
|
60
|
+
}, line) : null;
|
|
61
|
+
})
|
|
62
|
+
});
|
|
63
|
+
}
|
|
64
|
+
function Code({ className, code, icon: Icon, theme = "light", themes, copyButton, lang, fileName, height, style, radius, border, lineNumbers, highlightLines, lineIdPrefix, maxHighlightLength, lineMarks, ...props }) {
|
|
65
|
+
const { partStyle } = useStyleAxes({
|
|
66
|
+
radius,
|
|
67
|
+
border
|
|
68
|
+
}, ["radius", "border"]);
|
|
9
69
|
const showCopyButton = copyButton !== false && (copyButton === true || copyButton === void 0 && Boolean(lang));
|
|
10
70
|
const showHeader = fileName !== void 0 || showCopyButton;
|
|
11
71
|
const scrollRef = React$1.useRef(null);
|
|
72
|
+
const blockRef = React$1.useRef(null);
|
|
12
73
|
return /* @__PURE__ */ jsxs("div", {
|
|
13
|
-
className: cn("relative flex flex-col overflow-hidden border bg-background rounded-lg", className),
|
|
74
|
+
className: cn("relative flex flex-col overflow-hidden border-[length:var(--espd-own-border-width,var(--espd-border-width-surface,1px))] bg-background rounded-[var(--espd-own-radius,var(--espd-radius-surface,var(--radius-lg)))]", className),
|
|
14
75
|
style: {
|
|
76
|
+
...partStyle,
|
|
15
77
|
height,
|
|
16
78
|
...style
|
|
17
79
|
},
|
|
@@ -20,14 +82,26 @@ function Code({ className, code, icon: Icon, theme = "light", themes, copyButton
|
|
|
20
82
|
icon: Icon,
|
|
21
83
|
fileName,
|
|
22
84
|
copyContent: showCopyButton ? code : void 0
|
|
23
|
-
}), lang && /* @__PURE__ */
|
|
85
|
+
}), lang && /* @__PURE__ */ jsxs("div", {
|
|
24
86
|
ref: scrollRef,
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
87
|
+
"data-slot": "code-scroll",
|
|
88
|
+
className: "relative flex-1 min-h-0 overflow-auto bg-accent/10",
|
|
89
|
+
children: [/* @__PURE__ */ jsx(CodeBlock, {
|
|
90
|
+
ref: blockRef,
|
|
91
|
+
theme,
|
|
92
|
+
themes,
|
|
93
|
+
scrollContainerRef: scrollRef,
|
|
94
|
+
className: cn("relative text-sm p-4", "[&>pre,_&_code]:!bg-transparent [&>pre,_&_code]:[background:transparent_!important] [&>pre,_&_code]:border-none [&_code]:!text-[13px] [&_code_.line]:!px-0", "[&_code_.line]:inline-block [&_code_.line]:min-w-full [&_code_.line.highlighted]:bg-primary/12", "data-[line-numbers]:[&_code]:[counter-reset:line] data-[line-numbers]:[&_code_.line]:before:[counter-increment:line] data-[line-numbers]:[&_code_.line]:before:content-[counter(line)] data-[line-numbers]:[&_code_.line]:before:inline-block data-[line-numbers]:[&_code_.line]:before:w-[4ch] data-[line-numbers]:[&_code_.line]:before:mr-4 data-[line-numbers]:[&_code_.line]:before:text-right data-[line-numbers]:[&_code_.line]:before:text-muted-foreground/60 data-[line-numbers]:[&_code_.line]:before:select-none"),
|
|
95
|
+
code,
|
|
96
|
+
lang,
|
|
97
|
+
lineNumbers,
|
|
98
|
+
highlightLines,
|
|
99
|
+
lineIdPrefix,
|
|
100
|
+
maxHighlightLength
|
|
101
|
+
}), lineMarks && Object.keys(lineMarks).length > 0 && /* @__PURE__ */ jsx(LineMarks, {
|
|
102
|
+
blockRef,
|
|
103
|
+
marks: lineMarks
|
|
104
|
+
})]
|
|
31
105
|
})]
|
|
32
106
|
});
|
|
33
107
|
}
|
|
@@ -1,18 +1,35 @@
|
|
|
1
1
|
import { cn } from "../../../../utils/cn.js";
|
|
2
|
+
import { contrastingForeground, isPresetColor } from "../../../../utils/color.js";
|
|
3
|
+
import { useControlledState } from "../../../hooks/use-controlled-state.js";
|
|
2
4
|
import { useScrollOverflow } from "../../../hooks/use-scroll-overflow.js";
|
|
3
5
|
import { Tabs as Tabs$1, TabsContent as TabsContent$1, TabsContents as TabsContents$1, TabsHighlight, TabsHighlightItem, TabsList as TabsList$1, TabsTrigger as TabsTrigger$1, useTabs } from "../../primitives/animate/tabs.js";
|
|
4
6
|
import * as React$1 from "react";
|
|
5
|
-
import { jsx, jsxs } from "react/jsx-runtime";
|
|
7
|
+
import { Fragment as Fragment$1, jsx, jsxs } from "react/jsx-runtime";
|
|
8
|
+
import { motion, useReducedMotion } from "motion/react";
|
|
6
9
|
import { ChevronLeft, ChevronRight } from "lucide-react";
|
|
7
10
|
//#region src/core/animate-ui/components/animate/tabs.tsx
|
|
8
|
-
var
|
|
11
|
+
var TabsListContext = React$1.createContext({
|
|
12
|
+
variant: void 0,
|
|
13
|
+
size: "default",
|
|
14
|
+
collapsible: false,
|
|
15
|
+
collapsed: false,
|
|
16
|
+
toggleCollapsed: () => {}
|
|
17
|
+
});
|
|
18
|
+
/**
|
|
19
|
+
* Every variant paints from `--espd-tabs-color` (the list's `color`, primary
|
|
20
|
+
* by default), so one prop tints them all: the pill's 10% wash, the list's
|
|
21
|
+
* 30% border, the glow's 45% halo — the same mixes the `/10` `/30` `/45`
|
|
22
|
+
* utilities make — and the selected label.
|
|
23
|
+
*/
|
|
24
|
+
var TINT = "bg-[color:color-mix(in_oklab,var(--espd-tabs-color)_10%,transparent)]";
|
|
25
|
+
var TINT_BORDER = "border-[color:color-mix(in_oklab,var(--espd-tabs-color)_30%,transparent)]";
|
|
9
26
|
var TABS_LIST_VARIANTS = {
|
|
10
27
|
default: {
|
|
11
28
|
highlight: {
|
|
12
29
|
mode: "parent",
|
|
13
|
-
className:
|
|
30
|
+
className: `absolute z-0 inset-0 rounded-[var(--espd-own-radius,var(--espd-radius-item,var(--radius-md)))] ${TINT}`
|
|
14
31
|
},
|
|
15
|
-
list:
|
|
32
|
+
list: `bg-transparent text-muted-foreground inline-flex h-auto w-fit items-center justify-center rounded-md p-1 border ${TINT_BORDER}`
|
|
16
33
|
},
|
|
17
34
|
line: {
|
|
18
35
|
highlight: {
|
|
@@ -20,18 +37,80 @@ var TABS_LIST_VARIANTS = {
|
|
|
20
37
|
variant: "line",
|
|
21
38
|
lineHeight: 2,
|
|
22
39
|
boundsOffset: { top: 2 },
|
|
23
|
-
className: "absolute z-0 bg-
|
|
40
|
+
className: "absolute z-0 bg-[color:var(--espd-tabs-color)] rounded-none"
|
|
24
41
|
},
|
|
25
42
|
list: "text-muted-foreground inline-flex h-auto w-fit items-center justify-center gap-1 border-b border-border"
|
|
26
43
|
},
|
|
27
44
|
rounded: {
|
|
28
45
|
highlight: {
|
|
29
46
|
mode: "parent",
|
|
30
|
-
className:
|
|
47
|
+
className: `absolute z-0 inset-0 rounded-full ${TINT}`
|
|
48
|
+
},
|
|
49
|
+
list: `bg-transparent text-muted-foreground inline-flex h-auto w-fit items-center justify-center rounded-full p-1 border ${TINT_BORDER}`
|
|
50
|
+
},
|
|
51
|
+
/** `rounded` with the halo the other components' `glow` variant uses. */
|
|
52
|
+
glow: {
|
|
53
|
+
highlight: {
|
|
54
|
+
mode: "parent",
|
|
55
|
+
className: `absolute z-0 inset-0 rounded-full ${TINT}`
|
|
31
56
|
},
|
|
32
|
-
list:
|
|
57
|
+
list: `bg-transparent text-muted-foreground inline-flex h-auto w-fit items-center justify-center rounded-full p-1 border ${TINT_BORDER} shadow-glow shadow-[color:color-mix(in_oklab,var(--espd-tabs-color)_45%,transparent)]`
|
|
58
|
+
},
|
|
59
|
+
/**
|
|
60
|
+
* The selected tab is a solid pill in the list's `color`; the text on it
|
|
61
|
+
* takes a colour that reads against the fill. The list itself stays quiet:
|
|
62
|
+
* a hairline, no tint.
|
|
63
|
+
*/
|
|
64
|
+
solid: {
|
|
65
|
+
highlight: {
|
|
66
|
+
mode: "parent",
|
|
67
|
+
className: "absolute z-0 inset-0 rounded-full bg-[color:var(--espd-tabs-color)] shadow-sm"
|
|
68
|
+
},
|
|
69
|
+
list: "bg-transparent text-muted-foreground inline-flex h-auto w-fit items-center justify-center rounded-full p-1 border border-border"
|
|
33
70
|
}
|
|
34
71
|
};
|
|
72
|
+
/**
|
|
73
|
+
* `sm`: the list's padding and its triggers shrink to a 28px strip, for a
|
|
74
|
+
* toolbar. `lg`: 36px triggers with base text and 20px icons, for a page's
|
|
75
|
+
* main switch; the rounded list grows by as much as `sm` shrinks it.
|
|
76
|
+
*/
|
|
77
|
+
var TABS_LIST_SIZE = {
|
|
78
|
+
default: {
|
|
79
|
+
list: "",
|
|
80
|
+
trigger: "",
|
|
81
|
+
lineTrigger: ""
|
|
82
|
+
},
|
|
83
|
+
sm: {
|
|
84
|
+
list: "p-0.5",
|
|
85
|
+
trigger: "h-6 px-2.5 py-0 text-xs",
|
|
86
|
+
lineTrigger: "py-1.5 text-xs"
|
|
87
|
+
},
|
|
88
|
+
lg: {
|
|
89
|
+
list: "",
|
|
90
|
+
trigger: "h-9 px-4 py-0 gap-2 text-base [&_svg:not([class*='size-'])]:size-5",
|
|
91
|
+
lineTrigger: "py-3 gap-2 text-base [&_svg:not([class*='size-'])]:size-5"
|
|
92
|
+
}
|
|
93
|
+
};
|
|
94
|
+
/** The CSS variables a list sets from its `color`: the colour, and (for `solid`) the text that reads on a fill of it. */
|
|
95
|
+
function colorVars(color) {
|
|
96
|
+
if (isPresetColor(color)) return {
|
|
97
|
+
"--espd-tabs-color": `var(--color-${color})`,
|
|
98
|
+
"--espd-tabs-color-foreground": `var(--color-${color}-foreground)`
|
|
99
|
+
};
|
|
100
|
+
return {
|
|
101
|
+
"--espd-tabs-color": color,
|
|
102
|
+
"--espd-tabs-color-foreground": contrastingForeground(color)
|
|
103
|
+
};
|
|
104
|
+
}
|
|
105
|
+
/**
|
|
106
|
+
* Room the scroller keeps around the list so its `glow` halo (it reaches
|
|
107
|
+
* ~10px past the border) is not clipped; the fade mask's box grows by the
|
|
108
|
+
* same amount.
|
|
109
|
+
*/
|
|
110
|
+
var GLOW_GUTTER = {
|
|
111
|
+
mask: "-m-3",
|
|
112
|
+
scroller: "p-3"
|
|
113
|
+
};
|
|
35
114
|
/** Width of the edge fade, and the margin kept beside the active tab when it is scrolled into view. */
|
|
36
115
|
var EDGE_SIZE = 40;
|
|
37
116
|
function prefersReducedMotion() {
|
|
@@ -98,28 +177,36 @@ function fadeMask(start, end) {
|
|
|
98
177
|
};
|
|
99
178
|
}
|
|
100
179
|
var scrollButtonClass = "absolute top-1/2 z-10 -translate-y-1/2 inline-flex size-7 items-center justify-center rounded-full border border-border bg-background text-muted-foreground shadow-sm transition-colors hover:text-foreground [@media(pointer:coarse)]:hidden";
|
|
101
|
-
function TabsListContent({ variant, fullWidth, className, ...props }) {
|
|
180
|
+
function TabsListContent({ variant, size, color, fullWidth, className, collapsible: _collapsible, collapsed: _collapsed, defaultCollapsed: _defaultCollapsed, onCollapsedChange: _onCollapsedChange, ...props }) {
|
|
102
181
|
const config = TABS_LIST_VARIANTS[variant];
|
|
182
|
+
const vars = colorVars(color);
|
|
103
183
|
const scrollerRef = React$1.useRef(null);
|
|
104
184
|
const scrollable = props["aria-orientation"] !== "vertical";
|
|
105
185
|
const { overflow, scrollByPage } = useTabsOverflow(scrollerRef, scrollable);
|
|
186
|
+
const isGlow = variant === "glow";
|
|
106
187
|
const list = /* @__PURE__ */ jsx(TabsHighlight, {
|
|
107
188
|
ref: scrollerRef,
|
|
108
|
-
containerClassName: scrollable ? "flex
|
|
189
|
+
containerClassName: scrollable ? cn("flex overflow-x-auto overscroll-x-contain [scrollbar-width:none] [&::-webkit-scrollbar]:hidden", isGlow ? GLOW_GUTTER.scroller : "-my-1 py-1") : void 0,
|
|
109
190
|
...config.highlight,
|
|
110
191
|
children: /* @__PURE__ */ jsx(TabsList$1, {
|
|
111
|
-
className: cn(config.list, scrollable && "shrink-0 min-w-fit", scrollable && fullWidth && "max-md:w-full", className),
|
|
192
|
+
className: cn(config.list, TABS_LIST_SIZE[size].list, scrollable && "shrink-0 min-w-fit", scrollable && fullWidth && "max-md:w-full", className),
|
|
112
193
|
...props
|
|
113
194
|
})
|
|
114
195
|
});
|
|
115
|
-
if (!scrollable) return
|
|
196
|
+
if (!scrollable) return /* @__PURE__ */ jsx("div", {
|
|
197
|
+
className: "contents",
|
|
198
|
+
style: vars,
|
|
199
|
+
children: list
|
|
200
|
+
});
|
|
116
201
|
return /* @__PURE__ */ jsxs("div", {
|
|
117
202
|
"data-slot": "tabs-list-scroller",
|
|
118
203
|
"data-overflow-start": overflow.start || void 0,
|
|
119
204
|
"data-overflow-end": overflow.end || void 0,
|
|
120
205
|
className: cn("relative min-w-0 max-w-full", fullWidth && "max-md:w-full"),
|
|
206
|
+
style: vars,
|
|
121
207
|
children: [
|
|
122
208
|
/* @__PURE__ */ jsx("div", {
|
|
209
|
+
className: isGlow ? GLOW_GUTTER.mask : void 0,
|
|
123
210
|
style: fadeMask(overflow.start, overflow.end),
|
|
124
211
|
children: list
|
|
125
212
|
}),
|
|
@@ -153,25 +240,153 @@ function Tabs({ className, ...props }) {
|
|
|
153
240
|
* hidden tabs, chevron buttons page through them on pointer devices, and the
|
|
154
241
|
* active tab is kept in view. Pass `aria-orientation="vertical"` for a stacked list.
|
|
155
242
|
*/
|
|
156
|
-
function TabsList({ variant, fullWidth = true, ...props }) {
|
|
157
|
-
|
|
158
|
-
value:
|
|
243
|
+
function TabsList({ variant, size = "default", color = "primary", fullWidth = true, collapsible = false, collapsed: collapsedProp, defaultCollapsed = false, onCollapsedChange, ...props }) {
|
|
244
|
+
const [collapsed, setCollapsed] = useControlledState({
|
|
245
|
+
value: collapsedProp,
|
|
246
|
+
defaultValue: defaultCollapsed,
|
|
247
|
+
onChange: onCollapsedChange
|
|
248
|
+
});
|
|
249
|
+
const context = React$1.useMemo(() => ({
|
|
250
|
+
variant,
|
|
251
|
+
size,
|
|
252
|
+
collapsible,
|
|
253
|
+
collapsed,
|
|
254
|
+
toggleCollapsed: () => setCollapsed(!collapsed)
|
|
255
|
+
}), [
|
|
256
|
+
variant,
|
|
257
|
+
size,
|
|
258
|
+
collapsible,
|
|
259
|
+
collapsed,
|
|
260
|
+
setCollapsed
|
|
261
|
+
]);
|
|
262
|
+
return /* @__PURE__ */ jsx(TabsListContext.Provider, {
|
|
263
|
+
value: context,
|
|
159
264
|
children: /* @__PURE__ */ jsx(TabsListContent, {
|
|
160
265
|
variant: variant ?? "default",
|
|
266
|
+
size,
|
|
267
|
+
color,
|
|
161
268
|
fullWidth,
|
|
269
|
+
"data-collapsed": collapsed || void 0,
|
|
162
270
|
...props
|
|
163
271
|
})
|
|
164
272
|
});
|
|
165
273
|
}
|
|
166
|
-
var tabsTriggerBaseClass = "data-[state=active]:text-
|
|
167
|
-
|
|
168
|
-
|
|
274
|
+
var tabsTriggerBaseClass = "data-[state=active]:text-[color:var(--espd-tabs-color)] tracking-wide focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:outline-ring inline-flex flex-1 items-center justify-center gap-1.5 rounded-[var(--espd-own-radius,var(--espd-radius-item,var(--radius-md)))] w-full px-2 text-sm font-medium whitespace-nowrap transition-colors duration-500 ease-in-out focus-visible:ring-[3px] focus-visible:outline-1 disabled:pointer-events-none disabled:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4";
|
|
275
|
+
/**
|
|
276
|
+
* The selected label in the list's colour, its lightness held where text
|
|
277
|
+
* reads (4.5:1 on the 10% pill, with room for an off-white page): at most
|
|
278
|
+
* L 40 on a light page, at least L 62 on a dark one. Hue and chroma stay, and
|
|
279
|
+
* a colour already in range is unchanged. Without relative colour syntax, the
|
|
280
|
+
* colour as given. Not for `solid`, whose label sits on the fill.
|
|
281
|
+
*/
|
|
282
|
+
var readableLabelClass = "supports-[color:lch(from_red_l_c_h)]:data-[state=active]:text-[color:lch(from_var(--espd-tabs-color)_min(l,40)_c_h)] dark:supports-[color:lch(from_red_l_c_h)]:data-[state=active]:text-[color:lch(from_var(--espd-tabs-color)_max(l,62)_c_h)]";
|
|
283
|
+
/** The label squeezes shut with a little overshoot; the fade is quicker than the squeeze. */
|
|
284
|
+
var LABEL_SPRING = {
|
|
285
|
+
type: "spring",
|
|
286
|
+
stiffness: 420,
|
|
287
|
+
damping: 26,
|
|
288
|
+
opacity: { duration: .18 },
|
|
289
|
+
filter: { duration: .22 }
|
|
290
|
+
};
|
|
291
|
+
var ICON_WIGGLE = {
|
|
292
|
+
duration: .5,
|
|
293
|
+
ease: "easeOut"
|
|
294
|
+
};
|
|
295
|
+
var INSTANT = { duration: 0 };
|
|
296
|
+
/** Gap between icon and label while the label shows (the trigger's own gap is off, so the icon centres when folded). */
|
|
297
|
+
var LABEL_GAP = 6;
|
|
298
|
+
/**
|
|
299
|
+
* The icon, then the label. Folding squeezes the label to nothing (width, fade
|
|
300
|
+
* and a touch of blur, on a spring) while the icon gives a small wiggle; the
|
|
301
|
+
* label stays in the DOM, so it is still the tab's accessible name.
|
|
302
|
+
* Nothing moves on first render or under reduced motion.
|
|
303
|
+
*/
|
|
304
|
+
function TriggerContent({ icon, label, iconOnly }) {
|
|
305
|
+
const reduceMotion = useReducedMotion();
|
|
306
|
+
return /* @__PURE__ */ jsxs(Fragment$1, { children: [/* @__PURE__ */ jsx(motion.span, {
|
|
307
|
+
"data-slot": "tabs-trigger-icon",
|
|
308
|
+
"aria-hidden": true,
|
|
309
|
+
className: "inline-flex",
|
|
310
|
+
initial: false,
|
|
311
|
+
animate: iconOnly ? {
|
|
312
|
+
rotate: [
|
|
313
|
+
0,
|
|
314
|
+
-16,
|
|
315
|
+
10,
|
|
316
|
+
0
|
|
317
|
+
],
|
|
318
|
+
scale: [
|
|
319
|
+
1,
|
|
320
|
+
1.25,
|
|
321
|
+
.92,
|
|
322
|
+
1
|
|
323
|
+
]
|
|
324
|
+
} : {
|
|
325
|
+
rotate: [
|
|
326
|
+
0,
|
|
327
|
+
16,
|
|
328
|
+
-10,
|
|
329
|
+
0
|
|
330
|
+
],
|
|
331
|
+
scale: [
|
|
332
|
+
1,
|
|
333
|
+
1.2,
|
|
334
|
+
.95,
|
|
335
|
+
1
|
|
336
|
+
]
|
|
337
|
+
},
|
|
338
|
+
transition: reduceMotion ? INSTANT : ICON_WIGGLE,
|
|
339
|
+
children: icon
|
|
340
|
+
}), /* @__PURE__ */ jsx(motion.span, {
|
|
341
|
+
"data-slot": "tabs-trigger-label",
|
|
342
|
+
"data-hidden": iconOnly || void 0,
|
|
343
|
+
className: "inline-flex items-center overflow-hidden whitespace-nowrap",
|
|
344
|
+
initial: false,
|
|
345
|
+
animate: iconOnly ? {
|
|
346
|
+
width: 0,
|
|
347
|
+
opacity: 0,
|
|
348
|
+
marginLeft: 0,
|
|
349
|
+
filter: "blur(4px)"
|
|
350
|
+
} : {
|
|
351
|
+
width: "auto",
|
|
352
|
+
opacity: 1,
|
|
353
|
+
marginLeft: LABEL_GAP,
|
|
354
|
+
filter: "blur(0px)"
|
|
355
|
+
},
|
|
356
|
+
transition: reduceMotion ? INSTANT : LABEL_SPRING,
|
|
357
|
+
children: label
|
|
358
|
+
})] });
|
|
359
|
+
}
|
|
360
|
+
function triggerContent(icon, label, iconOnly) {
|
|
361
|
+
if (!icon) return label;
|
|
362
|
+
return /* @__PURE__ */ jsx(TriggerContent, {
|
|
363
|
+
icon,
|
|
364
|
+
label,
|
|
365
|
+
iconOnly
|
|
366
|
+
});
|
|
367
|
+
}
|
|
368
|
+
function TabsTrigger({ className, icon, onClick, ...props }) {
|
|
369
|
+
const list = React$1.useContext(TabsListContext);
|
|
370
|
+
const { activeValue } = useTabs();
|
|
371
|
+
const isLine = list.variant === "line";
|
|
372
|
+
const isSolid = list.variant === "solid";
|
|
373
|
+
const sizing = TABS_LIST_SIZE[list.size];
|
|
374
|
+
const iconOnly = Boolean(icon) && list.collapsed;
|
|
375
|
+
const handleClick = (event) => {
|
|
376
|
+
onClick?.(event);
|
|
377
|
+
if (icon && list.collapsible && activeValue === props.value) list.toggleCollapsed();
|
|
378
|
+
};
|
|
379
|
+
const child = props.children;
|
|
380
|
+
const children = props.asChild && React$1.isValidElement(child) ? React$1.cloneElement(child, void 0, triggerContent(icon, child.props.children, iconOnly)) : triggerContent(icon, child, iconOnly);
|
|
169
381
|
return /* @__PURE__ */ jsx(TabsHighlightItem, {
|
|
170
382
|
value: props.value,
|
|
171
383
|
className: "flex-1",
|
|
172
384
|
children: /* @__PURE__ */ jsx(TabsTrigger$1, {
|
|
173
|
-
className: cn(tabsTriggerBaseClass, isLine ? "text-muted-foreground py-2.5" : "text-muted-foreground h-[calc(100%-1px)] py-1", className),
|
|
174
|
-
|
|
385
|
+
className: cn(tabsTriggerBaseClass, isLine ? "text-muted-foreground py-2.5" : "text-muted-foreground h-[calc(100%-1px)] py-1", isLine ? sizing.lineTrigger : sizing.trigger, isSolid ? "data-[state=active]:text-[color:var(--espd-tabs-color-foreground)]" : readableLabelClass, icon && "gap-0", className),
|
|
386
|
+
"data-icon-only": iconOnly || void 0,
|
|
387
|
+
...props,
|
|
388
|
+
onClick: handleClick,
|
|
389
|
+
children
|
|
175
390
|
})
|
|
176
391
|
});
|
|
177
392
|
}
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { cn } from "../../../../utils/cn.js";
|
|
2
|
+
import { useStyleAxes } from "../../../../utils/style-axes.js";
|
|
2
3
|
import { Tooltip as Tooltip$1, TooltipArrow, TooltipContent as TooltipContent$1, TooltipProvider as TooltipProvider$1, TooltipTrigger as TooltipTrigger$1 } from "../../primitives/animate/tooltip.js";
|
|
3
4
|
import "react";
|
|
4
5
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
@@ -19,9 +20,16 @@ function Tooltip({ sideOffset = 10, ...props }) {
|
|
|
19
20
|
function TooltipTrigger({ ...props }) {
|
|
20
21
|
return /* @__PURE__ */ jsx(TooltipTrigger$1, { ...props });
|
|
21
22
|
}
|
|
22
|
-
function TooltipContent({ className, children, layout = "preserve-aspect", ...props }) {
|
|
23
|
+
function TooltipContent({ className, children, layout = "preserve-aspect", radius, elevation, style, ...props }) {
|
|
24
|
+
const { style: axisStyle } = useStyleAxes({
|
|
25
|
+
radius,
|
|
26
|
+
elevation,
|
|
27
|
+
style
|
|
28
|
+
}, ["radius", "elevation"]);
|
|
23
29
|
return /* @__PURE__ */ jsxs(TooltipContent$1, {
|
|
24
|
-
className: cn("z-50 w-fit bg-tooltip text-tooltip-foreground rounded-md", className),
|
|
30
|
+
className: cn("z-50 w-fit bg-tooltip text-tooltip-foreground rounded-[var(--espd-own-radius,var(--espd-radius-overlay,var(--radius-md)))]", "shadow-[shadow:var(--espd-own-elevation,0_0_#0000)]", className),
|
|
31
|
+
style: axisStyle,
|
|
32
|
+
...typeof children === "string" || typeof children === "number" ? { "data-text": String(children) } : {},
|
|
25
33
|
...props,
|
|
26
34
|
children: [/* @__PURE__ */ jsx(motion.div, {
|
|
27
35
|
className: "overflow-hidden px-3 py-1.5 text-xs text-balance",
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { cn } from "../../../../utils/cn.js";
|
|
2
|
+
import { useStyleAxes } from "../../../../utils/style-axes.js";
|
|
2
3
|
import { PreviewCard as PreviewCard$1, PreviewCardBackdrop as PreviewCardBackdrop$1, PreviewCardPopup, PreviewCardPortal, PreviewCardPositioner, PreviewCardTrigger as PreviewCardTrigger$1 } from "../../primitives/base/preview-card.js";
|
|
3
4
|
import "react";
|
|
4
5
|
import { jsx } from "react/jsx-runtime";
|
|
@@ -9,15 +10,31 @@ function PreviewCard(props) {
|
|
|
9
10
|
function PreviewCardTrigger(props) {
|
|
10
11
|
return /* @__PURE__ */ jsx(PreviewCardTrigger$1, { ...props });
|
|
11
12
|
}
|
|
12
|
-
|
|
13
|
+
/** Puts the style-axis variables first; `style` may also be Base UI's function of state. */
|
|
14
|
+
function withAxisStyle(partStyle, style) {
|
|
15
|
+
if (!partStyle) return style;
|
|
16
|
+
const s = style;
|
|
17
|
+
return typeof s === "function" ? (state) => ({
|
|
18
|
+
...partStyle,
|
|
19
|
+
...s(state)
|
|
20
|
+
}) : {
|
|
21
|
+
...partStyle,
|
|
22
|
+
...s
|
|
23
|
+
};
|
|
24
|
+
}
|
|
25
|
+
function PreviewCardPanel({ className, align = "center", sideOffset = 4, style, children, radius, elevation, ...props }) {
|
|
26
|
+
const { partStyle } = useStyleAxes({
|
|
27
|
+
radius,
|
|
28
|
+
elevation
|
|
29
|
+
}, ["radius", "elevation"]);
|
|
13
30
|
return /* @__PURE__ */ jsx(PreviewCardPortal, { children: /* @__PURE__ */ jsx(PreviewCardPositioner, {
|
|
14
31
|
align,
|
|
15
32
|
sideOffset,
|
|
16
33
|
className: "z-50",
|
|
17
34
|
...props,
|
|
18
35
|
children: /* @__PURE__ */ jsx(PreviewCardPopup, {
|
|
19
|
-
className: cn("bg-popover text-popover-foreground w-64 origin-(--transform-origin) rounded-md border p-4 shadow-md outline-hidden", className),
|
|
20
|
-
style,
|
|
36
|
+
className: cn("bg-popover text-popover-foreground w-64 origin-(--transform-origin) rounded-[var(--espd-own-radius,var(--espd-radius-overlay,var(--radius-md)))] border p-4 shadow-[shadow:var(--espd-own-elevation,var(--espd-elevation-overlay,var(--shadow-md)))] outline-hidden", className),
|
|
37
|
+
style: withAxisStyle(partStyle, style),
|
|
21
38
|
children
|
|
22
39
|
})
|
|
23
40
|
}) });
|
|
@@ -1,19 +1,20 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
import { cn } from "../../../../utils/cn.js";
|
|
3
|
+
import { useStyleAxes } from "../../../../utils/style-axes.js";
|
|
3
4
|
import { useControlledState } from "../../../hooks/use-controlled-state.js";
|
|
4
5
|
import { Button } from "../../primitives/buttons/button.js";
|
|
5
6
|
import * as React$1 from "react";
|
|
6
7
|
import { jsx } from "react/jsx-runtime";
|
|
7
|
-
import { CheckIcon, CopyIcon } from "lucide-react";
|
|
8
8
|
import { AnimatePresence, motion } from "motion/react";
|
|
9
|
+
import { CheckIcon, CopyIcon } from "lucide-react";
|
|
9
10
|
import { cva } from "class-variance-authority";
|
|
10
11
|
//#region src/core/animate-ui/components/buttons/copy.tsx
|
|
11
|
-
var buttonVariants = cva("flex items-center justify-center rounded-md transition-[box-shadow,_color,_background-color,_border-color,_outline-color,_text-decoration-color,_fill,_stroke] disabled:pointer-events-none disabled:opacity-50 [&_svg]:pointer-events-none [&_svg:not([class*='size-'])]:size-4 shrink-0 [&_svg]:shrink-0 outline-none focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:ring-[3px] aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive", {
|
|
12
|
+
var buttonVariants = cva("flex items-center justify-center rounded-[var(--espd-own-radius,var(--espd-radius-control,var(--radius-md)))] transition-[box-shadow,_color,_background-color,_border-color,_outline-color,_text-decoration-color,_fill,_stroke] disabled:pointer-events-none disabled:opacity-50 [&_svg]:pointer-events-none [&_svg:not([class*='size-'])]:size-4 shrink-0 [&_svg]:shrink-0 outline-none focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:ring-[3px] aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive", {
|
|
12
13
|
variants: {
|
|
13
14
|
variant: {
|
|
14
15
|
default: "bg-primary text-primary-foreground shadow-xs hover:bg-primary/90",
|
|
15
16
|
accent: "bg-accent text-accent-foreground shadow-xs hover:bg-accent/90",
|
|
16
|
-
destructive: "bg-destructive text-
|
|
17
|
+
destructive: "bg-destructive text-[color:var(--espd-on-solid-foreground,#fff)] shadow-xs hover:bg-destructive/90 focus-visible:ring-destructive/20 dark:focus-visible:ring-destructive/40 dark:bg-destructive/60",
|
|
17
18
|
outline: "border bg-background shadow-xs hover:bg-accent hover:text-accent-foreground dark:bg-input/30 dark:border-input dark:hover:bg-input/50",
|
|
18
19
|
secondary: "bg-secondary text-secondary-foreground shadow-xs hover:bg-secondary/80",
|
|
19
20
|
ghost: "hover:bg-accent hover:text-accent-foreground dark:hover:bg-accent/50",
|
|
@@ -21,8 +22,8 @@ var buttonVariants = cva("flex items-center justify-center rounded-md transition
|
|
|
21
22
|
},
|
|
22
23
|
size: {
|
|
23
24
|
default: "size-9",
|
|
24
|
-
sm: "size-8 rounded-md",
|
|
25
|
-
lg: "size-10 rounded-md"
|
|
25
|
+
sm: "size-8 rounded-[var(--espd-own-radius,var(--espd-radius-control,var(--radius-md)))]",
|
|
26
|
+
lg: "size-10 rounded-[var(--espd-own-radius,var(--espd-radius-control,var(--radius-md)))]"
|
|
26
27
|
}
|
|
27
28
|
},
|
|
28
29
|
defaultVariants: {
|
|
@@ -30,7 +31,8 @@ var buttonVariants = cva("flex items-center justify-center rounded-md transition
|
|
|
30
31
|
size: "default"
|
|
31
32
|
}
|
|
32
33
|
});
|
|
33
|
-
function CopyButton({ className, content, copied, onCopiedChange, onClick, variant, size, delay = 3e3, ...props }) {
|
|
34
|
+
function CopyButton({ className, content, copied, onCopiedChange, onClick, variant, size, delay = 3e3, radius, style, ...props }) {
|
|
35
|
+
const { partStyle } = useStyleAxes({ radius }, ["radius"]);
|
|
34
36
|
const [isCopied, setIsCopied] = useControlledState({
|
|
35
37
|
value: copied,
|
|
36
38
|
onChange: onCopiedChange
|
|
@@ -65,6 +67,10 @@ function CopyButton({ className, content, copied, onCopiedChange, onClick, varia
|
|
|
65
67
|
className
|
|
66
68
|
})),
|
|
67
69
|
onClick: handleCopy,
|
|
70
|
+
style: partStyle ? {
|
|
71
|
+
...partStyle,
|
|
72
|
+
...style
|
|
73
|
+
} : style,
|
|
68
74
|
...props,
|
|
69
75
|
children: /* @__PURE__ */ jsx(AnimatePresence, {
|
|
70
76
|
mode: "popLayout",
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { cn } from "../../../../utils/cn.js";
|
|
2
|
+
import { densityStyle, useStyleAxes } from "../../../../utils/style-axes.js";
|
|
2
3
|
import { Dialog as Dialog$1, DialogClose as DialogClose$1, DialogContent as DialogContent$1, DialogDescription as DialogDescription$1, DialogFooter as DialogFooter$1, DialogHeader as DialogHeader$1, DialogOverlay as DialogOverlay$1, DialogPortal, DialogTitle as DialogTitle$1, DialogTrigger as DialogTrigger$1 } from "../../primitives/radix/dialog.js";
|
|
3
4
|
import "react";
|
|
4
5
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
@@ -15,13 +16,26 @@ function DialogClose(props) {
|
|
|
15
16
|
}
|
|
16
17
|
function DialogOverlay({ className, ...props }) {
|
|
17
18
|
return /* @__PURE__ */ jsx(DialogOverlay$1, {
|
|
18
|
-
className: cn("fixed inset-0 z-50 bg-
|
|
19
|
+
className: cn("fixed inset-0 z-50 bg-[var(--espd-overlay-scrim,rgb(0_0_0/0.5))] backdrop-blur-[var(--espd-overlay-blur,0px)]", className),
|
|
19
20
|
...props
|
|
20
21
|
});
|
|
21
22
|
}
|
|
22
|
-
function DialogContent({ className, children, showCloseButton = true, closeButtonClassName, ...props }) {
|
|
23
|
+
function DialogContent({ className, children, showCloseButton = true, closeButtonClassName, radius, elevation, density, style, ...props }) {
|
|
24
|
+
const axes = useStyleAxes({
|
|
25
|
+
radius,
|
|
26
|
+
elevation
|
|
27
|
+
}, ["radius", "elevation"]);
|
|
28
|
+
const density_ = densityStyle(density);
|
|
29
|
+
const partStyle = axes.partStyle || density_ ? {
|
|
30
|
+
...density_,
|
|
31
|
+
...axes.partStyle
|
|
32
|
+
} : void 0;
|
|
23
33
|
return /* @__PURE__ */ jsxs(DialogPortal, { children: [/* @__PURE__ */ jsx(DialogOverlay, {}), /* @__PURE__ */ jsxs(DialogContent$1, {
|
|
24
|
-
className: cn("bg-background fixed top-[50%] left-[50%] z-50 grid w-full max-w-[calc(100%-2rem)] translate-x-[-50%] translate-y-[-50%] gap-4 rounded-lg border p-6 shadow-lg sm:max-w-lg", className),
|
|
34
|
+
className: cn("bg-background fixed top-[50%] left-[50%] z-50 grid w-full max-w-[calc(100%-2rem)] translate-x-[-50%] translate-y-[-50%] gap-[var(--espd-gap-stack,calc(var(--spacing)*4))] rounded-[var(--espd-own-radius,var(--espd-radius-overlay,var(--radius-lg)))] border p-6 shadow-[shadow:var(--espd-own-elevation,var(--espd-elevation-overlay,var(--shadow-lg)))] sm:max-w-lg", className),
|
|
35
|
+
style: partStyle ? {
|
|
36
|
+
...partStyle,
|
|
37
|
+
...style
|
|
38
|
+
} : style,
|
|
25
39
|
...props,
|
|
26
40
|
children: [children, showCloseButton && /* @__PURE__ */ jsxs(DialogClose$1, {
|
|
27
41
|
className: cn("ring-offset-background focus:ring-ring data-[state=open]:bg-accent data-[state=open]:text-muted-foreground absolute top-4 right-4 z-50 rounded-xs opacity-70 transition-opacity hover:opacity-100 focus:ring-2 focus:ring-offset-2 focus:outline-hidden disabled:pointer-events-none [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4", closeButtonClassName),
|