@re-code/ui-components 0.0.1 → 0.0.2

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 (35) hide show
  1. package/LICENSE +21 -21
  2. package/dist/cjs/index-BUHK0YWO.js +1347 -0
  3. package/dist/cjs/index.cjs.js +0 -1
  4. package/dist/cjs/loader.cjs.js +1 -1
  5. package/dist/cjs/ui-components.cjs.js +2 -29
  6. package/dist/cjs/ui-label.cjs.entry.js +2 -2
  7. package/dist/collection/components/ui-label/ui-label.js +1 -1
  8. package/dist/collection/components/ui-label/ui-label.stories.js +9 -9
  9. package/dist/components/index.js +1 -6
  10. package/dist/components/ui-label.js +1 -51
  11. package/dist/esm/index-DuNnHYm7.js +1339 -0
  12. package/dist/esm/index.js +1 -1
  13. package/dist/esm/loader.js +2 -2
  14. package/dist/esm/ui-components.js +3 -30
  15. package/dist/esm/ui-label.entry.js +2 -2
  16. package/dist/ui-components/index.esm.js +0 -1
  17. package/dist/ui-components/p-00537ea8.entry.js +1 -0
  18. package/dist/ui-components/p-DuNnHYm7.js +2 -0
  19. package/dist/ui-components/ui-components.css +1 -28
  20. package/dist/ui-components/ui-components.esm.js +1 -47
  21. package/package.json +65 -65
  22. package/dist/cjs/index-CwGon_W1.js +0 -4501
  23. package/dist/components/index2.js +0 -4488
  24. package/dist/esm/index-CDwILsz8.js +0 -4488
  25. package/dist/types/ui-components/.stencil/ui-label.d.ts +0 -15
  26. package/dist/types/ui-components/.stencil/ui-label.stories.d.ts +0 -10
  27. package/dist/ui-components/index-CDwILsz8.js +0 -4488
  28. package/dist/ui-components/index-Ds6GXFU9.js +0 -4491
  29. package/dist/ui-components/index-Ds6GXFU9.js.map +0 -1
  30. package/dist/ui-components/index-NEMW1Jjc.js +0 -4491
  31. package/dist/ui-components/index-NEMW1Jjc.js.map +0 -1
  32. package/dist/ui-components/index.esm.js.map +0 -1
  33. package/dist/ui-components/ui-components.esm.js.map +0 -1
  34. package/dist/ui-components/ui-label.entry.js +0 -24
  35. package/dist/ui-components/ui-label.entry.js.map +0 -1
package/dist/esm/index.js CHANGED
@@ -1 +1 @@
1
- //! Autogenerated index
1
+
@@ -1,5 +1,5 @@
1
- import { g as globalScripts, b as bootstrapLazy } from './index-CDwILsz8.js';
2
- export { s as setNonce } from './index-CDwILsz8.js';
1
+ import { g as globalScripts, b as bootstrapLazy } from './index-DuNnHYm7.js';
2
+ export { s as setNonce } from './index-DuNnHYm7.js';
3
3
 
