proto-table-wc 0.0.420 → 0.0.422

Sign up to get free protection for your applications and to get access to all the features.
@@ -2,7 +2,7 @@
2
2
 
3
3
  Object.defineProperty(exports, '__esModule', { value: true });
4
4
 
5
- const index = require('./index-76fed79c.js');
5
+ const index = require('./index-44146c73.js');
6
6
 
7
7
  const demoTableCss = ".detailWrapper{font-weight:100;font-size:13px;display:flex;flex-direction:column;justify-items:start;padding:5px;padding-left:30px}";
8
8
 
@@ -526,16 +526,17 @@ const addVnodes = (parentElm, before, parentVNode, vnodes, startIdx, endIdx) =>
526
526
  * @param vnodes a list of virtual DOM nodes to remove
527
527
  * @param startIdx the index at which to start removing nodes (inclusive)
528
528
  * @param endIdx the index at which to stop removing nodes (inclusive)
529
- * @param vnode a VNode
530
- * @param elm an element
531
529
  */
532
- const removeVnodes = (vnodes, startIdx, endIdx, vnode, elm) => {
533
- for (; startIdx <= endIdx; ++startIdx) {
534
- if ((vnode = vnodes[startIdx])) {
535
- elm = vnode.$elm$;
536
- callNodeRefs(vnode);
537
- // remove the vnode's element from the dom
538
- elm.remove();
530
+ const removeVnodes = (vnodes, startIdx, endIdx) => {
531
+ for (let index = startIdx; index <= endIdx; ++index) {
532
+ const vnode = vnodes[index];
533
+ if (vnode) {
534
+ const elm = vnode.$elm$;
535
+ nullifyVNodeRefs(vnode);
536
+ if (elm) {
537
+ // remove the vnode's element from the dom
538
+ elm.remove();
539
+ }
539
540
  }
540
541
  }
541
542
  };
@@ -792,10 +793,17 @@ const patch = (oldVNode, newVNode) => {
792
793
  elm.data = text;
793
794
  }
794
795
  };
795
- const callNodeRefs = (vNode) => {
796
+ /**
797
+ * 'Nullify' any VDom `ref` callbacks on a VDom node or its children by
798
+ * calling them with `null`. This signals that the DOM element corresponding to
799
+ * the VDom node has been removed from the DOM.
800
+ *
801
+ * @param vNode a virtual DOM node
802
+ */
803
+ const nullifyVNodeRefs = (vNode) => {
796
804
  {
797
805
  vNode.$attrs$ && vNode.$attrs$.ref && vNode.$attrs$.ref(null);
798
- vNode.$children$ && vNode.$children$.map(callNodeRefs);
806
+ vNode.$children$ && vNode.$children$.map(nullifyVNodeRefs);
799
807
  }
800
808
  };
801
809
  /**
@@ -845,20 +853,63 @@ const scheduleUpdate = (hostRef, isInitialLoad) => {
845
853
  const dispatch = () => dispatchHooks(hostRef, isInitialLoad);
846
854
  return writeTask(dispatch) ;
847
855
  };
856
+ /**
857
+ * Dispatch initial-render and update lifecycle hooks, enqueuing calls to
858
+ * component lifecycle methods like `componentWillLoad` as well as
859
+ * {@link updateComponent}, which will kick off the virtual DOM re-render.
860
+ *
861
+ * @param hostRef a reference to a host DOM node
862
+ * @param isInitialLoad whether we're on the initial load or not
863
+ * @returns an empty Promise which is used to enqueue a series of operations for
864
+ * the component
865
+ */
848
866
  const dispatchHooks = (hostRef, isInitialLoad) => {
849
867
  const endSchedule = createTime('scheduleUpdate', hostRef.$cmpMeta$.$tagName$);
850
868
  const instance = hostRef.$lazyInstance$ ;
851
- let promise;
869
+ // We're going to use this variable together with `enqueue` to implement a
870
+ // little promise-based queue. We start out with it `undefined`. When we add
871
+ // the first function to the queue we'll set this variable to be that
872
+ // function's return value. When we attempt to add subsequent values to the
873
+ // queue we'll check that value and, if it was a `Promise`, we'll then chain
874
+ // the new function off of that `Promise` using `.then()`. This will give our
875
+ // queue two nice properties:
876
+ //
877
+ // 1. If all functions added to the queue are synchronous they'll be called
878
+ // synchronously right away.
879
+ // 2. If all functions added to the queue are asynchronous they'll all be
880
+ // called in order after `dispatchHooks` exits.
881
+ let maybePromise;
852
882
  if (isInitialLoad) {
853
883
  {
854
- promise = safeCall(instance, 'componentWillLoad');
884
+ // If `componentWillLoad` returns a `Promise` then we want to wait on
885
+ // whatever's going on in that `Promise` before we launch into
886
+ // rendering the component, doing other lifecycle stuff, etc. So
887
+ // in that case we assign the returned promise to the variable we
888
+ // declared above to hold a possible 'queueing' Promise
889
+ maybePromise = safeCall(instance, 'componentWillLoad');
855
890
  }
856
891
  }
857
892
  endSchedule();
858
- return then(promise, () => updateComponent(hostRef, instance, isInitialLoad));
893
+ return enqueue(maybePromise, () => updateComponent(hostRef, instance, isInitialLoad));
859
894
  };
895
+ /**
896
+ * This function uses a Promise to implement a simple first-in, first-out queue
897
+ * of functions to be called.
898
+ *
899
+ * The queue is ordered on the basis of the first argument. If it's
900
+ * `undefined`, then nothing is on the queue yet, so the provided function can
901
+ * be called synchronously (although note that this function may return a
902
+ * `Promise`). The idea is that then the return value of that enqueueing
903
+ * operation is kept around, so that if it was a `Promise` then subsequent
904
+ * functions can be enqueued by calling this function again with that `Promise`
905
+ * as the first argument.
906
+ *
907
+ * @param maybePromise either a `Promise` which should resolve before the next function is called or an 'empty' sentinel
908
+ * @param fn a function to enqueue
909
+ * @returns either a `Promise` or the return value of the provided function
910
+ */
911
+ const enqueue = (maybePromise, fn) => maybePromise instanceof Promise ? maybePromise.then(fn) : fn();
860
912
  const updateComponent = async (hostRef, instance, isInitialLoad) => {
861
- // updateComponent
862
913
  const elm = hostRef.$hostElement$;
863
914
  const endUpdate = createTime('update', hostRef.$cmpMeta$.$tagName$);
864
915
  const rc = elm['s-rc'];
@@ -978,9 +1029,6 @@ const safeCall = (instance, method, arg) => {
978
1029
  }
979
1030
  return undefined;
980
1031
  };
981
- const then = (promise, thenFn) => {
982
- return promise && promise.then ? promise.then(thenFn) : thenFn();
983
- };
984
1032
  const addHydratedFlag = (elm) => elm.classList.add('hydrated')
985
1033
  ;
986
1034
  const getValue = (ref, propName) => getHostRef(ref).$instanceValues$.get(propName);
@@ -1111,9 +1159,9 @@ const proxyComponent = (Cstr, cmpMeta, flags) => {
1111
1159
  const initializeComponent = async (elm, hostRef, cmpMeta, hmrVersionId, Cstr) => {
1112
1160
  // initializeComponent
1113
1161
  if ((hostRef.$flags$ & 32 /* HOST_FLAGS.hasInitializedComponent */) === 0) {
1162
+ // Let the runtime know that the component has been initialized
1163
+ hostRef.$flags$ |= 32 /* HOST_FLAGS.hasInitializedComponent */;
1114
1164
  {
1115
- // we haven't initialized this element yet
1116
- hostRef.$flags$ |= 32 /* HOST_FLAGS.hasInitializedComponent */;
1117
1165
  // lazy loaded components
1118
1166
  // request the component's implementation to be
1119
1167
  // wired up with the host element
@@ -2,10 +2,10 @@
2
2
 
3
3
  Object.defineProperty(exports, '__esModule', { value: true });
4
4
 
5
- const index = require('./index-76fed79c.js');
5
+ const index = require('./index-44146c73.js');
6
6
 
7
7
  /*
8
- Stencil Client Patch Esm v3.2.1 | MIT Licensed | https://stenciljs.com
8
+ Stencil Client Patch Esm v3.2.2 | MIT Licensed | https://stenciljs.com
9
9
  */
10
10
  const patchEsm = () => {
11
11
  return index.promiseResolve();
@@ -2,10 +2,10 @@
2
2
 
3
3
  Object.defineProperty(exports, '__esModule', { value: true });
4
4
 
5
- const index = require('./index-76fed79c.js');
5
+ const index = require('./index-44146c73.js');
6
6
 
7
7
  /*
8
- Stencil Client Patch Browser v3.2.1 | MIT Licensed | https://stenciljs.com
8
+ Stencil Client Patch Browser v3.2.2 | MIT Licensed | https://stenciljs.com
9
9
  */
10
10
  const patchBrowser = () => {
11
11
  const importMeta = (typeof document === 'undefined' ? new (require('u' + 'rl').URL)('file:' + __filename).href : (document.currentScript && document.currentScript.src || new URL('proto-table-wc.cjs.js', document.baseURI).href));
@@ -5,7 +5,7 @@
5
5
  ],
6
6
  "compiler": {
7
7
  "name": "@stencil/core",
8
- "version": "3.2.1",
8
+ "version": "3.2.2",
9
9
  "typescriptVersion": "4.9.5"
10
10
  },
11
11
  "collections": [],
@@ -1,4 +1,4 @@
1
- import { r as registerInstance, h } from './index-dc847a9f.js';
1
+ import { r as registerInstance, h } from './index-c6cdc45c.js';
2
2
 
3
3
  const demoTableCss = ".detailWrapper{font-weight:100;font-size:13px;display:flex;flex-direction:column;justify-items:start;padding:5px;padding-left:30px}";
4
4
 
@@ -504,16 +504,17 @@ const addVnodes = (parentElm, before, parentVNode, vnodes, startIdx, endIdx) =>
504
504
  * @param vnodes a list of virtual DOM nodes to remove
505
505
  * @param startIdx the index at which to start removing nodes (inclusive)
506
506
  * @param endIdx the index at which to stop removing nodes (inclusive)
507
- * @param vnode a VNode
508
- * @param elm an element
509
507
  */
510
- const removeVnodes = (vnodes, startIdx, endIdx, vnode, elm) => {
511
- for (; startIdx <= endIdx; ++startIdx) {
512
- if ((vnode = vnodes[startIdx])) {
513
- elm = vnode.$elm$;
514
- callNodeRefs(vnode);
515
- // remove the vnode's element from the dom
516
- elm.remove();
508
+ const removeVnodes = (vnodes, startIdx, endIdx) => {
509
+ for (let index = startIdx; index <= endIdx; ++index) {
510
+ const vnode = vnodes[index];
511
+ if (vnode) {
512
+ const elm = vnode.$elm$;
513
+ nullifyVNodeRefs(vnode);
514
+ if (elm) {
515
+ // remove the vnode's element from the dom
516
+ elm.remove();
517
+ }
517
518
  }
518
519
  }
519
520
  };
@@ -770,10 +771,17 @@ const patch = (oldVNode, newVNode) => {
770
771
  elm.data = text;
771
772
  }
772
773
  };
773
- const callNodeRefs = (vNode) => {
774
+ /**
775
+ * 'Nullify' any VDom `ref` callbacks on a VDom node or its children by
776
+ * calling them with `null`. This signals that the DOM element corresponding to
777
+ * the VDom node has been removed from the DOM.
778
+ *
779
+ * @param vNode a virtual DOM node
780
+ */
781
+ const nullifyVNodeRefs = (vNode) => {
774
782
  {
775
783
  vNode.$attrs$ && vNode.$attrs$.ref && vNode.$attrs$.ref(null);
776
- vNode.$children$ && vNode.$children$.map(callNodeRefs);
784
+ vNode.$children$ && vNode.$children$.map(nullifyVNodeRefs);
777
785
  }
778
786
  };
779
787
  /**
@@ -823,20 +831,63 @@ const scheduleUpdate = (hostRef, isInitialLoad) => {
823
831
  const dispatch = () => dispatchHooks(hostRef, isInitialLoad);
824
832
  return writeTask(dispatch) ;
825
833
  };
834
+ /**
835
+ * Dispatch initial-render and update lifecycle hooks, enqueuing calls to
836
+ * component lifecycle methods like `componentWillLoad` as well as
837
+ * {@link updateComponent}, which will kick off the virtual DOM re-render.
838
+ *
839
+ * @param hostRef a reference to a host DOM node
840
+ * @param isInitialLoad whether we're on the initial load or not
841
+ * @returns an empty Promise which is used to enqueue a series of operations for
842
+ * the component
843
+ */
826
844
  const dispatchHooks = (hostRef, isInitialLoad) => {
827
845
  const endSchedule = createTime('scheduleUpdate', hostRef.$cmpMeta$.$tagName$);
828
846
  const instance = hostRef.$lazyInstance$ ;
829
- let promise;
847
+ // We're going to use this variable together with `enqueue` to implement a
848
+ // little promise-based queue. We start out with it `undefined`. When we add
849
+ // the first function to the queue we'll set this variable to be that
850
+ // function's return value. When we attempt to add subsequent values to the
851
+ // queue we'll check that value and, if it was a `Promise`, we'll then chain
852
+ // the new function off of that `Promise` using `.then()`. This will give our
853
+ // queue two nice properties:
854
+ //
855
+ // 1. If all functions added to the queue are synchronous they'll be called
856
+ // synchronously right away.
857
+ // 2. If all functions added to the queue are asynchronous they'll all be
858
+ // called in order after `dispatchHooks` exits.
859
+ let maybePromise;
830
860
  if (isInitialLoad) {
831
861
  {
832
- promise = safeCall(instance, 'componentWillLoad');
862
+ // If `componentWillLoad` returns a `Promise` then we want to wait on
863
+ // whatever's going on in that `Promise` before we launch into
864
+ // rendering the component, doing other lifecycle stuff, etc. So
865
+ // in that case we assign the returned promise to the variable we
866
+ // declared above to hold a possible 'queueing' Promise
867
+ maybePromise = safeCall(instance, 'componentWillLoad');
833
868
  }
834
869
  }
835
870
  endSchedule();
836
- return then(promise, () => updateComponent(hostRef, instance, isInitialLoad));
871
+ return enqueue(maybePromise, () => updateComponent(hostRef, instance, isInitialLoad));
837
872
  };
873
+ /**
874
+ * This function uses a Promise to implement a simple first-in, first-out queue
875
+ * of functions to be called.
876
+ *
877
+ * The queue is ordered on the basis of the first argument. If it's
878
+ * `undefined`, then nothing is on the queue yet, so the provided function can
879
+ * be called synchronously (although note that this function may return a
880
+ * `Promise`). The idea is that then the return value of that enqueueing
881
+ * operation is kept around, so that if it was a `Promise` then subsequent
882
+ * functions can be enqueued by calling this function again with that `Promise`
883
+ * as the first argument.
884
+ *
885
+ * @param maybePromise either a `Promise` which should resolve before the next function is called or an 'empty' sentinel
886
+ * @param fn a function to enqueue
887
+ * @returns either a `Promise` or the return value of the provided function
888
+ */
889
+ const enqueue = (maybePromise, fn) => maybePromise instanceof Promise ? maybePromise.then(fn) : fn();
838
890
  const updateComponent = async (hostRef, instance, isInitialLoad) => {
839
- // updateComponent
840
891
  const elm = hostRef.$hostElement$;
841
892
  const endUpdate = createTime('update', hostRef.$cmpMeta$.$tagName$);
842
893
  const rc = elm['s-rc'];
@@ -956,9 +1007,6 @@ const safeCall = (instance, method, arg) => {
956
1007
  }
957
1008
  return undefined;
958
1009
  };
959
- const then = (promise, thenFn) => {
960
- return promise && promise.then ? promise.then(thenFn) : thenFn();
961
- };
962
1010
  const addHydratedFlag = (elm) => elm.classList.add('hydrated')
963
1011
  ;
964
1012
  const getValue = (ref, propName) => getHostRef(ref).$instanceValues$.get(propName);
@@ -1089,9 +1137,9 @@ const proxyComponent = (Cstr, cmpMeta, flags) => {
1089
1137
  const initializeComponent = async (elm, hostRef, cmpMeta, hmrVersionId, Cstr) => {
1090
1138
  // initializeComponent
1091
1139
  if ((hostRef.$flags$ & 32 /* HOST_FLAGS.hasInitializedComponent */) === 0) {
1140
+ // Let the runtime know that the component has been initialized
1141
+ hostRef.$flags$ |= 32 /* HOST_FLAGS.hasInitializedComponent */;
1092
1142
  {
1093
- // we haven't initialized this element yet
1094
- hostRef.$flags$ |= 32 /* HOST_FLAGS.hasInitializedComponent */;
1095
1143
  // lazy loaded components
1096
1144
  // request the component's implementation to be
1097
1145
  // wired up with the host element
@@ -1,8 +1,8 @@
1
- import { p as promiseResolve, b as bootstrapLazy } from './index-dc847a9f.js';
2
- export { s as setNonce } from './index-dc847a9f.js';
1
+ import { p as promiseResolve, b as bootstrapLazy } from './index-c6cdc45c.js';
2
+ export { s as setNonce } from './index-c6cdc45c.js';
3
3
 
4
4
  /*
5
- Stencil Client Patch Esm v3.2.1 | MIT Licensed | https://stenciljs.com
5
+ Stencil Client Patch Esm v3.2.2 | MIT Licensed | https://stenciljs.com
6
6
  */
7
7
  const patchEsm = () => {
8
8
  return promiseResolve();
@@ -1,8 +1,8 @@
1
- import { p as promiseResolve, b as bootstrapLazy } from './index-dc847a9f.js';
2
- export { s as setNonce } from './index-dc847a9f.js';
1
+ import { p as promiseResolve, b as bootstrapLazy } from './index-c6cdc45c.js';
2
+ export { s as setNonce } from './index-c6cdc45c.js';
3
3
 
4
4
  /*
5
- Stencil Client Patch Browser v3.2.1 | MIT Licensed | https://stenciljs.com
5
+ Stencil Client Patch Browser v3.2.2 | MIT Licensed | https://stenciljs.com
6
6
  */
7
7
  const patchBrowser = () => {
8
8
  const importMeta = import.meta.url;
@@ -0,0 +1,2 @@
1
+ let t,e,n=!1,l=!1;const o={},s=t=>"object"==(t=typeof t)||"function"===t;function i(t){var e,n,l;return null!==(l=null===(n=null===(e=t.head)||void 0===e?void 0:e.querySelector('meta[name="csp-nonce"]'))||void 0===n?void 0:n.getAttribute("content"))&&void 0!==l?l:void 0}const c=(t,e,...n)=>{let l=null,o=!1,i=!1;const c=[],u=e=>{for(let n=0;n<e.length;n++)l=e[n],Array.isArray(l)?u(l):null!=l&&"boolean"!=typeof l&&((o="function"!=typeof t&&!s(l))&&(l+=""),o&&i?c[c.length-1].t+=l:c.push(o?r(null,l):l),i=o)};if(u(n),e){const t=e.className||e.class;t&&(e.class="object"!=typeof t?t:Object.keys(t).filter((e=>t[e])).join(" "))}const a=r(t,null);return a.l=e,c.length>0&&(a.o=c),a},r=(t,e)=>({i:0,u:t,t:e,h:null,o:null,l:null}),u={},a=new WeakMap,f=t=>"sc-"+t.p,d=(t,e,n,l,o,i)=>{if(n!==l){let c=D(t,e),r=e.toLowerCase();if("class"===e){const e=t.classList,o=p(n),s=p(l);e.remove(...o.filter((t=>t&&!s.includes(t)))),e.add(...s.filter((t=>t&&!o.includes(t))))}else if("ref"===e)l&&l(t);else if(c||"o"!==e[0]||"n"!==e[1]){const r=s(l);if((c||r&&null!==l)&&!o)try{if(t.tagName.includes("-"))t[e]=l;else{const o=null==l?"":l;"list"===e?c=!1:null!=n&&t[e]==o||(t[e]=o)}}catch(t){}null==l||!1===l?!1===l&&""!==t.getAttribute(e)||t.removeAttribute(e):(!c||4&i||o)&&!r&&t.setAttribute(e,l=!0===l?"":l)}else e="-"===e[2]?e.slice(3):D(z,r)?r.slice(2):r[2]+e.slice(3),n&&G.rel(t,e,n,!1),l&&G.ael(t,e,l,!1)}},h=/\s/,p=t=>t?t.split(h):[],m=(t,e,n,l)=>{const s=11===e.h.nodeType&&e.h.host?e.h.host:e.h,i=t&&t.l||o,c=e.l||o;for(l in i)l in c||d(s,l,i[l],void 0,n,e.i);for(l in c)d(s,l,i[l],c[l],n,e.i)},$=(e,l,o)=>{const s=l.o[o];let i,c,r=0;if(null!==s.t)i=s.h=B.createTextNode(s.t);else{if(n||(n="svg"===s.u),i=s.h=B.createElementNS(n?"http://www.w3.org/2000/svg":"http://www.w3.org/1999/xhtml",s.u),n&&"foreignObject"===s.u&&(n=!1),m(null,s,n),null!=t&&i["s-si"]!==t&&i.classList.add(i["s-si"]=t),s.o)for(r=0;r<s.o.length;++r)c=$(e,s,r),c&&i.appendChild(c);"svg"===s.u?n=!1:"foreignObject"===i.tagName&&(n=!0)}return i},y=(t,n,l,o,s,i)=>{let c,r=t;for(r.shadowRoot&&r.tagName===e&&(r=r.shadowRoot);s<=i;++s)o[s]&&(c=$(null,l,s),c&&(o[s].h=c,r.insertBefore(c,n)))},w=(t,e,n)=>{for(let l=e;l<=n;++l){const e=t[l];if(e){const t=e.h;g(e),t&&t.remove()}}},b=(t,e)=>t.u===e.u,v=(t,e)=>{const l=e.h=t.h,o=t.o,s=e.o,i=e.u,c=e.t;null===c?(n="svg"===i||"foreignObject"!==i&&n,m(t,e,n),null!==o&&null!==s?((t,e,n,l)=>{let o,s=0,i=0,c=e.length-1,r=e[0],u=e[c],a=l.length-1,f=l[0],d=l[a];for(;s<=c&&i<=a;)null==r?r=e[++s]:null==u?u=e[--c]:null==f?f=l[++i]:null==d?d=l[--a]:b(r,f)?(v(r,f),r=e[++s],f=l[++i]):b(u,d)?(v(u,d),u=e[--c],d=l[--a]):b(r,d)?(v(r,d),t.insertBefore(r.h,u.h.nextSibling),r=e[++s],d=l[--a]):b(u,f)?(v(u,f),t.insertBefore(u.h,r.h),u=e[--c],f=l[++i]):(o=$(e&&e[i],n,i),f=l[++i],o&&r.h.parentNode.insertBefore(o,r.h));s>c?y(t,null==l[a+1]?null:l[a+1].h,n,l,i,a):i>a&&w(e,s,c)})(l,o,e,s):null!==s?(null!==t.t&&(l.textContent=""),y(l,null,e,s,0,s.length-1)):null!==o&&w(o,0,o.length-1),n&&"svg"===i&&(n=!1)):t.t!==c&&(l.data=c)},g=t=>{t.l&&t.l.ref&&t.l.ref(null),t.o&&t.o.map(g)},S=(t,e)=>{e&&!t.m&&e["s-p"]&&e["s-p"].push(new Promise((e=>t.m=e)))},j=(t,e)=>{if(t.i|=16,!(4&t.i))return S(t,t.$),et((()=>O(t,e)));t.i|=512},O=(t,e)=>{const n=t.v;let l;return e&&(l=L(n,"componentWillLoad")),M(l,(()=>k(t,n,e)))},M=(t,e)=>t instanceof Promise?t.then(e):e(),k=async(t,e,n)=>{const l=t.g,o=l["s-rc"];n&&(t=>{const e=t.S,n=t.g,l=e.i,o=((t,e)=>{var n;let l=f(e);const o=_.get(l);if(t=11===t.nodeType?t:B,o)if("string"==typeof o){let e,s=a.get(t=t.head||t);if(s||a.set(t,s=new Set),!s.has(l)){{e=B.createElement("style"),e.innerHTML=o;const l=null!==(n=G.j)&&void 0!==n?n:i(B);null!=l&&e.setAttribute("nonce",l),t.insertBefore(e,t.querySelector("link"))}s&&s.add(l)}}else t.adoptedStyleSheets.includes(o)||(t.adoptedStyleSheets=[...t.adoptedStyleSheets,o]);return l})(n.shadowRoot?n.shadowRoot:n.getRootNode(),e);10&l&&(n["s-sc"]=o,n.classList.add(o+"-h"))})(t);C(t,e),o&&(o.map((t=>t())),l["s-rc"]=void 0);{const e=l["s-p"],n=()=>P(t);0===e.length?n():(Promise.all(e).then(n),t.i|=4,e.length=0)}},C=(n,l)=>{try{l=l.render(),n.i&=-17,n.i|=2,((n,l)=>{const o=n.g,s=n.O||r(null,null),i=(t=>t&&t.u===u)(l)?l:c(null,null,l);e=o.tagName,i.u=null,i.i|=4,n.O=i,i.h=s.h=o.shadowRoot||o,t=o["s-sc"],v(s,i)})(n,l)}catch(t){F(t,n.g)}return null},P=t=>{const e=t.g,n=t.v,l=t.$;64&t.i||(t.i|=64,E(e),L(n,"componentDidLoad"),t.M(e),l||x()),t.m&&(t.m(),t.m=void 0),512&t.i&&tt((()=>j(t,!1))),t.i&=-517},x=()=>{E(B.documentElement),tt((()=>(t=>{const e=G.ce("appload",{detail:{namespace:"proto-table-wc"}});return t.dispatchEvent(e),e})(z)))},L=(t,e,n)=>{if(t&&t[e])try{return t[e](n)}catch(t){F(t)}},E=t=>t.classList.add("hydrated"),N=(t,e,n)=>{if(e.k){const l=Object.entries(e.k),o=t.prototype;if(l.map((([t,[e]])=>{(31&e||2&n&&32&e)&&Object.defineProperty(o,t,{get(){return((t,e)=>R(this).C.get(e))(0,t)},set(e){((t,e,n)=>{const l=R(t),o=l.C.get(e),i=l.i,c=l.v;n=(t=>(null==t||s(t),t))(n),8&i&&void 0!==o||n===o||Number.isNaN(o)&&Number.isNaN(n)||(l.C.set(e,n),c&&2==(18&i)&&j(l,!1))})(this,t,e)},configurable:!0,enumerable:!0})})),1&n){const e=new Map;o.attributeChangedCallback=function(t,n,l){G.jmp((()=>{const n=e.get(t);if(this.hasOwnProperty(n))l=this[n],delete this[n];else if(o.hasOwnProperty(n)&&"number"==typeof this[n]&&this[n]==l)return;this[n]=(null!==l||"boolean"!=typeof this[n])&&l}))},t.observedAttributes=l.filter((([t,e])=>15&e[0])).map((([t,n])=>{const l=n[1]||t;return e.set(l,t),l}))}}return t},T=(t,e={})=>{var n;const l=[],o=e.exclude||[],s=z.customElements,c=B.head,r=c.querySelector("meta[charset]"),u=B.createElement("style"),a=[];let d,h=!0;Object.assign(G,e),G.P=new URL(e.resourcesUrl||"./",B.baseURI).href,t.map((t=>{t[1].map((e=>{const n={i:e[0],p:e[1],k:e[2],L:e[3]};n.k=e[2];const i=n.p,c=class extends HTMLElement{constructor(t){super(t),q(t=this,n),1&n.i&&t.attachShadow({mode:"open"})}connectedCallback(){d&&(clearTimeout(d),d=null),h?a.push(this):G.jmp((()=>(t=>{if(0==(1&G.i)){const e=R(t),n=e.S,l=()=>{};if(!(1&e.i)){e.i|=1;{let n=t;for(;n=n.parentNode||n.host;)if(n["s-p"]){S(e,e.$=n);break}}n.k&&Object.entries(n.k).map((([e,[n]])=>{if(31&n&&t.hasOwnProperty(e)){const n=t[e];delete t[e],t[e]=n}})),(async(t,e,n,l,o)=>{if(0==(32&e.i)){e.i|=32;{if((o=V(n)).then){const t=()=>{};o=await o,t()}o.isProxied||(N(o,n,2),o.isProxied=!0);const t=()=>{};e.i|=8;try{new o(e)}catch(t){F(t)}e.i&=-9,t()}if(o.style){let t=o.style;const e=f(n);if(!_.has(e)){const l=()=>{};((t,e,n)=>{let l=_.get(t);J&&n?(l=l||new CSSStyleSheet,"string"==typeof l?l=e:l.replaceSync(e)):l=e,_.set(t,l)})(e,t,!!(1&n.i)),l()}}}const s=e.$,i=()=>j(e,!0);s&&s["s-rc"]?s["s-rc"].push(i):i()})(0,e,n)}l()}})(this)))}disconnectedCallback(){G.jmp((()=>{}))}componentOnReady(){return R(this).N}};n.T=t[0],o.includes(i)||s.get(i)||(l.push(i),s.define(i,N(c,n,1)))}))}));{u.innerHTML=l+"{visibility:hidden}.hydrated{visibility:inherit}",u.setAttribute("data-styles","");const t=null!==(n=G.j)&&void 0!==n?n:i(B);null!=t&&u.setAttribute("nonce",t),c.insertBefore(u,r?r.nextSibling:c.firstChild)}h=!1,a.length?a.map((t=>t.connectedCallback())):G.jmp((()=>d=setTimeout(x,30)))},W=t=>G.j=t,A=new WeakMap,R=t=>A.get(t),U=(t,e)=>A.set(e.v=t,e),q=(t,e)=>{const n={i:0,g:t,S:e,C:new Map};return n.N=new Promise((t=>n.M=t)),t["s-p"]=[],t["s-rc"]=[],A.set(t,n)},D=(t,e)=>e in t,F=(t,e)=>(0,console.error)(t,e),H=new Map,V=t=>{const e=t.p.replace(/-/g,"_"),n=t.T,l=H.get(n);return l?l[e]:import(`./${n}.entry.js`).then((t=>(H.set(n,t),t[e])),F)
2
+ /*!__STENCIL_STATIC_IMPORT_SWITCH__*/},_=new Map,z="undefined"!=typeof window?window:{},B=z.document||{head:{}},G={i:0,P:"",jmp:t=>t(),raf:t=>requestAnimationFrame(t),ael:(t,e,n,l)=>t.addEventListener(e,n,l),rel:(t,e,n,l)=>t.removeEventListener(e,n,l),ce:(t,e)=>new CustomEvent(t,e)},I=t=>Promise.resolve(t),J=(()=>{try{return new CSSStyleSheet,"function"==typeof(new CSSStyleSheet).replaceSync}catch(t){}return!1})(),K=[],Q=[],X=(t,e)=>n=>{t.push(n),l||(l=!0,e&&4&G.i?tt(Z):G.raf(Z))},Y=t=>{for(let e=0;e<t.length;e++)try{t[e](performance.now())}catch(t){F(t)}t.length=0},Z=()=>{Y(K),Y(Q),(l=K.length>0)&&G.raf(Z)},tt=t=>I().then(t),et=X(Q,!0);export{T as b,c as h,I as p,U as r,W as s}
@@ -1 +1 @@
1
- import{r as t,h as e}from"./p-9534e369.js";const r=class{constructor(r){t(this,r),this.fields=[{label:"Date",prop:"date"},{label:"List Price",prop:"price"},{label:"% of Market",prop:"market"},{label:"ProfitTime Score",prop:"score"}],this.items=[],this.table=void 0,this.renderDetails=t=>{const{tags:r=[]}=t;return e("div",{class:"detailWrapper"},e("span",null,r.length," details..."),e("ul",null,r.map((t=>e("li",null,t)))))}}componentWillLoad(){this.items=[{date:"08/30/2020",price:"$24,000",market:"98%",score:"No Score",tags:["one","two","three"]},{date:"08/31/2020",price:"$24,000",market:"99%",score:"No Score",tags:["uno","duo"]},{date:"09/01/2020",price:"$27,000",market:"102%",score:"Platinum"},{date:"09/02/2020",price:"$27,423",market:"104%",score:"Platinum",tags:["dog","cat","fish","hamster"]},{date:"09/03/2020",price:"$27,521",market:"106%",score:"Platinum",tags:["4wd","sports"]},{date:"09/04/2020",price:"$27,687",market:"107%",score:"Platinum",tags:["leather","chrome"]}]}componentDidLoad(){const{table:t,items:e,fields:r}=this;t.data=e,t.fields=r,t.details=this.renderDetails}render(){return e("proto-table",{ref:t=>this.table=t})}};r.style=".detailWrapper{font-weight:100;font-size:13px;display:flex;flex-direction:column;justify-items:start;padding:5px;padding-left:30px}";const s={down:"M12 15.4L6.6 10 8 8.6l4 4 4-4 1.4 1.4z",up:"M16 15.4l-4-4-4 4L6.6 14 12 8.6l5.4 5.4z",left:"M14 17.4L8.6 12 14 6.6 15.4 8l-4 4 4 4z",right:"M10 17.4L8.6 16l4-4-4-4L10 6.6l5.4 5.4z",more:"M12 14a2 2 0 100-4 2 2 0 000 4zm-6 0a2 2 0 100-4 2 2 0 000 4zm12 0a2 2 0 100-4 2 2 0 000 4z","arrow-up":"M5.3 10.7l1.4 1.4L11 7.8V20h2V7.8l4.3 4.3 1.4-1.4L12 4z","arrow-down":"M18.7 13.3l-1.4-1.4-4.3 4.3V4h-2v12.2l-4.3-4.3-1.4 1.4L12 20z"},i={right:"show",down:"hide","arrow-up":"sort","arrow-down":"sort"},l=class{constructor(r){t(this,r),this.protoIcon=(t,r,l=24)=>{const o=s[t];return e("svg",{width:l,height:l,viewBox:"0 0 24 24",role:"img","aria-labelledby":"title"},e("title",null,(t=>i[t])(t)),e("g",{fill:r},e("path",{d:o})),e("path",{d:"M0 0h24v24H0z",fill:"none"}))},this.handleCellClick=(t,e)=>()=>{0===t&&(this.expanded=this.expanded===e?void 0:e)},this.handleSortClick=t=>()=>{this.sort===t?2===this.clicks?(this.clicks=0,this.sort=void 0):this.clicks=this.clicks+1:(this.sort=t,this.clicks=1)},this.iconFor=t=>this.sort===t&&2===this.clicks?"arrow-up":"arrow-down",this.header=()=>{const{fields:t,iconFor:r,protoIcon:s}=this;return e("div",{class:"header"},t.map((({label:t},i)=>{const l=i===this.sort?"headerCell sort":"headerCell",o=r(i);return e("div",{class:l,onClick:this.handleSortClick(i)},s(o),e("span",null,t))})))},this.row=(t,r)=>{const{fields:s,protoIcon:i}=this;return e("div",{class:"rowContainer"},e("div",{class:this.expanded===r?"row expanded":"row"},s.map((({prop:s},l)=>e("div",{class:l===this.sort?"cell sort":"cell",onClick:this.handleCellClick(l,r)},i(0===l&&this.details?this.expanded===r?"down":"right":"pad"),t[s])))),this.details&&this.expanded===r&&this.details(t))},this.data=[],this.details=void 0,this.fields=[],this.expanded=void 0,this.sort=void 0,this.clicks=0}render(){const t=this.data||[];return e("div",{class:"table"},this.header(),t.map(((t,e)=>this.row(t,e))))}};l.style=".table{font-weight:400;font-size:13px;display:flex;flex-direction:column;width:100%;border:1px solid var(--clrs-navy);border-radius:2px}.table svg{fill:var(--clrs-navy)}.header{display:flex}.headerCell{flex-basis:100%;display:flex;align-items:center;justify-items:start;border-right:1px solid var(--clrs-navy);border-bottom:1px solid var(--clrs-navy);padding:5px;cursor:pointer}.headerCell svg g{display:none}.headerCell.sort svg g{display:inline}.headerCell:hover svg g{display:inline}.headerCell:hover{background-color:var(--clrs-silver)}.headerCell:last-child{border-right:none}.cell{flex-basis:100%;display:flex;align-items:center;justify-items:start;padding:5px}.cell:first-child svg{cursor:pointer}.sort{background-color:var(--cx-column-sort)}.row{display:flex;justify-items:stretch;width:100%}.row.expanded{background-color:var(--cx-row-expanded)}.row.expanded svg{fill:var(--clrs-red)}.row:hover{background-color:var(--cx-row-hover)}";export{r as demo_table,l as proto_table}
1
+ import{r as t,h as e}from"./p-3be68326.js";const r=class{constructor(r){t(this,r),this.fields=[{label:"Date",prop:"date"},{label:"List Price",prop:"price"},{label:"% of Market",prop:"market"},{label:"ProfitTime Score",prop:"score"}],this.items=[],this.table=void 0,this.renderDetails=t=>{const{tags:r=[]}=t;return e("div",{class:"detailWrapper"},e("span",null,r.length," details..."),e("ul",null,r.map((t=>e("li",null,t)))))}}componentWillLoad(){this.items=[{date:"08/30/2020",price:"$24,000",market:"98%",score:"No Score",tags:["one","two","three"]},{date:"08/31/2020",price:"$24,000",market:"99%",score:"No Score",tags:["uno","duo"]},{date:"09/01/2020",price:"$27,000",market:"102%",score:"Platinum"},{date:"09/02/2020",price:"$27,423",market:"104%",score:"Platinum",tags:["dog","cat","fish","hamster"]},{date:"09/03/2020",price:"$27,521",market:"106%",score:"Platinum",tags:["4wd","sports"]},{date:"09/04/2020",price:"$27,687",market:"107%",score:"Platinum",tags:["leather","chrome"]}]}componentDidLoad(){const{table:t,items:e,fields:r}=this;t.data=e,t.fields=r,t.details=this.renderDetails}render(){return e("proto-table",{ref:t=>this.table=t})}};r.style=".detailWrapper{font-weight:100;font-size:13px;display:flex;flex-direction:column;justify-items:start;padding:5px;padding-left:30px}";const s={down:"M12 15.4L6.6 10 8 8.6l4 4 4-4 1.4 1.4z",up:"M16 15.4l-4-4-4 4L6.6 14 12 8.6l5.4 5.4z",left:"M14 17.4L8.6 12 14 6.6 15.4 8l-4 4 4 4z",right:"M10 17.4L8.6 16l4-4-4-4L10 6.6l5.4 5.4z",more:"M12 14a2 2 0 100-4 2 2 0 000 4zm-6 0a2 2 0 100-4 2 2 0 000 4zm12 0a2 2 0 100-4 2 2 0 000 4z","arrow-up":"M5.3 10.7l1.4 1.4L11 7.8V20h2V7.8l4.3 4.3 1.4-1.4L12 4z","arrow-down":"M18.7 13.3l-1.4-1.4-4.3 4.3V4h-2v12.2l-4.3-4.3-1.4 1.4L12 20z"},i={right:"show",down:"hide","arrow-up":"sort","arrow-down":"sort"},l=class{constructor(r){t(this,r),this.protoIcon=(t,r,l=24)=>{const o=s[t];return e("svg",{width:l,height:l,viewBox:"0 0 24 24",role:"img","aria-labelledby":"title"},e("title",null,(t=>i[t])(t)),e("g",{fill:r},e("path",{d:o})),e("path",{d:"M0 0h24v24H0z",fill:"none"}))},this.handleCellClick=(t,e)=>()=>{0===t&&(this.expanded=this.expanded===e?void 0:e)},this.handleSortClick=t=>()=>{this.sort===t?2===this.clicks?(this.clicks=0,this.sort=void 0):this.clicks=this.clicks+1:(this.sort=t,this.clicks=1)},this.iconFor=t=>this.sort===t&&2===this.clicks?"arrow-up":"arrow-down",this.header=()=>{const{fields:t,iconFor:r,protoIcon:s}=this;return e("div",{class:"header"},t.map((({label:t},i)=>{const l=i===this.sort?"headerCell sort":"headerCell",o=r(i);return e("div",{class:l,onClick:this.handleSortClick(i)},s(o),e("span",null,t))})))},this.row=(t,r)=>{const{fields:s,protoIcon:i}=this;return e("div",{class:"rowContainer"},e("div",{class:this.expanded===r?"row expanded":"row"},s.map((({prop:s},l)=>e("div",{class:l===this.sort?"cell sort":"cell",onClick:this.handleCellClick(l,r)},i(0===l&&this.details?this.expanded===r?"down":"right":"pad"),t[s])))),this.details&&this.expanded===r&&this.details(t))},this.data=[],this.details=void 0,this.fields=[],this.expanded=void 0,this.sort=void 0,this.clicks=0}render(){const t=this.data||[];return e("div",{class:"table"},this.header(),t.map(((t,e)=>this.row(t,e))))}};l.style=".table{font-weight:400;font-size:13px;display:flex;flex-direction:column;width:100%;border:1px solid var(--clrs-navy);border-radius:2px}.table svg{fill:var(--clrs-navy)}.header{display:flex}.headerCell{flex-basis:100%;display:flex;align-items:center;justify-items:start;border-right:1px solid var(--clrs-navy);border-bottom:1px solid var(--clrs-navy);padding:5px;cursor:pointer}.headerCell svg g{display:none}.headerCell.sort svg g{display:inline}.headerCell:hover svg g{display:inline}.headerCell:hover{background-color:var(--clrs-silver)}.headerCell:last-child{border-right:none}.cell{flex-basis:100%;display:flex;align-items:center;justify-items:start;padding:5px}.cell:first-child svg{cursor:pointer}.sort{background-color:var(--cx-column-sort)}.row{display:flex;justify-items:stretch;width:100%}.row.expanded{background-color:var(--cx-row-expanded)}.row.expanded svg{fill:var(--clrs-red)}.row:hover{background-color:var(--cx-row-hover)}";export{r as demo_table,l as proto_table}
@@ -1 +1 @@
1
- import{p as e,b as t}from"./p-9534e369.js";export{s as setNonce}from"./p-9534e369.js";(()=>{const t=import.meta.url,s={};return""!==t&&(s.resourcesUrl=new URL(".",t).href),e(s)})().then((e=>t([["p-234abb83",[[1,"demo-table"],[0,"proto-table",{data:[16],details:[8],fields:[16],expanded:[32],sort:[32],clicks:[32]}]]]],e)));
1
+ import{p as e,b as t}from"./p-3be68326.js";export{s as setNonce}from"./p-3be68326.js";(()=>{const t=import.meta.url,s={};return""!==t&&(s.resourcesUrl=new URL(".",t).href),e(s)})().then((e=>t([["p-d7d7a705",[[1,"demo-table"],[0,"proto-table",{data:[16],details:[8],fields:[16],expanded:[32],sort:[32],clicks:[32]}]]]],e)));
@@ -812,6 +812,7 @@ export declare namespace JSXBase {
812
812
  datetime?: string;
813
813
  }
814
814
  interface DialogHTMLAttributes<T> extends HTMLAttributes<T> {
815
+ onCancel?: (event: Event) => void;
815
816
  onClose?: (event: Event) => void;
816
817
  open?: boolean;
817
818
  returnValue?: string;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "proto-table-wc",
3
- "version": "0.0.420",
3
+ "version": "0.0.422",
4
4
  "description": "Stencil Component Starter",
5
5
  "main": "dist/index.cjs.js",
6
6
  "module": "dist/index.js",
@@ -25,11 +25,11 @@
25
25
  "format": "prettier --write src"
26
26
  },
27
27
  "dependencies": {
28
- "@stencil/core": "3.2.1"
28
+ "@stencil/core": "3.2.2"
29
29
  },
30
30
  "devDependencies": {
31
31
  "cspell": "6.31.1",
32
- "eslint": "8.39.0",
32
+ "eslint": "8.40.0",
33
33
  "prettier": "2.8.8",
34
34
  "tslint": "6.1.3",
35
35
  "typescript": "5.0.4"
@@ -1,2 +0,0 @@
1
- let e,t,n=!1,l=!1;const o={},s=e=>"object"==(e=typeof e)||"function"===e;function r(e){var t,n,l;return null!==(l=null===(n=null===(t=e.head)||void 0===t?void 0:t.querySelector('meta[name="csp-nonce"]'))||void 0===n?void 0:n.getAttribute("content"))&&void 0!==l?l:void 0}const i=(e,t,...n)=>{let l=null,o=!1,r=!1;const i=[],u=t=>{for(let n=0;n<t.length;n++)l=t[n],Array.isArray(l)?u(l):null!=l&&"boolean"!=typeof l&&((o="function"!=typeof e&&!s(l))&&(l+=""),o&&r?i[i.length-1].t+=l:i.push(o?c(null,l):l),r=o)};if(u(n),t){const e=t.className||t.class;e&&(t.class="object"!=typeof e?e:Object.keys(e).filter((t=>e[t])).join(" "))}const a=c(e,null);return a.l=t,i.length>0&&(a.o=i),a},c=(e,t)=>({i:0,u:e,t,h:null,o:null,l:null}),u={},a=new WeakMap,f=e=>"sc-"+e.p,d=(e,t,n,l,o,r)=>{if(n!==l){let i=D(e,t),c=t.toLowerCase();if("class"===t){const t=e.classList,o=p(n),s=p(l);t.remove(...o.filter((e=>e&&!s.includes(e)))),t.add(...s.filter((e=>e&&!o.includes(e))))}else if("ref"===t)l&&l(e);else if(i||"o"!==t[0]||"n"!==t[1]){const c=s(l);if((i||c&&null!==l)&&!o)try{if(e.tagName.includes("-"))e[t]=l;else{const o=null==l?"":l;"list"===t?i=!1:null!=n&&e[t]==o||(e[t]=o)}}catch(e){}null==l||!1===l?!1===l&&""!==e.getAttribute(t)||e.removeAttribute(t):(!i||4&r||o)&&!c&&e.setAttribute(t,l=!0===l?"":l)}else t="-"===t[2]?t.slice(3):D(z,c)?c.slice(2):c[2]+t.slice(3),n&&G.rel(e,t,n,!1),l&&G.ael(e,t,l,!1)}},h=/\s/,p=e=>e?e.split(h):[],$=(e,t,n,l)=>{const s=11===t.h.nodeType&&t.h.host?t.h.host:t.h,r=e&&e.l||o,i=t.l||o;for(l in r)l in i||d(s,l,r[l],void 0,n,t.i);for(l in i)d(s,l,r[l],i[l],n,t.i)},m=(t,l,o)=>{const s=l.o[o];let r,i,c=0;if(null!==s.t)r=s.h=B.createTextNode(s.t);else{if(n||(n="svg"===s.u),r=s.h=B.createElementNS(n?"http://www.w3.org/2000/svg":"http://www.w3.org/1999/xhtml",s.u),n&&"foreignObject"===s.u&&(n=!1),$(null,s,n),null!=e&&r["s-si"]!==e&&r.classList.add(r["s-si"]=e),s.o)for(c=0;c<s.o.length;++c)i=m(t,s,c),i&&r.appendChild(i);"svg"===s.u?n=!1:"foreignObject"===r.tagName&&(n=!0)}return r},y=(e,n,l,o,s,r)=>{let i,c=e;for(c.shadowRoot&&c.tagName===t&&(c=c.shadowRoot);s<=r;++s)o[s]&&(i=m(null,l,s),i&&(o[s].h=i,c.insertBefore(i,n)))},w=(e,t,n,l,o)=>{for(;t<=n;++t)(l=e[t])&&(o=l.h,g(l),o.remove())},b=(e,t)=>e.u===t.u,v=(e,t)=>{const l=t.h=e.h,o=e.o,s=t.o,r=t.u,i=t.t;null===i?(n="svg"===r||"foreignObject"!==r&&n,$(e,t,n),null!==o&&null!==s?((e,t,n,l)=>{let o,s=0,r=0,i=t.length-1,c=t[0],u=t[i],a=l.length-1,f=l[0],d=l[a];for(;s<=i&&r<=a;)null==c?c=t[++s]:null==u?u=t[--i]:null==f?f=l[++r]:null==d?d=l[--a]:b(c,f)?(v(c,f),c=t[++s],f=l[++r]):b(u,d)?(v(u,d),u=t[--i],d=l[--a]):b(c,d)?(v(c,d),e.insertBefore(c.h,u.h.nextSibling),c=t[++s],d=l[--a]):b(u,f)?(v(u,f),e.insertBefore(u.h,c.h),u=t[--i],f=l[++r]):(o=m(t&&t[r],n,r),f=l[++r],o&&c.h.parentNode.insertBefore(o,c.h));s>i?y(e,null==l[a+1]?null:l[a+1].h,n,l,r,a):r>a&&w(t,s,i)})(l,o,t,s):null!==s?(null!==e.t&&(l.textContent=""),y(l,null,t,s,0,s.length-1)):null!==o&&w(o,0,o.length-1),n&&"svg"===r&&(n=!1)):e.t!==i&&(l.data=i)},g=e=>{e.l&&e.l.ref&&e.l.ref(null),e.o&&e.o.map(g)},S=(e,t)=>{t&&!e.$&&t["s-p"]&&t["s-p"].push(new Promise((t=>e.$=t)))},j=(e,t)=>{if(e.i|=16,!(4&e.i))return S(e,e.m),te((()=>O(e,t)));e.i|=512},O=(e,t)=>{const n=e.v;let l;return t&&(l=L(n,"componentWillLoad")),P(l,(()=>M(e,n,t)))},M=async(e,t,n)=>{const l=e.g,o=l["s-rc"];n&&(e=>{const t=e.S,n=e.g,l=t.i,o=((e,t)=>{var n;let l=f(t);const o=_.get(l);if(e=11===e.nodeType?e:B,o)if("string"==typeof o){let t,s=a.get(e=e.head||e);if(s||a.set(e,s=new Set),!s.has(l)){{t=B.createElement("style"),t.innerHTML=o;const l=null!==(n=G.j)&&void 0!==n?n:r(B);null!=l&&t.setAttribute("nonce",l),e.insertBefore(t,e.querySelector("link"))}s&&s.add(l)}}else e.adoptedStyleSheets.includes(o)||(e.adoptedStyleSheets=[...e.adoptedStyleSheets,o]);return l})(n.shadowRoot?n.shadowRoot:n.getRootNode(),t);10&l&&(n["s-sc"]=o,n.classList.add(o+"-h"))})(e);k(e,t),o&&(o.map((e=>e())),l["s-rc"]=void 0);{const t=l["s-p"],n=()=>C(e);0===t.length?n():(Promise.all(t).then(n),e.i|=4,t.length=0)}},k=(n,l)=>{try{l=l.render(),n.i&=-17,n.i|=2,((n,l)=>{const o=n.g,s=n.O||c(null,null),r=(e=>e&&e.u===u)(l)?l:i(null,null,l);t=o.tagName,r.u=null,r.i|=4,n.O=r,r.h=s.h=o.shadowRoot||o,e=o["s-sc"],v(s,r)})(n,l)}catch(e){F(e,n.g)}return null},C=e=>{const t=e.g,n=e.v,l=e.m;64&e.i||(e.i|=64,E(t),L(n,"componentDidLoad"),e.M(t),l||x()),e.$&&(e.$(),e.$=void 0),512&e.i&&ee((()=>j(e,!1))),e.i&=-517},x=()=>{E(B.documentElement),ee((()=>(e=>{const t=G.ce("appload",{detail:{namespace:"proto-table-wc"}});return e.dispatchEvent(t),t})(z)))},L=(e,t,n)=>{if(e&&e[t])try{return e[t](n)}catch(e){F(e)}},P=(e,t)=>e&&e.then?e.then(t):t(),E=e=>e.classList.add("hydrated"),N=(e,t,n)=>{if(t.k){const l=Object.entries(t.k),o=e.prototype;if(l.map((([e,[t]])=>{(31&t||2&n&&32&t)&&Object.defineProperty(o,e,{get(){return((e,t)=>R(this).C.get(t))(0,e)},set(t){((e,t,n)=>{const l=R(e),o=l.C.get(t),r=l.i,i=l.v;n=(e=>(null==e||s(e),e))(n),8&r&&void 0!==o||n===o||Number.isNaN(o)&&Number.isNaN(n)||(l.C.set(t,n),i&&2==(18&r)&&j(l,!1))})(this,e,t)},configurable:!0,enumerable:!0})})),1&n){const t=new Map;o.attributeChangedCallback=function(e,n,l){G.jmp((()=>{const n=t.get(e);if(this.hasOwnProperty(n))l=this[n],delete this[n];else if(o.hasOwnProperty(n)&&"number"==typeof this[n]&&this[n]==l)return;this[n]=(null!==l||"boolean"!=typeof this[n])&&l}))},e.observedAttributes=l.filter((([e,t])=>15&t[0])).map((([e,n])=>{const l=n[1]||e;return t.set(l,e),l}))}}return e},T=(e,t={})=>{var n;const l=[],o=t.exclude||[],s=z.customElements,i=B.head,c=i.querySelector("meta[charset]"),u=B.createElement("style"),a=[];let d,h=!0;Object.assign(G,t),G.L=new URL(t.resourcesUrl||"./",B.baseURI).href,e.map((e=>{e[1].map((t=>{const n={i:t[0],p:t[1],k:t[2],P:t[3]};n.k=t[2];const r=n.p,i=class extends HTMLElement{constructor(e){super(e),q(e=this,n),1&n.i&&e.attachShadow({mode:"open"})}connectedCallback(){d&&(clearTimeout(d),d=null),h?a.push(this):G.jmp((()=>(e=>{if(0==(1&G.i)){const t=R(e),n=t.S,l=()=>{};if(!(1&t.i)){t.i|=1;{let n=e;for(;n=n.parentNode||n.host;)if(n["s-p"]){S(t,t.m=n);break}}n.k&&Object.entries(n.k).map((([t,[n]])=>{if(31&n&&e.hasOwnProperty(t)){const n=e[t];delete e[t],e[t]=n}})),(async(e,t,n,l,o)=>{if(0==(32&t.i)){{if(t.i|=32,(o=V(n)).then){const e=()=>{};o=await o,e()}o.isProxied||(N(o,n,2),o.isProxied=!0);const e=()=>{};t.i|=8;try{new o(t)}catch(e){F(e)}t.i&=-9,e()}if(o.style){let e=o.style;const t=f(n);if(!_.has(t)){const l=()=>{};((e,t,n)=>{let l=_.get(e);J&&n?(l=l||new CSSStyleSheet,"string"==typeof l?l=t:l.replaceSync(t)):l=t,_.set(e,l)})(t,e,!!(1&n.i)),l()}}}const s=t.m,r=()=>j(t,!0);s&&s["s-rc"]?s["s-rc"].push(r):r()})(0,t,n)}l()}})(this)))}disconnectedCallback(){G.jmp((()=>{}))}componentOnReady(){return R(this).N}};n.T=e[0],o.includes(r)||s.get(r)||(l.push(r),s.define(r,N(i,n,1)))}))}));{u.innerHTML=l+"{visibility:hidden}.hydrated{visibility:inherit}",u.setAttribute("data-styles","");const e=null!==(n=G.j)&&void 0!==n?n:r(B);null!=e&&u.setAttribute("nonce",e),i.insertBefore(u,c?c.nextSibling:i.firstChild)}h=!1,a.length?a.map((e=>e.connectedCallback())):G.jmp((()=>d=setTimeout(x,30)))},W=e=>G.j=e,A=new WeakMap,R=e=>A.get(e),U=(e,t)=>A.set(t.v=e,t),q=(e,t)=>{const n={i:0,g:e,S:t,C:new Map};return n.N=new Promise((e=>n.M=e)),e["s-p"]=[],e["s-rc"]=[],A.set(e,n)},D=(e,t)=>t in e,F=(e,t)=>(0,console.error)(e,t),H=new Map,V=e=>{const t=e.p.replace(/-/g,"_"),n=e.T,l=H.get(n);return l?l[t]:import(`./${n}.entry.js`).then((e=>(H.set(n,e),e[t])),F)
2
- /*!__STENCIL_STATIC_IMPORT_SWITCH__*/},_=new Map,z="undefined"!=typeof window?window:{},B=z.document||{head:{}},G={i:0,L:"",jmp:e=>e(),raf:e=>requestAnimationFrame(e),ael:(e,t,n,l)=>e.addEventListener(t,n,l),rel:(e,t,n,l)=>e.removeEventListener(t,n,l),ce:(e,t)=>new CustomEvent(e,t)},I=e=>Promise.resolve(e),J=(()=>{try{return new CSSStyleSheet,"function"==typeof(new CSSStyleSheet).replaceSync}catch(e){}return!1})(),K=[],Q=[],X=(e,t)=>n=>{e.push(n),l||(l=!0,t&&4&G.i?ee(Z):G.raf(Z))},Y=e=>{for(let t=0;t<e.length;t++)try{e[t](performance.now())}catch(e){F(e)}e.length=0},Z=()=>{Y(K),Y(Q),(l=K.length>0)&&G.raf(Z)},ee=e=>I().then(e),te=X(Q,!0);export{T as b,i as h,I as p,U as r,W as s}