@maggioli-design-system/mds-list 1.0.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.
Files changed (121) hide show
  1. package/dist/cjs/index-41114fc6.js +673 -0
  2. package/dist/cjs/index.cjs.js +2 -0
  3. package/dist/cjs/loader.cjs.js +21 -0
  4. package/dist/cjs/mds-list.cjs.entry.js +19 -0
  5. package/dist/cjs/mds-list.cjs.js +19 -0
  6. package/dist/collection/collection-manifest.json +12 -0
  7. package/dist/collection/components/mds-list/mds-list.css +26 -0
  8. package/dist/collection/components/mds-list/mds-list.js +15 -0
  9. package/dist/collection/components/mds-list/test/mds-list.stories.js +22 -0
  10. package/dist/collection/dictionary/autocomplete.js +59 -0
  11. package/dist/collection/dictionary/button.js +26 -0
  12. package/dist/collection/dictionary/color.js +19 -0
  13. package/dist/collection/dictionary/icon.js +3 -0
  14. package/dist/collection/dictionary/input-text-type.js +13 -0
  15. package/dist/collection/dictionary/loading.js +5 -0
  16. package/dist/collection/dictionary/typography.js +37 -0
  17. package/dist/collection/dictionary/variant.js +65 -0
  18. package/dist/collection/fixtures/cities.js +110 -0
  19. package/dist/collection/interface/input-value.js +1 -0
  20. package/dist/collection/types/autocomplete.js +1 -0
  21. package/dist/collection/types/button.js +1 -0
  22. package/dist/collection/types/form-rel.js +1 -0
  23. package/dist/collection/types/input-text-type.js +1 -0
  24. package/dist/collection/types/input-value-type.js +1 -0
  25. package/dist/collection/types/loading.js +1 -0
  26. package/dist/collection/types/typography.js +1 -0
  27. package/dist/collection/types/variant.js +1 -0
  28. package/dist/components/index.d.ts +26 -0
  29. package/dist/components/index.js +1 -0
  30. package/dist/components/mds-list.d.ts +11 -0
  31. package/dist/components/mds-list.js +34 -0
  32. package/dist/esm/index-6230983e.js +647 -0
  33. package/dist/esm/index.js +1 -0
  34. package/dist/esm/loader.js +17 -0
  35. package/dist/esm/mds-list.entry.js +15 -0
  36. package/dist/esm/mds-list.js +17 -0
  37. package/dist/esm/polyfills/core-js.js +11 -0
  38. package/dist/esm/polyfills/css-shim.js +1 -0
  39. package/dist/esm/polyfills/dom.js +79 -0
  40. package/dist/esm/polyfills/es5-html-element.js +1 -0
  41. package/dist/esm/polyfills/index.js +34 -0
  42. package/dist/esm/polyfills/system.js +6 -0
  43. package/dist/esm-es5/index-6230983e.js +1 -0
  44. package/dist/esm-es5/index.js +0 -0
  45. package/dist/esm-es5/loader.js +1 -0
  46. package/dist/esm-es5/mds-list.entry.js +1 -0
  47. package/dist/esm-es5/mds-list.js +1 -0
  48. package/dist/index.cjs.js +1 -0
  49. package/dist/index.js +1 -0
  50. package/dist/mds-list/index.esm.js +0 -0
  51. package/dist/mds-list/mds-list.esm.js +1 -0
  52. package/dist/mds-list/mds-list.js +130 -0
  53. package/dist/mds-list/p-233f72af.system.js +1 -0
  54. package/dist/mds-list/p-50ea2036.system.js +1 -0
  55. package/dist/mds-list/p-5b7327b3.js +1 -0
  56. package/dist/mds-list/p-9fd9e0ef.system.js +1 -0
  57. package/dist/mds-list/p-f2ee2e84.entry.js +1 -0
  58. package/dist/mds-list/p-f3960731.system.entry.js +1 -0
  59. package/dist/stats.json +349 -0
  60. package/dist/types/components/mds-list/mds-list.d.ts +3 -0
  61. package/dist/types/components.d.ts +37 -0
  62. package/dist/types/dictionary/autocomplete.d.ts +2 -0
  63. package/dist/types/dictionary/button.d.ts +5 -0
  64. package/dist/types/dictionary/color.d.ts +3 -0
  65. package/dist/types/dictionary/icon.d.ts +2 -0
  66. package/dist/types/dictionary/input-text-type.d.ts +2 -0
  67. package/dist/types/dictionary/loading.d.ts +2 -0
  68. package/dist/types/dictionary/typography.d.ts +5 -0
  69. package/dist/types/dictionary/variant.d.ts +9 -0
  70. package/dist/types/fixtures/cities.d.ts +2 -0
  71. package/dist/types/interface/input-value.d.ts +4 -0
  72. package/dist/types/stencil-public-runtime.d.ts +1563 -0
  73. package/dist/types/types/autocomplete.d.ts +2 -0
  74. package/dist/types/types/button.d.ts +4 -0
  75. package/dist/types/types/form-rel.d.ts +1 -0
  76. package/dist/types/types/input-text-type.d.ts +1 -0
  77. package/dist/types/types/input-value-type.d.ts +1 -0
  78. package/dist/types/types/loading.d.ts +1 -0
  79. package/dist/types/types/typography.d.ts +4 -0
  80. package/dist/types/types/variant.d.ts +10 -0
  81. package/loader/cdn.js +3 -0
  82. package/loader/index.cjs.js +3 -0
  83. package/loader/index.d.ts +12 -0
  84. package/loader/index.es2017.js +3 -0
  85. package/loader/index.js +4 -0
  86. package/loader/package.json +10 -0
  87. package/package.json +44 -0
  88. package/readme.md +10 -0
  89. package/src/components/mds-list/mds-list.css +15 -0
  90. package/src/components/mds-list/mds-list.tsx +19 -0
  91. package/src/components/mds-list/readme.md +10 -0
  92. package/src/components/mds-list/test/mds-list.stories.js +22 -0
  93. package/src/components.d.ts +37 -0
  94. package/src/dictionary/autocomplete.ts +62 -0
  95. package/src/dictionary/button.ts +35 -0
  96. package/src/dictionary/color.ts +24 -0
  97. package/src/dictionary/icon.ts +5 -0
  98. package/src/dictionary/input-text-type.ts +17 -0
  99. package/src/dictionary/loading.ts +9 -0
  100. package/src/dictionary/typography.ts +46 -0
  101. package/src/dictionary/variant.ts +82 -0
  102. package/src/fixtures/cities.ts +116 -0
  103. package/src/interface/input-value.ts +5 -0
  104. package/src/types/autocomplete.ts +69 -0
  105. package/src/types/button.ts +24 -0
  106. package/src/types/form-rel.ts +11 -0
  107. package/src/types/input-text-type.ts +11 -0
  108. package/src/types/input-value-type.ts +5 -0
  109. package/src/types/loading.ts +3 -0
  110. package/src/types/typography.ts +35 -0
  111. package/src/types/variant.ts +73 -0
  112. package/www/build/index.esm.js +0 -0
  113. package/www/build/mds-list.esm.js +1 -0
  114. package/www/build/mds-list.js +130 -0
  115. package/www/build/p-233f72af.system.js +1 -0
  116. package/www/build/p-50ea2036.system.js +1 -0
  117. package/www/build/p-5b7327b3.js +1 -0
  118. package/www/build/p-9fd9e0ef.system.js +1 -0
  119. package/www/build/p-f2ee2e84.entry.js +1 -0
  120. package/www/build/p-f3960731.system.entry.js +1 -0
  121. package/www/host.config.json +15 -0
