@cueplusplus/ui 0.16.0 → 0.18.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/CHANGELOG.md +901 -0
- package/README.md +1 -1
- package/dist/agent-runtime/tool-call-card.js +7 -3
- package/dist/brand/_chassis.d.ts +1 -1
- package/dist/brand/cue-mark.d.ts +1 -1
- package/dist/brand/cue-mark.js +1 -1
- package/dist/charts/ramps.js +1 -1
- package/dist/chat/agent-pile.js +2 -1
- package/dist/chat/ask-box.js +4 -3
- package/dist/chat/delegation-card.js +3 -2
- package/dist/chat/message-list.js +3 -2
- package/dist/chat/message.js +17 -7
- package/dist/chrome/_edge-scroller.js +2 -1
- package/dist/chrome/_status-bar.js +9 -3
- package/dist/chrome/_tabs-scroll.d.ts +1 -1
- package/dist/chrome/_tabs-scroll.js +1 -1
- package/dist/chrome/app-bar.js +9 -3
- package/dist/chrome/app-shell.js +2 -1
- package/dist/chrome/band.d.ts +18 -12
- package/dist/chrome/band.js +18 -32
- package/dist/chrome/empty-state.js +8 -4
- package/dist/chrome/eyebrow.d.ts +13 -5
- package/dist/chrome/eyebrow.js +18 -7
- package/dist/chrome/footer.d.ts +5 -0
- package/dist/chrome/footer.js +14 -3
- package/dist/chrome/navigation-menu.js +6 -3
- package/dist/chrome/page-shell.js +8 -5
- package/dist/chrome/panel.d.ts +5 -2
- package/dist/chrome/panel.js +10 -5
- package/dist/chrome/row.js +9 -5
- package/dist/chrome/scroll-area.js +6 -4
- package/dist/chrome/section-header.js +13 -4
- package/dist/chrome/segmented-control.js +14 -4
- package/dist/chrome/status-bar.js +2 -1
- package/dist/chrome/tabs.js +14 -3
- package/dist/chrome/toolbar.js +6 -3
- package/dist/chrome/tree.js +3 -2
- package/dist/color/_thumb.js +9 -3
- package/dist/color/color-area.js +1 -1
- package/dist/color/color-swatch.js +1 -1
- package/dist/configurator/_overrides.js +13 -4
- package/dist/configurator/configurator.js +4 -1
- package/dist/configurator/export-dialog.js +5 -2
- package/dist/configurator/panel-sections.js +6 -2
- package/dist/configurator/token-editor.js +4 -1
- package/dist/date/_trigger.js +4 -1
- package/dist/date/calendar.js +22 -12
- package/dist/dmx/channel-matrix.js +3 -2
- package/dist/dmx/dmx-bar.js +1 -1
- package/dist/dmx/dmx-strip.js +1 -1
- package/dist/dmx/universe-grid.js +3 -2
- package/dist/elements/activity-graph.js +3 -3
- package/dist/elements/agent-card.js +3 -3
- package/dist/elements/approval-card.js +3 -3
- package/dist/elements/artifact-card.js +2 -2
- package/dist/elements/background-inbox.js +2 -2
- package/dist/elements/canvas-split.js +2 -2
- package/dist/elements/chart.js +1 -1
- package/dist/elements/chat-panel.js +2 -2
- package/dist/elements/checkpoint-history.js +2 -2
- package/dist/elements/clamp.js +2 -1
- package/dist/elements/code-diff.js +1 -1
- package/dist/elements/code-runner.js +1 -1
- package/dist/elements/command-palette.js +6 -5
- package/dist/elements/comparison-card.js +2 -2
- package/dist/elements/composer.js +9 -8
- package/dist/elements/computer-use.js +1 -1
- package/dist/elements/confidence-marker.js +2 -1
- package/dist/elements/connection-state.js +1 -1
- package/dist/elements/context-breakdown.js +1 -1
- package/dist/elements/context-usage.js +1 -1
- package/dist/elements/conversation-search.js +4 -3
- package/dist/elements/cost-meter.js +1 -1
- package/dist/elements/data-table.js +2 -2
- package/dist/elements/day-separator.js +1 -1
- package/dist/elements/diagram.js +1 -1
- package/dist/elements/document-reference.js +3 -3
- package/dist/elements/draft-restore.js +1 -1
- package/dist/elements/edit-message.js +4 -3
- package/dist/elements/elements.css +26 -5
- package/dist/elements/elicitation-form.js +3 -3
- package/dist/elements/empty-state.js +2 -1
- package/dist/elements/error-state.js +1 -1
- package/dist/elements/feedback-dialog.js +4 -3
- package/dist/elements/file-tree.js +2 -2
- package/dist/elements/flow-graph.js +2 -2
- package/dist/elements/guardrail-notice.js +3 -3
- package/dist/elements/image-generation.js +1 -1
- package/dist/elements/inline-citation.js +3 -3
- package/dist/elements/job-progress.js +3 -3
- package/dist/elements/launcher-bubble.js +2 -2
- package/dist/elements/loading-state.js +1 -1
- package/dist/elements/map-answer.js +3 -2
- package/dist/elements/markdown.js +5 -4
- package/dist/elements/math-block.js +1 -1
- package/dist/elements/mcp-server-panel.js +3 -3
- package/dist/elements/message-attachment.js +4 -4
- package/dist/elements/message-pair.js +1 -1
- package/dist/elements/message-queue.js +2 -2
- package/dist/elements/mobile-composer.js +4 -3
- package/dist/elements/model-picker.js +3 -3
- package/dist/elements/onboarding.js +2 -2
- package/dist/elements/permission-grant.js +2 -2
- package/dist/elements/permission-scopes.js +5 -4
- package/dist/elements/prompt-library.js +7 -6
- package/dist/elements/queue-dock.js +4 -3
- package/dist/elements/quota-banner.js +1 -1
- package/dist/elements/quote-reply.js +1 -1
- package/dist/elements/read-aloud.js +2 -2
- package/dist/elements/reasoning-panel.js +2 -1
- package/dist/elements/recommendation-card.d.ts +1 -1
- package/dist/elements/recommendation-card.js +2 -2
- package/dist/elements/regenerate-menu.js +2 -2
- package/dist/elements/research-report.js +1 -1
- package/dist/elements/retrieval-chunks.js +1 -1
- package/dist/elements/revert-dock.js +5 -4
- package/dist/elements/reviewable-diff.js +1 -1
- package/dist/elements/schedule-card.js +3 -3
- package/dist/elements/score-breakdown.js +1 -1
- package/dist/elements/scroll-anchor.js +2 -2
- package/dist/elements/settings-panel.js +3 -2
- package/dist/elements/shared-conversation.js +2 -2
- package/dist/elements/sources.js +4 -3
- package/dist/elements/speaker-identity.js +1 -1
- package/dist/elements/spec-sheet.js +1 -1
- package/dist/elements/streaming-text.js +1 -1
- package/dist/elements/subagent-list.js +2 -2
- package/dist/elements/suggestions.js +1 -1
- package/dist/elements/surfaces.d.ts +1 -1
- package/dist/elements/surfaces.js +2 -1
- package/dist/elements/tail-status.js +1 -1
- package/dist/elements/terminal-block.js +1 -1
- package/dist/elements/thread-list.js +1 -1
- package/dist/elements/thread-search.js +5 -4
- package/dist/elements/timeline.js +1 -1
- package/dist/elements/todo-list.js +2 -2
- package/dist/elements/tool-call.js +4 -3
- package/dist/elements/tool-error.js +2 -2
- package/dist/elements/tool-group.js +1 -1
- package/dist/elements/tool-timeline.js +4 -3
- package/dist/elements/trace-waterfall.js +1 -1
- package/dist/elements/verdict-row.js +2 -2
- package/dist/elements/voice-conversation.js +3 -2
- package/dist/elements/web-preview.js +1 -1
- package/dist/elements/web-search.js +2 -2
- package/dist/elements/work-collapse.js +2 -1
- package/dist/flow/node-card.js +3 -2
- package/dist/flow/use-flow-theme.js +2 -1
- package/dist/forms/_chassis.d.ts +34 -6
- package/dist/forms/_chassis.js +44 -9
- package/dist/forms/_listbox.js +22 -14
- package/dist/forms/checkbox.js +13 -4
- package/dist/forms/env-var-input.js +3 -2
- package/dist/forms/field.d.ts +2 -1
- package/dist/forms/field.js +16 -5
- package/dist/forms/file-upload.js +3 -2
- package/dist/forms/input-group.js +11 -2
- package/dist/forms/multi-select.js +4 -3
- package/dist/forms/number-field.js +7 -3
- package/dist/forms/otp-field.js +15 -6
- package/dist/forms/password-input.js +4 -2
- package/dist/forms/radio-group.js +10 -4
- package/dist/forms/rating.js +2 -1
- package/dist/forms/scrub-input.js +2 -1
- package/dist/forms/search-input.js +2 -1
- package/dist/forms/select.js +10 -4
- package/dist/forms/slider.js +9 -3
- package/dist/forms/switch.js +9 -3
- package/dist/forms/tags-input.js +4 -3
- package/dist/forms/textarea.js +3 -1
- package/dist/forms/toggle-group.js +2 -1
- package/dist/forms/toggle.js +5 -1
- package/dist/index.d.ts +2 -2
- package/dist/index.js +2 -2
- package/dist/instruments/_data-row.js +2 -1
- package/dist/instruments/app-window-frame.js +1 -1
- package/dist/instruments/code-block.js +8 -2
- package/dist/instruments/group-bar.js +1 -1
- package/dist/instruments/ledger.js +6 -2
- package/dist/instruments/log-viewer.js +4 -3
- package/dist/instruments/meter.js +2 -1
- package/dist/instruments/progress.js +9 -3
- package/dist/instruments/seam-grid.js +5 -3
- package/dist/instruments/stat.js +13 -4
- package/dist/instruments/table.js +29 -10
- package/dist/instruments/terminal-frame.js +4 -2
- package/dist/instruments/usage-chart.js +1 -1
- package/dist/layout/_collapse.js +26 -5
- package/dist/layout/accordion.js +2 -1
- package/dist/layout/bento.js +7 -4
- package/dist/layout/breadcrumb.js +10 -5
- package/dist/layout/card.js +14 -7
- package/dist/layout/carousel.js +3 -2
- package/dist/layout/collapsible.js +6 -1
- package/dist/layout/container.js +2 -1
- package/dist/layout/description-list.js +4 -1
- package/dist/layout/frames.js +11 -5
- package/dist/layout/item.js +3 -2
- package/dist/layout/link.d.ts +30 -0
- package/dist/layout/link.js +22 -3
- package/dist/layout/pagination.js +8 -8
- package/dist/layout/preview.d.ts +32 -12
- package/dist/layout/preview.js +149 -40
- package/dist/layout/resizable.js +2 -1
- package/dist/layout/sidebar.js +11 -3
- package/dist/layout/stepper.js +6 -2
- package/dist/lib/cn.js +29 -2
- package/dist/midi/piano-keyboard.js +3 -2
- package/dist/midi/spectrum-visualizer.js +1 -1
- package/dist/midi/threshold-rail.js +2 -1
- package/dist/midi/timeline-ruler.js +1 -1
- package/dist/overlays/_surface.d.ts +74 -14
- package/dist/overlays/_surface.js +87 -14
- package/dist/overlays/alert-dialog.js +1 -1
- package/dist/overlays/command-palette.js +28 -9
- package/dist/overlays/dialog.d.ts +5 -0
- package/dist/overlays/dialog.js +6 -1
- package/dist/overlays/drawer.js +8 -1
- package/dist/overlays/hover-card.js +3 -1
- package/dist/overlays/info-tip.js +2 -1
- package/dist/overlays/menubar.js +3 -1
- package/dist/overlays/popover.js +3 -1
- package/dist/overlays/toast.js +14 -6
- package/dist/overlays/tooltip.js +3 -1
- package/dist/primitives/avatar.js +6 -2
- package/dist/primitives/button.d.ts +16 -1
- package/dist/primitives/button.js +44 -12
- package/dist/primitives/chip.d.ts +11 -29
- package/dist/primitives/chip.js +40 -50
- package/dist/primitives/icon-button.d.ts +1 -1
- package/dist/primitives/kbd.d.ts +6 -0
- package/dist/primitives/kbd.js +10 -1
- package/dist/primitives/skeleton.js +2 -1
- package/dist/system/_focus-ring-field.js +29 -0
- package/dist/system/_focus-ring.js +125 -0
- package/dist/system/_paint-glow.js +22 -3
- package/dist/system/_paint-rest-shade.js +32 -0
- package/dist/system/_paint-rim.js +22 -4
- package/dist/system/_paint-stroke-surface-1.js +1 -1
- package/dist/system/_paint-stroke-surface-2.js +14 -1
- package/dist/system/_paint-texture.js +5 -2
- package/dist/system/_style-accordion-rule.js +32 -0
- package/dist/system/_style-app-bar.js +65 -0
- package/dist/system/_style-avatar.js +20 -0
- package/dist/system/_style-band.js +57 -0
- package/dist/system/_style-body-leading.js +19 -0
- package/dist/system/_style-body-size.js +30 -0
- package/dist/system/_style-body-weight.js +24 -0
- package/dist/system/_style-body.js +32 -0
- package/dist/system/_style-caption-ink.js +17 -0
- package/dist/system/_style-caption-size.js +19 -0
- package/dist/system/_style-caption-weight.js +18 -0
- package/dist/system/_style-caption.js +19 -0
- package/dist/system/_style-card-gap.js +14 -0
- package/dist/system/_style-card-pad.js +43 -0
- package/dist/system/_style-cell.js +18 -0
- package/dist/system/_style-check-glyph.js +14 -0
- package/dist/system/_style-check.js +40 -0
- package/dist/system/_style-chip.js +143 -0
- package/dist/system/_style-choice-gap.js +15 -0
- package/dist/system/_style-code.js +13 -0
- package/dist/system/_style-collapse.js +94 -0
- package/dist/system/_style-control-face.js +29 -0
- package/dist/system/_style-control-gap.js +14 -0
- package/dist/system/_style-control-label.js +29 -0
- package/dist/system/_style-control-step.js +22 -0
- package/dist/system/_style-control.js +76 -0
- package/dist/system/_style-crumb.js +44 -0
- package/dist/system/_style-data-face.js +28 -0
- package/dist/system/_style-day.js +25 -0
- package/dist/system/_style-description.js +23 -0
- package/dist/system/_style-disabled.js +70 -0
- package/dist/system/_style-disclosure.js +21 -0
- package/dist/system/_style-empty-state.js +42 -0
- package/dist/system/_style-eyebrow.js +43 -0
- package/dist/system/_style-field-chassis.js +38 -0
- package/dist/system/_style-field-gap.js +12 -0
- package/dist/system/_style-footer-rule.js +47 -0
- package/dist/system/_style-glyph-ink.js +20 -0
- package/dist/system/_style-glyph-opacity.js +20 -0
- package/dist/system/_style-glyph-size.js +21 -0
- package/dist/system/_style-group-gap.js +15 -0
- package/dist/system/_style-group-label-pad.js +14 -0
- package/dist/system/_style-group-label.js +24 -0
- package/dist/system/_style-gutter.js +17 -0
- package/dist/system/_style-help-ink.js +14 -0
- package/dist/system/_style-help.js +38 -0
- package/dist/system/_style-hover-card-width.js +15 -0
- package/dist/system/_style-input-face.js +34 -0
- package/dist/system/_style-kbd.js +58 -0
- package/dist/system/_style-label-case.js +36 -0
- package/dist/system/_style-label-face.js +32 -0
- package/dist/system/_style-label-ink.js +29 -0
- package/dist/system/_style-label-leading.js +14 -0
- package/dist/system/_style-label-size.js +36 -0
- package/dist/system/_style-label-tracking.js +45 -0
- package/dist/system/_style-label-weight.js +40 -0
- package/dist/system/_style-lede.js +49 -0
- package/dist/system/_style-link.js +58 -0
- package/dist/system/_style-menu.js +43 -0
- package/dist/system/_style-meter.js +15 -0
- package/dist/system/_style-nav-item.js +41 -0
- package/dist/system/_style-nav-menu.js +48 -0
- package/dist/system/_style-nav-voice.js +43 -0
- package/dist/system/_style-option.js +99 -0
- package/dist/system/_style-otp.js +15 -0
- package/dist/system/_style-outline-hover.js +18 -0
- package/dist/system/_style-overlay-title.js +35 -0
- package/dist/system/_style-page-title.js +48 -0
- package/dist/system/_style-page.js +17 -0
- package/dist/system/_style-palette.js +18 -0
- package/dist/system/_style-panel.js +21 -0
- package/dist/system/_style-popover-pad.js +13 -0
- package/dist/system/_style-popover-width.js +15 -0
- package/dist/system/_style-quiet-ink.js +13 -0
- package/dist/system/_style-radio.js +19 -0
- package/dist/system/_style-row-disabled.js +17 -0
- package/dist/system/_style-row-pad.js +13 -0
- package/dist/system/_style-row.js +30 -0
- package/dist/system/_style-scrollbar.js +19 -0
- package/dist/system/_style-seam.js +43 -0
- package/dist/system/_style-section-rule.js +26 -0
- package/dist/system/_style-segment-pad.js +15 -0
- package/dist/system/_style-segment.js +30 -0
- package/dist/system/_style-segmented-control.js +86 -0
- package/dist/system/_style-selected.js +36 -0
- package/dist/system/_style-skeleton.js +15 -0
- package/dist/system/_style-slider.js +26 -0
- package/dist/system/_style-stage-marks.js +26 -0
- package/dist/system/_style-stat.js +31 -0
- package/dist/system/_style-stepper.js +16 -0
- package/dist/system/_style-switch.js +26 -0
- package/dist/system/_style-tab-hover.js +15 -0
- package/dist/system/_style-tab.js +71 -0
- package/dist/system/_style-text-focus.js +26 -0
- package/dist/system/_style-textarea.js +21 -0
- package/dist/system/_style-title.js +37 -0
- package/dist/system/_style-toast.js +22 -0
- package/dist/system/_style-toggle.js +50 -0
- package/dist/system/_style-toolbar.js +23 -0
- package/dist/system/_style-tooltip.js +46 -0
- package/dist/system/density.d.ts +15 -5
- package/dist/system/density.js +188 -25
- package/dist/system/index.d.ts +2 -2
- package/dist/system/index.js +2 -2
- package/dist/system/overrides.d.ts +1 -0
- package/dist/system/overrides.js +151 -3
- package/dist/system/portal.d.ts +3 -2
- package/dist/system/portal.js +22 -10
- package/dist/system/prepaint.d.ts +21 -5
- package/dist/system/prepaint.js +3 -1
- package/dist/system/published.d.ts +1 -0
- package/dist/system/published.js +131 -0
- package/dist/system/theme-provider.d.ts +118 -21
- package/dist/system/theme-provider.js +362 -73
- package/dist/system/theme-registry.d.ts +2 -1
- package/dist/system/theme-registry.js +27 -10
- package/dist/system/use-density.js +4 -3
- package/dist/system/use-theme.d.ts +5 -2
- package/dist/system/use-theme.js +7 -4
- package/dist/system/vocabulary.js +2 -2
- package/dist/theming/create-theme.js +12 -6
- package/dist/theming/serialize.d.ts +34 -2
- package/dist/theming/serialize.js +86 -4
- package/manifest/components/accordion.json +29 -2
- package/manifest/components/agent-pile.json +3 -0
- package/manifest/components/alert-dialog.json +36 -3
- package/manifest/components/app-bar.json +61 -2
- package/manifest/components/app-shell.json +5 -0
- package/manifest/components/ask-box.json +3 -1
- package/manifest/components/autocomplete.json +85 -1
- package/manifest/components/avatar-group.json +7 -0
- package/manifest/components/avatar.json +7 -0
- package/manifest/components/band.json +7 -3
- package/manifest/components/bento.json +12 -1
- package/manifest/components/breadcrumb.json +12 -0
- package/manifest/components/button.json +43 -4
- package/manifest/components/calendar.json +13 -0
- package/manifest/components/card.json +23 -1
- package/manifest/components/carousel.json +4 -1
- package/manifest/components/channel-matrix.json +37 -3
- package/manifest/components/chart-tooltip-content.json +35 -3
- package/manifest/components/chat-empty-state.json +3 -1
- package/manifest/components/checkbox-group.json +36 -1
- package/manifest/components/checkbox.json +36 -1
- package/manifest/components/chip.json +22 -1
- package/manifest/components/clamp.json +3 -1
- package/manifest/components/code-block.json +10 -1
- package/manifest/components/collapsible.json +35 -2
- package/manifest/components/color-area.json +4 -2
- package/manifest/components/color-field.json +29 -0
- package/manifest/components/color-picker.json +29 -0
- package/manifest/components/color-slider.json +3 -1
- package/manifest/components/colors-section.json +9 -1
- package/manifest/components/combobox.json +85 -1
- package/manifest/components/command-palette.json +39 -3
- package/manifest/components/composer-actions.json +3 -0
- package/manifest/components/composer-attach-button.json +3 -0
- package/manifest/components/composer-attachment-chip.json +3 -0
- package/manifest/components/composer-attachments.json +3 -0
- package/manifest/components/composer-bar.json +3 -0
- package/manifest/components/composer-command-item.json +3 -0
- package/manifest/components/composer-context.json +3 -0
- package/manifest/components/composer-input.json +3 -0
- package/manifest/components/composer-menu-item.json +3 -0
- package/manifest/components/composer-menu.json +3 -0
- package/manifest/components/composer-model-item.json +3 -0
- package/manifest/components/composer-model-trigger.json +3 -0
- package/manifest/components/composer-person-item.json +3 -0
- package/manifest/components/composer-send.json +3 -0
- package/manifest/components/composer-toolbar.json +3 -0
- package/manifest/components/composer-voice-button.json +3 -0
- package/manifest/components/composer-voice.json +3 -0
- package/manifest/components/composer.json +29 -0
- package/manifest/components/confidence-marker.json +3 -1
- package/manifest/components/container.json +2 -1
- package/manifest/components/context-menu.json +35 -3
- package/manifest/components/conversation-search.json +3 -1
- package/manifest/components/cue-mark.json +2 -2
- package/manifest/components/cue-portal-frame.json +1 -1
- package/manifest/components/data-row.json +3 -1
- package/manifest/components/data-tree.json +3 -1
- package/manifest/components/date-field.json +28 -0
- package/manifest/components/date-picker.json +32 -0
- package/manifest/components/date-range-picker.json +32 -0
- package/manifest/components/delegation-card.json +3 -1
- package/manifest/components/density.json +15 -7
- package/manifest/components/description-list.json +6 -1
- package/manifest/components/dialog.json +37 -3
- package/manifest/components/disclosure.json +35 -2
- package/manifest/components/dmx-bar.json +34 -3
- package/manifest/components/dmx-strip.json +34 -3
- package/manifest/components/drawer.json +36 -3
- package/manifest/components/dropdown-menu.json +35 -3
- package/manifest/components/edit-message.json +3 -1
- package/manifest/components/elements-command-palette.json +3 -1
- package/manifest/components/elements-composer.json +3 -0
- package/manifest/components/empty-state-composer.json +3 -1
- package/manifest/components/empty-state-greeting.json +3 -1
- package/manifest/components/empty-state-suggestion.json +3 -1
- package/manifest/components/empty-state-suggestions.json +3 -1
- package/manifest/components/empty-state.json +13 -0
- package/manifest/components/env-var-input.json +28 -0
- package/manifest/components/export-dialog.json +6 -1
- package/manifest/components/eyebrow.json +13 -2
- package/manifest/components/feedback-dialog.json +3 -0
- package/manifest/components/field-description.json +15 -0
- package/manifest/components/field-error.json +15 -0
- package/manifest/components/field-label.json +16 -1
- package/manifest/components/field.json +15 -0
- package/manifest/components/file-upload.json +3 -0
- package/manifest/components/footer.json +14 -1
- package/manifest/components/frames.json +14 -1
- package/manifest/components/hover-card.json +37 -3
- package/manifest/components/info-tip.json +3 -0
- package/manifest/components/input-group.json +31 -0
- package/manifest/components/input.json +29 -0
- package/manifest/components/item.json +3 -1
- package/manifest/components/kbd.json +12 -1
- package/manifest/components/ledger.json +9 -2
- package/manifest/components/link.json +33 -0
- package/manifest/components/log-viewer.json +3 -0
- package/manifest/components/map-answer.json +3 -1
- package/manifest/components/markdown-text.json +3 -0
- package/manifest/components/menubar.json +38 -4
- package/manifest/components/message-list.json +3 -0
- package/manifest/components/message.json +6 -1
- package/manifest/components/meter.json +1 -0
- package/manifest/components/mobile-composer.json +3 -1
- package/manifest/components/multi-select.json +86 -1
- package/manifest/components/musical-time-input.json +29 -0
- package/manifest/components/navigation-menu.json +48 -3
- package/manifest/components/node-card.json +3 -0
- package/manifest/components/number-field.json +30 -0
- package/manifest/components/otp-field.json +29 -0
- package/manifest/components/page-shell.json +14 -0
- package/manifest/components/pagination.json +22 -0
- package/manifest/components/panel-header.json +13 -0
- package/manifest/components/panel.json +14 -1
- package/manifest/components/password-input.json +28 -0
- package/manifest/components/permission-scopes.json +3 -1
- package/manifest/components/piano-keyboard.json +3 -0
- package/manifest/components/popover.json +37 -3
- package/manifest/components/preset-section.json +9 -1
- package/manifest/components/preview.json +24 -10
- package/manifest/components/progress.json +10 -1
- package/manifest/components/prompt-library.json +3 -1
- package/manifest/components/queue-dock.json +3 -1
- package/manifest/components/radio-group.json +14 -0
- package/manifest/components/radio.json +14 -0
- package/manifest/components/rating.json +4 -1
- package/manifest/components/reasoning-panel.json +3 -1
- package/manifest/components/recommendation-card.json +1 -1
- package/manifest/components/resizable.json +4 -1
- package/manifest/components/revert-dock.json +3 -1
- package/manifest/components/row.json +8 -1
- package/manifest/components/scroll-area.json +6 -2
- package/manifest/components/scrollable-tabs-list.json +21 -0
- package/manifest/components/scrub-input.json +28 -0
- package/manifest/components/seam-cell.json +1 -0
- package/manifest/components/seam-grid.json +1 -0
- package/manifest/components/seam-list.json +8 -1
- package/manifest/components/search-input.json +28 -0
- package/manifest/components/section-header.json +15 -2
- package/manifest/components/segmented-control.json +17 -0
- package/manifest/components/select.json +42 -0
- package/manifest/components/settings-panel.json +3 -0
- package/manifest/components/shape-section.json +9 -1
- package/manifest/components/sheet.json +35 -3
- package/manifest/components/shimmer-label.json +3 -0
- package/manifest/components/sidebar.json +19 -2
- package/manifest/components/skeleton.json +2 -0
- package/manifest/components/slider.json +16 -0
- package/manifest/components/sources.json +3 -1
- package/manifest/components/stat.json +17 -0
- package/manifest/components/status-bar.json +4 -0
- package/manifest/components/stepper.json +8 -0
- package/manifest/components/swap-label.json +3 -0
- package/manifest/components/switch.json +30 -0
- package/manifest/components/table-scroll-region.json +22 -2
- package/manifest/components/table.json +22 -2
- package/manifest/components/tabs.json +22 -1
- package/manifest/components/tags-input.json +86 -1
- package/manifest/components/terminal-frame.json +3 -0
- package/manifest/components/textarea.json +31 -0
- package/manifest/components/theme-configurator.json +35 -3
- package/manifest/components/theme-provider.json +31 -19
- package/manifest/components/thread-search.json +3 -1
- package/manifest/components/threshold-rail.json +3 -0
- package/manifest/components/time-field.json +28 -0
- package/manifest/components/toast.json +39 -2
- package/manifest/components/toggle-group.json +2 -1
- package/manifest/components/toggle.json +32 -0
- package/manifest/components/token-editor.json +6 -1
- package/manifest/components/tool-call-card.json +9 -2
- package/manifest/components/tool-call.json +3 -1
- package/manifest/components/tool-timeline.json +3 -1
- package/manifest/components/toolbar.json +22 -1
- package/manifest/components/tooltip.json +42 -3
- package/manifest/components/tree-visibility-toggle.json +3 -0
- package/manifest/components/tree.json +3 -0
- package/manifest/components/universe-grid.json +3 -0
- package/manifest/components/voice-conversation.json +3 -0
- package/manifest/components/work-collapse.json +3 -1
- package/manifest/fixtures.json +15 -0
- package/manifest/manifest.json +210 -190
- package/manifest/tokens.json +395 -4
- package/package.json +6 -6
|
@@ -18,12 +18,64 @@
|
|
|
18
18
|
* @example
|
|
19
19
|
* <Popover.Popup className={cn(overlaySurfaceClasses, className)} />
|
|
20
20
|
*/
|
|
21
|
-
declare const overlaySurfaceClasses = "rounded-
|
|
21
|
+
declare const overlaySurfaceClasses = "rounded-overlay border-transparent border-(length:--cue-paint-stroke-width) bg-[linear-gradient(var(--cue-style-overlay-ground,var(--cue-surface-2)),var(--cue-style-overlay-ground,var(--cue-surface-2))),linear-gradient(var(--cue-paint-stroke-angle),var(--cue-paint-stroke-overlay-from,var(--cue-border-overlay)),var(--cue-paint-stroke-overlay-to,var(--cue-border-overlay)))] bg-origin-border [background-clip:padding-box,border-box] shadow-[0_0_0_var(--cue-paint-rim-width)_var(--cue-paint-shade-hairline,transparent),0_calc(2px*var(--cue-paint-shadow-scale))_calc(6px*var(--cue-paint-shadow-scale))_var(--cue-paint-shadow-spread)_var(--cue-paint-shade-near,transparent),0_calc(8px*var(--cue-paint-shadow-scale))_calc(24px*var(--cue-paint-shadow-scale))_var(--cue-paint-shadow-spread)_var(--cue-paint-shade-far,rgba(0,0,0,0.4)),inset_0_1px_0_0_var(--cue-paint-sheen-ink,transparent)]";
|
|
22
22
|
/**
|
|
23
23
|
* The full-viewport dim behind a modal surface. `--cue-scrim` is theme-owned —
|
|
24
24
|
* dusk and hivehub tune their own — so the value is never hard-coded here.
|
|
25
|
+
*
|
|
26
|
+
* **The scrim's own filter (spec §3.10, P0.6) lives on a `::before`
|
|
27
|
+
* pseudo-element, never on `backdrop-filter` of the scrim itself.** Every
|
|
28
|
+
* element here is public through `backdropClassName` (dialog, sheet, drawer,
|
|
29
|
+
* alert-dialog and command-palette all feed it into
|
|
30
|
+
* `cn(scrimClasses, backdropClassName)`), which exists precisely so a consumer
|
|
31
|
+
* can put their own `backdrop-blur-*` on this element — so the scrim's own
|
|
32
|
+
* `backdrop-filter` is a slot this recipe must never write to at all, not a
|
|
33
|
+
* slot to compose into.
|
|
34
|
+
*
|
|
35
|
+
* **Why not fill one of Tailwind's own composition slots instead (the
|
|
36
|
+
* `_paint-glass.ts` technique).** Measured, and it does not survive
|
|
37
|
+
* `paint-scrim-filter: none`, which is every shipped pack's value but
|
|
38
|
+
* glaze's (`blur(8px)`, the Porcelain Look's dialog backdrop).
|
|
39
|
+
* Tailwind's composed `backdrop-filter: var(--tw-backdrop-blur,)
|
|
40
|
+
* var(--tw-backdrop-brightness,) … var(--tw-backdrop-grayscale,) …` accepts
|
|
41
|
+
* only `<filter-function>`s in that list; `none` is not one, so a slot filled
|
|
42
|
+
* with the literal text `none` sitting beside a consumer's `blur(8px)` is an
|
|
43
|
+
* **invalid** `backdrop-filter` value as a whole — not "no extra blur" but a
|
|
44
|
+
* parse failure that drops the entire declaration, computing `none` even for
|
|
45
|
+
* the consumer's own choice. `_paint-glass.ts` never meets this: its slot's
|
|
46
|
+
* default is a real filter function (`blur(8px)`), never the keyword `none`.
|
|
47
|
+
*
|
|
48
|
+
* **The pseudo-element has no such slot to collide over.** Its own
|
|
49
|
+
* `backdrop-filter: var(--cue-paint-scrim-filter, none)` is the only
|
|
50
|
+
* declaration for that property on that box, so `none` is simply valid and
|
|
51
|
+
* inert there, exactly as intended, whatever the scrim element's own
|
|
52
|
+
* `backdrop-filter` (via `backdropClassName`) computes. `content-['']` gives
|
|
53
|
+
* it a box; `absolute inset-0` sizes it to the scrim, whose own `fixed`
|
|
54
|
+
* positioning is a containing block for it; `pointer-events-none` keeps it out
|
|
55
|
+
* of the scrim's own click handling. The pseudo paints after the scrim's own
|
|
56
|
+
* `bg-(--cue-scrim)`, so a real filter blurs that tint together with the page
|
|
57
|
+
* — a flat tint, so the blur of it is the same tint.
|
|
58
|
+
*
|
|
59
|
+
* **The scrim never fades by its own opacity, because that would isolate the
|
|
60
|
+
* pseudo's backdrop.** An ancestor with opacity under 1 is a backdrop root: a
|
|
61
|
+
* descendant's `backdrop-filter` sees only what is painted inside it. When the
|
|
62
|
+
* scrim faded in by `opacity`, glaze's blur on the pseudo therefore had
|
|
63
|
+
* nothing to blur for the whole fade — the page stayed sharp while it dimmed,
|
|
64
|
+
* snapped to 8px the frame opacity reached 1, and lost the blur on the first
|
|
65
|
+
* frame of the exit (measured in Chromium; `paint-noop.spec.ts`'s P43 case
|
|
66
|
+
* reads the pixels halfway through). So the scrim holds opacity 1 and fades
|
|
67
|
+
* its parts: its background from `transparent`, the pseudo by its *own*
|
|
68
|
+
* opacity (an element's own opacity does not isolate its own backdrop), and
|
|
69
|
+
* its own `backdrop-filter` from `none` — the last only so a consumer's
|
|
70
|
+
* `backdrop-blur-*`, which faded with the scrim's opacity before, still fades
|
|
71
|
+
* rather than snapping in. That one is written for the starting and ending
|
|
72
|
+
* frames alone, where a whole-property `none` outranks the consumer's
|
|
73
|
+
* composed declaration without entering it; at rest the property is theirs.
|
|
74
|
+
* The pseudo's `transition` and timing are its own classes: Tailwind
|
|
75
|
+
* registers `--tw-duration` and `--tw-ease` with `inherits: false`, so the
|
|
76
|
+
* scrim's `duration-150 ease-out` never reach it.
|
|
25
77
|
*/
|
|
26
|
-
declare const scrimClasses = "fixed inset-0 z-50 bg-(--cue-scrim) transition-opacity duration-150 ease-out motion-reduce:transition-none data-[starting-style]:opacity-0 data-[ending-style]:opacity-0";
|
|
78
|
+
declare const scrimClasses = "fixed inset-0 z-50 bg-(--cue-scrim) before:absolute before:inset-0 before:content-[''] before:pointer-events-none before:[backdrop-filter:var(--cue-paint-scrim-filter,none)] transition-[background-color,backdrop-filter] duration-150 ease-out before:transition-opacity before:duration-150 before:ease-out motion-reduce:transition-none motion-reduce:before:transition-none data-[starting-style]:bg-transparent data-[ending-style]:bg-transparent data-[starting-style]:[backdrop-filter:none] data-[ending-style]:[backdrop-filter:none] data-[starting-style]:before:opacity-0 data-[ending-style]:before:opacity-0";
|
|
27
79
|
/**
|
|
28
80
|
* What a Base UI `Positioner` needs and nothing more: it is a layout box, not a
|
|
29
81
|
* painted one. The stacking context lives here so the popup itself can stay
|
|
@@ -44,26 +96,34 @@ declare const overlayPopupTransitionClasses = "origin-(--transform-origin) trans
|
|
|
44
96
|
* transition property list to name both.
|
|
45
97
|
*/
|
|
46
98
|
declare const overlayModalTransitionClasses = "transition-[opacity,scale] duration-150 ease-out motion-reduce:transition-none data-[starting-style]:scale-[0.98] data-[starting-style]:opacity-0 data-[ending-style]:scale-[0.98] data-[ending-style]:opacity-0";
|
|
47
|
-
/**
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
99
|
+
/**
|
|
100
|
+
* Body copy inside an overlay: the body voice (mono unless a style set names
|
|
101
|
+
* another face — `_style-body.ts`), one rung under the panel's own text.
|
|
102
|
+
*/
|
|
103
|
+
declare const overlayTextClasses = "font-[family-name:var(--cue-style-body-face,var(--cue-font-mono))] font-[number:var(--cue-style-body-weight,inherit)] text-(length:--cue-text-ui) text-fg";
|
|
104
|
+
/**
|
|
105
|
+
* The heading line of a dialog, an alert dialog or a popover: the title voice's
|
|
106
|
+
* face, weight and ink at the overlay title's own size (`_style-overlay-title.ts`).
|
|
107
|
+
*/
|
|
108
|
+
declare const overlayTitleClasses = "font-[family-name:var(--cue-style-title-face,var(--cue-font-mono))] text-[length:var(--cue-style-overlay-title-size,var(--cue-text-emphasis))] leading-[var(--cue-style-overlay-title-leading,inherit)] font-[number:var(--cue-style-title-weight,500)] [font-variation-settings:var(--cue-style-display-variation,normal)] text-[color:var(--cue-style-heading-ink,var(--cue-fg))]";
|
|
109
|
+
/** The supporting line under an overlay title, in the body voice. */
|
|
110
|
+
declare const overlayDescriptionClasses = "font-[family-name:var(--cue-style-body-face,var(--cue-font-mono))] font-[number:var(--cue-style-body-weight,inherit)] text-[length:var(--cue-style-body-size,var(--cue-text-ui))] leading-[var(--cue-style-body-leading,var(--cue-leading-ui))] text-fg-muted";
|
|
53
111
|
/** The action strip at the foot of a modal surface. */
|
|
54
112
|
declare const overlayFooterClasses = "flex items-center justify-end gap-(--cue-space-3) pt-(--cue-space-2)";
|
|
55
113
|
/**
|
|
56
114
|
* One row of a menu: the short rung of the density control ladder, highlighted
|
|
57
115
|
* with `accent-soft` rather than a solid fill (the luma defect ruling — a solid
|
|
58
|
-
* accent bar on a hovered row is too loud at console density).
|
|
116
|
+
* accent bar on a hovered row is too loud at console density). The row's ink
|
|
117
|
+
* and the highlight are the style set's, with those as their defaults
|
|
118
|
+
* (`_style-menu.ts`).
|
|
59
119
|
*/
|
|
60
|
-
declare const menuItemClasses = "flex h-control-sm cursor-default items-center gap-(--cue-space-2) rounded-(--radius-control) px-(--cue-space-3) font-mono text-(length:--cue-text-ui) text-fg-muted
|
|
61
|
-
/** The uppercase mono caption over a group of menu rows. */
|
|
62
|
-
declare const menuLabelClasses = "flex h-control-sm items-center px-(--cue-space-3) font-mono text-(
|
|
120
|
+
declare const menuItemClasses = "flex h-control-sm cursor-default items-center gap-(--cue-space-2) rounded-[var(--cue-style-menu-item-radius,calc(var(--cue-radius-control)*var(--cue-radius-scale)))] px-(--cue-space-3) font-[family-name:var(--cue-style-control-face,var(--cue-font-mono))] text-(length:--cue-text-ui) text-[color:var(--cue-style-quiet-ink,var(--cue-fg-muted))] data-[highlighted]:bg-[color:var(--cue-style-menu-highlight,var(--cue-accent-soft))] outline-none select-none data-[highlighted]:text-fg data-[disabled]:pointer-events-none data-[disabled]:opacity-[var(--cue-style-row-disabled-opacity,0.4)]";
|
|
121
|
+
/** The uppercase mono caption over a group of menu rows — by default. */
|
|
122
|
+
declare const menuLabelClasses = "flex h-control-sm items-center px-(--cue-space-3) py-[var(--cue-style-group-label-pad,0px)] font-[family-name:var(--cue-style-label-face,var(--cue-font-mono))] text-[length:var(--cue-style-group-label-size,var(--cue-style-label-size,var(--cue-text-label)))] tracking-[var(--cue-style-label-tracking,var(--cue-tracking-caps))] text-[color:var(--cue-style-group-label-ink,var(--cue-style-label-ink,var(--cue-fg-subtle)))] font-[number:var(--cue-style-label-weight,inherit)] [text-transform:var(--cue-style-label-case,uppercase)] select-none";
|
|
63
123
|
/** The hairline between menu groups. */
|
|
64
|
-
declare const menuSeparatorClasses = "my-(--cue-space-1) h-px bg-border";
|
|
124
|
+
declare const menuSeparatorClasses = "my-(--cue-space-1) mx-[var(--cue-style-menu-separator-inset,0px)] h-px bg-border";
|
|
65
125
|
/** Padding of a menu popup — a single space unit so rows reach the rim. */
|
|
66
|
-
declare const menuPopupClasses = "min-w-[10rem] p-(--cue-space-1)";
|
|
126
|
+
declare const menuPopupClasses = "min-w-[var(--cue-style-menu-min-width,10rem)] p-(--cue-space-1)";
|
|
67
127
|
/** Default gap in px between an anchored popup and its trigger. */
|
|
68
128
|
declare const OVERLAY_SIDE_OFFSET = 4;
|
|
69
129
|
//#endregion
|
|
@@ -1,5 +1,18 @@
|
|
|
1
|
+
import { CONTROL_FACE } from "../system/_style-control-face.js";
|
|
2
|
+
import { LABEL_FACE } from "../system/_style-label-face.js";
|
|
3
|
+
import { LABEL_WEIGHT } from "../system/_style-label-weight.js";
|
|
4
|
+
import { LABEL_CASE } from "../system/_style-label-case.js";
|
|
5
|
+
import { LABEL_TRACKING } from "../system/_style-label-tracking.js";
|
|
1
6
|
import { ELEVATION_2 } from "../system/_paint-elevation.js";
|
|
2
7
|
import { STROKE_SURFACE_2 } from "../system/_paint-stroke-surface-2.js";
|
|
8
|
+
import { BODY_VOICE } from "../system/_style-body.js";
|
|
9
|
+
import { GROUP_LABEL_INK, GROUP_LABEL_SIZE } from "../system/_style-group-label.js";
|
|
10
|
+
import { GROUP_LABEL_PAD } from "../system/_style-group-label-pad.js";
|
|
11
|
+
import { MENU_ITEM_INK, MENU_ITEM_RADIUS, MENU_MIN_WIDTH, MENU_SEPARATOR_INSET } from "../system/_style-menu.js";
|
|
12
|
+
import { ROW_DISABLED_OPACITY } from "../system/_style-row-disabled.js";
|
|
13
|
+
import { OVERLAY_TITLE_VOICE } from "../system/_style-overlay-title.js";
|
|
14
|
+
import { BODY_LEADING } from "../system/_style-body-leading.js";
|
|
15
|
+
import { BODY_SIZE } from "../system/_style-body-size.js";
|
|
3
16
|
//#region src/overlays/_surface.ts
|
|
4
17
|
/**
|
|
5
18
|
* The conventions every floating surface in this system shares.
|
|
@@ -20,12 +33,64 @@ import { STROKE_SURFACE_2 } from "../system/_paint-stroke-surface-2.js";
|
|
|
20
33
|
* @example
|
|
21
34
|
* <Popover.Popup className={cn(overlaySurfaceClasses, className)} />
|
|
22
35
|
*/
|
|
23
|
-
const overlaySurfaceClasses = `rounded-
|
|
36
|
+
const overlaySurfaceClasses = `rounded-overlay ${STROKE_SURFACE_2} ${ELEVATION_2}`;
|
|
24
37
|
/**
|
|
25
38
|
* The full-viewport dim behind a modal surface. `--cue-scrim` is theme-owned —
|
|
26
39
|
* dusk and hivehub tune their own — so the value is never hard-coded here.
|
|
40
|
+
*
|
|
41
|
+
* **The scrim's own filter (spec §3.10, P0.6) lives on a `::before`
|
|
42
|
+
* pseudo-element, never on `backdrop-filter` of the scrim itself.** Every
|
|
43
|
+
* element here is public through `backdropClassName` (dialog, sheet, drawer,
|
|
44
|
+
* alert-dialog and command-palette all feed it into
|
|
45
|
+
* `cn(scrimClasses, backdropClassName)`), which exists precisely so a consumer
|
|
46
|
+
* can put their own `backdrop-blur-*` on this element — so the scrim's own
|
|
47
|
+
* `backdrop-filter` is a slot this recipe must never write to at all, not a
|
|
48
|
+
* slot to compose into.
|
|
49
|
+
*
|
|
50
|
+
* **Why not fill one of Tailwind's own composition slots instead (the
|
|
51
|
+
* `_paint-glass.ts` technique).** Measured, and it does not survive
|
|
52
|
+
* `paint-scrim-filter: none`, which is every shipped pack's value but
|
|
53
|
+
* glaze's (`blur(8px)`, the Porcelain Look's dialog backdrop).
|
|
54
|
+
* Tailwind's composed `backdrop-filter: var(--tw-backdrop-blur,)
|
|
55
|
+
* var(--tw-backdrop-brightness,) … var(--tw-backdrop-grayscale,) …` accepts
|
|
56
|
+
* only `<filter-function>`s in that list; `none` is not one, so a slot filled
|
|
57
|
+
* with the literal text `none` sitting beside a consumer's `blur(8px)` is an
|
|
58
|
+
* **invalid** `backdrop-filter` value as a whole — not "no extra blur" but a
|
|
59
|
+
* parse failure that drops the entire declaration, computing `none` even for
|
|
60
|
+
* the consumer's own choice. `_paint-glass.ts` never meets this: its slot's
|
|
61
|
+
* default is a real filter function (`blur(8px)`), never the keyword `none`.
|
|
62
|
+
*
|
|
63
|
+
* **The pseudo-element has no such slot to collide over.** Its own
|
|
64
|
+
* `backdrop-filter: var(--cue-paint-scrim-filter, none)` is the only
|
|
65
|
+
* declaration for that property on that box, so `none` is simply valid and
|
|
66
|
+
* inert there, exactly as intended, whatever the scrim element's own
|
|
67
|
+
* `backdrop-filter` (via `backdropClassName`) computes. `content-['']` gives
|
|
68
|
+
* it a box; `absolute inset-0` sizes it to the scrim, whose own `fixed`
|
|
69
|
+
* positioning is a containing block for it; `pointer-events-none` keeps it out
|
|
70
|
+
* of the scrim's own click handling. The pseudo paints after the scrim's own
|
|
71
|
+
* `bg-(--cue-scrim)`, so a real filter blurs that tint together with the page
|
|
72
|
+
* — a flat tint, so the blur of it is the same tint.
|
|
73
|
+
*
|
|
74
|
+
* **The scrim never fades by its own opacity, because that would isolate the
|
|
75
|
+
* pseudo's backdrop.** An ancestor with opacity under 1 is a backdrop root: a
|
|
76
|
+
* descendant's `backdrop-filter` sees only what is painted inside it. When the
|
|
77
|
+
* scrim faded in by `opacity`, glaze's blur on the pseudo therefore had
|
|
78
|
+
* nothing to blur for the whole fade — the page stayed sharp while it dimmed,
|
|
79
|
+
* snapped to 8px the frame opacity reached 1, and lost the blur on the first
|
|
80
|
+
* frame of the exit (measured in Chromium; `paint-noop.spec.ts`'s P43 case
|
|
81
|
+
* reads the pixels halfway through). So the scrim holds opacity 1 and fades
|
|
82
|
+
* its parts: its background from `transparent`, the pseudo by its *own*
|
|
83
|
+
* opacity (an element's own opacity does not isolate its own backdrop), and
|
|
84
|
+
* its own `backdrop-filter` from `none` — the last only so a consumer's
|
|
85
|
+
* `backdrop-blur-*`, which faded with the scrim's opacity before, still fades
|
|
86
|
+
* rather than snapping in. That one is written for the starting and ending
|
|
87
|
+
* frames alone, where a whole-property `none` outranks the consumer's
|
|
88
|
+
* composed declaration without entering it; at rest the property is theirs.
|
|
89
|
+
* The pseudo's `transition` and timing are its own classes: Tailwind
|
|
90
|
+
* registers `--tw-duration` and `--tw-ease` with `inherits: false`, so the
|
|
91
|
+
* scrim's `duration-150 ease-out` never reach it.
|
|
27
92
|
*/
|
|
28
|
-
const scrimClasses = "fixed inset-0 z-50 bg-(--cue-scrim) transition-opacity duration-150 ease-out motion-reduce:transition-none data-[starting-style]:opacity-0 data-[ending-style]:opacity-0";
|
|
93
|
+
const scrimClasses = "fixed inset-0 z-50 bg-(--cue-scrim) before:absolute before:inset-0 before:content-[''] before:pointer-events-none before:[backdrop-filter:var(--cue-paint-scrim-filter,none)] transition-[background-color,backdrop-filter] duration-150 ease-out before:transition-opacity before:duration-150 before:ease-out motion-reduce:transition-none motion-reduce:before:transition-none data-[starting-style]:bg-transparent data-[ending-style]:bg-transparent data-[starting-style]:[backdrop-filter:none] data-[ending-style]:[backdrop-filter:none] data-[starting-style]:before:opacity-0 data-[ending-style]:before:opacity-0";
|
|
29
94
|
/**
|
|
30
95
|
* What a Base UI `Positioner` needs and nothing more: it is a layout box, not a
|
|
31
96
|
* painted one. The stacking context lives here so the popup itself can stay
|
|
@@ -46,26 +111,34 @@ const overlayPopupTransitionClasses = "origin-(--transform-origin) transition-[o
|
|
|
46
111
|
* transition property list to name both.
|
|
47
112
|
*/
|
|
48
113
|
const overlayModalTransitionClasses = "transition-[opacity,scale] duration-150 ease-out motion-reduce:transition-none data-[starting-style]:scale-[0.98] data-[starting-style]:opacity-0 data-[ending-style]:scale-[0.98] data-[ending-style]:opacity-0";
|
|
49
|
-
/**
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
114
|
+
/**
|
|
115
|
+
* Body copy inside an overlay: the body voice (mono unless a style set names
|
|
116
|
+
* another face — `_style-body.ts`), one rung under the panel's own text.
|
|
117
|
+
*/
|
|
118
|
+
const overlayTextClasses = `${BODY_VOICE} text-(length:--cue-text-ui) text-fg`;
|
|
119
|
+
/**
|
|
120
|
+
* The heading line of a dialog, an alert dialog or a popover: the title voice's
|
|
121
|
+
* face, weight and ink at the overlay title's own size (`_style-overlay-title.ts`).
|
|
122
|
+
*/
|
|
123
|
+
const overlayTitleClasses = OVERLAY_TITLE_VOICE;
|
|
124
|
+
/** The supporting line under an overlay title, in the body voice. */
|
|
125
|
+
const overlayDescriptionClasses = `${BODY_VOICE} ${BODY_SIZE} ${BODY_LEADING} text-fg-muted`;
|
|
55
126
|
/** The action strip at the foot of a modal surface. */
|
|
56
127
|
const overlayFooterClasses = "flex items-center justify-end gap-(--cue-space-3) pt-(--cue-space-2)";
|
|
57
128
|
/**
|
|
58
129
|
* One row of a menu: the short rung of the density control ladder, highlighted
|
|
59
130
|
* with `accent-soft` rather than a solid fill (the luma defect ruling — a solid
|
|
60
|
-
* accent bar on a hovered row is too loud at console density).
|
|
131
|
+
* accent bar on a hovered row is too loud at console density). The row's ink
|
|
132
|
+
* and the highlight are the style set's, with those as their defaults
|
|
133
|
+
* (`_style-menu.ts`).
|
|
61
134
|
*/
|
|
62
|
-
const menuItemClasses =
|
|
63
|
-
/** The uppercase mono caption over a group of menu rows. */
|
|
64
|
-
const menuLabelClasses =
|
|
135
|
+
const menuItemClasses = `flex h-control-sm cursor-default items-center gap-(--cue-space-2) ${MENU_ITEM_RADIUS} px-(--cue-space-3) ${CONTROL_FACE} text-(length:--cue-text-ui) ${MENU_ITEM_INK} outline-none select-none data-[highlighted]:text-fg data-[disabled]:pointer-events-none ${ROW_DISABLED_OPACITY}`;
|
|
136
|
+
/** The uppercase mono caption over a group of menu rows — by default. */
|
|
137
|
+
const menuLabelClasses = `flex h-control-sm items-center px-(--cue-space-3) ${GROUP_LABEL_PAD} ${LABEL_FACE} ${GROUP_LABEL_SIZE} ${LABEL_TRACKING} ${GROUP_LABEL_INK} ${LABEL_WEIGHT} ${LABEL_CASE} select-none`;
|
|
65
138
|
/** The hairline between menu groups. */
|
|
66
|
-
const menuSeparatorClasses =
|
|
139
|
+
const menuSeparatorClasses = `my-(--cue-space-1) ${MENU_SEPARATOR_INSET} h-px bg-border`;
|
|
67
140
|
/** Padding of a menu popup — a single space unit so rows reach the rim. */
|
|
68
|
-
const menuPopupClasses =
|
|
141
|
+
const menuPopupClasses = `${MENU_MIN_WIDTH} p-(--cue-space-1)`;
|
|
69
142
|
/** Default gap in px between an anchored popup and its trigger. */
|
|
70
143
|
const OVERLAY_SIDE_OFFSET = 4;
|
|
71
144
|
//#endregion
|
|
@@ -9,7 +9,7 @@ import { jsx, jsxs } from "react/jsx-runtime";
|
|
|
9
9
|
import { AlertDialog } from "@base-ui/react/alert-dialog";
|
|
10
10
|
//#region src/overlays/alert-dialog.tsx
|
|
11
11
|
/** Same geometry as a dialog; an alert is simply a narrower default. */
|
|
12
|
-
const alertDialogPopupVariants = cva(`${overlaySurfaceClasses} ${overlayModalTransitionClasses} fixed top-1/2 left-1/2 z-50 flex max-h-[85vh] w-[calc(100vw-2rem)] -translate-x-1/2 -translate-y-1/2 flex-col gap-(--cue-space-4) overflow-y-auto p-(--cue-space-6) outline-none`, {
|
|
12
|
+
const alertDialogPopupVariants = cva(`${overlaySurfaceClasses} rounded-[calc(var(--cue-style-dialog-radius,var(--cue-radius-overlay))*var(--cue-radius-scale))] ${overlayModalTransitionClasses} fixed top-1/2 left-1/2 z-50 flex max-h-[85vh] w-[calc(100vw-2rem)] -translate-x-1/2 -translate-y-1/2 flex-col gap-(--cue-space-4) overflow-y-auto p-(--cue-space-6) outline-none`, {
|
|
13
13
|
variants: { width: {
|
|
14
14
|
sm: "max-w-[20rem]",
|
|
15
15
|
md: "max-w-[26rem]",
|
|
@@ -1,8 +1,17 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
import { cn } from "../lib/cn.js";
|
|
3
|
+
import { CONTROL_FACE } from "../system/_style-control-face.js";
|
|
4
|
+
import { CONTROL_STEP_SIZE_BODY } from "../system/_style-control-step.js";
|
|
5
|
+
import { LABEL_FACE } from "../system/_style-label-face.js";
|
|
6
|
+
import { LABEL_CASE } from "../system/_style-label-case.js";
|
|
7
|
+
import { LABEL_TRACKING } from "../system/_style-label-tracking.js";
|
|
3
8
|
import { SearchGlyph } from "./_glyphs.js";
|
|
4
9
|
import { useCuePortalProps } from "../system/portal.js";
|
|
10
|
+
import { GROUP_LABEL_INK_SUBTLE, GROUP_LABEL_SIZE_MICRO } from "../system/_style-group-label.js";
|
|
11
|
+
import { MENU_ITEM_INK, MENU_ITEM_RADIUS } from "../system/_style-menu.js";
|
|
12
|
+
import { ROW_DISABLED_OPACITY } from "../system/_style-row-disabled.js";
|
|
5
13
|
import { overlayModalTransitionClasses, overlaySurfaceClasses, scrimClasses } from "./_surface.js";
|
|
14
|
+
import { PALETTE_FOOTER_PAD, PALETTE_RULE } from "../system/_style-palette.js";
|
|
6
15
|
import { useDebouncedValue } from "./_debounce.js";
|
|
7
16
|
import * as React from "react";
|
|
8
17
|
import { Fragment, jsx, jsxs } from "react/jsx-runtime";
|
|
@@ -47,8 +56,18 @@ function groupCommands(items) {
|
|
|
47
56
|
}
|
|
48
57
|
return groups;
|
|
49
58
|
}
|
|
50
|
-
/**
|
|
51
|
-
|
|
59
|
+
/**
|
|
60
|
+
* The palette's corner is a dialog's (round 6, spec §11, P152): coss's command
|
|
61
|
+
* palette is a dialog, rounded at its 16px surface rung. The same class as
|
|
62
|
+
* `dialog.tsx`'s `DIALOG_RADIUS`, kept in this file for that file's reason.
|
|
63
|
+
*/
|
|
64
|
+
const PALETTE_RADIUS = "rounded-[calc(var(--cue-style-dialog-radius,var(--cue-radius-overlay))*var(--cue-radius-scale))]";
|
|
65
|
+
/**
|
|
66
|
+
* The row: same rhythm as a menu row, with a reserved gutter for the icon. Its
|
|
67
|
+
* ink, highlight and corner are a menu row's (round 6, spec §11, P152): coss's
|
|
68
|
+
* command rows draw like its menu rows, in `fg` on 0.6 of the control corner.
|
|
69
|
+
*/
|
|
70
|
+
const commandItemClasses = `flex h-control-md cursor-default items-center gap-(--cue-space-3) ${MENU_ITEM_RADIUS} px-(--cue-space-3) ${CONTROL_FACE} text-(length:--cue-text-ui) ${MENU_ITEM_INK} outline-none select-none data-[highlighted]:text-fg data-[disabled]:pointer-events-none ${ROW_DISABLED_OPACITY}`;
|
|
52
71
|
/**
|
|
53
72
|
* The ⌘K surface: type a few letters, run a command.
|
|
54
73
|
*
|
|
@@ -114,7 +133,7 @@ function CommandPalette({ items, onSelect, open: openProp, defaultOpen = false,
|
|
|
114
133
|
}), /* @__PURE__ */ jsxs(Dialog.Popup, {
|
|
115
134
|
"aria-label": label,
|
|
116
135
|
"data-slot": "command-palette-popup",
|
|
117
|
-
className: cn(overlaySurfaceClasses, overlayModalTransitionClasses, "fixed top-[14vh] left-1/2 z-50 flex max-h-[72vh] w-[min(35rem,92vw)] -translate-x-1/2 flex-col overflow-hidden outline-none", className),
|
|
136
|
+
className: cn(overlaySurfaceClasses, PALETTE_RADIUS, overlayModalTransitionClasses, "fixed top-[14vh] left-1/2 z-50 flex max-h-[72vh] w-[min(35rem,92vw)] -translate-x-1/2 flex-col overflow-hidden outline-none", className),
|
|
118
137
|
children: [/* @__PURE__ */ jsxs(Combobox.Root, {
|
|
119
138
|
items: groups,
|
|
120
139
|
filteredItems: filteredGroups,
|
|
@@ -132,7 +151,7 @@ function CommandPalette({ items, onSelect, open: openProp, defaultOpen = false,
|
|
|
132
151
|
children: [
|
|
133
152
|
/* @__PURE__ */ jsxs("div", {
|
|
134
153
|
"data-slot": "command-palette-field",
|
|
135
|
-
className:
|
|
154
|
+
className: `flex h-control-lg shrink-0 items-center gap-(--cue-space-3) border-b ${PALETTE_RULE} bg-sunken px-(--cue-space-4)`,
|
|
136
155
|
children: [/* @__PURE__ */ jsx(SearchGlyph, {
|
|
137
156
|
"aria-hidden": "true",
|
|
138
157
|
className: "size-icon-md shrink-0 text-fg-subtle"
|
|
@@ -140,22 +159,22 @@ function CommandPalette({ items, onSelect, open: openProp, defaultOpen = false,
|
|
|
140
159
|
"aria-label": label,
|
|
141
160
|
placeholder,
|
|
142
161
|
"data-slot": "command-palette-input",
|
|
143
|
-
className:
|
|
162
|
+
className: cn(`h-full w-full min-w-0 border-0 bg-transparent p-0 ${CONTROL_STEP_SIZE_BODY} text-fg outline-none placeholder:text-fg-subtle`, CONTROL_FACE)
|
|
144
163
|
})]
|
|
145
164
|
}),
|
|
146
165
|
/* @__PURE__ */ jsx(Combobox.Empty, {
|
|
147
166
|
"data-slot": "command-palette-empty",
|
|
148
|
-
className: "flex h-control-lg items-center px-(--cue-space-4)
|
|
167
|
+
className: cn("flex h-control-lg items-center px-(--cue-space-4) text-(length:--cue-text-ui) text-fg-subtle select-none", CONTROL_FACE),
|
|
149
168
|
children: emptyMessage
|
|
150
169
|
}),
|
|
151
170
|
/* @__PURE__ */ jsx(Combobox.List, {
|
|
152
171
|
"data-slot": "command-palette-list",
|
|
153
|
-
className: "min-h-0 flex-1 overflow-y-auto overscroll-contain p-(--cue-space-1) outline-none",
|
|
172
|
+
className: "min-h-0 flex-1 overflow-y-auto overscroll-contain p-[var(--cue-style-listbox-pad,var(--cue-space-1))] outline-none",
|
|
154
173
|
children: (group) => /* @__PURE__ */ jsxs(Combobox.Group, {
|
|
155
174
|
items: group.items,
|
|
156
175
|
className: "block",
|
|
157
176
|
children: [group.value === "" ? null : /* @__PURE__ */ jsx(Combobox.GroupLabel, {
|
|
158
|
-
className:
|
|
177
|
+
className: cn(`flex h-control-sm items-center px-(--cue-space-3) ${GROUP_LABEL_SIZE_MICRO} ${GROUP_LABEL_INK_SUBTLE} select-none`, LABEL_FACE, LABEL_TRACKING, LABEL_CASE),
|
|
159
178
|
children: group.value
|
|
160
179
|
}), /* @__PURE__ */ jsx(Combobox.Collection, { children: (item) => /* @__PURE__ */ jsxs(Combobox.Item, {
|
|
161
180
|
value: item,
|
|
@@ -182,7 +201,7 @@ function CommandPalette({ items, onSelect, open: openProp, defaultOpen = false,
|
|
|
182
201
|
]
|
|
183
202
|
}), footer === null ? null : /* @__PURE__ */ jsx("div", {
|
|
184
203
|
"data-slot": "command-palette-footer",
|
|
185
|
-
className:
|
|
204
|
+
className: cn(`flex shrink-0 items-center gap-(--cue-space-4) border-t border-border bg-surface-1 px-(--cue-space-4) ${PALETTE_FOOTER_PAD} text-(length:--cue-text-micro) text-fg-subtle select-none`, CONTROL_FACE),
|
|
186
205
|
children: footer
|
|
187
206
|
})]
|
|
188
207
|
})]
|
|
@@ -8,6 +8,11 @@ import { Dialog } from "@base-ui/react/dialog";
|
|
|
8
8
|
* Centring is `top/left 50%` plus a translate rather than a flex-centred
|
|
9
9
|
* wrapper: the popup owns its own position, so nothing else has to cover the
|
|
10
10
|
* viewport and steal pointer events from the scrim.
|
|
11
|
+
*
|
|
12
|
+
* Its corner is `DIALOG_RADIUS`, the style set's `--cue-style-dialog-radius`
|
|
13
|
+
* over the overlay rung, spent after `overlaySurfaceClasses` so the popup's
|
|
14
|
+
* own `cn` drops the shared `rounded-overlay`: only the dialog reads the name,
|
|
15
|
+
* and every other overlay keeps the rung.
|
|
11
16
|
*/
|
|
12
17
|
declare const dialogPopupVariants: (props?: ({
|
|
13
18
|
width?: "sm" | "md" | "lg" | null | undefined;
|
package/dist/overlays/dialog.js
CHANGED
|
@@ -15,8 +15,13 @@ import { Dialog } from "@base-ui/react/dialog";
|
|
|
15
15
|
* Centring is `top/left 50%` plus a translate rather than a flex-centred
|
|
16
16
|
* wrapper: the popup owns its own position, so nothing else has to cover the
|
|
17
17
|
* viewport and steal pointer events from the scrim.
|
|
18
|
+
*
|
|
19
|
+
* Its corner is `DIALOG_RADIUS`, the style set's `--cue-style-dialog-radius`
|
|
20
|
+
* over the overlay rung, spent after `overlaySurfaceClasses` so the popup's
|
|
21
|
+
* own `cn` drops the shared `rounded-overlay`: only the dialog reads the name,
|
|
22
|
+
* and every other overlay keeps the rung.
|
|
18
23
|
*/
|
|
19
|
-
const dialogPopupVariants = cva(`${overlaySurfaceClasses} ${overlayModalTransitionClasses} fixed top-1/2 left-1/2 z-50 flex max-h-[85vh] w-[calc(100vw-2rem)] -translate-x-1/2 -translate-y-1/2 flex-col gap-(--cue-space-4) overflow-y-auto p-(--cue-space-6) outline-none`, {
|
|
24
|
+
const dialogPopupVariants = cva(`${overlaySurfaceClasses} rounded-[calc(var(--cue-style-dialog-radius,var(--cue-radius-overlay))*var(--cue-radius-scale))] ${overlayModalTransitionClasses} fixed top-1/2 left-1/2 z-50 flex max-h-[85vh] w-[calc(100vw-2rem)] -translate-x-1/2 -translate-y-1/2 flex-col gap-(--cue-space-4) overflow-y-auto p-[calc(var(--cue-space-6)*var(--cue-style-dialog-pad,1))] outline-none`, {
|
|
20
25
|
variants: { width: {
|
|
21
26
|
sm: "max-w-[20rem]",
|
|
22
27
|
md: "max-w-[28rem]",
|
package/dist/overlays/drawer.js
CHANGED
|
@@ -27,6 +27,13 @@ const VIEWPORT_ALIGNMENT = {
|
|
|
27
27
|
* sheet track the finger and then settle, rather than snapping when the gesture
|
|
28
28
|
* ends.
|
|
29
29
|
*/
|
|
30
|
+
/**
|
|
31
|
+
* A drawer's corners are a dialog's (round 6, spec §11, P155.radius): coss.com/ui
|
|
32
|
+
* rounds its drawer's open edge at its 16px surface rung, as it rounds a dialog.
|
|
33
|
+
* The same class as `dialog.tsx`'s `DIALOG_RADIUS`, kept in this file for that
|
|
34
|
+
* file's reason; the attached edge's `rounded-*-none` still squares that side.
|
|
35
|
+
*/
|
|
36
|
+
const DRAWER_RADIUS = "rounded-[calc(var(--cue-style-dialog-radius,var(--cue-radius-overlay))*var(--cue-radius-scale))]";
|
|
30
37
|
const POPUP_GEOMETRY = {
|
|
31
38
|
down: "max-h-[85vh] w-full max-w-[42rem] translate-y-(--drawer-swipe-movement-y) rounded-b-none border-x-0 border-b-0 data-[starting-style]:translate-y-full data-[ending-style]:translate-y-full",
|
|
32
39
|
up: "max-h-[85vh] w-full max-w-[42rem] translate-y-(--drawer-swipe-movement-y) rounded-t-none border-x-0 border-t-0 data-[starting-style]:-translate-y-full data-[ending-style]:-translate-y-full",
|
|
@@ -99,7 +106,7 @@ const Drawer$1 = {
|
|
|
99
106
|
children: /* @__PURE__ */ jsxs(Drawer.Popup, {
|
|
100
107
|
ref,
|
|
101
108
|
"data-slot": "drawer-popup",
|
|
102
|
-
className: cn(overlaySurfaceClasses, "flex flex-col overflow-y-auto overscroll-contain outline-none transition-transform duration-200 ease-out data-[swiping]:duration-0 motion-reduce:transition-none", POPUP_GEOMETRY[direction], className),
|
|
109
|
+
className: cn(overlaySurfaceClasses, DRAWER_RADIUS, "flex flex-col overflow-y-auto overscroll-contain outline-none transition-transform duration-200 ease-out data-[swiping]:duration-0 motion-reduce:transition-none", POPUP_GEOMETRY[direction], className),
|
|
103
110
|
...popupProps,
|
|
104
111
|
children: [grabHandle ? /* @__PURE__ */ jsx("div", {
|
|
105
112
|
"data-slot": "drawer-grab-handle",
|
|
@@ -4,6 +4,8 @@ import { useComposedRefs } from "../lib/compose.js";
|
|
|
4
4
|
import { useCuePortalProps } from "../system/portal.js";
|
|
5
5
|
import { overlayPopupTransitionClasses, overlayPositionerClasses, overlaySurfaceClasses } from "./_surface.js";
|
|
6
6
|
import { useCloseOnWheel } from "./_wheel.js";
|
|
7
|
+
import { HOVER_CARD_WIDTH } from "../system/_style-hover-card-width.js";
|
|
8
|
+
import { POPOVER_PAD } from "../system/_style-popover-pad.js";
|
|
7
9
|
import * as React from "react";
|
|
8
10
|
import { jsx } from "react/jsx-runtime";
|
|
9
11
|
import { PreviewCard } from "@base-ui/react/preview-card";
|
|
@@ -79,7 +81,7 @@ const HoverCard = {
|
|
|
79
81
|
children: /* @__PURE__ */ jsx(PreviewCard.Popup, {
|
|
80
82
|
ref: composedRef,
|
|
81
83
|
"data-slot": "hover-card-popup",
|
|
82
|
-
className: cn(overlaySurfaceClasses, overlayPopupTransitionClasses,
|
|
84
|
+
className: cn(overlaySurfaceClasses, overlayPopupTransitionClasses, `flex ${HOVER_CARD_WIDTH} flex-col gap-(--cue-space-2) ${POPOVER_PAD} font-mono text-(length:--cue-text-ui) text-fg-muted outline-none`, className),
|
|
83
85
|
...popupProps,
|
|
84
86
|
children
|
|
85
87
|
})
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
import { cn } from "../lib/cn.js";
|
|
3
|
+
import { FOCUS_RING } from "../system/_focus-ring.js";
|
|
3
4
|
import { Tooltip } from "./tooltip.js";
|
|
4
5
|
import "react";
|
|
5
6
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
@@ -27,7 +28,7 @@ function InfoTip({ text, width = 224, label = "More information", side = "top",
|
|
|
27
28
|
delay,
|
|
28
29
|
"aria-label": label,
|
|
29
30
|
"data-slot": "info-tip-trigger",
|
|
30
|
-
className: cn(
|
|
31
|
+
className: cn(`inline-flex size-[0.8125rem] shrink-0 cursor-help items-center justify-center rounded-full border border-border-strong bg-transparent font-mono text-(length:--cue-text-micro) leading-none font-bold text-fg-muted italic outline-none select-none hover:border-accent hover:text-accent ${FOCUS_RING}`, className),
|
|
31
32
|
children: "i"
|
|
32
33
|
}), /* @__PURE__ */ jsx(Tooltip.Content, {
|
|
33
34
|
side,
|
package/dist/overlays/menubar.js
CHANGED
|
@@ -1,5 +1,7 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
import { cn } from "../lib/cn.js";
|
|
3
|
+
import { FOCUS_RING_INSET } from "../system/_focus-ring.js";
|
|
4
|
+
import { CONTROL_FACE } from "../system/_style-control-face.js";
|
|
3
5
|
import { useCuePortalProps } from "../system/portal.js";
|
|
4
6
|
import { menuPopupClasses, overlayPopupTransitionClasses, overlayPositionerClasses, overlaySurfaceClasses } from "./_surface.js";
|
|
5
7
|
import { DropdownMenu } from "./dropdown-menu.js";
|
|
@@ -66,7 +68,7 @@ const Menubar$1 = {
|
|
|
66
68
|
return /* @__PURE__ */ jsx(Menu.Trigger, {
|
|
67
69
|
ref,
|
|
68
70
|
"data-slot": "menubar-trigger",
|
|
69
|
-
className: cn(
|
|
71
|
+
className: cn(`inline-flex h-control-sm shrink-0 cursor-default items-center rounded-control px-(--cue-space-3) text-(length:--cue-text-ui) whitespace-nowrap text-fg-muted transition-colors duration-150 outline-none select-none hover:text-fg ${FOCUS_RING_INSET} data-[popup-open]:bg-accent-soft data-[popup-open]:text-fg data-[disabled]:pointer-events-none data-[disabled]:opacity-40`, CONTROL_FACE, className),
|
|
70
72
|
...elementProps
|
|
71
73
|
});
|
|
72
74
|
}),
|
package/dist/overlays/popover.js
CHANGED
|
@@ -4,6 +4,8 @@ import { useComposedRefs } from "../lib/compose.js";
|
|
|
4
4
|
import { useCuePortalProps } from "../system/portal.js";
|
|
5
5
|
import { overlayDescriptionClasses, overlayPopupTransitionClasses, overlayPositionerClasses, overlaySurfaceClasses, overlayTitleClasses } from "./_surface.js";
|
|
6
6
|
import { useCloseOnWheel } from "./_wheel.js";
|
|
7
|
+
import { POPOVER_PAD } from "../system/_style-popover-pad.js";
|
|
8
|
+
import { POPOVER_WIDTH } from "../system/_style-popover-width.js";
|
|
7
9
|
import * as React from "react";
|
|
8
10
|
import { jsx } from "react/jsx-runtime";
|
|
9
11
|
import { Popover } from "@base-ui/react/popover";
|
|
@@ -78,7 +80,7 @@ const Popover$1 = {
|
|
|
78
80
|
children: /* @__PURE__ */ jsx(Popover.Popup, {
|
|
79
81
|
ref: composedRef,
|
|
80
82
|
"data-slot": "popover-popup",
|
|
81
|
-
className: cn(overlaySurfaceClasses, overlayPopupTransitionClasses,
|
|
83
|
+
className: cn(overlaySurfaceClasses, overlayPopupTransitionClasses, `flex ${POPOVER_WIDTH} max-w-[calc(100vw-2rem)] flex-col gap-(--cue-space-3) ${POPOVER_PAD} outline-none`, className),
|
|
82
84
|
...popupProps,
|
|
83
85
|
children
|
|
84
86
|
})
|
package/dist/overlays/toast.js
CHANGED
|
@@ -1,8 +1,16 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
import { cn } from "../lib/cn.js";
|
|
3
|
+
import { FOCUS_RING } from "../system/_focus-ring.js";
|
|
4
|
+
import { LABEL_FACE } from "../system/_style-label-face.js";
|
|
5
|
+
import { LABEL_CASE } from "../system/_style-label-case.js";
|
|
6
|
+
import { LABEL_TRACKING_TIGHT } from "../system/_style-label-tracking.js";
|
|
3
7
|
import { CrossGlyph } from "./_glyphs.js";
|
|
4
8
|
import { useCuePortalProps } from "../system/portal.js";
|
|
9
|
+
import { BODY_FACE, BODY_VOICE } from "../system/_style-body.js";
|
|
10
|
+
import { BODY_LEADING } from "../system/_style-body-leading.js";
|
|
11
|
+
import { BODY_SIZE, BODY_SIZE_LABEL } from "../system/_style-body-size.js";
|
|
5
12
|
import { overlaySurfaceClasses } from "./_surface.js";
|
|
13
|
+
import { TOAST_PAD_X, TOAST_PAD_Y, TOAST_WIDTH } from "../system/_style-toast.js";
|
|
6
14
|
import * as React from "react";
|
|
7
15
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
8
16
|
import { Toast } from "@base-ui/react/toast";
|
|
@@ -75,24 +83,24 @@ function ToastItem({ toast, className, closeLabel }) {
|
|
|
75
83
|
return /* @__PURE__ */ jsxs(Toast.Root, {
|
|
76
84
|
toast,
|
|
77
85
|
"data-slot": "toast-root",
|
|
78
|
-
className: cn(overlaySurfaceClasses,
|
|
86
|
+
className: cn(overlaySurfaceClasses, `relative flex flex-col gap-(--cue-space-1) border-l-2 ${TOAST_PAD_Y} pr-(--cue-space-6) ${TOAST_PAD_X} outline-none`, "transition-[opacity,translate] duration-150 ease-out motion-reduce:transition-none", "data-[starting-style]:translate-x-2 data-[starting-style]:opacity-0", "data-[ending-style]:translate-x-2 data-[ending-style]:opacity-0", "data-[limited]:hidden", TOAST_TONE_RAIL[toToastTone(toast.type)], className),
|
|
79
87
|
children: [
|
|
80
88
|
/* @__PURE__ */ jsx(Toast.Title, {
|
|
81
89
|
"data-slot": "toast-title",
|
|
82
|
-
className:
|
|
90
|
+
className: `${BODY_FACE} ${BODY_SIZE} font-medium text-fg`
|
|
83
91
|
}),
|
|
84
92
|
/* @__PURE__ */ jsx(Toast.Description, {
|
|
85
93
|
"data-slot": "toast-description",
|
|
86
|
-
className:
|
|
94
|
+
className: `${BODY_VOICE} ${BODY_SIZE_LABEL} ${BODY_LEADING} text-fg-muted`
|
|
87
95
|
}),
|
|
88
96
|
/* @__PURE__ */ jsx(Toast.Action, {
|
|
89
97
|
"data-slot": "toast-action",
|
|
90
|
-
className:
|
|
98
|
+
className: cn(`mt-(--cue-space-1) inline-flex h-control-sm w-fit cursor-pointer items-center justify-center rounded-control border border-border px-(--cue-space-3) text-(length:--cue-text-label) text-fg-muted transition-colors outline-none hover:border-border-strong hover:text-fg ${FOCUS_RING}`, LABEL_FACE, LABEL_TRACKING_TIGHT, LABEL_CASE)
|
|
91
99
|
}),
|
|
92
100
|
/* @__PURE__ */ jsx(Toast.Close, {
|
|
93
101
|
"aria-label": closeLabel,
|
|
94
102
|
"data-slot": "toast-close",
|
|
95
|
-
className:
|
|
103
|
+
className: `absolute top-(--cue-space-2) right-(--cue-space-2) flex size-icon-md cursor-pointer items-center justify-center rounded-control text-fg-subtle outline-none transition-colors hover:text-fg ${FOCUS_RING}`,
|
|
96
104
|
children: /* @__PURE__ */ jsx(CrossGlyph, { className: "size-icon-sm" })
|
|
97
105
|
})
|
|
98
106
|
]
|
|
@@ -115,7 +123,7 @@ function ToastViewport({ className, toastClassName, closeLabel = "Dismiss" }) {
|
|
|
115
123
|
...portalProps,
|
|
116
124
|
children: /* @__PURE__ */ jsx(Toast.Viewport, {
|
|
117
125
|
"data-slot": "toast-viewport",
|
|
118
|
-
className: cn(
|
|
126
|
+
className: cn(`fixed right-(--cue-space-6) bottom-(--cue-space-6) z-50 flex ${TOAST_WIDTH} max-w-[calc(100vw-2rem)] flex-col-reverse gap-(--cue-space-3) outline-none`, className),
|
|
119
127
|
children: toasts.map((toast) => /* @__PURE__ */ jsx(ToastItem, {
|
|
120
128
|
toast,
|
|
121
129
|
className: toastClassName,
|
package/dist/overlays/tooltip.js
CHANGED
|
@@ -1,7 +1,9 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
import { cn } from "../lib/cn.js";
|
|
3
|
+
import { BODY_WEIGHT } from "../system/_style-body-weight.js";
|
|
3
4
|
import { useCuePortalProps } from "../system/portal.js";
|
|
4
5
|
import { overlayPopupTransitionClasses, overlayPositionerClasses, overlaySurfaceClasses } from "./_surface.js";
|
|
6
|
+
import { TOOLTIP_FACE, TOOLTIP_INK, TOOLTIP_LEADING, TOOLTIP_PAD, TOOLTIP_RADIUS, TOOLTIP_SIZE, TOOLTIP_TRACKING } from "../system/_style-tooltip.js";
|
|
5
7
|
import * as React from "react";
|
|
6
8
|
import { jsx } from "react/jsx-runtime";
|
|
7
9
|
import { Tooltip } from "@base-ui/react/tooltip";
|
|
@@ -83,7 +85,7 @@ const Tooltip$1 = {
|
|
|
83
85
|
id,
|
|
84
86
|
role: "tooltip",
|
|
85
87
|
"data-slot": "tooltip-popup",
|
|
86
|
-
className: cn(overlaySurfaceClasses, overlayPopupTransitionClasses,
|
|
88
|
+
className: cn(overlaySurfaceClasses, overlayPopupTransitionClasses, `max-w-[16rem] ${TOOLTIP_RADIUS} ${TOOLTIP_PAD} ${TOOLTIP_SIZE} ${TOOLTIP_LEADING} ${BODY_WEIGHT} ${TOOLTIP_TRACKING} ${TOOLTIP_INK}`, TOOLTIP_FACE, className),
|
|
87
89
|
...popupProps,
|
|
88
90
|
children
|
|
89
91
|
})
|
|
@@ -1,14 +1,18 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
import { cn } from "../lib/cn.js";
|
|
3
3
|
import { cva } from "../lib/cva.js";
|
|
4
|
+
import { CAPTION_SIZE_LABEL } from "../system/_style-caption-size.js";
|
|
5
|
+
import { CAPTION_INK_MUTED } from "../system/_style-caption-ink.js";
|
|
6
|
+
import { CAPTION_WEIGHT } from "../system/_style-caption-weight.js";
|
|
7
|
+
import { AVATAR_EDGE, AVATAR_RADIUS } from "../system/_style-avatar.js";
|
|
4
8
|
import * as React from "react";
|
|
5
9
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
6
10
|
import { Avatar } from "@base-ui/react/avatar";
|
|
7
11
|
//#region src/primitives/avatar.tsx
|
|
8
|
-
const avatarVariants = cva(
|
|
12
|
+
const avatarVariants = cva(`relative inline-flex shrink-0 select-none items-center justify-center overflow-hidden ${AVATAR_RADIUS} border ${AVATAR_EDGE} bg-surface-2 font-mono leading-none tracking-normal ${CAPTION_INK_MUTED} ${CAPTION_WEIGHT} uppercase`, {
|
|
9
13
|
variants: { size: {
|
|
10
14
|
sm: "size-control-sm text-(length:--cue-text-micro)",
|
|
11
|
-
md:
|
|
15
|
+
md: `size-control-md ${CAPTION_SIZE_LABEL}`,
|
|
12
16
|
lg: "size-control-lg text-(length:--cue-text-ui)"
|
|
13
17
|
} },
|
|
14
18
|
defaultVariants: { size: "md" }
|