@orangecheck/design 0.26.0 → 0.28.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/index.d.mts CHANGED
@@ -1,4 +1,4 @@
1
- export { AppearanceControls, DEFAULT_OC_THEME, OC_DEFAULT_ACCENT, OC_MOTION_COOKIE, OC_SKIN_COOKIE, OC_THEMES, OcAppearanceMenu, OcAppearanceMenuProps, OcAurora, OcAuroraProps, OcMotion, OcTheme, OcThemeBridge, OcThemeId, OcThemePicker, OcThemePickerProps, OcThemeProvider, OcThemeProviderProps, accentFor, cn, getOcThemeInitScript, isKnownTheme, resolveTheme, useOcMotion, useOcSkin } from './tokens.mjs';
1
+ export { AppearanceControls, DEFAULT_OC_THEME, OC_DEFAULT_ACCENT, OC_GLYPHS, OC_GLYPH_CANVAS, OC_MOTION_COOKIE, OC_SKIN_COOKIE, OC_THEMES, OcAppearanceMenu, OcAppearanceMenuProps, OcAurora, OcAuroraProps, OcGlyphSlug, OcMotion, OcSceneRGB, OcSceneTokens, OcSigil, OcSigilProps, OcTheme, OcThemeBridge, OcThemeId, OcThemePicker, OcThemePickerProps, OcThemeProvider, OcThemeProviderProps, accentFor, cn, getOcThemeInitScript, isKnownTheme, normalizeHue, readOcSceneTokens, resolveTheme, subscribeOcTheme, useOcMotion, useOcSkin } from './tokens.mjs';
2
2
  export { Accordion, AccordionContent, AccordionItem, AccordionTrigger, Alert, AlertDescription, AlertTitle, AlertWithAction, AlertWithActionProps, AlertWithCountdown, AlertWithCountdownProps, Badge, Bar, BarProps, BitcoinAddress, BitcoinAddressProps, Button, Card, CardProps, Checkbox, ConfirmHost, ConfirmOptions, CopyButton, CopyButtonProps, Dialog, DialogClose, DialogContent, DialogDescription, DialogFooter, DialogHeader, DialogOverlay, DialogPortal, DialogTitle, DialogTrigger, ErrorBoundary, IconBadge, IconBadgeProps, Input, Label, Modal, ModalProps, Pagination, PaginationProps, Popover, PopoverAnchor, PopoverContent, PopoverTrigger, PromptHost, PromptOptions, QrCode, QrCodeProps, RadioGroup, RadioGroupItem, SatsAmount, SatsAmountProps, Select, SelectContent, SelectGroup, SelectItem, SelectLabel, SelectScrollDownButton, SelectScrollUpButton, SelectSeparator, SelectTrigger, SelectValue, Separator, Sheet, SheetClose, SheetContent, SheetDescription, SheetFooter, SheetHeader, SheetOverlay, SheetPortal, SheetTitle, SheetTrigger, Skeleton, SkeletonProps, Sparkline, SparklineProps, StatBlock, StatBlockProps, StatusPill, StatusPillProps, StatusPillSpec, StatusPillVariant, StatusTone, Surface, SurfaceProps, Switch, Tabs, TabsContent, TabsList, TabsTrigger, Textarea, ThemeToggle, ThemeToggleLink, Toaster, Tooltip, TooltipProps, Working, WorkingPanel, WorkingProps, badgeVariants, buttonVariants, confirm, iconBadgeVariants, makeStatusPill, prompt, surfaceVariants } from './primitives.mjs';
3
3
  export { AccentList, AccentListItem, AccentListProps, AccentNote, AccentNoteProps, BrandBand, Callout, CalloutProps, CalloutTone, CheckList, CheckListProps, ComparisonRow, ComparisonTable, ComparisonTableProps, DataRow, DataRowProps, DefinitionItem, DefinitionList, DefinitionListProps, EmailCapture, EmailCaptureProps, EmptyState, EmptyStateCta, EmptyStateProps, Faq, FaqItem, FaqProps, FeatureCard, FeatureCardProps, HelpHint, HelpHintProps, MarketingHeading, MarketingHeadingProps, NumberedStep, NumberedStepProps, Panel, PanelProps, Section, SectionHeader, SectionHeaderProps, SectionProps, StatCard, StatCardProps, StatGrid, StatGridProps, StatItem, StatTile, Step, StepList, StepListProps, TwoToneHeading, TwoToneHeadingProps, VerifiedChip, VerifiedChipProps } from './composites.mjs';
4
4
  export { AppShell, AppShellProps, EcosystemSlug, EcosystemSwitcher, EcosystemSwitcherProps, FAMILY_PROPERTIES, FamilyCategory, FamilyProperty, FooterColumn, FooterLink, LayoutSubHeader, LayoutSubHeaderProps, LayoutSubHeaderTag, OcAccountMenu, OcAccountMenuBuildInfo, OcAccountMenuItem, OcAccountMenuProps, OcAccountMenuSession, OcAccountMenuView, OcAccountMenuViewProps, OcAppBar, OcAppBarProps, OcDashboardHub, OcDashboardHubProps, OcDashboardShell, OcDashboardShellProps, OcDashboardTool, OcFamilyFooter, OcFamilyFooterBrand, OcFamilyFooterProps, OcLogoDropdown, OcLogoDropdownProps, OcPrimaryNav, OcPrimaryNavLink, OcPrimaryNavProps, SITE_STATE_LABEL, SiteState, findFamilyProperty } from './chrome.mjs';
