@novely/solid-renderer 0.51.0-next.2 → 0.51.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.
Files changed (2) hide show
  1. package/dist/index.jsx +295 -398
  2. package/package.json +8 -8
package/dist/index.jsx CHANGED
@@ -1,4 +1,4 @@
1
- // ../../node_modules/.pnpm/solid-js@1.9.4/node_modules/solid-js/dist/solid.js
1
+ // ../../node_modules/.pnpm/solid-js@1.9.7/node_modules/solid-js/dist/solid.js
2
2
  var sharedConfig = {
3
3
  context: void 0,
4
4
  registry: void 0,
@@ -25,6 +25,7 @@ function nextHydrateContext() {
25
25
  count: 0
26
26
  };
27
27
  }
28
+ var IS_DEV = false;
28
29
  var equalFn = (a, b) => a === b;
29
30
  var $PROXY = Symbol("solid-proxy");
30
31
  var SUPPORTS_PROXY = typeof Proxy === "function";
@@ -199,12 +200,12 @@ function useContext(context) {
199
200
  }
200
201
  function children(fn) {
201
202
  const children2 = createMemo(fn);
202
- const memo = createMemo(() => resolveChildren(children2()));
203
- memo.toArray = () => {
204
- const c = memo();
203
+ const memo2 = createMemo(() => resolveChildren(children2()));
204
+ memo2.toArray = () => {
205
+ const c = memo2();
205
206
  return Array.isArray(c) ? c : c != null ? [c] : [];
206
207
  };
207
- return memo;
208
+ return memo2;
208
209
  }
209
210
  var SuspenseContext;
210
211
  function readSignal() {
@@ -265,7 +266,7 @@ function writeSignal(node, value, isComp) {
265
266
  }
266
267
  if (Updates.length > 1e6) {
267
268
  Updates = [];
268
- if (false) ;
269
+ if (IS_DEV) ;
269
270
  throw new Error();
270
271
  }
271
272
  }, false);
