@mkbabb/glass-ui 3.12.0 → 4.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/CardAction-XH4YBVEK.js +158 -0
- package/dist/{CommandShortcut-CefCj5mt.js → CommandShortcut-DdtWXxOK.js} +58 -53
- package/dist/{ContextMenuSubContent-Bhg4f5jX.js → ContextMenuSubContent-B0Vs6atR.js} +4 -4
- package/dist/{DataTable-CUHMukiQ.js → DataTable-C464Zbqd.js} +99 -97
- package/dist/DialogContent-DDE6pQBU.js +103 -0
- package/dist/{DialogFooter-Gprw8H_A.js → DialogFooter-8eZbdmPc.js} +2 -2
- package/dist/FadingScroll-DwNnvKMs.js +76 -0
- package/dist/{HoverPopover-2LOIW34a.js → HoverPopover-Dpzwvc4t.js} +1 -1
- package/dist/IconChip-BDw1j5mu.js +54 -0
- package/dist/{IconTooltip-Cus0fvK0.js → IconTooltip-DSjasZIt.js} +1 -1
- package/dist/MetricBadge-BpC0R_Ec.js +79 -0
- package/dist/{Notification-DLMhblXR.js → Notification-DKjKsQq8.js} +10 -10
- package/dist/{NumberFieldContent-BbLOh8RU.js → NumberFieldContent-1VtwDSgf.js} +3 -3
- package/dist/PopoverContent-BTorlp--.js +127 -0
- package/dist/{Progress-iEuD9pxG.js → Progress-hAT4gqGH.js} +97 -77
- package/dist/{ScrollingText-BPP84wKo.js → ScrollingText-CUVFTWk2.js} +2 -2
- package/dist/{SelectScrollDownButton-T32cVFeM.js → SelectScrollDownButton-C1jb3b3K.js} +24 -8
- package/dist/{Switch-Ch-k3Rv-.js → Switch-Dr--uLGH.js} +2 -2
- package/dist/{Toaster-1rYWrmAm.js → Toaster-Bm_HQSpc.js} +55 -52
- package/dist/{ToggleGroupItem-COu_4IW4.js → ToggleGroupItem-Dzk9hWsF.js} +18 -22
- package/dist/animated-digit.js +3 -3
- package/dist/api/index.d.ts +10 -4
- package/dist/api.js +1 -1
- package/dist/aurora.js +113 -98
- package/dist/{badge-CaoFJzRb.js → badge-UILT_3pZ.js} +1 -1
- package/dist/badge.js +1 -1
- package/dist/{button-DN39cGqL.js → button-BNDWhAZb.js} +12 -12
- package/dist/button.js +1 -1
- package/dist/card.js +1 -1
- package/dist/carousel.d.ts +1 -1
- package/dist/carousel.js +101 -145
- package/dist/{check-BBKKKSTf.js → check-njhk-vfu.js} +1 -1
- package/dist/{chevron-down-BSkTP2aL.js → chevron-down-DKkxb4VV.js} +1 -1
- package/dist/{chevron-right-sDM0Yvrf.js → chevron-right-CPXbqQQz.js} +1 -1
- package/dist/{chevron-up-CCOD_FTz.js → chevron-up-n_24SqI-.js} +1 -1
- package/dist/coalesceMetric-5qIeZnTx.js +13 -0
- package/dist/collapsible.js +1 -1
- package/dist/{color-C5ls_QF7.js → color-DweYl7pE.js} +9 -7
- package/dist/color-swatch.d.ts +1 -0
- package/dist/color-swatch.js +47 -0
- package/dist/color.js +1 -1
- package/dist/command.js +1 -1
- package/dist/components/custom/animated-digit/AnimatedDigit.vue.d.ts +8 -0
- package/dist/components/custom/aurora/constants/presets.d.ts +16 -45
- package/dist/components/custom/aurora/constants/renderMode.d.ts +2 -0
- package/dist/components/custom/aurora/constants/shaders/mediums.glsl.d.ts +1 -1
- package/dist/components/custom/aurora/constants/shaders/vangogh-medium.glsl.d.ts +1 -0
- package/dist/components/custom/color-swatch/ColorSwatch.vue.d.ts +22 -0
- package/dist/components/custom/color-swatch/index.d.ts +1 -0
- package/dist/components/custom/configurator/Configurator.vue.d.ts +19 -8
- package/dist/components/custom/configurator/ConfiguratorRow.vue.d.ts +16 -0
- package/dist/components/custom/constellation/Constellation.vue.d.ts +23 -143
- package/dist/components/custom/constellation/composables/createConstellationField.d.ts +41 -0
- package/dist/components/custom/constellation/composables/useConstellation.d.ts +26 -0
- package/dist/components/custom/constellation/composables/useConstellationPointer.d.ts +35 -0
- package/dist/components/custom/constellation/constants.d.ts +61 -0
- package/dist/components/custom/constellation/constellationDraw.d.ts +30 -0
- package/dist/components/custom/constellation/constellationField.d.ts +3 -403
- package/dist/components/custom/constellation/constellationInteraction.d.ts +132 -0
- package/dist/components/custom/constellation/constellationTypes.d.ts +369 -0
- package/dist/components/custom/constellation/index.d.ts +5 -2
- package/dist/components/custom/controls/DarkModeToggle.vue.d.ts +11 -0
- package/dist/components/custom/dock/DockRail.vue.d.ts +89 -0
- package/dist/components/custom/dock/DockSection.vue.d.ts +69 -0
- package/dist/components/custom/dock/DockSeparator.vue.d.ts +49 -1
- package/dist/components/custom/dock/DockTabButton.vue.d.ts +5 -6
- package/dist/components/custom/dock/GlassDock.vue.d.ts +5 -118
- package/dist/components/custom/dock/composables/dockMorphContext.d.ts +36 -0
- package/dist/components/custom/dock/composables/index.d.ts +1 -0
- package/dist/components/custom/dock/composables/useDockClickIntegrity.d.ts +23 -0
- package/dist/components/custom/dock/composables/useDockMorphWindow.d.ts +15 -0
- package/dist/components/custom/dock/composables/useDockOrientationMorph.d.ts +44 -0
- package/dist/components/custom/dock/composables/useDockShellProps.d.ts +165 -0
- package/dist/components/custom/dock/composables/useLayerTransition.d.ts +44 -0
- package/dist/components/custom/dock/constants.d.ts +83 -0
- package/dist/components/custom/dock/index.d.ts +5 -0
- package/dist/components/custom/expandable-container/ExpandableContainer.vue.d.ts +15 -37
- package/dist/components/custom/fading-scroll/FadingScroll.vue.d.ts +25 -0
- package/dist/components/custom/fading-scroll/composables/useFadingScroll.d.ts +31 -0
- package/dist/components/custom/fading-scroll/constants.d.ts +19 -0
- package/dist/components/custom/fading-scroll/index.d.ts +2 -0
- package/dist/components/custom/fourier-field/FourierField.vue.d.ts +7 -0
- package/dist/components/custom/fourier-field/index.d.ts +1 -1
- package/dist/components/custom/fourier-field/math.d.ts +34 -0
- package/dist/components/custom/fourier-field/presets.d.ts +54 -0
- package/dist/components/custom/glass-panel/GlassPanel.vue.d.ts +8 -0
- package/dist/components/custom/goo-blob/composables/buildMetaballProgram.d.ts +18 -0
- package/dist/components/custom/goo-blob/composables/uploadBlobUniforms.d.ts +41 -0
- package/dist/components/custom/goo-blob/composables/useBlobPointer.d.ts +4 -3
- package/dist/components/custom/goo-blob/composables/useMetaballRenderer.d.ts +21 -8
- package/dist/components/custom/goo-blob/constants.d.ts +57 -0
- package/dist/components/custom/goo-blob/shaders/metaball-uniforms.glsl.d.ts +1 -0
- package/dist/components/custom/handmark/brush.d.ts +33 -6
- package/dist/components/custom/handmark/{useHandMark.d.ts → composables/useHandMark.d.ts} +6 -4
- package/dist/components/custom/handmark/constants.d.ts +39 -0
- package/dist/components/custom/handmark/geometry.d.ts +14 -12
- package/dist/components/custom/handmark/index.d.ts +8 -2
- package/dist/components/custom/handmark/types.d.ts +9 -0
- package/dist/components/custom/icon-chip/IconChip.vue.d.ts +4 -0
- package/dist/components/custom/icon-chip/index.d.ts +2 -0
- package/dist/components/custom/icon-chip/types.d.ts +72 -0
- package/dist/components/custom/instrument-chassis/InstrumentChassis.vue.d.ts +17 -4
- package/dist/components/custom/labeled-field/LabeledField.vue.d.ts +37 -0
- package/dist/components/custom/labeled-field/LabeledSelect.vue.d.ts +6 -0
- package/dist/components/custom/labeled-field/LabeledSlider.vue.d.ts +6 -0
- package/dist/components/custom/labeled-field/LabeledSwitch.vue.d.ts +6 -0
- package/dist/components/custom/metric-badge/MetricBadge.vue.d.ts +11 -18
- package/dist/components/custom/metric-badge/index.d.ts +1 -0
- package/dist/components/custom/metric-cell/MetricCell.vue.d.ts +15 -4
- package/dist/components/custom/metric-stack/MetricRow.vue.d.ts +6 -4
- package/dist/components/custom/pager-dots/PagerDots.vue.d.ts +39 -0
- package/dist/components/custom/pager-dots/index.d.ts +2 -0
- package/dist/components/custom/tabs/SegmentedTabs.vue.d.ts +20 -25
- package/dist/components/custom/tabs/composables/useTabIndicator.d.ts +30 -21
- package/dist/components/custom/tabs/constants.d.ts +18 -0
- package/dist/components/custom/tabs/index.d.ts +1 -1
- package/dist/components/custom/watercolor-dot/WatercolorDot.vue.d.ts +14 -0
- package/dist/components/ui/_shared/index.d.ts +2 -0
- package/dist/components/ui/_shared/menuItemVariants.d.ts +19 -0
- package/dist/components/ui/_shared/useSurfaceAxis.d.ts +41 -0
- package/dist/components/ui/card/Card.vue.d.ts +16 -4
- package/dist/components/ui/carousel/index.d.ts +0 -1
- package/dist/components/ui/command/Command.vue.d.ts +3 -0
- package/dist/components/ui/dialog/DialogContent.vue.d.ts +8 -3
- package/dist/components/ui/drawer/Drawer.vue.d.ts +1 -0
- package/dist/components/ui/drawer/DrawerContent.vue.d.ts +5 -0
- package/dist/components/ui/dropdown-menu/DropdownMenuSubContent.vue.d.ts +2 -2
- package/dist/components/ui/index.d.ts +0 -1
- package/dist/components/ui/metric-pill/MetricPill.vue.d.ts +6 -3
- package/dist/components/ui/popover/PopoverContent.vue.d.ts +3 -0
- package/dist/components/ui/progress/ProgressSectioned.vue.d.ts +14 -3
- package/dist/components/ui/select/SelectTrigger.vue.d.ts +27 -4
- package/dist/components/ui/sheet/SheetContent.vue.d.ts +6 -0
- package/dist/components/ui/skeleton/Skeleton.vue.d.ts +3 -0
- package/dist/components/ui/slider/index.d.ts +22 -19
- package/dist/components/ui/tabs/TabsIndicator.vue.d.ts +4 -1
- package/dist/components/ui/toast/use-toast.d.ts +2 -2
- package/dist/components/ui/toggle/Toggle.vue.d.ts +1 -1
- package/dist/components/ui/toggle/index.d.ts +1 -1
- package/dist/components/ui/toggle-group/ToggleGroup.vue.d.ts +1 -7
- package/dist/components/ui/toggle-group/ToggleGroupItem.vue.d.ts +1 -3
- package/dist/components/ui/toggle-group/toggleGroupContext.d.ts +0 -13
- package/dist/composables/color/index.d.ts +12 -0
- package/dist/composables/dark/useGlobalDark.d.ts +14 -12
- package/dist/composables/glass/index.d.ts +0 -1
- package/dist/composables/glass/useGlassBackdropLuminance.d.ts +59 -0
- package/dist/composables/glass/useSpecularTracking.d.ts +12 -3
- package/dist/composables/motion/core/index.d.ts +1 -1
- package/dist/composables/motion/curves.d.ts +48 -0
- package/dist/composables/motion/index.d.ts +2 -0
- package/dist/composables/motion/springPresets.d.ts +33 -0
- package/dist/composables/motion/suite.d.ts +2 -0
- package/dist/composables/motion/useLiquidFlex.d.ts +85 -0
- package/dist/composables/motion/useSpringMount.d.ts +1 -1
- package/dist/composables/motion/useViewTransition.d.ts +36 -1
- package/dist/configurator.js +1 -1
- package/dist/confirm-dialog.js +3 -3
- package/dist/constellation.js +373 -261
- package/dist/context-menu.js +2 -2
- package/dist/controls.js +48 -14
- package/dist/dark.js +1 -1
- package/dist/data-table.js +1 -1
- package/dist/dialog.js +2 -2
- package/dist/dock.js +901 -372
- package/dist/dockContext-Bu1Avy-a.js +17 -0
- package/dist/dom.js +5 -5
- package/dist/{dropdown-menu-D77jX6Df.js → dropdown-menu-BJ7E9js_.js} +11 -8
- package/dist/dropdown-menu.js +1 -1
- package/dist/expandable-container.js +44 -81
- package/dist/fading-scroll.d.ts +1 -0
- package/dist/fading-scroll.js +2 -0
- package/dist/forms.js +5 -5
- package/dist/fourier-field.js +140 -104
- package/dist/fourier-math.js +2 -2
- package/dist/glass-panel.js +90 -21
- package/dist/glass-ui.css +1 -1
- package/dist/glass-ui.js +230 -236
- package/dist/goo-blob.js +264 -228
- package/dist/handmark.js +203 -159
- package/dist/header-ribbon.js +1 -1
- package/dist/hover-card.js +1 -1
- package/dist/hover-popover.js +1 -1
- package/dist/icon-chip.d.ts +1 -0
- package/dist/icon-chip.js +2 -0
- package/dist/icon-tooltip.js +1 -1
- package/dist/index.d.ts +3 -5
- package/dist/instrument-chassis.js +1 -1
- package/dist/keyboard.js +1 -1
- package/dist/label.js +1 -1
- package/dist/labeled-field.js +28 -18
- package/dist/{math-DTpRVC0e.js → math-DeuJwLFx.js} +26 -2
- package/dist/{menuItemVariants-CCoBNkU5.js → menuItemVariants-DWRQXBxJ.js} +10 -4
- package/dist/metric-badge.js +1 -1
- package/dist/metric-cell.js +29 -22
- package/dist/metric-stack.js +35 -34
- package/dist/{minimize-2-lcXOuc6V.js → minimize-2-BV31Ob_h.js} +1 -1
- package/dist/motion-core.js +32 -136
- package/dist/motion-curves.d.ts +1 -0
- package/dist/motion-curves.js +130 -0
- package/dist/motion.js +38 -37
- package/dist/notification.js +1 -1
- package/dist/number-field.js +1 -1
- package/dist/pager-dots.d.ts +1 -0
- package/dist/pager-dots.js +91 -0
- package/dist/paper-backdrop.js +1 -1
- package/dist/popover.js +1 -1
- package/dist/progress.js +1 -1
- package/dist/pulse.js +1 -1
- package/dist/reactive.js +2 -2
- package/dist/scrolling-text.js +1 -1
- package/dist/{search-nbkvr2dC.js → search-BSGrf2Sk.js} +1 -1
- package/dist/search.js +10 -10
- package/dist/select.js +3 -3
- package/dist/separator.js +1 -1
- package/dist/sheet-CquRYOAw.js +218 -0
- package/dist/sheet.js +1 -1
- package/dist/{slider-ClgpP7EB.js → slider-DQ95MET2.js} +8 -8
- package/dist/slider.js +1 -1
- package/dist/sortable-list.js +3 -3
- package/dist/springPresets-WXaLbu8u.js +40 -0
- package/dist/stacked-icons.js +6 -6
- package/dist/styles/animations.css +25 -125
- package/dist/styles/cards.css +55 -0
- package/dist/styles/components.css +4 -1
- package/dist/styles/configurator.css +77 -0
- package/dist/styles/dock/density.css +19 -0
- package/dist/styles/dock/layer-group.css +83 -25
- package/dist/styles/dock/layers.css +23 -1
- package/dist/styles/dock/morph-bridge.css +123 -0
- package/dist/styles/dock/morph.css +175 -45
- package/dist/styles/dock/overflow.css +66 -1
- package/dist/styles/dock/rail-extend.css +397 -0
- package/dist/styles/dock/section.css +59 -0
- package/dist/styles/dock/shell.css +97 -110
- package/dist/styles/dock-controls/dark-mode-toggle.css +109 -0
- package/dist/styles/dock-controls/icon-button.css +143 -0
- package/dist/styles/dock-controls/tab-button.css +143 -0
- package/dist/styles/dock-controls/touch-floor.css +94 -0
- package/dist/styles/dock-controls/triggers.css +135 -0
- package/dist/styles/dock-controls.css +30 -595
- package/dist/styles/dock.css +8 -3
- package/dist/styles/drawer.css +48 -0
- package/dist/styles/feedback-tone.css +104 -0
- package/dist/styles/floating-panel.css +17 -0
- package/dist/styles/glass/a11y-fallback.css +245 -0
- package/dist/styles/glass/ladder.css +383 -0
- package/dist/styles/glass/material.css +238 -0
- package/dist/styles/glass/progress-rail.css +78 -0
- package/dist/styles/glass/squircle.css +66 -0
- package/dist/styles/glass/surface-axis.css +113 -0
- package/dist/styles/glass/surfaces.css +382 -0
- package/dist/styles/glass-refract.css +2 -0
- package/dist/styles/glass.css +34 -1188
- package/dist/styles/hover-popover.css +2 -0
- package/dist/styles/icon-chip.css +149 -0
- package/dist/styles/index.css +94 -18
- package/dist/styles/instrument-chassis.css +46 -0
- package/dist/styles/menu.css +127 -0
- package/dist/styles/paper.css +2 -68
- package/dist/styles/segmented-tabs.css +346 -0
- package/dist/styles/select.css +50 -0
- package/dist/styles/theme/bridges.css +347 -0
- package/dist/styles/theme/dark.css +7 -0
- package/dist/styles/theme/literals.css +94 -0
- package/dist/styles/theme/radius.css +95 -0
- package/dist/styles/theme.css +26 -529
- package/dist/styles/tokens/color-radius.css +287 -0
- package/dist/styles/tokens/dark-arm.css +308 -0
- package/dist/styles/tokens/glass.css +500 -0
- package/dist/styles/tokens/light-dark.css +187 -0
- package/dist/styles/tokens/offsets-sizing.css +562 -0
- package/dist/styles/tokens/property-regs.css +162 -0
- package/dist/styles/tokens/scale-paper.css +409 -0
- package/dist/styles/tokens/scheme-motion.css +352 -0
- package/dist/styles/tokens/shadow.css +166 -0
- package/dist/styles/tokens.css +22 -2360
- package/dist/styles/transitions.css +7 -7
- package/dist/styles/typography/scale.css +153 -0
- package/dist/styles/typography/semantic.css +220 -0
- package/dist/styles/typography/utilities.css +159 -0
- package/dist/styles/typography.css +23 -453
- package/dist/styles/utilities/a11y-overrides.css +169 -0
- package/dist/styles/utilities/animate.css +26 -0
- package/dist/styles/utilities/base.css +541 -0
- package/dist/styles/utilities/btn.css +218 -0
- package/dist/styles/utilities/components.css +317 -0
- package/dist/styles/utilities.css +19 -1318
- package/dist/styles/view-transition.css +4 -52
- package/dist/switch.js +1 -1
- package/dist/tabs.js +161 -181
- package/dist/timeline.js +2 -2
- package/dist/toast.js +1 -1
- package/dist/toggle-chip.js +3 -1
- package/dist/toggle-group.js +1 -1
- package/dist/tooltip.js +1 -1
- package/dist/typewriter.js +1 -1
- package/dist/{useAnimatedNumber-Bcpy5Etf.js → useAnimatedNumber-C_3wZLx4.js} +1 -1
- package/dist/useConfiguratorState-kiIlun8I.js +303 -0
- package/dist/useLiquidFlex-C12hXwOZ.js +30 -0
- package/dist/useRAFLoop-CdwJ7284.js +109 -0
- package/dist/{useScrollProgress-CffFGLa5.js → useScrollProgress-D7bYU2RK.js} +1 -1
- package/dist/useSpecularTracking-Bo5su68i.js +32 -0
- package/dist/useSpringMount-CvopqiFr.js +108 -0
- package/dist/useSurfaceAxis-CMnF2zHb.js +7 -0
- package/dist/{useTouchGate-WFyJYsth.js → useTouchGate-28Tk2-t2.js} +1 -1
- package/dist/useViewTransition-COsPjQVZ.js +47 -0
- package/dist/utils/coalesceMetric.d.ts +29 -0
- package/dist/utils/index.d.ts +1 -0
- package/dist/vReveal-D9k0jADx.js +10 -0
- package/dist/watercolor-dot.js +22 -13
- package/dist/{x-Dfsegz9Y.js → x-BUwTKe50.js} +1 -1
- package/package.json +134 -50
- package/src/styles/animations.css +25 -125
- package/src/styles/cards.css +53 -0
- package/src/styles/configurator.css +77 -0
- package/src/styles/dock/density.css +19 -0
- package/src/styles/dock/layer-group.css +83 -25
- package/src/styles/dock/layers.css +23 -1
- package/src/styles/dock/morph-bridge.css +123 -0
- package/src/styles/dock/morph.css +175 -45
- package/src/styles/dock/overflow.css +66 -1
- package/src/styles/dock/rail-extend.css +397 -0
- package/src/styles/dock/section.css +59 -0
- package/src/styles/dock/shell.css +97 -110
- package/src/styles/dock-controls/dark-mode-toggle.css +109 -0
- package/src/styles/dock-controls/icon-button.css +143 -0
- package/src/styles/dock-controls/tab-button.css +143 -0
- package/src/styles/dock-controls/touch-floor.css +94 -0
- package/src/styles/dock-controls/triggers.css +135 -0
- package/src/styles/dock-controls.css +30 -595
- package/src/styles/dock.css +8 -3
- package/src/styles/drawer.css +42 -0
- package/src/styles/feedback-tone.css +104 -0
- package/src/styles/floating-panel.css +15 -0
- package/src/styles/glass/a11y-fallback.css +245 -0
- package/src/styles/glass/ladder.css +383 -0
- package/src/styles/glass/material.css +238 -0
- package/src/styles/glass/progress-rail.css +78 -0
- package/src/styles/glass/squircle.css +66 -0
- package/src/styles/glass/surface-axis.css +113 -0
- package/src/styles/glass/surfaces.css +382 -0
- package/src/styles/glass.css +34 -1188
- package/src/styles/icon-chip.css +149 -0
- package/src/styles/index.css +93 -17
- package/src/styles/instrument-chassis.css +42 -0
- package/src/styles/menu.css +127 -0
- package/src/styles/paper.css +2 -68
- package/src/styles/segmented-tabs.css +340 -0
- package/src/styles/select.css +50 -0
- package/src/styles/theme/bridges.css +347 -0
- package/src/styles/theme/dark.css +7 -0
- package/src/styles/theme/literals.css +94 -0
- package/src/styles/theme/radius.css +95 -0
- package/src/styles/theme.css +26 -529
- package/src/styles/tokens/color-radius.css +287 -0
- package/src/styles/tokens/dark-arm.css +308 -0
- package/src/styles/tokens/glass.css +500 -0
- package/src/styles/tokens/light-dark.css +187 -0
- package/src/styles/tokens/offsets-sizing.css +562 -0
- package/src/styles/tokens/property-regs.css +162 -0
- package/src/styles/tokens/scale-paper.css +409 -0
- package/src/styles/tokens/scheme-motion.css +352 -0
- package/src/styles/tokens/shadow.css +166 -0
- package/src/styles/tokens.css +22 -2360
- package/src/styles/transitions.css +7 -7
- package/src/styles/typography/scale.css +153 -0
- package/src/styles/typography/semantic.css +220 -0
- package/src/styles/typography/utilities.css +159 -0
- package/src/styles/typography.css +23 -453
- package/src/styles/utilities/a11y-overrides.css +169 -0
- package/src/styles/utilities/animate.css +26 -0
- package/src/styles/utilities/base.css +541 -0
- package/src/styles/utilities/btn.css +218 -0
- package/src/styles/utilities/components.css +317 -0
- package/src/styles/utilities.css +19 -1318
- package/src/styles/view-transition.css +4 -52
- package/dist/CardAction-DuArVky-.js +0 -157
- package/dist/DeckProgress-Dmk4_AKN.js +0 -23
- package/dist/DialogContent-BRkT1cjP.js +0 -100
- package/dist/InstrumentRail-CUJ05YVG.js +0 -44
- package/dist/MetricBadge-BZVWIxNy.js +0 -80
- package/dist/PopoverContent-BId6ggf_.js +0 -121
- package/dist/TabsList-B8CVOQPC.js +0 -101
- package/dist/components/custom/deck-progress/DeckProgress.vue.d.ts +0 -27
- package/dist/components/custom/deck-progress/index.d.ts +0 -2
- package/dist/components/custom/dialog-native/GlassDialogNative.vue.d.ts +0 -57
- package/dist/components/custom/dialog-native/index.d.ts +0 -1
- package/dist/components/custom/instrument-rail/InstrumentRail.vue.d.ts +0 -91
- package/dist/components/custom/instrument-rail/index.d.ts +0 -2
- package/dist/components/ui/carousel/CarouselDots.vue.d.ts +0 -4
- package/dist/composables/motion/useRouteTransition.d.ts +0 -42
- package/dist/deck-progress.d.ts +0 -1
- package/dist/deck-progress.js +0 -2
- package/dist/dockContext-BKeIMmNk.js +0 -9
- package/dist/instrument-rail.d.ts +0 -1
- package/dist/instrument-rail.js +0 -2
- package/dist/sheet-VZEtNFvO.js +0 -214
- package/dist/styles/instrument-rail.css +0 -127
- package/dist/useConfiguratorState-DxAqksK6.js +0 -287
- package/dist/useGlassRenderer-D7YGOYiM.js +0 -69
- package/dist/useSpecularTracking-BVRZsRHA.js +0 -26
- package/dist/useSpringMount-BJSHcLl3.js +0 -113
- package/dist/useViewTransition-DaN5Zrox.js +0 -21
- package/dist/vReveal-zUIQk-rJ.js +0 -53
- package/src/styles/instrument-rail.css +0 -127
- /package/dist/{CollapsibleContent-CP9qF1v4.js → CollapsibleContent-C_s6fG7r.js} +0 -0
- /package/dist/{ContextMenuContent-DDa0v27s.js → ContextMenuContent-ON3x7cuk.js} +0 -0
- /package/dist/{HoverCardContent-B6CcQ8He.js → HoverCardContent-DkMaQzH5.js} +0 -0
- /package/dist/{Input-xuDwALQR.js → Input-DVG_J0ne.js} +0 -0
- /package/dist/{InstrumentChassis-C2f6cBaQ.js → InstrumentChassis-UUJX0-mW.js} +0 -0
- /package/dist/{Label-zRfbQdCn.js → Label-Ck9SWEKM.js} +0 -0
- /package/dist/{ModalOverlay-B1GkAjNb.js → ModalOverlay-CkPRRgl_.js} +0 -0
- /package/dist/{PaperBackdrop-CqwjnfLv.js → PaperBackdrop-nBKe0vkB.js} +0 -0
- /package/dist/{SelectGroup-BFiod7X2.js → SelectGroup-Dcczq44n.js} +0 -0
- /package/dist/{SelectSeparator-C4Ql0gzV.js → SelectSeparator-DK2y1Bun.js} +0 -0
- /package/dist/{Separator-D7sD7RKj.js → Separator-BArl4OaB.js} +0 -0
- /package/dist/{TooltipProvider-CmZzCuaG.js → TooltipProvider-B3MkB_8P.js} +0 -0
- /package/dist/{_plugin-vue_export-helper-ok8pgSl5.js → _plugin-vue_export-helper-CBt_VvXa.js} +0 -0
- /package/dist/{compile-BOXjLUxu.js → compile-EXXzEr1q.js} +0 -0
- /package/dist/{constants-yKeKnE84.js → constants-BPOqYJAm.js} +0 -0
- /package/dist/{createContext-B44Sah_H.js → createContext-B2RaZ-b8.js} +0 -0
- /package/dist/{createLucideIcon-B6uNAU9G.js → createLucideIcon-DydS2qgk.js} +0 -0
- /package/dist/{presets-BP_ALM0m.js → presets-BW2b-fr1.js} +0 -0
- /package/dist/{prng-D27-B3tK.js → prng-Cg22zv8g.js} +0 -0
- /package/dist/{supportsCssTimeline-C5oe0lnD.js → supportsCssTimeline-BWenxvHU.js} +0 -0
- /package/dist/{useGlobalDark-CAhOXNLO.js → useGlobalDark-C28t0VWJ.js} +0 -0
- /package/dist/{useIntersectionPause-Cck5Uxk8.js → useIntersectionPause-Bj4sPkMh.js} +0 -0
- /package/dist/{useInterval-Dsmqwi03.js → useInterval-CNdua40W.js} +0 -0
- /package/dist/{useKeyboardShortcuts-CyIYrndH.js → useKeyboardShortcuts-BXWXOZ-9.js} +0 -0
- /package/dist/{useResizeObserver-CWCbk5Px.js → useResizeObserver-V6nq5gJb.js} +0 -0
- /package/dist/{useResolveTokenColor-r9pnNjqK.js → useResolveTokenColor-NUG2zYAW.js} +0 -0
- /package/dist/{useSortable-C8ReQ50P.js → useSortable-BVqlJRBR.js} +0 -0
- /package/dist/{useTextHighlight-CWEi25hf.js → useTextHighlight-NmBM5V_4.js} +0 -0
- /package/dist/{useTimer-3xqf_54b.js → useTimer-B_PAasDL.js} +0 -0
- /package/dist/{useUserInvalidAria-DoJKMZ3s.js → useUserInvalidAria-CDfJuakL.js} +0 -0
- /package/dist/{useViewportReady-RIr5Wgkh.js → useViewportReady-CvBcCYDf.js} +0 -0
package/dist/dock.js
CHANGED
|
@@ -1,15 +1,21 @@
|
|
|
1
1
|
import { t as e } from "./cn-DJXf4yaB.js";
|
|
2
|
-
import { t } from "./createLucideIcon-
|
|
3
|
-
import { t as n } from "./chevron-down-
|
|
4
|
-
import { t as r } from "./
|
|
5
|
-
import { t as i } from "./
|
|
6
|
-
import {
|
|
7
|
-
import {
|
|
8
|
-
import {
|
|
9
|
-
import {
|
|
10
|
-
import {
|
|
11
|
-
import {
|
|
12
|
-
|
|
2
|
+
import { t } from "./createLucideIcon-DydS2qgk.js";
|
|
3
|
+
import { t as n } from "./chevron-down-DKkxb4VV.js";
|
|
4
|
+
import { t as r } from "./chevron-right-CPXbqQQz.js";
|
|
5
|
+
import { t as i } from "./useSpecularTracking-Bo5su68i.js";
|
|
6
|
+
import { t as a } from "./useResizeObserver-V6nq5gJb.js";
|
|
7
|
+
import { t as o } from "./useTouchGate-28Tk2-t2.js";
|
|
8
|
+
import { n as s } from "./useResolveTokenColor-NUG2zYAW.js";
|
|
9
|
+
import { n as c, t as l } from "./createContext-B2RaZ-b8.js";
|
|
10
|
+
import { a as u, c as d, i as f, n as p, o as m, r as h, s as g, t as _ } from "./dockContext-Bu1Avy-a.js";
|
|
11
|
+
import { t as v } from "./FadingScroll-DwNnvKMs.js";
|
|
12
|
+
import { t as y } from "./useLiquidFlex-C12hXwOZ.js";
|
|
13
|
+
import { t as b } from "./useIntersectionPause-Bj4sPkMh.js";
|
|
14
|
+
import { t as x } from "./useRAFLoop-CdwJ7284.js";
|
|
15
|
+
import { Fragment as S, computed as C, createBlock as w, createCommentVNode as T, createElementBlock as E, createElementVNode as D, createVNode as O, defineComponent as k, mergeModels as A, mergeProps as j, nextTick as M, normalizeClass as N, normalizeStyle as P, onBeforeUnmount as F, onMounted as I, onScopeDispose as L, onUnmounted as R, openBlock as z, readonly as B, ref as V, renderList as H, renderSlot as U, resolveDynamicComponent as W, toDisplayString as G, unref as K, useId as ee, useModel as q, useSlots as te, useTemplateRef as J, watch as Y, withCtx as X } from "vue";
|
|
16
|
+
import { DropdownMenuTrigger as Z, Primitive as ne, SelectIcon as re, SelectTrigger as ie, TabsIndicator as ae, TabsList as Q, TabsRoot as oe, TabsTrigger as se, useForwardProps as ce, useForwardPropsEmits as le } from "reka-ui";
|
|
17
|
+
import { SpringProgress as ue } from "@mkbabb/keyframes.js";
|
|
18
|
+
var de = t("pause", [["rect", {
|
|
13
19
|
x: "14",
|
|
14
20
|
y: "3",
|
|
15
21
|
width: "5",
|
|
@@ -23,152 +29,276 @@ var K = t("pause", [["rect", {
|
|
|
23
29
|
height: "18",
|
|
24
30
|
rx: "1",
|
|
25
31
|
key: "1wsw3u"
|
|
26
|
-
}]]),
|
|
32
|
+
}]]), fe = t("play", [["path", {
|
|
27
33
|
d: "M5 5a2 2 0 0 1 3.008-1.728l11.997 6.998a2 2 0 0 1 .003 3.458l-12 7A2 2 0 0 1 5 19z",
|
|
28
34
|
key: "10ikf1"
|
|
29
|
-
}]]),
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
35
|
+
}]]), pe = "(prefers-reduced-motion: reduce)", $ = 32;
|
|
36
|
+
function me(e) {
|
|
37
|
+
return typeof HTMLCanvasElement < "u" && e instanceof HTMLCanvasElement;
|
|
38
|
+
}
|
|
39
|
+
function he(e) {
|
|
40
|
+
let t = e / 255;
|
|
41
|
+
return t <= .03928 ? t / 12.92 : ((t + .055) / 1.055) ** 2.4;
|
|
42
|
+
}
|
|
43
|
+
function ge(e, t, n) {
|
|
44
|
+
return .2126 * he(e) + .7152 * he(t) + .0722 * he(n);
|
|
45
|
+
}
|
|
46
|
+
function _e(e) {
|
|
47
|
+
let t = e.match(/rgba?\(\s*([\d.]+)[,\s]+([\d.]+)[,\s]+([\d.]+)(?:[,\s/]+([\d.]+))?/i);
|
|
48
|
+
return t ? [
|
|
49
|
+
Number(t[1]),
|
|
50
|
+
Number(t[2]),
|
|
51
|
+
Number(t[3]),
|
|
52
|
+
t[4] === void 0 ? 1 : Number(t[4])
|
|
53
|
+
] : null;
|
|
54
|
+
}
|
|
55
|
+
function ve(e) {
|
|
56
|
+
if (!e) return null;
|
|
57
|
+
if (me(e)) return e;
|
|
58
|
+
if (typeof e == "function") {
|
|
59
|
+
let t = e();
|
|
60
|
+
return me(t) ? t : null;
|
|
39
61
|
}
|
|
40
|
-
|
|
62
|
+
if (typeof e == "string" && typeof document < "u") {
|
|
63
|
+
let t = document.querySelector(e);
|
|
64
|
+
return me(t) ? t : null;
|
|
65
|
+
}
|
|
66
|
+
return null;
|
|
67
|
+
}
|
|
68
|
+
function ye(e, t = {}) {
|
|
69
|
+
let { lightThreshold: n = .6, minSampleIntervalMs: r = 250, writeBucket: i = !0 } = t, o = Math.max(250, r), c = V(null), l = V(null);
|
|
70
|
+
if (typeof window > "u") return {
|
|
71
|
+
luma: B(c),
|
|
72
|
+
bucket: B(l),
|
|
73
|
+
sampleNow: () => {},
|
|
74
|
+
dispose: () => {}
|
|
75
|
+
};
|
|
76
|
+
let u = window.matchMedia(pe), d = u.matches, f = null, p = null;
|
|
77
|
+
function m() {
|
|
78
|
+
return f || (f = document.createElement("canvas"), f.width = $, f.height = $), p ||= f.getContext("2d", { willReadFrequently: !0 }), p;
|
|
79
|
+
}
|
|
80
|
+
function h() {
|
|
81
|
+
return t.live === void 0 ? e.value?.dataset.glassSample === "live" : t.live;
|
|
82
|
+
}
|
|
83
|
+
function g(e) {
|
|
84
|
+
let n = ve(t.backgroundCanvas);
|
|
85
|
+
if (!n || n.width === 0 || n.height === 0) return null;
|
|
86
|
+
let r = m();
|
|
87
|
+
if (!r) return null;
|
|
88
|
+
let i = e.getBoundingClientRect(), a = n.getBoundingClientRect();
|
|
89
|
+
if (a.width === 0 || a.height === 0) return null;
|
|
90
|
+
let o = n.width / a.width, s = n.height / a.height, c = Math.max(0, (i.left - a.left) * o), l = Math.max(0, (i.top - a.top) * s), u = Math.min(n.width - c, Math.max(1, i.width * o)), d = Math.min(n.height - l, Math.max(1, i.height * s));
|
|
91
|
+
if (u <= 0 || d <= 0) return null;
|
|
92
|
+
try {
|
|
93
|
+
r.clearRect(0, 0, $, $), r.drawImage(n, c, l, u, d, 0, 0, $, $);
|
|
94
|
+
let e = r.getImageData(0, 0, $, $).data, t = 0, i = 0;
|
|
95
|
+
for (let n = 0; n < e.length; n += 4) {
|
|
96
|
+
let r = e[n + 3] / 255, a = e[n] * r + 255 * (1 - r), o = e[n + 1] * r + 255 * (1 - r), s = e[n + 2] * r + 255 * (1 - r);
|
|
97
|
+
t += ge(a, o, s), i++;
|
|
98
|
+
}
|
|
99
|
+
return i > 0 ? t / i : null;
|
|
100
|
+
} catch {
|
|
101
|
+
return null;
|
|
102
|
+
}
|
|
103
|
+
}
|
|
104
|
+
function _(e) {
|
|
105
|
+
let t = e.getBoundingClientRect(), n = t.left + t.width / 2, r = t.top + t.height / 2, i = document.elementsFromPoint(n, r);
|
|
106
|
+
for (let t of i) {
|
|
107
|
+
if (!(t instanceof HTMLElement) || t === e || e.contains(t)) continue;
|
|
108
|
+
let n = getComputedStyle(t).backgroundColor, r = _e(s(n, e));
|
|
109
|
+
if (r && !(r[3] < .5)) return ge(r[0], r[1], r[2]);
|
|
110
|
+
}
|
|
111
|
+
let a = _e(s(getComputedStyle(document.body).backgroundColor, e));
|
|
112
|
+
return a ? ge(a[0], a[1], a[2]) : null;
|
|
113
|
+
}
|
|
114
|
+
function v(t) {
|
|
115
|
+
c.value = t;
|
|
116
|
+
let r = e.value;
|
|
117
|
+
if (r && (r.style.setProperty("--glass-backdrop-luma", t.toFixed(3)), i)) {
|
|
118
|
+
let e = t >= n ? "light" : "dark";
|
|
119
|
+
l.value = e, r.style.setProperty("--glass-backdrop", e);
|
|
120
|
+
}
|
|
121
|
+
}
|
|
122
|
+
let y = 0;
|
|
123
|
+
function S() {
|
|
124
|
+
let t = e.value;
|
|
125
|
+
if (!t) return;
|
|
126
|
+
let n = h() ? g(t) ?? _(t) : _(t);
|
|
127
|
+
n !== null && v(n), y = typeof performance < "u" ? performance.now() : Date.now();
|
|
128
|
+
}
|
|
129
|
+
let C = x(({ now: e }) => {
|
|
130
|
+
d || e - y < o || S();
|
|
131
|
+
}, {
|
|
132
|
+
immediate: !1,
|
|
133
|
+
pauseWhenHidden: !0,
|
|
134
|
+
respectReducedMotion: !0
|
|
135
|
+
}), w = b(() => e.value, {
|
|
136
|
+
pause: () => C.pause(),
|
|
137
|
+
resume: () => {
|
|
138
|
+
h() && !d && C.resume();
|
|
139
|
+
}
|
|
140
|
+
}, { rootMargin: "200px" }), T = a(e, () => S());
|
|
141
|
+
function E() {
|
|
142
|
+
d = u.matches, d ? (C.stop(), S()) : h() && C.start();
|
|
143
|
+
}
|
|
144
|
+
let D = () => E();
|
|
145
|
+
typeof u.addEventListener == "function" && u.addEventListener("change", D);
|
|
146
|
+
let O = Y(() => e.value, (e) => {
|
|
147
|
+
e && (S(), E());
|
|
148
|
+
}, {
|
|
149
|
+
immediate: !0,
|
|
150
|
+
flush: "post"
|
|
151
|
+
});
|
|
152
|
+
function k() {
|
|
153
|
+
O(), C.dispose(), w.dispose(), T.stop(), typeof u.removeEventListener == "function" && u.removeEventListener("change", D), f = null, p = null;
|
|
154
|
+
}
|
|
155
|
+
return L(k), {
|
|
156
|
+
luma: B(c),
|
|
157
|
+
bucket: B(l),
|
|
158
|
+
sampleNow: S,
|
|
159
|
+
dispose: k
|
|
160
|
+
};
|
|
161
|
+
}
|
|
41
162
|
//#endregion
|
|
42
163
|
//#region src/components/custom/dock/composables/isTeleportedTarget.ts
|
|
43
|
-
function
|
|
164
|
+
function be(e, t) {
|
|
44
165
|
if (!(e instanceof Element)) return !1;
|
|
45
166
|
let n = e.closest("[data-glass-dock-portal]");
|
|
46
167
|
return n ? t ? n.getAttribute("data-glass-dock-owner") === t : !0 : !1;
|
|
47
168
|
}
|
|
48
169
|
//#endregion
|
|
49
170
|
//#region src/components/custom/dock/composables/useDockState.ts
|
|
50
|
-
function
|
|
51
|
-
let { collapseDelay: t = 2500, rootEl: n, alwaysExpanded: r = !1, isTransitioning: i, dockId: a, onStateChange: o } = e, s = () => typeof r == "boolean" ? r : r.value, c = s(), l =
|
|
52
|
-
function
|
|
53
|
-
|
|
171
|
+
function xe(e) {
|
|
172
|
+
let { collapseDelay: t = 2500, rootEl: n, alwaysExpanded: r = !1, isTransitioning: i, dockId: a, onStateChange: o } = e, s = () => typeof r == "boolean" ? r : r.value, c = s(), l = V(c ? "pinned" : "collapsed"), u = V(c), d = V(c), f = null, p = V(0), m = C(() => p.value > 0), h = null, g = null, _ = !1, v = null;
|
|
173
|
+
function y() {
|
|
174
|
+
v &&= (clearTimeout(v), null);
|
|
54
175
|
}
|
|
55
|
-
function
|
|
56
|
-
|
|
176
|
+
function b(e) {
|
|
177
|
+
if (!e) return !1;
|
|
178
|
+
let t = n.value;
|
|
179
|
+
if (!t || typeof t.getBoundingClientRect != "function" || !t.hasAttribute("data-morphing")) return !1;
|
|
180
|
+
let r = t.getBoundingClientRect();
|
|
181
|
+
return e.clientX >= r.left && e.clientX <= r.right && e.clientY >= r.top && e.clientY <= r.bottom ? e.clientX - r.left <= 24 || r.right - e.clientX <= 24 || e.clientY - r.top <= 24 || r.bottom - e.clientY <= 24 : !1;
|
|
57
182
|
}
|
|
183
|
+
let x = l.value;
|
|
58
184
|
function S() {
|
|
59
|
-
|
|
60
|
-
}
|
|
61
|
-
function C() {
|
|
62
|
-
S(), h?.();
|
|
185
|
+
s() && (l.value = "pinned"), u.value = l.value !== "collapsed", d.value = l.value === "pinned", o && x !== l.value && o(l.value, x), x = l.value;
|
|
63
186
|
}
|
|
64
187
|
function w() {
|
|
65
|
-
|
|
66
|
-
T(), l.value = "collapsed", b();
|
|
67
|
-
}, t));
|
|
188
|
+
f &&= (clearTimeout(f), null);
|
|
68
189
|
}
|
|
69
190
|
function T() {
|
|
191
|
+
g !== null && (cancelAnimationFrame(g), g = null);
|
|
192
|
+
}
|
|
193
|
+
function E() {
|
|
194
|
+
T(), h?.();
|
|
195
|
+
}
|
|
196
|
+
function D() {
|
|
197
|
+
s() || p.value > 0 || (w(), f = setTimeout(() => {
|
|
198
|
+
O(), l.value = "collapsed", S();
|
|
199
|
+
}, t));
|
|
200
|
+
}
|
|
201
|
+
function O() {
|
|
70
202
|
typeof document > "u" || typeof PointerEvent > "u" || document.body.dispatchEvent(new PointerEvent("pointerdown", {
|
|
71
203
|
bubbles: !0,
|
|
72
204
|
composed: !0
|
|
73
205
|
}));
|
|
74
206
|
}
|
|
75
|
-
function
|
|
207
|
+
function k() {
|
|
76
208
|
if (s()) {
|
|
77
|
-
l.value = "pinned",
|
|
209
|
+
l.value = "pinned", S();
|
|
78
210
|
return;
|
|
79
211
|
}
|
|
80
|
-
|
|
212
|
+
_ ||= (_ = !0, w(), y(), O(), l.value = "collapsed", S(), !1);
|
|
81
213
|
}
|
|
82
|
-
function
|
|
214
|
+
function A() {
|
|
83
215
|
if (s()) {
|
|
84
|
-
l.value = "pinned",
|
|
216
|
+
l.value = "pinned", S();
|
|
85
217
|
return;
|
|
86
218
|
}
|
|
87
|
-
|
|
219
|
+
w(), y(), l.value = "hover", S();
|
|
88
220
|
}
|
|
89
|
-
function
|
|
90
|
-
s() || (
|
|
221
|
+
function j() {
|
|
222
|
+
s() || (w(), l.value === "collapsed" && (y(), v = setTimeout(() => {
|
|
223
|
+
v = null, !s() && l.value === "collapsed" && (l.value = "hover", S());
|
|
224
|
+
}, 60)));
|
|
91
225
|
}
|
|
92
|
-
function
|
|
93
|
-
if (!s() && l.value === "hover") {
|
|
226
|
+
function M(e) {
|
|
227
|
+
if (!s() && (y(), l.value === "hover")) {
|
|
94
228
|
if (p.value > 0) return;
|
|
95
229
|
if (e) {
|
|
96
230
|
let t = n.value;
|
|
97
|
-
if (t && e.relatedTarget instanceof Node && t.contains(e.relatedTarget) ||
|
|
231
|
+
if (t && e.relatedTarget instanceof Node && t.contains(e.relatedTarget) || be(e.relatedTarget, a) || b(e)) return;
|
|
98
232
|
}
|
|
99
|
-
|
|
233
|
+
D();
|
|
100
234
|
}
|
|
101
235
|
}
|
|
102
|
-
function
|
|
103
|
-
s() || (
|
|
236
|
+
function N() {
|
|
237
|
+
s() || (w(), l.value === "collapsed" && (l.value = "hover", S()));
|
|
104
238
|
}
|
|
105
|
-
function
|
|
239
|
+
function P(e) {
|
|
106
240
|
if (s() || l.value !== "hover" || p.value > 0) return;
|
|
107
241
|
let t = e.currentTarget;
|
|
108
|
-
e.relatedTarget && t.contains(e.relatedTarget) ||
|
|
242
|
+
e.relatedTarget && t.contains(e.relatedTarget) || be(e.relatedTarget, a) || D();
|
|
109
243
|
}
|
|
110
|
-
function
|
|
244
|
+
function F() {
|
|
111
245
|
if (s()) {
|
|
112
|
-
l.value = "pinned",
|
|
246
|
+
l.value = "pinned", S();
|
|
113
247
|
return;
|
|
114
248
|
}
|
|
115
|
-
|
|
249
|
+
w(), y(), l.value = "pinned", S();
|
|
116
250
|
}
|
|
117
|
-
function
|
|
118
|
-
p.value++,
|
|
251
|
+
function I() {
|
|
252
|
+
p.value++, w();
|
|
119
253
|
}
|
|
120
|
-
function
|
|
121
|
-
p.value = Math.max(0, p.value - 1), p.value === 0 && l.value === "hover" && (
|
|
122
|
-
p.value === 0 && l.value === "hover" &&
|
|
254
|
+
function L() {
|
|
255
|
+
p.value = Math.max(0, p.value - 1), p.value === 0 && l.value === "hover" && (w(), f = setTimeout(() => {
|
|
256
|
+
p.value === 0 && l.value === "hover" && D();
|
|
123
257
|
}, Math.min(t, 800)));
|
|
124
258
|
}
|
|
125
|
-
function
|
|
259
|
+
function z(e) {
|
|
126
260
|
if (s() || i?.value) return;
|
|
127
261
|
let t = n.value;
|
|
128
|
-
!t || t.contains(e.target) ||
|
|
262
|
+
!t || t.contains(e.target) || be(e.target, a) || k();
|
|
129
263
|
}
|
|
130
|
-
return
|
|
131
|
-
e ? (
|
|
132
|
-
|
|
133
|
-
document.removeEventListener("pointerdown",
|
|
264
|
+
return Y(u, (e) => {
|
|
265
|
+
e ? (E(), g = requestAnimationFrame(() => {
|
|
266
|
+
g = null, u.value && (document.addEventListener("pointerdown", z, !0), h = () => {
|
|
267
|
+
document.removeEventListener("pointerdown", z, !0), h = null;
|
|
134
268
|
});
|
|
135
|
-
})) :
|
|
136
|
-
}), typeof r == "boolean" ? r && (l.value = "pinned",
|
|
269
|
+
})) : E();
|
|
270
|
+
}), typeof r == "boolean" ? r && (l.value = "pinned", S()) : Y(r, (e) => {
|
|
137
271
|
if (e) {
|
|
138
|
-
|
|
272
|
+
w(), l.value = "pinned", S();
|
|
139
273
|
return;
|
|
140
274
|
}
|
|
141
|
-
l.value = "collapsed",
|
|
142
|
-
}, { immediate: !0 }),
|
|
143
|
-
|
|
275
|
+
l.value = "collapsed", S();
|
|
276
|
+
}, { immediate: !0 }), R(() => {
|
|
277
|
+
w(), y(), E();
|
|
144
278
|
}), {
|
|
145
279
|
state: l,
|
|
146
280
|
expanded: u,
|
|
147
281
|
isPinned: d,
|
|
148
282
|
isHeld: m,
|
|
149
|
-
onMouseEnter:
|
|
150
|
-
onMouseLeave:
|
|
151
|
-
onFocusIn:
|
|
152
|
-
onFocusOut:
|
|
153
|
-
onClickCollapsed:
|
|
154
|
-
keepOpen:
|
|
155
|
-
release:
|
|
156
|
-
expand:
|
|
157
|
-
collapse:
|
|
283
|
+
onMouseEnter: j,
|
|
284
|
+
onMouseLeave: M,
|
|
285
|
+
onFocusIn: N,
|
|
286
|
+
onFocusOut: P,
|
|
287
|
+
onClickCollapsed: F,
|
|
288
|
+
keepOpen: I,
|
|
289
|
+
release: L,
|
|
290
|
+
expand: A,
|
|
291
|
+
collapse: k
|
|
158
292
|
};
|
|
159
293
|
}
|
|
160
294
|
//#endregion
|
|
161
295
|
//#region src/components/custom/dock/composables/dockMorphContext.ts
|
|
162
|
-
var
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
}, Y = o("glass-ui:dock-morph-context");
|
|
166
|
-
Y.KEY;
|
|
167
|
-
function ue(e) {
|
|
168
|
-
Y.provide(e);
|
|
296
|
+
var Se = l(m), { KEY: Ce } = Se;
|
|
297
|
+
function we(e) {
|
|
298
|
+
Se.provide(e);
|
|
169
299
|
}
|
|
170
|
-
var
|
|
171
|
-
function
|
|
300
|
+
var Te = Se.use;
|
|
301
|
+
function Ee(e) {
|
|
172
302
|
let { rootEl: t, outerEl: n, outerActiveLayer: r, outerAxis: i } = e, a = null, o = /* @__PURE__ */ new Set();
|
|
173
303
|
function s() {
|
|
174
304
|
return t.value;
|
|
@@ -204,13 +334,13 @@ function fe(e) {
|
|
|
204
334
|
let e = s();
|
|
205
335
|
e && (e.style.removeProperty("--dock-morph-t"), e.removeAttribute("data-morphing")), c();
|
|
206
336
|
}
|
|
207
|
-
function
|
|
337
|
+
function _() {
|
|
208
338
|
if (!s()) return;
|
|
209
339
|
let e = a !== null && !a.settled ? a.velocity : 0;
|
|
210
340
|
if (!a || a.settled) {
|
|
211
|
-
c(), a = new
|
|
212
|
-
response:
|
|
213
|
-
dampingFraction:
|
|
341
|
+
c(), a = new ue({
|
|
342
|
+
response: g.response,
|
|
343
|
+
dampingFraction: g.dampingFraction,
|
|
214
344
|
initial: 0,
|
|
215
345
|
respectReducedMotion: !0
|
|
216
346
|
});
|
|
@@ -227,7 +357,7 @@ function fe(e) {
|
|
|
227
357
|
});
|
|
228
358
|
} else a.reset(0, e), a.target = 1;
|
|
229
359
|
}
|
|
230
|
-
function
|
|
360
|
+
function v(e, t, n, r) {
|
|
231
361
|
if (t !== e.txId) return;
|
|
232
362
|
let i = e.containerEl.value, a = s();
|
|
233
363
|
if (!(!i || !a)) {
|
|
@@ -235,10 +365,10 @@ function fe(e) {
|
|
|
235
365
|
m(e), h();
|
|
236
366
|
return;
|
|
237
367
|
}
|
|
238
|
-
i.style.setProperty("--dock-morph-from", `${n}px`), i.style.setProperty("--dock-morph-to", `${r}px`), a.setAttribute("data-morphing", ""),
|
|
368
|
+
i.style.setProperty("--dock-morph-from", `${n}px`), i.style.setProperty("--dock-morph-to", `${r}px`), a.setAttribute("data-morphing", ""), _();
|
|
239
369
|
}
|
|
240
370
|
}
|
|
241
|
-
function
|
|
371
|
+
function y(e, t, n) {
|
|
242
372
|
if (t === n) return;
|
|
243
373
|
let r = e.containerEl.value, i = s();
|
|
244
374
|
if (!r || !i) {
|
|
@@ -260,78 +390,198 @@ function fe(e) {
|
|
|
260
390
|
let t = e.containerEl.value, n = s();
|
|
261
391
|
if (!t || !n) return;
|
|
262
392
|
f(t);
|
|
263
|
-
let r = u(c);
|
|
393
|
+
let r = u(c), i = b(e, t).map((e) => x(e));
|
|
264
394
|
t.style.setProperty(r, "max-content");
|
|
265
|
-
let
|
|
266
|
-
t.style.removeProperty(r)
|
|
395
|
+
let o = d(t, c);
|
|
396
|
+
t.style.removeProperty(r);
|
|
397
|
+
for (let e of i) e();
|
|
398
|
+
v(e, a, l, o);
|
|
267
399
|
});
|
|
268
400
|
}
|
|
269
|
-
function
|
|
401
|
+
function b(e, t) {
|
|
402
|
+
let n = [];
|
|
403
|
+
for (let r of o) {
|
|
404
|
+
if (r === e) continue;
|
|
405
|
+
let i = r.containerEl.value;
|
|
406
|
+
i && i !== t && t.contains(i) && n.push(r);
|
|
407
|
+
}
|
|
408
|
+
return n;
|
|
409
|
+
}
|
|
410
|
+
function x(e) {
|
|
411
|
+
let t = e.containerEl.value;
|
|
412
|
+
if (!t) return () => {};
|
|
413
|
+
let n = u(e.axis.value), r = t.style.getPropertyValue(n);
|
|
414
|
+
return t.style.setProperty(n, "max-content"), () => {
|
|
415
|
+
r ? t.style.setProperty(n, r) : t.style.removeProperty(n);
|
|
416
|
+
};
|
|
417
|
+
}
|
|
418
|
+
function S(e) {
|
|
270
419
|
let t = {
|
|
271
420
|
containerEl: e.containerEl,
|
|
272
421
|
activeLayer: e.activeLayer,
|
|
273
422
|
axis: e.axis,
|
|
274
|
-
currentLayer:
|
|
275
|
-
leavingLayer:
|
|
423
|
+
currentLayer: V(e.activeLayer.value),
|
|
424
|
+
leavingLayer: V(null),
|
|
276
425
|
txId: 0,
|
|
277
426
|
stop: () => {}
|
|
278
427
|
};
|
|
279
|
-
return t.stop =
|
|
280
|
-
|
|
428
|
+
return t.stop = Y(e.activeLayer, (e, n) => {
|
|
429
|
+
y(t, e, n);
|
|
281
430
|
}), o.add(t), t;
|
|
282
431
|
}
|
|
283
|
-
function
|
|
432
|
+
function C(e) {
|
|
284
433
|
e.stop(), o.delete(e), h();
|
|
285
434
|
}
|
|
286
|
-
let
|
|
435
|
+
let w = S({
|
|
287
436
|
containerEl: n,
|
|
288
437
|
activeLayer: r,
|
|
289
438
|
axis: i
|
|
290
|
-
}),
|
|
291
|
-
let t =
|
|
439
|
+
}), T = { registerGroup(e) {
|
|
440
|
+
let t = S(e);
|
|
292
441
|
return {
|
|
293
|
-
currentLayer:
|
|
294
|
-
leavingLayer:
|
|
295
|
-
release: () =>
|
|
442
|
+
currentLayer: B(t.currentLayer),
|
|
443
|
+
leavingLayer: B(t.leavingLayer),
|
|
444
|
+
release: () => C(t)
|
|
296
445
|
};
|
|
297
446
|
} };
|
|
298
|
-
function
|
|
447
|
+
function E(e) {
|
|
299
448
|
let t = n.value;
|
|
300
449
|
if (!t || e.target !== t) return;
|
|
301
450
|
let r = u(i.value);
|
|
302
|
-
e.propertyName !== r && e.propertyName !== l(i.value) || a && a.settled && (m(
|
|
451
|
+
e.propertyName !== r && e.propertyName !== l(i.value) || a && a.settled && (m(w), h());
|
|
303
452
|
}
|
|
304
|
-
return
|
|
453
|
+
return R(() => {
|
|
305
454
|
for (let e of o) e.stop();
|
|
306
455
|
o.clear(), c();
|
|
307
456
|
}), {
|
|
308
|
-
context:
|
|
309
|
-
outerCurrentLayer:
|
|
310
|
-
onOuterTransitionEnd:
|
|
457
|
+
context: T,
|
|
458
|
+
outerCurrentLayer: B(w.currentLayer),
|
|
459
|
+
onOuterTransitionEnd: E
|
|
460
|
+
};
|
|
461
|
+
}
|
|
462
|
+
//#endregion
|
|
463
|
+
//#region src/components/custom/dock/composables/useDockShellProps.ts
|
|
464
|
+
function De(e) {
|
|
465
|
+
let t = C(() => {
|
|
466
|
+
if (e.containerName) return {
|
|
467
|
+
"container-type": "inline-size",
|
|
468
|
+
"container-name": e.containerName
|
|
469
|
+
};
|
|
470
|
+
}), n = C(() => e.collapseDelay ?? 2e3), r = C(() => e.layout ?? "linear"), i = C(() => e.shape ?? "pill"), a = C(() => e.orientation ?? "horizontal"), o = C(() => e.density ?? "comfortable"), s = C(() => e.overflow === "scroll" ? a.value === "vertical" ? "dock-scroll-y" : "dock-scroll-x" : null), c = C(() => e.alwaysExpanded || r.value === "grid");
|
|
471
|
+
return {
|
|
472
|
+
containerStyle: t,
|
|
473
|
+
collapseDelay: n,
|
|
474
|
+
startCollapsed: C(() => c.value ? !1 : e.startCollapsed ?? !0),
|
|
475
|
+
layoutValue: r,
|
|
476
|
+
shape: i,
|
|
477
|
+
orientation: a,
|
|
478
|
+
density: o,
|
|
479
|
+
scrollClass: s,
|
|
480
|
+
alwaysExpanded: c,
|
|
481
|
+
fitContent: C(() => e.fitContent ?? !1)
|
|
482
|
+
};
|
|
483
|
+
}
|
|
484
|
+
//#endregion
|
|
485
|
+
//#region src/components/custom/dock/composables/useDockMorphWindow.ts
|
|
486
|
+
function Oe(e) {
|
|
487
|
+
let t = e.trim();
|
|
488
|
+
return t ? t.endsWith("ms") ? Number.parseFloat(t) : t.endsWith("s") ? Number.parseFloat(t) * 1e3 : Number.parseFloat(t) || 0 : 0;
|
|
489
|
+
}
|
|
490
|
+
function ke(e) {
|
|
491
|
+
let t = getComputedStyle(e), n = t.transitionDuration.split(",").map(Oe), r = t.transitionDelay.split(",").map(Oe);
|
|
492
|
+
return Math.max(0, ...n.map((e, t) => e + (r[t] ?? r[0] ?? 0)));
|
|
493
|
+
}
|
|
494
|
+
function Ae(e) {
|
|
495
|
+
let t = Oe(getComputedStyle(e).getPropertyValue("--duration-normal") || "0.3s");
|
|
496
|
+
return Math.max(t > 0 ? t * 2 : 0, 600);
|
|
497
|
+
}
|
|
498
|
+
function je(e, t) {
|
|
499
|
+
let n = null, r = 0;
|
|
500
|
+
function i() {
|
|
501
|
+
n &&= (clearTimeout(n), null);
|
|
502
|
+
}
|
|
503
|
+
function a() {
|
|
504
|
+
let a = e.value;
|
|
505
|
+
if (!a) return;
|
|
506
|
+
let o = ++r;
|
|
507
|
+
i(), t.value = !0, n = setTimeout(() => {
|
|
508
|
+
o === r && (t.value = !1, n = null);
|
|
509
|
+
}, Math.max(ke(a), Ae(a)) + 50);
|
|
510
|
+
}
|
|
511
|
+
function o(n) {
|
|
512
|
+
n.target === e.value && d.has(n.propertyName) && (i(), r++, t.value = !1);
|
|
513
|
+
}
|
|
514
|
+
return F(i), {
|
|
515
|
+
markTransitioning: a,
|
|
516
|
+
onDockTransitionDone: o,
|
|
517
|
+
clearTransitionTimer: i
|
|
518
|
+
};
|
|
519
|
+
}
|
|
520
|
+
//#endregion
|
|
521
|
+
//#region src/components/custom/dock/composables/useDockClickIntegrity.ts
|
|
522
|
+
function Me(e) {
|
|
523
|
+
let { rootEl: t, visualExpanded: n } = e, r = null, i = !1, a = 0, o = null;
|
|
524
|
+
function s() {
|
|
525
|
+
o !== null && (clearTimeout(o), o = null);
|
|
526
|
+
}
|
|
527
|
+
function c() {
|
|
528
|
+
a = l() + 320, s(), o = setTimeout(() => {
|
|
529
|
+
o = null;
|
|
530
|
+
}, 320);
|
|
531
|
+
}
|
|
532
|
+
function l() {
|
|
533
|
+
return typeof performance < "u" && typeof performance.now == "function" ? performance.now() : Date.now();
|
|
534
|
+
}
|
|
535
|
+
function u() {
|
|
536
|
+
let e = t.value;
|
|
537
|
+
return e && e.hasAttribute("data-morphing") ? !0 : l() < a;
|
|
538
|
+
}
|
|
539
|
+
function d() {
|
|
540
|
+
let e = t.value;
|
|
541
|
+
return !!e && e.hasAttribute("data-morphing");
|
|
542
|
+
}
|
|
543
|
+
function f(e) {
|
|
544
|
+
r = e.target, n.value, i = d();
|
|
545
|
+
}
|
|
546
|
+
function p(e) {
|
|
547
|
+
if (!r || !e) return !1;
|
|
548
|
+
if (e === r) return !0;
|
|
549
|
+
let t = r instanceof Node ? r : null, n = e instanceof Node ? e : null;
|
|
550
|
+
return !t || !n ? !1 : t.contains(n) || n.contains(t);
|
|
551
|
+
}
|
|
552
|
+
function m(e) {
|
|
553
|
+
let t = i;
|
|
554
|
+
if (i = !1, !u()) {
|
|
555
|
+
r = null;
|
|
556
|
+
return;
|
|
557
|
+
}
|
|
558
|
+
if (!(!r && !t)) {
|
|
559
|
+
if (!t && p(e.target)) {
|
|
560
|
+
r = null;
|
|
561
|
+
return;
|
|
562
|
+
}
|
|
563
|
+
e.stopPropagation(), e.preventDefault(), r = null;
|
|
564
|
+
}
|
|
565
|
+
}
|
|
566
|
+
return F(s), {
|
|
567
|
+
onPointerDownCapture: f,
|
|
568
|
+
onClickCapture: m,
|
|
569
|
+
markExpandFlip: c
|
|
311
570
|
};
|
|
312
571
|
}
|
|
313
572
|
//#endregion
|
|
314
573
|
//#region src/components/custom/dock/GlassDock.vue?vue&type=script&setup=true&lang.ts
|
|
315
|
-
var
|
|
574
|
+
var Ne = ["data-has-rail"], Pe = [
|
|
316
575
|
"data-density",
|
|
317
576
|
"data-held",
|
|
318
577
|
"data-container-name"
|
|
319
|
-
],
|
|
578
|
+
], Fe = {
|
|
320
579
|
key: 0,
|
|
321
580
|
class: "dock-persistent"
|
|
322
|
-
},
|
|
323
|
-
|
|
324
|
-
class: "dock-layers dock-layer--vertical-body"
|
|
325
|
-
}, ve = { class: "dock-layer--vertical-section" }, ye = {
|
|
326
|
-
key: 1,
|
|
327
|
-
class: "dock-layers dock-layer--vertical-body"
|
|
328
|
-
}, be = ["inert"], xe = ["inert"], Se = /* @__PURE__ */ S({
|
|
581
|
+
}, Ie = ["inert"], Le = ["inert"], Re = /* @__PURE__ */ k({
|
|
582
|
+
inheritAttrs: !1,
|
|
329
583
|
__name: "GlassDock",
|
|
330
584
|
props: {
|
|
331
|
-
variant: {},
|
|
332
|
-
collapseDelay: {},
|
|
333
|
-
startCollapsed: { type: Boolean },
|
|
334
|
-
layout: {},
|
|
335
585
|
fitContent: { type: Boolean },
|
|
336
586
|
position: {},
|
|
337
587
|
alwaysExpanded: { type: Boolean },
|
|
@@ -339,181 +589,254 @@ var pe = [
|
|
|
339
589
|
orientation: {},
|
|
340
590
|
density: {},
|
|
341
591
|
overflow: {},
|
|
342
|
-
containerName: {}
|
|
592
|
+
containerName: {},
|
|
593
|
+
collapseDelay: {},
|
|
594
|
+
startCollapsed: { type: Boolean },
|
|
595
|
+
layout: {},
|
|
596
|
+
autoLuminance: { type: Boolean },
|
|
597
|
+
backgroundCanvas: { type: [
|
|
598
|
+
Function,
|
|
599
|
+
String,
|
|
600
|
+
null
|
|
601
|
+
] }
|
|
343
602
|
},
|
|
344
603
|
setup(e, { expose: t }) {
|
|
345
|
-
let n = e, r = g(
|
|
346
|
-
|
|
347
|
-
|
|
348
|
-
|
|
349
|
-
|
|
604
|
+
let n = e, { containerStyle: r, collapseDelay: i, startCollapsed: s, layoutValue: c, shape: l, orientation: u, density: d, scrollClass: f, alwaysExpanded: m, fitContent: h } = De(n), g = c, _ = J("dockEl"), v = J("layersEl");
|
|
605
|
+
n.autoLuminance !== !1 && ye(_, { backgroundCanvas: n.backgroundCanvas ?? null });
|
|
606
|
+
let y = V(!1), b = o(i.value), x = `glass-dock-${ee()}`, { expanded: S, isPinned: w, isHeld: O, onMouseEnter: k, onMouseLeave: A, onFocusIn: M, onFocusOut: P, onClickCollapsed: F, keepOpen: L, release: R, expand: B, collapse: H } = xe({
|
|
607
|
+
collapseDelay: i.value,
|
|
608
|
+
rootEl: _,
|
|
609
|
+
alwaysExpanded: m,
|
|
610
|
+
isTransitioning: y,
|
|
611
|
+
dockId: x
|
|
350
612
|
});
|
|
351
|
-
|
|
352
|
-
|
|
353
|
-
|
|
354
|
-
|
|
355
|
-
|
|
356
|
-
|
|
357
|
-
|
|
358
|
-
collapseDelay: o.value,
|
|
359
|
-
rootEl: u,
|
|
360
|
-
alwaysExpanded: O,
|
|
361
|
-
isTransitioning: M,
|
|
362
|
-
dockId: F
|
|
613
|
+
p({
|
|
614
|
+
id: x,
|
|
615
|
+
orientation: u,
|
|
616
|
+
layout: g,
|
|
617
|
+
keepOpen: L,
|
|
618
|
+
release: R,
|
|
619
|
+
held: O
|
|
363
620
|
});
|
|
364
|
-
|
|
365
|
-
|
|
366
|
-
|
|
367
|
-
|
|
368
|
-
|
|
369
|
-
|
|
370
|
-
|
|
621
|
+
let W = C(() => m.value || S.value), G = te(), q = C(() => !!G.rail), X = J("frameEl");
|
|
622
|
+
function Z() {
|
|
623
|
+
let e = X.value;
|
|
624
|
+
if (!e || !q.value) return;
|
|
625
|
+
let t = _.value?.querySelector("[data-rail-anchor]");
|
|
626
|
+
if (!t) {
|
|
627
|
+
e.style.removeProperty("--dock-rail-seam-offset");
|
|
628
|
+
return;
|
|
629
|
+
}
|
|
630
|
+
let n = e.getBoundingClientRect(), r = t.getBoundingClientRect(), i = u.value === "vertical" ? r.top + r.height / 2 - n.top : r.left + r.width / 2 - n.left;
|
|
631
|
+
e.style.setProperty("--dock-rail-seam-offset", `${Math.round(i)}px`);
|
|
632
|
+
}
|
|
633
|
+
a(_, () => Z()), I(() => Z()), Y([u, q], () => Z(), { flush: "post" });
|
|
634
|
+
let { context: ne, onOuterTransitionEnd: re } = Ee({
|
|
635
|
+
rootEl: _,
|
|
636
|
+
outerEl: v,
|
|
637
|
+
outerActiveLayer: C(() => W.value ? "full" : "summary"),
|
|
638
|
+
outerAxis: C(() => u.value)
|
|
371
639
|
});
|
|
372
|
-
|
|
373
|
-
|
|
374
|
-
|
|
375
|
-
|
|
376
|
-
outerAxis: g(() => "horizontal")
|
|
640
|
+
we(ne);
|
|
641
|
+
let ie = C(() => ({ "view-transition-name": x.replace(/[^a-zA-Z0-9_-]/g, "-") })), { markTransitioning: ae, onDockTransitionDone: Q } = je(_, y), { onPointerDownCapture: oe, onClickCapture: se, markExpandFlip: ce } = Me({
|
|
642
|
+
rootEl: _,
|
|
643
|
+
visualExpanded: W
|
|
377
644
|
});
|
|
378
|
-
|
|
379
|
-
|
|
380
|
-
|
|
381
|
-
|
|
382
|
-
return
|
|
383
|
-
}
|
|
384
|
-
function Ce(e) {
|
|
385
|
-
let t = getComputedStyle(e), n = t.transitionDuration.split(",").map(Z), r = t.transitionDelay.split(",").map(Z);
|
|
386
|
-
return Math.max(0, ...n.map((e, t) => e + (r[t] ?? r[0] ?? 0)));
|
|
387
|
-
}
|
|
388
|
-
function we(e) {
|
|
389
|
-
let t = Z(getComputedStyle(e).getPropertyValue("--duration-normal") || "0.3s");
|
|
390
|
-
return Math.max(t > 0 ? t * 2 : 0, 600);
|
|
391
|
-
}
|
|
392
|
-
function Q() {
|
|
393
|
-
L &&= (clearTimeout(L), null);
|
|
394
|
-
}
|
|
395
|
-
let Te = new Set([
|
|
396
|
-
"width",
|
|
397
|
-
"height",
|
|
398
|
-
"padding",
|
|
399
|
-
"transform"
|
|
400
|
-
]);
|
|
401
|
-
function Ee() {
|
|
402
|
-
let e = u.value;
|
|
403
|
-
if (!e) return;
|
|
404
|
-
let t = ++R;
|
|
405
|
-
Q(), M.value = !0, L = setTimeout(() => {
|
|
406
|
-
t === R && (M.value = !1, L = null);
|
|
407
|
-
}, Math.max(Ce(e), we(e)) + 50);
|
|
645
|
+
I(() => {
|
|
646
|
+
(n.alwaysExpanded || !s.value) && B();
|
|
647
|
+
});
|
|
648
|
+
function le() {
|
|
649
|
+
return !m.value;
|
|
408
650
|
}
|
|
409
|
-
function
|
|
410
|
-
|
|
651
|
+
function ue(e) {
|
|
652
|
+
if (!le() || W.value) return;
|
|
653
|
+
let t = _.value, n = e.touches[0];
|
|
654
|
+
!t || !n || b.handleTouchStart(t, n.clientY);
|
|
411
655
|
}
|
|
412
|
-
|
|
413
|
-
|
|
414
|
-
|
|
415
|
-
|
|
416
|
-
|
|
417
|
-
|
|
418
|
-
|
|
419
|
-
|
|
420
|
-
|
|
421
|
-
|
|
422
|
-
|
|
423
|
-
|
|
424
|
-
|
|
425
|
-
|
|
426
|
-
|
|
427
|
-
|
|
428
|
-
|
|
429
|
-
|
|
430
|
-
|
|
431
|
-
|
|
432
|
-
|
|
433
|
-
|
|
434
|
-
|
|
435
|
-
|
|
436
|
-
|
|
437
|
-
|
|
438
|
-
|
|
439
|
-
}), te(Q), t({
|
|
440
|
-
expanded: V,
|
|
441
|
-
isPinned: H,
|
|
442
|
-
isHeld: U,
|
|
443
|
-
isTransitioning: M,
|
|
444
|
-
expand: q,
|
|
445
|
-
collapse: J,
|
|
446
|
-
keepOpen: oe,
|
|
447
|
-
release: se
|
|
448
|
-
}), (t, n) => (k(), y("div", {
|
|
656
|
+
function de(e) {
|
|
657
|
+
le() && b.handleScrollCheck(e);
|
|
658
|
+
}
|
|
659
|
+
function fe() {
|
|
660
|
+
if (!le()) return;
|
|
661
|
+
let e = b.isActive.value;
|
|
662
|
+
b.handleTouchEnd(), !e && b.isActive.value && !W.value && B();
|
|
663
|
+
}
|
|
664
|
+
return Y(b.isActive, (e) => {
|
|
665
|
+
!e && S.value && !w.value && !m.value && H();
|
|
666
|
+
}), Y(W, (e) => {
|
|
667
|
+
ae(), e ? ce() : b.deactivate();
|
|
668
|
+
}), t({
|
|
669
|
+
expanded: S,
|
|
670
|
+
isPinned: w,
|
|
671
|
+
isHeld: O,
|
|
672
|
+
isTransitioning: y,
|
|
673
|
+
expand: B,
|
|
674
|
+
collapse: H,
|
|
675
|
+
keepOpen: L,
|
|
676
|
+
release: R
|
|
677
|
+
}), (t, n) => (z(), E("div", {
|
|
678
|
+
ref_key: "frameEl",
|
|
679
|
+
ref: X,
|
|
680
|
+
class: N(["glass-dock-frame", K(u)]),
|
|
681
|
+
"data-has-rail": q.value || void 0
|
|
682
|
+
}, [D("div", j({
|
|
449
683
|
ref_key: "dockEl",
|
|
450
|
-
ref:
|
|
451
|
-
|
|
452
|
-
|
|
453
|
-
|
|
454
|
-
`shape-${
|
|
455
|
-
`layout-${
|
|
456
|
-
|
|
684
|
+
ref: _
|
|
685
|
+
}, t.$attrs, {
|
|
686
|
+
class: ["glass-dock", [
|
|
687
|
+
K(u),
|
|
688
|
+
`shape-${K(l)}`,
|
|
689
|
+
`layout-${K(g)}`,
|
|
690
|
+
K(f),
|
|
457
691
|
{
|
|
458
|
-
expanded:
|
|
459
|
-
collapsed: !
|
|
460
|
-
pinned:
|
|
461
|
-
"fit-content":
|
|
462
|
-
"always-expanded":
|
|
463
|
-
"dock-overflow-wrap": e.overflow === "wrap" &&
|
|
692
|
+
expanded: W.value,
|
|
693
|
+
collapsed: !W.value,
|
|
694
|
+
pinned: K(w),
|
|
695
|
+
"fit-content": K(h),
|
|
696
|
+
"always-expanded": K(m),
|
|
697
|
+
"dock-overflow-wrap": e.overflow === "wrap" && K(u) !== "vertical"
|
|
464
698
|
},
|
|
465
|
-
e.position === "fixed" ? "fixed bottom-
|
|
466
|
-
]]
|
|
467
|
-
"data-density":
|
|
468
|
-
"data-held":
|
|
699
|
+
e.position === "fixed" ? "fixed bottom-(--dock-pos) left-1/2 -translate-x-1/2" : e.position === "sticky" ? "dock-sticky" : "dock-inline"
|
|
700
|
+
]],
|
|
701
|
+
"data-density": K(d),
|
|
702
|
+
"data-held": K(O) || void 0,
|
|
469
703
|
"data-container-name": e.containerName || void 0,
|
|
470
|
-
style:
|
|
471
|
-
onMouseenter: n[
|
|
472
|
-
onMouseleave: n[
|
|
473
|
-
onFocusin: n[
|
|
474
|
-
onFocusout: n[
|
|
475
|
-
onTouchstart:
|
|
476
|
-
onTouchmove:
|
|
477
|
-
onTouchend:
|
|
478
|
-
|
|
479
|
-
|
|
480
|
-
|
|
481
|
-
|
|
704
|
+
style: [K(r), ie.value],
|
|
705
|
+
onMouseenter: n[2] ||= (...e) => K(k) && K(k)(...e),
|
|
706
|
+
onMouseleave: n[3] ||= (e) => K(A)(e),
|
|
707
|
+
onFocusin: n[4] ||= (...e) => K(M) && K(M)(...e),
|
|
708
|
+
onFocusout: n[5] ||= (...e) => K(P) && K(P)(...e),
|
|
709
|
+
onTouchstart: ue,
|
|
710
|
+
onTouchmove: de,
|
|
711
|
+
onTouchend: fe,
|
|
712
|
+
onPointerdownCapture: n[6] ||= (...e) => K(oe) && K(oe)(...e),
|
|
713
|
+
onClickCapture: n[7] ||= (...e) => K(se) && K(se)(...e),
|
|
714
|
+
onTransitionend: n[8] ||= (...e) => K(Q) && K(Q)(...e),
|
|
715
|
+
onTransitioncancel: n[9] ||= (...e) => K(Q) && K(Q)(...e)
|
|
716
|
+
}), [t.$slots.persistent ? (z(), E("div", Fe, [U(t.$slots, "persistent")])) : T("", !0), D("div", {
|
|
482
717
|
ref_key: "layersEl",
|
|
483
|
-
ref:
|
|
718
|
+
ref: v,
|
|
484
719
|
class: "dock-layers",
|
|
485
|
-
onTransitionend: n[1] ||= (...e) =>
|
|
486
|
-
}, [
|
|
487
|
-
class:
|
|
488
|
-
inert: !
|
|
489
|
-
}, [
|
|
490
|
-
class:
|
|
491
|
-
inert:
|
|
492
|
-
onClick: n[0] ||= (...e) =>
|
|
493
|
-
}, [
|
|
494
|
-
|
|
495
|
-
|
|
496
|
-
}, [
|
|
497
|
-
|
|
498
|
-
|
|
499
|
-
|
|
500
|
-
|
|
501
|
-
|
|
502
|
-
}
|
|
503
|
-
|
|
504
|
-
|
|
505
|
-
|
|
720
|
+
onTransitionend: n[1] ||= (...e) => K(re) && K(re)(...e)
|
|
721
|
+
}, [D("div", {
|
|
722
|
+
class: N(["dock-layer dock-layer--full", { "is-active": W.value }]),
|
|
723
|
+
inert: !K(S) || void 0
|
|
724
|
+
}, [U(t.$slots, "default")], 10, Ie), D("div", {
|
|
725
|
+
class: N(["dock-layer dock-layer--summary", { "is-active": !W.value }]),
|
|
726
|
+
inert: K(S) || void 0,
|
|
727
|
+
onClick: n[0] ||= (...e) => K(F) && K(F)(...e)
|
|
728
|
+
}, [U(t.$slots, "collapsed")], 10, Le)], 544)], 16, Pe), q.value ? (z(), E("div", {
|
|
729
|
+
key: 0,
|
|
730
|
+
class: N(["dock-hairline-slot", K(u)])
|
|
731
|
+
}, [U(t.$slots, "rail")], 2)) : T("", !0)], 10, Ne));
|
|
732
|
+
}
|
|
733
|
+
}), ze = /* @__PURE__ */ k({
|
|
734
|
+
__name: "Tabs",
|
|
735
|
+
props: {
|
|
736
|
+
defaultValue: {},
|
|
737
|
+
orientation: {},
|
|
738
|
+
dir: {},
|
|
739
|
+
activationMode: {},
|
|
740
|
+
modelValue: {},
|
|
741
|
+
unmountOnHide: { type: Boolean },
|
|
742
|
+
asChild: { type: Boolean },
|
|
743
|
+
as: {}
|
|
744
|
+
},
|
|
745
|
+
emits: ["update:modelValue"],
|
|
746
|
+
setup(e, { emit: t }) {
|
|
747
|
+
let n = le(e, t);
|
|
748
|
+
return (e, t) => (z(), w(K(oe), j({ "data-slot": "tabs" }, K(n)), {
|
|
749
|
+
default: X(() => [U(e.$slots, "default")]),
|
|
750
|
+
_: 3
|
|
751
|
+
}, 16));
|
|
752
|
+
}
|
|
753
|
+
}), Be = /* @__PURE__ */ k({
|
|
754
|
+
__name: "TabsTrigger",
|
|
755
|
+
props: {
|
|
756
|
+
value: {},
|
|
757
|
+
disabled: { type: Boolean },
|
|
758
|
+
asChild: { type: Boolean },
|
|
759
|
+
as: {},
|
|
760
|
+
class: { type: [
|
|
761
|
+
Boolean,
|
|
762
|
+
null,
|
|
763
|
+
String,
|
|
764
|
+
Object,
|
|
765
|
+
Array
|
|
766
|
+
] }
|
|
767
|
+
},
|
|
768
|
+
setup(t) {
|
|
769
|
+
let n = t, r = ce(C(() => {
|
|
770
|
+
let { class: e, ...t } = n;
|
|
771
|
+
return t;
|
|
772
|
+
}));
|
|
773
|
+
return (t, i) => (z(), w(K(se), j({ "data-slot": "tabs-trigger" }, K(r), { class: K(e)("tap-squish focus-ring relative z-[1] inline-flex items-center justify-center whitespace-nowrap rounded-control p-1 px-3 text-sm font-medium transition-control disabled:pointer-events-none disabled:opacity-disabled data-[state=active]:text-[var(--active-tab-color,var(--foreground))] hover:text-foreground/70", n.class) }), {
|
|
774
|
+
default: X(() => [U(t.$slots, "default")]),
|
|
775
|
+
_: 3
|
|
776
|
+
}, 16, ["class"]));
|
|
777
|
+
}
|
|
778
|
+
}), Ve = /* @__PURE__ */ k({
|
|
779
|
+
__name: "TabsIndicator",
|
|
780
|
+
props: {
|
|
781
|
+
asChild: { type: Boolean },
|
|
782
|
+
as: {},
|
|
783
|
+
class: { type: [
|
|
784
|
+
Boolean,
|
|
785
|
+
null,
|
|
786
|
+
String,
|
|
787
|
+
Object,
|
|
788
|
+
Array
|
|
789
|
+
] },
|
|
790
|
+
surface: {
|
|
791
|
+
type: Boolean,
|
|
792
|
+
default: !0
|
|
793
|
+
}
|
|
794
|
+
},
|
|
795
|
+
setup(t) {
|
|
796
|
+
let n = t, r = C(() => {
|
|
797
|
+
let { class: e, surface: t, ...r } = n;
|
|
798
|
+
return r;
|
|
799
|
+
});
|
|
800
|
+
return (t, i) => (z(), w(K(ae), j({ "data-slot": "tabs-indicator" }, r.value, { class: K(e)("pointer-events-none absolute left-0 bottom-1 top-1 z-0 w-(--reka-tabs-indicator-size) translate-x-(--reka-tabs-indicator-position) rounded-pill transition-[width,translate] duration-normal ease-spring-snappy", n.surface && "bg-(--glass-bg-quiet) [backdrop-filter:var(--glass-blur-quiet)]", n.class) }), null, 16, ["class"]));
|
|
801
|
+
}
|
|
802
|
+
}), He = /* @__PURE__ */ k({
|
|
803
|
+
__name: "TabsList",
|
|
804
|
+
props: {
|
|
805
|
+
loop: { type: Boolean },
|
|
806
|
+
asChild: { type: Boolean },
|
|
807
|
+
as: {},
|
|
808
|
+
class: { type: [
|
|
809
|
+
Boolean,
|
|
810
|
+
null,
|
|
811
|
+
String,
|
|
812
|
+
Object,
|
|
813
|
+
Array
|
|
814
|
+
] },
|
|
815
|
+
indicator: {
|
|
816
|
+
type: Boolean,
|
|
817
|
+
default: !0
|
|
818
|
+
}
|
|
819
|
+
},
|
|
820
|
+
setup(t) {
|
|
821
|
+
let n = t, r = C(() => {
|
|
822
|
+
let { class: e, indicator: t, ...r } = n;
|
|
823
|
+
return r;
|
|
824
|
+
});
|
|
825
|
+
return (i, a) => (z(), w(K(Q), j({ "data-slot": "tabs-list" }, r.value, { class: K(e)("relative inline-flex h-(--control-h-md) items-center justify-center rounded-input p-1 text-muted-foreground", n.class) }), {
|
|
826
|
+
default: X(() => [t.indicator ? (z(), w(Ve, { key: 0 })) : T("", !0), U(i.$slots, "default")]),
|
|
827
|
+
_: 3
|
|
828
|
+
}, 16, ["class"]));
|
|
829
|
+
}
|
|
830
|
+
}), Ue = c(u, "[glass-ui:dock] <DockLayer> must be used inside <DockLayerGroup>"), { KEY: We } = Ue;
|
|
831
|
+
function Ge(e) {
|
|
832
|
+
Ue.provide(e);
|
|
506
833
|
}
|
|
507
|
-
var
|
|
508
|
-
|
|
834
|
+
var Ke = Ue.use;
|
|
835
|
+
Ue.useOptional;
|
|
509
836
|
//#endregion
|
|
510
837
|
//#region src/components/custom/dock/composables/useLayerTransition.ts
|
|
511
|
-
|
|
512
|
-
|
|
513
|
-
dampingFraction: .7
|
|
514
|
-
};
|
|
515
|
-
function Q(e) {
|
|
516
|
-
let { containerEl: t, activeLayer: n, axis: r } = e, i = g(() => r?.value === "vertical" ? "height" : "width"), a = g(() => i.value === "width" ? "inline-size" : "block-size"), o = (e) => e.getBoundingClientRect()[i.value], s = j(n.value), c = j(null), l = 0, u = null, d = null;
|
|
838
|
+
function qe(e) {
|
|
839
|
+
let { containerEl: t, activeLayer: n, axis: r } = e, i = C(() => r?.value === "vertical" ? "height" : "width"), a = C(() => i.value === "width" ? "inline-size" : "block-size"), o = (e) => e.getBoundingClientRect()[i.value], s = V(n.value), c = V(null), l = 0, u = null, d = null;
|
|
517
840
|
function f() {
|
|
518
841
|
u &&= (u.dispose(), null), d = null;
|
|
519
842
|
}
|
|
@@ -531,9 +854,9 @@ function Q(e) {
|
|
|
531
854
|
h(e, t);
|
|
532
855
|
return;
|
|
533
856
|
}
|
|
534
|
-
e.style.setProperty("--dock-morph-from", `${r}px`), e.style.setProperty("--dock-morph-to", `${i}px`), t.style.setProperty("--dock-morph-t", "0"), t.setAttribute("data-morphing", ""), o || (f(), u = new
|
|
535
|
-
response:
|
|
536
|
-
dampingFraction:
|
|
857
|
+
e.style.setProperty("--dock-morph-from", `${r}px`), e.style.setProperty("--dock-morph-to", `${i}px`), t.style.setProperty("--dock-morph-t", "0"), t.setAttribute("data-morphing", ""), o || (f(), u = new ue({
|
|
858
|
+
response: g.response,
|
|
859
|
+
dampingFraction: g.dampingFraction,
|
|
537
860
|
initial: 0,
|
|
538
861
|
respectReducedMotion: !0
|
|
539
862
|
}), d = e);
|
|
@@ -542,7 +865,7 @@ function Q(e) {
|
|
|
542
865
|
n === l && (t.style.setProperty("--dock-morph-t", `${r}`), s.settled && h(e, t));
|
|
543
866
|
});
|
|
544
867
|
}
|
|
545
|
-
|
|
868
|
+
Y(n, (e, n) => {
|
|
546
869
|
if (e === n) return;
|
|
547
870
|
let r = t.value;
|
|
548
871
|
if (!r) {
|
|
@@ -564,7 +887,7 @@ function Q(e) {
|
|
|
564
887
|
let n = t.value;
|
|
565
888
|
n && e.target === n && (e.propertyName !== a.value && e.propertyName !== i.value || u && u.settled && h(n, p(n)));
|
|
566
889
|
}
|
|
567
|
-
return
|
|
890
|
+
return R(f), {
|
|
568
891
|
onTransitionEnd: v,
|
|
569
892
|
currentLayer: s,
|
|
570
893
|
leavingLayer: c
|
|
@@ -572,9 +895,9 @@ function Q(e) {
|
|
|
572
895
|
}
|
|
573
896
|
//#endregion
|
|
574
897
|
//#region src/components/custom/dock/DockLayerGroup.vue?vue&type=script&setup=true&lang.ts
|
|
575
|
-
var
|
|
898
|
+
var Je = { key: 1 }, Ye = { key: 2 }, Xe = /* @__PURE__ */ k({
|
|
576
899
|
__name: "DockLayerGroup",
|
|
577
|
-
props: /* @__PURE__ */
|
|
900
|
+
props: /* @__PURE__ */ A({
|
|
578
901
|
orientation: {},
|
|
579
902
|
showRail: {
|
|
580
903
|
type: Boolean,
|
|
@@ -587,100 +910,103 @@ var Te = { key: 1 }, Ee = { key: 2 }, De = /* @__PURE__ */ S({
|
|
|
587
910
|
}),
|
|
588
911
|
emits: ["update:active"],
|
|
589
912
|
setup(e) {
|
|
590
|
-
let t = e, n =
|
|
913
|
+
let t = e, n = q(e, "active"), r = f(), i = V([]), a = J("containerEl");
|
|
591
914
|
function o(e) {
|
|
592
915
|
i.value.find((t) => t.id === e.id) || i.value.push(e);
|
|
593
916
|
}
|
|
594
|
-
function
|
|
917
|
+
function s(e) {
|
|
595
918
|
i.value = i.value.filter((t) => t.id !== e);
|
|
596
919
|
}
|
|
597
|
-
let
|
|
598
|
-
if (
|
|
599
|
-
let e =
|
|
920
|
+
let c = C(() => t.orientation ?? r?.orientation.value ?? "horizontal"), l = C(() => c.value === "vertical" ? "horizontal" : "vertical"), u = Te(), d, p, m;
|
|
921
|
+
if (u) {
|
|
922
|
+
let e = u.registerGroup({
|
|
600
923
|
containerEl: a,
|
|
601
924
|
activeLayer: n,
|
|
602
|
-
axis:
|
|
925
|
+
axis: c
|
|
603
926
|
});
|
|
604
|
-
|
|
927
|
+
d = e.currentLayer, p = e.leavingLayer, m = () => {}, F(() => e.release());
|
|
605
928
|
} else {
|
|
606
|
-
let e =
|
|
929
|
+
let e = qe({
|
|
607
930
|
containerEl: a,
|
|
608
931
|
activeLayer: n,
|
|
609
|
-
axis:
|
|
932
|
+
axis: c,
|
|
610
933
|
directionTypes: (e, t) => {
|
|
611
934
|
let n = i.value.findIndex((t) => t.id === e);
|
|
612
935
|
return [i.value.findIndex((e) => e.id === t) < n ? "layer-back" : "layer-forward"];
|
|
613
936
|
}
|
|
614
937
|
});
|
|
615
|
-
|
|
938
|
+
d = B(e.currentLayer), p = B(e.leavingLayer), m = e.onTransitionEnd;
|
|
616
939
|
}
|
|
617
|
-
let
|
|
618
|
-
"view-transition-name": `gl-dock-stack-${
|
|
940
|
+
let h = typeof document < "u" && "startViewTransition" in document, g = ee(), _ = C(() => h ? {
|
|
941
|
+
"view-transition-name": `gl-dock-stack-${g.replace(/[^a-zA-Z0-9_-]/g, "-")}`,
|
|
619
942
|
"view-transition-class": "gl-dock-layer"
|
|
620
943
|
} : void 0);
|
|
621
|
-
|
|
944
|
+
Ge({
|
|
622
945
|
register: o,
|
|
623
|
-
unregister:
|
|
624
|
-
currentLayerId:
|
|
625
|
-
leavingLayerId:
|
|
946
|
+
unregister: s,
|
|
947
|
+
currentLayerId: d,
|
|
948
|
+
leavingLayerId: p
|
|
626
949
|
});
|
|
627
|
-
function
|
|
628
|
-
return typeof e == "object" && !!e;
|
|
950
|
+
function v(e) {
|
|
951
|
+
return typeof e == "object" && !!e || typeof e == "function";
|
|
629
952
|
}
|
|
630
|
-
let
|
|
631
|
-
function
|
|
632
|
-
|
|
953
|
+
let y = V(!1);
|
|
954
|
+
function b() {
|
|
955
|
+
y.value || (y.value = !0, r?.keepOpen());
|
|
633
956
|
}
|
|
634
|
-
function
|
|
957
|
+
function x(e) {
|
|
635
958
|
let t = e.relatedTarget, n = e.currentTarget;
|
|
636
|
-
t && n?.contains(t) ||
|
|
959
|
+
t && n?.contains(t) || y.value && (y.value = !1, r?.release());
|
|
637
960
|
}
|
|
638
|
-
return (t, r) => (
|
|
961
|
+
return (t, r) => (z(), E("div", { class: N(["dock-layer-group", [c.value, `rail-${e.railPosition}`]]) }, [e.showRail && i.value.length > 1 ? (z(), w(K(ze), {
|
|
639
962
|
key: 0,
|
|
640
963
|
modelValue: n.value,
|
|
641
964
|
"onUpdate:modelValue": r[0] ||= (e) => n.value = e,
|
|
642
|
-
orientation:
|
|
965
|
+
orientation: l.value,
|
|
643
966
|
"as-child": !0
|
|
644
967
|
}, {
|
|
645
|
-
default:
|
|
646
|
-
class:
|
|
968
|
+
default: X(() => [O(K(He), {
|
|
969
|
+
class: N(["dock-layer-rail", e.railPosition]),
|
|
647
970
|
indicator: !1,
|
|
648
|
-
onFocusin:
|
|
649
|
-
onFocusout:
|
|
971
|
+
onFocusin: b,
|
|
972
|
+
onFocusout: x
|
|
650
973
|
}, {
|
|
651
|
-
default:
|
|
974
|
+
default: X(() => [(z(!0), E(S, null, H(i.value, (e) => (z(), w(K(Be), {
|
|
652
975
|
key: e.id,
|
|
653
976
|
value: e.id,
|
|
654
977
|
class: "dock-layer-tab",
|
|
655
978
|
title: e.label,
|
|
656
979
|
"aria-label": e.label ?? e.id
|
|
657
980
|
}, {
|
|
658
|
-
default:
|
|
981
|
+
default: X(() => [v(e.icon) ? (z(), w(W(e.icon), {
|
|
659
982
|
key: 0,
|
|
660
983
|
class: "size-4"
|
|
661
|
-
})) : typeof e.icon == "string" ? (
|
|
984
|
+
})) : typeof e.icon == "string" ? (z(), E("span", Je, G(e.icon), 1)) : (z(), E("span", Ye, G((e.label ?? e.id).charAt(0)), 1))]),
|
|
662
985
|
_: 2
|
|
663
986
|
}, 1032, [
|
|
664
987
|
"value",
|
|
665
988
|
"title",
|
|
666
989
|
"aria-label"
|
|
667
|
-
]))), 128)),
|
|
990
|
+
]))), 128)), O(K(Ve), {
|
|
991
|
+
class: "dock-layer-tab-indicator",
|
|
992
|
+
surface: !1
|
|
993
|
+
})]),
|
|
668
994
|
_: 1
|
|
669
995
|
}, 8, ["class"])]),
|
|
670
996
|
_: 1
|
|
671
|
-
}, 8, ["modelValue", "orientation"])) :
|
|
997
|
+
}, 8, ["modelValue", "orientation"])) : T("", !0), D("div", {
|
|
672
998
|
ref_key: "containerEl",
|
|
673
999
|
ref: a,
|
|
674
1000
|
class: "dock-layer-stack",
|
|
675
|
-
style:
|
|
676
|
-
onTransitionend: r[1] ||= (...e) =>
|
|
677
|
-
}, [
|
|
1001
|
+
style: P(_.value),
|
|
1002
|
+
onTransitionend: r[1] ||= (...e) => K(m) && K(m)(...e)
|
|
1003
|
+
}, [U(t.$slots, "default")], 36)], 2));
|
|
678
1004
|
}
|
|
679
|
-
}),
|
|
1005
|
+
}), Ze = [
|
|
680
1006
|
"inert",
|
|
681
1007
|
"aria-hidden",
|
|
682
1008
|
"tabindex"
|
|
683
|
-
],
|
|
1009
|
+
], Qe = /* @__PURE__ */ k({
|
|
684
1010
|
__name: "DockLayer",
|
|
685
1011
|
props: {
|
|
686
1012
|
id: {},
|
|
@@ -688,35 +1014,35 @@ var Te = { key: 1 }, Ee = { key: 2 }, De = /* @__PURE__ */ S({
|
|
|
688
1014
|
icon: {}
|
|
689
1015
|
},
|
|
690
1016
|
setup(e) {
|
|
691
|
-
let t = e, n =
|
|
692
|
-
|
|
1017
|
+
let t = e, n = Ke();
|
|
1018
|
+
I(() => {
|
|
693
1019
|
n.register({
|
|
694
1020
|
id: t.id,
|
|
695
1021
|
label: t.label,
|
|
696
1022
|
icon: t.icon
|
|
697
1023
|
});
|
|
698
|
-
}),
|
|
1024
|
+
}), F(() => {
|
|
699
1025
|
n.unregister(t.id);
|
|
700
1026
|
});
|
|
701
|
-
let r =
|
|
702
|
-
return
|
|
1027
|
+
let r = C(() => n.currentLayerId.value === t.id), i = C(() => n.leavingLayerId.value === t.id), a = J("hostEl");
|
|
1028
|
+
return Y(r, async (e, t) => {
|
|
703
1029
|
!e || t || typeof document < "u" && (() => {
|
|
704
1030
|
let e = document.activeElement;
|
|
705
1031
|
return !e || e === document.body ? !0 : !!e.closest("[inert]");
|
|
706
|
-
})() && (await
|
|
707
|
-
}), (e, t) => (
|
|
1032
|
+
})() && (await M(), a.value?.focus());
|
|
1033
|
+
}), (e, t) => (z(), E("div", {
|
|
708
1034
|
ref_key: "hostEl",
|
|
709
1035
|
ref: a,
|
|
710
|
-
class:
|
|
1036
|
+
class: N(["dock-layer-item-host", {
|
|
711
1037
|
"is-active": r.value,
|
|
712
1038
|
"is-leaving": i.value
|
|
713
1039
|
}]),
|
|
714
1040
|
inert: r.value ? void 0 : !0,
|
|
715
1041
|
"aria-hidden": r.value ? void 0 : !0,
|
|
716
1042
|
tabindex: r.value ? -1 : void 0
|
|
717
|
-
}, [
|
|
1043
|
+
}, [U(e.$slots, "default")], 10, Ze));
|
|
718
1044
|
}
|
|
719
|
-
}),
|
|
1045
|
+
}), $e = /* @__PURE__ */ k({
|
|
720
1046
|
__name: "DockIconButton",
|
|
721
1047
|
props: {
|
|
722
1048
|
compact: {
|
|
@@ -738,16 +1064,16 @@ var Te = { key: 1 }, Ee = { key: 2 }, De = /* @__PURE__ */ S({
|
|
|
738
1064
|
] }
|
|
739
1065
|
},
|
|
740
1066
|
setup(t) {
|
|
741
|
-
let n = t,
|
|
742
|
-
return (e, n) => (
|
|
1067
|
+
let n = t, r = C(() => e("dock-icon-button glass-specular-track", { "dock-icon-button--compact": n.compact }, n.class)), { specularStyle: a, onPointerMove: o } = i(), s = C(() => !n.asChild && n.as === "button" ? { type: n.type } : {});
|
|
1068
|
+
return (e, n) => (z(), w(K(ne), j({
|
|
743
1069
|
as: t.as,
|
|
744
1070
|
"as-child": t.asChild
|
|
745
1071
|
}, s.value, {
|
|
746
|
-
class:
|
|
747
|
-
style:
|
|
748
|
-
onPointermove:
|
|
1072
|
+
class: r.value,
|
|
1073
|
+
style: K(a),
|
|
1074
|
+
onPointermove: K(o)
|
|
749
1075
|
}), {
|
|
750
|
-
default:
|
|
1076
|
+
default: X(() => [U(e.$slots, "default")]),
|
|
751
1077
|
_: 3
|
|
752
1078
|
}, 16, [
|
|
753
1079
|
"as",
|
|
@@ -757,7 +1083,7 @@ var Te = { key: 1 }, Ee = { key: 2 }, De = /* @__PURE__ */ S({
|
|
|
757
1083
|
"onPointermove"
|
|
758
1084
|
]));
|
|
759
1085
|
}
|
|
760
|
-
}),
|
|
1086
|
+
}), et = /* @__PURE__ */ k({
|
|
761
1087
|
__name: "DockBackgroundToggle",
|
|
762
1088
|
props: {
|
|
763
1089
|
paused: {
|
|
@@ -769,22 +1095,22 @@ var Te = { key: 1 }, Ee = { key: 2 }, De = /* @__PURE__ */ S({
|
|
|
769
1095
|
},
|
|
770
1096
|
emits: ["update:paused"],
|
|
771
1097
|
setup(e, { emit: t }) {
|
|
772
|
-
let n = e, r = t, i =
|
|
1098
|
+
let n = e, r = t, i = C(() => n.paused ? n.playLabel : n.pauseLabel);
|
|
773
1099
|
function a() {
|
|
774
1100
|
r("update:paused", !n.paused);
|
|
775
1101
|
}
|
|
776
|
-
return (t, n) => (
|
|
1102
|
+
return (t, n) => (z(), w($e, {
|
|
777
1103
|
type: "button",
|
|
778
1104
|
"aria-pressed": e.paused,
|
|
779
1105
|
"aria-label": i.value,
|
|
780
1106
|
title: i.value,
|
|
781
1107
|
onClick: a
|
|
782
1108
|
}, {
|
|
783
|
-
default:
|
|
1109
|
+
default: X(() => [e.paused ? (z(), w(K(fe), {
|
|
784
1110
|
key: 0,
|
|
785
1111
|
size: 18,
|
|
786
1112
|
"aria-hidden": "true"
|
|
787
|
-
})) : (
|
|
1113
|
+
})) : (z(), w(K(de), {
|
|
788
1114
|
key: 1,
|
|
789
1115
|
size: 18,
|
|
790
1116
|
"aria-hidden": "true"
|
|
@@ -796,7 +1122,7 @@ var Te = { key: 1 }, Ee = { key: 2 }, De = /* @__PURE__ */ S({
|
|
|
796
1122
|
"title"
|
|
797
1123
|
]));
|
|
798
1124
|
}
|
|
799
|
-
}),
|
|
1125
|
+
}), tt = /* @__PURE__ */ k({
|
|
800
1126
|
__name: "DockTabButton",
|
|
801
1127
|
props: {
|
|
802
1128
|
as: { default: "button" },
|
|
@@ -813,13 +1139,13 @@ var Te = { key: 1 }, Ee = { key: 2 }, De = /* @__PURE__ */ S({
|
|
|
813
1139
|
] }
|
|
814
1140
|
},
|
|
815
1141
|
setup(t) {
|
|
816
|
-
let n = t, r =
|
|
817
|
-
return (e, n) => (
|
|
1142
|
+
let n = t, r = C(() => e("dock-tab-button", n.class));
|
|
1143
|
+
return (e, n) => (z(), w(K(ne), {
|
|
818
1144
|
as: t.as,
|
|
819
1145
|
"as-child": t.asChild,
|
|
820
|
-
class:
|
|
1146
|
+
class: N(r.value)
|
|
821
1147
|
}, {
|
|
822
|
-
default:
|
|
1148
|
+
default: X(() => [U(e.$slots, "default")]),
|
|
823
1149
|
_: 3
|
|
824
1150
|
}, 8, [
|
|
825
1151
|
"as",
|
|
@@ -827,7 +1153,7 @@ var Te = { key: 1 }, Ee = { key: 2 }, De = /* @__PURE__ */ S({
|
|
|
827
1153
|
"class"
|
|
828
1154
|
]));
|
|
829
1155
|
}
|
|
830
|
-
}),
|
|
1156
|
+
}), nt = /* @__PURE__ */ k({
|
|
831
1157
|
__name: "DockSelectTrigger",
|
|
832
1158
|
props: {
|
|
833
1159
|
disabled: { type: Boolean },
|
|
@@ -843,19 +1169,19 @@ var Te = { key: 1 }, Ee = { key: 2 }, De = /* @__PURE__ */ S({
|
|
|
843
1169
|
] }
|
|
844
1170
|
},
|
|
845
1171
|
setup(t) {
|
|
846
|
-
let r = t, i =
|
|
1172
|
+
let r = t, i = ce(C(() => {
|
|
847
1173
|
let { class: e, ...t } = r;
|
|
848
1174
|
return t;
|
|
849
1175
|
}));
|
|
850
|
-
return (t, a) => (
|
|
851
|
-
default:
|
|
852
|
-
default:
|
|
1176
|
+
return (t, a) => (z(), w(K(ie), j(K(i), { class: K(e)("dock-select-trigger", r.class) }), {
|
|
1177
|
+
default: X(() => [U(t.$slots, "default"), O(K(re), { "as-child": "" }, {
|
|
1178
|
+
default: X(() => [U(t.$slots, "icon", {}, () => [O(K(n), { class: "dock-select-trigger__chevron" })])]),
|
|
853
1179
|
_: 3
|
|
854
1180
|
})]),
|
|
855
1181
|
_: 3
|
|
856
1182
|
}, 16, ["class"]));
|
|
857
1183
|
}
|
|
858
|
-
}),
|
|
1184
|
+
}), rt = /* @__PURE__ */ k({
|
|
859
1185
|
__name: "DockDropdownTrigger",
|
|
860
1186
|
props: {
|
|
861
1187
|
disabled: { type: Boolean },
|
|
@@ -871,15 +1197,218 @@ var Te = { key: 1 }, Ee = { key: 2 }, De = /* @__PURE__ */ S({
|
|
|
871
1197
|
] }
|
|
872
1198
|
},
|
|
873
1199
|
setup(t) {
|
|
874
|
-
let n = t, r =
|
|
1200
|
+
let n = t, r = ce(C(() => {
|
|
875
1201
|
let { class: e, ...t } = n;
|
|
876
1202
|
return t;
|
|
877
1203
|
}));
|
|
878
|
-
return (t, i) => (
|
|
879
|
-
default:
|
|
1204
|
+
return (t, i) => (z(), w(K(Z), j(K(r), { class: K(e)("dock-dropdown-trigger", n.class) }), {
|
|
1205
|
+
default: X(() => [U(t.$slots, "default")]),
|
|
880
1206
|
_: 3
|
|
881
1207
|
}, 16, ["class"]));
|
|
882
1208
|
}
|
|
1209
|
+
}), it = [
|
|
1210
|
+
"data-orientation",
|
|
1211
|
+
"data-rail-anchor",
|
|
1212
|
+
"aria-orientation"
|
|
1213
|
+
], at = /* @__PURE__ */ k({
|
|
1214
|
+
__name: "DockSeparator",
|
|
1215
|
+
props: { anchor: {
|
|
1216
|
+
type: Boolean,
|
|
1217
|
+
default: !1
|
|
1218
|
+
} },
|
|
1219
|
+
setup(e) {
|
|
1220
|
+
let t = f(), n = C(() => t?.orientation.value ?? "horizontal"), r = C(() => n.value), i = C(() => n.value === "vertical" ? "horizontal" : "vertical");
|
|
1221
|
+
return (t, n) => (z(), E("div", {
|
|
1222
|
+
class: N(["dock-separator", { "dock-separator--anchor": e.anchor }]),
|
|
1223
|
+
role: "separator",
|
|
1224
|
+
"data-orientation": r.value,
|
|
1225
|
+
"data-rail-anchor": e.anchor || void 0,
|
|
1226
|
+
"aria-orientation": i.value
|
|
1227
|
+
}, null, 10, it));
|
|
1228
|
+
}
|
|
1229
|
+
}), ot = ["data-orientation", "aria-label"], st = ["aria-label"], ct = { class: "dock-hairline-extend-chip-label" }, lt = /* @__PURE__ */ k({
|
|
1230
|
+
__name: "DockRail",
|
|
1231
|
+
props: /* @__PURE__ */ A({
|
|
1232
|
+
extent: { default: "beyond" },
|
|
1233
|
+
position: { default: "end" },
|
|
1234
|
+
items: {},
|
|
1235
|
+
icon: {},
|
|
1236
|
+
iconLabel: { default: "Switch dock context" }
|
|
1237
|
+
}, {
|
|
1238
|
+
context: {},
|
|
1239
|
+
contextModifiers: {}
|
|
1240
|
+
}),
|
|
1241
|
+
emits: /* @__PURE__ */ A(["advance"], ["update:context"]),
|
|
1242
|
+
setup(e, { emit: t }) {
|
|
1243
|
+
let n = e, i = q(e, "context"), a = t, o = f(), s = C(() => o?.orientation.value ?? "horizontal"), c = C(() => n.icon ?? r), l = C(() => n.items && n.items.length > 0 ? [...n.items] : []);
|
|
1244
|
+
function u(e) {
|
|
1245
|
+
i.value = e, a("advance", e);
|
|
1246
|
+
}
|
|
1247
|
+
return (t, n) => (z(), E("div", {
|
|
1248
|
+
class: N(["dock-hairline-extend", [
|
|
1249
|
+
s.value,
|
|
1250
|
+
`extent-${e.extent}`,
|
|
1251
|
+
`at-${e.position}`
|
|
1252
|
+
]]),
|
|
1253
|
+
"data-orientation": s.value,
|
|
1254
|
+
role: "group",
|
|
1255
|
+
"aria-label": e.iconLabel
|
|
1256
|
+
}, [O(v, {
|
|
1257
|
+
axis: "x",
|
|
1258
|
+
class: "dock-hairline-fade"
|
|
1259
|
+
}, {
|
|
1260
|
+
default: X(() => [D("div", {
|
|
1261
|
+
class: "dock-hairline-strip",
|
|
1262
|
+
role: "tablist",
|
|
1263
|
+
"aria-label": e.iconLabel
|
|
1264
|
+
}, [(z(!0), E(S, null, H(l.value, (e) => (z(), w($e, {
|
|
1265
|
+
key: e.id,
|
|
1266
|
+
type: "button",
|
|
1267
|
+
class: N(["dock-hairline-extend-chip", { "is-active": i.value === e.id }]),
|
|
1268
|
+
role: "tab",
|
|
1269
|
+
"aria-selected": i.value === e.id,
|
|
1270
|
+
"aria-label": e.label,
|
|
1271
|
+
title: e.label,
|
|
1272
|
+
onClick: (t) => u(e.id)
|
|
1273
|
+
}, {
|
|
1274
|
+
default: X(() => [(z(), w(W(e.icon ?? c.value), { class: "size-4" })), D("span", ct, G(e.label), 1)]),
|
|
1275
|
+
_: 2
|
|
1276
|
+
}, 1032, [
|
|
1277
|
+
"class",
|
|
1278
|
+
"aria-selected",
|
|
1279
|
+
"aria-label",
|
|
1280
|
+
"title",
|
|
1281
|
+
"onClick"
|
|
1282
|
+
]))), 128))], 8, st)]),
|
|
1283
|
+
_: 1
|
|
1284
|
+
})], 10, ot));
|
|
1285
|
+
}
|
|
1286
|
+
}), ut = ["aria-label"], dt = [
|
|
1287
|
+
"data-kind",
|
|
1288
|
+
"data-section-id",
|
|
1289
|
+
"aria-label"
|
|
1290
|
+
], ft = /* @__PURE__ */ k({
|
|
1291
|
+
__name: "DockSection",
|
|
1292
|
+
props: {
|
|
1293
|
+
sections: {},
|
|
1294
|
+
anchorId: {},
|
|
1295
|
+
ariaLabel: { default: "Dock sections" }
|
|
1296
|
+
},
|
|
1297
|
+
setup(e) {
|
|
1298
|
+
let t = e, n = C(() => {
|
|
1299
|
+
if (t.anchorId) return t.anchorId;
|
|
1300
|
+
let e = t.sections.find((e) => e.kind === "nav");
|
|
1301
|
+
return e ? e.id : t.sections.find((e) => e.kind !== "rail-core")?.id;
|
|
1302
|
+
});
|
|
1303
|
+
function r(e) {
|
|
1304
|
+
return e > 0;
|
|
1305
|
+
}
|
|
1306
|
+
function i(e) {
|
|
1307
|
+
return e.id === n.value;
|
|
1308
|
+
}
|
|
1309
|
+
function a(e) {
|
|
1310
|
+
return `dock-section-zone--${e === "rail-core" ? "core" : e}`;
|
|
1311
|
+
}
|
|
1312
|
+
return (t, n) => (z(), E("div", {
|
|
1313
|
+
class: "dock-section",
|
|
1314
|
+
role: "group",
|
|
1315
|
+
"aria-label": e.ariaLabel
|
|
1316
|
+
}, [(z(!0), E(S, null, H(e.sections, (e, n) => (z(), E(S, { key: e.id }, [r(n) ? (z(), w(at, {
|
|
1317
|
+
key: 0,
|
|
1318
|
+
anchor: i(e)
|
|
1319
|
+
}, null, 8, ["anchor"])) : T("", !0), D("div", {
|
|
1320
|
+
class: N(["dock-section-zone", a(e.kind)]),
|
|
1321
|
+
"data-kind": e.kind,
|
|
1322
|
+
"data-section-id": e.id,
|
|
1323
|
+
"aria-label": e.label || void 0
|
|
1324
|
+
}, [U(t.$slots, e.id, {
|
|
1325
|
+
section: e,
|
|
1326
|
+
kind: e.kind
|
|
1327
|
+
})], 10, dt)], 64))), 128))], 8, ut));
|
|
1328
|
+
}
|
|
883
1329
|
});
|
|
884
1330
|
//#endregion
|
|
885
|
-
|
|
1331
|
+
//#region src/components/custom/dock/composables/useDockOrientationMorph.ts
|
|
1332
|
+
function pt(e) {
|
|
1333
|
+
let { rootEl: t } = e, n = V("vertical"), r = V(0), i = V(!1), a = y({
|
|
1334
|
+
from: e.verticalSize,
|
|
1335
|
+
to: 0,
|
|
1336
|
+
axis: "height"
|
|
1337
|
+
}), o = y({
|
|
1338
|
+
from: 0,
|
|
1339
|
+
to: e.horizontalSize,
|
|
1340
|
+
axis: "width"
|
|
1341
|
+
}), s = null;
|
|
1342
|
+
function c(e) {
|
|
1343
|
+
r.value = e, a.drive(e), o.drive(e);
|
|
1344
|
+
let n = t.value;
|
|
1345
|
+
n && n.style.setProperty("--dock-morph-t", `${e}`);
|
|
1346
|
+
}
|
|
1347
|
+
function l() {
|
|
1348
|
+
s &&= (s.dispose(), null);
|
|
1349
|
+
}
|
|
1350
|
+
function u() {
|
|
1351
|
+
return typeof window < "u" && typeof window.matchMedia == "function" && window.matchMedia("(prefers-reduced-motion: reduce)").matches;
|
|
1352
|
+
}
|
|
1353
|
+
function d(e) {
|
|
1354
|
+
if (u()) {
|
|
1355
|
+
m(e);
|
|
1356
|
+
return;
|
|
1357
|
+
}
|
|
1358
|
+
let n = t.value, a = s !== null && !s.settled ? s.velocity : 0;
|
|
1359
|
+
if (!s || s.settled) {
|
|
1360
|
+
l(), s = new ue({
|
|
1361
|
+
response: g.response,
|
|
1362
|
+
dampingFraction: g.dampingFraction,
|
|
1363
|
+
initial: r.value,
|
|
1364
|
+
respectReducedMotion: !0
|
|
1365
|
+
});
|
|
1366
|
+
let o = s;
|
|
1367
|
+
o.reset(r.value, a), o.target = e, i.value = !0, n && n.setAttribute("data-morphing", ""), o.play((e) => {
|
|
1368
|
+
if (c(e), o.settled) {
|
|
1369
|
+
i.value = !1;
|
|
1370
|
+
let e = t.value;
|
|
1371
|
+
e && e.removeAttribute("data-morphing");
|
|
1372
|
+
}
|
|
1373
|
+
});
|
|
1374
|
+
} else s.reset(r.value, a), s.target = e;
|
|
1375
|
+
}
|
|
1376
|
+
function f(e) {
|
|
1377
|
+
e === n.value && !i.value || (n.value = e, d(+(e === "horizontal")));
|
|
1378
|
+
}
|
|
1379
|
+
function p() {
|
|
1380
|
+
f(n.value === "vertical" ? "horizontal" : "vertical");
|
|
1381
|
+
}
|
|
1382
|
+
function m(e) {
|
|
1383
|
+
let r = e < 0 ? 0 : e > 1 ? 1 : e;
|
|
1384
|
+
l(), i.value = !1, n.value = r >= .5 ? "horizontal" : "vertical", c(r), c(r);
|
|
1385
|
+
let a = t.value;
|
|
1386
|
+
a && a.removeAttribute("data-morphing");
|
|
1387
|
+
}
|
|
1388
|
+
function h(e) {
|
|
1389
|
+
let t = Math.min(Math.max(e / .5, 0), 1);
|
|
1390
|
+
return 1 - t * t * (3 - 2 * t);
|
|
1391
|
+
}
|
|
1392
|
+
function _(e) {
|
|
1393
|
+
let t = Math.min(Math.max((e - .5) / .5, 0), 1);
|
|
1394
|
+
return t * t * (3 - 2 * t);
|
|
1395
|
+
}
|
|
1396
|
+
let v = C(() => a.sizeStyle.value), b = C(() => o.sizeStyle.value), x = C(() => ({ opacity: String(h(r.value)) })), S = C(() => ({ opacity: String(_(r.value)) })), w = C(() => Math.max(a.stretch.value, o.stretch.value));
|
|
1397
|
+
return Y(t, (e) => {
|
|
1398
|
+
e && e.style.setProperty("--dock-morph-t", `${r.value}`);
|
|
1399
|
+
}, { immediate: !0 }), L(l), {
|
|
1400
|
+
orientation: n,
|
|
1401
|
+
t: r,
|
|
1402
|
+
morphing: i,
|
|
1403
|
+
verticalStyle: v,
|
|
1404
|
+
horizontalStyle: b,
|
|
1405
|
+
verticalOpacity: x,
|
|
1406
|
+
horizontalOpacity: S,
|
|
1407
|
+
stretch: w,
|
|
1408
|
+
morphTo: f,
|
|
1409
|
+
toggle: p,
|
|
1410
|
+
pin: m
|
|
1411
|
+
};
|
|
1412
|
+
}
|
|
1413
|
+
//#endregion
|
|
1414
|
+
export { _ as DOCK_CONTEXT_KEY, et as DockBackgroundToggle, rt as DockDropdownTrigger, $e as DockIconButton, Qe as DockLayer, Xe as DockLayerGroup, lt as DockRail, ft as DockSection, nt as DockSelectTrigger, at as DockSeparator, tt as DockTabButton, Re as GlassDock, p as provideDockContext, h as useDockContext, pt as useDockOrientationMorph, qe as useLayerTransition, f as useOptionalDockContext };
|