marko 6.0.0-next.3.58 → 6.0.0-next.3.59

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/dom.mjs CHANGED
@@ -121,95 +121,114 @@ function stripSpacesAndPunctuation(str) {
121
121
  var DEFAULT_RUNTIME_ID = "M", DEFAULT_RENDER_ID = "_";
122
122
 
123
123
  // src/dom/resume.ts
124
- var registeredValues = {}, Render = class {
125
- q = [];
126
- s = {};
127
- E = {
128
- _: registeredValues
129
- };
130
- constructor(renders, runtimeId, renderId) {
131
- Object.assign(this, renders[renderId]), this.F = renders, this.G = runtimeId, this.t = renderId, this.H = this.w, this.u(), this.w = () => {
132
- this.H(), this.u();
133
- };
134
- }
135
- u() {
136
- let serializeContext = this.E, scopeLookup = this.s, visits = this.v, branchIds = /* @__PURE__ */ new Set(), parentBranchIds = /* @__PURE__ */ new Map();
137
- if (visits.length) {
138
- let commentPrefixLen = this.i.length, closestBranchMarkers = /* @__PURE__ */ new Map(), visitNodes = new Set(visits), lastEndNode;
139
- this.v = [];
140
- let branchEnd = (branchId, visit, reference) => {
141
- let branch = scopeLookup[branchId] ||= {}, endNode = reference;
142
- for (; visitNodes.has(endNode = endNode.previousSibling); ) ;
143
- endNode === lastEndNode && (endNode = reference.parentNode.insertBefore(new Text(), reference)), branch.b = lastEndNode = endNode, branch.a ||= endNode;
144
- for (let [markerScopeId, markerNode] of closestBranchMarkers)
145
- branch.a.compareDocumentPosition(markerNode) & 4 && reference.compareDocumentPosition(markerNode) & 2 && (parentBranchIds.set(markerScopeId, branchId), closestBranchMarkers.delete(markerScopeId));
146
- return branchIds.add(branchId), closestBranchMarkers.set(branchId, visit), branch;
147
- };
148
- for (let visit of visits) {
149
- let commentText = visit.data, dataIndex = commentText.indexOf(" ") + 1, scopeId = commentText.slice(
150
- commentPrefixLen + 1,
151
- dataIndex ? dataIndex - 1 : commentText.length
152
- ), scope = scopeLookup[scopeId] ||= { d: +scopeId }, data2 = dataIndex ? commentText.slice(dataIndex) : "", token = commentText[commentPrefixLen];
153
- if (token === "*" /* Node */) {
154
- let node = scope[data2] = visit.previousSibling;
155
- scope[data2 + ">" /* Getter */] = () => node;
156
- } else if (token === "$" /* ClosestBranch */)
157
- closestBranchMarkers.set(scopeId, visit);
158
- else if (token === "[" /* BranchStart */)
159
- this.f && (dataIndex && branchEnd(this.f, visit, visit), this.q.push(this.f)), this.f = scopeId, scope.a = visit;
160
- else if (token === "]" /* BranchEnd */) {
161
- scope[data2] = visit;
162
- let curParent = visit.parentNode, startNode = branchEnd(
163
- this.f,
164
- visit,
165
- visit
166
- ).a;
167
- curParent !== startNode.parentNode && curParent.prepend(startNode), this.f = this.q.pop();
168
- } else if (token === "|" /* BranchSingleNode */ || token === "=" /* BranchSingleNodeOnlyChildInParent */) {
169
- let next = data2.indexOf(" "), curNode = visit;
170
- for (scope[~next ? data2.slice(0, next) : data2] = token === "=" /* BranchSingleNodeOnlyChildInParent */ ? visit.parentNode : visit; ~next; ) {
171
- let start = next + 1;
172
- next = data2.indexOf(" ", start);
173
- let childScopeId = data2.slice(start, ~next ? next : data2.length);
174
- curNode = branchEnd(childScopeId, visit, curNode).b;
175
- }
176
- }
177
- }
178
- }
179
- let resumes = this.r;
180
- if (resumes) {
181
- this.r = [];
182
- let len = resumes.length, i = 0;
183
- try {
184
- for (isResuming = !0; i < len; ) {
185
- let resumeData = resumes[i++];
186
- if (typeof resumeData == "function") {
187
- let scopes = resumeData(serializeContext), { $global } = scopeLookup;
188
- $global || (scopeLookup.$global = $global = scopes.$ || {}, $global.runtimeId = this.G, $global.renderId = this.t, $global.g = 1e6);
189
- for (let scopeId in scopes)
190
- if (scopeId !== "$") {
191
- let scope = scopes[scopeId], prevScope = scopeLookup[scopeId];
192
- scope.$global = $global, scope.d = +scopeId, prevScope !== scope && (scopeLookup[scopeId] = Object.assign(
193
- scope,
194
- prevScope
195
- ));
196
- let parentBranchId = parentBranchIds.get(scopeId);
197
- if (parentBranchId && (scope.c = scopes[parentBranchId]), branchIds.has(scopeId)) {
198
- let branch = scope, parentBranch = branch.c;
199
- scope.c = branch, parentBranch && (branch.x = parentBranch, (parentBranch.n ||= /* @__PURE__ */ new Set()).add(branch));
124
+ var registeredValues = {};
125
+ function init(runtimeId = DEFAULT_RUNTIME_ID) {
126
+ let renders = window[runtimeId], defineRuntime = (desc) => Object.defineProperty(window, runtimeId, desc), resumeRender, initRuntime = (renders2) => {
127
+ defineRuntime({
128
+ value: resumeRender = (renderId) => {
129
+ let render = resumeRender[renderId] = renders2[renderId] || renders2(renderId), walk2 = render.w, commentPrefixLen = render.i.length, scopeStack = [], scopeLookup = render.s = {}, serializeContext = {
130
+ _: registeredValues
131
+ }, branchIds = /* @__PURE__ */ new Set(), parentBranchIds = /* @__PURE__ */ new Map(), closestBranchMarkers = /* @__PURE__ */ new Map(), currentScopeId;
132
+ return render.w = () => {
133
+ walk2.call(render);
134
+ let visits = render.v, resumes = render.r;
135
+ if (visits.length) {
136
+ let visitNodes = new Set(visits), lastEndNode;
137
+ render.v = [];
138
+ let branchEnd = (branchId, visit, reference) => {
139
+ let branch = scopeLookup[branchId] ||= {}, endNode = reference;
140
+ for (; visitNodes.has(endNode = endNode.previousSibling); ) ;
141
+ endNode === lastEndNode && (endNode = reference.parentNode.insertBefore(
142
+ new Text(),
143
+ reference
144
+ )), branch.b = lastEndNode = endNode, branch.a ||= endNode;
145
+ for (let [markerScopeId, markerNode] of closestBranchMarkers)
146
+ branch.a.compareDocumentPosition(markerNode) & 4 && reference.compareDocumentPosition(markerNode) & 2 && (parentBranchIds.set(markerScopeId, branchId), closestBranchMarkers.delete(markerScopeId));
147
+ return branchIds.add(branchId), closestBranchMarkers.set(branchId, visit), branch;
148
+ };
149
+ for (let visit of visits) {
150
+ let commentText = visit.data, dataIndex = commentText.indexOf(" ") + 1, scopeId = commentText.slice(
151
+ commentPrefixLen + 1,
152
+ dataIndex ? dataIndex - 1 : commentText.length
153
+ ), scope = scopeLookup[scopeId] ||= {
154
+ d: +scopeId
155
+ }, data2 = dataIndex ? commentText.slice(dataIndex) : "", token = commentText[commentPrefixLen];
156
+ if (token === "*" /* Node */) {
157
+ let node = scope[data2] = visit.previousSibling;
158
+ scope[data2 + ">" /* Getter */] = () => node;
159
+ } else if (token === "$" /* ClosestBranch */)
160
+ closestBranchMarkers.set(scopeId, visit);
161
+ else if (token === "[" /* BranchStart */)
162
+ currentScopeId && (dataIndex && branchEnd(currentScopeId, visit, visit), scopeStack.push(currentScopeId)), currentScopeId = scopeId, scope.a = visit;
163
+ else if (token === "]" /* BranchEnd */) {
164
+ scope[data2] = visit;
165
+ let curParent = visit.parentNode, startNode = branchEnd(
166
+ currentScopeId,
167
+ visit,
168
+ visit
169
+ ).a;
170
+ curParent !== startNode.parentNode && curParent.prepend(startNode), currentScopeId = scopeStack.pop();
171
+ } else if (token === "|" /* BranchSingleNode */ || token === "=" /* BranchSingleNodeOnlyChildInParent */) {
172
+ let next = data2.indexOf(" "), curNode = visit;
173
+ for (scope[~next ? data2.slice(0, next) : data2] = token === "=" /* BranchSingleNodeOnlyChildInParent */ ? visit.parentNode : visit; ~next; ) {
174
+ let start = next + 1;
175
+ next = data2.indexOf(" ", start);
176
+ let childScopeId = data2.slice(
177
+ start,
178
+ ~next ? next : data2.length
179
+ );
180
+ curNode = branchEnd(childScopeId, visit, curNode).b;
200
181
  }
201
182
  }
202
- } else i === len || typeof resumes[i] != "string" ? delete this.F[this.t] : registeredValues[resumes[i++]](
203
- scopeLookup[resumeData],
204
- scopeLookup[resumeData]
205
- );
206
- }
207
- } finally {
208
- isResuming = !1;
183
+ }
184
+ }
185
+ if (resumes)
186
+ try {
187
+ render.r = [], isResuming = !0;
188
+ for (let i = 0; i < resumes.length; i++) {
189
+ let serialized = resumes[i];
190
+ if (typeof serialized == "function") {
191
+ let scopes = serialized(serializeContext), { $global } = scopeLookup;
192
+ $global || (scopeLookup.$global = $global = scopes.$ || {}, $global.runtimeId = runtimeId, $global.renderId = renderId, $global.f = 1e6);
193
+ for (let scopeId in scopes)
194
+ if (scopeId !== "$") {
195
+ let scope = scopes[scopeId], prevScope = scopeLookup[scopeId];
196
+ scope.$global = $global, scope.d = +scopeId, prevScope !== scope && (scopeLookup[scopeId] = Object.assign(
197
+ scope,
198
+ prevScope
199
+ ));
200
+ let parentBranchId = parentBranchIds.get(scopeId);
201
+ if (parentBranchId && (scope.c = scopes[parentBranchId]), branchIds.has(scopeId)) {
202
+ let branch = scope, parentBranch = branch.c;
203
+ scope.c = branch, parentBranch && (branch.p = parentBranch, (parentBranch.m ||= /* @__PURE__ */ new Set()).add(
204
+ branch
205
+ ));
206
+ }
207
+ }
208
+ } else
209
+ registeredValues[resumes[++i]](
210
+ scopeLookup[serialized],
211
+ scopeLookup[serialized]
212
+ );
213
+ }
214
+ } finally {
215
+ isResuming = !1;
216
+ }
217
+ }, render;
209
218
  }
210
- }
211
- }
212
- }, isResuming = !1;
219
+ });
220
+ };
221
+ if (renders) {
222
+ initRuntime(renders);
223
+ for (let renderId in renders)
224
+ resumeRender(renderId).w();
225
+ } else
226
+ defineRuntime({
227
+ configurable: !0,
228
+ set: initRuntime
229
+ });
230
+ }
231
+ var isResuming = !1;
213
232
  function register(id, obj) {
214
233
  return registeredValues[id] = obj, obj;
215
234
  }
@@ -220,22 +239,6 @@ function getRegisteredWithScope(id, scope) {
220
239
  let val = registeredValues[id];
221
240
  return scope ? val(scope) : val;
222
241
  }
223
- function init(runtimeId = DEFAULT_RUNTIME_ID) {
224
- let resumeRender = (renderId) => resumeRender[renderId] = renders[renderId] = new Render(renders, runtimeId, renderId), renders;
225
- window[runtimeId] ? setRenders(window[runtimeId]) : Object.defineProperty(window, runtimeId, {
226
- configurable: !0,
227
- set: setRenders
228
- });
229
- function setRenders(v) {
230
- renders = v;
231
- for (let renderId in v)
232
- resumeRender(renderId);
233
- Object.defineProperty(window, runtimeId, {
234
- configurable: !0,
235
- value: resumeRender
236
- });
237
- }
238
- }
239
242
  function nodeRef(id, key) {
240
243
  return register(id, (scope) => () => scope[key]());
241
244
  }
@@ -630,28 +633,28 @@ function toInsertNode(startNode, endNode) {
630
633
  var pendingScopes = [];
631
634
  function createScope($global, closestBranch) {
632
635
  let scope = {
633
- d: $global.g++,
634
- h: 1,
636
+ d: $global.f++,
637
+ g: 1,
635
638
  c: closestBranch,
636
639
  $global
637
640
  };
638
641
  return pendingScopes.push(scope), scope;
639
642
  }
640
643
  function skipScope(scope) {
641
- return scope.$global.g++;
644
+ return scope.$global.f++;
642
645
  }
643
646
  function finishPendingScopes() {
644
647
  for (let scope of pendingScopes)
645
- scope.h = 0;
648
+ scope.g = 0;
646
649
  pendingScopes = [];
647
650
  }
648
651
  function destroyBranch(branch) {
649
- branch.x?.n?.delete(branch), destroyNestedBranches(branch);
652
+ branch.p?.m?.delete(branch), destroyNestedBranches(branch);
650
653
  }
651
654
  function destroyNestedBranches(branch) {
652
- branch.y = 1, branch.n?.forEach(destroyNestedBranches), branch.I?.forEach((scope) => {
653
- for (let id in scope.k)
654
- scope.k[id]?.abort();
655
+ branch.q = 1, branch.m?.forEach(destroyNestedBranches), branch.A?.forEach((scope) => {
656
+ for (let id in scope.j)
657
+ scope.j[id]?.abort();
655
658
  });
656
659
  }
657
660
  function removeAndDestroyBranch(branch) {
@@ -671,17 +674,17 @@ var pendingRenders = [], pendingRendersLookup = /* @__PURE__ */ new Map(), pendi
671
674
  function queueRender(scope, signal, signalKey, value2, scopeKey = scope.d) {
672
675
  let key = scopeKey * scopeKeyOffset + signalKey, existingRender = signalKey >= 0 && pendingRendersLookup.get(key);
673
676
  if (existingRender)
674
- existingRender.z = value2;
677
+ existingRender.t = value2;
675
678
  else {
676
679
  let render = {
677
- j: key,
678
- A: scope,
679
- J: signal,
680
- z: value2
680
+ h: key,
681
+ u: scope,
682
+ B: signal,
683
+ t: value2
681
684
  }, i = pendingRenders.push(render) - 1;
682
685
  for (; i; ) {
683
686
  let parentIndex = i - 1 >> 1, parent = pendingRenders[parentIndex];
684
- if (key - parent.j >= 0) break;
687
+ if (key - parent.h >= 0) break;
685
688
  pendingRenders[i] = parent, i = parentIndex;
686
689
  }
687
690
  signalKey >= 0 && pendingRendersLookup.set(key, render), pendingRenders[i] = render;
@@ -720,27 +723,27 @@ function runRenders() {
720
723
  for (; pendingRenders.length; ) {
721
724
  let render = pendingRenders[0], item = pendingRenders.pop();
722
725
  if (render !== item) {
723
- let i = 0, mid = pendingRenders.length >> 1, key = (pendingRenders[0] = item).j;
726
+ let i = 0, mid = pendingRenders.length >> 1, key = (pendingRenders[0] = item).h;
724
727
  for (; i < mid; ) {
725
728
  let bestChild = (i << 1) + 1, right = bestChild + 1;
726
- if (right < pendingRenders.length && pendingRenders[right].j - pendingRenders[bestChild].j < 0 && (bestChild = right), pendingRenders[bestChild].j - key >= 0)
729
+ if (right < pendingRenders.length && pendingRenders[right].h - pendingRenders[bestChild].h < 0 && (bestChild = right), pendingRenders[bestChild].h - key >= 0)
727
730
  break;
728
731
  pendingRenders[i] = pendingRenders[bestChild], i = bestChild;
729
732
  }
730
733
  pendingRenders[i] = item;
731
734
  }
732
- render.A.c?.y || render.J(render.A, render.z);
735
+ render.u.c?.q || render.B(render.u, render.t);
733
736
  }
734
737
  finishPendingScopes();
735
738
  }
736
739
 
737
740
  // src/dom/abort-signal.ts
738
741
  function resetAbortSignal(scope, id) {
739
- let ctrl = scope.k?.[id];
740
- ctrl && (queueEffect(ctrl, abort), scope.k[id] = void 0);
742
+ let ctrl = scope.j?.[id];
743
+ ctrl && (queueEffect(ctrl, abort), scope.j[id] = void 0);
741
744
  }
742
745
  function getAbortSignal(scope, id) {
743
- return scope.c && (scope.c.I ||= /* @__PURE__ */ new Set()).add(scope), ((scope.k ||= {})[id] ||= new AbortController()).signal;
746
+ return scope.c && (scope.c.A ||= /* @__PURE__ */ new Set()).add(scope), ((scope.j ||= {})[id] ||= new AbortController()).signal;
744
747
  }
745
748
  function abort(ctrl) {
746
749
  ctrl.abort();
@@ -866,7 +869,7 @@ function walkInternal(currentWalkIndex, walkCodes, scope) {
866
869
  // src/dom/renderer.ts
867
870
  function createBranch($global, renderer, parentScope, parentNode) {
868
871
  let branch = createScope($global), parentBranch = parentScope?.c;
869
- return branch._ = renderer.l || parentScope, branch.c = branch, parentBranch && (branch.x = parentBranch, (parentBranch.n ||= /* @__PURE__ */ new Set()).add(branch)), renderer.o?.(
872
+ return branch._ = renderer.k || parentScope, branch.c = branch, parentBranch && (branch.p = parentBranch, (parentBranch.m ||= /* @__PURE__ */ new Set()).add(branch)), renderer.n?.(
870
873
  branch,
871
874
  parentNode.namespaceURI
872
875
  ), branch;
@@ -878,10 +881,10 @@ function createAndSetupBranch($global, renderer, parentScope, parentNode) {
878
881
  );
879
882
  }
880
883
  function setupBranch(renderer, branch) {
881
- return (renderer.p || renderer.B) && queueRender(
884
+ return (renderer.o || renderer.x) && queueRender(
882
885
  branch,
883
886
  (branch2) => {
884
- renderer.p?.(branch2), renderer.B?.(branch2);
887
+ renderer.o?.(branch2), renderer.x?.(branch2);
885
888
  },
886
889
  -1
887
890
  ), branch;
@@ -902,12 +905,12 @@ function createContent(id, template, walks, setup, params, closures, dynamicScop
902
905
  };
903
906
  return (owner) => ({
904
907
  d: id,
905
- o: clone,
906
- l: owner,
907
- p: setup,
908
+ n: clone,
909
+ k: owner,
910
+ o: setup,
908
911
  e: params,
909
- B: closures,
910
- m: dynamicScopesAccessor
912
+ x: closures,
913
+ l: dynamicScopesAccessor
911
914
  });
912
915
  }
913
916
  function registerContent(id, template, walks, setup, params, closures, dynamicScopesAccessor) {
@@ -981,7 +984,7 @@ function value(valueAccessor, fn = () => {
981
984
  }
982
985
  function intersection(id, fn, defaultPending = 1, scopeIdAccessor = /* @__KEY__ */ "d") {
983
986
  return (scope) => {
984
- scope.h ? scope[id] === void 0 ? scope[id] = defaultPending : --scope[id] || fn(scope) : queueRender(scope, fn, id, 0, scope[scopeIdAccessor]);
987
+ scope.g ? scope[id] === void 0 ? scope[id] = defaultPending : --scope[id] || fn(scope) : queueRender(scope, fn, id, 0, scope[scopeIdAccessor]);
985
988
  };
986
989
  }
987
990
  function loopClosure(valueAccessor, ownerLoopNodeAccessor, fn) {
@@ -991,7 +994,7 @@ function loopClosure(valueAccessor, ownerLoopNodeAccessor, fn) {
991
994
  ownerScope,
992
995
  () => {
993
996
  for (let scope of scopes)
994
- !scope.h && !scope.y && childSignal(scope);
997
+ !scope.g && !scope.q && childSignal(scope);
995
998
  },
996
999
  -1,
997
1000
  0,
@@ -1003,7 +1006,7 @@ function loopClosure(valueAccessor, ownerLoopNodeAccessor, fn) {
1003
1006
  function conditionalClosure(valueAccessor, ownerConditionalNodeAccessor, branch, fn) {
1004
1007
  let childSignal = closure(valueAccessor, fn), scopeAccessor = ownerConditionalNodeAccessor + "!" /* ConditionalScope */, branchAccessor = ownerConditionalNodeAccessor + "(" /* ConditionalRenderer */, ownerSignal = (scope) => {
1005
1008
  let ifScope = scope[scopeAccessor];
1006
- ifScope && !ifScope.h && scope[branchAccessor] === branch && queueRender(ifScope, childSignal, -1);
1009
+ ifScope && !ifScope.g && scope[branchAccessor] === branch && queueRender(ifScope, childSignal, -1);
1007
1010
  };
1008
1011
  return ownerSignal._ = childSignal, ownerSignal;
1009
1012
  }
@@ -1015,13 +1018,13 @@ function subscribeToScopeSet(ownerScope, accessor, scope) {
1015
1018
  ));
1016
1019
  }
1017
1020
  function dynamicClosure(...closureSignals) {
1018
- let [{ C: ___scopeInstancesAccessor, D: ___signalIndexAccessor }] = closureSignals;
1021
+ let [{ y: ___scopeInstancesAccessor, z: ___signalIndexAccessor }] = closureSignals;
1019
1022
  for (let i = closureSignals.length; i--; )
1020
- closureSignals[i].K = i;
1023
+ closureSignals[i].C = i;
1021
1024
  return (scope) => {
1022
1025
  if (scope[___scopeInstancesAccessor])
1023
1026
  for (let childScope of scope[___scopeInstancesAccessor])
1024
- childScope.h || queueRender(
1027
+ childScope.g || queueRender(
1025
1028
  childScope,
1026
1029
  closureSignals[childScope[___signalIndexAccessor]],
1027
1030
  -1
@@ -1030,13 +1033,13 @@ function dynamicClosure(...closureSignals) {
1030
1033
  }
1031
1034
  function dynamicClosureRead(valueAccessor, fn, getOwnerScope) {
1032
1035
  let childSignal = closure(valueAccessor, fn, getOwnerScope), closureSignal = (scope) => {
1033
- scope[closureSignal.D] = closureSignal.K, childSignal(scope), subscribeToScopeSet(
1036
+ scope[closureSignal.z] = closureSignal.C, childSignal(scope), subscribeToScopeSet(
1034
1037
  getOwnerScope ? getOwnerScope(scope) : scope._,
1035
- closureSignal.C,
1038
+ closureSignal.y,
1036
1039
  scope
1037
1040
  );
1038
1041
  };
1039
- return closureSignal.C = valueAccessor + "!" /* ClosureScopes */, closureSignal.D = valueAccessor + "(" /* ClosureSignalIndex */, closureSignal;
1042
+ return closureSignal.y = valueAccessor + "!" /* ClosureScopes */, closureSignal.z = valueAccessor + "(" /* ClosureSignalIndex */, closureSignal;
1040
1043
  }
1041
1044
  function closure(valueAccessor, fn, getOwnerScope) {
1042
1045
  return (scope) => {
@@ -1107,15 +1110,15 @@ var dynamicTag = function(nodeAccessor, getContent, getTagVar, inputIsArgs) {
1107
1110
  0,
1108
1111
  content,
1109
1112
  createAndSetupBranch
1110
- ), content.m && subscribeToScopeSet(
1113
+ ), content.l && subscribeToScopeSet(
1114
+ content.k,
1111
1115
  content.l,
1112
- content.m,
1113
1116
  scope[childScopeAccessor][0 + "!" /* ConditionalScope */]
1114
1117
  );
1115
1118
  }
1116
- } else normalizedRenderer?.m && subscribeToScopeSet(
1119
+ } else normalizedRenderer?.l && subscribeToScopeSet(
1120
+ normalizedRenderer.k,
1117
1121
  normalizedRenderer.l,
1118
- normalizedRenderer.m,
1119
1122
  scope[childScopeAccessor]
1120
1123
  );
1121
1124
  if (normalizedRenderer) {
@@ -1221,7 +1224,7 @@ var classIdToBranch = /* @__PURE__ */ new Map(), compat = {
1221
1224
  register(RENDERER_REGISTER_ID, fn);
1222
1225
  },
1223
1226
  isRenderer(renderer) {
1224
- return renderer.o;
1227
+ return renderer.n;
1225
1228
  },
1226
1229
  getStartNode(branch) {
1227
1230
  return branch.a;
@@ -1246,7 +1249,7 @@ var classIdToBranch = /* @__PURE__ */ new Map(), compat = {
1246
1249
  },
1247
1250
  createRenderer(params, clone) {
1248
1251
  let renderer = createRenderer(0, 0, 0, params);
1249
- return renderer.o = (branch) => {
1252
+ return renderer.n = (branch) => {
1250
1253
  let cloned = clone();
1251
1254
  branch.a = cloned.startNode, branch.b = cloned.endNode;
1252
1255
  }, renderer;
@@ -1261,10 +1264,10 @@ var classIdToBranch = /* @__PURE__ */ new Map(), compat = {
1261
1264
  normalizedInput[key === "renderBody" ? "content" : key] = input[key];
1262
1265
  }
1263
1266
  if (component.effects = prepareEffects(() => {
1264
- branch ? existing = !0 : (out.global.g ||= 0, branch = component.scope = createAndSetupBranch(
1267
+ branch ? existing = !0 : (out.global.f ||= 0, branch = component.scope = createAndSetupBranch(
1265
1268
  out.global,
1266
1269
  renderer,
1267
- renderer.l,
1270
+ renderer.k,
1268
1271
  document.body
1269
1272
  )), renderer.e?.(branch, renderer._ ? args[0] : args);
1270
1273
  }), !existing)
@@ -1286,12 +1289,12 @@ var createTemplate = (id, template, walks, setup, inputSignal) => {
1286
1289
  function mount(input = {}, reference, position) {
1287
1290
  let branch, parentNode = reference, nextSibling = null, { $global } = input;
1288
1291
  switch ($global ? ({ $global, ...input } = input, $global = {
1289
- g: 0,
1292
+ f: 0,
1290
1293
  runtimeId: DEFAULT_RUNTIME_ID,
1291
1294
  renderId: DEFAULT_RENDER_ID,
1292
1295
  ...$global
1293
1296
  }) : $global = {
1294
- g: 0,
1297
+ f: 0,
1295
1298
  runtimeId: DEFAULT_RUNTIME_ID,
1296
1299
  renderId: DEFAULT_RENDER_ID
1297
1300
  }, position) {
@@ -1311,7 +1314,7 @@ function mount(input = {}, reference, position) {
1311
1314
  this,
1312
1315
  void 0,
1313
1316
  parentNode
1314
- ), this.p?.(branch), args?.(branch, input);
1317
+ ), this.o?.(branch), args?.(branch, input);
1315
1318
  });
1316
1319
  return insertChildNodes(
1317
1320
  parentNode,
package/dist/html.js CHANGED
@@ -1428,7 +1428,7 @@ function prepareChunk(chunk) {
1428
1428
  WALKER_RUNTIME_CODE + '("' + $global2.runtimeId + '")("' + $global2.renderId + '")'
1429
1429
  ));
1430
1430
  let resumes = "";
1431
- if ((state.writeScopes || serializer.flushed) && (resumes = state.serializer.stringify(state.writeScopes || {}, boundary), state.writeScopes = null), effects && (hasWalk = !0, resumes = resumes ? resumes + "," + effects : effects), boundary.done && (resumes || state.hasWrittenResume) && (resumes = resumes ? resumes + ",0" : "0"), resumes && (state.hasWrittenResume ? scripts = concatScripts(
1431
+ if ((state.writeScopes || serializer.flushed) && (resumes = state.serializer.stringify(state.writeScopes || {}, boundary), state.writeScopes = null), effects && (hasWalk = !0, resumes = resumes ? resumes + "," + effects : effects), resumes && (state.hasWrittenResume ? scripts = concatScripts(
1432
1432
  scripts,
1433
1433
  runtimePrefix + ".r.push(" + resumes + ")"
1434
1434
  ) : (state.hasWrittenResume = !0, scripts = concatScripts(
package/dist/html.mjs CHANGED
@@ -1347,7 +1347,7 @@ function prepareChunk(chunk) {
1347
1347
  WALKER_RUNTIME_CODE + '("' + $global2.runtimeId + '")("' + $global2.renderId + '")'
1348
1348
  ));
1349
1349
  let resumes = "";
1350
- if ((state.writeScopes || serializer.flushed) && (resumes = state.serializer.stringify(state.writeScopes || {}, boundary), state.writeScopes = null), effects && (hasWalk = !0, resumes = resumes ? resumes + "," + effects : effects), boundary.done && (resumes || state.hasWrittenResume) && (resumes = resumes ? resumes + ",0" : "0"), resumes && (state.hasWrittenResume ? scripts = concatScripts(
1350
+ if ((state.writeScopes || serializer.flushed) && (resumes = state.serializer.stringify(state.writeScopes || {}, boundary), state.writeScopes = null), effects && (hasWalk = !0, resumes = resumes ? resumes + "," + effects : effects), resumes && (state.hasWrittenResume ? scripts = concatScripts(
1351
1351
  scripts,
1352
1352
  runtimePrefix + ".r.push(" + resumes + ")"
1353
1353
  ) : (state.hasWrittenResume = !0, scripts = concatScripts(
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "marko",
3
- "version": "6.0.0-next.3.58",
3
+ "version": "6.0.0-next.3.59",
4
4
  "description": "Optimized runtime for Marko templates.",
5
5
  "keywords": [
6
6
  "api",