marko 5.33.9 → 5.33.10

Sign up to get free protection for your applications and to get access to all the features.
Files changed (85) hide show
  1. package/dist/core-tags/core/await/AsyncValue.js +21 -21
  2. package/dist/core-tags/core/await/renderer.js +11 -11
  3. package/dist/core-tags/core/await/reorderer-renderer.js +3 -3
  4. package/dist/node_modules/@internal/components-beginComponent/index-browser.js +4 -4
  5. package/dist/node_modules/@internal/components-beginComponent/index.js +11 -11
  6. package/dist/node_modules/@internal/components-define-widget-legacy/index-browser.js +45 -45
  7. package/dist/node_modules/@internal/components-define-widget-legacy/index.js +3 -3
  8. package/dist/node_modules/@internal/components-endComponent/index.js +3 -3
  9. package/dist/node_modules/@internal/components-entry/index-browser.js +2 -2
  10. package/dist/node_modules/@internal/components-entry/index.js +16 -16
  11. package/dist/node_modules/@internal/components-entry-legacy/index-browser.js +6 -6
  12. package/dist/node_modules/@internal/components-registry/index-browser.js +46 -46
  13. package/dist/node_modules/@internal/components-registry/index.js +2 -2
  14. package/dist/node_modules/@internal/components-util/index-browser.js +20 -20
  15. package/dist/node_modules/@internal/components-util/index.js +10 -10
  16. package/dist/node_modules/@internal/create-readable/index-browser.js +1 -1
  17. package/dist/node_modules/@internal/create-readable/index.js +9 -9
  18. package/dist/node_modules/@internal/preserve-tag/index-browser.js +7 -7
  19. package/dist/node_modules/@internal/preserve-tag/index.js +5 -5
  20. package/dist/node_modules/@internal/set-immediate/index-browser.js +4 -2
  21. package/dist/node_modules/@internal/set-immediate/index-worker.js +31 -2
  22. package/dist/node_modules/@internal/set-immediate/index.js +3 -2
  23. package/dist/node_modules/@internal/set-immediate/queueMicrotask.js +8 -0
  24. package/dist/runtime/RenderResult.js +8 -8
  25. package/dist/runtime/components/Component.js +145 -145
  26. package/dist/runtime/components/ComponentDef.js +28 -28
  27. package/dist/runtime/components/ComponentsContext.js +15 -15
  28. package/dist/runtime/components/GlobalComponentsContext.js +4 -4
  29. package/dist/runtime/components/KeySequence.js +3 -3
  30. package/dist/runtime/components/ServerComponent.js +13 -13
  31. package/dist/runtime/components/State.js +26 -26
  32. package/dist/runtime/components/attach-detach.js +8 -8
  33. package/dist/runtime/components/defineComponent.js +5 -5
  34. package/dist/runtime/components/dom-data.js +5 -5
  35. package/dist/runtime/components/event-delegation.js +10 -10
  36. package/dist/runtime/components/legacy/defineComponent-legacy.js +1 -1
  37. package/dist/runtime/components/legacy/defineRenderer-legacy.js +16 -16
  38. package/dist/runtime/components/legacy/dependencies/index.js +7 -7
  39. package/dist/runtime/components/legacy/renderer-legacy.js +43 -43
  40. package/dist/runtime/components/renderer.js +36 -36
  41. package/dist/runtime/components/update-manager.js +4 -4
  42. package/dist/runtime/createOut.js +1 -1
  43. package/dist/runtime/dom-insert.js +5 -5
  44. package/dist/runtime/helpers/_change-case.js +2 -2
  45. package/dist/runtime/helpers/dynamic-tag.js +16 -16
  46. package/dist/runtime/helpers/render-tag.js +1 -1
  47. package/dist/runtime/helpers/style-value.js +1 -1
  48. package/dist/runtime/helpers/tags-compat/runtime-dom.js +21 -21
  49. package/dist/runtime/helpers/tags-compat/runtime-html.js +8 -8
  50. package/dist/runtime/html/AsyncStream.js +31 -28
  51. package/dist/runtime/html/BufferedWriter.js +2 -2
  52. package/dist/runtime/html/StringWriter.js +1 -1
  53. package/dist/runtime/html/helpers/_dynamic-attr.js +2 -2
  54. package/dist/runtime/html/helpers/attr.js +4 -4
  55. package/dist/runtime/html/helpers/data-marko.js +6 -6
  56. package/dist/runtime/html/helpers/escape-quotes.js +2 -2
  57. package/dist/runtime/html/helpers/escape-xml.js +1 -1
  58. package/dist/runtime/html/helpers/props-script.js +1 -1
  59. package/dist/runtime/html/index.js +2 -2
  60. package/dist/runtime/renderable.js +5 -5
  61. package/dist/runtime/vdom/AsyncVDOMBuilder.js +96 -96
  62. package/dist/runtime/vdom/VComponent.js +5 -5
  63. package/dist/runtime/vdom/VDocumentFragment.js +7 -7
  64. package/dist/runtime/vdom/VElement.js +42 -42
  65. package/dist/runtime/vdom/VFragment.js +9 -9
  66. package/dist/runtime/vdom/VNode.js +33 -33
  67. package/dist/runtime/vdom/VText.js +8 -8
  68. package/dist/runtime/vdom/helpers/const-element.js +3 -3
  69. package/dist/runtime/vdom/hot-reload.js +21 -21
  70. package/dist/runtime/vdom/index.js +2 -2
  71. package/dist/runtime/vdom/morphdom/fragment.js +5 -5
  72. package/dist/runtime/vdom/morphdom/helpers.js +5 -5
  73. package/dist/runtime/vdom/morphdom/index.js +77 -77
  74. package/dist/runtime/vdom/vdom.js +14 -14
  75. package/package.json +3 -3
  76. package/src/core-tags/core/await/AsyncValue.js +1 -1
  77. package/src/node_modules/@internal/components-registry/index-browser.js +2 -2
  78. package/src/node_modules/@internal/set-immediate/index-browser.js +2 -0
  79. package/src/node_modules/@internal/set-immediate/index-worker.js +31 -2
  80. package/src/node_modules/@internal/set-immediate/index.js +1 -0
  81. package/src/node_modules/@internal/set-immediate/queueMicrotask.js +8 -0
  82. package/src/runtime/html/AsyncStream.js +4 -1
  83. package/src/runtime/vdom/hot-reload.js +2 -2
  84. package/dist/runtime/queueMicrotask.js +0 -14
  85. package/src/runtime/queueMicrotask.js +0 -14
