@dnncommunity/dnn-elements 0.13.0-beta.1

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.
Files changed (244) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +24 -0
  3. package/dist/cjs/app-globals-3a1e7e63.js +7 -0
  4. package/dist/cjs/app-globals-3a1e7e63.js.map +1 -0
  5. package/dist/cjs/css-shim-3bfdba4f.js +8 -0
  6. package/dist/cjs/css-shim-3bfdba4f.js.map +1 -0
  7. package/dist/cjs/debounce-1de79bc7.js +24 -0
  8. package/dist/cjs/debounce-1de79bc7.js.map +1 -0
  9. package/dist/cjs/dnn-button.cjs.entry.js +88 -0
  10. package/dist/cjs/dnn-button.cjs.entry.js.map +1 -0
  11. package/dist/cjs/dnn-button_14.cjs.entry.js +1580 -0
  12. package/dist/cjs/dnn-button_14.cjs.entry.js.map +1 -0
  13. package/dist/cjs/dnn-checkbox.cjs.entry.js +58 -0
  14. package/dist/cjs/dnn-checkbox.cjs.entry.js.map +1 -0
  15. package/dist/cjs/dnn-chevron.cjs.entry.js +34 -0
  16. package/dist/cjs/dnn-chevron.cjs.entry.js.map +1 -0
  17. package/dist/cjs/dnn-collapsible.cjs.entry.js +112 -0
  18. package/dist/cjs/dnn-collapsible.cjs.entry.js.map +1 -0
  19. package/dist/cjs/dnn-color-picker.cjs.entry.js +508 -0
  20. package/dist/cjs/dnn-color-picker.cjs.entry.js.map +1 -0
  21. package/dist/cjs/dnn-dropzone.cjs.entry.js +153 -0
  22. package/dist/cjs/dnn-dropzone.cjs.entry.js.map +1 -0
  23. package/dist/cjs/dnn-image-cropper.cjs.entry.js +424 -0
  24. package/dist/cjs/dnn-image-cropper.cjs.entry.js.map +1 -0
  25. package/dist/cjs/dnn-modal.cjs.entry.js +62 -0
  26. package/dist/cjs/dnn-modal.cjs.entry.js.map +1 -0
  27. package/dist/cjs/dnn-searchbox.cjs.entry.js +66 -0
  28. package/dist/cjs/dnn-searchbox.cjs.entry.js.map +1 -0
  29. package/dist/cjs/dnn-sort-icon.cjs.entry.js +43 -0
  30. package/dist/cjs/dnn-sort-icon.cjs.entry.js.map +1 -0
  31. package/dist/cjs/dnn-tab.cjs.entry.js +31 -0
  32. package/dist/cjs/dnn-tab.cjs.entry.js.map +1 -0
  33. package/dist/cjs/dnn-tabs.cjs.entry.js +50 -0
  34. package/dist/cjs/dnn-tabs.cjs.entry.js.map +1 -0
  35. package/dist/cjs/dnn-toggle.cjs.entry.js +37 -0
  36. package/dist/cjs/dnn-toggle.cjs.entry.js.map +1 -0
  37. package/dist/cjs/dnn-treeview-item.cjs.entry.js +48 -0
  38. package/dist/cjs/dnn-treeview-item.cjs.entry.js.map +1 -0
  39. package/dist/cjs/dnn.cjs.js +129 -0
  40. package/dist/cjs/dnn.cjs.js.map +1 -0
  41. package/dist/cjs/dom-8ac1ad03.js +77 -0
  42. package/dist/cjs/dom-8ac1ad03.js.map +1 -0
  43. package/dist/cjs/index-e85ec026.js +1327 -0
  44. package/dist/cjs/index-e85ec026.js.map +1 -0
  45. package/dist/cjs/index-eede7745.js +3069 -0
  46. package/dist/cjs/index-eede7745.js.map +1 -0
  47. package/dist/cjs/index.cjs.js +52 -0
  48. package/dist/cjs/index.cjs.js.map +1 -0
  49. package/dist/cjs/loader.cjs.js +39 -0
  50. package/dist/cjs/loader.cjs.js.map +1 -0
  51. package/dist/cjs/shadow-css-41d9783d.js +392 -0
  52. package/dist/cjs/shadow-css-41d9783d.js.map +1 -0
  53. package/dist/collection/collection-manifest.json +25 -0
  54. package/dist/collection/components/dnn-button/dnn-button.css +87 -0
  55. package/dist/collection/components/dnn-button/dnn-button.js +272 -0
  56. package/dist/collection/components/dnn-button/dnn-button.js.map +1 -0
  57. package/dist/collection/components/dnn-checkbox/dnn-checkbox.css +27 -0
  58. package/dist/collection/components/dnn-checkbox/dnn-checkbox.js +140 -0
  59. package/dist/collection/components/dnn-checkbox/dnn-checkbox.js.map +1 -0
  60. package/dist/collection/components/dnn-chevron/dnn-chevron.css +30 -0
  61. package/dist/collection/components/dnn-chevron/dnn-chevron.js +107 -0
  62. package/dist/collection/components/dnn-chevron/dnn-chevron.js.map +1 -0
  63. package/dist/collection/components/dnn-collapsible/dnn-collapsible.css +8 -0
  64. package/dist/collection/components/dnn-collapsible/dnn-collapsible.js +188 -0
  65. package/dist/collection/components/dnn-collapsible/dnn-collapsible.js.map +1 -0
  66. package/dist/collection/components/dnn-color-picker/dnn-color-picker.css +225 -0
  67. package/dist/collection/components/dnn-color-picker/dnn-color-picker.js +434 -0
  68. package/dist/collection/components/dnn-color-picker/dnn-color-picker.js.map +1 -0
  69. package/dist/collection/components/dnn-dropzone/dnn-dropzone.css +62 -0
  70. package/dist/collection/components/dnn-dropzone/dnn-dropzone.js +266 -0
  71. package/dist/collection/components/dnn-dropzone/dnn-dropzone.js.map +1 -0
  72. package/dist/collection/components/dnn-image-cropper/CornerType.js +9 -0
  73. package/dist/collection/components/dnn-image-cropper/CornerType.js.map +1 -0
  74. package/dist/collection/components/dnn-image-cropper/dnn-image-cropper.css +80 -0
  75. package/dist/collection/components/dnn-image-cropper/dnn-image-cropper.js +539 -0
  76. package/dist/collection/components/dnn-image-cropper/dnn-image-cropper.js.map +1 -0
  77. package/dist/collection/components/dnn-modal/dnn-modal.css +67 -0
  78. package/dist/collection/components/dnn-modal/dnn-modal.js +173 -0
  79. package/dist/collection/components/dnn-modal/dnn-modal.js.map +1 -0
  80. package/dist/collection/components/dnn-searchbox/dnn-searchbox.css +48 -0
  81. package/dist/collection/components/dnn-searchbox/dnn-searchbox.js +137 -0
  82. package/dist/collection/components/dnn-searchbox/dnn-searchbox.js.map +1 -0
  83. package/dist/collection/components/dnn-sort-icon/dnn-sort-icon.css +32 -0
  84. package/dist/collection/components/dnn-sort-icon/dnn-sort-icon.js +81 -0
  85. package/dist/collection/components/dnn-sort-icon/dnn-sort-icon.js.map +1 -0
  86. package/dist/collection/components/dnn-tab/dnn-tab.css +0 -0
  87. package/dist/collection/components/dnn-tab/dnn-tab.js +84 -0
  88. package/dist/collection/components/dnn-tab/dnn-tab.js.map +1 -0
  89. package/dist/collection/components/dnn-tabs/dnn-tabs.css +40 -0
  90. package/dist/collection/components/dnn-tabs/dnn-tabs.js +53 -0
  91. package/dist/collection/components/dnn-tabs/dnn-tabs.js.map +1 -0
  92. package/dist/collection/components/dnn-toggle/dnn-toggle.css +52 -0
  93. package/dist/collection/components/dnn-toggle/dnn-toggle.js +94 -0
  94. package/dist/collection/components/dnn-toggle/dnn-toggle.js.map +1 -0
  95. package/dist/collection/components/dnn-toggle/toggle-interface.js +2 -0
  96. package/dist/collection/components/dnn-toggle/toggle-interface.js.map +1 -0
  97. package/dist/collection/components/dnn-treeview-item/dnn-treeview-item.css +47 -0
  98. package/dist/collection/components/dnn-treeview-item/dnn-treeview-item.js +77 -0
  99. package/dist/collection/components/dnn-treeview-item/dnn-treeview-item.js.map +1 -0
  100. package/dist/collection/index.js +3 -0
  101. package/dist/collection/index.js.map +1 -0
  102. package/dist/collection/utilities/colorInfo.js +191 -0
  103. package/dist/collection/utilities/colorInfo.js.map +1 -0
  104. package/dist/collection/utilities/debounce.js +19 -0
  105. package/dist/collection/utilities/debounce.js.map +1 -0
  106. package/dist/collection/utilities/dnnServicesFramework.js +42 -0
  107. package/dist/collection/utilities/dnnServicesFramework.js.map +1 -0
  108. package/dist/dnn/app-globals-0f993ce5.js +5 -0
  109. package/dist/dnn/app-globals-0f993ce5.js.map +1 -0
  110. package/dist/dnn/css-shim-20dbffa5.js +6 -0
  111. package/dist/dnn/css-shim-20dbffa5.js.map +1 -0
  112. package/dist/dnn/debounce-06f55268.js +22 -0
  113. package/dist/dnn/debounce-06f55268.js.map +1 -0
  114. package/dist/dnn/dnn-button.entry.js +84 -0
  115. package/dist/dnn/dnn-button.entry.js.map +1 -0
  116. package/dist/dnn/dnn-checkbox.entry.js +54 -0
  117. package/dist/dnn/dnn-checkbox.entry.js.map +1 -0
  118. package/dist/dnn/dnn-chevron.entry.js +30 -0
  119. package/dist/dnn/dnn-chevron.entry.js.map +1 -0
  120. package/dist/dnn/dnn-collapsible.entry.js +108 -0
  121. package/dist/dnn/dnn-collapsible.entry.js.map +1 -0
  122. package/dist/dnn/dnn-color-picker.entry.js +504 -0
  123. package/dist/dnn/dnn-color-picker.entry.js.map +1 -0
  124. package/dist/dnn/dnn-dropzone.entry.js +149 -0
  125. package/dist/dnn/dnn-dropzone.entry.js.map +1 -0
  126. package/dist/dnn/dnn-image-cropper.entry.js +420 -0
  127. package/dist/dnn/dnn-image-cropper.entry.js.map +1 -0
  128. package/dist/dnn/dnn-modal.entry.js +58 -0
  129. package/dist/dnn/dnn-modal.entry.js.map +1 -0
  130. package/dist/dnn/dnn-searchbox.entry.js +62 -0
  131. package/dist/dnn/dnn-searchbox.entry.js.map +1 -0
  132. package/dist/dnn/dnn-sort-icon.entry.js +39 -0
  133. package/dist/dnn/dnn-sort-icon.entry.js.map +1 -0
  134. package/dist/dnn/dnn-tab.entry.js +27 -0
  135. package/dist/dnn/dnn-tab.entry.js.map +1 -0
  136. package/dist/dnn/dnn-tabs.entry.js +46 -0
  137. package/dist/dnn/dnn-tabs.entry.js.map +1 -0
  138. package/dist/dnn/dnn-toggle.entry.js +33 -0
  139. package/dist/dnn/dnn-toggle.entry.js.map +1 -0
  140. package/dist/dnn/dnn-treeview-item.entry.js +44 -0
  141. package/dist/dnn/dnn-treeview-item.entry.js.map +1 -0
  142. package/dist/dnn/dnn.esm.js +127 -0
  143. package/dist/dnn/dnn.esm.js.map +1 -0
  144. package/dist/dnn/dom-c5ed0ba5.js +75 -0
  145. package/dist/dnn/dom-c5ed0ba5.js.map +1 -0
  146. package/dist/dnn/index-6c0764e5.js +3033 -0
  147. package/dist/dnn/index-6c0764e5.js.map +1 -0
  148. package/dist/dnn/index.esm.js +47 -0
  149. package/dist/dnn/index.esm.js.map +1 -0
  150. package/dist/dnn/p-0e94f5ee.js +2 -0
  151. package/dist/dnn/p-0e94f5ee.js.map +1 -0
  152. package/dist/dnn/p-7acf3104.entry.js +11 -0
  153. package/dist/dnn/p-7acf3104.entry.js.map +1 -0
  154. package/dist/dnn/p-bd3d3361.js +2 -0
  155. package/dist/dnn/p-bd3d3361.js.map +1 -0
  156. package/dist/dnn/shadow-css-8c625855.js +390 -0
  157. package/dist/dnn/shadow-css-8c625855.js.map +1 -0
  158. package/dist/esm/app-globals-0f993ce5.js +5 -0
  159. package/dist/esm/app-globals-0f993ce5.js.map +1 -0
  160. package/dist/esm/css-shim-20dbffa5.js +6 -0
  161. package/dist/esm/css-shim-20dbffa5.js.map +1 -0
  162. package/dist/esm/debounce-06f55268.js +22 -0
  163. package/dist/esm/debounce-06f55268.js.map +1 -0
  164. package/dist/esm/dnn-button.entry.js +84 -0
  165. package/dist/esm/dnn-button.entry.js.map +1 -0
  166. package/dist/esm/dnn-button_14.entry.js +1563 -0
  167. package/dist/esm/dnn-button_14.entry.js.map +1 -0
  168. package/dist/esm/dnn-checkbox.entry.js +54 -0
  169. package/dist/esm/dnn-checkbox.entry.js.map +1 -0
  170. package/dist/esm/dnn-chevron.entry.js +30 -0
  171. package/dist/esm/dnn-chevron.entry.js.map +1 -0
  172. package/dist/esm/dnn-collapsible.entry.js +108 -0
  173. package/dist/esm/dnn-collapsible.entry.js.map +1 -0
  174. package/dist/esm/dnn-color-picker.entry.js +504 -0
  175. package/dist/esm/dnn-color-picker.entry.js.map +1 -0
  176. package/dist/esm/dnn-dropzone.entry.js +149 -0
  177. package/dist/esm/dnn-dropzone.entry.js.map +1 -0
  178. package/dist/esm/dnn-image-cropper.entry.js +420 -0
  179. package/dist/esm/dnn-image-cropper.entry.js.map +1 -0
  180. package/dist/esm/dnn-modal.entry.js +58 -0
  181. package/dist/esm/dnn-modal.entry.js.map +1 -0
  182. package/dist/esm/dnn-searchbox.entry.js +62 -0
  183. package/dist/esm/dnn-searchbox.entry.js.map +1 -0
  184. package/dist/esm/dnn-sort-icon.entry.js +39 -0
  185. package/dist/esm/dnn-sort-icon.entry.js.map +1 -0
  186. package/dist/esm/dnn-tab.entry.js +27 -0
  187. package/dist/esm/dnn-tab.entry.js.map +1 -0
  188. package/dist/esm/dnn-tabs.entry.js +46 -0
  189. package/dist/esm/dnn-tabs.entry.js.map +1 -0
  190. package/dist/esm/dnn-toggle.entry.js +33 -0
  191. package/dist/esm/dnn-toggle.entry.js.map +1 -0
  192. package/dist/esm/dnn-treeview-item.entry.js +44 -0
  193. package/dist/esm/dnn-treeview-item.entry.js.map +1 -0
  194. package/dist/esm/dnn.js +127 -0
  195. package/dist/esm/dnn.js.map +1 -0
  196. package/dist/esm/dom-c5ed0ba5.js +75 -0
  197. package/dist/esm/dom-c5ed0ba5.js.map +1 -0
  198. package/dist/esm/index-6c0764e5.js +3033 -0
  199. package/dist/esm/index-6c0764e5.js.map +1 -0
  200. package/dist/esm/index-f79d9e82.js +1299 -0
  201. package/dist/esm/index-f79d9e82.js.map +1 -0
  202. package/dist/esm/index.js +47 -0
  203. package/dist/esm/index.js.map +1 -0
  204. package/dist/esm/loader.js +35 -0
  205. package/dist/esm/loader.js.map +1 -0
  206. package/dist/esm/polyfills/core-js.js +11 -0
  207. package/dist/esm/polyfills/css-shim.js +1 -0
  208. package/dist/esm/polyfills/dom.js +79 -0
  209. package/dist/esm/polyfills/es5-html-element.js +1 -0
  210. package/dist/esm/polyfills/index.js +34 -0
  211. package/dist/esm/polyfills/system.js +6 -0
  212. package/dist/esm/shadow-css-8c625855.js +390 -0
  213. package/dist/esm/shadow-css-8c625855.js.map +1 -0
  214. package/dist/index.cjs.js +1 -0
  215. package/dist/index.js +1 -0
  216. package/dist/types/components/dnn-button/dnn-button.d.ts +55 -0
  217. package/dist/types/components/dnn-checkbox/dnn-checkbox.d.ts +16 -0
  218. package/dist/types/components/dnn-chevron/dnn-chevron.d.ts +13 -0
  219. package/dist/types/components/dnn-collapsible/dnn-collapsible.d.ts +22 -0
  220. package/dist/types/components/dnn-color-picker/dnn-color-picker.d.ts +46 -0
  221. package/dist/types/components/dnn-dropzone/dnn-dropzone.d.ts +45 -0
  222. package/dist/types/components/dnn-image-cropper/CornerType.d.ts +6 -0
  223. package/dist/types/components/dnn-image-cropper/dnn-image-cropper.d.ts +62 -0
  224. package/dist/types/components/dnn-modal/dnn-modal.d.ts +35 -0
  225. package/dist/types/components/dnn-searchbox/dnn-searchbox.d.ts +22 -0
  226. package/dist/types/components/dnn-sort-icon/dnn-sort-icon.d.ts +9 -0
  227. package/dist/types/components/dnn-tab/dnn-tab.d.ts +11 -0
  228. package/dist/types/components/dnn-tabs/dnn-tabs.d.ts +11 -0
  229. package/dist/types/components/dnn-toggle/dnn-toggle.d.ts +13 -0
  230. package/dist/types/components/dnn-toggle/toggle-interface.d.ts +3 -0
  231. package/dist/types/components/dnn-treeview-item/dnn-treeview-item.d.ts +16 -0
  232. package/dist/types/components.d.ts +611 -0
  233. package/dist/types/index.d.ts +3 -0
  234. package/dist/types/stencil-public-runtime.d.ts +1565 -0
  235. package/dist/types/utilities/colorInfo.d.ts +52 -0
  236. package/dist/types/utilities/debounce.d.ts +5 -0
  237. package/dist/types/utilities/dnnServicesFramework.d.ts +19 -0
  238. package/loader/cdn.js +3 -0
  239. package/loader/index.cjs.js +3 -0
  240. package/loader/index.d.ts +12 -0
  241. package/loader/index.es2017.js +3 -0
  242. package/loader/index.js +4 -0
  243. package/loader/package.json +10 -0
  244. package/package.json +48 -0