package/dist/index.d.ts CHANGED
@@ -1,4 +1,4 @@
1
- export { AppearanceControls, DEFAULT_OC_THEME, OC_DEFAULT_ACCENT, OC_MOTION_COOKIE, OC_SKIN_COOKIE, OC_THEMES, OcAppearanceMenu, OcAppearanceMenuProps, OcAurora, OcAuroraProps, OcMotion, OcTheme, OcThemeBridge, OcThemeId, OcThemePicker, OcThemePickerProps, OcThemeProvider, OcThemeProviderProps, accentFor, cn, getOcThemeInitScript, isKnownTheme, resolveTheme, useOcMotion, useOcSkin } from './tokens.js';
1
+ export { AppearanceControls, DEFAULT_OC_THEME, OC_DEFAULT_ACCENT, OC_GLYPHS, OC_GLYPH_CANVAS, OC_MOTION_COOKIE, OC_SKIN_COOKIE, OC_THEMES, OcAppearanceMenu, OcAppearanceMenuProps, OcAurora, OcAuroraProps, OcGlyphSlug, OcMotion, OcSceneRGB, OcSceneTokens, OcSigil, OcSigilProps, OcTheme, OcThemeBridge, OcThemeId, OcThemePicker, OcThemePickerProps, OcThemeProvider, OcThemeProviderProps, accentFor, cn, getOcThemeInitScript, isKnownTheme, normalizeHue, readOcSceneTokens, resolveTheme, subscribeOcTheme, useOcMotion, useOcSkin } from './tokens.js';
2
2
  export { Accordion, AccordionContent, AccordionItem, AccordionTrigger, Alert, AlertDescription, AlertTitle, AlertWithAction, AlertWithActionProps, AlertWithCountdown, AlertWithCountdownProps, Badge, Bar, BarProps, BitcoinAddress, BitcoinAddressProps, Button, Card, CardProps, Checkbox, ConfirmHost, ConfirmOptions, CopyButton, CopyButtonProps, Dialog, DialogClose, DialogContent, DialogDescription, DialogFooter, DialogHeader, DialogOverlay, DialogPortal, DialogTitle, DialogTrigger, ErrorBoundary, IconBadge, IconBadgeProps, Input, Label, Modal, ModalProps, Pagination, PaginationProps, Popover, PopoverAnchor, PopoverContent, PopoverTrigger, PromptHost, PromptOptions, QrCode, QrCodeProps, RadioGroup, RadioGroupItem, SatsAmount, SatsAmountProps, Select, SelectContent, SelectGroup, SelectItem, SelectLabel, SelectScrollDownButton, SelectScrollUpButton, SelectSeparator, SelectTrigger, SelectValue, Separator, Sheet, SheetClose, SheetContent, SheetDescription, SheetFooter, SheetHeader, SheetOverlay, SheetPortal, SheetTitle, SheetTrigger, Skeleton, SkeletonProps, Sparkline, SparklineProps, StatBlock, StatBlockProps, StatusPill, StatusPillProps, StatusPillSpec, StatusPillVariant, StatusTone, Surface, SurfaceProps, Switch, Tabs, TabsContent, TabsList, TabsTrigger, Textarea, ThemeToggle, ThemeToggleLink, Toaster, Tooltip, TooltipProps, Working, WorkingPanel, WorkingProps, badgeVariants, buttonVariants, confirm, iconBadgeVariants, makeStatusPill, prompt, surfaceVariants } from './primitives.js';
3
3
  export { AccentList, AccentListItem, AccentListProps, AccentNote, AccentNoteProps, BrandBand, Callout, CalloutProps, CalloutTone, CheckList, CheckListProps, ComparisonRow, ComparisonTable, ComparisonTableProps, DataRow, DataRowProps, DefinitionItem, DefinitionList, DefinitionListProps, EmailCapture, EmailCaptureProps, EmptyState, EmptyStateCta, EmptyStateProps, Faq, FaqItem, FaqProps, FeatureCard, FeatureCardProps, HelpHint, HelpHintProps, MarketingHeading, MarketingHeadingProps, NumberedStep, NumberedStepProps, Panel, PanelProps, Section, SectionHeader, SectionHeaderProps, SectionProps, StatCard, StatCardProps, StatGrid, StatGridProps, StatItem, StatTile, Step, StepList, StepListProps, TwoToneHeading, TwoToneHeadingProps, VerifiedChip, VerifiedChipProps } from './composites.js';
4
4
  export { AppShell, AppShellProps, EcosystemSlug, EcosystemSwitcher, EcosystemSwitcherProps, FAMILY_PROPERTIES, FamilyCategory, FamilyProperty, FooterColumn, FooterLink, LayoutSubHeader, LayoutSubHeaderProps, LayoutSubHeaderTag, OcAccountMenu, OcAccountMenuBuildInfo, OcAccountMenuItem, OcAccountMenuProps, OcAccountMenuSession, OcAccountMenuView, OcAccountMenuViewProps, OcAppBar, OcAppBarProps, OcDashboardHub, OcDashboardHubProps, OcDashboardShell, OcDashboardShellProps, OcDashboardTool, OcFamilyFooter, OcFamilyFooterBrand, OcFamilyFooterProps, OcLogoDropdown, OcLogoDropdownProps, OcPrimaryNav, OcPrimaryNavLink, OcPrimaryNavProps, SITE_STATE_LABEL, SiteState, findFamilyProperty } from './chrome.js';
package/dist/index.js CHANGED
@@ -58,7 +58,381 @@ var TabsPrimitive__namespace = /*#__PURE__*/_interopNamespace(TabsPrimitive);
58
58
  var QRCode__default = /*#__PURE__*/_interopDefault(QRCode);
59
59
  var Link6__default = /*#__PURE__*/_interopDefault(Link6);
60
60
 
