@mkbabb/glass-ui 3.8.0 → 3.10.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/README.md +1 -6
- package/dist/{CardAction-q2qHCJFG.js → CardAction-DuArVky-.js} +4 -4
- package/dist/{CommandShortcut-SzWRhROC.js → CommandShortcut-CefCj5mt.js} +7 -7
- package/dist/{ContextMenuSubContent-Do977Cbf.js → ContextMenuSubContent-Bhg4f5jX.js} +3 -3
- package/dist/{DataTable-CvlWXz65.js → DataTable-CUHMukiQ.js} +1 -1
- package/dist/{DialogContent-DjZWT3lK.js → DialogContent-BRkT1cjP.js} +1 -1
- package/dist/{MetricBadge-lTc002u2.js → MetricBadge-BZVWIxNy.js} +6 -4
- package/dist/{Notification-BxK8LZMw.js → Notification-DLMhblXR.js} +2 -2
- package/dist/{NumberFieldContent-CLNVR1iY.js → NumberFieldContent-BbLOh8RU.js} +2 -2
- package/dist/{SelectScrollDownButton-C7TRe-ep.js → SelectScrollDownButton-T32cVFeM.js} +3 -3
- package/dist/{SelectSeparator-L8pPEn4L.js → SelectSeparator-C4Ql0gzV.js} +1 -1
- package/dist/{Switch-LDKLmmgx.js → Switch-Ch-k3Rv-.js} +1 -1
- package/dist/{TabsList-qyHZ2lKY.js → TabsList-B8CVOQPC.js} +2 -2
- package/dist/{Toaster-CabYEEF_.js → Toaster-1rYWrmAm.js} +1 -1
- package/dist/{ToggleGroupItem-CkXUcBlt.js → ToggleGroupItem-Cev4pOVK.js} +4 -4
- package/dist/animated-digit.js +1 -1
- package/dist/api/index.d.ts +2 -1
- package/dist/api.js +1 -1
- package/dist/aurora.js +236 -545
- package/dist/{badge-DHQrc_GQ.js → badge-CaoFJzRb.js} +5 -5
- package/dist/badge.js +1 -1
- package/dist/{button-CAywcrhO.js → button-DN39cGqL.js} +13 -12
- package/dist/button.js +1 -1
- package/dist/card.js +1 -1
- package/dist/carousel.js +1 -1
- package/dist/color.js +1 -1
- package/dist/command.js +1 -1
- package/dist/{compile-BBTRjvQS.js → compile-BOXjLUxu.js} +24 -24
- package/dist/components/custom/aurora/composables/atoms.d.ts +21 -4
- package/dist/components/custom/aurora/composables/runtime.d.ts +0 -9
- package/dist/components/custom/aurora/composables/uniformBridge.d.ts +0 -11
- package/dist/components/custom/aurora/constants/renderMode.d.ts +0 -32
- package/dist/components/custom/aurora/constants/shaders/brush.glsl.d.ts +1 -1
- package/dist/components/custom/aurora/constants/shaders/mediums.glsl.d.ts +2 -2
- package/dist/components/custom/aurora/constants/shaders/tonemap.glsl.d.ts +1 -1
- package/dist/components/custom/aurora/index.d.ts +1 -1
- package/dist/components/custom/configurator/ConfiguratorLayer.vue.d.ts +1 -1
- package/dist/components/custom/constellation/Constellation.vue.d.ts +73 -1
- package/dist/components/custom/constellation/constellationField.d.ts +255 -3
- package/dist/components/custom/constellation/index.d.ts +2 -2
- package/dist/components/custom/dock/DockSeparator.vue.d.ts +3 -0
- package/dist/components/custom/dock/DockTabButton.vue.d.ts +4 -3
- package/dist/components/custom/dock/GlassDock.vue.d.ts +45 -63
- package/dist/components/custom/dock/composables/dockContext.d.ts +7 -0
- package/dist/components/custom/dock/index.d.ts +2 -1
- package/dist/components/custom/expandable-container/ExpandableContainer.vue.d.ts +29 -0
- package/dist/components/custom/fourier-field/FourierField.vue.d.ts +6 -0
- package/dist/components/custom/fourier-field/index.d.ts +25 -1
- package/dist/components/custom/fourier-field/math.d.ts +3 -8
- package/dist/components/custom/goo-blob/GooBlob.vue.d.ts +8 -10
- package/dist/components/custom/goo-blob/composables/useBlobMood.d.ts +19 -5
- package/dist/components/custom/goo-blob/composables/useMetaballRenderer.d.ts +6 -14
- package/dist/components/custom/goo-blob/index.d.ts +1 -1
- package/dist/components/custom/goo-blob/types.d.ts +59 -25
- package/dist/components/custom/handmark/HandMark.vue.d.ts +29 -0
- package/dist/components/custom/handmark/brush.d.ts +219 -0
- package/dist/components/custom/handmark/freehand.d.ts +69 -0
- package/dist/components/custom/handmark/geometry.d.ts +32 -0
- package/dist/components/custom/handmark/index.d.ts +21 -0
- package/dist/components/custom/handmark/ink.d.ts +11 -0
- package/dist/components/custom/handmark/texture.d.ts +39 -0
- package/dist/components/custom/handmark/types.d.ts +53 -0
- package/dist/components/custom/handmark/useHandMark.d.ts +66 -0
- package/dist/components/custom/metric-badge/MetricBadge.vue.d.ts +8 -0
- package/dist/components/custom/tabs/SegmentedTabs.vue.d.ts +92 -0
- package/dist/components/custom/tabs/composables/useTabIndicator.d.ts +49 -0
- package/dist/components/custom/tabs/index.d.ts +2 -5
- package/dist/components/ui/button/index.d.ts +1 -1
- package/dist/components/ui/card/Card.vue.d.ts +5 -3
- package/dist/components/ui/carousel/CarouselNext.vue.d.ts +1 -1
- package/dist/components/ui/carousel/CarouselPrevious.vue.d.ts +1 -1
- package/dist/components/ui/carousel/GlassCarouselPager.vue.d.ts +3 -4
- package/dist/components/ui/slider/index.d.ts +22 -11
- package/dist/components/ui/tabs/TabsList.vue.d.ts +1 -1
- package/dist/composables/color/index.d.ts +12 -7
- package/dist/composables/context/createContext.d.ts +1 -1
- package/dist/composables/glass/webgl/shaders/procedural-color.glsl.d.ts +1 -6
- package/dist/composables/motion/core/index.d.ts +1 -0
- package/dist/composables/motion/useRouteTransition.d.ts +42 -0
- package/dist/configurator.js +1 -1
- package/dist/confirm-dialog.js +1 -1
- package/dist/constellation.js +212 -72
- package/dist/context-menu.js +1 -1
- package/dist/controls.js +1 -1
- package/dist/dark.js +1 -1
- package/dist/data-table.js +1 -1
- package/dist/deck-progress.js +1 -1
- package/dist/dialog.js +1 -1
- package/dist/dock.js +257 -243
- package/dist/{dropdown-menu-B_4bWyyG.js → dropdown-menu-D77jX6Df.js} +3 -3
- package/dist/dropdown-menu.js +1 -1
- package/dist/expandable-container.js +61 -38
- package/dist/forms.js +5 -5
- package/dist/fourier-field.js +89 -97
- package/dist/fourier-math.d.ts +1 -0
- package/dist/fourier-math.js +2 -0
- package/dist/glass-panel.js +1 -1
- package/dist/glass-ui.css +1 -1
- package/dist/glass-ui.js +107 -109
- package/dist/goo-blob.js +316 -297
- package/dist/handmark.d.ts +1 -0
- package/dist/handmark.js +609 -0
- package/dist/hover-popover.js +1 -1
- package/dist/icon-tooltip.js +1 -1
- package/dist/index.d.ts +1 -2
- package/dist/keyboard.js +1 -1
- package/dist/labeled-field.js +5 -5
- package/dist/math-DTpRVC0e.js +27 -0
- package/dist/{menuItemVariants-DKM85SNE.js → menuItemVariants-CCoBNkU5.js} +1 -1
- package/dist/metric-badge.js +1 -1
- package/dist/metric-stack.js +1 -1
- package/dist/motion-core.js +70 -69
- package/dist/motion.js +2 -2
- package/dist/notification.js +1 -1
- package/dist/number-field.js +1 -1
- package/dist/pulse.js +1 -1
- package/dist/reactive.js +1 -1
- package/dist/scrolling-text.js +1 -1
- package/dist/search.js +4 -4
- package/dist/select.js +2 -2
- package/dist/{slider-D9puf-Ko.js → slider-CyzcxBoh.js} +6 -6
- package/dist/slider.js +1 -1
- package/dist/sortable-list.js +1 -1
- package/dist/status-dot.js +17 -16
- package/dist/styles/animations.css +80 -20
- package/dist/styles/cards.css +2 -2
- package/dist/styles/components.css +1 -1
- package/dist/styles/dock/density.css +230 -0
- package/dist/styles/dock/layer-group.css +275 -0
- package/dist/styles/dock/layers.css +355 -0
- package/dist/styles/dock/morph.css +244 -0
- package/dist/styles/dock/overflow.css +201 -0
- package/dist/styles/dock/shell.css +457 -0
- package/dist/styles/dock-controls.css +205 -55
- package/dist/styles/dock.css +42 -1349
- package/dist/styles/drawer.css +12 -4
- package/dist/styles/glass.css +535 -78
- package/dist/styles/index.css +12 -11
- package/dist/styles/paper.css +68 -2
- package/dist/styles/theme.css +58 -0
- package/dist/styles/tokens.css +601 -69
- package/dist/styles/transitions.css +20 -2
- package/dist/styles/utilities.css +218 -78
- package/dist/styles/view-transition.css +51 -0
- package/dist/switch.js +1 -1
- package/dist/tabs.js +182 -151
- package/dist/timeline.js +1 -1
- package/dist/toast.js +1 -1
- package/dist/toggle-group.js +1 -1
- package/dist/{useAnimatedNumber-C_3wZLx4.js → useAnimatedNumber-Bcpy5Etf.js} +1 -1
- package/dist/{useConfiguratorState-CMff4GzH.js → useConfiguratorState-DxAqksK6.js} +21 -10
- package/dist/{useGlassRenderer-5I0YkI4t.js → useGlassRenderer-D7YGOYiM.js} +1 -1
- package/dist/useViewTransition-DaN5Zrox.js +21 -0
- package/dist/vReveal-zUIQk-rJ.js +53 -0
- package/dist/watercolor-dot.js +1 -1
- package/package.json +80 -39
- package/src/styles/animations.css +80 -20
- package/src/styles/cards.css +2 -2
- package/src/styles/dock/density.css +230 -0
- package/src/styles/dock/layer-group.css +275 -0
- package/src/styles/dock/layers.css +355 -0
- package/src/styles/dock/morph.css +244 -0
- package/src/styles/dock/overflow.css +201 -0
- package/src/styles/dock/shell.css +457 -0
- package/src/styles/dock-controls.css +205 -55
- package/src/styles/dock.css +42 -1349
- package/src/styles/drawer.css +12 -4
- package/src/styles/glass.css +535 -78
- package/src/styles/index.css +12 -11
- package/src/styles/paper.css +68 -2
- package/src/styles/theme.css +58 -0
- package/src/styles/tokens.css +601 -69
- package/src/styles/transitions.css +20 -2
- package/src/styles/utilities.css +218 -78
- package/src/styles/view-transition.css +51 -0
- package/dist/DiscoGlyph-CG0F410s.js +0 -132
- package/dist/GlyphFace-DRjDkB0s.js +0 -51
- package/dist/UnderlineTabs-Uxn-R3MT.js +0 -39
- package/dist/components/custom/aurora/composables/gpuRuntime.d.ts +0 -16
- package/dist/components/custom/aurora/constants/shaders/aurora.wgsl.d.ts +0 -7
- package/dist/components/custom/aurora/constants/shaders/painterly.wgsl.d.ts +0 -7
- package/dist/components/custom/aurora/constants/shaders/wake.wgsl.d.ts +0 -4
- package/dist/components/custom/disco-glyph/DiscoGlyph.vue.d.ts +0 -58
- package/dist/components/custom/disco-glyph/index.d.ts +0 -1
- package/dist/components/custom/glass-carousel/GlassCarousel.vue.d.ts +0 -36
- package/dist/components/custom/glass-carousel/GlassCarouselItem.vue.d.ts +0 -28
- package/dist/components/custom/glass-carousel/index.d.ts +0 -4
- package/dist/components/custom/glass-carousel/useGlassCarousel.d.ts +0 -30
- package/dist/components/custom/glyph-face/GlyphFace.vue.d.ts +0 -64
- package/dist/components/custom/glyph-face/index.d.ts +0 -2
- package/dist/components/custom/glyph-face/keys.d.ts +0 -9
- package/dist/components/custom/responsive-tabs/ResponsiveTabs.vue.d.ts +0 -73
- package/dist/components/custom/responsive-tabs/index.d.ts +0 -2
- package/dist/components/custom/tabs/BouncyTabs.vue.d.ts +0 -27
- package/dist/components/custom/tabs/BouncyToggle.vue.d.ts +0 -60
- package/dist/components/custom/tabs/UnderlineTabs.vue.d.ts +0 -20
- package/dist/components/custom/tabs/composables/useBouncySlider.d.ts +0 -39
- package/dist/composables/glass/createGPUCanvas.d.ts +0 -40
- package/dist/disco-glyph.d.ts +0 -1
- package/dist/disco-glyph.js +0 -2
- package/dist/glass-carousel.d.ts +0 -1
- package/dist/glass-carousel.js +0 -219
- package/dist/glyph-face.d.ts +0 -1
- package/dist/glyph-face.js +0 -3
- package/dist/keys-BsYjEFOW.js +0 -9
- package/dist/responsive-tabs.d.ts +0 -1
- package/dist/responsive-tabs.js +0 -95
- package/dist/styles/disco-glyph.css +0 -26
- package/dist/styles/glyph-face.css +0 -92
- package/dist/vReveal-CqaCz_mC.js +0 -44
- package/src/styles/disco-glyph.css +0 -26
- package/src/styles/glyph-face.css +0 -92
- /package/dist/{DeckProgress-AVgbIULY.js → DeckProgress-Dmk4_AKN.js} +0 -0
- /package/dist/{HoverPopover-D56O6Ylp.js → HoverPopover-2LOIW34a.js} +0 -0
- /package/dist/{IconTooltip-D2T5nYOM.js → IconTooltip-Cus0fvK0.js} +0 -0
- /package/dist/{Input-DVG_J0ne.js → Input-xuDwALQR.js} +0 -0
- /package/dist/{ScrollingText-CVyqxvfv.js → ScrollingText-BPP84wKo.js} +0 -0
- /package/dist/{color-DMLTunJK.js → color-C5ls_QF7.js} +0 -0
- /package/dist/{constants-BPOqYJAm.js → constants-yKeKnE84.js} +0 -0
- /package/dist/{presets-D1XPuTj-.js → presets-Dkdv55Gt.js} +0 -0
- /package/dist/{prng-COGhh02-.js → prng-D27-B3tK.js} +0 -0
- /package/dist/{useGlobalDark-D3EBWzXK.js → useGlobalDark-d6waty-X.js} +0 -0
- /package/dist/{useIntersectionPause-Bj4sPkMh.js → useIntersectionPause-Cck5Uxk8.js} +0 -0
- /package/dist/{useInterval-CcLfq2WU.js → useInterval-Dsmqwi03.js} +0 -0
- /package/dist/{useKeyboardShortcuts-BXWXOZ-9.js → useKeyboardShortcuts-CyIYrndH.js} +0 -0
- /package/dist/{useScrollProgress-C9ysDic5.js → useScrollProgress-CffFGLa5.js} +0 -0
- /package/dist/{useSortable-MGAbCGVJ.js → useSortable-C8ReQ50P.js} +0 -0
- /package/dist/{useTextHighlight-9nMW23Qb.js → useTextHighlight-CWEi25hf.js} +0 -0
package/dist/constellation.js
CHANGED
|
@@ -1,19 +1,19 @@
|
|
|
1
1
|
import { t as e } from "./cn-DJXf4yaB.js";
|
|
2
2
|
import { t } from "./useCanvas2D-ClrQuZtp.js";
|
|
3
3
|
import { t as n } from "./_plugin-vue_export-helper-ok8pgSl5.js";
|
|
4
|
-
import { n as r, t as i } from "./prng-
|
|
5
|
-
import { computed as a, createElementBlock as o, createElementVNode as s, defineComponent as c,
|
|
4
|
+
import { n as r, t as i } from "./prng-D27-B3tK.js";
|
|
5
|
+
import { computed as a, createElementBlock as o, createElementVNode as s, defineComponent as c, getCurrentInstance as l, normalizeClass as u, onMounted as d, openBlock as f, ref as p, unref as m, useTemplateRef as h } from "vue";
|
|
6
6
|
//#region src/components/custom/constellation/constellationField.ts
|
|
7
|
-
var
|
|
7
|
+
var g = 1280, _ = 8e3, v = 8e3, y = {
|
|
8
8
|
node: "#b4afa3",
|
|
9
9
|
nodeDim: "#cdc8bd",
|
|
10
10
|
line: "#1c1714",
|
|
11
11
|
edgeAlpha: .22,
|
|
12
12
|
edgeFocusAlpha: .34,
|
|
13
|
-
alpha: .
|
|
13
|
+
alpha: .84
|
|
14
14
|
};
|
|
15
|
-
function
|
|
16
|
-
if (typeof window > "u") return { ...
|
|
15
|
+
function b(e) {
|
|
16
|
+
if (typeof window > "u") return { ...y };
|
|
17
17
|
let t = getComputedStyle(e), n = (e, n) => t.getPropertyValue(e).trim() || n, r = (e, n) => {
|
|
18
18
|
let r = t.getPropertyValue(e).trim();
|
|
19
19
|
if (!r) return n;
|
|
@@ -21,15 +21,40 @@ function _(e) {
|
|
|
21
21
|
return Number.isFinite(i) ? i : n;
|
|
22
22
|
};
|
|
23
23
|
return {
|
|
24
|
-
node: n("--constellation-node",
|
|
25
|
-
nodeDim: n("--constellation-node-dim",
|
|
26
|
-
line: n("--constellation-line",
|
|
27
|
-
edgeAlpha: r("--constellation-edge-alpha",
|
|
28
|
-
edgeFocusAlpha: r("--constellation-edge-focus-alpha",
|
|
29
|
-
alpha: r("--constellation-alpha",
|
|
24
|
+
node: n("--constellation-node", y.node),
|
|
25
|
+
nodeDim: n("--constellation-node-dim", y.nodeDim),
|
|
26
|
+
line: n("--constellation-line", y.line),
|
|
27
|
+
edgeAlpha: r("--constellation-edge-alpha", y.edgeAlpha),
|
|
28
|
+
edgeFocusAlpha: r("--constellation-edge-focus-alpha", y.edgeFocusAlpha),
|
|
29
|
+
alpha: r("--constellation-alpha", y.alpha)
|
|
30
30
|
};
|
|
31
31
|
}
|
|
32
|
-
function
|
|
32
|
+
function x(e) {
|
|
33
|
+
let t = {
|
|
34
|
+
response: A,
|
|
35
|
+
zeta: 1
|
|
36
|
+
}, n = { ...N }, r = {
|
|
37
|
+
minIdle: _,
|
|
38
|
+
jitter: v
|
|
39
|
+
};
|
|
40
|
+
if (typeof window > "u") return {
|
|
41
|
+
warp: t,
|
|
42
|
+
well: n,
|
|
43
|
+
wander: r
|
|
44
|
+
};
|
|
45
|
+
let i = getComputedStyle(e), a = (e, t) => {
|
|
46
|
+
let n = i.getPropertyValue(e).trim();
|
|
47
|
+
if (!n) return t;
|
|
48
|
+
let r = Number.parseFloat(n);
|
|
49
|
+
return Number.isFinite(r) ? r : t;
|
|
50
|
+
};
|
|
51
|
+
return t.response = a("--constellation-warp-response", A), t.zeta = a("--constellation-warp-zeta", 1), n.gain = a("--constellation-well-gain", N.gain), n.reach = a("--constellation-well-reach", N.reach), n.ramp = a("--constellation-well-ramp", N.ramp), n.maxSpeed = a("--constellation-well-max-speed", N.maxSpeed), n.holdMs = a("--constellation-well-hold-ms", N.holdMs), r.minIdle = a("--constellation-wander-idle", _), r.jitter = a("--constellation-wander-jitter", v), {
|
|
52
|
+
warp: t,
|
|
53
|
+
well: n,
|
|
54
|
+
wander: r
|
|
55
|
+
};
|
|
56
|
+
}
|
|
57
|
+
function S(e, t, n, r, i) {
|
|
33
58
|
let a = [];
|
|
34
59
|
for (let o = 0; o < t; o++) {
|
|
35
60
|
let t = e() * Math.PI * 2;
|
|
@@ -44,26 +69,65 @@ function v(e, t, n, r, i) {
|
|
|
44
69
|
}
|
|
45
70
|
return a;
|
|
46
71
|
}
|
|
47
|
-
function
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
72
|
+
function C(e, t, n) {
|
|
73
|
+
if (!(t > 0) || !(n > 0) || t === e.w && n === e.h) return;
|
|
74
|
+
let r = e.w / t, i = e.h / n;
|
|
75
|
+
for (let t of e.nodes) t.x *= r, t.y *= i;
|
|
76
|
+
e.warp.x *= r, e.warp.y *= i;
|
|
77
|
+
}
|
|
78
|
+
function w(e, t, n, r, i = 0, a = 0, o = Math.random) {
|
|
79
|
+
let { nodes: s, w: c, h: l } = e;
|
|
80
|
+
for (let e = 0; e < s.length; e++) {
|
|
81
|
+
let n = s[e];
|
|
82
|
+
n.x += n.vx * t, n.y += n.vy * t, n.x < 0 ? (n.x = 0, n.vx *= -1) : n.x > c && (n.x = c, n.vx *= -1), n.y < 0 ? (n.y = 0, n.vy *= -1) : n.y > l && (n.y = l, n.vy *= -1);
|
|
52
83
|
}
|
|
53
84
|
if (r && r.x >= 0) {
|
|
54
85
|
let e = 180 * t;
|
|
55
|
-
for (let t = 0; t <
|
|
56
|
-
let i =
|
|
86
|
+
for (let t = 0; t < s.length; t++) {
|
|
87
|
+
let i = s[t], a = r.x - i.x, o = r.y - i.y, c = Math.hypot(a, o);
|
|
57
88
|
if (c > .5 && c < e) {
|
|
58
|
-
let t = Math.hypot(i.vx, i.vy) || n, r = (1 - c / e) * .08,
|
|
59
|
-
i.vx =
|
|
89
|
+
let t = Math.hypot(i.vx, i.vy) || n, r = (1 - c / e) * .08, s = i.vx + a / c * r * t, l = i.vy + o / c * r * t, u = Math.hypot(s, l) || 1;
|
|
90
|
+
i.vx = s / u * t, i.vy = l / u * t;
|
|
60
91
|
}
|
|
61
92
|
}
|
|
62
93
|
}
|
|
63
|
-
|
|
94
|
+
if (k(e, t, n, i), F(e, i), e.wander && a > 0) {
|
|
95
|
+
let t = e.wander;
|
|
96
|
+
t.nextAt < 0 ? t.nextAt = a + t.minIdle + o() * t.jitter : a >= t.nextAt && z(e) && (I(e, B(e, o)), t.nextAt = a + t.minIdle + o() * t.jitter);
|
|
97
|
+
}
|
|
64
98
|
}
|
|
65
|
-
var
|
|
66
|
-
function
|
|
99
|
+
var T = .001, E = 1.5, D = 7, O = 22;
|
|
100
|
+
function k(e, t, n, r) {
|
|
101
|
+
let i = e.well;
|
|
102
|
+
if (!i || !(r > 0)) return;
|
|
103
|
+
let a = Math.min(r, M), o = i.cfg, s = i.target > 0 ? o.ramp : O, c = Math.min(s * a, 1);
|
|
104
|
+
i.strength += (i.target - i.strength) * c, i.strength < T && (i.strength = i.target <= 0 ? 0 : i.strength);
|
|
105
|
+
let { nodes: l } = e, u = o.reach * t, d = u * u, f = o.maxSpeed * t, p = i.target > 0 ? E : D, m = Math.min(p * a, 1), h = i.strength > T && i.x >= 0;
|
|
106
|
+
for (let e = 0; e < l.length; e++) {
|
|
107
|
+
let t = l[e];
|
|
108
|
+
if (h) {
|
|
109
|
+
let e = i.x - t.x, n = i.y - t.y, r = e * e + n * n;
|
|
110
|
+
if (r <= d) {
|
|
111
|
+
let s = Math.max(Math.sqrt(r), o.soften), c = o.gain * i.strength / (s * s), l = t.vx + e / s * c * a, u = t.vy + n / s * c * a, d = Math.hypot(l, u);
|
|
112
|
+
d > f && (l = l / d * f, u = u / d * f), t.vx = l, t.vy = u;
|
|
113
|
+
}
|
|
114
|
+
}
|
|
115
|
+
let r = Math.hypot(t.vx, t.vy);
|
|
116
|
+
if (r > 1e-9) {
|
|
117
|
+
let e = (r + (n - r) * m) / r;
|
|
118
|
+
t.vx *= e, t.vy *= e;
|
|
119
|
+
}
|
|
120
|
+
}
|
|
121
|
+
}
|
|
122
|
+
var A = .55, j = 1, M = .05, N = {
|
|
123
|
+
gain: 14e3,
|
|
124
|
+
reach: 340,
|
|
125
|
+
ramp: 4,
|
|
126
|
+
maxSpeed: 4,
|
|
127
|
+
soften: 8,
|
|
128
|
+
holdMs: 140
|
|
129
|
+
};
|
|
130
|
+
function P(e, t, n, r = -1) {
|
|
67
131
|
let { nodes: i } = e, a = -1, o = Infinity;
|
|
68
132
|
for (let e = 0; e < i.length; e++) {
|
|
69
133
|
if (e === r) continue;
|
|
@@ -72,13 +136,13 @@ function w(e, t, n, r = -1) {
|
|
|
72
136
|
}
|
|
73
137
|
return a;
|
|
74
138
|
}
|
|
75
|
-
function
|
|
139
|
+
function F(e, t) {
|
|
76
140
|
let { warp: n, nodes: r } = e;
|
|
77
141
|
if (!n || n.targetIdx < 0 || n.targetIdx >= r.length || !(t > 0)) return;
|
|
78
|
-
let i = Math.min(t,
|
|
79
|
-
n.vx +=
|
|
142
|
+
let i = Math.min(t, M), a = e.warpCfg?.response ?? .55, o = e.warpCfg?.zeta ?? 1, s = 2 * Math.PI / a, c = r[n.targetIdx], l = -2 * o * s * n.vx - s * s * (n.x - c.x), u = -2 * o * s * n.vy - s * s * (n.y - c.y);
|
|
143
|
+
n.vx += l * i, n.vy += u * i, n.x += n.vx * i, n.y += n.vy * i;
|
|
80
144
|
}
|
|
81
|
-
function
|
|
145
|
+
function I(e, t) {
|
|
82
146
|
let { warp: n, nodes: r } = e;
|
|
83
147
|
if (t < 0 || t >= r.length) {
|
|
84
148
|
n.targetIdx = -1, e.focalIndex = -1;
|
|
@@ -86,13 +150,28 @@ function E(e, t) {
|
|
|
86
150
|
}
|
|
87
151
|
e.focalIndex = t, n.targetIdx = t;
|
|
88
152
|
}
|
|
89
|
-
function
|
|
90
|
-
let r =
|
|
153
|
+
function L(e, t, n) {
|
|
154
|
+
let r = P(e, t, n, -1);
|
|
91
155
|
if (r >= 0 && r === e.focalIndex) return e.focalIndex;
|
|
92
|
-
let i =
|
|
93
|
-
return i < 0 ? -1 : (
|
|
156
|
+
let i = P(e, t, n, e.focalIndex);
|
|
157
|
+
return i < 0 ? -1 : (I(e, i), i);
|
|
94
158
|
}
|
|
95
|
-
|
|
159
|
+
var R = 24;
|
|
160
|
+
function z(e) {
|
|
161
|
+
let { warp: t, nodes: n } = e;
|
|
162
|
+
if (!t || t.targetIdx < 0 || t.targetIdx >= n.length) return !0;
|
|
163
|
+
let r = n[t.targetIdx];
|
|
164
|
+
return Math.hypot(t.x - r.x, t.y - r.y) < R;
|
|
165
|
+
}
|
|
166
|
+
function B(e, t) {
|
|
167
|
+
let n = e.nodes.length;
|
|
168
|
+
if (n <= 1) return e.focalIndex;
|
|
169
|
+
let r = e.focalIndex;
|
|
170
|
+
if (r < 0 || r >= n) return Math.floor(t() * n) % n;
|
|
171
|
+
let i = Math.floor(t() * (n - 1));
|
|
172
|
+
return i < r ? i : i + 1;
|
|
173
|
+
}
|
|
174
|
+
function V(e, t, n, r) {
|
|
96
175
|
let { nodes: i, k: a } = t, o = n * a, s = o * o, c = r.edgeAlpha * r.alpha;
|
|
97
176
|
e.strokeStyle = r.line, e.lineWidth = 1 * a;
|
|
98
177
|
for (let t = 0; t < i.length; t++) {
|
|
@@ -104,14 +183,14 @@ function O(e, t, n, r) {
|
|
|
104
183
|
}
|
|
105
184
|
e.globalAlpha = 1;
|
|
106
185
|
}
|
|
107
|
-
function
|
|
186
|
+
function H(e, t, n) {
|
|
108
187
|
let { nodes: r, k: i } = t;
|
|
109
188
|
for (let t = 0; t < r.length; t++) {
|
|
110
189
|
let a = r[t];
|
|
111
190
|
e.fillStyle = a.dim ? n.nodeDim : n.node, e.beginPath(), e.arc(a.x, a.y, a.r * i, 0, Math.PI * 2), e.fill();
|
|
112
191
|
}
|
|
113
192
|
}
|
|
114
|
-
function
|
|
193
|
+
function U(e, t, n, r, i) {
|
|
115
194
|
if (!i || i.x < 0) return;
|
|
116
195
|
let { nodes: a, k: o } = t, s = n * o, c = s * s, l = r.edgeFocusAlpha * r.alpha;
|
|
117
196
|
e.strokeStyle = r.line, e.lineWidth = 1 * o;
|
|
@@ -121,7 +200,7 @@ function A(e, t, n, r, i) {
|
|
|
121
200
|
}
|
|
122
201
|
e.globalAlpha = .55, e.fillStyle = r.node, e.beginPath(), e.arc(i.x, i.y, 2.6 * o, 0, Math.PI * 2), e.fill(), e.globalAlpha = 1;
|
|
123
202
|
}
|
|
124
|
-
function
|
|
203
|
+
function W(e, t, n, r, i) {
|
|
125
204
|
let { k: a } = t;
|
|
126
205
|
e.strokeStyle = i.line;
|
|
127
206
|
for (let t = r.length - 1; t >= 0; t--) {
|
|
@@ -137,8 +216,8 @@ function j(e, t, n, r, i) {
|
|
|
137
216
|
e.globalAlpha = 1;
|
|
138
217
|
}
|
|
139
218
|
//#endregion
|
|
140
|
-
//#region src/components/custom/constellation/Constellation.vue
|
|
141
|
-
var
|
|
219
|
+
//#region src/components/custom/constellation/Constellation.vue?vue&type=script&setup=true&lang.ts
|
|
220
|
+
var G = 0, K = /* @__PURE__ */ n(/* @__PURE__ */ c({
|
|
142
221
|
__name: "Constellation",
|
|
143
222
|
props: {
|
|
144
223
|
count: { default: 64 },
|
|
@@ -153,6 +232,15 @@ var M = /* @__PURE__ */ n(/* @__PURE__ */ c({
|
|
|
153
232
|
type: Boolean,
|
|
154
233
|
default: !1
|
|
155
234
|
},
|
|
235
|
+
wander: {
|
|
236
|
+
type: [Boolean, Object],
|
|
237
|
+
default: !1
|
|
238
|
+
},
|
|
239
|
+
gravityWell: {
|
|
240
|
+
type: [Boolean, Object],
|
|
241
|
+
default: !1
|
|
242
|
+
},
|
|
243
|
+
freeze: { type: Boolean },
|
|
156
244
|
class: { type: [
|
|
157
245
|
Boolean,
|
|
158
246
|
null,
|
|
@@ -163,7 +251,7 @@ var M = /* @__PURE__ */ n(/* @__PURE__ */ c({
|
|
|
163
251
|
drawOverlay: { type: Function }
|
|
164
252
|
},
|
|
165
253
|
setup(n, { expose: c }) {
|
|
166
|
-
let
|
|
254
|
+
let _ = h("hostRef"), v = h("canvasRef"), T = a(() => n.seed === void 0 ? Math.random : r(typeof n.seed == "string" ? i(n.seed) : n.seed)), E = () => typeof window < "u" && /[?&](export|print|freeze)\b/.test(window.location.search), D = l()?.vnode.props?.freeze, O = a(() => D === void 0 ? E() : D === !0 || D === ""), k = {
|
|
167
255
|
nodes: [],
|
|
168
256
|
canvas: null,
|
|
169
257
|
w: 0,
|
|
@@ -178,74 +266,126 @@ var M = /* @__PURE__ */ n(/* @__PURE__ */ c({
|
|
|
178
266
|
vy: 0,
|
|
179
267
|
targetIdx: -1
|
|
180
268
|
}
|
|
181
|
-
},
|
|
269
|
+
}, A = n.wander && n.wander !== !0 ? n.wander : {};
|
|
270
|
+
k.wander = n.wander ? {
|
|
271
|
+
nextAt: -1,
|
|
272
|
+
minIdle: A.minIdle ?? 8e3,
|
|
273
|
+
jitter: A.jitter ?? 8e3
|
|
274
|
+
} : void 0;
|
|
275
|
+
let j = n.gravityWell && n.gravityWell !== !0 ? n.gravityWell : {};
|
|
276
|
+
k.well = n.gravityWell ? {
|
|
277
|
+
x: -1,
|
|
278
|
+
y: -1,
|
|
279
|
+
strength: 0,
|
|
280
|
+
target: 0,
|
|
281
|
+
cfg: {
|
|
282
|
+
...N,
|
|
283
|
+
...j
|
|
284
|
+
}
|
|
285
|
+
} : void 0;
|
|
286
|
+
let M = {
|
|
182
287
|
x: -1,
|
|
183
288
|
y: -1
|
|
184
|
-
},
|
|
185
|
-
return
|
|
186
|
-
let e =
|
|
289
|
+
}, P = [], F = { ...y }, I = -1, R = !1, z = p(null);
|
|
290
|
+
return d(() => {
|
|
291
|
+
let e = v.value;
|
|
187
292
|
if (!e) return;
|
|
188
293
|
let r = t({
|
|
189
|
-
canvas:
|
|
294
|
+
canvas: v,
|
|
190
295
|
setup: (t) => ({ render(t, i) {
|
|
191
|
-
let a = e.clientWidth || e.offsetWidth || 1280, o = e.clientHeight || e.offsetHeight || 720, s = a /
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
296
|
+
let a = e.clientWidth || e.offsetWidth || 1280, o = e.clientHeight || e.offsetHeight || 720, s = a / g;
|
|
297
|
+
if (k.canvas = e, k.dpr = Math.min(typeof window < "u" && window.devicePixelRatio || 1, 2), k.w !== a || k.h !== o) {
|
|
298
|
+
let t = k.w, r = k.h;
|
|
299
|
+
if (k.w = a, k.h = o, k.k = s, k.nodes.length ? C(k, t, r) : (k.nodes = S(T.value, n.count, a, o, n.speed), k.warp.x = a / 2, k.warp.y = o / 2), F = b(e), !R) {
|
|
300
|
+
R = !0;
|
|
301
|
+
let t = x(e);
|
|
302
|
+
k.warpCfg = t.warp, k.well && (k.well.cfg = {
|
|
303
|
+
...t.well,
|
|
304
|
+
...j
|
|
305
|
+
}), k.wander && (k.wander.minIdle = A.minIdle ?? t.wander.minIdle, k.wander.jitter = A.jitter ?? t.wander.jitter);
|
|
306
|
+
}
|
|
307
|
+
}
|
|
308
|
+
k.k = s;
|
|
309
|
+
let c = I < 0 ? 0 : (i - I) / 1e3;
|
|
310
|
+
I = i;
|
|
311
|
+
let l = O.value || r.reducedMotion;
|
|
312
|
+
if (l && k.well && (k.well.strength = 0, k.well.target = 0, k.well.x = -1, k.well.y = -1), !l) {
|
|
313
|
+
let e = n.pointerReactive ? M : null;
|
|
314
|
+
w(k, s, n.speed, e, c, i, T.value);
|
|
197
315
|
}
|
|
198
|
-
t.clearRect(0, 0, a, o),
|
|
316
|
+
t.clearRect(0, 0, a, o), V(t, k, n.link, F), H(t, k, F), n.pointerReactive && !l && (U(t, k, n.link, F, M), W(t, k, i, P, F)), n.drawOverlay?.(t, k, l ? G : i);
|
|
199
317
|
} })
|
|
200
|
-
}), i =
|
|
318
|
+
}), i = _.value, a = (t) => {
|
|
201
319
|
let n = e.getBoundingClientRect();
|
|
202
320
|
if (!n.width || !n.height) return null;
|
|
203
321
|
let r = (t.clientX - n.left) / n.width, i = (t.clientY - n.top) / n.height;
|
|
204
322
|
return r < 0 || i < 0 || r > 1 || i > 1 ? null : {
|
|
205
|
-
x: r *
|
|
206
|
-
y: i *
|
|
323
|
+
x: r * k.w,
|
|
324
|
+
y: i * k.h
|
|
207
325
|
};
|
|
208
326
|
};
|
|
209
|
-
|
|
327
|
+
if (z.value = a, n.pointerReactive && i && !O.value && !r.reducedMotion && (i.addEventListener("pointermove", (e) => {
|
|
210
328
|
let t = a(e);
|
|
211
|
-
t ? (
|
|
329
|
+
t ? (M.x = t.x, M.y = t.y) : (M.x = -1, M.y = -1), r.wake();
|
|
212
330
|
}), i.addEventListener("pointerleave", () => {
|
|
213
|
-
|
|
331
|
+
M.x = -1, M.y = -1;
|
|
214
332
|
}), i.addEventListener("pointerdown", (e) => {
|
|
215
333
|
let t = a(e);
|
|
216
|
-
t &&
|
|
334
|
+
t && P.push({
|
|
217
335
|
x: t.x,
|
|
218
336
|
y: t.y,
|
|
219
337
|
start: -1
|
|
220
338
|
}), r.wake();
|
|
221
|
-
})), n.warpOnClick && i && !r.reducedMotion && i.addEventListener("pointerdown", (e) => {
|
|
339
|
+
})), n.warpOnClick && i && !O.value && !r.reducedMotion && i.addEventListener("pointerdown", (e) => {
|
|
222
340
|
let t = a(e);
|
|
223
|
-
t && (
|
|
224
|
-
})
|
|
341
|
+
t && (L(k, t.x, t.y), r.wake());
|
|
342
|
+
}), n.gravityWell && i && k.well && !O.value && !r.reducedMotion) {
|
|
343
|
+
let e = k.well, t, n = (n) => {
|
|
344
|
+
let i = a(n);
|
|
345
|
+
i && (e.x = i.x, e.y = i.y, t = window.setTimeout(() => {
|
|
346
|
+
e.target = 1, r.wake();
|
|
347
|
+
}, e.cfg.holdMs), r.wake());
|
|
348
|
+
}, o = (t) => {
|
|
349
|
+
if (e.target > 0) {
|
|
350
|
+
let n = a(t);
|
|
351
|
+
n && (e.x = n.x, e.y = n.y);
|
|
352
|
+
}
|
|
353
|
+
}, s = () => {
|
|
354
|
+
t !== void 0 && (clearTimeout(t), t = void 0), e.target = 0, r.wake();
|
|
355
|
+
};
|
|
356
|
+
i.addEventListener("pointerdown", n), i.addEventListener("pointermove", o), i.addEventListener("pointerup", s), i.addEventListener("pointerleave", s), i.addEventListener("pointercancel", s);
|
|
357
|
+
}
|
|
225
358
|
}), c({
|
|
226
|
-
field:
|
|
359
|
+
field: k,
|
|
360
|
+
isFrozen: O,
|
|
227
361
|
warpTo(e, t) {
|
|
228
362
|
if (typeof e == "number" && typeof t == "number") {
|
|
229
|
-
let n =
|
|
363
|
+
let n = z.value?.({
|
|
230
364
|
clientX: e,
|
|
231
365
|
clientY: t
|
|
232
366
|
});
|
|
233
|
-
return n ?
|
|
367
|
+
return n ? L(k, n.x, n.y) : -1;
|
|
234
368
|
}
|
|
235
369
|
let n = e;
|
|
236
|
-
return
|
|
370
|
+
return L(k, n.x, n.y);
|
|
371
|
+
},
|
|
372
|
+
holdWellAt(e, t) {
|
|
373
|
+
return k.well ? (k.well.x = e, k.well.y = t, k.well.target = 1, !0) : !1;
|
|
374
|
+
},
|
|
375
|
+
releaseWell() {
|
|
376
|
+
k.well && (k.well.target = 0);
|
|
237
377
|
}
|
|
238
|
-
}), (t, r) => (
|
|
378
|
+
}), (t, r) => (f(), o("div", {
|
|
239
379
|
ref_key: "hostRef",
|
|
240
|
-
ref:
|
|
241
|
-
class:
|
|
380
|
+
ref: _,
|
|
381
|
+
class: u(m(e)("constellation", n.class))
|
|
242
382
|
}, [s("canvas", {
|
|
243
383
|
ref_key: "canvasRef",
|
|
244
|
-
ref:
|
|
384
|
+
ref: v,
|
|
245
385
|
class: "constellation-canvas",
|
|
246
386
|
"aria-hidden": "true"
|
|
247
387
|
}, null, 512)], 2));
|
|
248
388
|
}
|
|
249
|
-
}), [["__scopeId", "data-v-
|
|
389
|
+
}), [["__scopeId", "data-v-a8ae86fe"]]);
|
|
250
390
|
//#endregion
|
|
251
|
-
export {
|
|
391
|
+
export { g as BASE_WIDTH, K as Constellation, y as DEFAULT_PALETTE, _ as DEFAULT_WANDER_IDLE, v as DEFAULT_WANDER_JITTER, N as DEFAULT_WELL_CONFIG, A as WARP_RESPONSE, j as WARP_ZETA, V as drawEdges, H as drawNodes, U as drawPointerWeb, W as drawRipples, P as nearestNode, B as pickWanderTarget, x as readInteractionConfig, b as readPalette, C as refitField, S as seedField, I as setWarpTarget, w as stepField, k as stepWell, z as warpSettled, F as warpStep, L as warpTo };
|
package/dist/context-menu.js
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import { a as e, c as t, i as n, l as r, n as i, o as a, r as o, s, t as c } from "./ContextMenuSubContent-
|
|
1
|
+
import { a as e, c as t, i as n, l as r, n as i, o as a, r as o, s, t as c } from "./ContextMenuSubContent-Bhg4f5jX.js";
|
|
2
2
|
import { n as l, r as u, t as d } from "./ContextMenuContent-DDa0v27s.js";
|
|
3
3
|
export { u as ContextMenu, s as ContextMenuCheckboxItem, d as ContextMenuContent, t as ContextMenuItem, o as ContextMenuLabel, r as ContextMenuRadioGroup, a as ContextMenuRadioItem, n as ContextMenuSeparator, e as ContextMenuShortcut, c as ContextMenuSubContent, i as ContextMenuSubTrigger, l as ContextMenuTrigger };
|
package/dist/controls.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { t as e } from "./cn-DJXf4yaB.js";
|
|
2
2
|
import { t } from "./_plugin-vue_export-helper-ok8pgSl5.js";
|
|
3
|
-
import { t as n } from "./useGlobalDark-
|
|
3
|
+
import { t as n } from "./useGlobalDark-d6waty-X.js";
|
|
4
4
|
import { computed as r, createBlock as i, createElementVNode as a, defineComponent as o, mergeProps as s, openBlock as c, resolveDynamicComponent as l, unref as u, useAttrs as d, watchEffect as f, withCtx as p } from "vue";
|
|
5
5
|
//#endregion
|
|
6
6
|
//#region src/components/custom/controls/DarkModeToggle.vue
|
package/dist/dark.js
CHANGED
package/dist/data-table.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { n as e, t } from "./DataTable-
|
|
1
|
+
import { n as e, t } from "./DataTable-CUHMukiQ.js";
|
|
2
2
|
export { t as DataTable, e as DataTablePagination };
|
package/dist/deck-progress.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { t as e } from "./DeckProgress-
|
|
1
|
+
import { t as e } from "./DeckProgress-Dmk4_AKN.js";
|
|
2
2
|
export { e as DeckProgress };
|
package/dist/dialog.js
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import { n as e, t } from "./DialogContent-
|
|
1
|
+
import { n as e, t } from "./DialogContent-BRkT1cjP.js";
|
|
2
2
|
import { a as n, i as r, n as i, o as a, r as o, s, t as c } from "./DialogFooter-Gprw8H_A.js";
|
|
3
3
|
export { e as Dialog, s as DialogClose, t as DialogContent, o as DialogDescription, c as DialogFooter, n as DialogHeader, i as DialogScrollContent, r as DialogTitle, a as DialogTrigger };
|