@mkbabb/glass-ui 3.2.0 → 3.4.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/{CardFooter-3-VGho1J.js → CardFooter-C390imy7.js} +2 -2
- package/dist/{CollapsibleContent-wlmlDujU.js → CollapsibleContent-cauTbZEM.js} +1 -1
- package/dist/{CommandShortcut-C6lsz3pG.js → CommandShortcut-BiVyqipe.js} +5 -4
- package/dist/DataTable-FfkaAg2z.js +465 -0
- package/dist/DialogContent-IQ8_BRrC.js +100 -0
- package/dist/{DiscoGlyph-B7YooI2-.js → DiscoGlyph-BaZ8OawK.js} +1 -1
- package/dist/{GlyphFace-Bvk6OIas.js → GlyphFace-B_7vOmYn.js} +1 -1
- package/dist/HoverPopover-DTSYkJtw.js +96 -0
- package/dist/{IconTooltip-DXveGjx7.js → IconTooltip-BTyYn4mr.js} +1 -1
- package/dist/Input-CU9CNKmo.js +52 -0
- package/dist/{MetricBadge-J_GBCb8e.js → MetricBadge-BlrdbOGN.js} +1 -1
- package/dist/{NumberFieldContent-B6L6YrQz.js → NumberFieldContent-iOTQ5rGO.js} +8 -4
- package/dist/{PopoverContent-CxEEUL7Y.js → PopoverContent-B8WtJECb.js} +1 -1
- package/dist/Progress-DjM86vfb.js +254 -0
- package/dist/{ScrollingText-1Qjnwz6H.js → ScrollingText-P9o_DuMn.js} +1 -1
- package/dist/{SelectScrollDownButton-BvvvAbuh.js → SelectScrollDownButton-BGn3rjs9.js} +9 -8
- package/dist/TabsIndicator-DA0x9gPr.js +97 -0
- package/dist/{ToggleGroupItem-Cy7xHFEo.js → ToggleGroupItem-gyXj998A.js} +37 -40
- package/dist/UnderlineTabs-Cq_AD03t.js +39 -0
- package/dist/animated-digit.js +2 -2
- package/dist/api/index.d.ts +2 -0
- package/dist/api.js +1 -1
- package/dist/aurora.js +454 -271
- package/dist/{button-DS3ULf5i.js → button-Ckn3eDfB.js} +27 -22
- package/dist/button.js +1 -1
- package/dist/card.js +1 -1
- package/dist/carousel.js +2 -2
- package/dist/collapsible.js +1 -1
- package/dist/color-rkK4RMx2.js +33 -0
- package/dist/color.d.ts +1 -0
- package/dist/color.js +2 -0
- package/dist/command.js +1 -1
- package/dist/compile-DVgAxagk.js +106 -0
- package/dist/components/custom/animated-digit/AnimatedDigit.vue.d.ts +7 -7
- package/dist/components/custom/aurora/Aurora.vue.d.ts +3 -3
- package/dist/components/custom/aurora/composables/color.d.ts +3 -25
- package/dist/components/custom/aurora/composables/cursorModel.d.ts +45 -0
- package/dist/components/custom/aurora/composables/frameLoop.d.ts +30 -0
- package/dist/components/custom/aurora/composables/glSetup.d.ts +29 -0
- package/dist/components/custom/aurora/composables/runtime.d.ts +45 -35
- package/dist/components/custom/aurora/composables/uniformBridge.d.ts +67 -0
- package/dist/components/custom/aurora/composables/useAurora.d.ts +14 -1
- package/dist/components/custom/aurora/composables/useCursorInteraction.d.ts +1 -1
- package/dist/components/custom/aurora/constants/budget.d.ts +50 -0
- package/dist/components/custom/aurora/{presets.d.ts → constants/presets.d.ts} +2 -5
- package/dist/components/custom/aurora/constants/shaders/aurora.frag.d.ts +1 -0
- package/dist/components/custom/aurora/constants/shaders/brush.glsl.d.ts +1 -0
- package/dist/components/custom/aurora/constants/shaders/composition.glsl.d.ts +1 -0
- package/dist/components/custom/aurora/constants/shaders/flow.glsl.d.ts +1 -0
- package/dist/components/custom/aurora/constants/shaders/mediums.glsl.d.ts +2 -0
- package/dist/components/custom/aurora/constants/shaders/tonemap.glsl.d.ts +1 -0
- package/dist/components/custom/aurora/index.d.ts +2 -2
- package/dist/components/custom/configurator/ConfiguratorLayer.vue.d.ts +14 -7
- package/dist/components/custom/configurator/density.d.ts +3 -8
- package/dist/components/custom/dock/DockBackgroundToggle.vue.d.ts +46 -0
- package/dist/components/custom/dock/DockIconButton.vue.d.ts +3 -3
- package/dist/components/custom/dock/DockLayerGroup.vue.d.ts +2 -2
- package/dist/components/custom/dock/GlassDock.vue.d.ts +22 -18
- package/dist/components/custom/dock/composables/dockContext.d.ts +4 -4
- package/dist/components/custom/dock/composables/dockLayerContext.d.ts +13 -6
- package/dist/components/custom/dock/composables/useLayerTransition.d.ts +32 -8
- package/dist/components/custom/dock/index.d.ts +1 -0
- package/dist/components/custom/expandable-container/ExpandableContainer.vue.d.ts +10 -0
- package/dist/components/custom/glass-panel/GlassPanel.vue.d.ts +1 -1
- package/dist/components/custom/glyph-face/keys.d.ts +3 -29
- package/dist/components/custom/goo-blob/GooBlob.vue.d.ts +48 -0
- package/dist/components/custom/goo-blob/composables/easing.d.ts +6 -0
- package/dist/components/custom/goo-blob/composables/useBlobMood.d.ts +14 -0
- package/dist/components/custom/goo-blob/composables/useBlobPointer.d.ts +18 -0
- package/dist/components/custom/goo-blob/composables/useBlobSatellites.d.ts +13 -0
- package/dist/components/custom/goo-blob/composables/useMetaballRenderer.d.ts +42 -0
- package/dist/components/custom/goo-blob/index.d.ts +7 -0
- package/dist/components/custom/goo-blob/shaders/metaball.frag.d.ts +1 -0
- package/dist/components/custom/goo-blob/shaders/metaball.vert.d.ts +1 -0
- package/dist/components/custom/goo-blob/shaders/oklch-perturb.glsl.d.ts +1 -0
- package/dist/components/custom/goo-blob/shaders/sdf-body.glsl.d.ts +1 -0
- package/dist/components/custom/goo-blob/shaders/watercolor-edges.glsl.d.ts +2 -0
- package/dist/components/custom/goo-blob/types.d.ts +77 -0
- package/dist/components/custom/hover-popover/HoverPopover.vue.d.ts +48 -9
- package/dist/components/custom/labeled-field/LabeledField.vue.d.ts +2 -0
- package/dist/components/custom/labeled-field/LabeledSelect.vue.d.ts +2 -2
- package/dist/components/custom/metric-stack/MetricRow.vue.d.ts +2 -2
- package/dist/components/custom/responsive-tabs/ResponsiveTabs.vue.d.ts +13 -7
- package/dist/components/custom/search/FuzzySearch.vue.d.ts +1 -1
- package/dist/components/custom/search/SearchBar.vue.d.ts +1 -1
- package/dist/components/custom/sortable-list/SortableHandle.vue.d.ts +7 -1
- package/dist/components/custom/sortable-list/context.d.ts +2 -3
- package/dist/components/custom/tabs/BouncyTabs.vue.d.ts +6 -3
- package/dist/components/custom/tabs/BouncyToggle.vue.d.ts +7 -3
- package/dist/components/custom/tabs/UnderlineTabs.vue.d.ts +6 -3
- package/dist/components/custom/tabs/composables/useBouncySlider.d.ts +39 -0
- package/dist/components/custom/timeline/ContinuousMarkers.vue.d.ts +49 -0
- package/dist/components/custom/timeline/ContinuousRail.vue.d.ts +26 -0
- package/dist/components/custom/timeline/ContinuousTimeline.vue.d.ts +4 -4
- package/dist/components/custom/typewriter/TypewriterText.vue.d.ts +2 -2
- package/dist/components/custom/watercolor-dot/WatercolorDot.vue.d.ts +45 -0
- package/dist/components/custom/watercolor-dot/index.d.ts +3 -0
- package/dist/components/custom/watercolor-dot/prng.d.ts +5 -0
- package/dist/components/custom/watercolor-dot/useWatercolorBlob.d.ts +24 -0
- package/dist/components/ui/_shared/menuItemVariants.d.ts +1 -1
- package/dist/components/ui/avatar/Avatar.vue.d.ts +1 -1
- package/dist/components/ui/avatar/AvatarImage.vue.d.ts +5 -1
- package/dist/components/ui/avatar/index.d.ts +1 -1
- package/dist/components/ui/badge/index.d.ts +2 -2
- package/dist/components/ui/button/Button.vue.d.ts +3 -1
- package/dist/components/ui/button/index.d.ts +2 -2
- package/dist/components/ui/carousel/CarouselNext.vue.d.ts +2 -2
- package/dist/components/ui/carousel/CarouselPrevious.vue.d.ts +2 -2
- package/dist/components/ui/combobox/Combobox.vue.d.ts +2 -2
- package/dist/components/ui/combobox/ComboboxInput.vue.d.ts +2 -1
- package/dist/components/ui/command/Command.vue.d.ts +3 -3
- package/dist/components/ui/command/CommandInput.vue.d.ts +2 -1
- package/dist/components/ui/data-table/DataTable.vue.d.ts +5 -4
- package/dist/components/ui/dialog/DialogContent.vue.d.ts +8 -0
- package/dist/components/ui/drawer/Drawer.vue.d.ts +4 -4
- package/dist/components/ui/input/Input.vue.d.ts +19 -1
- package/dist/components/ui/multi-select/MultiSelect.vue.d.ts +8 -4
- package/dist/components/ui/progress/Progress.vue.d.ts +26 -88
- package/dist/components/ui/progress/ProgressDefault.vue.d.ts +14 -0
- package/dist/components/ui/progress/ProgressGradient.vue.d.ts +25 -0
- package/dist/components/ui/progress/ProgressSectioned.vue.d.ts +36 -0
- package/dist/components/ui/progress/index.d.ts +5 -2
- package/dist/components/ui/progress/useProgressGeometry.d.ts +60 -0
- package/dist/components/ui/select/Select.vue.d.ts +2 -2
- package/dist/components/ui/select/SelectContent.vue.d.ts +1 -1
- package/dist/components/ui/select/SelectTrigger.vue.d.ts +3 -0
- package/dist/components/ui/sheet/index.d.ts +1 -1
- package/dist/components/ui/slider/index.d.ts +12 -11
- package/dist/components/ui/tags-input/TagsInput.vue.d.ts +2 -2
- package/dist/components/ui/textarea/Textarea.vue.d.ts +5 -1
- package/dist/components/ui/toast/Toast.vue.d.ts +4 -4
- 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/toggleGroupContext.d.ts +2 -3
- package/dist/composables/color/index.d.ts +49 -0
- package/dist/composables/context/createContext.d.ts +56 -0
- package/dist/composables/context/index.d.ts +1 -0
- package/dist/composables/dark/darkModeSyncScript.d.ts +23 -0
- package/dist/composables/dark/index.d.ts +3 -0
- package/dist/composables/dark/useGlobalDark.d.ts +19 -2
- package/dist/composables/dom/index.d.ts +0 -3
- package/dist/composables/dom/useClipboard.d.ts +35 -12
- package/dist/composables/dom/useDocumentVisibility.d.ts +20 -0
- package/dist/composables/glass/webgl/compile.d.ts +15 -0
- package/dist/composables/glass/webgl/shaders/procedural-color.glsl.d.ts +3 -0
- package/dist/composables/glass/webgl/useWebGLCanvas.d.ts +55 -0
- package/dist/composables/motion/core/index.d.ts +1 -1
- package/dist/composables/motion/index.d.ts +1 -1
- package/dist/composables/motion/useCountup.d.ts +29 -0
- package/dist/composables/motion/useNumericTransition.d.ts +14 -3
- package/dist/composables/motion/vReveal.d.ts +2 -0
- package/dist/composables/sidebar/useSidebarState.d.ts +2 -2
- package/dist/composables/sortable/dragController.d.ts +44 -0
- package/dist/composables/sortable/dropResolver.d.ts +34 -0
- package/dist/composables/sortable/ghostRenderer.d.ts +44 -0
- package/dist/composables/sortable/index.d.ts +1 -1
- package/dist/composables/sortable/touchGate.d.ts +26 -0
- package/dist/composables/sortable/transitionTiming.d.ts +50 -0
- package/dist/composables/sortable/types.d.ts +133 -0
- package/dist/composables/sortable/useSortable.d.ts +25 -153
- package/dist/configurator.js +1 -1
- package/dist/confirm-dialog.js +1 -1
- package/dist/controls.js +4 -4
- package/dist/createContext-DBMGRlx4.js +25 -0
- package/dist/dark.d.ts +2 -1
- package/dist/dark.js +9 -2
- package/dist/data-table.js +1 -1
- package/dist/dialog.js +1 -1
- package/dist/disco-glyph.js +1 -1
- package/dist/dock.js +400 -261
- package/dist/dockContext-spUj_-E5.js +9 -0
- package/dist/dom.js +6 -6
- package/dist/{dropdown-menu-naE0skDg.js → dropdown-menu-EFjl5iKo.js} +1 -1
- package/dist/dropdown-menu.js +1 -1
- package/dist/expandable-container.js +26 -20
- package/dist/fonts/README.md +21 -0
- package/dist/fonts/fraunces/fraunces-latin.woff2 +0 -0
- package/dist/forms.js +68 -59
- package/dist/glass-panel.js +1 -1
- package/dist/glass-ui.css +1 -1
- package/dist/glass-ui.js +226 -328
- package/dist/glyph-face.js +2 -2
- package/dist/goo-blob.d.ts +1 -0
- package/dist/goo-blob.js +538 -0
- package/dist/header-ribbon.js +2 -2
- package/dist/hover-card.js +1 -1
- package/dist/hover-popover.js +1 -1
- package/dist/icon-tooltip.js +1 -1
- package/dist/index.d.ts +1 -0
- package/dist/instrument-chassis.js +1 -1
- package/dist/instrument-rail.js +1 -1
- package/dist/keys-BFoma9vm.js +9 -0
- package/dist/label.js +1 -1
- package/dist/labeled-field.js +57 -39
- package/dist/metric-badge.js +1 -1
- package/dist/motion-core.js +82 -123
- package/dist/motion.js +62 -14
- package/dist/number-field.js +1 -1
- package/dist/paper-backdrop.js +1 -1
- package/dist/popover.js +1 -1
- package/dist/{presets-BpTf63Hp.js → presets-1OhFpaIC.js} +1 -1
- package/dist/prng-Bz_1Tydc.js +15 -0
- package/dist/progress.js +2 -2
- package/dist/reactive.js +2 -2
- package/dist/responsive-tabs.js +38 -32
- package/dist/scrolling-text.js +1 -1
- package/dist/search.js +8 -8
- package/dist/select.js +3 -3
- package/dist/separator.js +1 -1
- package/dist/sheet.js +1 -1
- package/dist/{slider-wx8ifVFB.js → slider-BOh8ycfZ.js} +7 -11
- package/dist/slider.js +1 -1
- package/dist/sortable-list.js +36 -38
- package/dist/stacked-icons.js +2 -2
- package/dist/styles/animations.css +1 -1
- package/dist/styles/cards.css +1 -1
- package/dist/styles/components.css +1 -1
- package/dist/styles/dock-controls.css +486 -0
- package/dist/styles/dock.css +284 -450
- package/dist/styles/fonts.css +25 -0
- package/dist/styles/glass-specular-track.css +154 -0
- package/dist/styles/glass.css +74 -2
- package/dist/styles/index.css +21 -2
- package/dist/styles/instrument-chassis.css +11 -4
- package/dist/styles/theme.css +73 -21
- package/dist/styles/tokens.css +271 -140
- package/dist/styles/typography.css +14 -8
- package/dist/styles/utilities.css +36 -8
- package/dist/styles/view-transition.css +10 -4
- package/dist/switch.js +1 -1
- package/dist/tabs.js +139 -112
- package/dist/timeline.js +219 -158
- package/dist/toast.js +1 -1
- package/dist/toggle-group.js +1 -1
- package/dist/tokens.d.ts +1 -1
- package/dist/tooltip.js +1 -1
- package/dist/{useAnimatedNumber-BOxrS3a6.js → useAnimatedNumber-BF6r64lA.js} +1 -1
- package/dist/useClipboard-D8vFyRCa.js +97 -0
- package/dist/{useConfiguratorState-Dq2gNv4A.js → useConfiguratorState-DUtC1jxr.js} +82 -86
- package/dist/useGlobalDark-CWiaCoEw.js +34 -0
- package/dist/useIntersectionPause-DAdVPVp4.js +53 -0
- package/dist/useSortable-DnyGXKKY.js +246 -0
- package/dist/{useTouchGate-XX8gHfay.js → useTouchGate-CS5Csc2h.js} +1 -1
- package/dist/utils/prng.d.ts +4 -0
- package/dist/vReveal-u2wSG2El.js +35 -0
- package/dist/watercolor-dot.d.ts +1 -0
- package/dist/watercolor-dot.js +129 -0
- package/package.json +101 -16
- package/src/fonts/README.md +21 -0
- package/src/fonts/fraunces/fraunces-latin.woff2 +0 -0
- package/src/styles/animations.css +1 -1
- package/src/styles/cards.css +1 -1
- package/src/styles/dock-controls.css +486 -0
- package/src/styles/dock.css +284 -450
- package/src/styles/fonts.css +25 -0
- package/src/styles/glass-specular-track.css +154 -0
- package/src/styles/glass.css +74 -2
- package/src/styles/index.css +21 -2
- package/src/styles/instrument-chassis.css +11 -4
- package/src/styles/theme.css +73 -21
- package/src/styles/tokens.css +271 -140
- package/src/styles/typography.css +14 -8
- package/src/styles/utilities.css +36 -8
- package/src/styles/view-transition.css +10 -4
- package/dist/DataTable-BsrDYdoE.js +0 -460
- package/dist/DialogContent-B61rP8lj.js +0 -93
- package/dist/HoverPopover-BlEwqG7S.js +0 -96
- package/dist/Input-IFsIzId2.js +0 -30
- package/dist/Progress-Bs44qWEM.js +0 -126
- package/dist/UnderlineTabs-B4FV2zi_.js +0 -37
- package/dist/components/custom/aurora/shaders/aurora.frag.d.ts +0 -1
- package/dist/composables/dom/useBreakpoint.d.ts +0 -38
- package/dist/composables/dom/useIdleReady.d.ts +0 -63
- package/dist/composables/dom/useViewportReady.d.ts +0 -87
- package/dist/composables/glass/webgl/frostShader.d.ts +0 -27
- package/dist/composables/motion/useAnimatedNumberMap.d.ts +0 -29
- package/dist/composables/motion/useStagger.d.ts +0 -50
- package/dist/dockContext-DM58L1Jt.js +0 -16
- package/dist/keys-SIKQYNx1.js +0 -11
- package/dist/supportsCssTimeline-IQY3gfKD.js +0 -12
- package/dist/useGlobalDark-BUUTZvkU.js +0 -24
- package/dist/useIdleReady-sLhGo6CL.js +0 -162
- package/dist/useIntersectionPause-CUmANkoc.js +0 -39
- package/dist/useSortable-DLK9kwZp.js +0 -189
- /package/dist/{HoverCardContent-DGUhpRVt.js → HoverCardContent-ICfIMZX1.js} +0 -0
- /package/dist/{InstrumentChassis-CqKPBNqp.js → InstrumentChassis-DaHIZCqy.js} +0 -0
- /package/dist/{InstrumentRail-CCjvKkpB.js → InstrumentRail-B0qqLFN0.js} +0 -0
- /package/dist/{Label-D53EOwLE.js → Label-CZk-3nTc.js} +0 -0
- /package/dist/{PaperBackdrop-Ds-wDsKf.js → PaperBackdrop-D_YZW47j.js} +0 -0
- /package/dist/{SelectGroup-DAgcsfFw.js → SelectGroup-CMdoCjRE.js} +0 -0
- /package/dist/{SelectSeparator-DN1jzLaI.js → SelectSeparator-CaJnPF3_.js} +0 -0
- /package/dist/{Separator-DXxac0j8.js → Separator-C2XtAXRp.js} +0 -0
- /package/dist/{Switch-imA0Hdjs.js → Switch-x8n6husW.js} +0 -0
- /package/dist/{Toaster-Brs6QjBU.js → Toaster-DdhMKfus.js} +0 -0
- /package/dist/{TooltipProvider-MZFRxOvT.js → TooltipProvider-D-JrSqDu.js} +0 -0
- /package/dist/components/custom/aurora/{renderMode.d.ts → constants/renderMode.d.ts} +0 -0
- /package/dist/components/custom/aurora/{shaders → constants/shaders}/aurora.vert.d.ts +0 -0
- /package/dist/{constants-DfWPi8kh.js → constants-DsCdlK9I.js} +0 -0
- /package/dist/{sheet-BnvZRXPq.js → sheet-CQYYrkr9.js} +0 -0
- /package/dist/{useGlassRenderer-C98tZnJ7.js → useGlassRenderer-Dn3WpfG-.js} +0 -0
- /package/dist/{useInterval-B58LmYth.js → useInterval-CHVYFpXV.js} +0 -0
- /package/dist/{useResizeObserver-C_7GjpRn.js → useResizeObserver-DX-STszm.js} +0 -0
- /package/dist/{useTextHighlight-CLST6an0.js → useTextHighlight-Dmtofpk2.js} +0 -0
- /package/dist/{useTimer-6FoosoDY.js → useTimer-DGgoxTXL.js} +0 -0
- /package/dist/{useUserInvalidAria-BW5iyqWR.js → useUserInvalidAria-DmvZ_6Dx.js} +0 -0
- /package/dist/{useViewTransition-CUJM7fXT.js → useViewTransition-D4ssvnXZ.js} +0 -0
|
@@ -34,7 +34,7 @@ var d = /* @__PURE__ */ i({
|
|
|
34
34
|
"data-grain": t.grain,
|
|
35
35
|
as: t.as,
|
|
36
36
|
"as-child": t.asChild,
|
|
37
|
-
class: a(c(e)("rounded-card text-card-foreground scrollbar-hidden", `glass-${t.tier}`, t.surface === "cartoon" && "cartoon-surface", t.shadow && t.surface === "glass" && "shadow-
|
|
37
|
+
class: a(c(e)("rounded-card text-card-foreground scrollbar-hidden", `glass-${t.tier}`, t.surface === "glass" && "glass-specular-track", t.surface === "cartoon" && "cartoon-surface", t.shadow && t.surface === "glass" && "shadow-card", !t.grain && "[&::after]:hidden", r.class))
|
|
38
38
|
}, {
|
|
39
39
|
default: l(() => [s(i.$slots, "default")]),
|
|
40
40
|
_: 3
|
|
@@ -95,7 +95,7 @@ var d = /* @__PURE__ */ i({
|
|
|
95
95
|
let n = t;
|
|
96
96
|
return (t, i) => (o(), r("p", {
|
|
97
97
|
"data-slot": "card-description",
|
|
98
|
-
class: a(c(e)("text-sm text-
|
|
98
|
+
class: a(c(e)("text-sm text-muted-foreground-strong", n.class))
|
|
99
99
|
}, [s(t.$slots, "default")], 2));
|
|
100
100
|
}
|
|
101
101
|
}), h = /* @__PURE__ */ i({
|
|
@@ -42,7 +42,7 @@ var p = /* @__PURE__ */ t({
|
|
|
42
42
|
},
|
|
43
43
|
setup(t) {
|
|
44
44
|
let n = t;
|
|
45
|
-
return (t, i) => (a(), e(s(l), r(n, { class: "overflow-hidden transition-
|
|
45
|
+
return (t, i) => (a(), e(s(l), r(n, { class: "overflow-hidden transition-collapse data-[state=closed]:animate-collapsible-up data-[state=open]:animate-collapsible-down" }), {
|
|
46
46
|
default: c(() => [o(t.$slots, "default")]),
|
|
47
47
|
_: 3
|
|
48
48
|
}, 16));
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { t as e } from "./cn-DJXf4yaB.js";
|
|
2
2
|
import { t } from "./search-DBG8qaRs.js";
|
|
3
|
-
import { n, t as r } from "./DialogContent-
|
|
3
|
+
import { n, t as r } from "./DialogContent-IQ8_BRrC.js";
|
|
4
4
|
import { t as i } from "./menuItemVariants-C2QlXqT3.js";
|
|
5
5
|
import { computed as a, createBlock as o, createCommentVNode as s, createElementBlock as c, createElementVNode as l, createTextVNode as u, createVNode as d, defineComponent as f, guardReactiveProps as p, mergeProps as m, normalizeClass as h, normalizeProps as g, openBlock as _, renderSlot as v, toDisplayString as y, unref as b, withCtx as x } from "vue";
|
|
6
6
|
import { ComboboxContent as S, ComboboxEmpty as C, ComboboxGroup as w, ComboboxInput as T, ComboboxItem as E, ComboboxLabel as D, ComboboxRoot as O, ComboboxSeparator as k, useForwardProps as A, useForwardPropsEmits as j } from "reka-ui";
|
|
@@ -66,7 +66,7 @@ var M = /* @__PURE__ */ f({
|
|
|
66
66
|
let i = j(e, t);
|
|
67
67
|
return (e, t) => (_(), o(b(n), g(p(b(i))), {
|
|
68
68
|
default: x(() => [d(b(r), { class: "overflow-hidden p-0" }, {
|
|
69
|
-
default: x(() => [d(M, { class: "[&_[cmdk-group-heading]]:px-2 [&_[cmdk-group-heading]]:font-medium [&_[cmdk-group-heading]]:text-muted-foreground [&_[cmdk-group]:not([hidden])_~[cmdk-group]]:pt-0 [&_[cmdk-group]]:px-2 [&_[cmdk-input-wrapper]_svg]:h-5 [&_[cmdk-input-wrapper]_svg]:w-5 [&_[cmdk-input]]:h-12 [&_[cmdk-item]]:px-2 [&_[cmdk-item]]:py-3 [&_[cmdk-item]_svg]:h-5 [&_[cmdk-item]_svg]:w-5" }, {
|
|
69
|
+
default: x(() => [d(M, { class: "[&_[cmdk-group-heading]]:px-2 [&_[cmdk-group-heading]]:font-medium [&_[cmdk-group-heading]]:text-muted-foreground [&_[cmdk-group]:not([hidden])_~[cmdk-group]]:pt-0 [&_[cmdk-group]]:px-2 [&_[data-cmdk-input-wrapper]_svg]:h-5 [&_[data-cmdk-input-wrapper]_svg]:w-5 [&_[cmdk-input]]:h-12 [&_[cmdk-item]]:px-2 [&_[cmdk-item]]:py-3 [&_[cmdk-item]_svg]:h-5 [&_[cmdk-item]_svg]:w-5" }, {
|
|
70
70
|
default: x(() => [v(e.$slots, "default")]),
|
|
71
71
|
_: 3
|
|
72
72
|
})]),
|
|
@@ -130,7 +130,7 @@ var M = /* @__PURE__ */ f({
|
|
|
130
130
|
}
|
|
131
131
|
}), I = {
|
|
132
132
|
class: "flex items-center border-b px-3",
|
|
133
|
-
"cmdk-input-wrapper": ""
|
|
133
|
+
"data-cmdk-input-wrapper": ""
|
|
134
134
|
}, L = /* @__PURE__ */ f({
|
|
135
135
|
inheritAttrs: !1,
|
|
136
136
|
__name: "CommandInput",
|
|
@@ -147,7 +147,8 @@ var M = /* @__PURE__ */ f({
|
|
|
147
147
|
String,
|
|
148
148
|
Object,
|
|
149
149
|
Array
|
|
150
|
-
] }
|
|
150
|
+
] },
|
|
151
|
+
placeholder: {}
|
|
151
152
|
},
|
|
152
153
|
setup(n) {
|
|
153
154
|
let r = n, i = A(a(() => {
|
|
@@ -0,0 +1,465 @@
|
|
|
1
|
+
import { t as e } from "./cn-DJXf4yaB.js";
|
|
2
|
+
import { n as t } from "./button-Ckn3eDfB.js";
|
|
3
|
+
import { t as n } from "./_plugin-vue_export-helper-C1je1s0u.js";
|
|
4
|
+
import { n as r, r as i, t as a } from "./ContextMenuContent-De01_83g.js";
|
|
5
|
+
import { t as o } from "./useResizeObserver-DX-STszm.js";
|
|
6
|
+
import { Fragment as s, computed as c, createBlock as l, createCommentVNode as u, createElementBlock as d, createElementVNode as f, createTextVNode as p, createVNode as m, defineComponent as h, mergeModels as g, mergeProps as _, normalizeClass as v, openBlock as y, ref as b, renderList as x, renderSlot as S, resolveDynamicComponent as C, toDisplayString as w, unref as T, useModel as E, useSlots as ee, withCtx as D, withModifiers as O } from "vue";
|
|
7
|
+
//#region src/components/ui/table/Table.vue?vue&type=script&setup=true&lang.ts
|
|
8
|
+
var k = { class: "relative w-full overflow-auto" }, A = /* @__PURE__ */ h({
|
|
9
|
+
__name: "Table",
|
|
10
|
+
props: { class: { type: [
|
|
11
|
+
Boolean,
|
|
12
|
+
null,
|
|
13
|
+
String,
|
|
14
|
+
Object,
|
|
15
|
+
Array
|
|
16
|
+
] } },
|
|
17
|
+
setup(t) {
|
|
18
|
+
let n = t;
|
|
19
|
+
return (t, r) => (y(), d("div", k, [f("table", { class: v(T(e)("w-full caption-bottom text-sm", n.class)) }, [S(t.$slots, "default")], 2)]));
|
|
20
|
+
}
|
|
21
|
+
}), j = /* @__PURE__ */ h({
|
|
22
|
+
__name: "TableBody",
|
|
23
|
+
props: { class: { type: [
|
|
24
|
+
Boolean,
|
|
25
|
+
null,
|
|
26
|
+
String,
|
|
27
|
+
Object,
|
|
28
|
+
Array
|
|
29
|
+
] } },
|
|
30
|
+
setup(t) {
|
|
31
|
+
let n = t;
|
|
32
|
+
return (t, r) => (y(), d("tbody", { class: v(T(e)("[&_tr:last-child]:border-0", n.class)) }, [S(t.$slots, "default")], 2));
|
|
33
|
+
}
|
|
34
|
+
}), M = /* @__PURE__ */ h({
|
|
35
|
+
__name: "TableCell",
|
|
36
|
+
props: { class: { type: [
|
|
37
|
+
Boolean,
|
|
38
|
+
null,
|
|
39
|
+
String,
|
|
40
|
+
Object,
|
|
41
|
+
Array
|
|
42
|
+
] } },
|
|
43
|
+
setup(t) {
|
|
44
|
+
let n = t;
|
|
45
|
+
return (t, r) => (y(), d("td", { class: v(T(e)("table-cell align-middle [&:has([role=checkbox])]:pr-0", n.class)) }, [S(t.$slots, "default")], 2));
|
|
46
|
+
}
|
|
47
|
+
}), N = /* @__PURE__ */ h({
|
|
48
|
+
__name: "TableHead",
|
|
49
|
+
props: { class: { type: [
|
|
50
|
+
Boolean,
|
|
51
|
+
null,
|
|
52
|
+
String,
|
|
53
|
+
Object,
|
|
54
|
+
Array
|
|
55
|
+
] } },
|
|
56
|
+
setup(t) {
|
|
57
|
+
let n = t;
|
|
58
|
+
return (t, r) => (y(), d("th", { class: v(T(e)("table-head text-left align-middle font-medium text-muted-foreground [&:has([role=checkbox])]:pr-0", n.class)) }, [S(t.$slots, "default")], 2));
|
|
59
|
+
}
|
|
60
|
+
}), P = /* @__PURE__ */ h({
|
|
61
|
+
__name: "TableHeader",
|
|
62
|
+
props: { class: { type: [
|
|
63
|
+
Boolean,
|
|
64
|
+
null,
|
|
65
|
+
String,
|
|
66
|
+
Object,
|
|
67
|
+
Array
|
|
68
|
+
] } },
|
|
69
|
+
setup(t) {
|
|
70
|
+
let n = t;
|
|
71
|
+
return (t, r) => (y(), d("thead", { class: v(T(e)("[&_tr]:border-b", n.class)) }, [S(t.$slots, "default")], 2));
|
|
72
|
+
}
|
|
73
|
+
}), F = /* @__PURE__ */ h({
|
|
74
|
+
__name: "TableRow",
|
|
75
|
+
props: { class: { type: [
|
|
76
|
+
Boolean,
|
|
77
|
+
null,
|
|
78
|
+
String,
|
|
79
|
+
Object,
|
|
80
|
+
Array
|
|
81
|
+
] } },
|
|
82
|
+
setup(t) {
|
|
83
|
+
let n = t;
|
|
84
|
+
return (t, r) => (y(), d("tr", { class: v(T(e)("border-b transition-colors hover:bg-muted/50 data-[state=selected]:bg-muted", n.class)) }, [S(t.$slots, "default")], 2));
|
|
85
|
+
}
|
|
86
|
+
}), I = { class: "flex items-center justify-center py-10" }, L = /* @__PURE__ */ h({
|
|
87
|
+
__name: "TableEmpty",
|
|
88
|
+
props: {
|
|
89
|
+
class: { type: [
|
|
90
|
+
Boolean,
|
|
91
|
+
null,
|
|
92
|
+
String,
|
|
93
|
+
Object,
|
|
94
|
+
Array
|
|
95
|
+
] },
|
|
96
|
+
colspan: { default: 1 }
|
|
97
|
+
},
|
|
98
|
+
setup(t) {
|
|
99
|
+
let n = t, r = c(() => {
|
|
100
|
+
let { class: e, ...t } = n;
|
|
101
|
+
return t;
|
|
102
|
+
});
|
|
103
|
+
return (t, i) => (y(), l(F, null, {
|
|
104
|
+
default: D(() => [m(M, _({ class: T(e)("p-4 whitespace-nowrap align-middle text-sm text-foreground", n.class) }, r.value), {
|
|
105
|
+
default: D(() => [f("div", I, [S(t.$slots, "default")])]),
|
|
106
|
+
_: 3
|
|
107
|
+
}, 16, ["class"])]),
|
|
108
|
+
_: 3
|
|
109
|
+
}));
|
|
110
|
+
}
|
|
111
|
+
}), R = /* @__PURE__ */ n(/* @__PURE__ */ h({
|
|
112
|
+
__name: "Skeleton",
|
|
113
|
+
props: {
|
|
114
|
+
variant: { default: "pulse" },
|
|
115
|
+
class: { type: [
|
|
116
|
+
Boolean,
|
|
117
|
+
null,
|
|
118
|
+
String,
|
|
119
|
+
Object,
|
|
120
|
+
Array
|
|
121
|
+
] }
|
|
122
|
+
},
|
|
123
|
+
setup(t) {
|
|
124
|
+
let n = t;
|
|
125
|
+
return (r, i) => (y(), d("div", { class: v(T(e)("rounded-input bg-muted", t.variant === "pulse" && "animate-pulse", t.variant === "shimmer" && "skeleton-shimmer", t.variant === "breath" && "skeleton-breath", n.class)) }, null, 2));
|
|
126
|
+
}
|
|
127
|
+
}), [["__scopeId", "data-v-bb7e255e"]]), z = { class: "tabular-nums" }, B = { class: "flex items-center gap-1" }, V = {
|
|
128
|
+
key: 0,
|
|
129
|
+
class: "px-1 select-none"
|
|
130
|
+
}, H = /* @__PURE__ */ h({
|
|
131
|
+
__name: "DataTablePagination",
|
|
132
|
+
props: {
|
|
133
|
+
page: {},
|
|
134
|
+
pageSize: {},
|
|
135
|
+
total: {},
|
|
136
|
+
class: {}
|
|
137
|
+
},
|
|
138
|
+
emits: ["update:page"],
|
|
139
|
+
setup(n, { emit: r }) {
|
|
140
|
+
let i = n, a = r, o = c(() => Math.max(1, Math.ceil(i.total / i.pageSize))), u = c(() => Math.min(Math.max(1, i.page), o.value)), h = c(() => {
|
|
141
|
+
let e = o.value, t = u.value;
|
|
142
|
+
if (e <= 7) return Array.from({ length: e }, (e, t) => t + 1);
|
|
143
|
+
let n = [1];
|
|
144
|
+
t > 3 && n.push(null);
|
|
145
|
+
let r = Math.max(2, t - 1), i = Math.min(e - 1, t + 1);
|
|
146
|
+
for (let e = r; e <= i; e++) n.push(e);
|
|
147
|
+
return t < e - 2 && n.push(null), n.push(e), n;
|
|
148
|
+
});
|
|
149
|
+
function g(e) {
|
|
150
|
+
let t = Math.min(Math.max(1, e), o.value);
|
|
151
|
+
t !== i.page && a("update:page", t);
|
|
152
|
+
}
|
|
153
|
+
return (r, a) => (y(), d("div", { class: v(T(e)("flex items-center justify-between border-t border-border px-4 py-2 text-sm text-muted-foreground", i.class)) }, [f("span", z, w(n.total.toLocaleString()) + " result" + w(n.total === 1 ? "" : "s"), 1), f("div", B, [
|
|
154
|
+
m(T(t), {
|
|
155
|
+
variant: "ghost",
|
|
156
|
+
size: "icon",
|
|
157
|
+
disabled: u.value <= 1,
|
|
158
|
+
onClick: a[0] ||= (e) => g(1),
|
|
159
|
+
"aria-label": "First page"
|
|
160
|
+
}, {
|
|
161
|
+
default: D(() => [...a[4] ||= [p(" ⟨⟨ ", -1)]]),
|
|
162
|
+
_: 1
|
|
163
|
+
}, 8, ["disabled"]),
|
|
164
|
+
m(T(t), {
|
|
165
|
+
variant: "ghost",
|
|
166
|
+
size: "icon",
|
|
167
|
+
disabled: u.value <= 1,
|
|
168
|
+
onClick: a[1] ||= (e) => g(u.value - 1),
|
|
169
|
+
"aria-label": "Previous page"
|
|
170
|
+
}, {
|
|
171
|
+
default: D(() => [...a[5] ||= [p(" ⟨ ", -1)]]),
|
|
172
|
+
_: 1
|
|
173
|
+
}, 8, ["disabled"]),
|
|
174
|
+
(y(!0), d(s, null, x(h.value, (e, n) => (y(), d(s, { key: n }, [e === null ? (y(), d("span", V, "...")) : (y(), l(T(t), {
|
|
175
|
+
key: 1,
|
|
176
|
+
variant: e === u.value ? "default" : "ghost",
|
|
177
|
+
size: "icon",
|
|
178
|
+
class: "tabular-nums",
|
|
179
|
+
onClick: (t) => g(e)
|
|
180
|
+
}, {
|
|
181
|
+
default: D(() => [p(w(e), 1)]),
|
|
182
|
+
_: 2
|
|
183
|
+
}, 1032, ["variant", "onClick"]))], 64))), 128)),
|
|
184
|
+
m(T(t), {
|
|
185
|
+
variant: "ghost",
|
|
186
|
+
size: "icon",
|
|
187
|
+
disabled: u.value >= o.value,
|
|
188
|
+
onClick: a[2] ||= (e) => g(u.value + 1),
|
|
189
|
+
"aria-label": "Next page"
|
|
190
|
+
}, {
|
|
191
|
+
default: D(() => [...a[6] ||= [p(" ⟩ ", -1)]]),
|
|
192
|
+
_: 1
|
|
193
|
+
}, 8, ["disabled"]),
|
|
194
|
+
m(T(t), {
|
|
195
|
+
variant: "ghost",
|
|
196
|
+
size: "icon",
|
|
197
|
+
disabled: u.value >= o.value,
|
|
198
|
+
onClick: a[3] ||= (e) => g(o.value),
|
|
199
|
+
"aria-label": "Last page"
|
|
200
|
+
}, {
|
|
201
|
+
default: D(() => [...a[7] ||= [p(" ⟩⟩ ", -1)]]),
|
|
202
|
+
_: 1
|
|
203
|
+
}, 8, ["disabled"])
|
|
204
|
+
])], 2));
|
|
205
|
+
}
|
|
206
|
+
}), te = {
|
|
207
|
+
key: 0,
|
|
208
|
+
class: "flex flex-col gap-2"
|
|
209
|
+
}, ne = {
|
|
210
|
+
key: 1,
|
|
211
|
+
class: "flex flex-col gap-2"
|
|
212
|
+
}, re = ["onClick"], ie = { class: "flex items-start justify-between gap-2" }, ae = { class: "min-w-0 font-medium" }, oe = {
|
|
213
|
+
key: 0,
|
|
214
|
+
class: "mt-2 grid grid-cols-[auto_1fr] gap-x-3 gap-y-1"
|
|
215
|
+
}, se = { class: "text-muted-foreground" }, ce = {
|
|
216
|
+
key: 2,
|
|
217
|
+
class: "rounded-lg border border-border p-6 text-center text-muted-foreground"
|
|
218
|
+
}, U = /* @__PURE__ */ h({
|
|
219
|
+
__name: "DataTable",
|
|
220
|
+
props: /* @__PURE__ */ g({
|
|
221
|
+
columns: {},
|
|
222
|
+
rows: {},
|
|
223
|
+
total: {},
|
|
224
|
+
pageSize: {},
|
|
225
|
+
isLoading: {
|
|
226
|
+
type: Boolean,
|
|
227
|
+
default: !1
|
|
228
|
+
},
|
|
229
|
+
rowKey: { default: "_id" },
|
|
230
|
+
getRowId: {},
|
|
231
|
+
sort: {},
|
|
232
|
+
infinite: {
|
|
233
|
+
type: Boolean,
|
|
234
|
+
default: !1
|
|
235
|
+
},
|
|
236
|
+
hasMore: {
|
|
237
|
+
type: Boolean,
|
|
238
|
+
default: !1
|
|
239
|
+
},
|
|
240
|
+
responsive: {
|
|
241
|
+
type: Boolean,
|
|
242
|
+
default: !1
|
|
243
|
+
},
|
|
244
|
+
cardBreakpoint: { default: 640 },
|
|
245
|
+
class: {}
|
|
246
|
+
}, {
|
|
247
|
+
page: { required: !0 },
|
|
248
|
+
pageModifiers: {}
|
|
249
|
+
}),
|
|
250
|
+
emits: /* @__PURE__ */ g([
|
|
251
|
+
"update:sort",
|
|
252
|
+
"select",
|
|
253
|
+
"load-more"
|
|
254
|
+
], ["update:page"]),
|
|
255
|
+
setup(t, { emit: n }) {
|
|
256
|
+
let h = t, g = E(t, "page"), _ = n, k = ee(), I = c(() => !!k["row-actions"]), z = c(() => !!k["row-context-menu"]), B = b(null), V = b(0);
|
|
257
|
+
o(B, (e) => {
|
|
258
|
+
V.value = e.width;
|
|
259
|
+
});
|
|
260
|
+
let U = c(() => h.responsive && V.value > 0 && V.value < h.cardBreakpoint), W = c(() => Array.from({ length: Math.min(h.pageSize, 5) }, (e, t) => t)), G = /* @__PURE__ */ new WeakMap(), le = 0;
|
|
261
|
+
function K(e, t) {
|
|
262
|
+
return t.split(".").reduce((e, t) => {
|
|
263
|
+
if (!(typeof e != "object" || !e)) return e[t];
|
|
264
|
+
}, e);
|
|
265
|
+
}
|
|
266
|
+
function q(e) {
|
|
267
|
+
return typeof e == "string" || typeof e == "number" || typeof e == "symbol";
|
|
268
|
+
}
|
|
269
|
+
function ue(e) {
|
|
270
|
+
return typeof e == "symbol" ? e.toString() : JSON.stringify(e);
|
|
271
|
+
}
|
|
272
|
+
function de(e) {
|
|
273
|
+
return h.getRowId ? h.getRowId(e) : K(e, h.rowKey);
|
|
274
|
+
}
|
|
275
|
+
function J(e) {
|
|
276
|
+
let t = e, n = G.get(t);
|
|
277
|
+
if (n) return n;
|
|
278
|
+
let r = Symbol(`DataTable row ${le++}`);
|
|
279
|
+
return G.set(t, r), r;
|
|
280
|
+
}
|
|
281
|
+
let Y = c(() => {
|
|
282
|
+
let e = h.rows.map((e) => de(e)), t = /* @__PURE__ */ new Map();
|
|
283
|
+
for (let n of e) q(n) && t.set(n, (t.get(n) ?? 0) + 1);
|
|
284
|
+
let n = e.filter((e) => !q(e)).length;
|
|
285
|
+
n > 0 && `${n}`;
|
|
286
|
+
let r = Array.from(t).filter(([, e]) => e > 1).map(([e]) => ue(e));
|
|
287
|
+
return r.length > 0 && (`${r.join(",")}`, `${r.join(", ")}`), h.rows.map((n, r) => {
|
|
288
|
+
let i = e[r];
|
|
289
|
+
return {
|
|
290
|
+
row: n,
|
|
291
|
+
key: q(i) && t.get(i) === 1 ? i : J(n)
|
|
292
|
+
};
|
|
293
|
+
});
|
|
294
|
+
});
|
|
295
|
+
function X(e, t) {
|
|
296
|
+
let n = K(e, t.key);
|
|
297
|
+
return t.formatter ? t.formatter(n, e) : n == null ? "—" : String(n);
|
|
298
|
+
}
|
|
299
|
+
function Z(e) {
|
|
300
|
+
return e === "right" ? "text-right" : e === "center" ? "text-center" : "text-left";
|
|
301
|
+
}
|
|
302
|
+
function fe(e) {
|
|
303
|
+
if (!e.sortable) return;
|
|
304
|
+
let t = h.sort;
|
|
305
|
+
t?.key === e.key ? _("update:sort", {
|
|
306
|
+
key: e.key,
|
|
307
|
+
direction: t.direction === "asc" ? "desc" : "asc"
|
|
308
|
+
}) : _("update:sort", {
|
|
309
|
+
key: e.key,
|
|
310
|
+
direction: "asc"
|
|
311
|
+
});
|
|
312
|
+
}
|
|
313
|
+
function pe(e) {
|
|
314
|
+
return e.sortable ? h.sort?.key === e.key ? h.sort.direction === "asc" ? " ↑" : " ↓" : " ↕" : "";
|
|
315
|
+
}
|
|
316
|
+
let Q = c(() => h.columns[0]), $ = c(() => h.columns.slice(1));
|
|
317
|
+
return (n, o) => (y(), d("div", {
|
|
318
|
+
ref_key: "rootRef",
|
|
319
|
+
ref: B,
|
|
320
|
+
class: v(T(e)("overflow-hidden", h.class))
|
|
321
|
+
}, [
|
|
322
|
+
U.value ? (y(), d(s, { key: 0 }, [t.isLoading && t.rows.length === 0 ? (y(), d("div", te, [(y(!0), d(s, null, x(W.value, (e) => (y(), d("div", {
|
|
323
|
+
key: "skel-card-" + e,
|
|
324
|
+
class: "rounded-lg border border-border p-3"
|
|
325
|
+
}, [m(T(R), { class: "mb-2 h-4 w-1/2" }), m(T(R), { class: "h-3 w-3/4" })]))), 128))])) : t.rows.length > 0 ? (y(), d("div", ne, [(y(!0), d(s, null, x(Y.value, (t) => (y(), l(C(z.value ? T(i) : "div"), { key: t.key }, {
|
|
326
|
+
default: D(() => [(y(), l(C(z.value ? T(r) : "div"), { "as-child": z.value ? !0 : void 0 }, {
|
|
327
|
+
default: D(() => [f("div", {
|
|
328
|
+
class: "cursor-pointer rounded-lg border border-border p-3 transition-colors hover:bg-muted/40",
|
|
329
|
+
onClick: (e) => _("select", t.row)
|
|
330
|
+
}, [f("div", ie, [f("div", ae, [Q.value?.component ? (y(), l(C(Q.value.component), {
|
|
331
|
+
key: 0,
|
|
332
|
+
value: K(t.row, Q.value.key),
|
|
333
|
+
row: t.row
|
|
334
|
+
}, null, 8, ["value", "row"])) : Q.value ? (y(), d(s, { key: 1 }, [p(w(X(t.row, Q.value)), 1)], 64)) : u("", !0)]), I.value ? (y(), d("div", {
|
|
335
|
+
key: 0,
|
|
336
|
+
class: "shrink-0",
|
|
337
|
+
onClick: o[0] ||= O(() => {}, ["stop"])
|
|
338
|
+
}, [S(n.$slots, "row-actions", { row: t.row })])) : u("", !0)]), $.value.length > 0 ? (y(), d("dl", oe, [(y(!0), d(s, null, x($.value, (n) => (y(), d(s, { key: n.key }, [f("dt", se, w(n.label), 1), f("dd", { class: v(T(e)("min-w-0 break-words", n.align === "right" && "text-right", n.class)) }, [n.component ? (y(), l(C(n.component), {
|
|
339
|
+
key: 0,
|
|
340
|
+
value: K(t.row, n.key),
|
|
341
|
+
row: t.row
|
|
342
|
+
}, null, 8, ["value", "row"])) : (y(), d(s, { key: 1 }, [p(w(X(t.row, n)), 1)], 64))], 2)], 64))), 128))])) : u("", !0)], 8, re)]),
|
|
343
|
+
_: 2
|
|
344
|
+
}, 1032, ["as-child"])), z.value ? (y(), l(T(a), { key: 0 }, {
|
|
345
|
+
default: D(() => [S(n.$slots, "row-context-menu", { row: t.row })]),
|
|
346
|
+
_: 2
|
|
347
|
+
}, 1024)) : u("", !0)]),
|
|
348
|
+
_: 2
|
|
349
|
+
}, 1024))), 128))])) : (y(), d("div", ce, [S(n.$slots, "empty", {}, () => [o[4] ||= p("No results found", -1)])]))], 64)) : (y(), l(T(A), { key: 1 }, {
|
|
350
|
+
default: D(() => [m(T(P), null, {
|
|
351
|
+
default: D(() => [m(T(F), { class: "text-muted-foreground" }, {
|
|
352
|
+
default: D(() => [(y(!0), d(s, null, x(t.columns, (t) => (y(), l(T(N), {
|
|
353
|
+
key: t.key,
|
|
354
|
+
class: v(T(e)(Z(t.align), t.sortable && "cursor-pointer select-none", t.headerClass)),
|
|
355
|
+
onClick: (e) => fe(t)
|
|
356
|
+
}, {
|
|
357
|
+
default: D(() => [p(w(t.label) + w(pe(t)), 1)]),
|
|
358
|
+
_: 2
|
|
359
|
+
}, 1032, ["class", "onClick"]))), 128)), I.value ? (y(), l(T(N), {
|
|
360
|
+
key: 0,
|
|
361
|
+
class: "w-10"
|
|
362
|
+
})) : u("", !0)]),
|
|
363
|
+
_: 1
|
|
364
|
+
})]),
|
|
365
|
+
_: 1
|
|
366
|
+
}), m(T(j), null, {
|
|
367
|
+
default: D(() => [t.isLoading && t.rows.length === 0 ? (y(!0), d(s, { key: 0 }, x(W.value, (e) => (y(), l(T(F), { key: "skel-" + e }, {
|
|
368
|
+
default: D(() => [(y(!0), d(s, null, x(t.columns, (e) => (y(), l(T(M), {
|
|
369
|
+
key: e.key,
|
|
370
|
+
class: v(Z(e.align))
|
|
371
|
+
}, {
|
|
372
|
+
default: D(() => [m(T(R), { class: "h-4 w-3/4" })]),
|
|
373
|
+
_: 1
|
|
374
|
+
}, 8, ["class"]))), 128)), I.value ? (y(), l(T(M), {
|
|
375
|
+
key: 0,
|
|
376
|
+
class: "w-10"
|
|
377
|
+
}, {
|
|
378
|
+
default: D(() => [m(T(R), { class: "h-4 w-6" })]),
|
|
379
|
+
_: 1
|
|
380
|
+
})) : u("", !0)]),
|
|
381
|
+
_: 1
|
|
382
|
+
}))), 128)) : t.rows.length > 0 ? (y(!0), d(s, { key: 1 }, x(Y.value, (c) => (y(), d(s, { key: c.key }, [z.value ? (y(), l(T(i), { key: 0 }, {
|
|
383
|
+
default: D(() => [m(T(r), { "as-child": "" }, {
|
|
384
|
+
default: D(() => [m(T(F), {
|
|
385
|
+
class: "cursor-pointer",
|
|
386
|
+
onClick: (e) => _("select", c.row)
|
|
387
|
+
}, {
|
|
388
|
+
default: D(() => [(y(!0), d(s, null, x(t.columns, (t) => (y(), l(T(M), {
|
|
389
|
+
key: t.key,
|
|
390
|
+
class: v(T(e)(Z(t.align), t.class))
|
|
391
|
+
}, {
|
|
392
|
+
default: D(() => [t.component ? (y(), l(C(t.component), {
|
|
393
|
+
key: 0,
|
|
394
|
+
value: K(c.row, t.key),
|
|
395
|
+
row: c.row
|
|
396
|
+
}, null, 8, ["value", "row"])) : (y(), d(s, { key: 1 }, [p(w(X(c.row, t)), 1)], 64))]),
|
|
397
|
+
_: 2
|
|
398
|
+
}, 1032, ["class"]))), 128)), I.value ? (y(), l(T(M), {
|
|
399
|
+
key: 0,
|
|
400
|
+
class: "w-10",
|
|
401
|
+
onClick: o[1] ||= O(() => {}, ["stop"])
|
|
402
|
+
}, {
|
|
403
|
+
default: D(() => [S(n.$slots, "row-actions", { row: c.row })]),
|
|
404
|
+
_: 2
|
|
405
|
+
}, 1024)) : u("", !0)]),
|
|
406
|
+
_: 2
|
|
407
|
+
}, 1032, ["onClick"])]),
|
|
408
|
+
_: 2
|
|
409
|
+
}, 1024), m(T(a), null, {
|
|
410
|
+
default: D(() => [S(n.$slots, "row-context-menu", { row: c.row })]),
|
|
411
|
+
_: 2
|
|
412
|
+
}, 1024)]),
|
|
413
|
+
_: 2
|
|
414
|
+
}, 1024)) : (y(), l(T(F), {
|
|
415
|
+
key: 1,
|
|
416
|
+
class: "cursor-pointer",
|
|
417
|
+
onClick: (e) => _("select", c.row)
|
|
418
|
+
}, {
|
|
419
|
+
default: D(() => [(y(!0), d(s, null, x(t.columns, (t) => (y(), l(T(M), {
|
|
420
|
+
key: t.key,
|
|
421
|
+
class: v(T(e)(Z(t.align), t.class))
|
|
422
|
+
}, {
|
|
423
|
+
default: D(() => [t.component ? (y(), l(C(t.component), {
|
|
424
|
+
key: 0,
|
|
425
|
+
value: K(c.row, t.key),
|
|
426
|
+
row: c.row
|
|
427
|
+
}, null, 8, ["value", "row"])) : (y(), d(s, { key: 1 }, [p(w(X(c.row, t)), 1)], 64))]),
|
|
428
|
+
_: 2
|
|
429
|
+
}, 1032, ["class"]))), 128)), I.value ? (y(), l(T(M), {
|
|
430
|
+
key: 0,
|
|
431
|
+
class: "w-10",
|
|
432
|
+
onClick: o[2] ||= O(() => {}, ["stop"])
|
|
433
|
+
}, {
|
|
434
|
+
default: D(() => [S(n.$slots, "row-actions", { row: c.row })]),
|
|
435
|
+
_: 2
|
|
436
|
+
}, 1024)) : u("", !0)]),
|
|
437
|
+
_: 2
|
|
438
|
+
}, 1032, ["onClick"]))], 64))), 128)) : (y(), l(T(L), {
|
|
439
|
+
key: 2,
|
|
440
|
+
colspan: t.columns.length + +!!I.value
|
|
441
|
+
}, {
|
|
442
|
+
default: D(() => [S(n.$slots, "empty", {}, () => [o[5] ||= p("No results found", -1)])]),
|
|
443
|
+
_: 3
|
|
444
|
+
}, 8, ["colspan"]))]),
|
|
445
|
+
_: 3
|
|
446
|
+
})]),
|
|
447
|
+
_: 3
|
|
448
|
+
})),
|
|
449
|
+
t.infinite ? S(n.$slots, "sentinel", { key: 2 }) : u("", !0),
|
|
450
|
+
!t.infinite && t.total > 0 ? (y(), l(H, {
|
|
451
|
+
key: 3,
|
|
452
|
+
page: g.value,
|
|
453
|
+
"page-size": t.pageSize,
|
|
454
|
+
total: t.total,
|
|
455
|
+
"onUpdate:page": o[3] ||= (e) => g.value = e
|
|
456
|
+
}, null, 8, [
|
|
457
|
+
"page",
|
|
458
|
+
"page-size",
|
|
459
|
+
"total"
|
|
460
|
+
])) : u("", !0)
|
|
461
|
+
], 2));
|
|
462
|
+
}
|
|
463
|
+
});
|
|
464
|
+
//#endregion
|
|
465
|
+
export { F as a, M as c, L as i, j as l, H as n, P as o, R as r, N as s, U as t, A as u };
|
|
@@ -0,0 +1,100 @@
|
|
|
1
|
+
import { t as e } from "./cn-DJXf4yaB.js";
|
|
2
|
+
import { t } from "./x-C4pz9nbD.js";
|
|
3
|
+
import { t as n } from "./useSpringMount-CnizvZGm.js";
|
|
4
|
+
import { t as r } from "./ModalOverlay-B_CBtqcE.js";
|
|
5
|
+
import { computed as i, createBlock as a, createCommentVNode as o, createElementVNode as s, createVNode as c, defineComponent as l, guardReactiveProps as u, mergeProps as d, normalizeProps as f, openBlock as p, renderSlot as m, unref as h, withCtx as g } from "vue";
|
|
6
|
+
import { DialogClose as _, DialogContent as v, DialogPortal as y, DialogRoot as b, injectDialogRootContext as x, useForwardPropsEmits as S } from "reka-ui";
|
|
7
|
+
//#endregion
|
|
8
|
+
//#region src/components/ui/dialog/Dialog.vue
|
|
9
|
+
var C = /* @__PURE__ */ l({
|
|
10
|
+
__name: "Dialog",
|
|
11
|
+
props: {
|
|
12
|
+
open: { type: Boolean },
|
|
13
|
+
defaultOpen: { type: Boolean },
|
|
14
|
+
modal: { type: Boolean }
|
|
15
|
+
},
|
|
16
|
+
emits: ["update:open"],
|
|
17
|
+
setup(e, { emit: t }) {
|
|
18
|
+
let n = S(e, t);
|
|
19
|
+
return (e, t) => (p(), a(h(b), f(u(h(n))), {
|
|
20
|
+
default: g(() => [m(e.$slots, "default")]),
|
|
21
|
+
_: 3
|
|
22
|
+
}, 16));
|
|
23
|
+
}
|
|
24
|
+
}), w = "fixed left-1/2 top-1/2 z-modal grid w-full max-w-lg gap-4 p-6", T = "-translate-x-1/2 -translate-y-1/2 duration-normal popover-animate", E = /* @__PURE__ */ l({
|
|
25
|
+
__name: "DialogContent",
|
|
26
|
+
props: {
|
|
27
|
+
forceMount: { type: Boolean },
|
|
28
|
+
disableOutsidePointerEvents: { type: Boolean },
|
|
29
|
+
asChild: { type: Boolean },
|
|
30
|
+
as: {},
|
|
31
|
+
class: { type: [
|
|
32
|
+
Boolean,
|
|
33
|
+
null,
|
|
34
|
+
String,
|
|
35
|
+
Object,
|
|
36
|
+
Array
|
|
37
|
+
] },
|
|
38
|
+
variant: { default: "glass" },
|
|
39
|
+
scrimAnimation: {},
|
|
40
|
+
spring: { type: [Boolean, String] },
|
|
41
|
+
showClose: {
|
|
42
|
+
type: Boolean,
|
|
43
|
+
default: !0
|
|
44
|
+
}
|
|
45
|
+
},
|
|
46
|
+
emits: [
|
|
47
|
+
"escapeKeyDown",
|
|
48
|
+
"pointerDownOutside",
|
|
49
|
+
"focusOutside",
|
|
50
|
+
"interactOutside",
|
|
51
|
+
"openAutoFocus",
|
|
52
|
+
"closeAutoFocus"
|
|
53
|
+
],
|
|
54
|
+
setup(l, { emit: u }) {
|
|
55
|
+
let f = l, b = u, C = S(i(() => {
|
|
56
|
+
let { class: e, variant: t, scrimAnimation: n, spring: r, showClose: i, ...a } = f;
|
|
57
|
+
return a;
|
|
58
|
+
}), b), E = i(() => f.variant === "opaque" ? "bg-background border sm:rounded-dialog" : "glass-floating rounded-dialog"), D = f.spring ? x() : null, O = f.spring && D ? n({
|
|
59
|
+
open: D.open,
|
|
60
|
+
preset: typeof f.spring == "string" ? f.spring : "smooth"
|
|
61
|
+
}) : null, k = i(() => {
|
|
62
|
+
if (!O) return;
|
|
63
|
+
let e = O.position.value;
|
|
64
|
+
return {
|
|
65
|
+
transform: `translate(-50%, -50%) scale(${1 - .05 * e})`,
|
|
66
|
+
opacity: String(1 - e),
|
|
67
|
+
animation: "none",
|
|
68
|
+
transition: "none"
|
|
69
|
+
};
|
|
70
|
+
});
|
|
71
|
+
return (n, i) => (p(), a(h(y), null, {
|
|
72
|
+
default: g(() => [c(r, {
|
|
73
|
+
scrim: "glass",
|
|
74
|
+
animate: "fade",
|
|
75
|
+
layout: "centered",
|
|
76
|
+
"scrim-animation": f.scrimAnimation
|
|
77
|
+
}, null, 8, ["scrim-animation"]), c(h(v), d(h(C), {
|
|
78
|
+
class: h(e)(w, f.spring ? "" : T, E.value, f.class),
|
|
79
|
+
style: k.value,
|
|
80
|
+
"data-spring": f.spring ? typeof f.spring == "string" ? f.spring : "smooth" : void 0
|
|
81
|
+
}), {
|
|
82
|
+
default: g(() => [m(n.$slots, "default"), f.showClose ? (p(), a(h(_), {
|
|
83
|
+
key: 0,
|
|
84
|
+
class: "focus-ring absolute right-4 top-4 rounded-sm opacity-70 transition-opacity hover:opacity-100 disabled:pointer-events-none data-[state=open]:bg-accent data-[state=open]:text-muted-foreground"
|
|
85
|
+
}, {
|
|
86
|
+
default: g(() => [c(h(t), { class: "w-4 h-4" }), i[0] ||= s("span", { class: "sr-only" }, "Close", -1)]),
|
|
87
|
+
_: 1
|
|
88
|
+
})) : o("", !0)]),
|
|
89
|
+
_: 3
|
|
90
|
+
}, 16, [
|
|
91
|
+
"class",
|
|
92
|
+
"style",
|
|
93
|
+
"data-spring"
|
|
94
|
+
])]),
|
|
95
|
+
_: 3
|
|
96
|
+
}));
|
|
97
|
+
}
|
|
98
|
+
});
|
|
99
|
+
//#endregion
|
|
100
|
+
export { C as n, E as t };
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { r as e } from "./keys-
|
|
1
|
+
import { r as e } from "./keys-BFoma9vm.js";
|
|
2
2
|
import { computed as t, createElementBlock as n, createElementVNode as r, defineComponent as i, normalizeClass as a, openBlock as o, useId as s, watch as c } from "vue";
|
|
3
3
|
//#region src/components/custom/disco-glyph/DiscoGlyph.vue?vue&type=script&setup=true&lang.ts
|
|
4
4
|
var l = ["viewBox"], u = [
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { t as e } from "./cn-DJXf4yaB.js";
|
|
2
|
-
import { n as t } from "./keys-
|
|
2
|
+
import { n as t } from "./keys-BFoma9vm.js";
|
|
3
3
|
import { computed as n, createElementBlock as r, createElementVNode as i, defineComponent as a, normalizeClass as o, normalizeStyle as s, openBlock as c, ref as l, renderSlot as u } from "vue";
|
|
4
4
|
//#region src/components/custom/glyph-face/GlyphFace.vue?vue&type=script&setup=true&lang.ts
|
|
5
5
|
var d = ["data-active"], f = /* @__PURE__ */ a({
|