marko 5.20.9 → 5.21.0
Sign up to get free protection for your applications and to get access to all the features.
- package/dist/compiler/config.js +1 -2
- package/dist/compiler/index.js +1 -2
- package/dist/compiler/modules.js +1 -2
- package/dist/core-tags/components/init-components-tag.js +1 -2
- package/dist/core-tags/components/preferred-script-location-tag.js +1 -2
- package/dist/core-tags/components/preserve-tag/index-browser.js +1 -2
- package/dist/core-tags/components/preserve-tag/index.js +1 -2
- package/dist/core-tags/core/__flush_here_and_after__.js +1 -2
- package/dist/core-tags/core/await/AsyncValue.js +1 -2
- package/dist/core-tags/core/await/client-reorder-runtime.js +1 -2
- package/dist/core-tags/core/await/renderer.js +1 -2
- package/dist/core-tags/core/await/reorderer-renderer.js +1 -2
- package/dist/index.js +1 -2
- package/dist/loader/index-browser.js +1 -2
- package/dist/loader/index.js +1 -2
- package/dist/node-require/browser-refresh.js +1 -2
- package/dist/node-require/hot-reload.js +1 -2
- package/dist/node-require/index.js +1 -2
- package/dist/runtime/RenderResult.js +1 -2
- package/dist/runtime/components/Component.js +1 -2
- package/dist/runtime/components/ComponentDef.js +1 -2
- package/dist/runtime/components/ComponentsContext.js +1 -2
- package/dist/runtime/components/GlobalComponentsContext.js +1 -2
- package/dist/runtime/components/KeySequence.js +1 -2
- package/dist/runtime/components/ServerComponent.js +1 -2
- package/dist/runtime/components/State.js +1 -2
- package/dist/runtime/components/attach-detach.js +1 -2
- package/dist/runtime/components/beginComponent/index-browser.js +1 -2
- package/dist/runtime/components/beginComponent/index.js +1 -2
- package/dist/runtime/components/defineComponent.js +1 -2
- package/dist/runtime/components/dom-data.js +1 -2
- package/dist/runtime/components/endComponent/index-browser.js +1 -2
- package/dist/runtime/components/endComponent/index.js +1 -2
- package/dist/runtime/components/entry/index-browser.js +1 -2
- package/dist/runtime/components/entry/index.js +1 -2
- package/dist/runtime/components/event-delegation.js +1 -2
- package/dist/runtime/components/index.js +1 -2
- package/dist/runtime/components/init-components/index-browser.js +1 -2
- package/dist/runtime/components/init-components/index.js +1 -2
- package/dist/runtime/components/registry/index-browser.js +1 -2
- package/dist/runtime/components/registry/index.js +1 -2
- package/dist/runtime/components/renderer.js +1 -2
- package/dist/runtime/components/update-manager.js +1 -2
- package/dist/runtime/components/util/index-browser.js +1 -2
- package/dist/runtime/components/util/index.js +1 -2
- package/dist/runtime/createOut.js +1 -2
- package/dist/runtime/dom-insert.js +1 -2
- package/dist/runtime/events.js +1 -2
- package/dist/runtime/helpers/_change-case.js +1 -2
- package/dist/runtime/helpers/assign.js +1 -2
- package/dist/runtime/helpers/class-value.js +1 -2
- package/dist/runtime/helpers/dynamic-tag.js +1 -2
- package/dist/runtime/helpers/load-nested-tag.js +1 -2
- package/dist/runtime/helpers/merge.js +1 -2
- package/dist/runtime/helpers/render-tag.js +1 -2
- package/dist/runtime/helpers/style-value.js +1 -2
- package/dist/runtime/helpers/to-string.js +1 -2
- package/dist/runtime/html/AsyncStream.js +1 -2
- package/dist/runtime/html/BufferedWriter.js +1 -2
- package/dist/runtime/html/StringWriter.js +1 -2
- package/dist/runtime/html/create-readable/index-browser.js +1 -2
- package/dist/runtime/html/create-readable/index.js +1 -2
- package/dist/runtime/html/helpers/_dynamic-attr.js +1 -2
- package/dist/runtime/html/helpers/attr.js +1 -2
- package/dist/runtime/html/helpers/attrs.js +1 -2
- package/dist/runtime/html/helpers/class-attr.js +1 -2
- package/dist/runtime/html/helpers/data-marko.js +1 -2
- package/dist/runtime/html/helpers/escape-quotes.js +1 -2
- package/dist/runtime/html/helpers/escape-script-placeholder.js +1 -2
- package/dist/runtime/html/helpers/escape-style-placeholder.js +1 -2
- package/dist/runtime/html/helpers/escape-xml.js +1 -2
- package/dist/runtime/html/helpers/merge-attrs.js +1 -2
- package/dist/runtime/html/helpers/props-script.js +1 -2
- package/dist/runtime/html/helpers/style-attr.js +1 -2
- package/dist/runtime/html/hot-reload.js +1 -2
- package/dist/runtime/html/index.js +1 -2
- package/dist/runtime/queueMicrotask.js +1 -2
- package/dist/runtime/renderable.js +1 -2
- package/dist/runtime/setImmediate/index-browser.js +1 -2
- package/dist/runtime/setImmediate/index-worker.js +1 -2
- package/dist/runtime/setImmediate/index.js +1 -2
- package/dist/runtime/vdom/AsyncVDOMBuilder.js +1 -2
- package/dist/runtime/vdom/VComponent.js +1 -2
- package/dist/runtime/vdom/VDocumentFragment.js +1 -2
- package/dist/runtime/vdom/VElement.js +1 -2
- package/dist/runtime/vdom/VFragment.js +1 -2
- package/dist/runtime/vdom/VNode.js +1 -2
- package/dist/runtime/vdom/VText.js +1 -2
- package/dist/runtime/vdom/helpers/attrs.js +1 -2
- package/dist/runtime/vdom/helpers/const.js +1 -2
- package/dist/runtime/vdom/helpers/v-element.js +1 -2
- package/dist/runtime/vdom/helpers/v-text.js +1 -2
- package/dist/runtime/vdom/hot-reload.js +1 -2
- package/dist/runtime/vdom/index.js +1 -2
- package/dist/runtime/vdom/morphdom/fragment.js +1 -2
- package/dist/runtime/vdom/morphdom/helpers.js +1 -2
- package/dist/runtime/vdom/morphdom/index.js +1 -2
- package/dist/runtime/vdom/morphdom/specialElHandlers.js +1 -2
- package/dist/runtime/vdom/parse-html.js +1 -2
- package/dist/runtime/vdom/preserve-attrs.js +1 -2
- package/dist/runtime/vdom/vdom.js +1 -2
- package/dist/taglib/index.js +1 -2
- package/package.json +4 -5
- package/LICENSE +0 -21
- package/dist/compiler/config.js.map +0 -1
- package/dist/compiler/index.js.map +0 -1
- package/dist/compiler/modules.js.map +0 -1
- package/dist/core-tags/components/init-components-tag.js.map +0 -1
- package/dist/core-tags/components/preferred-script-location-tag.js.map +0 -1
- package/dist/core-tags/components/preserve-tag/index-browser.js.map +0 -1
- package/dist/core-tags/components/preserve-tag/index.js.map +0 -1
- package/dist/core-tags/core/__flush_here_and_after__.js.map +0 -1
- package/dist/core-tags/core/await/AsyncValue.js.map +0 -1
- package/dist/core-tags/core/await/client-reorder-runtime.js.map +0 -1
- package/dist/core-tags/core/await/renderer.js.map +0 -1
- package/dist/core-tags/core/await/reorderer-renderer.js.map +0 -1
- package/dist/index.js.map +0 -1
- package/dist/loader/index-browser.js.map +0 -1
- package/dist/loader/index.js.map +0 -1
- package/dist/node-require/browser-refresh.js.map +0 -1
- package/dist/node-require/hot-reload.js.map +0 -1
- package/dist/node-require/index.js.map +0 -1
- package/dist/runtime/RenderResult.js.map +0 -1
- package/dist/runtime/components/Component.js.map +0 -1
- package/dist/runtime/components/ComponentDef.js.map +0 -1
- package/dist/runtime/components/ComponentsContext.js.map +0 -1
- package/dist/runtime/components/GlobalComponentsContext.js.map +0 -1
- package/dist/runtime/components/KeySequence.js.map +0 -1
- package/dist/runtime/components/ServerComponent.js.map +0 -1
- package/dist/runtime/components/State.js.map +0 -1
- package/dist/runtime/components/attach-detach.js.map +0 -1
- package/dist/runtime/components/beginComponent/index-browser.js.map +0 -1
- package/dist/runtime/components/beginComponent/index.js.map +0 -1
- package/dist/runtime/components/defineComponent.js.map +0 -1
- package/dist/runtime/components/dom-data.js.map +0 -1
- package/dist/runtime/components/endComponent/index-browser.js.map +0 -1
- package/dist/runtime/components/endComponent/index.js.map +0 -1
- package/dist/runtime/components/entry/index-browser.js.map +0 -1
- package/dist/runtime/components/entry/index.js.map +0 -1
- package/dist/runtime/components/event-delegation.js.map +0 -1
- package/dist/runtime/components/index.js.map +0 -1
- package/dist/runtime/components/init-components/index-browser.js.map +0 -1
- package/dist/runtime/components/init-components/index.js.map +0 -1
- package/dist/runtime/components/registry/index-browser.js.map +0 -1
- package/dist/runtime/components/registry/index.js.map +0 -1
- package/dist/runtime/components/renderer.js.map +0 -1
- package/dist/runtime/components/update-manager.js.map +0 -1
- package/dist/runtime/components/util/index-browser.js.map +0 -1
- package/dist/runtime/components/util/index.js.map +0 -1
- package/dist/runtime/createOut.js.map +0 -1
- package/dist/runtime/dom-insert.js.map +0 -1
- package/dist/runtime/events.js.map +0 -1
- package/dist/runtime/helpers/_change-case.js.map +0 -1
- package/dist/runtime/helpers/assign.js.map +0 -1
- package/dist/runtime/helpers/class-value.js.map +0 -1
- package/dist/runtime/helpers/dynamic-tag.js.map +0 -1
- package/dist/runtime/helpers/load-nested-tag.js.map +0 -1
- package/dist/runtime/helpers/merge.js.map +0 -1
- package/dist/runtime/helpers/render-tag.js.map +0 -1
- package/dist/runtime/helpers/style-value.js.map +0 -1
- package/dist/runtime/helpers/to-string.js.map +0 -1
- package/dist/runtime/html/AsyncStream.js.map +0 -1
- package/dist/runtime/html/BufferedWriter.js.map +0 -1
- package/dist/runtime/html/StringWriter.js.map +0 -1
- package/dist/runtime/html/create-readable/index-browser.js.map +0 -1
- package/dist/runtime/html/create-readable/index.js.map +0 -1
- package/dist/runtime/html/helpers/_dynamic-attr.js.map +0 -1
- package/dist/runtime/html/helpers/attr.js.map +0 -1
- package/dist/runtime/html/helpers/attrs.js.map +0 -1
- package/dist/runtime/html/helpers/class-attr.js.map +0 -1
- package/dist/runtime/html/helpers/data-marko.js.map +0 -1
- package/dist/runtime/html/helpers/escape-quotes.js.map +0 -1
- package/dist/runtime/html/helpers/escape-script-placeholder.js.map +0 -1
- package/dist/runtime/html/helpers/escape-style-placeholder.js.map +0 -1
- package/dist/runtime/html/helpers/escape-xml.js.map +0 -1
- package/dist/runtime/html/helpers/merge-attrs.js.map +0 -1
- package/dist/runtime/html/helpers/props-script.js.map +0 -1
- package/dist/runtime/html/helpers/style-attr.js.map +0 -1
- package/dist/runtime/html/hot-reload.js.map +0 -1
- package/dist/runtime/html/index.js.map +0 -1
- package/dist/runtime/queueMicrotask.js.map +0 -1
- package/dist/runtime/renderable.js.map +0 -1
- package/dist/runtime/setImmediate/index-browser.js.map +0 -1
- package/dist/runtime/setImmediate/index-worker.js.map +0 -1
- package/dist/runtime/setImmediate/index.js.map +0 -1
- package/dist/runtime/vdom/AsyncVDOMBuilder.js.map +0 -1
- package/dist/runtime/vdom/VComponent.js.map +0 -1
- package/dist/runtime/vdom/VDocumentFragment.js.map +0 -1
- package/dist/runtime/vdom/VElement.js.map +0 -1
- package/dist/runtime/vdom/VFragment.js.map +0 -1
- package/dist/runtime/vdom/VNode.js.map +0 -1
- package/dist/runtime/vdom/VText.js.map +0 -1
- package/dist/runtime/vdom/helpers/attrs.js.map +0 -1
- package/dist/runtime/vdom/helpers/const.js.map +0 -1
- package/dist/runtime/vdom/helpers/v-element.js.map +0 -1
- package/dist/runtime/vdom/helpers/v-text.js.map +0 -1
- package/dist/runtime/vdom/hot-reload.js.map +0 -1
- package/dist/runtime/vdom/index.js.map +0 -1
- package/dist/runtime/vdom/morphdom/fragment.js.map +0 -1
- package/dist/runtime/vdom/morphdom/helpers.js.map +0 -1
- package/dist/runtime/vdom/morphdom/index.js.map +0 -1
- package/dist/runtime/vdom/morphdom/specialElHandlers.js.map +0 -1
- package/dist/runtime/vdom/parse-html.js.map +0 -1
- package/dist/runtime/vdom/preserve-attrs.js.map +0 -1
- package/dist/runtime/vdom/vdom.js.map +0 -1
- package/dist/taglib/index.js.map +0 -1
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"sources":["../../../src/runtime/components/ComponentsContext.js"],"names":["GlobalComponentsContext","require","ComponentsContext","out","parentComponentsContext","globalComponentsContext","componentDef","nestedContextsForParent","push","global","undefined","prototype","host","componentDefs","emit","getComponentsContext","module","exports"],"mappings":"AAAA;AACA,IAAIA,uBAAuB,GAAGC,OAAO,CAAC,2BAAD,CAArC;;AAEA,SAASC,iBAAT,CAA2BC,GAA3B,EAAgCC,uBAAhC,EAAyD;AACvD,MAAIC,uBAAJ;AACA,MAAIC,YAAJ;;AAEA,MAAIF,uBAAJ,EAA6B;AAC3BC,IAAAA,uBAAuB,GAAGD,uBAAuB,GAAjD;AACAE,IAAAA,YAAY,GAAGF,uBAAuB,GAAtC;;AAEA,QAAIG,uBAAJ;AACA;AACE,MAAEA,uBAAuB,GAAGH,uBAAuB,IAAnD,CADF;AAEE;AACAG,MAAAA,uBAAuB,GAAGH,uBAAuB,IAAvB,GAA4C,EAAtE;AACD;;AAEDG,IAAAA,uBAAuB,CAACC,IAAxB,CAA6B,IAA7B;AACD,GAZD,MAYO;AACLH,IAAAA,uBAAuB,GAAGF,GAAG,CAACM,MAAJ,GAA1B;AACA,QAAIJ,uBAAuB,KAAKK,SAAhC,EAA2C;AACzCP,MAAAA,GAAG,CAACM,MAAJ,MAA2BJ,uBAAuB;AAChD,UAAIL,uBAAJ,CAA4BG,GAA5B,CADF;AAED;AACF;;AAED,YAAwBE,uBAAxB;AACA,YAAqB,EAArB;AACA,YAAcF,GAAd;AACA,YAAuBG,YAAvB;AACA,aAAyBI,SAAzB;AACA;AACEN,EAAAA,uBAAuB,IAAIA,uBAAuB,GADpD;AAED;;AAEDF,iBAAiB,CAACS,SAAlB,GAA8B;AAC5B,MAAmB,UAAUC,IAAV,EAAgB;AACjC,QAAIC,aAAa,GAAG,OAApB;;AAEAX,IAAAA,iBAAiB,IAAjB,CAAwCW,aAAxC,EAAuDD,IAAvD;;AAEA,YAAYE,IAAZ;;AAEA;AACA;AACA,YAAYL,MAAZ,MAAmCC,SAAnC;;AAEA,WAAOG,aAAP;AACD,GAb2B,EAA9B;;;AAgBA,SAASE,oBAAT,CAA8BZ,GAA9B,EAAmC;AACjC,SAAOA,GAAG,GAAH,KAAsBA,GAAG,GAAH,GAAoB,IAAID,iBAAJ,CAAsBC,GAAtB,CAA1C,CAAP;AACD;;AAEDa,MAAM,CAACC,OAAP,GAAiBA,OAAO,GAAGf,iBAA3B;;AAEAe,OAAO,GAAP,GAAkCF,oBAAlC","sourcesContent":["\"use strict\";\nvar GlobalComponentsContext = require(\"./GlobalComponentsContext\");\n\nfunction ComponentsContext(out, parentComponentsContext) {\n var globalComponentsContext;\n var componentDef;\n\n if (parentComponentsContext) {\n globalComponentsContext = parentComponentsContext.___globalContext;\n componentDef = parentComponentsContext.___componentDef;\n\n var nestedContextsForParent;\n if (\n !(nestedContextsForParent = parentComponentsContext.___nestedContexts)\n ) {\n nestedContextsForParent = parentComponentsContext.___nestedContexts = [];\n }\n\n nestedContextsForParent.push(this);\n } else {\n globalComponentsContext = out.global.___components;\n if (globalComponentsContext === undefined) {\n out.global.___components = globalComponentsContext =\n new GlobalComponentsContext(out);\n }\n }\n\n this.___globalContext = globalComponentsContext;\n this.___components = [];\n this.___out = out;\n this.___componentDef = componentDef;\n this.___nestedContexts = undefined;\n this.___isPreserved =\n parentComponentsContext && parentComponentsContext.___isPreserved;\n}\n\nComponentsContext.prototype = {\n ___initComponents: function (host) {\n var componentDefs = this.___components;\n\n ComponentsContext.___initClientRendered(componentDefs, host);\n\n this.___out.emit(\"___componentsInitialized\");\n\n // Reset things stored in global since global is retained for\n // future renders\n this.___out.global.___components = undefined;\n\n return componentDefs;\n }\n};\n\nfunction getComponentsContext(out) {\n return out.___components || (out.___components = new ComponentsContext(out));\n}\n\nmodule.exports = exports = ComponentsContext;\n\nexports.___getComponentsContext = getComponentsContext;\n"],"file":"ComponentsContext.js"}
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"sources":["../../../src/runtime/components/GlobalComponentsContext.js"],"names":["nextComponentIdProvider","require","GlobalComponentsContext","out","undefined","module","exports"],"mappings":"aAAA,IAAIA,uBAAuB,GAAGC,OAAO,CAAC,QAAD,CAAP,IAA9B;;AAEA,SAASC,uBAAT,CAAiCC,GAAjC,EAAsC;AACpC,aAAiC,EAAjC;AACA,aAA4BC,SAA5B;AACA,aAA0BJ,uBAAuB,CAACG,GAAD,CAAjD;AACD;;AAEDE,MAAM,CAACC,OAAP,GAAiBJ,uBAAjB","sourcesContent":["var nextComponentIdProvider = require(\"./util\").___nextComponentIdProvider;\n\nfunction GlobalComponentsContext(out) {\n this.___renderedComponentsById = {};\n this.___rerenderComponent = undefined;\n this.___nextComponentId = nextComponentIdProvider(out);\n}\n\nmodule.exports = GlobalComponentsContext;\n"],"file":"GlobalComponentsContext.js"}
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"sources":["../../../src/runtime/components/KeySequence.js"],"names":["KeySequence","Object","create","prototype","key","lookup","module","exports"],"mappings":"aAAA,SAASA,WAAT,GAAuB;AACrB,aAAiBC,MAAM,CAACC,MAAP,CAAc,IAAd,CAAjB;AACD;;AAEDF,WAAW,CAACG,SAAZ,OAAmC,UAAUC,GAAV,EAAe;AAChD,MAAIC,MAAM,GAAG,QAAb;;AAEA,MAAIA,MAAM,CAACD,GAAD,CAAV,EAAiB;AACf,WAAOA,GAAG,GAAG,GAAN,GAAYC,MAAM,CAACD,GAAD,CAAN,EAAnB;AACD;;AAEDC,EAAAA,MAAM,CAACD,GAAD,CAAN,GAAc,CAAd;AACA,SAAOA,GAAP;AACD,CATD;;AAWAE,MAAM,CAACC,OAAP,GAAiBP,WAAjB","sourcesContent":["function KeySequence() {\n this.___lookup = Object.create(null);\n}\n\nKeySequence.prototype.___nextKey = function (key) {\n var lookup = this.___lookup;\n\n if (lookup[key]) {\n return key + \"_\" + lookup[key]++;\n }\n\n lookup[key] = 1;\n return key;\n};\n\nmodule.exports = KeySequence;\n"],"file":"KeySequence.js"}
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"sources":["../../../src/runtime/components/ServerComponent.js"],"names":["ServerComponent","constructor","id","input","out","typeName","customEvents","scope","undefined","onCreate","onInput","onRender","newInput","state","newState","elId","nestedId","String","indexOf","substring","prototype","getElId","module","exports"],"mappings":"AAAA;;;AAGA,MAAMA,eAAN,CAAsB;AACpBC,EAAAA,WAAW,CAACC,EAAD,EAAKC,KAAL,EAAYC,GAAZ,EAAiBC,QAAjB,EAA2BC,YAA3B,EAAyCC,KAAzC,EAAgD;AACzD,SAAKL,EAAL,GAAUA,EAAV;AACA,cAAuBI,YAAvB;AACA,cAAgBC,KAAhB;AACA,SAAKF,QAAL,GAAgBA,QAAhB;AACA,cAA4BG,SAA5B,CALyD,CAKlB;AACvC,eAA0C,CAA1C;;AAEA,SAAKC,QAAL,CAAcN,KAAd,EAAqBC,GAArB;AACA,eAAuB,KAAKM,OAAL,CAAaP,KAAb,EAAoBC,GAApB,KAA4BD,KAAnD;AACA,QAAI,YAAkBK,SAAtB,EAAiC;AAC/B,gBAAgB,QAAhB;AACD;AACD,SAAKG,QAAL,CAAcP,GAAd;AACD;;AAEQ,MAALD,KAAK,CAACS,QAAD,EAAW;AAClB,cAAgBA,QAAhB;AACD;;AAEQ,MAALT,KAAK,GAAG;AACV,WAAO,OAAP;AACD;;AAEQ,MAALU,KAAK,CAACC,QAAD,EAAW;AAClB,cAAgBA,QAAhB;AACD;;AAEQ,MAALD,KAAK,GAAG;AACV,WAAO,OAAP;AACD;;AAED,YAAkB;AAChB,WAAO,OAAP;AACD;;AAEDE,EAAAA,IAAI,CAACC,QAAD,EAAW;AACb,QAAId,EAAE,GAAG,KAAKA,EAAd;;AAEA,QAAIc,QAAQ,IAAI,IAAhB,EAAsB;AACpB,aAAOd,EAAP;AACD,KAFD,MAEO;AACL,UAAI,OAAOc,QAAP,KAAoB,QAAxB,EAAkC;AAChC;;;;;AAKAA,QAAAA,QAAQ,GAAGC,MAAM,CAACD,QAAD,CAAjB;AACD;;AAED,UAAIA,QAAQ,CAACE,OAAT,CAAiB,GAAjB,MAA0B,CAA9B,EAAiC;AAC/BhB,QAAAA,EAAE,GAAG,MAAMA,EAAX;AACAc,QAAAA,QAAQ,GAAGA,QAAQ,CAACG,SAAT,CAAmB,CAAnB,CAAX;AACD;;AAED,aAAOjB,EAAE,GAAG,GAAL,GAAWc,QAAlB;AACD;AACF;;AAEDP,EAAAA,QAAQ,GAAG,CAAE;AACbC,EAAAA,OAAO,GAAG,CAAE;AACZC,EAAAA,QAAQ,GAAG,CAAE,CA/DO;;;AAkEtBX,eAAe,CAACoB,SAAhB,CAA0BC,OAA1B,GAAoCrB,eAAe,CAACoB,SAAhB,CAA0BL,IAA9D;;AAEAO,MAAM,CAACC,OAAP,GAAiBvB,eAAjB","sourcesContent":["\"use strict\";\nvar complain = \"MARKO_DEBUG\" && require(\"complain\");\n\nclass ServerComponent {\n constructor(id, input, out, typeName, customEvents, scope) {\n this.id = id;\n this.___customEvents = customEvents;\n this.___scope = scope;\n this.typeName = typeName;\n this.___bubblingDomEvents = undefined; // Used to keep track of bubbling DOM events for components rendered on the server\n this.___bubblingDomEventsExtraArgsCount = 0;\n\n this.onCreate(input, out);\n this.___updatedInput = this.onInput(input, out) || input;\n if (this.___input === undefined) {\n this.___input = this.___updatedInput;\n }\n this.onRender(out);\n }\n\n set input(newInput) {\n this.___input = newInput;\n }\n\n get input() {\n return this.___input;\n }\n\n set state(newState) {\n this.___state = newState;\n }\n\n get state() {\n return this.___state;\n }\n\n get ___rawState() {\n return this.___state;\n }\n\n elId(nestedId) {\n var id = this.id;\n\n if (nestedId == null) {\n return id;\n } else {\n if (typeof nestedId !== \"string\") {\n // eslint-disable-next-line no-constant-condition\n if (\"MARKO_DEBUG\") {\n complain(\"Using non strings as keys is deprecated.\");\n }\n\n nestedId = String(nestedId);\n }\n\n if (nestedId.indexOf(\"#\") === 0) {\n id = \"#\" + id;\n nestedId = nestedId.substring(1);\n }\n\n return id + \"-\" + nestedId;\n }\n }\n\n onCreate() {}\n onInput() {}\n onRender() {}\n}\n\nServerComponent.prototype.getElId = ServerComponent.prototype.elId;\n\nmodule.exports = ServerComponent;\n"],"file":"ServerComponent.js"}
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"sources":["../../../src/runtime/components/State.js"],"names":["extend","require","ensure","state","propertyName","proto","constructor","prototype","Object","defineProperty","get","set","value","State","component","seal","self","newState","key","rawState","undefined","name","shouldEnsure","forceDirty","forcedDirtyState","toJSON","module","exports"],"mappings":"aAAA,IAAIA,MAAM,GAAGC,OAAO,CAAC,oBAAD,CAApB;;AAEA,SAASC,MAAT,CAAgBC,KAAhB,EAAuBC,YAAvB,EAAqC;AACnC,MAAIC,KAAK,GAAGF,KAAK,CAACG,WAAN,CAAkBC,SAA9B;AACA,MAAI,EAAEH,YAAY,IAAIC,KAAlB,CAAJ,EAA8B;AAC5BG,IAAAA,MAAM,CAACC,cAAP,CAAsBJ,KAAtB,EAA6BD,YAA7B,EAA2C;AACzCM,MAAAA,GAAG,EAAE,YAA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,EAAgBT,KAAhB,EAAuBU,YAAvB,EAAqCC,UAArC,EAAiD;AACvD,QAAIJ,QAAQ,GAAG,QAAf;;AAEA,QAAIG,YAAJ,EAAkB;AAChBpB,MAAAA,MAAM,CAAC,IAAD,EAAOmB,IAAP,CAAN;AACD;;AAED,QAAIE,UAAJ,EAAgB;AACd,UAAIC,gBAAgB,GAAG,aAAmB,WAAiB,EAApC,CAAvB;AACAA,MAAAA,gBAAgB,CAACH,IAAD,CAAhB,GAAyB,IAAzB;AACD,KAHD,MAGO,IAAIF,QAAQ,CAACE,IAAD,CAAR,KAAmBT,KAAvB,EAA8B;AACnC;AACD;;AAED,QAAI,CAAC,OAAL,EAAoB;AAClB;AACA;AACA;AACA,gBAAgB,IAAhB,CAJkB,CAII;AACtB,iBAAcO,QAAd;AACA,iBAAcA,QAAQ,GAAGnB,MAAM,CAAC,EAAD,EAAKmB,QAAL,CAA/B;AACA,iBAAkB,EAAlB;AACA;AACD;;AAED,aAAgBE,IAAhB,IAAwBT,KAAxB;;AAEA,QAAIA,KAAK,KAAKQ,SAAd,EAAyB;AACvB;AACA,aAAOD,QAAQ,CAACE,IAAD,CAAf;AACD,KAHD,MAGO;AACL;AACAF,MAAAA,QAAQ,CAACE,IAAD,CAAR,GAAiBT,KAAjB;AACD;AACF,GAtEe;AAuEhBa,EAAAA,MAAM,EAAE,YAAY;AAClB,WAAO,QAAP;AACD,GAzEe,EAAlB;;;AA4EAC,MAAM,CAACC,OAAP,GAAiBd,KAAjB","sourcesContent":["var extend = require(\"raptor-util/extend\");\n\nfunction ensure(state, propertyName) {\n var proto = state.constructor.prototype;\n if (!(propertyName in proto)) {\n Object.defineProperty(proto, propertyName, {\n get: function () {\n return this.___raw[propertyName];\n },\n set: function (value) {\n this.___set(propertyName, value, false /* ensure:false */);\n }\n });\n }\n}\n\nfunction State(component) {\n this.___component = component;\n this.___raw = {};\n\n this.___dirty = false;\n this.___old = null;\n this.___changes = null;\n this.___forced = null; // An object that we use to keep tracking of state properties that were forced to be dirty\n\n Object.seal(this);\n}\n\nState.prototype = {\n ___reset: function () {\n var self = this;\n\n self.___dirty = false;\n self.___old = null;\n self.___changes = null;\n self.___forced = null;\n },\n\n ___replace: function (newState) {\n var state = this;\n var key;\n\n var rawState = this.___raw;\n\n for (key in rawState) {\n if (!(key in newState)) {\n state.___set(\n key,\n undefined,\n false /* ensure:false */,\n false /* forceDirty:false */\n );\n }\n }\n\n for (key in newState) {\n state.___set(\n key,\n newState[key],\n true /* ensure:true */,\n false /* forceDirty:false */\n );\n }\n },\n ___set: function (name, value, shouldEnsure, forceDirty) {\n var rawState = this.___raw;\n\n if (shouldEnsure) {\n ensure(this, name);\n }\n\n if (forceDirty) {\n var forcedDirtyState = this.___forced || (this.___forced = {});\n forcedDirtyState[name] = true;\n } else if (rawState[name] === value) {\n return;\n }\n\n if (!this.___dirty) {\n // This is the first time we are modifying the component state\n // so introduce some properties to do some tracking of\n // changes to the state\n this.___dirty = true; // Mark the component state as dirty (i.e. modified)\n this.___old = rawState;\n this.___raw = rawState = extend({}, rawState);\n this.___changes = {};\n this.___component.___queueUpdate();\n }\n\n this.___changes[name] = value;\n\n if (value === undefined) {\n // Don't store state properties with an undefined or null value\n delete rawState[name];\n } else {\n // Otherwise, store the new value in the component state\n rawState[name] = value;\n }\n },\n toJSON: function () {\n return this.___raw;\n }\n};\n\nmodule.exports = State;\n"],"file":"State.js"}
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"sources":["../../../src/runtime/components/attach-detach.js"],"names":["eventDelegation","require","delegateEvent","getEventFromEl","handleNodeAttach","node","componentsContext","nodeType","eventName","target","out","data","attachTargets","on","i","length","push","handleNodeDetach","allowDetach","preventDefault","detach","parentNode","removeChild"],"mappings":"aAAA,IAAIA,eAAe,GAAGC,OAAO,CAAC,oBAAD,CAA7B;AACA,IAAIC,aAAa,GAAGF,eAAe,IAAnC;AACA,IAAIG,cAAc,GAAGH,eAAe,IAApC;;AAEA;AACA;AACA;;AAEA,SAASI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;AACrCU,QAAAA,cAAc,EAAE,YAAY;AAC1BD,UAAAA,WAAW,GAAG,KAAd;AACD,SAHoC;AAIrCE,QAAAA,MAAM,EAAE,YAAY;AAClB,cAAIC,UAAU,GAAGhB,IAAI,CAACgB,UAAtB;AACA,cAAIA,UAAJ,EAAgB;AACdA,YAAAA,UAAU,CAACC,WAAX,CAAuBjB,IAAvB;AACD;AACF,SAToC,EAA1B,CAAb;;;AAYA,aAAOa,WAAP;AACD;AACF;AACF;;AAEDlB,eAAe,IAAf,GAAsCI,gBAAtC;AACAJ,eAAe,IAAf,GAAsCiB,gBAAtC","sourcesContent":["var eventDelegation = require(\"./event-delegation\");\nvar delegateEvent = eventDelegation.___delegateEvent;\nvar getEventFromEl = eventDelegation.___getEventFromEl;\n\n// var componentsUtil = require('./util');\n// var destroyNodeRecursive = componentsUtil.___destroyNodeRecursive;\n// var destroyComponentForNode = componentsUtil.___destroyComponentForNode;\n\nfunction handleNodeAttach(node, componentsContext) {\n if (node.nodeType === 1) {\n var eventName = \"onattach\";\n var target = getEventFromEl(node, eventName);\n if (target) {\n var out = componentsContext.___out;\n var data = out.data;\n\n var attachTargets = data.___attachTargets;\n if (!attachTargets) {\n attachTargets = data.___attachTargets = [];\n out.on(\"___componentsInitialized\", function () {\n for (var i = 0; i < attachTargets.length; i += 2) {\n var node = attachTargets[i];\n var target = attachTargets[i + 1];\n delegateEvent(node, eventName, target, {});\n }\n });\n }\n\n attachTargets.push(node);\n attachTargets.push(target);\n }\n }\n}\n\nfunction handleNodeDetach(node) {\n if (node.nodeType === 1) {\n var eventName = \"ondetach\";\n var target = getEventFromEl(node, eventName);\n if (target) {\n var allowDetach;\n\n delegateEvent(node, eventName, target, {\n preventDefault: function () {\n allowDetach = false;\n },\n detach: function () {\n var parentNode = node.parentNode;\n if (parentNode) {\n parentNode.removeChild(node);\n }\n }\n });\n\n return allowDetach;\n }\n }\n}\n\neventDelegation.___handleNodeAttach = handleNodeAttach;\neventDelegation.___handleNodeDetach = handleNodeDetach;\n"],"file":"attach-detach.js"}
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"sources":["../../../../src/runtime/components/beginComponent/index-browser.js"],"names":["ComponentDef","require","module","exports","beginComponent","componentsContext","component","key","ownerComponentDef","componentId","id","componentDef","push","out","bc"],"mappings":"aAAA,IAAIA,YAAY,GAAGC,OAAO,CAAC,iBAAD,CAA1B;;AAEAC,MAAM,CAACC,OAAP,GAAiB,SAASC,cAAT;AACfC,iBADe;AAEfC,SAFe;AAGfC,GAHe;AAIfC,iBAJe;AAKf;AACA,MAAIC,WAAW,GAAGH,SAAS,CAACI,EAA5B;AACA,MAAIC,YAAY,GAAIN,iBAAiB,GAAjB,GAAoC,IAAIL,YAAJ;AACtDM,EAAAA,SADsD;AAEtDG,EAAAA,WAFsD;AAGtDJ,EAAAA,iBAHsD,CAAxD;;AAKAA,EAAAA,iBAAiB,GAAjB;AACEI,EAAAA,WADF;AAEI,MAFJ;AAGAJ,EAAAA,iBAAiB,GAAjB,CAAgCO,IAAhC,CAAqCD,YAArC;;AAEA,MAAIE,GAAG,GAAGR,iBAAiB,GAA3B;AACAQ,EAAAA,GAAG,CAACC,EAAJ,CAAOR,SAAP,EAAkBC,GAAlB,EAAuBC,iBAAiB,IAAIA,iBAAiB,GAA7D;AACA,SAAOG,YAAP;AACD,CApBD","sourcesContent":["var ComponentDef = require(\"../ComponentDef\");\n\nmodule.exports = function beginComponent(\n componentsContext,\n component,\n key,\n ownerComponentDef\n) {\n var componentId = component.id;\n var componentDef = (componentsContext.___componentDef = new ComponentDef(\n component,\n componentId,\n componentsContext\n ));\n componentsContext.___globalContext.___renderedComponentsById[\n componentId\n ] = true;\n componentsContext.___components.push(componentDef);\n\n var out = componentsContext.___out;\n out.bc(component, key, ownerComponentDef && ownerComponentDef.___component);\n return componentDef;\n};\n"],"file":"index-browser.js"}
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"sources":["../../../../src/runtime/components/beginComponent/index.js"],"names":["ComponentDef","require","FLAG_WILL_RERENDER_IN_BROWSER","module","exports","beginComponent","componentsContext","component","key","ownerComponentDef","isSplitComponent","isImplicitComponent","componentId","id","componentDef","ownerIsRenderBoundary","ownerWillRerender","_wrr","push","out","runtimeId","global","noBrowserRerender","w"],"mappings":"AAAA;;AAEA,MAAMA,YAAY,GAAGC,OAAO,CAAC,iBAAD,CAA5B;;AAEA,IAAIC,6BAA6B,GAAG,CAApC;AACA;;AAEAC,MAAM,CAACC,OAAP,GAAiB,SAASC,cAAT;AACfC,iBADe;AAEfC,SAFe;AAGfC,GAHe;AAIfC,iBAJe;AAKfC,gBALe;AAMfC,mBANe;AAOf;AACA,MAAIC,WAAW,GAAGL,SAAS,CAACM,EAA5B;;AAEA,MAAIC,YAAY,GAAIR,iBAAiB,GAAjB,GAAoC,IAAIN,YAAJ;AACtDO,EAAAA,SADsD;AAEtDK,EAAAA,WAFsD;AAGtDN,EAAAA,iBAHsD,CAAxD;;;AAMA,MAAIS,qBAAqB;AACvBN,EAAAA,iBAAiB,IAAIA,iBAAiB,IADxC;AAEA,MAAIO,iBAAiB;AACnBP,EAAAA,iBAAiB;AACjBA,EAAAA,iBAAiB,IAAjB,GAA6BP,6BAF/B;AAGA;AACA,MAAI,CAACI,iBAAiB,GAAlB,IAAqCU,iBAAzC,EAA4D;AAC1DF,IAAAA,YAAY,IAAZ,IAAyBZ,6BAAzB;AACAY,IAAAA,YAAY,CAACG,IAAb,GAAoB,IAApB;AACA,WAAOH,YAAP;AACD;;AAED,MAAIH,mBAAmB,KAAK,IAA5B,EAAkC;AAChC;AACA;AACA;AACA,WAAOG,YAAP;AACD;;AAEDR,EAAAA,iBAAiB,GAAjB,CAAgCY,IAAhC,CAAqCJ,YAArC;;AAEA,MAAIK,GAAG,GAAGb,iBAAiB,GAA3B;AACA,MAAIc,SAAS,GAAGD,GAAG,CAACE,MAAJ,CAAWD,SAA3B;;AAEAN,EAAAA,YAAY,IAAZ,GAAiC,IAAjC;AACAA,EAAAA,YAAY,IAAZ,GAAkCR,iBAAiB,GAAnD;;AAEA,MAAII,gBAAgB,KAAK,KAArB,IAA8BS,GAAG,CAACE,MAAJ,CAAWC,iBAAX,KAAiC,IAAnE,EAAyE;AACvER,IAAAA,YAAY,IAAZ,IAAyBZ,6BAAzB;AACAY,IAAAA,YAAY,CAACG,IAAb,GAAoB,IAApB;AACAX,IAAAA,iBAAiB,GAAjB,GAAmC,KAAnC;AACD;;AAED,MAAI,CAACS,qBAAqB,IAAIC,iBAA1B,KAAgDR,GAAG,IAAI,IAA3D,EAAiE;AAC/DW,IAAAA,GAAG,CAACI,CAAJ;AACE;AACEH,IAAAA,SADF;AAEE,OAFF;AAGER,IAAAA,WAHF;AAIE,OAJF;AAKEH,IAAAA,iBAAiB,CAACI,EALpB;AAME,OANF;AAOEL,IAAAA,GAPF;AAQE,SATJ;;AAWD,GAZD,MAYO;AACLW,IAAAA,GAAG,CAACI,CAAJ,CAAM,SAASH,SAAT,GAAqB,GAArB,GAA2BR,WAA3B,GAAyC,KAA/C;AACD;;AAED,SAAOE,YAAP;AACD,CAlED","sourcesContent":["\"use strict\";\n\nconst ComponentDef = require(\"../ComponentDef\");\n\nvar FLAG_WILL_RERENDER_IN_BROWSER = 1;\n// var FLAG_HAS_RENDER_BODY = 2;\n\nmodule.exports = function beginComponent(\n componentsContext,\n component,\n key,\n ownerComponentDef,\n isSplitComponent,\n isImplicitComponent\n) {\n var componentId = component.id;\n\n var componentDef = (componentsContext.___componentDef = new ComponentDef(\n component,\n componentId,\n componentsContext\n ));\n\n var ownerIsRenderBoundary =\n ownerComponentDef && ownerComponentDef.___renderBoundary;\n var ownerWillRerender =\n ownerComponentDef &&\n ownerComponentDef.___flags & FLAG_WILL_RERENDER_IN_BROWSER;\n // On the server\n if (!componentsContext.___isPreserved && ownerWillRerender) {\n componentDef.___flags |= FLAG_WILL_RERENDER_IN_BROWSER;\n componentDef._wrr = true;\n return componentDef;\n }\n\n if (isImplicitComponent === true) {\n // We don't mount implicit components rendered on the server\n // unless the implicit component is nested within a UI component\n // that will re-render in the browser\n return componentDef;\n }\n\n componentsContext.___components.push(componentDef);\n\n let out = componentsContext.___out;\n let runtimeId = out.global.runtimeId;\n\n componentDef.___renderBoundary = true;\n componentDef.___parentPreserved = componentsContext.___isPreserved;\n\n if (isSplitComponent === false && out.global.noBrowserRerender !== true) {\n componentDef.___flags |= FLAG_WILL_RERENDER_IN_BROWSER;\n componentDef._wrr = true;\n componentsContext.___isPreserved = false;\n }\n\n if ((ownerIsRenderBoundary || ownerWillRerender) && key != null) {\n out.w(\n \"<!--\" +\n runtimeId +\n \"^\" +\n componentId +\n \" \" +\n ownerComponentDef.id +\n \" \" +\n key +\n \"-->\"\n );\n } else {\n out.w(\"<!--\" + runtimeId + \"#\" + componentId + \"-->\");\n }\n\n return componentDef;\n};\n"],"file":"index.js"}
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"sources":["../../../src/runtime/components/defineComponent.js"],"names":["BaseState","require","BaseComponent","inherit","module","exports","defineComponent","def","renderer","ComponentClass","proto","type","prototype","TypeError","Component","id","call","State","component"],"mappings":"AAAA;AACA;;AAEA,IAAIA,SAAS,GAAGC,OAAO,CAAC,SAAD,CAAvB;AACA,IAAIC,aAAa,GAAGD,OAAO,CAAC,aAAD,CAA3B;AACA,IAAIE,OAAO,GAAGF,OAAO,CAAC,qBAAD,CAArB;;AAEAG,MAAM,CAACC,OAAP,GAAiB,SAASC,eAAT,CAAyBC,GAAzB,EAA8BC,QAA9B,EAAwC;AACvD,MAAID,GAAG,GAAP,EAAwB;AACtB,WAAOA,GAAP;AACD;;AAED,MAAIE,cAAc,GAAG,YAAY,CAAE,CAAnC;AACA,MAAIC,KAAJ;;AAEA,MAAIC,IAAI,GAAG,OAAOJ,GAAlB;;AAEA,MAAII,IAAI,IAAI,UAAZ,EAAwB;AACtBD,IAAAA,KAAK,GAAGH,GAAG,CAACK,SAAZ;AACD,GAFD,MAEO,IAAID,IAAI,IAAI,QAAZ,EAAsB;AAC3BD,IAAAA,KAAK,GAAGH,GAAR;AACD,GAFM,MAEA;AACL,UAAMM,SAAS,EAAf;AACD;;AAEDJ,EAAAA,cAAc,CAACG,SAAf,GAA2BF,KAA3B;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA,WAASI,SAAT,CAAmBC,EAAnB,EAAuB;AACrBb,IAAAA,aAAa,CAACc,IAAd,CAAmB,IAAnB,EAAyBD,EAAzB;AACD;;AAED,MAAI,CAACL,KAAK,GAAV,EAA2B;AACzB;AACAP,IAAAA,OAAO,CAACM,cAAD,EAAiBP,aAAjB,CAAP;AACD;;AAED;AACA;AACAQ,EAAAA,KAAK,GAAGI,SAAS,CAACF,SAAV,GAAsBH,cAAc,CAACG,SAA7C;;AAEA;;AAEA;AACA;AACAE,EAAAA,SAAS,GAAT,GAA2B,IAA3B;;AAEA,WAASG,KAAT,CAAeC,SAAf,EAA0B;AACxBlB,IAAAA,SAAS,CAACgB,IAAV,CAAe,IAAf,EAAqBE,SAArB;AACD;AACDf,EAAAA,OAAO,CAACc,KAAD,EAAQjB,SAAR,CAAP;AACAU,EAAAA,KAAK,IAAL,GAAiBO,KAAjB;AACAP,EAAAA,KAAK,IAAL,GAAoBF,QAApB;;AAEA,SAAOM,SAAP;AACD,CArDD","sourcesContent":["\"use strict\";\n/* jshint newcap:false */\n\nvar BaseState = require(\"./State\");\nvar BaseComponent = require(\"./Component\");\nvar inherit = require(\"raptor-util/inherit\");\n\nmodule.exports = function defineComponent(def, renderer) {\n if (def.___isComponent) {\n return def;\n }\n\n var ComponentClass = function () {};\n var proto;\n\n var type = typeof def;\n\n if (type == \"function\") {\n proto = def.prototype;\n } else if (type == \"object\") {\n proto = def;\n } else {\n throw TypeError();\n }\n\n ComponentClass.prototype = proto;\n\n // We don't use the constructor provided by the user\n // since we don't invoke their constructor until\n // we have had a chance to do our own initialization.\n // Instead, we store their constructor in the \"initComponent\"\n // property and that method gets called later inside\n // init-components-browser.js\n function Component(id) {\n BaseComponent.call(this, id);\n }\n\n if (!proto.___isComponent) {\n // Inherit from Component if they didn't already\n inherit(ComponentClass, BaseComponent);\n }\n\n // The same prototype will be used by our constructor after\n // we he have set up the prototype chain using the inherit function\n proto = Component.prototype = ComponentClass.prototype;\n\n // proto.constructor = def.constructor = Component;\n\n // Set a flag on the constructor function to make it clear this is\n // a component so that we can short-circuit this work later\n Component.___isComponent = true;\n\n function State(component) {\n BaseState.call(this, component);\n }\n inherit(State, BaseState);\n proto.___State = State;\n proto.___renderer = renderer;\n\n return Component;\n};\n"],"file":"defineComponent.js"}
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"sources":["../../../src/runtime/components/dom-data.js"],"names":["module","exports","WeakMap"],"mappings":"aAAAA,MAAM,CAACC,OAAP,GAAiB;AACf,OAAoB,IAAIC,OAAJ,EADL;AAEf,OAAsB,IAAIA,OAAJ,EAFP;AAGf,MAAuB,IAAIA,OAAJ,EAHR;AAIf,OAAsB,IAAIA,OAAJ,EAJP;AAKf,OAAiB,IAAIA,OAAJ,EALF;AAMf,MAAkC,EANnB,EAAjB","sourcesContent":["module.exports = {\n ___vPropsByDOMNode: new WeakMap(),\n ___vElementByDOMNode: new WeakMap(),\n ___componentByDOMNode: new WeakMap(),\n ___detachedByDOMNode: new WeakMap(),\n ___keyByDOMNode: new WeakMap(),\n ___ssrKeyedElementsByComponentId: {}\n};\n"],"file":"dom-data.js"}
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"sources":["../../../../src/runtime/components/endComponent/index-browser.js"],"names":["module","exports","endComponent","out","ee"],"mappings":"AAAA;;AAEAA,MAAM,CAACC,OAAP,GAAiB,SAASC,YAAT,CAAsBC,GAAtB,EAA2B;AAC1CA,EAAAA,GAAG,CAACC,EAAJ,GAD0C,CAChC;AACX,CAFD","sourcesContent":["\"use strict\";\n\nmodule.exports = function endComponent(out) {\n out.ee(); // endElement() (also works for VComponent nodes pushed on to the stack)\n};\n"],"file":"index-browser.js"}
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"sources":["../../../../src/runtime/components/endComponent/index.js"],"names":["ComponentsContext","require","getComponentsContext","module","exports","endComponent","out","componentDef","w","global","runtimeId"],"mappings":"AAAA;;AAEA,IAAIA,iBAAiB,GAAGC,OAAO,CAAC,sBAAD,CAA/B;AACA,IAAIC,oBAAoB,GAAGF,iBAAiB,GAA5C;;AAEAG,MAAM,CAACC,OAAP,GAAiB,SAASC,YAAT,CAAsBC,GAAtB,EAA2BC,YAA3B,EAAyC;AACxD,MAAIA,YAAY,IAAhB,EAAoC;AAClCD,IAAAA,GAAG,CAACE,CAAJ,CAAM,SAASF,GAAG,CAACG,MAAJ,CAAWC,SAApB,GAAgC,MAAtC;AACAR,IAAAA,oBAAoB,CAACI,GAAD,CAApB,MAA2CC,YAAY,IAAvD;AACD;AACF,CALD","sourcesContent":["\"use strict\";\n\nvar ComponentsContext = require(\"../ComponentsContext\");\nvar getComponentsContext = ComponentsContext.___getComponentsContext;\n\nmodule.exports = function endComponent(out, componentDef) {\n if (componentDef.___renderBoundary) {\n out.w(\"<!--\" + out.global.runtimeId + \"/-->\");\n getComponentsContext(out).___isPreserved = componentDef.___parentPreserved;\n }\n};\n"],"file":"index.js"}
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"sources":["../../../../src/runtime/components/entry/index-browser.js"],"names":["initComponents","require","exports","getComponentForEl","init","window","$initComponents","registry","register","id","component","r"],"mappings":"aAAA,IAAIA,cAAc,GAAGC,OAAO,CAAC,oBAAD,CAA5B;AACAA,OAAO,CAAC,sBAAD,CAAP;AACED,cAAc,IADhB;;AAGAE,OAAO,CAACC,iBAAR,GAA4BF,OAAO,CAAC,SAAD,CAAP,IAA5B;AACAC,OAAO,CAACE,IAAR,GAAeC,MAAM,CAACC,eAAP,GAAyBN,cAAc,IAAtD;;AAEA,IAAIO,QAAQ,GAAGN,OAAO,CAAC,aAAD,CAAtB;AACAC,OAAO,CAACM,QAAR,GAAmB,UAAUC,EAAV,EAAcC,SAAd,EAAyB;AAC1CH,EAAAA,QAAQ,CAACI,CAAT,CAAWF,EAAX,EAAe,YAAY;AACzB,WAAOC,SAAP;AACD,GAFD;AAGD,CAJD","sourcesContent":["var initComponents = require(\"../init-components\");\nrequire(\"../ComponentsContext\").___initClientRendered =\n initComponents.___initClientRendered;\n\nexports.getComponentForEl = require(\"../util\").___getComponentForEl;\nexports.init = window.$initComponents = initComponents.___initServerRendered;\n\nvar registry = require(\"../registry\");\nexports.register = function (id, component) {\n registry.r(id, function () {\n return component;\n });\n};\n"],"file":"index-browser.js"}
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"sources":["../../../../src/runtime/components/entry/index.js"],"names":["warp10","require","safeJSONRegExp","IGNORE_GLOBAL_TYPES","Set","DEFAULT_RUNTIME_ID","FLAG_WILL_RERENDER_IN_BROWSER","FLAG_HAS_RENDER_BODY","safeJSONReplacer","match","charCodeAt","toString","isNotEmpty","obj","keys","Object","i","length","undefined","safeStringify","data","JSON","stringify","stringifyPrepare","replace","getSerializedGlobals","$global","serializedGlobalsLookup","serializedGlobals","key","value","has","addComponentsFromContext","componentsContext","componentsToHydrate","components","len","componentDef","id","component","flags","input","typeName","customEvents","scope","bubblingDomEvents","state","serializedProps","undefinedPropNames","renderBody","stateKeys","stateKey","push","extra","b","d","e","f","p","s","u","w","parts","hasExtra","nestedContexts","forEach","nestedContext","getInitComponentsData","out","componentDefs","global","isLast","didSerializeComponents","prefix","componentIdPrefix","widgetIdPrefix","l","TYPE_INDEX","typesLookup","Map","newTypes","typeIndex","get","size","set","g","t","getInitComponentsDataFromOut","runtimeId","r","writeInitComponentsCode","script","exports","getInitComponentsCode","initComponentsData","arguments","componentGlobalKey","getRenderedComponents"],"mappings":"AAAA;;AAEA,IAAIA,MAAM,GAAGC,OAAO,CAAC,QAAD,CAApB;AACA,IAAIC,cAAc,GAAG,oBAArB;AACA,IAAIC,mBAAmB,GAAG,IAAIC,GAAJ,CAAQ,CAAC,WAAD,EAAc,UAAd,EAA0B,QAA1B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B;AACA,QAAMQ,kBAAkB;AACtBR,EAAAA,SAAS,KAAKnF,kBAAd,GAAmC,IAAnC,GAA0CmF,SAAS,GAAG,IADxD;;AAGA,SAAQ,IAAGQ,kBAAmB,aAAYA,kBAAmB,gBAAe7E,aAAa;AACvF2E,EAAAA,kBADuF;AAEvF,KAFF;AAGD,CApBD;;AAsBAF,OAAO,GAAP,GAAsC5D,wBAAtC;AACA4D,OAAO,CAACF,uBAAR,GAAkCA,uBAAlC;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACAE,OAAO,CAACK,qBAAR,GAAgC,UAAU7B,GAAV,EAAe;AAC7C,SAAOpE,MAAM,CAACuB,gBAAP,CAAwBgE,4BAA4B,CAACnB,GAAD,CAApD,CAAP;AACD,CAFD","sourcesContent":["\"use strict\";\n\nvar warp10 = require(\"warp10\");\nvar safeJSONRegExp = /<\\/|\\u2028|\\u2029/g;\nvar IGNORE_GLOBAL_TYPES = new Set([\"undefined\", \"function\", \"symbol\"]);\nvar DEFAULT_RUNTIME_ID = \"M\";\n\nvar FLAG_WILL_RERENDER_IN_BROWSER = 1;\nvar FLAG_HAS_RENDER_BODY = 2;\n\nfunction safeJSONReplacer(match) {\n if (match === \"</\") {\n return \"\\\\u003C/\";\n } else {\n return \"\\\\u\" + match.charCodeAt(0).toString(16);\n }\n}\n\nfunction isNotEmpty(obj) {\n var keys = Object.keys(obj);\n for (var i = keys.length; i--; ) {\n if (obj[keys[i]] !== undefined) {\n return true;\n }\n }\n\n return false;\n}\nfunction safeStringify(data) {\n return JSON.stringify(warp10.stringifyPrepare(data)).replace(\n safeJSONRegExp,\n safeJSONReplacer\n );\n}\n\nfunction getSerializedGlobals($global) {\n let serializedGlobalsLookup = $global.serializedGlobals;\n if (serializedGlobalsLookup) {\n let serializedGlobals;\n let keys = Object.keys(serializedGlobalsLookup);\n for (let i = keys.length; i--; ) {\n let key = keys[i];\n if (serializedGlobalsLookup[key]) {\n let value = $global[key];\n if (!IGNORE_GLOBAL_TYPES.has(typeof value)) {\n if (serializedGlobals === undefined) {\n serializedGlobals = {};\n }\n serializedGlobals[key] = value;\n }\n }\n }\n\n return serializedGlobals;\n }\n}\n\nfunction addComponentsFromContext(componentsContext, componentsToHydrate) {\n var components = componentsContext.___components;\n\n var len = components.length;\n\n for (var i = 0; i < len; i++) {\n var componentDef = components[i];\n var id = componentDef.id;\n var component = componentDef.___component;\n var flags = componentDef.___flags;\n var input = component.input || 0;\n var typeName = component.typeName;\n var customEvents = component.___customEvents;\n var scope = component.___scope;\n var bubblingDomEvents = component.___bubblingDomEvents;\n\n var state;\n var serializedProps;\n var undefinedPropNames;\n\n if (flags & FLAG_WILL_RERENDER_IN_BROWSER) {\n if (typeof input.renderBody === \"function\") {\n flags |= FLAG_HAS_RENDER_BODY;\n input.renderBody = undefined;\n }\n } else {\n if (component.state) {\n state = component.state;\n // Update state properties with an `undefined` value to have a `null`\n // value so that the property name will be serialized down to the browser.\n // This ensures that we add the proper getter/setter for the state property.\n const stateKeys = Object.keys(state);\n for (let i = stateKeys.length; i--; ) {\n const stateKey = stateKeys[i];\n\n if (state[stateKey] === undefined) {\n if (undefinedPropNames) {\n undefinedPropNames.push(stateKey);\n } else {\n undefinedPropNames = [stateKey];\n }\n }\n }\n }\n\n component.___state = undefined; // We don't use `delete` to avoid V8 deoptimization\n component.___input = undefined; // We don't use `delete` to avoid V8 deoptimization\n component.typeName = undefined;\n component.id = undefined;\n component.___customEvents = undefined;\n component.___scope = undefined;\n component.___bubblingDomEvents = undefined;\n component.___bubblingDomEventsExtraArgsCount = undefined;\n component.___updatedInput = undefined;\n component.___updateQueued = undefined;\n\n if (isNotEmpty(component)) {\n serializedProps = component;\n }\n }\n\n var extra = {\n b: bubblingDomEvents,\n d: componentDef.___domEvents,\n e: customEvents,\n f: flags || undefined,\n p: customEvents && scope, // Only serialize scope if we need to attach custom events\n s: state,\n u: undefinedPropNames,\n w: serializedProps\n };\n\n var parts = [id, typeName];\n var hasExtra = isNotEmpty(extra);\n\n if (input) {\n parts.push(input);\n\n if (hasExtra) {\n parts.push(extra);\n }\n } else if (hasExtra) {\n parts.push(0, extra); // empty input;\n }\n\n componentsToHydrate.push(parts);\n }\n\n components.length = 0;\n\n // Also add any components from nested contexts\n var nestedContexts = componentsContext.___nestedContexts;\n if (nestedContexts !== undefined) {\n nestedContexts.forEach(function (nestedContext) {\n addComponentsFromContext(nestedContext, componentsToHydrate);\n });\n }\n}\n\nfunction getInitComponentsData(out, componentDefs) {\n const len = componentDefs.length;\n const $global = out.global;\n const isLast = $global.___isLastFlush;\n const didSerializeComponents = $global.___didSerializeComponents;\n const prefix = $global.componentIdPrefix || $global.widgetIdPrefix;\n\n if (len === 0) {\n if (isLast && didSerializeComponents) {\n return { p: prefix, l: 1 };\n }\n\n return;\n }\n\n const TYPE_INDEX = 1;\n const typesLookup =\n $global.___typesLookup || ($global.___typesLookup = new Map());\n let newTypes;\n\n for (let i = 0; i < len; i++) {\n const componentDef = componentDefs[i];\n const typeName = componentDef[TYPE_INDEX];\n let typeIndex = typesLookup.get(typeName);\n\n if (typeIndex === undefined) {\n typeIndex = typesLookup.size;\n typesLookup.set(typeName, typeIndex);\n\n if (newTypes) {\n newTypes.push(typeName);\n } else {\n newTypes = [typeName];\n }\n }\n\n componentDef[TYPE_INDEX] = typeIndex;\n }\n\n let serializedGlobals;\n\n if (!didSerializeComponents) {\n $global.___didSerializeComponents = true;\n serializedGlobals = getSerializedGlobals($global);\n }\n\n return {\n p: prefix,\n l: isLast && 1,\n g: serializedGlobals,\n w: componentDefs,\n t: newTypes\n };\n}\n\nfunction getInitComponentsDataFromOut(out) {\n const componentsContext = out.___components;\n\n if (componentsContext === null) {\n return;\n }\n\n const $global = out.global;\n const runtimeId = $global.runtimeId;\n const componentsToHydrate = [];\n addComponentsFromContext(componentsContext, componentsToHydrate);\n\n $global.___isLastFlush = true;\n const data = getInitComponentsData(out, componentsToHydrate);\n $global.___isLastFlush = undefined;\n\n if (runtimeId !== DEFAULT_RUNTIME_ID && data) {\n data.r = runtimeId;\n }\n\n return data;\n}\n\nfunction writeInitComponentsCode(out) {\n out.script(exports.___getInitComponentsCode(out));\n}\n\nexports.___getInitComponentsCode = function getInitComponentsCode(\n out,\n componentDefs\n) {\n const initComponentsData =\n arguments.length === 2\n ? getInitComponentsData(out, componentDefs)\n : getInitComponentsDataFromOut(out);\n\n if (initComponentsData === undefined) {\n return \"\";\n }\n\n const runtimeId = out.global.runtimeId;\n const componentGlobalKey =\n runtimeId === DEFAULT_RUNTIME_ID ? \"MC\" : runtimeId + \"_C\";\n\n return `$${componentGlobalKey}=(window.$${componentGlobalKey}||[]).concat(${safeStringify(\n initComponentsData\n )})`;\n};\n\nexports.___addComponentsFromContext = addComponentsFromContext;\nexports.writeInitComponentsCode = writeInitComponentsCode;\n\n/**\n * Returns an object that can be sent to the browser using JSON.stringify. The parsed object should be\n * passed to require('marko-components').initComponents(...);\n *\n * @param {ComponentsContext|AsyncWriter} componentsContext A ComponentsContext or an AsyncWriter\n * @return {Object} An object with information about the rendered components that can be serialized to JSON. The object should be treated as opaque\n */\nexports.getRenderedComponents = function (out) {\n return warp10.stringifyPrepare(getInitComponentsDataFromOut(out));\n};\n"],"file":"index.js"}
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"sources":["../../../src/runtime/components/event-delegation.js"],"names":["componentsUtil","require","runtimeId","componentLookup","getMarkoPropsFromEl","TEXT_NODE","listenersAttachedKey","delegatedEvents","getEventFromEl","el","eventName","virtualProps","eventInfo","split","length","parseInt","delegateEvent","node","target","event","targetMethod","targetComponentId","isOnce","extraArgs","targetComponent","targetFunc","Error","apply","concat","call","addDelegatedEventHandler","eventType","addDelegatedEventHandlerToHost","host","listeners","body","addEventListener","curNode","correspondingUseElement","nodeType","parentNode","propName","bubbles","propagationStopped","oldStopPropagation","stopPropagation","getAttribute","noop","exports","Object","keys","forEach"],"mappings":"aAAA,IAAIA,cAAc,GAAGC,OAAO,CAAC,QAAD,CAA5B;AACA,IAAIC,SAAS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AA9B;AACAC,OAAO,IAAP,GAA2BhC,aAA3B;AACAgC,OAAO,IAAP,GAA4BxC,cAA5B;AACAwC,OAAO,IAAP,GAAsClB,wBAAtC;AACAkB,OAAO,IAAP,GAAkB,UAAUf,IAAV,EAAgB;AAChCgB,EAAAA,MAAM,CAACC,IAAP,CAAY3C,eAAZ,EAA6B4C,OAA7B,CAAqC,UAAUpB,SAAV,EAAqB;AACxDC,IAAAA,8BAA8B,CAACD,SAAD,EAAYE,IAAZ,CAA9B;AACD,GAFD;AAGD,CAJD","sourcesContent":["var componentsUtil = require(\"./util\");\nvar runtimeId = componentsUtil.___runtimeId;\nvar componentLookup = componentsUtil.___componentLookup;\nvar getMarkoPropsFromEl = componentsUtil.___getMarkoPropsFromEl;\n\nvar TEXT_NODE = 3;\n\n// We make our best effort to allow multiple marko runtimes to be loaded in the\n// same window. Each marko runtime will get its own unique runtime ID.\nvar listenersAttachedKey = \"$MDE\" + runtimeId;\nvar delegatedEvents = {};\n\nfunction getEventFromEl(el, eventName) {\n var virtualProps = getMarkoPropsFromEl(el);\n var eventInfo = virtualProps[eventName];\n\n if (typeof eventInfo === \"string\") {\n eventInfo = eventInfo.split(\" \");\n if (eventInfo[2]) {\n eventInfo[2] = eventInfo[2] === \"true\";\n }\n if (eventInfo.length == 4) {\n eventInfo[3] = parseInt(eventInfo[3], 10);\n }\n }\n\n return eventInfo;\n}\n\nfunction delegateEvent(node, eventName, target, event) {\n var targetMethod = target[0];\n var targetComponentId = target[1];\n var isOnce = target[2];\n var extraArgs = target[3];\n\n if (isOnce) {\n var virtualProps = getMarkoPropsFromEl(node);\n delete virtualProps[eventName];\n }\n\n var targetComponent = componentLookup[targetComponentId];\n\n if (!targetComponent) {\n return;\n }\n\n var targetFunc =\n typeof targetMethod === \"function\"\n ? targetMethod\n : targetComponent[targetMethod];\n if (!targetFunc) {\n throw Error(\"Method not found: \" + targetMethod);\n }\n\n if (extraArgs != null) {\n if (typeof extraArgs === \"number\") {\n extraArgs = targetComponent.___bubblingDomEvents[extraArgs];\n }\n }\n\n // Invoke the component method\n if (extraArgs) {\n targetFunc.apply(targetComponent, extraArgs.concat(event, node));\n } else {\n targetFunc.call(targetComponent, event, node);\n }\n}\n\nfunction addDelegatedEventHandler(eventType) {\n if (!delegatedEvents[eventType]) {\n delegatedEvents[eventType] = true;\n }\n}\n\nfunction addDelegatedEventHandlerToHost(eventType, host) {\n var listeners = (host[listenersAttachedKey] =\n host[listenersAttachedKey] || {});\n if (!listeners[eventType]) {\n (host.body || host).addEventListener(\n eventType,\n (listeners[eventType] = function (event) {\n var curNode = event.target;\n if (!curNode) {\n return;\n }\n\n curNode =\n // event.target of an SVGElementInstance does not have a\n // `getAttribute` function in IE 11.\n // See https://github.com/marko-js/marko/issues/796\n curNode.correspondingUseElement ||\n // in some browsers the event target can be a text node\n // one example being dragenter in firefox.\n (curNode.nodeType === TEXT_NODE ? curNode.parentNode : curNode);\n\n // Search up the tree looking DOM events mapped to target\n // component methods\n var propName = \"on\" + eventType;\n var target;\n\n // Attributes will have the following form:\n // on<event_type>(\"<target_method>|<component_id>\")\n\n if (event.bubbles) {\n var propagationStopped = false;\n\n // Monkey-patch to fix #97\n var oldStopPropagation = event.stopPropagation;\n\n event.stopPropagation = function () {\n oldStopPropagation.call(event);\n propagationStopped = true;\n };\n\n do {\n if ((target = getEventFromEl(curNode, propName))) {\n delegateEvent(curNode, propName, target, event);\n\n if (propagationStopped) {\n break;\n }\n }\n } while ((curNode = curNode.parentNode) && curNode.getAttribute);\n } else if ((target = getEventFromEl(curNode, propName))) {\n delegateEvent(curNode, propName, target, event);\n }\n }),\n true\n );\n }\n}\n\nfunction noop() {}\n\nexports.___handleNodeAttach = noop;\nexports.___handleNodeDetach = noop;\nexports.___delegateEvent = delegateEvent;\nexports.___getEventFromEl = getEventFromEl;\nexports.___addDelegatedEventHandler = addDelegatedEventHandler;\nexports.___init = function (host) {\n Object.keys(delegatedEvents).forEach(function (eventType) {\n addDelegatedEventHandlerToHost(eventType, host);\n });\n};\n"],"file":"event-delegation.js"}
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"sources":["../../../src/runtime/components/index.js"],"names":["module","exports","require"],"mappings":"aAAAA,MAAM,CAACC,OAAP,GAAiBC,OAAO,CAAC,SAAD,CAAxB","sourcesContent":["module.exports = require(\"./entry\");\n"],"file":"index.js"}
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"sources":["../../../../src/runtime/components/init-components/index-browser.js"],"names":["warp10Finalize","require","eventDelegation","win","window","createFragmentNode","componentsUtil","componentLookup","addComponentRootToKeyedElements","ComponentDef","registry","domData","keyedElementsByComponentId","componentsByDOMNode","serverComponentRootNodes","serverRenderedMeta","DEFAULT_RUNTIME_ID","FLAG_WILL_RERENDER_IN_BROWSER","deferredDefs","indexServerComponentBoundaries","node","runtimeId","stack","componentId","ownerId","ownerComponent","keyedElements","nextSibling","runtimeLength","length","firstChild","nodeType","commentValue","nodeValue","slice","firstChar","push","endNode","startNode","pop","rootNode","parentNode","substring","parts","split","key","removeChild","markoKey","getAttribute","markoProps","separatorIndex","indexOf","Object","keys","forEach","invokeComponentEventHandler","component","targetMethodName","args","method","Error","apply","addEventListenerHelper","el","eventType","isOnce","listener","eventListener","event","removeEventListener","addEventListener","remove","addDOMEventListeners","extraArgs","handles","removeListener","concat","initComponent","componentDef","host","isExisting","domEvents","eventListenerHandles","domEventArgs","eventEl","initClientRendered","componentDefs","document","len","i","trackComponent","initServerRendered","renderedComponents","type","globalKey","fakeArray","r","renderedComponent","isFromSerializedGlobals","prefix","p","meta","isLast","l","g","t","w","map","typeName","tryHydrateComponent","reverse","tryInvoke","rawDef","mount","hydrateComponentAndGetMount","undefined","id","renderResult","set","afterInsert","fn","exports"],"mappings":"AAAA;;AAEA,IAAIA,cAAc,GAAGC,OAAO,CAAC,iBAAD,CAA5B;AACA,IAAIC,eAAe,GAAGD,OAAO,CAAC,qBAAD,CAA7B;AACA,IAAIE,GAAG,GAAGC,MAAV;AACA,IAAI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;AAEA,QAAIsB,YAAY,IAAZ,GAAwB7D,6BAA5B,EAA2D;AACzDuC,MAAAA,SAAS,GAAT,GAAoBuB,IAApB;AACAsC,MAAAA,YAAY,GAAG7D,SAAS,IAAT,CAAsBA,SAAS,GAA/B,EAA0C,IAA1C,CAAf;AACAkC,MAAAA,cAAc,CAACZ,YAAD,CAAd;AACA,aAAO,SAASmC,KAAT,GAAiB;AACtBI,QAAAA,YAAY,CAACE,WAAb,CAAyBxC,IAAzB;AACD,OAFD;AAGD,KAPD,MAOO;AACLW,MAAAA,cAAc,CAACZ,YAAD,CAAd;AACD;;AAED,WAAO,SAASmC,KAAT,GAAiB;AACtBpC,MAAAA,aAAa,CAACC,YAAD,EAAeC,IAAf,CAAb;AACD,KAFD;AAGD;AACF;;AAED,SAASW,cAAT,CAAwBZ,YAAxB,EAAsC;AACpC,MAAItB,SAAS,GAAGsB,YAAY,GAA5B;AACA,MAAItB,SAAJ,EAAe;AACbjD,IAAAA,eAAe,CAACiD,SAAS,CAAC4D,EAAX,CAAf,GAAgC5D,SAAhC;AACD;AACF;;AAED,SAASuD,SAAT,CAAmBS,EAAnB,EAAuB;AACrB,MAAIA,EAAJ,EAAQA,EAAE;AACX;;AAEDC,OAAO,IAAP,GAAgCpC,kBAAhC;AACAoC,OAAO,IAAP,GAAgC9B,kBAAhC;AACA8B,OAAO,IAAP,GAAiCZ,mBAAjC","sourcesContent":["\"use strict\";\nvar complain = \"MARKO_DEBUG\" && require(\"complain\");\nvar warp10Finalize = require(\"warp10/finalize\");\nvar eventDelegation = require(\"../event-delegation\");\nvar win = window;\nvar createFragmentNode =\n require(\"../../vdom/morphdom/fragment\").___createFragmentNode;\nvar componentsUtil = require(\"../util\");\nvar componentLookup = componentsUtil.___componentLookup;\nvar addComponentRootToKeyedElements =\n componentsUtil.___addComponentRootToKeyedElements;\nvar ComponentDef = require(\"../ComponentDef\");\nvar registry = require(\"../registry\");\nvar domData = require(\"../dom-data\");\nvar keyedElementsByComponentId = domData.___ssrKeyedElementsByComponentId;\nvar componentsByDOMNode = domData.___componentByDOMNode;\nvar serverComponentRootNodes = {};\nvar serverRenderedMeta = {};\n\nvar DEFAULT_RUNTIME_ID = \"M\";\nvar FLAG_WILL_RERENDER_IN_BROWSER = 1;\n// var FLAG_HAS_RENDER_BODY = 2;\n\nvar deferredDefs;\n\nfunction indexServerComponentBoundaries(node, runtimeId, stack) {\n var componentId;\n var ownerId;\n var ownerComponent;\n var keyedElements;\n var nextSibling;\n var runtimeLength = runtimeId.length;\n stack = stack || [];\n\n node = node.firstChild;\n while (node) {\n nextSibling = node.nextSibling;\n if (node.nodeType === 8) {\n // Comment node\n var commentValue = node.nodeValue;\n if (commentValue.slice(0, runtimeLength) === runtimeId) {\n var firstChar = commentValue[runtimeLength];\n\n if (firstChar === \"^\" || firstChar === \"#\") {\n stack.push(node);\n } else if (firstChar === \"/\") {\n var endNode = node;\n var startNode = stack.pop();\n var rootNode;\n\n if (startNode.parentNode === endNode.parentNode) {\n rootNode = createFragmentNode(startNode.nextSibling, endNode);\n } else {\n rootNode = createFragmentNode(\n endNode.parentNode.firstChild,\n endNode\n );\n }\n\n componentId = startNode.nodeValue.substring(runtimeLength + 1);\n firstChar = startNode.nodeValue[runtimeLength];\n\n if (firstChar === \"^\") {\n var parts = componentId.split(/ /g);\n var key = parts[2];\n ownerId = parts[1];\n componentId = parts[0];\n if ((ownerComponent = componentLookup[ownerId])) {\n keyedElements = ownerComponent.___keyedElements;\n } else {\n keyedElements =\n keyedElementsByComponentId[ownerId] ||\n (keyedElementsByComponentId[ownerId] = {});\n }\n addComponentRootToKeyedElements(\n keyedElements,\n key,\n rootNode,\n componentId\n );\n }\n\n serverComponentRootNodes[componentId] = rootNode;\n\n startNode.parentNode.removeChild(startNode);\n endNode.parentNode.removeChild(endNode);\n }\n }\n } else if (node.nodeType === 1) {\n // HTML element node\n var markoKey = node.getAttribute(\"data-marko-key\");\n var markoProps = componentsUtil.___getMarkoPropsFromEl(node);\n if (markoKey) {\n var separatorIndex = markoKey.indexOf(\" \");\n ownerId = markoKey.substring(separatorIndex + 1);\n markoKey = markoKey.substring(0, separatorIndex);\n if ((ownerComponent = componentLookup[ownerId])) {\n keyedElements = ownerComponent.___keyedElements;\n } else {\n keyedElements =\n keyedElementsByComponentId[ownerId] ||\n (keyedElementsByComponentId[ownerId] = {});\n }\n keyedElements[markoKey] = node;\n }\n if (markoProps) {\n Object.keys(markoProps).forEach(function (key) {\n if (key.slice(0, 2) === \"on\") {\n eventDelegation.___addDelegatedEventHandler(key.slice(2));\n }\n });\n }\n indexServerComponentBoundaries(node, runtimeId, stack);\n }\n\n node = nextSibling;\n }\n}\n\nfunction invokeComponentEventHandler(component, targetMethodName, args) {\n var method = component[targetMethodName];\n if (!method) {\n throw Error(\"Method not found: \" + targetMethodName);\n }\n\n method.apply(component, args);\n}\n\nfunction addEventListenerHelper(el, eventType, isOnce, listener) {\n var eventListener = listener;\n if (isOnce) {\n eventListener = function (event) {\n listener(event);\n el.removeEventListener(eventType, eventListener);\n };\n }\n\n el.addEventListener(eventType, eventListener, false);\n\n return function remove() {\n el.removeEventListener(eventType, eventListener);\n };\n}\n\nfunction addDOMEventListeners(\n component,\n el,\n eventType,\n targetMethodName,\n isOnce,\n extraArgs,\n handles\n) {\n var removeListener = addEventListenerHelper(\n el,\n eventType,\n isOnce,\n function (event) {\n var args = [event, el];\n if (extraArgs) {\n args = extraArgs.concat(args);\n }\n\n invokeComponentEventHandler(component, targetMethodName, args);\n }\n );\n handles.push(removeListener);\n}\n\nfunction initComponent(componentDef, host) {\n var component = componentDef.___component;\n\n component.___reset();\n component.___host = host;\n\n var isExisting = componentDef.___isExisting;\n\n if (isExisting) {\n component.___removeDOMEventListeners();\n }\n\n var domEvents = componentDef.___domEvents;\n if (domEvents) {\n var eventListenerHandles = [];\n\n domEvents.forEach(function (domEventArgs) {\n // The event mapping is for a direct DOM event (not a custom event and not for bubblign dom events)\n\n var eventType = domEventArgs[0];\n var targetMethodName = domEventArgs[1];\n var eventEl = component.___keyedElements[domEventArgs[2]];\n var isOnce = domEventArgs[3];\n var extraArgs = domEventArgs[4];\n\n addDOMEventListeners(\n component,\n eventEl,\n eventType,\n targetMethodName,\n isOnce,\n extraArgs,\n eventListenerHandles\n );\n });\n\n if (eventListenerHandles.length) {\n component.___domEventListenerHandles = eventListenerHandles;\n }\n }\n\n if (component.___mounted) {\n component.___emitUpdate();\n } else {\n component.___mounted = true;\n component.___emitMount();\n }\n}\n\n/**\n * This method is used to initialized components associated with UI components\n * rendered in the browser. While rendering UI components a \"components context\"\n * is added to the rendering context to keep up with which components are rendered.\n * When ready, the components can then be initialized by walking the component tree\n * in the components context (nested components are initialized before ancestor components).\n * @param {Array<marko-components/lib/ComponentDef>} componentDefs An array of ComponentDef instances\n */\nfunction initClientRendered(componentDefs, host) {\n if (!host) host = document;\n // Ensure that event handlers to handle delegating events are\n // always attached before initializing any components\n eventDelegation.___init(host);\n var len = componentDefs.length;\n var componentDef;\n var i;\n\n for (i = len; i--; ) {\n componentDef = componentDefs[i];\n trackComponent(componentDef);\n }\n\n for (i = len; i--; ) {\n componentDef = componentDefs[i];\n initComponent(componentDef, host);\n }\n}\n\n/**\n * This method initializes all components that were rendered on the server by iterating over all\n * of the component IDs.\n */\nfunction initServerRendered(renderedComponents, host) {\n var type = typeof renderedComponents;\n var globalKey = \"$\";\n var runtimeId;\n\n if (type !== \"object\") {\n if (type === \"string\") {\n runtimeId = renderedComponents;\n globalKey += runtimeId + \"_C\";\n } else {\n globalKey += (runtimeId = DEFAULT_RUNTIME_ID) + \"C\";\n }\n\n renderedComponents = win[globalKey];\n\n // eslint-disable-next-line no-constant-condition\n if (\"MARKO_DEBUG\") {\n if (\n renderedComponents &&\n renderedComponents.i !== undefined &&\n renderedComponents.i !== componentsUtil.___runtimeId\n ) {\n console.warn(\n \"Multiple instances of Marko have attached to the same runtime id. This could mean that more than one copy of Marko is loaded on the page, or that the script containing Marko has executed more than once.\"\n );\n }\n }\n\n var fakeArray = (win[globalKey] = {\n r: runtimeId,\n concat: initServerRendered\n });\n\n // eslint-disable-next-line no-constant-condition\n if (\"MARKO_DEBUG\") {\n fakeArray.i = componentsUtil.___runtimeId;\n }\n\n if (renderedComponents && renderedComponents.forEach) {\n renderedComponents.forEach(function (renderedComponent) {\n fakeArray.concat(renderedComponent);\n });\n }\n\n return fakeArray;\n }\n\n var isFromSerializedGlobals = this.concat === initServerRendered;\n renderedComponents = warp10Finalize(renderedComponents);\n\n if (isFromSerializedGlobals) {\n runtimeId = this.r;\n host = document;\n } else {\n runtimeId = renderedComponents.r || DEFAULT_RUNTIME_ID;\n if (!host) host = document;\n\n // eslint-disable-next-line no-constant-condition\n if (\"MARKO_DEBUG\") {\n complain(\n \"Passing serialized data to `require('marko/components).init` is deprecated. Instead set '$global.runtimeId' and provide the 'runtimeId' option to your Marko bundler plugin.\"\n );\n }\n }\n\n // eslint-disable-next-line no-constant-condition\n if (\"MARKO_DEBUG\") {\n if (host !== document) {\n complain(\n \"Passing a document other than the current document to `require('marko/components).init` is deprecated.\"\n );\n }\n }\n\n var prefix = renderedComponents.p || \"\";\n var meta = serverRenderedMeta[prefix];\n var isLast = renderedComponents.l;\n\n if (meta) {\n if (isLast) {\n delete serverRenderedMeta[prefix];\n }\n } else {\n meta = {};\n\n if (!isLast) {\n serverRenderedMeta[prefix] = meta;\n }\n }\n\n // Ensure that event handlers to handle delegating events are\n // always attached before initializing any components\n indexServerComponentBoundaries(host, runtimeId);\n eventDelegation.___init(host);\n\n if (renderedComponents.g) {\n meta.___globals = renderedComponents.g;\n }\n\n if (renderedComponents.t) {\n meta.___types = meta.___types\n ? meta.___types.concat(renderedComponents.t)\n : renderedComponents.t;\n }\n\n // hydrate components top down (leaf nodes last)\n // and return an array of functions to mount these components\n (renderedComponents.w || [])\n .map(function (componentDef) {\n var typeName = meta.___types[componentDef[1]];\n\n return registry.___isRegistered(typeName)\n ? tryHydrateComponent(componentDef, meta, host, runtimeId)\n : registry.___addPendingDef(\n componentDef,\n typeName,\n meta,\n host,\n runtimeId\n );\n })\n .reverse()\n .forEach(tryInvoke);\n\n return this;\n}\n\nfunction tryHydrateComponent(rawDef, meta, host, runtimeId) {\n var componentDef = ComponentDef.___deserialize(\n rawDef,\n meta.___types,\n meta.___globals,\n registry\n );\n var mount = hydrateComponentAndGetMount(componentDef, host);\n\n if (!mount) {\n // hydrateComponentAndGetMount will return false if there is not rootNode\n // for the component. If this is the case, we'll wait until the\n // DOM has fully loaded to attempt to init the component again.\n if (deferredDefs) {\n deferredDefs.push(componentDef);\n } else {\n deferredDefs = [componentDef];\n document.addEventListener(\"DOMContentLoaded\", function () {\n indexServerComponentBoundaries(host, runtimeId);\n deferredDefs\n .map(function (componentDef) {\n return hydrateComponentAndGetMount(componentDef, host);\n })\n .reverse()\n .forEach(tryInvoke);\n deferredDefs = undefined;\n });\n }\n }\n\n return mount;\n}\n\nfunction hydrateComponentAndGetMount(componentDef, host) {\n var componentId = componentDef.id;\n var component = componentDef.___component;\n var rootNode = serverComponentRootNodes[componentId];\n var renderResult;\n\n if (rootNode) {\n delete serverComponentRootNodes[componentId];\n\n component.___rootNode = rootNode;\n componentsByDOMNode.set(rootNode, component);\n\n if (componentDef.___flags & FLAG_WILL_RERENDER_IN_BROWSER) {\n component.___host = host;\n renderResult = component.___rerender(component.___input, true);\n trackComponent(componentDef);\n return function mount() {\n renderResult.afterInsert(host);\n };\n } else {\n trackComponent(componentDef);\n }\n\n return function mount() {\n initComponent(componentDef, host);\n };\n }\n}\n\nfunction trackComponent(componentDef) {\n var component = componentDef.___component;\n if (component) {\n componentLookup[component.id] = component;\n }\n}\n\nfunction tryInvoke(fn) {\n if (fn) fn();\n}\n\nexports.___initClientRendered = initClientRendered;\nexports.___initServerRendered = initServerRendered;\nexports.___tryHydrateComponent = tryHydrateComponent;\n"],"file":"index-browser.js"}
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"sources":["../../../../src/runtime/components/init-components/index.js"],"names":[],"mappings":"AAAA","sourcesContent":["// The server-side implementation of this module is intentionally empty\n"],"file":"index.js"}
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"sources":["../../../../src/runtime/components/registry/index-browser.js"],"names":["queueMicrotask","require","defineComponent","initComponents","registered","loaded","componentTypes","pendingDefs","register","type","def","pendingForType","forEach","args","addPendingDef","meta","host","runtimeId","push","isRegistered","Boolean","load","typeName","target","Error","getComponentClass","ComponentClass","Component","renderer","prototype","createComponent","id","exports","r"],"mappings":";AACA,IAAIA,cAAc,GAAGC,OAAO,CAAC,sBAAD,CAA5B;AACA,IAAIC,eAAe,GAAGD,OAAO,CAAC,oBAAD,CAA7B;AACA,IAAIE,cAAc,GAAGF,OAAO,CAAC,oBAAD,CAA5B;AACAA,OAAO,CAAC,UAAD,CAAP;;AAEA,IAAIG,UAAU,GAAG,EAAjB;AACA,IAAIC,MAAM,GAAG,EAAb;AACA,IAAIC,cAAc,GAAG,EAArB;AACA,IAAIC,WAAJ;;AAEA,SAASC,QAAT,CAAkBC,IAAlB,EAAwBC,GAAxB,EAA6B;AAC3B,MAAIC,cAAJ;AACA,MAAIJ,WAAJ,EAAiB;AACfI,IAAAA,cAAc,GAAGJ,WAAW,CAACE,IAAD,CAA5B;AACD;AACDL,EAAAA,UAAU,CAACK,IAAD,CAAV,GAAmBC,GAAnB;AACA,SAAOL,MAAM,CAACI,IAAD,CAAb;AACA,SAAOH,cAAc,CAACG,IAAD,CAArB;;AAEA,MAAIE,cAAJ,EAAoB;AAClB,WAAOJ,WAAW,CAACE,IAAD,CAAlB;AACAT,IAAAA,cAAc,CAAC,YAAY;AACzBW,MAAAA,cAAc,CAACC,OAAf,CAAuB,UAAUC,IAAV,EAAgB;AACrCV,QAAAA,cAAc,IAAd;AACEU,QAAAA,IAAI,CAAC,CAAD,CADN;AAEEA,QAAAA,IAAI,CAAC,CAAD,CAFN;AAGEA,QAAAA,IAAI,CAAC,CAAD,CAHN;AAIEA,QAAAA,IAAI,CAAC,CAAD,CAJN;;AAMD,OAP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;;AAEA,MAAI,CAACA,cAAc,GAAnB,EAAoC;AAClCA,IAAAA,cAAc,GAAGxB,eAAe,CAACwB,cAAD,EAAiBA,cAAc,CAACE,QAAhC,CAAhC;AACD;;AAED;AACAF,EAAAA,cAAc,CAACG,SAAf,OAAmCP,QAAnC;;AAEA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AA6BAhB,EAAAA,cAAc,CAACgB,QAAD,CAAd,GAA2BI,cAA3B;;AAEA,SAAOA,cAAP;AACD;;AAED,SAASI,eAAT,CAAyBR,QAAzB,EAAmCS,EAAnC,EAAuC;AACrC,MAAIL,cAAc,GAAGD,iBAAiB,CAACH,QAAD,CAAtC;AACA,SAAO,IAAII,cAAJ,CAAmBK,EAAnB,CAAP;AACD;;AAEDC,OAAO,CAACC,CAAR,GAAYzB,QAAZ;AACAwB,OAAO,IAAP,GAA+BP,iBAA/B;AACAO,OAAO,IAAP,GAA6BF,eAA7B;AACAE,OAAO,IAAP,GAA0Bb,YAA1B;AACAa,OAAO,IAAP,GAA2BlB,aAA3B","sourcesContent":["var complain = \"MARKO_DEBUG\" && require(\"complain\");\nvar queueMicrotask = require(\"../../queueMicrotask\");\nvar defineComponent = require(\"../defineComponent\");\nvar initComponents = require(\"../init-components\");\nrequire(\"../entry\");\n\nvar registered = {};\nvar loaded = {};\nvar componentTypes = {};\nvar pendingDefs;\n\nfunction register(type, def) {\n var pendingForType;\n if (pendingDefs) {\n pendingForType = pendingDefs[type];\n }\n registered[type] = def;\n delete loaded[type];\n delete componentTypes[type];\n\n if (pendingForType) {\n delete pendingDefs[type];\n queueMicrotask(function () {\n pendingForType.forEach(function (args) {\n initComponents.___tryHydrateComponent(\n args[0],\n args[1],\n args[2],\n args[3]\n )();\n });\n });\n }\n\n return type;\n}\n\nfunction addPendingDef(def, type, meta, host, runtimeId) {\n if (!pendingDefs) {\n pendingDefs = {};\n\n // eslint-disable-next-line no-constant-condition\n if (\"MARKO_DEBUG\") {\n document.addEventListener(\"load\", function () {\n var pendingComponentIds = Object.keys(pendingDefs);\n if (pendingComponentIds.length) {\n complain(\n \"Marko templates were never loaded for: \" + pendingComponentIds\n );\n }\n });\n }\n }\n (pendingDefs[type] = pendingDefs[type] || []).push([\n def,\n meta,\n host,\n runtimeId\n ]);\n}\n\nfunction isRegistered(type) {\n return Boolean(registered[type]);\n}\n\nfunction load(typeName) {\n var target = loaded[typeName];\n if (!target) {\n target = registered[typeName];\n\n if (target) {\n target = target();\n }\n\n if (!target) {\n throw Error(\"Component not found: \" + typeName);\n }\n\n loaded[typeName] = target;\n }\n\n return target;\n}\n\nfunction getComponentClass(typeName) {\n var ComponentClass = componentTypes[typeName];\n\n if (ComponentClass) {\n return ComponentClass;\n }\n\n ComponentClass = load(typeName);\n\n ComponentClass = ComponentClass.Component || ComponentClass;\n\n if (!ComponentClass.___isComponent) {\n ComponentClass = defineComponent(ComponentClass, ComponentClass.renderer);\n }\n\n // Make the component \"type\" accessible on each component instance\n ComponentClass.prototype.___type = typeName;\n\n // eslint-disable-next-line no-constant-condition\n if (\"MARKO_DEBUG\") {\n var classNameMatch =\n /\\/([^/]+?)(?:\\/index|\\/template|)(?:\\.marko|\\.component(?:-browser)?|)$/.exec(\n typeName\n );\n var className = classNameMatch ? classNameMatch[1] : \"AnonymousComponent\";\n className = className.replace(/-(.)/g, function (g) {\n return g[1].toUpperCase();\n });\n className = className\n .replace(/\\$\\d+\\.\\d+\\.\\d+$/, \"\")\n .replace(/^[^a-z$_]/i, \"_$&\")\n .replace(/[^0-9a-z$_]+/gi, \"_\");\n className = className[0].toUpperCase() + className.slice(1);\n // eslint-disable-next-line no-unused-vars\n try {\n var OldComponentClass = ComponentClass;\n eval(\n \"ComponentClass = function \" +\n className +\n \"(id, doc) { OldComponentClass.call(this, id, doc); }\"\n );\n ComponentClass.prototype = OldComponentClass.prototype;\n } catch (e) {\n /** ignore error */\n }\n }\n\n componentTypes[typeName] = ComponentClass;\n\n return ComponentClass;\n}\n\nfunction createComponent(typeName, id) {\n var ComponentClass = getComponentClass(typeName);\n return new ComponentClass(id);\n}\n\nexports.r = register;\nexports.___getComponentClass = getComponentClass;\nexports.___createComponent = createComponent;\nexports.___isRegistered = isRegistered;\nexports.___addPendingDef = addPendingDef;\n"],"file":"index-browser.js"}
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"sources":["../../../../src/runtime/components/registry/index.js"],"names":["copyProps","require","constructorCache","Map","BaseServerComponent","createServerComponentClass","renderingLogic","renderingLogicProps","prototype","ServerComponent","createComponent","id","input","out","typeName","customEvents","scope","get","set","exports"],"mappings":"AAAA;AACA,MAAMA,SAAS,GAAGC,OAAO,CAAC,uBAAD,CAAzB;AACA,MAAMC,gBAAgB,GAAG,IAAIC,GAAJ,EAAzB;AACA,MAAMC,mBAAmB,GAAGH,OAAO,CAAC,oBAAD,CAAnC;;AAEA,SAASI,0BAAT,CAAoCC,cAApC,EAAoD;AAClD,MAAIC,mBAAmB;AACrB,SAAOD,cAAP,KAA0B,UAA1B;AACIA,EAAAA,cAAc,CAACE,SADnB;AAEIF,EAAAA,cAHN;;AAKA,QAAMG,eAAN,SAA8BL,mBAA9B,CAAkD;;AAElDJ,EAAAA,SAAS,CAACO,mBAAD,EAAsBE,eAAe,CAACD,SAAtC,CAAT;;AAEA,SAAOC,eAAP;AACD;AACD,SAASC,eAAT;AACEJ,cADF;AAEEK,EAFF;AAGEC,KAHF;AAIEC,GAJF;AAKEC,QALF;AAMEC,YANF;AAOEC,KAPF;AAQE;AACA,MAAIP,eAAJ;;AAEA,MAAIH,cAAJ,EAAoB;AAClBG,IAAAA,eAAe,GAAGP,gBAAgB,CAACe,GAAjB,CAAqBX,cAArB,CAAlB;;AAEA,QAAI,CAACG,eAAL,EAAsB;AACpBA,MAAAA,eAAe,GAAGJ,0BAA0B,CAACC,cAAD,CAA5C;AACAJ,MAAAA,gBAAgB,CAACgB,GAAjB,CAAqBZ,cAArB,EAAqCG,eAArC;AACD;AACF,GAPD,MAOO;AACLA,IAAAA,eAAe,GAAGL,mBAAlB;AACD;;AAED,SAAO,IAAIK,eAAJ,CAAoBE,EAApB,EAAwBC,KAAxB,EAA+BC,GAA/B,EAAoCC,QAApC,EAA8CC,YAA9C,EAA4DC,KAA5D,CAAP;AACD;;AAEDG,OAAO,IAAP,GAAsB,IAAtB;AACAA,OAAO,IAAP,GAA6BT,eAA7B","sourcesContent":["\"use strict\";\nconst copyProps = require(\"raptor-util/copyProps\");\nconst constructorCache = new Map();\nconst BaseServerComponent = require(\"../ServerComponent\");\n\nfunction createServerComponentClass(renderingLogic) {\n var renderingLogicProps =\n typeof renderingLogic === \"function\"\n ? renderingLogic.prototype\n : renderingLogic;\n\n class ServerComponent extends BaseServerComponent {}\n\n copyProps(renderingLogicProps, ServerComponent.prototype);\n\n return ServerComponent;\n}\nfunction createComponent(\n renderingLogic,\n id,\n input,\n out,\n typeName,\n customEvents,\n scope\n) {\n let ServerComponent;\n\n if (renderingLogic) {\n ServerComponent = constructorCache.get(renderingLogic);\n\n if (!ServerComponent) {\n ServerComponent = createServerComponentClass(renderingLogic);\n constructorCache.set(renderingLogic, ServerComponent);\n }\n } else {\n ServerComponent = BaseServerComponent;\n }\n\n return new ServerComponent(id, input, out, typeName, customEvents, scope);\n}\n\nexports.___isServer = true;\nexports.___createComponent = createComponent;\n"],"file":"index.js"}
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"sources":["../../../src/runtime/components/renderer.js"],"names":["componentsUtil","require","componentLookup","ComponentsContext","getComponentsContext","registry","copyProps","isServer","beginComponent","endComponent","COMPONENT_BEGIN_ASYNC_ADDED_KEY","resolveComponentKey","key","parentComponentDef","substring","id","trackAsyncComponents","out","isSync","global","on","handleBeginAsync","handleBeginDetachedAsync","event","parentOut","asyncOut","componentsContext","undefined","c","createRendererFunc","templateRenderFunc","componentProps","renderingLogic","onInput","typeName","t","isSplit","s","isImplicitComponent","i","shouldApplySplitMixins","d","Error","renderer","input","globalComponentsContext","component","isRerender","isExisting","customEvents","ownerComponentDef","ownerComponentId","toString","destroy","renderingLogicProps","prototype","constructor","shouldUpdate","componentDef","module","exports"],"mappings":"aAAA,IAAIA,cAAc,GAAGC,OAAO,CAAC,QAAD,CAA5B;AACA,IAAIC,eAAe,GAAGF,cAAc,GAApC;;AAEA,IAAIG,iBAAiB,GAAGF,OAAO,CAAC,qBAAD,CAA/B;AACA,IAAIG,oBAAoB,GAAGD,iBAAiB,GAA5C;AACA,IAAIE,QAAQ,GAAGJ,OAAO,CAAC,YAAD,CAAtB;AACA,IAAIK,SAAS,GAAGL,OAAO,CAAC,uBAAD,CAAvB;AACA,IAAIM,QAAQ,GAAGP,cAAc,IAAd,KAA+B,IAA9C;AACA,IAAIQ,cAAc,GAAGP,OAAO,CAAC,kBAAD,CAA5B;AACA,IAAIQ,YAAY,GAAGR,OAAO,CAAC,gBAAD,CAA1B;;AAEA,IAAIS,+BAA+B,GAAG,KAAtC;;AAEA,SAASC,mBAAT,CAA6BC,GAA7B,EAAkCC,kBAAlC,EAAsD;AACpD,MAAID,GAAG,CAAC,CAAD,CAAH,KAAW,GAAf,EAAoB;AAClB,WAAOA,GAAG,CAACE,SAAJ,CAAc,CAAd,CAAP;AACD,GAFD,MAEO;AACL,WAAOD,kBAAkB,CAACE,EAAnB,GAAwB,GAAxB,GAA8BF,kBAAkB,IAAlB,CAA8BD,GAA9B,CAArC;AACD;AACF;;AAED,SAASI,oBAAT,CAA8BC,GAA9B,EAAmC;AACjC,MAAIA,GAAG,CAACC,MAAJ,MAAgBD,GAAG,CAACE,MAAJ,CAAWT,+BAAX,CAApB,EAAiE;AAC/D;AACD;;AAEDO,EAAAA,GAAG,CAACG,EAAJ,CAAO,YAAP,EAAqBC,gBAArB;AACAJ,EAAAA,GAAG,CAACG,EAAJ,CAAO,oBAAP,EAA6BE,wBAA7B;AACAL,EAAAA,GAAG,CAACE,MAAJ,CAAWT,+BAAX,IAA8C,IAA9C;AACD;;AAED,SAASW,gBAAT,CAA0BE,KAA1B,EAAiC;AAC/B,MAAIC,S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B,KAAzB;AACAA,UAAAA,SAAS,CAACW,YAAV,CAAuBb,KAAvB,EAA8BE,SAAS,GAAvC,MAAsD,KAFxD;AAGE;AACA;AACA;AACA;AACA7B,YAAAA,GAAG,IAAH,CAAyB6B,SAAzB;AACAD,YAAAA,uBAAuB,IAAvB,CAAkD9B,EAAlD,IAAwD,IAAxD;AACA+B,YAAAA,SAAS,GAAT,GANA,CAMsB;AACtB;AACD;AACF;AACF;;AAEDA,MAAAA,SAAS,GAAT,GAAsB7B,GAAG,CAACE,MAA1B;AACA2B,MAAAA,SAAS,IAAT,CAAwB7B,GAAxB;AACD;;AAED,QAAIyC,YAAY,GAAGlD,cAAc;AAC/BkB,IAAAA,iBAD+B;AAE/BoB,IAAAA,SAF+B;AAG/BlC,IAAAA,GAH+B;AAI/BsC,IAAAA,iBAJ+B;AAK/Bd,IAAAA,OAL+B;AAM/BE,IAAAA,mBAN+B,CAAjC;;;AASAoB,IAAAA,YAAY,IAAZ,GAA6BV,UAA7B;;AAEA;AACA;AACAlB,IAAAA,kBAAkB;AAChBc,IAAAA,KADgB;AAEhB3B,IAAAA,GAFgB;AAGhByC,IAAAA,YAHgB;AAIhBZ,IAAAA,SAJgB;AAKhBA,IAAAA,SAAS,IALO,CAAlB;;;AAQArC,IAAAA,YAAY,CAACQ,GAAD,EAAMyC,YAAN,CAAZ;AACAhC,IAAAA,iBAAiB,GAAjB,GAAoCb,kBAApC;AACD,GArJD;AAsJD;;AAED8C,MAAM,CAACC,OAAP,GAAiB/B,kBAAjB","sourcesContent":["var componentsUtil = require(\"./util\");\nvar componentLookup = componentsUtil.___componentLookup;\n\nvar ComponentsContext = require(\"./ComponentsContext\");\nvar getComponentsContext = ComponentsContext.___getComponentsContext;\nvar registry = require(\"./registry\");\nvar copyProps = require(\"raptor-util/copyProps\");\nvar isServer = componentsUtil.___isServer === true;\nvar beginComponent = require(\"./beginComponent\");\nvar endComponent = require(\"./endComponent\");\n\nvar COMPONENT_BEGIN_ASYNC_ADDED_KEY = \"$wa\";\n\nfunction resolveComponentKey(key, parentComponentDef) {\n if (key[0] === \"#\") {\n return key.substring(1);\n } else {\n return parentComponentDef.id + \"-\" + parentComponentDef.___nextKey(key);\n }\n}\n\nfunction trackAsyncComponents(out) {\n if (out.isSync() || out.global[COMPONENT_BEGIN_ASYNC_ADDED_KEY]) {\n return;\n }\n\n out.on(\"beginAsync\", handleBeginAsync);\n out.on(\"beginDetachedAsync\", handleBeginDetachedAsync);\n out.global[COMPONENT_BEGIN_ASYNC_ADDED_KEY] = true;\n}\n\nfunction handleBeginAsync(event) {\n var parentOut = event.parentOut;\n var asyncOut = event.out;\n var componentsContext = parentOut.___components;\n\n if (componentsContext !== undefined) {\n // We are going to start a nested ComponentsContext\n asyncOut.___components = new ComponentsContext(asyncOut, componentsContext);\n }\n // Carry along the component arguments\n asyncOut.c(\n parentOut.___assignedComponentDef,\n parentOut.___assignedKey,\n parentOut.___assignedCustomEvents\n );\n}\n\nfunction handleBeginDetachedAsync(event) {\n var asyncOut = event.out;\n handleBeginAsync(event);\n asyncOut.on(\"beginAsync\", handleBeginAsync);\n asyncOut.on(\"beginDetachedAsync\", handleBeginDetachedAsync);\n}\n\nfunction createRendererFunc(\n templateRenderFunc,\n componentProps,\n renderingLogic\n) {\n var onInput = renderingLogic && renderingLogic.onInput;\n var typeName = componentProps.t;\n var isSplit = componentProps.s === true;\n var isImplicitComponent = componentProps.i === true;\n\n var shouldApplySplitMixins = renderingLogic && isSplit;\n\n // eslint-disable-next-line no-constant-condition\n if (\"MARKO_DEBUG\") {\n if (!componentProps.d) {\n throw new Error(\n \"Component was compiled in a different NODE_ENV than the Marko runtime is using.\"\n );\n }\n } else if (componentProps.d) {\n throw new Error(\"Runtime/NODE_ENV Mismatch\");\n }\n\n return function renderer(input, out) {\n trackAsyncComponents(out);\n\n var componentsContext = getComponentsContext(out);\n var globalComponentsContext = componentsContext.___globalContext;\n\n var component = globalComponentsContext.___rerenderComponent;\n var isRerender = component !== undefined;\n var id;\n var isExisting;\n var customEvents;\n var parentComponentDef = componentsContext.___componentDef;\n var ownerComponentDef = out.___assignedComponentDef;\n var ownerComponentId = ownerComponentDef && ownerComponentDef.id;\n var key = out.___assignedKey;\n\n if (component) {\n // If component is provided then we are currently rendering\n // the top-level UI component as part of a re-render\n id = component.id; // We will use the ID of the component being re-rendered\n isExisting = true; // This is a re-render so we know the component is already in the DOM\n globalComponentsContext.___rerenderComponent = null;\n } else {\n // Otherwise, we are rendering a nested UI component. We will need\n // to match up the UI component with the component already in the\n // DOM (if any) so we will need to resolve the component ID from\n // the assigned key. We also need to handle any custom event bindings\n // that were provided.\n if (parentComponentDef) {\n // console.log('componentArgs:', componentArgs);\n customEvents = out.___assignedCustomEvents;\n\n if (key != null) {\n id = resolveComponentKey(key.toString(), parentComponentDef);\n } else {\n id = parentComponentDef.___nextComponentId();\n }\n } else {\n id = globalComponentsContext.___nextComponentId();\n }\n }\n\n if (isServer) {\n // If we are rendering on the server then things are simplier since\n // we don't need to match up the UI component with a previously\n // rendered component already mounted to the DOM. We also create\n // a lightweight ServerComponent\n component = registry.___createComponent(\n renderingLogic,\n id,\n input,\n out,\n typeName,\n customEvents,\n ownerComponentId\n );\n\n // This is the final input after running the lifecycle methods.\n // We will be passing the input to the template for the `input` param\n input = component.___updatedInput;\n } else {\n if (!component) {\n if (\n isRerender &&\n (component = componentLookup[id]) &&\n component.___type !== typeName\n ) {\n // Destroy the existing component since\n component.destroy();\n component = undefined;\n }\n\n if (component) {\n isExisting = true;\n } else {\n isExisting = false;\n // We need to create a new instance of the component\n component = registry.___createComponent(typeName, id);\n\n if (shouldApplySplitMixins === true) {\n shouldApplySplitMixins = false;\n\n var renderingLogicProps =\n typeof renderingLogic == \"function\"\n ? renderingLogic.prototype\n : renderingLogic;\n\n copyProps(renderingLogicProps, component.constructor.prototype);\n }\n }\n\n // Set this flag to prevent the component from being queued for update\n // based on the new input. The component is about to be rerendered\n // so we don't want to queue it up as a result of calling `setInput()`\n component.___updateQueued = true;\n\n if (customEvents !== undefined) {\n component.___setCustomEvents(customEvents, ownerComponentId);\n }\n\n if (isExisting === false) {\n component.___emitCreate(input, out);\n }\n\n input = component.___setInput(input, onInput, out);\n\n if (isExisting === true) {\n if (\n component.___isDirty === false ||\n component.shouldUpdate(input, component.___state) === false\n ) {\n // We put a placeholder element in the output stream to ensure that the existing\n // DOM node is matched up correctly when using morphdom. We flag the VElement\n // node to track that it is a preserve marker\n out.___preserveComponent(component);\n globalComponentsContext.___renderedComponentsById[id] = true;\n component.___reset(); // The component is no longer dirty so reset internal flags\n return;\n }\n }\n }\n\n component.___global = out.global;\n component.___emitRender(out);\n }\n\n var componentDef = beginComponent(\n componentsContext,\n component,\n key,\n ownerComponentDef,\n isSplit,\n isImplicitComponent\n );\n\n componentDef.___isExisting = isExisting;\n\n // Render the template associated with the component using the final template\n // data that we constructed\n templateRenderFunc(\n input,\n out,\n componentDef,\n component,\n component.___rawState\n );\n\n endComponent(out, componentDef);\n componentsContext.___componentDef = parentComponentDef;\n };\n}\n\nmodule.exports = createRendererFunc;\n"],"file":"renderer.js"}
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"sources":["../../../src/runtime/components/update-manager.js"],"names":["updatesScheduled","batchStack","unbatchedQueue","setImmediate","require","updateUnbatchedComponents","length","updateComponents","scheduleUpdates","queue","i","component","batchUpdate","func","batch","push","queueComponentUpdate","batchStackLen","exports"],"mappings":"AAAA;;AAEA,IAAIA,gBAAgB,GAAG,KAAvB;AACA,IAAIC,UAAU,GAAG,EAAjB,C,CAAqB;AACrB,IAAIC,cAAc,GAAG,EAArB,C,CAAyB;;AAEzB,IAAIC,YAAY,GAAGC,OAAO,CAAC,iBAAD,CAAP,IAAnB;;AAEA;AACA;AACA;AACA;AACA,SAASC,yBAAT,GAAqC;AACnC,MAAIH,cAAc,CAACI,MAAnB,EAA2B;AACzB,QAAI;AACFC,MAAAA,gBAAgB,CAACL,cAAD,CAAhB;AACD,KAFD,SAEU;AACR;AACA;AACA;AAC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,MAAAA,KAAK,IAAL,GAAiB,CAACH,SAAD,CAAjB;AACD;AACF,GAfD,MAeO;AACL;AACA;AACA;AACAH,IAAAA,eAAe;AACfN,IAAAA,cAAc,CAACa,IAAf,CAAoBJ,SAApB;AACD;AACF;;AAEDO,OAAO,IAAP,GAAkCF,oBAAlC;AACAE,OAAO,IAAP,GAAyBN,WAAzB","sourcesContent":["\"use strict\";\n\nvar updatesScheduled = false;\nvar batchStack = []; // A stack of batched updates\nvar unbatchedQueue = []; // Used for scheduled batched updates\n\nvar setImmediate = require(\"../setImmediate\").___setImmediate;\n\n/**\n * This function is called when we schedule the update of \"unbatched\"\n * updates to components.\n */\nfunction updateUnbatchedComponents() {\n if (unbatchedQueue.length) {\n try {\n updateComponents(unbatchedQueue);\n } finally {\n // Reset the flag now that this scheduled batch update\n // is complete so that we can later schedule another\n // batched update if needed\n updatesScheduled = false;\n }\n }\n}\n\nfunction scheduleUpdates() {\n if (updatesScheduled) {\n // We have already scheduled a batched update for the\n // nextTick so nothing to do\n return;\n }\n\n updatesScheduled = true;\n\n setImmediate(updateUnbatchedComponents);\n}\n\nfunction updateComponents(queue) {\n // Loop over the components in the queue and update them.\n // NOTE: It is okay if the queue grows during the iteration\n // since we will still get to them at the end\n for (var i = 0; i < queue.length; i++) {\n var component = queue[i];\n component.___update(); // Do the actual component update\n }\n\n // Clear out the queue by setting the length to zero\n queue.length = 0;\n}\n\nfunction batchUpdate(func) {\n // If the batched update stack is empty then this\n // is the outer batched update. After the outer\n // batched update completes we invoke the \"afterUpdate\"\n // event listeners.\n var batch = {\n ___queue: null\n };\n\n batchStack.push(batch);\n\n try {\n func();\n } finally {\n try {\n // Update all of the components that where queued up\n // in this batch (if any)\n if (batch.___queue) {\n updateComponents(batch.___queue);\n }\n } finally {\n // Now that we have completed the update of all the components\n // in this batch we need to remove it off the top of the stack\n batchStack.length--;\n }\n }\n}\n\nfunction queueComponentUpdate(component) {\n var batchStackLen = batchStack.length;\n\n if (batchStackLen) {\n // When a batch update is started we push a new batch on to a stack.\n // If the stack has a non-zero length then we know that a batch has\n // been started so we can just queue the component on the top batch. When\n // the batch is ended this component will be updated.\n var batch = batchStack[batchStackLen - 1];\n\n // We default the batch queue to null to avoid creating an Array instance\n // unnecessarily. If it is null then we create a new Array, otherwise\n // we push it onto the existing Array queue\n if (batch.___queue) {\n batch.___queue.push(component);\n } else {\n batch.___queue = [component];\n }\n } else {\n // We are not within a batched update. We need to schedule a batch update\n // for the nextTick (if that hasn't been done already) and we will\n // add the component to the unbatched queued\n scheduleUpdates();\n unbatchedQueue.push(component);\n }\n}\n\nexports.___queueComponentUpdate = queueComponentUpdate;\nexports.___batchUpdate = batchUpdate;\n"],"file":"update-manager.js"}
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"sources":["../../../../src/runtime/components/util/index-browser.js"],"names":["domData","require","componentsByDOMNode","keysByDOMNode","vElementsByDOMNode","vPropsByDOMNode","markoUID","window","$MUID","i","runtimeId","componentLookup","EMPTY_OBJECT","getComponentForEl","el","host","node","ownerDocument","document","getElementById","component","vElement","fragment","endNode","startNode","get","previousSibling","parentNode","destroyComponentForNode","componentToDestroy","id","destroyNodeRecursive","nodeType","key","test","curChild","firstChild","nextSibling","nextComponentId","nextComponentIdProvider","attachBubblingEvent","componentDef","handlerMethodName","isOnce","extraArgs","componentId","getMarkoPropsFromEl","virtualProps","getAttribute","set","JSON","parse","normalizeComponentKey","parentId","replace","addComponentRootToKeyedElements","keyedElements","rootNode","repeatedElementsForKey","exports"],"mappings":"aAAA,IAAIA,OAAO,GAAGC,OAAO,CAAC,aAAD,CAArB;AACA,IAAIC,mBAAmB,GAAGF,OAAO,GAAjC;AACA,IAAIG,aAAa,GAAGH,OAAO,IAA3B;AACA,IAAII,kBAAkB,GAAGJ,OAAO,IAAhC;AACA,IAAIK,eAAe,GAAGL,OAAO,IAA7B;AACA,IAAIM,QAAQ,GAAGC,MAAM,CAACC,KAAP,KAAiBD,MAAM,CAACC,KAAP,GAAe,EAA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yB,sBAAsB,GAAIF,aAAa,CAACvB,GAAD,CAAb;AAC5BuB,IAAAA,aAAa,CAACvB,GAAD,CAAb,IAAsB,EADxB;AAEAyB,IAAAA,sBAAsB,CAACb,WAAD,CAAtB,GAAsCY,QAAtC;AACD,GAJD,MAIO;AACLD,IAAAA,aAAa,CAACvB,GAAD,CAAb,GAAqBwB,QAArB;AACD;AACF;;AAED;;;;;;;;;;;;;;;;;;;;;;;;;;;AA2BAE,OAAO,IAAP,GAAuBjD,SAAvB;AACAiD,OAAO,GAAP,GAA6BhD,eAA7B;AACAgD,OAAO,IAAP,GAA+B9C,iBAA/B;AACA8C,OAAO,IAAP,GAAqC/B,uBAArC;AACA+B,OAAO,GAAP,GAAkC5B,oBAAlC;AACA4B,OAAO,IAAP,GAAqCpB,uBAArC;AACAoB,OAAO,IAAP,GAAiCnB,mBAAjC;AACAmB,OAAO,IAAP,GAAiCb,mBAAjC;AACAa,OAAO,IAAP,GAA6CJ,+BAA7C;AACAI,OAAO,IAAP,GAAmCP,qBAAnC","sourcesContent":["var domData = require(\"../dom-data\");\nvar componentsByDOMNode = domData.___componentByDOMNode;\nvar keysByDOMNode = domData.___keyByDOMNode;\nvar vElementsByDOMNode = domData.___vElementByDOMNode;\nvar vPropsByDOMNode = domData.___vPropsByDOMNode;\nvar markoUID = window.$MUID || (window.$MUID = { i: 0 });\nvar runtimeId = markoUID.i++;\n\nvar componentLookup = {};\n\nvar EMPTY_OBJECT = {};\n\nfunction getComponentForEl(el, host) {\n var node =\n typeof el == \"string\"\n ? ((host ? host.ownerDocument : host) || document).getElementById(el)\n : el;\n var component;\n var vElement;\n\n while (node) {\n if (node.fragment) {\n if (node.fragment.endNode === node) {\n node = node.fragment.startNode;\n } else {\n node = node.fragment;\n component = componentsByDOMNode.get(node);\n }\n } else if ((vElement = vElementsByDOMNode.get(node))) {\n component = vElement.___ownerComponent;\n }\n\n if (component) {\n return component;\n }\n\n node = node.previousSibling || node.parentNode;\n }\n}\n\nfunction destroyComponentForNode(node) {\n var componentToDestroy = componentsByDOMNode.get(node.fragment || node);\n if (componentToDestroy) {\n componentToDestroy.___destroyShallow();\n delete componentLookup[componentToDestroy.id];\n }\n}\nfunction destroyNodeRecursive(node, component) {\n destroyComponentForNode(node);\n if (node.nodeType === 1 || node.nodeType === 12) {\n var key;\n\n if (component && (key = keysByDOMNode.get(node))) {\n if (node === component.___keyedElements[key]) {\n if (componentsByDOMNode.get(node) && /\\[\\]$/.test(key)) {\n delete component.___keyedElements[key][\n componentsByDOMNode.get(node).id\n ];\n } else {\n delete component.___keyedElements[key];\n }\n }\n }\n\n var curChild = node.firstChild;\n while (curChild && curChild !== node.endNode) {\n destroyNodeRecursive(curChild, component);\n curChild = curChild.nextSibling;\n }\n }\n}\n\nfunction nextComponentId() {\n // Each component will get an ID that is unique across all loaded\n // marko runtimes. This allows multiple instances of marko to be\n // loaded in the same window and they should all place nice\n // together\n return \"c\" + markoUID.i++;\n}\n\nfunction nextComponentIdProvider() {\n return nextComponentId;\n}\n\nfunction attachBubblingEvent(\n componentDef,\n handlerMethodName,\n isOnce,\n extraArgs\n) {\n if (handlerMethodName) {\n var componentId = componentDef.id;\n if (extraArgs) {\n return [handlerMethodName, componentId, isOnce, extraArgs];\n } else {\n return [handlerMethodName, componentId, isOnce];\n }\n }\n}\n\nfunction getMarkoPropsFromEl(el) {\n var vElement = vElementsByDOMNode.get(el);\n var virtualProps;\n\n if (vElement) {\n virtualProps = vElement.___properties;\n } else {\n virtualProps = vPropsByDOMNode.get(el);\n if (!virtualProps) {\n virtualProps = el.getAttribute(\"data-marko\");\n vPropsByDOMNode.set(\n el,\n (virtualProps = virtualProps ? JSON.parse(virtualProps) : EMPTY_OBJECT)\n );\n }\n }\n\n return virtualProps;\n}\n\nfunction normalizeComponentKey(key, parentId) {\n if (key[0] === \"#\") {\n key = key.replace(\"#\" + parentId + \"-\", \"\");\n }\n return key;\n}\n\nfunction addComponentRootToKeyedElements(\n keyedElements,\n key,\n rootNode,\n componentId\n) {\n if (/\\[\\]$/.test(key)) {\n var repeatedElementsForKey = (keyedElements[key] =\n keyedElements[key] || {});\n repeatedElementsForKey[componentId] = rootNode;\n } else {\n keyedElements[key] = rootNode;\n }\n}\n\n// eslint-disable-next-line no-constant-condition\nif (\"MARKO_DEBUG\") {\n var warnNodeRemoved = function (event) {\n var fragment = event.target.fragment;\n if (fragment) {\n var baseError = new Error(\n \"Fragment boundary marker removed. This will cause an error when the fragment is updated.\"\n );\n fragment.___markersRemovedError = function (message) {\n var error = new Error(message + \" Boundary markers missing.\");\n\n baseError.stack = baseError.stack.replace(/.*warnNodeRemoved.*\\n/, \"\");\n\n // eslint-disable-next-line no-console\n console.warn(baseError);\n return error;\n };\n }\n };\n exports.___startDOMManipulationWarning = function (host) {\n host.addEventListener(\"DOMNodeRemoved\", warnNodeRemoved);\n };\n exports.___stopDOMManipulationWarning = function (host) {\n host.removeEventListener(\"DOMNodeRemoved\", warnNodeRemoved);\n };\n}\n\nexports.___runtimeId = runtimeId;\nexports.___componentLookup = componentLookup;\nexports.___getComponentForEl = getComponentForEl;\nexports.___destroyComponentForNode = destroyComponentForNode;\nexports.___destroyNodeRecursive = destroyNodeRecursive;\nexports.___nextComponentIdProvider = nextComponentIdProvider;\nexports.___attachBubblingEvent = attachBubblingEvent;\nexports.___getMarkoPropsFromEl = getMarkoPropsFromEl;\nexports.___addComponentRootToKeyedElements = addComponentRootToKeyedElements;\nexports.___normalizeComponentKey = normalizeComponentKey;\n"],"file":"index-browser.js"}
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"sources":["../../../../src/runtime/components/util/index.js"],"names":["FLAG_WILL_RERENDER_IN_BROWSER","nextComponentIdProvider","out","prefix","global","componentIdPrefix","widgetIdPrefix","nextId","nextComponentId","attachBubblingEvent","componentDef","handlerMethodName","isOnce","extraArgs","component","eventIndex","push","id","exports","noop"],"mappings":"aAAA,IAAIA,6BAA6B,GAAG,CAApC;AACA;;AAEA,SAASC,uBAAT,CAAiCC,GAA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AApD;;AAEA","sourcesContent":["var FLAG_WILL_RERENDER_IN_BROWSER = 1;\n// var FLAG_HAS_RENDER_BODY = 2;\n\nfunction nextComponentIdProvider(out) {\n var prefix = out.global.componentIdPrefix || out.global.widgetIdPrefix || \"s\"; // \"s\" is for server (we use \"b\" for the browser)\n var nextId = 0;\n\n return function nextComponentId() {\n return prefix + nextId++;\n };\n}\n\nfunction attachBubblingEvent(\n componentDef,\n handlerMethodName,\n isOnce,\n extraArgs\n) {\n if (handlerMethodName) {\n if (extraArgs) {\n var component = componentDef.___component;\n var eventIndex = component.___bubblingDomEventsExtraArgsCount++;\n\n // If we are not going to be doing a rerender in the browser\n // then we need to actually store the extra args with the UI component\n // so that they will be serialized down to the browser.\n // If we are rerendering in the browser then we just need to\n // increment ___bubblingDomEventsExtraArgsCount to keep track of\n // where the extra args will be found when the UI component is\n // rerendered in the browser\n\n if (!(componentDef.___flags & FLAG_WILL_RERENDER_IN_BROWSER)) {\n if (eventIndex === 0) {\n component.___bubblingDomEvents = [extraArgs];\n } else {\n component.___bubblingDomEvents.push(extraArgs);\n }\n }\n\n return (\n handlerMethodName +\n \" \" +\n componentDef.id +\n \" \" +\n isOnce +\n \" \" +\n eventIndex\n );\n } else {\n return handlerMethodName + \" \" + componentDef.id + \" \" + isOnce;\n }\n }\n}\n\nexports.___nextComponentIdProvider = nextComponentIdProvider;\nexports.___isServer = true;\nexports.___attachBubblingEvent = attachBubblingEvent;\nexports.___destroyComponentForNode = function noop() {};\nexports.___destroyNodeRecursive = function noop() {};\n\n// eslint-disable-next-line no-constant-condition\nif (\"MARKO_DEBUG\") {\n exports.___startDOMManipulationWarning = function noop() {};\n exports.___stopDOMManipulationWarning = function noop() {};\n}\n"],"file":"index.js"}
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"sources":["../../src/runtime/createOut.js"],"names":["actualCreateOut","setCreateOut","createOutFunc","createOut","globalData","module","exports"],"mappings":"aAAA,IAAIA,eAAJ;;AAEA,SAASC,YAAT,CAAsBC,aAAtB,EAAqC;AACnCF,EAAAA,eAAe,GAAGE,aAAlB;AACD;;AAED,SAASC,SAAT,CAAmBC,UAAnB,EAA+B;AAC7B,SAAOJ,eAAe,CAACI,UAAD,CAAtB;AACD;;AAEDD,SAAS,IAAT,GAA4BF,YAA5B;;AAEAI,MAAM,CAACC,OAAP,GAAiBH,SAAjB","sourcesContent":["var actualCreateOut;\n\nfunction setCreateOut(createOutFunc) {\n actualCreateOut = createOutFunc;\n}\n\nfunction createOut(globalData) {\n return actualCreateOut(globalData);\n}\n\ncreateOut.___setCreateOut = setCreateOut;\n\nmodule.exports = createOut;\n"],"file":"createOut.js"}
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"sources":["../../src/runtime/dom-insert.js"],"names":["extend","require","componentsUtil","destroyComponentForNode","destroyNodeRecursive","helpers","insertBefore","insertAfter","removeChild","resolveEl","el","elId","document","getElementById","Error","beforeRemove","referenceEl","module","exports","target","getEl","afterInsert","appendTo","prependTo","firstChild","replace","parentNode","replaceChildrenOf","curChild","nextSibling","innerHTML"],"mappings":"aAAA,IAAIA,MAAM,GAAGC,OAAO,CAAC,oBAAD,CAApB;AACA,IAAIC,cAAc,GAAGD,OAAO,CAAC,mBAAD,CAA5B;AACA,IAAIE,uBAAuB,GAAGD,cAAc,IAA5C;AACA,IAAIE,oBAAoB,GAAGF,cAAc,GAAzC;AACA,IAAIG,OAAO,GAAGJ,OAAO,CAAC,yBAAD,CAArB;;AAEA,IAAIK,YAAY,GAAGD,OAAO,IAA1B;AACA,IAAIE,WAAW,GAAGF,OAAO,IAAzB;AACA,IAAIG,WAAW,GAAGH,OAAO,IAAzB;;AAEA,SAASI,SAAT,CAAmBC,EAAnB,EAAuB;AACrB,MAAI,OAAOA,EAAP,IAAa,QAAjB,EAA2B;AACzB,QAAIC,IAAI,GAAGD,EAAX;AACAA,IAAAA,EAAE,GAAGE,QAAQ,CAACC,cAAT,CAAwBF,IAAxB,CAAL;AACA,QAAI,CAACD,EA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AAD,EAAOL,WAAP,CAAlB;AACD,KA/CY,EAAT,CAAN;;AAiDD,CAlDD","sourcesContent":["var extend = require(\"raptor-util/extend\");\nvar componentsUtil = require(\"./components/util\");\nvar destroyComponentForNode = componentsUtil.___destroyComponentForNode;\nvar destroyNodeRecursive = componentsUtil.___destroyNodeRecursive;\nvar helpers = require(\"./vdom/morphdom/helpers\");\n\nvar insertBefore = helpers.___insertBefore;\nvar insertAfter = helpers.___insertAfter;\nvar removeChild = helpers.___removeChild;\n\nfunction resolveEl(el) {\n if (typeof el == \"string\") {\n var elId = el;\n el = document.getElementById(elId);\n if (!el) {\n throw Error(\"Not found: \" + elId);\n }\n }\n return el;\n}\n\nfunction beforeRemove(referenceEl) {\n destroyNodeRecursive(referenceEl);\n destroyComponentForNode(referenceEl);\n}\n\nmodule.exports = function (target, getEl, afterInsert) {\n extend(target, {\n appendTo: function (referenceEl) {\n referenceEl = resolveEl(referenceEl);\n var el = getEl(this, referenceEl);\n insertBefore(el, null, referenceEl);\n return afterInsert(this, referenceEl);\n },\n prependTo: function (referenceEl) {\n referenceEl = resolveEl(referenceEl);\n var el = getEl(this, referenceEl);\n insertBefore(el, referenceEl.firstChild || null, referenceEl);\n return afterInsert(this, referenceEl);\n },\n replace: function (referenceEl) {\n referenceEl = resolveEl(referenceEl);\n var el = getEl(this, referenceEl);\n beforeRemove(referenceEl);\n insertBefore(el, referenceEl, referenceEl.parentNode);\n removeChild(referenceEl);\n return afterInsert(this, referenceEl);\n },\n replaceChildrenOf: function (referenceEl) {\n referenceEl = resolveEl(referenceEl);\n var el = getEl(this, referenceEl);\n\n var curChild = referenceEl.firstChild;\n while (curChild) {\n var nextSibling = curChild.nextSibling; // Just in case the DOM changes while removing\n beforeRemove(curChild);\n curChild = nextSibling;\n }\n\n referenceEl.innerHTML = \"\";\n insertBefore(el, null, referenceEl);\n return afterInsert(this, referenceEl);\n },\n insertBefore: function (referenceEl) {\n referenceEl = resolveEl(referenceEl);\n var el = getEl(this, referenceEl);\n insertBefore(el, referenceEl, referenceEl.parentNode);\n return afterInsert(this, referenceEl);\n },\n insertAfter: function (referenceEl) {\n referenceEl = resolveEl(referenceEl);\n var el = getEl(this, referenceEl);\n insertAfter(el, referenceEl, referenceEl.parentNode);\n return afterInsert(this, referenceEl);\n }\n });\n};\n"],"file":"dom-insert.js"}
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"sources":["../../src/runtime/events.js"],"names":["EventEmitter","require","module","exports"],"mappings":"aAAA,IAAIA,YAAY,GAAGC,OAAO,CAAC,cAAD,CAA1B;AACAC,MAAM,CAACC,OAAP,GAAiB,IAAIH,YAAJ,EAAjB","sourcesContent":["var EventEmitter = require(\"events-light\");\nmodule.exports = new EventEmitter();\n"],"file":"events.js"}
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"sources":["../../../src/runtime/helpers/_change-case.js"],"names":["camelToDashLookup","Object","create","dashToCamelLookup","exports","camelToDashCase","name","nameDashed","replace","toLowerCase","dashToCamelCase","nameCamel","matchToUpperCase","_","char","toUpperCase"],"mappings":"AAAA;;AAEA,IAAIA,iBAAiB,GAAGC,MAAM,CAACC,MAAP,CAAc,IAAd,CAAxB;AACA,IAAIC,iBAAiB,GAAGF,MAAM,CAACC,MAAP,CAAc,IAAd,CAAxB;;AAEA;AACA;AACA;AACAE,OAAO,IAAP,GAA6B,SAASC,eAAT,CAAyBC,IAAzB,EAA+B;AAC1D,MAAIC,UAAU,GAAGP,iBAAiB,CAACM,IAAD,CAAlC;AACA,MAAI,CAACC,UAAL,EAAiB;AACfA,IAAAA,UAAU,GAAGP,iBAAiB,CAACM,IAAD,CAAjB,GAA0BA,IAAI;AACxCE,IAAAA,OADoC,CAC5B,UAD4B,EAChB,KADgB;AAEpCC,IAAAA,WAFoC,EAAvC;;AAIA,QAAIF,UAAU,KAAKD,IAAnB,EAAyB;AACvBH,MAAAA,iBAAiB,CAACI,UAAD,CAAjB,GAAgCD,IAAhC;AACD;AACF;;AAED,SAAOC,UAAP;AACD,CAbD;;AAeA;AACA;AACA;AACAH,OAAO,IAAP,GAA6B,SAASM,eAAT,CAAyBJ,IAAzB,EAA+B;AAC1D,MAAIK,SAAS,GAAGR,iBAAiB,CAACG,IAAD,CAAjC;AACA,MAAI,CAACK,SAAL,EAAgB;AACdA,IAAAA,SAAS,GAAGR,iBAAiB,CAACG,IAAD,CAAjB,GAA0BA,IAAI,CAACE,OAAL;AACpC,eADoC;AAEpCI,IAAAA,gBAFoC,CAAtC;;;AAKA,QAAID,SAAS,KAAKL,IAAlB,EAAwB;AACtBN,MAAAA,iBAAiB,CAACW,SAAD,CAAjB,GAA+BL,IAA/B;AACD;AACF;;AAED,SAAOK,SAAP;AACD,CAdD;;AAgBA,SAASC,gBAAT,CAA0BC,CAA1B,EAA6BC,IAA7B,EAAmC;AACjC,SAAOA,IAAI,CAACC,WAAL,EAAP;AACD","sourcesContent":["\"use strict\";\n\nvar camelToDashLookup = Object.create(null);\nvar dashToCamelLookup = Object.create(null);\n\n/**\n * Helper for converting camelCase to dash-case.\n */\nexports.___camelToDashCase = function camelToDashCase(name) {\n var nameDashed = camelToDashLookup[name];\n if (!nameDashed) {\n nameDashed = camelToDashLookup[name] = name\n .replace(/([A-Z])/g, \"-$1\")\n .toLowerCase();\n\n if (nameDashed !== name) {\n dashToCamelLookup[nameDashed] = name;\n }\n }\n\n return nameDashed;\n};\n\n/**\n * Helper for converting dash-case to camelCase.\n */\nexports.___dashToCamelCase = function dashToCamelCase(name) {\n var nameCamel = dashToCamelLookup[name];\n if (!nameCamel) {\n nameCamel = dashToCamelLookup[name] = name.replace(\n /-([a-z])/g,\n matchToUpperCase\n );\n\n if (nameCamel !== name) {\n camelToDashLookup[nameCamel] = name;\n }\n }\n\n return nameCamel;\n};\n\nfunction matchToUpperCase(_, char) {\n return char.toUpperCase();\n}\n"],"file":"_change-case.js"}
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"sources":["../../../src/runtime/helpers/assign.js"],"names":["hasOwnProperty","Object","prototype","module","exports","assign","into","arguments","i","length","source","k","call"],"mappings":"AAAA;;AAEA,IAAIA,cAAc,GAAGC,MAAM,CAACC,SAAP,CAAiBF,cAAtC;;AAEA;AACA;AACA;AACAG,MAAM,CAACC,OAAP,GAAiB,SAASC,MAAT,GAAkB;AACjC,MAAIC,IAAI,GAAGC,SAAS,CAAC,CAAD,CAApB;AACA,OAAK,IAAIC,CAAC,GAAG,CAAb,EAAgBA,CAAC,GAAGD,SAAS,CAACE,MAA9B,EAAsCD,CAAC,EAAvC,EAA2C;AACzC,QAAIE,MAAM,GAAGH,SAAS,CAACC,CAAD,CAAtB;AACA,QAAIE,MAAM,IAAI,IAAd,EAAoB;AAClB,WAAK,IAAIC,CAAT,IAAcD,MAAd,EAAsB;AACpB,YAAIV,cAAc,CAACY,IAAf,CAAoBF,MAApB,EAA4BC,CAA5B,CAAJ,EAAoC;AAClCL,UAAAA,IAAI,CAACK,CAAD,CAAJ,GAAUD,MAAM,CAACC,CAAD,CAAhB;AACD;AACF;AACF;AACF;AACD,SAAOL,IAAP;AACD,CAbD","sourcesContent":["\"use strict\";\n\nvar hasOwnProperty = Object.prototype.hasOwnProperty;\n\n/**\n * Merges object properties\n */\nmodule.exports = function assign() {\n var into = arguments[0];\n for (var i = 1; i < arguments.length; i++) {\n var source = arguments[i];\n if (source != null) {\n for (var k in source) {\n if (hasOwnProperty.call(source, k)) {\n into[k] = source[k];\n }\n }\n }\n }\n return into;\n};\n"],"file":"assign.js"}
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"sources":["../../../src/runtime/helpers/class-value.js"],"names":["module","exports","classHelper","arg","result","sep","Array","isArray","i","len","length","value","key"],"mappings":"AAAA;;AAEAA,MAAM,CAACC,OAAP,GAAiB,SAASC,WAAT,CAAqBC,GAArB,EAA0B;AACzC,UAAQ,OAAOA,GAAf;AACE,SAAK,QAAL;AACE,aAAOA,GAAG,IAAI,IAAd;AACF,SAAK,QAAL;AACE,UAAIC,MAAM,GAAG,EAAb;AACA,UAAIC,GAAG,GAAG,EAAV;;AAEA,UAAIC,KAAK,CAACC,OAAN,CAAcJ,GAAd,CAAJ,EAAwB;AACtB,aAAK,IAAIK,CAAC,GAAG,CAAR,EAAWC,GAAG,GAAGN,GAAG,CAACO,MAA1B,EAAkCF,CAAC,GAAGC,GAAtC,EAA2CD,CAAC,EAA5C,EAAgD;AAC9C,cAAIG,KAAK,GAAGT,WAAW,CAACC,GAAG,CAACK,CAAD,CAAJ,CAAvB;AACA,cAAIG,KAAJ,EAAW;AACTP,YAAAA,MAAM,IAAIC,GAAG,GAAGM,KAAhB;AACAN,YAAAA,GAAG,GAAG,GAAN;AACD;AACF;AACF,OARD,MAQO;AACL,aAAK,IAAIO,GAAT,IAAgBT,GAAhB,EAAqB;AACnB,cAAIA,GAAG,CAACS,GAAD,CAAP,EAAc;AACZR,YAAAA,MAAM,IAAIC,GAAG,GAAGO,GAAhB;AACAP,YAAAA,GAAG,GAAG,GAAN;AACD;AACF;AACF;;AAED,aAAOD,MAAM,IAAI,IAAjB;;AAEF;AACE,aAAO,IAAP,CA3BJ;;AA6BD,CA9BD","sourcesContent":["\"use strict\";\n\nmodule.exports = function classHelper(arg) {\n switch (typeof arg) {\n case \"string\":\n return arg || null;\n case \"object\":\n var result = \"\";\n var sep = \"\";\n\n if (Array.isArray(arg)) {\n for (var i = 0, len = arg.length; i < len; i++) {\n var value = classHelper(arg[i]);\n if (value) {\n result += sep + value;\n sep = \" \";\n }\n }\n } else {\n for (var key in arg) {\n if (arg[key]) {\n result += sep + key;\n sep = \" \";\n }\n }\n }\n\n return result || null;\n\n default:\n return null;\n }\n};\n"],"file":"class-value.js"}
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"sources":["../../../src/runtime/helpers/dynamic-tag.js"],"names":["changeCase","require","ComponentsContext","getComponentsContext","ComponentDef","w10NOOP","NOOP","RENDER_BODY_TO_JSON","FLAG_WILL_RERENDER_IN_BROWSER","IS_SERVER","window","module","exports","dynamicTag","out","tag","getAttrs","renderBody","args","props","componentDef","key","customEvents","default","attrs","component","addEvents","attrsToCamelCase","renderer","_","render","c","isFn","flags","willRerender","isW10NOOP","preserve","bf","componentsContext","parentComponentDef","globalContext","id","toJSON","apply","concat","ef","error","result","len","length","event","i","d"],"mappings":"AAAA;;;AAGA,IAAIA,UAAU,GAAGC,OAAO,CAAC,gBAAD,CAAxB;AACA,IAAIC,iBAAiB,GAAGD,OAAO,CAAC,iCAAD,CAA/B;AACA,IAAIE,oBAAoB,GAAGD,iBAAiB,GAA5C;AACA,IAAIE,YAAY,GAAGH,OAAO,CAAC,4BAAD,CAA1B;AACA,IAAII,OAAO,GAAGJ,OAAO,CAAC,kBAAD,CAAP,CAA4BK,IAA1C;AACA,IAAIC,mBAAmB,GAAG,YAAY;AACpC,SAAOF,OAAP;AACD,CAFD;;AAIA,IAAIG,6BAA6B,GAAG,CAApC;AACA;AACA,IAAIC,SAAS,GAAG,OAAOC,MAAP,KAAkB,WAAlC;;AAEA;AACA;AACA;AACAC,MAAM,CAACC,OAAP,GAAiB,SAASC,UAAT;AACfC,GADe;AAEfC,GAFe;AAGfC,QAHe;AAIfC,UAJe;AAKfC,IALe;AAMfC,KANe;AAOfC,YAPe;AAQfC,GARe;AASfC,YATe;AAUf;AACA,MAAIP,GAAJ,EAAS;AACP,QAAIA,GAAG,CAACQ,OAAR,EAAiB;AACfR,MAAAA,GAAG,GAAGA,GAAG,CAACQ,OAAV;AACD;;AAED,QAAIC,KAAK,GAAGR,QAAQ,IAAIA,QAAQ,EAAhC;AACA,QAAIS,SAAS,GAAGL,YAAY,IAAIA,YAAY,GAA5C;AACA,QAAI,OAAOL,GAAP,KAAe,QAAnB,EAA6B;AAC3B,UAAIE,UAAJ,EAAgB;AACdH,QAAAA,GAAG,IAAH;AACEC,QAAAA,GADF;AAEES,QAAAA,KAFF;AAGEH,QAAAA,GAHF;AAIED,QAAAA,YAJF;AAKEM,QAAAA,SAAS,CAACN,YAAD,EAAeE,YAAf,EAA6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AAEEA,IAAAA,YAAY,IAAZ,GAAwBZ,6BAL5B;;AAOAS,IAAAA,UAAU,CAACH,GAAD,CAAV;AACAA,IAAAA,GAAG,CAAC+B,EAAJ;AACD;AACF,CAzHD;;AA2HA,SAASlB,gBAAT,CAA0BH,KAA1B,EAAiC;AAC/B,MAAIuB,MAAM,GAAG,EAAb;;AAEA,OAAK,IAAI1B,GAAT,IAAgBG,KAAhB,EAAuB;AACrBuB,IAAAA,MAAM,CAAC/C,UAAU,IAAV,CAA8BqB,GAA9B,CAAD,CAAN,GAA6CG,KAAK,CAACH,GAAD,CAAlD;AACD;;AAED,SAAO0B,MAAP;AACD;;AAED,SAASrB,SAAT,CAAmBN,YAAnB,EAAiCE,YAAjC,EAA+CH,KAA/C,EAAsD;AACpD,MAAI6B,GAAG,GAAG1B,YAAY,GAAGA,YAAY,CAAC2B,MAAhB,GAAyB,CAA/C;;AAEA,MAAID,GAAG,KAAK,CAAZ,EAAe;AACb,WAAO7B,KAAP;AACD;;AAED,MAAI4B,MAAM,GAAG5B,KAAK,IAAI,EAAtB;AACA,MAAI+B,KAAJ;;AAEA,OAAK,IAAIC,CAAC,GAAGH,GAAb,EAAkBG,CAAC,EAAnB,GAAyB;AACvBD,IAAAA,KAAK,GAAG5B,YAAY,CAAC6B,CAAD,CAApB;AACAJ,IAAAA,MAAM,CAAC,OAAOG,KAAK,CAAC,CAAD,CAAb,CAAN,GAA0B9B,YAAY,CAACgC,CAAb;AACxBF,IAAAA,KAAK,CAAC,CAAD,CADmB;AAExBA,IAAAA,KAAK,CAAC,CAAD,CAFmB;AAGxBA,IAAAA,KAAK,CAAC,CAAD,CAHmB;AAIxBA,IAAAA,KAAK,CAAC,CAAD,CAJmB,CAA1B;;AAMD;;AAED,SAAOH,MAAP;AACD","sourcesContent":["\"use strict\";\n\nvar complain = \"MARKO_DEBUG\" && require(\"complain\");\nvar changeCase = require(\"./_change-case\");\nvar ComponentsContext = require(\"../components/ComponentsContext\");\nvar getComponentsContext = ComponentsContext.___getComponentsContext;\nvar ComponentDef = require(\"../components/ComponentDef\");\nvar w10NOOP = require(\"warp10/constants\").NOOP;\nvar RENDER_BODY_TO_JSON = function () {\n return w10NOOP;\n};\n\nvar FLAG_WILL_RERENDER_IN_BROWSER = 1;\n// var FLAG_HAS_RENDER_BODY = 2;\nvar IS_SERVER = typeof window === \"undefined\";\n\n/**\n * Helper to render a dynamic tag\n */\nmodule.exports = function dynamicTag(\n out,\n tag,\n getAttrs,\n renderBody,\n args,\n props,\n componentDef,\n key,\n customEvents\n) {\n if (tag) {\n if (tag.default) {\n tag = tag.default;\n }\n\n var attrs = getAttrs && getAttrs();\n var component = componentDef && componentDef.___component;\n if (typeof tag === \"string\") {\n if (renderBody) {\n out.___beginElementDynamic(\n tag,\n attrs,\n key,\n componentDef,\n addEvents(componentDef, customEvents, props)\n );\n renderBody(out);\n out.___endElement();\n } else {\n out.___elementDynamic(\n tag,\n attrs,\n key,\n componentDef,\n addEvents(componentDef, customEvents, props)\n );\n }\n } else {\n if (attrs == null) {\n attrs = { renderBody: renderBody };\n } else if (typeof attrs === \"object\") {\n attrs = attrsToCamelCase(attrs);\n if (renderBody) {\n attrs.renderBody = renderBody;\n }\n }\n\n var renderer =\n tag._ ||\n tag.render ||\n (tag.renderer && tag.renderer.renderer) ||\n tag.renderer;\n\n // eslint-disable-next-line no-constant-condition\n if (\"MARKO_DEBUG\") {\n if (tag.renderer && tag.renderer.renderer === renderer) {\n complain(\n \"An object with a 'renderer' was passed to the dynamic tag, but renderer was another template.\"\n );\n }\n }\n\n if (renderer) {\n out.c(componentDef, key, customEvents);\n renderer(attrs, out);\n out.___assignedComponentDef = null;\n } else {\n var render = (tag && tag.renderBody) || tag;\n var isFn = typeof render === \"function\";\n\n // eslint-disable-next-line no-constant-condition\n if (\"MARKO_DEBUG\") {\n if (render.safeHTML || render.toHTML) {\n throw new Error(\n \"Using `<include(x)/>` or the `<${dynamic}/>` tags with a `{ safeHTML: ... }` object is no longer supported. Use the unescaped text placeholder syntax instead.\"\n );\n }\n }\n if (isFn) {\n var flags = componentDef ? componentDef.___flags : 0;\n var willRerender = flags & FLAG_WILL_RERENDER_IN_BROWSER;\n var isW10NOOP = render === w10NOOP;\n var preserve = IS_SERVER ? willRerender : isW10NOOP;\n out.bf(key, component, preserve);\n if (!isW10NOOP && isFn) {\n var componentsContext = getComponentsContext(out);\n var parentComponentDef = componentsContext.___componentDef;\n var globalContext = componentsContext.___globalContext;\n componentsContext.___componentDef = new ComponentDef(\n component,\n parentComponentDef.id + \"-\" + parentComponentDef.___nextKey(key),\n globalContext\n );\n render.toJSON = RENDER_BODY_TO_JSON;\n\n if (args) {\n render.apply(null, [out].concat(args, attrs));\n } else {\n render(out, attrs);\n }\n\n componentsContext.___componentDef = parentComponentDef;\n }\n out.ef();\n } else {\n out.error(\"Invalid dynamic tag value\");\n }\n }\n }\n } else if (renderBody) {\n out.bf(\n key,\n component,\n IS_SERVER &&\n componentDef &&\n componentDef.___flags & FLAG_WILL_RERENDER_IN_BROWSER\n );\n renderBody(out);\n out.ef();\n }\n};\n\nfunction attrsToCamelCase(attrs) {\n var result = {};\n\n for (var key in attrs) {\n result[changeCase.___dashToCamelCase(key)] = attrs[key];\n }\n\n return result;\n}\n\nfunction addEvents(componentDef, customEvents, props) {\n var len = customEvents ? customEvents.length : 0;\n\n if (len === 0) {\n return props;\n }\n\n var result = props || {};\n var event;\n\n for (var i = len; i--; ) {\n event = customEvents[i];\n result[\"on\" + event[0]] = componentDef.d(\n event[0],\n event[1],\n event[2],\n event[3]\n );\n }\n\n return result;\n}\n"],"file":"dynamic-tag.js"}
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"sources":["../../../src/runtime/helpers/load-nested-tag.js"],"names":["module","exports","loadNestedTagHelper","targetProperty","isRepeated","input","parent","existingArray","push"],"mappings":"AAAA;;AAEAA,MAAM,CAACC,OAAP,GAAiB,SAASC,mBAAT,CAA6BC,cAA7B,EAA6CC,UAA7C,EAAyD;AACxE,SAAO,UAAUC,KAAV,EAAiBC,MAAjB,EAAyB;AAC9B;AACA,QAAIF,UAAJ,EAAgB;AACd,UAAIG,aAAa,GAAGD,MAAM,CAACH,cAAD,CAA1B;AACA,UAAII,aAAJ,EAAmB;AACjBA,QAAAA,aAAa,CAACC,IAAd,CAAmBH,KAAnB;AACD,OAFD,MAEO;AACLC,QAAAA,MAAM,CAACH,cAAD,CAAN,GAAyB,CAACE,KAAD,CAAzB;AACD;AACF,KAPD,MAOO;AACLC,MAAAA,MAAM,CAACH,cAAD,CAAN,GAAyBE,KAAzB;AACD;AACF,GAZD;AAaD,CAdD","sourcesContent":["\"use strict\";\n\nmodule.exports = function loadNestedTagHelper(targetProperty, isRepeated) {\n return function (input, parent) {\n // If we are nested tag then we do not have a renderer\n if (isRepeated) {\n var existingArray = parent[targetProperty];\n if (existingArray) {\n existingArray.push(input);\n } else {\n parent[targetProperty] = [input];\n }\n } else {\n parent[targetProperty] = input;\n }\n };\n};\n"],"file":"load-nested-tag.js"}
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"sources":["../../../src/runtime/helpers/merge.js"],"names":["hasOwnProperty","Object","prototype","module","exports","merge","into","source","k","call"],"mappings":"aAAA,IAAIA,cAAc,GAAGC,MAAM,CAACC,SAAP,CAAiBF,cAAtC;;AAEA;AACA;AACA;AACAG,MAAM,CAACC,OAAP,GAAiB,SAASC,KAAT,CAAeC,IAAf,EAAqBC,MAArB,EAA6B;AAC5C,OAAK,IAAIC,CAAT,IAAcD,MAAd,EAAsB;AACpB,QAAIP,cAAc,CAACS,IAAf,CAAoBF,MAApB,EAA4BC,CAA5B,KAAkC,CAACR,cAAc,CAACS,IAAf,CAAoBH,IAApB,EAA0BE,CAA1B,CAAvC,EAAqE;AACnEF,MAAAA,IAAI,CAACE,CAAD,CAAJ,GAAUD,MAAM,CAACC,CAAD,CAAhB;AACD;AACF;AACD,SAAOF,IAAP;AACD,CAPD","sourcesContent":["var hasOwnProperty = Object.prototype.hasOwnProperty;\n\n/**\n * Merges object properties\n */\nmodule.exports = function merge(into, source) {\n for (var k in source) {\n if (hasOwnProperty.call(source, k) && !hasOwnProperty.call(into, k)) {\n into[k] = source[k];\n }\n }\n return into;\n};\n"],"file":"merge.js"}
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"sources":["../../../src/runtime/helpers/render-tag.js"],"names":["module","exports","renderTagHelper","handler","input","out","componentDef","key","customEvents","c","_","render","renderer"],"mappings":"AAAA;;AAEA;AACA;AACA;AACAA,MAAM,CAACC,OAAP,GAAiB,SAASC,eAAT;AACfC,OADe;AAEfC,KAFe;AAGfC,GAHe;AAIfC,YAJe;AAKfC,GALe;AAMfC,YANe;AAOf;AACAH,EAAAA,GAAG,CAACI,CAAJ,CAAMH,YAAN,EAAoBC,GAApB,EAAyBC,YAAzB;AACA,GAACL,OAAO,CAACO,CAAR,KAAcP,OAAO,CAACO,CAAR,GAAYP,OAAO,CAACQ,MAAR,IAAkBR,OAAO,CAACS,QAA1B,IAAsCT,OAAhE,CAAD;AACEC,EAAAA,KADF;AAEEC,EAAAA,GAFF;;AAIAA,EAAAA,GAAG,GAAH,GAA8B,IAA9B;AACD,CAdD","sourcesContent":["\"use strict\";\n\n/**\n * Helper to render a custom tag\n */\nmodule.exports = function renderTagHelper(\n handler,\n input,\n out,\n componentDef,\n key,\n customEvents\n) {\n out.c(componentDef, key, customEvents);\n (handler._ || (handler._ = handler.render || handler.renderer || handler))(\n input,\n out\n );\n out.___assignedComponentDef = null;\n};\n"],"file":"render-tag.js"}
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"sources":["../../../src/runtime/helpers/style-value.js"],"names":["changeCase","require","module","exports","styleHelper","style","type","styles","Array","isArray","i","len","length","next","name","value"],"mappings":"AAAA;;AAEA,IAAIA,UAAU,GAAGC,OAAO,CAAC,gBAAD,CAAxB;;AAEA;AACA;AACA;AACAC,MAAM,CAACC,OAAP,GAAiB,SAASC,WAAT,CAAqBC,KAArB,EAA4B;AAC3C,MAAI,CAACA,KAAL,EAAY;AACV,WAAO,IAAP;AACD;;AAED,MAAIC,IAAI,GAAG,OAAOD,KAAlB;;AAEA,MAAIC,IAAI,KAAK,QAAb,EAAuB;AACrB,QAAIC,MAAM,GAAG,EAAb;;AAEA,QAAIC,KAAK,CAACC,OAAN,CAAcJ,KAAd,CAAJ,EAA0B;AACxB,WAAK,IAAIK,CAAC,GAAG,CAAR,EAAWC,GAAG,GAAGN,KAAK,CAACO,MAA5B,EAAoCF,CAAC,GAAGC,GAAxC,EAA6CD,CAAC,EAA9C,EAAkD;AAChD,YAAIG,IAAI,GAAGT,WAAW,CAACC,KAAK,CAACK,CAAD,CAAN,CAAtB;AACA,YAAIG,IAAJ,EAAUN,MAAM,IAAIM,IAAI,IAAIA,IAAI,CAACA,IAAI,CAACD,MAAL,GAAc,CAAf,CAAJ,KAA0B,GAA1B,GAAgC,GAAhC,GAAsC,EAA1C,CAAd;AACX;AACF,KALD,MAKO,IAAIN,IAAI,KAAK,QAAb,EAAuB;AAC5B,WAAK,IAAIQ,IAAT,IAAiBT,KAAjB,EAAwB;AACtB,YAAIU,KAAK,GAAGV,KAAK,CAACS,IAAD,CAAjB;AACA,YAAIC,KAAK,IAAI,IAAT,IAAiBA,KAAK,KAAK,KAA/B,EAAsC;AACpC,cAAI,OAAOA,KAAP,KAAiB,QAAjB,IAA6BA,KAAjC,EAAwC;AACtCA,YAAAA,KAAK,IAAI,IAAT;AACD;;AAEDR,UAAAA,MAAM,IAAIP,UAAU,IAAV,CAA8Bc,IAA9B,IAAsC,GAAtC,GAA4CC,KAA5C,GAAoD,GAA9D;AACD;AACF;AACF;;AAED,WAAOR,MAAM,IAAI,IAAjB;AACD;;AAED,SAAOF,KAAP;AACD,CAhCD","sourcesContent":["\"use strict\";\n\nvar changeCase = require(\"./_change-case\");\n\n/**\n * Helper for generating the string for a style attribute\n */\nmodule.exports = function styleHelper(style) {\n if (!style) {\n return null;\n }\n\n var type = typeof style;\n\n if (type !== \"string\") {\n var styles = \"\";\n\n if (Array.isArray(style)) {\n for (var i = 0, len = style.length; i < len; i++) {\n var next = styleHelper(style[i]);\n if (next) styles += next + (next[next.length - 1] !== \";\" ? \";\" : \"\");\n }\n } else if (type === \"object\") {\n for (var name in style) {\n var value = style[name];\n if (value != null && value !== false) {\n if (typeof value === \"number\" && value) {\n value += \"px\";\n }\n\n styles += changeCase.___camelToDashCase(name) + \":\" + value + \";\";\n }\n }\n }\n\n return styles || null;\n }\n\n return style;\n};\n"],"file":"style-value.js"}
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"sources":["../../../src/runtime/helpers/to-string.js"],"names":["module","exports","value"],"mappings":"AAAA;;AAEAA,MAAM,CAACC,OAAP,GAAiB,UAAUC,KAAV,EAAiB;AAChC,SAAOA,KAAK,IAAI,IAAT,GAAgB,EAAhB,GAAqBA,KAAK,GAAG,EAApC;AACD,CAFD","sourcesContent":["\"use strict\";\n\nmodule.exports = function (value) {\n return value == null ? \"\" : value + \"\";\n};\n"],"file":"to-string.js"}
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"sources":["../../../src/runtime/html/AsyncStream.js"],"names":["EventEmitter","require","StringWriter","BufferedWriter","RenderResult","attrsHelper","markoAttr","escapeXmlHelper","parseHTML","escapeXmlOrNullish","x","escapeXmlString","selfClosingTags","noop","voidWriter","write","script","merge","clear","get","toString","State","root","stream","writer","events","finished","escapeEndingComment","text","replace","AsyncStream","global","parentOut","Error","finalGlobal","attributes","originalStream","state","_state","on","runtimeId","_ended","_remaining","_lastCount","_last","undefined","_parentOut","data","_sync","_stack","name","_timeoutId","_node","_elStack","DEFAULT_TIMEOUT","INCLUDE_STACK","process","env","NODE_ENV","enableAsyncStackTrace","proto","prototype","constructor","document","sync","isSync","str","getOutput","_result","beginAsync","options","currentWriter","newWriter","newStream","next","timeout","last","setTimeout","error","emit","out","_doFinish","end","remaining","_flushNext","_emitLast","timeoutId","clearTimeout","_handleChildDone","childOut","nextWriter","nextStream","event","callback","onLast","once","lastArray","push","i","length","lastCallback","type","arg","arguments","apply","removeListener","prependListener","pipe","e","stack","getNonMarkoStack","JSON","stringify","message","flush","scheduleFlush","createOut","newOut","bind","tagName","elementAttrs","key","componentDef","props","voidElements","indexOf","svgElements","element","openTagOnly","beginElement","endElement","pop","comment","bf","component","preserve","ef","host","node","nextEl","fragment","html","doc","ownerDocument","nextSibling","createDocumentFragment","appendChild","then","fn","fnErr","promise","Promise","resolve","reject","result","catch","c","customEvents","w","module","exports","split","slice","filter","line","test","join"],"mappings":"AAAA;AACA,IAAIA,YAAY,GAAGC,OAAO,CAAC,cAAD,CAA1B;AACA,IAAIC,YAAY,GAAGD,OAAO,CAAC,gBAAD,CAA1B;AACA,IAAIE,cAAc,GAAGF,OAAO,CAAC,kBAAD,CAA5B;AACA,IAAIG,YAAY,GAAGH,OAAO,CAAC,iBAAD,CAA1B;AACA,IAAII,WAAW,GAAGJ,OAAO,CAAC,iBAAD,CAAzB;AACA,IAAIK,SAAS,GAAGL,OAAO,CAAC,sBAAD,CAAvB;AACA,IAAIM,eAAe,GAAGN,OAAO,CAAC,sBAAD,CAA7B;AACA,IAAIO,SAAS,GAAGP,OAAO,CAAC,oBAAD,CAAvB;AACA,IAAIQ,kBAAkB,GAAGF,eAAe,CAACG,CAAzC;AACA,IAAIC,eAAe,GAAGJ,eAAe,IAArC;AACA,IAAIK,eAAe,GAAGX,OAAO,CAAC,mBAAD,CAA7B;;AAEA,SAASY,IAAT,GAAgB,CAAE;;AAElB,IAAIC,UAAU,GAAG;AACfC,EAAAA,KAAK,EAAEF,IADQ;AAEfG,EAAAA,MAAM,EAAEH,IAFO;AAGfI,EAAAA,KAAK,EAAEJ,IAHQ;AAIfK,EAAAA,KAAK,EAAEL,IAJQ;AAKfM,EAAAA,GAAG,EAAE,YAAY;AACf,WAAO,EAAP;AACD,GAPc;AAQfC,EAAAA,QAAQ,EAAE,YAAY;AACpB,WAAO,EAAP;AACD,GAVc,EAAjB;;;AAaA,SAASC,KAAT,C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AO,CAACC,OAAR,CAAgBF,OAAhB,EAAyBH,IAAzB,CAA8BC,EAA9B,EAAkCC,KAAlC,CAAP;AACD,GAnhBkC;;AAqhBnCM,EAAAA,KAAK,EAAE,UAAUN,KAAV,EAAiB;AACtB,WAAO,KAAKF,IAAL,CAAUtG,SAAV,EAAqBwG,KAArB,CAAP;AACD,GAvhBkC;;AAyhBnCO,EAAAA,CAAC,EAAE,UAAUlC,YAAV,EAAwBD,GAAxB,EAA6BoC,YAA7B,EAA2C;AAC5C,cAA+BnC,YAA/B;AACA,cAAsBD,GAAtB;AACA,eAA+BoC,YAA/B;AACD,GA7hBkC,EAArC;;;AAgiBA;AACAjG,KAAK,CAACkG,CAAN,GAAUlG,KAAK,CAAC7C,KAAhB;AACA6C,KAAK,IAAL,GAAsBA,KAAK,CAACsE,UAA5B;;AAEA6B,MAAM,CAACC,OAAP,GAAiBlI,WAAjB;;AAEA,SAASgF,gBAAT,CAA0BhC,KAA1B,EAAiC;AAC/B,SAAOA,KAAK,CAAC+B,KAAN;AACJzF,EAAAA,QADI;AAEJ6I,EAAAA,KAFI,CAEE,IAFF;AAGJC,EAAAA,KAHI,CAGE,CAHF;AAIJC,EAAAA,MAJI,CAIG,CAAAC,IAAI,KAAI,CAAC,0BAA0BC,IAA1B,CAA+BD,IAA/B,CAJZ;AAKJE,EAAAA,IALI,CAKC,IALD,CAAP;AAMD","sourcesContent":["\"use strict\";\nvar EventEmitter = require(\"events-light\");\nvar StringWriter = require(\"./StringWriter\");\nvar BufferedWriter = require(\"./BufferedWriter\");\nvar RenderResult = require(\"../RenderResult\");\nvar attrsHelper = require(\"./helpers/attrs\");\nvar markoAttr = require(\"./helpers/data-marko\");\nvar escapeXmlHelper = require(\"./helpers/escape-xml\");\nvar parseHTML = require(\"../vdom/parse-html\");\nvar escapeXmlOrNullish = escapeXmlHelper.x;\nvar escapeXmlString = escapeXmlHelper.___escapeXML;\nvar selfClosingTags = require(\"self-closing-tags\");\n\nfunction noop() {}\n\nvar voidWriter = {\n write: noop,\n script: noop,\n merge: noop,\n clear: noop,\n get: function () {\n return [];\n },\n toString: function () {\n return \"\";\n }\n};\n\nfunction State(root, stream, writer, events) {\n this.root = root;\n this.stream = stream;\n this.writer = writer;\n this.events = events;\n\n this.finished = false;\n}\n\nfunction escapeEndingComment(text) {\n return text.replace(/-->/g, \"-->\");\n}\n\nfunction AsyncStream(global, writer, parentOut) {\n if (parentOut === null) {\n throw new Error(\"illegal state\");\n }\n var finalGlobal = (this.attributes = global || {});\n var originalStream;\n var state;\n\n if (parentOut) {\n state = parentOut._state;\n originalStream = state.stream;\n } else {\n var events = (finalGlobal.events /* deprecated */ =\n writer && writer.on ? writer : new EventEmitter());\n\n if (writer) {\n originalStream = writer;\n writer = new BufferedWriter(writer);\n } else {\n writer = originalStream = new StringWriter();\n }\n\n state = new State(this, originalStream, writer, events);\n writer.state = state;\n }\n\n finalGlobal.runtimeId = finalGlobal.runtimeId || \"M\";\n this.global = finalGlobal;\n this.stream = originalStream;\n this._state = state;\n\n this._ended = false;\n this._remaining = 1;\n this._lastCount = 0;\n this._last = undefined; // Array\n this._parentOut = parentOut;\n\n this.data = {};\n this.writer = writer;\n writer.stream = this;\n\n this._sync = false;\n this._stack = undefined;\n this.name = undefined;\n this._timeoutId = undefined;\n\n this._node = undefined;\n\n this._elStack = undefined; // Array\n\n this.___components = null; // ComponentsContext\n\n this.___assignedComponentDef = null;\n this.___assignedKey = null;\n this.___assignedCustomEvents = null;\n this.___isLast = false;\n}\n\nAsyncStream.DEFAULT_TIMEOUT = 10000;\n\n/**\n * If set to `true`, AsyncStream errors will include the full stack trace\n */\nAsyncStream.INCLUDE_STACK =\n typeof process !== \"undefined\" &&\n (!process.env.NODE_ENV ||\n process.env.NODE_ENV === \"development\" ||\n process.env.NODE_ENV === \"dev\");\n\nAsyncStream.enableAsyncStackTrace = function () {\n AsyncStream.INCLUDE_STACK = true;\n};\n\nvar proto = (AsyncStream.prototype = {\n constructor: AsyncStream,\n ___host: typeof document === \"object\" && document,\n ___isOut: true,\n\n sync: function () {\n this._sync = true;\n },\n\n isSync: function () {\n return this._sync === true;\n },\n\n write: function (str) {\n if (str != null) {\n this.writer.write(str.toString());\n }\n return this;\n },\n\n script: function (str) {\n if (str != null) {\n this.writer.script(str.toString());\n }\n return this;\n },\n\n ___getOutput: function () {\n return this._state.writer.toString();\n },\n\n /**\n * Legacy...\n */\n getOutput: function () {\n return this.___getOutput();\n },\n\n toString: function () {\n return this._state.writer.toString();\n },\n\n ___getResult: function () {\n this._result = this._result || new RenderResult(this);\n return this._result;\n },\n\n beginAsync: function (options) {\n if (this._sync) {\n throw new Error(\"beginAsync() not allowed when using renderSync()\");\n }\n\n var state = this._state;\n\n var currentWriter = this.writer;\n\n /* ┏━━━━━┓ this\n ┃ WAS ┃ ↓↑\n ┗━━━━━┛ prevWriter → currentWriter → nextWriter */\n\n var newWriter = new StringWriter();\n var newStream = new AsyncStream(this.global, currentWriter, this);\n newWriter.state = state;\n\n this.writer = newWriter;\n newWriter.stream = this;\n\n newWriter.next = currentWriter.next;\n currentWriter.next = newWriter;\n\n /* ┏━━━━━┓ newStream this\n ┃ NOW ┃ ↓↑ ↓↑\n ┗━━━━━┛ prevWriter → currentWriter → newWriter → nextWriter */\n\n var timeout;\n var name;\n\n this._remaining++;\n\n if (options != null) {\n if (typeof options === \"number\") {\n timeout = options;\n } else {\n timeout = options.timeout;\n\n if (options.last === true) {\n if (timeout == null) {\n // Don't assign a timeout to last flush fragments\n // unless it is explicitly given a timeout\n timeout = 0;\n }\n\n this._lastCount++;\n newStream.___isLast = true;\n }\n\n name = options.name;\n }\n }\n\n if (timeout == null) {\n timeout = AsyncStream.DEFAULT_TIMEOUT;\n }\n\n newStream._stack = AsyncStream.INCLUDE_STACK ? new Error() : null;\n newStream.name = name;\n\n if (timeout > 0) {\n newStream._timeoutId = setTimeout(function () {\n newStream.error(\n new Error(\n \"Async fragment \" +\n (name ? \"(\" + name + \") \" : \"\") +\n \"timed out after \" +\n timeout +\n \"ms\"\n )\n );\n }, timeout);\n }\n\n state.events.emit(\"beginAsync\", {\n out: newStream,\n parentOut: this\n });\n\n return newStream;\n },\n\n _doFinish: function () {\n var state = this._state;\n\n state.finished = true;\n\n if (state.writer.end) {\n state.writer.end();\n } else {\n state.events.emit(\"finish\", this.___getResult());\n }\n },\n\n end: function (data) {\n if (this._ended === true) {\n return;\n }\n\n this._ended = true;\n\n var remaining = --this._remaining;\n\n if (data != null) {\n this.write(data);\n }\n\n var currentWriter = this.writer;\n\n /* ┏━━━━━┓ this nextStream\n ┃ WAS ┃ ↓↑ ↓↑\n ┗━━━━━┛ currentWriter → nextWriter → futureWriter */\n\n // Prevent any more writes to the current steam\n this.writer = voidWriter;\n currentWriter.stream = null;\n\n // Flush the contents of nextWriter to the currentWriter\n this._flushNext(currentWriter);\n\n /* ┏━━━━━┓ this ╵ nextStream\n ┃ ┃ ↓ ╵ ↓↑\n ┃ NOW ┃ voidWriter ╵ currentWriter → futureWriter\n ┃ ┃ ──────────────┴────────────────────────────────\n ┗━━━━━┛ Flushed & garbage collected: nextWriter */\n\n var parentOut = this._parentOut;\n\n if (parentOut === undefined) {\n if (remaining === 0) {\n this._doFinish();\n } else if (remaining - this._lastCount === 0) {\n this._emitLast();\n }\n } else {\n var timeoutId = this._timeoutId;\n\n if (timeoutId) {\n clearTimeout(timeoutId);\n }\n\n if (remaining === 0) {\n parentOut._handleChildDone(this);\n } else if (remaining - this._lastCount === 0) {\n this._emitLast();\n }\n }\n\n return this;\n },\n\n _handleChildDone: function (childOut) {\n var remaining = --this._remaining;\n\n if (remaining === 0) {\n var parentOut = this._parentOut;\n if (parentOut === undefined) {\n this._doFinish();\n } else {\n parentOut._handleChildDone(this);\n }\n } else {\n if (childOut.___isLast) {\n this._lastCount--;\n }\n\n if (remaining - this._lastCount === 0) {\n this._emitLast();\n }\n }\n },\n\n _flushNext: function (currentWriter) {\n // It is possible that currentWriter is the\n // last writer in the chain, so let's make\n // sure there is a nextWriter to flush.\n var nextWriter = currentWriter.next;\n if (nextWriter) {\n // Flush the contents of nextWriter\n // to the currentWriter\n currentWriter.merge(nextWriter);\n\n // Remove nextWriter from the chain.\n // It has been flushed and can now be\n // garbage collected.\n currentWriter.next = nextWriter.next;\n\n // It's possible that nextWriter is the last\n // writer in the chain and its stream already\n // ended, so let's make sure nextStream exists.\n var nextStream = nextWriter.stream;\n if (nextStream) {\n // Point the nextStream to currentWriter\n nextStream.writer = currentWriter;\n currentWriter.stream = nextStream;\n }\n }\n },\n\n on: function (event, callback) {\n var state = this._state;\n\n if (event === \"finish\" && state.finished === true) {\n callback(this.___getResult());\n } else if (event === \"last\") {\n this.onLast(callback);\n } else {\n state.events.on(event, callback);\n }\n\n return this;\n },\n\n once: function (event, callback) {\n var state = this._state;\n\n if (event === \"finish\" && state.finished === true) {\n callback(this.___getResult());\n } else if (event === \"last\") {\n this.onLast(callback);\n } else {\n state.events.once(event, callback);\n }\n\n return this;\n },\n\n onLast: function (callback) {\n var lastArray = this._last;\n\n if (lastArray === undefined) {\n this._last = [callback];\n } else {\n lastArray.push(callback);\n }\n\n return this;\n },\n\n _emitLast: function () {\n if (this._last) {\n var i = 0;\n var lastArray = this._last;\n this._last = undefined;\n (function next() {\n if (i === lastArray.length) {\n return;\n }\n var lastCallback = lastArray[i++];\n lastCallback(next);\n\n if (lastCallback.length === 0) {\n next();\n }\n })();\n }\n },\n\n emit: function (type, arg) {\n var events = this._state.events;\n switch (arguments.length) {\n case 1:\n events.emit(type);\n break;\n case 2:\n events.emit(type, arg);\n break;\n default:\n events.emit.apply(events, arguments);\n break;\n }\n return this;\n },\n\n removeListener: function () {\n var events = this._state.events;\n events.removeListener.apply(events, arguments);\n return this;\n },\n\n prependListener: function () {\n var events = this._state.events;\n events.prependListener.apply(events, arguments);\n return this;\n },\n\n pipe: function (stream) {\n this._state.stream.pipe(stream);\n return this;\n },\n\n error: function (e) {\n var name = this.name;\n var stack = this._stack;\n if (stack) stack = getNonMarkoStack(stack);\n\n if (!(e instanceof Error)) {\n e = new Error(JSON.stringify(e));\n }\n\n if (name || stack) {\n e.message +=\n \"\\nRendered by\" +\n (name ? \" \" + name : \"\") +\n (stack ? \":\\n\" + stack : \"\");\n }\n try {\n this.emit(\"error\", e);\n } finally {\n // If there is no listener for the error event then it will\n // throw a new here. In order to ensure that the async fragment\n // is still properly ended we need to put the end() in a `finally`\n // block\n this.end();\n }\n\n return this;\n },\n\n flush: function () {\n var state = this._state;\n\n if (!state.finished) {\n var writer = state.writer;\n if (writer && writer.scheduleFlush) {\n writer.scheduleFlush();\n }\n }\n return this;\n },\n\n createOut: function () {\n var newOut = new AsyncStream(this.global);\n // Forward error events to the parent out.\n newOut.on(\"error\", this.emit.bind(this, \"error\"));\n this._state.events.emit(\"beginDetachedAsync\", {\n out: newOut,\n parentOut: this\n });\n return newOut;\n },\n\n ___elementDynamic: function (\n tagName,\n elementAttrs,\n key,\n componentDef,\n props\n ) {\n var str =\n \"<\" +\n tagName +\n markoAttr(this, componentDef, props, key) +\n attrsHelper(elementAttrs);\n\n if (selfClosingTags.voidElements.indexOf(tagName) !== -1) {\n str += \">\";\n } else if (selfClosingTags.svgElements.indexOf(tagName) !== -1) {\n str += \"/>\";\n } else {\n str += \"></\" + tagName + \">\";\n }\n\n this.write(str);\n },\n\n element: function (tagName, elementAttrs, openTagOnly) {\n var str = \"<\" + tagName + attrsHelper(elementAttrs) + \">\";\n\n if (openTagOnly !== true) {\n str += \"</\" + tagName + \">\";\n }\n\n this.write(str);\n },\n\n ___beginElementDynamic: function (\n name,\n elementAttrs,\n key,\n componentDef,\n props\n ) {\n var str =\n \"<\" +\n name +\n markoAttr(this, componentDef, props, key) +\n attrsHelper(elementAttrs) +\n \">\";\n\n this.write(str);\n\n if (this._elStack) {\n this._elStack.push(name);\n } else {\n this._elStack = [name];\n }\n },\n\n beginElement: function (name, elementAttrs) {\n var str = \"<\" + name + attrsHelper(elementAttrs) + \">\";\n\n this.write(str);\n\n if (this._elStack) {\n this._elStack.push(name);\n } else {\n this._elStack = [name];\n }\n },\n\n endElement: function () {\n var tagName = this._elStack.pop();\n this.write(\"</\" + tagName + \">\");\n },\n\n comment: function (str) {\n this.write(\"<!--\" + escapeEndingComment(str) + \"-->\");\n },\n\n text: function (str) {\n this.write(escapeXmlOrNullish(str));\n },\n\n bf: function (key, component, preserve) {\n if (preserve) {\n this.write(\"<!--F#\" + escapeXmlString(key) + \"-->\");\n }\n if (this._elStack) {\n this._elStack.push(preserve);\n } else {\n this._elStack = [preserve];\n }\n },\n\n ef: function () {\n var preserve = this._elStack.pop();\n if (preserve) {\n this.write(\"<!--F/-->\");\n }\n },\n\n ___getNode: function (host) {\n var node = this._node;\n\n if (!node) {\n var nextEl;\n var fragment;\n var html = this.___getOutput();\n if (!host) host = this.___host;\n var doc = host.ownerDocument || host;\n\n if (html) {\n node = parseHTML(html);\n\n if (node && node.nextSibling) {\n // If there are multiple nodes, turn it into a document fragment.\n fragment = doc.createDocumentFragment();\n\n do {\n nextEl = node.nextSibling;\n fragment.appendChild(node);\n } while ((node = nextEl));\n\n node = fragment;\n }\n }\n\n // if HTML is empty use empty document fragment (so that we're returning a valid DOM node)\n this._node = node || doc.createDocumentFragment();\n }\n return node;\n },\n\n then: function (fn, fnErr) {\n var out = this;\n var promise = new Promise(function (resolve, reject) {\n out.on(\"error\", reject);\n out.on(\"finish\", function (result) {\n resolve(result);\n });\n });\n\n return Promise.resolve(promise).then(fn, fnErr);\n },\n\n catch: function (fnErr) {\n return this.then(undefined, fnErr);\n },\n\n c: function (componentDef, key, customEvents) {\n this.___assignedComponentDef = componentDef;\n this.___assignedKey = key;\n this.___assignedCustomEvents = customEvents;\n }\n});\n\n// alias:\nproto.w = proto.write;\nproto.___endElement = proto.endElement;\n\nmodule.exports = AsyncStream;\n\nfunction getNonMarkoStack(error) {\n return error.stack\n .toString()\n .split(\"\\n\")\n .slice(1)\n .filter(line => !/\\/node_modules\\/marko\\//.test(line))\n .join(\"\\n\");\n}\n"],"file":"AsyncStream.js"}
|