61
- // src/tokens/cn.ts
61
+ var __defProp = Object.defineProperty;
62
+ var __getOwnPropNames = Object.getOwnPropertyNames;
63
+ var __esm = (fn, res) => function __init() {
64
+ return fn && (res = (0, fn[__getOwnPropNames(fn)[0]])(fn = 0)), res;
65
+ };
66
+ var __export = (target, all) => {
67
+ for (var name in all)
68
+ __defProp(target, name, { get: all[name], enumerable: true });
69
+ };
70
+
71
+ // src/tokens/scene-tokens.ts
72
+ function parseColor(value) {
73
+ let m = value.match(/color\(srgb\s+([\d.]+)\s+([\d.]+)\s+([\d.]+)/);
74
+ if (m?.[1] != null && m[2] != null && m[3] != null) {
75
+ return { r: +m[1], g: +m[2], b: +m[3] };
76
+ }
77
+ m = value.match(/rgba?\(\s*([\d.]+)[,\s]+([\d.]+)[,\s]+([\d.]+)/);
78
+ if (m?.[1] != null && m[2] != null && m[3] != null) {
79
+ return { r: +m[1] / 255, g: +m[2] / 255, b: +m[3] / 255 };
80
+ }
81
+ return null;
82
+ }
83
+ function srgbToOklab({ r, g, b }) {
84
+ const lin = (c) => c <= 0.04045 ? c / 12.92 : Math.pow((c + 0.055) / 1.055, 2.4);
85
+ const lr = lin(r);
86
+ const lg = lin(g);
87
+ const lb = lin(b);
88
+ const l = Math.cbrt(0.4122214708 * lr + 0.5363325363 * lg + 0.0514459929 * lb);
89
+ const m = Math.cbrt(0.2119034982 * lr + 0.6806995451 * lg + 0.1073969566 * lb);
90
+ const s = Math.cbrt(0.0883024619 * lr + 0.2817188376 * lg + 0.6299787005 * lb);
91
+ return {
92
+ L: 0.2104542553 * l + 0.793617785 * m - 0.0040720468 * s,
93
+ a: 1.9779984951 * l - 2.428592205 * m + 0.4505937099 * s,
94
+ b: 0.0259040371 * l + 0.7827717662 * m - 0.808675766 * s
95
+ };
96
+ }
97
+ function oklabToSrgb(L, a, bb) {
98
+ const l = Math.pow(L + 0.3963377774 * a + 0.2158037573 * bb, 3);
99
+ const m = Math.pow(L - 0.1055613458 * a - 0.0638541728 * bb, 3);
100
+ const s = Math.pow(L - 0.0894841775 * a - 1.291485548 * bb, 3);
101
+ const lr = 4.0767416621 * l - 3.3077115913 * m + 0.2309699292 * s;
102
+ const lg = -1.2684380046 * l + 2.6097574011 * m - 0.3413193965 * s;
103
+ const lb = -0.0041960863 * l - 0.7034186147 * m + 1.707614701 * s;
104
+ const un = (c) => Math.min(1, Math.max(0, c <= 31308e-7 ? 12.92 * c : 1.055 * Math.pow(c, 1 / 2.4) - 0.055));
105
+ return { r: un(lr), g: un(lg), b: un(lb) };
106
+ }
107
+ function normalizeHue(c, isDark) {
108
+ const { L, a, b } = srgbToOklab(c);
109
+ const C = Math.hypot(a, b);
110
+ const targetL = isDark ? Math.min(0.75, Math.max(0.55, L)) : Math.min(0.95, Math.max(0.82, L + 0.25));
111
+ const scale = C > 1e-6 ? Math.min(C, 0.14) / C : 0;
112
+ return oklabToSrgb(targetL, a * scale, b * scale);
113
+ }
114
+ function readOcSceneTokens(host) {
115
+ if (typeof document === "undefined") return null;
116
+ const probe = document.createElement("div");
117
+ probe.setAttribute("aria-hidden", "true");
118
+ probe.style.cssText = "position:absolute;width:0;height:0;overflow:hidden;pointer-events:none;";
119
+ const cells = SLOTS.map((slot) => {
120
+ const cell = document.createElement("span");
121
+ cell.style.color = `color-mix(in srgb, var(${slot}), var(${slot}))`;
122
+ probe.appendChild(cell);
123
+ return cell;
124
+ });
125
+ host.appendChild(probe);
126
+ try {
127
+ const parsed = cells.map((cell) => parseColor(getComputedStyle(cell).color));
128
+ const [orange, green, blue, violet, background] = parsed;
129
+ if (!orange || !green || !blue || !violet || !background) return null;
130
+ const root = document.documentElement;
131
+ return {
132
+ palette: [orange, green, blue, violet],
133
+ background,
134
+ isDark: root.classList.contains("dark"),
135
+ motionOff: root.getAttribute("data-oc-motion") === "off"
136
+ };
137
+ } finally {
138
+ host.removeChild(probe);
139
+ }
140
+ }
141
+ function subscribeOcTheme(cb) {
142
+ if (typeof document === "undefined") return () => {
143
+ };
144
+ let raf1 = 0;
145
+ let raf2 = 0;
146
+ const schedule = () => {
147
+ cancelAnimationFrame(raf1);
148
+ cancelAnimationFrame(raf2);
149
+ raf1 = requestAnimationFrame(() => {
150
+ raf2 = requestAnimationFrame(cb);
151
+ });
152
+ };
153
+ const mo = new MutationObserver(schedule);
154
+ mo.observe(document.documentElement, {
155
+ attributes: true,
156
+ attributeFilter: ["class", "data-oc-theme", "data-oc-motion"]
157
+ });
158
+ return () => {
159
+ mo.disconnect();
160
+ cancelAnimationFrame(raf1);
161
+ cancelAnimationFrame(raf2);
162
+ };
163
+ }
164
+ var SLOTS;
165
+ var init_scene_tokens = __esm({
166
+ "src/tokens/scene-tokens.ts"() {
167
+ SLOTS = ["--au-orange", "--au-green", "--au-blue", "--au-violet", "--background"];
168
+ }
169
+ });
170
+
171
+ // src/tokens/aurora-gl.ts
172
+ var aurora_gl_exports = {};
173
+ __export(aurora_gl_exports, {
174
+ mountAuroraGL: () => mountAuroraGL
175
+ });
176
+ function killFlagged() {
177
+ try {
178
+ const raw = localStorage.getItem(KILL_KEY);
179
+ if (!raw) return false;
180
+ if (Date.now() - Number(raw) > KILL_TTL_MS) {
181
+ localStorage.removeItem(KILL_KEY);
182
+ return false;
183
+ }
184
+ return true;
185
+ } catch {
186
+ return false;
187
+ }
188
+ }
189
+ function setKillFlag() {
190
+ try {
191
+ localStorage.setItem(KILL_KEY, String(Date.now()));
192
+ } catch {
193
+ }
194
+ }
195
+ function cypherFinish() {
196
+ const skin = document.documentElement.getAttribute("data-oc-theme");
197
+ return skin !== null && skin !== "ember";
198
+ }
199
+ function samplePalette(host) {
200
+ const tokens = readOcSceneTokens(host);
201
+ if (!tokens) return null;
202
+ return {
203
+ hues: tokens.palette.map((h) => normalizeHue(h, tokens.isDark)),
204
+ bg: tokens.background,
205
+ isDark: tokens.isDark,
206
+ finish: cypherFinish() ? 1 : 0
207
+ };
208
+ }
209
+ function mountAuroraGL(container) {
210
+ if (killFlagged()) return null;
211
+ if (getComputedStyle(container).getPropertyValue("--oc-aurora-gl").trim() === "off") {
212
+ return null;
213
+ }
214
+ const canvas = document.createElement("canvas");
215
+ canvas.className = "oc-aurora__gl";
216
+ const glMaybe = canvas.getContext("webgl2", {
217
+ antialias: false,
218
+ depth: false,
219
+ stencil: false,
220
+ alpha: false,
221
+ powerPreference: "low-power",
222
+ failIfMajorPerformanceCaveat: true
223
+ // SwiftShader/blocklist → CSS floor, free
224
+ });
225
+ if (!glMaybe) return null;
226
+ const gl = glMaybe;
227
+ const first = samplePalette(container);
228
+ if (!first) return null;
229
+ let prog;
230
+ const uni = {};
231
+ try {
232
+ const compile = (type, src) => {
233
+ const s = gl.createShader(type);
234
+ gl.shaderSource(s, src);
235
+ gl.compileShader(s);
236
+ if (!gl.getShaderParameter(s, gl.COMPILE_STATUS)) throw new Error("compile");
237
+ return s;
238
+ };
239
+ prog = gl.createProgram();
240
+ gl.attachShader(prog, compile(gl.VERTEX_SHADER, VS));
241
+ gl.attachShader(prog, compile(gl.FRAGMENT_SHADER, FS));
242
+ gl.linkProgram(prog);
243
+ if (!gl.getProgramParameter(prog, gl.LINK_STATUS)) throw new Error("link");
244
+ gl.useProgram(prog);
245
+ const buf = gl.createBuffer();
246
+ gl.bindBuffer(gl.ARRAY_BUFFER, buf);
247
+ gl.bufferData(gl.ARRAY_BUFFER, new Float32Array([-1, -1, 3, -1, -1, 3]), gl.STATIC_DRAW);
248
+ const loc = gl.getAttribLocation(prog, "p");
249
+ gl.enableVertexAttribArray(loc);
250
+ gl.vertexAttribPointer(loc, 2, gl.FLOAT, false, 0, 0);
251
+ for (const k of ["uRes", "uT", "uIsDark", "uFinish", "uMix", "uA0", "uA1", "uA2", "uA3", "uB0", "uB1", "uB2", "uB3", "uBg"]) {
252
+ uni[k] = gl.getUniformLocation(prog, k);
253
+ }
254
+ } catch {
255
+ return null;
256
+ }
257
+ container.appendChild(canvas);
258
+ let palFrom = first;
259
+ let palTo = first;
260
+ let mixStart = 0;
261
+ let raf = 0;
262
+ let lastFrame = 0;
263
+ let clock = 0;
264
+ let lastTick = 0;
265
+ let lastInput = performance.now();
266
+ let live = false;
267
+ let disposed = false;
268
+ let slowStreak = 0;
269
+ const setVec = (k, c) => gl.uniform3f(uni[k] ?? null, c.r, c.g, c.b);
270
+ function resize() {
271
+ const coarse = matchMedia("(pointer: coarse)").matches;
272
+ const dpr = Math.min(devicePixelRatio || 1, coarse ? 1.5 : 2) * 0.75;
273
+ const w = Math.max(1, Math.round(container.clientWidth * dpr));
274
+ const hgt = Math.max(1, Math.round(container.clientHeight * dpr));
275
+ if (canvas.width !== w || canvas.height !== hgt) {
276
+ canvas.width = w;
277
+ canvas.height = hgt;
278
+ gl.viewport(0, 0, w, hgt);
279
+ }
280
+ }
281
+ function draw(now) {
282
+ raf = requestAnimationFrame(draw);
283
+ if (now - lastFrame < FRAME_MS) return;
284
+ const frameGap = now - lastFrame;
285
+ lastFrame = now;
286
+ if (frameGap > FRAME_MS * 2.5) {
287
+ if (++slowStreak > 90) {
288
+ setKillFlag();
289
+ dispose();
290
+ return;
291
+ }
292
+ } else if (slowStreak > 0) slowStreak--;
293
+ const settled = now - lastInput > SETTLE_MS;
294
+ if (!settled) {
295
+ clock += Math.min(now - lastTick, 100) / 1e3;
296
+ }
297
+ lastTick = now;
298
+ if (settled && live && mixDone(now)) return;
299
+ resize();
300
+ const mix = Math.min(1, (now - mixStart) / CROSSFADE_MS);
301
+ gl.uniform2f(uni.uRes ?? null, canvas.width, canvas.height);
302
+ gl.uniform1f(uni.uT ?? null, clock);
303
+ gl.uniform1f(uni.uIsDark ?? null, palTo.isDark ? 1 : 0);
304
+ gl.uniform1f(uni.uFinish ?? null, palTo.finish);
305
+ gl.uniform1f(uni.uMix ?? null, mix);
306
+ setVec("uA0", palFrom.hues[0]);
307
+ setVec("uA1", palFrom.hues[1]);
308
+ setVec("uA2", palFrom.hues[2]);
309
+ setVec("uA3", palFrom.hues[3]);
310
+ setVec("uB0", palTo.hues[0]);
311
+ setVec("uB1", palTo.hues[1]);
312
+ setVec("uB2", palTo.hues[2]);
313
+ setVec("uB3", palTo.hues[3]);
314
+ setVec("uBg", palTo.bg);
315
+ gl.drawArrays(gl.TRIANGLES, 0, 3);
316
+ if (!live) {
317
+ live = true;
318
+ container.classList.add("oc-aurora--gl-live");
319
+ }
320
+ }
321
+ function mixDone(now) {
322
+ return now - mixStart >= CROSSFADE_MS;
323
+ }
324
+ const onInput = () => {
325
+ lastInput = performance.now();
326
+ };
327
+ const onVisibility = () => {
328
+ if (document.hidden) {
329
+ cancelAnimationFrame(raf);
330
+ raf = 0;
331
+ } else if (!raf && !disposed) {
332
+ lastFrame = 0;
333
+ lastTick = performance.now();
334
+ raf = requestAnimationFrame(draw);
335
+ }
336
+ };
337
+ const onContextLost = (e) => {
338
+ e.preventDefault();
339
+ cancelAnimationFrame(raf);
340
+ raf = 0;
341
+ };
342
+ const onContextRestored = () => {
343
+ dispose();
344
+ };
345
+ const unsubscribeTheme = subscribeOcTheme(() => {
346
+ if (disposed) return;
347
+ const root = document.documentElement;
348
+ if (root.getAttribute("data-oc-motion") === "off") {
349
+ dispose();
350
+ return;
351
+ }
352
+ const next = samplePalette(container);
353
+ if (!next) return;
354
+ palFrom = { ...palTo, hues: [...palTo.hues] };
355
+ palTo = next;
356
+ mixStart = performance.now();
357
+ lastInput = performance.now();
358
+ });
359
+ window.addEventListener("pointermove", onInput, { passive: true });
360
+ window.addEventListener("scroll", onInput, { passive: true });
361
+ window.addEventListener("keydown", onInput, { passive: true });
362
+ document.addEventListener("visibilitychange", onVisibility);
363
+ canvas.addEventListener("webglcontextlost", onContextLost);
364
+ canvas.addEventListener("webglcontextrestored", onContextRestored);
365
+ function dispose() {
366
+ if (disposed) return;
367
+ disposed = true;
368
+ cancelAnimationFrame(raf);
369
+ unsubscribeTheme();
370
+ window.removeEventListener("pointermove", onInput);
371
+ window.removeEventListener("scroll", onInput);
372
+ window.removeEventListener("keydown", onInput);
373
+ document.removeEventListener("visibilitychange", onVisibility);
374
+ canvas.removeEventListener("webglcontextlost", onContextLost);
375
+ canvas.removeEventListener("webglcontextrestored", onContextRestored);
376
+ container.classList.remove("oc-aurora--gl-live");
377
+ canvas.remove();
378
+ const ext = gl.getExtension("WEBGL_lose_context");
379
+ if (ext) ext.loseContext();
380
+ }
381
+ resize();
382
+ mixStart = performance.now();
383
+ lastTick = performance.now();
384
+ raf = requestAnimationFrame(draw);
385
+ return dispose;
386
+ }
387
+ var KILL_KEY, KILL_TTL_MS, SETTLE_MS, FRAME_MS, CROSSFADE_MS, VS, FS;
388
+ var init_aurora_gl = __esm({
389
+ "src/tokens/aurora-gl.ts"() {
390
+ init_scene_tokens();
391
+ KILL_KEY = "oc-aurora-gl-kill:1";
392
+ KILL_TTL_MS = 7 * 24 * 60 * 60 * 1e3;
393
+ SETTLE_MS = 9e4;
394
+ FRAME_MS = 33;
395
+ CROSSFADE_MS = 250;
396
+ VS = `#version 300 es
397
+ in vec2 p;void main(){gl_Position=vec4(p,0.,1.);}`;
398
+ FS = `#version 300 es
399
+ precision highp float;
400
+ out vec4 o;
401
+ uniform vec2 uRes;uniform float uT,uIsDark,uFinish,uMix;
402
+ uniform vec3 uA0,uA1,uA2,uA3,uB0,uB1,uB2,uB3,uBg;
403
+ float h(vec2 p){return fract(sin(dot(p,vec2(127.1,311.7)))*43758.5453);}
404
+ float n2(vec2 p){vec2 i=floor(p),f=fract(p);f=f*f*(3.-2.*f);
405
+ return mix(mix(h(i),h(i+vec2(1,0)),f.x),mix(h(i+vec2(0,1)),h(i+vec2(1,1)),f.x),f.y);}
406
+ float fbm(vec2 p){float v=0.,a=.55;for(int i=0;i<3;i++){v+=a*n2(p);p=p*2.03+vec2(1.7,9.2);a*=.5;}return v;}
407
+ float B2(vec2 a){a=floor(a);return fract(a.x/2.+a.y*a.y*.75);}
408
+ // OKLab mix (Ottosson) so skin crossfades never transit gray-brown.
409
+ vec3 l2s(vec3 c){return mix(12.92*c,1.055*pow(c,vec3(1./2.4))-.055,step(.0031308,c));}
410
+ vec3 s2l(vec3 c){return mix(c/12.92,pow((c+.055)/1.055,vec3(2.4)),step(.04045,c));}
411
+ vec3 okmix(vec3 a,vec3 b,float t){
412
+ vec3 la=s2l(a),lb=s2l(b);
413
+ mat3 M1=mat3(.4122214708,.2119034982,.0883024619,.5363325363,.6806995451,.2817188376,.0514459929,.1073969566,.6299787005);
414
+ mat3 M2=mat3(4.0767416621,-1.2684380046,-.0041960863,-3.3077115913,2.6097574011,-.7034186147,.2309699292,-.3413193965,1.707614701);
415
+ vec3 ka=pow(M1*la,vec3(1./3.)),kb=pow(M1*lb,vec3(1./3.));
416
+ vec3 k=mix(ka,kb,t);return clamp(l2s(M2*(k*k*k)),0.,1.);}
417
+ void main(){
418
+ vec2 uv=gl_FragCoord.xy/uRes;
419
+ vec2 p=(uv-.5)*vec2(uRes.x/uRes.y,1.)*1.9;
420
+ float t=uT*.018;
421
+ vec2 w=vec2(fbm(p+vec2(0.,t)),fbm(p+vec2(5.2,1.3)-t*.7));
422
+ float f=fbm(p+1.9*w+vec2(t*.5,-t*.3));
423
+ float g=fbm(p*.6+w*1.2+vec2(9.1,3.7));
424
+ vec3 c0=okmix(uA0,uB0,uMix),c1=okmix(uA1,uB1,uMix),c2=okmix(uA2,uB2,uMix),c3=okmix(uA3,uB3,uMix);
425
+ vec3 c=mix(mix(c0,c1,smoothstep(.25,.55,g)),mix(c2,c3,smoothstep(.45,.8,g)),smoothstep(.4,.7,g));
426
+ float e=smoothstep(.32,.9,f);
427
+ if(uFinish>.5){
428
+ float b=B2(.125*gl_FragCoord.xy)*.0625+B2(.25*gl_FragCoord.xy)*.25+B2(.5*gl_FragCoord.xy);
429
+ e=floor(e*5.+b*.8-.4)/5.;}
430
+ // container CSS already applies the mode-op \xD7 intensity opacity + radial mask
431
+ vec3 col=(uIsDark>.5)?clamp(uBg+c*e*1.15,0.,1.):mix(uBg,c,e);
432
+ col+=(fract(52.9829189*fract(dot(gl_FragCoord.xy,vec2(0.06711056,0.00583715))))-.5)/255.;
433
+ o=vec4(col,1.);}`;
434
+ }
435
+ });
62
436
  function cn(...inputs) {
63
437
  return tailwindMerge.twMerge(clsx.clsx(inputs));
64
438
  }
@@ -110,9 +484,76 @@ function resolveTheme(id) {
110
484
  var OC_SKIN_COOKIE = "oc_skin";
111
485
  var OC_MOTION_COOKIE = "oc_motion";
112
486
  var BLOBS = [1, 2, 3, 4, 5];
113
- function OcAurora({ intensity, className }) {
487
+ function onIdle(cb, timeout) {
488
+ if (typeof requestIdleCallback === "function") {
489
+ const id2 = requestIdleCallback(cb, { timeout });
490
+ return () => cancelIdleCallback(id2);
491
+ }
492
+ const id = setTimeout(cb, timeout);
493
+ return () => clearTimeout(id);
494
+ }
495
+ function OcAurora({ intensity, gl = false, className }) {
496
+ const hostRef = React2.useRef(null);
497
+ React2.useEffect(() => {
498
+ if (!gl) return;
499
+ const host = hostRef.current;
500
+ if (!host) return;
501
+ let disposed = false;
502
+ let disposeScene = null;
503
+ let cancelIdle = null;
504
+ const prm = matchMedia("(prefers-reduced-motion: reduce)");
505
+ const forced = matchMedia("(forced-colors: active)");
506
+ function gatesPass() {
507
+ if (prm.matches || forced.matches) return false;
508
+ if (document.documentElement.getAttribute("data-oc-motion") === "off") return false;
509
+ const nav = navigator;
510
+ if (nav.connection?.saveData === true) return false;
511
+ if (typeof nav.deviceMemory === "number" && nav.deviceMemory <= 4) return false;
512
+ return true;
513
+ }
514
+ function boot() {
515
+ cancelIdle = onIdle(async () => {
516
+ if (disposed || disposeScene || !gatesPass()) return;
517
+ try {
518
+ const mod = await Promise.resolve().then(() => (init_aurora_gl(), aurora_gl_exports));
519
+ if (disposed || disposeScene || !gatesPass()) return;
520
+ disposeScene = mod.mountAuroraGL(host);
521
+ } catch {
522
+ }
523
+ }, 2e3);
524
+ }
525
+ function teardownScene() {
526
+ disposeScene?.();
527
+ disposeScene = null;
528
+ }
529
+ const onPrmChange = () => {
530
+ if (prm.matches) teardownScene();
531
+ else if (!disposeScene) boot();
532
+ };
533
+ prm.addEventListener?.("change", onPrmChange);
534
+ const mo = new MutationObserver(() => {
535
+ const off = document.documentElement.getAttribute("data-oc-motion") === "off";
536
+ if (!off && !disposeScene && !disposed) boot();
537
+ });
538
+ mo.observe(document.documentElement, {
539
+ attributes: true,
540
+ attributeFilter: ["data-oc-motion"]
541
+ });
542
+ if (document.readyState === "complete") boot();
543
+ else {
544
+ const onLoad = () => boot();
545
+ window.addEventListener("load", onLoad, { once: true });
546
+ }
547
+ return () => {
548
+ disposed = true;
549
+ cancelIdle?.();
550
+ prm.removeEventListener?.("change", onPrmChange);
551
+ mo.disconnect();
552
+ teardownScene();
553
+ };
554
+ }, [gl]);
114
555
  const style = intensity == null ? void 0 : { "--oc-aurora-intensity": String(intensity) };
115
- return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: cn("oc-aurora", className), style, "aria-hidden": "true", children: [
556
+ return /* @__PURE__ */ jsxRuntime.jsxs("div", { ref: hostRef, className: cn("oc-aurora", className), style, "aria-hidden": "true", children: [
116
557
  BLOBS.map((n) => /* @__PURE__ */ jsxRuntime.jsx("div", { className: `oc-aurora__blob oc-aurora__blob-${n}` }, n)),
117
558
  /* @__PURE__ */ jsxRuntime.jsx("div", { className: "oc-aurora__grain" })
118
559
  ] });
@@ -251,7 +692,13 @@ function OcThemeProvider({
251
692
  [skin, setSkin, motion, setMotion]
252
693
  );
253
694
  return /* @__PURE__ */ jsxRuntime.jsxs(OcSkinContext.Provider, { value, children: [
254
- aurora !== false && /* @__PURE__ */ jsxRuntime.jsx(OcAurora, { intensity: typeof aurora === "object" ? aurora.intensity : void 0 }),
695
+ aurora !== false && /* @__PURE__ */ jsxRuntime.jsx(
696
+ OcAurora,
697
+ {
698
+ intensity: typeof aurora === "object" ? aurora.intensity : void 0,
699
+ gl: typeof aurora === "object" ? aurora.gl : void 0
700
+ }
701
+ ),
255
702
  children
256
703
  ] });
257
704
  }
@@ -536,6 +983,103 @@ function OcAppearanceMenu({
536
983
  )
537
984
  ] });
538
985
  }
986
+
987
+ // src/tokens/index.ts
988
+ init_scene_tokens();
989
+
990
+ // src/tokens/glyphs.ts
991
+ var OC_GLYPH_CANVAS = 1024;
992
+ var OC_GLYPHS = {
993
+ orangecheck: `<path d="M518 856Q463 820 438.5 785.5Q414 751 414 711Q414 657 462.5 613.0Q511 569 711 473Q766 509 790.5 543.5Q815 578 815 621Q815 702 550 840ZM930 1460V1235Q845 1265 779.0 1279.5Q713 1294 659 1294Q583 1294 540.5 1265.0Q498 1236 498 1184Q498 1109 701 1004Q720 994 729 989Q943 879 1002.0 808.5Q1061 738 1061 637Q1061 548 1013.5 484.0Q966 420 864 373Q934 323 966.5 261.5Q999 200 999 119Q999 -28 894.5 -111.5Q790 -195 604 -195Q515 -195 429.0 -180.5Q343 -166 258 -137V92Q343 62 424.0 46.5Q505 31 578 31Q655 31 696.0 59.5Q737 88 737 141Q737 211 523 326L512 332L486 346Q170 516 170 688Q170 782 222.0 851.5Q274 921 371 954Q300 1004 268.0 1064.0Q236 1124 236 1206Q236 1348 340.0 1434.0Q444 1520 616 1520Q690 1520 768.5 1505.0Q847 1490 930 1460Z" fill="__FG__" transform="translate(225.3457 820.5434) scale(0.465726 -0.465726)"/>`,
994
+ attest: `<g transform="scale(42.666667 42.666667)"><path d="M3.85 8.62a4 4 0 0 1 4.78-4.77 4 4 0 0 1 6.74 0 4 4 0 0 1 4.78 4.78 4 4 0 0 1 0 6.74 4 4 0 0 1-4.77 4.78 4 4 0 0 1-6.75 0 4 4 0 0 1-4.78-4.77 4 4 0 0 1 0-6.76Z" fill="__FG__" stroke="__FG__" stroke-width="0.5"/><path d="M9 12 l2 2 l4 -4" fill="none" stroke="__INK__" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"/></g>`,
995
+ docs: `<g transform="scale(42.666667 42.666667)"><rect x="3" y="3" width="18" height="18" fill="__FG__"/><rect x="6" y="6" width="12" height="12" fill="none" stroke="__INK__" stroke-width="1.5"/><rect x="8" y="9" width="8" height="1.25" fill="__INK__"/><rect x="8" y="11.5" width="8" height="1.25" fill="__INK__"/><rect x="8" y="14" width="5" height="1.25" fill="__INK__"/></g>`,
996
+ me: `<g transform="scale(42.666667 42.666667)"><rect x="3" y="3" width="18" height="18" fill="__FG__"/><rect x="6" y="6" width="12" height="12" fill="none" stroke="__INK__" stroke-width="1.5"/><circle cx="12" cy="11" r="2" fill="__INK__"/><path d="M8 16.5 C 8 14.5, 9.5 13.5, 12 13.5 C 14.5 13.5, 16 14.5, 16 16.5" fill="none" stroke="__INK__" stroke-width="1.5" stroke-linecap="square"/></g>`,
997
+ vault: `<g transform="scale(42.666667 42.666667)"><path d="M8 9 L8 6.5 Q8 3.5 12 3.5 Q16 3.5 16 6.5 L16 9" fill="none" stroke="__FG__" stroke-width="2" stroke-linecap="square"/><rect x="4" y="9" width="16" height="12" fill="__FG__" stroke="__FG__" stroke-width="0.75"/><circle cx="12" cy="14.5" r="2.75" fill="none" stroke="__INK__" stroke-width="1.5"/><rect x="11.4" y="14.5" width="1.2" height="3.25" fill="__INK__"/><rect x="5.5" y="19" width="2.25" height="1.5" fill="__INK__"/><rect x="16.25" y="19" width="2.25" height="1.5" fill="__INK__"/></g>`,
998
+ fleet: `<g transform="scale(42.666667 42.666667)"><rect x="3" y="3" width="18" height="18" fill="__FG__"/><rect x="6" y="6" width="12" height="12" fill="none" stroke="__INK__" stroke-width="1.5"/><path d="M8.5 9.5 L11 12 L8.5 14.5" fill="none" stroke="__INK__" stroke-width="1.6" stroke-linejoin="miter" stroke-linecap="square"/><rect x="12" y="14" width="4" height="1.4" fill="__INK__"/></g>`,
999
+ chat: `<g transform="scale(42.666667 42.666667)"><path d="M5 4 H19 A2 2 0 0 1 21 6 V13 A2 2 0 0 1 19 15 H11 L7 19 V15 H5 A2 2 0 0 1 3 13 V6 A2 2 0 0 1 5 4 Z" fill="__FG__" stroke="__FG__" stroke-width="1.6" stroke-linejoin="round"/><circle cx="8" cy="9.5" r="1.15" fill="__INK__"/><circle cx="12" cy="9.5" r="1.15" fill="__INK__"/><circle cx="16" cy="9.5" r="1.15" fill="__INK__"/></g>`,
1000
+ cosign: `<g transform="scale(42.666667 42.666667)"><rect x="3" y="3" width="18" height="18" fill="__FG__"/><rect x="6" y="6" width="12" height="12" fill="none" stroke="__INK__" stroke-width="1.5"/><circle cx="9.2" cy="10.4" r="1.65" fill="__INK__"/><circle cx="14.8" cy="10.4" r="1.65" fill="__INK__"/><path d="M6.5 16.6 C 6.5 14.9, 7.6 14.1, 9.2 14.1 C 10.8 14.1, 11.9 14.9, 11.9 16.6" fill="none" stroke="__INK__" stroke-width="1.5" stroke-linecap="square"/><path d="M12.1 16.6 C 12.1 14.9, 13.2 14.1, 14.8 14.1 C 16.4 14.1, 17.5 14.9, 17.5 16.6" fill="none" stroke="__INK__" stroke-width="1.5" stroke-linecap="square"/></g>`,
1001
+ lock: `<g transform="scale(42.666667 42.666667)"><path d="M7 11V7.5a5 5 0 0 1 10 0V11" fill="none" stroke="__FG__" stroke-width="2" stroke-linecap="square"/><rect x="4" y="11" width="16" height="10" fill="__FG__" stroke="__FG__" stroke-width="0.75"/><rect x="11" y="14" width="2" height="4" fill="__INK__"/><rect x="10.25" y="14" width="3.5" height="1.5" fill="__INK__"/></g>`,
1002
+ vote: `<g transform="scale(42.666667 42.666667)"><rect x="2" y="14" width="4" height="8" fill="__FG__"/><rect x="10" y="8" width="4" height="14" fill="__FG__"/><rect x="18" y="2" width="4" height="20" fill="__FG__"/></g>`,
1003
+ stamp: `<g transform="scale(42.666667 42.666667)"><rect x="3" y="3" width="18" height="18" fill="__FG__"/><rect x="6" y="6" width="12" height="12" fill="none" stroke="__INK__" stroke-width="1.5"/><rect x="11.25" y="8.5" width="1.5" height="7" fill="__INK__"/><rect x="9.5" y="10" width="5" height="1.5" fill="__INK__"/><path d="M9 14.5 L12 15.75 L15 14.5" fill="none" stroke="__INK__" stroke-width="1.5" stroke-linejoin="miter" stroke-linecap="square"/></g>`,
1004
+ agent: `<g transform="scale(42.666667 42.666667)"><path d="M4 20 L12 4 L20 20 Z" fill="__FG__" stroke="__FG__" stroke-width="1.5" stroke-linejoin="miter"/><rect x="7.5" y="13.5" width="9" height="2" fill="__INK__"/><rect x="11" y="9" width="2" height="2" fill="__INK__"/></g>`,
1005
+ pledge: `<g transform="scale(42.666667 42.666667)"><rect x="3" y="3" width="18" height="18" fill="__FG__"/><rect x="6" y="6" width="12" height="12" fill="none" stroke="__INK__" stroke-width="1.5"/><rect x="9.25" y="8.5" width="1.75" height="7" fill="__INK__"/><rect x="9.25" y="8.5" width="4.5" height="1.5" fill="__INK__"/><rect x="12.25" y="8.5" width="1.5" height="3.5" fill="__INK__"/><rect x="9.25" y="10.5" width="4.5" height="1.5" fill="__INK__"/></g>`,
1006
+ analytics: `<g transform="scale(42.666667 42.666667)"><rect x="3" y="3" width="18" height="18" fill="__FG__"/><path d="M6 17 L10 12 L14 15 L18 8" fill="none" stroke="__INK__" stroke-width="1.8" stroke-linecap="square" stroke-linejoin="miter"/><rect x="16.6" y="6.6" width="2.8" height="2.8" fill="__INK__"/></g>`,
1007
+ btc: `<path d="M373 1414V1676H531V1414ZM670 1414V1676H829V1414ZM373 -186V76H531V-186ZM670 -186V76H829V-186ZM129 0V1490H705Q863 1490 972.50 1441Q1082 1392 1139 1305.50Q1196 1219 1196 1103Q1196 1016 1164 951Q1132 886 1074 843Q1016 800 937 779V774Q1024 765 1095.50 721Q1167 677 1210 600.50Q1253 524 1253 416Q1253 293 1194.50 199Q1136 105 1020 52.50Q904 0 731 0ZM391 217H700Q838 217 910.50 272.50Q983 328 983 428Q983 497 950 547.50Q917 598 855.50 626Q794 654 707 654H391ZM391 858H688Q762 858 817 883.50Q872 909 902 956Q932 1003 932 1068Q932 1161 868 1217.50Q804 1274 689 1274H391Z" fill="__FG__" transform="translate(238.3907 806.9912) scale(0.395961 -0.395961)"/>`
1008
+ };
1009
+ var LAYERS = [0, 1, 2, 3, 4, 5];
1010
+ function sub(markup, fg, ink) {
1011
+ return markup.split("__FG__").join(fg).split("__INK__").join(ink).split("__BG__").join("none");
1012
+ }
1013
+ function OcSigil({ glyph, corner = "bottom-left", parallax = true, className }) {
1014
+ const rawId = React2.useId();
1015
+ const id = React2.useMemo(() => `oc-sigil-${rawId.replace(/[^a-zA-Z0-9_-]/g, "")}`, [rawId]);
1016
+ const parRef = React2.useRef(null);
1017
+ const seed = React2.useMemo(() => {
1018
+ let h = 0;
1019
+ for (const ch of glyph) h = h * 31 + ch.charCodeAt(0) | 0;
1020
+ return (h % 7 - 3) * 1.5;
1021
+ }, [glyph]);
1022
+ const filled = React2.useMemo(() => sub(OC_GLYPHS[glyph], "currentColor", "currentColor"), [glyph]);
1023
+ const wire = React2.useMemo(() => sub(OC_GLYPHS[glyph], "none", "currentColor"), [glyph]);
1024
+ React2.useEffect(() => {
1025
+ if (!parallax) return;
1026
+ const el = parRef.current;
1027
+ if (!el) return;
1028
+ if (!matchMedia("(pointer: fine)").matches) return;
1029
+ const prm = matchMedia("(prefers-reduced-motion: reduce)");
1030
+ let raf = 0;
1031
+ let tx = 0;
1032
+ let ty = 0;
1033
+ let cx = 0;
1034
+ let cy = 0;
1035
+ const allowed = () => !prm.matches && document.documentElement.getAttribute("data-oc-motion") !== "off";
1036
+ const onMove = (e) => {
1037
+ if (!allowed()) return;
1038
+ tx = (e.clientX / innerWidth - 0.5) * 10;
1039
+ ty = (e.clientY / innerHeight - 0.5) * -10;
1040
+ if (!raf) raf = requestAnimationFrame(step);
1041
+ };
1042
+ const step = () => {
1043
+ raf = 0;
1044
+ cx += (tx - cx) * 0.06;
1045
+ cy += (ty - cy) * 0.06;
1046
+ el.style.setProperty("--oc-sigil-ry", `${Math.max(-5, Math.min(5, cx)).toFixed(2)}deg`);
1047
+ el.style.setProperty("--oc-sigil-rx", `${Math.max(-5, Math.min(5, cy)).toFixed(2)}deg`);
1048
+ if (Math.abs(tx - cx) + Math.abs(ty - cy) > 0.05) raf = requestAnimationFrame(step);
1049
+ };
1050
+ const onPrm = () => {
1051
+ if (prm.matches) {
1052
+ el.style.setProperty("--oc-sigil-rx", "0deg");
1053
+ el.style.setProperty("--oc-sigil-ry", "0deg");
1054
+ }
1055
+ };
1056
+ window.addEventListener("pointermove", onMove, { passive: true });
1057
+ prm.addEventListener?.("change", onPrm);
1058
+ return () => {
1059
+ window.removeEventListener("pointermove", onMove);
1060
+ prm.removeEventListener?.("change", onPrm);
1061
+ cancelAnimationFrame(raf);
1062
+ };
1063
+ }, [parallax]);
1064
+ return /* @__PURE__ */ jsxRuntime.jsxs(
1065
+ "div",
1066
+ {
1067
+ "aria-hidden": "true",
1068
+ className: cn("oc-sigil", `oc-sigil--${corner}`, className),
1069
+ style: { "--oc-sigil-seed": `${seed}deg` },
1070
+ children: [
1071
+ /* @__PURE__ */ jsxRuntime.jsx("svg", { width: "0", height: "0", style: { position: "absolute" }, "aria-hidden": "true", children: /* @__PURE__ */ jsxRuntime.jsxs("defs", { children: [
1072
+ /* @__PURE__ */ jsxRuntime.jsx("g", { id: `${id}-filled`, dangerouslySetInnerHTML: { __html: filled } }),
1073
+ /* @__PURE__ */ jsxRuntime.jsx("g", { id: `${id}-wire`, dangerouslySetInnerHTML: { __html: wire } })
1074
+ ] }) }),
1075
+ /* @__PURE__ */ jsxRuntime.jsx("div", { className: "oc-sigil__drift oc-ambient", children: /* @__PURE__ */ jsxRuntime.jsx("div", { ref: parRef, className: "oc-sigil__par", children: LAYERS.map((n) => /* @__PURE__ */ jsxRuntime.jsxs("svg", { viewBox: "0 0 1024 1024", className: `oc-sigil__layer oc-sigil__layer-${n}`, children: [
1076
+ /* @__PURE__ */ jsxRuntime.jsx("use", { className: "oc-sigil__use-filled", href: `#${id}-filled` }),
1077
+ /* @__PURE__ */ jsxRuntime.jsx("use", { className: "oc-sigil__use-wire", href: `#${id}-wire` })
1078
+ ] }, n)) }) })
1079
+ ]
1080
+ }
1081
+ );
1082
+ }
539
1083
  var buttonVariants = classVarianceAuthority.cva(
540
1084
  "focus-visible:border-ring focus-visible:ring-ring/50 aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive inline-flex shrink-0 items-center justify-center gap-2 rounded-md text-sm font-medium whitespace-nowrap transition-all outline-none focus-visible:ring-[3px] disabled:pointer-events-none disabled:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",
541
1085
  {
@@ -2121,7 +2665,7 @@ function Sparkline({ data, width = 96, height = 24, area = false, className }) {
2121
2665
  }
2122
2666
  );
2123
2667
  }
2124
- function StatBlock({ label, value, sub, delta, tone = "default", className }) {
2668
+ function StatBlock({ label, value, sub: sub2, delta, tone = "default", className }) {
2125
2669
  const toneClass = tone === "success" ? "text-success" : tone === "warning" ? "text-warning" : tone === "destructive" ? "text-destructive" : "text-foreground";
2126
2670
  return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: cn("flex flex-col gap-1", className), children: [
2127
2671
  /* @__PURE__ */ jsxRuntime.jsx("span", { className: "label-mono text-muted-foreground text-[10px]", children: label }),
@@ -2136,7 +2680,7 @@ function StatBlock({ label, value, sub, delta, tone = "default", className }) {
2136
2680
  }
2137
2681
  ),
2138
2682
  /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-baseline gap-2", children: [
2139
- sub && /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-muted-foreground font-mono text-[11px] tracking-wide lowercase", children: sub }),
2683
+ sub2 && /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-muted-foreground font-mono text-[11px] tracking-wide lowercase", children: sub2 }),
2140
2684
  delta && /* @__PURE__ */ jsxRuntime.jsxs(
2141
2685
  "span",
2142
2686
  {
@@ -5126,6 +5670,8 @@ exports.MarketingHeading = MarketingHeading;
5126
5670
  exports.Modal = Modal;
5127
5671
  exports.NumberedStep = NumberedStep;
5128
5672
  exports.OC_DEFAULT_ACCENT = OC_DEFAULT_ACCENT;
5673
+ exports.OC_GLYPHS = OC_GLYPHS;
5674
+ exports.OC_GLYPH_CANVAS = OC_GLYPH_CANVAS;
5129
5675
  exports.OC_MOTION_COOKIE = OC_MOTION_COOKIE;
5130
5676
  exports.OC_SKIN_COOKIE = OC_SKIN_COOKIE;
5131
5677
  exports.OC_THEMES = OC_THEMES;
@@ -5139,6 +5685,7 @@ exports.OcDashboardShell = OcDashboardShell;
5139
5685
  exports.OcFamilyFooter = OcFamilyFooter;
5140
5686
  exports.OcLogoDropdown = OcLogoDropdown;
5141
5687
  exports.OcPrimaryNav = OcPrimaryNav;
5688
+ exports.OcSigil = OcSigil;
5142
5689
  exports.OcThemeBridge = OcThemeBridge;
5143
5690
  exports.OcThemePicker = OcThemePicker;
5144
5691
  exports.OcThemeProvider = OcThemeProvider;
@@ -5215,12 +5762,15 @@ exports.getOcThemeInitScript = getOcThemeInitScript;
5215
5762
  exports.iconBadgeVariants = iconBadgeVariants;
5216
5763
  exports.isKnownTheme = isKnownTheme;
5217
5764
  exports.makeStatusPill = makeStatusPill;
5765
+ exports.normalizeHue = normalizeHue;
5218
5766
  exports.priceBoth = priceBoth;
5219
5767
  exports.prompt = prompt;
5768
+ exports.readOcSceneTokens = readOcSceneTokens;
5220
5769
  exports.relativeTime = relativeTime;
5221
5770
  exports.resolveTheme = resolveTheme;
5222
5771
  exports.satsToUsd = satsToUsd;
5223
5772
  exports.shortenAddress = shortenAddress;
5773
+ exports.subscribeOcTheme = subscribeOcTheme;
5224
5774
  exports.surfaceVariants = surfaceVariants;
5225
5775
  exports.usdToSats = usdToSats;
5226
5776
  exports.useOcMotion = useOcMotion;