@arcanejs/toolkit 1.1.1 → 3.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/backend/components/base.d.mts +10 -79
- package/dist/backend/components/base.d.ts +10 -79
- package/dist/backend/components/base.js +2 -2
- package/dist/backend/components/base.mjs +1 -1
- package/dist/backend/components/button.d.mts +9 -33
- package/dist/backend/components/button.d.ts +9 -33
- package/dist/backend/components/button.js +3 -3
- package/dist/backend/components/button.mjs +2 -2
- package/dist/backend/components/group.d.mts +9 -54
- package/dist/backend/components/group.d.ts +9 -54
- package/dist/backend/components/group.js +3 -3
- package/dist/backend/components/group.mjs +2 -2
- package/dist/backend/components/label.d.mts +6 -2
- package/dist/backend/components/label.d.ts +6 -2
- package/dist/backend/components/label.js +3 -3
- package/dist/backend/components/label.mjs +2 -2
- package/dist/backend/components/rect.d.mts +7 -2
- package/dist/backend/components/rect.d.ts +7 -2
- package/dist/backend/components/rect.js +3 -3
- package/dist/backend/components/rect.mjs +2 -2
- package/dist/backend/components/slider-button.d.mts +8 -3
- package/dist/backend/components/slider-button.d.ts +8 -3
- package/dist/backend/components/slider-button.js +3 -3
- package/dist/backend/components/slider-button.mjs +2 -2
- package/dist/backend/components/switch.d.mts +8 -3
- package/dist/backend/components/switch.d.ts +8 -3
- package/dist/backend/components/switch.js +3 -3
- package/dist/backend/components/switch.mjs +2 -2
- package/dist/backend/components/tabs.d.mts +7 -2
- package/dist/backend/components/tabs.d.ts +7 -2
- package/dist/backend/components/tabs.js +3 -3
- package/dist/backend/components/tabs.mjs +2 -2
- package/dist/backend/components/text-input.d.mts +8 -3
- package/dist/backend/components/text-input.d.ts +8 -3
- package/dist/backend/components/text-input.js +3 -3
- package/dist/backend/components/text-input.mjs +2 -2
- package/dist/backend/components/timeline.d.mts +7 -2
- package/dist/backend/components/timeline.d.ts +7 -2
- package/dist/backend/components/timeline.js +3 -3
- package/dist/backend/components/timeline.mjs +2 -2
- package/dist/{chunk-HNFNG5MD.js → chunk-4OZ22IQU.js} +5 -5
- package/dist/{chunk-5TGGF5UJ.mjs → chunk-5D7OSUZ6.mjs} +3 -3
- package/dist/{chunk-T4TMVBFM.js → chunk-6CWEURJP.js} +2 -2
- package/dist/{chunk-5JPYL5IU.js → chunk-7OX2FB6C.js} +2 -2
- package/dist/{chunk-PXYXUWXE.mjs → chunk-7TTY7CBH.mjs} +1 -1
- package/dist/{chunk-SIXWXDZW.js → chunk-CME7HZZK.js} +5 -5
- package/dist/{chunk-OAPIVG6M.mjs → chunk-CUZSHFDP.mjs} +1 -1
- package/dist/{chunk-ZLJECS4H.js → chunk-DG75CS7F.js} +5 -5
- package/dist/{chunk-V5T44HCM.js → chunk-DRQVYGTI.js} +2 -2
- package/dist/{chunk-ARRRZPUK.js → chunk-GMDJYFHD.js} +3 -3
- package/dist/{chunk-IBIEYR3L.mjs → chunk-JFZXSCGK.mjs} +3 -3
- package/dist/{chunk-LX5IL6WX.mjs → chunk-K37TZB75.mjs} +1 -1
- package/dist/{chunk-BDBRQJSI.mjs → chunk-N6IHYBZH.mjs} +1 -1
- package/dist/{chunk-SBHNIFAS.mjs → chunk-NEQRLPXK.mjs} +3 -3
- package/dist/{chunk-TOPIQUBZ.js → chunk-O5ZW6JYG.js} +6 -6
- package/dist/{chunk-7SZA6JUN.mjs → chunk-RYR5I5FT.mjs} +6 -6
- package/dist/{chunk-ADH7RZG5.js → chunk-SGACFY53.js} +6 -6
- package/dist/{chunk-25LALCAN.js → chunk-VEZGD2PG.js} +5 -5
- package/dist/{chunk-EFNFSHV3.mjs → chunk-W42AOMM6.mjs} +3 -3
- package/dist/{chunk-ISHGZXPO.mjs → chunk-YBBUC3QC.mjs} +3 -3
- package/dist/frontend/entrypoint.js +492 -221
- package/dist/frontend/entrypoint.js.map +4 -4
- package/dist/frontend/index.js +242 -6
- package/dist/frontend/index.mjs +255 -19
- package/dist/index.d.mts +7 -111
- package/dist/index.d.ts +7 -111
- package/dist/index.js +65 -26
- package/dist/index.mjs +54 -15
- package/dist/toolkit-2w2SWHlT.d.ts +269 -0
- package/dist/toolkit-DB8G2TaA.d.mts +269 -0
- package/package.json +5 -4
|
@@ -1085,7 +1085,7 @@
|
|
|
1085
1085
|
}
|
|
1086
1086
|
return dispatcher.useContext(Context);
|
|
1087
1087
|
}
|
|
1088
|
-
function
|
|
1088
|
+
function useState7(initialState) {
|
|
1089
1089
|
var dispatcher = resolveDispatcher();
|
|
1090
1090
|
return dispatcher.useState(initialState);
|
|
1091
1091
|
}
|
|
@@ -1097,7 +1097,7 @@
|
|
|
1097
1097
|
var dispatcher = resolveDispatcher();
|
|
1098
1098
|
return dispatcher.useRef(initialValue);
|
|
1099
1099
|
}
|
|
1100
|
-
function
|
|
1100
|
+
function useEffect5(create, deps) {
|
|
1101
1101
|
var dispatcher = resolveDispatcher();
|
|
1102
1102
|
return dispatcher.useEffect(create, deps);
|
|
1103
1103
|
}
|
|
@@ -1880,7 +1880,7 @@
|
|
|
1880
1880
|
exports.useContext = useContext2;
|
|
1881
1881
|
exports.useDebugValue = useDebugValue;
|
|
1882
1882
|
exports.useDeferredValue = useDeferredValue;
|
|
1883
|
-
exports.useEffect =
|
|
1883
|
+
exports.useEffect = useEffect5;
|
|
1884
1884
|
exports.useId = useId;
|
|
1885
1885
|
exports.useImperativeHandle = useImperativeHandle;
|
|
1886
1886
|
exports.useInsertionEffect = useInsertionEffect;
|
|
@@ -1888,7 +1888,7 @@
|
|
|
1888
1888
|
exports.useMemo = useMemo3;
|
|
1889
1889
|
exports.useReducer = useReducer;
|
|
1890
1890
|
exports.useRef = useRef2;
|
|
1891
|
-
exports.useState =
|
|
1891
|
+
exports.useState = useState7;
|
|
1892
1892
|
exports.useSyncExternalStore = useSyncExternalStore;
|
|
1893
1893
|
exports.useTransition = useTransition;
|
|
1894
1894
|
exports.version = ReactVersion;
|
|
@@ -2832,10 +2832,10 @@
|
|
|
2832
2832
|
return jsxWithValidation(type, props, key, false);
|
|
2833
2833
|
}
|
|
2834
2834
|
}
|
|
2835
|
-
var
|
|
2835
|
+
var jsx13 = jsxWithValidationDynamic;
|
|
2836
2836
|
var jsxs7 = jsxWithValidationStatic;
|
|
2837
2837
|
exports.Fragment = REACT_FRAGMENT_TYPE;
|
|
2838
|
-
exports.jsx =
|
|
2838
|
+
exports.jsx = jsx13;
|
|
2839
2839
|
exports.jsxs = jsxs7;
|
|
2840
2840
|
})();
|
|
2841
2841
|
}
|
|
@@ -24524,8 +24524,14 @@
|
|
|
24524
24524
|
}
|
|
24525
24525
|
});
|
|
24526
24526
|
|
|
24527
|
-
// ../toolkit-frontend/dist/chunk-
|
|
24527
|
+
// ../toolkit-frontend/dist/chunk-E7JSREGM.mjs
|
|
24528
24528
|
var import_react = __toESM(require_react(), 1);
|
|
24529
|
+
var import_react2 = __toESM(require_react(), 1);
|
|
24530
|
+
var __defProp2 = Object.defineProperty;
|
|
24531
|
+
var __export = (target, all) => {
|
|
24532
|
+
for (var name in all)
|
|
24533
|
+
__defProp2(target, name, { get: all[name], enumerable: true });
|
|
24534
|
+
};
|
|
24529
24535
|
function switchToMouseMode(ev) {
|
|
24530
24536
|
if (ev.movementX === 0 && ev.movementY === 0) return;
|
|
24531
24537
|
document.body.classList.remove("touch-mode");
|
|
@@ -24543,7 +24549,7 @@
|
|
|
24543
24549
|
});
|
|
24544
24550
|
}
|
|
24545
24551
|
var usePressable = (click) => {
|
|
24546
|
-
const [touching, setTouching] = (0,
|
|
24552
|
+
const [touching, setTouching] = (0, import_react2.useState)(false);
|
|
24547
24553
|
return {
|
|
24548
24554
|
touching,
|
|
24549
24555
|
handlers: {
|
|
@@ -24589,13 +24595,6 @@
|
|
|
24589
24595
|
}
|
|
24590
24596
|
var calculateClass = (...args) => args.filter((a2) => !!a2).join(" ");
|
|
24591
24597
|
|
|
24592
|
-
// ../toolkit-frontend/dist/chunk-7P6ASYW6.mjs
|
|
24593
|
-
var __defProp2 = Object.defineProperty;
|
|
24594
|
-
var __export = (target, all) => {
|
|
24595
|
-
for (var name in all)
|
|
24596
|
-
__defProp2(target, name, { get: all[name], enumerable: true });
|
|
24597
|
-
};
|
|
24598
|
-
|
|
24599
24598
|
// ../../node_modules/.pnpm/tslib@2.6.2/node_modules/tslib/tslib.es6.mjs
|
|
24600
24599
|
var __assign = function() {
|
|
24601
24600
|
__assign = Object.assign || function __assign2(t) {
|
|
@@ -24636,7 +24635,7 @@
|
|
|
24636
24635
|
);
|
|
24637
24636
|
|
|
24638
24637
|
// ../../node_modules/.pnpm/styled-components@6.1.13_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/styled-components/dist/styled-components.browser.esm.js
|
|
24639
|
-
var
|
|
24638
|
+
var import_react3 = __toESM(require_react());
|
|
24640
24639
|
var import_shallowequal = __toESM(require_shallowequal());
|
|
24641
24640
|
|
|
24642
24641
|
// ../../node_modules/.pnpm/stylis@4.3.2/node_modules/stylis/src/Enum.js
|
|
@@ -25317,7 +25316,7 @@
|
|
|
25317
25316
|
console.error = function(t2) {
|
|
25318
25317
|
for (var n2 = [], o3 = 1; o3 < arguments.length; o3++) n2[o3 - 1] = arguments[o3];
|
|
25319
25318
|
E.test(t2) ? (a2 = false, N.delete(s2)) : i2.apply(void 0, __spreadArray([t2], n2, false));
|
|
25320
|
-
}, (0,
|
|
25319
|
+
}, (0, import_react3.useRef)(), a2 && !N.has(s2) && (console.warn(s2), N.add(s2));
|
|
25321
25320
|
} catch (e) {
|
|
25322
25321
|
E.test(e.message) && N.delete(s2);
|
|
25323
25322
|
} finally {
|
|
@@ -25655,26 +25654,26 @@
|
|
|
25655
25654
|
}
|
|
25656
25655
|
var Me = new ke();
|
|
25657
25656
|
var ze = Fe();
|
|
25658
|
-
var $e =
|
|
25657
|
+
var $e = import_react3.default.createContext({ shouldForwardProp: void 0, styleSheet: Me, stylis: ze });
|
|
25659
25658
|
var Be = $e.Consumer;
|
|
25660
|
-
var Le =
|
|
25659
|
+
var Le = import_react3.default.createContext(void 0);
|
|
25661
25660
|
function Ge() {
|
|
25662
|
-
return (0,
|
|
25661
|
+
return (0, import_react3.useContext)($e);
|
|
25663
25662
|
}
|
|
25664
25663
|
function Ye(e) {
|
|
25665
|
-
var t = (0,
|
|
25664
|
+
var t = (0, import_react3.useState)(e.stylisPlugins), n = t[0], r2 = t[1], c2 = Ge().styleSheet, l2 = (0, import_react3.useMemo)(function() {
|
|
25666
25665
|
var t2 = c2;
|
|
25667
25666
|
return e.sheet ? t2 = e.sheet : e.target && (t2 = t2.reconstructWithOptions({ target: e.target }, false)), e.disableCSSOMInjection && (t2 = t2.reconstructWithOptions({ useCSSOMInjection: false })), t2;
|
|
25668
|
-
}, [e.disableCSSOMInjection, e.sheet, e.target, c2]), u2 = (0,
|
|
25667
|
+
}, [e.disableCSSOMInjection, e.sheet, e.target, c2]), u2 = (0, import_react3.useMemo)(function() {
|
|
25669
25668
|
return Fe({ options: { namespace: e.namespace, prefix: e.enableVendorPrefixes }, plugins: n });
|
|
25670
25669
|
}, [e.enableVendorPrefixes, e.namespace, n]);
|
|
25671
|
-
(0,
|
|
25670
|
+
(0, import_react3.useEffect)(function() {
|
|
25672
25671
|
(0, import_shallowequal.default)(n, e.stylisPlugins) || r2(e.stylisPlugins);
|
|
25673
25672
|
}, [e.stylisPlugins]);
|
|
25674
|
-
var d = (0,
|
|
25673
|
+
var d = (0, import_react3.useMemo)(function() {
|
|
25675
25674
|
return { shouldForwardProp: e.shouldForwardProp, styleSheet: l2, stylis: u2 };
|
|
25676
25675
|
}, [e.shouldForwardProp, l2, u2]);
|
|
25677
|
-
return
|
|
25676
|
+
return import_react3.default.createElement($e.Provider, { value: d }, import_react3.default.createElement(Le.Provider, { value: u2 }, e.children));
|
|
25678
25677
|
}
|
|
25679
25678
|
var We = function() {
|
|
25680
25679
|
function e(e2, t) {
|
|
@@ -25766,10 +25765,10 @@
|
|
|
25766
25765
|
return o2;
|
|
25767
25766
|
}, e;
|
|
25768
25767
|
}();
|
|
25769
|
-
var et =
|
|
25768
|
+
var et = import_react3.default.createContext(void 0);
|
|
25770
25769
|
var tt = et.Consumer;
|
|
25771
25770
|
function ot(e) {
|
|
25772
|
-
var n =
|
|
25771
|
+
var n = import_react3.default.useContext(et), r2 = (0, import_react3.useMemo)(function() {
|
|
25773
25772
|
return function(e2, n2) {
|
|
25774
25773
|
if (!e2) throw he(14);
|
|
25775
25774
|
if (re(e2)) {
|
|
@@ -25781,7 +25780,7 @@
|
|
|
25781
25780
|
return n2 ? __assign(__assign({}, n2), e2) : e2;
|
|
25782
25781
|
}(e.theme, n);
|
|
25783
25782
|
}, [e.theme, n]);
|
|
25784
|
-
return e.children ?
|
|
25783
|
+
return e.children ? import_react3.default.createElement(et.Provider, { value: r2 }, e.children) : null;
|
|
25785
25784
|
}
|
|
25786
25785
|
var rt = {};
|
|
25787
25786
|
var st = /* @__PURE__ */ new Set();
|
|
@@ -25806,8 +25805,8 @@
|
|
|
25806
25805
|
var N2 = new Qe(s2, g2, i2 ? a2.componentStyle : void 0);
|
|
25807
25806
|
function O2(e2, r3) {
|
|
25808
25807
|
return function(e3, r4, s3) {
|
|
25809
|
-
var i3 = e3.attrs, a3 = e3.componentStyle, c3 = e3.defaultProps, p3 = e3.foldedComponentIds, d2 = e3.styledComponentId, h2 = e3.target, f3 =
|
|
25810
|
-
(0,
|
|
25808
|
+
var i3 = e3.attrs, a3 = e3.componentStyle, c3 = e3.defaultProps, p3 = e3.foldedComponentIds, d2 = e3.styledComponentId, h2 = e3.target, f3 = import_react3.default.useContext(et), m3 = Ge(), y3 = e3.shouldForwardProp || m3.shouldForwardProp;
|
|
25809
|
+
(0, import_react3.useDebugValue)(d2);
|
|
25811
25810
|
var v2 = I(r4, f3, c3) || C, g3 = function(e4, n, o2) {
|
|
25812
25811
|
for (var r5, s4 = __assign(__assign({}, n), { className: void 0, theme: o2 }), i4 = 0; i4 < e4.length; i4 += 1) {
|
|
25813
25812
|
var a4 = re(r5 = e4[i4]) ? r5(s4) : r5;
|
|
@@ -25818,15 +25817,15 @@
|
|
|
25818
25817
|
for (var b3 in g3) void 0 === g3[b3] || "$" === b3[0] || "as" === b3 || "theme" === b3 && g3.theme === v2 || ("forwardedAs" === b3 ? w3.as = g3.forwardedAs : y3 && !y3(b3, S3) || (w3[b3] = g3[b3], y3 || false || isPropValid(b3) || st.has(b3) || !A.has(S3) || (st.add(b3), console.warn('styled-components: it looks like an unknown prop "'.concat(b3, '" is being sent through to the DOM, which will likely trigger a React console error. If you would like automatic filtering of unknown props, you can opt-into that behavior via `<StyleSheetManager shouldForwardProp={...}>` (connect an API like `@emotion/is-prop-valid`) or consider using transient props (`$` prefix for automatic filtering.)')))));
|
|
25819
25818
|
var E3 = function(e4, t) {
|
|
25820
25819
|
var n = Ge(), o2 = e4.generateAndInjectStyles(t, n.styleSheet, n.stylis);
|
|
25821
|
-
return (0,
|
|
25820
|
+
return (0, import_react3.useDebugValue)(o2), o2;
|
|
25822
25821
|
}(a3, g3);
|
|
25823
25822
|
e3.warnTooManyClasses && e3.warnTooManyClasses(E3);
|
|
25824
25823
|
var N3 = ie(p3, d2);
|
|
25825
|
-
return E3 && (N3 += " " + E3), g3.className && (N3 += " " + g3.className), w3[L(S3) && !A.has(S3) ? "class" : "className"] = N3, w3.ref = s3, (0,
|
|
25824
|
+
return E3 && (N3 += " " + E3), g3.className && (N3 += " " + g3.className), w3[L(S3) && !A.has(S3) ? "class" : "className"] = N3, w3.ref = s3, (0, import_react3.createElement)(S3, w3);
|
|
25826
25825
|
}(D2, e2, r3);
|
|
25827
25826
|
}
|
|
25828
25827
|
O2.displayName = y2;
|
|
25829
|
-
var D2 =
|
|
25828
|
+
var D2 = import_react3.default.forwardRef(O2);
|
|
25830
25829
|
return D2.attrs = S2, D2.componentStyle = N2, D2.displayName = y2, D2.shouldForwardProp = w2, D2.foldedComponentIds = i2 ? ie(a2.foldedComponentIds, a2.styledComponentId) : "", D2.styledComponentId = g2, D2.target = i2 ? a2.target : e, Object.defineProperty(D2, "defaultProps", { get: function() {
|
|
25831
25830
|
return this._foldedDefaultProps;
|
|
25832
25831
|
}, set: function(e2) {
|
|
@@ -25897,10 +25896,10 @@
|
|
|
25897
25896
|
var i2 = lt.apply(void 0, __spreadArray([n], r2, false)), a2 = "sc-global-".concat($(JSON.stringify(i2))), c2 = new ht(i2, a2);
|
|
25898
25897
|
P(a2);
|
|
25899
25898
|
var l2 = function(e) {
|
|
25900
|
-
var t = Ge(), n2 =
|
|
25901
|
-
return
|
|
25899
|
+
var t = Ge(), n2 = import_react3.default.useContext(et), r3 = import_react3.default.useRef(t.styleSheet.allocateGSInstance(a2)).current;
|
|
25900
|
+
return import_react3.default.Children.count(e.children) && console.warn("The global style component ".concat(a2, " was given child JSX. createGlobalStyle does not render children.")), i2.some(function(e2) {
|
|
25902
25901
|
return "string" == typeof e2 && -1 !== e2.indexOf("@import");
|
|
25903
|
-
}) && console.warn("Please do not use @import CSS syntax in createGlobalStyle at this time, as the CSSOM APIs we use in production do not handle it well. Instead, we recommend using a library such as react-helmet to inject a typical <link> meta tag to the stylesheet, or simply embedding it manually in your index.html <head> section for a simpler app."), t.styleSheet.server && u2(r3, e, t.styleSheet, n2, t.stylis),
|
|
25902
|
+
}) && console.warn("Please do not use @import CSS syntax in createGlobalStyle at this time, as the CSSOM APIs we use in production do not handle it well. Instead, we recommend using a library such as react-helmet to inject a typical <link> meta tag to the stylesheet, or simply embedding it manually in your index.html <head> section for a simpler app."), t.styleSheet.server && u2(r3, e, t.styleSheet, n2, t.stylis), import_react3.default.useLayoutEffect(function() {
|
|
25904
25903
|
if (!t.styleSheet.server) return u2(r3, e, t.styleSheet, n2, t.stylis), function() {
|
|
25905
25904
|
return c2.removeStyles(r3, t.styleSheet);
|
|
25906
25905
|
};
|
|
@@ -25913,7 +25912,7 @@
|
|
|
25913
25912
|
c2.renderStyles(e, i3, o2, s3);
|
|
25914
25913
|
}
|
|
25915
25914
|
}
|
|
25916
|
-
return
|
|
25915
|
+
return import_react3.default.memo(l2);
|
|
25917
25916
|
}
|
|
25918
25917
|
var vt = function() {
|
|
25919
25918
|
function e() {
|
|
@@ -25932,14 +25931,14 @@
|
|
|
25932
25931
|
var r2 = e2.instance.toString();
|
|
25933
25932
|
if (!r2) return [];
|
|
25934
25933
|
var s2 = ((n = {})[f] = "", n[y] = v, n.dangerouslySetInnerHTML = { __html: r2 }, n), i2 = Ce();
|
|
25935
|
-
return i2 && (s2.nonce = i2), [
|
|
25934
|
+
return i2 && (s2.nonce = i2), [import_react3.default.createElement("style", __assign({}, s2, { key: "sc-0-0" }))];
|
|
25936
25935
|
}, this.seal = function() {
|
|
25937
25936
|
e2.sealed = true;
|
|
25938
25937
|
}, this.instance = new ke({ isServer: true }), this.sealed = false;
|
|
25939
25938
|
}
|
|
25940
25939
|
return e.prototype.collectStyles = function(e2) {
|
|
25941
25940
|
if (this.sealed) throw he(2);
|
|
25942
|
-
return
|
|
25941
|
+
return import_react3.default.createElement(Ye, { sheet: this.instance }, e2);
|
|
25943
25942
|
}, e.prototype.interleaveWithNodeStream = function(e2) {
|
|
25944
25943
|
throw he(3);
|
|
25945
25944
|
}, e;
|
|
@@ -25948,7 +25947,7 @@
|
|
|
25948
25947
|
var St = "__sc-".concat(f, "__");
|
|
25949
25948
|
"undefined" != typeof window && (window[St] || (window[St] = 0), 1 === window[St] && console.warn("It looks like there are several instances of 'styled-components' initialized in this application. This may cause dynamic styles to not render properly, errors during the rehydration process, a missing theme prop, and makes your application bigger without good reason.\n\nSee https://s-c.sh/2BAXzed for more info."), window[St] += 1);
|
|
25950
25949
|
|
|
25951
|
-
// ../toolkit-frontend/dist/chunk-
|
|
25950
|
+
// ../toolkit-frontend/dist/chunk-MESQQRK3.mjs
|
|
25952
25951
|
var import_jsx_runtime = __toESM(require_jsx_runtime(), 1);
|
|
25953
25952
|
var core_exports = {};
|
|
25954
25953
|
__export(core_exports, {
|
|
@@ -25983,7 +25982,8 @@
|
|
|
25983
25982
|
`;
|
|
25984
25983
|
var TRANSPARENCY_SVG_URI = `data:image/svg+xml,${encodeURIComponent(TRANSPARENCY_SVG)}`;
|
|
25985
25984
|
|
|
25986
|
-
// ../toolkit-frontend/dist/chunk-
|
|
25985
|
+
// ../toolkit-frontend/dist/chunk-BQS6YM6U.mjs
|
|
25986
|
+
var import_jsx_runtime2 = __toESM(require_jsx_runtime(), 1);
|
|
25987
25987
|
var GlobalStyle = ft`
|
|
25988
25988
|
body {
|
|
25989
25989
|
&.touch-mode * {
|
|
@@ -25991,7 +25991,8 @@ body {
|
|
|
25991
25991
|
}
|
|
25992
25992
|
}
|
|
25993
25993
|
`;
|
|
25994
|
-
var
|
|
25994
|
+
var DARK_THEME = {
|
|
25995
|
+
pageBg: "#333",
|
|
25995
25996
|
colorGreen: "#98c379",
|
|
25996
25997
|
colorRed: "#e06c75",
|
|
25997
25998
|
colorAmber: "#d19a66",
|
|
@@ -26006,19 +26007,64 @@ body {
|
|
|
26006
26007
|
hintRGB: "66, 134, 244",
|
|
26007
26008
|
hintDark1: "#2a77f3",
|
|
26008
26009
|
textNormal: "#F3F3F5",
|
|
26010
|
+
textActive: "#ffffff",
|
|
26009
26011
|
textMuted: "#777777",
|
|
26012
|
+
shadows: {
|
|
26013
|
+
boxShadowInset: "inset 0px 0px 8px 0px rgba(0, 0, 0, 0.3)",
|
|
26014
|
+
textShadow: "0 -1px rgba(0, 0, 0, 0.7)",
|
|
26015
|
+
textShadowActive: "0 -1px rgba(0, 0, 0, 0.4)"
|
|
26016
|
+
},
|
|
26017
|
+
gradients: {
|
|
26018
|
+
button: "linear-gradient(to bottom, #4f5053, #343436)",
|
|
26019
|
+
buttonHover: "linear-gradient(to bottom, #5e6064, #393a3b)",
|
|
26020
|
+
buttonActive: "linear-gradient(to bottom, #242525, #37383a)",
|
|
26021
|
+
buttonPressedHover: "linear-gradient(to bottom, #282929, #414243)",
|
|
26022
|
+
hintPressed: "linear-gradient(to bottom,#2a77f3,#4286f4)"
|
|
26023
|
+
},
|
|
26010
26024
|
sizingPx: {
|
|
26011
26025
|
spacing: 15,
|
|
26012
26026
|
unitHeight: 40
|
|
26013
26027
|
}
|
|
26014
26028
|
};
|
|
26029
|
+
var LIGHT_THEME = {
|
|
26030
|
+
pageBg: "#f8f9fa",
|
|
26031
|
+
colorGreen: "#22863a",
|
|
26032
|
+
colorRed: "#d73a49",
|
|
26033
|
+
colorAmber: "#b08800",
|
|
26034
|
+
bgDark1: "#e9ecef",
|
|
26035
|
+
bg: "#ffffff",
|
|
26036
|
+
bgLight1: "#f5f5f5",
|
|
26037
|
+
borderDark: "#c7c7c7",
|
|
26038
|
+
borderLight: "#d7d7d7",
|
|
26039
|
+
borderLighter: "#eaecef",
|
|
26040
|
+
borderLighterer: "#f6f8fa",
|
|
26041
|
+
hint: "#4286f4",
|
|
26042
|
+
hintRGB: "0, 92, 197",
|
|
26043
|
+
hintDark1: "#2a77f3",
|
|
26044
|
+
textNormal: "#24292e",
|
|
26045
|
+
textActive: "#202020",
|
|
26046
|
+
textMuted: "#6a737d",
|
|
26047
|
+
shadows: {
|
|
26048
|
+
boxShadowInset: "inset 0px 0px 8px 0px rgba(0, 0, 0, 0.05)",
|
|
26049
|
+
textShadow: "0 1px rgba(255, 255, 255, 0.7)",
|
|
26050
|
+
textShadowActive: "0 1px rgba(255, 255, 255, 0.4)"
|
|
26051
|
+
},
|
|
26052
|
+
gradients: {
|
|
26053
|
+
button: "linear-gradient(to bottom, #e1e4e8, #d1d5da)",
|
|
26054
|
+
buttonHover: "linear-gradient(to bottom, #d1d5da, #c1c6cc)",
|
|
26055
|
+
buttonActive: "linear-gradient(to bottom, #b1b6bc, #d2d6da)",
|
|
26056
|
+
buttonPressedHover: "linear-gradient(to bottom, #a1a6ac, #91969c)",
|
|
26057
|
+
hintPressed: "linear-gradient(to bottom, #438bff, #85b3ff)"
|
|
26058
|
+
},
|
|
26059
|
+
sizingPx: DARK_THEME.sizingPx
|
|
26060
|
+
};
|
|
26015
26061
|
var BaseStyle = ft`
|
|
26016
26062
|
* {
|
|
26017
26063
|
box-sizing: border-box;
|
|
26018
26064
|
}
|
|
26019
26065
|
|
|
26020
26066
|
body {
|
|
26021
|
-
background:
|
|
26067
|
+
background: ${(p2) => p2.theme.pageBg};
|
|
26022
26068
|
margin: 0;
|
|
26023
26069
|
padding: 0;
|
|
26024
26070
|
font-size: 14px;
|
|
@@ -26027,8 +26073,8 @@ body {
|
|
|
26027
26073
|
`;
|
|
26028
26074
|
var buttonStateNormal = lt`
|
|
26029
26075
|
color: ${(p2) => p2.theme.textNormal};
|
|
26030
|
-
background:
|
|
26031
|
-
text-shadow:
|
|
26076
|
+
background: ${(p2) => p2.theme.gradients.button};
|
|
26077
|
+
text-shadow: ${(p2) => p2.theme.shadows.textShadow};
|
|
26032
26078
|
box-shadow:
|
|
26033
26079
|
inset 0 1px 0 rgba(255, 255, 255, 0.15),
|
|
26034
26080
|
0 1px 0 0 rgba(0, 0, 0, 0.25);
|
|
@@ -26036,14 +26082,14 @@ body {
|
|
|
26036
26082
|
var buttonStateNormalHover = lt`
|
|
26037
26083
|
color: ${(p2) => p2.theme.textNormal};
|
|
26038
26084
|
outline-color: rgba(243, 243, 245, 0.3);
|
|
26039
|
-
background:
|
|
26040
|
-
text-shadow:
|
|
26085
|
+
background: ${(p2) => p2.theme.gradients.buttonHover};
|
|
26086
|
+
text-shadow: ${(p2) => p2.theme.shadows.textShadow};
|
|
26041
26087
|
`;
|
|
26042
26088
|
var buttonStateNormalActive = lt`
|
|
26043
|
-
color:
|
|
26089
|
+
color: ${(p2) => p2.theme.textNormal};
|
|
26044
26090
|
outline-color: rgba(255, 255, 255, 0.3);
|
|
26045
|
-
background:
|
|
26046
|
-
text-shadow:
|
|
26091
|
+
background: ${(p2) => p2.theme.gradients.buttonActive};
|
|
26092
|
+
text-shadow: ${(p2) => p2.theme.shadows.textShadowActive};
|
|
26047
26093
|
box-shadow:
|
|
26048
26094
|
inset 0 1px 2px rgba(0, 0, 0, 0.2),
|
|
26049
26095
|
0 1px 0 0 rgba(255, 255, 255, 0.15);
|
|
@@ -26056,7 +26102,7 @@ body {
|
|
|
26056
26102
|
var buttonStatePressedHover = lt`
|
|
26057
26103
|
${buttonStateNormalActive}
|
|
26058
26104
|
box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.1), 0 1px 0 0 rgba(255,255,255,0.15);
|
|
26059
|
-
background:
|
|
26105
|
+
background: ${(p2) => p2.theme.gradients.buttonPressedHover};
|
|
26060
26106
|
`;
|
|
26061
26107
|
var buttonStatePressedActive = buttonStateNormalActive;
|
|
26062
26108
|
var buttonStateDisabled = lt`
|
|
@@ -26128,16 +26174,14 @@ body {
|
|
|
26128
26174
|
var isCoreComponent = (component) => component.namespace === "core";
|
|
26129
26175
|
|
|
26130
26176
|
// ../toolkit-frontend/dist/components/index.mjs
|
|
26131
|
-
var import_react3 = __toESM(require_react(), 1);
|
|
26132
26177
|
var import_react4 = __toESM(require_react(), 1);
|
|
26133
|
-
var import_jsx_runtime2 = __toESM(require_jsx_runtime(), 1);
|
|
26134
26178
|
var import_react5 = __toESM(require_react(), 1);
|
|
26135
|
-
var import_react6 = __toESM(require_react(), 1);
|
|
26136
26179
|
var import_jsx_runtime3 = __toESM(require_jsx_runtime(), 1);
|
|
26180
|
+
var import_react6 = __toESM(require_react(), 1);
|
|
26181
|
+
var import_react7 = __toESM(require_react(), 1);
|
|
26137
26182
|
var import_jsx_runtime4 = __toESM(require_jsx_runtime(), 1);
|
|
26138
26183
|
var import_jsx_runtime5 = __toESM(require_jsx_runtime(), 1);
|
|
26139
26184
|
var import_jsx_runtime6 = __toESM(require_jsx_runtime(), 1);
|
|
26140
|
-
var import_react7 = __toESM(require_react(), 1);
|
|
26141
26185
|
var import_jsx_runtime7 = __toESM(require_jsx_runtime(), 1);
|
|
26142
26186
|
var import_react8 = __toESM(require_react(), 1);
|
|
26143
26187
|
var import_jsx_runtime8 = __toESM(require_jsx_runtime(), 1);
|
|
@@ -26147,13 +26191,16 @@ body {
|
|
|
26147
26191
|
var import_jsx_runtime10 = __toESM(require_jsx_runtime(), 1);
|
|
26148
26192
|
var import_react11 = __toESM(require_react(), 1);
|
|
26149
26193
|
var import_jsx_runtime11 = __toESM(require_jsx_runtime(), 1);
|
|
26194
|
+
var import_react12 = __toESM(require_react(), 1);
|
|
26150
26195
|
var import_jsx_runtime12 = __toESM(require_jsx_runtime(), 1);
|
|
26151
|
-
var
|
|
26152
|
-
|
|
26153
|
-
|
|
26154
|
-
|
|
26155
|
-
|
|
26156
|
-
|
|
26196
|
+
var import_jsx_runtime13 = __toESM(require_jsx_runtime(), 1);
|
|
26197
|
+
var StageContext = (0, import_react5.createContext)(
|
|
26198
|
+
new Proxy({}, {
|
|
26199
|
+
get: () => {
|
|
26200
|
+
throw new Error("Missing StageContext.Provider");
|
|
26201
|
+
}
|
|
26202
|
+
})
|
|
26203
|
+
);
|
|
26157
26204
|
var TOUCH_INDICATOR_CLASS = "touch-indicator";
|
|
26158
26205
|
var TOUCHING_CLASS = "touching";
|
|
26159
26206
|
var ERROR_CLASS = "error";
|
|
@@ -26171,7 +26218,7 @@ body {
|
|
|
26171
26218
|
padding: 0 4px;
|
|
26172
26219
|
`;
|
|
26173
26220
|
var Button = (props) => {
|
|
26174
|
-
const { sendMessage } =
|
|
26221
|
+
const { sendMessage } = import_react4.default.useContext(StageContext);
|
|
26175
26222
|
const { touching, handlers } = usePressable(
|
|
26176
26223
|
() => sendMessage?.({
|
|
26177
26224
|
type: "component-message",
|
|
@@ -26181,7 +26228,7 @@ body {
|
|
|
26181
26228
|
})
|
|
26182
26229
|
);
|
|
26183
26230
|
const { state } = props.info;
|
|
26184
|
-
return /* @__PURE__ */ (0,
|
|
26231
|
+
return /* @__PURE__ */ (0, import_jsx_runtime3.jsxs)(
|
|
26185
26232
|
"div",
|
|
26186
26233
|
{
|
|
26187
26234
|
className: calculateClass(
|
|
@@ -26192,10 +26239,10 @@ body {
|
|
|
26192
26239
|
...handlers,
|
|
26193
26240
|
title: state.state === "error" ? state.error : void 0,
|
|
26194
26241
|
children: [
|
|
26195
|
-
/* @__PURE__ */ (0,
|
|
26196
|
-
/* @__PURE__ */ (0,
|
|
26197
|
-
props.info.icon && /* @__PURE__ */ (0,
|
|
26198
|
-
props.info.text && /* @__PURE__ */ (0,
|
|
26242
|
+
/* @__PURE__ */ (0, import_jsx_runtime3.jsx)("div", { className: TOUCH_INDICATOR_CLASS }),
|
|
26243
|
+
/* @__PURE__ */ (0, import_jsx_runtime3.jsxs)(ButtonContents, { children: [
|
|
26244
|
+
props.info.icon && /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(Icon, { icon: props.info.icon }),
|
|
26245
|
+
props.info.text && /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(ButtonLabel, { children: props.info.text })
|
|
26199
26246
|
] })
|
|
26200
26247
|
]
|
|
26201
26248
|
}
|
|
@@ -26213,8 +26260,8 @@ body {
|
|
|
26213
26260
|
}
|
|
26214
26261
|
|
|
26215
26262
|
&.${ERROR_CLASS} {
|
|
26216
|
-
color: ${
|
|
26217
|
-
border-color: ${
|
|
26263
|
+
color: ${(p2) => p2.theme.colorRed};
|
|
26264
|
+
border-color: ${(p2) => p2.theme.colorRed};
|
|
26218
26265
|
}
|
|
26219
26266
|
|
|
26220
26267
|
&.${TOUCHING_CLASS} {
|
|
@@ -26235,26 +26282,26 @@ body {
|
|
|
26235
26282
|
return "dark";
|
|
26236
26283
|
}
|
|
26237
26284
|
}
|
|
26238
|
-
var LastNestedColor =
|
|
26285
|
+
var LastNestedColor = import_react7.default.createContext("dark");
|
|
26239
26286
|
var NestedContent = ({ className, children }) => {
|
|
26240
|
-
const color =
|
|
26241
|
-
return /* @__PURE__ */ (0,
|
|
26287
|
+
const color = import_react7.default.useContext(LastNestedColor);
|
|
26288
|
+
return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)("div", { className: calculateClass(className, `color-${color}`), children: /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(LastNestedColor.Provider, { value: nextColor(color), children }) });
|
|
26242
26289
|
};
|
|
26243
26290
|
NestedContent.displayName = "NestedContent";
|
|
26244
26291
|
var StyledNestedContent = dt(NestedContent)`
|
|
26245
|
-
padding: ${
|
|
26246
|
-
box-shadow:
|
|
26292
|
+
padding: ${(p2) => p2.theme.sizingPx.spacing / 2}px;
|
|
26293
|
+
box-shadow: ${(p2) => p2.theme.shadows.boxShadowInset};
|
|
26247
26294
|
|
|
26248
26295
|
&.color-dark {
|
|
26249
|
-
background: ${
|
|
26296
|
+
background: ${(p2) => p2.theme.bgDark1};
|
|
26250
26297
|
}
|
|
26251
26298
|
|
|
26252
26299
|
&.color-lighter {
|
|
26253
|
-
background: ${
|
|
26300
|
+
background: ${(p2) => p2.theme.bg};
|
|
26254
26301
|
}
|
|
26255
26302
|
|
|
26256
26303
|
&.color-lighterer {
|
|
26257
|
-
background: ${
|
|
26304
|
+
background: ${(p2) => p2.theme.bgLight1};
|
|
26258
26305
|
}
|
|
26259
26306
|
`;
|
|
26260
26307
|
var CollapseIcon = dt(Icon)({
|
|
@@ -26264,11 +26311,11 @@ body {
|
|
|
26264
26311
|
display: flex;
|
|
26265
26312
|
align-items: center;
|
|
26266
26313
|
padding: 5px 2px;
|
|
26267
|
-
background: ${
|
|
26268
|
-
border-bottom: 1px solid ${
|
|
26314
|
+
background: ${(p2) => p2.theme.borderDark};
|
|
26315
|
+
border-bottom: 1px solid ${(p2) => p2.theme.borderDark};
|
|
26269
26316
|
|
|
26270
26317
|
&.touching {
|
|
26271
|
-
background: ${
|
|
26318
|
+
background: ${(p2) => p2.theme.bgDark1};
|
|
26272
26319
|
}
|
|
26273
26320
|
|
|
26274
26321
|
&.collapsed {
|
|
@@ -26282,8 +26329,8 @@ body {
|
|
|
26282
26329
|
var Label = dt.span`
|
|
26283
26330
|
display: inline-block;
|
|
26284
26331
|
border-radius: 3px;
|
|
26285
|
-
background: ${
|
|
26286
|
-
border: 1px solid ${
|
|
26332
|
+
background: ${(p2) => p2.theme.bg};
|
|
26333
|
+
border: 1px solid ${(p2) => p2.theme.bgLight1};
|
|
26287
26334
|
padding: 3px 4px;
|
|
26288
26335
|
`;
|
|
26289
26336
|
var Grow = dt.span({
|
|
@@ -26301,7 +26348,7 @@ body {
|
|
|
26301
26348
|
${(p2) => p2.info.direction === "vertical" ? "" : "align-items: center;"}
|
|
26302
26349
|
|
|
26303
26350
|
> * {
|
|
26304
|
-
margin: ${
|
|
26351
|
+
margin: ${(p2) => p2.theme.sizingPx.spacing / 2}px;
|
|
26305
26352
|
}
|
|
26306
26353
|
`;
|
|
26307
26354
|
var EditableTitle = dt.span`
|
|
@@ -26316,14 +26363,14 @@ body {
|
|
|
26316
26363
|
}
|
|
26317
26364
|
|
|
26318
26365
|
> .icon {
|
|
26319
|
-
color: ${
|
|
26366
|
+
color: ${(p2) => p2.theme.textMuted};
|
|
26320
26367
|
}
|
|
26321
26368
|
|
|
26322
26369
|
&:hover {
|
|
26323
|
-
background: ${
|
|
26370
|
+
background: ${(p2) => p2.theme.bg};
|
|
26324
26371
|
|
|
26325
26372
|
> .icon {
|
|
26326
|
-
color: ${
|
|
26373
|
+
color: ${(p2) => p2.theme.hint};
|
|
26327
26374
|
}
|
|
26328
26375
|
}
|
|
26329
26376
|
`;
|
|
@@ -26331,9 +26378,9 @@ body {
|
|
|
26331
26378
|
background: none;
|
|
26332
26379
|
border: none;
|
|
26333
26380
|
outline: none;
|
|
26334
|
-
color: ${
|
|
26381
|
+
color: ${(p2) => p2.theme.textNormal};
|
|
26335
26382
|
`;
|
|
26336
|
-
var GroupStateContext =
|
|
26383
|
+
var GroupStateContext = import_react6.default.createContext({
|
|
26337
26384
|
isCollapsed: () => {
|
|
26338
26385
|
throw new Error("missing GroupStateContext");
|
|
26339
26386
|
},
|
|
@@ -26342,7 +26389,7 @@ body {
|
|
|
26342
26389
|
}
|
|
26343
26390
|
});
|
|
26344
26391
|
var GroupStateWrapper = ({ openByDefault, children }) => {
|
|
26345
|
-
const [state, setState] = (0,
|
|
26392
|
+
const [state, setState] = (0, import_react6.useState)({});
|
|
26346
26393
|
const isCollapsed = (key, defaultState) => {
|
|
26347
26394
|
let match2 = state[key];
|
|
26348
26395
|
if (!match2) {
|
|
@@ -26360,13 +26407,13 @@ body {
|
|
|
26360
26407
|
[key]: current[key] === "closed" ? "open" : "closed"
|
|
26361
26408
|
}));
|
|
26362
26409
|
};
|
|
26363
|
-
return /* @__PURE__ */ (0,
|
|
26410
|
+
return /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(GroupStateContext.Provider, { value: { isCollapsed, toggleCollapsed }, children });
|
|
26364
26411
|
};
|
|
26365
26412
|
var Group = ({ className, info }) => {
|
|
26366
|
-
const groupState = (0,
|
|
26367
|
-
const { renderComponent, sendMessage } = (0,
|
|
26368
|
-
const [editingTitle, setEditingTitle] = (0,
|
|
26369
|
-
const children = /* @__PURE__ */ (0,
|
|
26413
|
+
const groupState = (0, import_react6.useContext)(GroupStateContext);
|
|
26414
|
+
const { renderComponent, sendMessage } = (0, import_react6.useContext)(StageContext);
|
|
26415
|
+
const [editingTitle, setEditingTitle] = (0, import_react6.useState)(false);
|
|
26416
|
+
const children = /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(GroupChildren, { info, children: info.children.map(renderComponent) });
|
|
26370
26417
|
const collapsible = !!info.defaultCollapsibleState;
|
|
26371
26418
|
const collapsed = info.defaultCollapsibleState ? groupState.isCollapsed(info.key, info.defaultCollapsibleState) : false;
|
|
26372
26419
|
const collapsePressable = usePressable(
|
|
@@ -26395,9 +26442,9 @@ body {
|
|
|
26395
26442
|
}
|
|
26396
26443
|
};
|
|
26397
26444
|
const hasBorder = info.border || displayHeader;
|
|
26398
|
-
const childrenElements = hasBorder ? /* @__PURE__ */ (0,
|
|
26399
|
-
return /* @__PURE__ */ (0,
|
|
26400
|
-
displayHeader ? /* @__PURE__ */ (0,
|
|
26445
|
+
const childrenElements = hasBorder ? /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(StyledNestedContent, { children }) : children;
|
|
26446
|
+
return /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)("div", { className: calculateClass(className, !hasBorder && "no-border"), children: [
|
|
26447
|
+
displayHeader ? /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)(
|
|
26401
26448
|
Header,
|
|
26402
26449
|
{
|
|
26403
26450
|
className: calculateClass(
|
|
@@ -26405,15 +26452,15 @@ body {
|
|
|
26405
26452
|
collapsible && collapsed && "collapsed"
|
|
26406
26453
|
),
|
|
26407
26454
|
children: [
|
|
26408
|
-
collapsible && /* @__PURE__ */ (0,
|
|
26455
|
+
collapsible && /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
|
|
26409
26456
|
CollapseIcon,
|
|
26410
26457
|
{
|
|
26411
26458
|
icon: collapsed ? "arrow_right" : "arrow_drop_down",
|
|
26412
26459
|
...collapsePressable.handlers
|
|
26413
26460
|
}
|
|
26414
26461
|
),
|
|
26415
|
-
info.labels?.map((l2) => /* @__PURE__ */ (0,
|
|
26416
|
-
showTitle && (info.editableTitle ? editingTitle ? /* @__PURE__ */ (0,
|
|
26462
|
+
info.labels?.map((l2) => /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(Label, { children: l2.text })),
|
|
26463
|
+
showTitle && (info.editableTitle ? editingTitle ? /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
|
|
26417
26464
|
TitleInput,
|
|
26418
26465
|
{
|
|
26419
26466
|
ref: (input) => input?.focus(),
|
|
@@ -26421,11 +26468,11 @@ body {
|
|
|
26421
26468
|
onKeyDown: keyDown,
|
|
26422
26469
|
defaultValue: info.title
|
|
26423
26470
|
}
|
|
26424
|
-
) : /* @__PURE__ */ (0,
|
|
26425
|
-
/* @__PURE__ */ (0,
|
|
26426
|
-
/* @__PURE__ */ (0,
|
|
26427
|
-
] }) : /* @__PURE__ */ (0,
|
|
26428
|
-
collapsible ? /* @__PURE__ */ (0,
|
|
26471
|
+
) : /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)(EditableTitle, { onClick: () => setEditingTitle(true), children: [
|
|
26472
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsx)("span", { children: info.title }),
|
|
26473
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsx)(Icon, { className: "icon", icon: "edit" })
|
|
26474
|
+
] }) : /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("span", { children: info.title })),
|
|
26475
|
+
collapsible ? /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(CollapseBar, { ...collapsePressable.handlers }) : /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(Grow, {}),
|
|
26429
26476
|
info.headers?.map((h) => h.children.map((c2) => renderComponent(c2)))
|
|
26430
26477
|
]
|
|
26431
26478
|
}
|
|
@@ -26435,12 +26482,12 @@ body {
|
|
|
26435
26482
|
};
|
|
26436
26483
|
Group.displayName = "Group";
|
|
26437
26484
|
var StyledGroup = dt(Group)`
|
|
26438
|
-
border: 1px solid ${
|
|
26485
|
+
border: 1px solid ${(p2) => p2.theme.borderDark};
|
|
26439
26486
|
|
|
26440
26487
|
> .title {
|
|
26441
26488
|
padding: 5px;
|
|
26442
|
-
background: ${
|
|
26443
|
-
border-bottom: 1px solid ${
|
|
26489
|
+
background: ${(p2) => p2.theme.borderDark};
|
|
26490
|
+
border-bottom: 1px solid ${(p2) => p2.theme.borderDark};
|
|
26444
26491
|
}
|
|
26445
26492
|
|
|
26446
26493
|
&.no-border {
|
|
@@ -26448,7 +26495,7 @@ body {
|
|
|
26448
26495
|
margin: 0 !important;
|
|
26449
26496
|
}
|
|
26450
26497
|
`;
|
|
26451
|
-
var Label2 = ({ className, info }) => /* @__PURE__ */ (0,
|
|
26498
|
+
var Label2 = ({ className, info }) => /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("div", { className, children: info.text });
|
|
26452
26499
|
var StyledLabel = dt(Label2)`
|
|
26453
26500
|
font-weight: ${(p2) => p2.info.bold ? "bold" : "normal"};
|
|
26454
26501
|
white-space: nowrap;
|
|
@@ -26462,7 +26509,7 @@ body {
|
|
|
26462
26509
|
background: url('${TRANSPARENCY_SVG_URI}');
|
|
26463
26510
|
background-repeat: repeat;
|
|
26464
26511
|
background-size: 10px;
|
|
26465
|
-
border: 1px solid ${
|
|
26512
|
+
border: 1px solid ${(p2) => p2.theme.borderDark};
|
|
26466
26513
|
|
|
26467
26514
|
&.${CLS_GROW} {
|
|
26468
26515
|
flex-grow: 1;
|
|
@@ -26472,7 +26519,7 @@ body {
|
|
|
26472
26519
|
width: 100%;
|
|
26473
26520
|
height: 100%;
|
|
26474
26521
|
`;
|
|
26475
|
-
var Rect = ({ className, info }) => /* @__PURE__ */ (0,
|
|
26522
|
+
var Rect = ({ className, info }) => /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(Wrapper, { className: calculateClass(className, info.grow && CLS_GROW), children: /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(Inner, { style: { backgroundColor: info.color } }) });
|
|
26476
26523
|
var CLASS_SLIDER_DISPLAY = "slider-display";
|
|
26477
26524
|
var CLASS_SLIDER_VALUE = "slider-value";
|
|
26478
26525
|
var CLASS_GRADIENT = "gradient";
|
|
@@ -26497,16 +26544,16 @@ body {
|
|
|
26497
26544
|
return pageX - rect.left;
|
|
26498
26545
|
};
|
|
26499
26546
|
var SliderButton = ({ info, className }) => {
|
|
26500
|
-
const { sendMessage } =
|
|
26501
|
-
const [state, setState] =
|
|
26502
|
-
const input =
|
|
26547
|
+
const { sendMessage } = import_react8.default.useContext(StageContext);
|
|
26548
|
+
const [state, setState] = import_react8.default.useState({ state: "closed" });
|
|
26549
|
+
const input = import_react8.default.useRef(null);
|
|
26503
26550
|
const displayValue = (value2) => {
|
|
26504
26551
|
if (info.max === 1 && info.min === 0) {
|
|
26505
26552
|
return `${Math.round(value2 * 100)}%`;
|
|
26506
26553
|
}
|
|
26507
26554
|
return NUMBER_FORMATTER.format(value2);
|
|
26508
26555
|
};
|
|
26509
|
-
const sendValue = (0,
|
|
26556
|
+
const sendValue = (0, import_react8.useCallback)(
|
|
26510
26557
|
(value2) => sendMessage?.({
|
|
26511
26558
|
type: "component-message",
|
|
26512
26559
|
namespace: "core",
|
|
@@ -26516,7 +26563,7 @@ body {
|
|
|
26516
26563
|
}),
|
|
26517
26564
|
[sendMessage, info.key]
|
|
26518
26565
|
);
|
|
26519
|
-
const sanitizeValue = (0,
|
|
26566
|
+
const sanitizeValue = (0, import_react8.useCallback)(
|
|
26520
26567
|
(value2) => {
|
|
26521
26568
|
const i2 = Math.round((value2 - info.min) / info.step);
|
|
26522
26569
|
const v2 = i2 * info.step + info.min;
|
|
@@ -26524,13 +26571,13 @@ body {
|
|
|
26524
26571
|
},
|
|
26525
26572
|
[info.min, info.max, info.step]
|
|
26526
26573
|
);
|
|
26527
|
-
const getNewValue = (0,
|
|
26574
|
+
const getNewValue = (0, import_react8.useCallback)(
|
|
26528
26575
|
(startValue, diff) => {
|
|
26529
26576
|
return sanitizeValue((startValue || 0) + diff);
|
|
26530
26577
|
},
|
|
26531
26578
|
[sanitizeValue]
|
|
26532
26579
|
);
|
|
26533
|
-
const getCurrentInputValue = (0,
|
|
26580
|
+
const getCurrentInputValue = (0, import_react8.useCallback)(
|
|
26534
26581
|
(e) => {
|
|
26535
26582
|
const float = parseFloat(e.currentTarget.value);
|
|
26536
26583
|
return sanitizeValue(isNaN(float) ? info.value || 0 : float);
|
|
@@ -26606,7 +26653,7 @@ body {
|
|
|
26606
26653
|
const sliderGradient = gradientStops ? {
|
|
26607
26654
|
background: `linear-gradient(90deg, ${gradientStops.join(", ")}), url(${TRANSPARENCY_SVG_URI})`
|
|
26608
26655
|
} : void 0;
|
|
26609
|
-
return /* @__PURE__ */ (0,
|
|
26656
|
+
return /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(
|
|
26610
26657
|
"div",
|
|
26611
26658
|
{
|
|
26612
26659
|
className: calculateClass(
|
|
@@ -26614,7 +26661,7 @@ body {
|
|
|
26614
26661
|
`state-${state.state}`,
|
|
26615
26662
|
info.grow && CLASS_GROW
|
|
26616
26663
|
),
|
|
26617
|
-
children: /* @__PURE__ */ (0,
|
|
26664
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime8.jsxs)(
|
|
26618
26665
|
"div",
|
|
26619
26666
|
{
|
|
26620
26667
|
className: "inner",
|
|
@@ -26623,7 +26670,7 @@ body {
|
|
|
26623
26670
|
onTouchStart,
|
|
26624
26671
|
style: state.state === "touching" ? { left: state.innerLeft } : {},
|
|
26625
26672
|
children: [
|
|
26626
|
-
/* @__PURE__ */ (0,
|
|
26673
|
+
/* @__PURE__ */ (0, import_jsx_runtime8.jsx)(
|
|
26627
26674
|
"input",
|
|
26628
26675
|
{
|
|
26629
26676
|
type: "text",
|
|
@@ -26633,8 +26680,8 @@ body {
|
|
|
26633
26680
|
onKeyDown
|
|
26634
26681
|
}
|
|
26635
26682
|
),
|
|
26636
|
-
/* @__PURE__ */ (0,
|
|
26637
|
-
/* @__PURE__ */ (0,
|
|
26683
|
+
/* @__PURE__ */ (0, import_jsx_runtime8.jsx)("div", { className: CLASS_SLIDER_VALUE, children: valueDisplay }),
|
|
26684
|
+
/* @__PURE__ */ (0, import_jsx_runtime8.jsx)(
|
|
26638
26685
|
"div",
|
|
26639
26686
|
{
|
|
26640
26687
|
className: calculateClass(
|
|
@@ -26642,10 +26689,10 @@ body {
|
|
|
26642
26689
|
sliderGradient && CLASS_GRADIENT
|
|
26643
26690
|
),
|
|
26644
26691
|
style: sliderGradient,
|
|
26645
|
-
children: /* @__PURE__ */ (0,
|
|
26692
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime8.jsx)("div", { className: "inner", style: { width: valueCSSPercent } })
|
|
26646
26693
|
}
|
|
26647
26694
|
),
|
|
26648
|
-
/* @__PURE__ */ (0,
|
|
26695
|
+
/* @__PURE__ */ (0, import_jsx_runtime8.jsx)("div", { className: CLASS_SLIDER_VALUE, children: valueDisplay })
|
|
26649
26696
|
]
|
|
26650
26697
|
}
|
|
26651
26698
|
)
|
|
@@ -26673,11 +26720,11 @@ body {
|
|
|
26673
26720
|
cursor: pointer;
|
|
26674
26721
|
transition: all 200ms;
|
|
26675
26722
|
border-radius: 3px;
|
|
26676
|
-
border: 1px solid ${
|
|
26723
|
+
border: 1px solid ${(p2) => p2.theme.borderDark};
|
|
26677
26724
|
${buttonStateNormal}
|
|
26678
26725
|
|
|
26679
26726
|
> input {
|
|
26680
|
-
color: ${
|
|
26727
|
+
color: ${(p2) => p2.theme.textNormal};
|
|
26681
26728
|
opacity: 0;
|
|
26682
26729
|
margin: 0 -9px;
|
|
26683
26730
|
padding: 6px 8px;
|
|
@@ -26685,22 +26732,22 @@ body {
|
|
|
26685
26732
|
pointer-events: none;
|
|
26686
26733
|
transition: all 200ms;
|
|
26687
26734
|
border-radius: 3px;
|
|
26688
|
-
background: ${
|
|
26689
|
-
border: 1px solid ${
|
|
26735
|
+
background: ${(p2) => p2.theme.bgDark1};
|
|
26736
|
+
border: 1px solid ${(p2) => p2.theme.borderDark};
|
|
26690
26737
|
overflow: hidden;
|
|
26691
|
-
box-shadow:
|
|
26738
|
+
box-shadow: ${(p2) => p2.theme.shadows.boxShadowInset};
|
|
26692
26739
|
}
|
|
26693
26740
|
|
|
26694
26741
|
> .${CLASS_SLIDER_DISPLAY} {
|
|
26695
26742
|
flex-grow: 1;
|
|
26696
26743
|
margin: 0 ${SLIDER_PADDING / 2}px;
|
|
26697
26744
|
height: 4px;
|
|
26698
|
-
background: ${
|
|
26699
|
-
border: 1px solid ${
|
|
26745
|
+
background: ${(p2) => p2.theme.bgDark1};
|
|
26746
|
+
border: 1px solid ${(p2) => p2.theme.borderDark};
|
|
26700
26747
|
|
|
26701
26748
|
> .inner {
|
|
26702
26749
|
height: 100%;
|
|
26703
|
-
background: ${
|
|
26750
|
+
background: ${(p2) => p2.theme.hint};
|
|
26704
26751
|
}
|
|
26705
26752
|
|
|
26706
26753
|
&.${CLASS_GRADIENT} {
|
|
@@ -26709,7 +26756,7 @@ body {
|
|
|
26709
26756
|
> .inner {
|
|
26710
26757
|
position: relative;
|
|
26711
26758
|
background: none;
|
|
26712
|
-
border-right: 2px solid ${
|
|
26759
|
+
border-right: 2px solid ${(p2) => p2.theme.borderDark};
|
|
26713
26760
|
|
|
26714
26761
|
&::before {
|
|
26715
26762
|
content: '';
|
|
@@ -26718,7 +26765,7 @@ body {
|
|
|
26718
26765
|
top: -5px;
|
|
26719
26766
|
bottom: -5px;
|
|
26720
26767
|
right: -3px;
|
|
26721
|
-
background: ${
|
|
26768
|
+
background: ${(p2) => p2.theme.borderDark};
|
|
26722
26769
|
}
|
|
26723
26770
|
|
|
26724
26771
|
&::after {
|
|
@@ -26728,7 +26775,7 @@ body {
|
|
|
26728
26775
|
top: -4px;
|
|
26729
26776
|
bottom: -4px;
|
|
26730
26777
|
right: -2px;
|
|
26731
|
-
background: ${
|
|
26778
|
+
background: ${(p2) => p2.theme.textNormal};
|
|
26732
26779
|
}
|
|
26733
26780
|
}
|
|
26734
26781
|
}
|
|
@@ -26768,7 +26815,7 @@ body {
|
|
|
26768
26815
|
z-index: 100;
|
|
26769
26816
|
|
|
26770
26817
|
.inner {
|
|
26771
|
-
background: ${
|
|
26818
|
+
background: ${(p2) => p2.theme.bgDark1};
|
|
26772
26819
|
width: ${OPEN_SLIDER_WIDTH}px;
|
|
26773
26820
|
|
|
26774
26821
|
> .${CLASS_SLIDER_VALUE} {
|
|
@@ -26781,9 +26828,9 @@ body {
|
|
|
26781
26828
|
var CLASS_TOUCHING = "touching";
|
|
26782
26829
|
var TOUCH_INDICATOR_CLASS2 = "touch-indicator";
|
|
26783
26830
|
var Switch = ({ className, info }) => {
|
|
26784
|
-
const { sendMessage } =
|
|
26785
|
-
const [touching, setTouching] = (0,
|
|
26786
|
-
const onClick = (0,
|
|
26831
|
+
const { sendMessage } = import_react9.default.useContext(StageContext);
|
|
26832
|
+
const [touching, setTouching] = (0, import_react9.useState)(false);
|
|
26833
|
+
const onClick = (0, import_react9.useMemo)(
|
|
26787
26834
|
() => () => {
|
|
26788
26835
|
sendMessage?.({
|
|
26789
26836
|
type: "component-message",
|
|
@@ -26794,14 +26841,14 @@ body {
|
|
|
26794
26841
|
},
|
|
26795
26842
|
[sendMessage, info.key]
|
|
26796
26843
|
);
|
|
26797
|
-
const onTouchStart = (0,
|
|
26844
|
+
const onTouchStart = (0, import_react9.useMemo)(
|
|
26798
26845
|
() => (event) => {
|
|
26799
26846
|
event.preventDefault();
|
|
26800
26847
|
setTouching(true);
|
|
26801
26848
|
},
|
|
26802
26849
|
[]
|
|
26803
26850
|
);
|
|
26804
|
-
const onTouchEnd = (0,
|
|
26851
|
+
const onTouchEnd = (0, import_react9.useMemo)(
|
|
26805
26852
|
() => (event) => {
|
|
26806
26853
|
event.preventDefault();
|
|
26807
26854
|
setTouching(false);
|
|
@@ -26809,7 +26856,7 @@ body {
|
|
|
26809
26856
|
},
|
|
26810
26857
|
[]
|
|
26811
26858
|
);
|
|
26812
|
-
return /* @__PURE__ */ (0,
|
|
26859
|
+
return /* @__PURE__ */ (0, import_jsx_runtime9.jsxs)(
|
|
26813
26860
|
"div",
|
|
26814
26861
|
{
|
|
26815
26862
|
className: calculateClass(className, touching && CLASS_TOUCHING),
|
|
@@ -26817,11 +26864,11 @@ body {
|
|
|
26817
26864
|
onTouchStart,
|
|
26818
26865
|
onTouchEnd,
|
|
26819
26866
|
children: [
|
|
26820
|
-
/* @__PURE__ */ (0,
|
|
26821
|
-
/* @__PURE__ */ (0,
|
|
26822
|
-
/* @__PURE__ */ (0,
|
|
26823
|
-
/* @__PURE__ */ (0,
|
|
26824
|
-
/* @__PURE__ */ (0,
|
|
26867
|
+
/* @__PURE__ */ (0, import_jsx_runtime9.jsx)("div", { className: TOUCH_INDICATOR_CLASS2 }),
|
|
26868
|
+
/* @__PURE__ */ (0, import_jsx_runtime9.jsx)("div", { className: "inner", children: /* @__PURE__ */ (0, import_jsx_runtime9.jsxs)("div", { className: "slider" + (info.state === "on" ? " on" : ""), children: [
|
|
26869
|
+
/* @__PURE__ */ (0, import_jsx_runtime9.jsx)("div", { className: "on-text", children: "ON" }),
|
|
26870
|
+
/* @__PURE__ */ (0, import_jsx_runtime9.jsx)("div", { className: "off-text", children: "OFF" }),
|
|
26871
|
+
/* @__PURE__ */ (0, import_jsx_runtime9.jsx)("div", { className: "button" })
|
|
26825
26872
|
] }) })
|
|
26826
26873
|
]
|
|
26827
26874
|
}
|
|
@@ -26841,7 +26888,7 @@ body {
|
|
|
26841
26888
|
min-width: ${BUTTON_WIDTH + TEXT_WIDTH}px;
|
|
26842
26889
|
height: ${SWITCH_HEIGHT}px;
|
|
26843
26890
|
border-radius: 3px;
|
|
26844
|
-
border: 1px solid ${
|
|
26891
|
+
border: 1px solid ${(p2) => p2.theme.borderDark};
|
|
26845
26892
|
|
|
26846
26893
|
> .slider {
|
|
26847
26894
|
position: absolute;
|
|
@@ -26863,7 +26910,7 @@ body {
|
|
|
26863
26910
|
text-align: center;
|
|
26864
26911
|
top: 0;
|
|
26865
26912
|
line-height: ${SWITCH_HEIGHT - 2}px;
|
|
26866
|
-
text-shadow:
|
|
26913
|
+
text-shadow: ${(p2) => p2.theme.shadows.textShadowActive};
|
|
26867
26914
|
box-shadow:
|
|
26868
26915
|
inset 0 1px 2px rgba(0, 0, 0, 0.2),
|
|
26869
26916
|
0 1px 0 0 rgba(255, 255, 255, 0.15);
|
|
@@ -26871,26 +26918,22 @@ body {
|
|
|
26871
26918
|
|
|
26872
26919
|
> .on-text {
|
|
26873
26920
|
left: -40px;
|
|
26874
|
-
background:
|
|
26875
|
-
to bottom,
|
|
26876
|
-
${THEME.hintDark1},
|
|
26877
|
-
${THEME.hint}
|
|
26878
|
-
);
|
|
26921
|
+
background: ${(p2) => p2.theme.gradients.hintPressed};
|
|
26879
26922
|
}
|
|
26880
26923
|
|
|
26881
26924
|
> .button {
|
|
26882
26925
|
top: -1px;
|
|
26883
26926
|
left: -1px;
|
|
26884
26927
|
width: ${BUTTON_WIDTH}px;
|
|
26885
|
-
background:
|
|
26886
|
-
text-shadow:
|
|
26928
|
+
background: ${(p2) => p2.theme.gradients.button};
|
|
26929
|
+
text-shadow: ${(p2) => p2.theme.shadows.textShadow};
|
|
26887
26930
|
box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.15);
|
|
26888
26931
|
border-radius: 3px;
|
|
26889
|
-
border: 1px solid ${
|
|
26932
|
+
border: 1px solid ${(p2) => p2.theme.borderDark};
|
|
26890
26933
|
}
|
|
26891
26934
|
|
|
26892
26935
|
> .off-text {
|
|
26893
|
-
background:
|
|
26936
|
+
background: ${(p2) => p2.theme.gradients.buttonActive};
|
|
26894
26937
|
left: ${BUTTON_WIDTH - 2}px;
|
|
26895
26938
|
}
|
|
26896
26939
|
|
|
@@ -26899,7 +26942,7 @@ body {
|
|
|
26899
26942
|
}
|
|
26900
26943
|
|
|
26901
26944
|
&:hover > .button {
|
|
26902
|
-
background:
|
|
26945
|
+
background: ${(p2) => p2.theme.gradients.buttonHover};
|
|
26903
26946
|
}
|
|
26904
26947
|
}
|
|
26905
26948
|
}
|
|
@@ -26917,47 +26960,47 @@ body {
|
|
|
26917
26960
|
var Wrapper2 = dt.div`
|
|
26918
26961
|
display: flex;
|
|
26919
26962
|
flex-direction: column;
|
|
26920
|
-
background: ${
|
|
26921
|
-
border: 1px solid ${
|
|
26963
|
+
background: ${(p2) => p2.theme.borderDark};
|
|
26964
|
+
border: 1px solid ${(p2) => p2.theme.borderDark};
|
|
26922
26965
|
`;
|
|
26923
26966
|
var TabList = dt.div`
|
|
26924
26967
|
display: flex;
|
|
26925
26968
|
flex-direction: row;
|
|
26926
|
-
border-bottom: 1px solid ${
|
|
26969
|
+
border-bottom: 1px solid ${(p2) => p2.theme.borderDark};
|
|
26927
26970
|
`;
|
|
26928
26971
|
var TabItem = dt.div`
|
|
26929
|
-
height: ${
|
|
26972
|
+
height: ${(p2) => p2.theme.sizingPx.spacing * 3}px;
|
|
26930
26973
|
display: flex;
|
|
26931
26974
|
flex-direction: column;
|
|
26932
26975
|
justify-content: center;
|
|
26933
|
-
padding: 0 ${
|
|
26976
|
+
padding: 0 ${(p2) => p2.theme.sizingPx.spacing}px;
|
|
26934
26977
|
cursor: pointer;
|
|
26935
|
-
background: ${
|
|
26978
|
+
background: ${(p2) => p2.theme.bgDark1};
|
|
26936
26979
|
margin-right: 1px;
|
|
26937
26980
|
|
|
26938
26981
|
&:hover,
|
|
26939
26982
|
&.touching {
|
|
26940
|
-
background: ${
|
|
26983
|
+
background: ${(p2) => p2.theme.bgLight1};
|
|
26941
26984
|
}
|
|
26942
26985
|
|
|
26943
26986
|
&.current {
|
|
26944
|
-
color: ${
|
|
26987
|
+
color: ${(p2) => p2.theme.hint};
|
|
26945
26988
|
|
|
26946
26989
|
&::after {
|
|
26947
26990
|
content: '';
|
|
26948
|
-
border-bottom: 2px solid ${
|
|
26991
|
+
border-bottom: 2px solid ${(p2) => p2.theme.hint};
|
|
26949
26992
|
display: block;
|
|
26950
|
-
margin-top: ${
|
|
26993
|
+
margin-top: ${(p2) => p2.theme.sizingPx.spacing / 2}px;
|
|
26951
26994
|
}
|
|
26952
26995
|
}
|
|
26953
26996
|
`;
|
|
26954
26997
|
var Tabs = (props) => {
|
|
26955
|
-
const { renderComponent } =
|
|
26956
|
-
const [touching, setTouching] =
|
|
26957
|
-
const [currentTab, setCurrentTab] =
|
|
26998
|
+
const { renderComponent } = import_react10.default.useContext(StageContext);
|
|
26999
|
+
const [touching, setTouching] = import_react10.default.useState(null);
|
|
27000
|
+
const [currentTab, setCurrentTab] = import_react10.default.useState(0);
|
|
26958
27001
|
const tab = props.info.tabs[currentTab];
|
|
26959
|
-
return /* @__PURE__ */ (0,
|
|
26960
|
-
/* @__PURE__ */ (0,
|
|
27002
|
+
return /* @__PURE__ */ (0, import_jsx_runtime10.jsxs)(Wrapper2, { children: [
|
|
27003
|
+
/* @__PURE__ */ (0, import_jsx_runtime10.jsx)(TabList, { children: props.info.tabs.map((tab2, i2) => /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(
|
|
26961
27004
|
TabItem,
|
|
26962
27005
|
{
|
|
26963
27006
|
className: calculateClass(
|
|
@@ -26978,18 +27021,18 @@ body {
|
|
|
26978
27021
|
},
|
|
26979
27022
|
i2
|
|
26980
27023
|
)) }),
|
|
26981
|
-
/* @__PURE__ */ (0,
|
|
27024
|
+
/* @__PURE__ */ (0, import_jsx_runtime10.jsx)(StyledNestedContent, { children: tab?.child && renderComponent(tab.child) })
|
|
26982
27025
|
] });
|
|
26983
27026
|
};
|
|
26984
27027
|
var TextInput = ({ className, info }) => {
|
|
26985
|
-
const { sendMessage } =
|
|
26986
|
-
const ref =
|
|
26987
|
-
(0,
|
|
27028
|
+
const { sendMessage } = import_react11.default.useContext(StageContext);
|
|
27029
|
+
const ref = import_react11.default.useRef(null);
|
|
27030
|
+
(0, import_react11.useEffect)(() => {
|
|
26988
27031
|
if (ref.current && ref.current.value !== info.value) {
|
|
26989
27032
|
ref.current.value = info.value;
|
|
26990
27033
|
}
|
|
26991
27034
|
}, [info.value]);
|
|
26992
|
-
return /* @__PURE__ */ (0,
|
|
27035
|
+
return /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(
|
|
26993
27036
|
"input",
|
|
26994
27037
|
{
|
|
26995
27038
|
className,
|
|
@@ -27010,12 +27053,12 @@ body {
|
|
|
27010
27053
|
box-sizing: border-box;
|
|
27011
27054
|
padding: 6px 8px;
|
|
27012
27055
|
border-radius: 3px;
|
|
27013
|
-
background: ${
|
|
27014
|
-
border: 1px solid ${
|
|
27056
|
+
background: ${(p2) => p2.theme.bgDark1};
|
|
27057
|
+
border: 1px solid ${(p2) => p2.theme.borderDark};
|
|
27015
27058
|
overflow: hidden;
|
|
27016
|
-
box-shadow:
|
|
27017
|
-
color: ${
|
|
27018
|
-
text-shadow:
|
|
27059
|
+
box-shadow: ${(p2) => p2.theme.shadows.boxShadowInset};
|
|
27060
|
+
color: ${(p2) => p2.theme.textNormal};
|
|
27061
|
+
text-shadow: ${(p2) => p2.theme.shadows.textShadow};
|
|
27019
27062
|
|
|
27020
27063
|
@media (max-width: 500px) {
|
|
27021
27064
|
flex-basis: 100%;
|
|
@@ -27042,12 +27085,12 @@ body {
|
|
|
27042
27085
|
var Bar = dt.div`
|
|
27043
27086
|
width: 100%;
|
|
27044
27087
|
height: 10px;
|
|
27045
|
-
border: 1px solid ${
|
|
27046
|
-
background: ${
|
|
27088
|
+
border: 1px solid ${(p2) => p2.theme.borderDark};
|
|
27089
|
+
background: ${(p2) => p2.theme.borderDark};
|
|
27047
27090
|
`;
|
|
27048
27091
|
var Fill = dt.div`
|
|
27049
27092
|
height: 100%;
|
|
27050
|
-
background: ${
|
|
27093
|
+
background: ${(p2) => p2.theme.hint};
|
|
27051
27094
|
`;
|
|
27052
27095
|
var Title = dt.div`
|
|
27053
27096
|
font-size: 1.5em;
|
|
@@ -27061,12 +27104,12 @@ body {
|
|
|
27061
27104
|
`;
|
|
27062
27105
|
var Timeline = (props) => {
|
|
27063
27106
|
const { className, info } = props;
|
|
27064
|
-
const frameState =
|
|
27107
|
+
const frameState = import_react12.default.useRef({
|
|
27065
27108
|
animationFrame: -1,
|
|
27066
27109
|
state: null
|
|
27067
27110
|
});
|
|
27068
|
-
const [currentTimeMillis, setCurrentTimeMillis] = (0,
|
|
27069
|
-
(0,
|
|
27111
|
+
const [currentTimeMillis, setCurrentTimeMillis] = (0, import_react12.useState)(0);
|
|
27112
|
+
(0, import_react12.useEffect)(() => {
|
|
27070
27113
|
frameState.current.state = info.state;
|
|
27071
27114
|
const recalculateCurrentTimeMillis = () => {
|
|
27072
27115
|
if (frameState.current.state !== info.state) {
|
|
@@ -27088,15 +27131,15 @@ body {
|
|
|
27088
27131
|
window.cancelAnimationFrame(frameState.current.animationFrame);
|
|
27089
27132
|
};
|
|
27090
27133
|
}, [frameState, info.state]);
|
|
27091
|
-
return /* @__PURE__ */ (0,
|
|
27092
|
-
/* @__PURE__ */ (0,
|
|
27093
|
-
/* @__PURE__ */ (0,
|
|
27094
|
-
info.title && /* @__PURE__ */ (0,
|
|
27095
|
-
info.subtitles?.map((subtitle, k2) => /* @__PURE__ */ (0,
|
|
27134
|
+
return /* @__PURE__ */ (0, import_jsx_runtime12.jsxs)(Wrapper3, { className, children: [
|
|
27135
|
+
/* @__PURE__ */ (0, import_jsx_runtime12.jsxs)(Data, { children: [
|
|
27136
|
+
/* @__PURE__ */ (0, import_jsx_runtime12.jsxs)(Metadata, { children: [
|
|
27137
|
+
info.title && /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(Title, { children: info.title }),
|
|
27138
|
+
info.subtitles?.map((subtitle, k2) => /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(Subtitle, { children: subtitle }, k2))
|
|
27096
27139
|
] }),
|
|
27097
|
-
/* @__PURE__ */ (0,
|
|
27140
|
+
/* @__PURE__ */ (0, import_jsx_runtime12.jsxs)(SourceData, { children: [
|
|
27098
27141
|
info.source?.name,
|
|
27099
|
-
/* @__PURE__ */ (0,
|
|
27142
|
+
/* @__PURE__ */ (0, import_jsx_runtime12.jsx)(
|
|
27100
27143
|
IndicatorIcon,
|
|
27101
27144
|
{
|
|
27102
27145
|
icon: info.state.state === "playing" ? "play_arrow" : "pause"
|
|
@@ -27104,7 +27147,7 @@ body {
|
|
|
27104
27147
|
)
|
|
27105
27148
|
] })
|
|
27106
27149
|
] }),
|
|
27107
|
-
/* @__PURE__ */ (0,
|
|
27150
|
+
/* @__PURE__ */ (0, import_jsx_runtime12.jsx)(Bar, { children: /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(
|
|
27108
27151
|
Fill,
|
|
27109
27152
|
{
|
|
27110
27153
|
style: {
|
|
@@ -27122,23 +27165,23 @@ body {
|
|
|
27122
27165
|
}
|
|
27123
27166
|
switch (info.component) {
|
|
27124
27167
|
case "button":
|
|
27125
|
-
return /* @__PURE__ */ (0,
|
|
27168
|
+
return /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(StyledButton, { info }, info.key);
|
|
27126
27169
|
case "group":
|
|
27127
|
-
return /* @__PURE__ */ (0,
|
|
27170
|
+
return /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(StyledGroup, { info }, info.key);
|
|
27128
27171
|
case "label":
|
|
27129
|
-
return /* @__PURE__ */ (0,
|
|
27172
|
+
return /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(StyledLabel, { info }, info.key);
|
|
27130
27173
|
case "rect":
|
|
27131
|
-
return /* @__PURE__ */ (0,
|
|
27174
|
+
return /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(Rect, { info }, info.key);
|
|
27132
27175
|
case "slider_button":
|
|
27133
|
-
return /* @__PURE__ */ (0,
|
|
27176
|
+
return /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(StyledSliderButton, { info }, info.key);
|
|
27134
27177
|
case "switch":
|
|
27135
|
-
return /* @__PURE__ */ (0,
|
|
27178
|
+
return /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(StyledSwitch, { info }, info.key);
|
|
27136
27179
|
case "tabs":
|
|
27137
|
-
return /* @__PURE__ */ (0,
|
|
27180
|
+
return /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(Tabs, { info }, info.key);
|
|
27138
27181
|
case "text-input":
|
|
27139
|
-
return /* @__PURE__ */ (0,
|
|
27182
|
+
return /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(StyledTextInput, { info }, info.key);
|
|
27140
27183
|
case "timeline":
|
|
27141
|
-
return /* @__PURE__ */ (0,
|
|
27184
|
+
return /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(Timeline, { info }, info.key);
|
|
27142
27185
|
case "group-header":
|
|
27143
27186
|
case "tab":
|
|
27144
27187
|
throw new Error(
|
|
@@ -27201,20 +27244,239 @@ body {
|
|
|
27201
27244
|
};
|
|
27202
27245
|
|
|
27203
27246
|
// src/frontend/stage.tsx
|
|
27204
|
-
var
|
|
27247
|
+
var import_react15 = __toESM(require_react());
|
|
27248
|
+
|
|
27249
|
+
// ../toolkit-frontend/src/util/index.ts
|
|
27250
|
+
var import_react14 = __toESM(require_react());
|
|
27251
|
+
|
|
27252
|
+
// ../toolkit-frontend/src/util/touch.ts
|
|
27253
|
+
var import_react13 = __toESM(require_react());
|
|
27254
|
+
|
|
27255
|
+
// ../toolkit-frontend/src/util/index.ts
|
|
27256
|
+
var usePreferredColorScheme2 = () => {
|
|
27257
|
+
const [theme, setTheme] = (0, import_react14.useState)("light");
|
|
27258
|
+
(0, import_react14.useEffect)(() => {
|
|
27259
|
+
if (typeof window !== "undefined") {
|
|
27260
|
+
const mediaQuery = window.matchMedia("(prefers-color-scheme: dark)");
|
|
27261
|
+
setTheme(mediaQuery.matches ? "dark" : "light");
|
|
27262
|
+
const handleChange = (event) => {
|
|
27263
|
+
setTheme(event.matches ? "dark" : "light");
|
|
27264
|
+
};
|
|
27265
|
+
mediaQuery.addEventListener("change", handleChange);
|
|
27266
|
+
return () => {
|
|
27267
|
+
mediaQuery.removeEventListener("change", handleChange);
|
|
27268
|
+
};
|
|
27269
|
+
}
|
|
27270
|
+
}, []);
|
|
27271
|
+
return theme;
|
|
27272
|
+
};
|
|
27273
|
+
|
|
27274
|
+
// ../toolkit-frontend/src/styling.tsx
|
|
27275
|
+
var import_jsx_runtime14 = __toESM(require_jsx_runtime());
|
|
27276
|
+
var GlobalStyle2 = ft`
|
|
27277
|
+
body {
|
|
27278
|
+
&.touch-mode * {
|
|
27279
|
+
cursor: none !important;
|
|
27280
|
+
}
|
|
27281
|
+
}
|
|
27282
|
+
`;
|
|
27283
|
+
var DARK_THEME2 = {
|
|
27284
|
+
pageBg: "#333",
|
|
27285
|
+
colorGreen: "#98c379",
|
|
27286
|
+
colorRed: "#e06c75",
|
|
27287
|
+
colorAmber: "#d19a66",
|
|
27288
|
+
bgDark1: "#252524",
|
|
27289
|
+
bg: "#2a2a2b",
|
|
27290
|
+
bgLight1: "#353638",
|
|
27291
|
+
borderDark: "#151516",
|
|
27292
|
+
borderLight: "#1c1d1d",
|
|
27293
|
+
borderLighter: "#252524",
|
|
27294
|
+
borderLighterer: "#6b6b67",
|
|
27295
|
+
hint: "#4286f4",
|
|
27296
|
+
hintRGB: "66, 134, 244",
|
|
27297
|
+
hintDark1: "#2a77f3",
|
|
27298
|
+
textNormal: "#F3F3F5",
|
|
27299
|
+
textActive: "#ffffff",
|
|
27300
|
+
textMuted: "#777777",
|
|
27301
|
+
shadows: {
|
|
27302
|
+
boxShadowInset: "inset 0px 0px 8px 0px rgba(0, 0, 0, 0.3)",
|
|
27303
|
+
textShadow: "0 -1px rgba(0, 0, 0, 0.7)",
|
|
27304
|
+
textShadowActive: "0 -1px rgba(0, 0, 0, 0.4)"
|
|
27305
|
+
},
|
|
27306
|
+
gradients: {
|
|
27307
|
+
button: "linear-gradient(to bottom, #4f5053, #343436)",
|
|
27308
|
+
buttonHover: "linear-gradient(to bottom, #5e6064, #393a3b)",
|
|
27309
|
+
buttonActive: "linear-gradient(to bottom, #242525, #37383a)",
|
|
27310
|
+
buttonPressedHover: "linear-gradient(to bottom, #282929, #414243)",
|
|
27311
|
+
hintPressed: "linear-gradient(to bottom,#2a77f3,#4286f4)"
|
|
27312
|
+
},
|
|
27313
|
+
sizingPx: {
|
|
27314
|
+
spacing: 15,
|
|
27315
|
+
unitHeight: 40
|
|
27316
|
+
}
|
|
27317
|
+
};
|
|
27318
|
+
var LIGHT_THEME2 = {
|
|
27319
|
+
pageBg: "#f8f9fa",
|
|
27320
|
+
colorGreen: "#22863a",
|
|
27321
|
+
colorRed: "#d73a49",
|
|
27322
|
+
colorAmber: "#b08800",
|
|
27323
|
+
bgDark1: "#e9ecef",
|
|
27324
|
+
bg: "#ffffff",
|
|
27325
|
+
bgLight1: "#f5f5f5",
|
|
27326
|
+
borderDark: "#c7c7c7",
|
|
27327
|
+
borderLight: "#d7d7d7",
|
|
27328
|
+
borderLighter: "#eaecef",
|
|
27329
|
+
borderLighterer: "#f6f8fa",
|
|
27330
|
+
hint: "#4286f4",
|
|
27331
|
+
hintRGB: "0, 92, 197",
|
|
27332
|
+
hintDark1: "#2a77f3",
|
|
27333
|
+
textNormal: "#24292e",
|
|
27334
|
+
textActive: "#202020",
|
|
27335
|
+
textMuted: "#6a737d",
|
|
27336
|
+
shadows: {
|
|
27337
|
+
boxShadowInset: "inset 0px 0px 8px 0px rgba(0, 0, 0, 0.05)",
|
|
27338
|
+
textShadow: "0 1px rgba(255, 255, 255, 0.7)",
|
|
27339
|
+
textShadowActive: "0 1px rgba(255, 255, 255, 0.4)"
|
|
27340
|
+
},
|
|
27341
|
+
gradients: {
|
|
27342
|
+
button: "linear-gradient(to bottom, #e1e4e8, #d1d5da)",
|
|
27343
|
+
buttonHover: "linear-gradient(to bottom, #d1d5da, #c1c6cc)",
|
|
27344
|
+
buttonActive: "linear-gradient(to bottom, #b1b6bc, #d2d6da)",
|
|
27345
|
+
buttonPressedHover: "linear-gradient(to bottom, #a1a6ac, #91969c)",
|
|
27346
|
+
hintPressed: "linear-gradient(to bottom, #438bff, #85b3ff)"
|
|
27347
|
+
},
|
|
27348
|
+
sizingPx: DARK_THEME2.sizingPx
|
|
27349
|
+
};
|
|
27350
|
+
var BaseStyle2 = ft`
|
|
27351
|
+
* {
|
|
27352
|
+
box-sizing: border-box;
|
|
27353
|
+
}
|
|
27354
|
+
|
|
27355
|
+
body {
|
|
27356
|
+
background: ${(p2) => p2.theme.pageBg};
|
|
27357
|
+
margin: 0;
|
|
27358
|
+
padding: 0;
|
|
27359
|
+
font-size: 14px;
|
|
27360
|
+
font-family: sans-serif;
|
|
27361
|
+
}
|
|
27362
|
+
`;
|
|
27363
|
+
var buttonStateNormal2 = lt`
|
|
27364
|
+
color: ${(p2) => p2.theme.textNormal};
|
|
27365
|
+
background: ${(p2) => p2.theme.gradients.button};
|
|
27366
|
+
text-shadow: ${(p2) => p2.theme.shadows.textShadow};
|
|
27367
|
+
box-shadow:
|
|
27368
|
+
inset 0 1px 0 rgba(255, 255, 255, 0.15),
|
|
27369
|
+
0 1px 0 0 rgba(0, 0, 0, 0.25);
|
|
27370
|
+
`;
|
|
27371
|
+
var buttonStateNormalHover2 = lt`
|
|
27372
|
+
color: ${(p2) => p2.theme.textNormal};
|
|
27373
|
+
outline-color: rgba(243, 243, 245, 0.3);
|
|
27374
|
+
background: ${(p2) => p2.theme.gradients.buttonHover};
|
|
27375
|
+
text-shadow: ${(p2) => p2.theme.shadows.textShadow};
|
|
27376
|
+
`;
|
|
27377
|
+
var buttonStateNormalActive2 = lt`
|
|
27378
|
+
color: ${(p2) => p2.theme.textNormal};
|
|
27379
|
+
outline-color: rgba(255, 255, 255, 0.3);
|
|
27380
|
+
background: ${(p2) => p2.theme.gradients.buttonActive};
|
|
27381
|
+
text-shadow: ${(p2) => p2.theme.shadows.textShadowActive};
|
|
27382
|
+
box-shadow:
|
|
27383
|
+
inset 0 1px 2px rgba(0, 0, 0, 0.2),
|
|
27384
|
+
0 1px 0 0 rgba(255, 255, 255, 0.15);
|
|
27385
|
+
transition-duration: 50ms;
|
|
27386
|
+
`;
|
|
27387
|
+
var buttonStatePressed2 = lt`
|
|
27388
|
+
${buttonStateNormalActive2}
|
|
27389
|
+
box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.1), 0 1px 0 0 rgba(255,255,255,0.15);
|
|
27390
|
+
`;
|
|
27391
|
+
var buttonStatePressedHover2 = lt`
|
|
27392
|
+
${buttonStateNormalActive2}
|
|
27393
|
+
box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.1), 0 1px 0 0 rgba(255,255,255,0.15);
|
|
27394
|
+
background: ${(p2) => p2.theme.gradients.buttonPressedHover};
|
|
27395
|
+
`;
|
|
27396
|
+
var buttonStatePressedActive2 = buttonStateNormalActive2;
|
|
27397
|
+
var buttonStateDisabled2 = lt`
|
|
27398
|
+
${buttonStateNormal2}
|
|
27399
|
+
|
|
27400
|
+
cursor: default;
|
|
27401
|
+
background: ${(p2) => p2.theme.bg} !important;
|
|
27402
|
+
color: rgba(${(p2) => p2.theme.textNormal}, 0.4);
|
|
27403
|
+
`;
|
|
27404
|
+
var button2 = lt`
|
|
27405
|
+
position: relative;
|
|
27406
|
+
box-sizing: border-box;
|
|
27407
|
+
cursor: pointer;
|
|
27408
|
+
transition: all 200ms;
|
|
27409
|
+
border-radius: 3px;
|
|
27410
|
+
border: 1px solid ${(p2) => p2.theme.borderDark};
|
|
27411
|
+
overflow: hidden;
|
|
27412
|
+
display: flex;
|
|
27413
|
+
justify-content: center;
|
|
27414
|
+
align-items: center;
|
|
27415
|
+
outline-color: transparent;
|
|
27416
|
+
${buttonStateNormal2}
|
|
27417
|
+
|
|
27418
|
+
&:hover {
|
|
27419
|
+
${buttonStateNormalHover2}
|
|
27420
|
+
}
|
|
27421
|
+
|
|
27422
|
+
&:active {
|
|
27423
|
+
${buttonStateNormalActive2}
|
|
27424
|
+
}
|
|
27425
|
+
`;
|
|
27426
|
+
var buttonPressed2 = lt`
|
|
27427
|
+
${buttonStatePressed2}
|
|
27428
|
+
|
|
27429
|
+
&:hover {
|
|
27430
|
+
${buttonStatePressedHover2}
|
|
27431
|
+
}
|
|
27432
|
+
|
|
27433
|
+
&:active {
|
|
27434
|
+
${buttonStatePressedActive2}
|
|
27435
|
+
}
|
|
27436
|
+
`;
|
|
27437
|
+
var buttonDisabled2 = lt`
|
|
27438
|
+
${buttonStateDisabled2}
|
|
27439
|
+
|
|
27440
|
+
&:hover, &:active {
|
|
27441
|
+
${buttonStateDisabled2}
|
|
27442
|
+
}
|
|
27443
|
+
`;
|
|
27444
|
+
var touchIndicatorNormal2 = lt`
|
|
27445
|
+
position: absolute;
|
|
27446
|
+
top: -6px;
|
|
27447
|
+
right: -6px;
|
|
27448
|
+
left: -6px;
|
|
27449
|
+
bottom: -6px;
|
|
27450
|
+
border-radius: 6px;
|
|
27451
|
+
border: 2px solid rgba(0, 0, 0, 0);
|
|
27452
|
+
background-color: none;
|
|
27453
|
+
transition: border-color 300ms;
|
|
27454
|
+
`;
|
|
27455
|
+
var touchIndicatorTouching2 = lt`
|
|
27456
|
+
border-color: ${(p2) => p2.theme.hint};
|
|
27457
|
+
background-color: rgba(${(p2) => p2.theme.hintRGB}, 0.2);
|
|
27458
|
+
transition: border-color 0s;
|
|
27459
|
+
`;
|
|
27460
|
+
var PreferredThemeProvider2 = ({ dark, light, children }) => {
|
|
27461
|
+
const theme = usePreferredColorScheme2();
|
|
27462
|
+
return /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(ot, { theme: theme === "dark" ? dark : light, children });
|
|
27463
|
+
};
|
|
27464
|
+
|
|
27465
|
+
// src/frontend/stage.tsx
|
|
27205
27466
|
var Stage = ({ className, renderers }) => {
|
|
27206
|
-
const [root, setRoot] = (0,
|
|
27467
|
+
const [root, setRoot] = (0, import_react15.useState)(
|
|
27207
27468
|
void 0
|
|
27208
27469
|
);
|
|
27209
|
-
const socket = (0,
|
|
27210
|
-
const
|
|
27470
|
+
const socket = (0, import_react15.useRef)(null);
|
|
27471
|
+
const uuid = (0, import_react15.useRef)(null);
|
|
27472
|
+
const preparedRenderers = (0, import_react15.useMemo)(() => {
|
|
27211
27473
|
const prepared = {};
|
|
27212
27474
|
for (const renderer of renderers) {
|
|
27213
27475
|
prepared[renderer.namespace] = renderer;
|
|
27214
27476
|
}
|
|
27215
27477
|
return prepared;
|
|
27216
27478
|
}, [renderers]);
|
|
27217
|
-
const renderComponent = (0,
|
|
27479
|
+
const renderComponent = (0, import_react15.useCallback)(
|
|
27218
27480
|
(info) => {
|
|
27219
27481
|
const renderer = preparedRenderers[info.namespace];
|
|
27220
27482
|
if (!renderer) {
|
|
@@ -27224,7 +27486,7 @@ body {
|
|
|
27224
27486
|
},
|
|
27225
27487
|
[preparedRenderers]
|
|
27226
27488
|
);
|
|
27227
|
-
(0,
|
|
27489
|
+
(0, import_react15.useEffect)(() => {
|
|
27228
27490
|
initializeWebsocket();
|
|
27229
27491
|
}, []);
|
|
27230
27492
|
const initializeWebsocket = async () => {
|
|
@@ -27257,6 +27519,9 @@ body {
|
|
|
27257
27519
|
};
|
|
27258
27520
|
const handleMessage = (msg) => {
|
|
27259
27521
|
switch (msg.type) {
|
|
27522
|
+
case "metadata":
|
|
27523
|
+
uuid.current = msg.connectionUuid;
|
|
27524
|
+
return;
|
|
27260
27525
|
case "tree-full":
|
|
27261
27526
|
setRoot(msg.root);
|
|
27262
27527
|
return;
|
|
@@ -27265,26 +27530,32 @@ body {
|
|
|
27265
27530
|
return;
|
|
27266
27531
|
}
|
|
27267
27532
|
};
|
|
27268
|
-
return /* @__PURE__ */
|
|
27533
|
+
return /* @__PURE__ */ import_react15.default.createElement(
|
|
27269
27534
|
StageContext.Provider,
|
|
27270
27535
|
{
|
|
27271
27536
|
value: {
|
|
27272
27537
|
sendMessage,
|
|
27273
|
-
renderComponent
|
|
27538
|
+
renderComponent,
|
|
27539
|
+
get connectionUuid() {
|
|
27540
|
+
if (!uuid.current) {
|
|
27541
|
+
throw new Error("Unexpected missing UUID");
|
|
27542
|
+
}
|
|
27543
|
+
return uuid.current;
|
|
27544
|
+
}
|
|
27274
27545
|
}
|
|
27275
27546
|
},
|
|
27276
|
-
/* @__PURE__ */
|
|
27547
|
+
/* @__PURE__ */ import_react15.default.createElement(GroupStateWrapper, { openByDefault: false }, /* @__PURE__ */ import_react15.default.createElement("div", { className }, root ? renderComponent(root) : /* @__PURE__ */ import_react15.default.createElement("div", { className: "no-root" }, "No root has been added to the light desk")))
|
|
27277
27548
|
);
|
|
27278
27549
|
};
|
|
27279
27550
|
var StyledStage = dt(Stage)`
|
|
27280
27551
|
width: 100%;
|
|
27281
27552
|
height: 100%;
|
|
27282
|
-
background-color:
|
|
27283
|
-
color: ${
|
|
27284
|
-
padding: ${
|
|
27553
|
+
background-color: ${(p2) => p2.theme.pageBg};
|
|
27554
|
+
color: ${(p2) => p2.theme.textNormal};
|
|
27555
|
+
padding: ${(p2) => p2.theme.sizingPx.spacing}px;
|
|
27285
27556
|
`;
|
|
27286
27557
|
function rootComponent(props) {
|
|
27287
|
-
return /* @__PURE__ */
|
|
27558
|
+
return /* @__PURE__ */ import_react15.default.createElement(PreferredThemeProvider2, { dark: DARK_THEME, light: LIGHT_THEME }, /* @__PURE__ */ import_react15.default.createElement(BaseStyle, null), /* @__PURE__ */ import_react15.default.createElement(GlobalStyle, null), /* @__PURE__ */ import_react15.default.createElement(StyledStage, { ...props }));
|
|
27288
27559
|
}
|
|
27289
27560
|
|
|
27290
27561
|
// src/frontend/index.ts
|