@@ -0,0 +1,1299 @@
1
+ const NAMESPACE = 'dnn';
2
+
3
+ let scopeId;
4
+ let hostTagName;
5
+ let isSvgMode = false;
6
+ let queuePending = false;
7
+ const win = typeof window !== 'undefined' ? window : {};
8
+ const doc = win.document || { head: {} };
9
+ const plt = {
10
+ $flags$: 0,
11
+ $resourcesUrl$: '',
12
+ jmp: (h) => h(),
13
+ raf: (h) => requestAnimationFrame(h),
14
+ ael: (el, eventName, listener, opts) => el.addEventListener(eventName, listener, opts),
15
+ rel: (el, eventName, listener, opts) => el.removeEventListener(eventName, listener, opts),
16
+ ce: (eventName, opts) => new CustomEvent(eventName, opts),
17
+ };
18
+ const promiseResolve = (v) => Promise.resolve(v);
19
+ const supportsConstructibleStylesheets = /*@__PURE__*/ (() => {
20
+ try {
21
+ new CSSStyleSheet();
22
+ return typeof new CSSStyleSheet().replace === 'function';
23
+ }
24
+ catch (e) { }
25
+ return false;
26
+ })()
27
+ ;
28
+ const addHostEventListeners = (elm, hostRef, listeners, attachParentListeners) => {
29
+ if (listeners) {
30
+ listeners.map(([flags, name, method]) => {
31
+ const target = elm;
32
+ const handler = hostListenerProxy(hostRef, method);
33
+ const opts = hostListenerOpts(flags);
34
+ plt.ael(target, name, handler, opts);
35
+ (hostRef.$rmListeners$ = hostRef.$rmListeners$ || []).push(() => plt.rel(target, name, handler, opts));
36
+ });
37
+ }
38
+ };
39
+ const hostListenerProxy = (hostRef, methodName) => (ev) => {
40
+ try {
41
+ {
42
+ if (hostRef.$flags$ & 256 /* isListenReady */) {
43
+ // instance is ready, let's call it's member method for this event
44
+ hostRef.$lazyInstance$[methodName](ev);
45
+ }
46
+ else {
47
+ (hostRef.$queuedListeners$ = hostRef.$queuedListeners$ || []).push([methodName, ev]);
48
+ }
49
+ }
50
+ }
51
+ catch (e) {
52
+ consoleError(e);
53
+ }
54
+ };
55
+ // prettier-ignore
56
+ const hostListenerOpts = (flags) => (flags & 2 /* Capture */) !== 0;
57
+ const HYDRATED_CSS = '{visibility:hidden}.hydrated{visibility:inherit}';
58
+ const createTime = (fnName, tagName = '') => {
59
+ {
60
+ return () => {
61
+ return;
62
+ };
63
+ }
64
+ };
65
+ const uniqueTime = (key, measureText) => {
66
+ {
67
+ return () => {
68
+ return;
69
+ };
70
+ }
71
+ };
72
+ const rootAppliedStyles = new WeakMap();
73
+ const registerStyle = (scopeId, cssText, allowCS) => {
74
+ let style = styles.get(scopeId);
75
+ if (supportsConstructibleStylesheets && allowCS) {
76
+ style = (style || new CSSStyleSheet());
77
+ style.replace(cssText);
78
+ }
79
+ else {
80
+ style = cssText;
81
+ }
82
+ styles.set(scopeId, style);
83
+ };
84
+ const addStyle = (styleContainerNode, cmpMeta, mode, hostElm) => {
85
+ let scopeId = getScopeId(cmpMeta);
86
+ let style = styles.get(scopeId);
87
+ // if an element is NOT connected then getRootNode() will return the wrong root node
88
+ // so the fallback is to always use the document for the root node in those cases
89
+ styleContainerNode = styleContainerNode.nodeType === 11 /* DocumentFragment */ ? styleContainerNode : doc;
90
+ if (style) {
91
+ if (typeof style === 'string') {
92
+ styleContainerNode = styleContainerNode.head || styleContainerNode;
93
+ let appliedStyles = rootAppliedStyles.get(styleContainerNode);
94
+ let styleElm;
95
+ if (!appliedStyles) {
96
+ rootAppliedStyles.set(styleContainerNode, (appliedStyles = new Set()));
97
+ }
98
+ if (!appliedStyles.has(scopeId)) {
99
+ {
100
+ {
101
+ styleElm = doc.createElement('style');
102
+ styleElm.innerHTML = style;
103
+ }
104
+ styleContainerNode.insertBefore(styleElm, styleContainerNode.querySelector('link'));
105
+ }
106
+ if (appliedStyles) {
107
+ appliedStyles.add(scopeId);
108
+ }
109
+ }
110
+ }
111
+ else if (!styleContainerNode.adoptedStyleSheets.includes(style)) {
112
+ styleContainerNode.adoptedStyleSheets = [...styleContainerNode.adoptedStyleSheets, style];
113
+ }
114
+ }
115
+ return scopeId;
116
+ };
117
+ const attachStyles = (hostRef) => {
118
+ const cmpMeta = hostRef.$cmpMeta$;
119
+ const elm = hostRef.$hostElement$;
120
+ const flags = cmpMeta.$flags$;
121
+ const endAttachStyles = createTime('attachStyles', cmpMeta.$tagName$);
122
+ const scopeId = addStyle(elm.shadowRoot ? elm.shadowRoot : elm.getRootNode(), cmpMeta);
123
+ if (flags & 10 /* needsScopedEncapsulation */) {
124
+ // only required when we're NOT using native shadow dom (slot)
125
+ // or this browser doesn't support native shadow dom
126
+ // and this host element was NOT created with SSR
127
+ // let's pick out the inner content for slot projection
128
+ // create a node to represent where the original
129
+ // content was first placed, which is useful later on
130
+ // DOM WRITE!!
131
+ elm['s-sc'] = scopeId;
132
+ elm.classList.add(scopeId + '-h');
133
+ }
134
+ endAttachStyles();
135
+ };
136
+ const getScopeId = (cmp, mode) => 'sc-' + (cmp.$tagName$);
137
+ /**
138
+ * Default style mode id
139
+ */
140
+ /**
141
+ * Reusable empty obj/array
142
+ * Don't add values to these!!
143
+ */
144
+ const EMPTY_OBJ = {};
145
+ /**
146
+ * Namespaces
147
+ */
148
+ const SVG_NS = 'http://www.w3.org/2000/svg';
149
+ const HTML_NS = 'http://www.w3.org/1999/xhtml';
150
+ const isDef = (v) => v != null;
151
+ const isComplexType = (o) => {
152
+ // https://jsperf.com/typeof-fn-object/5
153
+ o = typeof o;
154
+ return o === 'object' || o === 'function';
155
+ };
156
+ /**
157
+ * Production h() function based on Preact by
158
+ * Jason Miller (@developit)
159
+ * Licensed under the MIT License
160
+ * https://github.com/developit/preact/blob/master/LICENSE
161
+ *
162
+ * Modified for Stencil's compiler and vdom
163
+ */
164
+ // const stack: any[] = [];
165
+ // export function h(nodeName: string | d.FunctionalComponent, vnodeData: d.PropsType, child?: d.ChildType): d.VNode;
166
+ // export function h(nodeName: string | d.FunctionalComponent, vnodeData: d.PropsType, ...children: d.ChildType[]): d.VNode;
167
+ const h = (nodeName, vnodeData, ...children) => {
168
+ let child = null;
169
+ let simple = false;
170
+ let lastSimple = false;
171
+ let vNodeChildren = [];
172
+ const walk = (c) => {
173
+ for (let i = 0; i < c.length; i++) {
174
+ child = c[i];
175
+ if (Array.isArray(child)) {
176
+ walk(child);
177
+ }
178
+ else if (child != null && typeof child !== 'boolean') {
179
+ if ((simple = typeof nodeName !== 'function' && !isComplexType(child))) {
180
+ child = String(child);
181
+ }
182
+ if (simple && lastSimple) {
183
+ // If the previous child was simple (string), we merge both
184
+ vNodeChildren[vNodeChildren.length - 1].$text$ += child;
185
+ }
186
+ else {
187
+ // Append a new vNode, if it's text, we create a text vNode
188
+ vNodeChildren.push(simple ? newVNode(null, child) : child);
189
+ }
190
+ lastSimple = simple;
191
+ }
192
+ }
193
+ };
194
+ walk(children);
195
+ if (vnodeData) {
196
+ {
197
+ const classData = vnodeData.className || vnodeData.class;
198
+ if (classData) {
199
+ vnodeData.class =
200
+ typeof classData !== 'object'
201
+ ? classData
202
+ : Object.keys(classData)
203
+ .filter((k) => classData[k])
204
+ .join(' ');
205
+ }
206
+ }
207
+ }
208
+ const vnode = newVNode(nodeName, null);
209
+ vnode.$attrs$ = vnodeData;
210
+ if (vNodeChildren.length > 0) {
211
+ vnode.$children$ = vNodeChildren;
212
+ }
213
+ return vnode;
214
+ };
215
+ const newVNode = (tag, text) => {
216
+ const vnode = {
217
+ $flags$: 0,
218
+ $tag$: tag,
219
+ $text$: text,
220
+ $elm$: null,
221
+ $children$: null,
222
+ };
223
+ {
224
+ vnode.$attrs$ = null;
225
+ }
226
+ return vnode;
227
+ };
228
+ const Host = {};
229
+ const isHost = (node) => node && node.$tag$ === Host;
230
+ /**
231
+ * Production setAccessor() function based on Preact by
232
+ * Jason Miller (@developit)
233
+ * Licensed under the MIT License
234
+ * https://github.com/developit/preact/blob/master/LICENSE
235
+ *
236
+ * Modified for Stencil's compiler and vdom
237
+ */
238
+ const setAccessor = (elm, memberName, oldValue, newValue, isSvg, flags) => {
239
+ if (oldValue !== newValue) {
240
+ let isProp = isMemberInElement(elm, memberName);
241
+ let ln = memberName.toLowerCase();
242
+ if (memberName === 'class') {
243
+ const classList = elm.classList;
244
+ const oldClasses = parseClassList(oldValue);
245
+ const newClasses = parseClassList(newValue);
246
+ classList.remove(...oldClasses.filter((c) => c && !newClasses.includes(c)));
247
+ classList.add(...newClasses.filter((c) => c && !oldClasses.includes(c)));
248
+ }
249
+ else if (memberName === 'style') {
250
+ // update style attribute, css properties and values
251
+ {
252
+ for (const prop in oldValue) {
253
+ if (!newValue || newValue[prop] == null) {
254
+ if (prop.includes('-')) {
255
+ elm.style.removeProperty(prop);
256
+ }
257
+ else {
258
+ elm.style[prop] = '';
259
+ }
260
+ }
261
+ }
262
+ }
263
+ for (const prop in newValue) {
264
+ if (!oldValue || newValue[prop] !== oldValue[prop]) {
265
+ if (prop.includes('-')) {
266
+ elm.style.setProperty(prop, newValue[prop]);
267
+ }
268
+ else {
269
+ elm.style[prop] = newValue[prop];
270
+ }
271
+ }
272
+ }
273
+ }
274
+ else if (memberName === 'ref') {
275
+ // minifier will clean this up
276
+ if (newValue) {
277
+ newValue(elm);
278
+ }
279
+ }
280
+ else if ((!isProp ) &&
281
+ memberName[0] === 'o' &&
282
+ memberName[1] === 'n') {
283
+ // Event Handlers
284
+ // so if the member name starts with "on" and the 3rd characters is
285
+ // a capital letter, and it's not already a member on the element,
286
+ // then we're assuming it's an event listener
287
+ if (memberName[2] === '-') {
288
+ // on- prefixed events
289
+ // allows to be explicit about the dom event to listen without any magic
290
+ // under the hood:
291
+ // <my-cmp on-click> // listens for "click"
292
+ // <my-cmp on-Click> // listens for "Click"
293
+ // <my-cmp on-ionChange> // listens for "ionChange"
294
+ // <my-cmp on-EVENTS> // listens for "EVENTS"
295
+ memberName = memberName.slice(3);
296
+ }
297
+ else if (isMemberInElement(win, ln)) {
298
+ // standard event
299
+ // the JSX attribute could have been "onMouseOver" and the
300
+ // member name "onmouseover" is on the window's prototype
301
+ // so let's add the listener "mouseover", which is all lowercased
302
+ memberName = ln.slice(2);
303
+ }
304
+ else {
305
+ // custom event
306
+ // the JSX attribute could have been "onMyCustomEvent"
307
+ // so let's trim off the "on" prefix and lowercase the first character
308
+ // and add the listener "myCustomEvent"
309
+ // except for the first character, we keep the event name case
310
+ memberName = ln[2] + memberName.slice(3);
311
+ }
312
+ if (oldValue) {
313
+ plt.rel(elm, memberName, oldValue, false);
314
+ }
315
+ if (newValue) {
316
+ plt.ael(elm, memberName, newValue, false);
317
+ }
318
+ }
319
+ else {
320
+ // Set property if it exists and it's not a SVG
321
+ const isComplex = isComplexType(newValue);
322
+ if ((isProp || (isComplex && newValue !== null)) && !isSvg) {
323
+ try {
324
+ if (!elm.tagName.includes('-')) {
325
+ let n = newValue == null ? '' : newValue;
326
+ // Workaround for Safari, moving the <input> caret when re-assigning the same valued
327
+ if (memberName === 'list') {
328
+ isProp = false;
329
+ }
330
+ else if (oldValue == null || elm[memberName] != n) {
331
+ elm[memberName] = n;
332
+ }
333
+ }
334
+ else {
335
+ elm[memberName] = newValue;
336
+ }
337
+ }
338
+ catch (e) { }
339
+ }
340
+ if (newValue == null || newValue === false) {
341
+ if (newValue !== false || elm.getAttribute(memberName) === '') {
342
+ {
343
+ elm.removeAttribute(memberName);
344
+ }
345
+ }
346
+ }
347
+ else if ((!isProp || flags & 4 /* isHost */ || isSvg) && !isComplex) {
348
+ newValue = newValue === true ? '' : newValue;
349
+ {
350
+ elm.setAttribute(memberName, newValue);
351
+ }
352
+ }
353
+ }
354
+ }
355
+ };
356
+ const parseClassListRegex = /\s/;
357
+ const parseClassList = (value) => (!value ? [] : value.split(parseClassListRegex));
358
+ const updateElement = (oldVnode, newVnode, isSvgMode, memberName) => {
359
+ // if the element passed in is a shadow root, which is a document fragment
360
+ // then we want to be adding attrs/props to the shadow root's "host" element
361
+ // if it's not a shadow root, then we add attrs/props to the same element
362
+ const elm = newVnode.$elm$.nodeType === 11 /* DocumentFragment */ && newVnode.$elm$.host
363
+ ? newVnode.$elm$.host
364
+ : newVnode.$elm$;
365
+ const oldVnodeAttrs = (oldVnode && oldVnode.$attrs$) || EMPTY_OBJ;
366
+ const newVnodeAttrs = newVnode.$attrs$ || EMPTY_OBJ;
367
+ {
368
+ // remove attributes no longer present on the vnode by setting them to undefined
369
+ for (memberName in oldVnodeAttrs) {
370
+ if (!(memberName in newVnodeAttrs)) {
371
+ setAccessor(elm, memberName, oldVnodeAttrs[memberName], undefined, isSvgMode, newVnode.$flags$);
372
+ }
373
+ }
374
+ }
375
+ // add new & update changed attributes
376
+ for (memberName in newVnodeAttrs) {
377
+ setAccessor(elm, memberName, oldVnodeAttrs[memberName], newVnodeAttrs[memberName], isSvgMode, newVnode.$flags$);
378
+ }
379
+ };
380
+ const createElm = (oldParentVNode, newParentVNode, childIndex, parentElm) => {
381
+ // tslint:disable-next-line: prefer-const
382
+ let newVNode = newParentVNode.$children$[childIndex];
383
+ let i = 0;
384
+ let elm;
385
+ let childNode;
386
+ if (newVNode.$text$ !== null) {
387
+ // create text node
388
+ elm = newVNode.$elm$ = doc.createTextNode(newVNode.$text$);
389
+ }
390
+ else {
391
+ if (!isSvgMode) {
392
+ isSvgMode = newVNode.$tag$ === 'svg';
393
+ }
394
+ // create element
395
+ elm = newVNode.$elm$ = (doc.createElementNS(isSvgMode ? SVG_NS : HTML_NS, newVNode.$tag$)
396
+ );
397
+ if (isSvgMode && newVNode.$tag$ === 'foreignObject') {
398
+ isSvgMode = false;
399
+ }
400
+ // add css classes, attrs, props, listeners, etc.
401
+ {
402
+ updateElement(null, newVNode, isSvgMode);
403
+ }
404
+ if (isDef(scopeId) && elm['s-si'] !== scopeId) {
405
+ // if there is a scopeId and this is the initial render
406
+ // then let's add the scopeId as a css class
407
+ elm.classList.add((elm['s-si'] = scopeId));
408
+ }
409
+ if (newVNode.$children$) {
410
+ for (i = 0; i < newVNode.$children$.length; ++i) {
411
+ // create the node
412
+ childNode = createElm(oldParentVNode, newVNode, i);
413
+ // return node could have been null
414
+ if (childNode) {
415
+ // append our new node
416
+ elm.appendChild(childNode);
417
+ }
418
+ }
419
+ }
420
+ {
421
+ if (newVNode.$tag$ === 'svg') {
422
+ // Only reset the SVG context when we're exiting <svg> element
423
+ isSvgMode = false;
424
+ }
425
+ else if (elm.tagName === 'foreignObject') {
426
+ // Reenter SVG context when we're exiting <foreignObject> element
427
+ isSvgMode = true;
428
+ }
429
+ }
430
+ }
431
+ return elm;
432
+ };
433
+ const addVnodes = (parentElm, before, parentVNode, vnodes, startIdx, endIdx) => {
434
+ let containerElm = (parentElm);
435
+ let childNode;
436
+ if (containerElm.shadowRoot && containerElm.tagName === hostTagName) {
437
+ containerElm = containerElm.shadowRoot;
438
+ }
439
+ for (; startIdx <= endIdx; ++startIdx) {
440
+ if (vnodes[startIdx]) {
441
+ childNode = createElm(null, parentVNode, startIdx);
442
+ if (childNode) {
443
+ vnodes[startIdx].$elm$ = childNode;
444
+ containerElm.insertBefore(childNode, before);
445
+ }
446
+ }
447
+ }
448
+ };
449
+ const removeVnodes = (vnodes, startIdx, endIdx, vnode, elm) => {
450
+ for (; startIdx <= endIdx; ++startIdx) {
451
+ if ((vnode = vnodes[startIdx])) {
452
+ elm = vnode.$elm$;
453
+ callNodeRefs(vnode);
454
+ // remove the vnode's element from the dom
455
+ elm.remove();
456
+ }
457
+ }
458
+ };
459
+ const updateChildren = (parentElm, oldCh, newVNode, newCh) => {
460
+ let oldStartIdx = 0;
461
+ let newStartIdx = 0;
462
+ let oldEndIdx = oldCh.length - 1;
463
+ let oldStartVnode = oldCh[0];
464
+ let oldEndVnode = oldCh[oldEndIdx];
465
+ let newEndIdx = newCh.length - 1;
466
+ let newStartVnode = newCh[0];
467
+ let newEndVnode = newCh[newEndIdx];
468
+ let node;
469
+ while (oldStartIdx <= oldEndIdx && newStartIdx <= newEndIdx) {
470
+ if (oldStartVnode == null) {
471
+ // Vnode might have been moved left
472
+ oldStartVnode = oldCh[++oldStartIdx];
473
+ }
474
+ else if (oldEndVnode == null) {
475
+ oldEndVnode = oldCh[--oldEndIdx];
476
+ }
477
+ else if (newStartVnode == null) {
478
+ newStartVnode = newCh[++newStartIdx];
479
+ }
480
+ else if (newEndVnode == null) {
481
+ newEndVnode = newCh[--newEndIdx];
482
+ }
483
+ else if (isSameVnode(oldStartVnode, newStartVnode)) {
484
+ patch(oldStartVnode, newStartVnode);
485
+ oldStartVnode = oldCh[++oldStartIdx];
486
+ newStartVnode = newCh[++newStartIdx];
487
+ }
488
+ else if (isSameVnode(oldEndVnode, newEndVnode)) {
489
+ patch(oldEndVnode, newEndVnode);
490
+ oldEndVnode = oldCh[--oldEndIdx];
491
+ newEndVnode = newCh[--newEndIdx];
492
+ }
493
+ else if (isSameVnode(oldStartVnode, newEndVnode)) {
494
+ patch(oldStartVnode, newEndVnode);
495
+ parentElm.insertBefore(oldStartVnode.$elm$, oldEndVnode.$elm$.nextSibling);
496
+ oldStartVnode = oldCh[++oldStartIdx];
497
+ newEndVnode = newCh[--newEndIdx];
498
+ }
499
+ else if (isSameVnode(oldEndVnode, newStartVnode)) {
500
+ patch(oldEndVnode, newStartVnode);
501
+ parentElm.insertBefore(oldEndVnode.$elm$, oldStartVnode.$elm$);
502
+ oldEndVnode = oldCh[--oldEndIdx];
503
+ newStartVnode = newCh[++newStartIdx];
504
+ }
505
+ else {
506
+ {
507
+ // new element
508
+ node = createElm(oldCh && oldCh[newStartIdx], newVNode, newStartIdx);
509
+ newStartVnode = newCh[++newStartIdx];
510
+ }
511
+ if (node) {
512
+ {
513
+ oldStartVnode.$elm$.parentNode.insertBefore(node, oldStartVnode.$elm$);
514
+ }
515
+ }
516
+ }
517
+ }
518
+ if (oldStartIdx > oldEndIdx) {
519
+ addVnodes(parentElm, newCh[newEndIdx + 1] == null ? null : newCh[newEndIdx + 1].$elm$, newVNode, newCh, newStartIdx, newEndIdx);
520
+ }
521
+ else if (newStartIdx > newEndIdx) {
522
+ removeVnodes(oldCh, oldStartIdx, oldEndIdx);
523
+ }
524
+ };
525
+ const isSameVnode = (vnode1, vnode2) => {
526
+ // compare if two vnode to see if they're "technically" the same
527
+ // need to have the same element tag, and same key to be the same
528
+ if (vnode1.$tag$ === vnode2.$tag$) {
529
+ return true;
530
+ }
531
+ return false;
532
+ };
533
+ const patch = (oldVNode, newVNode) => {
534
+ const elm = (newVNode.$elm$ = oldVNode.$elm$);
535
+ const oldChildren = oldVNode.$children$;
536
+ const newChildren = newVNode.$children$;
537
+ const tag = newVNode.$tag$;
538
+ const text = newVNode.$text$;
539
+ if (text === null) {
540
+ {
541
+ // test if we're rendering an svg element, or still rendering nodes inside of one
542
+ // only add this to the when the compiler sees we're using an svg somewhere
543
+ isSvgMode = tag === 'svg' ? true : tag === 'foreignObject' ? false : isSvgMode;
544
+ }
545
+ // element node
546
+ {
547
+ if (tag === 'slot')
548
+ ;
549
+ else {
550
+ // either this is the first render of an element OR it's an update
551
+ // AND we already know it's possible it could have changed
552
+ // this updates the element's css classes, attrs, props, listeners, etc.
553
+ updateElement(oldVNode, newVNode, isSvgMode);
554
+ }
555
+ }
556
+ if (oldChildren !== null && newChildren !== null) {
557
+ // looks like there's child vnodes for both the old and new vnodes
558
+ updateChildren(elm, oldChildren, newVNode, newChildren);
559
+ }
560
+ else if (newChildren !== null) {
561
+ // no old child vnodes, but there are new child vnodes to add
562
+ if (oldVNode.$text$ !== null) {
563
+ // the old vnode was text, so be sure to clear it out
564
+ elm.textContent = '';
565
+ }
566
+ // add the new vnode children
567
+ addVnodes(elm, null, newVNode, newChildren, 0, newChildren.length - 1);
568
+ }
569
+ else if (oldChildren !== null) {
570
+ // no new child vnodes, but there are old child vnodes to remove
571
+ removeVnodes(oldChildren, 0, oldChildren.length - 1);
572
+ }
573
+ if (isSvgMode && tag === 'svg') {
574
+ isSvgMode = false;
575
+ }
576
+ }
577
+ else if (oldVNode.$text$ !== text) {
578
+ // update the text content for the text only vnode
579
+ // and also only if the text is different than before
580
+ elm.data = text;
581
+ }
582
+ };
583
+ const callNodeRefs = (vNode) => {
584
+ {
585
+ vNode.$attrs$ && vNode.$attrs$.ref && vNode.$attrs$.ref(null);
586
+ vNode.$children$ && vNode.$children$.map(callNodeRefs);
587
+ }
588
+ };
589
+ const renderVdom = (hostRef, renderFnResults) => {
590
+ const hostElm = hostRef.$hostElement$;
591
+ const cmpMeta = hostRef.$cmpMeta$;
592
+ const oldVNode = hostRef.$vnode$ || newVNode(null, null);
593
+ const rootVnode = isHost(renderFnResults) ? renderFnResults : h(null, null, renderFnResults);
594
+ hostTagName = hostElm.tagName;
595
+ if (cmpMeta.$attrsToReflect$) {
596
+ rootVnode.$attrs$ = rootVnode.$attrs$ || {};
597
+ cmpMeta.$attrsToReflect$.map(([propName, attribute]) => (rootVnode.$attrs$[attribute] = hostElm[propName]));
598
+ }
599
+ rootVnode.$tag$ = null;
600
+ rootVnode.$flags$ |= 4 /* isHost */;
601
+ hostRef.$vnode$ = rootVnode;
602
+ rootVnode.$elm$ = oldVNode.$elm$ = (hostElm.shadowRoot || hostElm );
603
+ {
604
+ scopeId = hostElm['s-sc'];
605
+ }
606
+ // synchronous patch
607
+ patch(oldVNode, rootVnode);
608
+ };
609
+ const getElement = (ref) => (getHostRef(ref).$hostElement$ );
610
+ const createEvent = (ref, name, flags) => {
611
+ const elm = getElement(ref);
612
+ return {
613
+ emit: (detail) => {
614
+ return emitEvent(elm, name, {
615
+ bubbles: !!(flags & 4 /* Bubbles */),
616
+ composed: !!(flags & 2 /* Composed */),
617
+ cancelable: !!(flags & 1 /* Cancellable */),
618
+ detail,
619
+ });
620
+ },
621
+ };
622
+ };
623
+ /**
624
+ * Helper function to create & dispatch a custom Event on a provided target
625
+ * @param elm the target of the Event
626
+ * @param name the name to give the custom Event
627
+ * @param opts options for configuring a custom Event
628
+ * @returns the custom Event
629
+ */
630
+ const emitEvent = (elm, name, opts) => {
631
+ const ev = plt.ce(name, opts);
632
+ elm.dispatchEvent(ev);
633
+ return ev;
634
+ };
635
+ const attachToAncestor = (hostRef, ancestorComponent) => {
636
+ if (ancestorComponent && !hostRef.$onRenderResolve$ && ancestorComponent['s-p']) {
637
+ ancestorComponent['s-p'].push(new Promise((r) => (hostRef.$onRenderResolve$ = r)));
638
+ }
639
+ };
640
+ const scheduleUpdate = (hostRef, isInitialLoad) => {
641
+ {
642
+ hostRef.$flags$ |= 16 /* isQueuedForUpdate */;
643
+ }
644
+ if (hostRef.$flags$ & 4 /* isWaitingForChildren */) {
645
+ hostRef.$flags$ |= 512 /* needsRerender */;
646
+ return;
647
+ }
648
+ attachToAncestor(hostRef, hostRef.$ancestorComponent$);
649
+ // there is no ancestor component or the ancestor component
650
+ // has already fired off its lifecycle update then
651
+ // fire off the initial update
652
+ const dispatch = () => dispatchHooks(hostRef, isInitialLoad);
653
+ return writeTask(dispatch) ;
654
+ };
655
+ const dispatchHooks = (hostRef, isInitialLoad) => {
656
+ const endSchedule = createTime('scheduleUpdate', hostRef.$cmpMeta$.$tagName$);
657
+ const instance = hostRef.$lazyInstance$ ;
658
+ let promise;
659
+ if (isInitialLoad) {
660
+ {
661
+ hostRef.$flags$ |= 256 /* isListenReady */;
662
+ if (hostRef.$queuedListeners$) {
663
+ hostRef.$queuedListeners$.map(([methodName, event]) => safeCall(instance, methodName, event));
664
+ hostRef.$queuedListeners$ = null;
665
+ }
666
+ }
667
+ {
668
+ promise = safeCall(instance, 'componentWillLoad');
669
+ }
670
+ }
671
+ endSchedule();
672
+ return then(promise, () => updateComponent(hostRef, instance, isInitialLoad));
673
+ };
674
+ const updateComponent = async (hostRef, instance, isInitialLoad) => {
675
+ // updateComponent
676
+ const elm = hostRef.$hostElement$;
677
+ const endUpdate = createTime('update', hostRef.$cmpMeta$.$tagName$);
678
+ const rc = elm['s-rc'];
679
+ if (isInitialLoad) {
680
+ // DOM WRITE!
681
+ attachStyles(hostRef);
682
+ }
683
+ const endRender = createTime('render', hostRef.$cmpMeta$.$tagName$);
684
+ {
685
+ callRender(hostRef, instance);
686
+ }
687
+ if (rc) {
688
+ // ok, so turns out there are some child host elements
689
+ // waiting on this parent element to load
690
+ // let's fire off all update callbacks waiting
691
+ rc.map((cb) => cb());
692
+ elm['s-rc'] = undefined;
693
+ }
694
+ endRender();
695
+ endUpdate();
696
+ {
697
+ const childrenPromises = elm['s-p'];
698
+ const postUpdate = () => postUpdateComponent(hostRef);
699
+ if (childrenPromises.length === 0) {
700
+ postUpdate();
701
+ }
702
+ else {
703
+ Promise.all(childrenPromises).then(postUpdate);
704
+ hostRef.$flags$ |= 4 /* isWaitingForChildren */;
705
+ childrenPromises.length = 0;
706
+ }
707
+ }
708
+ };
709
+ const callRender = (hostRef, instance, elm) => {
710
+ try {
711
+ instance = instance.render() ;
712
+ {
713
+ hostRef.$flags$ &= ~16 /* isQueuedForUpdate */;
714
+ }
715
+ {
716
+ hostRef.$flags$ |= 2 /* hasRendered */;
717
+ }
718
+ {
719
+ {
720
+ // looks like we've got child nodes to render into this host element
721
+ // or we need to update the css class/attrs on the host element
722
+ // DOM WRITE!
723
+ {
724
+ renderVdom(hostRef, instance);
725
+ }
726
+ }
727
+ }
728
+ }
729
+ catch (e) {
730
+ consoleError(e, hostRef.$hostElement$);
731
+ }
732
+ return null;
733
+ };
734
+ const postUpdateComponent = (hostRef) => {
735
+ const tagName = hostRef.$cmpMeta$.$tagName$;
736
+ const elm = hostRef.$hostElement$;
737
+ const endPostUpdate = createTime('postUpdate', tagName);
738
+ const instance = hostRef.$lazyInstance$ ;
739
+ const ancestorComponent = hostRef.$ancestorComponent$;
740
+ if (!(hostRef.$flags$ & 64 /* hasLoadedComponent */)) {
741
+ hostRef.$flags$ |= 64 /* hasLoadedComponent */;
742
+ {
743
+ // DOM WRITE!
744
+ addHydratedFlag(elm);
745
+ }
746
+ {
747
+ safeCall(instance, 'componentDidLoad');
748
+ }
749
+ endPostUpdate();
750
+ {
751
+ hostRef.$onReadyResolve$(elm);
752
+ if (!ancestorComponent) {
753
+ appDidLoad();
754
+ }
755
+ }
756
+ }
757
+ else {
758
+ endPostUpdate();
759
+ }
760
+ {
761
+ hostRef.$onInstanceResolve$(elm);
762
+ }
763
+ // load events fire from bottom to top
764
+ // the deepest elements load first then bubbles up
765
+ {
766
+ if (hostRef.$onRenderResolve$) {
767
+ hostRef.$onRenderResolve$();
768
+ hostRef.$onRenderResolve$ = undefined;
769
+ }
770
+ if (hostRef.$flags$ & 512 /* needsRerender */) {
771
+ nextTick(() => scheduleUpdate(hostRef, false));
772
+ }
773
+ hostRef.$flags$ &= ~(4 /* isWaitingForChildren */ | 512 /* needsRerender */);
774
+ }
775
+ // ( •_•)
776
+ // ( •_•)>⌐■-■
777
+ // (⌐■_■)
778
+ };
779
+ const appDidLoad = (who) => {
780
+ // on appload
781
+ // we have finish the first big initial render
782
+ {
783
+ addHydratedFlag(doc.documentElement);
784
+ }
785
+ nextTick(() => emitEvent(win, 'appload', { detail: { namespace: NAMESPACE } }));
786
+ };
787
+ const safeCall = (instance, method, arg) => {
788
+ if (instance && instance[method]) {
789
+ try {
790
+ return instance[method](arg);
791
+ }
792
+ catch (e) {
793
+ consoleError(e);
794
+ }
795
+ }
796
+ return undefined;
797
+ };
798
+ const then = (promise, thenFn) => {
799
+ return promise && promise.then ? promise.then(thenFn) : thenFn();
800
+ };
801
+ const addHydratedFlag = (elm) => elm.classList.add('hydrated')
802
+ ;
803
+ const parsePropertyValue = (propValue, propType) => {
804
+ // ensure this value is of the correct prop type
805
+ if (propValue != null && !isComplexType(propValue)) {
806
+ if (propType & 4 /* Boolean */) {
807
+ // per the HTML spec, any string value means it is a boolean true value
808
+ // but we'll cheat here and say that the string "false" is the boolean false
809
+ return propValue === 'false' ? false : propValue === '' || !!propValue;
810
+ }
811
+ if (propType & 2 /* Number */) {
812
+ // force it to be a number
813
+ return parseFloat(propValue);
814
+ }
815
+ if (propType & 1 /* String */) {
816
+ // could have been passed as a number or boolean
817
+ // but we still want it as a string
818
+ return String(propValue);
819
+ }
820
+ // redundant return here for better minification
821
+ return propValue;
822
+ }
823
+ // not sure exactly what type we want
824
+ // so no need to change to a different type
825
+ return propValue;
826
+ };
827
+ const getValue = (ref, propName) => getHostRef(ref).$instanceValues$.get(propName);
828
+ const setValue = (ref, propName, newVal, cmpMeta) => {
829
+ // check our new property value against our internal value
830
+ const hostRef = getHostRef(ref);
831
+ const elm = hostRef.$hostElement$ ;
832
+ const oldVal = hostRef.$instanceValues$.get(propName);
833
+ const flags = hostRef.$flags$;
834
+ const instance = hostRef.$lazyInstance$ ;
835
+ newVal = parsePropertyValue(newVal, cmpMeta.$members$[propName][0]);
836
+ if ((!(flags & 8 /* isConstructingInstance */) || oldVal === undefined) && newVal !== oldVal) {
837
+ // gadzooks! the property's value has changed!!
838
+ // set our new value!
839
+ hostRef.$instanceValues$.set(propName, newVal);
840
+ if (instance) {
841
+ // get an array of method names of watch functions to call
842
+ if (cmpMeta.$watchers$ && flags & 128 /* isWatchReady */) {
843
+ const watchMethods = cmpMeta.$watchers$[propName];
844
+ if (watchMethods) {
845
+ // this instance is watching for when this property changed
846
+ watchMethods.map((watchMethodName) => {
847
+ try {
848
+ // fire off each of the watch methods that are watching this property
849
+ instance[watchMethodName](newVal, oldVal, propName);
850
+ }
851
+ catch (e) {
852
+ consoleError(e, elm);
853
+ }
854
+ });
855
+ }
856
+ }
857
+ if ((flags & (2 /* hasRendered */ | 16 /* isQueuedForUpdate */)) === 2 /* hasRendered */) {
858
+ // looks like this value actually changed, so we've got work to do!
859
+ // but only if we've already rendered, otherwise just chill out
860
+ // queue that we need to do an update, but don't worry about queuing
861
+ // up millions cuz this function ensures it only runs once
862
+ scheduleUpdate(hostRef, false);
863
+ }
864
+ }
865
+ }
866
+ };
867
+ const proxyComponent = (Cstr, cmpMeta, flags) => {
868
+ if (cmpMeta.$members$) {
869
+ if (Cstr.watchers) {
870
+ cmpMeta.$watchers$ = Cstr.watchers;
871
+ }
872
+ // It's better to have a const than two Object.entries()
873
+ const members = Object.entries(cmpMeta.$members$);
874
+ const prototype = Cstr.prototype;
875
+ members.map(([memberName, [memberFlags]]) => {
876
+ if ((memberFlags & 31 /* Prop */ ||
877
+ ((flags & 2 /* proxyState */) && memberFlags & 32 /* State */))) {
878
+ // proxyComponent - prop
879
+ Object.defineProperty(prototype, memberName, {
880
+ get() {
881
+ // proxyComponent, get value
882
+ return getValue(this, memberName);
883
+ },
884
+ set(newValue) {
885
+ // proxyComponent, set value
886
+ setValue(this, memberName, newValue, cmpMeta);
887
+ },
888
+ configurable: true,
889
+ enumerable: true,
890
+ });
891
+ }
892
+ else if (flags & 1 /* isElementConstructor */ &&
893
+ memberFlags & 64 /* Method */) {
894
+ // proxyComponent - method
895
+ Object.defineProperty(prototype, memberName, {
896
+ value(...args) {
897
+ const ref = getHostRef(this);
898
+ return ref.$onInstancePromise$.then(() => ref.$lazyInstance$[memberName](...args));
899
+ },
900
+ });
901
+ }
902
+ });
903
+ if ((flags & 1 /* isElementConstructor */)) {
904
+ const attrNameToPropName = new Map();
905
+ prototype.attributeChangedCallback = function (attrName, _oldValue, newValue) {
906
+ plt.jmp(() => {
907
+ const propName = attrNameToPropName.get(attrName);
908
+ // In a web component lifecycle the attributeChangedCallback runs prior to connectedCallback
909
+ // in the case where an attribute was set inline.
910
+ // ```html
911
+ // <my-component some-attribute="some-value"></my-component>
912
+ // ```
913
+ //
914
+ // There is an edge case where a developer sets the attribute inline on a custom element and then
915
+ // programmatically changes it before it has been upgraded as shown below:
916
+ //
917
+ // ```html
918
+ // <!-- this component has _not_ been upgraded yet -->
919
+ // <my-component id="test" some-attribute="some-value"></my-component>
920
+ // <script>
921
+ // // grab non-upgraded component
922
+ // el = document.querySelector("#test");
923
+ // el.someAttribute = "another-value";
924
+ // // upgrade component
925
+ // customElements.define('my-component', MyComponent);
926
+ // </script>
927
+ // ```
928
+ // In this case if we do not unshadow here and use the value of the shadowing property, attributeChangedCallback
929
+ // will be called with `newValue = "some-value"` and will set the shadowed property (this.someAttribute = "another-value")
930
+ // to the value that was set inline i.e. "some-value" from above example. When
931
+ // the connectedCallback attempts to unshadow it will use "some-value" as the initial value rather than "another-value"
932
+ //
933
+ // The case where the attribute was NOT set inline but was not set programmatically shall be handled/unshadowed
934
+ // by connectedCallback as this attributeChangedCallback will not fire.
935
+ //
936
+ // https://developers.google.com/web/fundamentals/web-components/best-practices#lazy-properties
937
+ //
938
+ // TODO(STENCIL-16) we should think about whether or not we actually want to be reflecting the attributes to
939
+ // properties here given that this goes against best practices outlined here
940
+ // https://developers.google.com/web/fundamentals/web-components/best-practices#avoid-reentrancy
941
+ if (this.hasOwnProperty(propName)) {
942
+ newValue = this[propName];
943
+ delete this[propName];
944
+ }
945
+ else if (prototype.hasOwnProperty(propName) &&
946
+ typeof this[propName] === 'number' &&
947
+ this[propName] == newValue) {
948
+ // if the propName exists on the prototype of `Cstr`, this update may be a result of Stencil using native
949
+ // APIs to reflect props as attributes. Calls to `setAttribute(someElement, propName)` will result in
950
+ // `propName` to be converted to a `DOMString`, which may not be what we want for other primitive props.
951
+ return;
952
+ }
953
+ this[propName] = newValue === null && typeof this[propName] === 'boolean' ? false : newValue;
954
+ });
955
+ };
956
+ // create an array of attributes to observe
957
+ // and also create a map of html attribute name to js property name
958
+ Cstr.observedAttributes = members
959
+ .filter(([_, m]) => m[0] & 15 /* HasAttribute */) // filter to only keep props that should match attributes
960
+ .map(([propName, m]) => {
961
+ const attrName = m[1] || propName;
962
+ attrNameToPropName.set(attrName, propName);
963
+ if (m[0] & 512 /* ReflectAttr */) {
964
+ cmpMeta.$attrsToReflect$.push([propName, attrName]);
965
+ }
966
+ return attrName;
967
+ });
968
+ }
969
+ }
970
+ return Cstr;
971
+ };
972
+ const initializeComponent = async (elm, hostRef, cmpMeta, hmrVersionId, Cstr) => {
973
+ // initializeComponent
974
+ if ((hostRef.$flags$ & 32 /* hasInitializedComponent */) === 0) {
975
+ {
976
+ // we haven't initialized this element yet
977
+ hostRef.$flags$ |= 32 /* hasInitializedComponent */;
978
+ // lazy loaded components
979
+ // request the component's implementation to be
980
+ // wired up with the host element
981
+ Cstr = loadModule(cmpMeta);
982
+ if (Cstr.then) {
983
+ // Await creates a micro-task avoid if possible
984
+ const endLoad = uniqueTime();
985
+ Cstr = await Cstr;
986
+ endLoad();
987
+ }
988
+ if (!Cstr.isProxied) {
989
+ // we've never proxied this Constructor before
990
+ // let's add the getters/setters to its prototype before
991
+ // the first time we create an instance of the implementation
992
+ {
993
+ cmpMeta.$watchers$ = Cstr.watchers;
994
+ }
995
+ proxyComponent(Cstr, cmpMeta, 2 /* proxyState */);
996
+ Cstr.isProxied = true;
997
+ }
998
+ const endNewInstance = createTime('createInstance', cmpMeta.$tagName$);
999
+ // ok, time to construct the instance
1000
+ // but let's keep track of when we start and stop
1001
+ // so that the getters/setters don't incorrectly step on data
1002
+ {
1003
+ hostRef.$flags$ |= 8 /* isConstructingInstance */;
1004
+ }
1005
+ // construct the lazy-loaded component implementation
1006
+ // passing the hostRef is very important during
1007
+ // construction in order to directly wire together the
1008
+ // host element and the lazy-loaded instance
1009
+ try {
1010
+ new Cstr(hostRef);
1011
+ }
1012
+ catch (e) {
1013
+ consoleError(e);
1014
+ }
1015
+ {
1016
+ hostRef.$flags$ &= ~8 /* isConstructingInstance */;
1017
+ }
1018
+ {
1019
+ hostRef.$flags$ |= 128 /* isWatchReady */;
1020
+ }
1021
+ endNewInstance();
1022
+ }
1023
+ if (Cstr.style) {
1024
+ // this component has styles but we haven't registered them yet
1025
+ let style = Cstr.style;
1026
+ const scopeId = getScopeId(cmpMeta);
1027
+ if (!styles.has(scopeId)) {
1028
+ const endRegisterStyles = createTime('registerStyles', cmpMeta.$tagName$);
1029
+ registerStyle(scopeId, style, !!(cmpMeta.$flags$ & 1 /* shadowDomEncapsulation */));
1030
+ endRegisterStyles();
1031
+ }
1032
+ }
1033
+ }
1034
+ // we've successfully created a lazy instance
1035
+ const ancestorComponent = hostRef.$ancestorComponent$;
1036
+ const schedule = () => scheduleUpdate(hostRef, true);
1037
+ if (ancestorComponent && ancestorComponent['s-rc']) {
1038
+ // this is the initial load and this component it has an ancestor component
1039
+ // but the ancestor component has NOT fired its will update lifecycle yet
1040
+ // so let's just cool our jets and wait for the ancestor to continue first
1041
+ // this will get fired off when the ancestor component
1042
+ // finally gets around to rendering its lazy self
1043
+ // fire off the initial update
1044
+ ancestorComponent['s-rc'].push(schedule);
1045
+ }
1046
+ else {
1047
+ schedule();
1048
+ }
1049
+ };
1050
+ const connectedCallback = (elm) => {
1051
+ if ((plt.$flags$ & 1 /* isTmpDisconnected */) === 0) {
1052
+ const hostRef = getHostRef(elm);
1053
+ const cmpMeta = hostRef.$cmpMeta$;
1054
+ const endConnected = createTime('connectedCallback', cmpMeta.$tagName$);
1055
+ if (!(hostRef.$flags$ & 1 /* hasConnected */)) {
1056
+ // first time this component has connected
1057
+ hostRef.$flags$ |= 1 /* hasConnected */;
1058
+ {
1059
+ // find the first ancestor component (if there is one) and register
1060
+ // this component as one of the actively loading child components for its ancestor
1061
+ let ancestorComponent = elm;
1062
+ while ((ancestorComponent = ancestorComponent.parentNode || ancestorComponent.host)) {
1063
+ // climb up the ancestors looking for the first
1064
+ // component that hasn't finished its lifecycle update yet
1065
+ if (ancestorComponent['s-p']) {
1066
+ // we found this components first ancestor component
1067
+ // keep a reference to this component's ancestor component
1068
+ attachToAncestor(hostRef, (hostRef.$ancestorComponent$ = ancestorComponent));
1069
+ break;
1070
+ }
1071
+ }
1072
+ }
1073
+ // Lazy properties
1074
+ // https://developers.google.com/web/fundamentals/web-components/best-practices#lazy-properties
1075
+ if (cmpMeta.$members$) {
1076
+ Object.entries(cmpMeta.$members$).map(([memberName, [memberFlags]]) => {
1077
+ if (memberFlags & 31 /* Prop */ && elm.hasOwnProperty(memberName)) {
1078
+ const value = elm[memberName];
1079
+ delete elm[memberName];
1080
+ elm[memberName] = value;
1081
+ }
1082
+ });
1083
+ }
1084
+ {
1085
+ initializeComponent(elm, hostRef, cmpMeta);
1086
+ }
1087
+ }
1088
+ else {
1089
+ // not the first time this has connected
1090
+ // reattach any event listeners to the host
1091
+ // since they would have been removed when disconnected
1092
+ addHostEventListeners(elm, hostRef, cmpMeta.$listeners$);
1093
+ }
1094
+ endConnected();
1095
+ }
1096
+ };
1097
+ const disconnectedCallback = (elm) => {
1098
+ if ((plt.$flags$ & 1 /* isTmpDisconnected */) === 0) {
1099
+ const hostRef = getHostRef(elm);
1100
+ const instance = hostRef.$lazyInstance$ ;
1101
+ {
1102
+ if (hostRef.$rmListeners$) {
1103
+ hostRef.$rmListeners$.map((rmListener) => rmListener());
1104
+ hostRef.$rmListeners$ = undefined;
1105
+ }
1106
+ }
1107
+ {
1108
+ safeCall(instance, 'disconnectedCallback');
1109
+ }
1110
+ }
1111
+ };
1112
+ const bootstrapLazy = (lazyBundles, options = {}) => {
1113
+ const endBootstrap = createTime();
1114
+ const cmpTags = [];
1115
+ const exclude = options.exclude || [];
1116
+ const customElements = win.customElements;
1117
+ const head = doc.head;
1118
+ const metaCharset = /*@__PURE__*/ head.querySelector('meta[charset]');
1119
+ const visibilityStyle = /*@__PURE__*/ doc.createElement('style');
1120
+ const deferredConnectedCallbacks = [];
1121
+ let appLoadFallback;
1122
+ let isBootstrapping = true;
1123
+ Object.assign(plt, options);
1124
+ plt.$resourcesUrl$ = new URL(options.resourcesUrl || './', doc.baseURI).href;
1125
+ lazyBundles.map((lazyBundle) => {
1126
+ lazyBundle[1].map((compactMeta) => {
1127
+ const cmpMeta = {
1128
+ $flags$: compactMeta[0],
1129
+ $tagName$: compactMeta[1],
1130
+ $members$: compactMeta[2],
1131
+ $listeners$: compactMeta[3],
1132
+ };
1133
+ {
1134
+ cmpMeta.$members$ = compactMeta[2];
1135
+ }
1136
+ {
1137
+ cmpMeta.$listeners$ = compactMeta[3];
1138
+ }
1139
+ {
1140
+ cmpMeta.$attrsToReflect$ = [];
1141
+ }
1142
+ {
1143
+ cmpMeta.$watchers$ = {};
1144
+ }
1145
+ const tagName = cmpMeta.$tagName$;
1146
+ const HostElement = class extends HTMLElement {
1147
+ // StencilLazyHost
1148
+ constructor(self) {
1149
+ // @ts-ignore
1150
+ super(self);
1151
+ self = this;
1152
+ registerHost(self, cmpMeta);
1153
+ if (cmpMeta.$flags$ & 1 /* shadowDomEncapsulation */) {
1154
+ // this component is using shadow dom
1155
+ // and this browser supports shadow dom
1156
+ // add the read-only property "shadowRoot" to the host element
1157
+ // adding the shadow root build conditionals to minimize runtime
1158
+ {
1159
+ {
1160
+ self.attachShadow({ mode: 'open' });
1161
+ }
1162
+ }
1163
+ }
1164
+ }
1165
+ connectedCallback() {
1166
+ if (appLoadFallback) {
1167
+ clearTimeout(appLoadFallback);
1168
+ appLoadFallback = null;
1169
+ }
1170
+ if (isBootstrapping) {
1171
+ // connectedCallback will be processed once all components have been registered
1172
+ deferredConnectedCallbacks.push(this);
1173
+ }
1174
+ else {
1175
+ plt.jmp(() => connectedCallback(this));
1176
+ }
1177
+ }
1178
+ disconnectedCallback() {
1179
+ plt.jmp(() => disconnectedCallback(this));
1180
+ }
1181
+ componentOnReady() {
1182
+ return getHostRef(this).$onReadyPromise$;
1183
+ }
1184
+ };
1185
+ cmpMeta.$lazyBundleId$ = lazyBundle[0];
1186
+ if (!exclude.includes(tagName) && !customElements.get(tagName)) {
1187
+ cmpTags.push(tagName);
1188
+ customElements.define(tagName, proxyComponent(HostElement, cmpMeta, 1 /* isElementConstructor */));
1189
+ }
1190
+ });
1191
+ });
1192
+ {
1193
+ visibilityStyle.innerHTML = cmpTags + HYDRATED_CSS;
1194
+ visibilityStyle.setAttribute('data-styles', '');
1195
+ head.insertBefore(visibilityStyle, metaCharset ? metaCharset.nextSibling : head.firstChild);
1196
+ }
1197
+ // Process deferred connectedCallbacks now all components have been registered
1198
+ isBootstrapping = false;
1199
+ if (deferredConnectedCallbacks.length) {
1200
+ deferredConnectedCallbacks.map((host) => host.connectedCallback());
1201
+ }
1202
+ else {
1203
+ {
1204
+ plt.jmp(() => (appLoadFallback = setTimeout(appDidLoad, 30)));
1205
+ }
1206
+ }
1207
+ // Fallback appLoad event
1208
+ endBootstrap();
1209
+ };
1210
+ const hostRefs = new WeakMap();
1211
+ const getHostRef = (ref) => hostRefs.get(ref);
1212
+ const registerInstance = (lazyInstance, hostRef) => hostRefs.set((hostRef.$lazyInstance$ = lazyInstance), hostRef);
1213
+ const registerHost = (elm, cmpMeta) => {
1214
+ const hostRef = {
1215
+ $flags$: 0,
1216
+ $hostElement$: elm,
1217
+ $cmpMeta$: cmpMeta,
1218
+ $instanceValues$: new Map(),
1219
+ };
1220
+ {
1221
+ hostRef.$onInstancePromise$ = new Promise((r) => (hostRef.$onInstanceResolve$ = r));
1222
+ }
1223
+ {
1224
+ hostRef.$onReadyPromise$ = new Promise((r) => (hostRef.$onReadyResolve$ = r));
1225
+ elm['s-p'] = [];
1226
+ elm['s-rc'] = [];
1227
+ }
1228
+ addHostEventListeners(elm, hostRef, cmpMeta.$listeners$);
1229
+ return hostRefs.set(elm, hostRef);
1230
+ };
1231
+ const isMemberInElement = (elm, memberName) => memberName in elm;
1232
+ const consoleError = (e, el) => (0, console.error)(e, el);
1233
+ const cmpModules = /*@__PURE__*/ new Map();
1234
+ const loadModule = (cmpMeta, hostRef, hmrVersionId) => {
1235
+ // loadModuleImport
1236
+ const exportName = cmpMeta.$tagName$.replace(/-/g, '_');
1237
+ const bundleId = cmpMeta.$lazyBundleId$;
1238
+ const module = cmpModules.get(bundleId) ;
1239
+ if (module) {
1240
+ return module[exportName];
1241
+ }
1242
+ return import(
1243
+ /* webpackInclude: /\.entry\.js$/ */
1244
+ /* webpackExclude: /\.system\.entry\.js$/ */
1245
+ /* webpackMode: "lazy" */
1246
+ `./${bundleId}.entry.js${''}`).then((importedModule) => {
1247
+ {
1248
+ cmpModules.set(bundleId, importedModule);
1249
+ }
1250
+ return importedModule[exportName];
1251
+ }, consoleError);
1252
+ };
1253
+ const styles = new Map();
1254
+ const queueDomReads = [];
1255
+ const queueDomWrites = [];
1256
+ const queueTask = (queue, write) => (cb) => {
1257
+ queue.push(cb);
1258
+ if (!queuePending) {
1259
+ queuePending = true;
1260
+ if (write && plt.$flags$ & 4 /* queueSync */) {
1261
+ nextTick(flush);
1262
+ }
1263
+ else {
1264
+ plt.raf(flush);
1265
+ }
1266
+ }
1267
+ };
1268
+ const consume = (queue) => {
1269
+ for (let i = 0; i < queue.length; i++) {
1270
+ try {
1271
+ queue[i](performance.now());
1272
+ }
1273
+ catch (e) {
1274
+ consoleError(e);
1275
+ }
1276
+ }
1277
+ queue.length = 0;
1278
+ };
1279
+ const flush = () => {
1280
+ // always force a bunch of medium callbacks to run, but still have
1281
+ // a throttle on how many can run in a certain time
1282
+ // DOM READS!!!
1283
+ consume(queueDomReads);
1284
+ // DOM WRITES!!!
1285
+ {
1286
+ consume(queueDomWrites);
1287
+ if ((queuePending = queueDomReads.length > 0)) {
1288
+ // still more to do yet, but we've run out of time
1289
+ // let's let this thing cool off and try again in the next tick
1290
+ plt.raf(flush);
1291
+ }
1292
+ }
1293
+ };
1294
+ const nextTick = /*@__PURE__*/ (cb) => promiseResolve().then(cb);
1295
+ const writeTask = /*@__PURE__*/ queueTask(queueDomWrites, true);
1296
+
1297
+ export { Host as H, bootstrapLazy as b, createEvent as c, getElement as g, h, promiseResolve as p, registerInstance as r };
1298
+
1299
+ //# sourceMappingURL=index-f79d9e82.js.map