@@ -0,0 +1,647 @@
1
+ const NAMESPACE = 'mds-list';
2
+
3
+ let scopeId;
4
+ let hostTagName;
5
+ let queuePending = false;
6
+ const win = typeof window !== 'undefined' ? window : {};
7
+ const doc = win.document || { head: {} };
8
+ const plt = {
9
+ $flags$: 0,
10
+ $resourcesUrl$: '',
11
+ jmp: (h) => h(),
12
+ raf: (h) => requestAnimationFrame(h),
13
+ ael: (el, eventName, listener, opts) => el.addEventListener(eventName, listener, opts),
14
+ rel: (el, eventName, listener, opts) => el.removeEventListener(eventName, listener, opts),
15
+ ce: (eventName, opts) => new CustomEvent(eventName, opts),
16
+ };
17
+ const promiseResolve = (v) => Promise.resolve(v);
18
+ const supportsConstructibleStylesheets = /*@__PURE__*/ (() => {
19
+ try {
20
+ new CSSStyleSheet();
21
+ return typeof new CSSStyleSheet().replace === 'function';
22
+ }
23
+ catch (e) { }
24
+ return false;
25
+ })()
26
+ ;
27
+ const HYDRATED_CSS = '{visibility:hidden}.hydrated{visibility:inherit}';
28
+ const createTime = (fnName, tagName = '') => {
29
+ {
30
+ return () => {
31
+ return;
32
+ };
33
+ }
34
+ };
35
+ const uniqueTime = (key, measureText) => {
36
+ {
37
+ return () => {
38
+ return;
39
+ };
40
+ }
41
+ };
42
+ const rootAppliedStyles = new WeakMap();
43
+ const registerStyle = (scopeId, cssText, allowCS) => {
44
+ let style = styles.get(scopeId);
45
+ if (supportsConstructibleStylesheets && allowCS) {
46
+ style = (style || new CSSStyleSheet());
47
+ style.replace(cssText);
48
+ }
49
+ else {
50
+ style = cssText;
51
+ }
52
+ styles.set(scopeId, style);
53
+ };
54
+ const addStyle = (styleContainerNode, cmpMeta, mode, hostElm) => {
55
+ let scopeId = getScopeId(cmpMeta);
56
+ let style = styles.get(scopeId);
57
+ // if an element is NOT connected then getRootNode() will return the wrong root node
58
+ // so the fallback is to always use the document for the root node in those cases
59
+ styleContainerNode = styleContainerNode.nodeType === 11 /* DocumentFragment */ ? styleContainerNode : doc;
60
+ if (style) {
61
+ if (typeof style === 'string') {
62
+ styleContainerNode = styleContainerNode.head || styleContainerNode;
63
+ let appliedStyles = rootAppliedStyles.get(styleContainerNode);
64
+ let styleElm;
65
+ if (!appliedStyles) {
66
+ rootAppliedStyles.set(styleContainerNode, (appliedStyles = new Set()));
67
+ }
68
+ if (!appliedStyles.has(scopeId)) {
69
+ {
70
+ {
71
+ styleElm = doc.createElement('style');
72
+ styleElm.innerHTML = style;
73
+ }
74
+ styleContainerNode.insertBefore(styleElm, styleContainerNode.querySelector('link'));
75
+ }
76
+ if (appliedStyles) {
77
+ appliedStyles.add(scopeId);
78
+ }
79
+ }
80
+ }
81
+ else if (!styleContainerNode.adoptedStyleSheets.includes(style)) {
82
+ styleContainerNode.adoptedStyleSheets = [...styleContainerNode.adoptedStyleSheets, style];
83
+ }
84
+ }
85
+ return scopeId;
86
+ };
87
+ const attachStyles = (hostRef) => {
88
+ const cmpMeta = hostRef.$cmpMeta$;
89
+ const elm = hostRef.$hostElement$;
90
+ const flags = cmpMeta.$flags$;
91
+ const endAttachStyles = createTime('attachStyles', cmpMeta.$tagName$);
92
+ const scopeId = addStyle(elm.shadowRoot ? elm.shadowRoot : elm.getRootNode(), cmpMeta);
93
+ if (flags & 10 /* needsScopedEncapsulation */) {
94
+ // only required when we're NOT using native shadow dom (slot)
95
+ // or this browser doesn't support native shadow dom
96
+ // and this host element was NOT created with SSR
97
+ // let's pick out the inner content for slot projection
98
+ // create a node to represent where the original
99
+ // content was first placed, which is useful later on
100
+ // DOM WRITE!!
101
+ elm['s-sc'] = scopeId;
102
+ elm.classList.add(scopeId + '-h');
103
+ }
104
+ endAttachStyles();
105
+ };
106
+ const getScopeId = (cmp, mode) => 'sc-' + (cmp.$tagName$);
107
+ const isDef = (v) => v != null;
108
+ const isComplexType = (o) => {
109
+ // https://jsperf.com/typeof-fn-object/5
110
+ o = typeof o;
111
+ return o === 'object' || o === 'function';
112
+ };
113
+ /**
114
+ * Production h() function based on Preact by
115
+ * Jason Miller (@developit)
116
+ * Licensed under the MIT License
117
+ * https://github.com/developit/preact/blob/master/LICENSE
118
+ *
119
+ * Modified for Stencil's compiler and vdom
120
+ */
121
+ // const stack: any[] = [];
122
+ // export function h(nodeName: string | d.FunctionalComponent, vnodeData: d.PropsType, child?: d.ChildType): d.VNode;
123
+ // export function h(nodeName: string | d.FunctionalComponent, vnodeData: d.PropsType, ...children: d.ChildType[]): d.VNode;
124
+ const h = (nodeName, vnodeData, ...children) => {
125
+ let child = null;
126
+ let simple = false;
127
+ let lastSimple = false;
128
+ let vNodeChildren = [];
129
+ const walk = (c) => {
130
+ for (let i = 0; i < c.length; i++) {
131
+ child = c[i];
132
+ if (Array.isArray(child)) {
133
+ walk(child);
134
+ }
135
+ else if (child != null && typeof child !== 'boolean') {
136
+ if ((simple = typeof nodeName !== 'function' && !isComplexType(child))) {
137
+ child = String(child);
138
+ }
139
+ if (simple && lastSimple) {
140
+ // If the previous child was simple (string), we merge both
141
+ vNodeChildren[vNodeChildren.length - 1].$text$ += child;
142
+ }
143
+ else {
144
+ // Append a new vNode, if it's text, we create a text vNode
145
+ vNodeChildren.push(simple ? newVNode(null, child) : child);
146
+ }
147
+ lastSimple = simple;
148
+ }
149
+ }
150
+ };
151
+ walk(children);
152
+ const vnode = newVNode(nodeName, null);
153
+ vnode.$attrs$ = vnodeData;
154
+ if (vNodeChildren.length > 0) {
155
+ vnode.$children$ = vNodeChildren;
156
+ }
157
+ return vnode;
158
+ };
159
+ const newVNode = (tag, text) => {
160
+ const vnode = {
161
+ $flags$: 0,
162
+ $tag$: tag,
163
+ $text$: text,
164
+ $elm$: null,
165
+ $children$: null,
166
+ };
167
+ return vnode;
168
+ };
169
+ const Host = {};
170
+ const isHost = (node) => node && node.$tag$ === Host;
171
+ const createElm = (oldParentVNode, newParentVNode, childIndex, parentElm) => {
172
+ // tslint:disable-next-line: prefer-const
173
+ let newVNode = newParentVNode.$children$[childIndex];
174
+ let i = 0;
175
+ let elm;
176
+ let childNode;
177
+ {
178
+ // create element
179
+ elm = newVNode.$elm$ = (doc.createElement(newVNode.$tag$));
180
+ if (isDef(scopeId) && elm['s-si'] !== scopeId) {
181
+ // if there is a scopeId and this is the initial render
182
+ // then let's add the scopeId as a css class
183
+ elm.classList.add((elm['s-si'] = scopeId));
184
+ }
185
+ if (newVNode.$children$) {
186
+ for (i = 0; i < newVNode.$children$.length; ++i) {
187
+ // create the node
188
+ childNode = createElm(oldParentVNode, newVNode, i);
189
+ // return node could have been null
190
+ if (childNode) {
191
+ // append our new node
192
+ elm.appendChild(childNode);
193
+ }
194
+ }
195
+ }
196
+ }
197
+ return elm;
198
+ };
199
+ const addVnodes = (parentElm, before, parentVNode, vnodes, startIdx, endIdx) => {
200
+ let containerElm = (parentElm);
201
+ let childNode;
202
+ if (containerElm.shadowRoot && containerElm.tagName === hostTagName) {
203
+ containerElm = containerElm.shadowRoot;
204
+ }
205
+ for (; startIdx <= endIdx; ++startIdx) {
206
+ if (vnodes[startIdx]) {
207
+ childNode = createElm(null, parentVNode, startIdx);
208
+ if (childNode) {
209
+ vnodes[startIdx].$elm$ = childNode;
210
+ containerElm.insertBefore(childNode, before);
211
+ }
212
+ }
213
+ }
214
+ };
215
+ const patch = (oldVNode, newVNode) => {
216
+ const elm = (newVNode.$elm$ = oldVNode.$elm$);
217
+ const newChildren = newVNode.$children$;
218
+ {
219
+ if (newChildren !== null) {
220
+ // add the new vnode children
221
+ addVnodes(elm, null, newVNode, newChildren, 0, newChildren.length - 1);
222
+ }
223
+ else ;
224
+ }
225
+ };
226
+ const renderVdom = (hostRef, renderFnResults) => {
227
+ const hostElm = hostRef.$hostElement$;
228
+ const oldVNode = hostRef.$vnode$ || newVNode(null, null);
229
+ const rootVnode = isHost(renderFnResults) ? renderFnResults : h(null, null, renderFnResults);
230
+ hostTagName = hostElm.tagName;
231
+ rootVnode.$tag$ = null;
232
+ rootVnode.$flags$ |= 4 /* isHost */;
233
+ hostRef.$vnode$ = rootVnode;
234
+ rootVnode.$elm$ = oldVNode.$elm$ = (hostElm.shadowRoot || hostElm );
235
+ {
236
+ scopeId = hostElm['s-sc'];
237
+ }
238
+ // synchronous patch
239
+ patch(oldVNode, rootVnode);
240
+ };
241
+ /**
242
+ * Helper function to create & dispatch a custom Event on a provided target
243
+ * @param elm the target of the Event
244
+ * @param name the name to give the custom Event
245
+ * @param opts options for configuring a custom Event
246
+ * @returns the custom Event
247
+ */
248
+ const emitEvent = (elm, name, opts) => {
249
+ const ev = plt.ce(name, opts);
250
+ elm.dispatchEvent(ev);
251
+ return ev;
252
+ };
253
+ const attachToAncestor = (hostRef, ancestorComponent) => {
254
+ if (ancestorComponent && !hostRef.$onRenderResolve$ && ancestorComponent['s-p']) {
255
+ ancestorComponent['s-p'].push(new Promise((r) => (hostRef.$onRenderResolve$ = r)));
256
+ }
257
+ };
258
+ const scheduleUpdate = (hostRef, isInitialLoad) => {
259
+ if (hostRef.$flags$ & 4 /* isWaitingForChildren */) {
260
+ hostRef.$flags$ |= 512 /* needsRerender */;
261
+ return;
262
+ }
263
+ attachToAncestor(hostRef, hostRef.$ancestorComponent$);
264
+ // there is no ancestor component or the ancestor component
265
+ // has already fired off its lifecycle update then
266
+ // fire off the initial update
267
+ const dispatch = () => dispatchHooks(hostRef, isInitialLoad);
268
+ return writeTask(dispatch) ;
269
+ };
270
+ const dispatchHooks = (hostRef, isInitialLoad) => {
271
+ const endSchedule = createTime('scheduleUpdate', hostRef.$cmpMeta$.$tagName$);
272
+ const instance = hostRef.$lazyInstance$ ;
273
+ let promise;
274
+ endSchedule();
275
+ return then(promise, () => updateComponent(hostRef, instance, isInitialLoad));
276
+ };
277
+ const updateComponent = async (hostRef, instance, isInitialLoad) => {
278
+ // updateComponent
279
+ const elm = hostRef.$hostElement$;
280
+ const endUpdate = createTime('update', hostRef.$cmpMeta$.$tagName$);
281
+ const rc = elm['s-rc'];
282
+ if (isInitialLoad) {
283
+ // DOM WRITE!
284
+ attachStyles(hostRef);
285
+ }
286
+ const endRender = createTime('render', hostRef.$cmpMeta$.$tagName$);
287
+ {
288
+ callRender(hostRef, instance);
289
+ }
290
+ if (rc) {
291
+ // ok, so turns out there are some child host elements
292
+ // waiting on this parent element to load
293
+ // let's fire off all update callbacks waiting
294
+ rc.map((cb) => cb());
295
+ elm['s-rc'] = undefined;
296
+ }
297
+ endRender();
298
+ endUpdate();
299
+ {
300
+ const childrenPromises = elm['s-p'];
301
+ const postUpdate = () => postUpdateComponent(hostRef);
302
+ if (childrenPromises.length === 0) {
303
+ postUpdate();
304
+ }
305
+ else {
306
+ Promise.all(childrenPromises).then(postUpdate);
307
+ hostRef.$flags$ |= 4 /* isWaitingForChildren */;
308
+ childrenPromises.length = 0;
309
+ }
310
+ }
311
+ };
312
+ const callRender = (hostRef, instance, elm) => {
313
+ try {
314
+ instance = instance.render() ;
315
+ {
316
+ hostRef.$flags$ |= 2 /* hasRendered */;
317
+ }
318
+ {
319
+ {
320
+ // looks like we've got child nodes to render into this host element
321
+ // or we need to update the css class/attrs on the host element
322
+ // DOM WRITE!
323
+ {
324
+ renderVdom(hostRef, instance);
325
+ }
326
+ }
327
+ }
328
+ }
329
+ catch (e) {
330
+ consoleError(e, hostRef.$hostElement$);
331
+ }
332
+ return null;
333
+ };
334
+ const postUpdateComponent = (hostRef) => {
335
+ const tagName = hostRef.$cmpMeta$.$tagName$;
336
+ const elm = hostRef.$hostElement$;
337
+ const endPostUpdate = createTime('postUpdate', tagName);
338
+ const ancestorComponent = hostRef.$ancestorComponent$;
339
+ if (!(hostRef.$flags$ & 64 /* hasLoadedComponent */)) {
340
+ hostRef.$flags$ |= 64 /* hasLoadedComponent */;
341
+ {
342
+ // DOM WRITE!
343
+ addHydratedFlag(elm);
344
+ }
345
+ endPostUpdate();
346
+ {
347
+ hostRef.$onReadyResolve$(elm);
348
+ if (!ancestorComponent) {
349
+ appDidLoad();
350
+ }
351
+ }
352
+ }
353
+ else {
354
+ endPostUpdate();
355
+ }
356
+ // load events fire from bottom to top
357
+ // the deepest elements load first then bubbles up
358
+ {
359
+ if (hostRef.$onRenderResolve$) {
360
+ hostRef.$onRenderResolve$();
361
+ hostRef.$onRenderResolve$ = undefined;
362
+ }
363
+ if (hostRef.$flags$ & 512 /* needsRerender */) {
364
+ nextTick(() => scheduleUpdate(hostRef, false));
365
+ }
366
+ hostRef.$flags$ &= ~(4 /* isWaitingForChildren */ | 512 /* needsRerender */);
367
+ }
368
+ // ( •_•)
369
+ // ( •_•)>⌐■-■
370
+ // (⌐■_■)
371
+ };
372
+ const appDidLoad = (who) => {
373
+ // on appload
374
+ // we have finish the first big initial render
375
+ {
376
+ addHydratedFlag(doc.documentElement);
377
+ }
378
+ nextTick(() => emitEvent(win, 'appload', { detail: { namespace: NAMESPACE } }));
379
+ };
380
+ const then = (promise, thenFn) => {
381
+ return promise && promise.then ? promise.then(thenFn) : thenFn();
382
+ };
383
+ const addHydratedFlag = (elm) => elm.classList.add('hydrated')
384
+ ;
385
+ const proxyComponent = (Cstr, cmpMeta, flags) => {
386
+ return Cstr;
387
+ };
388
+ const initializeComponent = async (elm, hostRef, cmpMeta, hmrVersionId, Cstr) => {
389
+ // initializeComponent
390
+ if ((hostRef.$flags$ & 32 /* hasInitializedComponent */) === 0) {
391
+ {
392
+ // we haven't initialized this element yet
393
+ hostRef.$flags$ |= 32 /* hasInitializedComponent */;
394
+ // lazy loaded components
395
+ // request the component's implementation to be
396
+ // wired up with the host element
397
+ Cstr = loadModule(cmpMeta);
398
+ if (Cstr.then) {
399
+ // Await creates a micro-task avoid if possible
400
+ const endLoad = uniqueTime();
401
+ Cstr = await Cstr;
402
+ endLoad();
403
+ }
404
+ const endNewInstance = createTime('createInstance', cmpMeta.$tagName$);
405
+ // construct the lazy-loaded component implementation
406
+ // passing the hostRef is very important during
407
+ // construction in order to directly wire together the
408
+ // host element and the lazy-loaded instance
409
+ try {
410
+ new Cstr(hostRef);
411
+ }
412
+ catch (e) {
413
+ consoleError(e);
414
+ }
415
+ endNewInstance();
416
+ }
417
+ if (Cstr.style) {
418
+ // this component has styles but we haven't registered them yet
419
+ let style = Cstr.style;
420
+ const scopeId = getScopeId(cmpMeta);
421
+ if (!styles.has(scopeId)) {
422
+ const endRegisterStyles = createTime('registerStyles', cmpMeta.$tagName$);
423
+ registerStyle(scopeId, style, !!(cmpMeta.$flags$ & 1 /* shadowDomEncapsulation */));
424
+ endRegisterStyles();
425
+ }
426
+ }
427
+ }
428
+ // we've successfully created a lazy instance
429
+ const ancestorComponent = hostRef.$ancestorComponent$;
430
+ const schedule = () => scheduleUpdate(hostRef, true);
431
+ if (ancestorComponent && ancestorComponent['s-rc']) {
432
+ // this is the initial load and this component it has an ancestor component
433
+ // but the ancestor component has NOT fired its will update lifecycle yet
434
+ // so let's just cool our jets and wait for the ancestor to continue first
435
+ // this will get fired off when the ancestor component
436
+ // finally gets around to rendering its lazy self
437
+ // fire off the initial update
438
+ ancestorComponent['s-rc'].push(schedule);
439
+ }
440
+ else {
441
+ schedule();
442
+ }
443
+ };
444
+ const connectedCallback = (elm) => {
445
+ if ((plt.$flags$ & 1 /* isTmpDisconnected */) === 0) {
446
+ const hostRef = getHostRef(elm);
447
+ const cmpMeta = hostRef.$cmpMeta$;
448
+ const endConnected = createTime('connectedCallback', cmpMeta.$tagName$);
449
+ if (!(hostRef.$flags$ & 1 /* hasConnected */)) {
450
+ // first time this component has connected
451
+ hostRef.$flags$ |= 1 /* hasConnected */;
452
+ {
453
+ // find the first ancestor component (if there is one) and register
454
+ // this component as one of the actively loading child components for its ancestor
455
+ let ancestorComponent = elm;
456
+ while ((ancestorComponent = ancestorComponent.parentNode || ancestorComponent.host)) {
457
+ // climb up the ancestors looking for the first
458
+ // component that hasn't finished its lifecycle update yet
459
+ if (ancestorComponent['s-p']) {
460
+ // we found this components first ancestor component
461
+ // keep a reference to this component's ancestor component
462
+ attachToAncestor(hostRef, (hostRef.$ancestorComponent$ = ancestorComponent));
463
+ break;
464
+ }
465
+ }
466
+ }
467
+ {
468
+ initializeComponent(elm, hostRef, cmpMeta);
469
+ }
470
+ }
471
+ endConnected();
472
+ }
473
+ };
474
+ const disconnectedCallback = (elm) => {
475
+ if ((plt.$flags$ & 1 /* isTmpDisconnected */) === 0) {
476
+ getHostRef(elm);
477
+ }
478
+ };
479
+ const bootstrapLazy = (lazyBundles, options = {}) => {
480
+ const endBootstrap = createTime();
481
+ const cmpTags = [];
482
+ const exclude = options.exclude || [];
483
+ const customElements = win.customElements;
484
+ const head = doc.head;
485
+ const metaCharset = /*@__PURE__*/ head.querySelector('meta[charset]');
486
+ const visibilityStyle = /*@__PURE__*/ doc.createElement('style');
487
+ const deferredConnectedCallbacks = [];
488
+ let appLoadFallback;
489
+ let isBootstrapping = true;
490
+ Object.assign(plt, options);
491
+ plt.$resourcesUrl$ = new URL(options.resourcesUrl || './', doc.baseURI).href;
492
+ lazyBundles.map((lazyBundle) => {
493
+ lazyBundle[1].map((compactMeta) => {
494
+ const cmpMeta = {
495
+ $flags$: compactMeta[0],
496
+ $tagName$: compactMeta[1],
497
+ $members$: compactMeta[2],
498
+ $listeners$: compactMeta[3],
499
+ };
500
+ const tagName = cmpMeta.$tagName$;
501
+ const HostElement = class extends HTMLElement {
502
+ // StencilLazyHost
503
+ constructor(self) {
504
+ // @ts-ignore
505
+ super(self);
506
+ self = this;
507
+ registerHost(self, cmpMeta);
508
+ if (cmpMeta.$flags$ & 1 /* shadowDomEncapsulation */) {
509
+ // this component is using shadow dom
510
+ // and this browser supports shadow dom
511
+ // add the read-only property "shadowRoot" to the host element
512
+ // adding the shadow root build conditionals to minimize runtime
513
+ {
514
+ {
515
+ self.attachShadow({ mode: 'open' });
516
+ }
517
+ }
518
+ }
519
+ }
520
+ connectedCallback() {
521
+ if (appLoadFallback) {
522
+ clearTimeout(appLoadFallback);
523
+ appLoadFallback = null;
524
+ }
525
+ if (isBootstrapping) {
526
+ // connectedCallback will be processed once all components have been registered
527
+ deferredConnectedCallbacks.push(this);
528
+ }
529
+ else {
530
+ plt.jmp(() => connectedCallback(this));
531
+ }
532
+ }
533
+ disconnectedCallback() {
534
+ plt.jmp(() => disconnectedCallback(this));
535
+ }
536
+ componentOnReady() {
537
+ return getHostRef(this).$onReadyPromise$;
538
+ }
539
+ };
540
+ cmpMeta.$lazyBundleId$ = lazyBundle[0];
541
+ if (!exclude.includes(tagName) && !customElements.get(tagName)) {
542
+ cmpTags.push(tagName);
543
+ customElements.define(tagName, proxyComponent(HostElement));
544
+ }
545
+ });
546
+ });
547
+ {
548
+ visibilityStyle.innerHTML = cmpTags + HYDRATED_CSS;
549
+ visibilityStyle.setAttribute('data-styles', '');
550
+ head.insertBefore(visibilityStyle, metaCharset ? metaCharset.nextSibling : head.firstChild);
551
+ }
552
+ // Process deferred connectedCallbacks now all components have been registered
553
+ isBootstrapping = false;
554
+ if (deferredConnectedCallbacks.length) {
555
+ deferredConnectedCallbacks.map((host) => host.connectedCallback());
556
+ }
557
+ else {
558
+ {
559
+ plt.jmp(() => (appLoadFallback = setTimeout(appDidLoad, 30)));
560
+ }
561
+ }
562
+ // Fallback appLoad event
563
+ endBootstrap();
564
+ };
565
+ const hostRefs = new WeakMap();
566
+ const getHostRef = (ref) => hostRefs.get(ref);
567
+ const registerInstance = (lazyInstance, hostRef) => hostRefs.set((hostRef.$lazyInstance$ = lazyInstance), hostRef);
568
+ const registerHost = (elm, cmpMeta) => {
569
+ const hostRef = {
570
+ $flags$: 0,
571
+ $hostElement$: elm,
572
+ $cmpMeta$: cmpMeta,
573
+ $instanceValues$: new Map(),
574
+ };
575
+ {
576
+ hostRef.$onReadyPromise$ = new Promise((r) => (hostRef.$onReadyResolve$ = r));
577
+ elm['s-p'] = [];
578
+ elm['s-rc'] = [];
579
+ }
580
+ return hostRefs.set(elm, hostRef);
581
+ };
582
+ const consoleError = (e, el) => (0, console.error)(e, el);
583
+ const cmpModules = /*@__PURE__*/ new Map();
584
+ const loadModule = (cmpMeta, hostRef, hmrVersionId) => {
585
+ // loadModuleImport
586
+ const exportName = cmpMeta.$tagName$.replace(/-/g, '_');
587
+ const bundleId = cmpMeta.$lazyBundleId$;
588
+ const module = cmpModules.get(bundleId) ;
589
+ if (module) {
590
+ return module[exportName];
591
+ }
592
+ return import(
593
+ /* webpackInclude: /\.entry\.js$/ */
594
+ /* webpackExclude: /\.system\.entry\.js$/ */
595
+ /* webpackMode: "lazy" */
596
+ `./${bundleId}.entry.js${''}`).then((importedModule) => {
597
+ {
598
+ cmpModules.set(bundleId, importedModule);
599
+ }
600
+ return importedModule[exportName];
601
+ }, consoleError);
602
+ };
603
+ const styles = new Map();
604
+ const queueDomReads = [];
605
+ const queueDomWrites = [];
606
+ const queueTask = (queue, write) => (cb) => {
607
+ queue.push(cb);
608
+ if (!queuePending) {
609
+ queuePending = true;
610
+ if (write && plt.$flags$ & 4 /* queueSync */) {
611
+ nextTick(flush);
612
+ }
613
+ else {
614
+ plt.raf(flush);
615
+ }
616
+ }
617
+ };
618
+ const consume = (queue) => {
619
+ for (let i = 0; i < queue.length; i++) {
620
+ try {
621
+ queue[i](performance.now());
622
+ }
623
+ catch (e) {
624
+ consoleError(e);
625
+ }
626
+ }
627
+ queue.length = 0;
628
+ };
629
+ const flush = () => {
630
+ // always force a bunch of medium callbacks to run, but still have
631
+ // a throttle on how many can run in a certain time
632
+ // DOM READS!!!
633
+ consume(queueDomReads);
634
+ // DOM WRITES!!!
635
+ {
636
+ consume(queueDomWrites);
637
+ if ((queuePending = queueDomReads.length > 0)) {
638
+ // still more to do yet, but we've run out of time
639
+ // let's let this thing cool off and try again in the next tick
640
+ plt.raf(flush);
641
+ }
642
+ }
643
+ };
644
+ const nextTick = /*@__PURE__*/ (cb) => promiseResolve().then(cb);
645
+ const writeTask = /*@__PURE__*/ queueTask(queueDomWrites, true);
646
+
647
+ export { Host as H, bootstrapLazy as b, h, promiseResolve as p, registerInstance as r };
@@ -0,0 +1 @@
1
+
@@ -0,0 +1,17 @@
1
+ import { p as promiseResolve, b as bootstrapLazy } from './index-6230983e.js';
2
+
3
+ /*
4
+ Stencil Client Patch Esm v2.12.0 | MIT Licensed | https://stenciljs.com
5
+ */
6
+ const patchEsm = () => {
7
+ return promiseResolve();
8
+ };
9
+
10
+ const defineCustomElements = (win, options) => {
11
+ if (typeof window === 'undefined') return Promise.resolve();
12
+ return patchEsm().then(() => {
13
+ return bootstrapLazy([["mds-list",[[1,"mds-list"]]]], options);
14
+ });
15
+ };
16
+
17
+ export { defineCustomElements };
@@ -0,0 +1,15 @@
1
+ import { r as registerInstance, h, H as Host } from './index-6230983e.js';
2
+
3
+ const mdsListCss = "*,::before,::after{border-color:currentColor;--tw-ring-offset-shadow:0 0 #0000;--tw-ring-shadow:0 0 #0000;--tw-shadow:0 0 #0000;--tw-shadow-colored:0 0 #0000}.border{border-width:1px}.shadow{--tw-shadow:0 1px 3px 0 rgb(0 0 0 / 0.1), 0 1px 2px -1px rgb(0 0 0 / 0.1);--tw-shadow-colored:0 1px 3px 0 var(--tw-shadow-color), 0 1px 2px -1px var(--tw-shadow-color);-webkit-box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow)}:host{display:grid;gap:1rem;padding-left:1rem}ul{margin:0px;padding:0px}";
4
+
5
+ let MdsList = class {
6
+ constructor(hostRef) {
7
+ registerInstance(this, hostRef);
8
+ }
9
+ render() {
10
+ return (h(Host, null, h("slot", null)));
11
+ }
12
+ };
13
+ MdsList.style = mdsListCss;
14
+
15
+ export { MdsList as mds_list };
@@ -0,0 +1,17 @@
1
+ import { p as promiseResolve, b as bootstrapLazy } from './index-6230983e.js';
2
+
3
+ /*
4
+ Stencil Client Patch Browser v2.12.0 | MIT Licensed | https://stenciljs.com
5
+ */
6
+ const patchBrowser = () => {
7
+ const importMeta = import.meta.url;
8
+ const opts = {};
9
+ if (importMeta !== '') {
10
+ opts.resourcesUrl = new URL('.', importMeta).href;
11
+ }
12
+ return promiseResolve(opts);
13
+ };
14
+
15
+ patchBrowser().then(options => {
16
+ return bootstrapLazy([["mds-list",[[1,"mds-list"]]]], options);
17
+ });