@@ -2,78 +2,78 @@
2
2
  function VNode() {}
3
3
 
4
4
  VNode.prototype = {
5
- bT_: function (finalChildCount, ownerComponent) {
6
- this.cg_ = finalChildCount;
7
- this.ch_ = 0;
8
- this.bZ_ = null;
9
- this.ci_ = null;
10
- this.bW_ = null;
5
+ bU_: function (finalChildCount, ownerComponent) {
6
+ this.ch_ = finalChildCount;
7
+ this.ci_ = 0;
8
+ this.c__ = null;
9
+ this.cj_ = null;
11
10
  this.bX_ = null;
12
- this._J_ = ownerComponent;
11
+ this.bY_ = null;
12
+ this._L_ = ownerComponent;
13
13
  },
14
14
 
15
- get ay_() {
16
- var firstChild = this.bZ_;
15
+ get az_() {
16
+ var firstChild = this.c__;
17
17
 
18
- if (firstChild && firstChild.bY_) {
19
- var nestedFirstChild = firstChild.ay_;
18
+ if (firstChild && firstChild.bZ_) {
19
+ var nestedFirstChild = firstChild.az_;
20
20
  // The first child is a DocumentFragment node.
21
21
  // If the DocumentFragment node has a first child then we will return that.
22
22
  // Otherwise, the DocumentFragment node is not *really* the first child and
23
23
  // we need to skip to its next sibling
24
- return nestedFirstChild || firstChild.cj_;
24
+ return nestedFirstChild || firstChild.ck_;
25
25
  }
26
26
 
27
27
  return firstChild;
28
28
  },
29
29
 
30
- get cj_() {
31
- var nextSibling = this.bX_;
30
+ get ck_() {
31
+ var nextSibling = this.bY_;
32
32
 
33
33
  if (nextSibling) {
34
- if (nextSibling.bY_) {
35
- var firstChild = nextSibling.ay_;
36
- return firstChild || nextSibling.cj_;
34
+ if (nextSibling.bZ_) {
35
+ var firstChild = nextSibling.az_;
36
+ return firstChild || nextSibling.ck_;
37
37
  }
38
38
  } else {
39
- var parentNode = this.bW_;
40
- if (parentNode && parentNode.bY_) {
41
- return parentNode.cj_;
39
+ var parentNode = this.bX_;
40
+ if (parentNode && parentNode.bZ_) {
41
+ return parentNode.ck_;
42
42
  }
43
43
  }
44
44
 
45
45
  return nextSibling;
46
46
  },
47
47
 
48
- bM_: function (child) {
49
- this.ch_++;
48
+ bN_: function (child) {
49
+ this.ci_++;
50
50
 
51
- if (this.ca_ === "textarea") {
52
- if (child.ck_) {
53
- this.cb_ += child.cl_;
51
+ if (this.cb_ === "textarea") {
52
+ if (child.cl_) {
53
+ this.cc_ += child.cm_;
54
54
  } else {
55
55
  throw TypeError();
56
56
  }
57
57
  } else {
58
- var lastChild = this.ci_;
58
+ var lastChild = this.cj_;
59
59
 
60
- child.bW_ = this;
60
+ child.bX_ = this;
61
61
 
62
62
  if (lastChild) {
63
- lastChild.bX_ = child;
63
+ lastChild.bY_ = child;
64
64
  } else {
65
- this.bZ_ = child;
65
+ this.c__ = child;
66
66
  }
67
67
 
68
- this.ci_ = child;
68
+ this.cj_ = child;
69
69
  }
70
70
 
71
71
  return child;
72
72
  },
73
73
 
74
- cd_: function finishChild() {
75
- if (this.ch_ === this.cg_ && this.bW_) {
76
- return this.bW_.cd_();
74
+ ce_: function finishChild() {
75
+ if (this.ci_ === this.ch_ && this.bX_) {
76
+ return this.bX_.ce_();
77
77
  } else {
78
78
  return this;
79
79
  }
@@ -2,21 +2,21 @@
2
2
  var VNode = require("./VNode");
3
3
 
4
4
  function VText(value, ownerComponent) {
5
- this.bT_(-1 /* no children */, ownerComponent);
6
- this.cl_ = value;
5
+ this.bU_(-1 /* no children */, ownerComponent);
6
+ this.cm_ = value;
7
7
  }
8
8
 
9
9
  VText.prototype = {
10
- ck_: true,
10
+ cl_: true,
11
11
 
12
- bV_: 3,
12
+ bW_: 3,
13
13
 
14
- bl_: function (host) {
15
- return (host.ownerDocument || host).createTextNode(this.cl_);
14
+ bm_: function (host) {
15
+ return (host.ownerDocument || host).createTextNode(this.cm_);
16
16
  },
17
17
 
18
- bN_: function () {
19
- return new VText(this.cl_);
18
+ bO_: function () {
19
+ return new VText(this.cm_);
20
20
  }
21
21
  };
22
22
 
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
 
3
- var VElement = require("../vdom").bv_;
3
+ var VElement = require("../vdom").bw_;
4
4
  var i = 0;
5
5
 
6
6
  module.exports = function (tagName, attrs, childCount) {
@@ -13,12 +13,12 @@ function ConstVElement(tagName, attrs, childCount) {
13
13
 
14
14
  ConstVElement.prototype = Object.create(VElement.prototype);
15
15
  ConstVElement.prototype.e = function (tagName, attrs, childCount) {
16
- var child = this.bM_(
16
+ var child = this.bN_(
17
17
  new ConstVElement(tagName, attrs, childCount)
18
18
  );
19
19
 
20
20
  if (childCount === 0) {
21
- return this.cd_();
21
+ return this.ce_();
22
22
  } else {
23
23
  return child;
24
24
  }
@@ -1,10 +1,10 @@
1
1
  "use strict";var registry = require("@internal/components-registry");
2
+ var setImmediate = require("@internal/set-immediate")._i_;
2
3
  var updateManager = require("../components/update-manager");
3
- var queueMicrotask = require("../queueMicrotask");
4
4
  var runtime = require(".");
5
5
 
6
6
  var createTemplate = runtime.t;
7
- var createComponent = registry._C_;
7
+ var createComponent = registry._E_;
8
8
  var registered = {};
9
9
  var instancesByType = {};
10
10
  var queue;
@@ -27,37 +27,37 @@ exports.t = runtime.t = function (typeName) {
27
27
  if (instances.size) {
28
28
  if (!queue) {
29
29
  queue = [];
30
- queueMicrotask(batchUpdate);
30
+ setImmediate(batchUpdate);
31
31
  }
32
32
 
33
33
  queue.push(function () {
34
- var newProto = registry._D_(typeName).prototype;
34
+ var newProto = registry._F_(typeName).prototype;
35
35
  instances.forEach(function (instance) {
36
36
  if (hasLifecycleChanged(instance.__proto__, newProto)) {
37
- var renderer = instance.P_;
38
- instance.P_ = (input, out) => {
39
- instance.aD_(input, out);
37
+ var renderer = instance.Q_;
38
+ instance.Q_ = (input, out) => {
39
+ instance.aE_(input, out);
40
40
  if (instance.onInput) {
41
41
  input = instance.onInput(input, out) || input;
42
42
  }
43
- instance.P_ = renderer;
44
- instance.P_(input, out);
43
+ instance.Q_ = renderer;
44
+ instance.Q_(input, out);
45
45
  };
46
46
 
47
- instance.cm_ = true;
48
- instance.am_();
49
- instance._t_ = false;
47
+ instance.cn_ = true;
48
+ instance.an_();
49
+ instance._v_ = false;
50
50
 
51
- if (instance.ag_) {
52
- instance.ag_.removeAllListeners();
53
- instance.ag_ = null;
51
+ if (instance.ah_) {
52
+ instance.ah_.removeAllListeners();
53
+ instance.ah_ = null;
54
54
  }
55
55
  }
56
56
 
57
57
  instance.__proto__ = newProto;
58
- instance._B_(
59
- instance.N_, false).
60
- afterInsert(instance.A_);
58
+ instance._D_(
59
+ instance.O_, false).
60
+ afterInsert(instance.B_);
61
61
  });
62
62
  });
63
63
  }
@@ -71,14 +71,14 @@ exports.t = runtime.t = function (typeName) {
71
71
  }
72
72
  };
73
73
 
74
- registry._C_ = function (typeName, id) {
74
+ registry._E_ = function (typeName, id) {
75
75
  var instances = instancesByType[typeName];
76
76
  var instance = createComponent(typeName, id);
77
77
 
78
78
  if (instances) {
79
79
  instances.add(instance);
80
80
  instance.once("destroy", function () {
81
- if (!instance.cm_) {
81
+ if (!instance.cn_) {
82
82
  instances.delete(instance);
83
83
  }
84
84
  });
@@ -104,7 +104,7 @@ function hasLifecycleChanged(oldProto, newProto) {
104
104
  }
105
105
 
106
106
  function batchUpdate() {
107
- updateManager.aw_(function () {
107
+ updateManager.ax_(function () {
108
108
  var pending = queue;
109
109
  queue = undefined;
110
110
 
@@ -15,11 +15,11 @@ exports.t = function createTemplate(typeName) {
15
15
  };
16
16
 
17
17
  function Template(typeName) {
18
- this.path = this.Q_ = typeName;
18
+ this.path = this.R_ = typeName;
19
19
  }
20
20
 
21
21
  var AsyncVDOMBuilder = require("./AsyncVDOMBuilder");
22
- require("../createOut").bb_(
22
+ require("../createOut").bc_(
23
23
  Template.prototype.createOut = function createOut(
24
24
  globalData,
25
25
  parent,
@@ -1,5 +1,5 @@
1
1
  "use strict";var helpers = require("./helpers");
2
- var insertBefore = helpers.bc_;
2
+ var insertBefore = helpers.bd_;
3
3
 
4
4
  var fragmentPrototype = {
5
5
  nodeType: 12,
@@ -80,8 +80,8 @@ function createFragmentNode(startNode, nextNode, parentNode) {
80
80
 
81
81
  function beginFragmentNode(startNode, parentNode) {
82
82
  var fragment = createFragmentNode(startNode, null, parentNode);
83
- fragment.cn_ = function (nextNode) {
84
- fragment.cn_ = null;
83
+ fragment.co_ = function (nextNode) {
84
+ fragment.co_ = null;
85
85
  insertBefore(
86
86
  fragment.endNode,
87
87
  nextNode,
@@ -91,5 +91,5 @@ function beginFragmentNode(startNode, parentNode) {
91
91
  return fragment;
92
92
  }
93
93
 
94
- exports._h_ = createFragmentNode;
95
- exports.co_ = beginFragmentNode;
94
+ exports._j_ = createFragmentNode;
95
+ exports.cp_ = beginFragmentNode;
@@ -35,8 +35,8 @@ function removeChild(node) {
35
35
  node.parentNode.removeChild(node);
36
36
  }
37
37
 
38
- exports.bc_ = insertBefore;
39
- exports.bd_ = insertAfter;
40
- exports.cj_ = nextSibling;
41
- exports.ay_ = firstChild;
42
- exports.be_ = removeChild;
38
+ exports.bd_ = insertBefore;
39
+ exports.be_ = insertAfter;
40
+ exports.ck_ = nextSibling;
41
+ exports.az_ = firstChild;
42
+ exports.bf_ = removeChild;