proto-daisy-db 0.0.204 → 0.0.205

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.
@@ -360,11 +360,19 @@ const setAccessor = (elm, memberName, oldValue, newValue, isSvg, flags) => {
360
360
  // except for the first character, we keep the event name case
361
361
  memberName = ln[2] + memberName.slice(3);
362
362
  }
363
- if (oldValue) {
364
- plt.rel(elm, memberName, oldValue, false);
365
- }
366
- if (newValue) {
367
- plt.ael(elm, memberName, newValue, false);
363
+ if (oldValue || newValue) {
364
+ // Need to account for "capture" events.
365
+ // If the event name ends with "Capture", we'll update the name to remove
366
+ // the "Capture" suffix and make sure the event listener is setup to handle the capture event.
367
+ const capture = memberName.endsWith(CAPTURE_EVENT_SUFFIX);
368
+ // Make sure we only replace the last instance of "Capture"
369
+ memberName = memberName.replace(CAPTURE_EVENT_REGEX, '');
370
+ if (oldValue) {
371
+ plt.rel(elm, memberName, oldValue, capture);
372
+ }
373
+ if (newValue) {
374
+ plt.ael(elm, memberName, newValue, capture);
375
+ }
368
376
  }
369
377
  }
370
378
  else {
@@ -406,6 +414,8 @@ const setAccessor = (elm, memberName, oldValue, newValue, isSvg, flags) => {
406
414
  };
407
415
  const parseClassListRegex = /\s/;
408
416
  const parseClassList = (value) => (!value ? [] : value.split(parseClassListRegex));
417
+ const CAPTURE_EVENT_SUFFIX = 'Capture';
418
+ const CAPTURE_EVENT_REGEX = new RegExp(CAPTURE_EVENT_SUFFIX + '$');
409
419
  const updateElement = (oldVnode, newVnode, isSvgMode, memberName) => {
410
420
  // if the element passed in is a shadow root, which is a document fragment
411
421
  // then we want to be adding attrs/props to the shadow root's "host" element
@@ -2,7 +2,7 @@
2
2
 
3
3
  Object.defineProperty(exports, '__esModule', { value: true });
4
4
 
5
- const index = require('./index-f28db6ca.js');
5
+ const index = require('./index-2deefb9f.js');
6
6
 
7
7
  const defineCustomElements = (win, options) => {
8
8
  if (typeof window === 'undefined') return undefined;
@@ -2,10 +2,10 @@
2
2
 
3
3
  Object.defineProperty(exports, '__esModule', { value: true });
4
4
 
5
- const index = require('./index-f28db6ca.js');
5
+ const index = require('./index-2deefb9f.js');
6
6
 
7
7
  /*
8
- Stencil Client Patch Browser v4.6.0 | MIT Licensed | https://stenciljs.com
8
+ Stencil Client Patch Browser v4.7.0 | 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-daisy-db.cjs.js', document.baseURI).href));
@@ -2,7 +2,7 @@
2
2
 
3
3
  Object.defineProperty(exports, '__esModule', { value: true });
4
4
 
5
- const index = require('./index-f28db6ca.js');
5
+ const index = require('./index-2deefb9f.js');
6
6
 
7
7
  const KEY = 'proto-daisy-db:app-data';
8
8
  const promisedParseJSON = (json) => {
@@ -8,7 +8,7 @@
8
8
  ],
9
9
  "compiler": {
10
10
  "name": "@stencil/core",
11
- "version": "4.6.0",
11
+ "version": "4.7.0",
12
12
  "typescriptVersion": "5.2.2"
13
13
  },
14
14
  "collections": [],
@@ -338,11 +338,19 @@ const setAccessor = (elm, memberName, oldValue, newValue, isSvg, flags) => {
338
338
  // except for the first character, we keep the event name case
339
339
  memberName = ln[2] + memberName.slice(3);
340
340
  }
341
- if (oldValue) {
342
- plt.rel(elm, memberName, oldValue, false);
343
- }
344
- if (newValue) {
345
- plt.ael(elm, memberName, newValue, false);
341
+ if (oldValue || newValue) {
342
+ // Need to account for "capture" events.
343
+ // If the event name ends with "Capture", we'll update the name to remove
344
+ // the "Capture" suffix and make sure the event listener is setup to handle the capture event.
345
+ const capture = memberName.endsWith(CAPTURE_EVENT_SUFFIX);
346
+ // Make sure we only replace the last instance of "Capture"
347
+ memberName = memberName.replace(CAPTURE_EVENT_REGEX, '');
348
+ if (oldValue) {
349
+ plt.rel(elm, memberName, oldValue, capture);
350
+ }
351
+ if (newValue) {
352
+ plt.ael(elm, memberName, newValue, capture);
353
+ }
346
354
  }
347
355
  }
348
356
  else {
@@ -384,6 +392,8 @@ const setAccessor = (elm, memberName, oldValue, newValue, isSvg, flags) => {
384
392
  };
385
393
  const parseClassListRegex = /\s/;
386
394
  const parseClassList = (value) => (!value ? [] : value.split(parseClassListRegex));
395
+ const CAPTURE_EVENT_SUFFIX = 'Capture';
396
+ const CAPTURE_EVENT_REGEX = new RegExp(CAPTURE_EVENT_SUFFIX + '$');
387
397
  const updateElement = (oldVnode, newVnode, isSvgMode, memberName) => {
388
398
  // if the element passed in is a shadow root, which is a document fragment
389
399
  // then we want to be adding attrs/props to the shadow root's "host" element
@@ -1,5 +1,5 @@
1
- import { b as bootstrapLazy } from './index-8bfa8f15.js';
2
- export { s as setNonce } from './index-8bfa8f15.js';
1
+ import { b as bootstrapLazy } from './index-b0e0c2f5.js';
2
+ export { s as setNonce } from './index-b0e0c2f5.js';
3
3
 
4
4
  const defineCustomElements = (win, options) => {
5
5
  if (typeof window === 'undefined') return undefined;
@@ -1,8 +1,8 @@
1
- import { p as promiseResolve, b as bootstrapLazy } from './index-8bfa8f15.js';
2
- export { s as setNonce } from './index-8bfa8f15.js';
1
+ import { p as promiseResolve, b as bootstrapLazy } from './index-b0e0c2f5.js';
2
+ export { s as setNonce } from './index-b0e0c2f5.js';
3
3
 
4
4
  /*
5
- Stencil Client Patch Browser v4.6.0 | MIT Licensed | https://stenciljs.com
5
+ Stencil Client Patch Browser v4.7.0 | MIT Licensed | https://stenciljs.com
6
6
  */
7
7
  const patchBrowser = () => {
8
8
  const importMeta = import.meta.url;
@@ -1,4 +1,4 @@
1
- import { r as registerInstance, h } from './index-8bfa8f15.js';
1
+ import { r as registerInstance, h } from './index-b0e0c2f5.js';
2
2
 
3
3
  const KEY = 'proto-daisy-db:app-data';
4
4
  const promisedParseJSON = (json) => {
@@ -1 +1 @@
1
- import{r as t,h as o}from"./p-0add9224.js";const s="proto-daisy-db:app-data",a=class{constructor(o){t(this,o),this.emitter=void 0}componentDidLoad(){if(this.emitter&&window[this.emitter]){const t=window[this.emitter];t.on("app-data:get",(()=>{var o;console.log("app-data:get"),(o=localStorage.getItem(s),new Promise(((t,s)=>{try{t(JSON.parse(o))}catch(t){s(t)}}))).then((o=>{t.emit("app-data:value",o)})).catch((t=>{console.log(t)}))})),t.on("app-data:store",(t=>{console.log("app-data:store",t),(t=>{const o=JSON.stringify(t);localStorage.setItem(s,o)})(t)})),t.emit("proto-daisy-db",{ready:!0})}}render(){return o("div",null)}};a.style="";const r=class{constructor(o){t(this,o),this.data=void 0}render(){const t=this.data?Object.keys(this.data):[];return o("div",{class:"flex flex-col"},t.map((t=>o("span",null,t))))}};r.style="";const e=class{constructor(o){t(this,o),this.data=void 0}render(){return o("div",{class:"flex"},o("span",null,this.data?this.data.stamp:""))}};e.style="";const i=class{constructor(o){t(this,o),this.emitter=void 0,this.data=void 0}componentDidLoad(){this.emitter&&window[this.emitter]&&window[this.emitter].on("app-data:value",(t=>{this.data=t}))}emitData(){if(this.emitter&&window[this.emitter]){const t=window[this.emitter],o={login:!0,stamp:Date.now(),theme:"dark",dealers:[]};this.data=void 0,t.emit("app-data:store",o)}}fetchData(){this.emitter&&window[this.emitter]&&window[this.emitter].emit("app-data:get",42)}render(){return o("div",{class:"flex flex-col font-sans"},o("div",{class:"flex flex-row content-center gap-2"},o("button",{class:"btn bg-clrs-navy text-clrs-white",onClick:()=>this.emitData()},"Save"),o("button",{class:"btn bg-clrs-blue text-clrs-white",onClick:()=>this.fetchData()},"Fetch")),o("proto-faux-type",{class:"mt-4",emitter:this.emitter}),o("proto-faux-stamp",{class:"mt-2 text-xs",data:this.data}),o("proto-faux-keys",{class:"mt-2",data:this.data}))}};i.style="*,::before,::after{--tw-border-spacing-x:0;--tw-border-spacing-y:0;--tw-translate-x:0;--tw-translate-y:0;--tw-rotate:0;--tw-skew-x:0;--tw-skew-y:0;--tw-scale-x:1;--tw-scale-y:1;--tw-scroll-snap-strictness:proximity;--tw-ring-offset-width:0px;--tw-ring-offset-color:#fff;--tw-ring-color:rgb(59 130 246 / 0.5);--tw-ring-offset-shadow:0 0 #0000;--tw-ring-shadow:0 0 #0000;--tw-shadow:0 0 #0000;--tw-shadow-colored:0 0 #0000;}::backdrop{--tw-border-spacing-x:0;--tw-border-spacing-y:0;--tw-translate-x:0;--tw-translate-y:0;--tw-rotate:0;--tw-skew-x:0;--tw-skew-y:0;--tw-scale-x:1;--tw-scale-y:1;--tw-scroll-snap-strictness:proximity;--tw-ring-offset-width:0px;--tw-ring-offset-color:#fff;--tw-ring-color:rgb(59 130 246 / 0.5);--tw-ring-offset-shadow:0 0 #0000;--tw-ring-shadow:0 0 #0000;--tw-shadow:0 0 #0000;--tw-shadow-colored:0 0 #0000;}.btn{border-radius:0.375rem;border-width:1px;border-style:solid;border-color:var(--clrs-aqua, #7fdbff);padding:0.5rem}.mt-2{margin-top:0.5rem}.mt-4{margin-top:1rem}.flex{display:flex}.flex-row{flex-direction:row}.flex-col{flex-direction:column}.content-center{align-content:center}.gap-2{gap:0.5rem}.bg-clrs-blue{background-color:var(--clrs-blue, #0074d9)}.bg-clrs-navy{background-color:var(--clrs-navy, #001f3f)}.font-sans{font-family:ui-sans-serif,\n system-ui,\n -apple-system,\n BlinkMacSystemFont,\n 'Segoe UI',\n Roboto,\n 'Helvetica Neue',\n Arial,\n 'Noto Sans',\n sans-serif,\n 'Apple Color Emoji',\n 'Segoe UI Emoji',\n 'Segoe UI Symbol',\n 'Noto Color Emoji'}.text-xs{font-size:0.75rem;line-height:1rem}.italic{font-style:italic}.text-clrs-white{color:var(--clrs-white, #ffffff)}.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),\n 0 1px 2px -1px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),\n var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow)}";const n=class{constructor(o){t(this,o),this.emitter=void 0,this.eventType=void 0}componentDidLoad(){this.emitter&&window[this.emitter]&&window[this.emitter].on("*",(t=>{this.eventType=t}))}render(){return o("div",null,o("span",{class:"text-xs italic"},this.eventType))}};n.style="proto-faux-type{}";export{a as proto_daisy_db,r as proto_faux_keys,e as proto_faux_stamp,i as proto_faux_trigger,n as proto_faux_type}
1
+ import{r as t,h as o}from"./p-de7e7f4d.js";const s="proto-daisy-db:app-data",a=class{constructor(o){t(this,o),this.emitter=void 0}componentDidLoad(){if(this.emitter&&window[this.emitter]){const t=window[this.emitter];t.on("app-data:get",(()=>{var o;console.log("app-data:get"),(o=localStorage.getItem(s),new Promise(((t,s)=>{try{t(JSON.parse(o))}catch(t){s(t)}}))).then((o=>{t.emit("app-data:value",o)})).catch((t=>{console.log(t)}))})),t.on("app-data:store",(t=>{console.log("app-data:store",t),(t=>{const o=JSON.stringify(t);localStorage.setItem(s,o)})(t)})),t.emit("proto-daisy-db",{ready:!0})}}render(){return o("div",null)}};a.style="";const r=class{constructor(o){t(this,o),this.data=void 0}render(){const t=this.data?Object.keys(this.data):[];return o("div",{class:"flex flex-col"},t.map((t=>o("span",null,t))))}};r.style="";const e=class{constructor(o){t(this,o),this.data=void 0}render(){return o("div",{class:"flex"},o("span",null,this.data?this.data.stamp:""))}};e.style="";const i=class{constructor(o){t(this,o),this.emitter=void 0,this.data=void 0}componentDidLoad(){this.emitter&&window[this.emitter]&&window[this.emitter].on("app-data:value",(t=>{this.data=t}))}emitData(){if(this.emitter&&window[this.emitter]){const t=window[this.emitter],o={login:!0,stamp:Date.now(),theme:"dark",dealers:[]};this.data=void 0,t.emit("app-data:store",o)}}fetchData(){this.emitter&&window[this.emitter]&&window[this.emitter].emit("app-data:get",42)}render(){return o("div",{class:"flex flex-col font-sans"},o("div",{class:"flex flex-row content-center gap-2"},o("button",{class:"btn bg-clrs-navy text-clrs-white",onClick:()=>this.emitData()},"Save"),o("button",{class:"btn bg-clrs-blue text-clrs-white",onClick:()=>this.fetchData()},"Fetch")),o("proto-faux-type",{class:"mt-4",emitter:this.emitter}),o("proto-faux-stamp",{class:"mt-2 text-xs",data:this.data}),o("proto-faux-keys",{class:"mt-2",data:this.data}))}};i.style="*,::before,::after{--tw-border-spacing-x:0;--tw-border-spacing-y:0;--tw-translate-x:0;--tw-translate-y:0;--tw-rotate:0;--tw-skew-x:0;--tw-skew-y:0;--tw-scale-x:1;--tw-scale-y:1;--tw-scroll-snap-strictness:proximity;--tw-ring-offset-width:0px;--tw-ring-offset-color:#fff;--tw-ring-color:rgb(59 130 246 / 0.5);--tw-ring-offset-shadow:0 0 #0000;--tw-ring-shadow:0 0 #0000;--tw-shadow:0 0 #0000;--tw-shadow-colored:0 0 #0000;}::backdrop{--tw-border-spacing-x:0;--tw-border-spacing-y:0;--tw-translate-x:0;--tw-translate-y:0;--tw-rotate:0;--tw-skew-x:0;--tw-skew-y:0;--tw-scale-x:1;--tw-scale-y:1;--tw-scroll-snap-strictness:proximity;--tw-ring-offset-width:0px;--tw-ring-offset-color:#fff;--tw-ring-color:rgb(59 130 246 / 0.5);--tw-ring-offset-shadow:0 0 #0000;--tw-ring-shadow:0 0 #0000;--tw-shadow:0 0 #0000;--tw-shadow-colored:0 0 #0000;}.btn{border-radius:0.375rem;border-width:1px;border-style:solid;border-color:var(--clrs-aqua, #7fdbff);padding:0.5rem}.mt-2{margin-top:0.5rem}.mt-4{margin-top:1rem}.flex{display:flex}.flex-row{flex-direction:row}.flex-col{flex-direction:column}.content-center{align-content:center}.gap-2{gap:0.5rem}.bg-clrs-blue{background-color:var(--clrs-blue, #0074d9)}.bg-clrs-navy{background-color:var(--clrs-navy, #001f3f)}.font-sans{font-family:ui-sans-serif,\n system-ui,\n -apple-system,\n BlinkMacSystemFont,\n 'Segoe UI',\n Roboto,\n 'Helvetica Neue',\n Arial,\n 'Noto Sans',\n sans-serif,\n 'Apple Color Emoji',\n 'Segoe UI Emoji',\n 'Segoe UI Symbol',\n 'Noto Color Emoji'}.text-xs{font-size:0.75rem;line-height:1rem}.italic{font-style:italic}.text-clrs-white{color:var(--clrs-white, #ffffff)}.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),\n 0 1px 2px -1px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),\n var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow)}";const n=class{constructor(o){t(this,o),this.emitter=void 0,this.eventType=void 0}componentDidLoad(){this.emitter&&window[this.emitter]&&window[this.emitter].on("*",(t=>{this.eventType=t}))}render(){return o("div",null,o("span",{class:"text-xs italic"},this.eventType))}};n.style="proto-faux-type{}";export{a as proto_daisy_db,r as proto_faux_keys,e as proto_faux_stamp,i as proto_faux_trigger,n as proto_faux_type}
@@ -0,0 +1,2 @@
1
+ let n,t,e=!1;const l={},o=n=>"object"==(n=typeof n)||"function"===n;function s(n){var t,e,l;return null!==(l=null===(e=null===(t=n.head)||void 0===t?void 0:t.querySelector('meta[name="csp-nonce"]'))||void 0===e?void 0:e.getAttribute("content"))&&void 0!==l?l:void 0}const i=(n,t,...e)=>{let l=null,s=!1,i=!1;const r=[],u=t=>{for(let e=0;e<t.length;e++)l=t[e],Array.isArray(l)?u(l):null!=l&&"boolean"!=typeof l&&((s="function"!=typeof n&&!o(l))&&(l+=""),s&&i?r[r.length-1].t+=l:r.push(s?c(null,l):l),i=s)};if(u(e),t){const n=t.className||t.class;n&&(t.class="object"!=typeof n?n:Object.keys(n).filter((t=>n[t])).join(" "))}const a=c(n,null);return a.l=t,r.length>0&&(a.o=r),a},c=(n,t)=>({i:0,u:n,t,p:null,o:null,l:null}),r={},u=new WeakMap,a=n=>"sc-"+n.$,f=(n,t,e,l,s,i)=>{if(e!==l){let c=F(n,t),r=t.toLowerCase();if("class"===t){const t=n.classList,o=y(e),s=y(l);t.remove(...o.filter((n=>n&&!s.includes(n)))),t.add(...s.filter((n=>n&&!o.includes(n))))}else if(c||"o"!==t[0]||"n"!==t[1]){const r=o(l);if((c||r&&null!==l)&&!s)try{if(n.tagName.includes("-"))n[t]=l;else{const o=null==l?"":l;"list"===t?c=!1:null!=e&&n[t]==o||(n[t]=o)}}catch(n){}null==l||!1===l?!1===l&&""!==n.getAttribute(t)||n.removeAttribute(t):(!c||4&i||s)&&!r&&n.setAttribute(t,l=!0===l?"":l)}else if(t="-"===t[2]?t.slice(3):F(B,r)?r.slice(2):r[2]+t.slice(3),e||l){const o=t.endsWith(p);t=t.replace($,""),e&&I.rel(n,t,e,o),l&&I.ael(n,t,l,o)}}},d=/\s/,y=n=>n?n.split(d):[],p="Capture",$=RegExp(p+"$"),h=(n,t,e,o)=>{const s=11===t.p.nodeType&&t.p.host?t.p.host:t.p,i=n&&n.l||l,c=t.l||l;for(o in i)o in c||f(s,o,i[o],void 0,e,t.i);for(o in c)f(s,o,i[o],c[o],e,t.i)},m=(t,e,l)=>{const o=e.o[l];let s,i,c=0;if(null!==o.t)s=o.p=G.createTextNode(o.t);else if(s=o.p=G.createElement(o.u),h(null,o,!1),null!=n&&s["s-si"]!==n&&s.classList.add(s["s-si"]=n),o.o)for(c=0;c<o.o.length;++c)i=m(t,o,c),i&&s.appendChild(i);return s},v=(n,e,l,o,s,i)=>{let c,r=n;for(r.shadowRoot&&r.tagName===t&&(r=r.shadowRoot);s<=i;++s)o[s]&&(c=m(null,l,s),c&&(o[s].p=c,r.insertBefore(c,e)))},b=(n,t,e)=>{for(let l=t;l<=e;++l){const t=n[l];if(t){const n=t.p;n&&n.remove()}}},w=(n,t)=>n.u===t.u,S=(n,t)=>{const e=t.p=n.p,l=n.o,o=t.o,s=t.t;null===s?(h(n,t,!1),null!==l&&null!==o?((n,t,e,l)=>{let o,s=0,i=0,c=t.length-1,r=t[0],u=t[c],a=l.length-1,f=l[0],d=l[a];for(;s<=c&&i<=a;)null==r?r=t[++s]:null==u?u=t[--c]:null==f?f=l[++i]:null==d?d=l[--a]:w(r,f)?(S(r,f),r=t[++s],f=l[++i]):w(u,d)?(S(u,d),u=t[--c],d=l[--a]):w(r,d)?(S(r,d),n.insertBefore(r.p,u.p.nextSibling),r=t[++s],d=l[--a]):w(u,f)?(S(u,f),n.insertBefore(u.p,r.p),u=t[--c],f=l[++i]):(o=m(t&&t[i],e,i),f=l[++i],o&&r.p.parentNode.insertBefore(o,r.p));s>c?v(n,null==l[a+1]?null:l[a+1].p,e,l,i,a):i>a&&b(t,s,c)})(e,l,t,o):null!==o?(null!==n.t&&(e.textContent=""),v(e,null,t,o,0,o.length-1)):null!==l&&b(l,0,l.length-1)):n.t!==s&&(e.data=s)},g=(n,t)=>{t&&!n.h&&t["s-p"]&&t["s-p"].push(new Promise((t=>n.h=t)))},j=(n,t)=>{if(n.i|=16,!(4&n.i))return g(n,n.m),en((()=>M(n,t)));n.i|=512},M=(n,t)=>{const e=n.v;return O(void 0,(()=>C(n,e,t)))},O=(n,t)=>k(n)?n.then(t):t(),k=n=>n instanceof Promise||n&&n.then&&"function"==typeof n.then,C=async(n,t,e)=>{var l;const o=n.$hostElement$,i=o["s-rc"];e&&(n=>{const t=n.S,e=n.$hostElement$,l=t.i,o=((n,t)=>{var e;const l=a(t),o=z.get(l);if(n=11===n.nodeType?n:G,o)if("string"==typeof o){let t,i=u.get(n=n.head||n);if(i||u.set(n,i=new Set),!i.has(l)){{t=G.createElement("style"),t.innerHTML=o;const l=null!==(e=I.j)&&void 0!==e?e:s(G);null!=l&&t.setAttribute("nonce",l),n.insertBefore(t,n.querySelector("link"))}i&&i.add(l)}}else n.adoptedStyleSheets.includes(o)||(n.adoptedStyleSheets=[...n.adoptedStyleSheets,o]);return l})(e.shadowRoot?e.shadowRoot:e.getRootNode(),t);10&l&&(e["s-sc"]=o,e.classList.add(o+"-h"))})(n);P(n,t,o,e),i&&(i.map((n=>n())),o["s-rc"]=void 0);{const t=null!==(l=o["s-p"])&&void 0!==l?l:[],e=()=>x(n);0===t.length?e():(Promise.all(t).then(e),n.i|=4,t.length=0)}},P=(e,l,o,s)=>{try{l=l.render(),e.i&=-17,e.i|=2,((e,l,o=!1)=>{const s=e.$hostElement$,u=e.M||c(null,null),a=(n=>n&&n.u===r)(l)?l:i(null,null,l);if(t=s.tagName,o&&a.l)for(const n of Object.keys(a.l))s.hasAttribute(n)&&!["key","ref","style","class"].includes(n)&&(a.l[n]=s[n]);a.u=null,a.i|=4,e.M=a,a.p=u.p=s.shadowRoot||s,n=s["s-sc"],S(u,a)})(e,l,s)}catch(n){H(n,e.$hostElement$)}return null},x=n=>{const t=n.$hostElement$,e=n.v,l=n.m;64&n.i||(n.i|=64,L(t),A(e,"componentDidLoad"),n.O(t),l||E()),n.h&&(n.h(),n.h=void 0),512&n.i&&tn((()=>j(n,!1))),n.i&=-517},E=()=>{L(G.documentElement),tn((()=>(n=>{const t=I.ce("appload",{detail:{namespace:"proto-daisy-db"}});return n.dispatchEvent(t),t})(B)))},A=(n,t,e)=>{if(n&&n[t])try{return n[t](e)}catch(n){H(n)}},L=n=>n.classList.add("hydrated"),N=(n,t,e)=>{var l;if(t.k){const s=Object.entries(t.k),i=n.prototype;if(s.map((([n,[l]])=>{(31&l||2&e&&32&l)&&Object.defineProperty(i,n,{get(){return((n,t)=>W(this).C.get(t))(0,n)},set(e){((n,t,e,l)=>{const s=W(n),i=s.C.get(t),c=s.i,r=s.v;e=((n,t)=>null==n||o(n)?n:1&t?n+"":n)(e,l.k[t][0]),8&c&&void 0!==i||e===i||Number.isNaN(i)&&Number.isNaN(e)||(s.C.set(t,e),r&&2==(18&c)&&j(s,!1))})(this,n,e,t)},configurable:!0,enumerable:!0})})),1&e){const e=new Map;i.attributeChangedCallback=function(n,l,o){I.jmp((()=>{const s=e.get(n);if(this.hasOwnProperty(s))o=this[s],delete this[s];else{if(i.hasOwnProperty(s)&&"number"==typeof this[s]&&this[s]==o)return;if(null==s){const e=W(this),s=null==e?void 0:e.i;if(!(8&s)&&128&s&&o!==l){const s=e.v,i=t.P[n];null==i||i.forEach((t=>{null!=s[t]&&s[t].call(s,o,l,n)}))}return}}this[s]=(null!==o||"boolean"!=typeof this[s])&&o}))},n.observedAttributes=Array.from(new Set([...Object.keys(null!==(l=t.P)&&void 0!==l?l:{}),...s.filter((([n,t])=>15&t[0])).map((([n,t])=>{const l=t[1]||n;return e.set(l,n),l}))]))}}return n},R=(n,t={})=>{var e;const l=[],o=t.exclude||[],i=B.customElements,c=G.head,r=c.querySelector("meta[charset]"),u=G.createElement("style"),f=[];let d,y=!0;Object.assign(I,t),I.A=new URL(t.resourcesUrl||"./",G.baseURI).href,n.map((n=>{n[1].map((t=>{const e={i:t[0],$:t[1],k:t[2],L:t[3]};e.k=t[2];const s=e.$,c=class extends HTMLElement{constructor(n){super(n),D(n=this,e),1&e.i&&n.attachShadow({mode:"open"})}connectedCallback(){d&&(clearTimeout(d),d=null),y?f.push(this):I.jmp((()=>(n=>{if(0==(1&I.i)){const t=W(n),e=t.S,l=()=>{};if(1&t.i)(null==t?void 0:t.v)||(null==t?void 0:t.N)&&t.N.then((()=>{}));else{t.i|=1;{let e=n;for(;e=e.parentNode||e.host;)if(e["s-p"]){g(t,t.m=e);break}}e.k&&Object.entries(e.k).map((([t,[e]])=>{if(31&e&&n.hasOwnProperty(t)){const e=n[t];delete n[t],n[t]=e}})),(async(n,t,e)=>{let l;if(0==(32&t.i)){t.i|=32;{if(l=_(e),l.then){const n=()=>{};l=await l,n()}l.isProxied||(N(l,e,2),l.isProxied=!0);const n=()=>{};t.i|=8;try{new l(t)}catch(n){H(n)}t.i&=-9,n()}if(l.style){let n=l.style;const t=a(e);if(!z.has(t)){const l=()=>{};((n,t,e)=>{let l=z.get(n);K&&e?(l=l||new CSSStyleSheet,"string"==typeof l?l=t:l.replaceSync(t)):l=t,z.set(n,l)})(t,n,!!(1&e.i)),l()}}}const o=t.m,s=()=>j(t,!0);o&&o["s-rc"]?o["s-rc"].push(s):s()})(0,t,e)}l()}})(this)))}disconnectedCallback(){I.jmp((()=>(async()=>{if(0==(1&I.i)){const n=W(this);(null==n?void 0:n.v)||(null==n?void 0:n.N)&&n.N.then((()=>{}))}})()))}componentOnReady(){return W(this).N}};e.R=n[0],o.includes(s)||i.get(s)||(l.push(s),i.define(s,N(c,e,1)))}))}));{u.innerHTML=l+"{visibility:hidden}.hydrated{visibility:inherit}",u.setAttribute("data-styles","");const n=null!==(e=I.j)&&void 0!==e?e:s(G);null!=n&&u.setAttribute("nonce",n),c.insertBefore(u,r?r.nextSibling:c.firstChild)}y=!1,f.length?f.map((n=>n.connectedCallback())):I.jmp((()=>d=setTimeout(E,30)))},T=n=>I.j=n,U=new WeakMap,W=n=>U.get(n),q=(n,t)=>U.set(t.v=n,t),D=(n,t)=>{const e={i:0,$hostElement$:n,S:t,C:new Map};return e.N=new Promise((n=>e.O=n)),n["s-p"]=[],n["s-rc"]=[],U.set(n,e)},F=(n,t)=>t in n,H=(n,t)=>(0,console.error)(n,t),V=new Map,_=n=>{const t=n.$.replace(/-/g,"_"),e=n.R,l=V.get(e);return l?l[t]:import(`./${e}.entry.js`).then((n=>(V.set(e,n),n[t])),H)
2
+ /*!__STENCIL_STATIC_IMPORT_SWITCH__*/},z=new Map,B="undefined"!=typeof window?window:{},G=B.document||{head:{}},I={i:0,A:"",jmp:n=>n(),raf:n=>requestAnimationFrame(n),ael:(n,t,e,l)=>n.addEventListener(t,e,l),rel:(n,t,e,l)=>n.removeEventListener(t,e,l),ce:(n,t)=>new CustomEvent(n,t)},J=n=>Promise.resolve(n),K=(()=>{try{return new CSSStyleSheet,"function"==typeof(new CSSStyleSheet).replaceSync}catch(n){}return!1})(),Q=[],X=[],Y=(n,t)=>l=>{n.push(l),e||(e=!0,t&&4&I.i?tn(nn):I.raf(nn))},Z=n=>{for(let t=0;t<n.length;t++)try{n[t](performance.now())}catch(n){H(n)}n.length=0},nn=()=>{Z(Q),Z(X),(e=Q.length>0)&&I.raf(nn)},tn=n=>J().then(n),en=Y(X,!0);export{R as b,i as h,J as p,q as r,T as s}
@@ -1 +1 @@
1
- import{p as t,b as e}from"./p-0add9224.js";export{s as setNonce}from"./p-0add9224.js";(()=>{const e=import.meta.url,a={};return""!==e&&(a.resourcesUrl=new URL(".",e).href),t(a)})().then((t=>e([["p-c81480c8",[[0,"proto-faux-trigger",{emitter:[1],data:[1040]}],[1,"proto-daisy-db",{emitter:[1]}],[0,"proto-faux-keys",{data:[16]}],[0,"proto-faux-stamp",{data:[16]}],[0,"proto-faux-type",{emitter:[1],eventType:[1025,"event-type"]}]]]],t)));
1
+ import{p as t,b as e}from"./p-de7e7f4d.js";export{s as setNonce}from"./p-de7e7f4d.js";(()=>{const e=import.meta.url,o={};return""!==e&&(o.resourcesUrl=new URL(".",e).href),t(o)})().then((t=>e([["p-79510073",[[0,"proto-faux-trigger",{emitter:[1],data:[1040]}],[1,"proto-daisy-db",{emitter:[1]}],[0,"proto-faux-keys",{data:[16]}],[0,"proto-faux-stamp",{data:[16]}],[0,"proto-faux-type",{emitter:[1],eventType:[1025,"event-type"]}]]]],t)));
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "proto-daisy-db",
3
- "version": "0.0.204",
3
+ "version": "0.0.205",
4
4
  "description": "Stencil Component Starter",
5
5
  "main": "dist/index.cjs.js",
6
6
  "module": "dist/index.js",
@@ -27,7 +27,7 @@
27
27
  "format": "prettier --write src"
28
28
  },
29
29
  "dependencies": {
30
- "@stencil/core": "4.6.0",
30
+ "@stencil/core": "4.7.0",
31
31
  "mitt": "3.0.1"
32
32
  },
33
33
  "devDependencies": {
@@ -37,7 +37,7 @@
37
37
  "postcss": "8.4.31",
38
38
  "prettier": "3.0.3",
39
39
  "prettier-plugin-tailwindcss": "0.5.6",
40
- "proto-tailwindcss-clrs": "0.0.281",
40
+ "proto-tailwindcss-clrs": "0.0.282",
41
41
  "tailwindcss": "3.3.5"
42
42
  },
43
43
  "license": "MIT"
@@ -1,2 +0,0 @@
1
- let n,t,e=!1;const l={},o=n=>"object"==(n=typeof n)||"function"===n;function s(n){var t,e,l;return null!==(l=null===(e=null===(t=n.head)||void 0===t?void 0:t.querySelector('meta[name="csp-nonce"]'))||void 0===e?void 0:e.getAttribute("content"))&&void 0!==l?l:void 0}const i=(n,t,...e)=>{let l=null,s=!1,i=!1;const r=[],u=t=>{for(let e=0;e<t.length;e++)l=t[e],Array.isArray(l)?u(l):null!=l&&"boolean"!=typeof l&&((s="function"!=typeof n&&!o(l))&&(l+=""),s&&i?r[r.length-1].t+=l:r.push(s?c(null,l):l),i=s)};if(u(e),t){const n=t.className||t.class;n&&(t.class="object"!=typeof n?n:Object.keys(n).filter((t=>n[t])).join(" "))}const a=c(n,null);return a.l=t,r.length>0&&(a.o=r),a},c=(n,t)=>({i:0,u:n,t,h:null,o:null,l:null}),r={},u=new WeakMap,a=n=>"sc-"+n.$,f=(n,t,e,l,s,i)=>{if(e!==l){let c=q(n,t),r=t.toLowerCase();if("class"===t){const t=n.classList,o=y(e),s=y(l);t.remove(...o.filter((n=>n&&!s.includes(n)))),t.add(...s.filter((n=>n&&!o.includes(n))))}else if(c||"o"!==t[0]||"n"!==t[1]){const r=o(l);if((c||r&&null!==l)&&!s)try{if(n.tagName.includes("-"))n[t]=l;else{const o=null==l?"":l;"list"===t?c=!1:null!=e&&n[t]==o||(n[t]=o)}}catch(n){}null==l||!1===l?!1===l&&""!==n.getAttribute(t)||n.removeAttribute(t):(!c||4&i||s)&&!r&&n.setAttribute(t,l=!0===l?"":l)}else t="-"===t[2]?t.slice(3):q(_,r)?r.slice(2):r[2]+t.slice(3),e&&B.rel(n,t,e,!1),l&&B.ael(n,t,l,!1)}},d=/\s/,y=n=>n?n.split(d):[],h=(n,t,e,o)=>{const s=11===t.h.nodeType&&t.h.host?t.h.host:t.h,i=n&&n.l||l,c=t.l||l;for(o in i)o in c||f(s,o,i[o],void 0,e,t.i);for(o in c)f(s,o,i[o],c[o],e,t.i)},$=(t,e,l)=>{const o=e.o[l];let s,i,c=0;if(null!==o.t)s=o.h=z.createTextNode(o.t);else if(s=o.h=z.createElement(o.u),h(null,o,!1),null!=n&&s["s-si"]!==n&&s.classList.add(s["s-si"]=n),o.o)for(c=0;c<o.o.length;++c)i=$(t,o,c),i&&s.appendChild(i);return s},p=(n,e,l,o,s,i)=>{let c,r=n;for(r.shadowRoot&&r.tagName===t&&(r=r.shadowRoot);s<=i;++s)o[s]&&(c=$(null,l,s),c&&(o[s].h=c,r.insertBefore(c,e)))},m=(n,t,e)=>{for(let l=t;l<=e;++l){const t=n[l];if(t){const n=t.h;n&&n.remove()}}},v=(n,t)=>n.u===t.u,b=(n,t)=>{const e=t.h=n.h,l=n.o,o=t.o,s=t.t;null===s?(h(n,t,!1),null!==l&&null!==o?((n,t,e,l)=>{let o,s=0,i=0,c=t.length-1,r=t[0],u=t[c],a=l.length-1,f=l[0],d=l[a];for(;s<=c&&i<=a;)null==r?r=t[++s]:null==u?u=t[--c]:null==f?f=l[++i]:null==d?d=l[--a]:v(r,f)?(b(r,f),r=t[++s],f=l[++i]):v(u,d)?(b(u,d),u=t[--c],d=l[--a]):v(r,d)?(b(r,d),n.insertBefore(r.h,u.h.nextSibling),r=t[++s],d=l[--a]):v(u,f)?(b(u,f),n.insertBefore(u.h,r.h),u=t[--c],f=l[++i]):(o=$(t&&t[i],e,i),f=l[++i],o&&r.h.parentNode.insertBefore(o,r.h));s>c?p(n,null==l[a+1]?null:l[a+1].h,e,l,i,a):i>a&&m(t,s,c)})(e,l,t,o):null!==o?(null!==n.t&&(e.textContent=""),p(e,null,t,o,0,o.length-1)):null!==l&&m(l,0,l.length-1)):n.t!==s&&(e.data=s)},w=(n,t)=>{t&&!n.p&&t["s-p"]&&t["s-p"].push(new Promise((t=>n.p=t)))},S=(n,t)=>{if(n.i|=16,!(4&n.i))return w(n,n.m),nn((()=>g(n,t)));n.i|=512},g=(n,t)=>{const e=n.v;return j(void 0,(()=>O(n,e,t)))},j=(n,t)=>M(n)?n.then(t):t(),M=n=>n instanceof Promise||n&&n.then&&"function"==typeof n.then,O=async(n,t,e)=>{var l;const o=n.$hostElement$,i=o["s-rc"];e&&(n=>{const t=n.S,e=n.$hostElement$,l=t.i,o=((n,t)=>{var e;const l=a(t),o=V.get(l);if(n=11===n.nodeType?n:z,o)if("string"==typeof o){let t,i=u.get(n=n.head||n);if(i||u.set(n,i=new Set),!i.has(l)){{t=z.createElement("style"),t.innerHTML=o;const l=null!==(e=B.j)&&void 0!==e?e:s(z);null!=l&&t.setAttribute("nonce",l),n.insertBefore(t,n.querySelector("link"))}i&&i.add(l)}}else n.adoptedStyleSheets.includes(o)||(n.adoptedStyleSheets=[...n.adoptedStyleSheets,o]);return l})(e.shadowRoot?e.shadowRoot:e.getRootNode(),t);10&l&&(e["s-sc"]=o,e.classList.add(o+"-h"))})(n);k(n,t,o,e),i&&(i.map((n=>n())),o["s-rc"]=void 0);{const t=null!==(l=o["s-p"])&&void 0!==l?l:[],e=()=>C(n);0===t.length?e():(Promise.all(t).then(e),n.i|=4,t.length=0)}},k=(e,l,o,s)=>{try{l=l.render(),e.i&=-17,e.i|=2,((e,l,o=!1)=>{const s=e.$hostElement$,u=e.M||c(null,null),a=(n=>n&&n.u===r)(l)?l:i(null,null,l);if(t=s.tagName,o&&a.l)for(const n of Object.keys(a.l))s.hasAttribute(n)&&!["key","ref","style","class"].includes(n)&&(a.l[n]=s[n]);a.u=null,a.i|=4,e.M=a,a.h=u.h=s.shadowRoot||s,n=s["s-sc"],b(u,a)})(e,l,s)}catch(n){D(n,e.$hostElement$)}return null},C=n=>{const t=n.$hostElement$,e=n.v,l=n.m;64&n.i||(n.i|=64,A(t),x(e,"componentDidLoad"),n.O(t),l||P()),n.p&&(n.p(),n.p=void 0),512&n.i&&Z((()=>S(n,!1))),n.i&=-517},P=()=>{A(z.documentElement),Z((()=>(n=>{const t=B.ce("appload",{detail:{namespace:"proto-daisy-db"}});return n.dispatchEvent(t),t})(_)))},x=(n,t,e)=>{if(n&&n[t])try{return n[t](e)}catch(n){D(n)}},A=n=>n.classList.add("hydrated"),E=(n,t,e)=>{var l;if(t.k){const s=Object.entries(t.k),i=n.prototype;if(s.map((([n,[l]])=>{(31&l||2&e&&32&l)&&Object.defineProperty(i,n,{get(){return((n,t)=>R(this).C.get(t))(0,n)},set(e){((n,t,e,l)=>{const s=R(n),i=s.C.get(t),c=s.i,r=s.v;e=((n,t)=>null==n||o(n)?n:1&t?n+"":n)(e,l.k[t][0]),8&c&&void 0!==i||e===i||Number.isNaN(i)&&Number.isNaN(e)||(s.C.set(t,e),r&&2==(18&c)&&S(s,!1))})(this,n,e,t)},configurable:!0,enumerable:!0})})),1&e){const e=new Map;i.attributeChangedCallback=function(n,l,o){B.jmp((()=>{const s=e.get(n);if(this.hasOwnProperty(s))o=this[s],delete this[s];else{if(i.hasOwnProperty(s)&&"number"==typeof this[s]&&this[s]==o)return;if(null==s){const e=R(this),s=null==e?void 0:e.i;if(!(8&s)&&128&s&&o!==l){const s=e.v,i=t.P[n];null==i||i.forEach((t=>{null!=s[t]&&s[t].call(s,o,l,n)}))}return}}this[s]=(null!==o||"boolean"!=typeof this[s])&&o}))},n.observedAttributes=Array.from(new Set([...Object.keys(null!==(l=t.P)&&void 0!==l?l:{}),...s.filter((([n,t])=>15&t[0])).map((([n,t])=>{const l=t[1]||n;return e.set(l,n),l}))]))}}return n},L=(n,t={})=>{var e;const l=[],o=t.exclude||[],i=_.customElements,c=z.head,r=c.querySelector("meta[charset]"),u=z.createElement("style"),f=[];let d,y=!0;Object.assign(B,t),B.A=new URL(t.resourcesUrl||"./",z.baseURI).href,n.map((n=>{n[1].map((t=>{const e={i:t[0],$:t[1],k:t[2],L:t[3]};e.k=t[2];const s=e.$,c=class extends HTMLElement{constructor(n){super(n),W(n=this,e),1&e.i&&n.attachShadow({mode:"open"})}connectedCallback(){d&&(clearTimeout(d),d=null),y?f.push(this):B.jmp((()=>(n=>{if(0==(1&B.i)){const t=R(n),e=t.S,l=()=>{};if(1&t.i)(null==t?void 0:t.v)||(null==t?void 0:t.N)&&t.N.then((()=>{}));else{t.i|=1;{let e=n;for(;e=e.parentNode||e.host;)if(e["s-p"]){w(t,t.m=e);break}}e.k&&Object.entries(e.k).map((([t,[e]])=>{if(31&e&&n.hasOwnProperty(t)){const e=n[t];delete n[t],n[t]=e}})),(async(n,t,e)=>{let l;if(0==(32&t.i)){t.i|=32;{if(l=H(e),l.then){const n=()=>{};l=await l,n()}l.isProxied||(E(l,e,2),l.isProxied=!0);const n=()=>{};t.i|=8;try{new l(t)}catch(n){D(n)}t.i&=-9,n()}if(l.style){let n=l.style;const t=a(e);if(!V.has(t)){const l=()=>{};((n,t,e)=>{let l=V.get(n);I&&e?(l=l||new CSSStyleSheet,"string"==typeof l?l=t:l.replaceSync(t)):l=t,V.set(n,l)})(t,n,!!(1&e.i)),l()}}}const o=t.m,s=()=>S(t,!0);o&&o["s-rc"]?o["s-rc"].push(s):s()})(0,t,e)}l()}})(this)))}disconnectedCallback(){B.jmp((()=>(async()=>{if(0==(1&B.i)){const n=R(this);(null==n?void 0:n.v)||(null==n?void 0:n.N)&&n.N.then((()=>{}))}})()))}componentOnReady(){return R(this).N}};e.T=n[0],o.includes(s)||i.get(s)||(l.push(s),i.define(s,E(c,e,1)))}))}));{u.innerHTML=l+"{visibility:hidden}.hydrated{visibility:inherit}",u.setAttribute("data-styles","");const n=null!==(e=B.j)&&void 0!==e?e:s(z);null!=n&&u.setAttribute("nonce",n),c.insertBefore(u,r?r.nextSibling:c.firstChild)}y=!1,f.length?f.map((n=>n.connectedCallback())):B.jmp((()=>d=setTimeout(P,30)))},N=n=>B.j=n,T=new WeakMap,R=n=>T.get(n),U=(n,t)=>T.set(t.v=n,t),W=(n,t)=>{const e={i:0,$hostElement$:n,S:t,C:new Map};return e.N=new Promise((n=>e.O=n)),n["s-p"]=[],n["s-rc"]=[],T.set(n,e)},q=(n,t)=>t in n,D=(n,t)=>(0,console.error)(n,t),F=new Map,H=n=>{const t=n.$.replace(/-/g,"_"),e=n.T,l=F.get(e);return l?l[t]:import(`./${e}.entry.js`).then((n=>(F.set(e,n),n[t])),D)
2
- /*!__STENCIL_STATIC_IMPORT_SWITCH__*/},V=new Map,_="undefined"!=typeof window?window:{},z=_.document||{head:{}},B={i:0,A:"",jmp:n=>n(),raf:n=>requestAnimationFrame(n),ael:(n,t,e,l)=>n.addEventListener(t,e,l),rel:(n,t,e,l)=>n.removeEventListener(t,e,l),ce:(n,t)=>new CustomEvent(n,t)},G=n=>Promise.resolve(n),I=(()=>{try{return new CSSStyleSheet,"function"==typeof(new CSSStyleSheet).replaceSync}catch(n){}return!1})(),J=[],K=[],Q=(n,t)=>l=>{n.push(l),e||(e=!0,t&&4&B.i?Z(Y):B.raf(Y))},X=n=>{for(let t=0;t<n.length;t++)try{n[t](performance.now())}catch(n){D(n)}n.length=0},Y=()=>{X(J),X(K),(e=J.length>0)&&B.raf(Y)},Z=n=>G().then(n),nn=Q(K,!0);export{L as b,i as h,G as p,U as r,N as s}