4
4
  const defineCustomElements = async (win, options) => {
5
5
  if (typeof window === 'undefined') return undefined;
@@ -1,45 +1,18 @@
1
- import { B as BUILD, c as consoleDevInfo, H, w as win, N as NAMESPACE, p as promiseResolve, g as globalScripts, b as bootstrapLazy } from './index-CDwILsz8.js';
2
- export { s as setNonce } from './index-CDwILsz8.js';
1
+ import { p as promiseResolve, g as globalScripts, b as bootstrapLazy } from './index-DuNnHYm7.js';
2
+ export { s as setNonce } from './index-DuNnHYm7.js';
3
3
 
4
4
  /*
5
5
  Stencil Client Patch Browser v4.41.2 | MIT Licensed | https://stenciljs.com
6
6
  */
7
7
 
8
8
  var patchBrowser = () => {
9
- if (BUILD.isDev && !BUILD.isTesting) {
10
- consoleDevInfo("Running in development mode.");
11
- }
12
- if (BUILD.cloneNodeFix) {
13
- patchCloneNodeFix(H.prototype);
14
- }
15
- const scriptElm = BUILD.scriptDataOpts ? win.document && Array.from(win.document.querySelectorAll("script")).find(
16
- (s) => new RegExp(`/${NAMESPACE}(\\.esm)?\\.js($|\\?|#)`).test(s.src) || s.getAttribute("data-stencil-namespace") === NAMESPACE
17
- ) : null;
18
9
  const importMeta = import.meta.url;
19
- const opts = BUILD.scriptDataOpts ? (scriptElm || {})["data-opts"] || {} : {};
10
+ const opts = {};
20
11
  if (importMeta !== "") {
21
12
  opts.resourcesUrl = new URL(".", importMeta).href;
22
13
  }
23
14
  return promiseResolve(opts);
24
15
  };
25
- var patchCloneNodeFix = (HTMLElementPrototype) => {
26
- const nativeCloneNodeFn = HTMLElementPrototype.cloneNode;
27
- HTMLElementPrototype.cloneNode = function(deep) {
28
- if (this.nodeName === "TEMPLATE") {
29
- return nativeCloneNodeFn.call(this, deep);
30
- }
31
- const clonedNode = nativeCloneNodeFn.call(this, false);
32
- const srcChildNodes = this.childNodes;
33
- if (deep) {
34
- for (let i = 0; i < srcChildNodes.length; i++) {
35
- if (srcChildNodes[i].nodeType !== 2) {
36
- clonedNode.appendChild(srcChildNodes[i].cloneNode(true));
37
- }
38
- }
39
- }
40
- return clonedNode;
41
- };
42
- };
43
16
 
44
17
  patchBrowser().then(async (options) => {
45
18
  await globalScripts();
@@ -1,4 +1,4 @@
1
- import { r as registerInstance, h, a as Host } from './index-CDwILsz8.js';
1
+ import { r as registerInstance, h, H as Host } from './index-DuNnHYm7.js';
2
2
 
3
3
  const uiLabelCss = () => `:host{display:inline-block;font-family:"Roboto", system-ui, -apple-system, sans-serif;color:#1D1B20;transition:all 0.2s ease-in-out}:host(.ui-label--display-large){font-size:57px;line-height:64px;font-weight:400;letter-spacing:-0.25px}:host(.ui-label--display-medium){font-size:45px;line-height:52px;font-weight:400;letter-spacing:0px}:host(.ui-label--display-small){font-size:36px;line-height:44px;font-weight:400;letter-spacing:0px}:host(.ui-label--headline-large){font-size:32px;line-height:40px;font-weight:400;letter-spacing:0px}:host(.ui-label--headline-medium){font-size:28px;line-height:36px;font-weight:400;letter-spacing:0px}:host(.ui-label--headline-small){font-size:24px;line-height:32px;font-weight:400;letter-spacing:0px}:host(.ui-label--title-large){font-size:22px;line-height:28px;font-weight:400;letter-spacing:0px}:host(.ui-label--title-medium){font-size:16px;line-height:24px;font-weight:500;letter-spacing:0.15px}:host(.ui-label--title-small){font-size:14px;line-height:20px;font-weight:500;letter-spacing:0.1px}:host(.ui-label--body-large){font-size:16px;line-height:24px;font-weight:400;letter-spacing:0.5px}:host(.ui-label--body-medium){font-size:14px;line-height:20px;font-weight:400;letter-spacing:0.25px}:host(.ui-label--body-small){font-size:12px;line-height:16px;font-weight:400;letter-spacing:0.4px}:host(.ui-label--label-large){font-size:14px;line-height:20px;font-weight:500;letter-spacing:0.1px}:host(.ui-label--label-medium){font-size:12px;line-height:16px;font-weight:500;letter-spacing:0.5px}:host(.ui-label--label-small){font-size:11px;line-height:16px;font-weight:500;letter-spacing:0.5px}:host(.ui-label--color-primary){color:#6750A4}:host(.ui-label--color-on-primary){color:#FFFFFF}:host(.ui-label--color-primary-container){color:#EADDFF}:host(.ui-label--color-on-primary-container){color:#21005D}:host(.ui-label--color-secondary){color:#625B71}:host(.ui-label--color-on-secondary){color:#FFFFFF}:host(.ui-label--color-secondary-container){color:#E8DEF8}:host(.ui-label--color-on-secondary-container){color:#1D192B}:host(.ui-label--color-tertiary){color:#7D5260}:host(.ui-label--color-on-tertiary){color:#FFFFFF}:host(.ui-label--color-tertiary-container){color:#FFD8E4}:host(.ui-label--color-on-tertiary-container){color:#31111D}:host(.ui-label--color-error){color:#B3261E}:host(.ui-label--color-on-error){color:#FFFFFF}:host(.ui-label--color-surface){color:#FEF7FF}:host(.ui-label--color-on-surface){color:#1D1B20}:host(.ui-label--color-on-surface-variant){color:#49454F}:host(.ui-label--color-outline){color:#79747E}:host(.ui-label--weight-normal){font-weight:400}:host(.ui-label--weight-medium){font-weight:500}:host(.ui-label--weight-bold){font-weight:700}:host(.ui-label--italic){font-style:italic !important}`;
4
4
 
@@ -16,7 +16,7 @@ const UiLabel = class {
16
16
  [`ui-label--weight-${this.weight}`]: !!this.weight,
17
17
  'ui-label--italic': this.italic
18
18
  };
19
- return (h(Host, { key: 'aa90dba620bb302ef1f8d2d9452eab3cb1c993db', class: classMap }, h("span", { key: '09e6a2daad525a3946a4d926799e866970a70fc3' }, this.label, " ", h("slot", { key: '972f325c8826a2bc3f7d1a36bf5adb4335285904' }))));
19
+ return (h(Host, { key: 'f27dfd1b6693b5728b941dd191d2314c68b2ac82', class: classMap }, h("span", { key: 'cbf3de59fc8bc1a2c47c5de5570990deb595d06b' }, this.label, " ", h("slot", { key: '6bf134e3df5360475a1c49891c923556114288d7' }))));
20
20
  }
21
21
  };
22
22
  UiLabel.style = uiLabelCss();
@@ -1 +0,0 @@
1
- //! Autogenerated index
@@ -0,0 +1 @@
1
+ import{r as e,h as l,H as o}from"./p-DuNnHYm7.js";const t=class{constructor(l){e(this,l),this.variant="body-medium",this.color="on-surface",this.italic=!1}render(){return l(o,{key:"f27dfd1b6693b5728b941dd191d2314c68b2ac82",class:{[`ui-label--${this.variant}`]:!0,[`ui-label--color-${this.color}`]:!0,[`ui-label--weight-${this.weight}`]:!!this.weight,"ui-label--italic":this.italic}},l("span",{key:"cbf3de59fc8bc1a2c47c5de5570990deb595d06b"},this.label," ",l("slot",{key:"6bf134e3df5360475a1c49891c923556114288d7"})))}};t.style=':host{display:inline-block;font-family:"Roboto", system-ui, -apple-system, sans-serif;color:#1D1B20;transition:all 0.2s ease-in-out}:host(.ui-label--display-large){font-size:57px;line-height:64px;font-weight:400;letter-spacing:-0.25px}:host(.ui-label--display-medium){font-size:45px;line-height:52px;font-weight:400;letter-spacing:0px}:host(.ui-label--display-small){font-size:36px;line-height:44px;font-weight:400;letter-spacing:0px}:host(.ui-label--headline-large){font-size:32px;line-height:40px;font-weight:400;letter-spacing:0px}:host(.ui-label--headline-medium){font-size:28px;line-height:36px;font-weight:400;letter-spacing:0px}:host(.ui-label--headline-small){font-size:24px;line-height:32px;font-weight:400;letter-spacing:0px}:host(.ui-label--title-large){font-size:22px;line-height:28px;font-weight:400;letter-spacing:0px}:host(.ui-label--title-medium){font-size:16px;line-height:24px;font-weight:500;letter-spacing:0.15px}:host(.ui-label--title-small){font-size:14px;line-height:20px;font-weight:500;letter-spacing:0.1px}:host(.ui-label--body-large){font-size:16px;line-height:24px;font-weight:400;letter-spacing:0.5px}:host(.ui-label--body-medium){font-size:14px;line-height:20px;font-weight:400;letter-spacing:0.25px}:host(.ui-label--body-small){font-size:12px;line-height:16px;font-weight:400;letter-spacing:0.4px}:host(.ui-label--label-large){font-size:14px;line-height:20px;font-weight:500;letter-spacing:0.1px}:host(.ui-label--label-medium){font-size:12px;line-height:16px;font-weight:500;letter-spacing:0.5px}:host(.ui-label--label-small){font-size:11px;line-height:16px;font-weight:500;letter-spacing:0.5px}:host(.ui-label--color-primary){color:#6750A4}:host(.ui-label--color-on-primary){color:#FFFFFF}:host(.ui-label--color-primary-container){color:#EADDFF}:host(.ui-label--color-on-primary-container){color:#21005D}:host(.ui-label--color-secondary){color:#625B71}:host(.ui-label--color-on-secondary){color:#FFFFFF}:host(.ui-label--color-secondary-container){color:#E8DEF8}:host(.ui-label--color-on-secondary-container){color:#1D192B}:host(.ui-label--color-tertiary){color:#7D5260}:host(.ui-label--color-on-tertiary){color:#FFFFFF}:host(.ui-label--color-tertiary-container){color:#FFD8E4}:host(.ui-label--color-on-tertiary-container){color:#31111D}:host(.ui-label--color-error){color:#B3261E}:host(.ui-label--color-on-error){color:#FFFFFF}:host(.ui-label--color-surface){color:#FEF7FF}:host(.ui-label--color-on-surface){color:#1D1B20}:host(.ui-label--color-on-surface-variant){color:#49454F}:host(.ui-label--color-outline){color:#79747E}:host(.ui-label--weight-normal){font-weight:400}:host(.ui-label--weight-medium){font-weight:500}:host(.ui-label--weight-bold){font-weight:700}:host(.ui-label--italic){font-style:italic !important}';export{t as ui_label}
@@ -0,0 +1,2 @@
1
+ const t=()=>{},e=':root{--color-primary:#6750A4;--color-on-primary:#FFFFFF;--color-primary-container:#EADDFF;--color-on-primary-container:#21005D;--color-secondary:#625B71;--color-on-secondary:#FFFFFF;--color-secondary-container:#E8DEF8;--color-on-secondary-container:#1D192B;--color-tertiary:#7D5260;--color-on-tertiary:#FFFFFF;--color-tertiary-container:#FFD8E4;--color-on-tertiary-container:#31111D;--color-error:#B3261E;--color-on-error:#FFFFFF;--color-surface:#FEF7FF;--color-on-surface:#1D1B20;--color-on-surface-variant:#49454F;--color-outline:#79747E}html,body{margin:0;padding:0;font-family:"Roboto", system-ui, -apple-system, sans-serif;background-color:#FEF7FF;color:#1D1B20}';var n,o=(t,e)=>{var n;Object.entries(null!=(n=e.o.t)?n:{}).map((([n,[o]])=>{if(31&o||32&o){const o=t[n],l=function(t,e){for(;t;){const n=Object.getOwnPropertyDescriptor(t,e);if(null==n?void 0:n.get)return n;t=Object.getPrototypeOf(t)}}(Object.getPrototypeOf(t),n)||Object.getOwnPropertyDescriptor(t,n);l&&Object.defineProperty(t,n,{get(){return l.get.call(this)},set(t){l.set.call(this,t)},configurable:!0,enumerable:!0}),t[n]=e.l.has(n)?e.l.get(n):o}}))},l=t=>{if(t.__stencil__getHostRef)return t.__stencil__getHostRef()},r=(t,e)=>{e&&(t.__stencil__getHostRef=()=>e,e.i=t,512&e.o.u&&o(t,e))},i=(t,e)=>(0,console.error)(t,e),s=new Map,c=new Map,a="undefined"!=typeof window?window:{},u={u:0,p:"",jmp:t=>t(),raf:t=>requestAnimationFrame(t),ael:(t,e,n,o)=>t.addEventListener(e,n,o),rel:(t,e,n,o)=>t.removeEventListener(e,n,o),ce:(t,e)=>new CustomEvent(t,e)},f=t=>Promise.resolve(t),d=(()=>{try{return!!a.document.adoptedStyleSheets&&(new CSSStyleSheet,"function"==typeof(new CSSStyleSheet).replaceSync)}catch(t){}return!1})(),p=!!d&&(()=>!!a.document&&Object.getOwnPropertyDescriptor(a.document.adoptedStyleSheets,"length").writable)(),h=!1,m=[],y=[],v=(t,e)=>n=>{t.push(n),h||(h=!0,e&&4&u.u?F($):u.raf($))},b=t=>{for(let e=0;e<t.length;e++)try{t[e](performance.now())}catch(t){i(t)}t.length=0},$=()=>{b(m),b(y),(h=m.length>0)&&u.raf($)},F=t=>f().then(t),w=v(y,!0);function g(){var t;const o=this.attachShadow({mode:"open"});if(void 0===n&&(n=null!=(t=function(t){if(!d)return;const e=new CSSStyleSheet;return e.replaceSync(t),e}(e))?t:null),n)p?o.adoptedStyleSheets.push(n):o.adoptedStyleSheets=[...o.adoptedStyleSheets,n];else if(!d){const t=document.createElement("style");t.innerHTML=e,o.prepend(t)}}function j(t){var e,n,o;return null!=(o=null==(n=null==(e=t.head)?void 0:e.querySelector('meta[name="csp-nonce"]'))?void 0:n.getAttribute("content"))?o:void 0}var S,O=new WeakMap,E=t=>"sc-"+t.h,D=t=>"object"==(t=typeof t)||"function"===t,k=(t,e,...n)=>{let o=null,l=null,r=!1,i=!1;const s=[],c=e=>{for(let n=0;n<e.length;n++)o=e[n],Array.isArray(o)?c(o):null!=o&&"boolean"!=typeof o&&((r="function"!=typeof t&&!D(o))&&(o+=""),r&&i?s[s.length-1].m+=o:s.push(r?C(null,o):o),i=r)};if(c(n),e){e.key&&(l=e.key);{const t=e.className||e.class;t&&(e.class="object"!=typeof t?t:Object.keys(t).filter((e=>t[e])).join(" "))}}const a=C(t,null);return a.v=e,s.length>0&&(a.$=s),a.F=l,a},C=(t,e)=>({u:0,j:t,m:null!=e?e:null,S:null,$:null,v:null,F:null}),M={},A=(t,e)=>null==t||D(t)?t:4&e?"false"!==t&&(""===t||!!t):1&e?t+"":t,R=(t,e,n,o)=>{if(n!==o&&(e.toLowerCase(),"class"===e)){const e=t.classList,l=P(n);let r=P(o);e.remove(...l.filter((t=>t&&!r.includes(t)))),e.add(...r.filter((t=>t&&!l.includes(t))))}},x=/\s/,P=t=>("object"==typeof t&&t&&"baseVal"in t&&(t=t.baseVal),t&&"string"==typeof t?t.split(x):[]),B=(t,e)=>{const n=11===e.S.nodeType&&e.S.host?e.S.host:e.S,o=t&&t.v||{},l=e.v||{};for(const t of L(Object.keys(o)))t in l||R(n,t,o[t],void 0);for(const t of L(Object.keys(l)))R(n,t,o[t],l[t])};function L(t){return t.includes("ref")?[...t.filter((t=>"ref"!==t)),"ref"]:t}var N=!1,U=(t,e,n)=>{const o=e.$[n];let l,r,i=0;if(null!=o.m)l=o.S=a.document.createTextNode(o.m);else{if(!a.document)throw Error("You are trying to render a Stencil component in an environment that doesn't support the DOM.");if(l=o.S=a.document.createElement(o.j),B(null,o),o.$){const e="template"===o.j?l.content:l;for(i=0;i<o.$.length;++i)r=U(t,o,i),r&&e.appendChild(r)}}return l["s-hn"]=S,l},H=(t,e,n,o,l,r)=>{let i,s=t;for(s.shadowRoot&&s.tagName===S&&(s=s.shadowRoot),"template"===n.j&&(s=s.content);l<=r;++l)o[l]&&(i=U(null,n,l),i&&(o[l].S=i,q(s,i,e)))},T=(t,e,n)=>{for(let o=e;o<=n;++o){const e=t[o];if(e){const t=e.S;t&&t.remove()}}},W=(t,e,n=!1)=>t.j===e.j&&(n?(n&&!t.F&&e.F&&(t.F=e.F),!0):t.F===e.F),V=(t,e,n=!1)=>{const o=e.S=t.S,l=t.$,r=e.$,i=e.m;null==i?("slot"!==e.j||N||t.O!==e.O&&(e.S["s-sn"]=e.O||"",(t=>{u.u|=1;const e=t.closest(S.toLowerCase());if(null!=e){const n=Array.from(e.__childNodes||e.childNodes).find((t=>t["s-cr"])),o=Array.from(t.__childNodes||t.childNodes);for(const t of n?o.reverse():o)null!=t["s-sh"]&&(q(e,t,null!=n?n:null),t["s-sh"]=void 0)}u.u&=-2})(e.S.parentElement)),B(t,e),null!==l&&null!==r?((t,e,n,o,l=!1)=>{let r,i,s=0,c=0,a=0,u=0,f=e.length-1,d=e[0],p=e[f],h=o.length-1,m=o[0],y=o[h];const v="template"===n.j?t.content:t;for(;s<=f&&c<=h;)if(null==d)d=e[++s];else if(null==p)p=e[--f];else if(null==m)m=o[++c];else if(null==y)y=o[--h];else if(W(d,m,l))V(d,m,l),d=e[++s],m=o[++c];else if(W(p,y,l))V(p,y,l),p=e[--f],y=o[--h];else if(W(d,y,l))V(d,y,l),q(v,d.S,p.S.nextSibling),d=e[++s],y=o[--h];else if(W(p,m,l))V(p,m,l),q(v,p.S,d.S),p=e[--f],m=o[++c];else{for(a=-1,u=s;u<=f;++u)if(e[u]&&null!==e[u].F&&e[u].F===m.F){a=u;break}a>=0?(i=e[a],i.j!==m.j?r=U(e&&e[c],n,a):(V(i,m,l),e[a]=void 0,r=i.S),m=o[++c]):(r=U(e&&e[c],n,c),m=o[++c]),r&&q(d.S.parentNode,r,d.S)}s>f?H(t,null==o[h+1]?null:o[h+1].S,n,o,c,h):c>h&&T(e,s,f)})(o,l,e,r,n):null!==r?(null!==t.m&&(o.textContent=""),H(o,null,e,r,0,r.length-1)):!n&&null!==l&&T(l,0,l.length-1)):t.m!==i&&(o.data=i)},q=(t,e,n)=>t.__insertBefore?t.__insertBefore(e,n):null==t?void 0:t.insertBefore(e,n),z=(t,e)=>{if(e&&!t.D&&e["s-p"]){const n=e["s-p"].push(new Promise((o=>t.D=()=>{e["s-p"].splice(n-1,1),o()})))}},G=(t,e)=>{if(t.u|=16,4&t.u)return void(t.u|=512);z(t,t.k);const n=()=>Y(t,e);if(!e)return w(n);queueMicrotask((()=>{n()}))},Y=(t,e)=>{const n=t.$hostElement$,o=t.i;if(!o)throw Error(`Can't render component <${n.tagName.toLowerCase()} /> with invalid Stencil runtime! Make sure this imported component is compiled with a \`externalRuntime: true\` flag. For more information, please refer to https://stenciljs.com/docs/custom-elements#externalruntime`);let l;return e?(t.C.length&&t.C.forEach((t=>t(n))),l=Z(o,"componentWillLoad",void 0,n)):l=Z(o,"componentWillUpdate",void 0,n),l=_(l,(()=>Z(o,"componentWillRender",void 0,n))),_(l,(()=>J(t,o,e)))},_=(t,e)=>I(t)?t.then(e).catch((t=>{console.error(t),e()})):e(),I=t=>t instanceof Promise||t&&t.then&&"function"==typeof t.then,J=async(t,e,n)=>{var o;const l=t.$hostElement$,r=l["s-rc"];n&&(t=>{const e=t.o,n=t.$hostElement$,o=e.u,l=((t,e)=>{var n,o,l;const r=E(e),i=c.get(r);if(!a.document)return r;if(t=11===t.nodeType?t:a.document,i)if("string"==typeof i){let l,s=O.get(t=t.head||t);if(s||O.set(t,s=new Set),!s.has(r)){l=a.document.createElement("style"),l.textContent=i;const c=null!=(n=u.M)?n:j(a.document);if(null!=c&&l.setAttribute("nonce",c),!(1&e.u))if("HEAD"===t.nodeName){const e=t.querySelectorAll("link[rel=preconnect]"),n=e.length>0?e[e.length-1].nextSibling:t.querySelector("style");t.insertBefore(l,(null==n?void 0:n.parentNode)===t?n:null)}else if("host"in t)if(d){const e=new(null!=(o=t.defaultView)?o:t.ownerDocument.defaultView).CSSStyleSheet;e.replaceSync(i),p?t.adoptedStyleSheets.unshift(e):t.adoptedStyleSheets=[e,...t.adoptedStyleSheets]}else{const e=t.querySelector("style");e?e.textContent=i+e.textContent:t.prepend(l)}else t.append(l);1&e.u&&t.insertBefore(l,null),4&e.u&&(l.textContent+="slot-fb{display:contents}slot-fb[hidden]{display:none}"),s&&s.add(r)}}else{let e=O.get(t);if(e||O.set(t,e=new Set),!e.has(r)){const n=null!=(l=t.defaultView)?l:t.ownerDocument.defaultView;let o;if(i.constructor===n.CSSStyleSheet)o=i;else{o=new n.CSSStyleSheet;for(let t=0;t<i.cssRules.length;t++)o.insertRule(i.cssRules[t].cssText,t)}p?t.adoptedStyleSheets.push(o):t.adoptedStyleSheets=[...t.adoptedStyleSheets,o],e.add(r)}}return r})(n.shadowRoot?n.shadowRoot:n.getRootNode(),e);10&o&&(n["s-sc"]=l,n.classList.add(l+"-h"))})(t);K(t,e,l,n),r&&(r.map((t=>t())),l["s-rc"]=void 0);{const e=null!=(o=l["s-p"])?o:[],n=()=>Q(t);0===e.length?n():(Promise.all(e).then(n),t.u|=4,e.length=0)}},K=(t,e,n,o)=>{try{e=e.render(),t.u&=-17,t.u|=2,((t,e,n=!1)=>{const o=t.$hostElement$,l=t.o,r=t.A||C(null,null),i=(t=>t&&t.j===M)(e)?e:k(null,null,e);if(S=o.tagName,n&&i.v)for(const t of Object.keys(i.v))o.hasAttribute(t)&&!["key","ref","style","class"].includes(t)&&(i.v[t]=o[t]);i.j=null,i.u|=4,t.A=i,i.S=r.S=o.shadowRoot||o,N=!(!(1&l.u)||128&l.u),V(r,i,n)})(t,e,o)}catch(e){i(e,t.$hostElement$)}return null},Q=t=>{const e=t.$hostElement$,n=t.i,o=t.k;Z(n,"componentDidRender",void 0,e),64&t.u?Z(n,"componentDidUpdate",void 0,e):(t.u|=64,tt(e),Z(n,"componentDidLoad",void 0,e),t.R(e),o||X()),t.D&&(t.D(),t.D=void 0),512&t.u&&F((()=>G(t,!1))),t.u&=-517},X=()=>{F((()=>(t=>{const e=u.ce("appload",{detail:{namespace:"ui-components"}});return t.dispatchEvent(e),e})(a)))},Z=(t,e,n,o)=>{if(t&&t[e])try{return t[e](n)}catch(t){i(t,o)}},tt=t=>t.classList.add("hydrated"),et=(t,e,n,o)=>{const r=l(t);if(!r)return;if(!r)throw Error(`Couldn't find host element for "${o.h}" as it is unknown to this Stencil runtime. This usually happens when integrating a 3rd party Stencil component with another Stencil component or application. Please reach out to the maintainers of the 3rd party Stencil component or report this on the Stencil Discord server (https://chat.stenciljs.com) or comment on this similar [GitHub issue](https://github.com/stenciljs/core/issues/5457).`);const i=r.l.get(e),s=r.u,c=r.i;if(n=A(n,o.t[e][0]),!(8&s&&void 0!==i||n===i||Number.isNaN(i)&&Number.isNaN(n)||(r.l.set(e,n),2!=(18&s)))){if(c.componentShouldUpdate&&!1===c.componentShouldUpdate(n,i,e))return;G(r,!1)}},nt=(t,e,n)=>{var o,r;const i=t.prototype;if(e.t){const s=Object.entries(null!=(o=e.t)?o:{});if(s.map((([t,[o]])=>{if(31&o||2&n&&32&o){const{get:r,set:s}=Object.getOwnPropertyDescriptor(i,t)||{};r&&(e.t[t][0]|=2048),s&&(e.t[t][0]|=4096),(1&n||!r)&&Object.defineProperty(i,t,{get(){{if(!(2048&e.t[t][0]))return((t,e)=>l(this).l.get(e))(0,t);const n=l(this),o=n?n.i:i;if(!o)return;return o[t]}},configurable:!0,enumerable:!0}),Object.defineProperty(i,t,{set(r){const i=l(this);if(i){if(s)return void 0===(32&o?this[t]:i.$hostElement$[t])&&i.l.get(t)&&(r=i.l.get(t)),s.call(this,A(r,o)),void et(this,t,r=32&o?this[t]:i.$hostElement$[t],e);{if(!(1&n&&4096&e.t[t][0]))return et(this,t,r,e),void(1&n&&!i.i&&i.C.push((()=>{4096&e.t[t][0]&&i.i[t]!==i.l.get(t)&&(i.i[t]=r)})));const l=()=>{const n=i.i[t];!i.l.get(t)&&n&&i.l.set(t,n),i.i[t]=A(r,o),et(this,t,i.i[t],e)};i.i?l():i.C.push((()=>{l()}))}}}})}})),1&n){const n=new Map;i.attributeChangedCallback=function(t,o,r){u.jmp((()=>{var c;const a=n.get(t),u=l(this);if(this.hasOwnProperty(a)&&(r=this[a],delete this[a]),i.hasOwnProperty(a)&&"number"==typeof this[a]&&this[a]==r)return;if(null==a){const n=null==u?void 0:u.u;if(u&&n&&!(8&n)&&r!==o){const l=u.i,i=null==(c=e.P)?void 0:c[t];null==i||i.forEach((e=>{const[[i,s]]=Object.entries(e);null!=l[i]&&(128&n||1&s)&&l[i].call(l,r,o,t)}))}return}const f=s.find((([t])=>t===a));f&&4&f[1][0]&&(r=null!==r&&"false"!==r);const d=Object.getOwnPropertyDescriptor(i,a);r==this[a]||d.get&&!d.set||(this[a]=r)}))},t.observedAttributes=Array.from(new Set([...Object.keys(null!=(r=e.P)?r:{}),...s.filter((([t,e])=>31&e[0])).map((([t,e])=>{const o=e[1]||t;return n.set(o,t),o}))]))}}return t},ot=(t,e)=>{Z(t,"connectedCallback",void 0,e)},lt=(t,e)=>{Z(t,"disconnectedCallback",void 0,e||t)},rt=(t,e={})=>{var n;if(!a.document)return void console.warn("Stencil: No document found. Skipping bootstrapping lazy components.");const o=[],r=e.exclude||[],f=a.customElements,p=a.document.head,h=p.querySelector("meta[charset]"),m=a.document.createElement("style"),y=[];let v,b=!0;if(Object.assign(u,e),u.p=new URL(e.resourcesUrl||"./",a.document.baseURI).href,t.map((t=>{t[1].map((e=>{const n={u:e[0],h:e[1],t:e[2],B:e[3]};n.t=e[2];const a=n.h,p=class extends HTMLElement{"s-p";"s-rc";hasRegisteredEventListeners=!1;constructor(t){if(super(t),((t,e)=>{const n={u:0,$hostElement$:t,o:e,l:new Map,L:new Map};n.N=new Promise((t=>n.R=t)),t["s-p"]=[],t["s-rc"]=[],n.C=[];const o=n;t.__stencil__getHostRef=()=>o})(t=this,n),1&n.u)if(t.shadowRoot){if("open"!==t.shadowRoot.mode)throw Error(`Unable to re-use existing shadow root for ${n.h}! Mode is set to ${t.shadowRoot.mode} but Stencil only supports open shadow roots.`)}else g.call(t,n)}connectedCallback(){l(this)&&(this.hasRegisteredEventListeners||(this.hasRegisteredEventListeners=!0),v&&(clearTimeout(v),v=null),b?y.push(this):u.jmp((()=>(t=>{if(!(1&u.u)){const e=l(t);if(!e)return;const n=e.o,o=()=>{};if(1&e.u)(null==e?void 0:e.i)?ot(e.i,t):(null==e?void 0:e.N)&&e.N.then((()=>ot(e.i,t)));else{e.u|=1;{let n=t;for(;n=n.parentNode||n.host;)if(n["s-p"]){z(e,e.k=n);break}}n.t&&Object.entries(n.t).map((([e,[n]])=>{if(31&n&&e in t&&t[e]!==Object.prototype[e]){const n=t[e];delete t[e],t[e]=n}})),(async(t,e,n)=>{let o;if(!(32&e.u)){if(e.u|=32,n.U){const l=((t,e)=>{const n=t.h.replace(/-/g,"_"),o=t.U;if(!o)return;const l=s.get(o);return l?l[n]:import(`./${o}.entry.js`).then((t=>(s.set(o,t),t[n])),(t=>{i(t,e.$hostElement$)}))
2
+ /*!__STENCIL_STATIC_IMPORT_SWITCH__*/})(n,e);if(l&&"then"in l){const t=()=>{};o=await l,t()}else o=l;if(!o)throw Error(`Constructor for "${n.h}#${e.H}" was not found`);o.isProxied||(nt(o,n,2),o.isProxied=!0);const r=()=>{};e.u|=8;try{new o(e)}catch(e){i(e,t)}e.u&=-9,r(),ot(e.i,t)}else o=t.constructor,customElements.whenDefined(t.localName).then((()=>e.u|=128));if(o&&o.style){let t;"string"==typeof o.style&&(t=o.style);const e=E(n);if(!c.has(e)){const o=()=>{};((t,e,n)=>{let o=c.get(t);d&&n?(o=o||new CSSStyleSheet,"string"==typeof o?o=e:o.replaceSync(e)):o=e,c.set(t,o)})(e,t,!!(1&n.u)),o()}}}const l=e.k,r=()=>G(e,!0);l&&l["s-rc"]?l["s-rc"].push(r):r()})(t,e,n)}o()}})(this))))}disconnectedCallback(){u.jmp((()=>(async t=>{if(!(1&u.u)){const e=l(t);(null==e?void 0:e.i)?lt(e.i,t):(null==e?void 0:e.N)&&e.N.then((()=>lt(e.i,t)))}O.has(t)&&O.delete(t),t.shadowRoot&&O.has(t.shadowRoot)&&O.delete(t.shadowRoot)})(this))),u.raf((()=>{var t;const e=l(this);if(!e)return;const n=y.findIndex((t=>t===this));n>-1&&y.splice(n,1),(null==(t=null==e?void 0:e.A)?void 0:t.S)instanceof Node&&!e.A.S.isConnected&&delete e.A.S}))}componentOnReady(){var t;return null==(t=l(this))?void 0:t.N}};n.U=t[0],r.includes(a)||f.get(a)||(o.push(a),f.define(a,nt(p,n,1)))}))})),o.length>0&&(m.textContent+=o.sort()+"{visibility:hidden}.hydrated{visibility:inherit}",m.innerHTML.length)){m.setAttribute("data-styles","");const t=null!=(n=u.M)?n:j(a.document);null!=t&&m.setAttribute("nonce",t),p.insertBefore(m,h?h.nextSibling:p.firstChild)}b=!1,y.length?y.map((t=>t.connectedCallback())):u.jmp((()=>v=setTimeout(X,30)))},it=t=>u.M=t;export{M as H,rt as b,t as g,k as h,f as p,r,it as s}
@@ -1,28 +1 @@
1
- :root {
2
- --color-primary: #6750A4;
3
- --color-on-primary: #FFFFFF;
4
- --color-primary-container: #EADDFF;
5
- --color-on-primary-container: #21005D;
6
- --color-secondary: #625B71;
7
- --color-on-secondary: #FFFFFF;
8
- --color-secondary-container: #E8DEF8;
9
- --color-on-secondary-container: #1D192B;
10
- --color-tertiary: #7D5260;
11
- --color-on-tertiary: #FFFFFF;
12
- --color-tertiary-container: #FFD8E4;
13
- --color-on-tertiary-container: #31111D;
14
- --color-error: #B3261E;
15
- --color-on-error: #FFFFFF;
16
- --color-surface: #FEF7FF;
17
- --color-on-surface: #1D1B20;
18
- --color-on-surface-variant: #49454F;
19
- --color-outline: #79747E;
20
- }
21
-
22
- html, body {
23
- margin: 0;
24
- padding: 0;
25
- font-family: "Roboto", system-ui, -apple-system, sans-serif;
26
- background-color: #FEF7FF;
27
- color: #1D1B20;
28
- }
1
+ :root{--color-primary:#6750A4;--color-on-primary:#FFFFFF;--color-primary-container:#EADDFF;--color-on-primary-container:#21005D;--color-secondary:#625B71;--color-on-secondary:#FFFFFF;--color-secondary-container:#E8DEF8;--color-on-secondary-container:#1D192B;--color-tertiary:#7D5260;--color-on-tertiary:#FFFFFF;--color-tertiary-container:#FFD8E4;--color-on-tertiary-container:#31111D;--color-error:#B3261E;--color-on-error:#FFFFFF;--color-surface:#FEF7FF;--color-on-surface:#1D1B20;--color-on-surface-variant:#49454F;--color-outline:#79747E}html,body{margin:0;padding:0;font-family:"Roboto", system-ui, -apple-system, sans-serif;background-color:#FEF7FF;color:#1D1B20}
@@ -1,47 +1 @@
1
- import { B as BUILD, c as consoleDevInfo, H, w as win, N as NAMESPACE, p as promiseResolve, g as globalScripts, b as bootstrapLazy } from './index-CDwILsz8.js';
2
- export { s as setNonce } from './index-CDwILsz8.js';
3
-
4
- /*
5
- Stencil Client Patch Browser v4.41.2 | MIT Licensed | https://stenciljs.com
6
- */
7
-
8
- var patchBrowser = () => {
9
- if (BUILD.isDev && !BUILD.isTesting) {
10
- consoleDevInfo("Running in development mode.");
11
- }
12
- if (BUILD.cloneNodeFix) {
13
- patchCloneNodeFix(H.prototype);
14
- }
15
- const scriptElm = BUILD.scriptDataOpts ? win.document && Array.from(win.document.querySelectorAll("script")).find(
16
- (s) => new RegExp(`/${NAMESPACE}(\\.esm)?\\.js($|\\?|#)`).test(s.src) || s.getAttribute("data-stencil-namespace") === NAMESPACE
17
- ) : null;
18
- const importMeta = import.meta.url;
19
- const opts = BUILD.scriptDataOpts ? (scriptElm || {})["data-opts"] || {} : {};
20
- if (importMeta !== "") {
21
- opts.resourcesUrl = new URL(".", importMeta).href;
22
- }
23
- return promiseResolve(opts);
24
- };
25
- var patchCloneNodeFix = (HTMLElementPrototype) => {
26
- const nativeCloneNodeFn = HTMLElementPrototype.cloneNode;
27
- HTMLElementPrototype.cloneNode = function(deep) {
28
- if (this.nodeName === "TEMPLATE") {
29
- return nativeCloneNodeFn.call(this, deep);
30
- }
31
- const clonedNode = nativeCloneNodeFn.call(this, false);
32
- const srcChildNodes = this.childNodes;
33
- if (deep) {
34
- for (let i = 0; i < srcChildNodes.length; i++) {
35
- if (srcChildNodes[i].nodeType !== 2) {
36
- clonedNode.appendChild(srcChildNodes[i].cloneNode(true));
37
- }
38
- }
39
- }
40
- return clonedNode;
41
- };
42
- };
43
-
44
- patchBrowser().then(async (options) => {
45
- await globalScripts();
46
- return bootstrapLazy([["ui-label",[[257,"ui-label",{"label":[1],"variant":[1],"color":[1],"weight":[1],"italic":[4]}]]]], options);
47
- });
1
+ import{p as a,g as t,b as e}from"./p-DuNnHYm7.js";export{s as setNonce}from"./p-DuNnHYm7.js";(()=>{const t=import.meta.url,e={};return""!==t&&(e.resourcesUrl=new URL(".",t).href),a(e)})().then((async a=>(await t(),e([["p-00537ea8",[[257,"ui-label",{label:[1],variant:[1],color:[1],weight:[1],italic:[4]}]]]],a))));
package/package.json CHANGED
@@ -1,65 +1,65 @@
1
- {
2
- "name": "@re-code/ui-components",
3
- "version": "0.0.1",
4
- "description": "Stencil Component Starter for Wa-Machi Design System",
5
- "main": "dist/index.cjs.js",
6
- "module": "dist/index.js",
7
- "es2015": "dist/esm/index.mjs",
8
- "es2017": "dist/esm/index.mjs",
9
- "types": "dist/types/index.d.ts",
10
- "collection": "dist/collection/collection-manifest.json",
11
- "collection:main": "dist/collection/index.js",
12
- "unpkg": "dist/ui-components/ui-components.esm.js",
13
- "files": [
14
- "dist/"
15
- ],
16
- "scripts": {
17
- "build": "stencil build --docs",
18
- "build:watch": "stencil build --dev --watch",
19
- "start": "stencil build --dev --watch --serve",
20
- "test": "stencil test --spec --e2e",
21
- "test:watch": "stencil test --spec --e2e --watchAll",
22
- "generate": "stencil generate",
23
- "lint": "eslint .",
24
- "storybook": "storybook dev -p 6006",
25
- "build-storybook": "npm run build && storybook build",
26
- "dev": "concurrently \"npm run build:watch\" \"npm run storybook\""
27
- },
28
- "dependencies": {
29
- "@stencil/core": "^4.12.0",
30
- "@stencil/sass": "^3.0.0"
31
- },
32
- "devDependencies": {
33
- "@eslint/js": "^9.39.2",
34
- "@storybook/addon-essentials": "^8.0.0",
35
- "@storybook/addon-links": "^8.0.0",
36
- "@storybook/blocks": "^8.0.0",
37
- "@storybook/web-components": "^8.0.0",
38
- "@storybook/web-components-vite": "^8.0.0",
39
- "@types/jest": "^29.5.0",
40
- "@types/node": "^20.0.0",
41
- "@typescript-eslint/eslint-plugin": "^8.53.1",
42
- "@typescript-eslint/parser": "^8.53.1",
43
- "concurrently": "^9.1.2",
44
- "eslint": "^9.39.2",
45
- "globals": "^17.0.0",
46
- "jest": "^29.5.0",
47
- "jest-cli": "^29.5.0",
48
- "lit": "^3.1.0",
49
- "puppeteer": "^21.0.0",
50
- "rimraf": "^5.0.0",
51
- "storybook": "^8.0.0",
52
- "typescript": "^5.0.0",
53
- "typescript-eslint": "^8.53.1",
54
- "vite": "^5.0.0"
55
- },
56
- "license": "MIT",
57
- "repository": {
58
- "type": "git",
59
- "url": "https://github.com/iamcodex96/ui-components.git"
60
- },
61
- "tags": [
62
- "autodocs"
63
- ],
64
- "private": false
65
- }
1
+ {
2
+ "name": "@re-code/ui-components",
3
+ "version": "0.0.2",
4
+ "description": "Stencil Component Starter for Wa-Machi Design System",
5
+ "main": "dist/index.cjs.js",
6
+ "module": "dist/index.js",
7
+ "es2015": "dist/esm/index.mjs",
8
+ "es2017": "dist/esm/index.mjs",
9
+ "types": "dist/types/index.d.ts",
10
+ "collection": "dist/collection/collection-manifest.json",
11
+ "collection:main": "dist/collection/index.js",
12
+ "unpkg": "dist/ui-components/ui-components.esm.js",
13
+ "files": [
14
+ "dist/"
15
+ ],
16
+ "scripts": {
17
+ "build": "stencil build --docs",
18
+ "build:watch": "stencil build --dev --watch",
19
+ "start": "stencil build --dev --watch --serve",
20
+ "test": "stencil test --spec --e2e",
21
+ "test:watch": "stencil test --spec --e2e --watchAll",
22
+ "generate": "stencil generate",
23
+ "lint": "eslint .",
24
+ "storybook": "storybook dev -p 6006",
25
+ "build-storybook": "npm run build && storybook build",
26
+ "dev": "concurrently \"npm run build:watch\" \"npm run storybook\""
27
+ },
28
+ "dependencies": {
29
+ "@stencil/core": "^4.12.0",
30
+ "@stencil/sass": "^3.0.0"
31
+ },
32
+ "devDependencies": {
33
+ "@eslint/js": "^9.39.2",
34
+ "@storybook/addon-essentials": "^8.0.0",
35
+ "@storybook/addon-links": "^8.0.0",
36
+ "@storybook/blocks": "^8.0.0",
37
+ "@storybook/web-components": "^8.0.0",
38
+ "@storybook/web-components-vite": "^8.0.0",
39
+ "@types/jest": "^29.5.0",
40
+ "@types/node": "^20.0.0",
41
+ "@typescript-eslint/eslint-plugin": "^8.53.1",
42
+ "@typescript-eslint/parser": "^8.53.1",
43
+ "concurrently": "^9.1.2",
44
+ "eslint": "^9.39.2",
45
+ "globals": "^17.0.0",
46
+ "jest": "^29.5.0",
47
+ "jest-cli": "^29.5.0",
48
+ "lit": "^3.1.0",
49
+ "puppeteer": "^21.0.0",
50
+ "rimraf": "^5.0.0",
51
+ "storybook": "^8.0.0",
52
+ "typescript": "^5.0.0",
53
+ "typescript-eslint": "^8.53.1",
54
+ "vite": "^5.0.0"
55
+ },
56
+ "license": "MIT",
57
+ "repository": {
58
+ "type": "git",
59
+ "url": "https://github.com/iamcodex96/ui-components.git"
60
+ },
61
+ "tags": [
62
+ "autodocs"
63
+ ],
64
+ "private": false
65
+ }