@florid-kit/components 0.8.58 → 0.8.59
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.
- package/components/filter-chip.d.ts +2 -1
- package/index.js +15 -15
- package/index.mjs +85 -82
- package/package.json +1 -1
package/index.js
CHANGED
|
@@ -12,7 +12,7 @@
|
|
|
12
12
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
13
13
|
*/const it=globalThis,yt=it.trustedTypes,Xt=yt?yt.createPolicy("lit-html",{createHTML:o=>o}):void 0,re="$lit$",F=`lit$${Math.random().toFixed(9).slice(2)}$`,se="?"+F,we=`<${se}>`,K=document,rt=()=>K.createComment(""),st=o=>o===null||typeof o!="object"&&typeof o!="function",zt=Array.isArray,xe=o=>zt(o)||typeof(o==null?void 0:o[Symbol.iterator])=="function",Ct=`[
|
|
14
14
|
\f\r]`,et=/<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g,Jt=/-->/g,Qt=/>/g,V=RegExp(`>|${Ct}(?:([^\\s"'>=/]+)(${Ct}*=${Ct}*(?:[^
|
|
15
|
-
\f\r"'\`<>=]|("|')|))|$)`,"g"),Yt=/'/g,te=/"/g,ae=/^(?:script|style|textarea|title)$/i,$e=o=>(t,...e)=>({_$litType$:o,strings:t,values:e}),l=$e(1),U=Symbol.for("lit-noChange"),d=Symbol.for("lit-nothing"),ee=new WeakMap,q=K.createTreeWalker(K,129);function le(o,t){if(!zt(o)||!o.hasOwnProperty("raw"))throw Error("invalid template strings array");return Xt!==void 0?Xt.createHTML(t):t}const _e=(o,t)=>{const e=o.length-1,n=[];let i,r=t===2?"<svg>":t===3?"<math>":"",s=et;for(let h=0;h<e;h++){const c=o[h];let f,m,p=-1,$=0;for(;$<c.length&&(s.lastIndex=$,m=s.exec(c),m!==null);)$=s.lastIndex,s===et?m[1]==="!--"?s=Jt:m[1]!==void 0?s=Qt:m[2]!==void 0?(ae.test(m[2])&&(i=RegExp("</"+m[2],"g")),s=V):m[3]!==void 0&&(s=V):s===V?m[0]===">"?(s=i??et,p=-1):m[1]===void 0?p=-2:(p=s.lastIndex-m[2].length,f=m[1],s=m[3]===void 0?V:m[3]==='"'?te:Yt):s===te||s===Yt?s=V:s===Jt||s===Qt?s=et:(s=V,i=void 0);const
|
|
15
|
+
\f\r"'\`<>=]|("|')|))|$)`,"g"),Yt=/'/g,te=/"/g,ae=/^(?:script|style|textarea|title)$/i,$e=o=>(t,...e)=>({_$litType$:o,strings:t,values:e}),l=$e(1),U=Symbol.for("lit-noChange"),d=Symbol.for("lit-nothing"),ee=new WeakMap,q=K.createTreeWalker(K,129);function le(o,t){if(!zt(o)||!o.hasOwnProperty("raw"))throw Error("invalid template strings array");return Xt!==void 0?Xt.createHTML(t):t}const _e=(o,t)=>{const e=o.length-1,n=[];let i,r=t===2?"<svg>":t===3?"<math>":"",s=et;for(let h=0;h<e;h++){const c=o[h];let f,m,p=-1,$=0;for(;$<c.length&&(s.lastIndex=$,m=s.exec(c),m!==null);)$=s.lastIndex,s===et?m[1]==="!--"?s=Jt:m[1]!==void 0?s=Qt:m[2]!==void 0?(ae.test(m[2])&&(i=RegExp("</"+m[2],"g")),s=V):m[3]!==void 0&&(s=V):s===V?m[0]===">"?(s=i??et,p=-1):m[1]===void 0?p=-2:(p=s.lastIndex-m[2].length,f=m[1],s=m[3]===void 0?V:m[3]==='"'?te:Yt):s===te||s===Yt?s=V:s===Jt||s===Qt?s=et:(s=V,i=void 0);const L=s===V&&o[h+1].startsWith("/>")?" ":"";r+=s===et?c+we:p>=0?(n.push(f),c.slice(0,p)+re+c.slice(p)+F+L):c+F+(p===-2?h:L)}return[le(o,r+(o[e]||"<?>")+(t===2?"</svg>":t===3?"</math>":"")),n]};class at{constructor({strings:t,_$litType$:e},n){let i;this.parts=[];let r=0,s=0;const h=t.length-1,c=this.parts,[f,m]=_e(t,e);if(this.el=at.createElement(f,n),q.currentNode=this.el.content,e===2||e===3){const p=this.el.content.firstChild;p.replaceWith(...p.childNodes)}for(;(i=q.nextNode())!==null&&c.length<h;){if(i.nodeType===1){if(i.hasAttributes())for(const p of i.getAttributeNames())if(p.endsWith(re)){const $=m[s++],L=i.getAttribute(p).split(F),ft=/([.?@])?(.*)/.exec($);c.push({type:1,index:r,name:ft[2],strings:L,ctor:ft[1]==="."?ke:ft[1]==="?"?Ae:ft[1]==="@"?Ee:wt}),i.removeAttribute(p)}else p.startsWith(F)&&(c.push({type:6,index:r}),i.removeAttribute(p));if(ae.test(i.tagName)){const p=i.textContent.split(F),$=p.length-1;if($>0){i.textContent=yt?yt.emptyScript:"";for(let L=0;L<$;L++)i.append(p[L],rt()),q.nextNode(),c.push({type:2,index:++r});i.append(p[$],rt())}}}else if(i.nodeType===8)if(i.data===se)c.push({type:2,index:r});else{let p=-1;for(;(p=i.data.indexOf(F,p+1))!==-1;)c.push({type:7,index:r}),p+=F.length-1}r++}}static createElement(t,e){const n=K.createElement("template");return n.innerHTML=t,n}}function Q(o,t,e=o,n){var s,h;if(t===U)return t;let i=n!==void 0?(s=e._$Co)==null?void 0:s[n]:e._$Cl;const r=st(t)?void 0:t._$litDirective$;return(i==null?void 0:i.constructor)!==r&&((h=i==null?void 0:i._$AO)==null||h.call(i,!1),r===void 0?i=void 0:(i=new r(o),i._$AT(o,e,n)),n!==void 0?(e._$Co??(e._$Co=[]))[n]=i:e._$Cl=i),i!==void 0&&(t=Q(o,i._$AS(o,t.values),i,n)),t}class Ce{constructor(t,e){this._$AV=[],this._$AN=void 0,this._$AD=t,this._$AM=e}get parentNode(){return this._$AM.parentNode}get _$AU(){return this._$AM._$AU}u(t){const{el:{content:e},parts:n}=this._$AD,i=((t==null?void 0:t.creationScope)??K).importNode(e,!0);q.currentNode=i;let r=q.nextNode(),s=0,h=0,c=n[0];for(;c!==void 0;){if(s===c.index){let f;c.type===2?f=new ut(r,r.nextSibling,this,t):c.type===1?f=new c.ctor(r,c.name,c.strings,this,t):c.type===6&&(f=new Se(r,this,t)),this._$AV.push(f),c=n[++h]}s!==(c==null?void 0:c.index)&&(r=q.nextNode(),s++)}return q.currentNode=K,i}p(t){let e=0;for(const n of this._$AV)n!==void 0&&(n.strings!==void 0?(n._$AI(t,n,e),e+=n.strings.length-2):n._$AI(t[e])),e++}}class ut{get _$AU(){var t;return((t=this._$AM)==null?void 0:t._$AU)??this._$Cv}constructor(t,e,n,i){this.type=2,this._$AH=d,this._$AN=void 0,this._$AA=t,this._$AB=e,this._$AM=n,this.options=i,this._$Cv=(i==null?void 0:i.isConnected)??!0}get parentNode(){let t=this._$AA.parentNode;const e=this._$AM;return e!==void 0&&(t==null?void 0:t.nodeType)===11&&(t=e.parentNode),t}get startNode(){return this._$AA}get endNode(){return this._$AB}_$AI(t,e=this){t=Q(this,t,e),st(t)?t===d||t==null||t===""?(this._$AH!==d&&this._$AR(),this._$AH=d):t!==this._$AH&&t!==U&&this._(t):t._$litType$!==void 0?this.$(t):t.nodeType!==void 0?this.T(t):xe(t)?this.k(t):this._(t)}O(t){return this._$AA.parentNode.insertBefore(t,this._$AB)}T(t){this._$AH!==t&&(this._$AR(),this._$AH=this.O(t))}_(t){this._$AH!==d&&st(this._$AH)?this._$AA.nextSibling.data=t:this.T(K.createTextNode(t)),this._$AH=t}$(t){var r;const{values:e,_$litType$:n}=t,i=typeof n=="number"?this._$AC(t):(n.el===void 0&&(n.el=at.createElement(le(n.h,n.h[0]),this.options)),n);if(((r=this._$AH)==null?void 0:r._$AD)===i)this._$AH.p(e);else{const s=new Ce(i,this),h=s.u(this.options);s.p(e),this.T(h),this._$AH=s}}_$AC(t){let e=ee.get(t.strings);return e===void 0&&ee.set(t.strings,e=new at(t)),e}k(t){zt(this._$AH)||(this._$AH=[],this._$AR());const e=this._$AH;let n,i=0;for(const r of t)i===e.length?e.push(n=new ut(this.O(rt()),this.O(rt()),this,this.options)):n=e[i],n._$AI(r),i++;i<e.length&&(this._$AR(n&&n._$AB.nextSibling,i),e.length=i)}_$AR(t=this._$AA.nextSibling,e){var n;for((n=this._$AP)==null?void 0:n.call(this,!1,!0,e);t&&t!==this._$AB;){const i=t.nextSibling;t.remove(),t=i}}setConnected(t){var e;this._$AM===void 0&&(this._$Cv=t,(e=this._$AP)==null||e.call(this,t))}}class wt{get tagName(){return this.element.tagName}get _$AU(){return this._$AM._$AU}constructor(t,e,n,i,r){this.type=1,this._$AH=d,this._$AN=void 0,this.element=t,this.name=e,this._$AM=i,this.options=r,n.length>2||n[0]!==""||n[1]!==""?(this._$AH=Array(n.length-1).fill(new String),this.strings=n):this._$AH=d}_$AI(t,e=this,n,i){const r=this.strings;let s=!1;if(r===void 0)t=Q(this,t,e,0),s=!st(t)||t!==this._$AH&&t!==U,s&&(this._$AH=t);else{const h=t;let c,f;for(t=r[0],c=0;c<r.length-1;c++)f=Q(this,h[n+c],e,c),f===U&&(f=this._$AH[c]),s||(s=!st(f)||f!==this._$AH[c]),f===d?t=d:t!==d&&(t+=(f??"")+r[c+1]),this._$AH[c]=f}s&&!i&&this.j(t)}j(t){t===d?this.element.removeAttribute(this.name):this.element.setAttribute(this.name,t??"")}}class ke extends wt{constructor(){super(...arguments),this.type=3}j(t){this.element[this.name]=t===d?void 0:t}}class Ae extends wt{constructor(){super(...arguments),this.type=4}j(t){this.element.toggleAttribute(this.name,!!t&&t!==d)}}class Ee extends wt{constructor(t,e,n,i,r){super(t,e,n,i,r),this.type=5}_$AI(t,e=this){if((t=Q(this,t,e,0)??d)===U)return;const n=this._$AH,i=t===d&&n!==d||t.capture!==n.capture||t.once!==n.once||t.passive!==n.passive,r=t!==d&&(n===d||i);i&&this.element.removeEventListener(this.name,this,n),r&&this.element.addEventListener(this.name,this,t),this._$AH=t}handleEvent(t){var e;typeof this._$AH=="function"?this._$AH.call(((e=this.options)==null?void 0:e.host)??this.element,t):this._$AH.handleEvent(t)}}class Se{constructor(t,e,n){this.element=t,this.type=6,this._$AN=void 0,this._$AM=e,this.options=n}get _$AU(){return this._$AM._$AU}_$AI(t){Q(this,t)}}const kt=it.litHtmlPolyfillSupport;kt==null||kt(at,ut),(it.litHtmlVersions??(it.litHtmlVersions=[])).push("3.3.0");const Le=(o,t,e)=>{const n=(e==null?void 0:e.renderBefore)??t;let i=n._$litPart$;if(i===void 0){const r=(e==null?void 0:e.renderBefore)??null;n._$litPart$=i=new ut(t.insertBefore(rt(),r),r,void 0,e??{})}return i._$AI(o),i};/**
|
|
16
16
|
* @license
|
|
17
17
|
* Copyright 2017 Google LLC
|
|
18
18
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
@@ -668,7 +668,7 @@
|
|
|
668
668
|
.sr-only {
|
|
669
669
|
display: none;
|
|
670
670
|
}
|
|
671
|
-
`;B([a({type:String,reflect:!0})],C.prototype,"bgstyle",2);B([a({type:String,reflect:!0})],C.prototype,"size",2);B([a({type:String,reflect:!0})],C.prototype,"status",2);B([a({type:String,reflect:!0})],C.prototype,"type",2);B([a({type:String})],C.prototype,"strokewidth",2);B([a({type:String})],C.prototype,"icon",2);B([a({type:Boolean,reflect:!0})],C.prototype,"disabled",2);B([a({type:Boolean})],C.prototype,"showSrLabel",2);B([a({type:String})],C.prototype,"srLabel",2);C=B([w("o-icon-button")],C);var po=Object.defineProperty,uo=Object.getOwnPropertyDescriptor,X=(o,t,e,n)=>{for(var i=n>1?void 0:n?uo(t,e):t,r=o.length-1,s;r>=0;r--)(s=o[r])&&(i=(n?s(t,e,i):s(i))||i);return n&&i&&po(t,e,i),i};let
|
|
671
|
+
`;B([a({type:String,reflect:!0})],C.prototype,"bgstyle",2);B([a({type:String,reflect:!0})],C.prototype,"size",2);B([a({type:String,reflect:!0})],C.prototype,"status",2);B([a({type:String,reflect:!0})],C.prototype,"type",2);B([a({type:String})],C.prototype,"strokewidth",2);B([a({type:String})],C.prototype,"icon",2);B([a({type:Boolean,reflect:!0})],C.prototype,"disabled",2);B([a({type:Boolean})],C.prototype,"showSrLabel",2);B([a({type:String})],C.prototype,"srLabel",2);C=B([w("o-icon-button")],C);var po=Object.defineProperty,uo=Object.getOwnPropertyDescriptor,X=(o,t,e,n)=>{for(var i=n>1?void 0:n?uo(t,e):t,r=o.length-1,s;r>=0;r--)(s=o[r])&&(i=(n?s(t,e,i):s(i))||i);return n&&i&&po(t,e,i),i};let H=class extends v{constructor(){super(...arguments),this.href="",this.target="",this.template="standard",this.inverse=!1,this.endIcon=!1,this.reverseEndIcon=!1}_handleClick(o){(!this.href||this.href==="#")&&o.preventDefault()}render(){const o=this.href||"#";return l`
|
|
672
672
|
<a
|
|
673
673
|
href="${o}"
|
|
674
674
|
target="${_(this.target||void 0)}"
|
|
@@ -694,7 +694,7 @@
|
|
|
694
694
|
></o-icon-button>
|
|
695
695
|
`:null}
|
|
696
696
|
</a>
|
|
697
|
-
`}};
|
|
697
|
+
`}};H.styles=y`
|
|
698
698
|
:host([template="standard"]) a {
|
|
699
699
|
color: var(--color-content-action-secondary);
|
|
700
700
|
font-size: var(--font-size-200);
|
|
@@ -781,7 +781,7 @@
|
|
|
781
781
|
height: 1px;
|
|
782
782
|
}
|
|
783
783
|
/* End of underline effect */
|
|
784
|
-
`;X([a({type:String})],
|
|
784
|
+
`;X([a({type:String})],H.prototype,"href",2);X([a({type:String})],H.prototype,"target",2);X([a({type:String,reflect:!0})],H.prototype,"template",2);X([a({type:Boolean,reflect:!0})],H.prototype,"inverse",2);X([a({type:Boolean,reflect:!0})],H.prototype,"endIcon",2);X([a({type:Boolean,reflect:!0})],H.prototype,"reverseEndIcon",2);H=X([w("o-link")],H);var vo=Object.defineProperty,fo=Object.getOwnPropertyDescriptor,$t=(o,t,e,n)=>{for(var i=n>1?void 0:n?fo(t,e):t,r=o.length-1,s;r>=0;r--)(s=o[r])&&(i=(n?s(t,e,i):s(i))||i);return n&&i&&vo(t,e,i),i};let tt=class extends v{constructor(){super(...arguments),this.rating=0}getStarKeys(){const o=[];for(let t=0;t<5;t++){const e=this.rating-t;let n;e>=1?n=100:e<=0?n=0:n=Math.round(e*100/25)*25,o.push(`star-${n}`)}return o}render(){const o=this.getStarKeys();return l`
|
|
785
785
|
<div class="rating">
|
|
786
786
|
<div class="stars">
|
|
787
787
|
${o.map(t=>l`<span class="star">${I(G[t]??"")}</span>`)}
|
|
@@ -829,7 +829,7 @@
|
|
|
829
829
|
* @license
|
|
830
830
|
* Copyright 2017 Google LLC
|
|
831
831
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
832
|
-
*/const nt=(o,t)=>{var n;const e=o._$AN;if(e===void 0)return!1;for(const i of e)(n=i._$AO)==null||n.call(i,t,!1),nt(i,t);return!0},mt=o=>{let t,e;do{if((t=o._$AM)===void 0)break;e=t._$AN,e.delete(o),o=t}while((e==null?void 0:e.size)===0)},ce=o=>{for(let t;t=o._$AM;o=t){let e=t._$AN;if(e===void 0)t._$AN=e=new Set;else if(e.has(o))break;e.add(o),mo(t)}};function go(o){this._$AN!==void 0?(mt(this),this._$AM=o,ce(this)):this._$AM=o}function yo(o,t=!1,e=0){const n=this._$AH,i=this._$AN;if(i!==void 0&&i.size!==0)if(t)if(Array.isArray(n))for(let r=e;r<n.length;r++)nt(n[r],!1),mt(n[r]);else n!=null&&(nt(n,!1),mt(n));else nt(this,o)}const mo=o=>{o.type==Mt.CHILD&&(o._$AP??(o._$AP=yo),o._$AQ??(o._$AQ=go))};class wo extends jt{constructor(){super(...arguments),this._$AN=void 0}_$AT(t,e,n){super._$AT(t,e,n),ce(this),this.isConnected=t._$AU}_$AO(t,e=!0){var n,i;t!==this.isConnected&&(this.isConnected=t,t?(n=this.reconnected)==null||n.call(this):(i=this.disconnected)==null||i.call(this)),e&&(nt(this,t),mt(this))}setValue(t){if(bo(this._$Ct))this._$Ct._$AI(t,this);else{const e=[...this._$Ct._$AH];e[this._$Ci]=t,this._$Ct._$AI(e,this,0)}}disconnected(){}reconnected(){}}class xo extends wo{constructor(){super(...arguments),this.prevData={}}render(t){return d}update(t,[e]){var n;this.element!==t.element&&(this.element=t.element),this.host=((n=t.options)===null||n===void 0?void 0:n.host)||this.element,this.apply(e),this.groom(e),this.prevData={...e}}apply(t){if(!t)return;const{prevData:e,element:n}=this;for(const i in t){const r=t[i];r!==e[i]&&(n[i]=r)}}groom(t){const{prevData:e,element:n}=this;if(e)for(const i in e)(!t||!(i in t)&&n[i]===e[i])&&(n[i]=void 0)}}class $o extends xo{constructor(){super(...arguments),this.eventData={}}apply(t){if(t)for(const e in t){const n=t[e];n!==this.eventData[e]&&this.applyEvent(e,n)}}applyEvent(t,e){const{prevData:n,element:i}=this;this.eventData[t]=e,n[t]&&i.removeEventListener(t,this,e),i.addEventListener(t,this,e)}groom(t){const{prevData:e,element:n}=this;if(e)for(const i in e)(!t||!(i in t)&&n[i]===e[i])&&this.groomEvent(i,e[i])}groomEvent(t,e){const{element:n}=this;delete this.eventData[t],n.removeEventListener(t,this,e)}handleEvent(t){const e=this.eventData[t.type];typeof e=="function"?e.call(this.host,t):e.handleEvent(t)}disconnected(){const{eventData:t,element:e}=this;for(const n in t){const i=n.slice(1),r=t[n];e.removeEventListener(i,this,r)}}reconnected(){const{eventData:t,element:e}=this;for(const n in t){const i=n.slice(1),r=t[n];e.addEventListener(i,this,r)}}}class _o extends $o{apply(t){if(!t)return;const{prevData:e,element:n}=this;for(const i in t){const r=t[i];if(r===e[i])continue;const s=i.slice(1);switch(i[0]){case"@":this.eventData[s]=r,this.applyEvent(s,r);break;case".":n[s]=r;break;case"?":r?n.setAttribute(s,""):n.removeAttribute(s);break;default:r!=null?n.setAttribute(i,String(r)):n.removeAttribute(i);break}}}groom(t){const{prevData:e,element:n}=this;if(e)for(const i in e){const r=i.slice(1);if(!t||!(i in t)&&n[r]===e[i])switch(i[0]){case"@":this.groomEvent(r,e[i]);break;case".":n[r]=void 0;break;case"?":n.removeAttribute(r);break;default:n.removeAttribute(i);break}}}}const oe=Tt(_o);var Co=Object.defineProperty,ko=Object.getOwnPropertyDescriptor,g=(o,t,e,n)=>{for(var i=n>1?void 0:n?ko(t,e):t,r=o.length-1,s;r>=0;r--)(s=o[r])&&(i=(n?s(t,e,i):s(i))||i);return n&&i&&Co(t,e,i),i};let u=class extends v{constructor(){super(...arguments),this.open=!1,this.showHeader=!0,this.showFooter=!1,this.showHeaderStartIcon=!1,this.headerTitle="",this.headerTitleClassName="panel-title",this.closeButtonLabel="Close the modal",this.firstButtonLabel="Close",this.firstButtonVariant="primary",this.firstButtonProps={},this.onFirstButtonClickClose=!1,this.secondButtonLabel="",this.secondButtonVariant="secondary",this.secondButtonProps={},this.onSecondButtonClickClose=!1,this.disablePortal=!1,this.zIndex=99,this.initialized=!1,this.showDetail=!1,this.isHidingDetail=!1,this.previousFocusedElement=null,this.innerFocusedElement=null,this._onOpenDetail=()=>{this.showDetail=!0,this.showHeaderStartIcon=!0},this.handleKeyDown=o=>{this.open&&(o.key==="Escape"?this.closePanel():o.key==="Tab"&&this.trapFocus(o))},this.handleClosePanel=o=>{if(o instanceof KeyboardEvent&&o.key!=="Enter"&&o.key!==" ")return;o.preventDefault(),o.stopPropagation();const t=o.currentTarget,e=(t==null?void 0:t.getAttribute("data-role"))==="back";if(this.showDetail&&e){this.isHidingDetail=!0;const n=this.renderRoot.querySelector(".content");if(n){const i=()=>{this.showDetail=!1,this.isHidingDetail=!1,this.showHeaderStartIcon=!1,n.removeEventListener("animationend",i)};n.addEventListener("animationend",i)}else this.showDetail=!1,this.isHidingDetail=!1,this.showHeaderStartIcon=!1;return}this.closePanel()}}connectedCallback(){super.connectedCallback(),!this.disablePortal&&this.parentElement!==document.body&&document.body.appendChild(this),this.addEventListener("keydown",this.handleKeyDown),this.updateComplete.then(()=>{this.initialized=!0}),this.addEventListener("open-detail",this._onOpenDetail)}disconnectedCallback(){document.body.style.overflow="",document.body.removeAttribute("data-side-panel"),this.removeEventListener("keydown",this.handleKeyDown),super.disconnectedCallback(),this.removeEventListener("open-detail",this._onOpenDetail)}trapFocus(o){var i,r,s,h,c,f,m,p,$,
|
|
832
|
+
*/const nt=(o,t)=>{var n;const e=o._$AN;if(e===void 0)return!1;for(const i of e)(n=i._$AO)==null||n.call(i,t,!1),nt(i,t);return!0},mt=o=>{let t,e;do{if((t=o._$AM)===void 0)break;e=t._$AN,e.delete(o),o=t}while((e==null?void 0:e.size)===0)},ce=o=>{for(let t;t=o._$AM;o=t){let e=t._$AN;if(e===void 0)t._$AN=e=new Set;else if(e.has(o))break;e.add(o),mo(t)}};function go(o){this._$AN!==void 0?(mt(this),this._$AM=o,ce(this)):this._$AM=o}function yo(o,t=!1,e=0){const n=this._$AH,i=this._$AN;if(i!==void 0&&i.size!==0)if(t)if(Array.isArray(n))for(let r=e;r<n.length;r++)nt(n[r],!1),mt(n[r]);else n!=null&&(nt(n,!1),mt(n));else nt(this,o)}const mo=o=>{o.type==Mt.CHILD&&(o._$AP??(o._$AP=yo),o._$AQ??(o._$AQ=go))};class wo extends jt{constructor(){super(...arguments),this._$AN=void 0}_$AT(t,e,n){super._$AT(t,e,n),ce(this),this.isConnected=t._$AU}_$AO(t,e=!0){var n,i;t!==this.isConnected&&(this.isConnected=t,t?(n=this.reconnected)==null||n.call(this):(i=this.disconnected)==null||i.call(this)),e&&(nt(this,t),mt(this))}setValue(t){if(bo(this._$Ct))this._$Ct._$AI(t,this);else{const e=[...this._$Ct._$AH];e[this._$Ci]=t,this._$Ct._$AI(e,this,0)}}disconnected(){}reconnected(){}}class xo extends wo{constructor(){super(...arguments),this.prevData={}}render(t){return d}update(t,[e]){var n;this.element!==t.element&&(this.element=t.element),this.host=((n=t.options)===null||n===void 0?void 0:n.host)||this.element,this.apply(e),this.groom(e),this.prevData={...e}}apply(t){if(!t)return;const{prevData:e,element:n}=this;for(const i in t){const r=t[i];r!==e[i]&&(n[i]=r)}}groom(t){const{prevData:e,element:n}=this;if(e)for(const i in e)(!t||!(i in t)&&n[i]===e[i])&&(n[i]=void 0)}}class $o extends xo{constructor(){super(...arguments),this.eventData={}}apply(t){if(t)for(const e in t){const n=t[e];n!==this.eventData[e]&&this.applyEvent(e,n)}}applyEvent(t,e){const{prevData:n,element:i}=this;this.eventData[t]=e,n[t]&&i.removeEventListener(t,this,e),i.addEventListener(t,this,e)}groom(t){const{prevData:e,element:n}=this;if(e)for(const i in e)(!t||!(i in t)&&n[i]===e[i])&&this.groomEvent(i,e[i])}groomEvent(t,e){const{element:n}=this;delete this.eventData[t],n.removeEventListener(t,this,e)}handleEvent(t){const e=this.eventData[t.type];typeof e=="function"?e.call(this.host,t):e.handleEvent(t)}disconnected(){const{eventData:t,element:e}=this;for(const n in t){const i=n.slice(1),r=t[n];e.removeEventListener(i,this,r)}}reconnected(){const{eventData:t,element:e}=this;for(const n in t){const i=n.slice(1),r=t[n];e.addEventListener(i,this,r)}}}class _o extends $o{apply(t){if(!t)return;const{prevData:e,element:n}=this;for(const i in t){const r=t[i];if(r===e[i])continue;const s=i.slice(1);switch(i[0]){case"@":this.eventData[s]=r,this.applyEvent(s,r);break;case".":n[s]=r;break;case"?":r?n.setAttribute(s,""):n.removeAttribute(s);break;default:r!=null?n.setAttribute(i,String(r)):n.removeAttribute(i);break}}}groom(t){const{prevData:e,element:n}=this;if(e)for(const i in e){const r=i.slice(1);if(!t||!(i in t)&&n[r]===e[i])switch(i[0]){case"@":this.groomEvent(r,e[i]);break;case".":n[r]=void 0;break;case"?":n.removeAttribute(r);break;default:n.removeAttribute(i);break}}}}const oe=Tt(_o);var Co=Object.defineProperty,ko=Object.getOwnPropertyDescriptor,g=(o,t,e,n)=>{for(var i=n>1?void 0:n?ko(t,e):t,r=o.length-1,s;r>=0;r--)(s=o[r])&&(i=(n?s(t,e,i):s(i))||i);return n&&i&&Co(t,e,i),i};let u=class extends v{constructor(){super(...arguments),this.open=!1,this.showHeader=!0,this.showFooter=!1,this.showHeaderStartIcon=!1,this.headerTitle="",this.headerTitleClassName="panel-title",this.closeButtonLabel="Close the modal",this.firstButtonLabel="Close",this.firstButtonVariant="primary",this.firstButtonProps={},this.onFirstButtonClickClose=!1,this.secondButtonLabel="",this.secondButtonVariant="secondary",this.secondButtonProps={},this.onSecondButtonClickClose=!1,this.disablePortal=!1,this.zIndex=99,this.initialized=!1,this.showDetail=!1,this.isHidingDetail=!1,this.previousFocusedElement=null,this.innerFocusedElement=null,this._onOpenDetail=()=>{this.showDetail=!0,this.showHeaderStartIcon=!0},this.handleKeyDown=o=>{this.open&&(o.key==="Escape"?this.closePanel():o.key==="Tab"&&this.trapFocus(o))},this.handleClosePanel=o=>{if(o instanceof KeyboardEvent&&o.key!=="Enter"&&o.key!==" ")return;o.preventDefault(),o.stopPropagation();const t=o.currentTarget,e=(t==null?void 0:t.getAttribute("data-role"))==="back";if(this.showDetail&&e){this.isHidingDetail=!0;const n=this.renderRoot.querySelector(".content");if(n){const i=()=>{this.showDetail=!1,this.isHidingDetail=!1,this.showHeaderStartIcon=!1,n.removeEventListener("animationend",i)};n.addEventListener("animationend",i)}else this.showDetail=!1,this.isHidingDetail=!1,this.showHeaderStartIcon=!1;return}this.closePanel()}}connectedCallback(){super.connectedCallback(),!this.disablePortal&&this.parentElement!==document.body&&document.body.appendChild(this),this.addEventListener("keydown",this.handleKeyDown),this.updateComplete.then(()=>{this.initialized=!0}),this.addEventListener("open-detail",this._onOpenDetail)}disconnectedCallback(){document.body.style.overflow="",document.body.removeAttribute("data-side-panel"),this.removeEventListener("keydown",this.handleKeyDown),super.disconnectedCallback(),this.removeEventListener("open-detail",this._onOpenDetail)}trapFocus(o){var i,r,s,h,c,f,m,p,$,L;this.innerFocusedElement=document.activeElement||null,this.innerFocusedElement=((r=(i=this.innerFocusedElement)==null?void 0:i.shadowRoot)==null?void 0:r.activeElement)||this.innerFocusedElement;const t=this.getFocusableElements();if(t.length===0)return;const e=t[0],n=t[t.length-1];o.shiftKey&&this.innerFocusedElement===e?(o.preventDefault(),n.shadowRoot?(c=(h=(s=n.shadowRoot)==null?void 0:s.querySelector(u.focusablesSelector))==null?void 0:h.focus)==null||c.call(h):(f=n.focus)==null||f.call(n)):!o.shiftKey&&this.innerFocusedElement===n&&(o.preventDefault(),e.shadowRoot?($=(p=(m=e.shadowRoot)==null?void 0:m.querySelector(u.focusablesSelector))==null?void 0:p.focus)==null||$.call(p):(L=e.focus)==null||L.call(e))}getFocusableElements(){const o=this.renderRoot.querySelector(".panel");if(!o)return[];function t(i){return!(i.disabled||i.hasAttribute("disabled")||i.hasAttribute("tabindex")&&i.getAttribute("tabindex")==="-1")}function e(i){var s;const r=[i.matches(u.focusablesSelector)?i:[]];if(!["o-icon-button","o-button"].includes(i.tagName.toLowerCase())){const h=Array.from(i instanceof HTMLSlotElement?i.assignedElements({flatten:!0}):[]).filter(t).flatMap(e),c=Array.from(((s=i.shadowRoot)==null?void 0:s.querySelectorAll("*"))||[]).filter(t).flatMap(e);r.push(...h,...c)}return r.flat()}return Array.from(o.querySelectorAll("*")).filter(t).flatMap(e)}openPanel(){this.previousFocusedElement=document.activeElement,this.open=!0,document.body.style.overflow="hidden",document.body.setAttribute("data-side-panel","open"),this.updateComplete.then(()=>{var o,t,e,n;if(this.showHeader){const i=((o=this.shadowRoot)==null?void 0:o.querySelector(".panel .close-btn"))||null,r=((t=i==null?void 0:i.shadowRoot)==null?void 0:t.querySelector("button"))||null;r&&((e=r.focus)==null||e.call(r))}else{const i=this.getFocusableElements()[0];(n=i==null?void 0:i.focus)==null||n.call(i)}}),this.dispatchEvent(new CustomEvent("open",{bubbles:!0,composed:!0}))}closePanel(){var o,t,e,n,i;this.open=!1,this.showDetail=!1,document.body.style.overflow="",document.body.removeAttribute("data-side-panel"),((o=this.previousFocusedElement)==null?void 0:o.tagName.toLowerCase())==="o-button"?(n=(e=(t=this.previousFocusedElement.shadowRoot)==null?void 0:t.querySelector(".button"))==null?void 0:e.focus)==null||n.call(e):(i=this.previousFocusedElement)==null||i.focus(),this.dispatchEvent(new CustomEvent("close",{bubbles:!0,composed:!0}))}handleFirstClick(o){o instanceof KeyboardEvent&&o.key!=="Enter"&&o.key!==" "||(o.preventDefault(),o.stopPropagation(),this.onFirstButtonClickClose&&this.closePanel(),this.dispatchEvent(new CustomEvent("firstbuttonclick",{bubbles:!0,composed:!0,cancelable:!0,detail:{button:"first",target:o.target}})))}handleSecondClick(o){o instanceof KeyboardEvent&&o.key!=="Enter"&&o.key!==" "||(o.preventDefault(),o.stopPropagation(),this.onSecondButtonClickClose&&this.closePanel(),this.dispatchEvent(new CustomEvent("secondbuttonclick",{bubbles:!0,composed:!0,cancelable:!0,detail:{button:"second",target:o.target}})))}updated(){this.style.setProperty("--z-overlay",`${this.zIndex||99}`),this.style.setProperty("--z-panel",`${this.zIndex?this.zIndex+1:99}`)}render(){const o=this.showHeader?l`
|
|
833
833
|
<div class="header">
|
|
834
834
|
${this.showHeaderStartIcon?l`
|
|
835
835
|
<o-icon-button
|
|
@@ -1388,7 +1388,7 @@
|
|
|
1388
1388
|
border-color: transparent var(--color-alpha-dark-strongest) transparent transparent;
|
|
1389
1389
|
}
|
|
1390
1390
|
|
|
1391
|
-
`;Rt([a({type:String,reflect:!0})],ct.prototype,"type",2);Rt([a({type:String,reflect:!0})],ct.prototype,"text",2);ct=Rt([w("o-tooltip")],ct);var Oo=Object.defineProperty,Bo=Object.getOwnPropertyDescriptor,
|
|
1391
|
+
`;Rt([a({type:String,reflect:!0})],ct.prototype,"type",2);Rt([a({type:String,reflect:!0})],ct.prototype,"text",2);ct=Rt([w("o-tooltip")],ct);var Oo=Object.defineProperty,Bo=Object.getOwnPropertyDescriptor,M=(o,t,e,n)=>{for(var i=n>1?void 0:n?Bo(t,e):t,r=o.length-1,s;r>=0;r--)(s=o[r])&&(i=(n?s(t,e,i):s(i))||i);return n&&i&&Oo(t,e,i),i};let P=class extends v{constructor(){super(...arguments),this.options=[],this.value="",this.name="",this.disabled=!1,this.width="100%",this.open=!1,this.activeIndex=-1,this.menuWidth="",this._handleOutsideClick=o=>{this.contains(o.target)||(this.open=!1,this.activeIndex=-1)}}connectedCallback(){super.connectedCallback(),document.addEventListener("click",this._handleOutsideClick)}disconnectedCallback(){document.removeEventListener("click",this._handleOutsideClick),super.disconnectedCallback()}toggle(){var o;if(!this.disabled){if(this.open=!this.open,this.activeIndex=this.open?this.options.findIndex(t=>t.value===this.value):-1,this.open&&this.width==="auto"){const t=(o=this.renderRoot)==null?void 0:o.querySelector("button");t&&(this.menuWidth=`${t.getBoundingClientRect().width}px`)}this.open&&this.updateComplete.then(()=>{this._focusActiveOption()})}}_focusActiveOption(){var t;const o=(t=this.renderRoot)==null?void 0:t.querySelector(`#option-${this.activeIndex}`);o==null||o.focus()}selectOption(o){this.value=o.value,this.dispatchEvent(new CustomEvent("change",{detail:{value:this.value,url:o.url}})),this.open=!1,this.activeIndex=-1}handleKeydown(o){if(this.disabled){o.preventDefault();return}if(!this.open){(o.key==="ArrowDown"||o.key==="ArrowUp")&&(o.preventDefault(),this.open=!0,this.activeIndex=this.options.findIndex(t=>t.value===this.value),this.updateComplete.then(()=>this._focusActiveOption()));return}switch(o.key){case"ArrowDown":o.preventDefault(),this.activeIndex=(this.activeIndex+1)%this.options.length,this.updateComplete.then(()=>this._focusActiveOption());break;case"ArrowUp":o.preventDefault(),this.activeIndex=(this.activeIndex-1+this.options.length)%this.options.length,this.updateComplete.then(()=>this._focusActiveOption());break;case"Home":o.preventDefault(),this.activeIndex=0,this.updateComplete.then(()=>this._focusActiveOption());break;case"End":o.preventDefault(),this.activeIndex=this.options.length-1,this.updateComplete.then(()=>this._focusActiveOption());break;case"Enter":o.preventDefault(),this.activeIndex>=0&&this.selectOption(this.options[this.activeIndex]);break;case"Escape":o.preventDefault(),this.open=!1,this.activeIndex=-1;break}}updated(o){this.options.length>0&&(this.options.some(e=>e.value===this.value)||(this.value=this.options[0].value))}render(){const o=G.checkstroke.replace("<svg",'<svg aria-hidden="true" focusable="false" part="svg"'),t=this.options.find(e=>e.value===this.value);return l`
|
|
1392
1392
|
<button
|
|
1393
1393
|
role="combobox"
|
|
1394
1394
|
aria-haspopup="listbox"
|
|
@@ -1436,7 +1436,7 @@
|
|
|
1436
1436
|
</ul>`:null}
|
|
1437
1437
|
|
|
1438
1438
|
<input type="hidden" name="${this.name}" .value="${this.value}" />
|
|
1439
|
-
`}};
|
|
1439
|
+
`}};P.styles=y`
|
|
1440
1440
|
:host {
|
|
1441
1441
|
display: inline-block;
|
|
1442
1442
|
position: relative;
|
|
@@ -1575,7 +1575,7 @@
|
|
|
1575
1575
|
input[type="hidden"] {
|
|
1576
1576
|
display: none;
|
|
1577
1577
|
}
|
|
1578
|
-
`;
|
|
1578
|
+
`;M([a({type:Array,reflect:!0})],P.prototype,"options",2);M([a({type:String,reflect:!0})],P.prototype,"value",2);M([a({type:String,reflect:!0})],P.prototype,"name",2);M([a({type:Boolean,reflect:!0})],P.prototype,"disabled",2);M([a({type:String,reflect:!0})],P.prototype,"width",2);M([W()],P.prototype,"open",2);M([W()],P.prototype,"activeIndex",2);M([W()],P.prototype,"menuWidth",2);P=M([w("o-dropdown")],P);var zo=Object.getOwnPropertyDescriptor,Do=(o,t,e,n)=>{for(var i=n>1?void 0:n?zo(t,e):t,r=o.length-1,s;r>=0;r--)(s=o[r])&&(i=s(i)||i);return i};let Pt=class extends v{render(){return l` <span class="dots"></span> `}};Pt.styles=y`
|
|
1579
1579
|
:host {
|
|
1580
1580
|
display: flex;
|
|
1581
1581
|
align-items: center;
|
|
@@ -1954,7 +1954,7 @@
|
|
|
1954
1954
|
overflow: hidden;
|
|
1955
1955
|
}
|
|
1956
1956
|
}
|
|
1957
|
-
`;Ut([a({type:Object,reflect:!0})],ht.prototype,"option",2);Ut([a({type:Number,reflect:!0})],ht.prototype,"imageSize",2);ht=Ut([w("o-reassurance")],ht);var Uo=Object.defineProperty,No=Object.getOwnPropertyDescriptor,
|
|
1957
|
+
`;Ut([a({type:Object,reflect:!0})],ht.prototype,"option",2);Ut([a({type:Number,reflect:!0})],ht.prototype,"imageSize",2);ht=Ut([w("o-reassurance")],ht);var Uo=Object.defineProperty,No=Object.getOwnPropertyDescriptor,T=(o,t,e,n)=>{for(var i=n>1?void 0:n?No(t,e):t,r=o.length-1,s;r>=0;r--)(s=o[r])&&(i=(n?s(t,e,i):s(i))||i);return n&&i&&Uo(t,e,i),i};const Vo=Ht(v);let A=class extends Vo{constructor(){super(...arguments),this.link="",this.name="",this.value="",this.text="",this.size="standard",this.selected=!1,this.fullwidth=!1,this.inactive=!1}handleClick(o){this.selected||(this.selected=!0);const t={selected:this.selected},e=new CustomEvent("selected",{detail:t,bubbles:!0,composed:!0,cancelable:!0});this.dispatchEvent(e),e.defaultPrevented&&o.preventDefault(),this.selected=t.selected}render(){const o=this.text;return this.link?l`
|
|
1958
1958
|
<a href="${this.link}" class="o-chip" tabindex="${this.inactive?"-1":"0"}" aria-hidden="${this.inactive?"true":"false"}">
|
|
1959
1959
|
${o?this.text:l`<slot></slot>`}
|
|
1960
1960
|
</a>
|
|
@@ -2052,7 +2052,7 @@
|
|
|
2052
2052
|
display: inline-flex;
|
|
2053
2053
|
align-items: center;
|
|
2054
2054
|
}
|
|
2055
|
-
`;
|
|
2055
|
+
`;T([a({type:String,reflect:!0})],A.prototype,"link",2);T([a({reflect:!0})],A.prototype,"name",2);T([a({reflect:!0})],A.prototype,"value",2);T([a({type:String})],A.prototype,"text",2);T([a({type:String,reflect:!0})],A.prototype,"size",2);T([a({type:Boolean,reflect:!0})],A.prototype,"selected",2);T([a({type:Boolean,reflect:!0})],A.prototype,"fullwidth",2);T([a({type:Boolean,reflect:!0})],A.prototype,"inactive",2);A=T([w("o-chip")],A);var qo=Object.defineProperty,Zo=Object.getOwnPropertyDescriptor,Nt=(o,t,e,n)=>{for(var i=n>1?void 0:n?Zo(t,e):t,r=o.length-1,s;r>=0;r--)(s=o[r])&&(i=(n?s(t,e,i):s(i))||i);return n&&i&&qo(t,e,i),i};let dt=class extends v{constructor(){super(),this.name="",this.value="",this.addEventListener("selected",this.onChipSelected)}onChipSelected(o){const t=o.target instanceof A?o.target:null;t!=null&&t.link||(this.name=(t==null?void 0:t.name)||"",this.value=(t==null?void 0:t.value)||"",this.querySelectorAll("o-chip").forEach(e=>{e!==t&&(e.selected=!1)}))}render(){return l`
|
|
2056
2056
|
<slot></slot>
|
|
2057
2057
|
`}};dt.styles=y`
|
|
2058
2058
|
:host {
|
|
@@ -2061,8 +2061,8 @@
|
|
|
2061
2061
|
flex-wrap: wrap;
|
|
2062
2062
|
gap: var(--spacing-s);
|
|
2063
2063
|
}
|
|
2064
|
-
`;Nt([a({reflect:!0})],dt.prototype,"name",2);Nt([a({reflect:!0})],dt.prototype,"value",2);dt=Nt([w("o-chipset")],dt);var Ko=Object.defineProperty,Wo=Object.getOwnPropertyDescriptor,
|
|
2065
|
-
<a role="button" tabindex="0" class="button" href=${this.
|
|
2064
|
+
`;Nt([a({reflect:!0})],dt.prototype,"name",2);Nt([a({reflect:!0})],dt.prototype,"value",2);dt=Nt([w("o-chipset")],dt);var Ko=Object.defineProperty,Wo=Object.getOwnPropertyDescriptor,D=(o,t,e,n)=>{for(var i=n>1?void 0:n?Wo(t,e):t,r=o.length-1,s;r>=0;r--)(s=o[r])&&(i=(n?s(t,e,i):s(i))||i);return n&&i&&Ko(t,e,i),i};const Go=Ht(v);let E=class extends Go{constructor(){super(...arguments),this.name="",this.value="",this.type="",this.text="",this.selected=!1,this.disabled=!1,this.fullwidth=!1,this.crossIconName="cross",this.strikethroughImgName="strikeDiagonal"}handleClick(o){if(o instanceof KeyboardEvent&&o.key!=="Enter"&&o.key!==" ")return;this.selected=!this.selected;const t={selected:this.selected},e=new CustomEvent("selected",{detail:t,bubbles:!0,composed:!0,cancelable:!0});this.dispatchEvent(e),e.defaultPrevented&&o.preventDefault(),this.selected=t.selected}crossIcon(){const o=G[this.crossIconName].replace("<svg",'<svg aria-hidden="true" focusable="false" part="svg"').replace(/stroke=[#"'a-z1-9]*/gi,"");return l`<span class="cross-icon">${I(o)}</span>`}strikeThroughImg(){const o=io[this.strikethroughImgName].replace("<svg",'<svg aria-hidden="true" focusable="false" part="strikethrough"').replace(/stroke=[#"'a-z1-9]*/gi,"");return I(o)}render(){const o=this.text;return l`${this.type==="link"?l`
|
|
2065
|
+
<a role="button" tabindex="0" class="button" href=${this.href} ?disabled=${this.disabled} @click=${this.handleClick} @keydown=${this.handleClick}
|
|
2066
2066
|
aria-label=${this.ariaLabel} aria-pressed=${this.selected}>
|
|
2067
2067
|
${o?l`
|
|
2068
2068
|
${this.text?l`<span class="text">${this.text}</span>`:d}
|
|
@@ -2081,7 +2081,7 @@
|
|
|
2081
2081
|
</button>
|
|
2082
2082
|
`}
|
|
2083
2083
|
${this.disabled?this.strikeThroughImg():d}
|
|
2084
|
-
`}};
|
|
2084
|
+
`}};E.styles=y`
|
|
2085
2085
|
:host {
|
|
2086
2086
|
cursor: pointer;
|
|
2087
2087
|
display: inline-flex;
|
|
@@ -2206,7 +2206,7 @@
|
|
|
2206
2206
|
stroke-linecap: round;
|
|
2207
2207
|
}
|
|
2208
2208
|
}
|
|
2209
|
-
`;
|
|
2209
|
+
`;D([a({reflect:!0})],E.prototype,"name",2);D([a({reflect:!0})],E.prototype,"value",2);D([a({type:String,reflect:!0})],E.prototype,"type",2);D([a({type:String,reflect:!0})],E.prototype,"href",2);D([a({type:String,reflect:!0,attribute:"data-href"})],E.prototype,"dataHref",2);D([a({type:String})],E.prototype,"text",2);D([a({type:Boolean,reflect:!0})],E.prototype,"selected",2);D([a({type:Boolean,reflect:!0})],E.prototype,"disabled",2);D([a({type:Boolean,reflect:!0})],E.prototype,"fullwidth",2);E=D([w("o-filter-chip")],E);var Xo=Object.defineProperty,j=(o,t,e,n)=>{for(var i=void 0,r=o.length-1,s;r>=0;r--)(s=o[r])&&(i=s(t,e,i)||i);return i&&Xo(t,e,i),i};const qt=class qt extends v{constructor(){super(...arguments),this.type="cart | chevron",this.titleProduct="",this.volume="",this.perLiter="",this.mainPrice="",this.imageUrl="https://placehold.co/56x70",this.altImage="",this.fullwidth=!1}onClick(){typeof this.onClickTile=="function"&&this.onClickTile()}get icons(){return this.type==="chevron"?l`
|
|
2210
2210
|
<o-icon-button
|
|
2211
2211
|
@click=${this.onClick}
|
|
2212
2212
|
icon="chevronRight"
|
|
@@ -2321,7 +2321,7 @@
|
|
|
2321
2321
|
letter-spacing: var(--letter-spacing-absolute);
|
|
2322
2322
|
line-height: var(--line-height-160);
|
|
2323
2323
|
}
|
|
2324
|
-
`;let
|
|
2324
|
+
`;let S=qt;j([a({type:String})],S.prototype,"type");j([a({type:String})],S.prototype,"titleProduct");j([a({type:String})],S.prototype,"volume");j([a({type:String})],S.prototype,"perLiter");j([a({type:String})],S.prototype,"mainPrice");j([a({type:String})],S.prototype,"imageUrl");j([a({type:String})],S.prototype,"altImage");j([a({type:Boolean})],S.prototype,"fullwidth");j([a({type:Function})],S.prototype,"onClickTile");customElements.define("mini-tile",S);var Jo=Object.defineProperty,Qo=Object.getOwnPropertyDescriptor,Vt=(o,t,e,n)=>{for(var i=n>1?void 0:n?Qo(t,e):t,r=o.length-1,s;r>=0;r--)(s=o[r])&&(i=(n?s(t,e,i):s(i))||i);return n&&i&&Jo(t,e,i),i};let pt=class extends v{constructor(){super(...arguments),this.variant="cart",this.text=""}render(){return l`
|
|
2325
2325
|
<span class="badge">
|
|
2326
2326
|
${this.text?this.text:l`<slot></slot>`}
|
|
2327
2327
|
</span>
|
package/index.mjs
CHANGED
|
@@ -296,8 +296,8 @@ const _e = (o, t) => {
|
|
|
296
296
|
const c = o[h];
|
|
297
297
|
let f, m, p = -1, $ = 0;
|
|
298
298
|
for (; $ < c.length && (s.lastIndex = $, m = s.exec(c), m !== null); ) $ = s.lastIndex, s === et ? m[1] === "!--" ? s = Jt : m[1] !== void 0 ? s = Qt : m[2] !== void 0 ? (ae.test(m[2]) && (i = RegExp("</" + m[2], "g")), s = V) : m[3] !== void 0 && (s = V) : s === V ? m[0] === ">" ? (s = i ?? et, p = -1) : m[1] === void 0 ? p = -2 : (p = s.lastIndex - m[2].length, f = m[1], s = m[3] === void 0 ? V : m[3] === '"' ? te : Yt) : s === te || s === Yt ? s = V : s === Jt || s === Qt ? s = et : (s = V, i = void 0);
|
|
299
|
-
const
|
|
300
|
-
r += s === et ? c + we : p >= 0 ? (n.push(f), c.slice(0, p) + re + c.slice(p) + F +
|
|
299
|
+
const L = s === V && o[h + 1].startsWith("/>") ? " " : "";
|
|
300
|
+
r += s === et ? c + we : p >= 0 ? (n.push(f), c.slice(0, p) + re + c.slice(p) + F + L) : c + F + (p === -2 ? h : L);
|
|
301
301
|
}
|
|
302
302
|
return [le(o, r + (o[e] || "<?>") + (t === 2 ? "</svg>" : t === 3 ? "</math>" : "")), n];
|
|
303
303
|
};
|
|
@@ -314,14 +314,14 @@ class at {
|
|
|
314
314
|
for (; (i = q.nextNode()) !== null && c.length < h; ) {
|
|
315
315
|
if (i.nodeType === 1) {
|
|
316
316
|
if (i.hasAttributes()) for (const p of i.getAttributeNames()) if (p.endsWith(re)) {
|
|
317
|
-
const $ = m[s++],
|
|
318
|
-
c.push({ type: 1, index: r, name: ft[2], strings:
|
|
317
|
+
const $ = m[s++], L = i.getAttribute(p).split(F), ft = /([.?@])?(.*)/.exec($);
|
|
318
|
+
c.push({ type: 1, index: r, name: ft[2], strings: L, ctor: ft[1] === "." ? ke : ft[1] === "?" ? Ae : ft[1] === "@" ? Ee : wt }), i.removeAttribute(p);
|
|
319
319
|
} else p.startsWith(F) && (c.push({ type: 6, index: r }), i.removeAttribute(p));
|
|
320
320
|
if (ae.test(i.tagName)) {
|
|
321
321
|
const p = i.textContent.split(F), $ = p.length - 1;
|
|
322
322
|
if ($ > 0) {
|
|
323
323
|
i.textContent = yt ? yt.emptyScript : "";
|
|
324
|
-
for (let
|
|
324
|
+
for (let L = 0; L < $; L++) i.append(p[L], rt()), q.nextNode(), c.push({ type: 2, index: ++r });
|
|
325
325
|
i.append(p[$], rt());
|
|
326
326
|
}
|
|
327
327
|
}
|
|
@@ -1555,7 +1555,7 @@ var po = Object.defineProperty, uo = Object.getOwnPropertyDescriptor, X = (o, t,
|
|
|
1555
1555
|
(s = o[r]) && (i = (n ? s(t, e, i) : s(i)) || i);
|
|
1556
1556
|
return n && i && po(t, e, i), i;
|
|
1557
1557
|
};
|
|
1558
|
-
let
|
|
1558
|
+
let H = class extends v {
|
|
1559
1559
|
constructor() {
|
|
1560
1560
|
super(...arguments), this.href = "", this.target = "", this.template = "standard", this.inverse = !1, this.endIcon = !1, this.reverseEndIcon = !1;
|
|
1561
1561
|
}
|
|
@@ -1593,7 +1593,7 @@ let D = class extends v {
|
|
|
1593
1593
|
`;
|
|
1594
1594
|
}
|
|
1595
1595
|
};
|
|
1596
|
-
|
|
1596
|
+
H.styles = y`
|
|
1597
1597
|
:host([template="standard"]) a {
|
|
1598
1598
|
color: var(--color-content-action-secondary);
|
|
1599
1599
|
font-size: var(--font-size-200);
|
|
@@ -1683,25 +1683,25 @@ D.styles = y`
|
|
|
1683
1683
|
`;
|
|
1684
1684
|
X([
|
|
1685
1685
|
a({ type: String })
|
|
1686
|
-
],
|
|
1686
|
+
], H.prototype, "href", 2);
|
|
1687
1687
|
X([
|
|
1688
1688
|
a({ type: String })
|
|
1689
|
-
],
|
|
1689
|
+
], H.prototype, "target", 2);
|
|
1690
1690
|
X([
|
|
1691
1691
|
a({ type: String, reflect: !0 })
|
|
1692
|
-
],
|
|
1692
|
+
], H.prototype, "template", 2);
|
|
1693
1693
|
X([
|
|
1694
1694
|
a({ type: Boolean, reflect: !0 })
|
|
1695
|
-
],
|
|
1695
|
+
], H.prototype, "inverse", 2);
|
|
1696
1696
|
X([
|
|
1697
1697
|
a({ type: Boolean, reflect: !0 })
|
|
1698
|
-
],
|
|
1698
|
+
], H.prototype, "endIcon", 2);
|
|
1699
1699
|
X([
|
|
1700
1700
|
a({ type: Boolean, reflect: !0 })
|
|
1701
|
-
],
|
|
1702
|
-
|
|
1701
|
+
], H.prototype, "reverseEndIcon", 2);
|
|
1702
|
+
H = X([
|
|
1703
1703
|
w("o-link")
|
|
1704
|
-
],
|
|
1704
|
+
], H);
|
|
1705
1705
|
var vo = Object.defineProperty, fo = Object.getOwnPropertyDescriptor, $t = (o, t, e, n) => {
|
|
1706
1706
|
for (var i = n > 1 ? void 0 : n ? fo(t, e) : t, r = o.length - 1, s; r >= 0; r--)
|
|
1707
1707
|
(s = o[r]) && (i = (n ? s(t, e, i) : s(i)) || i);
|
|
@@ -2007,12 +2007,12 @@ let u = class extends v {
|
|
|
2007
2007
|
document.body.style.overflow = "", document.body.removeAttribute("data-side-panel"), this.removeEventListener("keydown", this.handleKeyDown), super.disconnectedCallback(), this.removeEventListener("open-detail", this._onOpenDetail);
|
|
2008
2008
|
}
|
|
2009
2009
|
trapFocus(o) {
|
|
2010
|
-
var i, r, s, h, c, f, m, p, $,
|
|
2010
|
+
var i, r, s, h, c, f, m, p, $, L;
|
|
2011
2011
|
this.innerFocusedElement = document.activeElement || null, this.innerFocusedElement = ((r = (i = this.innerFocusedElement) == null ? void 0 : i.shadowRoot) == null ? void 0 : r.activeElement) || this.innerFocusedElement;
|
|
2012
2012
|
const t = this.getFocusableElements();
|
|
2013
2013
|
if (t.length === 0) return;
|
|
2014
2014
|
const e = t[0], n = t[t.length - 1];
|
|
2015
|
-
o.shiftKey && this.innerFocusedElement === e ? (o.preventDefault(), n.shadowRoot ? (c = (h = (s = n.shadowRoot) == null ? void 0 : s.querySelector(u.focusablesSelector)) == null ? void 0 : h.focus) == null || c.call(h) : (f = n.focus) == null || f.call(n)) : !o.shiftKey && this.innerFocusedElement === n && (o.preventDefault(), e.shadowRoot ? ($ = (p = (m = e.shadowRoot) == null ? void 0 : m.querySelector(u.focusablesSelector)) == null ? void 0 : p.focus) == null || $.call(p) : (
|
|
2015
|
+
o.shiftKey && this.innerFocusedElement === e ? (o.preventDefault(), n.shadowRoot ? (c = (h = (s = n.shadowRoot) == null ? void 0 : s.querySelector(u.focusablesSelector)) == null ? void 0 : h.focus) == null || c.call(h) : (f = n.focus) == null || f.call(n)) : !o.shiftKey && this.innerFocusedElement === n && (o.preventDefault(), e.shadowRoot ? ($ = (p = (m = e.shadowRoot) == null ? void 0 : m.querySelector(u.focusablesSelector)) == null ? void 0 : p.focus) == null || $.call(p) : (L = e.focus) == null || L.call(e));
|
|
2016
2016
|
}
|
|
2017
2017
|
getFocusableElements() {
|
|
2018
2018
|
const o = this.renderRoot.querySelector(".panel");
|
|
@@ -2836,12 +2836,12 @@ Rt([
|
|
|
2836
2836
|
ct = Rt([
|
|
2837
2837
|
w("o-tooltip")
|
|
2838
2838
|
], ct);
|
|
2839
|
-
var Oo = Object.defineProperty, Bo = Object.getOwnPropertyDescriptor,
|
|
2839
|
+
var Oo = Object.defineProperty, Bo = Object.getOwnPropertyDescriptor, M = (o, t, e, n) => {
|
|
2840
2840
|
for (var i = n > 1 ? void 0 : n ? Bo(t, e) : t, r = o.length - 1, s; r >= 0; r--)
|
|
2841
2841
|
(s = o[r]) && (i = (n ? s(t, e, i) : s(i)) || i);
|
|
2842
2842
|
return n && i && Oo(t, e, i), i;
|
|
2843
2843
|
};
|
|
2844
|
-
let
|
|
2844
|
+
let P = class extends v {
|
|
2845
2845
|
constructor() {
|
|
2846
2846
|
super(...arguments), this.options = [], this.value = "", this.name = "", this.disabled = !1, this.width = "100%", this.open = !1, this.activeIndex = -1, this.menuWidth = "", this._handleOutsideClick = (o) => {
|
|
2847
2847
|
this.contains(o.target) || (this.open = !1, this.activeIndex = -1);
|
|
@@ -2964,7 +2964,7 @@ let L = class extends v {
|
|
|
2964
2964
|
`;
|
|
2965
2965
|
}
|
|
2966
2966
|
};
|
|
2967
|
-
|
|
2967
|
+
P.styles = y`
|
|
2968
2968
|
:host {
|
|
2969
2969
|
display: inline-block;
|
|
2970
2970
|
position: relative;
|
|
@@ -3104,33 +3104,33 @@ L.styles = y`
|
|
|
3104
3104
|
display: none;
|
|
3105
3105
|
}
|
|
3106
3106
|
`;
|
|
3107
|
-
|
|
3107
|
+
M([
|
|
3108
3108
|
a({ type: Array, reflect: !0 })
|
|
3109
|
-
],
|
|
3110
|
-
|
|
3109
|
+
], P.prototype, "options", 2);
|
|
3110
|
+
M([
|
|
3111
3111
|
a({ type: String, reflect: !0 })
|
|
3112
|
-
],
|
|
3113
|
-
|
|
3112
|
+
], P.prototype, "value", 2);
|
|
3113
|
+
M([
|
|
3114
3114
|
a({ type: String, reflect: !0 })
|
|
3115
|
-
],
|
|
3116
|
-
|
|
3115
|
+
], P.prototype, "name", 2);
|
|
3116
|
+
M([
|
|
3117
3117
|
a({ type: Boolean, reflect: !0 })
|
|
3118
|
-
],
|
|
3119
|
-
|
|
3118
|
+
], P.prototype, "disabled", 2);
|
|
3119
|
+
M([
|
|
3120
3120
|
a({ type: String, reflect: !0 })
|
|
3121
|
-
],
|
|
3122
|
-
|
|
3121
|
+
], P.prototype, "width", 2);
|
|
3122
|
+
M([
|
|
3123
3123
|
W()
|
|
3124
|
-
],
|
|
3125
|
-
|
|
3124
|
+
], P.prototype, "open", 2);
|
|
3125
|
+
M([
|
|
3126
3126
|
W()
|
|
3127
|
-
],
|
|
3128
|
-
|
|
3127
|
+
], P.prototype, "activeIndex", 2);
|
|
3128
|
+
M([
|
|
3129
3129
|
W()
|
|
3130
|
-
],
|
|
3131
|
-
|
|
3130
|
+
], P.prototype, "menuWidth", 2);
|
|
3131
|
+
P = M([
|
|
3132
3132
|
w("o-dropdown")
|
|
3133
|
-
],
|
|
3133
|
+
], P);
|
|
3134
3134
|
var zo = Object.getOwnPropertyDescriptor, Do = (o, t, e, n) => {
|
|
3135
3135
|
for (var i = n > 1 ? void 0 : n ? zo(t, e) : t, r = o.length - 1, s; r >= 0; r--)
|
|
3136
3136
|
(s = o[r]) && (i = s(i) || i);
|
|
@@ -3689,7 +3689,7 @@ Ut([
|
|
|
3689
3689
|
ht = Ut([
|
|
3690
3690
|
w("o-reassurance")
|
|
3691
3691
|
], ht);
|
|
3692
|
-
var Uo = Object.defineProperty, No = Object.getOwnPropertyDescriptor,
|
|
3692
|
+
var Uo = Object.defineProperty, No = Object.getOwnPropertyDescriptor, T = (o, t, e, n) => {
|
|
3693
3693
|
for (var i = n > 1 ? void 0 : n ? No(t, e) : t, r = o.length - 1, s; r >= 0; r--)
|
|
3694
3694
|
(s = o[r]) && (i = (n ? s(t, e, i) : s(i)) || i);
|
|
3695
3695
|
return n && i && Uo(t, e, i), i;
|
|
@@ -3808,31 +3808,31 @@ A.styles = y`
|
|
|
3808
3808
|
align-items: center;
|
|
3809
3809
|
}
|
|
3810
3810
|
`;
|
|
3811
|
-
|
|
3811
|
+
T([
|
|
3812
3812
|
a({ type: String, reflect: !0 })
|
|
3813
3813
|
], A.prototype, "link", 2);
|
|
3814
|
-
|
|
3814
|
+
T([
|
|
3815
3815
|
a({ reflect: !0 })
|
|
3816
3816
|
], A.prototype, "name", 2);
|
|
3817
|
-
|
|
3817
|
+
T([
|
|
3818
3818
|
a({ reflect: !0 })
|
|
3819
3819
|
], A.prototype, "value", 2);
|
|
3820
|
-
|
|
3820
|
+
T([
|
|
3821
3821
|
a({ type: String })
|
|
3822
3822
|
], A.prototype, "text", 2);
|
|
3823
|
-
|
|
3823
|
+
T([
|
|
3824
3824
|
a({ type: String, reflect: !0 })
|
|
3825
3825
|
], A.prototype, "size", 2);
|
|
3826
|
-
|
|
3826
|
+
T([
|
|
3827
3827
|
a({ type: Boolean, reflect: !0 })
|
|
3828
3828
|
], A.prototype, "selected", 2);
|
|
3829
|
-
|
|
3829
|
+
T([
|
|
3830
3830
|
a({ type: Boolean, reflect: !0 })
|
|
3831
3831
|
], A.prototype, "fullwidth", 2);
|
|
3832
|
-
|
|
3832
|
+
T([
|
|
3833
3833
|
a({ type: Boolean, reflect: !0 })
|
|
3834
3834
|
], A.prototype, "inactive", 2);
|
|
3835
|
-
A =
|
|
3835
|
+
A = T([
|
|
3836
3836
|
w("o-chip")
|
|
3837
3837
|
], A);
|
|
3838
3838
|
var qo = Object.defineProperty, Zo = Object.getOwnPropertyDescriptor, Nt = (o, t, e, n) => {
|
|
@@ -3873,15 +3873,15 @@ Nt([
|
|
|
3873
3873
|
dt = Nt([
|
|
3874
3874
|
w("o-chipset")
|
|
3875
3875
|
], dt);
|
|
3876
|
-
var Ko = Object.defineProperty, Wo = Object.getOwnPropertyDescriptor,
|
|
3876
|
+
var Ko = Object.defineProperty, Wo = Object.getOwnPropertyDescriptor, D = (o, t, e, n) => {
|
|
3877
3877
|
for (var i = n > 1 ? void 0 : n ? Wo(t, e) : t, r = o.length - 1, s; r >= 0; r--)
|
|
3878
3878
|
(s = o[r]) && (i = (n ? s(t, e, i) : s(i)) || i);
|
|
3879
3879
|
return n && i && Ko(t, e, i), i;
|
|
3880
3880
|
};
|
|
3881
3881
|
const Go = Ht(v);
|
|
3882
|
-
let
|
|
3882
|
+
let E = class extends Go {
|
|
3883
3883
|
constructor() {
|
|
3884
|
-
super(...arguments), this.name = "", this.value = "", this.type = "", this.
|
|
3884
|
+
super(...arguments), this.name = "", this.value = "", this.type = "", this.text = "", this.selected = !1, this.disabled = !1, this.fullwidth = !1, this.crossIconName = "cross", this.strikethroughImgName = "strikeDiagonal";
|
|
3885
3885
|
}
|
|
3886
3886
|
handleClick(o) {
|
|
3887
3887
|
if (o instanceof KeyboardEvent && o.key !== "Enter" && o.key !== " ")
|
|
@@ -3907,7 +3907,7 @@ let P = class extends Go {
|
|
|
3907
3907
|
render() {
|
|
3908
3908
|
const o = this.text;
|
|
3909
3909
|
return l`${this.type === "link" ? l`
|
|
3910
|
-
<a role="button" tabindex="0" class="button" href=${this.
|
|
3910
|
+
<a role="button" tabindex="0" class="button" href=${this.href} ?disabled=${this.disabled} @click=${this.handleClick} @keydown=${this.handleClick}
|
|
3911
3911
|
aria-label=${this.ariaLabel} aria-pressed=${this.selected}>
|
|
3912
3912
|
${o ? l`
|
|
3913
3913
|
${this.text ? l`<span class="text">${this.text}</span>` : d}
|
|
@@ -3929,7 +3929,7 @@ let P = class extends Go {
|
|
|
3929
3929
|
`;
|
|
3930
3930
|
}
|
|
3931
3931
|
};
|
|
3932
|
-
|
|
3932
|
+
E.styles = y`
|
|
3933
3933
|
:host {
|
|
3934
3934
|
cursor: pointer;
|
|
3935
3935
|
display: inline-flex;
|
|
@@ -4055,33 +4055,36 @@ P.styles = y`
|
|
|
4055
4055
|
}
|
|
4056
4056
|
}
|
|
4057
4057
|
`;
|
|
4058
|
-
|
|
4058
|
+
D([
|
|
4059
4059
|
a({ reflect: !0 })
|
|
4060
|
-
],
|
|
4061
|
-
|
|
4060
|
+
], E.prototype, "name", 2);
|
|
4061
|
+
D([
|
|
4062
4062
|
a({ reflect: !0 })
|
|
4063
|
-
],
|
|
4064
|
-
|
|
4063
|
+
], E.prototype, "value", 2);
|
|
4064
|
+
D([
|
|
4065
4065
|
a({ type: String, reflect: !0 })
|
|
4066
|
-
],
|
|
4067
|
-
|
|
4066
|
+
], E.prototype, "type", 2);
|
|
4067
|
+
D([
|
|
4068
|
+
a({ type: String, reflect: !0 })
|
|
4069
|
+
], E.prototype, "href", 2);
|
|
4070
|
+
D([
|
|
4068
4071
|
a({ type: String, reflect: !0, attribute: "data-href" })
|
|
4069
|
-
],
|
|
4070
|
-
|
|
4072
|
+
], E.prototype, "dataHref", 2);
|
|
4073
|
+
D([
|
|
4071
4074
|
a({ type: String })
|
|
4072
|
-
],
|
|
4073
|
-
|
|
4075
|
+
], E.prototype, "text", 2);
|
|
4076
|
+
D([
|
|
4074
4077
|
a({ type: Boolean, reflect: !0 })
|
|
4075
|
-
],
|
|
4076
|
-
|
|
4078
|
+
], E.prototype, "selected", 2);
|
|
4079
|
+
D([
|
|
4077
4080
|
a({ type: Boolean, reflect: !0 })
|
|
4078
|
-
],
|
|
4079
|
-
|
|
4081
|
+
], E.prototype, "disabled", 2);
|
|
4082
|
+
D([
|
|
4080
4083
|
a({ type: Boolean, reflect: !0 })
|
|
4081
|
-
],
|
|
4082
|
-
|
|
4084
|
+
], E.prototype, "fullwidth", 2);
|
|
4085
|
+
E = D([
|
|
4083
4086
|
w("o-filter-chip")
|
|
4084
|
-
],
|
|
4087
|
+
], E);
|
|
4085
4088
|
var Xo = Object.defineProperty, j = (o, t, e, n) => {
|
|
4086
4089
|
for (var i = void 0, r = o.length - 1, s; r >= 0; r--)
|
|
4087
4090
|
(s = o[r]) && (i = s(t, e, i) || i);
|
|
@@ -4217,35 +4220,35 @@ qt.styles = y`
|
|
|
4217
4220
|
line-height: var(--line-height-160);
|
|
4218
4221
|
}
|
|
4219
4222
|
`;
|
|
4220
|
-
let
|
|
4223
|
+
let S = qt;
|
|
4221
4224
|
j([
|
|
4222
4225
|
a({ type: String })
|
|
4223
|
-
],
|
|
4226
|
+
], S.prototype, "type");
|
|
4224
4227
|
j([
|
|
4225
4228
|
a({ type: String })
|
|
4226
|
-
],
|
|
4229
|
+
], S.prototype, "titleProduct");
|
|
4227
4230
|
j([
|
|
4228
4231
|
a({ type: String })
|
|
4229
|
-
],
|
|
4232
|
+
], S.prototype, "volume");
|
|
4230
4233
|
j([
|
|
4231
4234
|
a({ type: String })
|
|
4232
|
-
],
|
|
4235
|
+
], S.prototype, "perLiter");
|
|
4233
4236
|
j([
|
|
4234
4237
|
a({ type: String })
|
|
4235
|
-
],
|
|
4238
|
+
], S.prototype, "mainPrice");
|
|
4236
4239
|
j([
|
|
4237
4240
|
a({ type: String })
|
|
4238
|
-
],
|
|
4241
|
+
], S.prototype, "imageUrl");
|
|
4239
4242
|
j([
|
|
4240
4243
|
a({ type: String })
|
|
4241
|
-
],
|
|
4244
|
+
], S.prototype, "altImage");
|
|
4242
4245
|
j([
|
|
4243
4246
|
a({ type: Boolean })
|
|
4244
|
-
],
|
|
4247
|
+
], S.prototype, "fullwidth");
|
|
4245
4248
|
j([
|
|
4246
4249
|
a({ type: Function })
|
|
4247
|
-
],
|
|
4248
|
-
customElements.define("mini-tile",
|
|
4250
|
+
], S.prototype, "onClickTile");
|
|
4251
|
+
customElements.define("mini-tile", S);
|
|
4249
4252
|
var Jo = Object.defineProperty, Qo = Object.getOwnPropertyDescriptor, Vt = (o, t, e, n) => {
|
|
4250
4253
|
for (var i = n > 1 ? void 0 : n ? Qo(t, e) : t, r = o.length - 1, s; r >= 0; r--)
|
|
4251
4254
|
(s = o[r]) && (i = (n ? s(t, e, i) : s(i)) || i);
|