@amiceli/papierjs 0.1.0 → 0.3.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/{index-e5bb90c8.js → index-bb0e67a4.js} +331 -5
- package/dist/cjs/index-bb0e67a4.js.map +1 -0
- package/dist/cjs/loader.cjs.js +2 -2
- package/dist/cjs/p-alert.cjs.entry.js +1 -1
- package/dist/cjs/p-badge.cjs.entry.js +34 -0
- package/dist/cjs/p-badge.cjs.entry.js.map +1 -0
- package/dist/cjs/p-breadcrumb-item.cjs.entry.js +35 -0
- package/dist/cjs/p-breadcrumb-item.cjs.entry.js.map +1 -0
- package/dist/cjs/p-breadcrumb.cjs.entry.js +41 -0
- package/dist/cjs/p-breadcrumb.cjs.entry.js.map +1 -0
- package/dist/cjs/p-button.cjs.entry.js +2 -2
- package/dist/cjs/p-dropdown-item.cjs.entry.js +2 -2
- package/dist/cjs/p-dropdown.cjs.entry.js +3 -3
- package/dist/cjs/p-input-text.cjs.entry.js +2 -2
- package/dist/cjs/p-leaf.cjs.entry.js +26 -0
- package/dist/cjs/p-leaf.cjs.entry.js.map +1 -0
- package/dist/cjs/p-modal.cjs.entry.js +29 -0
- package/dist/cjs/p-modal.cjs.entry.js.map +1 -0
- package/dist/cjs/p-progress-bar.cjs.entry.js +2 -2
- package/dist/cjs/papierjs.cjs.js +2 -2
- package/dist/collection/collection-manifest.json +5 -0
- package/dist/collection/components/badge/badge.css +3222 -0
- package/dist/collection/components/badge/badge.js +82 -0
- package/dist/collection/components/badge/badge.js.map +1 -0
- package/dist/collection/components/breadcrumb/breadcrumb.css +3396 -0
- package/dist/collection/components/breadcrumb/breadcrumb.js +64 -0
- package/dist/collection/components/breadcrumb/breadcrumb.js.map +1 -0
- package/dist/collection/components/breadcrumb-item/breadcrumb-item.js +97 -0
- package/dist/collection/components/breadcrumb-item/breadcrumb-item.js.map +1 -0
- package/dist/collection/components/button/button.js +1 -1
- package/dist/collection/components/dropdown/dropdown.js +2 -2
- package/dist/collection/components/dropdown-item/dropdown-item.js +1 -1
- package/dist/collection/components/input/input-text/input-text.js +1 -1
- package/dist/collection/components/leaf/leaf.css +3219 -0
- package/dist/collection/components/leaf/leaf.js +48 -0
- package/dist/collection/components/leaf/leaf.js.map +1 -0
- package/dist/collection/components/p-modal/p-modal.css +3224 -0
- package/dist/collection/components/p-modal/p-modal.js +61 -0
- package/dist/collection/components/p-modal/p-modal.js.map +1 -0
- package/dist/collection/components/p-modal/p-modal.preview.js +26 -0
- package/dist/collection/components/p-modal/p-modal.preview.js.map +1 -0
- package/dist/collection/components/progress-bar/progress-bar.js +1 -1
- package/dist/components/index.js +1 -1
- package/dist/components/{p-92aa42e7.js → p-784ab1ae.js} +294 -6
- package/dist/components/p-784ab1ae.js.map +1 -0
- package/dist/components/p-alert.js +1 -1
- package/dist/components/p-badge.d.ts +11 -0
- package/dist/components/p-badge.js +52 -0
- package/dist/components/p-badge.js.map +1 -0
- package/dist/components/p-breadcrumb-item.d.ts +11 -0
- package/dist/components/p-breadcrumb-item.js +54 -0
- package/dist/components/p-breadcrumb-item.js.map +1 -0
- package/dist/components/p-breadcrumb.d.ts +11 -0
- package/dist/components/p-breadcrumb.js +58 -0
- package/dist/components/p-breadcrumb.js.map +1 -0
- package/dist/components/p-button.js +2 -2
- package/dist/components/p-dropdown-item.js +2 -2
- package/dist/components/p-dropdown.js +3 -3
- package/dist/components/p-input-text.js +2 -2
- package/dist/components/p-leaf.d.ts +11 -0
- package/dist/components/p-leaf.js +42 -0
- package/dist/components/p-leaf.js.map +1 -0
- package/dist/components/p-modal.d.ts +11 -0
- package/dist/components/p-modal.js +48 -0
- package/dist/components/p-modal.js.map +1 -0
- package/dist/components/p-progress-bar.js +2 -2
- package/dist/esm/{index-809c10ff.js → index-d88148b4.js} +331 -6
- package/dist/esm/index-d88148b4.js.map +1 -0
- package/dist/esm/loader.js +3 -3
- package/dist/esm/p-alert.entry.js +1 -1
- package/dist/esm/p-badge.entry.js +30 -0
- package/dist/esm/p-badge.entry.js.map +1 -0
- package/dist/esm/p-breadcrumb-item.entry.js +31 -0
- package/dist/esm/p-breadcrumb-item.entry.js.map +1 -0
- package/dist/esm/p-breadcrumb.entry.js +37 -0
- package/dist/esm/p-breadcrumb.entry.js.map +1 -0
- package/dist/esm/p-button.entry.js +2 -2
- package/dist/esm/p-dropdown-item.entry.js +2 -2
- package/dist/esm/p-dropdown.entry.js +3 -3
- package/dist/esm/p-input-text.entry.js +2 -2
- package/dist/esm/p-leaf.entry.js +22 -0
- package/dist/esm/p-leaf.entry.js.map +1 -0
- package/dist/esm/p-modal.entry.js +25 -0
- package/dist/esm/p-modal.entry.js.map +1 -0
- package/dist/esm/p-progress-bar.entry.js +2 -2
- package/dist/esm/papierjs.js +3 -3
- package/dist/papierjs/p-022f2011.entry.js +2 -0
- package/dist/papierjs/p-022f2011.entry.js.map +1 -0
- package/dist/papierjs/p-1cac6dc4.entry.js +2 -0
- package/dist/papierjs/p-1cac6dc4.entry.js.map +1 -0
- package/dist/papierjs/p-2ed960c9.entry.js +2 -0
- package/dist/papierjs/p-2ed960c9.entry.js.map +1 -0
- package/dist/papierjs/p-5f857750.entry.js +2 -0
- package/dist/papierjs/p-5f857750.entry.js.map +1 -0
- package/dist/papierjs/{p-6e9110f7.entry.js → p-704b216f.entry.js} +3 -3
- package/dist/papierjs/{p-8e9a6ac4.entry.js → p-7f976699.entry.js} +2 -2
- package/dist/papierjs/{p-ce66a0db.entry.js → p-8240849e.entry.js} +2 -2
- package/dist/papierjs/p-8b96fa1d.js +3 -0
- package/dist/papierjs/p-8b96fa1d.js.map +1 -0
- package/dist/papierjs/{p-99159731.entry.js → p-ca16de19.entry.js} +2 -2
- package/dist/papierjs/{p-c3243b73.entry.js → p-d2178145.entry.js} +2 -2
- package/dist/papierjs/p-ebbd3c9d.entry.js +2 -0
- package/dist/papierjs/p-ebbd3c9d.entry.js.map +1 -0
- package/dist/papierjs/{p-de62cf76.entry.js → p-ff268801.entry.js} +2 -2
- package/dist/papierjs/papierjs.esm.js +1 -1
- package/dist/papierjs/papierjs.esm.js.map +1 -1
- package/dist/types/components/badge/badge.d.ts +9 -0
- package/dist/types/components/breadcrumb/breadcrumb.d.ts +7 -0
- package/dist/types/components/breadcrumb-item/breadcrumb-item.d.ts +8 -0
- package/dist/types/components/leaf/leaf.d.ts +5 -0
- package/dist/types/components/p-modal/p-modal.d.ts +6 -0
- package/dist/types/components/p-modal/p-modal.preview.d.ts +1 -0
- package/dist/types/components.d.ts +81 -0
- package/package.json +7 -7
- package/readme.md +14 -6
- package/dist/cjs/index-e5bb90c8.js.map +0 -1
- package/dist/components/p-92aa42e7.js.map +0 -1
- package/dist/esm/index-809c10ff.js.map +0 -1
- package/dist/papierjs/p-45914d24.js +0 -3
- package/dist/papierjs/p-45914d24.js.map +0 -1
- /package/dist/papierjs/{p-6e9110f7.entry.js.map → p-704b216f.entry.js.map} +0 -0
- /package/dist/papierjs/{p-8e9a6ac4.entry.js.map → p-7f976699.entry.js.map} +0 -0
- /package/dist/papierjs/{p-ce66a0db.entry.js.map → p-8240849e.entry.js.map} +0 -0
- /package/dist/papierjs/{p-99159731.entry.js.map → p-ca16de19.entry.js.map} +0 -0
- /package/dist/papierjs/{p-c3243b73.entry.js.map → p-d2178145.entry.js.map} +0 -0
- /package/dist/papierjs/{p-de62cf76.entry.js.map → p-ff268801.entry.js.map} +0 -0
|
@@ -0,0 +1,61 @@
|
|
|
1
|
+
import { Host, h } from "@stencil/core";
|
|
2
|
+
export class PModal {
|
|
3
|
+
constructor() {
|
|
4
|
+
this.isOpen = false;
|
|
5
|
+
}
|
|
6
|
+
open() {
|
|
7
|
+
this.isOpen = true;
|
|
8
|
+
}
|
|
9
|
+
close() {
|
|
10
|
+
this.isOpen = false;
|
|
11
|
+
}
|
|
12
|
+
render() {
|
|
13
|
+
return (h(Host, { key: '5c4e7a04c0ccd3be165ae01c0efa8872624e0ca9' }, this.isOpen && (h("div", { key: 'c3ab6740f10f5d22be2c5b71be9ec550a314eb82', class: "papier" }, h("div", { key: '2cfc871e6c9cb41e7cde854667ab724f244c991d', class: "modal" }, h("div", { key: '7bde677fa33cb292b892ddb2afe3862058abc8e0', class: "modal-bg", onClick: () => this.close() }), h("div", { key: 'bf2eb167e2212f0d4ea8cbd3c336d3d6b3f3551f', class: "modal-body" }, h("span", { key: '6d273c5b6da477fdd7b7e380e3ae480929a3344f', class: "btn-close", onClick: () => this.close() }, "X"), h("h4", { key: 'eef7c2b42a6f5ecba1888d84aaeeeb6f4ecec5ac', class: "modal-title" }, h("slot", { key: '3962a58c0b73d75da6c1a9b63d61fcd194d46680', name: "title" })), h("h5", { key: 'ac9648a3ec88e861bbcb841cb595f84af7e6b774', class: "modal-subtitle" }, h("slot", { key: '3f011e0ed1d54b7682a86cc5d9f183cd784fb0ec', name: "sub-title" })), h("p", { key: '8ebb994ada7f45643b35beb5a81cedf8c1589475', class: "modal-text" }, h("slot", { key: '6226b1b51f09af6924cfd423e9d14295b9955df0', name: "text" })), h("slot", { key: 'aa050710343d4021b526134b914a67baae20ede9' })))))));
|
|
14
|
+
}
|
|
15
|
+
static get is() { return "p-modal"; }
|
|
16
|
+
static get encapsulation() { return "shadow"; }
|
|
17
|
+
static get originalStyleUrls() {
|
|
18
|
+
return {
|
|
19
|
+
"$": ["p-modal.scss"]
|
|
20
|
+
};
|
|
21
|
+
}
|
|
22
|
+
static get styleUrls() {
|
|
23
|
+
return {
|
|
24
|
+
"$": ["p-modal.css"]
|
|
25
|
+
};
|
|
26
|
+
}
|
|
27
|
+
static get states() {
|
|
28
|
+
return {
|
|
29
|
+
"isOpen": {}
|
|
30
|
+
};
|
|
31
|
+
}
|
|
32
|
+
static get methods() {
|
|
33
|
+
return {
|
|
34
|
+
"open": {
|
|
35
|
+
"complexType": {
|
|
36
|
+
"signature": "() => Promise<void>",
|
|
37
|
+
"parameters": [],
|
|
38
|
+
"references": {},
|
|
39
|
+
"return": "Promise<void>"
|
|
40
|
+
},
|
|
41
|
+
"docs": {
|
|
42
|
+
"text": "",
|
|
43
|
+
"tags": []
|
|
44
|
+
}
|
|
45
|
+
},
|
|
46
|
+
"close": {
|
|
47
|
+
"complexType": {
|
|
48
|
+
"signature": "() => Promise<void>",
|
|
49
|
+
"parameters": [],
|
|
50
|
+
"references": {},
|
|
51
|
+
"return": "Promise<void>"
|
|
52
|
+
},
|
|
53
|
+
"docs": {
|
|
54
|
+
"text": "",
|
|
55
|
+
"tags": []
|
|
56
|
+
}
|
|
57
|
+
}
|
|
58
|
+
};
|
|
59
|
+
}
|
|
60
|
+
}
|
|
61
|
+
//# sourceMappingURL=p-modal.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"p-modal.js","sourceRoot":"","sources":["../../../src/components/p-modal/p-modal.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,IAAI,EAAE,MAAM,EAAE,KAAK,EAAE,CAAC,EAAE,MAAM,eAAe,CAAA;AAOjE,MAAM,OAAO,MAAM;IALnB;QAOI,WAAM,GAAY,KAAK,CAAA;KA8C1B;IA3CU,IAAI;QACP,IAAI,CAAC,MAAM,GAAG,IAAI,CAAA;IACtB,CAAC;IAGM,KAAK;QACR,IAAI,CAAC,MAAM,GAAG,KAAK,CAAA;IACvB,CAAC;IAED,MAAM;QACF,OAAO,CACH,EAAC,IAAI,uDACA,IAAI,CAAC,MAAM,IAAI,CACZ,4DAAK,KAAK,EAAC,QAAQ;YACf,4DAAK,KAAK,EAAC,OAAO;gBACd,4DACI,KAAK,EAAC,UAAU,EAChB,OAAO,EAAE,GAAG,EAAE,CAAC,IAAI,CAAC,KAAK,EAAE,GAC7B;gBACF,4DAAK,KAAK,EAAC,YAAY;oBACnB,6DACI,KAAK,EAAC,WAAW,EACjB,OAAO,EAAE,GAAG,EAAE,CAAC,IAAI,CAAC,KAAK,EAAE,QAGxB;oBACP,2DAAI,KAAK,EAAC,aAAa;wBACnB,6DAAM,IAAI,EAAC,OAAO,GAAG,CACpB;oBACL,2DAAI,KAAK,EAAC,gBAAgB;wBACtB,6DAAM,IAAI,EAAC,WAAW,GAAG,CACxB;oBACL,0DAAG,KAAK,EAAC,YAAY;wBACjB,6DAAM,IAAI,EAAC,MAAM,GAAG,CACpB;oBACJ,8DAAQ,CACN,CACJ,CACJ,CACT,CACE,CACV,CAAA;IACL,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CACJ","sourcesContent":["import { Component, Host, Method, State, h } from '@stencil/core'\n\n@Component({\n tag: 'p-modal',\n styleUrl: 'p-modal.scss',\n shadow: true,\n})\nexport class PModal {\n @State()\n isOpen: boolean = false\n\n @Method()\n public open() {\n this.isOpen = true\n }\n\n @Method()\n public close() {\n this.isOpen = false\n }\n\n render() {\n return (\n <Host>\n {this.isOpen && (\n <div class=\"papier\">\n <div class=\"modal\">\n <div\n class=\"modal-bg\"\n onClick={() => this.close()}\n />\n <div class=\"modal-body\">\n <span\n class=\"btn-close\"\n onClick={() => this.close()}\n >\n X\n </span>\n <h4 class=\"modal-title\">\n <slot name=\"title\" />\n </h4>\n <h5 class=\"modal-subtitle\">\n <slot name=\"sub-title\" />\n </h5>\n <p class=\"modal-text\">\n <slot name=\"text\" />\n </p>\n <slot />\n </div>\n </div>\n </div>\n )}\n </Host>\n )\n }\n}\n"]}
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
export function previewModal() {
|
|
2
|
+
const inputObserver = new MutationObserver(() => {
|
|
3
|
+
const modal = document.querySelector('#modal-1');
|
|
4
|
+
const buttonModal = document.querySelector('#open-modal-1');
|
|
5
|
+
const otherModal = document.querySelector('#modal-2');
|
|
6
|
+
const otherButton = document.querySelector('#open-modal-2');
|
|
7
|
+
const closeIt = document.querySelector('#close-it');
|
|
8
|
+
if (modal && buttonModal && otherModal && otherButton) {
|
|
9
|
+
buttonModal.addEventListener('click', () => {
|
|
10
|
+
modal.open();
|
|
11
|
+
});
|
|
12
|
+
otherButton.addEventListener('click', () => {
|
|
13
|
+
otherModal.open();
|
|
14
|
+
});
|
|
15
|
+
closeIt.addEventListener('click', () => {
|
|
16
|
+
otherModal.close();
|
|
17
|
+
});
|
|
18
|
+
inputObserver.disconnect();
|
|
19
|
+
}
|
|
20
|
+
});
|
|
21
|
+
inputObserver.observe(document.body, {
|
|
22
|
+
childList: true,
|
|
23
|
+
subtree: true,
|
|
24
|
+
});
|
|
25
|
+
}
|
|
26
|
+
//# sourceMappingURL=p-modal.preview.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"p-modal.preview.js","sourceRoot":"","sources":["../../../src/components/p-modal/p-modal.preview.ts"],"names":[],"mappings":"AAEA,MAAM,UAAU,YAAY;IACxB,MAAM,aAAa,GAAG,IAAI,gBAAgB,CAAC,GAAG,EAAE;QAC5C,MAAM,KAAK,GAAG,QAAQ,CAAC,aAAa,CAAC,UAAU,CAAsB,CAAA;QACrE,MAAM,WAAW,GAAG,QAAQ,CAAC,aAAa,CAAC,eAAe,CAAC,CAAA;QAE3D,MAAM,UAAU,GAAG,QAAQ,CAAC,aAAa,CACrC,UAAU,CACQ,CAAA;QACtB,MAAM,WAAW,GAAG,QAAQ,CAAC,aAAa,CAAC,eAAe,CAAC,CAAA;QAC3D,MAAM,OAAO,GAAG,QAAQ,CAAC,aAAa,CAAC,WAAW,CAAC,CAAA;QAEnD,IAAI,KAAK,IAAI,WAAW,IAAI,UAAU,IAAI,WAAW,EAAE,CAAC;YACpD,WAAW,CAAC,gBAAgB,CAAC,OAAO,EAAE,GAAG,EAAE;gBACvC,KAAK,CAAC,IAAI,EAAE,CAAA;YAChB,CAAC,CAAC,CAAA;YACF,WAAW,CAAC,gBAAgB,CAAC,OAAO,EAAE,GAAG,EAAE;gBACvC,UAAU,CAAC,IAAI,EAAE,CAAA;YACrB,CAAC,CAAC,CAAA;YACF,OAAO,CAAC,gBAAgB,CAAC,OAAO,EAAE,GAAG,EAAE;gBACnC,UAAU,CAAC,KAAK,EAAE,CAAA;YACtB,CAAC,CAAC,CAAA;YACF,aAAa,CAAC,UAAU,EAAE,CAAA;QAC9B,CAAC;IACL,CAAC,CAAC,CAAA;IAEF,aAAa,CAAC,OAAO,CAAC,QAAQ,CAAC,IAAI,EAAE;QACjC,SAAS,EAAE,IAAI;QACf,OAAO,EAAE,IAAI;KAChB,CAAC,CAAA;AACN,CAAC","sourcesContent":["import type { PModal } from '../../../dist/types/components/p-modal/p-modal'\n\nexport function previewModal() {\n const inputObserver = new MutationObserver(() => {\n const modal = document.querySelector('#modal-1') as unknown as PModal\n const buttonModal = document.querySelector('#open-modal-1')\n\n const otherModal = document.querySelector(\n '#modal-2',\n ) as unknown as PModal\n const otherButton = document.querySelector('#open-modal-2')\n const closeIt = document.querySelector('#close-it')\n\n if (modal && buttonModal && otherModal && otherButton) {\n buttonModal.addEventListener('click', () => {\n modal.open()\n })\n otherButton.addEventListener('click', () => {\n otherModal.open()\n })\n closeIt.addEventListener('click', () => {\n otherModal.close()\n })\n inputObserver.disconnect()\n }\n })\n\n inputObserver.observe(document.body, {\n childList: true,\n subtree: true,\n })\n}\n"]}
|
|
@@ -35,7 +35,7 @@ export class ProgressBar {
|
|
|
35
35
|
return cssClass;
|
|
36
36
|
}
|
|
37
37
|
render() {
|
|
38
|
-
return (h("div", { key: '
|
|
38
|
+
return (h("div", { key: 'b5b6f14316d2f2581fc02d2ca4c1c6fc589f9b0a', class: this.getParentClass() }, h("div", { key: '9f7c3be8aa7fd5cfa58bfedd61335594723b91ce', class: "progress" }, h("div", { key: '758ac60825e1c5ad51fc1897d9f85fa8a148194e', class: this.getClass() }, h("slot", { key: '274937e50c80c677f2da3d08981cc01b3f4731c8' })))));
|
|
39
39
|
}
|
|
40
40
|
static get is() { return "p-progress-bar"; }
|
|
41
41
|
static get encapsulation() { return "shadow"; }
|
package/dist/components/index.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
const NAMESPACE = 'papierjs';
|
|
2
|
-
const BUILD = /* papierjs */ { allRenderFn: true, appendChildSlotFix: false, asyncLoading: true, asyncQueue: false, attachStyles: true, cloneNodeFix: false, cmpDidLoad: true, cmpDidRender: false, cmpDidUnload: false, cmpDidUpdate: false, cmpShouldUpdate: false, cmpWillLoad: false, cmpWillRender: false, cmpWillUpdate: false, connectedCallback: false, constructableCSS: true, cssAnnotations: true, devTools: false, disconnectedCallback: false, element: false, event: true, experimentalScopedSlotChanges: false, experimentalSlotFixes: false, formAssociated: false, hasRenderFn: true, hostListener: true, hostListenerTarget: true, hostListenerTargetBody: false, hostListenerTargetDocument: false, hostListenerTargetParent: false, hostListenerTargetWindow: true, hotModuleReplacement: false, hydrateClientSide: false, hydrateServerSide: false, hydratedAttribute: false, hydratedClass: true, hydratedSelectorName: "hydrated", invisiblePrehydration: true, isDebug: false, isDev: false, isTesting: false, lazyLoad: false, lifecycle: true, lifecycleDOMEvents: false, member: true, method:
|
|
2
|
+
const BUILD = /* papierjs */ { allRenderFn: true, appendChildSlotFix: false, asyncLoading: true, asyncQueue: false, attachStyles: true, cloneNodeFix: false, cmpDidLoad: true, cmpDidRender: false, cmpDidUnload: false, cmpDidUpdate: false, cmpShouldUpdate: false, cmpWillLoad: false, cmpWillRender: false, cmpWillUpdate: false, connectedCallback: false, constructableCSS: true, cssAnnotations: true, devTools: false, disconnectedCallback: false, element: false, event: true, experimentalScopedSlotChanges: false, experimentalSlotFixes: false, formAssociated: false, hasRenderFn: true, hostListener: true, hostListenerTarget: true, hostListenerTargetBody: false, hostListenerTargetDocument: false, hostListenerTargetParent: false, hostListenerTargetWindow: true, hotModuleReplacement: false, hydrateClientSide: false, hydrateServerSide: false, hydratedAttribute: false, hydratedClass: true, hydratedSelectorName: "hydrated", invisiblePrehydration: true, isDebug: false, isDev: false, isTesting: false, lazyLoad: false, lifecycle: true, lifecycleDOMEvents: false, member: true, method: true, mode: false, modernPropertyDecls: false, observeAttribute: true, profile: false, prop: true, propBoolean: true, propMutable: false, propNumber: true, propString: true, reflect: false, scoped: false, scopedSlotTextContentFix: false, scriptDataOpts: false, shadowDelegatesFocus: false, shadowDom: true, slot: true, slotChildNodesFix: false, slotRelocation: true, state: true, style: true, svg: false, taskQueue: true, updatable: true, vdomAttribute: true, vdomClass: true, vdomFunctional: false, vdomKey: true, vdomListener: true, vdomPropOrAttr: true, vdomRef: false, vdomRender: true, vdomStyle: false, vdomText: true, vdomXlink: false, watchCallback: false };
|
|
3
3
|
|
|
4
4
|
/*
|
|
5
5
|
Stencil Client Platform v4.25.3 | MIT Licensed | https://stenciljs.com
|
|
@@ -175,6 +175,63 @@ var unwrapErr = (result) => {
|
|
|
175
175
|
throw result.value;
|
|
176
176
|
}
|
|
177
177
|
};
|
|
178
|
+
var updateFallbackSlotVisibility = (elm) => {
|
|
179
|
+
const childNodes = elm.__childNodes || elm.childNodes;
|
|
180
|
+
if (elm.tagName && elm.tagName.includes("-") && elm["s-cr"] && elm.tagName !== "SLOT-FB") {
|
|
181
|
+
getHostSlotNodes(childNodes, elm.tagName).forEach((slotNode) => {
|
|
182
|
+
var _a;
|
|
183
|
+
if (slotNode.nodeType === 1 /* ElementNode */ && slotNode.tagName === "SLOT-FB") {
|
|
184
|
+
if ((_a = getHostSlotChildNodes(slotNode, slotNode["s-sn"], false)) == null ? void 0 : _a.length) {
|
|
185
|
+
slotNode.hidden = true;
|
|
186
|
+
} else {
|
|
187
|
+
slotNode.hidden = false;
|
|
188
|
+
}
|
|
189
|
+
}
|
|
190
|
+
});
|
|
191
|
+
}
|
|
192
|
+
for (const childNode of childNodes) {
|
|
193
|
+
if (childNode.nodeType === 1 /* ElementNode */ && (childNode.__childNodes || childNode.childNodes).length) {
|
|
194
|
+
updateFallbackSlotVisibility(childNode);
|
|
195
|
+
}
|
|
196
|
+
}
|
|
197
|
+
};
|
|
198
|
+
function getHostSlotNodes(childNodes, hostName, slotName) {
|
|
199
|
+
let i2 = 0;
|
|
200
|
+
let slottedNodes = [];
|
|
201
|
+
let childNode;
|
|
202
|
+
for (; i2 < childNodes.length; i2++) {
|
|
203
|
+
childNode = childNodes[i2];
|
|
204
|
+
if (childNode["s-sr"] && childNode["s-hn"] === hostName && (slotName === void 0 || childNode["s-sn"] === slotName)) {
|
|
205
|
+
slottedNodes.push(childNode);
|
|
206
|
+
if (typeof slotName !== "undefined") return slottedNodes;
|
|
207
|
+
}
|
|
208
|
+
slottedNodes = [...slottedNodes, ...getHostSlotNodes(childNode.childNodes, hostName, slotName)];
|
|
209
|
+
}
|
|
210
|
+
return slottedNodes;
|
|
211
|
+
}
|
|
212
|
+
var getHostSlotChildNodes = (node, slotName, includeSlot = true) => {
|
|
213
|
+
const childNodes = [];
|
|
214
|
+
if (includeSlot && node["s-sr"] || !node["s-sr"]) childNodes.push(node);
|
|
215
|
+
while ((node = node.nextSibling) && node["s-sn"] === slotName) {
|
|
216
|
+
childNodes.push(node);
|
|
217
|
+
}
|
|
218
|
+
return childNodes;
|
|
219
|
+
};
|
|
220
|
+
var isNodeLocatedInSlot = (nodeToRelocate, slotName) => {
|
|
221
|
+
if (nodeToRelocate.nodeType === 1 /* ElementNode */) {
|
|
222
|
+
if (nodeToRelocate.getAttribute("slot") === null && slotName === "") {
|
|
223
|
+
return true;
|
|
224
|
+
}
|
|
225
|
+
if (nodeToRelocate.getAttribute("slot") === slotName) {
|
|
226
|
+
return true;
|
|
227
|
+
}
|
|
228
|
+
return false;
|
|
229
|
+
}
|
|
230
|
+
if (nodeToRelocate["s-sn"] === slotName) {
|
|
231
|
+
return true;
|
|
232
|
+
}
|
|
233
|
+
return slotName === "";
|
|
234
|
+
};
|
|
178
235
|
var createTime = (fnName, tagName = "") => {
|
|
179
236
|
{
|
|
180
237
|
return () => {
|
|
@@ -185,6 +242,7 @@ var createTime = (fnName, tagName = "") => {
|
|
|
185
242
|
var h = (nodeName, vnodeData, ...children) => {
|
|
186
243
|
let child = null;
|
|
187
244
|
let key = null;
|
|
245
|
+
let slotName = null;
|
|
188
246
|
let simple = false;
|
|
189
247
|
let lastSimple = false;
|
|
190
248
|
const vNodeChildren = [];
|
|
@@ -211,6 +269,9 @@ var h = (nodeName, vnodeData, ...children) => {
|
|
|
211
269
|
if (vnodeData.key) {
|
|
212
270
|
key = vnodeData.key;
|
|
213
271
|
}
|
|
272
|
+
if (vnodeData.name) {
|
|
273
|
+
slotName = vnodeData.name;
|
|
274
|
+
}
|
|
214
275
|
{
|
|
215
276
|
const classData = vnodeData.className || vnodeData.class;
|
|
216
277
|
if (classData) {
|
|
@@ -226,6 +287,9 @@ var h = (nodeName, vnodeData, ...children) => {
|
|
|
226
287
|
{
|
|
227
288
|
vnode.$key$ = key;
|
|
228
289
|
}
|
|
290
|
+
{
|
|
291
|
+
vnode.$name$ = slotName;
|
|
292
|
+
}
|
|
229
293
|
return vnode;
|
|
230
294
|
};
|
|
231
295
|
var newVNode = (tag, text) => {
|
|
@@ -242,6 +306,9 @@ var newVNode = (tag, text) => {
|
|
|
242
306
|
{
|
|
243
307
|
vnode.$key$ = null;
|
|
244
308
|
}
|
|
309
|
+
{
|
|
310
|
+
vnode.$name$ = null;
|
|
311
|
+
}
|
|
245
312
|
return vnode;
|
|
246
313
|
};
|
|
247
314
|
var Host = {};
|
|
@@ -491,16 +558,38 @@ function sortedAttrNames(attrNames) {
|
|
|
491
558
|
attrNames
|
|
492
559
|
);
|
|
493
560
|
}
|
|
561
|
+
var contentRef;
|
|
494
562
|
var hostTagName;
|
|
495
563
|
var useNativeShadowDom = false;
|
|
564
|
+
var checkSlotFallbackVisibility = false;
|
|
565
|
+
var checkSlotRelocate = false;
|
|
496
566
|
var isSvgMode = false;
|
|
497
567
|
var createElm = (oldParentVNode, newParentVNode, childIndex) => {
|
|
568
|
+
var _a;
|
|
498
569
|
const newVNode2 = newParentVNode.$children$[childIndex];
|
|
499
570
|
let i2 = 0;
|
|
500
571
|
let elm;
|
|
501
572
|
let childNode;
|
|
573
|
+
let oldVNode;
|
|
574
|
+
if (!useNativeShadowDom) {
|
|
575
|
+
checkSlotRelocate = true;
|
|
576
|
+
if (newVNode2.$tag$ === "slot") {
|
|
577
|
+
newVNode2.$flags$ |= newVNode2.$children$ ? (
|
|
578
|
+
// slot element has fallback content
|
|
579
|
+
// still create an element that "mocks" the slot element
|
|
580
|
+
2 /* isSlotFallback */
|
|
581
|
+
) : (
|
|
582
|
+
// slot element does not have fallback content
|
|
583
|
+
// create an html comment we'll use to always reference
|
|
584
|
+
// where actual slot content should sit next to
|
|
585
|
+
1 /* isSlotReference */
|
|
586
|
+
);
|
|
587
|
+
}
|
|
588
|
+
}
|
|
502
589
|
if (newVNode2.$text$ !== null) {
|
|
503
590
|
elm = newVNode2.$elm$ = doc.createTextNode(newVNode2.$text$);
|
|
591
|
+
} else if (newVNode2.$flags$ & 1 /* isSlotReference */) {
|
|
592
|
+
elm = newVNode2.$elm$ = doc.createTextNode("");
|
|
504
593
|
} else {
|
|
505
594
|
elm = newVNode2.$elm$ = doc.createElement(
|
|
506
595
|
!useNativeShadowDom && BUILD.slotRelocation && newVNode2.$flags$ & 2 /* isSlotFallback */ ? "slot-fb" : newVNode2.$tag$
|
|
@@ -518,10 +607,50 @@ var createElm = (oldParentVNode, newParentVNode, childIndex) => {
|
|
|
518
607
|
}
|
|
519
608
|
}
|
|
520
609
|
elm["s-hn"] = hostTagName;
|
|
610
|
+
{
|
|
611
|
+
if (newVNode2.$flags$ & (2 /* isSlotFallback */ | 1 /* isSlotReference */)) {
|
|
612
|
+
elm["s-sr"] = true;
|
|
613
|
+
elm["s-cr"] = contentRef;
|
|
614
|
+
elm["s-sn"] = newVNode2.$name$ || "";
|
|
615
|
+
elm["s-rf"] = (_a = newVNode2.$attrs$) == null ? void 0 : _a.ref;
|
|
616
|
+
oldVNode = oldParentVNode && oldParentVNode.$children$ && oldParentVNode.$children$[childIndex];
|
|
617
|
+
if (oldVNode && oldVNode.$tag$ === newVNode2.$tag$ && oldParentVNode.$elm$) {
|
|
618
|
+
{
|
|
619
|
+
putBackInOriginalLocation(oldParentVNode.$elm$, false);
|
|
620
|
+
}
|
|
621
|
+
}
|
|
622
|
+
}
|
|
623
|
+
}
|
|
521
624
|
return elm;
|
|
522
625
|
};
|
|
626
|
+
var putBackInOriginalLocation = (parentElm, recursive) => {
|
|
627
|
+
plt.$flags$ |= 1 /* isTmpDisconnected */;
|
|
628
|
+
const oldSlotChildNodes = Array.from(parentElm.__childNodes || parentElm.childNodes);
|
|
629
|
+
if (parentElm["s-sr"] && BUILD.experimentalSlotFixes) {
|
|
630
|
+
let node = parentElm;
|
|
631
|
+
while (node = node.nextSibling) {
|
|
632
|
+
if (node && node["s-sn"] === parentElm["s-sn"] && node["s-sh"] === hostTagName) {
|
|
633
|
+
oldSlotChildNodes.push(node);
|
|
634
|
+
}
|
|
635
|
+
}
|
|
636
|
+
}
|
|
637
|
+
for (let i2 = oldSlotChildNodes.length - 1; i2 >= 0; i2--) {
|
|
638
|
+
const childNode = oldSlotChildNodes[i2];
|
|
639
|
+
if (childNode["s-hn"] !== hostTagName && childNode["s-ol"]) {
|
|
640
|
+
insertBefore(referenceNode(childNode).parentNode, childNode, referenceNode(childNode));
|
|
641
|
+
childNode["s-ol"].remove();
|
|
642
|
+
childNode["s-ol"] = void 0;
|
|
643
|
+
childNode["s-sh"] = void 0;
|
|
644
|
+
checkSlotRelocate = true;
|
|
645
|
+
}
|
|
646
|
+
if (recursive) {
|
|
647
|
+
putBackInOriginalLocation(childNode, recursive);
|
|
648
|
+
}
|
|
649
|
+
}
|
|
650
|
+
plt.$flags$ &= ~1 /* isTmpDisconnected */;
|
|
651
|
+
};
|
|
523
652
|
var addVnodes = (parentElm, before, parentVNode, vnodes, startIdx, endIdx) => {
|
|
524
|
-
let containerElm = parentElm;
|
|
653
|
+
let containerElm = parentElm["s-cr"] && parentElm["s-cr"].parentNode || parentElm;
|
|
525
654
|
let childNode;
|
|
526
655
|
if (containerElm.shadowRoot && containerElm.tagName === hostTagName) {
|
|
527
656
|
containerElm = containerElm.shadowRoot;
|
|
@@ -531,7 +660,7 @@ var addVnodes = (parentElm, before, parentVNode, vnodes, startIdx, endIdx) => {
|
|
|
531
660
|
childNode = createElm(null, parentVNode, startIdx);
|
|
532
661
|
if (childNode) {
|
|
533
662
|
vnodes[startIdx].$elm$ = childNode;
|
|
534
|
-
insertBefore(containerElm, childNode, before);
|
|
663
|
+
insertBefore(containerElm, childNode, referenceNode(before) );
|
|
535
664
|
}
|
|
536
665
|
}
|
|
537
666
|
}
|
|
@@ -542,6 +671,14 @@ var removeVnodes = (vnodes, startIdx, endIdx) => {
|
|
|
542
671
|
if (vnode) {
|
|
543
672
|
const elm = vnode.$elm$;
|
|
544
673
|
if (elm) {
|
|
674
|
+
{
|
|
675
|
+
checkSlotFallbackVisibility = true;
|
|
676
|
+
if (elm["s-ol"]) {
|
|
677
|
+
elm["s-ol"].remove();
|
|
678
|
+
} else {
|
|
679
|
+
putBackInOriginalLocation(elm, true);
|
|
680
|
+
}
|
|
681
|
+
}
|
|
545
682
|
elm.remove();
|
|
546
683
|
}
|
|
547
684
|
}
|
|
@@ -578,11 +715,17 @@ var updateChildren = (parentElm, oldCh, newVNode2, newCh, isInitialRender = fals
|
|
|
578
715
|
oldEndVnode = oldCh[--oldEndIdx];
|
|
579
716
|
newEndVnode = newCh[--newEndIdx];
|
|
580
717
|
} else if (isSameVnode(oldStartVnode, newEndVnode, isInitialRender)) {
|
|
718
|
+
if ((oldStartVnode.$tag$ === "slot" || newEndVnode.$tag$ === "slot")) {
|
|
719
|
+
putBackInOriginalLocation(oldStartVnode.$elm$.parentNode, false);
|
|
720
|
+
}
|
|
581
721
|
patch(oldStartVnode, newEndVnode, isInitialRender);
|
|
582
722
|
insertBefore(parentElm, oldStartVnode.$elm$, oldEndVnode.$elm$.nextSibling);
|
|
583
723
|
oldStartVnode = oldCh[++oldStartIdx];
|
|
584
724
|
newEndVnode = newCh[--newEndIdx];
|
|
585
725
|
} else if (isSameVnode(oldEndVnode, newStartVnode, isInitialRender)) {
|
|
726
|
+
if ((oldStartVnode.$tag$ === "slot" || newEndVnode.$tag$ === "slot")) {
|
|
727
|
+
putBackInOriginalLocation(oldEndVnode.$elm$.parentNode, false);
|
|
728
|
+
}
|
|
586
729
|
patch(oldEndVnode, newStartVnode, isInitialRender);
|
|
587
730
|
insertBefore(parentElm, oldEndVnode.$elm$, oldStartVnode.$elm$);
|
|
588
731
|
oldEndVnode = oldCh[--oldEndIdx];
|
|
@@ -613,7 +756,11 @@ var updateChildren = (parentElm, oldCh, newVNode2, newCh, isInitialRender = fals
|
|
|
613
756
|
}
|
|
614
757
|
if (node) {
|
|
615
758
|
{
|
|
616
|
-
insertBefore(
|
|
759
|
+
insertBefore(
|
|
760
|
+
referenceNode(oldStartVnode.$elm$).parentNode,
|
|
761
|
+
node,
|
|
762
|
+
referenceNode(oldStartVnode.$elm$)
|
|
763
|
+
);
|
|
617
764
|
}
|
|
618
765
|
}
|
|
619
766
|
}
|
|
@@ -633,6 +780,9 @@ var updateChildren = (parentElm, oldCh, newVNode2, newCh, isInitialRender = fals
|
|
|
633
780
|
};
|
|
634
781
|
var isSameVnode = (leftVNode, rightVNode, isInitialRender = false) => {
|
|
635
782
|
if (leftVNode.$tag$ === rightVNode.$tag$) {
|
|
783
|
+
if (leftVNode.$tag$ === "slot") {
|
|
784
|
+
return leftVNode.$name$ === rightVNode.$name$;
|
|
785
|
+
}
|
|
636
786
|
if (!isInitialRender) {
|
|
637
787
|
return leftVNode.$key$ === rightVNode.$key$;
|
|
638
788
|
}
|
|
@@ -643,12 +793,14 @@ var isSameVnode = (leftVNode, rightVNode, isInitialRender = false) => {
|
|
|
643
793
|
}
|
|
644
794
|
return false;
|
|
645
795
|
};
|
|
796
|
+
var referenceNode = (node) => node && node["s-ol"] || node;
|
|
646
797
|
var patch = (oldVNode, newVNode2, isInitialRender = false) => {
|
|
647
798
|
const elm = newVNode2.$elm$ = oldVNode.$elm$;
|
|
648
799
|
const oldChildren = oldVNode.$children$;
|
|
649
800
|
const newChildren = newVNode2.$children$;
|
|
650
801
|
const tag = newVNode2.$tag$;
|
|
651
802
|
const text = newVNode2.$text$;
|
|
803
|
+
let defaultHolder;
|
|
652
804
|
if (text === null) {
|
|
653
805
|
{
|
|
654
806
|
if (tag === "slot" && !useNativeShadowDom) ; else {
|
|
@@ -668,16 +820,69 @@ var patch = (oldVNode, newVNode2, isInitialRender = false) => {
|
|
|
668
820
|
) {
|
|
669
821
|
removeVnodes(oldChildren, 0, oldChildren.length - 1);
|
|
670
822
|
}
|
|
823
|
+
} else if ((defaultHolder = elm["s-cr"])) {
|
|
824
|
+
defaultHolder.parentNode.textContent = text;
|
|
671
825
|
} else if (oldVNode.$text$ !== text) {
|
|
672
826
|
elm.data = text;
|
|
673
827
|
}
|
|
674
828
|
};
|
|
829
|
+
var relocateNodes = [];
|
|
830
|
+
var markSlotContentForRelocation = (elm) => {
|
|
831
|
+
let node;
|
|
832
|
+
let hostContentNodes;
|
|
833
|
+
let j;
|
|
834
|
+
const children = elm.__childNodes || elm.childNodes;
|
|
835
|
+
for (const childNode of children) {
|
|
836
|
+
if (childNode["s-sr"] && (node = childNode["s-cr"]) && node.parentNode) {
|
|
837
|
+
hostContentNodes = node.parentNode.__childNodes || node.parentNode.childNodes;
|
|
838
|
+
const slotName = childNode["s-sn"];
|
|
839
|
+
for (j = hostContentNodes.length - 1; j >= 0; j--) {
|
|
840
|
+
node = hostContentNodes[j];
|
|
841
|
+
if (!node["s-cn"] && !node["s-nr"] && node["s-hn"] !== childNode["s-hn"] && (!BUILD.experimentalSlotFixes )) {
|
|
842
|
+
if (isNodeLocatedInSlot(node, slotName)) {
|
|
843
|
+
let relocateNodeData = relocateNodes.find((r) => r.$nodeToRelocate$ === node);
|
|
844
|
+
checkSlotFallbackVisibility = true;
|
|
845
|
+
node["s-sn"] = node["s-sn"] || slotName;
|
|
846
|
+
if (relocateNodeData) {
|
|
847
|
+
relocateNodeData.$nodeToRelocate$["s-sh"] = childNode["s-hn"];
|
|
848
|
+
relocateNodeData.$slotRefNode$ = childNode;
|
|
849
|
+
} else {
|
|
850
|
+
node["s-sh"] = childNode["s-hn"];
|
|
851
|
+
relocateNodes.push({
|
|
852
|
+
$slotRefNode$: childNode,
|
|
853
|
+
$nodeToRelocate$: node
|
|
854
|
+
});
|
|
855
|
+
}
|
|
856
|
+
if (node["s-sr"]) {
|
|
857
|
+
relocateNodes.map((relocateNode) => {
|
|
858
|
+
if (isNodeLocatedInSlot(relocateNode.$nodeToRelocate$, node["s-sn"])) {
|
|
859
|
+
relocateNodeData = relocateNodes.find((r) => r.$nodeToRelocate$ === node);
|
|
860
|
+
if (relocateNodeData && !relocateNode.$slotRefNode$) {
|
|
861
|
+
relocateNode.$slotRefNode$ = relocateNodeData.$slotRefNode$;
|
|
862
|
+
}
|
|
863
|
+
}
|
|
864
|
+
});
|
|
865
|
+
}
|
|
866
|
+
} else if (!relocateNodes.some((r) => r.$nodeToRelocate$ === node)) {
|
|
867
|
+
relocateNodes.push({
|
|
868
|
+
$nodeToRelocate$: node
|
|
869
|
+
});
|
|
870
|
+
}
|
|
871
|
+
}
|
|
872
|
+
}
|
|
873
|
+
}
|
|
874
|
+
if (childNode.nodeType === 1 /* ElementNode */) {
|
|
875
|
+
markSlotContentForRelocation(childNode);
|
|
876
|
+
}
|
|
877
|
+
}
|
|
878
|
+
};
|
|
675
879
|
var insertBefore = (parent, newNode, reference) => {
|
|
676
880
|
{
|
|
677
881
|
return parent == null ? void 0 : parent.insertBefore(newNode, reference);
|
|
678
882
|
}
|
|
679
883
|
};
|
|
680
884
|
var renderVdom = (hostRef, renderFnResults, isInitialLoad = false) => {
|
|
885
|
+
var _a, _b, _c, _d;
|
|
681
886
|
const hostElm = hostRef.$hostElement$;
|
|
682
887
|
const cmpMeta = hostRef.$cmpMeta$;
|
|
683
888
|
const oldVNode = hostRef.$vnode$ || newVNode(null, null);
|
|
@@ -695,7 +900,77 @@ var renderVdom = (hostRef, renderFnResults, isInitialLoad = false) => {
|
|
|
695
900
|
hostRef.$vnode$ = rootVnode;
|
|
696
901
|
rootVnode.$elm$ = oldVNode.$elm$ = hostElm.shadowRoot || hostElm ;
|
|
697
902
|
useNativeShadowDom = (cmpMeta.$flags$ & 1 /* shadowDomEncapsulation */) !== 0;
|
|
903
|
+
{
|
|
904
|
+
contentRef = hostElm["s-cr"];
|
|
905
|
+
checkSlotFallbackVisibility = false;
|
|
906
|
+
}
|
|
698
907
|
patch(oldVNode, rootVnode, isInitialLoad);
|
|
908
|
+
{
|
|
909
|
+
plt.$flags$ |= 1 /* isTmpDisconnected */;
|
|
910
|
+
if (checkSlotRelocate) {
|
|
911
|
+
markSlotContentForRelocation(rootVnode.$elm$);
|
|
912
|
+
for (const relocateData of relocateNodes) {
|
|
913
|
+
const nodeToRelocate = relocateData.$nodeToRelocate$;
|
|
914
|
+
if (!nodeToRelocate["s-ol"]) {
|
|
915
|
+
const orgLocationNode = doc.createTextNode("");
|
|
916
|
+
orgLocationNode["s-nr"] = nodeToRelocate;
|
|
917
|
+
insertBefore(nodeToRelocate.parentNode, nodeToRelocate["s-ol"] = orgLocationNode, nodeToRelocate);
|
|
918
|
+
}
|
|
919
|
+
}
|
|
920
|
+
for (const relocateData of relocateNodes) {
|
|
921
|
+
const nodeToRelocate = relocateData.$nodeToRelocate$;
|
|
922
|
+
const slotRefNode = relocateData.$slotRefNode$;
|
|
923
|
+
if (slotRefNode) {
|
|
924
|
+
const parentNodeRef = slotRefNode.parentNode;
|
|
925
|
+
let insertBeforeNode = slotRefNode.nextSibling;
|
|
926
|
+
{
|
|
927
|
+
let orgLocationNode = (_a = nodeToRelocate["s-ol"]) == null ? void 0 : _a.previousSibling;
|
|
928
|
+
while (orgLocationNode) {
|
|
929
|
+
let refNode = (_b = orgLocationNode["s-nr"]) != null ? _b : null;
|
|
930
|
+
if (refNode && refNode["s-sn"] === nodeToRelocate["s-sn"] && parentNodeRef === (refNode.__parentNode || refNode.parentNode)) {
|
|
931
|
+
refNode = refNode.nextSibling;
|
|
932
|
+
while (refNode === nodeToRelocate || (refNode == null ? void 0 : refNode["s-sr"])) {
|
|
933
|
+
refNode = refNode == null ? void 0 : refNode.nextSibling;
|
|
934
|
+
}
|
|
935
|
+
if (!refNode || !refNode["s-nr"]) {
|
|
936
|
+
insertBeforeNode = refNode;
|
|
937
|
+
break;
|
|
938
|
+
}
|
|
939
|
+
}
|
|
940
|
+
orgLocationNode = orgLocationNode.previousSibling;
|
|
941
|
+
}
|
|
942
|
+
}
|
|
943
|
+
const parent = nodeToRelocate.__parentNode || nodeToRelocate.parentNode;
|
|
944
|
+
const nextSibling = nodeToRelocate.__nextSibling || nodeToRelocate.nextSibling;
|
|
945
|
+
if (!insertBeforeNode && parentNodeRef !== parent || nextSibling !== insertBeforeNode) {
|
|
946
|
+
if (nodeToRelocate !== insertBeforeNode) {
|
|
947
|
+
if (!nodeToRelocate["s-hn"] && nodeToRelocate["s-ol"]) {
|
|
948
|
+
nodeToRelocate["s-hn"] = nodeToRelocate["s-ol"].parentNode.nodeName;
|
|
949
|
+
}
|
|
950
|
+
insertBefore(parentNodeRef, nodeToRelocate, insertBeforeNode);
|
|
951
|
+
if (nodeToRelocate.nodeType === 1 /* ElementNode */ && nodeToRelocate.tagName !== "SLOT-FB") {
|
|
952
|
+
nodeToRelocate.hidden = (_c = nodeToRelocate["s-ih"]) != null ? _c : false;
|
|
953
|
+
}
|
|
954
|
+
}
|
|
955
|
+
}
|
|
956
|
+
nodeToRelocate && typeof slotRefNode["s-rf"] === "function" && slotRefNode["s-rf"](nodeToRelocate);
|
|
957
|
+
} else {
|
|
958
|
+
if (nodeToRelocate.nodeType === 1 /* ElementNode */) {
|
|
959
|
+
if (isInitialLoad) {
|
|
960
|
+
nodeToRelocate["s-ih"] = (_d = nodeToRelocate.hidden) != null ? _d : false;
|
|
961
|
+
}
|
|
962
|
+
nodeToRelocate.hidden = true;
|
|
963
|
+
}
|
|
964
|
+
}
|
|
965
|
+
}
|
|
966
|
+
}
|
|
967
|
+
if (checkSlotFallbackVisibility) {
|
|
968
|
+
updateFallbackSlotVisibility(rootVnode.$elm$);
|
|
969
|
+
}
|
|
970
|
+
plt.$flags$ &= ~1 /* isTmpDisconnected */;
|
|
971
|
+
relocateNodes.length = 0;
|
|
972
|
+
}
|
|
973
|
+
contentRef = void 0;
|
|
699
974
|
};
|
|
700
975
|
|
|
701
976
|
// src/runtime/update-component.ts
|
|
@@ -1000,6 +1275,12 @@ var connectedCallback = (elm) => {
|
|
|
1000
1275
|
const endConnected = createTime("connectedCallback", cmpMeta.$tagName$);
|
|
1001
1276
|
if (!(hostRef.$flags$ & 1 /* hasConnected */)) {
|
|
1002
1277
|
hostRef.$flags$ |= 1 /* hasConnected */;
|
|
1278
|
+
{
|
|
1279
|
+
if (// TODO(STENCIL-854): Remove code related to legacy shadowDomShim field
|
|
1280
|
+
cmpMeta.$flags$ & (4 /* hasSlotRelocation */ | 8 /* needsShadowDomShim */)) {
|
|
1281
|
+
setContentReference(elm);
|
|
1282
|
+
}
|
|
1283
|
+
}
|
|
1003
1284
|
{
|
|
1004
1285
|
let ancestorComponent = elm;
|
|
1005
1286
|
while (ancestorComponent = ancestorComponent.parentNode || ancestorComponent.host) {
|
|
@@ -1030,6 +1311,13 @@ var connectedCallback = (elm) => {
|
|
|
1030
1311
|
endConnected();
|
|
1031
1312
|
}
|
|
1032
1313
|
};
|
|
1314
|
+
var setContentReference = (elm) => {
|
|
1315
|
+
const contentRefElm = elm["s-cr"] = doc.createComment(
|
|
1316
|
+
""
|
|
1317
|
+
);
|
|
1318
|
+
contentRefElm["s-cn"] = true;
|
|
1319
|
+
insertBefore(elm, contentRefElm, elm.firstChild);
|
|
1320
|
+
};
|
|
1033
1321
|
var disconnectedCallback = async (elm) => {
|
|
1034
1322
|
if ((plt.$flags$ & 1 /* isTmpDisconnected */) === 0) {
|
|
1035
1323
|
const hostRef = getHostRef(elm);
|
|
@@ -1138,6 +1426,6 @@ var setNonce = (nonce) => plt.$nonce$ = nonce;
|
|
|
1138
1426
|
// src/runtime/platform-options.ts
|
|
1139
1427
|
var setPlatformOptions = (opts) => Object.assign(plt, opts);
|
|
1140
1428
|
|
|
1141
|
-
export { H, setNonce as a, setPlatformOptions as b, createEvent as c, getAssetPath as g, h, proxyCustomElement as p, setAssetPath as s };
|
|
1429
|
+
export { H, setNonce as a, setPlatformOptions as b, createEvent as c, Host as d, getAssetPath as g, h, proxyCustomElement as p, setAssetPath as s };
|
|
1142
1430
|
|
|
1143
|
-
//# sourceMappingURL=p-
|
|
1431
|
+
//# sourceMappingURL=p-784ab1ae.js.map
|