marko 5.37.2 → 5.37.4
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/compiler/index.js +11 -11
- package/dist/core-tags/components/init-components-tag.js +4 -4
- package/dist/core-tags/components/preferred-script-location-tag.js +2 -2
- package/dist/core-tags/core/__flush_here_and_after__.js +1 -1
- package/dist/core-tags/core/await/AsyncValue.js +21 -21
- package/dist/core-tags/core/await/renderer.js +24 -24
- package/dist/core-tags/core/await/reorderer-renderer.js +6 -6
- package/dist/node-require/browser-refresh.js +1 -18
- package/dist/node-require/index.js +7 -7
- package/dist/node_modules/@internal/components-beginComponent/index-browser.js +5 -5
- package/dist/node_modules/@internal/components-beginComponent/index.js +12 -12
- package/dist/node_modules/@internal/components-define-widget-legacy/index-browser.js +99 -99
- 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 +29 -29
- package/dist/node_modules/@internal/components-entry-legacy/index-browser.js +13 -13
- package/dist/node_modules/@internal/components-entry-legacy/index.js +1 -1
- package/dist/node_modules/@internal/components-registry/index-browser.js +102 -102
- 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 +20 -24
- 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 +8 -8
- package/dist/node_modules/@internal/preserve-tag/index.js +6 -6
- package/dist/node_modules/@internal/set-immediate/index-browser.js +2 -2
- package/dist/node_modules/@internal/set-immediate/index-worker.js +3 -3
- package/dist/node_modules/@internal/set-immediate/index.js +3 -3
- package/dist/runtime/RenderResult.js +24 -24
- package/dist/runtime/components/Component.js +163 -163
- package/dist/runtime/components/ComponentDef.js +34 -34
- package/dist/runtime/components/ComponentsContext.js +20 -20
- package/dist/runtime/components/GlobalComponentsContext.js +4 -4
- package/dist/runtime/components/KeySequence.js +3 -3
- package/dist/runtime/components/ServerComponent.js +17 -17
- package/dist/runtime/components/State.js +28 -28
- package/dist/runtime/components/attach-detach.js +8 -8
- package/dist/runtime/components/defineComponent.js +5 -5
- package/dist/runtime/components/dom-data.js +6 -6
- 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 +25 -25
- package/dist/runtime/components/legacy/dependencies/index.js +10 -10
- package/dist/runtime/components/legacy/renderer-legacy.js +56 -56
- package/dist/runtime/components/renderer.js +45 -45
- 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/dynamic-tag.js +33 -33
- package/dist/runtime/helpers/render-tag.js +1 -1
- package/dist/runtime/helpers/serialize-noop.js +2 -2
- package/dist/runtime/helpers/style-value.js +1 -1
- package/dist/runtime/helpers/tags-compat/runtime-dom.js +35 -35
- package/dist/runtime/helpers/tags-compat/runtime-html.js +16 -16
- package/dist/runtime/html/AsyncStream.js +28 -28
- package/dist/runtime/html/BufferedWriter.js +2 -2
- package/dist/runtime/html/StringWriter.js +2 -2
- package/dist/runtime/html/helpers/_dynamic-attr.js +2 -2
- package/dist/runtime/html/helpers/attr.js +11 -11
- package/dist/runtime/html/helpers/attrs.js +6 -6
- 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/merge-attrs.js +11 -11
- 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 +100 -100
- package/dist/runtime/vdom/VComment.js +7 -7
- package/dist/runtime/vdom/VComponent.js +5 -5
- package/dist/runtime/vdom/VDocumentFragment.js +8 -8
- package/dist/runtime/vdom/VElement.js +52 -52
- package/dist/runtime/vdom/VFragment.js +9 -9
- package/dist/runtime/vdom/VNode.js +34 -34
- package/dist/runtime/vdom/VText.js +8 -8
- package/dist/runtime/vdom/helpers/attrs.js +6 -6
- package/dist/runtime/vdom/helpers/const-element.js +3 -3
- package/dist/runtime/vdom/hot-reload.js +20 -20
- package/dist/runtime/vdom/index.js +2 -2
- package/dist/runtime/vdom/morphdom/fragment.js +10 -10
- package/dist/runtime/vdom/morphdom/helpers.js +5 -5
- package/dist/runtime/vdom/morphdom/index.js +81 -81
- package/dist/runtime/vdom/vdom.js +15 -15
- package/dist/taglib/index.js +6 -6
- package/dist/translator/index.js +2 -1
- package/dist/translator/util/get-component-files.js +1 -1
- package/docs/typescript.md +1 -1
- package/package.json +2 -2
- package/src/translator/index.js +1 -0
|
@@ -10,10 +10,10 @@ window.addEventListener("message", function (ev) {
|
|
|
10
10
|
}
|
|
11
11
|
});
|
|
12
12
|
|
|
13
|
-
exports.
|
|
13
|
+
exports._k_ = function (callback) {
|
|
14
14
|
if (queue.push(callback) === 1) {
|
|
15
15
|
window.postMessage(msg, "*");
|
|
16
16
|
}
|
|
17
17
|
};
|
|
18
18
|
|
|
19
|
-
exports.
|
|
19
|
+
exports.e_ = require("./queueMicrotask");
|
|
@@ -3,7 +3,7 @@ var count = 0;
|
|
|
3
3
|
var queue = new Set();
|
|
4
4
|
function noop() {}
|
|
5
5
|
|
|
6
|
-
exports.
|
|
6
|
+
exports._k_ = function setImmediate(cb) {
|
|
7
7
|
queue.add(cb);
|
|
8
8
|
if (!count) {
|
|
9
9
|
queueMicrotaskInternal(noop);
|
|
@@ -11,11 +11,11 @@ exports.___setImmediate = function setImmediate(cb) {
|
|
|
11
11
|
return cb;
|
|
12
12
|
};
|
|
13
13
|
|
|
14
|
-
exports.
|
|
14
|
+
exports.af_ = function clearImmediate(id) {
|
|
15
15
|
queue.delete(id);
|
|
16
16
|
};
|
|
17
17
|
|
|
18
|
-
exports.
|
|
18
|
+
exports.e_ = queueMicrotaskInternal;
|
|
19
19
|
|
|
20
20
|
function queueMicrotaskInternal(cb) {
|
|
21
21
|
count++;
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
"use strict";exports.
|
|
2
|
-
exports.
|
|
3
|
-
exports.
|
|
1
|
+
"use strict";exports._k_ = setImmediate;
|
|
2
|
+
exports.af_ = clearImmediate;
|
|
3
|
+
exports.e_ = require("./queueMicrotask");
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";var domInsert = require("./dom-insert");
|
|
2
2
|
// eslint-disable-next-line no-constant-binary-expression
|
|
3
|
-
|
|
3
|
+
|
|
4
4
|
|
|
5
5
|
function getRootNode(el) {
|
|
6
6
|
var cur = el;
|
|
@@ -9,7 +9,7 @@ function getRootNode(el) {
|
|
|
9
9
|
}
|
|
10
10
|
|
|
11
11
|
function getComponentDefs(result) {
|
|
12
|
-
var componentDefs = result.
|
|
12
|
+
var componentDefs = result.b_;
|
|
13
13
|
|
|
14
14
|
if (!componentDefs) {
|
|
15
15
|
throw Error("No component");
|
|
@@ -18,8 +18,8 @@ function getComponentDefs(result) {
|
|
|
18
18
|
}
|
|
19
19
|
|
|
20
20
|
function RenderResult(out) {
|
|
21
|
-
this.out = this.
|
|
22
|
-
this.
|
|
21
|
+
this.out = this.s_ = out;
|
|
22
|
+
this.b_ = undefined;
|
|
23
23
|
}
|
|
24
24
|
|
|
25
25
|
module.exports = RenderResult;
|
|
@@ -29,7 +29,7 @@ var proto = RenderResult.prototype = {
|
|
|
29
29
|
return this.getComponents()[0];
|
|
30
30
|
},
|
|
31
31
|
getComponents: function (selector) {
|
|
32
|
-
if (this.
|
|
32
|
+
if (this.b_ === undefined) {
|
|
33
33
|
throw Error("Not added to DOM");
|
|
34
34
|
}
|
|
35
35
|
|
|
@@ -38,7 +38,7 @@ var proto = RenderResult.prototype = {
|
|
|
38
38
|
var components = [];
|
|
39
39
|
|
|
40
40
|
componentDefs.forEach(function (componentDef) {
|
|
41
|
-
var component = componentDef.
|
|
41
|
+
var component = componentDef.t_;
|
|
42
42
|
if (!selector || selector(component)) {
|
|
43
43
|
components.push(component);
|
|
44
44
|
}
|
|
@@ -48,24 +48,24 @@ var proto = RenderResult.prototype = {
|
|
|
48
48
|
},
|
|
49
49
|
|
|
50
50
|
afterInsert: function (host) {
|
|
51
|
-
var out = this.
|
|
52
|
-
var componentsContext = out.
|
|
51
|
+
var out = this.s_;
|
|
52
|
+
var componentsContext = out.b_;
|
|
53
53
|
if (componentsContext) {
|
|
54
|
-
this.
|
|
54
|
+
this.b_ = componentsContext.ag_(host);
|
|
55
55
|
} else {
|
|
56
|
-
this.
|
|
56
|
+
this.b_ = null;
|
|
57
57
|
}
|
|
58
58
|
|
|
59
59
|
return this;
|
|
60
60
|
},
|
|
61
61
|
getNode: function (host) {
|
|
62
|
-
return this.
|
|
62
|
+
return this.s_.ah_(host);
|
|
63
63
|
},
|
|
64
64
|
getOutput: function () {
|
|
65
|
-
return this.
|
|
65
|
+
return this.s_.ai_();
|
|
66
66
|
},
|
|
67
67
|
toString: function () {
|
|
68
|
-
return this.
|
|
68
|
+
return this.s_.toString();
|
|
69
69
|
},
|
|
70
70
|
document: typeof document === "object" && document
|
|
71
71
|
};
|
|
@@ -73,11 +73,11 @@ var proto = RenderResult.prototype = {
|
|
|
73
73
|
Object.defineProperty(proto, "html", {
|
|
74
74
|
get: function () {
|
|
75
75
|
// eslint-disable-next-line no-constant-condition
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
76
|
+
|
|
77
|
+
|
|
78
|
+
|
|
79
|
+
|
|
80
|
+
|
|
81
81
|
return this.toString();
|
|
82
82
|
}
|
|
83
83
|
});
|
|
@@ -85,12 +85,12 @@ Object.defineProperty(proto, "html", {
|
|
|
85
85
|
Object.defineProperty(proto, "context", {
|
|
86
86
|
get: function () {
|
|
87
87
|
// eslint-disable-next-line no-constant-condition
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
return this.
|
|
88
|
+
|
|
89
|
+
|
|
90
|
+
|
|
91
|
+
|
|
92
|
+
|
|
93
|
+
return this.s_;
|
|
94
94
|
}
|
|
95
95
|
});
|
|
96
96
|
|