@@ -277,11 +278,7 @@ function updateComputation(node) {
277
278
  if (!node.fn) return;
278
279
  cleanNode(node);
279
280
  const time = ExecCount;
280
- runComputation(
281
- node,
282
- Transition && Transition.running && Transition.sources.has(node) ? node.tValue : node.value,
283
- time
284
- );
281
+ runComputation(node, Transition && Transition.running && Transition.sources.has(node) ? node.tValue : node.value, time);
285
282
  if (Transition && !Transition.running && Transition.sources.has(node)) {
286
283
  queueMicrotask(() => {
287
284
  runUpdates(() => {
@@ -512,8 +509,7 @@ function lookUpstream(node, ignore) {
512
509
  if (source.sources) {
513
510
  const state = runningTransition ? source.tState : source.state;
514
511
  if (state === STALE) {
515
- if (source !== ignore && (!source.updatedAt || source.updatedAt < ExecCount))
516
- runTop(source);
512
+ if (source !== ignore && (!source.updatedAt || source.updatedAt < ExecCount)) runTop(source);
517
513
  } else if (state === PENDING) lookUpstream(source, ignore);
518
514
  }
519
515
  }
@@ -589,13 +585,12 @@ function handleError(err, owner = Owner) {
589
585
  const fns = ERROR && owner && owner.context && owner.context[ERROR];
590
586
  const error = castError(err);
591
587
  if (!fns) throw error;
592
- if (Effects)
593
- Effects.push({
594
- fn() {
595
- runErrors(error, fns, owner);
596
- },
597
- state: STALE
598
- });
588
+ if (Effects) Effects.push({
589
+ fn() {
590
+ runErrors(error, fns, owner);
591
+ },
592
+ state: STALE
593
+ });
599
594
  else runErrors(error, fns, owner);
600
595
  }
601
596
  function resolveChildren(children2) {
@@ -613,16 +608,13 @@ function resolveChildren(children2) {
613
608
  function createProvider(id, options) {
614
609
  return function provider(props) {
615
610
  let res;
616
- createRenderEffect(
617
- () => res = untrack(() => {
618
- Owner.context = {
619
- ...Owner.context,
620
- [id]: props.value
621
- };
622
- return children(() => props.children);
623
- }),
624
- void 0
625
- );
611
+ createRenderEffect(() => res = untrack(() => {
612
+ Owner.context = {
613
+ ...Owner.context,
614
+ [id]: props.value
615
+ };
616
+ return children(() => props.children);
617
+ }), void 0);
626
618
  return res;
627
619
  };
628
620
  }
@@ -831,29 +823,25 @@ function mergeProps(...sources) {
831
823
  sources[i] = typeof s === "function" ? (proxy = true, createMemo(s)) : s;
832
824
  }
833
825
  if (SUPPORTS_PROXY && proxy) {
834
- return new Proxy(
835
- {
836
- get(property) {
837
- for (let i = sources.length - 1; i >= 0; i--) {
838
- const v = resolveSource(sources[i])[property];
839
- if (v !== void 0) return v;
840
- }
841
- },
842
- has(property) {
843
- for (let i = sources.length - 1; i >= 0; i--) {
844
- if (property in resolveSource(sources[i])) return true;
845
- }
846
- return false;
847
- },
848
- keys() {
849
- const keys = [];
850
- for (let i = 0; i < sources.length; i++)
851
- keys.push(...Object.keys(resolveSource(sources[i])));
852
- return [...new Set(keys)];
826
+ return new Proxy({
827
+ get(property) {
828
+ for (let i = sources.length - 1; i >= 0; i--) {
829
+ const v = resolveSource(sources[i])[property];
830
+ if (v !== void 0) return v;
853
831
  }
854
832
  },
855
- propTraps
856
- );
833
+ has(property) {
834
+ for (let i = sources.length - 1; i >= 0; i--) {
835
+ if (property in resolveSource(sources[i])) return true;
836
+ }
837
+ return false;
838
+ },
839
+ keys() {
840
+ const keys = [];
841
+ for (let i = 0; i < sources.length; i++) keys.push(...Object.keys(resolveSource(sources[i])));
842
+ return [...new Set(keys)];
843
+ }
844
+ }, propTraps);
857
845
  }
858
846
  const sourcesMap = {};
859
847
  const defined = /* @__PURE__ */ Object.create(null);
@@ -893,37 +881,29 @@ function splitProps(props, ...keys) {
893
881
  if (SUPPORTS_PROXY && $PROXY in props) {
894
882
  const blocked = new Set(keys.length > 1 ? keys.flat() : keys[0]);
895
883
  const res = keys.map((k) => {
896
- return new Proxy(
897
- {
898
- get(property) {
899
- return k.includes(property) ? props[property] : void 0;
900
- },
901
- has(property) {
902
- return k.includes(property) && property in props;
903
- },
904
- keys() {
905
- return k.filter((property) => property in props);
906
- }
884
+ return new Proxy({
885
+ get(property) {
886
+ return k.includes(property) ? props[property] : void 0;
907
887
  },
908
- propTraps
909
- );
910
- });
911
- res.push(
912
- new Proxy(
913
- {
914
- get(property) {
915
- return blocked.has(property) ? void 0 : props[property];
916
- },
917
- has(property) {
918
- return blocked.has(property) ? false : property in props;
919
- },
920
- keys() {
921
- return Object.keys(props).filter((k) => !blocked.has(k));
922
- }
888
+ has(property) {
889
+ return k.includes(property) && property in props;
923
890
  },
924
- propTraps
925
- )
926
- );
891
+ keys() {
892
+ return k.filter((property) => property in props);
893
+ }
894
+ }, propTraps);
895
+ });
896
+ res.push(new Proxy({
897
+ get(property) {
898
+ return blocked.has(property) ? void 0 : props[property];
899
+ },
900
+ has(property) {
901
+ return blocked.has(property) ? false : property in props;
902
+ },
903
+ keys() {
904
+ return Object.keys(props).filter((k) => !blocked.has(k));
905
+ }
906
+ }, propTraps));
927
907
  return res;
928
908
  }
929
909
  const otherObject = {};
@@ -966,124 +946,71 @@ function Index(props) {
966
946
  }
967
947
  function Show(props) {
968
948
  const keyed = props.keyed;
969
- const condition = createMemo(() => props.when, void 0, {
970
- equals: (a, b) => keyed ? a === b : !a === !b
949
+ const conditionValue = createMemo(() => props.when, void 0, void 0);
950
+ const condition = keyed ? conditionValue : createMemo(conditionValue, void 0, {
951
+ equals: (a, b) => !a === !b
971
952
  });
972
- return createMemo(
973
- () => {
974
- const c = condition();
975
- if (c) {
976
- const child = props.children;
977
- const fn = typeof child === "function" && child.length > 0;
978
- return fn ? untrack(
979
- () => child(
980
- keyed ? c : () => {
981
- if (!untrack(condition)) throw narrowedError("Show");
982
- return props.when;
983
- }
984
- )
985
- ) : child;
986
- }
987
- return props.fallback;
988
- },
989
- void 0,
990
- void 0
991
- );
953
+ return createMemo(() => {
954
+ const c = condition();
955
+ if (c) {
956
+ const child = props.children;
957
+ const fn = typeof child === "function" && child.length > 0;
958
+ return fn ? untrack(() => child(keyed ? c : () => {
959
+ if (!untrack(condition)) throw narrowedError("Show");
960
+ return conditionValue();
961
+ })) : child;
962
+ }
963
+ return props.fallback;
964
+ }, void 0, void 0);
992
965
  }
993
966
  function Switch(props) {
994
- let keyed = false;
995
- const equals = (a, b) => (keyed ? a[1] === b[1] : !a[1] === !b[1]) && a[2] === b[2];
996
- const conditions = children(() => props.children), evalConditions = createMemo(
997
- () => {
998
- let conds = conditions();
999
- if (!Array.isArray(conds)) conds = [conds];
1000
- for (let i = 0; i < conds.length; i++) {
1001
- const c = conds[i].when;
1002
- if (c) {
1003
- keyed = !!conds[i].keyed;
1004
- return [i, c, conds[i]];
1005
- }
1006
- }
1007
- return [-1];
1008
- },
1009
- void 0,
1010
- {
1011
- equals
967
+ const chs = children(() => props.children);
968
+ const switchFunc = createMemo(() => {
969
+ const ch = chs();
970
+ const mps = Array.isArray(ch) ? ch : [ch];
971
+ let func = () => void 0;
972
+ for (let i = 0; i < mps.length; i++) {
973
+ const index = i;
974
+ const mp = mps[i];
975
+ const prevFunc = func;
976
+ const conditionValue = createMemo(() => prevFunc() ? void 0 : mp.when, void 0, void 0);
977
+ const condition = mp.keyed ? conditionValue : createMemo(conditionValue, void 0, {
978
+ equals: (a, b) => !a === !b
979
+ });
980
+ func = () => prevFunc() || (condition() ? [index, conditionValue, mp] : void 0);
1012
981
  }
1013
- );
1014
- return createMemo(
1015
- () => {
1016
- const [index, when, cond] = evalConditions();
1017
- if (index < 0) return props.fallback;
1018
- const c = cond.children;
1019
- const fn = typeof c === "function" && c.length > 0;
1020
- return fn ? untrack(
1021
- () => c(
1022
- keyed ? when : () => {
1023
- if (untrack(evalConditions)[0] !== index) throw narrowedError("Match");
1024
- return cond.when;
1025
- }
1026
- )
1027
- ) : c;
1028
- },
1029
- void 0,
1030
- void 0
1031
- );
982
+ return func;
983
+ });
984
+ return createMemo(() => {
985
+ const sel = switchFunc()();
986
+ if (!sel) return props.fallback;
987
+ const [index, conditionValue, mp] = sel;
988
+ const child = mp.children;
989
+ const fn = typeof child === "function" && child.length > 0;
990
+ return fn ? untrack(() => child(mp.keyed ? conditionValue() : () => {
991
+ if (untrack(switchFunc)()?.[0] !== index) throw narrowedError("Match");
992
+ return conditionValue();
993
+ })) : child;
994
+ }, void 0, void 0);
1032
995
  }
1033
996
  function Match(props) {
1034
997
  return props;
1035
998
  }
1036
999
 
1037
- // ../../node_modules/.pnpm/solid-js@1.9.4/node_modules/solid-js/web/dist/web.js
1038
- var booleans = [
1039
- "allowfullscreen",
1040
- "async",
1041
- "autofocus",
1042
- "autoplay",
1043
- "checked",
1044
- "controls",
1045
- "default",
1046
- "disabled",
1047
- "formnovalidate",
1048
- "hidden",
1049
- "indeterminate",
1050
- "inert",
1051
- "ismap",
1052
- "loop",
1053
- "multiple",
1054
- "muted",
1055
- "nomodule",
1056
- "novalidate",
1057
- "open",
1058
- "playsinline",
1059
- "readonly",
1060
- "required",
1061
- "reversed",
1062
- "seamless",
1063
- "selected"
1064
- ];
1065
- var Properties = /* @__PURE__ */ new Set([
1066
- "className",
1067
- "value",
1068
- "readOnly",
1069
- "formNoValidate",
1070
- "isMap",
1071
- "noModule",
1072
- "playsInline",
1073
- ...booleans
1074
- ]);
1075
- var ChildProperties = /* @__PURE__ */ new Set([
1076
- "innerHTML",
1077
- "textContent",
1078
- "innerText",
1079
- "children"
1080
- ]);
1000
+ // ../../node_modules/.pnpm/solid-js@1.9.7/node_modules/solid-js/web/dist/web.js
1001
+ var booleans = ["allowfullscreen", "async", "autofocus", "autoplay", "checked", "controls", "default", "disabled", "formnovalidate", "hidden", "indeterminate", "inert", "ismap", "loop", "multiple", "muted", "nomodule", "novalidate", "open", "playsinline", "readonly", "required", "reversed", "seamless", "selected"];
1002
+ var Properties = /* @__PURE__ */ new Set(["className", "value", "readOnly", "noValidate", "formNoValidate", "isMap", "noModule", "playsInline", ...booleans]);
1003
+ var ChildProperties = /* @__PURE__ */ new Set(["innerHTML", "textContent", "innerText", "children"]);
1081
1004
  var Aliases = /* @__PURE__ */ Object.assign(/* @__PURE__ */ Object.create(null), {
1082
1005
  className: "class",
1083
1006
  htmlFor: "for"
1084
1007
  });
1085
1008
  var PropAliases = /* @__PURE__ */ Object.assign(/* @__PURE__ */ Object.create(null), {
1086
1009
  class: "className",
1010
+ novalidate: {
1011
+ $: "noValidate",
1012
+ FORM: 1
1013
+ },
1087
1014
  formnovalidate: {
1088
1015
  $: "formNoValidate",
1089
1016
  BUTTON: 1,
@@ -1111,34 +1038,12 @@ function getPropAlias(prop, tagName) {
1111
1038
  const a = PropAliases[prop];
1112
1039
  return typeof a === "object" ? a[tagName] ? a["$"] : void 0 : a;
1113
1040
  }
1114
- var DelegatedEvents = /* @__PURE__ */ new Set([
1115
- "beforeinput",
1116
- "click",
1117
- "dblclick",
1118
- "contextmenu",
1119
- "focusin",
1120
- "focusout",
1121
- "input",
1122
- "keydown",
1123
- "keyup",
1124
- "mousedown",
1125
- "mousemove",
1126
- "mouseout",
1127
- "mouseover",
1128
- "mouseup",
1129
- "pointerdown",
1130
- "pointermove",
1131
- "pointerout",
1132
- "pointerover",
1133
- "pointerup",
1134
- "touchend",
1135
- "touchmove",
1136
- "touchstart"
1137
- ]);
1041
+ var DelegatedEvents = /* @__PURE__ */ new Set(["beforeinput", "click", "dblclick", "contextmenu", "focusin", "focusout", "input", "keydown", "keyup", "mousedown", "mousemove", "mouseout", "mouseover", "mouseup", "pointerdown", "pointermove", "pointerout", "pointerover", "pointerup", "touchend", "touchmove", "touchstart"]);
1138
1042
  var SVGNamespace = {
1139
1043
  xlink: "http://www.w3.org/1999/xlink",
1140
1044
  xml: "http://www.w3.org/XML/1998/namespace"
1141
1045
  };
1046
+ var memo = (fn) => createMemo(() => fn());
1142
1047
  function reconcileArrays(parentNode, a, b) {
1143
1048
  let bLength = b.length, aEnd = a.length, bEnd = bLength, aStart = 0, bStart = 0, after = a[aEnd - 1].nextSibling, map = null;
1144
1049
  while (aStart < aEnd || bStart < bEnd) {
@@ -1199,12 +1104,12 @@ function render(code, element, init, options = {}) {
1199
1104
  element.textContent = "";
1200
1105
  };
1201
1106
  }
1202
- function template(html, isImportNode, isSVG) {
1107
+ function template(html, isImportNode, isSVG, isMathML) {
1203
1108
  let node;
1204
1109
  const create = () => {
1205
- const t = document.createElement("template");
1110
+ const t = isMathML ? document.createElementNS("http://www.w3.org/1998/Math/MathML", "template") : document.createElement("template");
1206
1111
  t.innerHTML = html;
1207
- return isSVG ? t.content.firstChild.firstChild : t.content.firstChild;
1112
+ return isSVG ? t.content.firstChild.firstChild : isMathML ? t.firstChild : t.content.firstChild;
1208
1113
  };
1209
1114
  const fn = isImportNode ? () => untrack(() => document.importNode(node || (node = create()), true)) : () => (node || (node = create())).cloneNode(true);
1210
1115
  fn.cloneNode = fn;
@@ -1291,9 +1196,7 @@ function style(node, value, prev) {
1291
1196
  function spread(node, props = {}, isSVG, skipChildren) {
1292
1197
  const prevProps = {};
1293
1198
  if (!skipChildren) {
1294
- createRenderEffect(
1295
- () => prevProps.children = insertExpression(node, props.children, prevProps.children)
1296
- );
1199
+ createRenderEffect(() => prevProps.children = insertExpression(node, props.children, prevProps.children));
1297
1200
  }
1298
1201
  createRenderEffect(() => typeof props.ref === "function" && use(props.ref, node));
1299
1202
  createRenderEffect(() => assign(node, props, isSVG, true, prevProps, true));
@@ -1332,8 +1235,7 @@ function toPropertyName(name) {
1332
1235
  }
1333
1236
  function toggleClassKey(node, key, value) {
1334
1237
  const classNames = key.trim().split(/\s+/);
1335
- for (let i = 0, nameLen = classNames.length; i < nameLen; i++)
1336
- node.classList.toggle(classNames[i], value);
1238
+ for (let i = 0, nameLen = classNames.length; i < nameLen; i++) node.classList.toggle(classNames[i], value);
1337
1239
  }
1338
1240
  function assignProp(node, prop, value, prev, isSVG, skipRef, props) {
1339
1241
  let isCE, isProp, isChildProp, propAlias, forceProp;
@@ -1525,11 +1427,7 @@ function normalizeIncomingArray(normalized, array, current, unwrap) {
1525
1427
  } else if (t === "function") {
1526
1428
  if (unwrap) {
1527
1429
  while (typeof item === "function") item = item();
1528
- dynamic = normalizeIncomingArray(
1529
- normalized,
1530
- Array.isArray(item) ? item : [item],
1531
- Array.isArray(prev) ? prev : [prev]
1532
- ) || dynamic;
1430
+ dynamic = normalizeIncomingArray(normalized, Array.isArray(item) ? item : [item], Array.isArray(prev) ? prev : [prev]) || dynamic;
1533
1431
  } else {
1534
1432
  normalized.push(item);
1535
1433
  dynamic = true;
@@ -1554,8 +1452,7 @@ function cleanChildren(parent, current, marker, replacement) {
1554
1452
  const el = current[i];
1555
1453
  if (node !== el) {
1556
1454
  const isParent = el.parentNode === parent;
1557
- if (!inserted && !i)
1558
- isParent ? parent.replaceChild(node, el) : parent.insertBefore(node, marker);
1455
+ if (!inserted && !i) isParent ? parent.replaceChild(node, el) : parent.insertBefore(node, marker);
1559
1456
  else isParent && el.remove();
1560
1457
  } else inserted = true;
1561
1458
  }
@@ -1569,50 +1466,48 @@ function createElement(tagName, isSVG = false) {
1569
1466
  return isSVG ? document.createElementNS(SVG_NAMESPACE, tagName) : document.createElement(tagName);
1570
1467
  }
1571
1468
  function Portal(props) {
1572
- const { useShadow } = props, marker = document.createTextNode(""), mount = () => props.mount || document.body, owner = getOwner();
1469
+ const {
1470
+ useShadow
1471
+ } = props, marker = document.createTextNode(""), mount = () => props.mount || document.body, owner = getOwner();
1573
1472
  let content;
1574
1473
  let hydrating = !!sharedConfig.context;
1575
- createEffect(
1576
- () => {
1577
- if (hydrating) getOwner().user = hydrating = false;
1578
- content || (content = runWithOwner(owner, () => createMemo(() => props.children)));
1579
- const el = mount();
1580
- if (el instanceof HTMLHeadElement) {
1581
- const [clean2, setClean] = createSignal(false);
1582
- const cleanup = () => setClean(true);
1583
- createRoot((dispose2) => insert(el, () => !clean2() ? content() : dispose2(), null));
1584
- onCleanup(cleanup);
1585
- } else {
1586
- const container = createElement(props.isSVG ? "g" : "div", props.isSVG), renderRoot = useShadow && container.attachShadow ? container.attachShadow({
1587
- mode: "open"
1588
- }) : container;
1589
- Object.defineProperty(container, "_$host", {
1590
- get() {
1591
- return marker.parentNode;
1592
- },
1593
- configurable: true
1594
- });
1595
- insert(renderRoot, content);
1596
- el.appendChild(container);
1597
- props.ref && props.ref(container);
1598
- onCleanup(() => el.removeChild(container));
1599
- }
1600
- },
1601
- void 0,
1602
- {
1603
- render: !hydrating
1474
+ createEffect(() => {
1475
+ if (hydrating) getOwner().user = hydrating = false;
1476
+ content || (content = runWithOwner(owner, () => createMemo(() => props.children)));
1477
+ const el = mount();
1478
+ if (el instanceof HTMLHeadElement) {
1479
+ const [clean2, setClean] = createSignal(false);
1480
+ const cleanup = () => setClean(true);
1481
+ createRoot((dispose2) => insert(el, () => !clean2() ? content() : dispose2(), null));
1482
+ onCleanup(cleanup);
1483
+ } else {
1484
+ const container = createElement(props.isSVG ? "g" : "div", props.isSVG), renderRoot = useShadow && container.attachShadow ? container.attachShadow({
1485
+ mode: "open"
1486
+ }) : container;
1487
+ Object.defineProperty(container, "_$host", {
1488
+ get() {
1489
+ return marker.parentNode;
1490
+ },
1491
+ configurable: true
1492
+ });
1493
+ insert(renderRoot, content);
1494
+ el.appendChild(container);
1495
+ props.ref && props.ref(container);
1496
+ onCleanup(() => el.removeChild(container));
1604
1497
  }
1605
- );
1498
+ }, void 0, {
1499
+ render: !hydrating
1500
+ });
1606
1501
  return marker;
1607
1502
  }
1608
1503
 
1609
- // ../../node_modules/.pnpm/nanostores@0.11.3/node_modules/nanostores/task/index.js
1504
+ // ../../node_modules/.pnpm/nanostores@0.11.4/node_modules/nanostores/task/index.js
1610
1505
  var tasks = 0;
1611
1506
  function cleanTasks() {
1612
1507
  tasks = 0;
1613
1508
  }
1614
1509
 
1615
- // ../../node_modules/.pnpm/nanostores@0.11.3/node_modules/nanostores/clean-stores/index.js
1510
+ // ../../node_modules/.pnpm/nanostores@0.11.4/node_modules/nanostores/clean-stores/index.js
1616
1511
  var clean = Symbol("clean");
1617
1512
  var cleanStores = (...stores) => {
1618
1513
  if (false) {
@@ -1629,7 +1524,7 @@ var cleanStores = (...stores) => {
1629
1524
  }
1630
1525
  };
1631
1526
 
1632
- // ../../node_modules/.pnpm/nanostores@0.11.3/node_modules/nanostores/atom/index.js
1527
+ // ../../node_modules/.pnpm/nanostores@0.11.4/node_modules/nanostores/atom/index.js
1633
1528
  var listenerQueue = [];
1634
1529
  var lqIndex = 0;
1635
1530
  var QUEUE_ITEMS_PER_LISTENER = 4;
@@ -1712,7 +1607,7 @@ var atom = (initialValue) => {
1712
1607
  return $atom;
1713
1608
  };
1714
1609
 
1715
- // ../../node_modules/.pnpm/nanostores@0.11.3/node_modules/nanostores/lifecycle/index.js
1610
+ // ../../node_modules/.pnpm/nanostores@0.11.4/node_modules/nanostores/lifecycle/index.js
1716
1611
  var MOUNT = 5;
1717
1612
  var UNMOUNT = 6;
1718
1613
  var REVERT_MUTATION = 10;
@@ -1782,7 +1677,7 @@ var onMount2 = ($store, initialize) => {
1782
1677
  });
1783
1678
  };
1784
1679
 
1785
- // ../../node_modules/.pnpm/nanostores@0.11.3/node_modules/nanostores/deep-map/path.js
1680
+ // ../../node_modules/.pnpm/nanostores@0.11.4/node_modules/nanostores/deep-map/path.js
1786
1681
  function getPath(obj, path) {
1787
1682
  let allKeys = getAllKeysFromPath(path);
1788
1683
  let res = obj;
@@ -1840,7 +1735,7 @@ function ensureKey(obj, key, nextKey) {
1840
1735
  }
1841
1736
  }
1842
1737
 
1843
- // ../../node_modules/.pnpm/nanostores@0.11.3/node_modules/nanostores/deep-map/index.js
1738
+ // ../../node_modules/.pnpm/nanostores@0.11.4/node_modules/nanostores/deep-map/index.js
1844
1739
  function deepMap(initial = {}) {
1845
1740
  let $deepMap = atom(initial);
1846
1741
  $deepMap.setKey = (key, value) => {
@@ -1853,7 +1748,7 @@ function deepMap(initial = {}) {
1853
1748
  return $deepMap;
1854
1749
  }
1855
1750
 
1856
- // ../../node_modules/.pnpm/yocto-queue@1.1.1/node_modules/yocto-queue/index.js
1751
+ // ../../node_modules/.pnpm/yocto-queue@1.2.1/node_modules/yocto-queue/index.js
1857
1752
  var Node = class {
1858
1753
  value;
1859
1754
  next;
@@ -1909,6 +1804,11 @@ var Queue = class {
1909
1804
  current = current.next;
1910
1805
  }
1911
1806
  }
1807
+ *drain() {
1808
+ while (this.#head) {
1809
+ yield this.dequeue();
1810
+ }
1811
+ }
1912
1812
  };
1913
1813
 
1914
1814
  // ../../node_modules/.pnpm/p-limit@6.2.0/node_modules/p-limit/index.js
@@ -1984,7 +1884,7 @@ function validateConcurrency(concurrency) {
1984
1884
  }
1985
1885
  }
1986
1886
 
1987
- // ../../node_modules/.pnpm/simple-web-audio@0.9.0_postcss@8.5.3/node_modules/simple-web-audio/dist/index.mjs
1887
+ // ../../node_modules/.pnpm/simple-web-audio@0.9.0_postcss@8.5.6/node_modules/simple-web-audio/dist/index.mjs
1988
1888
  var waitForInteraction = (() => {
1989
1889
  const { promise, resolve } = Promise.withResolvers();
1990
1890
  const onUserInteraction = () => {
@@ -3168,13 +3068,13 @@ var ControlPanelButtons = (props) => {
3168
3068
  createRenderEffect(() => setAttribute(_el$7, "title", data.t(props.auto() ? "Stop" : "Auto")));
3169
3069
  return _el$7;
3170
3070
  })(), (() => {
3171
- var _el$9 = _tmpl$3(), _el$10 = _el$9.firstChild;
3071
+ var _el$9 = _tmpl$3(), _el$0 = _el$9.firstChild;
3172
3072
  _el$9.$$click = () => {
3173
3073
  data.options.save("auto");
3174
3074
  data.options.exit(true);
3175
3075
  props.openSettings();
3176
3076
  };
3177
- insert(_el$10, () => data.t("Settings"));
3077
+ insert(_el$0, () => data.t("Settings"));
3178
3078
  insert(_el$9, createComponent(Icon, {
3179
3079
  "class": "control-panel__button__icon",
3180
3080
  icon: "#novely-settings-icon"
@@ -3182,31 +3082,31 @@ var ControlPanelButtons = (props) => {
3182
3082
  createRenderEffect(() => setAttribute(_el$9, "title", data.t("Settings")));
3183
3083
  return _el$9;
3184
3084
  })(), (() => {
3185
- var _el$11 = _tmpl$3(), _el$12 = _el$11.firstChild;
3186
- _el$11.$$click = () => {
3085
+ var _el$1 = _tmpl$3(), _el$10 = _el$1.firstChild;
3086
+ _el$1.$$click = () => {
3187
3087
  data.options.exit();
3188
3088
  };
3189
- insert(_el$12, () => data.t("Exit"));
3190
- insert(_el$11, createComponent(Icon, {
3089
+ insert(_el$10, () => data.t("Exit"));
3090
+ insert(_el$1, createComponent(Icon, {
3191
3091
  "class": "control-panel__button__icon",
3192
3092
  icon: "#novely-x-icon"
3193
3093
  }), null);
3194
- createRenderEffect(() => setAttribute(_el$11, "title", data.t("Exit")));
3195
- return _el$11;
3094
+ createRenderEffect(() => setAttribute(_el$1, "title", data.t("Exit")));
3095
+ return _el$1;
3196
3096
  })(), createComponent(Show, {
3197
3097
  get when() {
3198
3098
  return data.media.hyperWide();
3199
3099
  },
3200
3100
  get children() {
3201
- var _el$13 = _tmpl$4();
3202
- _el$13.$$click = () => {
3101
+ var _el$11 = _tmpl$4();
3102
+ _el$11.$$click = () => {
3203
3103
  props.closeDropdown();
3204
3104
  };
3205
- insert(_el$13, createComponent(Icon, {
3105
+ insert(_el$11, createComponent(Icon, {
3206
3106
  icon: "#novely-x-icon"
3207
3107
  }));
3208
- createRenderEffect(() => setAttribute(_el$13, "title", data.t("CloseMenu")));
3209
- return _el$13;
3108
+ createRenderEffect(() => setAttribute(_el$11, "title", data.t("CloseMenu")));
3109
+ return _el$11;
3210
3110
  }
3211
3111
  })];
3212
3112
  };
@@ -3227,7 +3127,7 @@ var DialogName = (props) => {
3227
3127
  get when() {
3228
3128
  return props.mood;
3229
3129
  },
3230
- children: (mood) => [" ", _tmpl$23(), " ", createMemo(mood)]
3130
+ children: (mood) => [" ", _tmpl$23(), " ", memo(mood)]
3231
3131
  }), null);
3232
3132
  createRenderEffect((_p$) => {
3233
3133
  var _v$ = color(), _v$2 = props.character ? 1 : 0, _v$3 = props.character ? "visible" : "hidden";
@@ -3300,7 +3200,7 @@ var Modal = (props) => {
3300
3200
  })();
3301
3201
  };
3302
3202
 
3303
- // ../../node_modules/.pnpm/@solid-primitives+transition-group@1.1.0_solid-js@1.9.4/node_modules/@solid-primitives/transition-group/dist/index.js
3203
+ // ../../node_modules/.pnpm/@solid-primitives+transition-group@1.1.1_solid-js@1.9.7/node_modules/@solid-primitives/transition-group/dist/index.js
3304
3204
  var noop2 = () => {
3305
3205
  };
3306
3206
  var noopTransition = (el, done) => done();
@@ -3366,10 +3266,10 @@ function createSwitchTransition(source, options) {
3366
3266
  return returned;
3367
3267
  }
3368
3268
 
3369
- // ../../node_modules/.pnpm/@solid-primitives+utils@6.3.0_solid-js@1.9.4/node_modules/@solid-primitives/utils/dist/index.js
3269
+ // ../../node_modules/.pnpm/@solid-primitives+utils@6.3.1_solid-js@1.9.7/node_modules/@solid-primitives/utils/dist/index.js
3370
3270
  var access = (v) => typeof v === "function" && !v.length ? v() : v;
3371
3271
 
3372
- // ../../node_modules/.pnpm/@solid-primitives+refs@1.1.0_solid-js@1.9.4/node_modules/@solid-primitives/refs/dist/index.js
3272
+ // ../../node_modules/.pnpm/@solid-primitives+refs@1.1.1_solid-js@1.9.7/node_modules/@solid-primitives/refs/dist/index.js
3373
3273
  var defaultElementPredicate = isServer ? (item) => item != null && typeof item === "object" && "t" in item : (item) => item instanceof Element;
3374
3274
  function getFirstChild(value, predicate) {
3375
3275
  if (predicate(value))
@@ -3390,7 +3290,7 @@ function resolveFirst(fn, predicate = defaultElementPredicate, serverPredicate =
3390
3290
  return createMemo(() => getFirstChild(children2(), isServer ? serverPredicate : predicate));
3391
3291
  }
3392
3292
 
3393
- // ../../node_modules/.pnpm/solid-transition-group@0.2.3_solid-js@1.9.4/node_modules/solid-transition-group/dist/index.js
3293
+ // ../../node_modules/.pnpm/solid-transition-group@0.3.0_solid-js@1.9.7/node_modules/solid-transition-group/dist/index.js
3394
3294
  function createClassnames(props) {
3395
3295
  return createMemo(() => {
3396
3296
  const name = props.name || "s";
@@ -3470,19 +3370,16 @@ var TRANSITION_MODE_MAP = {
3470
3370
  };
3471
3371
  var Transition2 = (props) => {
3472
3372
  const classnames = createClassnames(props);
3473
- return createSwitchTransition(
3474
- resolveFirst(() => props.children),
3475
- {
3476
- mode: TRANSITION_MODE_MAP[props.mode],
3477
- appear: props.appear,
3478
- onEnter(el, done) {
3479
- enterTransition(classnames(), props, el, done);
3480
- },
3481
- onExit(el, done) {
3482
- exitTransition(classnames(), props, el, done);
3483
- }
3373
+ return createSwitchTransition(resolveFirst(() => props.children), {
3374
+ mode: TRANSITION_MODE_MAP[props.mode],
3375
+ appear: props.appear,
3376
+ onEnter(el, done) {
3377
+ enterTransition(classnames(), props, el, done);
3378
+ },
3379
+ onExit(el, done) {
3380
+ exitTransition(classnames(), props, el, done);
3484
3381
  }
3485
- );
3382
+ });
3486
3383
  };
3487
3384
 
3488
3385
  // src/context-state.ts
@@ -3496,7 +3393,7 @@ var { useContextState, removeContextState } = createContextStateRoot(() => {
3496
3393
 
3497
3394
  // src/components/Save.tsx
3498
3395
  var _tmpl$7 = /* @__PURE__ */ template(`<div class=saves__list-item__overlay>`);
3499
- var _tmpl$24 = /* @__PURE__ */ template(`<iframe tabindex=-1 class=saves__list-item__iframe src=about:blank>`, true, false);
3396
+ var _tmpl$24 = /* @__PURE__ */ template(`<iframe tabindex=-1 class=saves__list-item__iframe src=about:blank>`, true, false, false);
3500
3397
  var _tmpl$33 = /* @__PURE__ */ template(`<li class=saves__list-item><div class=saves__list-item__load role=button tabindex=0></div><div class=saves__list-item__description><div></div><div></div></div><button type=reset class="button saves__button-reset"><span>`);
3501
3398
  var _tmpl$42 = /* @__PURE__ */ template(`<div class=saves__list-item__iframe>`);
3502
3399
  var CURRENT_DATE = /* @__PURE__ */ new Date();
@@ -4095,15 +3992,15 @@ var DialogOverview = (props) => {
4095
3992
  return entries();
4096
3993
  },
4097
3994
  children: (entry) => (() => {
4098
- var _el$6 = _tmpl$43(), _el$7 = _el$6.firstChild, _el$8 = _el$7.firstChild, _el$9 = _el$7.nextSibling, _el$11 = _el$9.nextSibling, _el$12 = _el$11.firstChild;
3995
+ var _el$6 = _tmpl$43(), _el$7 = _el$6.firstChild, _el$8 = _el$7.firstChild, _el$9 = _el$7.nextSibling, _el$1 = _el$9.nextSibling, _el$10 = _el$1.firstChild;
4099
3996
  insert(_el$8, () => removeTagsFromHTML(entry.name));
4100
3997
  insert(_el$9, createComponent(Show, {
4101
3998
  get when() {
4102
3999
  return entry.voice;
4103
4000
  },
4104
4001
  get children() {
4105
- var _el$10 = _tmpl$34();
4106
- _el$10.$$click = async () => {
4002
+ var _el$0 = _tmpl$34();
4003
+ _el$0.$$click = async () => {
4107
4004
  if (!entry.voice) return;
4108
4005
  const voice = props.audio.getAudio("voice", entry.voice);
4109
4006
  const source = currentlyPlayingSource();
@@ -4129,15 +4026,15 @@ var DialogOverview = (props) => {
4129
4026
  });
4130
4027
  }
4131
4028
  };
4132
- insert(_el$10, createComponent(Icon, {
4029
+ insert(_el$0, createComponent(Icon, {
4133
4030
  get icon() {
4134
4031
  return currentlyPlayingSource() === entry.voice ? "#novely-stop-icon" : "#novely-play-icon";
4135
4032
  }
4136
4033
  }));
4137
- return _el$10;
4034
+ return _el$0;
4138
4035
  }
4139
4036
  }));
4140
- insert(_el$12, () => removeTagsFromHTML(entry.text));
4037
+ insert(_el$10, () => removeTagsFromHTML(entry.text));
4141
4038
  return _el$6;
4142
4039
  })()
4143
4040
  })
@@ -4165,7 +4062,7 @@ var Await = (props) => {
4165
4062
  });
4166
4063
  };
4167
4064
 
4168
- // ../../node_modules/.pnpm/@solid-primitives+destructure@0.2.0_solid-js@1.9.4/node_modules/@solid-primitives/destructure/dist/index.js
4065
+ // ../../node_modules/.pnpm/@solid-primitives+destructure@0.2.1_solid-js@1.9.7/node_modules/@solid-primitives/destructure/dist/index.js
4169
4066
  var isReactiveObject = (value) => typeof value === "object" && value !== null;
4170
4067
  function createProxyCache(obj, get) {
4171
4068
  return new Proxy({}, {
@@ -4184,7 +4081,7 @@ function createProxyCache(obj, get) {
4184
4081
  }
4185
4082
  function destructure(source, options) {
4186
4083
  const config = options ?? {};
4187
- const memo = config.memo ?? typeof source === "function";
4084
+ const memo2 = config.memo ?? typeof source === "function";
4188
4085
  const getter = typeof source === "function" ? (key) => () => source()[key] : (key) => () => source[key];
4189
4086
  const obj = access(source);
4190
4087
  if (config.lazy) {
@@ -4192,17 +4089,17 @@ function destructure(source, options) {
4192
4089
  return createProxyCache(obj, (key) => {
4193
4090
  const calc = getter(key);
4194
4091
  if (config.deep && isReactiveObject(obj[key]))
4195
- return runWithOwner(owner, () => destructure(calc, { ...config, memo }));
4196
- return memo ? runWithOwner(owner, () => createMemo(calc, void 0, options)) : calc;
4092
+ return runWithOwner(owner, () => destructure(calc, { ...config, memo: memo2 }));
4093
+ return memo2 ? runWithOwner(owner, () => createMemo(calc, void 0, options)) : calc;
4197
4094
  });
4198
4095
  }
4199
4096
  const result = Array.isArray(obj) ? [] : {};
4200
4097
  for (const [key, value] of Object.entries(obj)) {
4201
4098
  const calc = getter(key);
4202
4099
  if (config.deep && isReactiveObject(value))
4203
- result[key] = destructure(calc, { ...config, memo });
4100
+ result[key] = destructure(calc, { ...config, memo: memo2 });
4204
4101
  else
4205
- result[key] = memo ? createMemo(calc, void 0, options) : calc;
4102
+ result[key] = memo2 ? createMemo(calc, void 0, options) : calc;
4206
4103
  }
4207
4104
  return result;
4208
4105
  }
@@ -4217,12 +4114,12 @@ var _tmpl$62 = /* @__PURE__ */ template(`<button type=submit class="button dialo
4217
4114
  var _tmpl$72 = /* @__PURE__ */ template(`<div class=exit-dialog-buttons><button type=button class=button></button><button type=button class=button>`);
4218
4115
  var _tmpl$82 = /* @__PURE__ */ template(`<button type=button class="button control-panel__button">`);
4219
4116
  var _tmpl$92 = /* @__PURE__ */ template(`<span class=control-panel-container-fix aria-hidden=true>&#8203;`);
4220
- var _tmpl$102 = /* @__PURE__ */ template(`<div class=control-panel-container-backdrop>`);
4221
- var _tmpl$112 = /* @__PURE__ */ template(`<div class=control-panel><div role=menubar class=control-panel-container>`);
4222
- var _tmpl$122 = /* @__PURE__ */ template(`<div class="loading overlay game"><div class=loading__animation><div></div><div></div><div></div><div>`);
4223
- var _tmpl$132 = /* @__PURE__ */ template(`<div><div class=background></div><div class=characters></div><div class=action-dialog><div class=action-dialog-container role=button tabindex=0><div class=action-dialog-content></div></div></div><div></div><div class=action-text role=button tabindex=0></div><div class=action-image>`);
4224
- var _tmpl$14 = /* @__PURE__ */ template(`<button type=button class="button choice-dialog__choice"><span>`);
4225
- var _tmpl$15 = /* @__PURE__ */ template(`<div class=action-image__image-container>`);
4117
+ var _tmpl$0 = /* @__PURE__ */ template(`<div class=control-panel-container-backdrop>`);
4118
+ var _tmpl$1 = /* @__PURE__ */ template(`<div class=control-panel><div role=menubar class=control-panel-container>`);
4119
+ var _tmpl$102 = /* @__PURE__ */ template(`<div class="loading overlay game"><div class=loading__animation><div></div><div></div><div></div><div>`);
4120
+ var _tmpl$112 = /* @__PURE__ */ template(`<div><div class=background></div><div class=characters></div><div class=action-dialog><div class=action-dialog-container role=button tabindex=0><div class=action-dialog-content></div></div></div><div></div><div class=action-text role=button tabindex=0></div><div class=action-image>`);
4121
+ var _tmpl$122 = /* @__PURE__ */ template(`<button type=button class="button choice-dialog__choice"><span>`);
4122
+ var _tmpl$132 = /* @__PURE__ */ template(`<div class=action-image__image-container>`);
4226
4123
  var Game = (props) => {
4227
4124
  const data = useData();
4228
4125
  const {
@@ -4322,7 +4219,7 @@ var Game = (props) => {
4322
4219
  }
4323
4220
  });
4324
4221
  return (() => {
4325
- var _el$ = _tmpl$132(), _el$2 = _el$.firstChild, _el$3 = _el$2.nextSibling, _el$4 = _el$3.nextSibling, _el$5 = _el$4.firstChild, _el$7 = _el$5.firstChild, _el$17 = _el$4.nextSibling, _el$18 = _el$17.nextSibling, _el$24 = _el$18.nextSibling;
4222
+ var _el$ = _tmpl$112(), _el$2 = _el$.firstChild, _el$3 = _el$2.nextSibling, _el$4 = _el$3.nextSibling, _el$5 = _el$4.firstChild, _el$7 = _el$5.firstChild, _el$15 = _el$4.nextSibling, _el$16 = _el$15.nextSibling, _el$22 = _el$16.nextSibling;
4326
4223
  setAttribute(_el$3, "data-characters", true);
4327
4224
  insert(_el$3, createComponent(For, {
4328
4225
  get each() {
@@ -4426,14 +4323,14 @@ var Game = (props) => {
4426
4323
  return visible();
4427
4324
  },
4428
4325
  get children() {
4429
- var _el$26 = _tmpl$14(), _el$27 = _el$26.firstChild;
4430
- _el$26.$$click = () => {
4326
+ var _el$24 = _tmpl$122(), _el$25 = _el$24.firstChild;
4327
+ _el$24.$$click = () => {
4431
4328
  onSelect();
4432
4329
  if (disabled()) return;
4433
4330
  choice().resolve?.(index);
4434
4331
  };
4435
- insert(_el$27, text2);
4436
- insert(_el$26, createComponent(Show, {
4332
+ insert(_el$25, text2);
4333
+ insert(_el$24, createComponent(Show, {
4437
4334
  when: image !== "",
4438
4335
  get children() {
4439
4336
  return createComponent(Canvas, {
@@ -4448,8 +4345,8 @@ var Game = (props) => {
4448
4345
  });
4449
4346
  }
4450
4347
  }), null);
4451
- createRenderEffect(() => setAttribute(_el$26, "aria-disabled", disabled()));
4452
- return _el$26;
4348
+ createRenderEffect(() => setAttribute(_el$24, "aria-disabled", disabled()));
4349
+ return _el$24;
4453
4350
  }
4454
4351
  });
4455
4352
  }
@@ -4457,7 +4354,7 @@ var Game = (props) => {
4457
4354
  return _el$9;
4458
4355
  })()];
4459
4356
  }
4460
- }), _el$17);
4357
+ }), _el$15);
4461
4358
  insert(_el$, createComponent(Modal, {
4462
4359
  "class": "input-dialog",
4463
4360
  isModal: false,
@@ -4468,22 +4365,22 @@ var Game = (props) => {
4468
4365
  trapFocus: () => !props.isPreview && !exitPromptShown(),
4469
4366
  get children() {
4470
4367
  return [(() => {
4471
- var _el$10 = _tmpl$44();
4472
- insert(_el$10, () => input().label);
4473
- return _el$10;
4474
- })(), createMemo(() => input().element), (() => {
4475
- var _el$11 = _tmpl$52();
4476
- insert(_el$11, () => input().error);
4477
- return _el$11;
4368
+ var _el$0 = _tmpl$44();
4369
+ insert(_el$0, () => input().label);
4370
+ return _el$0;
4371
+ })(), memo(() => input().element), (() => {
4372
+ var _el$1 = _tmpl$52();
4373
+ insert(_el$1, () => input().error);
4374
+ return _el$1;
4478
4375
  })(), (() => {
4479
- var _el$12 = _tmpl$62();
4480
- _el$12.$$click = onInputButtonClick;
4481
- insert(_el$12, () => data.t("Sumbit"));
4482
- createRenderEffect(() => setAttribute(_el$12, "aria-disabled", Boolean(input().error)));
4483
- return _el$12;
4376
+ var _el$10 = _tmpl$62();
4377
+ _el$10.$$click = onInputButtonClick;
4378
+ insert(_el$10, () => data.t("Sumbit"));
4379
+ createRenderEffect(() => setAttribute(_el$10, "aria-disabled", Boolean(input().error)));
4380
+ return _el$10;
4484
4381
  })()];
4485
4382
  }
4486
- }), _el$17);
4383
+ }), _el$15);
4487
4384
  insert(_el$, createComponent(Modal, {
4488
4385
  "class": "exit-dialog",
4489
4386
  isModal: true,
@@ -4491,34 +4388,34 @@ var Game = (props) => {
4491
4388
  trapFocus: () => !props.isPreview && exitPromptShown(),
4492
4389
  get children() {
4493
4390
  return [(() => {
4494
- var _el$13 = _tmpl$26();
4495
- insert(_el$13, () => data.t("ExitDialogWarning"));
4496
- return _el$13;
4391
+ var _el$11 = _tmpl$26();
4392
+ insert(_el$11, () => data.t("ExitDialogWarning"));
4393
+ return _el$11;
4497
4394
  })(), (() => {
4498
- var _el$14 = _tmpl$72(), _el$15 = _el$14.firstChild, _el$16 = _el$15.nextSibling;
4499
- _el$15.$$click = () => {
4395
+ var _el$12 = _tmpl$72(), _el$13 = _el$12.firstChild, _el$14 = _el$13.nextSibling;
4396
+ _el$13.$$click = () => {
4500
4397
  data.$rendererState.setKey("exitPromptShown", false);
4501
4398
  };
4502
- insert(_el$15, () => data.t("ExitDialogBack"));
4503
- _el$16.$$click = () => {
4399
+ insert(_el$13, () => data.t("ExitDialogBack"));
4400
+ _el$14.$$click = () => {
4504
4401
  data.options.exit(true);
4505
4402
  };
4506
- insert(_el$16, () => data.t("ExitDialogExit"));
4507
- return _el$14;
4403
+ insert(_el$14, () => data.t("ExitDialogExit"));
4404
+ return _el$12;
4508
4405
  })()];
4509
4406
  }
4510
- }), _el$17);
4511
- setAttribute(_el$17, "data-custom", true);
4512
- insert(_el$17, createComponent(For, {
4407
+ }), _el$15);
4408
+ setAttribute(_el$15, "data-custom", true);
4409
+ insert(_el$15, createComponent(For, {
4513
4410
  get each() {
4514
4411
  return customs();
4515
4412
  },
4516
4413
  children: (value) => value.node
4517
4414
  }));
4518
- addEventListener2(_el$18, "keydown", onKey(TextWriter.click, " "), true);
4519
- addEventListener2(_el$18, "keypress", onKey(TextWriter.click, "Enter"));
4520
- addEventListener2(_el$18, "click", TextWriter.click, true);
4521
- insert(_el$18, createComponent(TextWriter.Typewriter, {
4415
+ addEventListener2(_el$16, "keydown", onKey(TextWriter.click, " "), true);
4416
+ addEventListener2(_el$16, "keypress", onKey(TextWriter.click, "Enter"));
4417
+ addEventListener2(_el$16, "click", TextWriter.click, true);
4418
+ insert(_el$16, createComponent(TextWriter.Typewriter, {
4522
4419
  get content() {
4523
4420
  return text().content;
4524
4421
  }
@@ -4528,8 +4425,8 @@ var Game = (props) => {
4528
4425
  return !props.isPreview;
4529
4426
  },
4530
4427
  get children() {
4531
- var _el$19 = _tmpl$112(), _el$23 = _el$19.firstChild;
4532
- insert(_el$19, createComponent(Show, {
4428
+ var _el$17 = _tmpl$1(), _el$21 = _el$17.firstChild;
4429
+ insert(_el$17, createComponent(Show, {
4533
4430
  get when() {
4534
4431
  return data.media.hyperWide();
4535
4432
  },
@@ -4539,46 +4436,46 @@ var Game = (props) => {
4539
4436
  return !controlPanelMenuExpanded();
4540
4437
  },
4541
4438
  get children() {
4542
- var _el$20 = _tmpl$82();
4543
- _el$20.$$click = () => {
4439
+ var _el$18 = _tmpl$82();
4440
+ _el$18.$$click = () => {
4544
4441
  setControlPanelMenuExpanded((prev) => !prev);
4545
4442
  };
4546
- setAttribute(_el$20, "aria-controls", controlPanelMenuID);
4547
- insert(_el$20, createComponent(Icon, {
4443
+ setAttribute(_el$18, "aria-controls", controlPanelMenuID);
4444
+ insert(_el$18, createComponent(Icon, {
4548
4445
  icon: "#novely-list-icon"
4549
4446
  }));
4550
4447
  createRenderEffect((_p$) => {
4551
4448
  var _v$3 = data.t("OpenMenu"), _v$4 = controlPanelMenuExpanded();
4552
- _v$3 !== _p$.e && setAttribute(_el$20, "title", _p$.e = _v$3);
4553
- _v$4 !== _p$.t && setAttribute(_el$20, "aria-expanded", _p$.t = _v$4);
4449
+ _v$3 !== _p$.e && setAttribute(_el$18, "title", _p$.e = _v$3);
4450
+ _v$4 !== _p$.t && setAttribute(_el$18, "aria-expanded", _p$.t = _v$4);
4554
4451
  return _p$;
4555
4452
  }, {
4556
4453
  e: void 0,
4557
4454
  t: void 0
4558
4455
  });
4559
- return _el$20;
4456
+ return _el$18;
4560
4457
  }
4561
4458
  });
4562
4459
  }
4563
- }), _el$23);
4564
- insert(_el$19, createComponent(Show, {
4460
+ }), _el$21);
4461
+ insert(_el$17, createComponent(Show, {
4565
4462
  get when() {
4566
- return createMemo(() => !!(data.media.hyperWide() && controlPanelMenuExpanded()))() && !exitPromptShown();
4463
+ return memo(() => !!(data.media.hyperWide() && controlPanelMenuExpanded()))() && !exitPromptShown();
4567
4464
  },
4568
4465
  get children() {
4569
- return [_tmpl$92(), _tmpl$102()];
4466
+ return [_tmpl$92(), _tmpl$0()];
4570
4467
  }
4571
- }), _el$23);
4468
+ }), _el$21);
4572
4469
  use((element) => {
4573
4470
  clickOutside(element, () => {
4574
4471
  if (untrack(data.media.hyperWide) && untrack(controlPanelMenuExpanded)) {
4575
4472
  setControlPanelMenuExpanded(false);
4576
4473
  }
4577
4474
  });
4578
- }, _el$23);
4579
- setAttribute(_el$23, "id", controlPanelMenuID);
4580
- _el$23.classList.toggle("control-panel-container--center", !!(controls === "inside"));
4581
- insert(_el$23, createComponent(ControlPanelButtons, {
4475
+ }, _el$21);
4476
+ setAttribute(_el$21, "id", controlPanelMenuID);
4477
+ _el$21.classList.toggle("control-panel-container--center", !!(controls === "inside"));
4478
+ insert(_el$21, createComponent(ControlPanelButtons, {
4582
4479
  openSettings: () => {
4583
4480
  data.$rendererState.setKey("screen", "settings");
4584
4481
  },
@@ -4593,17 +4490,17 @@ var Game = (props) => {
4593
4490
  }));
4594
4491
  createRenderEffect((_p$) => {
4595
4492
  var _v$5 = !!(data.media.hyperWide() && !controlPanelMenuExpanded()), _v$6 = !!(data.media.hyperWide() && controlPanelMenuExpanded());
4596
- _v$5 !== _p$.e && _el$23.classList.toggle("control-panel-container--wide-closed", _p$.e = _v$5);
4597
- _v$6 !== _p$.t && _el$23.classList.toggle("control-panel-container--wide-open", _p$.t = _v$6);
4493
+ _v$5 !== _p$.e && _el$21.classList.toggle("control-panel-container--wide-closed", _p$.e = _v$5);
4494
+ _v$6 !== _p$.t && _el$21.classList.toggle("control-panel-container--wide-open", _p$.t = _v$6);
4598
4495
  return _p$;
4599
4496
  }, {
4600
4497
  e: void 0,
4601
4498
  t: void 0
4602
4499
  });
4603
- return _el$19;
4500
+ return _el$17;
4604
4501
  }
4605
- }), _el$24);
4606
- insert(_el$24, createComponent(Index, {
4502
+ }), _el$22);
4503
+ insert(_el$22, createComponent(Index, {
4607
4504
  get each() {
4608
4505
  return images();
4609
4506
  },
@@ -4642,9 +4539,9 @@ var Game = (props) => {
4642
4539
  return image().visible;
4643
4540
  },
4644
4541
  get children() {
4645
- var _el$28 = _tmpl$15();
4646
- insert(_el$28, () => image().image);
4647
- return _el$28;
4542
+ var _el$26 = _tmpl$132();
4543
+ insert(_el$26, () => image().image);
4544
+ return _el$26;
4648
4545
  }
4649
4546
  });
4650
4547
  }
@@ -4663,23 +4560,23 @@ var Game = (props) => {
4663
4560
  return loading();
4664
4561
  },
4665
4562
  get children() {
4666
- return _tmpl$122();
4563
+ return _tmpl$102();
4667
4564
  }
4668
4565
  }), null);
4669
4566
  createRenderEffect((_p$) => {
4670
- var _v$7 = `${props.className || ""} game`, _v$8 = !!props.isPreview, _v$9 = bg().startsWith("url") ? void 0 : bg(), _v$10 = bg().startsWith("url") ? bg() : void 0, _v$11 = charactersCount(), _v$12 = !!dialog().visible, _v$13 = !dialog().visible, _v$14 = !(dialog().miniature.character && dialog().miniature.emotion), _v$15 = !dialog().content, _v$16 = !!props.isPreview, _v$17 = !!Boolean(text().content), _v$18 = !text().content;
4567
+ var _v$7 = `${props.className || ""} game`, _v$8 = !!props.isPreview, _v$9 = bg().startsWith("url") ? void 0 : bg(), _v$0 = bg().startsWith("url") ? bg() : void 0, _v$1 = charactersCount(), _v$10 = !!dialog().visible, _v$11 = !dialog().visible, _v$12 = !(dialog().miniature.character && dialog().miniature.emotion), _v$13 = !dialog().content, _v$14 = !!props.isPreview, _v$15 = !!Boolean(text().content), _v$16 = !text().content;
4671
4568
  _v$7 !== _p$.e && className(_el$, _p$.e = _v$7);
4672
4569
  _v$8 !== _p$.t && _el$.classList.toggle("preview", _p$.t = _v$8);
4673
4570
  _v$9 !== _p$.a && ((_p$.a = _v$9) != null ? _el$2.style.setProperty("background-color", _v$9) : _el$2.style.removeProperty("background-color"));
4674
- _v$10 !== _p$.o && ((_p$.o = _v$10) != null ? _el$2.style.setProperty("background-image", _v$10) : _el$2.style.removeProperty("background-image"));
4675
- _v$11 !== _p$.i && ((_p$.i = _v$11) != null ? _el$3.style.setProperty("--shown-characters-count", _v$11) : _el$3.style.removeProperty("--shown-characters-count"));
4676
- _v$12 !== _p$.n && _el$4.classList.toggle("action-dialog--visible", _p$.n = _v$12);
4677
- _v$13 !== _p$.s && _el$4.classList.toggle("action-dialog--hidden", _p$.s = _v$13);
4678
- _v$14 !== _p$.h && setAttribute(_el$5, "data-no-person", _p$.h = _v$14);
4679
- _v$15 !== _p$.r && setAttribute(_el$5, "aria-disabled", _p$.r = _v$15);
4680
- _v$16 !== _p$.d && _el$7.classList.toggle("action-dialog-content--disable-shadow", _p$.d = _v$16);
4681
- _v$17 !== _p$.l && _el$18.classList.toggle("action-text--shown", _p$.l = _v$17);
4682
- _v$18 !== _p$.u && setAttribute(_el$18, "aria-disabled", _p$.u = _v$18);
4571
+ _v$0 !== _p$.o && ((_p$.o = _v$0) != null ? _el$2.style.setProperty("background-image", _v$0) : _el$2.style.removeProperty("background-image"));
4572
+ _v$1 !== _p$.i && ((_p$.i = _v$1) != null ? _el$3.style.setProperty("--shown-characters-count", _v$1) : _el$3.style.removeProperty("--shown-characters-count"));
4573
+ _v$10 !== _p$.n && _el$4.classList.toggle("action-dialog--visible", _p$.n = _v$10);
4574
+ _v$11 !== _p$.s && _el$4.classList.toggle("action-dialog--hidden", _p$.s = _v$11);
4575
+ _v$12 !== _p$.h && setAttribute(_el$5, "data-no-person", _p$.h = _v$12);
4576
+ _v$13 !== _p$.r && setAttribute(_el$5, "aria-disabled", _p$.r = _v$13);
4577
+ _v$14 !== _p$.d && _el$7.classList.toggle("action-dialog-content--disable-shadow", _p$.d = _v$14);
4578
+ _v$15 !== _p$.l && _el$16.classList.toggle("action-text--shown", _p$.l = _v$15);
4579
+ _v$16 !== _p$.u && setAttribute(_el$16, "aria-disabled", _p$.u = _v$16);
4683
4580
  return _p$;
4684
4581
  }, {
4685
4582
  e: void 0,
@@ -4701,17 +4598,17 @@ var Game = (props) => {
4701
4598
  delegateEvents(["click", "keydown"]);
4702
4599
 
4703
4600
  // src/screens/loading.tsx
4704
- var _tmpl$16 = /* @__PURE__ */ template(`<div class=loading><div class=loading__animation><div></div><div></div><div></div><div>`);
4601
+ var _tmpl$14 = /* @__PURE__ */ template(`<div class=loading><div class=loading__animation><div></div><div></div><div></div><div>`);
4705
4602
  var Loading = (props) => {
4706
4603
  return (() => {
4707
- var _el$ = _tmpl$16();
4604
+ var _el$ = _tmpl$14();
4708
4605
  createRenderEffect(() => _el$.classList.toggle("overlay", !!props.overlay));
4709
4606
  return _el$;
4710
4607
  })();
4711
4608
  };
4712
4609
 
4713
4610
  // src/screens/mainmenu.tsx
4714
- var _tmpl$17 = /* @__PURE__ */ template(`<div class=main-menu><div class=main-menu__controls><button type=button class="button main-menu__button"><span class=main-menu__button__text></span></button><button type=button class="button main-menu__button"><span class=main-menu__button__text></span></button><button type=button class="button main-menu__button"><span class=main-menu__button__text></span></button><button type=button class="button main-menu__button"><span class=main-menu__button__text>`);
4611
+ var _tmpl$15 = /* @__PURE__ */ template(`<div class=main-menu><div class=main-menu__controls><button type=button class="button main-menu__button"><span class=main-menu__button__text></span></button><button type=button class="button main-menu__button"><span class=main-menu__button__text></span></button><button type=button class="button main-menu__button"><span class=main-menu__button__text></span></button><button type=button class="button main-menu__button"><span class=main-menu__button__text>`);
4715
4612
  var _tmpl$27 = /* @__PURE__ */ template(`<button>`);
4716
4613
  var MainMenu = () => {
4717
4614
  const {
@@ -4728,7 +4625,7 @@ var MainMenu = () => {
4728
4625
  $rendererState.mutate((s) => s.screen, screen);
4729
4626
  });
4730
4627
  return (() => {
4731
- var _el$ = _tmpl$17(), _el$2 = _el$.firstChild, _el$3 = _el$2.firstChild, _el$4 = _el$3.firstChild, _el$5 = _el$3.nextSibling, _el$6 = _el$5.firstChild, _el$7 = _el$5.nextSibling, _el$8 = _el$7.firstChild, _el$9 = _el$7.nextSibling, _el$10 = _el$9.firstChild;
4628
+ var _el$ = _tmpl$15(), _el$2 = _el$.firstChild, _el$3 = _el$2.firstChild, _el$4 = _el$3.firstChild, _el$5 = _el$3.nextSibling, _el$6 = _el$5.firstChild, _el$7 = _el$5.nextSibling, _el$8 = _el$7.firstChild, _el$9 = _el$7.nextSibling, _el$0 = _el$9.firstChild;
4732
4629
  _el$3.$$click = () => {
4733
4630
  options.newGame();
4734
4631
  };
@@ -4753,7 +4650,7 @@ var MainMenu = () => {
4753
4650
  _el$9.$$click = () => {
4754
4651
  goto("settings");
4755
4652
  };
4756
- insert(_el$10, () => t("Settings"));
4653
+ insert(_el$0, () => t("Settings"));
4757
4654
  insert(_el$9, createComponent(Icon, {
4758
4655
  icon: "#novely-settings-icon"
4759
4656
  }), null);
@@ -4767,9 +4664,9 @@ var MainMenu = () => {
4767
4664
  return rendererStore().mainmenu;
4768
4665
  },
4769
4666
  children: (item) => (() => {
4770
- var _el$11 = _tmpl$27();
4771
- spread(_el$11, mergeProps(() => item(goto)), false, false);
4772
- return _el$11;
4667
+ var _el$1 = _tmpl$27();
4668
+ spread(_el$1, mergeProps(() => item(goto)), false, false);
4669
+ return _el$1;
4773
4670
  })()
4774
4671
  })
4775
4672
  }), null);
@@ -4779,7 +4676,7 @@ var MainMenu = () => {
4779
4676
  delegateEvents(["click"]);
4780
4677
 
4781
4678
  // src/screens/saves.tsx
4782
- var _tmpl$18 = /* @__PURE__ */ template(`<ol class=saves__list>`);
4679
+ var _tmpl$16 = /* @__PURE__ */ template(`<ol class=saves__list>`);
4783
4680
  var _tmpl$28 = /* @__PURE__ */ template(`<div class=saves><div class=saves__controls><button type=button class="button saves__button"></button></div><div class=saves__list-container>`);
4784
4681
  var _tmpl$36 = /* @__PURE__ */ template(`<div class="saves__list saves__list--empty">`);
4785
4682
  var Saves = () => {
@@ -4865,7 +4762,7 @@ var Saves = () => {
4865
4762
  })();
4866
4763
  },
4867
4764
  get children() {
4868
- var _el$5 = _tmpl$18();
4765
+ var _el$5 = _tmpl$16();
4869
4766
  use(setList, _el$5);
4870
4767
  insert(_el$5, createComponent(For, {
4871
4768
  get each() {
@@ -4896,7 +4793,7 @@ var Saves = () => {
4896
4793
  delegateEvents(["click"]);
4897
4794
 
4898
4795
  // src/screens/settings.tsx
4899
- var _tmpl$19 = /* @__PURE__ */ template(`<div class="root settings"><div class=settings__controls><button type=button class="button settings__button"></button><button type=button class="button settings__button"></button></div><div class=settings__options>`);
4796
+ var _tmpl$17 = /* @__PURE__ */ template(`<div class="root settings"><div class=settings__controls><button type=button class="button settings__button"></button><button type=button class="button settings__button"></button></div><div class=settings__options>`);
4900
4797
  var _tmpl$29 = /* @__PURE__ */ template(`<option>`);
4901
4798
  var Settings = (props) => {
4902
4799
  const {
@@ -4940,7 +4837,7 @@ var Settings = (props) => {
4940
4837
  return fn;
4941
4838
  };
4942
4839
  return (() => {
4943
- var _el$ = _tmpl$19(), _el$2 = _el$.firstChild, _el$3 = _el$2.firstChild, _el$4 = _el$3.nextSibling, _el$5 = _el$2.nextSibling;
4840
+ var _el$ = _tmpl$17(), _el$2 = _el$.firstChild, _el$3 = _el$2.firstChild, _el$4 = _el$3.nextSibling, _el$5 = _el$2.nextSibling;
4944
4841
  _el$3.$$click = () => {
4945
4842
  $rendererState.setKey("screen", "mainmenu");
4946
4843
  };
@@ -5045,7 +4942,7 @@ var Settings = (props) => {
5045
4942
  delegateEvents(["click"]);
5046
4943
 
5047
4944
  // src/components/Root.tsx
5048
- var _tmpl$20 = /* @__PURE__ */ template(`<div class=root>`);
4945
+ var _tmpl$18 = /* @__PURE__ */ template(`<div class=root>`);
5049
4946
  var createRootComponent = ({
5050
4947
  $rendererState,
5051
4948
  $contextState,
@@ -5078,7 +4975,7 @@ var createRootComponent = ({
5078
4975
  emitter.emit("screen:change", currentScreen);
5079
4976
  });
5080
4977
  return (() => {
5081
- var _el$ = _tmpl$20();
4978
+ var _el$ = _tmpl$18();
5082
4979
  var _ref$ = setRoot;
5083
4980
  typeof _ref$ === "function" ? use(_ref$, _el$) : setRoot = _el$;
5084
4981
  insert(_el$, createComponent(Provider, {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@novely/solid-renderer",
3
- "version": "0.51.0-next.2",
3
+ "version": "0.51.0",
4
4
  "type": "module",
5
5
  "publishConfig": {
6
6
  "access": "public"
@@ -10,17 +10,17 @@
10
10
  "module": "./dist/index.jsx",
11
11
  "sideEffects": false,
12
12
  "devDependencies": {
13
- "esbuild": "^0.24.2",
13
+ "esbuild": "^0.25.5",
14
14
  "esbuild-plugin-solid": "^0.6.0",
15
- "typescript": "^5.7.3"
15
+ "typescript": "^5.8.3"
16
16
  },
17
17
  "dependencies": {
18
- "@novely/core": ">=0.51.0",
19
- "@solid-primitives/destructure": "^0.2.0",
18
+ "@solid-primitives/destructure": "^0.2.1",
20
19
  "clsx": "^2.1.1",
21
- "es-toolkit": "^1.31.0",
22
- "solid-js": "~1.9.4",
23
- "solid-transition-group": "^0.2.3",
20
+ "es-toolkit": "^1.39.5",
21
+ "solid-js": "~1.9.7",
22
+ "solid-transition-group": "^0.3.0",
23
+ "@novely/core": "^0.52.0",
24
24
  "@novely/renderer-toolkit": "0.13.0"
25
25
  },
26
26
  "peerDependencies": {