marko 5.33.8 → 5.33.10
Sign up to get free protection for your applications and to get access to all the features.
- package/dist/core-tags/core/await/AsyncValue.js +21 -21
- package/dist/core-tags/core/await/renderer.js +11 -11
- package/dist/core-tags/core/await/reorderer-renderer.js +3 -3
- package/dist/node_modules/@internal/components-beginComponent/index-browser.js +4 -4
- package/dist/node_modules/@internal/components-beginComponent/index.js +11 -11
- package/dist/node_modules/@internal/components-define-widget-legacy/index-browser.js +45 -45
- package/dist/node_modules/@internal/components-define-widget-legacy/index.js +3 -3
- package/dist/node_modules/@internal/components-endComponent/index.js +3 -3
- package/dist/node_modules/@internal/components-entry/index-browser.js +2 -2
- package/dist/node_modules/@internal/components-entry/index.js +16 -16
- package/dist/node_modules/@internal/components-entry-legacy/index-browser.js +6 -6
- package/dist/node_modules/@internal/components-registry/index-browser.js +46 -46
- package/dist/node_modules/@internal/components-registry/index.js +2 -2
- package/dist/node_modules/@internal/components-util/index-browser.js +20 -20
- package/dist/node_modules/@internal/components-util/index.js +10 -10
- package/dist/node_modules/@internal/create-readable/index-browser.js +1 -1
- package/dist/node_modules/@internal/create-readable/index.js +9 -9
- package/dist/node_modules/@internal/preserve-tag/index-browser.js +7 -7
- package/dist/node_modules/@internal/preserve-tag/index.js +5 -5
- package/dist/node_modules/@internal/set-immediate/index-browser.js +4 -2
- package/dist/node_modules/@internal/set-immediate/index-worker.js +31 -2
- package/dist/node_modules/@internal/set-immediate/index.js +3 -2
- package/dist/node_modules/@internal/set-immediate/queueMicrotask.js +8 -0
- package/dist/runtime/RenderResult.js +8 -8
- package/dist/runtime/components/Component.js +145 -145
- package/dist/runtime/components/ComponentDef.js +28 -28
- package/dist/runtime/components/ComponentsContext.js +15 -15
- package/dist/runtime/components/GlobalComponentsContext.js +4 -4
- package/dist/runtime/components/KeySequence.js +3 -3
- package/dist/runtime/components/ServerComponent.js +13 -13
- package/dist/runtime/components/State.js +26 -26
- package/dist/runtime/components/attach-detach.js +8 -8
- package/dist/runtime/components/defineComponent.js +5 -5
- package/dist/runtime/components/dom-data.js +5 -5
- package/dist/runtime/components/event-delegation.js +10 -10
- package/dist/runtime/components/legacy/defineComponent-legacy.js +1 -1
- package/dist/runtime/components/legacy/defineRenderer-legacy.js +16 -16
- package/dist/runtime/components/legacy/dependencies/index.js +7 -7
- package/dist/runtime/components/legacy/renderer-legacy.js +43 -43
- package/dist/runtime/components/renderer.js +36 -36
- package/dist/runtime/components/update-manager.js +4 -4
- package/dist/runtime/createOut.js +1 -1
- package/dist/runtime/dom-insert.js +5 -5
- package/dist/runtime/helpers/_change-case.js +2 -2
- package/dist/runtime/helpers/class-value.js +2 -5
- package/dist/runtime/helpers/dynamic-tag.js +16 -16
- package/dist/runtime/helpers/render-tag.js +1 -1
- package/dist/runtime/helpers/style-value.js +3 -3
- package/dist/runtime/helpers/tags-compat/runtime-dom.js +21 -21
- package/dist/runtime/helpers/tags-compat/runtime-html.js +8 -8
- package/dist/runtime/html/AsyncStream.js +31 -28
- package/dist/runtime/html/BufferedWriter.js +2 -2
- package/dist/runtime/html/StringWriter.js +1 -1
- package/dist/runtime/html/helpers/_dynamic-attr.js +2 -2
- package/dist/runtime/html/helpers/attr.js +4 -4
- package/dist/runtime/html/helpers/data-marko.js +6 -6
- package/dist/runtime/html/helpers/escape-quotes.js +2 -2
- package/dist/runtime/html/helpers/escape-xml.js +1 -1
- package/dist/runtime/html/helpers/props-script.js +1 -1
- package/dist/runtime/html/index.js +2 -2
- package/dist/runtime/renderable.js +5 -5
- package/dist/runtime/vdom/AsyncVDOMBuilder.js +96 -96
- package/dist/runtime/vdom/VComponent.js +5 -5
- package/dist/runtime/vdom/VDocumentFragment.js +7 -7
- package/dist/runtime/vdom/VElement.js +55 -51
- package/dist/runtime/vdom/VFragment.js +9 -9
- package/dist/runtime/vdom/VNode.js +22 -22
- package/dist/runtime/vdom/VText.js +4 -4
- package/dist/runtime/vdom/helpers/const-element.js +3 -3
- package/dist/runtime/vdom/hot-reload.js +19 -19
- package/dist/runtime/vdom/index.js +2 -2
- package/dist/runtime/vdom/morphdom/fragment.js +2 -2
- package/dist/runtime/vdom/morphdom/helpers.js +4 -4
- package/dist/runtime/vdom/morphdom/index.js +68 -68
- package/dist/runtime/vdom/vdom.js +12 -12
- package/package.json +3 -3
- package/src/core-tags/core/await/AsyncValue.js +1 -1
- package/src/node_modules/@internal/components-registry/index-browser.js +2 -2
- package/src/node_modules/@internal/set-immediate/index-browser.js +2 -0
- package/src/node_modules/@internal/set-immediate/index-worker.js +31 -2
- package/src/node_modules/@internal/set-immediate/index.js +1 -0
- package/src/node_modules/@internal/set-immediate/queueMicrotask.js +8 -0
- package/src/runtime/helpers/class-value.js +2 -5
- package/src/runtime/helpers/style-value.js +2 -2
- package/src/runtime/html/AsyncStream.js +4 -1
- package/src/runtime/vdom/VElement.js +15 -11
- package/src/runtime/vdom/hot-reload.js +2 -2
- package/dist/runtime/queueMicrotask.js +0 -14
- package/src/runtime/queueMicrotask.js +0 -14
@@ -4,7 +4,7 @@
|
|
4
4
|
var inherit = require("raptor-util/inherit");
|
5
5
|
var componentsUtil = require("@internal/components-util");
|
6
6
|
var domData = require("../components/dom-data");
|
7
|
-
var vElementByDOMNode = domData.
|
7
|
+
var vElementByDOMNode = domData._J_;
|
8
8
|
var VNode = require("./VNode");
|
9
9
|
var ATTR_XLINK_HREF = "xlink:href";
|
10
10
|
var xmlnsRegExp = /^xmlns(:|$)/;
|
@@ -81,17 +81,17 @@ function assign(a, b) {
|
|
81
81
|
}
|
82
82
|
|
83
83
|
function VElementClone(other) {
|
84
|
-
this.
|
85
|
-
this.bW_ = null;
|
84
|
+
this.c__ = other.c__;
|
86
85
|
this.bX_ = null;
|
86
|
+
this.bY_ = null;
|
87
87
|
|
88
|
-
this.
|
89
|
-
this.c__ = other.c__;
|
90
|
-
this._L_ = other._L_;
|
88
|
+
this.bV_ = other.bV_;
|
91
89
|
this.ca_ = other.ca_;
|
92
|
-
this.
|
90
|
+
this._N_ = other._N_;
|
93
91
|
this.cb_ = other.cb_;
|
92
|
+
this.u_ = other.u_;
|
94
93
|
this.cc_ = other.cc_;
|
94
|
+
this.cd_ = other.cd_;
|
95
95
|
}
|
96
96
|
|
97
97
|
function VElement(
|
@@ -103,7 +103,7 @@ childCount,
|
|
103
103
|
flags,
|
104
104
|
props)
|
105
105
|
{
|
106
|
-
this.
|
106
|
+
this.bU_(childCount, ownerComponent);
|
107
107
|
|
108
108
|
var constId;
|
109
109
|
|
@@ -111,21 +111,21 @@ props)
|
|
111
111
|
constId = props.i;
|
112
112
|
}
|
113
113
|
|
114
|
-
this.
|
115
|
-
this.
|
116
|
-
this.
|
117
|
-
this.
|
118
|
-
this.
|
119
|
-
this.
|
120
|
-
this.
|
121
|
-
this.
|
122
|
-
this.
|
114
|
+
this.bV_ = key;
|
115
|
+
this.u_ = flags || 0;
|
116
|
+
this.ca_ = attrs || EMPTY_OBJECT;
|
117
|
+
this._N_ = props || EMPTY_OBJECT;
|
118
|
+
this.cb_ = tagName;
|
119
|
+
this.cc_ = "";
|
120
|
+
this.cd_ = constId;
|
121
|
+
this.ac_ = false;
|
122
|
+
this.ab_ = false;
|
123
123
|
}
|
124
124
|
|
125
125
|
VElement.prototype = {
|
126
|
-
|
126
|
+
bW_: 1,
|
127
127
|
|
128
|
-
|
128
|
+
bO_: function () {
|
129
129
|
return new VElementClone(this);
|
130
130
|
},
|
131
131
|
|
@@ -137,7 +137,7 @@ VElement.prototype = {
|
|
137
137
|
* @param {int|null} childCount The number of child nodes (or `null` if not known)
|
138
138
|
*/
|
139
139
|
e: function (tagName, attrs, key, ownerComponent, childCount, flags, props) {
|
140
|
-
var child = this.
|
140
|
+
var child = this.bN_(
|
141
141
|
new VElement(
|
142
142
|
tagName,
|
143
143
|
attrs,
|
@@ -150,7 +150,7 @@ VElement.prototype = {
|
|
150
150
|
);
|
151
151
|
|
152
152
|
if (childCount === 0) {
|
153
|
-
return this.
|
153
|
+
return this.ce_();
|
154
154
|
} else {
|
155
155
|
return child;
|
156
156
|
}
|
@@ -163,18 +163,18 @@ VElement.prototype = {
|
|
163
163
|
* @param {String} value The value for the new Comment node
|
164
164
|
*/
|
165
165
|
n: function (node, ownerComponent) {
|
166
|
-
node = node.
|
167
|
-
node.
|
168
|
-
this.
|
169
|
-
return this.
|
166
|
+
node = node.bO_();
|
167
|
+
node._L_ = ownerComponent;
|
168
|
+
this.bN_(node);
|
169
|
+
return this.ce_();
|
170
170
|
},
|
171
171
|
|
172
|
-
|
173
|
-
var tagName = this.
|
174
|
-
var attributes = this.
|
172
|
+
bm_: function (host, parentNamespaceURI) {
|
173
|
+
var tagName = this.cb_;
|
174
|
+
var attributes = this.ca_;
|
175
175
|
var namespaceURI = DEFAULT_NS[tagName] || parentNamespaceURI || NS_HTML;
|
176
176
|
|
177
|
-
var flags = this.
|
177
|
+
var flags = this.u_;
|
178
178
|
var el = (host.ownerDocument || host).createElementNS(
|
179
179
|
namespaceURI,
|
180
180
|
tagName
|
@@ -196,21 +196,13 @@ VElement.prototype = {
|
|
196
196
|
}
|
197
197
|
|
198
198
|
if (tagName === "textarea") {
|
199
|
-
el.defaultValue = this.
|
199
|
+
el.defaultValue = this.cc_;
|
200
200
|
}
|
201
201
|
}
|
202
202
|
|
203
203
|
vElementByDOMNode.set(el, this);
|
204
204
|
|
205
205
|
return el;
|
206
|
-
},
|
207
|
-
|
208
|
-
ce_: function (name) {
|
209
|
-
// We don't care about the namespaces since the there
|
210
|
-
// is no chance that attributes with the same name will have
|
211
|
-
// different namespaces
|
212
|
-
var value = this.c__[name];
|
213
|
-
return value != null && value !== false;
|
214
206
|
}
|
215
207
|
};
|
216
208
|
|
@@ -232,7 +224,7 @@ function virtualizeElement(node, virtualizeChildNodes, ownerComponent) {
|
|
232
224
|
var attrName = attr.name;
|
233
225
|
if (!xmlnsRegExp.test(attrName)) {
|
234
226
|
if (attrName === "data-marko") {
|
235
|
-
props = componentsUtil.
|
227
|
+
props = componentsUtil._p_(node);
|
236
228
|
} else if (attr.namespaceURI === NS_XLINK) {
|
237
229
|
attrs[ATTR_XLINK_HREF] = attr.value;
|
238
230
|
} else {
|
@@ -258,8 +250,8 @@ function virtualizeElement(node, virtualizeChildNodes, ownerComponent) {
|
|
258
250
|
props
|
259
251
|
);
|
260
252
|
|
261
|
-
if (vdomEl.
|
262
|
-
vdomEl.
|
253
|
+
if (vdomEl.cb_ === "textarea") {
|
254
|
+
vdomEl.cc_ = node.value;
|
263
255
|
} else if (virtualizeChildNodes) {
|
264
256
|
virtualizeChildNodes(node, vdomEl, ownerComponent);
|
265
257
|
}
|
@@ -270,15 +262,15 @@ function virtualizeElement(node, virtualizeChildNodes, ownerComponent) {
|
|
270
262
|
VElement.cf_ = virtualizeElement;
|
271
263
|
|
272
264
|
VElement.cg_ = function (fromEl, vFromEl, toEl) {
|
273
|
-
var fromFlags = vFromEl.
|
274
|
-
var toFlags = toEl.
|
275
|
-
var attrs = toEl.
|
265
|
+
var fromFlags = vFromEl.u_;
|
266
|
+
var toFlags = toEl.u_;
|
267
|
+
var attrs = toEl.ca_;
|
276
268
|
|
277
269
|
if (toFlags & FLAG_CUSTOM_ELEMENT) {
|
278
270
|
return assign(fromEl, attrs);
|
279
271
|
}
|
280
272
|
|
281
|
-
var props = toEl.
|
273
|
+
var props = toEl._N_;
|
282
274
|
var attrName;
|
283
275
|
|
284
276
|
// We use expando properties to associate the previous HTML
|
@@ -289,7 +281,7 @@ VElement.cg_ = function (fromEl, vFromEl, toEl) {
|
|
289
281
|
// real VElement node will not have the expando property
|
290
282
|
// so we build the attribute map from the expando property
|
291
283
|
|
292
|
-
var oldAttrs = vFromEl.
|
284
|
+
var oldAttrs = vFromEl.ca_;
|
293
285
|
|
294
286
|
if (oldAttrs === attrs) {
|
295
287
|
// For constant attributes the same object will be provided
|
@@ -303,19 +295,31 @@ VElement.cg_ = function (fromEl, vFromEl, toEl) {
|
|
303
295
|
|
304
296
|
if (toFlags & FLAG_SIMPLE_ATTRS && fromFlags & FLAG_SIMPLE_ATTRS) {
|
305
297
|
if (oldAttrs["class"] !== (attrValue = attrs["class"])) {
|
306
|
-
|
298
|
+
if (attrValue) {
|
299
|
+
fromEl.className = attrValue;
|
300
|
+
} else {
|
301
|
+
fromEl.removeAttribute("class");
|
302
|
+
}
|
307
303
|
}
|
308
304
|
if (oldAttrs.id !== (attrValue = attrs.id)) {
|
309
|
-
|
305
|
+
if (attrValue) {
|
306
|
+
fromEl.id = attrValue;
|
307
|
+
} else {
|
308
|
+
fromEl.removeAttribute("id");
|
309
|
+
}
|
310
310
|
}
|
311
311
|
if (oldAttrs.style !== (attrValue = attrs.style)) {
|
312
|
-
|
312
|
+
if (attrValue) {
|
313
|
+
fromEl.style.cssText = attrValue;
|
314
|
+
} else {
|
315
|
+
fromEl.removeAttribute("style");
|
316
|
+
}
|
313
317
|
}
|
314
318
|
return;
|
315
319
|
}
|
316
320
|
|
317
321
|
var preserve = props && props.pa || EMPTY_OBJECT;
|
318
|
-
var specialAttrs = specialElHandlers[toEl.
|
322
|
+
var specialAttrs = specialElHandlers[toEl.cb_] || EMPTY_OBJECT;
|
319
323
|
var specialAttr;
|
320
324
|
|
321
325
|
// Loop over all of the attributes in the attribute map and compare
|
@@ -353,7 +357,7 @@ VElement.cg_ = function (fromEl, vFromEl, toEl) {
|
|
353
357
|
// was not a virtualized node (i.e., a node that was not rendered by a
|
354
358
|
// Marko template, but rather a node that was created from an HTML
|
355
359
|
// string or a real DOM node).
|
356
|
-
if (toEl.
|
360
|
+
if (toEl.bV_ === null || fromFlags & FLAG_SPREAD_ATTRS) {
|
357
361
|
for (attrName in oldAttrs) {
|
358
362
|
if (!(attrName in attrs)) {
|
359
363
|
if (specialAttr = specialAttrs[attrName]) {
|
@@ -1,21 +1,21 @@
|
|
1
1
|
"use strict";var inherit = require("raptor-util/inherit");
|
2
2
|
var domData = require("../components/dom-data");
|
3
|
-
var keysByDOMNode = domData.
|
4
|
-
var vElementByDOMNode = domData.
|
5
|
-
var createFragmentNode = require("./morphdom/fragment").
|
3
|
+
var keysByDOMNode = domData._I_;
|
4
|
+
var vElementByDOMNode = domData._J_;
|
5
|
+
var createFragmentNode = require("./morphdom/fragment")._j_;
|
6
6
|
var VNode = require("./VNode");
|
7
7
|
|
8
8
|
function VFragment(key, ownerComponent, preserve) {
|
9
|
-
this.
|
10
|
-
this.
|
11
|
-
this.
|
9
|
+
this.bU_(null /* childCount */, ownerComponent);
|
10
|
+
this.bV_ = key;
|
11
|
+
this.ac_ = preserve;
|
12
12
|
}
|
13
13
|
|
14
14
|
VFragment.prototype = {
|
15
|
-
|
16
|
-
|
15
|
+
bW_: 12,
|
16
|
+
bm_: function () {
|
17
17
|
var fragment = createFragmentNode();
|
18
|
-
keysByDOMNode.set(fragment, this.
|
18
|
+
keysByDOMNode.set(fragment, this.bV_);
|
19
19
|
vElementByDOMNode.set(fragment, this);
|
20
20
|
return fragment;
|
21
21
|
}
|
@@ -2,21 +2,21 @@
|
|
2
2
|
function VNode() {}
|
3
3
|
|
4
4
|
VNode.prototype = {
|
5
|
-
|
5
|
+
bU_: function (finalChildCount, ownerComponent) {
|
6
6
|
this.ch_ = finalChildCount;
|
7
7
|
this.ci_ = 0;
|
8
|
-
this.
|
8
|
+
this.c__ = null;
|
9
9
|
this.cj_ = null;
|
10
|
-
this.bW_ = null;
|
11
10
|
this.bX_ = null;
|
12
|
-
this.
|
11
|
+
this.bY_ = null;
|
12
|
+
this._L_ = ownerComponent;
|
13
13
|
},
|
14
14
|
|
15
|
-
get
|
16
|
-
var firstChild = this.
|
15
|
+
get az_() {
|
16
|
+
var firstChild = this.c__;
|
17
17
|
|
18
|
-
if (firstChild && firstChild.
|
19
|
-
var nestedFirstChild = firstChild.
|
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
|
@@ -28,16 +28,16 @@ VNode.prototype = {
|
|
28
28
|
},
|
29
29
|
|
30
30
|
get ck_() {
|
31
|
-
var nextSibling = this.
|
31
|
+
var nextSibling = this.bY_;
|
32
32
|
|
33
33
|
if (nextSibling) {
|
34
|
-
if (nextSibling.
|
35
|
-
var firstChild = nextSibling.
|
34
|
+
if (nextSibling.bZ_) {
|
35
|
+
var firstChild = nextSibling.az_;
|
36
36
|
return firstChild || nextSibling.ck_;
|
37
37
|
}
|
38
38
|
} else {
|
39
|
-
var parentNode = this.
|
40
|
-
if (parentNode && parentNode.
|
39
|
+
var parentNode = this.bX_;
|
40
|
+
if (parentNode && parentNode.bZ_) {
|
41
41
|
return parentNode.ck_;
|
42
42
|
}
|
43
43
|
}
|
@@ -45,24 +45,24 @@ VNode.prototype = {
|
|
45
45
|
return nextSibling;
|
46
46
|
},
|
47
47
|
|
48
|
-
|
48
|
+
bN_: function (child) {
|
49
49
|
this.ci_++;
|
50
50
|
|
51
|
-
if (this.
|
51
|
+
if (this.cb_ === "textarea") {
|
52
52
|
if (child.cl_) {
|
53
|
-
this.
|
53
|
+
this.cc_ += child.cm_;
|
54
54
|
} else {
|
55
55
|
throw TypeError();
|
56
56
|
}
|
57
57
|
} else {
|
58
58
|
var lastChild = this.cj_;
|
59
59
|
|
60
|
-
child.
|
60
|
+
child.bX_ = this;
|
61
61
|
|
62
62
|
if (lastChild) {
|
63
|
-
lastChild.
|
63
|
+
lastChild.bY_ = child;
|
64
64
|
} else {
|
65
|
-
this.
|
65
|
+
this.c__ = child;
|
66
66
|
}
|
67
67
|
|
68
68
|
this.cj_ = child;
|
@@ -71,9 +71,9 @@ VNode.prototype = {
|
|
71
71
|
return child;
|
72
72
|
},
|
73
73
|
|
74
|
-
|
75
|
-
if (this.ci_ === this.ch_ && this.
|
76
|
-
return this.
|
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,20 +2,20 @@
|
|
2
2
|
var VNode = require("./VNode");
|
3
3
|
|
4
4
|
function VText(value, ownerComponent) {
|
5
|
-
this.
|
5
|
+
this.bU_(-1 /* no children */, ownerComponent);
|
6
6
|
this.cm_ = value;
|
7
7
|
}
|
8
8
|
|
9
9
|
VText.prototype = {
|
10
10
|
cl_: true,
|
11
11
|
|
12
|
-
|
12
|
+
bW_: 3,
|
13
13
|
|
14
|
-
|
14
|
+
bm_: function (host) {
|
15
15
|
return (host.ownerDocument || host).createTextNode(this.cm_);
|
16
16
|
},
|
17
17
|
|
18
|
-
|
18
|
+
bO_: function () {
|
19
19
|
return new VText(this.cm_);
|
20
20
|
}
|
21
21
|
};
|
@@ -1,6 +1,6 @@
|
|
1
1
|
"use strict";
|
2
2
|
|
3
|
-
var VElement = require("../vdom").
|
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.
|
16
|
+
var child = this.bN_(
|
17
17
|
new ConstVElement(tagName, attrs, childCount)
|
18
18
|
);
|
19
19
|
|
20
20
|
if (childCount === 0) {
|
21
|
-
return this.
|
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.
|
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
|
-
|
30
|
+
setImmediate(batchUpdate);
|
31
31
|
}
|
32
32
|
|
33
33
|
queue.push(function () {
|
34
|
-
var newProto = registry.
|
34
|
+
var newProto = registry._F_(typeName).prototype;
|
35
35
|
instances.forEach(function (instance) {
|
36
36
|
if (hasLifecycleChanged(instance.__proto__, newProto)) {
|
37
|
-
var renderer = instance.
|
38
|
-
instance.
|
39
|
-
instance.
|
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.
|
44
|
-
instance.
|
43
|
+
instance.Q_ = renderer;
|
44
|
+
instance.Q_(input, out);
|
45
45
|
};
|
46
46
|
|
47
47
|
instance.cn_ = true;
|
48
|
-
instance.
|
49
|
-
instance.
|
48
|
+
instance.an_();
|
49
|
+
instance._v_ = false;
|
50
50
|
|
51
|
-
if (instance.
|
52
|
-
instance.
|
53
|
-
instance.
|
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.
|
59
|
-
instance.
|
60
|
-
afterInsert(instance.
|
58
|
+
instance._D_(
|
59
|
+
instance.O_, false).
|
60
|
+
afterInsert(instance.B_);
|
61
61
|
});
|
62
62
|
});
|
63
63
|
}
|
@@ -71,7 +71,7 @@ exports.t = runtime.t = function (typeName) {
|
|
71
71
|
}
|
72
72
|
};
|
73
73
|
|
74
|
-
registry.
|
74
|
+
registry._E_ = function (typeName, id) {
|
75
75
|
var instances = instancesByType[typeName];
|
76
76
|
var instance = createComponent(typeName, id);
|
77
77
|
|
@@ -104,7 +104,7 @@ function hasLifecycleChanged(oldProto, newProto) {
|
|
104
104
|
}
|
105
105
|
|
106
106
|
function batchUpdate() {
|
107
|
-
updateManager.
|
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.
|
18
|
+
this.path = this.R_ = typeName;
|
19
19
|
}
|
20
20
|
|
21
21
|
var AsyncVDOMBuilder = require("./AsyncVDOMBuilder");
|
22
|
-
require("../createOut").
|
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.
|
2
|
+
var insertBefore = helpers.bd_;
|
3
3
|
|
4
4
|
var fragmentPrototype = {
|
5
5
|
nodeType: 12,
|
@@ -91,5 +91,5 @@ function beginFragmentNode(startNode, parentNode) {
|
|
91
91
|
return fragment;
|
92
92
|
}
|
93
93
|
|
94
|
-
exports.
|
94
|
+
exports._j_ = createFragmentNode;
|
95
95
|
exports.cp_ = beginFragmentNode;
|
@@ -35,8 +35,8 @@ function removeChild(node) {
|
|
35
35
|
node.parentNode.removeChild(node);
|
36
36
|
}
|
37
37
|
|
38
|
-
exports.
|
39
|
-
exports.
|
38
|
+
exports.bd_ = insertBefore;
|
39
|
+
exports.be_ = insertAfter;
|
40
40
|
exports.ck_ = nextSibling;
|
41
|
-
exports.
|
42
|
-
exports.
|
41
|
+
exports.az_ = firstChild;
|
42
|
+
exports.bf_ = removeChild;
|