@mkbabb/glass-ui 8.0.0 → 10.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/MIGRATION.md +4768 -0
- package/README.md +57 -13
- package/dist/DialogContent-CwIBvou_.js +157 -0
- package/dist/{DropdownMenuTrigger-8UZsBtZ8.js → DropdownMenuTrigger-CKRnhDSQ.js} +1 -1
- package/dist/{Surface-i1tWC-Ga.js → Surface-1nPoabc3.js} +1 -1
- package/dist/{accent-tone-solve-Cw7WkRD9.js → accent-tone-solve-5H6FY2QO.js} +1 -1
- package/dist/aurora.js +386 -355
- package/dist/{badge-owUOaaba.js → badge-BO6BC4G5.js} +1 -1
- package/dist/badge.js +1 -1
- package/dist/blob.js +44 -44
- package/dist/{button-yvGPb0Bx.js → button-BOFTUPyU.js} +1 -1
- package/dist/button.js +1 -1
- package/dist/{card-3HFFpC7_.js → card-ByyqRBvK.js} +2 -2
- package/dist/card.js +1 -1
- package/dist/carousel.js +3 -3
- package/dist/{checkbox-BnXuGgJ3.js → checkbox-B1qn65se.js} +1 -1
- package/dist/checkbox.js +1 -1
- package/dist/chip.js +8 -3
- package/dist/{class-names-q-UGOkHH.js → class-names-FlXcvRRT.js} +65 -18
- package/dist/{collapsible-B7O6m-Ch.js → collapsible-DFzK29Oh.js} +5 -2
- package/dist/collapsible.js +1 -1
- package/dist/color.glsl-DTJhdekG.js +34 -0
- package/dist/color.js +11 -11
- package/dist/color.wgsl-BTszLY39.js +398 -0
- package/dist/{command-BuBnYpxF.js → command-C-5xSEJ2.js} +8 -8
- package/dist/command.js +1 -1
- package/dist/component-styles.css +1 -0
- package/dist/components/_shared/class-names.d.ts +10 -1
- package/dist/components/_shared/control.d.ts +0 -1
- package/dist/components/_shared/index.d.ts +0 -1
- package/dist/components/_shared/menu/menu.css +1 -1
- package/dist/components/_shared/overlay/index.d.ts +1 -0
- package/dist/components/_shared/overlay/shortcuts.d.ts +12 -0
- package/dist/components/aurora/Aurora.vue.d.ts +1 -0
- package/dist/components/aurora/composables/atoms.d.ts +22 -6
- package/dist/components/aurora/composables/frameLoop.d.ts +6 -5
- package/dist/components/aurora/composables/runtime.d.ts +28 -1
- package/dist/components/aurora/composables/useAurora.d.ts +28 -0
- package/dist/components/aurora/composables/wgpuSetup.d.ts +1 -1
- package/dist/components/aurora/constants/presets.d.ts +62 -5
- package/dist/components/aurora/index.d.ts +1 -1
- package/dist/components/blob/Blob.vue.d.ts +3 -3
- package/dist/components/card/Card.vue.d.ts +8 -2
- package/dist/components/chip/Chip.vue.d.ts +1 -7
- package/dist/components/chip/chipVariants.d.ts +1 -0
- package/dist/components/collapsible/Collapsible.vue.d.ts +1 -0
- package/dist/components/command/CommandDialog.vue.d.ts +1 -1
- package/dist/components/configurator/Configurator.vue.d.ts +25 -2
- package/dist/components/configurator/ConfiguratorRow.vue.d.ts +4 -2
- package/dist/components/configurator/styles.css +1 -1
- package/dist/components/dark-mode-toggle/dark-mode-toggle.css +1 -1
- package/dist/components/deck/styles/capture.css +1 -1
- package/dist/components/dialog/styles.css +1 -1
- package/dist/components/dock/DockSeparator.vue.d.ts +2 -3
- package/dist/components/dock/GlassDock.vue.d.ts +1 -0
- package/dist/components/dock/composables/dockContext.d.ts +1 -8
- package/dist/components/dock/composables/dockCrossfadeContext.d.ts +0 -2
- package/dist/components/dock/composables/index.d.ts +1 -1
- package/dist/components/dock/composables/useDockHold.d.ts +16 -12
- package/dist/components/dock/composables/useDockRun.d.ts +20 -0
- package/dist/components/dock/composables/useDockSearch.d.ts +1 -1
- package/dist/components/dock/composables/useDockShellProps.d.ts +18 -101
- package/dist/components/dock/composables/useDockState.d.ts +2 -9
- package/dist/components/dock/constants.d.ts +15 -0
- package/dist/components/dock/index.d.ts +2 -2
- package/dist/components/dock/styles/controls/icon-button.css +1 -1
- package/dist/components/dock/styles/controls/tab-button.css +1 -1
- package/dist/components/dock/styles/controls/triggers.css +1 -1
- package/dist/components/dock/styles/controls.css +1 -1
- package/dist/components/dock/styles/density.css +1 -1
- package/dist/components/dock/styles/index.css +1 -1
- package/dist/components/dock/styles/layer-group.css +1 -1
- package/dist/components/dock/styles/layers.css +1 -1
- package/dist/components/dock/styles/morph.css +1 -1
- package/dist/components/dock/styles/run.css +1 -0
- package/dist/components/dock/styles/search.css +1 -1
- package/dist/components/dock/styles/shape.css +1 -1
- package/dist/components/dock/styles/shell-regions.css +1 -1
- package/dist/components/dock/styles/shell.css +1 -1
- package/dist/components/fourier-field/FourierField.vue.d.ts +29 -26
- package/dist/components/fourier-field/clock.d.ts +35 -0
- package/dist/components/fourier-field/constants.d.ts +80 -104
- package/dist/components/fourier-field/index.d.ts +3 -28
- package/dist/components/fourier-field/math.d.ts +69 -77
- package/dist/components/fourier-field/renderer/mint.d.ts +50 -0
- package/dist/components/fourier-field/renderer/uniforms.d.ts +84 -0
- package/dist/components/fourier-field/renderer/wgpu.d.ts +28 -0
- package/dist/components/fourier-field/shaders/compute.wgsl.d.ts +1 -0
- package/dist/components/fourier-field/shaders/render.wgsl.d.ts +1 -0
- package/dist/components/fourier-field/useFourierField.d.ts +49 -0
- package/dist/components/handmark/HandMark.vue.d.ts +18 -14
- package/dist/components/handmark/index.d.ts +4 -23
- package/dist/components/handmark/stroke.d.ts +92 -0
- package/dist/components/labeled-field/LabeledSwitch.vue.d.ts +3 -1
- package/dist/components/labeled-field/types.d.ts +1 -1
- package/dist/components/menu/DropdownMenu.vue.d.ts +1 -1
- package/dist/components/metric/coalesce-metric.d.ts +6 -1
- package/dist/components/metric/styles.css +1 -1
- package/dist/components/popover/Popover.vue.d.ts +1 -1
- package/dist/components/scroll-progress-rim/styles.css +1 -1
- package/dist/components/sheet/styles.css +1 -1
- package/dist/components/slider/styles.css +1 -1
- package/dist/components/tabs/SegmentedTabs.vue.d.ts +25 -112
- package/dist/components/tabs/composables/useTabDragMorph.d.ts +1 -1
- package/dist/components/tabs/composables/useTabResponsive.d.ts +11 -11
- package/dist/components/tabs/index.d.ts +1 -1
- package/dist/components/tabs/styles/drag.css +1 -1
- package/dist/components/tabs/styles/segmented.css +1 -1
- package/dist/components/tabs/types.d.ts +85 -0
- package/dist/components/timeline/index.d.ts +2 -0
- package/dist/components/toast/Toast.vue.d.ts +2 -2
- package/dist/composables/color/index.d.ts +0 -15
- package/dist/composables/dark/darkModeSyncScript.d.ts +42 -0
- package/dist/composables/dom/useResolveTokenColor.d.ts +1 -1
- package/dist/composables/glass/index.d.ts +2 -0
- package/dist/composables/keyboard/useKeyboardShortcuts.d.ts +47 -1
- package/dist/composables/motion/pointer/pointerFieldMappings.d.ts +0 -41
- package/dist/{components/search/composables → composables/search}/index.d.ts +2 -2
- package/dist/{components/search/composables/fuzzySearchIndex.d.ts → composables/search/match.d.ts} +8 -3
- package/dist/composables/sidebar/types.d.ts +5 -1
- package/dist/configurator-DiwVN573.js +339 -0
- package/dist/configurator.js +1 -1
- package/dist/constellation.js +5 -5
- package/dist/{content-CWO-XL7o.js → content-So3j6SOe.js} +1 -1
- package/dist/control-DJp15L4U.js +7 -0
- package/dist/dark-mode-toggle.js +2 -2
- package/dist/{dark-z_P5QwqI.js → dark-pONY3x93.js} +2 -2
- package/dist/dark.js +1 -1
- package/dist/{data-table-_RrOEdiw.js → data-table-Ba_uTfPc.js} +3 -3
- package/dist/data-table.js +1 -1
- package/dist/{deck-Ci6YjB5e.js → deck-Cm_VmyNL.js} +1 -1
- package/dist/deck.js +1 -1
- package/dist/{dialog-CbRnTRtg.js → dialog-BZoFG0j8.js} +1 -1
- package/dist/dialog.js +2 -2
- package/dist/dock.js +718 -496
- package/dist/dom.js +90 -8
- package/dist/easing.js +5 -5
- package/dist/expandable-container-CZUj9BzY.js +142 -0
- package/dist/expandable-container.js +2 -142
- package/dist/fourier-field.js +638 -855
- package/dist/fourier-math.js +6 -6
- package/dist/glass-ui.css +1 -1
- package/dist/glass-ui.js +88 -75
- package/dist/handmark.js +330 -718
- package/dist/index.d.ts +2 -2
- package/dist/infinite-scroll.js +16 -17
- package/dist/{input-Bls2A4Tt.js → input-eLZ_AU7l.js} +1 -1
- package/dist/input.js +1 -1
- package/dist/keyboard.js +64 -21
- package/dist/{label-BQEZhnK_.js → label-CE03H1KL.js} +2 -2
- package/dist/label.js +1 -1
- package/dist/labeled-field.js +9 -6
- package/dist/{menu-wLu1XGKn.js → menu-BnmCOa3y.js} +93 -90
- package/dist/menu.js +2 -2
- package/dist/metric.js +12 -7
- package/dist/{motion-D4uYE0UM.js → motion-BvV1_24p.js} +1 -1
- package/dist/motion-core.js +35 -35
- package/dist/{number-field-NFAwQ0HK.js → number-field-RP89046a.js} +2 -2
- package/dist/number-field.js +1 -1
- package/dist/pager-dots.js +3 -3
- package/dist/{participation-B0hdsIRo.js → participation-Di4UHbzk.js} +8 -8
- package/dist/{pointerFieldMappings-DP5tla5z.js → pointerFieldMappings-DXwlU5uj.js} +7 -23
- package/dist/popover-DA87hFBx.js +184 -0
- package/dist/popover.js +1 -1
- package/dist/{progress-DF8dWZIX.js → progress-eVa-mc7J.js} +1 -1
- package/dist/progress.js +1 -1
- package/dist/{radio-group-Ci8o-pDx.js → radio-group-B58Bz16F.js} +2 -2
- package/dist/radio-group.js +1 -1
- package/dist/{select-CDgwGH_P.js → select-fy3vtArm.js} +13 -13
- package/dist/select.js +1 -1
- package/dist/{separator-CN11t406.js → separator-D4EZM10u.js} +2 -2
- package/dist/separator.js +1 -1
- package/dist/{sheet-BEFvnO_u.js → sheet-BQJyER59.js} +120 -115
- package/dist/sheet.js +2 -2
- package/dist/shortcuts-DGGWNRNe.js +13 -0
- package/dist/sidebar.js +4 -4
- package/dist/{slider-gsc8jDIo.js → slider-5ChjjWSR.js} +1 -1
- package/dist/slider.js +1 -1
- package/dist/{status-dot-BpnqOP5N.js → status-dot-W4LFiJps.js} +2 -2
- package/dist/status-dot.js +1 -1
- package/dist/styles/accessibility.css +1 -1
- package/dist/styles/animations.css +1 -1
- package/dist/styles/components.css +1 -1
- package/dist/styles/glass/a11y-fallback.css +1 -1
- package/dist/styles/glass/dissolve.css +1 -1
- package/dist/styles/glass/focus-veil.css +1 -1
- package/dist/styles/glass/ladder.css +1 -1
- package/dist/styles/glass/material.css +1 -1
- package/dist/styles/glass/overlay-plate.css +1 -1
- package/dist/styles/glass/reveal.css +1 -1
- package/dist/styles/glass-specular-track.css +1 -1
- package/dist/styles/paper.css +1 -1
- package/dist/styles/scroll-choreography.css +1 -1
- package/dist/styles/scroll-chrome.css +1 -1
- package/dist/styles/scroll-driven.css +1 -1
- package/dist/styles/theme/literals.css +1 -1
- package/dist/styles/tokens/color-radius.css +1 -1
- package/dist/styles/tokens/dark-arm-glass.css +1 -1
- package/dist/styles/tokens/light-dark.css +1 -1
- package/dist/styles/tokens/offsets.css +1 -1
- package/dist/styles/tokens/scheme-motion.css +1 -1
- package/dist/styles/tokens/sizing.css +1 -1
- package/dist/styles/typography/semantic.css +1 -1
- package/dist/styles/typography/utilities.css +1 -1
- package/dist/styles/utilities/a11y-overrides.css +1 -1
- package/dist/styles/utilities/responsive.css +1 -1
- package/dist/styles/view-transition.css +1 -1
- package/dist/styles/viz-reveal.css +1 -1
- package/dist/surface.js +1 -1
- package/dist/{switch-DxZzDrmV.js → switch-BYUZ6g9G.js} +2 -2
- package/dist/switch.js +1 -1
- package/dist/{tabs-CYscnq5H.js → tabs-rdRXKXxd.js} +4 -3
- package/dist/tabs.js +1 -1
- package/dist/textarea.js +1 -1
- package/dist/timeline.js +44 -42
- package/dist/{toast-9c6Kp58L.js → toast-DVOwo6GB.js} +1 -1
- package/dist/toast.js +1 -1
- package/dist/{toggle-group-11aPGMfE.js → toggle-group-CC5b3o1R.js} +2 -2
- package/dist/toggle-group.js +1 -1
- package/dist/{tooltip-DqKMZ4dn.js → tooltip-DhTHhtJN.js} +2 -2
- package/dist/tooltip.js +1 -1
- package/dist/typewriter.js +1 -1
- package/dist/{useAccentTone-DFAh1osB.js → useAccentTone-DitmKfGL.js} +1 -1
- package/dist/{resolveCanvasColor-6MCrswTB.js → useCanvas2D-CQRElMyE.js} +1 -11
- package/dist/{usePointerVelocityField-DsIf7yyq.js → usePointerVelocityField-Lx26_Yap.js} +1 -1
- package/dist/useResolveTokenColor-B2FfJnd9.js +24 -0
- package/package.json +5 -21
- package/dist/DialogContent-4hzLiaCQ.js +0 -152
- package/dist/canvas.d.ts +0 -1
- package/dist/canvas.js +0 -2
- package/dist/color.wgsl-B0N3mKMb.js +0 -412
- package/dist/compile-D7VYG3gi.js +0 -19
- package/dist/components/dock/composables/useDockOverflowFit.d.ts +0 -20
- package/dist/components/dock/composables/useDockTouchGate.d.ts +0 -42
- package/dist/components/dock/styles/overflow.css +0 -1
- package/dist/components/fourier-field/composables/fourierFieldGLSetup.d.ts +0 -24
- package/dist/components/fourier-field/composables/fourierFieldWGPUSetup.d.ts +0 -31
- package/dist/components/fourier-field/composables/uniformBridgeWGPU.d.ts +0 -39
- package/dist/components/fourier-field/composables/useFourierField.d.ts +0 -56
- package/dist/components/fourier-field/shaders/fourier-field.compute.wgsl.d.ts +0 -1
- package/dist/components/fourier-field/shaders/fourier-field.glsl.d.ts +0 -4
- package/dist/components/fourier-field/shaders/fourier-field.render.wgsl.d.ts +0 -1
- package/dist/components/fourier-field/shaders/fourier-field.ribbon.d.ts +0 -51
- package/dist/components/handmark/brush.d.ts +0 -269
- package/dist/components/handmark/composables/useHandMark.d.ts +0 -99
- package/dist/components/handmark/constants.d.ts +0 -69
- package/dist/components/handmark/freehand.d.ts +0 -69
- package/dist/components/handmark/geometry.d.ts +0 -62
- package/dist/components/handmark/ink.d.ts +0 -11
- package/dist/components/handmark/noise.d.ts +0 -30
- package/dist/components/handmark/texture.d.ts +0 -39
- package/dist/components/handmark/types.d.ts +0 -70
- package/dist/components/search/SearchBar.vue.d.ts +0 -38
- package/dist/components/search/index.d.ts +0 -8
- package/dist/components/search/searchVariants.d.ts +0 -16
- package/dist/configurator-BoeScnDL.js +0 -311
- package/dist/control-Da4XeT43.js +0 -11
- package/dist/popover-DBMKTPkL.js +0 -181
- package/dist/search.d.ts +0 -1
- package/dist/search.js +0 -61
- package/dist/useFuzzySearch-CUnZknpm.js +0 -177
- package/dist/useResolveTokenColor-CspQv_ik.js +0 -107
- /package/dist/{components/search/composables → composables/search}/types.d.ts +0 -0
- /package/dist/{components/search/composables → composables/search}/useFuzzySearch.d.ts +0 -0
|
@@ -0,0 +1,398 @@
|
|
|
1
|
+
import { n as e, t } from "./createCanvasLifecycle-hJHobVTn.js";
|
|
2
|
+
import { a as n, i as r, o as i, r as a } from "./rendererStatus-BxUlBLVy.js";
|
|
3
|
+
//#region src/composables/glass/webgl/useWebGLCanvas.ts
|
|
4
|
+
function o() {
|
|
5
|
+
if (typeof document > "u") return null;
|
|
6
|
+
let e = null;
|
|
7
|
+
try {
|
|
8
|
+
if (e = document.createElement("canvas").getContext("webgl2"), !e) return null;
|
|
9
|
+
let t = e.getExtension("WEBGL_debug_renderer_info");
|
|
10
|
+
return t ? String(e.getParameter(t.UNMASKED_RENDERER_WEBGL) ?? "").toLowerCase() : null;
|
|
11
|
+
} catch {
|
|
12
|
+
return null;
|
|
13
|
+
} finally {
|
|
14
|
+
e?.getExtension("WEBGL_lose_context")?.loseContext();
|
|
15
|
+
}
|
|
16
|
+
}
|
|
17
|
+
function s(e, n) {
|
|
18
|
+
let { setup: r, contextAttrs: i } = n, a = null, o = null;
|
|
19
|
+
function s() {
|
|
20
|
+
let t = e.getContext("webgl2", i ?? void 0);
|
|
21
|
+
if (!t) throw Error("[useWebGLCanvas] WebGL2 unavailable");
|
|
22
|
+
return a = t, o = r(a), {
|
|
23
|
+
frame: o.frame,
|
|
24
|
+
shouldContinue: o.shouldContinue,
|
|
25
|
+
time: o.time,
|
|
26
|
+
teardown: () => {
|
|
27
|
+
o?.teardown?.(), a?.getExtension("WEBGL_lose_context")?.loseContext(), a = null, o = null;
|
|
28
|
+
}
|
|
29
|
+
};
|
|
30
|
+
}
|
|
31
|
+
let c = null, l = null;
|
|
32
|
+
function u(e) {
|
|
33
|
+
e.preventDefault(), a = null, o = null, l?.();
|
|
34
|
+
}
|
|
35
|
+
let d = t({
|
|
36
|
+
canvas: e,
|
|
37
|
+
mode: n.mode,
|
|
38
|
+
respectReducedMotion: n.respectReducedMotion,
|
|
39
|
+
dprPolicy: n.dprPolicy,
|
|
40
|
+
composeIntersectionPark: n.composeIntersectionPark,
|
|
41
|
+
intersectionRootMargin: n.intersectionRootMargin,
|
|
42
|
+
revealBloom: n.revealBloom,
|
|
43
|
+
onContextStateChange: n.onContextStateChange,
|
|
44
|
+
onContextError: n.onContextError,
|
|
45
|
+
buildContext: s,
|
|
46
|
+
resize: (e) => o?.resize(e),
|
|
47
|
+
bindContextEvents: (t, n) => {
|
|
48
|
+
c = t, l = n, e.addEventListener("webglcontextlost", u, !1), e.addEventListener("webglcontextrestored", c, !1);
|
|
49
|
+
},
|
|
50
|
+
unbindContextEvents: () => {
|
|
51
|
+
e.removeEventListener("webglcontextlost", u, !1), c && e.removeEventListener("webglcontextrestored", c, !1);
|
|
52
|
+
}
|
|
53
|
+
});
|
|
54
|
+
return {
|
|
55
|
+
arm: d.arm,
|
|
56
|
+
presize: d.presize,
|
|
57
|
+
suspend: d.suspend,
|
|
58
|
+
resume: d.resume,
|
|
59
|
+
wake: d.wake,
|
|
60
|
+
renderAt: d.renderAt,
|
|
61
|
+
dispose: d.dispose,
|
|
62
|
+
get gl() {
|
|
63
|
+
return a;
|
|
64
|
+
},
|
|
65
|
+
get reducedMotion() {
|
|
66
|
+
return d.reducedMotion;
|
|
67
|
+
}
|
|
68
|
+
};
|
|
69
|
+
}
|
|
70
|
+
//#endregion
|
|
71
|
+
//#region src/composables/glass/webgpu/webgpuDevice.ts
|
|
72
|
+
var c = class extends Error {
|
|
73
|
+
kind;
|
|
74
|
+
constructor(e, t, n) {
|
|
75
|
+
super(t), this.name = "WebGPUInitError", this.kind = e, n !== void 0 && (this.cause = n);
|
|
76
|
+
}
|
|
77
|
+
};
|
|
78
|
+
function l(e) {
|
|
79
|
+
try {
|
|
80
|
+
let t = e.info;
|
|
81
|
+
if (t?.isFallbackAdapter || e.isFallbackAdapter) return !0;
|
|
82
|
+
if (!t) return !1;
|
|
83
|
+
let n = [
|
|
84
|
+
t.vendor,
|
|
85
|
+
t.architecture,
|
|
86
|
+
t.description
|
|
87
|
+
].filter((e) => typeof e == "string").join(" ").toLowerCase();
|
|
88
|
+
return n.includes("swiftshader") || n.includes("llvmpipe") || n.includes("software") || n.includes("basic render") || n.includes("microsoft basic");
|
|
89
|
+
} catch {
|
|
90
|
+
return !1;
|
|
91
|
+
}
|
|
92
|
+
}
|
|
93
|
+
var u = 6e3;
|
|
94
|
+
function d(e, t) {
|
|
95
|
+
if (typeof setTimeout > "u") return e;
|
|
96
|
+
let n, r = new Promise((e, r) => {
|
|
97
|
+
n = setTimeout(() => {
|
|
98
|
+
r(new c("acquire-timeout", `[useWebGPUCanvas] ${t}() did not settle within ${u}ms — falling to the WebGL2 net`));
|
|
99
|
+
}, u);
|
|
100
|
+
});
|
|
101
|
+
return Promise.race([e, r]).finally(() => clearTimeout(n));
|
|
102
|
+
}
|
|
103
|
+
//#endregion
|
|
104
|
+
//#region src/composables/glass/webgpu/useWebGPUCanvas.ts
|
|
105
|
+
function f() {
|
|
106
|
+
return typeof navigator < "u" && "gpu" in navigator && navigator.gpu != null;
|
|
107
|
+
}
|
|
108
|
+
var p = null;
|
|
109
|
+
function m(e, t) {
|
|
110
|
+
if (p) return p;
|
|
111
|
+
if (!f()) return Promise.reject(new c("no-navigator-gpu", "[useWebGPUCanvas] navigator.gpu unavailable"));
|
|
112
|
+
let n = (async () => {
|
|
113
|
+
let i = await d(navigator.gpu.requestAdapter(e), "requestAdapter");
|
|
114
|
+
if (!i) throw new c("no-adapter", "[useWebGPUCanvas] no GPU adapter");
|
|
115
|
+
if (l(i)) throw new c("software-adapter", "[useWebGPUCanvas] software WebGPU adapter (SwiftShader/llvmpipe/fallback) — falling to the WebGL2 net");
|
|
116
|
+
let a;
|
|
117
|
+
try {
|
|
118
|
+
a = await d(i.requestDevice(t), "requestDevice");
|
|
119
|
+
} catch (e) {
|
|
120
|
+
throw e instanceof c ? e : new c("device-request", "[useWebGPUCanvas] requestDevice rejected", e);
|
|
121
|
+
}
|
|
122
|
+
return a.lost.then(() => {
|
|
123
|
+
p === n && (p = null);
|
|
124
|
+
}), {
|
|
125
|
+
device: a,
|
|
126
|
+
adapterClass: r(i.info)
|
|
127
|
+
};
|
|
128
|
+
})();
|
|
129
|
+
return n.catch(() => {
|
|
130
|
+
p === n && (p = null);
|
|
131
|
+
}), p = n, n;
|
|
132
|
+
}
|
|
133
|
+
function h(n, r) {
|
|
134
|
+
let { setup: i } = r, a = r.alphaMode ?? "premultiplied", o = null, s = null, l = "bgra8unorm", u = null, d = !1, p = null, h = null, g = "Acquiring adapter", _ = null, v = null, y = null;
|
|
135
|
+
function b() {
|
|
136
|
+
if (!o) throw Error("[useWebGPUCanvas] device not acquired");
|
|
137
|
+
let e = n.getContext("webgpu");
|
|
138
|
+
if (!e) throw Error("[useWebGPUCanvas] WebGPU context unavailable");
|
|
139
|
+
return s = e, l = navigator.gpu.getPreferredCanvasFormat(), e.configure({
|
|
140
|
+
device: o,
|
|
141
|
+
format: l,
|
|
142
|
+
alphaMode: a
|
|
143
|
+
}), o.pushErrorScope("validation"), o.addEventListener("uncapturederror", x), u = i(o, s, l), C(), y = o.popErrorScope(), y.then((e) => {
|
|
144
|
+
e && r.onInitError?.(e);
|
|
145
|
+
}), {
|
|
146
|
+
frame: (e) => u?.frame(e),
|
|
147
|
+
shouldContinue: () => u?.shouldContinue() ?? !1,
|
|
148
|
+
time: (e) => u?.time?.(e) ?? e,
|
|
149
|
+
teardown: S
|
|
150
|
+
};
|
|
151
|
+
}
|
|
152
|
+
function x(e) {
|
|
153
|
+
let t = e.error;
|
|
154
|
+
r.onInitError?.(t);
|
|
155
|
+
}
|
|
156
|
+
function S() {
|
|
157
|
+
u?.teardown?.(), o?.removeEventListener("uncapturederror", x), s?.unconfigure(), s = null, u = null, y = null;
|
|
158
|
+
}
|
|
159
|
+
function C() {
|
|
160
|
+
try {
|
|
161
|
+
u?.resize(e(n, r.dprPolicy)), u?.frame(0);
|
|
162
|
+
} catch {}
|
|
163
|
+
}
|
|
164
|
+
let w = t({
|
|
165
|
+
canvas: n,
|
|
166
|
+
mode: r.mode,
|
|
167
|
+
respectReducedMotion: r.respectReducedMotion,
|
|
168
|
+
dprPolicy: r.dprPolicy,
|
|
169
|
+
composeIntersectionPark: r.composeIntersectionPark,
|
|
170
|
+
intersectionRootMargin: r.intersectionRootMargin,
|
|
171
|
+
revealBloom: r.revealBloom,
|
|
172
|
+
onContextStateChange: (e) => {
|
|
173
|
+
if (e === "lost") {
|
|
174
|
+
r.onContextStateChange?.(e);
|
|
175
|
+
return;
|
|
176
|
+
}
|
|
177
|
+
let t = y;
|
|
178
|
+
if (!t) {
|
|
179
|
+
r.onContextStateChange?.(e);
|
|
180
|
+
return;
|
|
181
|
+
}
|
|
182
|
+
t.then((n) => {
|
|
183
|
+
!d && !n && y === t && r.onContextStateChange?.(e);
|
|
184
|
+
});
|
|
185
|
+
},
|
|
186
|
+
onContextError: (e) => r.onInitError?.(e),
|
|
187
|
+
buildContext: b,
|
|
188
|
+
resize: (e) => u?.resize(e),
|
|
189
|
+
bindContextEvents: (e, t) => {
|
|
190
|
+
_ = e, v = t;
|
|
191
|
+
},
|
|
192
|
+
unbindContextEvents: () => {
|
|
193
|
+
_ = null, v = null;
|
|
194
|
+
}
|
|
195
|
+
});
|
|
196
|
+
async function T() {
|
|
197
|
+
if (!f()) throw new c("no-navigator-gpu", "[useWebGPUCanvas] navigator.gpu unavailable");
|
|
198
|
+
let e = await m(r.adapterOptions, r.deviceDescriptor);
|
|
199
|
+
o = e.device, g = e.adapterClass, E(e.device);
|
|
200
|
+
}
|
|
201
|
+
function E(e) {
|
|
202
|
+
e.lost.then((e) => {
|
|
203
|
+
if (!d) {
|
|
204
|
+
if (v?.(), S(), o = null, e.reason === "destroyed") {
|
|
205
|
+
let t = /* @__PURE__ */ Error(`[useWebGPUCanvas] device destroyed${e.message ? ` (${e.message})` : ""}`);
|
|
206
|
+
h = t, r.onInitError?.(t);
|
|
207
|
+
return;
|
|
208
|
+
}
|
|
209
|
+
T().then(() => {
|
|
210
|
+
d || _?.();
|
|
211
|
+
}).catch((e) => {
|
|
212
|
+
h = e, r.onInitError?.(e);
|
|
213
|
+
});
|
|
214
|
+
}
|
|
215
|
+
});
|
|
216
|
+
}
|
|
217
|
+
async function D() {
|
|
218
|
+
if (!d) {
|
|
219
|
+
if (h) throw h;
|
|
220
|
+
if (p) return p;
|
|
221
|
+
if (o) {
|
|
222
|
+
w.arm();
|
|
223
|
+
return;
|
|
224
|
+
}
|
|
225
|
+
return w.presize(), p = (async () => {
|
|
226
|
+
try {
|
|
227
|
+
if (await T(), d) return;
|
|
228
|
+
if (w.arm(), y) {
|
|
229
|
+
let e = r.mode !== "capture";
|
|
230
|
+
e && w.suspend("manual");
|
|
231
|
+
let t = await y;
|
|
232
|
+
if (d) return;
|
|
233
|
+
if (t) throw new c("pipeline-validation", `[useWebGPUCanvas] pipeline failed validation (${t.message})`);
|
|
234
|
+
e && w.resume("manual");
|
|
235
|
+
}
|
|
236
|
+
} catch (e) {
|
|
237
|
+
throw h = e, S(), e instanceof c || r.onInitError?.(e), e;
|
|
238
|
+
} finally {
|
|
239
|
+
p = null;
|
|
240
|
+
}
|
|
241
|
+
})(), p;
|
|
242
|
+
}
|
|
243
|
+
}
|
|
244
|
+
return {
|
|
245
|
+
armAsync: D,
|
|
246
|
+
arm: () => {
|
|
247
|
+
o && w.arm();
|
|
248
|
+
},
|
|
249
|
+
presize: w.presize,
|
|
250
|
+
suspend: w.suspend,
|
|
251
|
+
resume: w.resume,
|
|
252
|
+
wake: w.wake,
|
|
253
|
+
renderAt: w.renderAt,
|
|
254
|
+
dispose: () => {
|
|
255
|
+
d = !0, w.dispose(), o = null;
|
|
256
|
+
},
|
|
257
|
+
get device() {
|
|
258
|
+
return o;
|
|
259
|
+
},
|
|
260
|
+
get adapterClass() {
|
|
261
|
+
return g;
|
|
262
|
+
},
|
|
263
|
+
get reducedMotion() {
|
|
264
|
+
return w.reducedMotion;
|
|
265
|
+
}
|
|
266
|
+
};
|
|
267
|
+
}
|
|
268
|
+
//#endregion
|
|
269
|
+
//#region src/composables/glass/webgpu/useGpuSubstrate.ts
|
|
270
|
+
function g(e, t) {
|
|
271
|
+
let r;
|
|
272
|
+
return r = s(e, {
|
|
273
|
+
mode: t.mode,
|
|
274
|
+
respectReducedMotion: t.respectReducedMotion,
|
|
275
|
+
contextAttrs: t.contextAttrs,
|
|
276
|
+
dprPolicy: t.dprPolicy,
|
|
277
|
+
composeIntersectionPark: t.composeIntersectionPark,
|
|
278
|
+
intersectionRootMargin: t.intersectionRootMargin,
|
|
279
|
+
revealBloom: t.revealBloom,
|
|
280
|
+
onContextStateChange: (e) => {
|
|
281
|
+
t.onStatus?.(e === "lost" ? n("webgl2") : {
|
|
282
|
+
phase: "ready",
|
|
283
|
+
engine: "webgl2",
|
|
284
|
+
adapter: a(r.gl)
|
|
285
|
+
});
|
|
286
|
+
},
|
|
287
|
+
setup: t.setupGL,
|
|
288
|
+
onContextError: (e) => {
|
|
289
|
+
t.onStatus?.(i("webgl2", "WebGL 2 context", e)), t.onInitError?.(e);
|
|
290
|
+
}
|
|
291
|
+
}), r;
|
|
292
|
+
}
|
|
293
|
+
function _(e, t) {
|
|
294
|
+
let r = f() && t.setupWGPU != null, o = null, s = null, l = r ? "webgpu" : "webgl2", u = !1, d = (e) => t.onStatus?.(e), p = (e, t, r) => d(e === "lost" ? n(t) : {
|
|
295
|
+
phase: "ready",
|
|
296
|
+
engine: t,
|
|
297
|
+
adapter: r()
|
|
298
|
+
});
|
|
299
|
+
d(n(l)), r ? o = h(e, {
|
|
300
|
+
mode: t.mode,
|
|
301
|
+
respectReducedMotion: t.respectReducedMotion,
|
|
302
|
+
dprPolicy: t.dprPolicy,
|
|
303
|
+
composeIntersectionPark: t.composeIntersectionPark,
|
|
304
|
+
intersectionRootMargin: t.intersectionRootMargin,
|
|
305
|
+
revealBloom: t.revealBloom,
|
|
306
|
+
setup: t.setupWGPU,
|
|
307
|
+
alphaMode: t.alphaMode,
|
|
308
|
+
adapterOptions: t.adapterOptions,
|
|
309
|
+
deviceDescriptor: t.deviceDescriptor,
|
|
310
|
+
onContextStateChange: (e) => {
|
|
311
|
+
p(e, "webgpu", () => o?.adapterClass ?? "Hardware adapter");
|
|
312
|
+
},
|
|
313
|
+
onInitError: (e) => {
|
|
314
|
+
d(i("webgpu", o?.adapterClass ?? "Hardware adapter", e)), t.onInitError?.(e);
|
|
315
|
+
}
|
|
316
|
+
}) : s = g(e, t);
|
|
317
|
+
function m(r) {
|
|
318
|
+
o?.dispose(), o = null, l = "webgl2", d(n("webgl2")), t.onBackendFallback?.({
|
|
319
|
+
from: "webgpu",
|
|
320
|
+
to: "webgl2",
|
|
321
|
+
error: r
|
|
322
|
+
});
|
|
323
|
+
try {
|
|
324
|
+
s = g(e, t), s.arm(), d({
|
|
325
|
+
phase: "ready",
|
|
326
|
+
engine: "webgl2",
|
|
327
|
+
adapter: a(s.gl)
|
|
328
|
+
});
|
|
329
|
+
} catch (e) {
|
|
330
|
+
throw s = null, d(i("webgl2", "WebGL 2 context", e)), t.onInitError?.(e), e;
|
|
331
|
+
}
|
|
332
|
+
}
|
|
333
|
+
async function _() {
|
|
334
|
+
if (!u) {
|
|
335
|
+
if (v(), o) try {
|
|
336
|
+
await o.armAsync(), d({
|
|
337
|
+
phase: "ready",
|
|
338
|
+
engine: "webgpu",
|
|
339
|
+
adapter: o.adapterClass
|
|
340
|
+
});
|
|
341
|
+
return;
|
|
342
|
+
} catch (e) {
|
|
343
|
+
if (u) return;
|
|
344
|
+
if (e instanceof c && e.kind !== "pipeline-validation") {
|
|
345
|
+
m(e);
|
|
346
|
+
return;
|
|
347
|
+
}
|
|
348
|
+
throw d(i("webgpu", o.adapterClass, e)), e;
|
|
349
|
+
}
|
|
350
|
+
try {
|
|
351
|
+
s?.arm(), d({
|
|
352
|
+
phase: "ready",
|
|
353
|
+
engine: "webgl2",
|
|
354
|
+
adapter: a(s?.gl ?? null)
|
|
355
|
+
});
|
|
356
|
+
} catch (e) {
|
|
357
|
+
throw d(i("webgl2", "WebGL 2 context", e)), t.onInitError?.(e), e;
|
|
358
|
+
}
|
|
359
|
+
}
|
|
360
|
+
}
|
|
361
|
+
function v() {
|
|
362
|
+
u || (o?.presize(), s?.presize());
|
|
363
|
+
}
|
|
364
|
+
function y() {
|
|
365
|
+
u || (v(), o?.arm(), s?.arm());
|
|
366
|
+
}
|
|
367
|
+
return {
|
|
368
|
+
get backend() {
|
|
369
|
+
return l;
|
|
370
|
+
},
|
|
371
|
+
armAsync: _,
|
|
372
|
+
arm: y,
|
|
373
|
+
presize: v,
|
|
374
|
+
suspend: (e) => {
|
|
375
|
+
o?.suspend(e), s?.suspend(e);
|
|
376
|
+
},
|
|
377
|
+
resume: (e) => {
|
|
378
|
+
o?.resume(e), s?.resume(e);
|
|
379
|
+
},
|
|
380
|
+
wake: () => {
|
|
381
|
+
o?.wake(), s?.wake();
|
|
382
|
+
},
|
|
383
|
+
renderAt: (e) => {
|
|
384
|
+
o?.renderAt(e), s?.renderAt(e);
|
|
385
|
+
},
|
|
386
|
+
dispose: () => {
|
|
387
|
+
u = !0, o?.dispose(), s?.dispose(), o = null, s = null;
|
|
388
|
+
},
|
|
389
|
+
get reducedMotion() {
|
|
390
|
+
return (o ?? s)?.reducedMotion ?? !1;
|
|
391
|
+
}
|
|
392
|
+
};
|
|
393
|
+
}
|
|
394
|
+
//#endregion
|
|
395
|
+
//#region src/composables/glass/procedural/color.wgsl.ts
|
|
396
|
+
var v = "\nfn srgbToLinearCh(c: f32) -> f32 {\n if (c <= 0.04045) { return c / 12.92; }\n return pow((c + 0.055) / 1.055, 2.4);\n}\nfn srgbToLinear(c: vec3<f32>) -> vec3<f32> {\n return vec3<f32>(srgbToLinearCh(c.r), srgbToLinearCh(c.g), srgbToLinearCh(c.b));\n}\n\nfn linearToSrgbCh(c: f32) -> f32 {\n if (c <= 0.0031308) { return c * 12.92; }\n return 1.055 * pow(c, 1.0 / 2.4) - 0.055;\n}\nfn linearToSrgb(c: vec3<f32>) -> vec3<f32> {\n return vec3<f32>(linearToSrgbCh(c.r), linearToSrgbCh(c.g), linearToSrgbCh(c.b));\n}", y = "const FBM_ROT: mat2x2<f32> = mat2x2<f32>(0.8, 0.6, -0.6, 0.8);", b = "\n// value.js LINEAR_SRGB_TO_LMS, row-major → WGSL columns (= the transpose).\nconst LINEAR_SRGB_TO_LMS: mat3x3<f32> = mat3x3<f32>(\n 0.4122214708, 0.2119034982, 0.0883024619,\n 0.5363325363, 0.6806995451, 0.2817188376,\n 0.0514459929, 0.1073969566, 0.6299787005\n);\n\n// value.js srgbToOKLab's INLINE LMS→OKLab coefficients, row-major → WGSL columns.\nconst LMS_TO_OKLAB: mat3x3<f32> = mat3x3<f32>(\n 0.2104542553, 1.9779984951, 0.0259040371,\n 0.7936177850, -2.4285922050, 0.7827717662,\n -0.0040720468, 0.4505937099, -0.8086757660\n);\n\n// value.js OKLAB_TO_LMS_COEFF, row-major → WGSL columns.\nconst OKLAB_TO_LMS: mat3x3<f32> = mat3x3<f32>(\n 1.0, 1.0, 1.0,\n 0.3963377774, -0.1055613458, -0.0894841775,\n 0.2158037573, -0.0638541728, -1.2914855480\n);\n\n// value.js LMS_TO_LINEAR_SRGB, row-major → WGSL columns.\nconst LMS_TO_LINEAR_SRGB: mat3x3<f32> = mat3x3<f32>(\n 4.0767416621, -1.2684380046, -0.0041960863,\n -3.3077115913, 2.6097574011, -0.7034186147,\n 0.2309699292, -0.3413193965, 1.7076147010\n);\n\nfn cbrt3(v: vec3<f32>) -> vec3<f32> {\n return sign(v) * pow(abs(v), vec3<f32>(1.0 / 3.0));\n}\n\n// Gamma sRGB → raw OKLab (L, a, b). Mirrors value.js srgbToOKLab.\nfn srgbToOklab(c: vec3<f32>) -> vec3<f32> {\n let lin = srgbToLinear(c);\n let lms = LINEAR_SRGB_TO_LMS * lin;\n return LMS_TO_OKLAB * cbrt3(lms);\n}\n\n// Raw OKLab (L, a, b) → linear sRGB. Mirrors value.js oklabToLinearSRGB.\nfn oklabToLinearSrgb(lab: vec3<f32>) -> vec3<f32> {\n let lms_ = OKLAB_TO_LMS * lab;\n let lms = lms_ * lms_ * lms_;\n return LMS_TO_LINEAR_SRGB * lms;\n}\n\n// OKLab → OKLCh: H in RADIANS, folded to [0, 2pi). Mirrors value.js rawOklabToOklch.\nfn oklabToOklch(lab: vec3<f32>) -> vec3<f32> {\n let C = length(lab.yz);\n var H = atan2(lab.z, lab.y);\n if (H < 0.0) { H = H + 2.0 * PI; }\n return vec3<f32>(lab.x, C, H);\n}\n\n// OKLCh (H radians) → OKLab. Mirrors value.js rawOklchToOklab.\nfn oklchToOklab(lch: vec3<f32>) -> vec3<f32> {\n return vec3<f32>(lch.x, lch.y * cos(lch.z), lch.y * sin(lch.z));\n}", x = "\n// value.js interpolateHue in the NORMALIZED-TURNS domain. methods: 0 shorter,\n// 1 longer, 2 increasing, 3 decreasing.\nfn interpolateHueTurns(h0: f32, h1: f32, t: f32, method: i32) -> f32 {\n let TAU = 2.0 * PI;\n var a = h0 / TAU;\n var b = h1 / TAU;\n let i = b - a;\n if (method == 0) { // shorter\n if (i > 0.5) { a = a + 1.0; } else if (i < -0.5) { b = b + 1.0; }\n } else if (method == 1) { // longer\n if (i > 0.0 && i < 0.5) { a = a + 1.0; } else if (i > -0.5 && i <= 0.0) { b = b + 1.0; }\n } else if (method == 2) { // increasing\n if (i < 0.0) { b = b + 1.0; }\n } else { // decreasing\n if (i > 0.0) { a = a + 1.0; }\n }\n var r = a + t * (b - a);\n r = fract(r); // fract is non-negative in WGSL\n return r * TAU; // back to radians\n}\n\n// Linear-sRGB endpoint pair → OKLab-rectangular interpolation → linear sRGB.\nfn mixPaletteOklab(linA: vec3<f32>, linB: vec3<f32>, t: f32) -> vec3<f32> {\n let labA = LMS_TO_OKLAB * cbrt3(LINEAR_SRGB_TO_LMS * linA);\n let labB = LMS_TO_OKLAB * cbrt3(LINEAR_SRGB_TO_LMS * linB);\n let lab = mix(labA, labB, t);\n return oklabToLinearSrgb(lab);\n}\n\n// Linear-sRGB endpoint pair → OKLCh hue-arc interpolation → linear sRGB.\nfn mixPaletteOklchArc(linA: vec3<f32>, linB: vec3<f32>, t: f32, method: i32) -> vec3<f32> {\n let labA = LMS_TO_OKLAB * cbrt3(LINEAR_SRGB_TO_LMS * linA);\n let labB = LMS_TO_OKLAB * cbrt3(LINEAR_SRGB_TO_LMS * linB);\n let lchA = oklabToOklch(labA);\n let lchB = oklabToOklch(labB);\n let L = mix(lchA.x, lchB.x, t);\n let C = mix(lchA.y, lchB.y, t);\n let H = interpolateHueTurns(lchA.z, lchB.z, t, method);\n return oklabToLinearSrgb(oklchToOklab(vec3<f32>(L, C, H)));\n}\n\n// The ramp dispatcher (the samplePalette splices it). tRaw is the raw inter-stop\n// parameter [0,1]; the smoothstep ease + the huePath branch live here so the ramp is\n// one source. increasing(2)/decreasing(3) take the OKLCh hue-arc; every other method\n// takes the OKLab-rectangular straight line.\nfn samplePaletteRamp(a: vec3<f32>, b: vec3<f32>, tRaw: f32, huePath: i32) -> vec3<f32> {\n let t = smoothstep(0.0, 1.0, tRaw);\n if (huePath == 2 || huePath == 3) {\n return mixPaletteOklchArc(a, b, t, huePath);\n }\n return mixPaletteOklab(a, b, t);\n}";
|
|
397
|
+
//#endregion
|
|
398
|
+
export { _ as a, x as i, v as n, o, b as r, y as t };
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import { t as e } from "./class-names-
|
|
1
|
+
import { t as e } from "./class-names-FlXcvRRT.js";
|
|
2
2
|
import { t } from "./primitive-B2t2jdqM.js";
|
|
3
3
|
import { t as n } from "./selection-DqIULxRG.js";
|
|
4
|
-
import { n as r, t as i } from "./DialogContent-
|
|
5
|
-
import { t as a } from "./
|
|
6
|
-
import { t as o } from "./
|
|
4
|
+
import { n as r, t as i } from "./DialogContent-CwIBvou_.js";
|
|
5
|
+
import { t as a } from "./participation-Di4UHbzk.js";
|
|
6
|
+
import { t as o } from "./rowClass-DYOXwxhO.js";
|
|
7
7
|
import { computed as s, createBlock as c, createCommentVNode as l, createElementBlock as u, createTextVNode as d, createVNode as f, defineComponent as p, mergeProps as m, normalizeClass as h, openBlock as g, renderSlot as _, toDisplayString as v, unref as y, useAttrs as b, withCtx as x } from "vue";
|
|
8
8
|
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 } from "reka-ui";
|
|
9
9
|
import { Search as A } from "@lucide/vue";
|
|
@@ -231,20 +231,20 @@ var j = /* @__PURE__ */ p({
|
|
|
231
231
|
},
|
|
232
232
|
emits: ["select"],
|
|
233
233
|
setup(n, { emit: r }) {
|
|
234
|
-
let i = n,
|
|
234
|
+
let i = n, a = r, l = b(), u = s(() => t(l));
|
|
235
235
|
function d(e) {
|
|
236
236
|
if (i.disabled) {
|
|
237
237
|
e.preventDefault();
|
|
238
238
|
return;
|
|
239
239
|
}
|
|
240
|
-
|
|
240
|
+
a("select", e);
|
|
241
241
|
}
|
|
242
242
|
return (t, n) => (g(), c(y(E), m(u.value, {
|
|
243
243
|
"data-slot": "command-item",
|
|
244
244
|
value: i.value,
|
|
245
245
|
disabled: i.disabled,
|
|
246
246
|
"text-value": i.textValue,
|
|
247
|
-
class: y(e)("command__item", y(
|
|
247
|
+
class: y(e)("command__item", y(o)(), i.class),
|
|
248
248
|
onSelect: d
|
|
249
249
|
}), {
|
|
250
250
|
default: x(() => [_(t.$slots, "default")]),
|
|
@@ -277,7 +277,7 @@ var j = /* @__PURE__ */ p({
|
|
|
277
277
|
"interactOutside"
|
|
278
278
|
],
|
|
279
279
|
setup(t, { emit: n }) {
|
|
280
|
-
let r = t, i = n,
|
|
280
|
+
let r = t, i = n, o = b(), l = s(() => ({ ...o })), u = a();
|
|
281
281
|
return (t, n) => (g(), c(y(S), m({
|
|
282
282
|
...l.value,
|
|
283
283
|
...y(u).portalAttrs.value
|
package/dist/command.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
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 "./command-
|
|
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 "./command-C-5xSEJ2.js";
|
|
2
2
|
export { r as Command, t as CommandDialog, s as CommandEmpty, a as CommandGroup, e as CommandInput, n as CommandItem, o as CommandList, i as CommandSeparator, c as CommandShortcut };
|
|
@@ -21,7 +21,16 @@ export type ClassValue = string | number | false | null | undefined | ClassValue
|
|
|
21
21
|
*
|
|
22
22
|
* Tokens that don't match a known bucket pass through untouched (custom
|
|
23
23
|
* classes, arbitrary-value utilities like `[&::after]:hidden`, anything
|
|
24
|
-
* not in the conflict table)
|
|
24
|
+
* not in the conflict table), and between two of them the winner is
|
|
25
|
+
* stylesheet emission order, not argument order.
|
|
26
|
+
* [2026-09-22 · O-32 §4.2 / O-23 L-2: the families that fall through at
|
|
27
|
+
* 10.0.0, named so an override can be priced — the theme font registers
|
|
28
|
+
* `font-text` / `font-display` / `font-serif-math` (the family bucket is
|
|
29
|
+
* `font-sans|serif|mono` only), `tracking-*`, `leading-*`, and the semantic
|
|
30
|
+
* `border-*` / `ring-*` colours (`border-border`, `ring-ring`; those buckets
|
|
31
|
+
* match palette-number names only). Every `text-*` and `shadow-*` name
|
|
32
|
+
* `.published-roster` carries IS bucketed, by its true property — a unit in
|
|
33
|
+
* `tests/components/_shared/classNames.test.ts` reads the roster to hold it.]
|
|
25
34
|
*/
|
|
26
35
|
export declare function cn(...inputs: ClassValue[]): string;
|
|
27
36
|
/** Normalize Vue-compatible class values without shipping a runtime class helper. */
|
|
@@ -1 +1 @@
|
|
|
1
|
-
@layer components{.glass-menu-row{--menu-row-bg: var(--glass-plate-quiet);--menu-row-lift: -1px;min-block-size: max(2rem,var(--touch-target,2.75rem));transition: background-color var(--engage-control-engage-release) var(--ease-standard),color var(--engage-control-engage-release) var(--ease-standard),border-color var(--engage-control-engage-release) var(--ease-standard),box-shadow var(--engage-control-engage-release) var(--ease-standard),translate var(--spring-dock-duration) var(--spring-dock),scale var(--spring-press-duration) var(--transition-liquid-spatial);translate: 0 0;}.glass-menu-row:focus:not([data-disabled]),.glass-menu-row[data-highlighted]:not([data-disabled]),.glass-menu-row[data-state="open"]:not([data-disabled]){background: var(--menu-row-bg);color: var(--accent-foreground);transition: background-color var(--engage-control-engage-attack) var(--ease-standard),color var(--engage-control-engage-attack) var(--ease-standard),border-color var(--engage-control-engage-attack) var(--ease-standard),box-shadow var(--engage-control-engage-attack) var(--ease-standard),translate var(--spring-dock-duration) var(--spring-dock),scale var(--spring-press-duration) var(--transition-liquid-spatial);}@media (hover: hover){.glass-menu-row:hover:not([data-disabled]){background: var(--menu-row-bg);color: var(--accent-foreground);translate: 0 var(--menu-row-lift);transition: background-color var(--engage-control-engage-attack) var(--ease-standard),color var(--engage-control-engage-attack) var(--ease-standard),border-color var(--engage-control-engage-attack) var(--ease-standard),box-shadow var(--engage-control-engage-attack) var(--ease-standard),translate var(--spring-dock-duration) var(--spring-dock),scale var(--spring-press-duration) var(--transition-liquid-spatial);}}
|
|
1
|
+
@layer components{.glass-menu-row{--menu-row-bg: var(--glass-plate-quiet);--menu-row-lift: -1px;min-block-size: max(2rem,var(--touch-target,2.75rem));transition: background-color var(--engage-control-engage-release) var(--ease-standard),color var(--engage-control-engage-release) var(--ease-standard),border-color var(--engage-control-engage-release) var(--ease-standard),box-shadow var(--engage-control-engage-release) var(--ease-standard),translate var(--spring-dock-duration) var(--spring-dock),scale var(--spring-press-duration) var(--transition-liquid-spatial);translate: 0 0;}.glass-menu-row:focus:not([data-disabled]),.glass-menu-row[data-highlighted]:not([data-disabled]),.glass-menu-row[data-state="open"]:not([data-disabled]){background: var(--menu-row-bg);color: var(--accent-foreground);transition: background-color var(--engage-control-engage-attack) var(--ease-standard),color var(--engage-control-engage-attack) var(--ease-standard),border-color var(--engage-control-engage-attack) var(--ease-standard),box-shadow var(--engage-control-engage-attack) var(--ease-standard),translate var(--spring-dock-duration) var(--spring-dock),scale var(--spring-press-duration) var(--transition-liquid-spatial);}@media (hover: hover){.glass-menu-row:hover:not([data-disabled]){background: var(--menu-row-bg);color: var(--accent-foreground);translate: 0 var(--menu-row-lift);transition: background-color var(--engage-control-engage-attack) var(--ease-standard),color var(--engage-control-engage-attack) var(--ease-standard),border-color var(--engage-control-engage-attack) var(--ease-standard),box-shadow var(--engage-control-engage-attack) var(--ease-standard),translate var(--spring-dock-duration) var(--spring-dock),scale var(--spring-press-duration) var(--transition-liquid-spatial);}}@media (prefers-reduced-motion: reduce){.glass-menu-row{--menu-row-lift: 0px;transition: background-color var(--engage-control-engage-release) var(--ease-standard),color var(--engage-control-engage-release) var(--ease-standard),border-color var(--engage-control-engage-release) var(--ease-standard),box-shadow var(--engage-control-engage-release) var(--ease-standard);}}}@layer components{.glass-menu-divider{block-size: 1px;background: color-mix( in oklab,var(--foreground) calc(var(--ink-seam) * 100%),transparent );}}
|
|
@@ -10,3 +10,4 @@ export { overlayContentAttrs, type OverlayAttrs, type OverlayRole } from "./cont
|
|
|
10
10
|
export { isTeleportedTarget } from "./isTeleportedTarget.js";
|
|
11
11
|
export { useDockParticipation, useHoldToken, type DockParticipation, type DockPortalAttrs, type HoldTarget, type HoldToken, } from "./participation.js";
|
|
12
12
|
export type { FloatingAlign, FloatingPlacementProps, FloatingSide, } from "./placement.js";
|
|
13
|
+
export { useModalShortcutBarrier } from "./shortcuts.js";
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Hold a shortcut barrier for as long as `active` reads true.
|
|
3
|
+
*
|
|
4
|
+
* ORDERING is the whole contract and it is why this runs `immediate` in SETUP:
|
|
5
|
+
* the barrier admits registrations made AFTER it, so it has to be raised before
|
|
6
|
+
* the overlay's own content mounts and registers anything. A `pre`-flush watch
|
|
7
|
+
* fires ahead of the render that mounts that content, and the immediate arm covers
|
|
8
|
+
* an overlay that is open on its first frame.
|
|
9
|
+
*
|
|
10
|
+
* The release is idempotent, so the scope-dispose arm is safe beside a close.
|
|
11
|
+
*/
|
|
12
|
+
export declare function useModalShortcutBarrier(active: () => boolean): void;
|
|
@@ -91,6 +91,7 @@ declare const __VLS_export: import("vue").DefineComponent<__VLS_Props, {
|
|
|
91
91
|
pause: () => void;
|
|
92
92
|
resume: () => void;
|
|
93
93
|
isArmed: Readonly<import("vue").Ref<boolean, boolean>>;
|
|
94
|
+
isSettled: Readonly<import("vue").Ref<boolean, boolean>>;
|
|
94
95
|
rendererStatus: Readonly<import("vue").Ref<RendererStatus, RendererStatus>>;
|
|
95
96
|
}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
|
|
96
97
|
rendererStatus: (status: RendererStatus) => any;
|
|
@@ -74,14 +74,16 @@ export interface AuroraFieldInteractivityAtom {
|
|
|
74
74
|
*/
|
|
75
75
|
amplitude?: number;
|
|
76
76
|
}
|
|
77
|
-
/**
|
|
77
|
+
/** No impasto to relight (smooth, and every medium but oil/vangogh): no `light`. */
|
|
78
78
|
export interface AuroraSmoothInteractivityAtom extends AuroraFieldInteractivityAtom {
|
|
79
79
|
light?: never;
|
|
80
80
|
}
|
|
81
|
-
/**
|
|
81
|
+
/** The impasto media (oil, vangogh) may also steer their light from the cursor. */
|
|
82
82
|
export interface AuroraPainterlyInteractivityAtom extends AuroraFieldInteractivityAtom {
|
|
83
83
|
light?: boolean;
|
|
84
84
|
}
|
|
85
|
+
/** Media whose texture amount writes `impasto` — the only ones `light` relights. */
|
|
86
|
+
type AuroraImpastoMedium = "oil" | "vangogh";
|
|
85
87
|
export type AuroraInteractivityAtom = AuroraSmoothInteractivityAtom | AuroraPainterlyInteractivityAtom;
|
|
86
88
|
/**
|
|
87
89
|
* The Tier-1 atoms of control (≤7) — the user's named control elements. EVERY atom is
|
|
@@ -89,7 +91,14 @@ export type AuroraInteractivityAtom = AuroraSmoothInteractivityAtom | AuroraPain
|
|
|
89
91
|
* so `DEFAULT_ATOMS` (the empty set) resolves to `DEFAULT_AURORA_CONFIG`.
|
|
90
92
|
*/
|
|
91
93
|
interface AuroraAtomsBase {
|
|
92
|
-
/**
|
|
94
|
+
/**
|
|
95
|
+
* A seed color (CSS string or an OklchStop anchor) → drives the derived palette.
|
|
96
|
+
*
|
|
97
|
+
* A string is parsed by `cssToOklch`, which THROWS `GlassColorError` on a contextual
|
|
98
|
+
* value (`var(--x)`, `currentColor`) or a non-opaque one — it resolves nothing from
|
|
99
|
+
* the DOM and invents no stock palette. Resolve the token yourself and pass either
|
|
100
|
+
* the resolved string or the `OklchStop` form.
|
|
101
|
+
*/
|
|
93
102
|
seed?: string | OklchStop;
|
|
94
103
|
/** The hue scheme across the derived ramp. Default `analogous` (when a seed is set). */
|
|
95
104
|
harmony?: AuroraHarmony;
|
|
@@ -154,8 +163,9 @@ interface AuroraAtomsBase {
|
|
|
154
163
|
motion?: AuroraMotionAtom;
|
|
155
164
|
}
|
|
156
165
|
/**
|
|
157
|
-
* The medium-discriminated atoms surface.
|
|
158
|
-
*
|
|
166
|
+
* The medium-discriminated atoms surface. Every medium retains swirl/scroll/amplitude;
|
|
167
|
+
* the directional `light` axis is admitted only where the medium writes impasto for it
|
|
168
|
+
* to relight (oil, vangogh) and is `never` on every other arm.
|
|
159
169
|
*/
|
|
160
170
|
export type AuroraAtoms = AuroraAtomsBase & ({
|
|
161
171
|
medium?: {
|
|
@@ -164,7 +174,13 @@ export type AuroraAtoms = AuroraAtomsBase & ({
|
|
|
164
174
|
interactivity?: AuroraSmoothInteractivityAtom;
|
|
165
175
|
} | {
|
|
166
176
|
medium: {
|
|
167
|
-
kind: Exclude<AuroraMedium, "smooth">;
|
|
177
|
+
kind: Exclude<AuroraMedium, "smooth" | AuroraImpastoMedium>;
|
|
178
|
+
amount?: number;
|
|
179
|
+
};
|
|
180
|
+
interactivity?: AuroraSmoothInteractivityAtom;
|
|
181
|
+
} | {
|
|
182
|
+
medium: {
|
|
183
|
+
kind: AuroraImpastoMedium;
|
|
168
184
|
amount?: number;
|
|
169
185
|
};
|
|
170
186
|
interactivity?: AuroraPainterlyInteractivityAtom;
|
|
@@ -11,14 +11,15 @@
|
|
|
11
11
|
*
|
|
12
12
|
* `drawFrame` re-sends the per-frame cursor + time uniforms and issues the single
|
|
13
13
|
* full-screen-triangle draw. `needsAnimation` is the demand gate: `false` under
|
|
14
|
-
* reduced-motion (the static frame draws once, then parks), `false` at steady-state (
|
|
15
|
-
*
|
|
16
|
-
* `true` while drift is live or the field is still easing
|
|
17
|
-
* attractor motion above ε).
|
|
14
|
+
* reduced-motion (the static frame draws once, then parks), `false` at steady-state (no
|
|
15
|
+
* drift axis above its own amplitude floor AND the field settled — the next frame is
|
|
16
|
+
* pixel-identical), and `true` while drift is live or the field is still easing
|
|
17
|
+
* (engagement, speed, burst, attractor motion above ε). The drift half is
|
|
18
|
+
* `isAuroraDriftLive` — the ONE predicate this loop and both WGSL loops share.
|
|
18
19
|
*/
|
|
19
20
|
import type { UniformLocations } from "./glSetup.js";
|
|
20
21
|
import type { AuroraCursorUniforms } from "./uniformBridge.js";
|
|
21
|
-
import type
|
|
22
|
+
import { type AuroraConfig } from "../constants/presets.js";
|
|
22
23
|
import type { UsePointerVelocityField } from "../../../composables/motion/pointer/usePointerVelocityField.js";
|
|
23
24
|
/** The at-rest scalars a config-less cursor read seeds (strength ceiling + influence radius). */
|
|
24
25
|
export interface AuroraCursorScalars {
|
|
@@ -75,6 +75,20 @@ export interface AuroraRuntimeOptions {
|
|
|
75
75
|
* threaded through both seams.
|
|
76
76
|
*/
|
|
77
77
|
forceWebGLUnderSoftwareRaster?: boolean;
|
|
78
|
+
/**
|
|
79
|
+
* Pin the render backend instead of letting the substrate picker choose.
|
|
80
|
+
*
|
|
81
|
+
* `"webgl2"` withholds the WGSL setup from `createGpuSubstrate`, which is the ONLY
|
|
82
|
+
* honest way to reach the WebGL2 arm in-app: the picker's `attemptWebGPU` reads
|
|
83
|
+
* `supportsWebGPU() && setupWGPU != null`, so a browser flag cannot express this and
|
|
84
|
+
* `renderMode: "webgl"` is a MODE (animate at all / never), not a backend.
|
|
85
|
+
*
|
|
86
|
+
* The capture harness drives it as `?engine=webgl2` so the GL arm can be archived
|
|
87
|
+
* before it is deleted. There is no `"webgpu"` member: forcing WebGPU on a host
|
|
88
|
+
* without an adapter would be a masking fallback — the picker already prefers it and
|
|
89
|
+
* falls loud when it cannot arm.
|
|
90
|
+
*/
|
|
91
|
+
forceBackend?: "webgl2";
|
|
78
92
|
/**
|
|
79
93
|
* Reveal-bloom consumer door.
|
|
80
94
|
*
|
|
@@ -131,7 +145,20 @@ export interface AuroraRuntime extends Omit<AuroraInstance, "pause" | "resume">
|
|
|
131
145
|
/** Live reduced-motion state; the cursor listener early-outs on it. */
|
|
132
146
|
readonly reducedMotion: boolean;
|
|
133
147
|
}
|
|
134
|
-
/**
|
|
148
|
+
/**
|
|
149
|
+
* One impasto-keyed predicate shared by pointer writes and uniform projection.
|
|
150
|
+
*
|
|
151
|
+
* `swirl` is the DEFAULT-ON axis: every aurora shapes under the pointer unless its
|
|
152
|
+
* config says `swirl: false`. Suppression is not this predicate's job — the master
|
|
153
|
+
* tempo scalar zeroes the field tick under reduced motion and under the background
|
|
154
|
+
* pause, so a PRM reader never sees the cursor regardless of what this returns.
|
|
155
|
+
*
|
|
156
|
+
* `light` stays an explicit opt-in AND is keyed on the impasto AMOUNT, not the medium
|
|
157
|
+
* name: it steers `uLightDir`, which only `relightImpasto` reads, and every term there is
|
|
158
|
+
* multiplied by `uImpasto`. `impasto` defaults to 0, so `light` alone paints nothing on
|
|
159
|
+
* crayon or pastel exactly as it paints nothing on smooth, and must not arm a pointer
|
|
160
|
+
* path that provably cannot change a pixel.
|
|
161
|
+
*/
|
|
135
162
|
export declare function isAuroraPointerEnabled(config: AuroraConfig): boolean;
|
|
136
163
|
/** One shader-time projection shared by the WebGPU and WebGL2 bridges. */
|
|
137
164
|
export declare function resolveAuroraRenderTime(config: AuroraConfig, elapsedSec: number, progress: number, reducedMotion: boolean): number;
|