@almadar/shell-web 0.1.0 → 1.1.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/{ArbitraryClassCompiler-Mzabq-UB.d.ts → ArbitraryClassCompiler-CO_iASBn.d.ts} +99 -4
- package/dist/AvlGlyph-PIXU6QH5.js +5 -0
- package/dist/AvlStateMachine-CKGMECMG.js +8 -0
- package/dist/AvlTransitionDetail-QZX6G5KJ.js +10 -0
- package/dist/AvlTransitionExplainer-26WLEIC6.js +11 -0
- package/dist/BehaviorView-JLZ4PKWY.js +10 -0
- package/dist/{EventBusProvider-CVwjkV_2.d.ts → EventBusProvider-BFFHfN4O.d.ts} +12 -0
- package/dist/{FileTree-BCFnBEuQ.d.ts → FileTree-B3GDAjaQ.d.ts} +131 -4
- package/dist/FlowCanvas-RPII4V24.js +23 -0
- package/dist/{BehaviorValueFrame-SSEMEBTG.css → FlowCanvas-VWUPMBKB.css} +189 -191
- package/dist/{GameAudioProvider-Cm9BnvmP.d.ts → GameAudioProvider-D7wo5ryN.d.ts} +5 -8
- package/dist/KernelEngineContext-CPeWQMAz.d.ts +46 -0
- package/dist/LayersPanel-M2LHWUFF.js +6 -0
- package/dist/ModuleCard-NJD6JQGD.js +6 -0
- package/dist/OrbInspector-OWWKPOBF.js +23 -0
- package/dist/{TraitValueFrame-4G3KOUBR.css → OrbInspector-VMTMZHNQ.css} +189 -191
- package/dist/{Select-mDZIwNqN.d.ts → Select-C2Uq6t86.d.ts} +17 -31
- package/dist/ServerBridge-Bqsj-lOU.d.ts +124 -0
- package/dist/{FlowCanvas-3JRMNJLV.css → UISlotRenderer-BIS6KT7T.css} +189 -191
- package/dist/UISlotRenderer-PY7FIJXN.js +23 -0
- package/dist/auth/browser/index.js +1 -0
- package/dist/auth/react/index.d.ts +8 -1
- package/dist/auth/react/index.js +40 -2
- package/dist/avl/index.css +189 -191
- package/dist/avl/index.d.ts +107 -85
- package/dist/avl/index.js +170 -39
- package/dist/{chunk-P4LNHAFI.js → chunk-2WGR4TDJ.js} +465 -36
- package/dist/{chunk-GKIFONTE.js → chunk-3S54FWRC.js} +2 -2
- package/dist/{chunk-KVQS4GXU.js → chunk-4YJ53G7S.js} +18 -8
- package/dist/{chunk-MBQAMMSE.js → chunk-4YXBKHHM.js} +269 -658
- package/dist/{chunk-YDNJLLG6.js → chunk-57DC34LY.js} +19 -10
- package/dist/{chunk-FP3WIKTC.js → chunk-7N6ZPHQ5.js} +9 -1
- package/dist/{chunk-AILY3XPS.js → chunk-AE7VCQB6.js} +5 -6
- package/dist/{chunk-L677XGY3.js → chunk-AGVSO4WY.js} +4 -5
- package/dist/{chunk-FAJDTHWC.js → chunk-AGXD77SL.js} +2 -2
- package/dist/chunk-AU7O65OX.js +66 -0
- package/dist/{chunk-DFNZUYX4.js → chunk-FAKU5F62.js} +273 -29
- package/dist/{chunk-U6QRZASX.js → chunk-ILQXJ2AR.js} +1 -1
- package/dist/chunk-M74BCDBQ.js +490 -0
- package/dist/{chunk-GYTPOFVC.js → chunk-MS4K3K2R.js} +12095 -13329
- package/dist/{chunk-SGM3FASH.js → chunk-OWNG4JZI.js} +13 -12
- package/dist/{chunk-VFF5OO47.js → chunk-PCR37T3U.js} +15 -38
- package/dist/{chunk-SJGJJKBY.js → chunk-PRLHKBXG.js} +5 -3
- package/dist/{chunk-R5O5AUPI.js → chunk-PRXQGGCO.js} +93 -86
- package/dist/{chunk-42FY4RYA.js → chunk-REXYVBUO.js} +2 -2
- package/dist/{chunk-EQAMU2ZC.js → chunk-UTDC2NEA.js} +1 -1
- package/dist/{chunk-73SRAB4P.js → chunk-UU57VNS2.js} +2 -2
- package/dist/{chunk-TESBIVUA.js → chunk-VHC2M26B.js} +2 -2
- package/dist/{chunk-L2DEKY4J.js → chunk-VO2TTLS5.js} +3 -6
- package/dist/{chunk-2PY54Z44.js → chunk-VUIACGDU.js} +4 -5
- package/dist/{chunk-DLZF4PVE.js → chunk-YYIHRIDH.js} +3 -3
- package/dist/{chunk-DYEKAA4L.js → chunk-ZDRDJKYB.js} +243 -252
- package/dist/components/index.css +189 -191
- package/dist/components/index.d.ts +739 -289
- package/dist/components/index.js +25 -28
- package/dist/context/index.d.ts +2 -3
- package/dist/context/index.js +4 -3
- package/dist/core.d.ts +95 -19
- package/dist/core.js +2 -1
- package/dist/design-classes/index.cjs +3 -1
- package/dist/design-classes/index.js +3 -1
- package/dist/{fx-CmQjnHmT.d.ts → fx-Br8zjvu9.d.ts} +6 -6
- package/dist/hooks/index.d.ts +40 -5
- package/dist/hooks/index.js +5 -4
- package/dist/index.d.ts +40 -114
- package/dist/index.js +174 -34
- package/dist/kernel-client-JW6OH5FX.js +537 -0
- package/dist/kernel-wire-DGAySGhX.d.ts +95 -0
- package/dist/lib/index.d.ts +3 -4
- package/dist/lib/index.js +4 -4
- package/dist/{prism-AIWGN2X5.js → prism-X5YWKXO5.js} +5 -3
- package/dist/providers/index.css +189 -191
- package/dist/providers/index.d.ts +41 -28
- package/dist/providers/index.js +19 -24
- package/dist/renderer/index.d.ts +0 -2
- package/dist/renderer/index.js +1 -0
- package/dist/runtime/index.css +189 -191
- package/dist/runtime/index.d.ts +57 -253
- package/dist/runtime/index.js +18 -24
- package/dist/ssr/index.cjs +2643 -535
- package/dist/ssr/index.d.cts +0 -23
- package/dist/ssr/index.d.ts +0 -23
- package/dist/ssr/index.js +2639 -535
- package/dist/storage/browser/index.js +1 -0
- package/dist/test-support.d.ts +15 -8
- package/dist/test-support.js +91 -24
- package/dist/{paintDispatch-ChW5mVuK.d.ts → verificationRegistry-oopV1J1n.d.ts} +132 -30
- package/package.json +14 -38
- package/src/core/lib/band-shapes.json +7 -0
- package/src/core/locales/ar.json +18 -5
- package/src/core/locales/en.json +18 -5
- package/src/core/locales/sl.json +18 -5
- package/tailwind-preset.cjs +30 -1
- package/dist/AvlGlyph-JKJOAH23.js +0 -6
- package/dist/AvlStateMachine-PI4YGREK.js +0 -8
- package/dist/AvlTransitionDetail-ZH7V24UG.js +0 -12
- package/dist/AvlTransitionExplainer-ZSRT7L6Y.js +0 -13
- package/dist/BehaviorValueFrame-6RUJXT4A.js +0 -29
- package/dist/BehaviorView-RFEE5J6E.js +0 -10
- package/dist/Canvas3DHost-_Y-5uLM_.d.ts +0 -552
- package/dist/FlowCanvas-STDC4OWK.js +0 -27
- package/dist/KernelEngineContext-BOCQoFwk.d.ts +0 -43
- package/dist/LayersPanel-BBQ54IVG.js +0 -7
- package/dist/ModuleCard-3TT2X7IW.js +0 -7
- package/dist/OrbInspector-K6T6O7GI.js +0 -27
- package/dist/OrbInspector-MHLJ6OEE.css +0 -1756
- package/dist/ServerBridge-Cm1On51b.d.ts +0 -233
- package/dist/TraitValueFrame-2PJGLLVI.js +0 -28
- package/dist/UISlotRenderer-JKFSX24W.js +0 -27
- package/dist/UISlotRenderer-KVFO6J7R.css +0 -1756
- package/dist/UserContext-DqWeZkUZ.d.ts +0 -100
- package/dist/avl-3d-context-BIRKWpaL.d.ts +0 -204
- package/dist/avl-schema-parser-CtJxJ9KU.d.ts +0 -132
- package/dist/avl-zoom-state-CKMVuBFg.d.ts +0 -17
- package/dist/chunk-2QOH2HWM.js +0 -95
- package/dist/chunk-6P3MWXYE.js +0 -440
- package/dist/chunk-B4BU77LT.js +0 -432
- package/dist/chunk-DJ433ET5.js +0 -1327
- package/dist/chunk-DZ42OJQC.js +0 -176
- package/dist/chunk-EOWMARUB.js +0 -16
- package/dist/chunk-FIW6WN23.js +0 -508
- package/dist/chunk-GAR5TQ5B.js +0 -199
- package/dist/chunk-PC7K4SK7.js +0 -1384
- package/dist/chunk-ZO6MXAS3.js +0 -69
- package/dist/kernel-client-ZH4PSMCN.js +0 -367
- package/dist/kernel-wire-B4S8pnP3.d.ts +0 -65
- package/dist/three/index.css +0 -503
- package/dist/three/index.d.ts +0 -1185
- package/dist/three/index.js +0 -3896
- package/dist/useKeyboardRouter-Dsq553Ur.d.ts +0 -42
- package/dist/verificationRegistry-CabxhfTv.d.ts +0 -122
|
@@ -1,14 +1,18 @@
|
|
|
1
|
-
import * as
|
|
2
|
-
import
|
|
1
|
+
import * as React44 from 'react';
|
|
2
|
+
import React44__default, { useRef, useEffect, createContext, useCallback, useMemo, useContext, useState, useId, useSyncExternalStore, useLayoutEffect } from 'react';
|
|
3
3
|
import { clsx } from 'clsx';
|
|
4
4
|
import { extendTailwindMerge } from 'tailwind-merge';
|
|
5
5
|
import { jsxs, Fragment, jsx } from 'react/jsx-runtime';
|
|
6
6
|
import { createLogger } from '@almadar/logger';
|
|
7
|
-
import { isSystemUiEvent, actionTestId, LOADING_STATE_MARKER, matchPath, isRoutePage, matchPathAmong, defaultPage, kernelEvaluator, KernelEvalError, toWireValue } from '@almadar/core';
|
|
8
|
-
export { comparePathSpecificity, matchPath, matchPathAmong } from '@almadar/core';
|
|
9
7
|
import { X, Loader2, HelpCircle, ArrowDownNarrowWide, ArrowUpNarrowWide, Share2, RefreshCw, VolumeX, Volume2, Square, Trash2 } from 'lucide-react';
|
|
10
8
|
import dynamicIconImports from 'lucide-react/dynamicIconImports.mjs';
|
|
9
|
+
import themeToggleEn from '@almadar/std/ui-theme-toggle-locales/en';
|
|
10
|
+
import themeToggleAr from '@almadar/std/ui-theme-toggle-locales/ar';
|
|
11
|
+
import themeToggleSl from '@almadar/std/ui-theme-toggle-locales/sl';
|
|
12
|
+
import { actionTestId, LOADING_STATE_MARKER, matchPath, isRoutePage, matchPathAmong, defaultPage, notFoundPage, kernelEvaluator, KernelEvalError, toWireValue } from '@almadar/core';
|
|
13
|
+
export { comparePathSpecificity, matchPath, matchPathAmong } from '@almadar/core';
|
|
11
14
|
import { useLocation, useNavigate } from 'react-router-dom';
|
|
15
|
+
import patternTileGeometry from '@almadar/core/patterns/pattern-tile-geometry.json';
|
|
12
16
|
|
|
13
17
|
// src/core/lib/theme-scale.ts
|
|
14
18
|
var THEME_SCALE_KEYS = {
|
|
@@ -113,7 +117,7 @@ function applyMorphAnimation(container, animate, duration, delay, easing) {
|
|
|
113
117
|
el.style.opacity = animate ? "1" : "0";
|
|
114
118
|
});
|
|
115
119
|
}
|
|
116
|
-
var AnimatedGraphic =
|
|
120
|
+
var AnimatedGraphic = React44__default.forwardRef(
|
|
117
121
|
({
|
|
118
122
|
src,
|
|
119
123
|
svgContent,
|
|
@@ -136,7 +140,7 @@ var AnimatedGraphic = React43__default.forwardRef(
|
|
|
136
140
|
const fetchedSvg = useFetchedSvg(svgContent ? void 0 : src);
|
|
137
141
|
const resolvedSvg = svgContent ?? fetchedSvg;
|
|
138
142
|
const prevAnimateRef = useRef(animate);
|
|
139
|
-
const setRef =
|
|
143
|
+
const setRef = React44__default.useCallback(
|
|
140
144
|
(node) => {
|
|
141
145
|
containerRef.current = node;
|
|
142
146
|
if (typeof ref === "function") ref(node);
|
|
@@ -395,14 +399,23 @@ function EventBusProvider({ children, isolated = false }) {
|
|
|
395
399
|
return /* @__PURE__ */ jsx(EventBusContext.Provider, { value: contextValue, children });
|
|
396
400
|
}
|
|
397
401
|
|
|
402
|
+
// src/core/lib/band-shapes.json
|
|
403
|
+
var band_shapes_default = {
|
|
404
|
+
wave: "M0 60 C240 100 480 100 720 60 C960 20 1200 20 1440 60 V100 H0 Z",
|
|
405
|
+
arc: "M0 100 Q720 0 1440 100 Z",
|
|
406
|
+
tilt: "M0 100 L1440 0 V100 Z",
|
|
407
|
+
step: "M0 100 V75 H360 V50 H720 V25 H1080 V0 H1440 V100 Z",
|
|
408
|
+
scallop: "M0 100 V40 a60 40 0 0 1 120 0 a60 40 0 0 1 120 0 a60 40 0 0 1 120 0 a60 40 0 0 1 120 0 a60 40 0 0 1 120 0 a60 40 0 0 1 120 0 a60 40 0 0 1 120 0 a60 40 0 0 1 120 0 a60 40 0 0 1 120 0 a60 40 0 0 1 120 0 a60 40 0 0 1 120 0 a60 40 0 0 1 120 0 V100 Z"
|
|
409
|
+
};
|
|
410
|
+
|
|
398
411
|
// src/core/lib/bandShapes.ts
|
|
399
412
|
var shape = (d) => `url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 1440 100' preserveAspectRatio='none'><path d='${d}'/></svg>")`;
|
|
400
413
|
var BAND_SHAPES = {
|
|
401
|
-
wave: shape(
|
|
402
|
-
arc: shape(
|
|
403
|
-
tilt: shape(
|
|
404
|
-
step: shape(
|
|
405
|
-
scallop: shape(
|
|
414
|
+
wave: shape(band_shapes_default.wave),
|
|
415
|
+
arc: shape(band_shapes_default.arc),
|
|
416
|
+
tilt: shape(band_shapes_default.tilt),
|
|
417
|
+
step: shape(band_shapes_default.step),
|
|
418
|
+
scallop: shape(band_shapes_default.scallop)
|
|
406
419
|
};
|
|
407
420
|
var BAND_EDGE_HEIGHT = "clamp(24px, 6vw, 96px)";
|
|
408
421
|
var BAND_ACCENT_FALLBACK = "linear-gradient(180deg, color-mix(in oklab, var(--color-primary) 12%, var(--color-background)), var(--color-background))";
|
|
@@ -1174,7 +1187,7 @@ var positionStyles = {
|
|
|
1174
1187
|
fixed: "fixed",
|
|
1175
1188
|
sticky: "sticky"
|
|
1176
1189
|
};
|
|
1177
|
-
var Box =
|
|
1190
|
+
var Box = React44__default.forwardRef(
|
|
1178
1191
|
({
|
|
1179
1192
|
padding,
|
|
1180
1193
|
paddingX,
|
|
@@ -1266,12 +1279,12 @@ var Box = React43__default.forwardRef(
|
|
|
1266
1279
|
const bandLayers = isBand ? /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
1267
1280
|
backdrop != null && /* @__PURE__ */ jsx(Box, { as: "span", "data-band-layer": "", "aria-hidden": true, className: "band-backdrop", children: backdrop }),
|
|
1268
1281
|
texture && /* @__PURE__ */ jsx(Box, { as: "span", "data-band-layer": "", "aria-hidden": true, className: "band-texture" }),
|
|
1269
|
-
edgeTop !== "none" && /* @__PURE__ */ jsx(Box, { as: "span", "data-band-layer": "", "aria-hidden": true, className: "band-edge band-edge-top",
|
|
1270
|
-
edgeBottom !== "none" && /* @__PURE__ */ jsx(Box, { as: "span", "data-band-layer": "", "aria-hidden": true, className: "band-edge band-edge-bottom",
|
|
1282
|
+
edgeTop !== "none" && /* @__PURE__ */ jsx(Box, { as: "span", "data-band-layer": "", "aria-hidden": true, className: cn("band-edge band-edge-top", `band-edge-shape-${edgeTop}`, `band-edge-color-${edgeColor}`, edgeFlip && "band-edge-flip") }),
|
|
1283
|
+
edgeBottom !== "none" && /* @__PURE__ */ jsx(Box, { as: "span", "data-band-layer": "", "aria-hidden": true, className: cn("band-edge band-edge-bottom", `band-edge-shape-${edgeBottom}`, `band-edge-color-${edgeColor}`, edgeFlip && "band-edge-flip") })
|
|
1271
1284
|
] }) : null;
|
|
1272
1285
|
const isClickable = action || onClick;
|
|
1273
1286
|
const actionControl = action && rest.role === void 0 && rest.tabIndex === void 0 ? pressableProps(handleClick) : {};
|
|
1274
|
-
return
|
|
1287
|
+
return React44__default.createElement(
|
|
1275
1288
|
Component,
|
|
1276
1289
|
{
|
|
1277
1290
|
ref: setRef,
|
|
@@ -1414,7 +1427,7 @@ function getTraitPresence() {
|
|
|
1414
1427
|
}
|
|
1415
1428
|
function presenceGroup(traitIndex, traitName) {
|
|
1416
1429
|
const entry = traitIndex.byName.get(traitName);
|
|
1417
|
-
if (entry === void 0 || !entry.
|
|
1430
|
+
if (entry === void 0 || !entry.shared) return [traitName];
|
|
1418
1431
|
return [...traitIndex.byName].filter(([, e]) => e.frameKey === entry.frameKey).map(([name]) => name);
|
|
1419
1432
|
}
|
|
1420
1433
|
var EMPTY_CHAIN = Object.freeze([]);
|
|
@@ -1539,7 +1552,7 @@ function useEventBus() {
|
|
|
1539
1552
|
return {
|
|
1540
1553
|
...baseBus,
|
|
1541
1554
|
emit: (type, payload, source) => {
|
|
1542
|
-
if (typeof type === "string" && type.startsWith("UI:") && !type.slice(3).includes(".") && !
|
|
1555
|
+
if (typeof type === "string" && type.startsWith("UI:") && !type.slice(3).includes(".") && !source?.trait) {
|
|
1543
1556
|
scopeLog.warn("emit:bare-key-no-scope", { type });
|
|
1544
1557
|
}
|
|
1545
1558
|
baseBus.emit(type, payload, source);
|
|
@@ -1549,7 +1562,7 @@ function useEventBus() {
|
|
|
1549
1562
|
return {
|
|
1550
1563
|
...baseBus,
|
|
1551
1564
|
emit: (type, payload, source) => {
|
|
1552
|
-
if (typeof type === "string" && type.startsWith("UI:")
|
|
1565
|
+
if (typeof type === "string" && type.startsWith("UI:")) {
|
|
1553
1566
|
const tail = type.slice(3);
|
|
1554
1567
|
const isQualified = tail.includes(".");
|
|
1555
1568
|
const event = isQualified ? tail.split(".").slice(2).join(".") : tail;
|
|
@@ -1631,7 +1644,7 @@ var animatedStyles = {
|
|
|
1631
1644
|
"scale-up": { opacity: 1, transform: "scale(1) translateY(0)" },
|
|
1632
1645
|
"none": {}
|
|
1633
1646
|
};
|
|
1634
|
-
var AnimatedReveal =
|
|
1647
|
+
var AnimatedReveal = React44__default.forwardRef(
|
|
1635
1648
|
({
|
|
1636
1649
|
trigger = "scroll",
|
|
1637
1650
|
animation = "fade-up",
|
|
@@ -1761,7 +1774,7 @@ var AnimatedReveal = React43__default.forwardRef(
|
|
|
1761
1774
|
}
|
|
1762
1775
|
);
|
|
1763
1776
|
AnimatedReveal.displayName = "AnimatedReveal";
|
|
1764
|
-
var Aside =
|
|
1777
|
+
var Aside = React44__default.forwardRef(
|
|
1765
1778
|
({ className, children, ...rest }, ref) => /* @__PURE__ */ jsx("aside", { ref, className: cn(className), ...rest, children })
|
|
1766
1779
|
);
|
|
1767
1780
|
Aside.displayName = "Aside";
|
|
@@ -1843,7 +1856,7 @@ function blit(ctx, src, dx, dy, dw, dh) {
|
|
|
1843
1856
|
}
|
|
1844
1857
|
var sliceDataUrlCache = /* @__PURE__ */ new Map();
|
|
1845
1858
|
function useAtlasSliceDataUrl(asset) {
|
|
1846
|
-
const [, bump] =
|
|
1859
|
+
const [, bump] = React44.useReducer((x) => x + 1, 0);
|
|
1847
1860
|
if (!isAtlasAsset(asset)) return void 0;
|
|
1848
1861
|
const key = `${asset.atlas}#${asset.sprite}`;
|
|
1849
1862
|
const cached = sliceDataUrlCache.get(key);
|
|
@@ -1910,13 +1923,13 @@ function AtlasImage({
|
|
|
1910
1923
|
"aria-hidden": ariaHidden,
|
|
1911
1924
|
...rest
|
|
1912
1925
|
}) {
|
|
1913
|
-
const [, bump] =
|
|
1914
|
-
const canvasRef =
|
|
1926
|
+
const [, bump] = React44.useReducer((x) => x + 1, 0);
|
|
1927
|
+
const canvasRef = React44.useRef(null);
|
|
1915
1928
|
const sliced = isAtlasAsset(asset);
|
|
1916
1929
|
const atlas = sliced ? getAtlas(asset.atlas, bump) : void 0;
|
|
1917
1930
|
const img = sliced && asset?.url ? getSheetImage(asset.url, bump) : null;
|
|
1918
1931
|
const rect = sliced && atlas ? subRectFor(atlas, asset.sprite) : null;
|
|
1919
|
-
|
|
1932
|
+
React44.useEffect(() => {
|
|
1920
1933
|
const canvas = canvasRef.current;
|
|
1921
1934
|
if (!canvas || !img || !rect) return;
|
|
1922
1935
|
canvas.width = rect.sw;
|
|
@@ -2017,9 +2030,9 @@ function load(key) {
|
|
|
2017
2030
|
}
|
|
2018
2031
|
var adapters = /* @__PURE__ */ new Map();
|
|
2019
2032
|
function makeLazyIcon(key) {
|
|
2020
|
-
const LazyIcon =
|
|
2021
|
-
const [Icon2, setIcon] =
|
|
2022
|
-
|
|
2033
|
+
const LazyIcon = React44__default.forwardRef((props, ref) => {
|
|
2034
|
+
const [Icon2, setIcon] = React44__default.useState(() => loaded.get(key));
|
|
2035
|
+
React44__default.useEffect(() => {
|
|
2023
2036
|
if (Icon2 !== void 0) return void 0;
|
|
2024
2037
|
let live = true;
|
|
2025
2038
|
void load(key).then((component) => {
|
|
@@ -2154,7 +2167,7 @@ function useIconFamily() {
|
|
|
2154
2167
|
var resolveLucide = resolveLucideByName;
|
|
2155
2168
|
function makeLucideAdapter(name) {
|
|
2156
2169
|
const LucideComp = resolveLucide(name);
|
|
2157
|
-
const Adapter =
|
|
2170
|
+
const Adapter = React44__default.forwardRef((props, ref) => /* @__PURE__ */ jsx(
|
|
2158
2171
|
LucideComp,
|
|
2159
2172
|
{
|
|
2160
2173
|
ref,
|
|
@@ -2223,9 +2236,9 @@ var Icon = ({
|
|
|
2223
2236
|
const effectiveName = typeof icon === "string" && icon !== "" ? icon : name;
|
|
2224
2237
|
const effectiveStrokeWidth = strokeWidth != null && strokeWidth > 0 ? strokeWidth : void 0;
|
|
2225
2238
|
const family = useIconFamily();
|
|
2226
|
-
const svgRef =
|
|
2239
|
+
const svgRef = React44__default.useRef(null);
|
|
2227
2240
|
const themeStroke = useThemeIconStrokeApplies(svgRef);
|
|
2228
|
-
const RenderedComponent =
|
|
2241
|
+
const RenderedComponent = React44__default.useMemo(() => {
|
|
2229
2242
|
if (directIcon) return null;
|
|
2230
2243
|
return effectiveName ? resolveIconForFamily(effectiveName) : null;
|
|
2231
2244
|
}, [directIcon, effectiveName, family]);
|
|
@@ -2395,6 +2408,9 @@ var en_default = {
|
|
|
2395
2408
|
"aria.closeToast": "Dismiss toast",
|
|
2396
2409
|
"aria.closeAlert": "Dismiss alert",
|
|
2397
2410
|
"aria.removeFilter": "Remove filter",
|
|
2411
|
+
"aria.chart": "Chart",
|
|
2412
|
+
"aria.graph": "Graph",
|
|
2413
|
+
"aria.pageNavigation": "Page navigation",
|
|
2398
2414
|
"aria.closeDrawer": "Close drawer",
|
|
2399
2415
|
"aria.closePanel": "Close panel",
|
|
2400
2416
|
"aria.dockPanel": "Side panel",
|
|
@@ -2609,6 +2625,15 @@ var en_default = {
|
|
|
2609
2625
|
"docSearch.placeholder": "Search documentation...",
|
|
2610
2626
|
"stateMachine.loading": "Loading state machine\u2026",
|
|
2611
2627
|
"stateMachine.noStateMachine": "No state machine to visualize",
|
|
2628
|
+
"stateMachine.background": "Runs in the background",
|
|
2629
|
+
"stateMachine.linked": "Other orbitals this page talks to",
|
|
2630
|
+
"stateMachine.guarded": "Guarded: it runs only when its condition holds",
|
|
2631
|
+
"stateMachine.selfEvents": "{{state}}: {{count}} events that stay in this state",
|
|
2632
|
+
"stateMachine.boxLabel": "{{trait}}: {{state}} ({{count}} states)",
|
|
2633
|
+
"stateMachine.boxLabelIdle": "{{trait}} ({{count}} states)",
|
|
2634
|
+
"stateMachine.wireLabel": "{{from}} sends {{event}} to {{to}}",
|
|
2635
|
+
"stateMachine.expand": "Open {{trait}} in place",
|
|
2636
|
+
"stateMachine.collapse": "Close {{trait}}",
|
|
2612
2637
|
"avl.trigger": "Trigger",
|
|
2613
2638
|
"avl.guard": "Guard",
|
|
2614
2639
|
"avl.effects": "Effects",
|
|
@@ -2626,6 +2651,8 @@ var en_default = {
|
|
|
2626
2651
|
"avl.noTraitData": "No trait data",
|
|
2627
2652
|
"avl.computingLayout": "Computing layout...",
|
|
2628
2653
|
"avl.noStateMachine": "No state machine",
|
|
2654
|
+
"avl.layoutFailed": "The state machine layout failed to load.",
|
|
2655
|
+
"avl.pendingSourceState": "Transition source selected",
|
|
2629
2656
|
"avl.listensFor": "listens for {{event}}",
|
|
2630
2657
|
"avl.emits": "emits {{event}}",
|
|
2631
2658
|
"avl.pageLayout": "Page Layout",
|
|
@@ -3188,6 +3215,7 @@ var en_default = {
|
|
|
3188
3215
|
"gridPicker.all": "All",
|
|
3189
3216
|
"gridPicker.moreRefine": "+{{count}} more \u2014 refine your search",
|
|
3190
3217
|
"graphCanvas.noNodes": "No nodes to display.",
|
|
3218
|
+
"graphCanvas.selectedNode": "Selected: {{label}}",
|
|
3191
3219
|
"codeBlock.noCode": "No code to display.",
|
|
3192
3220
|
"codeBlock.region": "Code",
|
|
3193
3221
|
"fab.action": "Action",
|
|
@@ -3230,10 +3258,6 @@ var en_default = {
|
|
|
3230
3258
|
"videoEmbed.notFound": "The video was not found or is private",
|
|
3231
3259
|
"videoEmbed.notEmbeddable": "The video's owner does not allow it to be embedded",
|
|
3232
3260
|
"videoEmbed.noVideo": "No video selected",
|
|
3233
|
-
"themeToggle.switchToLight": "Switch to light mode",
|
|
3234
|
-
"themeToggle.switchToDark": "Switch to dark mode",
|
|
3235
|
-
"themeToggle.light": "Light",
|
|
3236
|
-
"themeToggle.dark": "Dark",
|
|
3237
3261
|
"avatar.alt": "Avatar",
|
|
3238
3262
|
"avatar.status": "Status: {{status}}",
|
|
3239
3263
|
"avatar.status.online": "online",
|
|
@@ -3541,7 +3565,9 @@ var en_default = {
|
|
|
3541
3565
|
"debug.replayForward": "Next hop",
|
|
3542
3566
|
"debug.replayPlay": "Play",
|
|
3543
3567
|
"debug.replayPause": "Pause",
|
|
3544
|
-
"debug.replayStep": "{{step}} / {{total}}"
|
|
3568
|
+
"debug.replayStep": "{{step}} / {{total}}",
|
|
3569
|
+
"stateMachine.inspect": "Inspect: pick a trait on the page",
|
|
3570
|
+
"stateMachine.inspectHint": "Click a part of the page \xB7 Esc to stop"
|
|
3545
3571
|
};
|
|
3546
3572
|
|
|
3547
3573
|
// src/core/lib/format.ts
|
|
@@ -3762,6 +3788,9 @@ var ar_default = {
|
|
|
3762
3788
|
"aria.closeToast": "\u0625\u063A\u0644\u0627\u0642 \u0627\u0644\u062A\u0646\u0628\u064A\u0647",
|
|
3763
3789
|
"aria.closeAlert": "\u0625\u063A\u0644\u0627\u0642 \u0627\u0644\u062A\u0646\u0628\u064A\u0647",
|
|
3764
3790
|
"aria.removeFilter": "\u0625\u0632\u0627\u0644\u0629 \u0627\u0644\u0641\u0644\u062A\u0631",
|
|
3791
|
+
"aria.chart": "\u0645\u062E\u0637\u0637",
|
|
3792
|
+
"aria.graph": "\u0645\u062E\u0637\u0637 \u0634\u0628\u0643\u064A",
|
|
3793
|
+
"aria.pageNavigation": "\u0627\u0644\u062A\u0646\u0642\u0644 \u0628\u064A\u0646 \u0627\u0644\u0635\u0641\u062D\u0627\u062A",
|
|
3765
3794
|
"aria.closeDrawer": "\u0625\u063A\u0644\u0627\u0642 \u0627\u0644\u0644\u0648\u062D\u0629",
|
|
3766
3795
|
"aria.closePanel": "\u0625\u063A\u0644\u0627\u0642 \u0627\u0644\u0644\u0648\u062D\u0629",
|
|
3767
3796
|
"aria.dockPanel": "\u0627\u0644\u0644\u0648\u062D\u0629 \u0627\u0644\u062C\u0627\u0646\u0628\u064A\u0629",
|
|
@@ -3976,6 +4005,15 @@ var ar_default = {
|
|
|
3976
4005
|
"docSearch.placeholder": "\u0627\u0644\u0628\u062D\u062B \u0641\u064A \u0627\u0644\u0648\u062B\u0627\u0626\u0642...",
|
|
3977
4006
|
"stateMachine.loading": "\u062C\u0627\u0631\u064D \u062A\u062D\u0645\u064A\u0644 \u0622\u0644\u0629 \u0627\u0644\u062D\u0627\u0644\u0629\u2026",
|
|
3978
4007
|
"stateMachine.noStateMachine": "\u0644\u0627 \u062A\u0648\u062C\u062F \u0622\u0644\u0629 \u062D\u0627\u0644\u0629 \u0644\u0639\u0631\u0636\u0647\u0627",
|
|
4008
|
+
"stateMachine.background": "\u064A\u0639\u0645\u0644 \u0641\u064A \u0627\u0644\u062E\u0644\u0641\u064A\u0629",
|
|
4009
|
+
"stateMachine.linked": "\u0645\u062F\u0627\u0631\u0627\u062A \u0623\u062E\u0631\u0649 \u062A\u062A\u062D\u062F\u062B \u0645\u0639\u0647\u0627 \u0647\u0630\u0647 \u0627\u0644\u0635\u0641\u062D\u0629",
|
|
4010
|
+
"stateMachine.guarded": "\u0645\u062D\u0631\u0648\u0633: \u064A\u0639\u0645\u0644 \u0641\u0642\u0637 \u0639\u0646\u062F\u0645\u0627 \u064A\u062A\u062D\u0642\u0642 \u0634\u0631\u0637\u0647",
|
|
4011
|
+
"stateMachine.selfEvents": "{{state}}: {{count}} \u0623\u062D\u062F\u0627\u062B \u062A\u0628\u0642\u0649 \u0641\u064A \u0647\u0630\u0647 \u0627\u0644\u062D\u0627\u0644\u0629",
|
|
4012
|
+
"stateMachine.boxLabel": "{{trait}}: {{state}} ({{count}} \u062D\u0627\u0644\u0627\u062A)",
|
|
4013
|
+
"stateMachine.boxLabelIdle": "{{trait}} ({{count}} \u062D\u0627\u0644\u0627\u062A)",
|
|
4014
|
+
"stateMachine.wireLabel": "{{from}} \u064A\u0631\u0633\u0644 {{event}} \u0625\u0644\u0649 {{to}}",
|
|
4015
|
+
"stateMachine.expand": "\u0627\u0641\u062A\u062D {{trait}} \u0641\u064A \u0645\u0643\u0627\u0646\u0647",
|
|
4016
|
+
"stateMachine.collapse": "\u0623\u063A\u0644\u0642 {{trait}}",
|
|
3979
4017
|
"avl.trigger": "\u0627\u0644\u0645\u064F\u0634\u063A\u0650\u0651\u0644",
|
|
3980
4018
|
"avl.guard": "\u0627\u0644\u062D\u0627\u0631\u0633",
|
|
3981
4019
|
"avl.effects": "\u0627\u0644\u062A\u0623\u062B\u064A\u0631\u0627\u062A",
|
|
@@ -3993,6 +4031,8 @@ var ar_default = {
|
|
|
3993
4031
|
"avl.noTraitData": "\u0644\u0627 \u062A\u0648\u062C\u062F \u0628\u064A\u0627\u0646\u0627\u062A \u0633\u0645\u0629",
|
|
3994
4032
|
"avl.computingLayout": "\u062C\u0627\u0631\u064D \u062D\u0633\u0627\u0628 \u0627\u0644\u062A\u062E\u0637\u064A\u0637...",
|
|
3995
4033
|
"avl.noStateMachine": "\u0644\u0627 \u062A\u0648\u062C\u062F \u0622\u0644\u0629 \u062D\u0627\u0644\u0627\u062A",
|
|
4034
|
+
"avl.layoutFailed": "\u062A\u0639\u0630\u0651\u0631 \u062A\u062D\u0645\u064A\u0644 \u062A\u062E\u0637\u064A\u0637 \u0622\u0644\u0629 \u0627\u0644\u062D\u0627\u0644\u0627\u062A.",
|
|
4035
|
+
"avl.pendingSourceState": "\u062A\u0645 \u062A\u062D\u062F\u064A\u062F \u0645\u0635\u062F\u0631 \u0627\u0644\u0627\u0646\u062A\u0642\u0627\u0644",
|
|
3996
4036
|
"avl.listensFor": "\u064A\u0633\u062A\u0645\u0639 \u0625\u0644\u0649 {{event}}",
|
|
3997
4037
|
"avl.emits": "\u064A\u064F\u0635\u062F\u0631 {{event}}",
|
|
3998
4038
|
"avl.pageLayout": "\u062A\u062E\u0637\u064A\u0637 \u0627\u0644\u0635\u0641\u062D\u0629",
|
|
@@ -4559,6 +4599,7 @@ var ar_default = {
|
|
|
4559
4599
|
"gridPicker.all": "\u0627\u0644\u0643\u0644",
|
|
4560
4600
|
"gridPicker.moreRefine": "+{{count}} \u0623\u062E\u0631\u0649 \u2014 \u062F\u0642\u0651\u0642 \u0628\u062D\u062B\u0643",
|
|
4561
4601
|
"graphCanvas.noNodes": "\u0644\u0627 \u062A\u0648\u062C\u062F \u0639\u0642\u062F \u0644\u0639\u0631\u0636\u0647\u0627.",
|
|
4602
|
+
"graphCanvas.selectedNode": "\u0627\u0644\u0645\u062D\u062F\u062F: {{label}}",
|
|
4562
4603
|
"codeBlock.noCode": "\u0644\u0627 \u064A\u0648\u062C\u062F \u0643\u0648\u062F \u0644\u0639\u0631\u0636\u0647.",
|
|
4563
4604
|
"codeBlock.region": "\u0627\u0644\u0634\u064A\u0641\u0631\u0629 \u0627\u0644\u0628\u0631\u0645\u062C\u064A\u0629",
|
|
4564
4605
|
"fab.action": "\u0625\u062C\u0631\u0627\u0621",
|
|
@@ -4601,10 +4642,6 @@ var ar_default = {
|
|
|
4601
4642
|
"videoEmbed.notFound": "\u0644\u0645 \u064A\u062A\u0645 \u0627\u0644\u0639\u062B\u0648\u0631 \u0639\u0644\u0649 \u0627\u0644\u0641\u064A\u062F\u064A\u0648 \u0623\u0648 \u0623\u0646\u0647 \u062E\u0627\u0635",
|
|
4602
4643
|
"videoEmbed.notEmbeddable": "\u0645\u0627\u0644\u0643 \u0627\u0644\u0641\u064A\u062F\u064A\u0648 \u0644\u0627 \u064A\u0633\u0645\u062D \u0628\u062A\u0636\u0645\u064A\u0646\u0647",
|
|
4603
4644
|
"videoEmbed.noVideo": "\u0644\u0645 \u064A\u062A\u0645 \u0627\u062E\u062A\u064A\u0627\u0631 \u0641\u064A\u062F\u064A\u0648",
|
|
4604
|
-
"themeToggle.switchToLight": "\u0627\u0644\u062A\u0628\u062F\u064A\u0644 \u0625\u0644\u0649 \u0627\u0644\u0648\u0636\u0639 \u0627\u0644\u0641\u0627\u062A\u062D",
|
|
4605
|
-
"themeToggle.switchToDark": "\u0627\u0644\u062A\u0628\u062F\u064A\u0644 \u0625\u0644\u0649 \u0627\u0644\u0648\u0636\u0639 \u0627\u0644\u062F\u0627\u0643\u0646",
|
|
4606
|
-
"themeToggle.light": "\u0641\u0627\u062A\u062D",
|
|
4607
|
-
"themeToggle.dark": "\u062F\u0627\u0643\u0646",
|
|
4608
4645
|
"avatar.alt": "\u0627\u0644\u0635\u0648\u0631\u0629 \u0627\u0644\u0631\u0645\u0632\u064A\u0629",
|
|
4609
4646
|
"avatar.status": "\u0627\u0644\u062D\u0627\u0644\u0629: {{status}}",
|
|
4610
4647
|
"avatar.status.online": "\u0645\u062A\u0635\u0644",
|
|
@@ -4912,7 +4949,9 @@ var ar_default = {
|
|
|
4912
4949
|
"debug.replayForward": "\u0627\u0644\u062E\u0637\u0648\u0629 \u0627\u0644\u062A\u0627\u0644\u064A\u0629",
|
|
4913
4950
|
"debug.replayPlay": "\u062A\u0634\u063A\u064A\u0644",
|
|
4914
4951
|
"debug.replayPause": "\u0625\u064A\u0642\u0627\u0641 \u0645\u0624\u0642\u062A",
|
|
4915
|
-
"debug.replayStep": "{{step}} / {{total}}"
|
|
4952
|
+
"debug.replayStep": "{{step}} / {{total}}",
|
|
4953
|
+
"stateMachine.inspect": "\u0641\u062D\u0635: \u0627\u062E\u062A\u0631 \u0633\u0645\u0629 \u0645\u0646 \u0627\u0644\u0635\u0641\u062D\u0629",
|
|
4954
|
+
"stateMachine.inspectHint": "\u0627\u0646\u0642\u0631 \u062C\u0632\u0621\u064B\u0627 \u0645\u0646 \u0627\u0644\u0635\u0641\u062D\u0629 \xB7 Esc \u0644\u0644\u0625\u064A\u0642\u0627\u0641"
|
|
4916
4955
|
};
|
|
4917
4956
|
|
|
4918
4957
|
// src/core/locales/sl.json
|
|
@@ -5027,6 +5066,9 @@ var sl_default = {
|
|
|
5027
5066
|
"aria.closeToast": "Zapri obvestilo",
|
|
5028
5067
|
"aria.closeAlert": "Zapri opozorilo",
|
|
5029
5068
|
"aria.removeFilter": "Odstrani filter",
|
|
5069
|
+
"aria.chart": "Grafikon",
|
|
5070
|
+
"aria.graph": "Graf",
|
|
5071
|
+
"aria.pageNavigation": "Krmarjenje po straneh",
|
|
5030
5072
|
"aria.closeDrawer": "Zapri predal",
|
|
5031
5073
|
"aria.closePanel": "Zapri plo\u0161\u010Do",
|
|
5032
5074
|
"aria.dockPanel": "Stranska plo\u0161\u010Da",
|
|
@@ -5241,6 +5283,15 @@ var sl_default = {
|
|
|
5241
5283
|
"docSearch.placeholder": "Iskanje po dokumentaciji...",
|
|
5242
5284
|
"stateMachine.loading": "Nalaganje stanjskega stroja\u2026",
|
|
5243
5285
|
"stateMachine.noStateMachine": "Ni stanjskega stroja za prikaz",
|
|
5286
|
+
"stateMachine.background": "Te\u010De v ozadju",
|
|
5287
|
+
"stateMachine.linked": "Druge orbitale, s katerimi ta stran govori",
|
|
5288
|
+
"stateMachine.guarded": "Za\u0161\u010Diteno: te\u010De le, ko velja njegov pogoj",
|
|
5289
|
+
"stateMachine.selfEvents": "{{state}}: {{count}} dogodkov, ki ostanejo v tem stanju",
|
|
5290
|
+
"stateMachine.boxLabel": "{{trait}}: {{state}} (stanj: {{count}})",
|
|
5291
|
+
"stateMachine.boxLabelIdle": "{{trait}} (stanj: {{count}})",
|
|
5292
|
+
"stateMachine.wireLabel": "{{from}} po\u0161lje {{event}} k {{to}}",
|
|
5293
|
+
"stateMachine.expand": "Odpri {{trait}} na mestu",
|
|
5294
|
+
"stateMachine.collapse": "Zapri {{trait}}",
|
|
5244
5295
|
"avl.trigger": "Spro\u017Eilec",
|
|
5245
5296
|
"avl.guard": "Varovalo",
|
|
5246
5297
|
"avl.effects": "U\u010Dinki",
|
|
@@ -5258,6 +5309,8 @@ var sl_default = {
|
|
|
5258
5309
|
"avl.noTraitData": "Ni podatkov o lastnosti vedenja",
|
|
5259
5310
|
"avl.computingLayout": "Ra\u010Dunanje postavitve ...",
|
|
5260
5311
|
"avl.noStateMachine": "Ni stanjskega stroja",
|
|
5312
|
+
"avl.layoutFailed": "Postavitve stanjskega stroja ni bilo mogo\u010De nalo\u017Eiti.",
|
|
5313
|
+
"avl.pendingSourceState": "Izbran vir prehoda",
|
|
5261
5314
|
"avl.listensFor": "poslu\u0161a za {{event}}",
|
|
5262
5315
|
"avl.emits": "oddaja {{event}}",
|
|
5263
5316
|
"avl.pageLayout": "Postavitev strani",
|
|
@@ -5824,6 +5877,7 @@ var sl_default = {
|
|
|
5824
5877
|
"gridPicker.all": "Vse",
|
|
5825
5878
|
"gridPicker.moreRefine": "+\u0161e {{count}} \u2014 zo\u017Eite iskanje",
|
|
5826
5879
|
"graphCanvas.noNodes": "Ni vozli\u0161\u010D za prikaz.",
|
|
5880
|
+
"graphCanvas.selectedNode": "Izbrano: {{label}}",
|
|
5827
5881
|
"codeBlock.noCode": "Ni kode za prikaz.",
|
|
5828
5882
|
"codeBlock.region": "Koda",
|
|
5829
5883
|
"fab.action": "Dejanje",
|
|
@@ -5866,10 +5920,6 @@ var sl_default = {
|
|
|
5866
5920
|
"videoEmbed.notFound": "Video ni bil najden ali je zaseben",
|
|
5867
5921
|
"videoEmbed.notEmbeddable": "Lastnik videa ne dovoli vdelave",
|
|
5868
5922
|
"videoEmbed.noVideo": "Video ni izbran",
|
|
5869
|
-
"themeToggle.switchToLight": "Preklopi na svetli na\u010Din",
|
|
5870
|
-
"themeToggle.switchToDark": "Preklopi na temni na\u010Din",
|
|
5871
|
-
"themeToggle.light": "Svetlo",
|
|
5872
|
-
"themeToggle.dark": "Temno",
|
|
5873
5923
|
"avatar.alt": "Avatar",
|
|
5874
5924
|
"avatar.status": "Stanje: {{status}}",
|
|
5875
5925
|
"avatar.status.online": "na spletu",
|
|
@@ -6177,15 +6227,23 @@ var sl_default = {
|
|
|
6177
6227
|
"debug.replayForward": "Naslednji korak",
|
|
6178
6228
|
"debug.replayPlay": "Predvajaj",
|
|
6179
6229
|
"debug.replayPause": "Premor",
|
|
6180
|
-
"debug.replayStep": "{{step}} / {{total}}"
|
|
6230
|
+
"debug.replayStep": "{{step}} / {{total}}",
|
|
6231
|
+
"stateMachine.inspect": "Pregled: izberi lastnost na strani",
|
|
6232
|
+
"stateMachine.inspectHint": "Klikni del strani \xB7 Esc za konec"
|
|
6181
6233
|
};
|
|
6182
|
-
|
|
6183
|
-
// src/core/hooks/useTranslate.ts
|
|
6184
6234
|
var { $meta: _meta2, ...coreMessages2 } = en_default;
|
|
6185
|
-
var
|
|
6235
|
+
var withThemeToggle = (messages, labels) => ({
|
|
6236
|
+
...messages,
|
|
6237
|
+
...Object.fromEntries(Object.entries(labels).map(([key, value]) => [`themeToggle.${key}`, value]))
|
|
6238
|
+
});
|
|
6239
|
+
var coreLocale2 = withThemeToggle(coreMessages2, themeToggleEn);
|
|
6186
6240
|
var { $meta: _arMeta, ...arMessages } = ar_default;
|
|
6187
6241
|
var { $meta: _slMeta, ...slMessages } = sl_default;
|
|
6188
|
-
var uiLocales = {
|
|
6242
|
+
var uiLocales = {
|
|
6243
|
+
en: coreLocale2,
|
|
6244
|
+
ar: withThemeToggle(arMessages, themeToggleAr),
|
|
6245
|
+
sl: withThemeToggle(slMessages, themeToggleSl)
|
|
6246
|
+
};
|
|
6189
6247
|
var I18nContext = createContext({
|
|
6190
6248
|
locale: "en",
|
|
6191
6249
|
direction: "ltr",
|
|
@@ -6206,7 +6264,7 @@ function I18nProvider({ value, children, documentRoot }) {
|
|
|
6206
6264
|
document.documentElement.lang = value.locale;
|
|
6207
6265
|
document.documentElement.dir = value.direction;
|
|
6208
6266
|
}, [documentRoot, value.locale, value.direction]);
|
|
6209
|
-
return
|
|
6267
|
+
return React44__default.createElement(I18nContext.Provider, { value }, children);
|
|
6210
6268
|
}
|
|
6211
6269
|
function useTranslate() {
|
|
6212
6270
|
return useContext(I18nContext);
|
|
@@ -6292,8 +6350,8 @@ var Avatar = ({
|
|
|
6292
6350
|
}) => {
|
|
6293
6351
|
const eventBus = useEventBus();
|
|
6294
6352
|
const { t } = useTranslate();
|
|
6295
|
-
const [imgFailed, setImgFailed] =
|
|
6296
|
-
|
|
6353
|
+
const [imgFailed, setImgFailed] = React44__default.useState(false);
|
|
6354
|
+
React44__default.useEffect(() => {
|
|
6297
6355
|
setImgFailed(false);
|
|
6298
6356
|
}, [src]);
|
|
6299
6357
|
const initials = providedInitials ?? (name ? generateInitials(name) : void 0);
|
|
@@ -6428,7 +6486,7 @@ var sizeStyles = {
|
|
|
6428
6486
|
md: "px-2.5 py-1 text-sm",
|
|
6429
6487
|
lg: "px-3 py-1.5 text-base"
|
|
6430
6488
|
};
|
|
6431
|
-
var Badge =
|
|
6489
|
+
var Badge = React44__default.forwardRef(
|
|
6432
6490
|
({ className, variant = "default", size = "sm", amount, label, icon, iconAsset, children, onRemove, removeLabel, onClick, ...props }, ref) => {
|
|
6433
6491
|
const { t } = useTranslate();
|
|
6434
6492
|
const iconSizes3 = {
|
|
@@ -6706,7 +6764,8 @@ function NavigationProvider({
|
|
|
6706
6764
|
}, [schema, initialPage]);
|
|
6707
6765
|
const [state, setState] = useState(initialState);
|
|
6708
6766
|
const navigateTo = useCallback((path, payload) => {
|
|
6709
|
-
const
|
|
6767
|
+
const missing = notFoundPage(schema);
|
|
6768
|
+
const result = findPageByPath(schema, path) ?? (missing ? { page: missing.page, params: {}, orbitalName: missing.orbitalName } : null);
|
|
6710
6769
|
if (!result) {
|
|
6711
6770
|
log3.error("No page found for path", { path });
|
|
6712
6771
|
return;
|
|
@@ -7021,14 +7080,6 @@ var NavStackRouterBridge = ({
|
|
|
7021
7080
|
},
|
|
7022
7081
|
[routerNavigate]
|
|
7023
7082
|
);
|
|
7024
|
-
const eventBus = useEventBus();
|
|
7025
|
-
useEffect(
|
|
7026
|
-
() => eventBus.on("UI:NAVIGATE", (event) => {
|
|
7027
|
-
const url = event.payload?.url;
|
|
7028
|
-
if (typeof url === "string" && url.length > 0) routerNavigate(url);
|
|
7029
|
-
}),
|
|
7030
|
-
[eventBus, routerNavigate]
|
|
7031
|
-
);
|
|
7032
7083
|
return /* @__PURE__ */ jsx(
|
|
7033
7084
|
NavStackProvider,
|
|
7034
7085
|
{
|
|
@@ -7135,7 +7186,7 @@ function resolveIconProp(value, sizeClass) {
|
|
|
7135
7186
|
const IconComp = value;
|
|
7136
7187
|
return /* @__PURE__ */ jsx(IconComp, { className: sizeClass });
|
|
7137
7188
|
}
|
|
7138
|
-
if (
|
|
7189
|
+
if (React44__default.isValidElement(value)) {
|
|
7139
7190
|
return value;
|
|
7140
7191
|
}
|
|
7141
7192
|
if (typeof value === "object" && value !== null && isIconLike(value)) {
|
|
@@ -7144,13 +7195,15 @@ function resolveIconProp(value, sizeClass) {
|
|
|
7144
7195
|
}
|
|
7145
7196
|
return value;
|
|
7146
7197
|
}
|
|
7147
|
-
var Button =
|
|
7198
|
+
var Button = React44__default.forwardRef(
|
|
7148
7199
|
({
|
|
7149
7200
|
className,
|
|
7150
7201
|
variant = "primary",
|
|
7151
7202
|
size = "md",
|
|
7152
7203
|
isLoading = false,
|
|
7153
7204
|
disabled,
|
|
7205
|
+
htmlType,
|
|
7206
|
+
type: nativeType,
|
|
7154
7207
|
leftIcon,
|
|
7155
7208
|
rightIcon,
|
|
7156
7209
|
icon: iconProp,
|
|
@@ -7171,7 +7224,7 @@ var Button = React43__default.forwardRef(
|
|
|
7171
7224
|
const navStack = useNavStack();
|
|
7172
7225
|
const { pending: pending2, activate } = usePendingAction();
|
|
7173
7226
|
const busy = isLoading || pending2;
|
|
7174
|
-
const [focused, setFocused] =
|
|
7227
|
+
const [focused, setFocused] = React44__default.useState(false);
|
|
7175
7228
|
const inert = Boolean(disabled) || busy;
|
|
7176
7229
|
const emitAction = () => {
|
|
7177
7230
|
if (!action) return;
|
|
@@ -7258,7 +7311,7 @@ var Button = React43__default.forwardRef(
|
|
|
7258
7311
|
"button",
|
|
7259
7312
|
{
|
|
7260
7313
|
ref,
|
|
7261
|
-
type: "button",
|
|
7314
|
+
type: htmlType ?? nativeType ?? "button",
|
|
7262
7315
|
disabled: Boolean(disabled) && !focused,
|
|
7263
7316
|
"aria-disabled": inert || void 0,
|
|
7264
7317
|
"aria-busy": busy || void 0,
|
|
@@ -7274,12 +7327,12 @@ var Button = React43__default.forwardRef(
|
|
|
7274
7327
|
}
|
|
7275
7328
|
);
|
|
7276
7329
|
Button.displayName = "Button";
|
|
7277
|
-
var SurfaceContext =
|
|
7330
|
+
var SurfaceContext = React44__default.createContext(false);
|
|
7278
7331
|
function SurfaceBoundary({ children }) {
|
|
7279
7332
|
return /* @__PURE__ */ jsx(SurfaceContext.Provider, { value: true, children });
|
|
7280
7333
|
}
|
|
7281
7334
|
function useContentSurface(surface = "auto") {
|
|
7282
|
-
const onSurface =
|
|
7335
|
+
const onSurface = React44__default.useContext(SurfaceContext);
|
|
7283
7336
|
const paints = surface === "auto" && !onSurface;
|
|
7284
7337
|
return {
|
|
7285
7338
|
className: paints ? "surface-content" : void 0,
|
|
@@ -7287,7 +7340,7 @@ function useContentSurface(surface = "auto") {
|
|
|
7287
7340
|
};
|
|
7288
7341
|
}
|
|
7289
7342
|
function useOnSurface() {
|
|
7290
|
-
return
|
|
7343
|
+
return React44__default.useContext(SurfaceContext);
|
|
7291
7344
|
}
|
|
7292
7345
|
var sizeStyles3 = {
|
|
7293
7346
|
xs: "h-3 w-3",
|
|
@@ -7309,7 +7362,7 @@ function SpinnerGlyph({ size, iconClassName }) {
|
|
|
7309
7362
|
/* @__PURE__ */ jsx("span", { "data-loader-icon": "", style: { display: "var(--loader-icon-display, inline-flex)" }, children: /* @__PURE__ */ jsx(Icon, { name: "loader", className: cn("animate-spin", iconClassName, sizeStyles3[size]) }) })
|
|
7310
7363
|
] });
|
|
7311
7364
|
}
|
|
7312
|
-
var Spinner =
|
|
7365
|
+
var Spinner = React44__default.forwardRef(
|
|
7313
7366
|
({ className, size = "md", overlay, ...props }, ref) => {
|
|
7314
7367
|
const { t } = useTranslate();
|
|
7315
7368
|
if (overlay) {
|
|
@@ -7394,7 +7447,7 @@ var lookStyles = {
|
|
|
7394
7447
|
chip: "shadow-none rounded-pill border-[length:var(--border-width)] border-border",
|
|
7395
7448
|
"tile-image-first": "p-0 overflow-hidden"
|
|
7396
7449
|
};
|
|
7397
|
-
var Card =
|
|
7450
|
+
var Card = React44__default.forwardRef(
|
|
7398
7451
|
({
|
|
7399
7452
|
className,
|
|
7400
7453
|
variant = "bordered",
|
|
@@ -7444,9 +7497,9 @@ var Card = React43__default.forwardRef(
|
|
|
7444
7497
|
}
|
|
7445
7498
|
);
|
|
7446
7499
|
Card.displayName = "Card";
|
|
7447
|
-
var CardHeader =
|
|
7500
|
+
var CardHeader = React44__default.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsx("div", { ref, className: cn("mb-4", className), ...props }));
|
|
7448
7501
|
CardHeader.displayName = "CardHeader";
|
|
7449
|
-
var CardTitle =
|
|
7502
|
+
var CardTitle = React44__default.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsx(
|
|
7450
7503
|
"h3",
|
|
7451
7504
|
{
|
|
7452
7505
|
ref,
|
|
@@ -7459,11 +7512,11 @@ var CardTitle = React43__default.forwardRef(({ className, ...props }, ref) => /*
|
|
|
7459
7512
|
}
|
|
7460
7513
|
));
|
|
7461
7514
|
CardTitle.displayName = "CardTitle";
|
|
7462
|
-
var CardContent =
|
|
7515
|
+
var CardContent = React44__default.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsx("div", { ref, className: cn("", className), ...props }));
|
|
7463
7516
|
CardContent.displayName = "CardContent";
|
|
7464
7517
|
var CardBody = CardContent;
|
|
7465
7518
|
CardBody.displayName = "CardBody";
|
|
7466
|
-
var CardFooter =
|
|
7519
|
+
var CardFooter = React44__default.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsx(
|
|
7467
7520
|
"div",
|
|
7468
7521
|
{
|
|
7469
7522
|
ref,
|
|
@@ -7486,7 +7539,7 @@ var Center = ({
|
|
|
7486
7539
|
...rest
|
|
7487
7540
|
}) => {
|
|
7488
7541
|
const mergedStyle = minHeight ? { minHeight, ...style } : style;
|
|
7489
|
-
return
|
|
7542
|
+
return React44__default.createElement(Component, {
|
|
7490
7543
|
...domPassthrough(rest),
|
|
7491
7544
|
className: cn(
|
|
7492
7545
|
inline ? "inline-flex" : "flex",
|
|
@@ -7596,10 +7649,10 @@ var Typography = ({
|
|
|
7596
7649
|
const variant = variantProp ?? (level ? `h${level}` : "body1");
|
|
7597
7650
|
const Component = as || defaultElements[variant];
|
|
7598
7651
|
let body = children ?? content;
|
|
7599
|
-
if (format !== void 0 && format !== "none" && (typeof body === "string" || typeof body === "number"
|
|
7652
|
+
if (format !== void 0 && format !== "none" && (typeof body === "string" || typeof body === "number")) {
|
|
7600
7653
|
body = formatValue(body, format, fmt);
|
|
7601
7654
|
}
|
|
7602
|
-
return
|
|
7655
|
+
return React44__default.createElement(
|
|
7603
7656
|
Component,
|
|
7604
7657
|
{
|
|
7605
7658
|
...domPassthrough(rest),
|
|
@@ -7633,9 +7686,9 @@ var Typography = ({
|
|
|
7633
7686
|
);
|
|
7634
7687
|
};
|
|
7635
7688
|
Typography.displayName = "Typography";
|
|
7636
|
-
var Checkbox =
|
|
7689
|
+
var Checkbox = React44__default.forwardRef(
|
|
7637
7690
|
({ className, label, id, error, required, onChange, ...props }, ref) => {
|
|
7638
|
-
const generatedId =
|
|
7691
|
+
const generatedId = React44__default.useId();
|
|
7639
7692
|
const inputId = id || generatedId;
|
|
7640
7693
|
const errorId = error ? `${inputId}-error` : void 0;
|
|
7641
7694
|
const describedBy = [props["aria-describedby"], errorId].filter(Boolean).join(" ") || void 0;
|
|
@@ -7722,7 +7775,7 @@ var ConditionalWrapper = ({
|
|
|
7722
7775
|
fallback = null,
|
|
7723
7776
|
animate = false
|
|
7724
7777
|
}) => {
|
|
7725
|
-
if (
|
|
7778
|
+
if (condition === void 0 || condition === null) {
|
|
7726
7779
|
return /* @__PURE__ */ jsx(Fragment, { children });
|
|
7727
7780
|
}
|
|
7728
7781
|
const [isVisible] = guardsHold(toEvalContext(context), [condition]);
|
|
@@ -7739,46 +7792,14 @@ var ConditionalWrapper = ({
|
|
|
7739
7792
|
return isVisible ? /* @__PURE__ */ jsx(Fragment, { children }) : /* @__PURE__ */ jsx(Fragment, { children: fallback });
|
|
7740
7793
|
};
|
|
7741
7794
|
ConditionalWrapper.displayName = "ConditionalWrapper";
|
|
7742
|
-
|
|
7743
|
-
// src/core/atoms/fx.ts
|
|
7744
7795
|
function resolveFxView(item, presets) {
|
|
7745
|
-
|
|
7746
|
-
if (!row) return item;
|
|
7747
|
-
return {
|
|
7748
|
-
...item,
|
|
7749
|
-
space: item.space ?? row.space,
|
|
7750
|
-
effect: item.effect ?? row.effect,
|
|
7751
|
-
color: item.color ?? row.color,
|
|
7752
|
-
size: item.size ?? row.size,
|
|
7753
|
-
vx: item.vx ?? row.vx,
|
|
7754
|
-
vy: item.vy ?? row.vy,
|
|
7755
|
-
vz: item.vz ?? row.vz,
|
|
7756
|
-
particleCount: item.particleCount ?? row.particleCount,
|
|
7757
|
-
animation: item.animation ?? row.animation,
|
|
7758
|
-
shape: row.shape,
|
|
7759
|
-
count: row.count,
|
|
7760
|
-
glow: row.glow,
|
|
7761
|
-
gravity: row.gravity,
|
|
7762
|
-
color2: row.color2
|
|
7763
|
-
};
|
|
7796
|
+
return JSON.parse(kernelEvaluator().resolveFxView(JSON.stringify(item), presets === void 0 ? void 0 : JSON.stringify(presets)));
|
|
7764
7797
|
}
|
|
7765
7798
|
function fxLifecycle(item, epochNowMs, tickMs) {
|
|
7766
|
-
|
|
7767
|
-
const lifeMs = maxTtl * tickMs;
|
|
7768
|
-
const ageMs = item.bornAt !== void 0 && epochNowMs > 0 ? Math.max(0, epochNowMs - item.bornAt) : (1 - item.ttl / maxTtl) * lifeMs;
|
|
7769
|
-
const progress = Math.min(1, Math.max(0, ageMs / lifeMs));
|
|
7770
|
-
return { lifeMs, ageMs, progress, fade: 1 - progress };
|
|
7799
|
+
return JSON.parse(kernelEvaluator().fxLifecycle(JSON.stringify(item), epochNowMs, tickMs));
|
|
7771
7800
|
}
|
|
7772
7801
|
function fxHash01(seed, salt) {
|
|
7773
|
-
|
|
7774
|
-
for (let i = 0; i < seed.length; i++) {
|
|
7775
|
-
h ^= seed.charCodeAt(i);
|
|
7776
|
-
h = Math.imul(h, 16777619);
|
|
7777
|
-
}
|
|
7778
|
-
h ^= h >>> 13;
|
|
7779
|
-
h = Math.imul(h, 1274126177);
|
|
7780
|
-
h ^= h >>> 16;
|
|
7781
|
-
return (h >>> 0) / 4294967296;
|
|
7802
|
+
return kernelEvaluator().fxHash01(seed, salt);
|
|
7782
7803
|
}
|
|
7783
7804
|
var CONFETTI_COLORS = [
|
|
7784
7805
|
"var(--color-primary)",
|
|
@@ -7940,7 +7961,7 @@ function DayCell({
|
|
|
7940
7961
|
);
|
|
7941
7962
|
}
|
|
7942
7963
|
DayCell.displayName = "DayCell";
|
|
7943
|
-
var Dialog =
|
|
7964
|
+
var Dialog = React44__default.forwardRef(
|
|
7944
7965
|
({
|
|
7945
7966
|
role = "dialog",
|
|
7946
7967
|
"aria-modal": ariaModal = true,
|
|
@@ -8072,7 +8093,7 @@ var iconSizes = {
|
|
|
8072
8093
|
md: "w-3.5 h-3.5",
|
|
8073
8094
|
lg: "w-4 h-4"
|
|
8074
8095
|
};
|
|
8075
|
-
var FilterPill =
|
|
8096
|
+
var FilterPill = React44__default.forwardRef(
|
|
8076
8097
|
({
|
|
8077
8098
|
className,
|
|
8078
8099
|
variant = "default",
|
|
@@ -8085,6 +8106,7 @@ var FilterPill = React43__default.forwardRef(
|
|
|
8085
8106
|
clickEvent,
|
|
8086
8107
|
removeEvent,
|
|
8087
8108
|
children,
|
|
8109
|
+
selected,
|
|
8088
8110
|
"aria-pressed": ariaPressed,
|
|
8089
8111
|
...props
|
|
8090
8112
|
}, ref) => {
|
|
@@ -8093,11 +8115,11 @@ var FilterPill = React43__default.forwardRef(
|
|
|
8093
8115
|
const payloadLabel = typeof children === "string" || typeof children === "number" ? children : label;
|
|
8094
8116
|
const handleClick = useCallback(() => {
|
|
8095
8117
|
onClick?.();
|
|
8096
|
-
if (clickEvent) eventBus.emit(`UI:${clickEvent}`, { label: payloadLabel });
|
|
8118
|
+
if (clickEvent) eventBus.emit(`UI:${clickEvent}`, { ...payloadLabel !== void 0 ? { label: payloadLabel } : {} });
|
|
8097
8119
|
}, [onClick, clickEvent, eventBus, payloadLabel]);
|
|
8098
8120
|
const handleRemove = useCallback(() => {
|
|
8099
8121
|
onRemove?.();
|
|
8100
|
-
if (removeEvent) eventBus.emit(`UI:${removeEvent}`, { label: payloadLabel });
|
|
8122
|
+
if (removeEvent) eventBus.emit(`UI:${removeEvent}`, { ...payloadLabel !== void 0 ? { label: payloadLabel } : {} });
|
|
8101
8123
|
}, [onRemove, removeEvent, eventBus, payloadLabel]);
|
|
8102
8124
|
const resolvedIcon = typeof icon === "string" ? /* @__PURE__ */ jsx(Icon, { name: icon, className: iconSizes[size] }) : icon ? /* @__PURE__ */ jsx(Icon, { icon, className: iconSizes[size] }) : null;
|
|
8103
8125
|
const pressable = onClick || clickEvent ? handleClick : void 0;
|
|
@@ -8118,7 +8140,7 @@ var FilterPill = React43__default.forwardRef(
|
|
|
8118
8140
|
{
|
|
8119
8141
|
className: cn("inline-flex items-center gap-1", pressable && "cursor-pointer"),
|
|
8120
8142
|
...pressableProps(pressable),
|
|
8121
|
-
"aria-pressed": pressable ? ariaPressed : void 0,
|
|
8143
|
+
"aria-pressed": pressable ? ariaPressed ?? selected : void 0,
|
|
8122
8144
|
children: [
|
|
8123
8145
|
resolvedIcon,
|
|
8124
8146
|
/* @__PURE__ */ jsx("span", { children: children ?? label })
|
|
@@ -8331,7 +8353,29 @@ var InfiniteScrollSentinel = ({
|
|
|
8331
8353
|
);
|
|
8332
8354
|
};
|
|
8333
8355
|
InfiniteScrollSentinel.displayName = "InfiniteScrollSentinel";
|
|
8334
|
-
|
|
8356
|
+
function echoKey(value) {
|
|
8357
|
+
return Array.isArray(value) ? JSON.stringify(value) : String(value ?? "");
|
|
8358
|
+
}
|
|
8359
|
+
function useFieldDraft(value, declarative) {
|
|
8360
|
+
const [draft, setDraft] = React44__default.useState(value);
|
|
8361
|
+
const pending2 = React44__default.useRef(/* @__PURE__ */ new Set());
|
|
8362
|
+
React44__default.useEffect(() => {
|
|
8363
|
+
if (!declarative) return;
|
|
8364
|
+
const key = echoKey(value);
|
|
8365
|
+
if (pending2.current.has(key)) {
|
|
8366
|
+
pending2.current.delete(key);
|
|
8367
|
+
return;
|
|
8368
|
+
}
|
|
8369
|
+
pending2.current.clear();
|
|
8370
|
+
setDraft(value);
|
|
8371
|
+
}, [value, declarative]);
|
|
8372
|
+
const record = React44__default.useCallback((next) => {
|
|
8373
|
+
pending2.current.add(echoKey(next));
|
|
8374
|
+
setDraft(next);
|
|
8375
|
+
}, []);
|
|
8376
|
+
return { displayValue: declarative ? draft : value, record };
|
|
8377
|
+
}
|
|
8378
|
+
var Input = React44__default.forwardRef(
|
|
8335
8379
|
({
|
|
8336
8380
|
className,
|
|
8337
8381
|
inputType,
|
|
@@ -8354,7 +8398,7 @@ var Input = React43__default.forwardRef(
|
|
|
8354
8398
|
const { t } = useTranslate();
|
|
8355
8399
|
const eventBus = useEventBus();
|
|
8356
8400
|
const type = inputType || htmlType || "text";
|
|
8357
|
-
const generatedId =
|
|
8401
|
+
const generatedId = React44__default.useId();
|
|
8358
8402
|
const fieldId = props.id ?? generatedId;
|
|
8359
8403
|
const descriptionId = helperText || error ? `${fieldId}-description` : void 0;
|
|
8360
8404
|
const describedBy = [props["aria-describedby"], descriptionId].filter(Boolean).join(" ") || void 0;
|
|
@@ -8365,19 +8409,7 @@ var Input = React43__default.forwardRef(
|
|
|
8365
8409
|
"aria-describedby": describedBy
|
|
8366
8410
|
};
|
|
8367
8411
|
const isDeclarative = typeof onChange === "string";
|
|
8368
|
-
const
|
|
8369
|
-
const pendingEchoRef = React43__default.useRef(/* @__PURE__ */ new Set());
|
|
8370
|
-
React43__default.useEffect(() => {
|
|
8371
|
-
if (!isDeclarative) return;
|
|
8372
|
-
const incoming = value == null ? "" : String(value);
|
|
8373
|
-
if (pendingEchoRef.current.has(incoming)) {
|
|
8374
|
-
pendingEchoRef.current.delete(incoming);
|
|
8375
|
-
return;
|
|
8376
|
-
}
|
|
8377
|
-
pendingEchoRef.current.clear();
|
|
8378
|
-
setLocalValue(value);
|
|
8379
|
-
}, [value, isDeclarative]);
|
|
8380
|
-
const displayValue = isDeclarative ? localValue : value;
|
|
8412
|
+
const { displayValue, record } = useFieldDraft(value, isDeclarative);
|
|
8381
8413
|
const resolveIconNode = (i, cls) => {
|
|
8382
8414
|
if (!i) return null;
|
|
8383
8415
|
if (typeof i === "string") return /* @__PURE__ */ jsx(Icon, { name: i, className: cls });
|
|
@@ -8407,8 +8439,7 @@ var Input = React43__default.forwardRef(
|
|
|
8407
8439
|
const target = e.target;
|
|
8408
8440
|
const payload = type === "checkbox" ? { checked: target.checked } : { value: target.value };
|
|
8409
8441
|
if (type !== "checkbox") {
|
|
8410
|
-
|
|
8411
|
-
setLocalValue(target.value);
|
|
8442
|
+
record(target.value);
|
|
8412
8443
|
}
|
|
8413
8444
|
eventBus.emit(`UI:${onChange}`, payload);
|
|
8414
8445
|
} else {
|
|
@@ -8534,7 +8565,7 @@ var Input = React43__default.forwardRef(
|
|
|
8534
8565
|
}
|
|
8535
8566
|
);
|
|
8536
8567
|
Input.displayName = "Input";
|
|
8537
|
-
var Label =
|
|
8568
|
+
var Label = React44__default.forwardRef(
|
|
8538
8569
|
({ className, required, children, ...props }, ref) => {
|
|
8539
8570
|
return /* @__PURE__ */ jsxs(
|
|
8540
8571
|
"label",
|
|
@@ -8608,7 +8639,7 @@ var Stack = ({
|
|
|
8608
8639
|
};
|
|
8609
8640
|
const isHorizontal = direction === "horizontal";
|
|
8610
8641
|
const directionClass = responsive && isHorizontal ? reverse ? "flex-col-reverse md:flex-row-reverse" : "flex-col md:flex-row" : isHorizontal ? reverse ? "flex-row-reverse" : "flex-row" : reverse ? "flex-col-reverse" : "flex-col";
|
|
8611
|
-
return
|
|
8642
|
+
return React44__default.createElement(
|
|
8612
8643
|
Component,
|
|
8613
8644
|
{
|
|
8614
8645
|
...domPassthrough(rest),
|
|
@@ -8653,9 +8684,9 @@ var LawReferenceTooltip = ({
|
|
|
8653
8684
|
...rest
|
|
8654
8685
|
}) => {
|
|
8655
8686
|
const { t } = useTranslate();
|
|
8656
|
-
const [isVisible, setIsVisible] =
|
|
8657
|
-
const timeoutRef =
|
|
8658
|
-
const triggerRef =
|
|
8687
|
+
const [isVisible, setIsVisible] = React44__default.useState(false);
|
|
8688
|
+
const timeoutRef = React44__default.useRef(null);
|
|
8689
|
+
const triggerRef = React44__default.useRef(null);
|
|
8659
8690
|
const handleMouseEnter = () => {
|
|
8660
8691
|
if (timeoutRef.current) clearTimeout(timeoutRef.current);
|
|
8661
8692
|
timeoutRef.current = setTimeout(() => setIsVisible(true), 200);
|
|
@@ -8666,7 +8697,7 @@ var LawReferenceTooltip = ({
|
|
|
8666
8697
|
};
|
|
8667
8698
|
const { revealed, triggerProps } = useTapReveal({ refs: [triggerRef] });
|
|
8668
8699
|
const open = isVisible || revealed;
|
|
8669
|
-
|
|
8700
|
+
React44__default.useEffect(() => {
|
|
8670
8701
|
return () => {
|
|
8671
8702
|
if (timeoutRef.current) clearTimeout(timeoutRef.current);
|
|
8672
8703
|
};
|
|
@@ -8793,465 +8824,6 @@ var Overlay = ({
|
|
|
8793
8824
|
}
|
|
8794
8825
|
);
|
|
8795
8826
|
};
|
|
8796
|
-
var PI = Math.PI;
|
|
8797
|
-
function lineIntersection(x1, y1, x2, y2, x3, y3, x4, y4) {
|
|
8798
|
-
const denom = (x1 - x2) * (y3 - y4) - (y1 - y2) * (x3 - x4);
|
|
8799
|
-
if (Math.abs(denom) < 1e-10) return [(x1 + x3) / 2, (y1 + y3) / 2];
|
|
8800
|
-
const t = ((x1 - x3) * (y3 - y4) - (y1 - y3) * (x3 - x4)) / denom;
|
|
8801
|
-
return [x1 + t * (x2 - x1), y1 + t * (y2 - y1)];
|
|
8802
|
-
}
|
|
8803
|
-
function f(n) {
|
|
8804
|
-
return n.toFixed(3);
|
|
8805
|
-
}
|
|
8806
|
-
function picStar(cx, cy, R, n, theta, extent) {
|
|
8807
|
-
const verts = [];
|
|
8808
|
-
for (let k = 0; k < n; k++) {
|
|
8809
|
-
const angle = PI / n + k * (2 * PI) / n;
|
|
8810
|
-
verts.push([cx + R * Math.cos(angle), cy + R * Math.sin(angle)]);
|
|
8811
|
-
}
|
|
8812
|
-
const mids = [];
|
|
8813
|
-
for (let k = 0; k < n; k++) {
|
|
8814
|
-
const next = (k + 1) % n;
|
|
8815
|
-
mids.push([(verts[k][0] + verts[next][0]) / 2, (verts[k][1] + verts[next][1]) / 2]);
|
|
8816
|
-
}
|
|
8817
|
-
const innerPts = [];
|
|
8818
|
-
for (let k = 0; k < n; k++) {
|
|
8819
|
-
const next = (k + 1) % n;
|
|
8820
|
-
const M1 = mids[k];
|
|
8821
|
-
const M2 = mids[next];
|
|
8822
|
-
const edx1 = verts[(k + 1) % n][0] - verts[k][0];
|
|
8823
|
-
const edy1 = verts[(k + 1) % n][1] - verts[k][1];
|
|
8824
|
-
const elen1 = Math.sqrt(edx1 * edx1 + edy1 * edy1);
|
|
8825
|
-
const tx1 = edx1 / elen1;
|
|
8826
|
-
const ty1 = edy1 / elen1;
|
|
8827
|
-
const r1x = tx1 * Math.cos(theta) + ty1 * Math.sin(theta);
|
|
8828
|
-
const r1y = -tx1 * Math.sin(theta) + ty1 * Math.cos(theta);
|
|
8829
|
-
const edx2 = verts[(next + 1) % n][0] - verts[next][0];
|
|
8830
|
-
const edy2 = verts[(next + 1) % n][1] - verts[next][1];
|
|
8831
|
-
const elen2 = Math.sqrt(edx2 * edx2 + edy2 * edy2);
|
|
8832
|
-
const tx2 = edx2 / elen2;
|
|
8833
|
-
const ty2 = edy2 / elen2;
|
|
8834
|
-
const bTheta = PI - theta;
|
|
8835
|
-
const r2x = tx2 * Math.cos(bTheta) + ty2 * Math.sin(bTheta);
|
|
8836
|
-
const r2y = -tx2 * Math.sin(bTheta) + ty2 * Math.cos(bTheta);
|
|
8837
|
-
const P = lineIntersection(
|
|
8838
|
-
M1[0],
|
|
8839
|
-
M1[1],
|
|
8840
|
-
M1[0] + r1x * extent,
|
|
8841
|
-
M1[1] + r1y * extent,
|
|
8842
|
-
M2[0],
|
|
8843
|
-
M2[1],
|
|
8844
|
-
M2[0] + r2x * extent,
|
|
8845
|
-
M2[1] + r2y * extent
|
|
8846
|
-
);
|
|
8847
|
-
innerPts.push(P);
|
|
8848
|
-
}
|
|
8849
|
-
const starPath = mids.map((m, k) => {
|
|
8850
|
-
const inner = innerPts[k];
|
|
8851
|
-
const nextMid = mids[(k + 1) % n];
|
|
8852
|
-
return `M ${f(m[0])},${f(m[1])} L ${f(inner[0])},${f(inner[1])} L ${f(nextMid[0])},${f(nextMid[1])}`;
|
|
8853
|
-
}).join(" ");
|
|
8854
|
-
return { starPath, mids, verts };
|
|
8855
|
-
}
|
|
8856
|
-
function Star8({ size, color, strokeWidth }) {
|
|
8857
|
-
const s = size;
|
|
8858
|
-
const cx = s / 2;
|
|
8859
|
-
const cy = s / 2;
|
|
8860
|
-
const a = s / (1 + Math.SQRT2);
|
|
8861
|
-
const R = a / (2 * Math.sin(PI / 8));
|
|
8862
|
-
const theta = 67.5 * PI / 180;
|
|
8863
|
-
const { starPath, mids } = picStar(cx, cy, R, 8, theta, s);
|
|
8864
|
-
const corners = [[0, 0], [s, 0], [s, s], [0, s]];
|
|
8865
|
-
const crossPaths = [];
|
|
8866
|
-
for (const [cornX, cornY] of corners) {
|
|
8867
|
-
const dists = mids.map((m, i) => ({ i, d: Math.hypot(m[0] - cornX, m[1] - cornY) }));
|
|
8868
|
-
dists.sort((a2, b) => a2.d - b.d);
|
|
8869
|
-
const m1 = mids[dists[0].i];
|
|
8870
|
-
const m2 = mids[dists[1].i];
|
|
8871
|
-
crossPaths.push(`M ${f(m1[0])},${f(m1[1])} L ${f(cornX)},${f(cornY)} L ${f(m2[0])},${f(m2[1])}`);
|
|
8872
|
-
}
|
|
8873
|
-
return /* @__PURE__ */ jsxs("g", { fill: "none", stroke: color, strokeWidth, children: [
|
|
8874
|
-
/* @__PURE__ */ jsx("path", { d: starPath }),
|
|
8875
|
-
crossPaths.map((d, i) => /* @__PURE__ */ jsx("path", { d }, i))
|
|
8876
|
-
] });
|
|
8877
|
-
}
|
|
8878
|
-
function Star6({ size, color, strokeWidth }) {
|
|
8879
|
-
const w = size;
|
|
8880
|
-
const h = size * (2 / Math.sqrt(3));
|
|
8881
|
-
const cx = w / 2;
|
|
8882
|
-
const cy = h / 2;
|
|
8883
|
-
const a = w / Math.sqrt(3);
|
|
8884
|
-
const R = a;
|
|
8885
|
-
const theta = 60 * PI / 180;
|
|
8886
|
-
const { starPath, mids, verts } = picStar(cx, cy, R, 6, theta, w);
|
|
8887
|
-
const triPaths = [];
|
|
8888
|
-
for (let k = 0; k < 6; k++) {
|
|
8889
|
-
const v = verts[k];
|
|
8890
|
-
const m1 = mids[(k + 5) % 6];
|
|
8891
|
-
const m2 = mids[k];
|
|
8892
|
-
triPaths.push(`M ${f(m1[0])},${f(m1[1])} L ${f(v[0])},${f(v[1])} L ${f(m2[0])},${f(m2[1])}`);
|
|
8893
|
-
}
|
|
8894
|
-
return /* @__PURE__ */ jsxs("g", { fill: "none", stroke: color, strokeWidth, children: [
|
|
8895
|
-
/* @__PURE__ */ jsx("path", { d: starPath }),
|
|
8896
|
-
triPaths.map((d, i) => /* @__PURE__ */ jsx("path", { d }, i))
|
|
8897
|
-
] });
|
|
8898
|
-
}
|
|
8899
|
-
function Khatam({ size, color, strokeWidth }) {
|
|
8900
|
-
const s = size;
|
|
8901
|
-
const cx = s / 2;
|
|
8902
|
-
const cy = s / 2;
|
|
8903
|
-
const a = s / (1 + Math.SQRT2);
|
|
8904
|
-
const R = a / (2 * Math.sin(PI / 8));
|
|
8905
|
-
const theta = 72 * PI / 180;
|
|
8906
|
-
const { starPath, mids } = picStar(cx, cy, R, 8, theta, s);
|
|
8907
|
-
const corners = [[0, 0], [s, 0], [s, s], [0, s]];
|
|
8908
|
-
const crossPaths = [];
|
|
8909
|
-
for (const [cornX, cornY] of corners) {
|
|
8910
|
-
const dists = mids.map((m, i) => ({ i, d: Math.hypot(m[0] - cornX, m[1] - cornY) }));
|
|
8911
|
-
dists.sort((a2, b) => a2.d - b.d);
|
|
8912
|
-
const m1 = mids[dists[0].i];
|
|
8913
|
-
const m2 = mids[dists[1].i];
|
|
8914
|
-
crossPaths.push(`M ${f(m1[0])},${f(m1[1])} L ${f(cornX)},${f(cornY)} L ${f(m2[0])},${f(m2[1])}`);
|
|
8915
|
-
}
|
|
8916
|
-
const orbitR = R * 0.35;
|
|
8917
|
-
return /* @__PURE__ */ jsxs("g", { fill: "none", stroke: color, strokeWidth, children: [
|
|
8918
|
-
/* @__PURE__ */ jsx("path", { d: starPath }),
|
|
8919
|
-
crossPaths.map((d, i) => /* @__PURE__ */ jsx("path", { d }, i)),
|
|
8920
|
-
/* @__PURE__ */ jsx("circle", { cx, cy, r: orbitR, opacity: "0.4" })
|
|
8921
|
-
] });
|
|
8922
|
-
}
|
|
8923
|
-
function RosetteDouble({ size, color, strokeWidth }) {
|
|
8924
|
-
const s = size;
|
|
8925
|
-
const cx = s / 2;
|
|
8926
|
-
const cy = s / 2;
|
|
8927
|
-
const a = s / (1 + Math.SQRT2);
|
|
8928
|
-
const Router = a / (2 * Math.sin(PI / 8));
|
|
8929
|
-
const Rinner = Router * 0.45;
|
|
8930
|
-
const outer = picStar(cx, cy, Router, 8, 72 * PI / 180, s);
|
|
8931
|
-
const inner = picStar(cx, cy, Rinner, 8, 68 * PI / 180, s);
|
|
8932
|
-
const corners = [[0, 0], [s, 0], [s, s], [0, s]];
|
|
8933
|
-
const crossPaths = [];
|
|
8934
|
-
for (const [cornX, cornY] of corners) {
|
|
8935
|
-
const dists = outer.mids.map((m, i) => ({ i, d: Math.hypot(m[0] - cornX, m[1] - cornY) }));
|
|
8936
|
-
dists.sort((a2, b) => a2.d - b.d);
|
|
8937
|
-
const m1 = outer.mids[dists[0].i];
|
|
8938
|
-
const m2 = outer.mids[dists[1].i];
|
|
8939
|
-
crossPaths.push(`M ${f(m1[0])},${f(m1[1])} L ${f(cornX)},${f(cornY)} L ${f(m2[0])},${f(m2[1])}`);
|
|
8940
|
-
}
|
|
8941
|
-
const connectors = [];
|
|
8942
|
-
for (let k = 0; k < 8; k++) {
|
|
8943
|
-
const om = outer.mids[k];
|
|
8944
|
-
const im = inner.mids[k];
|
|
8945
|
-
connectors.push(`M ${f(im[0])},${f(im[1])} L ${f(om[0])},${f(om[1])}`);
|
|
8946
|
-
}
|
|
8947
|
-
return /* @__PURE__ */ jsxs("g", { fill: "none", stroke: color, strokeWidth, children: [
|
|
8948
|
-
/* @__PURE__ */ jsx("path", { d: outer.starPath }),
|
|
8949
|
-
/* @__PURE__ */ jsx("path", { d: inner.starPath, opacity: "0.7" }),
|
|
8950
|
-
crossPaths.map((d, i) => /* @__PURE__ */ jsx("path", { d }, `c${i}`)),
|
|
8951
|
-
connectors.map((d, i) => /* @__PURE__ */ jsx("path", { d, opacity: "0.4" }, `n${i}`))
|
|
8952
|
-
] });
|
|
8953
|
-
}
|
|
8954
|
-
function RosetteFilled({ size, color, strokeWidth }) {
|
|
8955
|
-
const s = size;
|
|
8956
|
-
const cx = s / 2;
|
|
8957
|
-
const cy = s / 2;
|
|
8958
|
-
const a = s / (1 + Math.SQRT2);
|
|
8959
|
-
const Router = a / (2 * Math.sin(PI / 8));
|
|
8960
|
-
const theta = 72 * PI / 180;
|
|
8961
|
-
const outer = picStar(cx, cy, Router, 8, theta, s);
|
|
8962
|
-
const Rinner = Router * 0.35;
|
|
8963
|
-
const inner6 = picStar(cx, cy, Rinner, 6, 60 * PI / 180, s);
|
|
8964
|
-
const corners = [[0, 0], [s, 0], [s, s], [0, s]];
|
|
8965
|
-
const crossPaths = [];
|
|
8966
|
-
for (const [cornX, cornY] of corners) {
|
|
8967
|
-
const dists = outer.mids.map((m, i) => ({ i, d: Math.hypot(m[0] - cornX, m[1] - cornY) }));
|
|
8968
|
-
dists.sort((a2, b) => a2.d - b.d);
|
|
8969
|
-
const m1 = outer.mids[dists[0].i];
|
|
8970
|
-
const m2 = outer.mids[dists[1].i];
|
|
8971
|
-
crossPaths.push(`M ${f(m1[0])},${f(m1[1])} L ${f(cornX)},${f(cornY)} L ${f(m2[0])},${f(m2[1])}`);
|
|
8972
|
-
}
|
|
8973
|
-
const triPaths = [];
|
|
8974
|
-
for (let k = 0; k < 6; k++) {
|
|
8975
|
-
const v = inner6.verts[k];
|
|
8976
|
-
const m1 = inner6.mids[(k + 5) % 6];
|
|
8977
|
-
const m2 = inner6.mids[k];
|
|
8978
|
-
triPaths.push(`M ${f(m1[0])},${f(m1[1])} L ${f(v[0])},${f(v[1])} L ${f(m2[0])},${f(m2[1])}`);
|
|
8979
|
-
}
|
|
8980
|
-
const orbitR = Router * 0.35;
|
|
8981
|
-
return /* @__PURE__ */ jsxs("g", { fill: "none", stroke: color, strokeWidth, children: [
|
|
8982
|
-
/* @__PURE__ */ jsx("path", { d: outer.starPath }),
|
|
8983
|
-
crossPaths.map((d, i) => /* @__PURE__ */ jsx("path", { d }, `c${i}`)),
|
|
8984
|
-
/* @__PURE__ */ jsx("circle", { cx, cy, r: orbitR, opacity: "0.3" }),
|
|
8985
|
-
/* @__PURE__ */ jsx("path", { d: inner6.starPath, opacity: "0.6" }),
|
|
8986
|
-
triPaths.map((d, i) => /* @__PURE__ */ jsx("path", { d, opacity: "0.5" }, `t${i}`))
|
|
8987
|
-
] });
|
|
8988
|
-
}
|
|
8989
|
-
function Star10({ size, color, strokeWidth }) {
|
|
8990
|
-
const s = size;
|
|
8991
|
-
const cx = s / 2;
|
|
8992
|
-
const cy = s / 2;
|
|
8993
|
-
const R = s * 0.42;
|
|
8994
|
-
const theta = 72 * PI / 180;
|
|
8995
|
-
const { starPath, mids, verts } = picStar(cx, cy, R, 10, theta, s);
|
|
8996
|
-
const edgePaths = [];
|
|
8997
|
-
for (let k = 0; k < 10; k++) {
|
|
8998
|
-
const v = verts[k];
|
|
8999
|
-
const m1 = mids[(k + 9) % 10];
|
|
9000
|
-
const m2 = mids[k];
|
|
9001
|
-
edgePaths.push(`M ${f(m1[0])},${f(m1[1])} L ${f(v[0])},${f(v[1])} L ${f(m2[0])},${f(m2[1])}`);
|
|
9002
|
-
}
|
|
9003
|
-
return /* @__PURE__ */ jsxs("g", { fill: "none", stroke: color, strokeWidth, children: [
|
|
9004
|
-
/* @__PURE__ */ jsx("path", { d: starPath }),
|
|
9005
|
-
edgePaths.map((d, i) => /* @__PURE__ */ jsx("path", { d }, i))
|
|
9006
|
-
] });
|
|
9007
|
-
}
|
|
9008
|
-
function Star12({ size, color, strokeWidth }) {
|
|
9009
|
-
const s = size;
|
|
9010
|
-
const cx = s / 2;
|
|
9011
|
-
const cy = s / 2;
|
|
9012
|
-
const R = s * 0.44;
|
|
9013
|
-
const theta = 75 * PI / 180;
|
|
9014
|
-
const { starPath, mids, verts } = picStar(cx, cy, R, 12, theta, s);
|
|
9015
|
-
const triPaths = [];
|
|
9016
|
-
for (let k = 0; k < 12; k++) {
|
|
9017
|
-
const v = verts[k];
|
|
9018
|
-
const m1 = mids[(k + 11) % 12];
|
|
9019
|
-
const m2 = mids[k];
|
|
9020
|
-
triPaths.push(`M ${f(m1[0])},${f(m1[1])} L ${f(v[0])},${f(v[1])} L ${f(m2[0])},${f(m2[1])}`);
|
|
9021
|
-
}
|
|
9022
|
-
return /* @__PURE__ */ jsxs("g", { fill: "none", stroke: color, strokeWidth, children: [
|
|
9023
|
-
/* @__PURE__ */ jsx("path", { d: starPath }),
|
|
9024
|
-
triPaths.map((d, i) => /* @__PURE__ */ jsx("path", { d }, i))
|
|
9025
|
-
] });
|
|
9026
|
-
}
|
|
9027
|
-
function Seigaiha({ size, color, strokeWidth }) {
|
|
9028
|
-
const s = size;
|
|
9029
|
-
const r = s / 2;
|
|
9030
|
-
const paths = [];
|
|
9031
|
-
const centers = [
|
|
9032
|
-
[s / 2, s * 0.6],
|
|
9033
|
-
[0, s * 0.1],
|
|
9034
|
-
[s, s * 0.1]
|
|
9035
|
-
];
|
|
9036
|
-
for (const [cx, cy] of centers) {
|
|
9037
|
-
for (let ring = 1; ring <= 3; ring++) {
|
|
9038
|
-
const cr = r * (ring / 3);
|
|
9039
|
-
paths.push(
|
|
9040
|
-
`M ${f(cx - cr)},${f(cy)} A ${f(cr)} ${f(cr)} 0 0 1 ${f(cx + cr)},${f(cy)}`
|
|
9041
|
-
);
|
|
9042
|
-
}
|
|
9043
|
-
}
|
|
9044
|
-
return /* @__PURE__ */ jsx("g", { fill: "none", stroke: color, strokeWidth, children: paths.map((d, i) => /* @__PURE__ */ jsx("path", { d }, i)) });
|
|
9045
|
-
}
|
|
9046
|
-
function GreekKey({ size, color, strokeWidth }) {
|
|
9047
|
-
const s = size;
|
|
9048
|
-
const u = s / 4;
|
|
9049
|
-
const paths = [
|
|
9050
|
-
// Outer frame
|
|
9051
|
-
`M 0,0 L ${f(s)},0`,
|
|
9052
|
-
`M 0,${f(s)} L ${f(s)},${f(s)}`,
|
|
9053
|
-
// Spiral from left
|
|
9054
|
-
`M 0,${f(u)} L ${f(3 * u)},${f(u)} L ${f(3 * u)},${f(3 * u)} L ${f(u)},${f(3 * u)} L ${f(u)},${f(2 * u)} L ${f(2 * u)},${f(2 * u)}`,
|
|
9055
|
-
// Spiral from right (mirrored, offset)
|
|
9056
|
-
`M ${f(s)},${f(3 * u)} L ${f(s - 3 * u)},${f(3 * u)} L ${f(s - 3 * u)},${f(u)} L ${f(s - u)},${f(u)} L ${f(s - u)},${f(2 * u)} L ${f(s - 2 * u)},${f(2 * u)}`,
|
|
9057
|
-
// Vertical connectors at edges
|
|
9058
|
-
`M 0,0 L 0,${f(u)}`,
|
|
9059
|
-
`M ${f(s)},0 L ${f(s)},${f(u)}`,
|
|
9060
|
-
`M 0,${f(3 * u)} L 0,${f(s)}`,
|
|
9061
|
-
`M ${f(s)},${f(3 * u)} L ${f(s)},${f(s)}`
|
|
9062
|
-
];
|
|
9063
|
-
return /* @__PURE__ */ jsx("g", { fill: "none", stroke: color, strokeWidth, children: paths.map((d, i) => /* @__PURE__ */ jsx("path", { d }, i)) });
|
|
9064
|
-
}
|
|
9065
|
-
function CelticKnot({ size, color, strokeWidth }) {
|
|
9066
|
-
const s = size;
|
|
9067
|
-
const q = s / 4;
|
|
9068
|
-
const r = q * 0.9;
|
|
9069
|
-
const paths = [
|
|
9070
|
-
// Band 1: diagonal with curves at crossings
|
|
9071
|
-
`M 0,0 Q ${f(q)},${f(q)} ${f(2 * q)},${f(2 * q)}`,
|
|
9072
|
-
`M ${f(2 * q)},${f(2 * q)} Q ${f(3 * q)},${f(3 * q)} ${f(s)},${f(s)}`,
|
|
9073
|
-
// Band 2: other diagonal
|
|
9074
|
-
`M ${f(s)},0 Q ${f(3 * q)},${f(q)} ${f(2 * q)},${f(2 * q)}`,
|
|
9075
|
-
`M ${f(2 * q)},${f(2 * q)} Q ${f(q)},${f(3 * q)} 0,${f(s)}`,
|
|
9076
|
-
// Outer loops that connect bands at tile edges for continuous weave
|
|
9077
|
-
`M 0,0 Q ${f(-q * 0.3)},${f(2 * q)} 0,${f(s)}`,
|
|
9078
|
-
`M ${f(s)},0 Q ${f(s + q * 0.3)},${f(2 * q)} ${f(s)},${f(s)}`,
|
|
9079
|
-
`M 0,0 Q ${f(2 * q)},${f(-q * 0.3)} ${f(s)},0`,
|
|
9080
|
-
`M 0,${f(s)} Q ${f(2 * q)},${f(s + q * 0.3)} ${f(s)},${f(s)}`,
|
|
9081
|
-
// Inner circle at crossing
|
|
9082
|
-
`M ${f(2 * q + r * 0.3)},${f(2 * q)} A ${f(r * 0.3)} ${f(r * 0.3)} 0 1 1 ${f(2 * q + r * 0.3)},${f(2 * q + 1e-3)}`
|
|
9083
|
-
];
|
|
9084
|
-
return /* @__PURE__ */ jsx("g", { fill: "none", stroke: color, strokeWidth, children: paths.map((d, i) => /* @__PURE__ */ jsx("path", { d }, i)) });
|
|
9085
|
-
}
|
|
9086
|
-
function Kolam({ size, color, strokeWidth }) {
|
|
9087
|
-
const s = size;
|
|
9088
|
-
const u = s / 4;
|
|
9089
|
-
const dotR = s * 0.015;
|
|
9090
|
-
const dots = [];
|
|
9091
|
-
for (let row = 1; row <= 3; row++) {
|
|
9092
|
-
for (let col = 1; col <= 3; col++) {
|
|
9093
|
-
dots.push([col * u, row * u]);
|
|
9094
|
-
}
|
|
9095
|
-
}
|
|
9096
|
-
const curves = [];
|
|
9097
|
-
for (let row = 1; row <= 3; row++) {
|
|
9098
|
-
const y = row * u;
|
|
9099
|
-
for (let col = 1; col < 3; col++) {
|
|
9100
|
-
const x1 = col * u;
|
|
9101
|
-
const x2 = (col + 1) * u;
|
|
9102
|
-
const mx = (x1 + x2) / 2;
|
|
9103
|
-
const bulge = u * 0.4;
|
|
9104
|
-
curves.push(`M ${f(x1)},${f(y)} C ${f(mx)},${f(y - bulge)} ${f(mx)},${f(y - bulge)} ${f(x2)},${f(y)}`);
|
|
9105
|
-
curves.push(`M ${f(x1)},${f(y)} C ${f(mx)},${f(y + bulge)} ${f(mx)},${f(y + bulge)} ${f(x2)},${f(y)}`);
|
|
9106
|
-
}
|
|
9107
|
-
}
|
|
9108
|
-
for (let col = 1; col <= 3; col++) {
|
|
9109
|
-
const x = col * u;
|
|
9110
|
-
for (let row = 1; row < 3; row++) {
|
|
9111
|
-
const y1 = row * u;
|
|
9112
|
-
const y2 = (row + 1) * u;
|
|
9113
|
-
const my = (y1 + y2) / 2;
|
|
9114
|
-
const bulge = u * 0.4;
|
|
9115
|
-
curves.push(`M ${f(x)},${f(y1)} C ${f(x - bulge)},${f(my)} ${f(x - bulge)},${f(my)} ${f(x)},${f(y2)}`);
|
|
9116
|
-
curves.push(`M ${f(x)},${f(y1)} C ${f(x + bulge)},${f(my)} ${f(x + bulge)},${f(my)} ${f(x)},${f(y2)}`);
|
|
9117
|
-
}
|
|
9118
|
-
}
|
|
9119
|
-
for (let k = 1; k <= 3; k++) {
|
|
9120
|
-
curves.push(`M ${f(k * u)},${f(u)} C ${f(k * u)},${f(u * 0.5)} ${f(k * u)},${f(u * 0.5)} ${f(k * u)},0`);
|
|
9121
|
-
curves.push(`M ${f(k * u)},${f(3 * u)} C ${f(k * u)},${f(3.5 * u)} ${f(k * u)},${f(3.5 * u)} ${f(k * u)},${f(s)}`);
|
|
9122
|
-
curves.push(`M ${f(u)},${f(k * u)} C ${f(u * 0.5)},${f(k * u)} ${f(u * 0.5)},${f(k * u)} 0,${f(k * u)}`);
|
|
9123
|
-
curves.push(`M ${f(3 * u)},${f(k * u)} C ${f(3.5 * u)},${f(k * u)} ${f(3.5 * u)},${f(k * u)} ${f(s)},${f(k * u)}`);
|
|
9124
|
-
}
|
|
9125
|
-
return /* @__PURE__ */ jsxs("g", { fill: "none", stroke: color, strokeWidth, children: [
|
|
9126
|
-
curves.map((d, i) => /* @__PURE__ */ jsx("path", { d }, `c${i}`)),
|
|
9127
|
-
dots.map(([x, y], i) => /* @__PURE__ */ jsx("circle", { cx: x, cy: y, r: dotR, fill: color, opacity: "0.5" }, `d${i}`))
|
|
9128
|
-
] });
|
|
9129
|
-
}
|
|
9130
|
-
function Arch({ size, color, strokeWidth }) {
|
|
9131
|
-
const w = size;
|
|
9132
|
-
const h = size * 1.5;
|
|
9133
|
-
const cx = w / 2;
|
|
9134
|
-
const paths = [];
|
|
9135
|
-
for (let ring = 0; ring < 4; ring++) {
|
|
9136
|
-
const scale2 = 1 - ring * 0.2;
|
|
9137
|
-
const archW = w * 0.48 * scale2;
|
|
9138
|
-
const archH = h * 0.7 * scale2;
|
|
9139
|
-
const baseY = h * 0.85;
|
|
9140
|
-
const tipY = baseY - archH;
|
|
9141
|
-
const lx = cx - archW;
|
|
9142
|
-
const rx = cx + archW;
|
|
9143
|
-
const offset = archW * 0.3;
|
|
9144
|
-
const lcx = lx + offset;
|
|
9145
|
-
const rdx = cx - lcx;
|
|
9146
|
-
const rdy = baseY - tipY;
|
|
9147
|
-
const radius = Math.sqrt(rdx * rdx + rdy * rdy);
|
|
9148
|
-
paths.push(
|
|
9149
|
-
`M ${f(lx)},${f(baseY)} A ${f(radius)} ${f(radius)} 0 0 1 ${f(cx)},${f(tipY)} A ${f(radius)} ${f(radius)} 0 0 1 ${f(rx)},${f(baseY)}`
|
|
9150
|
-
);
|
|
9151
|
-
if (ring === 0) {
|
|
9152
|
-
paths.push(`M ${f(lx)},${f(baseY)} L ${f(rx)},${f(baseY)}`);
|
|
9153
|
-
}
|
|
9154
|
-
}
|
|
9155
|
-
const innerScale = 1 - 3 * 0.2;
|
|
9156
|
-
const keyR = w * 0.48 * innerScale * 0.35;
|
|
9157
|
-
const keyY = h * 0.85 - h * 0.7 * innerScale * 0.4;
|
|
9158
|
-
paths.push(
|
|
9159
|
-
`M ${f(cx + keyR)},${f(keyY)} A ${f(keyR)} ${f(keyR)} 0 1 1 ${f(cx + keyR)},${f(keyY + 1e-3)}`
|
|
9160
|
-
);
|
|
9161
|
-
const spR = w * 0.15;
|
|
9162
|
-
paths.push(`M 0,0 A ${f(spR)} ${f(spR)} 0 0 0 ${f(spR)},${f(spR)}`);
|
|
9163
|
-
paths.push(`M ${f(w)},0 A ${f(spR)} ${f(spR)} 0 0 1 ${f(w - spR)},${f(spR)}`);
|
|
9164
|
-
return /* @__PURE__ */ jsx("g", { fill: "none", stroke: color, strokeWidth, children: paths.map((d, i) => /* @__PURE__ */ jsx("path", { d }, i)) });
|
|
9165
|
-
}
|
|
9166
|
-
function ArabesqueVine({ size, color, strokeWidth }) {
|
|
9167
|
-
const w = size;
|
|
9168
|
-
const h = size * 1.2;
|
|
9169
|
-
const cx = w / 2;
|
|
9170
|
-
const paths = [];
|
|
9171
|
-
const amp = w * 0.3;
|
|
9172
|
-
const segments = 3;
|
|
9173
|
-
const segH = h / segments;
|
|
9174
|
-
for (let i = 0; i < segments; i++) {
|
|
9175
|
-
const y0 = i * segH;
|
|
9176
|
-
const y1 = y0 + segH;
|
|
9177
|
-
const dir = i % 2 === 0 ? 1 : -1;
|
|
9178
|
-
paths.push(
|
|
9179
|
-
`M ${f(cx)},${f(y0)} C ${f(cx + amp * dir)},${f(y0 + segH * 0.33)} ${f(cx - amp * dir)},${f(y0 + segH * 0.66)} ${f(cx)},${f(y1)}`
|
|
9180
|
-
);
|
|
9181
|
-
const branchY = y0 + segH * 0.5;
|
|
9182
|
-
const branchX = cx + amp * dir * 0.15;
|
|
9183
|
-
const tendrilLen = w * 0.25;
|
|
9184
|
-
const tlx = branchX - tendrilLen;
|
|
9185
|
-
const tly = branchY - tendrilLen * 0.4;
|
|
9186
|
-
paths.push(
|
|
9187
|
-
`M ${f(branchX)},${f(branchY)} C ${f(branchX - tendrilLen * 0.5)},${f(branchY - tendrilLen * 0.8)} ${f(tlx - tendrilLen * 0.2)},${f(tly + tendrilLen * 0.3)} ${f(tlx)},${f(tly)}`
|
|
9188
|
-
);
|
|
9189
|
-
paths.push(
|
|
9190
|
-
`M ${f(tlx)},${f(tly)} C ${f(tlx + tendrilLen * 0.3)},${f(tly + tendrilLen * 0.5)} ${f(branchX - tendrilLen * 0.2)},${f(branchY + tendrilLen * 0.3)} ${f(branchX)},${f(branchY)}`
|
|
9191
|
-
);
|
|
9192
|
-
const trx = branchX + tendrilLen;
|
|
9193
|
-
const try_ = branchY + tendrilLen * 0.4;
|
|
9194
|
-
paths.push(
|
|
9195
|
-
`M ${f(branchX)},${f(branchY)} C ${f(branchX + tendrilLen * 0.5)},${f(branchY + tendrilLen * 0.8)} ${f(trx + tendrilLen * 0.2)},${f(try_ - tendrilLen * 0.3)} ${f(trx)},${f(try_)}`
|
|
9196
|
-
);
|
|
9197
|
-
paths.push(
|
|
9198
|
-
`M ${f(trx)},${f(try_)} C ${f(trx - tendrilLen * 0.3)},${f(try_ - tendrilLen * 0.5)} ${f(branchX + tendrilLen * 0.2)},${f(branchY - tendrilLen * 0.3)} ${f(branchX)},${f(branchY)}`
|
|
9199
|
-
);
|
|
9200
|
-
const spiralR = tendrilLen * 0.15;
|
|
9201
|
-
paths.push(
|
|
9202
|
-
`M ${f(tlx)},${f(tly)} A ${f(spiralR)} ${f(spiralR)} 0 1 0 ${f(tlx + spiralR * 2)},${f(tly)}`
|
|
9203
|
-
);
|
|
9204
|
-
paths.push(
|
|
9205
|
-
`M ${f(trx)},${f(try_)} A ${f(spiralR)} ${f(spiralR)} 0 1 1 ${f(trx - spiralR * 2)},${f(try_)}`
|
|
9206
|
-
);
|
|
9207
|
-
}
|
|
9208
|
-
return /* @__PURE__ */ jsx("g", { fill: "none", stroke: color, strokeWidth, children: paths.map((d, i) => /* @__PURE__ */ jsx("path", { d }, i)) });
|
|
9209
|
-
}
|
|
9210
|
-
function ArabesqueNet({ size, color, strokeWidth }) {
|
|
9211
|
-
const s = size;
|
|
9212
|
-
const cells = 4;
|
|
9213
|
-
const cellW = s / cells;
|
|
9214
|
-
const cellH = s / cells;
|
|
9215
|
-
const paths = [];
|
|
9216
|
-
for (let row = 0; row < cells; row++) {
|
|
9217
|
-
for (let col = 0; col < cells; col++) {
|
|
9218
|
-
const cx = col * cellW + cellW / 2;
|
|
9219
|
-
const cy = row * cellH + cellH / 2;
|
|
9220
|
-
const hw = cellW * 0.5;
|
|
9221
|
-
const hh = cellH * 0.5;
|
|
9222
|
-
const bulge = cellW * 0.25;
|
|
9223
|
-
paths.push(
|
|
9224
|
-
`M ${f(cx)},${f(cy - hh)} Q ${f(cx + bulge)},${f(cy - bulge)} ${f(cx + hw)},${f(cy)}`
|
|
9225
|
-
);
|
|
9226
|
-
paths.push(
|
|
9227
|
-
`M ${f(cx + hw)},${f(cy)} Q ${f(cx + bulge)},${f(cy + bulge)} ${f(cx)},${f(cy + hh)}`
|
|
9228
|
-
);
|
|
9229
|
-
paths.push(
|
|
9230
|
-
`M ${f(cx)},${f(cy + hh)} Q ${f(cx - bulge)},${f(cy + bulge)} ${f(cx - hw)},${f(cy)}`
|
|
9231
|
-
);
|
|
9232
|
-
paths.push(
|
|
9233
|
-
`M ${f(cx - hw)},${f(cy)} Q ${f(cx - bulge)},${f(cy - bulge)} ${f(cx)},${f(cy - hh)}`
|
|
9234
|
-
);
|
|
9235
|
-
}
|
|
9236
|
-
}
|
|
9237
|
-
return /* @__PURE__ */ jsx("g", { fill: "none", stroke: color, strokeWidth, children: paths.map((d, i) => /* @__PURE__ */ jsx("path", { d }, i)) });
|
|
9238
|
-
}
|
|
9239
|
-
var VARIANT_MAP = {
|
|
9240
|
-
"star8": Star8,
|
|
9241
|
-
"star6": Star6,
|
|
9242
|
-
"khatam": Khatam,
|
|
9243
|
-
"star10": Star10,
|
|
9244
|
-
"star12": Star12,
|
|
9245
|
-
"rosette-double": RosetteDouble,
|
|
9246
|
-
"rosette-filled": RosetteFilled,
|
|
9247
|
-
"seigaiha": Seigaiha,
|
|
9248
|
-
"greek-key": GreekKey,
|
|
9249
|
-
"celtic-knot": CelticKnot,
|
|
9250
|
-
"kolam": Kolam,
|
|
9251
|
-
"arch": Arch,
|
|
9252
|
-
"arabesque-vine": ArabesqueVine,
|
|
9253
|
-
"arabesque-net": ArabesqueNet
|
|
9254
|
-
};
|
|
9255
8827
|
var PatternTile = ({
|
|
9256
8828
|
variant = "star8",
|
|
9257
8829
|
size = 60,
|
|
@@ -9260,21 +8832,31 @@ var PatternTile = ({
|
|
|
9260
8832
|
className,
|
|
9261
8833
|
...rest
|
|
9262
8834
|
}) => {
|
|
9263
|
-
const
|
|
9264
|
-
|
|
8835
|
+
const tile = patternTileGeometry.variants[variant];
|
|
8836
|
+
const scale2 = size / patternTileGeometry.unit;
|
|
8837
|
+
const unitStrokeWidth = scale2 === 0 ? strokeWidth : strokeWidth / scale2;
|
|
8838
|
+
return /* @__PURE__ */ jsx("g", { className, ...domPassthrough(rest), children: /* @__PURE__ */ jsx("g", { transform: `scale(${scale2})`, fill: "none", stroke: color, strokeWidth: unitStrokeWidth, children: tile.elements.map((element, index) => {
|
|
8839
|
+
const opacity = "opacity" in element ? element.opacity : void 0;
|
|
8840
|
+
if ("d" in element) {
|
|
8841
|
+
return /* @__PURE__ */ jsx("path", { d: element.d, opacity }, index);
|
|
8842
|
+
}
|
|
8843
|
+
return /* @__PURE__ */ jsx(
|
|
8844
|
+
"circle",
|
|
8845
|
+
{
|
|
8846
|
+
cx: element.cx,
|
|
8847
|
+
cy: element.cy,
|
|
8848
|
+
r: element.r,
|
|
8849
|
+
fill: "filled" in element && element.filled ? color : "none",
|
|
8850
|
+
opacity
|
|
8851
|
+
},
|
|
8852
|
+
index
|
|
8853
|
+
);
|
|
8854
|
+
}) }) });
|
|
9265
8855
|
};
|
|
9266
8856
|
PatternTile.displayName = "PatternTile";
|
|
9267
8857
|
function getTileDimensions(variant, size) {
|
|
9268
|
-
|
|
9269
|
-
|
|
9270
|
-
}
|
|
9271
|
-
if (variant === "arch") {
|
|
9272
|
-
return { width: size, height: size * 1.5 };
|
|
9273
|
-
}
|
|
9274
|
-
if (variant === "arabesque-vine") {
|
|
9275
|
-
return { width: size, height: size * 1.2 };
|
|
9276
|
-
}
|
|
9277
|
-
return { width: size, height: size };
|
|
8858
|
+
const tile = patternTileGeometry.variants[variant];
|
|
8859
|
+
return { width: size, height: size * tile.height / patternTileGeometry.unit };
|
|
9278
8860
|
}
|
|
9279
8861
|
var colorClasses = {
|
|
9280
8862
|
default: "bg-primary",
|
|
@@ -9441,7 +9023,7 @@ var dotSizeClasses = {
|
|
|
9441
9023
|
md: "w-2.5 h-2.5",
|
|
9442
9024
|
lg: "w-3 h-3"
|
|
9443
9025
|
};
|
|
9444
|
-
var Radio =
|
|
9026
|
+
var Radio = React44__default.forwardRef(
|
|
9445
9027
|
({
|
|
9446
9028
|
label,
|
|
9447
9029
|
helperText,
|
|
@@ -9459,12 +9041,12 @@ var Radio = React43__default.forwardRef(
|
|
|
9459
9041
|
required,
|
|
9460
9042
|
...props
|
|
9461
9043
|
}, ref) => {
|
|
9462
|
-
const reactId =
|
|
9044
|
+
const reactId = React44__default.useId();
|
|
9463
9045
|
const baseId = id || `radio-${reactId}`;
|
|
9464
9046
|
const hasError = !!error;
|
|
9465
9047
|
const eventBus = useEventBus();
|
|
9466
|
-
const [selected, setSelected] =
|
|
9467
|
-
|
|
9048
|
+
const [selected, setSelected] = React44__default.useState(value);
|
|
9049
|
+
React44__default.useEffect(() => {
|
|
9468
9050
|
if (value !== void 0) setSelected(value);
|
|
9469
9051
|
}, [value]);
|
|
9470
9052
|
const pick = (next, e) => {
|
|
@@ -9614,7 +9196,7 @@ var thumbSizes = {
|
|
|
9614
9196
|
md: "w-4 h-4",
|
|
9615
9197
|
lg: "w-5 h-5"
|
|
9616
9198
|
};
|
|
9617
|
-
var RangeSlider =
|
|
9199
|
+
var RangeSlider = React44__default.forwardRef(
|
|
9618
9200
|
({
|
|
9619
9201
|
className,
|
|
9620
9202
|
min = 0,
|
|
@@ -9938,11 +9520,14 @@ function NativeSelect({
|
|
|
9938
9520
|
...props
|
|
9939
9521
|
}) {
|
|
9940
9522
|
const eventBus = useEventBus();
|
|
9523
|
+
const declarative = typeof onChange === "string" || typeof onValueChange === "string" || Boolean(action);
|
|
9524
|
+
const { displayValue, record } = useFieldDraft(value, declarative);
|
|
9941
9525
|
const generatedId = useId();
|
|
9942
9526
|
const fieldId = props.id ?? generatedId;
|
|
9943
9527
|
const errorId = error ? `${fieldId}-error` : void 0;
|
|
9944
9528
|
const describedBy = [props["aria-describedby"], errorId].filter(Boolean).join(" ") || void 0;
|
|
9945
9529
|
const handleChange = (e) => {
|
|
9530
|
+
if (declarative) record(e.target.value);
|
|
9946
9531
|
if (typeof onChange === "string") {
|
|
9947
9532
|
eventBus.emit(`UI:${onChange}`, { value: e.target.value });
|
|
9948
9533
|
} else {
|
|
@@ -9960,7 +9545,7 @@ function NativeSelect({
|
|
|
9960
9545
|
"select",
|
|
9961
9546
|
{
|
|
9962
9547
|
onChange: handleChange,
|
|
9963
|
-
value,
|
|
9548
|
+
value: displayValue,
|
|
9964
9549
|
className: cn(
|
|
9965
9550
|
"block w-full rounded-interactive border-[length:var(--border-width)] shadow-elevation-interactive interactive-border appearance-none",
|
|
9966
9551
|
"px-3 py-2 pr-10 text-sm text-foreground font-medium",
|
|
@@ -10006,6 +9591,8 @@ function RichSelect({
|
|
|
10006
9591
|
...rest
|
|
10007
9592
|
}) {
|
|
10008
9593
|
const eventBus = useEventBus();
|
|
9594
|
+
const declarative = typeof onChange === "string" || typeof onValueChange === "string" || Boolean(action);
|
|
9595
|
+
const { displayValue, record } = useFieldDraft(value, declarative);
|
|
10009
9596
|
const { t } = useTranslate();
|
|
10010
9597
|
const [open, setOpen] = useState(false);
|
|
10011
9598
|
const [search, setSearch] = useState("");
|
|
@@ -10019,7 +9606,7 @@ function RichSelect({
|
|
|
10019
9606
|
const errorId = error ? `${baseId}-error` : void 0;
|
|
10020
9607
|
const describedBy = [passthrough["aria-describedby"], errorId].filter(Boolean).join(" ") || void 0;
|
|
10021
9608
|
const optionId = (index) => `${baseId}-opt-${index}`;
|
|
10022
|
-
const selected = multiple ? Array.isArray(
|
|
9609
|
+
const selected = multiple ? Array.isArray(displayValue) ? displayValue : displayValue ? [displayValue] : [] : displayValue ? [displayValue] : [];
|
|
10023
9610
|
const all = flatOptions(options, groups);
|
|
10024
9611
|
const matches = (o) => !(searchable && search) || o.label.toLowerCase().includes(search.toLowerCase());
|
|
10025
9612
|
const useGroups = Boolean(groups && groups.length > 0);
|
|
@@ -10038,6 +9625,7 @@ function RichSelect({
|
|
|
10038
9625
|
returnFocusRef: triggerRef
|
|
10039
9626
|
});
|
|
10040
9627
|
const emitValue = (next) => {
|
|
9628
|
+
if (declarative) record(next);
|
|
10041
9629
|
if (typeof onChange === "string") {
|
|
10042
9630
|
eventBus.emit(`UI:${onChange}`, { value: next });
|
|
10043
9631
|
}
|
|
@@ -10061,7 +9649,7 @@ function RichSelect({
|
|
|
10061
9649
|
e.stopPropagation();
|
|
10062
9650
|
emitValue(multiple ? [] : "");
|
|
10063
9651
|
};
|
|
10064
|
-
|
|
9652
|
+
React44__default.useEffect(() => {
|
|
10065
9653
|
const handler = (e) => {
|
|
10066
9654
|
if (containerRef.current && !containerRef.current.contains(e.target)) {
|
|
10067
9655
|
closeList();
|
|
@@ -10275,7 +9863,7 @@ function RichSelect({
|
|
|
10275
9863
|
error && /* @__PURE__ */ jsx(Typography, { id: errorId, variant: "caption", color: "error", className: "mt-1", children: error })
|
|
10276
9864
|
] });
|
|
10277
9865
|
}
|
|
10278
|
-
var Select =
|
|
9866
|
+
var Select = React44__default.forwardRef(
|
|
10279
9867
|
(props, _ref) => {
|
|
10280
9868
|
const { multiple, searchable, clearable } = props;
|
|
10281
9869
|
if (multiple || searchable || clearable) {
|
|
@@ -10398,7 +9986,7 @@ var sizeStyles5 = {
|
|
|
10398
9986
|
md: "w-2.5 h-2.5",
|
|
10399
9987
|
lg: "w-3 h-3"
|
|
10400
9988
|
};
|
|
10401
|
-
var StatusDot =
|
|
9989
|
+
var StatusDot = React44__default.forwardRef(
|
|
10402
9990
|
({ className, status = "offline", pulse = false, size = "md", label, ...props }, ref) => {
|
|
10403
9991
|
const { t } = useTranslate();
|
|
10404
9992
|
return /* @__PURE__ */ jsx(
|
|
@@ -10425,7 +10013,7 @@ var StatusDot = React43__default.forwardRef(
|
|
|
10425
10013
|
}
|
|
10426
10014
|
);
|
|
10427
10015
|
StatusDot.displayName = "StatusDot";
|
|
10428
|
-
var Switch =
|
|
10016
|
+
var Switch = React44.forwardRef(
|
|
10429
10017
|
({
|
|
10430
10018
|
checked,
|
|
10431
10019
|
defaultChecked = false,
|
|
@@ -10440,12 +10028,12 @@ var Switch = React43.forwardRef(
|
|
|
10440
10028
|
...rest
|
|
10441
10029
|
}, ref) => {
|
|
10442
10030
|
const eventBus = useEventBus();
|
|
10443
|
-
const generatedId =
|
|
10031
|
+
const generatedId = React44.useId();
|
|
10444
10032
|
const switchId = id ?? generatedId;
|
|
10445
|
-
const [isChecked, setIsChecked] =
|
|
10033
|
+
const [isChecked, setIsChecked] = React44.useState(
|
|
10446
10034
|
checked !== void 0 ? checked : defaultChecked
|
|
10447
10035
|
);
|
|
10448
|
-
|
|
10036
|
+
React44.useEffect(() => {
|
|
10449
10037
|
if (checked !== void 0) {
|
|
10450
10038
|
setIsChecked(checked);
|
|
10451
10039
|
}
|
|
@@ -10545,20 +10133,20 @@ var TextHighlight = ({
|
|
|
10545
10133
|
"data-annotation-id": annotationId,
|
|
10546
10134
|
className: cn(baseStyles, typeStyles[highlightType], className),
|
|
10547
10135
|
onClick: () => {
|
|
10548
|
-
if (action) eventBus.emit(`UI:${action}`, { annotationId });
|
|
10136
|
+
if (action) eventBus.emit(`UI:${action}`, { ...annotationId !== void 0 ? { annotationId } : {} });
|
|
10549
10137
|
onClick?.();
|
|
10550
10138
|
},
|
|
10551
10139
|
onMouseEnter: () => {
|
|
10552
|
-
if (hoverEvent) eventBus.emit(`UI:${hoverEvent}`, { hovered: true, annotationId });
|
|
10140
|
+
if (hoverEvent) eventBus.emit(`UI:${hoverEvent}`, { hovered: true, ...annotationId !== void 0 ? { annotationId } : {} });
|
|
10553
10141
|
onMouseEnter?.();
|
|
10554
10142
|
},
|
|
10555
10143
|
onMouseLeave: () => {
|
|
10556
|
-
if (hoverEvent) eventBus.emit(`UI:${hoverEvent}`, { hovered: false, annotationId });
|
|
10144
|
+
if (hoverEvent) eventBus.emit(`UI:${hoverEvent}`, { hovered: false, ...annotationId !== void 0 ? { annotationId } : {} });
|
|
10557
10145
|
onMouseLeave?.();
|
|
10558
10146
|
},
|
|
10559
10147
|
onPointerDown: (e) => {
|
|
10560
10148
|
if (e.pointerType === "mouse") return;
|
|
10561
|
-
if (hoverEvent) eventBus.emit(`UI:${hoverEvent}`, { hovered: true, annotationId });
|
|
10149
|
+
if (hoverEvent) eventBus.emit(`UI:${hoverEvent}`, { hovered: true, ...annotationId !== void 0 ? { annotationId } : {} });
|
|
10562
10150
|
onMouseEnter?.();
|
|
10563
10151
|
},
|
|
10564
10152
|
role: "button",
|
|
@@ -10568,7 +10156,7 @@ var TextHighlight = ({
|
|
|
10568
10156
|
onKeyDown: (e) => {
|
|
10569
10157
|
if (e.key === "Enter" || e.key === " ") {
|
|
10570
10158
|
e.preventDefault();
|
|
10571
|
-
if (action) eventBus.emit(`UI:${action}`, { annotationId });
|
|
10159
|
+
if (action) eventBus.emit(`UI:${action}`, { ...annotationId !== void 0 ? { annotationId } : {} });
|
|
10572
10160
|
onClick?.();
|
|
10573
10161
|
}
|
|
10574
10162
|
},
|
|
@@ -10577,15 +10165,17 @@ var TextHighlight = ({
|
|
|
10577
10165
|
);
|
|
10578
10166
|
};
|
|
10579
10167
|
TextHighlight.displayName = "TextHighlight";
|
|
10580
|
-
var Textarea =
|
|
10581
|
-
({ className, label, helperText, error, onChange, action, onKeyDown, id, required, ...props }, ref) => {
|
|
10168
|
+
var Textarea = React44__default.forwardRef(
|
|
10169
|
+
({ className, label, helperText, error, onChange, action, onKeyDown, id, required, value, ...props }, ref) => {
|
|
10582
10170
|
const eventBus = useEventBus();
|
|
10583
|
-
const
|
|
10171
|
+
const { displayValue, record } = useFieldDraft(value, typeof onChange === "string");
|
|
10172
|
+
const generatedId = React44__default.useId();
|
|
10584
10173
|
const fieldId = id ?? generatedId;
|
|
10585
10174
|
const descriptionId = error || helperText ? `${fieldId}-description` : void 0;
|
|
10586
10175
|
const describedBy = [props["aria-describedby"], descriptionId].filter(Boolean).join(" ") || void 0;
|
|
10587
10176
|
const handleChange = (e) => {
|
|
10588
10177
|
if (typeof onChange === "string") {
|
|
10178
|
+
record(e.target.value);
|
|
10589
10179
|
eventBus.emit(`UI:${onChange}`, { value: e.target.value });
|
|
10590
10180
|
} else {
|
|
10591
10181
|
onChange?.(e);
|
|
@@ -10615,6 +10205,7 @@ var Textarea = React43__default.forwardRef(
|
|
|
10615
10205
|
className
|
|
10616
10206
|
),
|
|
10617
10207
|
...props,
|
|
10208
|
+
value: displayValue,
|
|
10618
10209
|
id: fieldId,
|
|
10619
10210
|
required,
|
|
10620
10211
|
"aria-required": required ? true : void 0,
|
|
@@ -10645,12 +10236,16 @@ var ThemeToggle = ({
|
|
|
10645
10236
|
className,
|
|
10646
10237
|
size = "md",
|
|
10647
10238
|
showLabel = false,
|
|
10239
|
+
switchToLightLabel,
|
|
10240
|
+
switchToDarkLabel,
|
|
10241
|
+
lightLabel,
|
|
10242
|
+
darkLabel,
|
|
10648
10243
|
...rest
|
|
10649
10244
|
}) => {
|
|
10650
10245
|
const { resolvedMode, toggleMode } = useTheme();
|
|
10651
10246
|
const { t } = useTranslate();
|
|
10652
10247
|
const isDark = resolvedMode === "dark";
|
|
10653
|
-
const switchLabel = isDark ? t("themeToggle.switchToLight") : t("themeToggle.switchToDark");
|
|
10248
|
+
const switchLabel = isDark ? switchToLightLabel ?? t("themeToggle.switchToLight") : switchToDarkLabel ?? t("themeToggle.switchToDark");
|
|
10654
10249
|
return /* @__PURE__ */ jsxs(
|
|
10655
10250
|
"button",
|
|
10656
10251
|
{
|
|
@@ -10682,7 +10277,7 @@ var ThemeToggle = ({
|
|
|
10682
10277
|
className: cn(iconSizes2[size], "text-foreground")
|
|
10683
10278
|
}
|
|
10684
10279
|
),
|
|
10685
|
-
showLabel && /* @__PURE__ */ jsx("span", { className: "text-sm font-medium", children: isDark ? t("themeToggle.light") : t("themeToggle.dark") })
|
|
10280
|
+
showLabel && /* @__PURE__ */ jsx("span", { className: "text-sm font-medium", children: isDark ? lightLabel ?? t("themeToggle.light") : darkLabel ?? t("themeToggle.dark") })
|
|
10686
10281
|
]
|
|
10687
10282
|
}
|
|
10688
10283
|
);
|
|
@@ -10747,7 +10342,7 @@ var iconNameMap = {
|
|
|
10747
10342
|
down: "trending-down",
|
|
10748
10343
|
flat: "arrow-right"
|
|
10749
10344
|
};
|
|
10750
|
-
var TrendIndicator =
|
|
10345
|
+
var TrendIndicator = React44__default.forwardRef(
|
|
10751
10346
|
({
|
|
10752
10347
|
className,
|
|
10753
10348
|
value,
|
|
@@ -10801,8 +10396,11 @@ var TypewriterText = ({
|
|
|
10801
10396
|
const [charCount, setCharCount] = useState(0);
|
|
10802
10397
|
const [started, setStarted] = useState(startDelay === 0);
|
|
10803
10398
|
const reducedMotion = usePrefersReducedMotion();
|
|
10804
|
-
const
|
|
10805
|
-
|
|
10399
|
+
const eventBus = useEventBus();
|
|
10400
|
+
const completeRef = useRef(() => void 0);
|
|
10401
|
+
completeRef.current = () => {
|
|
10402
|
+
if (onComplete) eventBus.emit(`UI:${onComplete}`, {});
|
|
10403
|
+
};
|
|
10806
10404
|
useEffect(() => {
|
|
10807
10405
|
if (startDelay <= 0) {
|
|
10808
10406
|
setStarted(true);
|
|
@@ -10823,7 +10421,7 @@ var TypewriterText = ({
|
|
|
10823
10421
|
useEffect(() => {
|
|
10824
10422
|
if (!started) return void 0;
|
|
10825
10423
|
if (reducedMotion || charCount >= safeText.length) {
|
|
10826
|
-
|
|
10424
|
+
completeRef.current();
|
|
10827
10425
|
return void 0;
|
|
10828
10426
|
}
|
|
10829
10427
|
const interval = window.setInterval(() => {
|
|
@@ -10888,6 +10486,12 @@ var VideoEmbed = ({
|
|
|
10888
10486
|
videoId,
|
|
10889
10487
|
src,
|
|
10890
10488
|
title,
|
|
10489
|
+
noVideoLabel,
|
|
10490
|
+
apiUnavailableMessage,
|
|
10491
|
+
invalidVideoMessage,
|
|
10492
|
+
playbackFailedMessage,
|
|
10493
|
+
notFoundMessage,
|
|
10494
|
+
notEmbeddableMessage,
|
|
10891
10495
|
autoplay = false,
|
|
10892
10496
|
controls = true,
|
|
10893
10497
|
start = 0,
|
|
@@ -10899,22 +10503,29 @@ var VideoEmbed = ({
|
|
|
10899
10503
|
}) => {
|
|
10900
10504
|
const eventBus = useEventBus();
|
|
10901
10505
|
const { t } = useTranslate();
|
|
10902
|
-
const hostRef =
|
|
10903
|
-
const
|
|
10904
|
-
|
|
10905
|
-
|
|
10506
|
+
const hostRef = React44.useRef(null);
|
|
10507
|
+
const errorMessages = {
|
|
10508
|
+
"videoEmbed.apiUnavailable": apiUnavailableMessage,
|
|
10509
|
+
"videoEmbed.invalidVideo": invalidVideoMessage,
|
|
10510
|
+
"videoEmbed.playbackFailed": playbackFailedMessage,
|
|
10511
|
+
"videoEmbed.notFound": notFoundMessage,
|
|
10512
|
+
"videoEmbed.notEmbeddable": notEmbeddableMessage
|
|
10513
|
+
};
|
|
10514
|
+
const announce = React44.useRef({ readyEvent, playEvent, errorEvent, eventBus, t, errorMessages });
|
|
10515
|
+
announce.current = { readyEvent, playEvent, errorEvent, eventBus, t, errorMessages };
|
|
10516
|
+
const fireReady = React44.useCallback((source) => {
|
|
10906
10517
|
const { readyEvent: ready, eventBus: bus } = announce.current;
|
|
10907
10518
|
if (ready) bus.emit(`UI:${ready}`, { source });
|
|
10908
10519
|
}, []);
|
|
10909
|
-
const firePlay =
|
|
10520
|
+
const firePlay = React44.useCallback((source) => {
|
|
10910
10521
|
const { playEvent: play, eventBus: bus } = announce.current;
|
|
10911
10522
|
if (play) bus.emit(`UI:${play}`, { source });
|
|
10912
10523
|
}, []);
|
|
10913
|
-
const fireError =
|
|
10914
|
-
const { errorEvent: failed, eventBus: bus, t: translate } = announce.current;
|
|
10915
|
-
if (failed) bus.emit(`UI:${failed}`, { error: translate(key), code });
|
|
10524
|
+
const fireError = React44.useCallback((key, code) => {
|
|
10525
|
+
const { errorEvent: failed, eventBus: bus, t: translate, errorMessages: messages } = announce.current;
|
|
10526
|
+
if (failed) bus.emit(`UI:${failed}`, { error: messages[key] || translate(key), code });
|
|
10916
10527
|
}, []);
|
|
10917
|
-
|
|
10528
|
+
React44.useEffect(() => {
|
|
10918
10529
|
const wrapper = hostRef.current;
|
|
10919
10530
|
if (!videoId || !wrapper) return;
|
|
10920
10531
|
const mount = document.createElement("div");
|
|
@@ -10955,7 +10566,7 @@ var VideoEmbed = ({
|
|
|
10955
10566
|
ref: hostRef,
|
|
10956
10567
|
className: frame,
|
|
10957
10568
|
role: "region",
|
|
10958
|
-
"aria-label": title
|
|
10569
|
+
"aria-label": title || t("aria.videoEmbed"),
|
|
10959
10570
|
"data-pattern": "video-embed"
|
|
10960
10571
|
}
|
|
10961
10572
|
);
|
|
@@ -10964,13 +10575,13 @@ var VideoEmbed = ({
|
|
|
10964
10575
|
"iframe",
|
|
10965
10576
|
{
|
|
10966
10577
|
src,
|
|
10967
|
-
title: title
|
|
10578
|
+
title: title || t("aria.videoEmbed"),
|
|
10968
10579
|
className: "border-0",
|
|
10969
10580
|
allow: "autoplay; encrypted-media; fullscreen; picture-in-picture",
|
|
10970
10581
|
allowFullScreen: true,
|
|
10971
10582
|
onLoad: () => fireReady(src)
|
|
10972
10583
|
}
|
|
10973
|
-
) : /* @__PURE__ */ jsx("span", { children: t("videoEmbed.noVideo") }) });
|
|
10584
|
+
) : /* @__PURE__ */ jsx("span", { children: noVideoLabel || t("videoEmbed.noVideo") }) });
|
|
10974
10585
|
};
|
|
10975
10586
|
VideoEmbed.displayName = "VideoEmbed";
|
|
10976
10587
|
function buildForkPaths(x, y, branches, scale2) {
|
|
@@ -11136,7 +10747,7 @@ var SvgFlow = ({
|
|
|
11136
10747
|
...rest
|
|
11137
10748
|
}) => {
|
|
11138
10749
|
const a11y = domPassthrough(rest);
|
|
11139
|
-
const markerId =
|
|
10750
|
+
const markerId = React44__default.useMemo(() => {
|
|
11140
10751
|
flowIdCounter += 1;
|
|
11141
10752
|
return `almadar-flow-arrow-${flowIdCounter}`;
|
|
11142
10753
|
}, []);
|
|
@@ -11688,7 +11299,7 @@ var SvgRing = ({
|
|
|
11688
11299
|
...rest
|
|
11689
11300
|
}) => {
|
|
11690
11301
|
const a11y = domPassthrough(rest);
|
|
11691
|
-
const gradientId =
|
|
11302
|
+
const gradientId = React44__default.useMemo(() => {
|
|
11692
11303
|
ringIdCounter += 1;
|
|
11693
11304
|
return `almadar-ring-glow-${ringIdCounter}`;
|
|
11694
11305
|
}, []);
|
|
@@ -11874,4 +11485,4 @@ function stripMeta(obj) {
|
|
|
11874
11485
|
return result;
|
|
11875
11486
|
}
|
|
11876
11487
|
|
|
11877
|
-
export { AnimatedGraphic, AnimatedReveal, Aside, AtlasImage, AtlasPanel, Avatar, BAND_ACCENT_FALLBACK, BAND_EDGE_FILL, BAND_SHAPES, BUILT_IN_THEMES, Badge, Box, Button, CONFETTI_BURST_KEYFRAMES, CONFETTI_COLORS, Card, CardBody, CardContent, CardFooter, CardHeader, CardTitle, Center, Checkbox, ConditionalWrapper, ConfettiEffect, DEFAULT_CURRENCY, DayCell, Dialog, Divider, EventBusContext, EventBusProvider, FilterPill, FlipContainer, GameIcon, HStack, I18nProvider, INLINE_TEXT_ATTR, Icon, Image2 as Image, InfiniteScrollSentinel, Input, Label, LawReferenceTooltip, NavStackProvider, NavStackRouterBridge, NavigationProvider, Overlay, PatternTile, PendingScopeContext, Presence, ProgressBar, Radio, RangeSlider, STRETCHED_ABOVE, STRETCHED_CONTROL, SVG_MOTION_CLASSES, SectionHeader, Select, Spacer, Sparkline, Spinner, Stack, StatusDot, SurfaceBoundary, SvgBranch, SvgConnection, SvgFlow, SvgGrid, SvgLobe, SvgMesh, SvgMorph, SvgNode, SvgPulse, SvgRing, SvgShield, SvgStack, Switch, THEME_SCALE_KEYS, TextHighlight, Textarea, ThemeProvider, ThemeScopeContext, ThemeToggle, TimeSlotCell, TraitScopeProvider, TrendIndicator, TypewriterText, Typography, VStack, VideoEmbed, atlasFailed, atlasUrlOf, bandEdgeHeight, bandEdgeLayerStyle, bandEdgeMask, bandPadding, beginPending, blit, cn, compareCellValues, coreMessages3 as coreMessages, createConfettiParticles, createTraitPresence, createTranslate, cssTimeMs, domPassthrough, endPending, entriesFor, evaluateBinding, evaluateBindings, extractRouteParams, findPageByName, findPageByPath, followHref, formatDate, formatDateTime, formatTime, formatValue, fxHash01, fxLifecycle, getAllPages, getAtlas, getCurrentIconFamily, getDefaultPage, getGlobalEventBus, getTileDimensions, getTraitPresence, guardsHold, isAbsoluteHref, isAtlasAsset, isInertNavStack, isMotionEnabled, isPending, isSpriteSheetAtlas, kebabToPascal, keyInViewerMode, layoutScale, localeMeta, lucideIconKey, matchNavPage, mergeMessages, motionTiming, navLabelsFromItems, newPendingKey, pageEntryLabel, parseCalendarDate, pathMatches, presenceGroup, pressableProps, previousEntry, registryKeyMode, registryKeyTheme, relabelCurrent, resolveAssetSource, resolveEntryLabels, resolveFxView, resolveIcon, resolveIconForFamily, resolveLucideByName, rowActivationProps, rowOpenControlProps, setGlobalEventBus, sortRows, subRectFor, subscribePending, svgMotionClass, syncNavStack, themeHasMode, toDateInputValue, toDateTimeInputValue, useActivePage, useAnimateChanges, useAtlasSliceDataUrl, useContentSurface, useDialogBehavior, useEmitEvent, useEventBus, useEventListener, useEventSubscription, useFormatContext, useIconFamily, useInfiniteScroll, useInitPayload, useMediaQuery, useNavStack, useNavigateTo, useNavigation, useNavigationId, useNavigationState, useOnSurface, usePendingAction, usePendingRows, usePendingScopeValue, usePrefersReducedMotion, usePresence, useRenderI18n, useResolvedIcon, useRootEventBus, useScopeHasPending, useScopedMode, useTapReveal, useTheme, useThemeIconStrokeApplies, useThemeScope, useTraitScope, useTraitScopeChain, useTranslate };
|
|
11488
|
+
export { AnimatedGraphic, AnimatedReveal, Aside, AtlasImage, AtlasPanel, Avatar, BAND_ACCENT_FALLBACK, BAND_EDGE_FILL, BAND_SHAPES, BUILT_IN_THEMES, Badge, Box, Button, CONFETTI_BURST_KEYFRAMES, CONFETTI_COLORS, Card, CardBody, CardContent, CardFooter, CardHeader, CardTitle, Center, Checkbox, ConditionalWrapper, ConfettiEffect, DEFAULT_CURRENCY, DayCell, Dialog, Divider, EventBusContext, EventBusProvider, FilterPill, FlipContainer, GameIcon, HStack, I18nProvider, INLINE_TEXT_ATTR, Icon, Image2 as Image, InfiniteScrollSentinel, Input, Label, LawReferenceTooltip, NavStackProvider, NavStackRouterBridge, NavigationProvider, Overlay, PatternTile, PendingScopeContext, Presence, ProgressBar, Radio, RangeSlider, STRETCHED_ABOVE, STRETCHED_CONTROL, SVG_MOTION_CLASSES, SectionHeader, Select, Spacer, Sparkline, Spinner, Stack, StatusDot, SurfaceBoundary, SvgBranch, SvgConnection, SvgFlow, SvgGrid, SvgLobe, SvgMesh, SvgMorph, SvgNode, SvgPulse, SvgRing, SvgShield, SvgStack, Switch, THEME_SCALE_KEYS, TextHighlight, Textarea, ThemeProvider, ThemeScopeContext, ThemeToggle, TimeSlotCell, TraitScopeProvider, TrendIndicator, TypewriterText, Typography, VStack, VideoEmbed, atlasFailed, atlasUrlOf, bandEdgeHeight, bandEdgeLayerStyle, bandEdgeMask, bandPadding, beginPending, blit, boxesOf2 as boxesOf, cn, compareCellValues, coreMessages3 as coreMessages, createConfettiParticles, createTraitPresence, createTranslate, cssTimeMs, domPassthrough, endPending, entriesFor, evaluateBinding, evaluateBindings, extractRouteParams, findPageByName, findPageByPath, followHref, formatDate, formatDateTime, formatTime, formatValue, fxHash01, fxLifecycle, getAllPages, getAtlas, getCurrentIconFamily, getDefaultPage, getGlobalEventBus, getTileDimensions, getTraitPresence, guardsHold, isAbsoluteHref, isAtlasAsset, isInertNavStack, isMotionEnabled, isPending, isSpriteSheetAtlas, kebabToPascal, keyInViewerMode, layoutScale, localeMeta, lucideIconKey, matchNavPage, mergeMessages, motionTiming, navLabelsFromItems, newPendingKey, pageEntryLabel, parseCalendarDate, pathMatches, presenceGroup, pressableProps, previousEntry, registryKeyMode, registryKeyTheme, relabelCurrent, resolveAssetSource, resolveEntryLabels, resolveFxView, resolveIcon, resolveIconForFamily, resolveLucideByName, rowActivationProps, rowOpenControlProps, setGlobalEventBus, sortRows, subRectFor, subscribePending, svgMotionClass, syncNavStack, themeHasMode, toDateInputValue, toDateTimeInputValue, useActivePage, useAnimateChanges, useAtlasSliceDataUrl, useContentSurface, useDialogBehavior, useEmitEvent, useEventBus, useEventListener, useEventSubscription, useFormatContext, useIconFamily, useInfiniteScroll, useInitPayload, useMediaQuery, useNavStack, useNavigateTo, useNavigation, useNavigationId, useNavigationState, useOnSurface, usePendingAction, usePendingRows, usePendingScopeValue, usePrefersReducedMotion, usePresence, useRenderI18n, useResolvedIcon, useRootEventBus, useScopeHasPending, useScopedMode, useTapReveal, useTheme, useThemeIconStrokeApplies, useThemeScope, useTraitScope, useTraitScopeChain, useTranslate };
|