@pontive/pontkit-core 1.20.0 → 1.20.1
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/catalog.json +1 -1
- package/custom-elements.json +1 -1
- package/dist/components/renderers/auth/form/_form.d.ts +7 -1
- package/dist/index.js +125 -125
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +306 -294
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -44,7 +44,7 @@
|
|
|
44
44
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
45
45
|
*/const co=globalThis,Ml=e=>e,ii=co.trustedTypes,Bl=ii?ii.createPolicy("lit-html",{createHTML:e=>e}):void 0,bp="$lit$",mr=`lit$${Math.random().toFixed(9).slice(2)}$`,yp="?"+mr,_u=`<${yp}>`,Br=document,uo=()=>Br.createComment(""),mo=e=>e===null||typeof e!="object"&&typeof e!="function",ja=Array.isArray,wu=e=>ja(e)||typeof(e==null?void 0:e[Symbol.iterator])=="function",as=`[
|
|
46
46
|
\f\r]`,eo=/<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g,Ul=/-->/g,ql=/>/g,Tr=RegExp(`>|${as}(?:([^\\s"'>=/]+)(${as}*=${as}*(?:[^
|
|
47
|
-
\f\r"'\`<>=]|("|')|))|$)`,"g"),jl=/'/g,zl=/"/g,_p=/^(?:script|style|textarea|title)$/i,wp=e=>(t,...r)=>({_$litType$:e,strings:t,values:r}),l=wp(1),U=wp(2),Gt=Symbol.for("lit-noChange"),h=Symbol.for("lit-nothing"),Vl=new WeakMap,kr=Br.createTreeWalker(Br,129);function $p(e,t){if(!ja(e)||!e.hasOwnProperty("raw"))throw Error("invalid template strings array");return Bl!==void 0?Bl.createHTML(t):t}const $u=(e,t)=>{const r=e.length-1,o=[];let n,i=t===2?"<svg>":t===3?"<math>":"",s=eo;for(let d=0;d<r;d++){const c=e[d];let u,v,
|
|
47
|
+
\f\r"'\`<>=]|("|')|))|$)`,"g"),jl=/'/g,zl=/"/g,_p=/^(?:script|style|textarea|title)$/i,wp=e=>(t,...r)=>({_$litType$:e,strings:t,values:r}),l=wp(1),U=wp(2),Gt=Symbol.for("lit-noChange"),h=Symbol.for("lit-nothing"),Vl=new WeakMap,kr=Br.createTreeWalker(Br,129);function $p(e,t){if(!ja(e)||!e.hasOwnProperty("raw"))throw Error("invalid template strings array");return Bl!==void 0?Bl.createHTML(t):t}const $u=(e,t)=>{const r=e.length-1,o=[];let n,i=t===2?"<svg>":t===3?"<math>":"",s=eo;for(let d=0;d<r;d++){const c=e[d];let u,v,y=-1,w=0;for(;w<c.length&&(s.lastIndex=w,v=s.exec(c),v!==null);)w=s.lastIndex,s===eo?v[1]==="!--"?s=Ul:v[1]!==void 0?s=ql:v[2]!==void 0?(_p.test(v[2])&&(n=RegExp("</"+v[2],"g")),s=Tr):v[3]!==void 0&&(s=Tr):s===Tr?v[0]===">"?(s=n??eo,y=-1):v[1]===void 0?y=-2:(y=s.lastIndex-v[2].length,u=v[1],s=v[3]===void 0?Tr:v[3]==='"'?zl:jl):s===zl||s===jl?s=Tr:s===Ul||s===ql?s=eo:(s=Tr,n=void 0);const b=s===Tr&&e[d+1].startsWith("/>")?" ":"";i+=s===eo?c+_u:y>=0?(o.push(u),c.slice(0,y)+bp+c.slice(y)+mr+b):c+mr+(y===-2?d:b)}return[$p(e,i+(e[r]||"<?>")+(t===2?"</svg>":t===3?"</math>":"")),o]};class go{constructor({strings:t,_$litType$:r},o){let n;this.parts=[];let i=0,s=0;const d=t.length-1,c=this.parts,[u,v]=$u(t,r);if(this.el=go.createElement(u,o),kr.currentNode=this.el.content,r===2||r===3){const y=this.el.content.firstChild;y.replaceWith(...y.childNodes)}for(;(n=kr.nextNode())!==null&&c.length<d;){if(n.nodeType===1){if(n.hasAttributes())for(const y of n.getAttributeNames())if(y.endsWith(bp)){const w=v[s++],b=n.getAttribute(y).split(mr),C=/([.?@])?(.*)/.exec(w);c.push({type:1,index:i,name:C[2],strings:b,ctor:C[1]==="."?Cu:C[1]==="?"?Eu:C[1]==="@"?Su:Li}),n.removeAttribute(y)}else y.startsWith(mr)&&(c.push({type:6,index:i}),n.removeAttribute(y));if(_p.test(n.tagName)){const y=n.textContent.split(mr),w=y.length-1;if(w>0){n.textContent=ii?ii.emptyScript:"";for(let b=0;b<w;b++)n.append(y[b],uo()),kr.nextNode(),c.push({type:2,index:++i});n.append(y[w],uo())}}}else if(n.nodeType===8)if(n.data===yp)c.push({type:2,index:i});else{let y=-1;for(;(y=n.data.indexOf(mr,y+1))!==-1;)c.push({type:7,index:i}),y+=mr.length-1}i++}}static createElement(t,r){const o=Br.createElement("template");return o.innerHTML=t,o}}function Sn(e,t,r=e,o){var s,d;if(t===Gt)return t;let n=o!==void 0?(s=r._$Co)==null?void 0:s[o]:r._$Cl;const i=mo(t)?void 0:t._$litDirective$;return(n==null?void 0:n.constructor)!==i&&((d=n==null?void 0:n._$AO)==null||d.call(n,!1),i===void 0?n=void 0:(n=new i(e),n._$AT(e,r,o)),o!==void 0?(r._$Co??(r._$Co=[]))[o]=n:r._$Cl=n),n!==void 0&&(t=Sn(e,n._$AS(e,t.values),n,o)),t}class Pu{constructor(t,r){this._$AV=[],this._$AN=void 0,this._$AD=t,this._$AM=r}get parentNode(){return this._$AM.parentNode}get _$AU(){return this._$AM._$AU}u(t){const{el:{content:r},parts:o}=this._$AD,n=((t==null?void 0:t.creationScope)??Br).importNode(r,!0);kr.currentNode=n;let i=kr.nextNode(),s=0,d=0,c=o[0];for(;c!==void 0;){if(s===c.index){let u;c.type===2?u=new Eo(i,i.nextSibling,this,t):c.type===1?u=new c.ctor(i,c.name,c.strings,this,t):c.type===6&&(u=new xu(i,this,t)),this._$AV.push(u),c=o[++d]}s!==(c==null?void 0:c.index)&&(i=kr.nextNode(),s++)}return kr.currentNode=Br,n}p(t){let r=0;for(const o of this._$AV)o!==void 0&&(o.strings!==void 0?(o._$AI(t,o,r),r+=o.strings.length-2):o._$AI(t[r])),r++}}class Eo{get _$AU(){var t;return((t=this._$AM)==null?void 0:t._$AU)??this._$Cv}constructor(t,r,o,n){this.type=2,this._$AH=h,this._$AN=void 0,this._$AA=t,this._$AB=r,this._$AM=o,this.options=n,this._$Cv=(n==null?void 0:n.isConnected)??!0}get parentNode(){let t=this._$AA.parentNode;const r=this._$AM;return r!==void 0&&(t==null?void 0:t.nodeType)===11&&(t=r.parentNode),t}get startNode(){return this._$AA}get endNode(){return this._$AB}_$AI(t,r=this){t=Sn(this,t,r),mo(t)?t===h||t==null||t===""?(this._$AH!==h&&this._$AR(),this._$AH=h):t!==this._$AH&&t!==Gt&&this._(t):t._$litType$!==void 0?this.$(t):t.nodeType!==void 0?this.T(t):wu(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!==h&&mo(this._$AH)?this._$AA.nextSibling.data=t:this.T(Br.createTextNode(t)),this._$AH=t}$(t){var i;const{values:r,_$litType$:o}=t,n=typeof o=="number"?this._$AC(t):(o.el===void 0&&(o.el=go.createElement($p(o.h,o.h[0]),this.options)),o);if(((i=this._$AH)==null?void 0:i._$AD)===n)this._$AH.p(r);else{const s=new Pu(n,this),d=s.u(this.options);s.p(r),this.T(d),this._$AH=s}}_$AC(t){let r=Vl.get(t.strings);return r===void 0&&Vl.set(t.strings,r=new go(t)),r}k(t){ja(this._$AH)||(this._$AH=[],this._$AR());const r=this._$AH;let o,n=0;for(const i of t)n===r.length?r.push(o=new Eo(this.O(uo()),this.O(uo()),this,this.options)):o=r[n],o._$AI(i),n++;n<r.length&&(this._$AR(o&&o._$AB.nextSibling,n),r.length=n)}_$AR(t=this._$AA.nextSibling,r){var o;for((o=this._$AP)==null?void 0:o.call(this,!1,!0,r);t!==this._$AB;){const n=Ml(t).nextSibling;Ml(t).remove(),t=n}}setConnected(t){var r;this._$AM===void 0&&(this._$Cv=t,(r=this._$AP)==null||r.call(this,t))}}class Li{get tagName(){return this.element.tagName}get _$AU(){return this._$AM._$AU}constructor(t,r,o,n,i){this.type=1,this._$AH=h,this._$AN=void 0,this.element=t,this.name=r,this._$AM=n,this.options=i,o.length>2||o[0]!==""||o[1]!==""?(this._$AH=Array(o.length-1).fill(new String),this.strings=o):this._$AH=h}_$AI(t,r=this,o,n){const i=this.strings;let s=!1;if(i===void 0)t=Sn(this,t,r,0),s=!mo(t)||t!==this._$AH&&t!==Gt,s&&(this._$AH=t);else{const d=t;let c,u;for(t=i[0],c=0;c<i.length-1;c++)u=Sn(this,d[o+c],r,c),u===Gt&&(u=this._$AH[c]),s||(s=!mo(u)||u!==this._$AH[c]),u===h?t=h:t!==h&&(t+=(u??"")+i[c+1]),this._$AH[c]=u}s&&!n&&this.j(t)}j(t){t===h?this.element.removeAttribute(this.name):this.element.setAttribute(this.name,t??"")}}class Cu extends Li{constructor(){super(...arguments),this.type=3}j(t){this.element[this.name]=t===h?void 0:t}}class Eu extends Li{constructor(){super(...arguments),this.type=4}j(t){this.element.toggleAttribute(this.name,!!t&&t!==h)}}class Su extends Li{constructor(t,r,o,n,i){super(t,r,o,n,i),this.type=5}_$AI(t,r=this){if((t=Sn(this,t,r,0)??h)===Gt)return;const o=this._$AH,n=t===h&&o!==h||t.capture!==o.capture||t.once!==o.once||t.passive!==o.passive,i=t!==h&&(o===h||n);n&&this.element.removeEventListener(this.name,this,o),i&&this.element.addEventListener(this.name,this,t),this._$AH=t}handleEvent(t){var r;typeof this._$AH=="function"?this._$AH.call(((r=this.options)==null?void 0:r.host)??this.element,t):this._$AH.handleEvent(t)}}class xu{constructor(t,r,o){this.element=t,this.type=6,this._$AN=void 0,this._$AM=r,this.options=o}get _$AU(){return this._$AM._$AU}_$AI(t){Sn(this,t)}}const ls=co.litHtmlPolyfillSupport;ls==null||ls(go,Eo),(co.litHtmlVersions??(co.litHtmlVersions=[])).push("3.3.3");const Ou=(e,t,r)=>{const o=(r==null?void 0:r.renderBefore)??t;let n=o._$litPart$;if(n===void 0){const i=(r==null?void 0:r.renderBefore)??null;o._$litPart$=n=new Eo(t.insertBefore(uo(),i),i,void 0,r??{})}return n._$AI(e),n};/**
|
|
48
48
|
* @license
|
|
49
49
|
* Copyright 2017 Google LLC
|
|
50
50
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
@@ -68,7 +68,7 @@
|
|
|
68
68
|
* @license
|
|
69
69
|
* Copyright 2017 Google LLC
|
|
70
70
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
71
|
-
*/function So(e,t){return(r,o,n)=>{const i=s=>{var d;return((d=s.renderRoot)==null?void 0:d.querySelector(e))??null};return Au(r,o,{get(){return i(this)}})}}var Tu=Object.defineProperty,Pp=(e,t,r,o)=>{for(var n=void 0,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(t,r,n)||n);return n&&Tu(t,r,n),n};let
|
|
71
|
+
*/function So(e,t){return(r,o,n)=>{const i=s=>{var d;return((d=s.renderRoot)==null?void 0:d.querySelector(e))??null};return Au(r,o,{get(){return i(this)}})}}var Tu=Object.defineProperty,Pp=(e,t,r,o)=>{for(var n=void 0,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(t,r,n)||n);return n&&Tu(t,r,n),n};let _=class extends f{constructor(){super(),this.customClass="",this.customStyle=""}getAttributesToExclude(){return[]}getAttributesToRemoveFromParent(){return["class"]}disconnectedCallback(){var t;super.disconnectedCallback(),(t=this.mutationObserver)==null||t.disconnect()}removeParentAttributes(){this.getAttributesToRemoveFromParent().forEach(r=>{r==="class"&&this.hasAttribute("class")&&(this.customClass=this.getAttribute("class")||""),r==="style"&&this.hasAttribute("style")&&(this.customStyle=this.getAttribute("style")||""),this.hasAttribute(r)&&this.removeAttribute(r)})}getFilteredAttributes(){const t={};return Array.from(this.attributes).forEach(r=>{this.getAttributesToExclude().includes(r.name)||(t[r.name]=r.value??"")}),t}isCustomPropertySet(t){const r=getComputedStyle(this).getPropertyValue(t).trim();return r!=="inherit"&&r.length>0}applyCustomClass(t,r,o=""){var i,s;let n="";t.some(d=>this.isCustomPropertySet(d))&&(n=o),n&&((s=(i=this.shadowRoot)==null?void 0:i.querySelector(r))==null||s.classList.add(n))}removeDuplicateContent(){var i;const t=document.createTreeWalker(this,NodeFilter.SHOW_TEXT|NodeFilter.SHOW_ELEMENT,{acceptNode:s=>{var d;return s.nodeType===Node.COMMENT_NODE||s.nodeType===Node.TEXT_NODE&&!((d=s.textContent)!=null&&d.trim())?NodeFilter.FILTER_REJECT:NodeFilter.FILTER_ACCEPT}}),r=new Map,o=[];let n;for(;n=t.nextNode();){let s;if(n.nodeType===Node.TEXT_NODE){const d=(i=n.textContent)==null?void 0:i.trim();if(!d)continue;s=`text:${d}`}else if(n instanceof HTMLElement){const d=Array.from(n.attributes).map(c=>`${c.name}=${c.value}`).sort().join(":");s=`element:${n.tagName}:${d}`}else continue;if(r.has(s)){const d=r.get(s);d&&d.parentNode&&o.push(d),r.set(s,n)}else r.set(s,n)}o.forEach(s=>{s.parentNode&&(console.log("Removing duplicate:",s),s.parentNode.removeChild(s))})}moveLightDomChildrenInto(t,r){let o;if(r&&r.length>0){o=r.filter(n=>this.contains(n)&&n!==t&&!n.contains(t));for(const n of o){const i=Array.from(t.childNodes).find(s=>{var d;return(d=s.isEqualNode)==null?void 0:d.call(s,n)});i&&t.removeChild(i)}}else o=Array.from(this.childNodes).filter(n=>n!==t&&!t.contains(n)&&!n.contains(t));for(const n of o)t.appendChild(n)}normalizeEnum(t,r,o){if(!t)return o;const n=Object.values(r),i=Object.keys(r);return n.includes(t)?t:i.includes(t)?r[t]:o}observeStyleAndClassSync(t){this.mutationObserver=new MutationObserver(r=>{for(const o of r)if(o.type==="attributes"){if(o.attributeName==="style"){const n=this.getAttribute("style")||"";n&&(this.customStyle=n,this.removeAttribute("style"))}if(o.attributeName==="class"){const n=this.getAttribute("class")||"";n&&(t.className=n,this.removeAttribute("class"))}}}),this.mutationObserver.observe(this,{attributes:!0,attributeFilter:["style","class"]})}};Pp([a({type:String,reflect:!0})],_.prototype,"customClass");Pp([a({type:String,reflect:!0})],_.prototype,"customStyle");function za(){const e=new Date().getTime();return"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,function(r){const o=(e+Math.random()*16)%16|0;return(r=="x"?o:o&3|8).toString(16)})}const Du=new CSSStyleSheet,Rl=class Rl extends f{constructor(){super()}connectedCallback(){super.connectedCallback(),this.shadowRoot?this.shadowRoot.adoptedStyleSheets=[...this.shadowRoot.adoptedStyleSheets,Du]:console.error("Shadow root not available in ShadowWrapper")}render(){return l`<div><slot></slot></div>`}};Rl.styles=vp`
|
|
72
72
|
:host {
|
|
73
73
|
display: block;
|
|
74
74
|
border: 2px solid black;
|
|
@@ -77,7 +77,7 @@
|
|
|
77
77
|
.wrapper {
|
|
78
78
|
display: block;
|
|
79
79
|
}
|
|
80
|
-
`;let zs=Rl;customElements.define("pont-shadow-wrapper",zs);function Cp(e){var t,r,o="";if(typeof e=="string"||typeof e=="number")o+=e;else if(typeof e=="object")if(Array.isArray(e)){var n=e.length;for(t=0;t<n;t++)e[t]&&(r=Cp(e[t]))&&(o&&(o+=" "),o+=r)}else for(r in e)e[r]&&(o&&(o+=" "),o+=r);return o}function Va(){for(var e,t,r=0,o="",n=arguments.length;r<n;r++)(e=arguments[r])&&(t=Cp(e))&&(o&&(o+=" "),o+=t);return o}const Ha="-",Lu=e=>{const t=ku(e),{conflictingClassGroups:r,conflictingClassGroupModifiers:o}=e;return{getClassGroupId:s=>{const d=s.split(Ha);return d[0]===""&&d.length!==1&&d.shift(),Ep(d,t)||Fu(s)},getConflictingClassGroupIds:(s,d)=>{const c=r[s]||[];return d&&o[s]?[...c,...o[s]]:c}}},Ep=(e,t)=>{var s;if(e.length===0)return t.classGroupId;const r=e[0],o=t.nextPart.get(r),n=o?Ep(e.slice(1),o):void 0;if(n)return n;if(t.validators.length===0)return;const i=e.join(Ha);return(s=t.validators.find(({validator:d})=>d(i)))==null?void 0:s.classGroupId},Hl=/^\[(.+)\]$/,Fu=e=>{if(Hl.test(e)){const t=Hl.exec(e)[1],r=t==null?void 0:t.substring(0,t.indexOf(":"));if(r)return"arbitrary.."+r}},ku=e=>{const{theme:t,prefix:r}=e,o={nextPart:new Map,validators:[]};return Mu(Object.entries(e.classGroups),r).forEach(([i,s])=>{Vs(s,o,i,t)}),o},Vs=(e,t,r,o)=>{e.forEach(n=>{if(typeof n=="string"){const i=n===""?t:Gl(t,n);i.classGroupId=r;return}if(typeof n=="function"){if(Nu(n)){Vs(n(o),t,r,o);return}t.validators.push({validator:n,classGroupId:r});return}Object.entries(n).forEach(([i,s])=>{Vs(s,Gl(t,i),r,o)})})},Gl=(e,t)=>{let r=e;return t.split(Ha).forEach(o=>{r.nextPart.has(o)||r.nextPart.set(o,{nextPart:new Map,validators:[]}),r=r.nextPart.get(o)}),r},Nu=e=>e.isThemeGetter,Mu=(e,t)=>t?e.map(([r,o])=>{const n=o.map(i=>typeof i=="string"?t+i:typeof i=="object"?Object.fromEntries(Object.entries(i).map(([s,d])=>[t+s,d])):i);return[r,n]}):e,Bu=e=>{if(e<1)return{get:()=>{},set:()=>{}};let t=0,r=new Map,o=new Map;const n=(i,s)=>{r.set(i,s),t++,t>e&&(t=0,o=r,r=new Map)};return{get(i){let s=r.get(i);if(s!==void 0)return s;if((s=o.get(i))!==void 0)return n(i,s),s},set(i,s){r.has(i)?r.set(i,s):n(i,s)}}},Sp="!",Uu=e=>{const{separator:t,experimentalParseClassName:r}=e,o=t.length===1,n=t[0],i=t.length,s=d=>{const c=[];let u=0,v=0,b;for(let O=0;O<d.length;O++){let S=d[O];if(u===0){if(S===n&&(o||d.slice(O,O+i)===t)){c.push(d.slice(v,O)),v=O+i;continue}if(S==="/"){b=O;continue}}S==="["?u++:S==="]"&&u--}const w=c.length===0?d:d.substring(v),_=w.startsWith(Sp),C=_?w.substring(1):w,P=b&&b>v?b-v:void 0;return{modifiers:c,hasImportantModifier:_,baseClassName:C,maybePostfixModifierPosition:P}};return r?d=>r({className:d,parseClassName:s}):s},qu=e=>{if(e.length<=1)return e;const t=[];let r=[];return e.forEach(o=>{o[0]==="["?(t.push(...r.sort(),o),r=[]):r.push(o)}),t.push(...r.sort()),t},ju=e=>({cache:Bu(e.cacheSize),parseClassName:Uu(e),...Lu(e)}),zu=/\s+/,Vu=(e,t)=>{const{parseClassName:r,getClassGroupId:o,getConflictingClassGroupIds:n}=t,i=[],s=e.trim().split(zu);let d="";for(let c=s.length-1;c>=0;c-=1){const u=s[c],{modifiers:v,hasImportantModifier:b,baseClassName:w,maybePostfixModifierPosition:_}=r(u);let C=!!_,P=o(C?w.substring(0,_):w);if(!P){if(!C){d=u+(d.length>0?" "+d:d);continue}if(P=o(w),!P){d=u+(d.length>0?" "+d:d);continue}C=!1}const O=qu(v).join(":"),S=b?O+Sp:O,D=S+P;if(i.includes(D))continue;i.push(D);const L=n(P,C);for(let I=0;I<L.length;++I){const Q=L[I];i.push(S+Q)}d=u+(d.length>0?" "+d:d)}return d};function Hu(){let e=0,t,r,o="";for(;e<arguments.length;)(t=arguments[e++])&&(r=xp(t))&&(o&&(o+=" "),o+=r);return o}const xp=e=>{if(typeof e=="string")return e;let t,r="";for(let o=0;o<e.length;o++)e[o]&&(t=xp(e[o]))&&(r&&(r+=" "),r+=t);return r};function Gu(e,...t){let r,o,n,i=s;function s(c){const u=t.reduce((v,b)=>b(v),e());return r=ju(u),o=r.cache.get,n=r.cache.set,i=d,d(c)}function d(c){const u=o(c);if(u)return u;const v=Vu(c,r);return n(c,v),v}return function(){return i(Hu.apply(null,arguments))}}const Z=e=>{const t=r=>r[e]||[];return t.isThemeGetter=!0,t},Op=/^\[(?:([a-z-]+):)?(.+)\]$/i,Ku=/^\d+\/\d+$/,Wu=new Set(["px","full","screen"]),Yu=/^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/,Qu=/\d+(%|px|r?em|[sdl]?v([hwib]|min|max)|pt|pc|in|cm|mm|cap|ch|ex|r?lh|cq(w|h|i|b|min|max))|\b(calc|min|max|clamp)\(.+\)|^0$/,Zu=/^(rgba?|hsla?|hwb|(ok)?(lab|lch)|color-mix)\(.+\)$/,Ju=/^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/,Xu=/^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/,Qe=e=>En(e)||Wu.has(e)||Ku.test(e),cr=e=>kn(e,"length",am),En=e=>!!e&&!Number.isNaN(Number(e)),cs=e=>kn(e,"number",En),ro=e=>!!e&&Number.isInteger(Number(e)),tm=e=>e.endsWith("%")&&En(e.slice(0,-1)),B=e=>Op.test(e),pr=e=>Yu.test(e),em=new Set(["length","size","percentage"]),rm=e=>kn(e,em,Rp),nm=e=>kn(e,"position",Rp),om=new Set(["image","url"]),im=e=>kn(e,om,dm),sm=e=>kn(e,"",lm),no=()=>!0,kn=(e,t,r)=>{const o=Op.exec(e);return o?o[1]?typeof t=="string"?o[1]===t:t.has(o[1]):r(o[2]):!1},am=e=>Qu.test(e)&&!Zu.test(e),Rp=()=>!1,lm=e=>Ju.test(e),dm=e=>Xu.test(e),cm=()=>{const e=Z("colors"),t=Z("spacing"),r=Z("blur"),o=Z("brightness"),n=Z("borderColor"),i=Z("borderRadius"),s=Z("borderSpacing"),d=Z("borderWidth"),c=Z("contrast"),u=Z("grayscale"),v=Z("hueRotate"),b=Z("invert"),w=Z("gap"),_=Z("gradientColorStops"),C=Z("gradientColorStopPositions"),P=Z("inset"),O=Z("margin"),S=Z("opacity"),D=Z("padding"),L=Z("saturate"),I=Z("scale"),Q=Z("sepia"),R=Z("skew"),A=Z("space"),T=Z("translate"),x=()=>["auto","contain","none"],N=()=>["auto","hidden","clip","visible","scroll"],F=()=>["auto",B,t],$=()=>[B,t],k=()=>["",Qe,cr],M=()=>["auto",En,B],ne=()=>["bottom","center","left","left-bottom","left-top","right","right-bottom","right-top","top"],ye=()=>["solid","dashed","dotted","double","none"],Ho=()=>["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","hard-light","soft-light","difference","exclusion","hue","saturation","color","luminosity"],un=()=>["start","end","center","between","around","evenly","stretch"],Ar=()=>["","0",B],mn=()=>["auto","avoid","all","avoid-page","page","left","right","column"],Tt=()=>[En,B];return{cacheSize:500,separator:":",theme:{colors:[no],spacing:[Qe,cr],blur:["none","",pr,B],brightness:Tt(),borderColor:[e],borderRadius:["none","","full",pr,B],borderSpacing:$(),borderWidth:k(),contrast:Tt(),grayscale:Ar(),hueRotate:Tt(),invert:Ar(),gap:$(),gradientColorStops:[e],gradientColorStopPositions:[tm,cr],inset:F(),margin:F(),opacity:Tt(),padding:$(),saturate:Tt(),scale:Tt(),sepia:Ar(),skew:Tt(),space:$(),translate:$()},classGroups:{aspect:[{aspect:["auto","square","video",B]}],container:["container"],columns:[{columns:[pr]}],"break-after":[{"break-after":mn()}],"break-before":[{"break-before":mn()}],"break-inside":[{"break-inside":["auto","avoid","avoid-page","avoid-column"]}],"box-decoration":[{"box-decoration":["slice","clone"]}],box:[{box:["border","content"]}],display:["block","inline-block","inline","flex","inline-flex","table","inline-table","table-caption","table-cell","table-column","table-column-group","table-footer-group","table-header-group","table-row-group","table-row","flow-root","grid","inline-grid","contents","list-item","hidden"],float:[{float:["right","left","none","start","end"]}],clear:[{clear:["left","right","both","none","start","end"]}],isolation:["isolate","isolation-auto"],"object-fit":[{object:["contain","cover","fill","none","scale-down"]}],"object-position":[{object:[...ne(),B]}],overflow:[{overflow:N()}],"overflow-x":[{"overflow-x":N()}],"overflow-y":[{"overflow-y":N()}],overscroll:[{overscroll:x()}],"overscroll-x":[{"overscroll-x":x()}],"overscroll-y":[{"overscroll-y":x()}],position:["static","fixed","absolute","relative","sticky"],inset:[{inset:[P]}],"inset-x":[{"inset-x":[P]}],"inset-y":[{"inset-y":[P]}],start:[{start:[P]}],end:[{end:[P]}],top:[{top:[P]}],right:[{right:[P]}],bottom:[{bottom:[P]}],left:[{left:[P]}],visibility:["visible","invisible","collapse"],z:[{z:["auto",ro,B]}],basis:[{basis:F()}],"flex-direction":[{flex:["row","row-reverse","col","col-reverse"]}],"flex-wrap":[{flex:["wrap","wrap-reverse","nowrap"]}],flex:[{flex:["1","auto","initial","none",B]}],grow:[{grow:Ar()}],shrink:[{shrink:Ar()}],order:[{order:["first","last","none",ro,B]}],"grid-cols":[{"grid-cols":[no]}],"col-start-end":[{col:["auto",{span:["full",ro,B]},B]}],"col-start":[{"col-start":M()}],"col-end":[{"col-end":M()}],"grid-rows":[{"grid-rows":[no]}],"row-start-end":[{row:["auto",{span:[ro,B]},B]}],"row-start":[{"row-start":M()}],"row-end":[{"row-end":M()}],"grid-flow":[{"grid-flow":["row","col","dense","row-dense","col-dense"]}],"auto-cols":[{"auto-cols":["auto","min","max","fr",B]}],"auto-rows":[{"auto-rows":["auto","min","max","fr",B]}],gap:[{gap:[w]}],"gap-x":[{"gap-x":[w]}],"gap-y":[{"gap-y":[w]}],"justify-content":[{justify:["normal",...un()]}],"justify-items":[{"justify-items":["start","end","center","stretch"]}],"justify-self":[{"justify-self":["auto","start","end","center","stretch"]}],"align-content":[{content:["normal",...un(),"baseline"]}],"align-items":[{items:["start","end","center","baseline","stretch"]}],"align-self":[{self:["auto","start","end","center","stretch","baseline"]}],"place-content":[{"place-content":[...un(),"baseline"]}],"place-items":[{"place-items":["start","end","center","baseline","stretch"]}],"place-self":[{"place-self":["auto","start","end","center","stretch"]}],p:[{p:[D]}],px:[{px:[D]}],py:[{py:[D]}],ps:[{ps:[D]}],pe:[{pe:[D]}],pt:[{pt:[D]}],pr:[{pr:[D]}],pb:[{pb:[D]}],pl:[{pl:[D]}],m:[{m:[O]}],mx:[{mx:[O]}],my:[{my:[O]}],ms:[{ms:[O]}],me:[{me:[O]}],mt:[{mt:[O]}],mr:[{mr:[O]}],mb:[{mb:[O]}],ml:[{ml:[O]}],"space-x":[{"space-x":[A]}],"space-x-reverse":["space-x-reverse"],"space-y":[{"space-y":[A]}],"space-y-reverse":["space-y-reverse"],w:[{w:["auto","min","max","fit","svw","lvw","dvw",B,t]}],"min-w":[{"min-w":[B,t,"min","max","fit"]}],"max-w":[{"max-w":[B,t,"none","full","min","max","fit","prose",{screen:[pr]},pr]}],h:[{h:[B,t,"auto","min","max","fit","svh","lvh","dvh"]}],"min-h":[{"min-h":[B,t,"min","max","fit","svh","lvh","dvh"]}],"max-h":[{"max-h":[B,t,"min","max","fit","svh","lvh","dvh"]}],size:[{size:[B,t,"auto","min","max","fit"]}],"font-size":[{text:["base",pr,cr]}],"font-smoothing":["antialiased","subpixel-antialiased"],"font-style":["italic","not-italic"],"font-weight":[{font:["thin","extralight","light","normal","medium","semibold","bold","extrabold","black",cs]}],"font-family":[{font:[no]}],"fvn-normal":["normal-nums"],"fvn-ordinal":["ordinal"],"fvn-slashed-zero":["slashed-zero"],"fvn-figure":["lining-nums","oldstyle-nums"],"fvn-spacing":["proportional-nums","tabular-nums"],"fvn-fraction":["diagonal-fractions","stacked-fractions"],tracking:[{tracking:["tighter","tight","normal","wide","wider","widest",B]}],"line-clamp":[{"line-clamp":["none",En,cs]}],leading:[{leading:["none","tight","snug","normal","relaxed","loose",Qe,B]}],"list-image":[{"list-image":["none",B]}],"list-style-type":[{list:["none","disc","decimal",B]}],"list-style-position":[{list:["inside","outside"]}],"placeholder-color":[{placeholder:[e]}],"placeholder-opacity":[{"placeholder-opacity":[S]}],"text-alignment":[{text:["left","center","right","justify","start","end"]}],"text-color":[{text:[e]}],"text-opacity":[{"text-opacity":[S]}],"text-decoration":["underline","overline","line-through","no-underline"],"text-decoration-style":[{decoration:[...ye(),"wavy"]}],"text-decoration-thickness":[{decoration:["auto","from-font",Qe,cr]}],"underline-offset":[{"underline-offset":["auto",Qe,B]}],"text-decoration-color":[{decoration:[e]}],"text-transform":["uppercase","lowercase","capitalize","normal-case"],"text-overflow":["truncate","text-ellipsis","text-clip"],"text-wrap":[{text:["wrap","nowrap","balance","pretty"]}],indent:[{indent:$()}],"vertical-align":[{align:["baseline","top","middle","bottom","text-top","text-bottom","sub","super",B]}],whitespace:[{whitespace:["normal","nowrap","pre","pre-line","pre-wrap","break-spaces"]}],break:[{break:["normal","words","all","keep"]}],hyphens:[{hyphens:["none","manual","auto"]}],content:[{content:["none",B]}],"bg-attachment":[{bg:["fixed","local","scroll"]}],"bg-clip":[{"bg-clip":["border","padding","content","text"]}],"bg-opacity":[{"bg-opacity":[S]}],"bg-origin":[{"bg-origin":["border","padding","content"]}],"bg-position":[{bg:[...ne(),nm]}],"bg-repeat":[{bg:["no-repeat",{repeat:["","x","y","round","space"]}]}],"bg-size":[{bg:["auto","cover","contain",rm]}],"bg-image":[{bg:["none",{"gradient-to":["t","tr","r","br","b","bl","l","tl"]},im]}],"bg-color":[{bg:[e]}],"gradient-from-pos":[{from:[C]}],"gradient-via-pos":[{via:[C]}],"gradient-to-pos":[{to:[C]}],"gradient-from":[{from:[_]}],"gradient-via":[{via:[_]}],"gradient-to":[{to:[_]}],rounded:[{rounded:[i]}],"rounded-s":[{"rounded-s":[i]}],"rounded-e":[{"rounded-e":[i]}],"rounded-t":[{"rounded-t":[i]}],"rounded-r":[{"rounded-r":[i]}],"rounded-b":[{"rounded-b":[i]}],"rounded-l":[{"rounded-l":[i]}],"rounded-ss":[{"rounded-ss":[i]}],"rounded-se":[{"rounded-se":[i]}],"rounded-ee":[{"rounded-ee":[i]}],"rounded-es":[{"rounded-es":[i]}],"rounded-tl":[{"rounded-tl":[i]}],"rounded-tr":[{"rounded-tr":[i]}],"rounded-br":[{"rounded-br":[i]}],"rounded-bl":[{"rounded-bl":[i]}],"border-w":[{border:[d]}],"border-w-x":[{"border-x":[d]}],"border-w-y":[{"border-y":[d]}],"border-w-s":[{"border-s":[d]}],"border-w-e":[{"border-e":[d]}],"border-w-t":[{"border-t":[d]}],"border-w-r":[{"border-r":[d]}],"border-w-b":[{"border-b":[d]}],"border-w-l":[{"border-l":[d]}],"border-opacity":[{"border-opacity":[S]}],"border-style":[{border:[...ye(),"hidden"]}],"divide-x":[{"divide-x":[d]}],"divide-x-reverse":["divide-x-reverse"],"divide-y":[{"divide-y":[d]}],"divide-y-reverse":["divide-y-reverse"],"divide-opacity":[{"divide-opacity":[S]}],"divide-style":[{divide:ye()}],"border-color":[{border:[n]}],"border-color-x":[{"border-x":[n]}],"border-color-y":[{"border-y":[n]}],"border-color-s":[{"border-s":[n]}],"border-color-e":[{"border-e":[n]}],"border-color-t":[{"border-t":[n]}],"border-color-r":[{"border-r":[n]}],"border-color-b":[{"border-b":[n]}],"border-color-l":[{"border-l":[n]}],"divide-color":[{divide:[n]}],"outline-style":[{outline:["",...ye()]}],"outline-offset":[{"outline-offset":[Qe,B]}],"outline-w":[{outline:[Qe,cr]}],"outline-color":[{outline:[e]}],"ring-w":[{ring:k()}],"ring-w-inset":["ring-inset"],"ring-color":[{ring:[e]}],"ring-opacity":[{"ring-opacity":[S]}],"ring-offset-w":[{"ring-offset":[Qe,cr]}],"ring-offset-color":[{"ring-offset":[e]}],shadow:[{shadow:["","inner","none",pr,sm]}],"shadow-color":[{shadow:[no]}],opacity:[{opacity:[S]}],"mix-blend":[{"mix-blend":[...Ho(),"plus-lighter","plus-darker"]}],"bg-blend":[{"bg-blend":Ho()}],filter:[{filter:["","none"]}],blur:[{blur:[r]}],brightness:[{brightness:[o]}],contrast:[{contrast:[c]}],"drop-shadow":[{"drop-shadow":["","none",pr,B]}],grayscale:[{grayscale:[u]}],"hue-rotate":[{"hue-rotate":[v]}],invert:[{invert:[b]}],saturate:[{saturate:[L]}],sepia:[{sepia:[Q]}],"backdrop-filter":[{"backdrop-filter":["","none"]}],"backdrop-blur":[{"backdrop-blur":[r]}],"backdrop-brightness":[{"backdrop-brightness":[o]}],"backdrop-contrast":[{"backdrop-contrast":[c]}],"backdrop-grayscale":[{"backdrop-grayscale":[u]}],"backdrop-hue-rotate":[{"backdrop-hue-rotate":[v]}],"backdrop-invert":[{"backdrop-invert":[b]}],"backdrop-opacity":[{"backdrop-opacity":[S]}],"backdrop-saturate":[{"backdrop-saturate":[L]}],"backdrop-sepia":[{"backdrop-sepia":[Q]}],"border-collapse":[{border:["collapse","separate"]}],"border-spacing":[{"border-spacing":[s]}],"border-spacing-x":[{"border-spacing-x":[s]}],"border-spacing-y":[{"border-spacing-y":[s]}],"table-layout":[{table:["auto","fixed"]}],caption:[{caption:["top","bottom"]}],transition:[{transition:["none","all","","colors","opacity","shadow","transform",B]}],duration:[{duration:Tt()}],ease:[{ease:["linear","in","out","in-out",B]}],delay:[{delay:Tt()}],animate:[{animate:["none","spin","ping","pulse","bounce",B]}],transform:[{transform:["","gpu","none"]}],scale:[{scale:[I]}],"scale-x":[{"scale-x":[I]}],"scale-y":[{"scale-y":[I]}],rotate:[{rotate:[ro,B]}],"translate-x":[{"translate-x":[T]}],"translate-y":[{"translate-y":[T]}],"skew-x":[{"skew-x":[R]}],"skew-y":[{"skew-y":[R]}],"transform-origin":[{origin:["center","top","top-right","right","bottom-right","bottom","bottom-left","left","top-left",B]}],accent:[{accent:["auto",e]}],appearance:[{appearance:["none","auto"]}],cursor:[{cursor:["auto","default","pointer","wait","text","move","help","not-allowed","none","context-menu","progress","cell","crosshair","vertical-text","alias","copy","no-drop","grab","grabbing","all-scroll","col-resize","row-resize","n-resize","e-resize","s-resize","w-resize","ne-resize","nw-resize","se-resize","sw-resize","ew-resize","ns-resize","nesw-resize","nwse-resize","zoom-in","zoom-out",B]}],"caret-color":[{caret:[e]}],"pointer-events":[{"pointer-events":["none","auto"]}],resize:[{resize:["none","y","x",""]}],"scroll-behavior":[{scroll:["auto","smooth"]}],"scroll-m":[{"scroll-m":$()}],"scroll-mx":[{"scroll-mx":$()}],"scroll-my":[{"scroll-my":$()}],"scroll-ms":[{"scroll-ms":$()}],"scroll-me":[{"scroll-me":$()}],"scroll-mt":[{"scroll-mt":$()}],"scroll-mr":[{"scroll-mr":$()}],"scroll-mb":[{"scroll-mb":$()}],"scroll-ml":[{"scroll-ml":$()}],"scroll-p":[{"scroll-p":$()}],"scroll-px":[{"scroll-px":$()}],"scroll-py":[{"scroll-py":$()}],"scroll-ps":[{"scroll-ps":$()}],"scroll-pe":[{"scroll-pe":$()}],"scroll-pt":[{"scroll-pt":$()}],"scroll-pr":[{"scroll-pr":$()}],"scroll-pb":[{"scroll-pb":$()}],"scroll-pl":[{"scroll-pl":$()}],"snap-align":[{snap:["start","end","center","align-none"]}],"snap-stop":[{snap:["normal","always"]}],"snap-type":[{snap:["none","x","y","both"]}],"snap-strictness":[{snap:["mandatory","proximity"]}],touch:[{touch:["auto","none","manipulation"]}],"touch-x":[{"touch-pan":["x","left","right"]}],"touch-y":[{"touch-pan":["y","up","down"]}],"touch-pz":["touch-pinch-zoom"],select:[{select:["none","text","all","auto"]}],"will-change":[{"will-change":["auto","scroll","contents","transform",B]}],fill:[{fill:[e,"none"]}],"stroke-w":[{stroke:[Qe,cr,cs]}],stroke:[{stroke:[e,"none"]}],sr:["sr-only","not-sr-only"],"forced-color-adjust":[{"forced-color-adjust":["auto","none"]}]},conflictingClassGroups:{overflow:["overflow-x","overflow-y"],overscroll:["overscroll-x","overscroll-y"],inset:["inset-x","inset-y","start","end","top","right","bottom","left"],"inset-x":["right","left"],"inset-y":["top","bottom"],flex:["basis","grow","shrink"],gap:["gap-x","gap-y"],p:["px","py","ps","pe","pt","pr","pb","pl"],px:["pr","pl"],py:["pt","pb"],m:["mx","my","ms","me","mt","mr","mb","ml"],mx:["mr","ml"],my:["mt","mb"],size:["w","h"],"font-size":["leading"],"fvn-normal":["fvn-ordinal","fvn-slashed-zero","fvn-figure","fvn-spacing","fvn-fraction"],"fvn-ordinal":["fvn-normal"],"fvn-slashed-zero":["fvn-normal"],"fvn-figure":["fvn-normal"],"fvn-spacing":["fvn-normal"],"fvn-fraction":["fvn-normal"],"line-clamp":["display","overflow"],rounded:["rounded-s","rounded-e","rounded-t","rounded-r","rounded-b","rounded-l","rounded-ss","rounded-se","rounded-ee","rounded-es","rounded-tl","rounded-tr","rounded-br","rounded-bl"],"rounded-s":["rounded-ss","rounded-es"],"rounded-e":["rounded-se","rounded-ee"],"rounded-t":["rounded-tl","rounded-tr"],"rounded-r":["rounded-tr","rounded-br"],"rounded-b":["rounded-br","rounded-bl"],"rounded-l":["rounded-tl","rounded-bl"],"border-spacing":["border-spacing-x","border-spacing-y"],"border-w":["border-w-s","border-w-e","border-w-t","border-w-r","border-w-b","border-w-l"],"border-w-x":["border-w-r","border-w-l"],"border-w-y":["border-w-t","border-w-b"],"border-color":["border-color-s","border-color-e","border-color-t","border-color-r","border-color-b","border-color-l"],"border-color-x":["border-color-r","border-color-l"],"border-color-y":["border-color-t","border-color-b"],"scroll-m":["scroll-mx","scroll-my","scroll-ms","scroll-me","scroll-mt","scroll-mr","scroll-mb","scroll-ml"],"scroll-mx":["scroll-mr","scroll-ml"],"scroll-my":["scroll-mt","scroll-mb"],"scroll-p":["scroll-px","scroll-py","scroll-ps","scroll-pe","scroll-pt","scroll-pr","scroll-pb","scroll-pl"],"scroll-px":["scroll-pr","scroll-pl"],"scroll-py":["scroll-pt","scroll-pb"],touch:["touch-x","touch-y","touch-pz"],"touch-x":["touch"],"touch-y":["touch"],"touch-pz":["touch"]},conflictingClassGroupModifiers:{"font-size":["leading"]}}},Ip=Gu(cm);function m(...e){return Ip(Va(e))}/**
|
|
80
|
+
`;let zs=Rl;customElements.define("pont-shadow-wrapper",zs);function Cp(e){var t,r,o="";if(typeof e=="string"||typeof e=="number")o+=e;else if(typeof e=="object")if(Array.isArray(e)){var n=e.length;for(t=0;t<n;t++)e[t]&&(r=Cp(e[t]))&&(o&&(o+=" "),o+=r)}else for(r in e)e[r]&&(o&&(o+=" "),o+=r);return o}function Va(){for(var e,t,r=0,o="",n=arguments.length;r<n;r++)(e=arguments[r])&&(t=Cp(e))&&(o&&(o+=" "),o+=t);return o}const Ha="-",Lu=e=>{const t=ku(e),{conflictingClassGroups:r,conflictingClassGroupModifiers:o}=e;return{getClassGroupId:s=>{const d=s.split(Ha);return d[0]===""&&d.length!==1&&d.shift(),Ep(d,t)||Fu(s)},getConflictingClassGroupIds:(s,d)=>{const c=r[s]||[];return d&&o[s]?[...c,...o[s]]:c}}},Ep=(e,t)=>{var s;if(e.length===0)return t.classGroupId;const r=e[0],o=t.nextPart.get(r),n=o?Ep(e.slice(1),o):void 0;if(n)return n;if(t.validators.length===0)return;const i=e.join(Ha);return(s=t.validators.find(({validator:d})=>d(i)))==null?void 0:s.classGroupId},Hl=/^\[(.+)\]$/,Fu=e=>{if(Hl.test(e)){const t=Hl.exec(e)[1],r=t==null?void 0:t.substring(0,t.indexOf(":"));if(r)return"arbitrary.."+r}},ku=e=>{const{theme:t,prefix:r}=e,o={nextPart:new Map,validators:[]};return Mu(Object.entries(e.classGroups),r).forEach(([i,s])=>{Vs(s,o,i,t)}),o},Vs=(e,t,r,o)=>{e.forEach(n=>{if(typeof n=="string"){const i=n===""?t:Gl(t,n);i.classGroupId=r;return}if(typeof n=="function"){if(Nu(n)){Vs(n(o),t,r,o);return}t.validators.push({validator:n,classGroupId:r});return}Object.entries(n).forEach(([i,s])=>{Vs(s,Gl(t,i),r,o)})})},Gl=(e,t)=>{let r=e;return t.split(Ha).forEach(o=>{r.nextPart.has(o)||r.nextPart.set(o,{nextPart:new Map,validators:[]}),r=r.nextPart.get(o)}),r},Nu=e=>e.isThemeGetter,Mu=(e,t)=>t?e.map(([r,o])=>{const n=o.map(i=>typeof i=="string"?t+i:typeof i=="object"?Object.fromEntries(Object.entries(i).map(([s,d])=>[t+s,d])):i);return[r,n]}):e,Bu=e=>{if(e<1)return{get:()=>{},set:()=>{}};let t=0,r=new Map,o=new Map;const n=(i,s)=>{r.set(i,s),t++,t>e&&(t=0,o=r,r=new Map)};return{get(i){let s=r.get(i);if(s!==void 0)return s;if((s=o.get(i))!==void 0)return n(i,s),s},set(i,s){r.has(i)?r.set(i,s):n(i,s)}}},Sp="!",Uu=e=>{const{separator:t,experimentalParseClassName:r}=e,o=t.length===1,n=t[0],i=t.length,s=d=>{const c=[];let u=0,v=0,y;for(let O=0;O<d.length;O++){let S=d[O];if(u===0){if(S===n&&(o||d.slice(O,O+i)===t)){c.push(d.slice(v,O)),v=O+i;continue}if(S==="/"){y=O;continue}}S==="["?u++:S==="]"&&u--}const w=c.length===0?d:d.substring(v),b=w.startsWith(Sp),C=b?w.substring(1):w,P=y&&y>v?y-v:void 0;return{modifiers:c,hasImportantModifier:b,baseClassName:C,maybePostfixModifierPosition:P}};return r?d=>r({className:d,parseClassName:s}):s},qu=e=>{if(e.length<=1)return e;const t=[];let r=[];return e.forEach(o=>{o[0]==="["?(t.push(...r.sort(),o),r=[]):r.push(o)}),t.push(...r.sort()),t},ju=e=>({cache:Bu(e.cacheSize),parseClassName:Uu(e),...Lu(e)}),zu=/\s+/,Vu=(e,t)=>{const{parseClassName:r,getClassGroupId:o,getConflictingClassGroupIds:n}=t,i=[],s=e.trim().split(zu);let d="";for(let c=s.length-1;c>=0;c-=1){const u=s[c],{modifiers:v,hasImportantModifier:y,baseClassName:w,maybePostfixModifierPosition:b}=r(u);let C=!!b,P=o(C?w.substring(0,b):w);if(!P){if(!C){d=u+(d.length>0?" "+d:d);continue}if(P=o(w),!P){d=u+(d.length>0?" "+d:d);continue}C=!1}const O=qu(v).join(":"),S=y?O+Sp:O,D=S+P;if(i.includes(D))continue;i.push(D);const L=n(P,C);for(let I=0;I<L.length;++I){const Q=L[I];i.push(S+Q)}d=u+(d.length>0?" "+d:d)}return d};function Hu(){let e=0,t,r,o="";for(;e<arguments.length;)(t=arguments[e++])&&(r=xp(t))&&(o&&(o+=" "),o+=r);return o}const xp=e=>{if(typeof e=="string")return e;let t,r="";for(let o=0;o<e.length;o++)e[o]&&(t=xp(e[o]))&&(r&&(r+=" "),r+=t);return r};function Gu(e,...t){let r,o,n,i=s;function s(c){const u=t.reduce((v,y)=>y(v),e());return r=ju(u),o=r.cache.get,n=r.cache.set,i=d,d(c)}function d(c){const u=o(c);if(u)return u;const v=Vu(c,r);return n(c,v),v}return function(){return i(Hu.apply(null,arguments))}}const Z=e=>{const t=r=>r[e]||[];return t.isThemeGetter=!0,t},Op=/^\[(?:([a-z-]+):)?(.+)\]$/i,Ku=/^\d+\/\d+$/,Wu=new Set(["px","full","screen"]),Yu=/^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/,Qu=/\d+(%|px|r?em|[sdl]?v([hwib]|min|max)|pt|pc|in|cm|mm|cap|ch|ex|r?lh|cq(w|h|i|b|min|max))|\b(calc|min|max|clamp)\(.+\)|^0$/,Zu=/^(rgba?|hsla?|hwb|(ok)?(lab|lch)|color-mix)\(.+\)$/,Ju=/^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/,Xu=/^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/,Qe=e=>En(e)||Wu.has(e)||Ku.test(e),cr=e=>kn(e,"length",am),En=e=>!!e&&!Number.isNaN(Number(e)),cs=e=>kn(e,"number",En),ro=e=>!!e&&Number.isInteger(Number(e)),tm=e=>e.endsWith("%")&&En(e.slice(0,-1)),B=e=>Op.test(e),pr=e=>Yu.test(e),em=new Set(["length","size","percentage"]),rm=e=>kn(e,em,Rp),nm=e=>kn(e,"position",Rp),om=new Set(["image","url"]),im=e=>kn(e,om,dm),sm=e=>kn(e,"",lm),no=()=>!0,kn=(e,t,r)=>{const o=Op.exec(e);return o?o[1]?typeof t=="string"?o[1]===t:t.has(o[1]):r(o[2]):!1},am=e=>Qu.test(e)&&!Zu.test(e),Rp=()=>!1,lm=e=>Ju.test(e),dm=e=>Xu.test(e),cm=()=>{const e=Z("colors"),t=Z("spacing"),r=Z("blur"),o=Z("brightness"),n=Z("borderColor"),i=Z("borderRadius"),s=Z("borderSpacing"),d=Z("borderWidth"),c=Z("contrast"),u=Z("grayscale"),v=Z("hueRotate"),y=Z("invert"),w=Z("gap"),b=Z("gradientColorStops"),C=Z("gradientColorStopPositions"),P=Z("inset"),O=Z("margin"),S=Z("opacity"),D=Z("padding"),L=Z("saturate"),I=Z("scale"),Q=Z("sepia"),R=Z("skew"),A=Z("space"),T=Z("translate"),x=()=>["auto","contain","none"],N=()=>["auto","hidden","clip","visible","scroll"],F=()=>["auto",B,t],$=()=>[B,t],k=()=>["",Qe,cr],M=()=>["auto",En,B],ne=()=>["bottom","center","left","left-bottom","left-top","right","right-bottom","right-top","top"],ye=()=>["solid","dashed","dotted","double","none"],Ho=()=>["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","hard-light","soft-light","difference","exclusion","hue","saturation","color","luminosity"],un=()=>["start","end","center","between","around","evenly","stretch"],Ar=()=>["","0",B],mn=()=>["auto","avoid","all","avoid-page","page","left","right","column"],Tt=()=>[En,B];return{cacheSize:500,separator:":",theme:{colors:[no],spacing:[Qe,cr],blur:["none","",pr,B],brightness:Tt(),borderColor:[e],borderRadius:["none","","full",pr,B],borderSpacing:$(),borderWidth:k(),contrast:Tt(),grayscale:Ar(),hueRotate:Tt(),invert:Ar(),gap:$(),gradientColorStops:[e],gradientColorStopPositions:[tm,cr],inset:F(),margin:F(),opacity:Tt(),padding:$(),saturate:Tt(),scale:Tt(),sepia:Ar(),skew:Tt(),space:$(),translate:$()},classGroups:{aspect:[{aspect:["auto","square","video",B]}],container:["container"],columns:[{columns:[pr]}],"break-after":[{"break-after":mn()}],"break-before":[{"break-before":mn()}],"break-inside":[{"break-inside":["auto","avoid","avoid-page","avoid-column"]}],"box-decoration":[{"box-decoration":["slice","clone"]}],box:[{box:["border","content"]}],display:["block","inline-block","inline","flex","inline-flex","table","inline-table","table-caption","table-cell","table-column","table-column-group","table-footer-group","table-header-group","table-row-group","table-row","flow-root","grid","inline-grid","contents","list-item","hidden"],float:[{float:["right","left","none","start","end"]}],clear:[{clear:["left","right","both","none","start","end"]}],isolation:["isolate","isolation-auto"],"object-fit":[{object:["contain","cover","fill","none","scale-down"]}],"object-position":[{object:[...ne(),B]}],overflow:[{overflow:N()}],"overflow-x":[{"overflow-x":N()}],"overflow-y":[{"overflow-y":N()}],overscroll:[{overscroll:x()}],"overscroll-x":[{"overscroll-x":x()}],"overscroll-y":[{"overscroll-y":x()}],position:["static","fixed","absolute","relative","sticky"],inset:[{inset:[P]}],"inset-x":[{"inset-x":[P]}],"inset-y":[{"inset-y":[P]}],start:[{start:[P]}],end:[{end:[P]}],top:[{top:[P]}],right:[{right:[P]}],bottom:[{bottom:[P]}],left:[{left:[P]}],visibility:["visible","invisible","collapse"],z:[{z:["auto",ro,B]}],basis:[{basis:F()}],"flex-direction":[{flex:["row","row-reverse","col","col-reverse"]}],"flex-wrap":[{flex:["wrap","wrap-reverse","nowrap"]}],flex:[{flex:["1","auto","initial","none",B]}],grow:[{grow:Ar()}],shrink:[{shrink:Ar()}],order:[{order:["first","last","none",ro,B]}],"grid-cols":[{"grid-cols":[no]}],"col-start-end":[{col:["auto",{span:["full",ro,B]},B]}],"col-start":[{"col-start":M()}],"col-end":[{"col-end":M()}],"grid-rows":[{"grid-rows":[no]}],"row-start-end":[{row:["auto",{span:[ro,B]},B]}],"row-start":[{"row-start":M()}],"row-end":[{"row-end":M()}],"grid-flow":[{"grid-flow":["row","col","dense","row-dense","col-dense"]}],"auto-cols":[{"auto-cols":["auto","min","max","fr",B]}],"auto-rows":[{"auto-rows":["auto","min","max","fr",B]}],gap:[{gap:[w]}],"gap-x":[{"gap-x":[w]}],"gap-y":[{"gap-y":[w]}],"justify-content":[{justify:["normal",...un()]}],"justify-items":[{"justify-items":["start","end","center","stretch"]}],"justify-self":[{"justify-self":["auto","start","end","center","stretch"]}],"align-content":[{content:["normal",...un(),"baseline"]}],"align-items":[{items:["start","end","center","baseline","stretch"]}],"align-self":[{self:["auto","start","end","center","stretch","baseline"]}],"place-content":[{"place-content":[...un(),"baseline"]}],"place-items":[{"place-items":["start","end","center","baseline","stretch"]}],"place-self":[{"place-self":["auto","start","end","center","stretch"]}],p:[{p:[D]}],px:[{px:[D]}],py:[{py:[D]}],ps:[{ps:[D]}],pe:[{pe:[D]}],pt:[{pt:[D]}],pr:[{pr:[D]}],pb:[{pb:[D]}],pl:[{pl:[D]}],m:[{m:[O]}],mx:[{mx:[O]}],my:[{my:[O]}],ms:[{ms:[O]}],me:[{me:[O]}],mt:[{mt:[O]}],mr:[{mr:[O]}],mb:[{mb:[O]}],ml:[{ml:[O]}],"space-x":[{"space-x":[A]}],"space-x-reverse":["space-x-reverse"],"space-y":[{"space-y":[A]}],"space-y-reverse":["space-y-reverse"],w:[{w:["auto","min","max","fit","svw","lvw","dvw",B,t]}],"min-w":[{"min-w":[B,t,"min","max","fit"]}],"max-w":[{"max-w":[B,t,"none","full","min","max","fit","prose",{screen:[pr]},pr]}],h:[{h:[B,t,"auto","min","max","fit","svh","lvh","dvh"]}],"min-h":[{"min-h":[B,t,"min","max","fit","svh","lvh","dvh"]}],"max-h":[{"max-h":[B,t,"min","max","fit","svh","lvh","dvh"]}],size:[{size:[B,t,"auto","min","max","fit"]}],"font-size":[{text:["base",pr,cr]}],"font-smoothing":["antialiased","subpixel-antialiased"],"font-style":["italic","not-italic"],"font-weight":[{font:["thin","extralight","light","normal","medium","semibold","bold","extrabold","black",cs]}],"font-family":[{font:[no]}],"fvn-normal":["normal-nums"],"fvn-ordinal":["ordinal"],"fvn-slashed-zero":["slashed-zero"],"fvn-figure":["lining-nums","oldstyle-nums"],"fvn-spacing":["proportional-nums","tabular-nums"],"fvn-fraction":["diagonal-fractions","stacked-fractions"],tracking:[{tracking:["tighter","tight","normal","wide","wider","widest",B]}],"line-clamp":[{"line-clamp":["none",En,cs]}],leading:[{leading:["none","tight","snug","normal","relaxed","loose",Qe,B]}],"list-image":[{"list-image":["none",B]}],"list-style-type":[{list:["none","disc","decimal",B]}],"list-style-position":[{list:["inside","outside"]}],"placeholder-color":[{placeholder:[e]}],"placeholder-opacity":[{"placeholder-opacity":[S]}],"text-alignment":[{text:["left","center","right","justify","start","end"]}],"text-color":[{text:[e]}],"text-opacity":[{"text-opacity":[S]}],"text-decoration":["underline","overline","line-through","no-underline"],"text-decoration-style":[{decoration:[...ye(),"wavy"]}],"text-decoration-thickness":[{decoration:["auto","from-font",Qe,cr]}],"underline-offset":[{"underline-offset":["auto",Qe,B]}],"text-decoration-color":[{decoration:[e]}],"text-transform":["uppercase","lowercase","capitalize","normal-case"],"text-overflow":["truncate","text-ellipsis","text-clip"],"text-wrap":[{text:["wrap","nowrap","balance","pretty"]}],indent:[{indent:$()}],"vertical-align":[{align:["baseline","top","middle","bottom","text-top","text-bottom","sub","super",B]}],whitespace:[{whitespace:["normal","nowrap","pre","pre-line","pre-wrap","break-spaces"]}],break:[{break:["normal","words","all","keep"]}],hyphens:[{hyphens:["none","manual","auto"]}],content:[{content:["none",B]}],"bg-attachment":[{bg:["fixed","local","scroll"]}],"bg-clip":[{"bg-clip":["border","padding","content","text"]}],"bg-opacity":[{"bg-opacity":[S]}],"bg-origin":[{"bg-origin":["border","padding","content"]}],"bg-position":[{bg:[...ne(),nm]}],"bg-repeat":[{bg:["no-repeat",{repeat:["","x","y","round","space"]}]}],"bg-size":[{bg:["auto","cover","contain",rm]}],"bg-image":[{bg:["none",{"gradient-to":["t","tr","r","br","b","bl","l","tl"]},im]}],"bg-color":[{bg:[e]}],"gradient-from-pos":[{from:[C]}],"gradient-via-pos":[{via:[C]}],"gradient-to-pos":[{to:[C]}],"gradient-from":[{from:[b]}],"gradient-via":[{via:[b]}],"gradient-to":[{to:[b]}],rounded:[{rounded:[i]}],"rounded-s":[{"rounded-s":[i]}],"rounded-e":[{"rounded-e":[i]}],"rounded-t":[{"rounded-t":[i]}],"rounded-r":[{"rounded-r":[i]}],"rounded-b":[{"rounded-b":[i]}],"rounded-l":[{"rounded-l":[i]}],"rounded-ss":[{"rounded-ss":[i]}],"rounded-se":[{"rounded-se":[i]}],"rounded-ee":[{"rounded-ee":[i]}],"rounded-es":[{"rounded-es":[i]}],"rounded-tl":[{"rounded-tl":[i]}],"rounded-tr":[{"rounded-tr":[i]}],"rounded-br":[{"rounded-br":[i]}],"rounded-bl":[{"rounded-bl":[i]}],"border-w":[{border:[d]}],"border-w-x":[{"border-x":[d]}],"border-w-y":[{"border-y":[d]}],"border-w-s":[{"border-s":[d]}],"border-w-e":[{"border-e":[d]}],"border-w-t":[{"border-t":[d]}],"border-w-r":[{"border-r":[d]}],"border-w-b":[{"border-b":[d]}],"border-w-l":[{"border-l":[d]}],"border-opacity":[{"border-opacity":[S]}],"border-style":[{border:[...ye(),"hidden"]}],"divide-x":[{"divide-x":[d]}],"divide-x-reverse":["divide-x-reverse"],"divide-y":[{"divide-y":[d]}],"divide-y-reverse":["divide-y-reverse"],"divide-opacity":[{"divide-opacity":[S]}],"divide-style":[{divide:ye()}],"border-color":[{border:[n]}],"border-color-x":[{"border-x":[n]}],"border-color-y":[{"border-y":[n]}],"border-color-s":[{"border-s":[n]}],"border-color-e":[{"border-e":[n]}],"border-color-t":[{"border-t":[n]}],"border-color-r":[{"border-r":[n]}],"border-color-b":[{"border-b":[n]}],"border-color-l":[{"border-l":[n]}],"divide-color":[{divide:[n]}],"outline-style":[{outline:["",...ye()]}],"outline-offset":[{"outline-offset":[Qe,B]}],"outline-w":[{outline:[Qe,cr]}],"outline-color":[{outline:[e]}],"ring-w":[{ring:k()}],"ring-w-inset":["ring-inset"],"ring-color":[{ring:[e]}],"ring-opacity":[{"ring-opacity":[S]}],"ring-offset-w":[{"ring-offset":[Qe,cr]}],"ring-offset-color":[{"ring-offset":[e]}],shadow:[{shadow:["","inner","none",pr,sm]}],"shadow-color":[{shadow:[no]}],opacity:[{opacity:[S]}],"mix-blend":[{"mix-blend":[...Ho(),"plus-lighter","plus-darker"]}],"bg-blend":[{"bg-blend":Ho()}],filter:[{filter:["","none"]}],blur:[{blur:[r]}],brightness:[{brightness:[o]}],contrast:[{contrast:[c]}],"drop-shadow":[{"drop-shadow":["","none",pr,B]}],grayscale:[{grayscale:[u]}],"hue-rotate":[{"hue-rotate":[v]}],invert:[{invert:[y]}],saturate:[{saturate:[L]}],sepia:[{sepia:[Q]}],"backdrop-filter":[{"backdrop-filter":["","none"]}],"backdrop-blur":[{"backdrop-blur":[r]}],"backdrop-brightness":[{"backdrop-brightness":[o]}],"backdrop-contrast":[{"backdrop-contrast":[c]}],"backdrop-grayscale":[{"backdrop-grayscale":[u]}],"backdrop-hue-rotate":[{"backdrop-hue-rotate":[v]}],"backdrop-invert":[{"backdrop-invert":[y]}],"backdrop-opacity":[{"backdrop-opacity":[S]}],"backdrop-saturate":[{"backdrop-saturate":[L]}],"backdrop-sepia":[{"backdrop-sepia":[Q]}],"border-collapse":[{border:["collapse","separate"]}],"border-spacing":[{"border-spacing":[s]}],"border-spacing-x":[{"border-spacing-x":[s]}],"border-spacing-y":[{"border-spacing-y":[s]}],"table-layout":[{table:["auto","fixed"]}],caption:[{caption:["top","bottom"]}],transition:[{transition:["none","all","","colors","opacity","shadow","transform",B]}],duration:[{duration:Tt()}],ease:[{ease:["linear","in","out","in-out",B]}],delay:[{delay:Tt()}],animate:[{animate:["none","spin","ping","pulse","bounce",B]}],transform:[{transform:["","gpu","none"]}],scale:[{scale:[I]}],"scale-x":[{"scale-x":[I]}],"scale-y":[{"scale-y":[I]}],rotate:[{rotate:[ro,B]}],"translate-x":[{"translate-x":[T]}],"translate-y":[{"translate-y":[T]}],"skew-x":[{"skew-x":[R]}],"skew-y":[{"skew-y":[R]}],"transform-origin":[{origin:["center","top","top-right","right","bottom-right","bottom","bottom-left","left","top-left",B]}],accent:[{accent:["auto",e]}],appearance:[{appearance:["none","auto"]}],cursor:[{cursor:["auto","default","pointer","wait","text","move","help","not-allowed","none","context-menu","progress","cell","crosshair","vertical-text","alias","copy","no-drop","grab","grabbing","all-scroll","col-resize","row-resize","n-resize","e-resize","s-resize","w-resize","ne-resize","nw-resize","se-resize","sw-resize","ew-resize","ns-resize","nesw-resize","nwse-resize","zoom-in","zoom-out",B]}],"caret-color":[{caret:[e]}],"pointer-events":[{"pointer-events":["none","auto"]}],resize:[{resize:["none","y","x",""]}],"scroll-behavior":[{scroll:["auto","smooth"]}],"scroll-m":[{"scroll-m":$()}],"scroll-mx":[{"scroll-mx":$()}],"scroll-my":[{"scroll-my":$()}],"scroll-ms":[{"scroll-ms":$()}],"scroll-me":[{"scroll-me":$()}],"scroll-mt":[{"scroll-mt":$()}],"scroll-mr":[{"scroll-mr":$()}],"scroll-mb":[{"scroll-mb":$()}],"scroll-ml":[{"scroll-ml":$()}],"scroll-p":[{"scroll-p":$()}],"scroll-px":[{"scroll-px":$()}],"scroll-py":[{"scroll-py":$()}],"scroll-ps":[{"scroll-ps":$()}],"scroll-pe":[{"scroll-pe":$()}],"scroll-pt":[{"scroll-pt":$()}],"scroll-pr":[{"scroll-pr":$()}],"scroll-pb":[{"scroll-pb":$()}],"scroll-pl":[{"scroll-pl":$()}],"snap-align":[{snap:["start","end","center","align-none"]}],"snap-stop":[{snap:["normal","always"]}],"snap-type":[{snap:["none","x","y","both"]}],"snap-strictness":[{snap:["mandatory","proximity"]}],touch:[{touch:["auto","none","manipulation"]}],"touch-x":[{"touch-pan":["x","left","right"]}],"touch-y":[{"touch-pan":["y","up","down"]}],"touch-pz":["touch-pinch-zoom"],select:[{select:["none","text","all","auto"]}],"will-change":[{"will-change":["auto","scroll","contents","transform",B]}],fill:[{fill:[e,"none"]}],"stroke-w":[{stroke:[Qe,cr,cs]}],stroke:[{stroke:[e,"none"]}],sr:["sr-only","not-sr-only"],"forced-color-adjust":[{"forced-color-adjust":["auto","none"]}]},conflictingClassGroups:{overflow:["overflow-x","overflow-y"],overscroll:["overscroll-x","overscroll-y"],inset:["inset-x","inset-y","start","end","top","right","bottom","left"],"inset-x":["right","left"],"inset-y":["top","bottom"],flex:["basis","grow","shrink"],gap:["gap-x","gap-y"],p:["px","py","ps","pe","pt","pr","pb","pl"],px:["pr","pl"],py:["pt","pb"],m:["mx","my","ms","me","mt","mr","mb","ml"],mx:["mr","ml"],my:["mt","mb"],size:["w","h"],"font-size":["leading"],"fvn-normal":["fvn-ordinal","fvn-slashed-zero","fvn-figure","fvn-spacing","fvn-fraction"],"fvn-ordinal":["fvn-normal"],"fvn-slashed-zero":["fvn-normal"],"fvn-figure":["fvn-normal"],"fvn-spacing":["fvn-normal"],"fvn-fraction":["fvn-normal"],"line-clamp":["display","overflow"],rounded:["rounded-s","rounded-e","rounded-t","rounded-r","rounded-b","rounded-l","rounded-ss","rounded-se","rounded-ee","rounded-es","rounded-tl","rounded-tr","rounded-br","rounded-bl"],"rounded-s":["rounded-ss","rounded-es"],"rounded-e":["rounded-se","rounded-ee"],"rounded-t":["rounded-tl","rounded-tr"],"rounded-r":["rounded-tr","rounded-br"],"rounded-b":["rounded-br","rounded-bl"],"rounded-l":["rounded-tl","rounded-bl"],"border-spacing":["border-spacing-x","border-spacing-y"],"border-w":["border-w-s","border-w-e","border-w-t","border-w-r","border-w-b","border-w-l"],"border-w-x":["border-w-r","border-w-l"],"border-w-y":["border-w-t","border-w-b"],"border-color":["border-color-s","border-color-e","border-color-t","border-color-r","border-color-b","border-color-l"],"border-color-x":["border-color-r","border-color-l"],"border-color-y":["border-color-t","border-color-b"],"scroll-m":["scroll-mx","scroll-my","scroll-ms","scroll-me","scroll-mt","scroll-mr","scroll-mb","scroll-ml"],"scroll-mx":["scroll-mr","scroll-ml"],"scroll-my":["scroll-mt","scroll-mb"],"scroll-p":["scroll-px","scroll-py","scroll-ps","scroll-pe","scroll-pt","scroll-pr","scroll-pb","scroll-pl"],"scroll-px":["scroll-pr","scroll-pl"],"scroll-py":["scroll-pt","scroll-pb"],touch:["touch-x","touch-y","touch-pz"],"touch-x":["touch"],"touch-y":["touch"],"touch-pz":["touch"]},conflictingClassGroupModifiers:{"font-size":["leading"]}}},Ip=Gu(cm);function m(...e){return Ip(Va(e))}/**
|
|
81
81
|
* @license
|
|
82
82
|
* Copyright 2017 Google LLC
|
|
83
83
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
@@ -93,7 +93,7 @@
|
|
|
93
93
|
* @license
|
|
94
94
|
* Copyright 2017 Google LLC
|
|
95
95
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
96
|
-
*/class ai extends xo{constructor(t){if(super(t),this.it=h,t.type!==Xe.CHILD)throw Error(this.constructor.directiveName+"() can only be used in child bindings")}render(t){if(t===h||t==null)return this._t=void 0,this.it=t;if(t===Gt)return t;if(typeof t!="string")throw Error(this.constructor.directiveName+"() called with a non-string value");if(t===this.it)return this._t;this.it=t;const r=[t];return r.raw=r,this._t={_$litType$:this.constructor.resultType,strings:r,values:[]}}}ai.directiveName="unsafeHTML",ai.resultType=1;const Fp=Xr(ai),fo={base:[""],item:["pont-border-b-accordion-item-width-border pont-border-b-accordion-item-color-border"],trigger:["pont-flex pont-flex-1 pont-gap-accordion-trigger-space-gap pont-justify-between pont-items-start","pont-py-accordion-trigger-space-py","pont-w-accordion-trigger-space-w","pont-rounded-accordion-trigger-radius pont-outline-none","pont-text-accordion-trigger-font pont-font-accordion-trigger-font-weight pont-text-left","pont-transition-all","hover:pont-underline","focus-visible:pont-border-accordion-trigger-width-border-focus focus-visible:pont-border-accordion-trigger-color-border-focus","focus-visible:pont-ring-accordion-trigger-width-ring-focus focus-visible:pont-ring-accordion-trigger-color-ring-focus","disabled:pont-pointer-events-none disabled:pont-opacity-50","[&[data-state=open]>svg]:pont-rotate-180"],chevron:["pont-shrink-0","pont-size-accordion-trigger-icon-space-size","pont-text-accordion-trigger-icon-color-text","pont-translate-y-0.5 pont-transition-transform pont-duration-200","pont-pointer-events-none"],content:["pont-overflow-hidden","pont-text-accordion-content-font pont-font-accordion-content-font-weight","data-[state=closed]:pont-h-accordion-content-space-h-closed","data-[state=closed]:pont-animate-accordion-content-animate-closed","data-[state=open]:pont-animate-accordion-content-animate-open","data-[state=open]:pont-h-fit","[&>div]:pont-pt-accordion-content-div-space-pt [&>div]:pont-pb-accordion-content-div-space-pb"]};var bm=Object.getOwnPropertyDescriptor,ym=(e,t,r,o)=>{for(var n=o>1?void 0:o?bm(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let Hs=class extends
|
|
96
|
+
*/class ai extends xo{constructor(t){if(super(t),this.it=h,t.type!==Xe.CHILD)throw Error(this.constructor.directiveName+"() can only be used in child bindings")}render(t){if(t===h||t==null)return this._t=void 0,this.it=t;if(t===Gt)return t;if(typeof t!="string")throw Error(this.constructor.directiveName+"() called with a non-string value");if(t===this.it)return this._t;this.it=t;const r=[t];return r.raw=r,this._t={_$litType$:this.constructor.resultType,strings:r,values:[]}}}ai.directiveName="unsafeHTML",ai.resultType=1;const Fp=Xr(ai),fo={base:[""],item:["pont-border-b-accordion-item-width-border pont-border-b-accordion-item-color-border"],trigger:["pont-flex pont-flex-1 pont-gap-accordion-trigger-space-gap pont-justify-between pont-items-start","pont-py-accordion-trigger-space-py","pont-w-accordion-trigger-space-w","pont-rounded-accordion-trigger-radius pont-outline-none","pont-text-accordion-trigger-font pont-font-accordion-trigger-font-weight pont-text-left","pont-transition-all","hover:pont-underline","focus-visible:pont-border-accordion-trigger-width-border-focus focus-visible:pont-border-accordion-trigger-color-border-focus","focus-visible:pont-ring-accordion-trigger-width-ring-focus focus-visible:pont-ring-accordion-trigger-color-ring-focus","disabled:pont-pointer-events-none disabled:pont-opacity-50","[&[data-state=open]>svg]:pont-rotate-180"],chevron:["pont-shrink-0","pont-size-accordion-trigger-icon-space-size","pont-text-accordion-trigger-icon-color-text","pont-translate-y-0.5 pont-transition-transform pont-duration-200","pont-pointer-events-none"],content:["pont-overflow-hidden","pont-text-accordion-content-font pont-font-accordion-content-font-weight","data-[state=closed]:pont-h-accordion-content-space-h-closed","data-[state=closed]:pont-animate-accordion-content-animate-closed","data-[state=open]:pont-animate-accordion-content-animate-open","data-[state=open]:pont-h-fit","[&>div]:pont-pt-accordion-content-div-space-pt [&>div]:pont-pb-accordion-content-div-space-pb"]};var bm=Object.getOwnPropertyDescriptor,ym=(e,t,r,o)=>{for(var n=o>1?void 0:o?bm(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let Hs=class extends _{constructor(){super(...arguments),this._onAccordionClick=()=>{this.requestUpdate()}}get _accordion(){let e=this.parentElement;for(;e&&!(e instanceof xn);)e=e.parentElement;return e}get _item(){let e=this.parentElement;for(;e&&!(e instanceof Pe);)e=e.parentElement;return e}getAttributesToExclude(){return[]}createRenderRoot(){return this}connectedCallback(){var e;super.connectedCallback(),(e=this._accordion)==null||e.addEventListener("clicked-accordion",this._onAccordionClick)}disconnectedCallback(){var e;super.disconnectedCallback(),(e=this._accordion)==null||e.removeEventListener("clicked-accordion",this._onAccordionClick)}firstUpdated(e){this.removeDuplicateContent()}hasActiveState(){var e,t;return!!((e=this._item)!=null&&e.value)&&!!((t=this._accordion)!=null&&t.selectedItems.includes(this._item.value))}render(){var t;const e=this.hasActiveState();return l`
|
|
97
97
|
<div
|
|
98
98
|
part="accordion-content"
|
|
99
99
|
role="region"
|
|
@@ -104,7 +104,7 @@
|
|
|
104
104
|
>
|
|
105
105
|
<div>${Fp(((t=this.textContent)==null?void 0:t.trim())||"")}</div>
|
|
106
106
|
</div>
|
|
107
|
-
`}};Hs=ym([p("pont-accordion-content")],Hs);var _m=Object.defineProperty,wm=Object.getOwnPropertyDescriptor,Ga=(e,t,r,o)=>{for(var n=o>1?void 0:o?wm(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&_m(t,r,n),n};let Pe=class extends
|
|
107
|
+
`}};Hs=ym([p("pont-accordion-content")],Hs);var _m=Object.defineProperty,wm=Object.getOwnPropertyDescriptor,Ga=(e,t,r,o)=>{for(var n=o>1?void 0:o?wm(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&_m(t,r,n),n};let Pe=class extends _{constructor(){super(...arguments),this.value="",this.tabindex=0,this._initialChildren=[],this._onClick=e=>{const t=e.target.closest("pont-accordion-trigger");!t||!this._accordion||(e.preventDefault(),e.stopPropagation(),this._accordion.raiseEvent(this.value),t.requestUpdate(),setTimeout(()=>this.requestUpdate(),0))},this._onAccordionClick=()=>{this.requestUpdate()}}get _accordion(){let e=this.parentElement;for(;e&&!(e instanceof xn);)e=e.parentElement;return e}getAttributesToExclude(){return["aria-orientation","role","data-orientation","data-testid"]}createRenderRoot(){return this}connectedCallback(){var e;super.connectedCallback(),this._initialChildren=this.filterChildren(),this.addEventListener("click",this._onClick),(e=this._accordion)==null||e.addEventListener("clicked-accordion",this._onAccordionClick)}disconnectedCallback(){var e;super.disconnectedCallback(),this.removeEventListener("click",this._onClick),(e=this._accordion)==null||e.removeEventListener("clicked-accordion",this._onAccordionClick)}filterChildren(){return Array.from(this.children).filter(e=>e instanceof Gs||e instanceof Hs)}render(){var r;const e=(r=this._accordion)==null?void 0:r.selectedItems.includes(this.value),t=this._initialChildren.length?this._initialChildren:this.filterChildren();return l`
|
|
108
108
|
<div
|
|
109
109
|
data-state=${e?"open":"closed"}
|
|
110
110
|
class="${m(fo.item,this.className)}"
|
|
@@ -115,7 +115,7 @@
|
|
|
115
115
|
>
|
|
116
116
|
${t}
|
|
117
117
|
</div>
|
|
118
|
-
`}};Ga([a({type:String})],Pe.prototype,"value",2);Ga([a({type:Number})],Pe.prototype,"tabindex",2);Pe=Ga([p("pont-accordion-item")],Pe);var $m=Object.getOwnPropertyDescriptor,Pm=(e,t,r,o)=>{for(var n=o>1?void 0:o?$m(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let Gs=class extends
|
|
118
|
+
`}};Ga([a({type:String})],Pe.prototype,"value",2);Ga([a({type:Number})],Pe.prototype,"tabindex",2);Pe=Ga([p("pont-accordion-item")],Pe);var $m=Object.getOwnPropertyDescriptor,Pm=(e,t,r,o)=>{for(var n=o>1?void 0:o?$m(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let Gs=class extends _{get _item(){let e=this.parentElement;for(;e&&!(e instanceof Pe);)e=e.parentElement;return e}get _accordion(){let e=this.parentElement;for(;e&&!(e instanceof xn);)e=e.parentElement;return e}getAttributesToExclude(){return["value","defaultValue"]}createRenderRoot(){return this}firstUpdated(e){this.removeDuplicateContent()}hasActiveState(){var e,t;return!!((e=this._item)!=null&&e.value)&&!!((t=this._accordion)!=null&&t.selectedItems.includes(this._item.value))}render(){var t;const e=this.hasActiveState();return l`
|
|
119
119
|
<button
|
|
120
120
|
type="button"
|
|
121
121
|
part="accordion-trigger"
|
|
@@ -144,7 +144,7 @@
|
|
|
144
144
|
<path d="m6 9 6 6 6-6" />
|
|
145
145
|
</svg>
|
|
146
146
|
</button>
|
|
147
|
-
`}};Gs=Pm([p("pont-accordion-trigger")],Gs);var Fr=(e=>(e.MULTIPLE="multiple",e.SINGLE="single",e))(Fr||{}),Cm=Object.defineProperty,Em=Object.getOwnPropertyDescriptor,kp=(e,t,r,o)=>{for(var n=o>1?void 0:o?Em(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&Cm(t,r,n),n};let xn=class extends
|
|
147
|
+
`}};Gs=Pm([p("pont-accordion-trigger")],Gs);var Fr=(e=>(e.MULTIPLE="multiple",e.SINGLE="single",e))(Fr||{}),Cm=Object.defineProperty,Em=Object.getOwnPropertyDescriptor,kp=(e,t,r,o)=>{for(var n=o>1?void 0:o?Em(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&Cm(t,r,n),n};let xn=class extends _{constructor(){super(...arguments),this.type=Fr.MULTIPLE,this.selectedItems=[],this._initialChildren=[]}getAttributesToExclude(){return["variant","data-testid"]}createRenderRoot(){return this}connectedCallback(){super.connectedCallback(),this._initialChildren=Array.from(this.children).filter(e=>e instanceof Pe)}willUpdate(e){e.has("type")&&(this.type===Fr.SINGLE&&this.selectedItems.length>1&&(this.selectedItems=this.selectedItems.slice(0,1)),this._initialChildren.forEach(t=>{t instanceof Pe&&t.requestUpdate()}))}updated(e){e.has("type")&&this._initialChildren.forEach(t=>{t instanceof Pe&&t.requestUpdate()})}setSelectedItems(e){const t=this.selectedItems.indexOf(e);if(t>-1)if(this.type===Fr.SINGLE)this.selectedItems=[];else if(this.type===Fr.MULTIPLE)this.selectedItems.splice(t,1);else throw new Error("Invalid accordion type");else if(this.type===Fr.SINGLE)this.selectedItems=[e];else if(this.type===Fr.MULTIPLE)this.selectedItems.push(e);else throw new Error("Invalid accordion type")}raiseEvent(e){this.setSelectedItems(e),this.dispatchEvent(new CustomEvent("clicked-accordion",{bubbles:!0,composed:!0,detail:{selectedItems:this.selectedItems}}))}render(){const e=this._initialChildren.length?this._initialChildren:Array.from(this.children).filter(t=>t instanceof Pe);return l`
|
|
148
148
|
<div
|
|
149
149
|
data-orientation="vertical"
|
|
150
150
|
${xt(this.getFilteredAttributes())}
|
|
@@ -196,7 +196,7 @@
|
|
|
196
196
|
aria-label=${this.ariaLabel??h}
|
|
197
197
|
aria-invalid=${this.invalid||this.ariaInvalid==="true"?"true":h}
|
|
198
198
|
></span>
|
|
199
|
-
`}};Oo([a({type:String})],On.prototype,"variant",2);Oo([a({type:Boolean})],On.prototype,"invalid",2);Oo([a({type:String})],On.prototype,"href",2);Oo([a({type:String})],On.prototype,"target",2);On=Oo([p("pont-badge")],On);const Nn={list:["pont-flex pont-flex-wrap pont-gap-breadcrumb-list-space-gap-sm sm:pont-gap-breadcrumb-list-space-gap pont-items-center","pont-text-breadcrumb-list-font pont-font-breadcrumb-list-font-weight pont-text-breadcrumb-list-color-text pont-break-words"],item:["pont-inline-flex pont-gap-breadcrumb-item-space-gap pont-items-center"],link:["pont-transition-colors","hover:pont-text-breadcrumb-link-color-text-hover"],page:["pont-font-breadcrumb-page-font-weight pont-text-breadcrumb-page-color-text"],separator:["[&>svg]:pont-size-breadcrumb-separator-icon-space-size"],ellipsis:["pont-flex pont-justify-center pont-items-center","pont-size-breadcrumb-ellipsis-space-size","[&>svg]:pont-size-breadcrumb-ellipsis-icon-space-size"]};var Qm=Object.getOwnPropertyDescriptor,Zm=(e,t,r,o)=>{for(var n=o>1?void 0:o?Qm(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let ed=class extends
|
|
199
|
+
`}};Oo([a({type:String})],On.prototype,"variant",2);Oo([a({type:Boolean})],On.prototype,"invalid",2);Oo([a({type:String})],On.prototype,"href",2);Oo([a({type:String})],On.prototype,"target",2);On=Oo([p("pont-badge")],On);const Nn={list:["pont-flex pont-flex-wrap pont-gap-breadcrumb-list-space-gap-sm sm:pont-gap-breadcrumb-list-space-gap pont-items-center","pont-text-breadcrumb-list-font pont-font-breadcrumb-list-font-weight pont-text-breadcrumb-list-color-text pont-break-words"],item:["pont-inline-flex pont-gap-breadcrumb-item-space-gap pont-items-center"],link:["pont-transition-colors","hover:pont-text-breadcrumb-link-color-text-hover"],page:["pont-font-breadcrumb-page-font-weight pont-text-breadcrumb-page-color-text"],separator:["[&>svg]:pont-size-breadcrumb-separator-icon-space-size"],ellipsis:["pont-flex pont-justify-center pont-items-center","pont-size-breadcrumb-ellipsis-space-size","[&>svg]:pont-size-breadcrumb-ellipsis-icon-space-size"]};var Qm=Object.getOwnPropertyDescriptor,Zm=(e,t,r,o)=>{for(var n=o>1?void 0:o?Qm(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let ed=class extends _{getAttributesToExclude(){return[""]}createRenderRoot(){return this}render(){const e=this.getFilteredAttributes();return l`
|
|
200
200
|
<span
|
|
201
201
|
${xt(e)}
|
|
202
202
|
id="pont-bread-crumb-ellipsis"
|
|
@@ -220,14 +220,14 @@
|
|
|
220
220
|
<circle cx="5" cy="12" r="1" />
|
|
221
221
|
</svg>
|
|
222
222
|
</span>
|
|
223
|
-
`}};ed=Zm([p("pont-bread-crumb-ellipsis")],ed);var Jm=Object.getOwnPropertyDescriptor,Xm=(e,t,r,o)=>{for(var n=o>1?void 0:o?Jm(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let rd=class extends
|
|
223
|
+
`}};ed=Zm([p("pont-bread-crumb-ellipsis")],ed);var Jm=Object.getOwnPropertyDescriptor,Xm=(e,t,r,o)=>{for(var n=o>1?void 0:o?Jm(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let rd=class extends _{get _containerElement(){return this.querySelector("li[part=breadcrumb-item]")}getAttributesToExclude(){return["variant"]}createRenderRoot(){return this}firstUpdated(e){this.moveLightDomChildrenInto(this._containerElement)}render(){const e=this.getFilteredAttributes();return l`
|
|
224
224
|
<li
|
|
225
225
|
${xt(e)}
|
|
226
226
|
id="pont-bread-crumb-item"
|
|
227
227
|
class="${m(Nn.item,this.className)}"
|
|
228
228
|
part="breadcrumb-item"
|
|
229
229
|
></li>
|
|
230
|
-
`}};rd=Xm([p("pont-bread-crumb-item")],rd);var tg=Object.defineProperty,eg=Object.getOwnPropertyDescriptor,Bp=(e,t,r,o)=>{for(var n=o>1?void 0:o?eg(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&tg(t,r,n),n};let Ys=class extends
|
|
230
|
+
`}};rd=Xm([p("pont-bread-crumb-item")],rd);var tg=Object.defineProperty,eg=Object.getOwnPropertyDescriptor,Bp=(e,t,r,o)=>{for(var n=o>1?void 0:o?eg(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&tg(t,r,n),n};let Ys=class extends _{constructor(){super(...arguments),this.href="/"}get _containerElement(){return this.querySelector("a[part=breadcrumb-link]")}getAttributesToExclude(){return[""]}createRenderRoot(){return this}firstUpdated(e){this.moveLightDomChildrenInto(this._containerElement)}render(){const e=this.getFilteredAttributes();return l`
|
|
231
231
|
<a
|
|
232
232
|
${xt(e)}
|
|
233
233
|
id="pont-bread-crumb-link"
|
|
@@ -236,14 +236,14 @@
|
|
|
236
236
|
part="breadcrumb-link"
|
|
237
237
|
>
|
|
238
238
|
</a>
|
|
239
|
-
`}};Bp([a({type:String})],Ys.prototype,"href",2);Ys=Bp([p("pont-bread-crumb-link")],Ys);var rg=Object.getOwnPropertyDescriptor,ng=(e,t,r,o)=>{for(var n=o>1?void 0:o?rg(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let nd=class extends
|
|
239
|
+
`}};Bp([a({type:String})],Ys.prototype,"href",2);Ys=Bp([p("pont-bread-crumb-link")],Ys);var rg=Object.getOwnPropertyDescriptor,ng=(e,t,r,o)=>{for(var n=o>1?void 0:o?rg(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let nd=class extends _{get _containerElement(){return this.querySelector("ol[part=breadcrumb-list]")}getAttributesToExclude(){return["variant"]}createRenderRoot(){return this}firstUpdated(e){this.moveLightDomChildrenInto(this._containerElement)}render(){const e=this.getFilteredAttributes();return l`
|
|
240
240
|
<ol
|
|
241
241
|
${xt(e)}
|
|
242
242
|
id="pont-bread-crumb-list"
|
|
243
243
|
class="${m(Nn.list,this.className)}"
|
|
244
244
|
part="breadcrumb-list"
|
|
245
245
|
></ol>
|
|
246
|
-
`}};nd=ng([p("pont-bread-crumb-list")],nd);var og=Object.getOwnPropertyDescriptor,ig=(e,t,r,o)=>{for(var n=o>1?void 0:o?og(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let od=class extends
|
|
246
|
+
`}};nd=ng([p("pont-bread-crumb-list")],nd);var og=Object.getOwnPropertyDescriptor,ig=(e,t,r,o)=>{for(var n=o>1?void 0:o?og(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let od=class extends _{getAttributesToExclude(){return[""]}createRenderRoot(){return this}render(){const e=this.getFilteredAttributes();return l`
|
|
247
247
|
<li
|
|
248
248
|
${xt(e)}
|
|
249
249
|
id="pont-bread-crumb-separator"
|
|
@@ -265,7 +265,7 @@
|
|
|
265
265
|
<path d="m9 18 6-6-6-6" />
|
|
266
266
|
</svg>
|
|
267
267
|
</li>
|
|
268
|
-
`}};od=ig([p("pont-bread-crumb-separator")],od);var sg=Object.getOwnPropertyDescriptor,ag=(e,t,r,o)=>{for(var n=o>1?void 0:o?sg(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let id=class extends
|
|
268
|
+
`}};od=ig([p("pont-bread-crumb-separator")],od);var sg=Object.getOwnPropertyDescriptor,ag=(e,t,r,o)=>{for(var n=o>1?void 0:o?sg(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let id=class extends _{get _containerElement(){return this.querySelector("span[part=breadcrumb-text]")}getAttributesToExclude(){return[""]}createRenderRoot(){return this}firstUpdated(e){this.moveLightDomChildrenInto(this._containerElement)}render(){const e=this.getFilteredAttributes();return l`
|
|
269
269
|
<span
|
|
270
270
|
${xt(e)}
|
|
271
271
|
id="pont-bread-crumb-text"
|
|
@@ -275,7 +275,7 @@
|
|
|
275
275
|
part="breadcrumb-text"
|
|
276
276
|
>
|
|
277
277
|
</span>
|
|
278
|
-
`}};id=ag([p("pont-bread-crumb-text")],id);var lg=Object.getOwnPropertyDescriptor,dg=(e,t,r,o)=>{for(var n=o>1?void 0:o?lg(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let sd=class extends
|
|
278
|
+
`}};id=ag([p("pont-bread-crumb-text")],id);var lg=Object.getOwnPropertyDescriptor,dg=(e,t,r,o)=>{for(var n=o>1?void 0:o?lg(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let sd=class extends _{get _containerElement(){return this.querySelector("nav[part=breadcrumb]")}getAttributesToExclude(){return[""]}createRenderRoot(){return this}firstUpdated(e){this.moveLightDomChildrenInto(this._containerElement)}render(){const e=this.getFilteredAttributes();return l`
|
|
279
279
|
<nav
|
|
280
280
|
${xt(e)}
|
|
281
281
|
part="breadcrumb"
|
|
@@ -400,15 +400,15 @@
|
|
|
400
400
|
<tbody class=${m("calendar-weeks",V.weeks)}>
|
|
401
401
|
${Array.from({length:Math.ceil(i.length/7)},(u,v)=>l`
|
|
402
402
|
<tr class=${m("calendar-week",V.week)}>
|
|
403
|
-
${i.slice(v*7,(v+1)*7).map((
|
|
403
|
+
${i.slice(v*7,(v+1)*7).map((y,w)=>{var T,x,N;const b=new Date(this.currentDate.getFullYear(),y.month,Number(y.day)),C=!1,P=b.toDateString()===new Date().toDateString(),O=this.mode==="range"&&b.toDateString()===((T=this.selectedStartDate)==null?void 0:T.toDateString()),S=this.mode==="range"&&this.isDayInRange(b,!0),D=this.mode==="range"&&b.toDateString()===((x=this.selectedEndDate)==null?void 0:x.toDateString()),L=this.mode==="single"&&b.toDateString()===((N=this.selectedStartDate)==null?void 0:N.toDateString()),I=L||O||S||D,Q=w===0,R=w===6;let A=P?"Today, ":"";return A+=mg(b),A+=I?", selected":"",l`
|
|
404
404
|
<td
|
|
405
405
|
class=${m("calendar-day",V.day.base,P&&!I&&V.day.today,I&&V.day.selected.common,L&&V.day.selected.single,O&&V.day.selected.range.start,S&&V.day.selected.range.middle,D&&V.day.selected.range.end,Q&&V.day.index.first,R&&V.day.index.last,C)}
|
|
406
406
|
role="gridcell"
|
|
407
|
-
data-day=${
|
|
407
|
+
data-day=${b.toISOString().slice(0,10)}
|
|
408
408
|
?data-disabled=${void 0}
|
|
409
409
|
?data-focused=${void 0}
|
|
410
410
|
?data-hidden=${void 0}
|
|
411
|
-
?data-outside=${
|
|
411
|
+
?data-outside=${y.isOutside?"true":void 0}
|
|
412
412
|
?data-today=${P?"true":void 0}
|
|
413
413
|
?data-selected=${I?"true":void 0}
|
|
414
414
|
?aria-disabled=${void 0}
|
|
@@ -417,7 +417,7 @@
|
|
|
417
417
|
>
|
|
418
418
|
<button
|
|
419
419
|
data-pont-button
|
|
420
|
-
class=${m("calendar-day-button",V.dayButton.base,
|
|
420
|
+
class=${m("calendar-day-button",V.dayButton.base,y.isOutside&&V.dayButton.outside,P&&V.dayButton.today)}
|
|
421
421
|
?disabled=${void 0}
|
|
422
422
|
data-variant="ghost"
|
|
423
423
|
data-size="icon"
|
|
@@ -428,9 +428,9 @@
|
|
|
428
428
|
tabindex=${L||D?"0":"-1"}
|
|
429
429
|
type="button"
|
|
430
430
|
aria-label=${A}
|
|
431
|
-
@click="${()=>this.selectDate(Number(
|
|
431
|
+
@click="${()=>this.selectDate(Number(y.day),y.isOutside)}"
|
|
432
432
|
>
|
|
433
|
-
${
|
|
433
|
+
${y.day}
|
|
434
434
|
</button>
|
|
435
435
|
</td>
|
|
436
436
|
`})}
|
|
@@ -660,26 +660,26 @@
|
|
|
660
660
|
</button>
|
|
661
661
|
|
|
662
662
|
${this._renderInput()}
|
|
663
|
-
`}};ke([a({attribute:"default-checked",type:Boolean})],se.prototype,"defaultChecked",2);ke([a({attribute:!0,type:Boolean})],se.prototype,"checked",2);ke([a({attribute:!1,type:Function})],se.prototype,"onCheckedChange",2);ke([a({type:Boolean})],se.prototype,"disabled",2);ke([a({type:Boolean})],se.prototype,"required",2);ke([a({type:Boolean})],se.prototype,"invalid",2);ke([a({type:String})],se.prototype,"name",2);ke([a({type:String})],se.prototype,"value",2);ke([g()],se.prototype,"_checked",2);se=ke([p("pont-checkbox")],se);var zg=Object.getOwnPropertyDescriptor,Vg=(e,t,r,o)=>{for(var n=o>1?void 0:o?zg(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let hd=class extends
|
|
663
|
+
`}};ke([a({attribute:"default-checked",type:Boolean})],se.prototype,"defaultChecked",2);ke([a({attribute:!0,type:Boolean})],se.prototype,"checked",2);ke([a({attribute:!1,type:Function})],se.prototype,"onCheckedChange",2);ke([a({type:Boolean})],se.prototype,"disabled",2);ke([a({type:Boolean})],se.prototype,"required",2);ke([a({type:Boolean})],se.prototype,"invalid",2);ke([a({type:String})],se.prototype,"name",2);ke([a({type:String})],se.prototype,"value",2);ke([g()],se.prototype,"_checked",2);se=ke([p("pont-checkbox")],se);var zg=Object.getOwnPropertyDescriptor,Vg=(e,t,r,o)=>{for(var n=o>1?void 0:o?zg(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let hd=class extends _{getAttributesToExclude(){return[""]}get _containerElement(){return this.querySelector("div[part=collapsible-trigger]")}firstUpdated(e){this.moveLightDomChildrenInto(this._containerElement)}createRenderRoot(){return this}get _collapsible(){let e=this.parentElement;for(;e&&!(e instanceof di);)e=e.parentElement;return e}onTrigger(){const e=this._collapsible;e&&(e.open=!e.open,this.dispatchEvent(new CustomEvent("click-collapsible-event",{bubbles:!0,composed:!0})))}render(){const e=this.getFilteredAttributes();return l`
|
|
664
664
|
<div
|
|
665
665
|
@click=${this.onTrigger}
|
|
666
666
|
${xt(e)}
|
|
667
667
|
part="collapsible-trigger"
|
|
668
668
|
></div>
|
|
669
|
-
`}};hd=Vg([p("pont-collapsible-trigger")],hd);var Hg=Object.getOwnPropertyDescriptor,Gg=(e,t,r,o)=>{for(var n=o>1?void 0:o?Hg(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let ud=class extends
|
|
669
|
+
`}};hd=Vg([p("pont-collapsible-trigger")],hd);var Hg=Object.getOwnPropertyDescriptor,Gg=(e,t,r,o)=>{for(var n=o>1?void 0:o?Hg(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let ud=class extends _{constructor(){super(...arguments),this._toggleHandler=e=>{const t=e;requestAnimationFrame(()=>{const r=this._containerElement;r&&(r.style.display=t.detail.open?"block":"none")})}}get _containerElement(){return this.querySelector("div[part=collapsible-content]")}firstUpdated(e){this.moveLightDomChildrenInto(this._containerElement)}createRenderRoot(){return this}getAttributesToExclude(){return[""]}connectedCallback(){super.connectedCallback(),this.addEventListener("toggle-collapsible-content",this._toggleHandler)}disconnectedCallback(){this.removeEventListener("toggle-collapsible-content",this._toggleHandler),super.disconnectedCallback()}render(){const e=this.getFilteredAttributes();return l`
|
|
670
670
|
<div
|
|
671
671
|
${xt(e)}
|
|
672
672
|
class="${m("",this.className)}"
|
|
673
673
|
style="display: none;--radix-collapsible-content-height: 100px; --radix-collapsible-content-width: 350px;"
|
|
674
674
|
part="collapsible-content"
|
|
675
675
|
></div>
|
|
676
|
-
`}};ud=Gg([p("pont-collapsible-content")],ud);var Kg=Object.defineProperty,Wg=Object.getOwnPropertyDescriptor,zp=(e,t,r,o)=>{for(var n=o>1?void 0:o?Wg(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&Kg(t,r,n),n};let di=class extends
|
|
676
|
+
`}};ud=Gg([p("pont-collapsible-content")],ud);var Kg=Object.defineProperty,Wg=Object.getOwnPropertyDescriptor,zp=(e,t,r,o)=>{for(var n=o>1?void 0:o?Wg(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&Kg(t,r,n),n};let di=class extends _{constructor(){super(...arguments),this.open=!1,this._clickHandler=()=>{var e;(e=this.querySelector("pont-collapsible-content"))==null||e.dispatchEvent(new CustomEvent("toggle-collapsible-content",{detail:{open:this.open}}))}}getAttributesToExclude(){return[""]}createRenderRoot(){return this}get _containerElement(){return this.querySelector("div[part=collapsible]")}firstUpdated(e){this.moveLightDomChildrenInto(this._containerElement)}connectedCallback(){super.connectedCallback(),this.addEventListener("click-collapsible-event",this._clickHandler)}disconnectedCallback(){this.removeEventListener("click-collapsible-event",this._clickHandler),super.disconnectedCallback()}render(){const e=this.getFilteredAttributes();return l`
|
|
677
677
|
<div
|
|
678
678
|
${xt(e)}
|
|
679
679
|
class="${m("",this.className)}"
|
|
680
680
|
part="collapsible"
|
|
681
681
|
></div>
|
|
682
|
-
`}};zp([a({type:Boolean})],di.prototype,"open",2);di=zp([p("pont-collapsible")],di);const Bn={empty:["pont-py-combo-box-empty-space-py","pont-text-center","pont-text-combo-box-empty-font"],group:{base:["pont-pointer-events-none","pont-invisible","pont-absolute","pont-z-50","pont-mt-combo-box-group-space-mt","pont-max-h-combo-box-group-space-max-h","pont-w-combo-box-group-space-w","pont-origin-top","pont-scale-y-0","pont-transform","pont-overflow-hidden","pont-overflow-y-auto","pont-rounded-combo-box-group-radius","pont-border-combo-box-group-width-border","pont-border-combo-box-group-color-border","pont-bg-combo-box-group-color-bg","pont-px-combo-box-group-space-px","pont-py-combo-box-group-space-py","pont-opacity-0","pont-shadow-combo-box-group-shadow","pont-transition-opacity","pont-duration-combo-box-group-motion-duration","pont-ease-combo-box-group-motion-fn","[&::-webkit-scrollbar]:pont-w-0"]},input:["pont-flex","pont-h-combo-box-input-space-h","pont-w-combo-box-input-space-w","pont-rounded-combo-box-input-radius","pont-border-0","pont-bg-combo-box-input-color-bg","pont-px-combo-box-input-space-px","pont-py-combo-box-input-space-py","pont-text-combo-box-input-font","pont-text-combo-box-input-color-text","pont-shadow-none","placeholder:pont-text-combo-box-input-color-text-placeholder","focus:pont-outline-none","focus-visible:pont-ring-0"],trigger:{base:["pont-z-20","pont-flex","pont-h-combo-box-trigger-space-h","pont-flex-row-reverse","pont-items-center","pont-justify-between","pont-rounded-combo-box-trigger-radius","pont-border-combo-box-trigger-width-border","pont-border-combo-box-trigger-color-border","pont-bg-combo-box-trigger-color-bg","pont-px-combo-box-trigger-space-px","pont-py-combo-box-trigger-space-py","pont-text-combo-box-trigger-font","focus:pont-outline-none","focus:pont-ring-combo-box-trigger-width-ring-focus","focus:pont-ring-combo-box-trigger-color-ring-focus","focus:pont-ring-offset-combo-box-trigger-width-ring-offset-focus","disabled:pont-cursor-not-allowed","disabled:pont-opacity-combo-box-trigger-opacity-disabled"]},value:["pont-line-clamp-1","pont-flex","pont-w-combo-box-value-space-w"],item:{base:["pont-flex","pont-w-combo-box-item-space-w","pont-cursor-pointer","pont-flex-row-reverse","pont-items-center","pont-justify-between","pont-rounded-combo-box-item-radius","pont-px-combo-box-item-space-px","pont-py-combo-box-item-space-py","hover:pont-bg-accent","focus:pont-bg-combo-box-item-color-bg-hover","focus:pont-outline-none"]}};var Yg=Object.defineProperty,Qg=Object.getOwnPropertyDescriptor,Vp=(e,t,r,o)=>{for(var n=o>1?void 0:o?Qg(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&Yg(t,r,n),n};let Xs=class extends
|
|
682
|
+
`}};zp([a({type:Boolean})],di.prototype,"open",2);di=zp([p("pont-collapsible")],di);const Bn={empty:["pont-py-combo-box-empty-space-py","pont-text-center","pont-text-combo-box-empty-font"],group:{base:["pont-pointer-events-none","pont-invisible","pont-absolute","pont-z-50","pont-mt-combo-box-group-space-mt","pont-max-h-combo-box-group-space-max-h","pont-w-combo-box-group-space-w","pont-origin-top","pont-scale-y-0","pont-transform","pont-overflow-hidden","pont-overflow-y-auto","pont-rounded-combo-box-group-radius","pont-border-combo-box-group-width-border","pont-border-combo-box-group-color-border","pont-bg-combo-box-group-color-bg","pont-px-combo-box-group-space-px","pont-py-combo-box-group-space-py","pont-opacity-0","pont-shadow-combo-box-group-shadow","pont-transition-opacity","pont-duration-combo-box-group-motion-duration","pont-ease-combo-box-group-motion-fn","[&::-webkit-scrollbar]:pont-w-0"]},input:["pont-flex","pont-h-combo-box-input-space-h","pont-w-combo-box-input-space-w","pont-rounded-combo-box-input-radius","pont-border-0","pont-bg-combo-box-input-color-bg","pont-px-combo-box-input-space-px","pont-py-combo-box-input-space-py","pont-text-combo-box-input-font","pont-text-combo-box-input-color-text","pont-shadow-none","placeholder:pont-text-combo-box-input-color-text-placeholder","focus:pont-outline-none","focus-visible:pont-ring-0"],trigger:{base:["pont-z-20","pont-flex","pont-h-combo-box-trigger-space-h","pont-flex-row-reverse","pont-items-center","pont-justify-between","pont-rounded-combo-box-trigger-radius","pont-border-combo-box-trigger-width-border","pont-border-combo-box-trigger-color-border","pont-bg-combo-box-trigger-color-bg","pont-px-combo-box-trigger-space-px","pont-py-combo-box-trigger-space-py","pont-text-combo-box-trigger-font","focus:pont-outline-none","focus:pont-ring-combo-box-trigger-width-ring-focus","focus:pont-ring-combo-box-trigger-color-ring-focus","focus:pont-ring-offset-combo-box-trigger-width-ring-offset-focus","disabled:pont-cursor-not-allowed","disabled:pont-opacity-combo-box-trigger-opacity-disabled"]},value:["pont-line-clamp-1","pont-flex","pont-w-combo-box-value-space-w"],item:{base:["pont-flex","pont-w-combo-box-item-space-w","pont-cursor-pointer","pont-flex-row-reverse","pont-items-center","pont-justify-between","pont-rounded-combo-box-item-radius","pont-px-combo-box-item-space-px","pont-py-combo-box-item-space-py","hover:pont-bg-accent","focus:pont-bg-combo-box-item-color-bg-hover","focus:pont-outline-none"]}};var Yg=Object.defineProperty,Qg=Object.getOwnPropertyDescriptor,Vp=(e,t,r,o)=>{for(var n=o>1?void 0:o?Qg(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&Yg(t,r,n),n};let Xs=class extends _{constructor(){super(...arguments),this.handleClick=()=>{this._comboBox&&([...document.getElementsByTagName("pont-combo-box")].forEach(t=>{var r;t.uuid!==((r=this._comboBox)==null?void 0:r.uuid)&&(t.isOpen=!1)}),this._comboBox.isOpen=!this._comboBox.isOpen)}}get _comboBox(){let e=this.parentElement;for(;e&&!(e instanceof Ft);)e=e.parentElement;return e}getAttributesToExclude(){return[]}createRenderRoot(){return this}firstUpdated(e){super.firstUpdated(e),this.moveLightDomChildrenInto(this.buttonElement),this.addEventListener("click",t=>{t.stopPropagation()})}render(){return l`
|
|
683
683
|
<button
|
|
684
684
|
type="button"
|
|
685
685
|
part="combo-box-trigger-button"
|
|
@@ -707,7 +707,7 @@
|
|
|
707
707
|
role=${this.decorative?"none":"separator"}
|
|
708
708
|
aria-orientation=${this.decorative?h:this.orientation}
|
|
709
709
|
></div>
|
|
710
|
-
`}};Wa([a({type:String})],ci.prototype,"orientation",2);Wa([a({type:Boolean})],ci.prototype,"decorative",2);ci=Wa([p("pont-separator")],ci);var ef=Object.defineProperty,rf=Object.getOwnPropertyDescriptor,Io=(e,t,r,o)=>{for(var n=o>1?void 0:o?rf(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&ef(t,r,n),n};let qr=class extends
|
|
710
|
+
`}};Wa([a({type:String})],ci.prototype,"orientation",2);Wa([a({type:Boolean})],ci.prototype,"decorative",2);ci=Wa([p("pont-separator")],ci);var ef=Object.defineProperty,rf=Object.getOwnPropertyDescriptor,Io=(e,t,r,o)=>{for(var n=o>1?void 0:o?rf(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&ef(t,r,n),n};let qr=class extends _{constructor(){super(...arguments),this.searchKey="",this.focusedIndex=0,this.selectedValue="",this.isOpen=!1,this.handleItemClicked=()=>{this.requestUpdate()},this.handleTriggerComboBox=e=>{var t,r;e.detail.isOpen!==((t=this._comboBox)==null?void 0:t.isOpen)&&this.requestUpdate(),e.detail.isOpen&&((r=this._comboBox)!=null&&r.selectedValue)&&(this.focusedIndex=this.comboBoxItems.findIndex(o=>{var n;return o.getAttribute("value")===((n=this._comboBox)==null?void 0:n.selectedValue)}),this.requestUpdate())},this.handleKeyDown=e=>{var r;if(!((r=this._comboBox)!=null&&r.isOpen))return;e.preventDefault();const t=this.filteredItems;switch(e.key){case"ArrowDown":if(t.length===0)return;this.focusedIndex=(this.focusedIndex+1)%t.length;break;case"ArrowUp":if(t.length===0)return;this.focusedIndex=(this.focusedIndex-1+t.length)%t.length;break;case"Enter":if(this.focusedIndex>=0&&this.focusedIndex<t.length){const o=t[this.focusedIndex].getAttribute("value");this.dispatchEvent(new CustomEvent("clicked-combo-box-item",{bubbles:!0,composed:!0,detail:{selectedItem:o}}))}break}},this.handleMouseOver=(e,t)=>{e.preventDefault(),this.focusedIndex=t},this.onSelectedValue=(e,t)=>{this.focusedIndex=t,this.selectedValue=e},this.boundHandleComboBoxStateChanged=this.handleComboBoxStateChanged.bind(this),this.boundHandleKeyDown=this.handleKeyDown.bind(this)}get comboBoxItems(){return Array.from(this.querySelectorAll('[data-managed="true"][tag="pont-combo-box-item"], pont-combo-box-item')).filter(e=>e.hasAttribute("value"))}get comboBoxInput(){return this.querySelector("pont-combo-box-input")}get comboBoxEmpty(){return this.querySelector("pont-combo-box-empty")}get hasResults(){return!this.filteredItems.length}get filteredItems(){var t;const e=(t=this.searchKey)==null?void 0:t.toLowerCase();return this.comboBoxItems.filter(r=>{var o;return(o=r.getAttribute("value"))==null?void 0:o.toLowerCase().includes(e)})}get _comboBox(){let e=this.parentElement;for(;e&&!(e instanceof Ft);)e=e.parentElement;return e}handleComboBoxStateChanged(e){var n;const{isOpen:t,targetComboBoxId:r}=e.detail;if(this.isOpen=t,r!==((n=this._comboBox)==null?void 0:n.uuid))return;const o=this.renderRoot.querySelector('[part="select-group"]');o&&(t?(clearTimeout(o._hideTimeout),o.classList.remove("pont-scale-y-0","pont-opacity-0"),o.classList.add("pont-scale-y-100","pont-opacity-100"),o.classList.remove("pont-invisible","pont-pointer-events-none"),o.classList.add("pont-visible","pont-pointer-events-auto")):(o.classList.remove("pont-opacity-100"),o.classList.add("pont-opacity-0"),o._hideTimeout=setTimeout(()=>{o.classList.remove("pont-visible","pont-pointer-events-auto","pont-scale-y-100"),o.classList.add("pont-invisible","pont-pointer-events-none","pont-scale-y-0")},300)))}moveChildren(){const e=this.renderRoot.querySelector('[part="select-group"]');if(!e)return;const t={top:e.querySelector("#topSlot"),empty:e.querySelector("#emptySlot"),list:e.querySelector("#listSlot")},r={"pont-combo-box-input":"top","pont-combo-box-empty":"empty","pont-combo-box-item":"list"};Array.from(this.children).forEach(o=>{var s;const n=o.tagName.toLowerCase(),i=r[n];i&&(o.setAttribute("data-managed","true"),(s=t[i])==null||s.appendChild(o))})}renderFilteredItems(){return this.comboBoxItems.forEach(e=>e.setAttribute("hidden","true")),this.filteredItems.map((e,t)=>{var i;const r=e.getAttribute("value")??"",o=t===this.focusedIndex,n=r.toLowerCase()===((i=this._comboBox)==null?void 0:i.selectedValue.toLowerCase());return l`
|
|
711
711
|
<pont-combo-box-item
|
|
712
712
|
@mouseover="${s=>this.handleMouseOver(s,t)}"
|
|
713
713
|
.value=${r}
|
|
@@ -734,7 +734,7 @@
|
|
|
734
734
|
${this.renderFilteredItems()}
|
|
735
735
|
</div>
|
|
736
736
|
</div>
|
|
737
|
-
`}};Io([g()],qr.prototype,"searchKey",2);Io([g()],qr.prototype,"focusedIndex",2);Io([g()],qr.prototype,"selectedValue",2);Io([g()],qr.prototype,"isOpen",2);qr=Io([p("pont-combo-box-group")],qr);var nf=Object.defineProperty,of=Object.getOwnPropertyDescriptor,pe=(e,t,r,o)=>{for(var n=o>1?void 0:o?of(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&nf(t,r,n),n};let Wt=class extends
|
|
737
|
+
`}};Io([g()],qr.prototype,"searchKey",2);Io([g()],qr.prototype,"focusedIndex",2);Io([g()],qr.prototype,"selectedValue",2);Io([g()],qr.prototype,"isOpen",2);qr=Io([p("pont-combo-box-group")],qr);var nf=Object.defineProperty,of=Object.getOwnPropertyDescriptor,pe=(e,t,r,o)=>{for(var n=o>1?void 0:o?of(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&nf(t,r,n),n};let Wt=class extends _{constructor(){super(...arguments),this.value="",this.key="",this.tabindex=0,this.isSelected=!1,this.isFocus=!1,this.class="",this.selectItemIndex=-1,this.onSelect=(e,t)=>{},this.onMouseOver=(e,t)=>{},this.handleClick=e=>{this.onSelect(this.value,this.selectItemIndex),e.stopPropagation();const t=new CustomEvent("clicked-combo-box-item",{bubbles:!0,composed:!0,detail:{selectedItem:this.value}});this.dispatchEvent(t)}}getAttributesToExclude(){return["aria-orientation","role","data-orientation","data-testid"]}connectedCallback(){super.connectedCallback()}firstUpdated(e){this.moveLightDomChildrenInto(this.itemDivContainer)}createRenderRoot(){return this}render(){const e=this.getFilteredAttributes();return l`
|
|
738
738
|
<div
|
|
739
739
|
${xt(e)}
|
|
740
740
|
@click=${this.handleClick}
|
|
@@ -768,21 +768,21 @@
|
|
|
768
768
|
@keydown="${this.handleKeyDown}"
|
|
769
769
|
/>
|
|
770
770
|
</div>
|
|
771
|
-
`}};Ya([a({type:String})],pi.prototype,"placeholder",2);Ya([g()],pi.prototype,"searchValue",2);pi=Ya([p("pont-combo-box-input")],pi);var lf=Object.getOwnPropertyDescriptor,df=(e,t,r,o)=>{for(var n=o>1?void 0:o?lf(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let md=class extends
|
|
771
|
+
`}};Ya([a({type:String})],pi.prototype,"placeholder",2);Ya([g()],pi.prototype,"searchValue",2);pi=Ya([p("pont-combo-box-input")],pi);var lf=Object.getOwnPropertyDescriptor,df=(e,t,r,o)=>{for(var n=o>1?void 0:o?lf(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let md=class extends _{createRenderRoot(){return this}getAttributesToExclude(){return[]}firstUpdated(e){this.removeDuplicateContent()}render(){return l`
|
|
772
772
|
<div
|
|
773
773
|
class="${m(Bn.empty,this.className)}"
|
|
774
774
|
role="presentation"
|
|
775
775
|
>
|
|
776
776
|
${Array.from(this.childNodes)[0].textContent}
|
|
777
777
|
</div>
|
|
778
|
-
`}};md=df([p("pont-combo-box-empty")],md);var cf=Object.defineProperty,pf=Object.getOwnPropertyDescriptor,Ne=(e,t,r,o)=>{for(var n=o>1?void 0:o?pf(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&cf(t,r,n),n};let Ft=class extends
|
|
778
|
+
`}};md=df([p("pont-combo-box-empty")],md);var cf=Object.defineProperty,pf=Object.getOwnPropertyDescriptor,Ne=(e,t,r,o)=>{for(var n=o>1?void 0:o?pf(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&cf(t,r,n),n};let Ft=class extends _{constructor(){super(),this.isOpen=!1,this.selectedValue="",this.searchTerm="",this.focusedIndex=-1,this.filteredItems=[],this.uuid=za(),this.label="Select an item",this.items=[],this.handleClickOutside=e=>{var o;const t=(o=this.renderRoot)==null?void 0:o.querySelector("[data-combo-box-uuid]"),r=e.target;if(!r.tagName.includes("RTG-COMBO")&&!(r.shadowRoot&&r.shadowRoot.innerHTML.includes(t==null?void 0:t.innerHTML))){if(this.isOpen&&!t||!(t!=null&&t.contains(r)))this.isOpen=!1;else if(!(r==null?void 0:r.firstElementChild))return}}}connectedCallback(){super.connectedCallback(),document.addEventListener("clicked-combo-box-item",e=>{this.isOpen&&(this.selectedValue=e.detail.selectedItem,this.isOpen=!1,this.requestUpdate())})}getAttributesToExclude(){return[]}createRenderRoot(){return this}firstUpdated(e){this.moveLightDomChildrenInto(this.parentDiveElement),this.items&&this.items.length>0&&(this.filteredItems=this.items.filter(t=>t.toLowerCase().includes(this.searchTerm)))}updated(e){super.updated(e),e.has("isOpen")&&(this.dispatchEvent(new CustomEvent("pont-combo-box-state-changed",{detail:{isOpen:this.isOpen,targetComboBoxId:this.uuid},bubbles:!0,composed:!0})),this.isOpen?document.addEventListener("mousedown",this.handleClickOutside):document.removeEventListener("mousedown",this.handleClickOutside))}disconnectedCallback(){document.removeEventListener("mousedown",this.handleClickOutside),super.disconnectedCallback()}selectItem(e){const t=e.target;if(t instanceof HTMLElement){const r=t.closest("pont-combo-box-item");r?(this.selectedValue=r.getAttribute("data-hs-combo-box-value")||"",this.isOpen=!1):console.log("No valid pont-combo-box-item found")}else console.log("Event target is not an HTMLElement")}render(){return l`
|
|
779
779
|
<div
|
|
780
780
|
class="${m("pont-relative",this.className)}"
|
|
781
781
|
data-hs-combo-box=""
|
|
782
782
|
data-combo-box-uuid=${this.uuid}
|
|
783
783
|
part="combo-box"
|
|
784
784
|
></div>
|
|
785
|
-
`}};Ne([a({type:Boolean})],Ft.prototype,"isOpen",2);Ne([g()],Ft.prototype,"selectedValue",2);Ne([g()],Ft.prototype,"searchTerm",2);Ne([g()],Ft.prototype,"focusedIndex",2);Ne([g()],Ft.prototype,"filteredItems",2);Ne([g()],Ft.prototype,"uuid",2);Ne([a({type:String})],Ft.prototype,"label",2);Ne([a({type:Array})],Ft.prototype,"items",2);Ne([So('[part="combo-box"]')],Ft.prototype,"parentDiveElement",2);Ft=Ne([p("pont-combo-box")],Ft);const xe={root:["pont-flex pont-overflow-hidden","pont-flex-col","pont-w-command-space-w pont-h-command-space-h","pont-text-command-color-text","pont-bg-command-color-bg","pont-rounded-command-radius"],input:{wrapper:["pont-flex","pont-gap-command-input-wrapper-space-gap pont-items-center","pont-px-command-input-wrapper-space-px","pont-h-command-input-wrapper-space-h","pont-border-b-command-input-wrapper-width-border pont-border-b-command-input-wrapper-color-border"],icon:["pont-shrink-0","pont-size-command-input-icon-space-size","pont-opacity-command-input-icon-opacity"],input:["pont-flex","pont-py-command-input-space-py","pont-w-command-input-space-w pont-h-command-input-space-h","pont-text-command-input-font","pont-bg-command-input-color-bg","pont-rounded-command-input-radius pont-outline-hidden","focus:pont-outline-none","disabled:pont-opacity-command-input-opacity-disabled disabled:pont-cursor-not-allowed","placeholder:pont-text-command-input-placeholder-color-text"]},list:["pont-overflow-x-hidden pont-overflow-y-auto","pont-max-h-command-list-space-max-h","pont-scroll-py-1"],empty:["pont-py-command-empty-space-py","pont-text-command-empty-font pont-text-center"],group:["pont-overflow-hidden","pont-p-command-group-space-p","pont-text-command-group-color-text"],heading:["pont-px-command-heading-space-px pont-py-command-heading-space-py","pont-text-command-heading-font pont-font-command-heading-font-weight pont-text-command-heading-color-text"],separator:["pont-command-separator-space-mx","pont-h-command-separator-space-h","pont-bg-command-separator-color-bg"],item:["pont-flex pont-relative","pont-gap-command-item-space-gap pont-items-center","pont-px-command-item-space-px pont-py-command-item-space-py","pont-text-command-item-font","pont-rounded-command-item-radius pont-outline-hidden","pont-cursor-default pont-select-none","hover:pont-text-command-item-color-text-hover hover:pont-bg-command-item-color-bg-hover","aria-selected:pont-text-command-item-color-text-selected aria-selected:pont-bg-command-item-color-bg-selected",'data-[disabled="true"]:pont-opacity-command-item-opacity-disabled data-[disabled="true"]:pont-pointer-events-none','[&_svg]:pont-shrink-0 [&_svg:not([class*="pont-size-"])]:pont-size-command-item-icon-space-size [&_svg:not([class*="pont-text-"])]:pont-text-command-item-icon-color-text [&_svg]:pont-pointer-events-none']};var hf=Object.defineProperty,uf=Object.getOwnPropertyDescriptor,Qa=(e,t,r,o)=>{for(var n=o>1?void 0:o?uf(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&hf(t,r,n),n};let jr=class extends
|
|
785
|
+
`}};Ne([a({type:Boolean})],Ft.prototype,"isOpen",2);Ne([g()],Ft.prototype,"selectedValue",2);Ne([g()],Ft.prototype,"searchTerm",2);Ne([g()],Ft.prototype,"focusedIndex",2);Ne([g()],Ft.prototype,"filteredItems",2);Ne([g()],Ft.prototype,"uuid",2);Ne([a({type:String})],Ft.prototype,"label",2);Ne([a({type:Array})],Ft.prototype,"items",2);Ne([So('[part="combo-box"]')],Ft.prototype,"parentDiveElement",2);Ft=Ne([p("pont-combo-box")],Ft);const xe={root:["pont-flex pont-overflow-hidden","pont-flex-col","pont-w-command-space-w pont-h-command-space-h","pont-text-command-color-text","pont-bg-command-color-bg","pont-rounded-command-radius"],input:{wrapper:["pont-flex","pont-gap-command-input-wrapper-space-gap pont-items-center","pont-px-command-input-wrapper-space-px","pont-h-command-input-wrapper-space-h","pont-border-b-command-input-wrapper-width-border pont-border-b-command-input-wrapper-color-border"],icon:["pont-shrink-0","pont-size-command-input-icon-space-size","pont-opacity-command-input-icon-opacity"],input:["pont-flex","pont-py-command-input-space-py","pont-w-command-input-space-w pont-h-command-input-space-h","pont-text-command-input-font","pont-bg-command-input-color-bg","pont-rounded-command-input-radius pont-outline-hidden","focus:pont-outline-none","disabled:pont-opacity-command-input-opacity-disabled disabled:pont-cursor-not-allowed","placeholder:pont-text-command-input-placeholder-color-text"]},list:["pont-overflow-x-hidden pont-overflow-y-auto","pont-max-h-command-list-space-max-h","pont-scroll-py-1"],empty:["pont-py-command-empty-space-py","pont-text-command-empty-font pont-text-center"],group:["pont-overflow-hidden","pont-p-command-group-space-p","pont-text-command-group-color-text"],heading:["pont-px-command-heading-space-px pont-py-command-heading-space-py","pont-text-command-heading-font pont-font-command-heading-font-weight pont-text-command-heading-color-text"],separator:["pont-command-separator-space-mx","pont-h-command-separator-space-h","pont-bg-command-separator-color-bg"],item:["pont-flex pont-relative","pont-gap-command-item-space-gap pont-items-center","pont-px-command-item-space-px pont-py-command-item-space-py","pont-text-command-item-font","pont-rounded-command-item-radius pont-outline-hidden","pont-cursor-default pont-select-none","hover:pont-text-command-item-color-text-hover hover:pont-bg-command-item-color-bg-hover","aria-selected:pont-text-command-item-color-text-selected aria-selected:pont-bg-command-item-color-bg-selected",'data-[disabled="true"]:pont-opacity-command-item-opacity-disabled data-[disabled="true"]:pont-pointer-events-none','[&_svg]:pont-shrink-0 [&_svg:not([class*="pont-size-"])]:pont-size-command-item-icon-space-size [&_svg:not([class*="pont-text-"])]:pont-text-command-item-icon-color-text [&_svg]:pont-pointer-events-none']};var hf=Object.defineProperty,uf=Object.getOwnPropertyDescriptor,Qa=(e,t,r,o)=>{for(var n=o>1?void 0:o?uf(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&hf(t,r,n),n};let jr=class extends _{constructor(){super(...arguments),this._id="",this._hidden="true"}get containerElement(){return this.querySelector(`#${this.identifier}`)}get identifier(){if(this._id!=="")return this._id;const e=this.parentElement;return e?this._id=`${e.getAttribute("id")}e${jr._counter++}`:this._id=`rtgcmdrxlxe${jr._counter++}`,this._id}getAttributesToExclude(){return[]}createRenderRoot(){return this}firstUpdated(e){this.moveLightDomChildrenInto(this.containerElement)}render(){return l`
|
|
786
786
|
<div
|
|
787
787
|
rtgcmd-empty
|
|
788
788
|
id="${this.identifier}"
|
|
@@ -790,7 +790,7 @@
|
|
|
790
790
|
role="presentation"
|
|
791
791
|
class=${m(xe.empty,this._hidden==="true"&&"pont-hidden",this.className)}
|
|
792
792
|
></div>
|
|
793
|
-
`}};jr._counter=0;Qa([a({type:String})],jr.prototype,"_id",2);Qa([a({attribute:"aria-hidden",type:String})],jr.prototype,"_hidden",2);jr=Qa([p("pont-command-empty")],jr);var mf=Object.defineProperty,gf=Object.getOwnPropertyDescriptor,ki=(e,t,r,o)=>{for(var n=o>1?void 0:o?gf(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&mf(t,r,n),n};let br=class extends
|
|
793
|
+
`}};jr._counter=0;Qa([a({type:String})],jr.prototype,"_id",2);Qa([a({attribute:"aria-hidden",type:String})],jr.prototype,"_hidden",2);jr=Qa([p("pont-command-empty")],jr);var mf=Object.defineProperty,gf=Object.getOwnPropertyDescriptor,ki=(e,t,r,o)=>{for(var n=o>1?void 0:o?gf(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&mf(t,r,n),n};let br=class extends _{constructor(){super(...arguments),this.heading="",this._id="",this._hidden=""}get itemsContainerElement(){return this.querySelector(`#${this.identifier}g`)}get identifier(){if(this._id!=="")return this._id;const e=this.parentElement;return e?this._id=`${e.getAttribute("id")}g${br._counter++}`:this._id=`rtgcmdrxlxg${br._counter++}`,this._id}createRenderRoot(){return this}getAttributesToExclude(){return[]}firstUpdated(e){const t=this.itemsContainerElement;if(t){for(;t.firstChild;)t.removeChild(t.firstChild);this.moveLightDomChildrenInto(t)}}render(){return l`
|
|
794
794
|
<div
|
|
795
795
|
rtgcmd-group
|
|
796
796
|
id="${this.identifier}"
|
|
@@ -854,7 +854,7 @@
|
|
|
854
854
|
class=${m(xe.input.input)}
|
|
855
855
|
/>
|
|
856
856
|
</div>
|
|
857
|
-
`}};Za([a({type:String})],hi.prototype,"placeholder",2);Za([a({attribute:"value",type:String})],hi.prototype,"_value",2);hi=Za([p("pont-command-input")],hi);var bf=Object.defineProperty,yf=Object.getOwnPropertyDescriptor,Un=(e,t,r,o)=>{for(var n=o>1?void 0:o?yf(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&bf(t,r,n),n};let Ae=class extends
|
|
857
|
+
`}};Za([a({type:String})],hi.prototype,"placeholder",2);Za([a({attribute:"value",type:String})],hi.prototype,"_value",2);hi=Za([p("pont-command-input")],hi);var bf=Object.defineProperty,yf=Object.getOwnPropertyDescriptor,Un=(e,t,r,o)=>{for(var n=o>1?void 0:o?yf(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&bf(t,r,n),n};let Ae=class extends _{constructor(){super(...arguments),this.selected=!1,this._id="",this._hidden="false",this.onSelect=()=>{},this.disabled="false"}get containerElement(){return this.querySelector(`#${this.identifier}`)}get identifier(){if(this._id!=="")return this._id;const e=this.parentElement;return e?this._id=`${e.getAttribute("id")}li${Ae._counter++}`:this._id=`rtgcmdrxgxli${Ae._counter++}`,this._id}get value(){var e;return((e=this.textContent)==null?void 0:e.trim())||""}handleMouseEvent(e){(e.type==="mouseover"||e.type==="focus")&&(this.selected=!0),e.type==="mouseleave"&&(this.selected=!1)}createRenderRoot(){return this}getAttributesToExclude(){return[]}firstUpdated(e){this.moveLightDomChildrenInto(this.containerElement)}updated(e){}render(){return l`
|
|
858
858
|
<div
|
|
859
859
|
rtgcmd-item
|
|
860
860
|
id="${this.identifier}"
|
|
@@ -871,7 +871,7 @@
|
|
|
871
871
|
@click="${this.onSelect}"
|
|
872
872
|
class=${m(xe.item,this._hidden==="true"&&"pont-hidden",this.className)}
|
|
873
873
|
></div>
|
|
874
|
-
`}};Ae._counter=0;Un([a({type:String})],Ae.prototype,"_id",2);Un([a({attribute:"aria-hidden",type:String})],Ae.prototype,"_hidden",2);Un([a({type:Function})],Ae.prototype,"onSelect",2);Un([a({attribute:"data-value",type:String}),a({type:Boolean})],Ae.prototype,"containerElement",1);Un([a({attribute:"data-disabled",type:String})],Ae.prototype,"disabled",2);Ae=Un([p("pont-command-item")],Ae);var _f=Object.getOwnPropertyDescriptor,wf=(e,t,r,o)=>{for(var n=o>1?void 0:o?_f(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let gd=class extends
|
|
874
|
+
`}};Ae._counter=0;Un([a({type:String})],Ae.prototype,"_id",2);Un([a({attribute:"aria-hidden",type:String})],Ae.prototype,"_hidden",2);Un([a({type:Function})],Ae.prototype,"onSelect",2);Un([a({attribute:"data-value",type:String}),a({type:Boolean})],Ae.prototype,"containerElement",1);Un([a({attribute:"data-disabled",type:String})],Ae.prototype,"disabled",2);Ae=Un([p("pont-command-item")],Ae);var _f=Object.getOwnPropertyDescriptor,wf=(e,t,r,o)=>{for(var n=o>1?void 0:o?_f(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let gd=class extends _{get identifier(){const e=this.parentElement;return e?`${e.getAttribute("id")}l`:"rtgcmdrxl"}get containerElement(){return this.querySelector("div[rtgcmd-list]")}createRenderRoot(){return this}getAttributesToExclude(){return[]}firstUpdated(e){this.moveLightDomChildrenInto(this.containerElement)}render(){return l`
|
|
875
875
|
<div
|
|
876
876
|
rtgcmd-list
|
|
877
877
|
id="${this.identifier}"
|
|
@@ -889,7 +889,7 @@
|
|
|
889
889
|
role="separator"
|
|
890
890
|
class=${m(xe.separator,this.className)}
|
|
891
891
|
></div>
|
|
892
|
-
`}`}};zr._counter=0;Ja([a({type:String})],zr.prototype,"_id",2);Ja([a({attribute:"aria-hidden",type:String})],zr.prototype,"_hidden",2);zr=Ja([p("pont-command-separator")],zr);var Cf=Object.getOwnPropertyDescriptor,Ef=(e,t,r,o)=>{for(var n=o>1?void 0:o?Cf(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let fd=class extends
|
|
892
|
+
`}`}};zr._counter=0;Ja([a({type:String})],zr.prototype,"_id",2);Ja([a({attribute:"aria-hidden",type:String})],zr.prototype,"_hidden",2);zr=Ja([p("pont-command-separator")],zr);var Cf=Object.getOwnPropertyDescriptor,Ef=(e,t,r,o)=>{for(var n=o>1?void 0:o?Cf(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let fd=class extends _{get containerElement(){return this.querySelector("div[rtgcmd-root]")}getAttributesToExclude(){return[]}getAttributesToRemoveFromParent(){return["class","style"]}createRenderRoot(){return this}firstUpdated(e){this.removeParentAttributes(),this.moveLightDomChildrenInto(this.containerElement),this.containerElement&&this.observeStyleAndClassSync(this.containerElement)}render(){const e=this.customClass||"",t=this.customStyle||"";return l`
|
|
893
893
|
<div
|
|
894
894
|
part="command"
|
|
895
895
|
class="${m(xe.root,e)}"
|
|
@@ -897,7 +897,7 @@
|
|
|
897
897
|
id="rtgcmdr1"
|
|
898
898
|
rtgcmd-root
|
|
899
899
|
></div>
|
|
900
|
-
`}};fd=Ef([p("pont-command")],fd);const Dt={root:[""],content:["pont-overflow-x-hidden pont-overflow-y-auto pont-z-50","pont-p-context-menu-content-space-p","pont-min-w-context-menu-content-space-min-w","pont-text-context-menu-content-color-text","pont-bg-context-menu-content-color-bg","pont-rounded-context-menu-content-radius pont-border-context-menu-content-width-border pont-border-context-menu-content-color-border","pont-shadow-context-menu-content-shadow","pont-translate-y-0.5","pont-slide-in-from-top-2","data-[state=open]:pont-animate-in data-[state=open]:pont-fade-in-0 data-[state=open]:pont-zoom-in-95","data-[state=closed]:pont-animate-out data-[state=closed]:pont-fade-out-0 data-[state=closed]:pont-zoom-out-95"],group:[""],item:["pont-flex pont-relative","pont-gap-context-menu-item-space-gap pont-items-center","pont-px-context-menu-item-space-px pont-py-context-menu-item-space-py","pont-text-context-menu-item-font","pont-rounded-context-menu-item-radius pont-outline-hidden","pont-cursor-default","pont-select-none","hover:pont-bg-context-menu-item-color-bg-hover hover:pont-text-context-menu-item-color-text-hover","focus:pont-bg-context-menu-item-color-bg-focus focus:pont-text-context-menu-item-color-text-focus","data-[disabled]:pont-opacity-context-menu-item-opacity-disabled data-[disabled]:pont-pointer-events-none",'[&_svg]:pont-shrink-0 [&_svg:not([class*="pont-size-"])]:pont-size-context-menu-item-icon-space-size [&_svg:not([class*="pont-text-"])]:pont-text-context-menu-item-icon-color-text [&_svg]:pont-pointer-events-none'],checkboxItem:{base:["pont-flex pont-relative","pont-gap-context-menu-checkbox-item-space-gap pont-items-center","pont-pl-context-menu-checkbox-item-space-pl pont-pr-context-menu-checkbox-item-space-pr pont-py-context-menu-checkbox-item-space-py","pont-text-context-menu-checkbox-item-font","pont-rounded-context-menu-checkbox-item-radius pont-outline-hidden","pont-cursor-default","pont-select-none","aria-selected:pont-bg-context-menu-checkbox-item-color-bg-focus aria-selected:pont-text-context-menu-checkbox-item-color-text-focus","data-[disabled]:pont-opacity-context-menu-checkbox-item-opacity-disabled data-[disabled]:pont-pointer-events-none"],span:["pont-flex pont-absolute pont-left-2","pont-justify-center pont-items-center","pont-size-context-menu-checkbox-item-icon-container-space-size","pont-pointer-events-none"],icon:["pont-shrink-0","pont-size-context-menu-checkbox-item-icon-space-size","pont-pointer-events-none"]},radioItem:{base:["pont-flex pont-relative","pont-gap-context-menu-radio-item-space-gap pont-items-center","pont-pl-context-menu-radio-item-space-pl pont-pr-context-menu-radio-item-space-pr pont-py-context-menu-radio-item-space-py","pont-text-context-menu-radio-item-font","pont-rounded-context-menu-radio-item-radius pont-outline-hidden","pont-cursor-default","pont-select-none","aria-selected:pont-bg-context-menu-radio-item-color-bg-focus aria-selected:pont-text-context-menu-radio-item-color-text-focus","data-[disabled]:pont-opacity-context-menu-radio-item-opacity-disabled data-[disabled]:pont-pointer-events-none"],span:["pont-flex pont-absolute pont-left-2","pont-justify-center pont-items-center","pont-size-context-menu-radio-item-icon-container-space-size","pont-pointer-events-none"],icon:["pont-shrink-0","pont-size-context-menu-radio-item-icon-space-size","pont-pointer-events-none","pont-fill-current"]},label:["pont-px-context-menu-label-space-px pont-py-context-menu-label-space-py","pont-text-context-menu-label-font pont-font-context-menu-label-font-weight"],separator:["pont-mx-context-menu-separator-space-mx pont-my-context-menu-separator-space-my","pont-h-context-menu-separator-space-h","pont-bg-context-menu-separator-color-bg"],shortcut:["pont-ml-auto","pont-text-context-menu-shortcut-font pont-text-context-menu-shortcut-color-text"]};var Sf=Object.defineProperty,xf=Object.getOwnPropertyDescriptor,qn=(e,t,r,o)=>{for(var n=o>1?void 0:o?xf(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&Sf(t,r,n),n};let Vr=class extends
|
|
900
|
+
`}};fd=Ef([p("pont-command")],fd);const Dt={root:[""],content:["pont-overflow-x-hidden pont-overflow-y-auto pont-z-50","pont-p-context-menu-content-space-p","pont-min-w-context-menu-content-space-min-w","pont-text-context-menu-content-color-text","pont-bg-context-menu-content-color-bg","pont-rounded-context-menu-content-radius pont-border-context-menu-content-width-border pont-border-context-menu-content-color-border","pont-shadow-context-menu-content-shadow","pont-translate-y-0.5","pont-slide-in-from-top-2","data-[state=open]:pont-animate-in data-[state=open]:pont-fade-in-0 data-[state=open]:pont-zoom-in-95","data-[state=closed]:pont-animate-out data-[state=closed]:pont-fade-out-0 data-[state=closed]:pont-zoom-out-95"],group:[""],item:["pont-flex pont-relative","pont-gap-context-menu-item-space-gap pont-items-center","pont-px-context-menu-item-space-px pont-py-context-menu-item-space-py","pont-text-context-menu-item-font","pont-rounded-context-menu-item-radius pont-outline-hidden","pont-cursor-default","pont-select-none","hover:pont-bg-context-menu-item-color-bg-hover hover:pont-text-context-menu-item-color-text-hover","focus:pont-bg-context-menu-item-color-bg-focus focus:pont-text-context-menu-item-color-text-focus","data-[disabled]:pont-opacity-context-menu-item-opacity-disabled data-[disabled]:pont-pointer-events-none",'[&_svg]:pont-shrink-0 [&_svg:not([class*="pont-size-"])]:pont-size-context-menu-item-icon-space-size [&_svg:not([class*="pont-text-"])]:pont-text-context-menu-item-icon-color-text [&_svg]:pont-pointer-events-none'],checkboxItem:{base:["pont-flex pont-relative","pont-gap-context-menu-checkbox-item-space-gap pont-items-center","pont-pl-context-menu-checkbox-item-space-pl pont-pr-context-menu-checkbox-item-space-pr pont-py-context-menu-checkbox-item-space-py","pont-text-context-menu-checkbox-item-font","pont-rounded-context-menu-checkbox-item-radius pont-outline-hidden","pont-cursor-default","pont-select-none","aria-selected:pont-bg-context-menu-checkbox-item-color-bg-focus aria-selected:pont-text-context-menu-checkbox-item-color-text-focus","data-[disabled]:pont-opacity-context-menu-checkbox-item-opacity-disabled data-[disabled]:pont-pointer-events-none"],span:["pont-flex pont-absolute pont-left-2","pont-justify-center pont-items-center","pont-size-context-menu-checkbox-item-icon-container-space-size","pont-pointer-events-none"],icon:["pont-shrink-0","pont-size-context-menu-checkbox-item-icon-space-size","pont-pointer-events-none"]},radioItem:{base:["pont-flex pont-relative","pont-gap-context-menu-radio-item-space-gap pont-items-center","pont-pl-context-menu-radio-item-space-pl pont-pr-context-menu-radio-item-space-pr pont-py-context-menu-radio-item-space-py","pont-text-context-menu-radio-item-font","pont-rounded-context-menu-radio-item-radius pont-outline-hidden","pont-cursor-default","pont-select-none","aria-selected:pont-bg-context-menu-radio-item-color-bg-focus aria-selected:pont-text-context-menu-radio-item-color-text-focus","data-[disabled]:pont-opacity-context-menu-radio-item-opacity-disabled data-[disabled]:pont-pointer-events-none"],span:["pont-flex pont-absolute pont-left-2","pont-justify-center pont-items-center","pont-size-context-menu-radio-item-icon-container-space-size","pont-pointer-events-none"],icon:["pont-shrink-0","pont-size-context-menu-radio-item-icon-space-size","pont-pointer-events-none","pont-fill-current"]},label:["pont-px-context-menu-label-space-px pont-py-context-menu-label-space-py","pont-text-context-menu-label-font pont-font-context-menu-label-font-weight"],separator:["pont-mx-context-menu-separator-space-mx pont-my-context-menu-separator-space-my","pont-h-context-menu-separator-space-h","pont-bg-context-menu-separator-color-bg"],shortcut:["pont-ml-auto","pont-text-context-menu-shortcut-font pont-text-context-menu-shortcut-color-text"]};var Sf=Object.defineProperty,xf=Object.getOwnPropertyDescriptor,qn=(e,t,r,o)=>{for(var n=o>1?void 0:o?xf(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&Sf(t,r,n),n};let Vr=class extends _{constructor(){super(...arguments),this._id="",this.selected=!1,this.checked=!1,this.disabled=!1}get value(){var e;return((e=this.textContent)==null?void 0:e.trim())||""}get _containerElement(){return this.querySelector("div[part=context-menu-checkbox-item-container]")}getAttributesToExclude(){return["data-testid"]}handleMouseEvent(e){(e.type==="mouseover"||e.type==="focus")&&(this.selected=!0),e.type==="mouseleave"&&(this.selected=!1)}toggleChecked(){this.checked=!this.checked}createRenderRoot(){return this}firstUpdated(e){this.moveLightDomChildrenInto(this._containerElement)}render(){return l`
|
|
901
901
|
<div
|
|
902
902
|
rtgcmd-item
|
|
903
903
|
part="context-menu-checkbox"
|
|
@@ -932,12 +932,12 @@
|
|
|
932
932
|
</span>
|
|
933
933
|
<div part="context-menu-checkbox-item-container"></div>
|
|
934
934
|
</div>
|
|
935
|
-
`}};qn([a({type:String})],Vr.prototype,"_id",2);qn([a({attribute:"data-value",type:String})],Vr.prototype,"value",1);qn([a({type:Boolean})],Vr.prototype,"selected",2);qn([a({type:Boolean})],Vr.prototype,"checked",2);qn([a({attribute:"data-disabled",type:Boolean})],Vr.prototype,"disabled",2);Vr=qn([p("pont-context-menu-checkbox-item")],Vr);var Of=Object.defineProperty,Rf=Object.getOwnPropertyDescriptor,Gp=(e,t,r,o)=>{for(var n=o>1?void 0:o?Rf(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&Of(t,r,n),n};let ea=class extends
|
|
935
|
+
`}};qn([a({type:String})],Vr.prototype,"_id",2);qn([a({attribute:"data-value",type:String})],Vr.prototype,"value",1);qn([a({type:Boolean})],Vr.prototype,"selected",2);qn([a({type:Boolean})],Vr.prototype,"checked",2);qn([a({attribute:"data-disabled",type:Boolean})],Vr.prototype,"disabled",2);Vr=qn([p("pont-context-menu-checkbox-item")],Vr);var Of=Object.defineProperty,Rf=Object.getOwnPropertyDescriptor,Gp=(e,t,r,o)=>{for(var n=o>1?void 0:o?Rf(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&Of(t,r,n),n};let ea=class extends _{constructor(){super(),this.isOpen=!1,this.handleClickOutside=this.handleClickOutside.bind(this)}get _containerElement(){return this.querySelector("div[part=context-menu-content")}connectedCallback(){super.connectedCallback(),document.addEventListener("click",this.handleClickOutside)}disconnectedCallback(){document.removeEventListener("click",this.handleClickOutside),super.disconnectedCallback()}handleClickOutside(e){const t=this==null?void 0:this.querySelector("button");!this.contains(e.target)&&!(t!=null&&t.contains(e.target))&&requestAnimationFrame(()=>{this._containerElement.style.display="none",this._containerElement.style.position="absolute",this._containerElement.dataset.state="closed",this.isOpen=!1})}getAttributesToExclude(){return[]}createRenderRoot(){return this}firstUpdated(e){this.moveLightDomChildrenInto(this._containerElement)}render(){return l`
|
|
936
936
|
<div
|
|
937
937
|
part="context-menu-content"
|
|
938
938
|
class=${m(Dt.content,this.className)}
|
|
939
939
|
></div>
|
|
940
|
-
`}};Gp([g()],ea.prototype,"isOpen",2);ea=Gp([p("pont-context-menu-content")],ea);var If=Object.defineProperty,Af=Object.getOwnPropertyDescriptor,Kp=(e,t,r,o)=>{for(var n=o>1?void 0:o?Af(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&If(t,r,n),n};let ra=class extends
|
|
940
|
+
`}};Gp([g()],ea.prototype,"isOpen",2);ea=Gp([p("pont-context-menu-content")],ea);var If=Object.defineProperty,Af=Object.getOwnPropertyDescriptor,Kp=(e,t,r,o)=>{for(var n=o>1?void 0:o?Af(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&If(t,r,n),n};let ra=class extends _{constructor(){super(...arguments),this.heading=""}get _containerElement(){return this.querySelector("div[ rtgcontext-group-items]")}createRenderRoot(){return this}getAttributesToExclude(){return["data-testid"]}firstUpdated(e){this.moveLightDomChildrenInto(this._containerElement)}render(){return l`
|
|
941
941
|
<div
|
|
942
942
|
rtgcmd-group
|
|
943
943
|
part="context-menu-group"
|
|
@@ -950,7 +950,7 @@
|
|
|
950
950
|
|
|
951
951
|
<div rtgcontext-group-items role="group"></div>
|
|
952
952
|
</div>
|
|
953
|
-
`}};Kp([a({type:String})],ra.prototype,"heading",2);ra=Kp([p("pont-context-menu-group")],ra);var Tf=Object.defineProperty,Df=Object.getOwnPropertyDescriptor,Xa=(e,t,r,o)=>{for(var n=o>1?void 0:o?Df(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&Tf(t,r,n),n};let ui=class extends
|
|
953
|
+
`}};Kp([a({type:String})],ra.prototype,"heading",2);ra=Kp([p("pont-context-menu-group")],ra);var Tf=Object.defineProperty,Df=Object.getOwnPropertyDescriptor,Xa=(e,t,r,o)=>{for(var n=o>1?void 0:o?Df(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&Tf(t,r,n),n};let ui=class extends _{constructor(){super(...arguments),this.disabled=!1}get _containerElement(){return this.querySelector("div[part=context-menu-item]")}getAttributesToExclude(){return[]}get value(){var e;return((e=this.textContent)==null?void 0:e.trim())||""}firstUpdated(e){var t;this.moveLightDomChildrenInto(this._containerElement),(t=this._containerElement)==null||t.addEventListener("click",()=>{this.dispatchEvent(new MouseEvent("click",{bubbles:!0,composed:!0,cancelable:!0})),this.dispatchEvent(new CustomEvent("close-context-menu",{bubbles:!0,composed:!0}))})}connectedCallback(){super.connectedCallback()}disconnectedCallback(){}createRenderRoot(){return this}render(){return l`
|
|
954
954
|
<div
|
|
955
955
|
part="context-menu-item"
|
|
956
956
|
role="option"
|
|
@@ -958,7 +958,7 @@
|
|
|
958
958
|
?data-disabled=${this.disabled}
|
|
959
959
|
class=${m(Dt.item,this.className)}
|
|
960
960
|
></div>
|
|
961
|
-
`}};Xa([a({attribute:"data-value",type:String})],ui.prototype,"value",1);Xa([a({attribute:"data-disabled",type:Boolean})],ui.prototype,"disabled",2);ui=Xa([p("pont-context-menu-item")],ui);var Lf=Object.defineProperty,Ff=Object.getOwnPropertyDescriptor,jn=(e,t,r,o)=>{for(var n=o>1?void 0:o?Ff(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&Lf(t,r,n),n};let Hr=class extends
|
|
961
|
+
`}};Xa([a({attribute:"data-value",type:String})],ui.prototype,"value",1);Xa([a({attribute:"data-disabled",type:Boolean})],ui.prototype,"disabled",2);ui=Xa([p("pont-context-menu-item")],ui);var Lf=Object.defineProperty,Ff=Object.getOwnPropertyDescriptor,jn=(e,t,r,o)=>{for(var n=o>1?void 0:o?Ff(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&Lf(t,r,n),n};let Hr=class extends _{constructor(){super(...arguments),this._id="",this.selected=!1,this.checked=!1,this.disabled=!1}get value(){var e;return((e=this.textContent)==null?void 0:e.trim())||""}get _containerElement(){return this.querySelector("div[part=context-menu-radio-item-container]")}getAttributesToExclude(){return["data-testid"]}handleMouseEvent(e){(e.type==="mouseover"||e.type==="focus")&&(this.selected=!0),e.type==="mouseleave"&&(this.selected=!1)}toggleChecked(){this.checked||(this.checked=!0,this.dispatchEvent(new CustomEvent("radio-selected",{bubbles:!0,composed:!0})))}createRenderRoot(){return this}firstUpdated(e){this.moveLightDomChildrenInto(this._containerElement)}render(){return l`
|
|
962
962
|
<div
|
|
963
963
|
rtgcmd-item
|
|
964
964
|
part="context-menu-radio"
|
|
@@ -998,30 +998,30 @@
|
|
|
998
998
|
role="separator"
|
|
999
999
|
class=${m(Dt.separator,this.className)}
|
|
1000
1000
|
></div>
|
|
1001
|
-
`}};Wp([a({type:String})],na.prototype,"_id",2);na=Wp([p("pont-context-menu-separator")],na);var Mf=Object.getOwnPropertyDescriptor,Bf=(e,t,r,o)=>{for(var n=o>1?void 0:o?Mf(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let vd=class extends
|
|
1001
|
+
`}};Wp([a({type:String})],na.prototype,"_id",2);na=Wp([p("pont-context-menu-separator")],na);var Mf=Object.getOwnPropertyDescriptor,Bf=(e,t,r,o)=>{for(var n=o>1?void 0:o?Mf(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let vd=class extends _{get _containerElement(){return this.querySelector("span[part=context-menu-shortcut]")}getAttributesToExclude(){return[]}createRenderRoot(){return this.classList=m(Dt.shortcut),this}firstUpdated(e){this.moveLightDomChildrenInto(this._containerElement)}render(){return l`
|
|
1002
1002
|
<span
|
|
1003
1003
|
part="context-menu-shortcut"
|
|
1004
1004
|
class=${m(Dt.shortcut,this.className)}
|
|
1005
1005
|
>
|
|
1006
1006
|
</span>
|
|
1007
|
-
`}};vd=Bf([p("pont-context-menu-shortcut")],vd);var Uf=Object.getOwnPropertyDescriptor,qf=(e,t,r,o)=>{for(var n=o>1?void 0:o?Uf(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let bd=class extends f{createRenderRoot(){return this}render(){return l``}};bd=qf([p("pont-context-menu-trigger")],bd);var jf=Object.defineProperty,zf=Object.getOwnPropertyDescriptor,Yp=(e,t,r,o)=>{for(var n=o>1?void 0:o?zf(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&jf(t,r,n),n};let oa=class extends
|
|
1007
|
+
`}};vd=Bf([p("pont-context-menu-shortcut")],vd);var Uf=Object.getOwnPropertyDescriptor,qf=(e,t,r,o)=>{for(var n=o>1?void 0:o?Uf(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let bd=class extends f{createRenderRoot(){return this}render(){return l``}};bd=qf([p("pont-context-menu-trigger")],bd);var jf=Object.defineProperty,zf=Object.getOwnPropertyDescriptor,Yp=(e,t,r,o)=>{for(var n=o>1?void 0:o?zf(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&jf(t,r,n),n};let oa=class extends _{constructor(){super(...arguments),this.isOpen=!1,this.handleClickOutside=e=>{const t=e.target;this!=null&&this.contains(t)||(this.isOpen=!1)}}get _containerElement(){return this.querySelector("div[part=context-menu]")}get _triggerElement(){return this.querySelector("pont-context-menu-trigger")}get _content(){return this==null?void 0:this.querySelector("div[part=context-menu-content]")}connectedCallback(){super.connectedCallback(),document.addEventListener("click",this.handleClickOutside),this.addEventListener("radio-selected",this._handleRadioSelected),this.addEventListener("close-context-menu",()=>{this.isOpen=!1,requestAnimationFrame(()=>{const e=this._content;e&&(e.style.display="none")})})}disconnectedCallback(){document.removeEventListener("click",this.handleClickOutside),super.disconnectedCallback()}toggleDropdown(e){e.preventDefault(),e.stopPropagation();const{clientX:t,clientY:r}=e,o=e.target.getBoundingClientRect();requestAnimationFrame(()=>{const n=this._content;n&&(n.style.display="",n.style.position="absolute",n.style.left=`${t-o.left}px`,n.style.top=`${r-o.top}px`,n.dataset.state="open",this.isOpen=!0)})}updated(e){super.updated(e);const t=this._content;t&&(t.dataset.state=this.isOpen?"open":"closed")}_handleRadioSelected(e){this.querySelectorAll("pont-context-menu-radio-item").forEach(t=>{t!==e.target&&(t.checked=!1)})}getAttributesToExclude(){return[]}firstUpdated(e){var t;this.moveLightDomChildrenInto(this._containerElement),(t=this._triggerElement)==null||t.addEventListener("contextmenu",r=>{this.toggleDropdown(r)}),this.style.position="relative"}createRenderRoot(){return this}render(){return l`
|
|
1008
1008
|
<div
|
|
1009
1009
|
part="context-menu"
|
|
1010
1010
|
class=${m(Dt.root,this.className)}
|
|
1011
1011
|
></div>
|
|
1012
|
-
`}};Yp([g()],oa.prototype,"isOpen",2);oa=Yp([p("pont-context-menu")],oa);const tl={root:["pont-relative"],trigger:[""],content:["pont-fixed pont-z-50","pont-p-popover-content-space-p","pont-w-popover-content-space-w","pont-text-popover-content-color-text","pont-bg-popover-content-color-bg","pont-rounded-popover-content-radius pont-border-popover-content-width-border pont-border-popover-content-color-border pont-outline-hidden","pont-shadow-popover-content-shadow",'data-[state="open"]:pont-block data-[state="closed"]:pont-hidden','data-[state="open"]:pont-animate-in data-[state="open"]:pont-fade-in-0 data-[state="open"]:pont-zoom-in-95','data-[state="closed"]:pont-animate-out data-[state="closed"]:pont-fade-out-0 data-[state="closed"]:pont-zoom-out-95',"pont-translate-y-0.5"]};var Vf=Object.defineProperty,Hf=Object.getOwnPropertyDescriptor,Ao=(e,t,r,o)=>{for(var n=o>1?void 0:o?Hf(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&Vf(t,r,n),n};let In=class extends
|
|
1012
|
+
`}};Yp([g()],oa.prototype,"isOpen",2);oa=Yp([p("pont-context-menu")],oa);const tl={root:["pont-relative"],trigger:[""],content:["pont-fixed pont-z-50","pont-p-popover-content-space-p","pont-w-popover-content-space-w","pont-text-popover-content-color-text","pont-bg-popover-content-color-bg","pont-rounded-popover-content-radius pont-border-popover-content-width-border pont-border-popover-content-color-border pont-outline-hidden","pont-shadow-popover-content-shadow",'data-[state="open"]:pont-block data-[state="closed"]:pont-hidden','data-[state="open"]:pont-animate-in data-[state="open"]:pont-fade-in-0 data-[state="open"]:pont-zoom-in-95','data-[state="closed"]:pont-animate-out data-[state="closed"]:pont-fade-out-0 data-[state="closed"]:pont-zoom-out-95',"pont-translate-y-0.5"]};var Vf=Object.defineProperty,Hf=Object.getOwnPropertyDescriptor,Ao=(e,t,r,o)=>{for(var n=o>1?void 0:o?Hf(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&Vf(t,r,n),n};let In=class extends _{constructor(){super(...arguments),this.enableDefaultStyle=!0,this.styleContent=!0,this.side="bottom",this.state="closed"}get _popover(){let e=this.parentElement;for(;e&&!(e instanceof bo);)e=e.parentElement;return e}get _containerElement(){return this.querySelector("div[part=popover-content]")}handleClickOutside(e){const t=this._popover;t&&!t.contains(e.target)&&(t.isOpen=!1)}firstUpdated(e){this.moveLightDomChildrenInto(this._containerElement),window.addEventListener("click",this.handleClickOutside.bind(this))}updated(e){var t;(t=this._popover)!=null&&t.isOpen||window.removeEventListener("click",this.handleClickOutside.bind(this))}preventClickPropagation(e){e.stopPropagation()}getAttributesToExclude(){return["data-testid"]}createRenderRoot(){return this}render(){return l`
|
|
1013
1013
|
<div
|
|
1014
1014
|
part="popover-content"
|
|
1015
1015
|
data-state=${this.state}
|
|
1016
1016
|
class=${m(tl.content,this.className)}
|
|
1017
1017
|
@click="${this.preventClickPropagation}"
|
|
1018
1018
|
></div>
|
|
1019
|
-
`}};Ao([a({type:Boolean})],In.prototype,"enableDefaultStyle",2);Ao([a({type:Boolean})],In.prototype,"styleContent",2);Ao([a({type:String})],In.prototype,"side",2);Ao([a({attribute:"data-state",type:String})],In.prototype,"state",2);In=Ao([p("pont-popover-content")],In);var Gf=Object.getOwnPropertyDescriptor,Kf=(e,t,r,o)=>{for(var n=o>1?void 0:o?Gf(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let yd=class extends
|
|
1019
|
+
`}};Ao([a({type:Boolean})],In.prototype,"enableDefaultStyle",2);Ao([a({type:Boolean})],In.prototype,"styleContent",2);Ao([a({type:String})],In.prototype,"side",2);Ao([a({attribute:"data-state",type:String})],In.prototype,"state",2);In=Ao([p("pont-popover-content")],In);var Gf=Object.getOwnPropertyDescriptor,Kf=(e,t,r,o)=>{for(var n=o>1?void 0:o?Gf(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let yd=class extends _{constructor(){super(...arguments),this.handleClick=()=>{const e=this._popover;e&&(e.isOpen=!e.isOpen)}}get _popover(){let e=this.parentElement;for(;e&&!(e instanceof bo);)e=e.parentElement;return e}get _containerElement(){return this.querySelector("div[part=popover-trigger]")}firstUpdated(e){super.firstUpdated(e),this.moveLightDomChildrenInto(this._containerElement),this.addEventListener("click",t=>{this.handleClick(),t.stopPropagation()})}createRenderRoot(){return this}getAttributesToExclude(){return["data-testid"]}render(){return l`
|
|
1020
1020
|
<div
|
|
1021
1021
|
part="popover-trigger"
|
|
1022
1022
|
class=${m(tl.trigger,this.className)}
|
|
1023
1023
|
></div>
|
|
1024
|
-
`}};yd=Kf([p("pont-popover-trigger")],yd);var Wf=Object.defineProperty,Yf=Object.getOwnPropertyDescriptor,Qp=(e,t,r,o)=>{for(var n=o>1?void 0:o?Yf(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&Wf(t,r,n),n};let bo=class extends
|
|
1024
|
+
`}};yd=Kf([p("pont-popover-trigger")],yd);var Wf=Object.defineProperty,Yf=Object.getOwnPropertyDescriptor,Qp=(e,t,r,o)=>{for(var n=o>1?void 0:o?Yf(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&Wf(t,r,n),n};let bo=class extends _{constructor(){super(...arguments),this.isOpen=!1}get _containerElement(){return this.querySelector("div[part=popover]")}get _contentElement(){return this.querySelector("pont-popover-content")}createRenderRoot(){return this}firstUpdated(e){this.moveLightDomChildrenInto(this._containerElement)}updated(e){this._contentElement.state=this.isOpen?"open":"closed",this._contentElement.requestUpdate()}render(){return l`
|
|
1025
1025
|
<div part="popover" class=${m(tl.root,this.className)}></div>
|
|
1026
1026
|
`}};Qp([g()],bo.prototype,"isOpen",2);bo=Qp([p("pont-popover")],bo);const ps={root:[""],trigger:[""],content:["pont-p-date-picker-content-space-p","pont-w-auto"]};var Qf=Object.defineProperty,Zf=Object.getOwnPropertyDescriptor,Zp=(e,t,r,o)=>{for(var n=o>1?void 0:o?Zf(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&Qf(t,r,n),n};let ia=class extends f{constructor(){super(...arguments),this.selectedDate=null}handleDateSelected(e){this.selectedDate=e.detail.startDate,this.requestUpdate()}createRenderRoot(){return this}render(){return l`
|
|
1027
1027
|
<pont-popover
|
|
@@ -1065,12 +1065,12 @@
|
|
|
1065
1065
|
<pont-calendar mode="single"></pont-calendar>
|
|
1066
1066
|
</pont-popover-content>
|
|
1067
1067
|
</pont-popover>
|
|
1068
|
-
`}};Zp([a({type:Object})],ia.prototype,"selectedDate",2);ia=Zp([p("pont-date-picker")],ia);const oe={root:[""],trigger:[""],close:[""],overlay:["pont-fixed pont-inset-0 pont-z-50","pont-bg-dialog-overlay-color-bg","data-[state=open]:pont-animate-in data-[state=open]:pont-fade-in-0","data-[state=closed]:pont-animate-out data-[state=closed]:pont-fade-out-0"],content:{base:["pont-fixed pont-top-[50%] pont-left-[50%] pont-z-50","pont-grid pont-gap-dialog-content-space-gap","pont-p-dialog-content-space-p","pont-w-dialog-content-space-w pont-max-w-dialog-content-space-max-w-sm sm:pont-max-w-dialog-content-space-max-w","pont-bg-dialog-content-color-bg","pont-rounded-dialog-content-radius pont-border-dialog-content-width-border pont-border-dialog-content-color-border pont-outline-none","pont-shadow-dialog-content-shadow","pont-duration-200","pont-translate-x-[-50%] pont-translate-y-[-50%]","data-[state=open]:pont-animate-in data-[state=open]:pont-fade-in-0 data-[state=open]:pont-zoom-in-95","data-[state=closed]:pont-animate-out data-[state=closed]:pont-fade-out-0 data-[state=closed]:pont-zoom-out-95"],close:{base:["pont-absolute pont-top-4 pont-right-4","pont-rounded-dialog-close-radius","pont-ring-offset-dialog-close-color-ring-offset","pont-transition-opacity","focus:pont-ring-dialog-close-width-ring-focus focus:pont-ring-dialog-close-color-ring-focus focus:pont-ring-offset-dialog-close-width-ring-offset focus:pont-outline-hidden","disabled:pont-pointer-events-none","data-[state=open]:pont-bg-dialog-close-color-bg data-[state=open]:pont-text-dialog-close-color-text"],icon:["pont-shrink-0","pont-size-dialog-close-icon-space-size","pont-pointer-events-none"]}},header:["pont-flex pont-flex-col pont-gap-dialog-header-space-gap","pont-text-center","sm:pont-text-left"],footer:["pont-flex pont-flex-col-reverse pont-gap-dialog-footer-space-gap","sm:pont-flex-row sm:pont-justify-end"],title:["pont-text-dialog-title-font pont-font-dialog-title-font-weight"],description:["pont-text-dialog-description-font pont-font-dialog-description-font-weight pont-text-dialog-description-color-text"]};var Jf=Object.getOwnPropertyDescriptor,Xf=(e,t,r,o)=>{for(var n=o>1?void 0:o?Jf(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};const tv="closed";let _d=class extends
|
|
1068
|
+
`}};Zp([a({type:Object})],ia.prototype,"selectedDate",2);ia=Zp([p("pont-date-picker")],ia);const oe={root:[""],trigger:[""],close:[""],overlay:["pont-fixed pont-inset-0 pont-z-50","pont-bg-dialog-overlay-color-bg","data-[state=open]:pont-animate-in data-[state=open]:pont-fade-in-0","data-[state=closed]:pont-animate-out data-[state=closed]:pont-fade-out-0"],content:{base:["pont-fixed pont-top-[50%] pont-left-[50%] pont-z-50","pont-grid pont-gap-dialog-content-space-gap","pont-p-dialog-content-space-p","pont-w-dialog-content-space-w pont-max-w-dialog-content-space-max-w-sm sm:pont-max-w-dialog-content-space-max-w","pont-bg-dialog-content-color-bg","pont-rounded-dialog-content-radius pont-border-dialog-content-width-border pont-border-dialog-content-color-border pont-outline-none","pont-shadow-dialog-content-shadow","pont-duration-200","pont-translate-x-[-50%] pont-translate-y-[-50%]","data-[state=open]:pont-animate-in data-[state=open]:pont-fade-in-0 data-[state=open]:pont-zoom-in-95","data-[state=closed]:pont-animate-out data-[state=closed]:pont-fade-out-0 data-[state=closed]:pont-zoom-out-95"],close:{base:["pont-absolute pont-top-4 pont-right-4","pont-rounded-dialog-close-radius","pont-ring-offset-dialog-close-color-ring-offset","pont-transition-opacity","focus:pont-ring-dialog-close-width-ring-focus focus:pont-ring-dialog-close-color-ring-focus focus:pont-ring-offset-dialog-close-width-ring-offset focus:pont-outline-hidden","disabled:pont-pointer-events-none","data-[state=open]:pont-bg-dialog-close-color-bg data-[state=open]:pont-text-dialog-close-color-text"],icon:["pont-shrink-0","pont-size-dialog-close-icon-space-size","pont-pointer-events-none"]}},header:["pont-flex pont-flex-col pont-gap-dialog-header-space-gap","pont-text-center","sm:pont-text-left"],footer:["pont-flex pont-flex-col-reverse pont-gap-dialog-footer-space-gap","sm:pont-flex-row sm:pont-justify-end"],title:["pont-text-dialog-title-font pont-font-dialog-title-font-weight"],description:["pont-text-dialog-description-font pont-font-dialog-description-font-weight pont-text-dialog-description-color-text"]};var Jf=Object.getOwnPropertyDescriptor,Xf=(e,t,r,o)=>{for(var n=o>1?void 0:o?Jf(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};const tv="closed";let _d=class extends _{get _dialog(){let e=this.parentElement;for(;e;){if(e instanceof An)return e;e=e.parentElement}return e}get _containerElement(){return this.querySelector("div[part=dialog-close]")}firstUpdated(e){super.firstUpdated(e),this.moveLightDomChildrenInto(this._containerElement),this.addEventListener("click",()=>{const t=this._dialog;t&&(t.dataset.state=tv)})}getAttributesToExclude(){return["data-testid"]}createRenderRoot(){return this}render(){return l`
|
|
1069
1069
|
<div
|
|
1070
1070
|
part="dialog-close"
|
|
1071
1071
|
class=${m(oe.close,this.className)}
|
|
1072
1072
|
></div>
|
|
1073
|
-
`}};_d=Xf([p("pont-dialog-close")],_d);var ev=Object.defineProperty,rv=Object.getOwnPropertyDescriptor,el=(e,t,r,o)=>{for(var n=o>1?void 0:o?rv(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&ev(t,r,n),n};const hs="closed";let mi=class extends
|
|
1073
|
+
`}};_d=Xf([p("pont-dialog-close")],_d);var ev=Object.defineProperty,rv=Object.getOwnPropertyDescriptor,el=(e,t,r,o)=>{for(var n=o>1?void 0:o?rv(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&ev(t,r,n),n};const hs="closed";let mi=class extends _{constructor(){super(...arguments),this.state=hs,this.showCloseButton=!1,this.handleCloseButtonClick=()=>{const e=this._dialog;e&&(e.dataset.state=hs)}}get _containerElement(){return this.querySelector("div[part=dialog-content-slot]")}get ـcomponentElement(){return this.querySelector("div[part=dialog-content]")}get _dialog(){let e=this.parentElement;for(;e;){if(e instanceof An)return e;e=e.parentElement}return e}getAttributesToExclude(){return["date-testid"]}createRenderRoot(){return this}firstUpdated(e){this.moveLightDomChildrenInto(this._containerElement)}updated(e){requestAnimationFrame(()=>{e.get("state")===hs?this.ـcomponentElement.style.display="grid":this.ـcomponentElement.style.display="none"})}render(){return l`
|
|
1074
1074
|
<div
|
|
1075
1075
|
rtgdlg-content
|
|
1076
1076
|
part="dialog-content"
|
|
@@ -1105,7 +1105,7 @@
|
|
|
1105
1105
|
</button>
|
|
1106
1106
|
`:""}
|
|
1107
1107
|
</div>
|
|
1108
|
-
`}};el([a({attribute:"data-state",type:String})],mi.prototype,"state",2);el([a({attribute:"show-close-button",type:Boolean})],mi.prototype,"showCloseButton",2);mi=el([p("pont-dialog-content")],mi);var nv=Object.getOwnPropertyDescriptor,ov=(e,t,r,o)=>{for(var n=o>1?void 0:o?nv(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let wd=class extends
|
|
1108
|
+
`}};el([a({attribute:"data-state",type:String})],mi.prototype,"state",2);el([a({attribute:"show-close-button",type:Boolean})],mi.prototype,"showCloseButton",2);mi=el([p("pont-dialog-content")],mi);var nv=Object.getOwnPropertyDescriptor,ov=(e,t,r,o)=>{for(var n=o>1?void 0:o?nv(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let wd=class extends _{get _containerElement(){return this.querySelector("div[part=dialog-footer]")}getAttributesToExclude(){return[]}createRenderRoot(){return this}firstUpdated(e){this.moveLightDomChildrenInto(this._containerElement)}render(){return l`
|
|
1109
1109
|
<div
|
|
1110
1110
|
part="dialog-footer"
|
|
1111
1111
|
class=${m(oe.footer,this.className)}
|
|
@@ -1126,12 +1126,12 @@
|
|
|
1126
1126
|
part="dialog-overly"
|
|
1127
1127
|
class=${m(oe.overlay,this.className)}
|
|
1128
1128
|
></div>
|
|
1129
|
-
`}};$d=lv([p("pont-dialog-overlay")],$d);var dv=Object.getOwnPropertyDescriptor,cv=(e,t,r,o)=>{for(var n=o>1?void 0:o?dv(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};const pv="open";let Pd=class extends
|
|
1129
|
+
`}};$d=lv([p("pont-dialog-overlay")],$d);var dv=Object.getOwnPropertyDescriptor,cv=(e,t,r,o)=>{for(var n=o>1?void 0:o?dv(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};const pv="open";let Pd=class extends _{constructor(){super(...arguments),this.handleClick=()=>{const e=this._dialog;e&&(e.dataset.state=pv)}}get _dialog(){let e=this.parentElement;for(;e;){if(e instanceof An)return e;e=e.parentElement}return e}get _containerElement(){return this.querySelector("div[part=dialog-trigger]")}firstUpdated(e){super.firstUpdated(e),this.moveLightDomChildrenInto(this._containerElement),this.addEventListener("click",t=>{t.stopPropagation(),this.handleClick()})}getAttributesToExclude(){return[]}createRenderRoot(){return this}render(){return l`
|
|
1130
1130
|
<div
|
|
1131
1131
|
part="dialog-trigger"
|
|
1132
1132
|
class=${m(oe.trigger,this.className)}
|
|
1133
1133
|
></div>
|
|
1134
|
-
`}};Pd=cv([p("pont-dialog-trigger")],Pd);var hv=Object.defineProperty,uv=Object.getOwnPropertyDescriptor,Jp=(e,t,r,o)=>{for(var n=o>1?void 0:o?uv(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&hv(t,r,n),n};const mv="open",gv="closed";let An=class extends
|
|
1134
|
+
`}};Pd=cv([p("pont-dialog-trigger")],Pd);var hv=Object.defineProperty,uv=Object.getOwnPropertyDescriptor,Jp=(e,t,r,o)=>{for(var n=o>1?void 0:o?uv(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&hv(t,r,n),n};const mv="open",gv="closed";let An=class extends _{constructor(){super(...arguments),this.state=gv}get _containerElement(){return this.querySelector("div[rtgdlg-root]")}get _content(){const e=this.querySelector("pont-dialog-content");return e||null}updated(e){super.updated(e);const t=this._content;t&&(t.dataset.state=this.state)}firstUpdated(e){this.moveLightDomChildrenInto(this._containerElement)}createRenderRoot(){return this}getAttributesToExclude(){return[]}render(){return l`
|
|
1135
1135
|
<div
|
|
1136
1136
|
rtgdlg-root
|
|
1137
1137
|
part="dialog"
|
|
@@ -1139,12 +1139,12 @@
|
|
|
1139
1139
|
>
|
|
1140
1140
|
${this.state===mv?l` <pont-dialog-overlay></pont-dialog-overlay>`:h}
|
|
1141
1141
|
</div>
|
|
1142
|
-
`}};Jp([a({attribute:"data-state",type:String})],An.prototype,"state",2);An=Jp([p("pont-dialog")],An);const we={open:"open",closed:"closed"},Te={root:[""],trigger:[""],close:[""],overlay:["pont-fixed pont-inset-0 pont-z-50","pont-bg-drawer-overlay-color-bg","data-[state=open]:pont-animate-in data-[state=open]:pont-fade-in-0","data-[state=closed]:pont-animate-out data-[state=closed]:pont-fade-out-0"],content:{base:["pont-fixed pont-inset-x-0 pont-bottom-0 pont-z-50","pont-flex pont-flex-col","pont-mt-drawer-content-space-mt","pont-h-auto pont-max-h-[80vh]","pont-bg-drawer-content-color-bg","pont-rounded-t-drawer-content-radius pont-border-t-drawer-content-width-border pont-border-t-drawer-content-color-border"],thumb:["pont-shrink-0","pont-mx-auto pont-mt-drawer-thumb-space-mt","pont-w-drawer-thumb-space-w pont-h-drawer-thumb-space-h","pont-bg-drawer-thumb-color-bg","pont-rounded-drawer-thumb-radius"]},header:["pont-flex pont-flex-col pont-gap-drawer-header-space-gap-sm md:pont-gap-drawer-header-space-gap","pont-p-drawer-header-space-p","pont-text-center"],footer:["pont-flex pont-flex-col pont-gap-drawer-footer-space-gap","pont-p-drawer-footer-space-p pont-mt-auto"],title:["pont-text-drawer-title-font pont-font-drawer-title-font-weight pont-text-drawer-title-color-text"],description:["pont-text-drawer-description-font pont-font-drawer-description-font-weight pont-text-drawer-description-color-text"]};var fv=Object.getOwnPropertyDescriptor,vv=(e,t,r,o)=>{for(var n=o>1?void 0:o?fv(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let Cd=class extends
|
|
1142
|
+
`}};Jp([a({attribute:"data-state",type:String})],An.prototype,"state",2);An=Jp([p("pont-dialog")],An);const we={open:"open",closed:"closed"},Te={root:[""],trigger:[""],close:[""],overlay:["pont-fixed pont-inset-0 pont-z-50","pont-bg-drawer-overlay-color-bg","data-[state=open]:pont-animate-in data-[state=open]:pont-fade-in-0","data-[state=closed]:pont-animate-out data-[state=closed]:pont-fade-out-0"],content:{base:["pont-fixed pont-inset-x-0 pont-bottom-0 pont-z-50","pont-flex pont-flex-col","pont-mt-drawer-content-space-mt","pont-h-auto pont-max-h-[80vh]","pont-bg-drawer-content-color-bg","pont-rounded-t-drawer-content-radius pont-border-t-drawer-content-width-border pont-border-t-drawer-content-color-border"],thumb:["pont-shrink-0","pont-mx-auto pont-mt-drawer-thumb-space-mt","pont-w-drawer-thumb-space-w pont-h-drawer-thumb-space-h","pont-bg-drawer-thumb-color-bg","pont-rounded-drawer-thumb-radius"]},header:["pont-flex pont-flex-col pont-gap-drawer-header-space-gap-sm md:pont-gap-drawer-header-space-gap","pont-p-drawer-header-space-p","pont-text-center"],footer:["pont-flex pont-flex-col pont-gap-drawer-footer-space-gap","pont-p-drawer-footer-space-p pont-mt-auto"],title:["pont-text-drawer-title-font pont-font-drawer-title-font-weight pont-text-drawer-title-color-text"],description:["pont-text-drawer-description-font pont-font-drawer-description-font-weight pont-text-drawer-description-color-text"]};var fv=Object.getOwnPropertyDescriptor,vv=(e,t,r,o)=>{for(var n=o>1?void 0:o?fv(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let Cd=class extends _{get _drawer(){let e=this.parentElement;for(;e;){if(e instanceof yo)return e;e=e.parentElement}return e}get _containerElement(){return this.querySelector("div[part=drawer-close]")}async firstUpdated(e){super.firstUpdated(e),await this.updateComplete;const t=this._containerElement;if(t){this.moveLightDomChildrenInto(t);const r=t.querySelector("button, [data-close], [role=button]");r&&r.addEventListener("click",o=>{o.stopPropagation();const n=this._drawer;n&&(n.dataset.state=we.closed)})}}getAttributesToExclude(){return["data-testid"]}createRenderRoot(){return this}render(){return l`
|
|
1143
1143
|
<div
|
|
1144
1144
|
part="drawer-close"
|
|
1145
1145
|
class=${m(Te.close,this.className)}
|
|
1146
1146
|
></div>
|
|
1147
|
-
`}};Cd=vv([p("pont-drawer-close")],Cd);var bv=Object.defineProperty,yv=Object.getOwnPropertyDescriptor,Xp=(e,t,r,o)=>{for(var n=o>1?void 0:o?yv(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&bv(t,r,n),n};let sa=class extends
|
|
1147
|
+
`}};Cd=vv([p("pont-drawer-close")],Cd);var bv=Object.defineProperty,yv=Object.getOwnPropertyDescriptor,Xp=(e,t,r,o)=>{for(var n=o>1?void 0:o?yv(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&bv(t,r,n),n};let sa=class extends _{constructor(){super(...arguments),this.state=we.closed}connectedCallback(){super.connectedCallback();const e=document.createElement("style");e.textContent=`
|
|
1148
1148
|
@keyframes slideInUp {
|
|
1149
1149
|
from { transform: translateY(100%); }
|
|
1150
1150
|
to { transform: translateY(0); }
|
|
@@ -1173,17 +1173,17 @@
|
|
|
1173
1173
|
<div part="drawer-thumb" class=${m(Te.content.thumb)}></div>
|
|
1174
1174
|
<div part="drawer-content-slot"></div>
|
|
1175
1175
|
</div>
|
|
1176
|
-
`}};Xp([a({attribute:"data-state",type:String})],sa.prototype,"state",2);sa=Xp([p("pont-drawer-content")],sa);var _v=Object.getOwnPropertyDescriptor,wv=(e,t,r,o)=>{for(var n=o>1?void 0:o?_v(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let Ed=class extends
|
|
1176
|
+
`}};Xp([a({attribute:"data-state",type:String})],sa.prototype,"state",2);sa=Xp([p("pont-drawer-content")],sa);var _v=Object.getOwnPropertyDescriptor,wv=(e,t,r,o)=>{for(var n=o>1?void 0:o?_v(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let Ed=class extends _{get _containerElement(){return this.querySelector("p[part=drawer-description")}getAttributesToExclude(){return[]}createRenderRoot(){return this}firstUpdated(e){this.moveLightDomChildrenInto(this._containerElement)}render(){return l`
|
|
1177
1177
|
<p
|
|
1178
1178
|
part="drawer-description"
|
|
1179
1179
|
class=${m(Te.description,this.className)}
|
|
1180
1180
|
></p>
|
|
1181
|
-
`}};Ed=wv([p("pont-drawer-description")],Ed);var $v=Object.getOwnPropertyDescriptor,Pv=(e,t,r,o)=>{for(var n=o>1?void 0:o?$v(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let Sd=class extends
|
|
1181
|
+
`}};Ed=wv([p("pont-drawer-description")],Ed);var $v=Object.getOwnPropertyDescriptor,Pv=(e,t,r,o)=>{for(var n=o>1?void 0:o?$v(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let Sd=class extends _{get _containerElement(){return this.querySelector("div[part=drawer-footer]")}getAttributesToExclude(){return[]}createRenderRoot(){return this}firstUpdated(e){this.moveLightDomChildrenInto(this._containerElement)}render(){return l`
|
|
1182
1182
|
<div
|
|
1183
1183
|
part="drawer-footer"
|
|
1184
1184
|
class=${m(Te.footer,this.className)}
|
|
1185
1185
|
></div>
|
|
1186
|
-
`}};Sd=Pv([p("pont-drawer-footer")],Sd);var Cv=Object.getOwnPropertyDescriptor,Ev=(e,t,r,o)=>{for(var n=o>1?void 0:o?Cv(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let xd=class extends
|
|
1186
|
+
`}};Sd=Pv([p("pont-drawer-footer")],Sd);var Cv=Object.getOwnPropertyDescriptor,Ev=(e,t,r,o)=>{for(var n=o>1?void 0:o?Cv(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let xd=class extends _{get _containerElement(){return this.querySelector("div[part=drawer-header")}createRenderRoot(){return this}firstUpdated(e){this.moveLightDomChildrenInto(this._containerElement)}render(){return l`
|
|
1187
1187
|
<div
|
|
1188
1188
|
part="drawer-header"
|
|
1189
1189
|
class=${m(Te.header,this.className)}
|
|
@@ -1193,17 +1193,17 @@
|
|
|
1193
1193
|
part="drawer-overly"
|
|
1194
1194
|
class=${m(Te.overlay,this.className)}
|
|
1195
1195
|
></div>
|
|
1196
|
-
`}};Od=xv([p("pont-drawer-overlay")],Od);var Ov=Object.getOwnPropertyDescriptor,Rv=(e,t,r,o)=>{for(var n=o>1?void 0:o?Ov(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let Rd=class extends
|
|
1196
|
+
`}};Od=xv([p("pont-drawer-overlay")],Od);var Ov=Object.getOwnPropertyDescriptor,Rv=(e,t,r,o)=>{for(var n=o>1?void 0:o?Ov(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let Rd=class extends _{get _containerElement(){return this.querySelector("h2[part=drawer-title")}getAttributesToExclude(){return[]}createRenderRoot(){return this}firstUpdated(e){this.moveLightDomChildrenInto(this._containerElement)}render(){return l`
|
|
1197
1197
|
<h2
|
|
1198
1198
|
part="drawer-title"
|
|
1199
1199
|
class=${m(Te.title,this.className)}
|
|
1200
1200
|
></h2>
|
|
1201
|
-
`}};Rd=Rv([p("pont-drawer-title")],Rd);var Iv=Object.getOwnPropertyDescriptor,Av=(e,t,r,o)=>{for(var n=o>1?void 0:o?Iv(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let Id=class extends
|
|
1201
|
+
`}};Rd=Rv([p("pont-drawer-title")],Rd);var Iv=Object.getOwnPropertyDescriptor,Av=(e,t,r,o)=>{for(var n=o>1?void 0:o?Iv(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let Id=class extends _{constructor(){super(...arguments),this.handleClick=()=>{const e=this._drawer;e&&(e.dataset.state=we.open)}}get _drawer(){let e=this.parentElement;for(;e;){if(e instanceof yo)return e;e=e.parentElement}return e}get _containerElement(){return this.querySelector("div[part=drawer-trigger]")}firstUpdated(e){super.firstUpdated(e),this.moveLightDomChildrenInto(this._containerElement),this.addEventListener("click",t=>{t.stopPropagation(),this.handleClick()})}getAttributesToExclude(){return[]}createRenderRoot(){return this}render(){return l`
|
|
1202
1202
|
<div
|
|
1203
1203
|
part="drawer-trigger"
|
|
1204
1204
|
class=${m(Te.trigger,this.className)}
|
|
1205
1205
|
></div>
|
|
1206
|
-
`}};Id=Av([p("pont-drawer-trigger")],Id);var Tv=Object.defineProperty,Dv=Object.getOwnPropertyDescriptor,th=(e,t,r,o)=>{for(var n=o>1?void 0:o?Dv(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&Tv(t,r,n),n};let yo=class extends
|
|
1206
|
+
`}};Id=Av([p("pont-drawer-trigger")],Id);var Tv=Object.defineProperty,Dv=Object.getOwnPropertyDescriptor,th=(e,t,r,o)=>{for(var n=o>1?void 0:o?Dv(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&Tv(t,r,n),n};let yo=class extends _{constructor(){super(...arguments),this.state=we.closed,this.handleOutsideClick=e=>{const t=this._content;this.state===we.open&&t&&(t.contains(e.target)||(this.state=we.closed,this.dispatchEvent(new CustomEvent("drawer-close"))))}}get _containerElement(){return this.querySelector("div[rtgdlg-root]")}get _content(){const e=this.querySelector("pont-drawer-content");return e||null}connectedCallback(){super.connectedCallback(),this.setupOutsideClickHandler()}disconnectedCallback(){super.disconnectedCallback(),this.removeOutsideClickHandler()}updated(e){super.updated(e);const t=this._content;t&&(t.dataset.state=this.state),e.has("state")&&this.setupOutsideClickHandler()}setupOutsideClickHandler(){this.state===we.open?document.addEventListener("click",this.handleOutsideClick):this.removeOutsideClickHandler()}removeOutsideClickHandler(){document.removeEventListener("click",this.handleOutsideClick)}firstUpdated(e){this.moveLightDomChildrenInto(this._containerElement)}createRenderRoot(){return this}getAttributesToExclude(){return[]}render(){return l`
|
|
1207
1207
|
<div
|
|
1208
1208
|
rtgdlg-root
|
|
1209
1209
|
part="drawer"
|
|
@@ -1211,7 +1211,7 @@
|
|
|
1211
1211
|
>
|
|
1212
1212
|
${this.state===we.open?l` <pont-drawer-overlay></pont-drawer-overlay>`:h}
|
|
1213
1213
|
</div>
|
|
1214
|
-
`}};th([a({attribute:"data-state",type:String})],yo.prototype,"state",2);yo=th([p("pont-drawer")],yo);const Lt={root:["pont-relative"],content:["pont-overflow-x-hidden pont-overflow-y-auto pont-z-50 pont-absolute","pont-p-dropdown-menu-content-space-p","pont-min-w-dropdown-menu-content-space-min-w","pont-text-dropdown-menu-content-color-text","pont-bg-dropdown-menu-content-color-bg","pont-rounded-dropdown-menu-content-radius pont-border-dropdown-menu-content-width-border pont-border-dropdown-menu-content-color-border","pont-shadow-dropdown-menu-content-shadow","pont-translate-y-0.5","pont-slide-in-from-top-2","data-[state=open]:pont-animate-in data-[state=open]:pont-fade-in-0 data-[state=open]:pont-zoom-in-95","data-[state=closed]:pont-animate-out data-[state=closed]:pont-fade-out-0 data-[state=closed]:pont-zoom-out-95"],group:[""],item:["pont-flex pont-relative","pont-gap-dropdown-menu-item-space-gap pont-items-center","pont-px-dropdown-menu-item-space-px pont-py-dropdown-menu-item-space-py","pont-text-dropdown-menu-item-font","pont-rounded-dropdown-menu-item-radius pont-outline-hidden","pont-cursor-default","pont-select-none","hover:pont-bg-dropdown-menu-item-color-bg-hover hover:pont-text-dropdown-menu-item-color-text-hover","focus:pont-bg-dropdown-menu-item-color-bg-focus focus:pont-text-dropdown-menu-item-color-text-focus","data-[disabled]:pont-opacity-dropdown-menu-item-opacity-disabled data-[disabled]:pont-pointer-events-none",'[&_svg]:pont-shrink-0 [&_svg:not([class*="pont-size-"])]:pont-size-dropdown-menu-item-icon-space-size [&_svg:not([class*="pont-text-"])]:pont-text-dropdown-menu-item-icon-color-text [&_svg]:pont-pointer-events-none'],checkboxItem:{base:["pont-flex pont-relative","pont-gap-dropdown-menu-checkbox-item-space-gap pont-items-center","pont-pl-dropdown-menu-checkbox-item-space-pl pont-pr-dropdown-menu-checkbox-item-space-pr pont-py-dropdown-menu-checkbox-item-space-py","pont-text-dropdown-menu-checkbox-item-font","pont-rounded-dropdown-menu-checkbox-item-radius pont-outline-hidden","pont-cursor-default","pont-select-none","aria-selected:pont-bg-dropdown-menu-checkbox-item-color-bg-focus aria-selected:pont-text-dropdown-menu-checkbox-item-color-text-focus","data-[disabled]:pont-opacity-dropdown-menu-checkbox-item-opacity-disabled data-[disabled]:pont-pointer-events-none"],span:["pont-flex pont-absolute pont-left-2","pont-justify-center pont-items-center","pont-size-dropdown-menu-checkbox-item-icon-container-space-size","pont-pointer-events-none"],icon:["pont-shrink-0","pont-size-dropdown-menu-checkbox-item-icon-space-size","pont-pointer-events-none"]},radioItem:{base:["pont-flex pont-relative","pont-gap-dropdown-menu-radio-item-space-gap pont-items-center","pont-pl-dropdown-menu-radio-item-space-pl pont-pr-dropdown-menu-radio-item-space-pr pont-py-dropdown-menu-radio-item-space-py","pont-text-dropdown-menu-radio-item-font","pont-rounded-dropdown-menu-radio-item-radius pont-outline-hidden","pont-cursor-default","pont-select-none","aria-selected:pont-bg-dropdown-menu-radio-item-color-bg-focus aria-selected:pont-text-dropdown-menu-radio-item-color-text-focus","data-[disabled]:pont-opacity-dropdown-menu-radio-item-opacity-disabled data-[disabled]:pont-pointer-events-none"],span:["pont-flex pont-absolute pont-left-2","pont-justify-center pont-items-center","pont-size-dropdown-menu-radio-item-icon-container-space-size","pont-pointer-events-none"],icon:["pont-shrink-0","pont-size-dropdown-menu-radio-item-icon-space-size","pont-pointer-events-none","pont-fill-current"]},label:["pont-px-dropdown-menu-label-space-px pont-py-dropdown-menu-label-space-py","pont-text-dropdown-menu-label-font pont-font-dropdown-menu-label-font-weight"],separator:["pont-mx-dropdown-menu-separator-space-mx pont-my-dropdown-menu-separator-space-my","pont-h-dropdown-menu-separator-space-h","pont-bg-dropdown-menu-separator-color-bg"],shortcut:["pont-ml-auto","pont-text-dropdown-menu-shortcut-font pont-text-dropdown-menu-shortcut-color-text"]};var Lv=Object.defineProperty,Fv=Object.getOwnPropertyDescriptor,zn=(e,t,r,o)=>{for(var n=o>1?void 0:o?Fv(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&Lv(t,r,n),n};let Gr=class extends
|
|
1214
|
+
`}};th([a({attribute:"data-state",type:String})],yo.prototype,"state",2);yo=th([p("pont-drawer")],yo);const Lt={root:["pont-relative"],content:["pont-overflow-x-hidden pont-overflow-y-auto pont-z-50 pont-absolute","pont-p-dropdown-menu-content-space-p","pont-min-w-dropdown-menu-content-space-min-w","pont-text-dropdown-menu-content-color-text","pont-bg-dropdown-menu-content-color-bg","pont-rounded-dropdown-menu-content-radius pont-border-dropdown-menu-content-width-border pont-border-dropdown-menu-content-color-border","pont-shadow-dropdown-menu-content-shadow","pont-translate-y-0.5","pont-slide-in-from-top-2","data-[state=open]:pont-animate-in data-[state=open]:pont-fade-in-0 data-[state=open]:pont-zoom-in-95","data-[state=closed]:pont-animate-out data-[state=closed]:pont-fade-out-0 data-[state=closed]:pont-zoom-out-95"],group:[""],item:["pont-flex pont-relative","pont-gap-dropdown-menu-item-space-gap pont-items-center","pont-px-dropdown-menu-item-space-px pont-py-dropdown-menu-item-space-py","pont-text-dropdown-menu-item-font","pont-rounded-dropdown-menu-item-radius pont-outline-hidden","pont-cursor-default","pont-select-none","hover:pont-bg-dropdown-menu-item-color-bg-hover hover:pont-text-dropdown-menu-item-color-text-hover","focus:pont-bg-dropdown-menu-item-color-bg-focus focus:pont-text-dropdown-menu-item-color-text-focus","data-[disabled]:pont-opacity-dropdown-menu-item-opacity-disabled data-[disabled]:pont-pointer-events-none",'[&_svg]:pont-shrink-0 [&_svg:not([class*="pont-size-"])]:pont-size-dropdown-menu-item-icon-space-size [&_svg:not([class*="pont-text-"])]:pont-text-dropdown-menu-item-icon-color-text [&_svg]:pont-pointer-events-none'],checkboxItem:{base:["pont-flex pont-relative","pont-gap-dropdown-menu-checkbox-item-space-gap pont-items-center","pont-pl-dropdown-menu-checkbox-item-space-pl pont-pr-dropdown-menu-checkbox-item-space-pr pont-py-dropdown-menu-checkbox-item-space-py","pont-text-dropdown-menu-checkbox-item-font","pont-rounded-dropdown-menu-checkbox-item-radius pont-outline-hidden","pont-cursor-default","pont-select-none","aria-selected:pont-bg-dropdown-menu-checkbox-item-color-bg-focus aria-selected:pont-text-dropdown-menu-checkbox-item-color-text-focus","data-[disabled]:pont-opacity-dropdown-menu-checkbox-item-opacity-disabled data-[disabled]:pont-pointer-events-none"],span:["pont-flex pont-absolute pont-left-2","pont-justify-center pont-items-center","pont-size-dropdown-menu-checkbox-item-icon-container-space-size","pont-pointer-events-none"],icon:["pont-shrink-0","pont-size-dropdown-menu-checkbox-item-icon-space-size","pont-pointer-events-none"]},radioItem:{base:["pont-flex pont-relative","pont-gap-dropdown-menu-radio-item-space-gap pont-items-center","pont-pl-dropdown-menu-radio-item-space-pl pont-pr-dropdown-menu-radio-item-space-pr pont-py-dropdown-menu-radio-item-space-py","pont-text-dropdown-menu-radio-item-font","pont-rounded-dropdown-menu-radio-item-radius pont-outline-hidden","pont-cursor-default","pont-select-none","aria-selected:pont-bg-dropdown-menu-radio-item-color-bg-focus aria-selected:pont-text-dropdown-menu-radio-item-color-text-focus","data-[disabled]:pont-opacity-dropdown-menu-radio-item-opacity-disabled data-[disabled]:pont-pointer-events-none"],span:["pont-flex pont-absolute pont-left-2","pont-justify-center pont-items-center","pont-size-dropdown-menu-radio-item-icon-container-space-size","pont-pointer-events-none"],icon:["pont-shrink-0","pont-size-dropdown-menu-radio-item-icon-space-size","pont-pointer-events-none","pont-fill-current"]},label:["pont-px-dropdown-menu-label-space-px pont-py-dropdown-menu-label-space-py","pont-text-dropdown-menu-label-font pont-font-dropdown-menu-label-font-weight"],separator:["pont-mx-dropdown-menu-separator-space-mx pont-my-dropdown-menu-separator-space-my","pont-h-dropdown-menu-separator-space-h","pont-bg-dropdown-menu-separator-color-bg"],shortcut:["pont-ml-auto","pont-text-dropdown-menu-shortcut-font pont-text-dropdown-menu-shortcut-color-text"]};var Lv=Object.defineProperty,Fv=Object.getOwnPropertyDescriptor,zn=(e,t,r,o)=>{for(var n=o>1?void 0:o?Fv(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&Lv(t,r,n),n};let Gr=class extends _{constructor(){super(...arguments),this._id="",this.selected=!1,this.checked=!1,this.disabled=!1}get value(){var e;return((e=this.textContent)==null?void 0:e.trim())||""}get _containerElement(){return this.querySelector("div[part=dropdown-menu-checkbox-item-container]")}get _dropdownMenu(){let e=this.parentElement;for(;e&&!(e instanceof Pt);)e=e.parentElement;return e}handleMouseEvent(e){(e.type==="mouseover"||e.type==="focus")&&(this.selected=!0),e.type==="mouseleave"&&(this.selected=!1)}toggleChecked(){this._dropdownMenu.isOpen=!1,this.checked=!this.checked}createRenderRoot(){return this}firstUpdated(e){this.moveLightDomChildrenInto(this._containerElement)}render(){return l`
|
|
1215
1215
|
<div
|
|
1216
1216
|
rtgcmd-item
|
|
1217
1217
|
part="dropdown-menu-item"
|
|
@@ -1248,14 +1248,14 @@
|
|
|
1248
1248
|
</span>
|
|
1249
1249
|
<div part="dropdown-menu-checkbox-item-container"></div>
|
|
1250
1250
|
</div>
|
|
1251
|
-
`}};zn([a({type:String})],Gr.prototype,"_id",2);zn([a({attribute:"data-value",type:String})],Gr.prototype,"value",1);zn([a({type:Boolean})],Gr.prototype,"selected",2);zn([a({type:Boolean})],Gr.prototype,"checked",2);zn([a({attribute:"data-disabled",type:Boolean})],Gr.prototype,"disabled",2);Gr=zn([p("pont-dropdown-menu-checkbox-item")],Gr);const nl="closed";var kv=Object.defineProperty,Nv=Object.getOwnPropertyDescriptor,ol=(e,t,r,o)=>{for(var n=o>1?void 0:o?Nv(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&kv(t,r,n),n};let fi=class extends
|
|
1251
|
+
`}};zn([a({type:String})],Gr.prototype,"_id",2);zn([a({attribute:"data-value",type:String})],Gr.prototype,"value",1);zn([a({type:Boolean})],Gr.prototype,"selected",2);zn([a({type:Boolean})],Gr.prototype,"checked",2);zn([a({attribute:"data-disabled",type:Boolean})],Gr.prototype,"disabled",2);Gr=zn([p("pont-dropdown-menu-checkbox-item")],Gr);const nl="closed";var kv=Object.defineProperty,Nv=Object.getOwnPropertyDescriptor,ol=(e,t,r,o)=>{for(var n=o>1?void 0:o?Nv(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&kv(t,r,n),n};let fi=class extends _{constructor(){super(),this.state=nl,this.isOpen=!1,this.handleWindowChange=this.handleWindowChange.bind(this)}get _dropdownMenu(){let e=this.parentElement;for(;e&&!(e instanceof Pt);)e=e.parentElement;return e}get _containerElement(){return this.querySelector("div[part=dropdown-menu-content]")}connectedCallback(){super.connectedCallback(),window.addEventListener("resize",this.handleWindowChange),window.addEventListener("scroll",this.handleWindowChange,!0)}disconnectedCallback(){window.removeEventListener("resize",this.handleWindowChange),window.removeEventListener("scroll",this.handleWindowChange,!0),super.disconnectedCallback()}handleWindowChange(){this.isOpen&&requestAnimationFrame(()=>this.positionContent())}updated(e){super.updated(e),this.state==="open"?(this.isOpen=!0,requestAnimationFrame(()=>this.positionContent())):this.isOpen=!1}createRenderRoot(){return this}firstUpdated(e){this.moveLightDomChildrenInto(this._containerElement)}positionContent(){const e=this._dropdownMenu,t=this._containerElement,r=e==null?void 0:e._triggerElement;if(!e||!t||!r||!this.isOpen)return;const o=document.documentElement.clientWidth,n=document.documentElement.clientHeight,i=8,s=r.getBoundingClientRect();t.style.position="fixed",t.style.minWidth=`${Math.max(s.width,t.offsetWidth)}px`,t.style.maxWidth=`${Math.min(t.offsetWidth,o-i*2)}px`;let d=s.left,c=s.bottom;const u=t.getBoundingClientRect(),v=o-d>=u.width+i,y=s.right>=u.width+i,w=n-c>=u.height+i,b=s.top>=u.height+i;v||!y&&w?(t.style.left=`${d}px`,t.style.right="auto"):(t.style.left="auto",t.style.right=`${o-s.right}px`),w||!b&&v?(t.style.top=`${c}px`,t.style.bottom="auto"):(t.style.top="auto",t.style.bottom=`${n-s.top}px`),requestAnimationFrame(()=>{const C=t.getBoundingClientRect();if(C.right>o-i){const P=C.right-(o-i),O=parseFloat(t.style.left||"0");Number.isNaN(O)||(t.style.left=`${Math.max(0,O-P)}px`)}if(C.left<i){const P=i-C.left,O=parseFloat(t.style.left||"0");Number.isNaN(O)||(t.style.left=`${Math.max(0,O+P)}px`)}if(C.bottom>n-i){const P=C.bottom-(n-i),O=parseFloat(t.style.bottom||"0");Number.isNaN(O)||(t.style.bottom=`${Math.max(0,O+P)}px`)}if(C.top<i){const P=i-C.top,O=parseFloat(t.style.top||"0");Number.isNaN(O)||(t.style.top=`${Math.max(0,O+P)}px`)}})}render(){return l`
|
|
1252
1252
|
<div
|
|
1253
1253
|
data-slot="dropdown-menu-content"
|
|
1254
1254
|
part="dropdown-menu-content"
|
|
1255
1255
|
style="display: ${this.isOpen?"block":"none"};"
|
|
1256
1256
|
class=${m(Lt.content,this.className)}
|
|
1257
1257
|
></div>
|
|
1258
|
-
`}};ol([a({attribute:"data-state",type:String})],fi.prototype,"state",2);ol([g()],fi.prototype,"isOpen",2);fi=ol([p("pont-dropdown-menu-content")],fi);var Mv=Object.defineProperty,Bv=Object.getOwnPropertyDescriptor,Ni=(e,t,r,o)=>{for(var n=o>1?void 0:o?Bv(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&Mv(t,r,n),n};let _o=class extends
|
|
1258
|
+
`}};ol([a({attribute:"data-state",type:String})],fi.prototype,"state",2);ol([g()],fi.prototype,"isOpen",2);fi=ol([p("pont-dropdown-menu-content")],fi);var Mv=Object.defineProperty,Bv=Object.getOwnPropertyDescriptor,Ni=(e,t,r,o)=>{for(var n=o>1?void 0:o?Bv(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&Mv(t,r,n),n};let _o=class extends _{constructor(){super(...arguments),this.heading="",this._id="",this._hidden=""}get _containerElement(){return this.querySelector("div[rtgcmd-group-items]")}createRenderRoot(){return this}firstUpdated(e){this.moveLightDomChildrenInto(this._containerElement)}render(){return l`${this._hidden==="true"?h:l`
|
|
1259
1259
|
<div
|
|
1260
1260
|
rtgcmd-group
|
|
1261
1261
|
part="dropdown-menu-group"
|
|
@@ -1268,7 +1268,7 @@
|
|
|
1268
1268
|
|
|
1269
1269
|
<div rtgcmd-group-items role="group"></div>
|
|
1270
1270
|
</div>
|
|
1271
|
-
`}`}};Ni([a({type:String})],_o.prototype,"heading",2);Ni([a({attribute:"id",type:String})],_o.prototype,"_id",2);Ni([a({attribute:"aria-hidden",type:String})],_o.prototype,"_hidden",2);_o=Ni([p("pont-dropdown-menu-group")],_o);var Uv=Object.defineProperty,qv=Object.getOwnPropertyDescriptor,Vn=(e,t,r,o)=>{for(var n=o>1?void 0:o?qv(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&Uv(t,r,n),n};let Kr=class extends
|
|
1271
|
+
`}`}};Ni([a({type:String})],_o.prototype,"heading",2);Ni([a({attribute:"id",type:String})],_o.prototype,"_id",2);Ni([a({attribute:"aria-hidden",type:String})],_o.prototype,"_hidden",2);_o=Ni([p("pont-dropdown-menu-group")],_o);var Uv=Object.defineProperty,qv=Object.getOwnPropertyDescriptor,Vn=(e,t,r,o)=>{for(var n=o>1?void 0:o?qv(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&Uv(t,r,n),n};let Kr=class extends _{constructor(){super(...arguments),this._id="",this._hidden="",this.selected=!1,this.disabled=!1}get _containerElement(){return this.querySelector("div[part=dropdown-menu-item]")}get value(){var e;return((e=this.textContent)==null?void 0:e.trim())||""}get _dropdownMenu(){let e=this.parentElement;for(;e&&!(e instanceof Pt);)e=e.parentElement;return e}handleMouseEvent(e){console.log(e,this.value),(e.type==="mouseover"||e.type==="focus")&&(this.selected=!0),e.type==="mouseleave"&&(this.selected=!1)}handleClickDefault(){this._dropdownMenu.isOpen=!1}createRenderRoot(){return this}firstUpdated(e){this.moveLightDomChildrenInto(this._containerElement)}render(){return l` ${this._hidden==="true"?h:l`
|
|
1272
1272
|
<div
|
|
1273
1273
|
rtgcmd-item
|
|
1274
1274
|
part="dropdown-menu-item"
|
|
@@ -1284,7 +1284,7 @@
|
|
|
1284
1284
|
@click="${this.handleClickDefault}"
|
|
1285
1285
|
class=${m(Lt.item,this.className)}
|
|
1286
1286
|
></div>
|
|
1287
|
-
`}`}};Vn([a({type:String})],Kr.prototype,"_id",2);Vn([a({attribute:"aria-hidden",type:String})],Kr.prototype,"_hidden",2);Vn([a({attribute:"data-value",type:String})],Kr.prototype,"value",1);Vn([a({type:Boolean})],Kr.prototype,"selected",2);Vn([a({attribute:"data-disabled",type:Boolean})],Kr.prototype,"disabled",2);Kr=Vn([p("pont-dropdown-menu-item")],Kr);var jv=Object.defineProperty,zv=Object.getOwnPropertyDescriptor,tn=(e,t,r,o)=>{for(var n=o>1?void 0:o?zv(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&jv(t,r,n),n};let yr=class extends
|
|
1287
|
+
`}`}};Vn([a({type:String})],Kr.prototype,"_id",2);Vn([a({attribute:"aria-hidden",type:String})],Kr.prototype,"_hidden",2);Vn([a({attribute:"data-value",type:String})],Kr.prototype,"value",1);Vn([a({type:Boolean})],Kr.prototype,"selected",2);Vn([a({attribute:"data-disabled",type:Boolean})],Kr.prototype,"disabled",2);Kr=Vn([p("pont-dropdown-menu-item")],Kr);var jv=Object.defineProperty,zv=Object.getOwnPropertyDescriptor,tn=(e,t,r,o)=>{for(var n=o>1?void 0:o?zv(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&jv(t,r,n),n};let yr=class extends _{constructor(){super(...arguments),this._id="",this._hidden="",this.selected=!1,this.checked=!1,this.disabled=!1}get value(){var e;return((e=this.textContent)==null?void 0:e.trim())||""}get _containerElement(){return this.querySelector("div[part=dropdown-menu-radio-item-container]")}handleMouseEvent(e){(e.type==="mouseover"||e.type==="focus")&&(this.selected=!0),e.type==="mouseleave"&&(this.selected=!1)}toggleChecked(){this.checked||(this.checked=!0,this.dispatchEvent(new CustomEvent("radio-selected",{bubbles:!0,composed:!0})))}createRenderRoot(){return this}firstUpdated(e){this.moveLightDomChildrenInto(this._containerElement)}render(){return l`
|
|
1288
1288
|
<div
|
|
1289
1289
|
rtgcmd-item
|
|
1290
1290
|
part="dropdown-menu-radio"
|
|
@@ -1319,18 +1319,18 @@
|
|
|
1319
1319
|
</span>
|
|
1320
1320
|
<div part="dropdown-menu-radio-item-container"></div>
|
|
1321
1321
|
</div>
|
|
1322
|
-
`}};tn([a({type:String})],yr.prototype,"_id",2);tn([a({attribute:"aria-hidden",type:String})],yr.prototype,"_hidden",2);tn([a({attribute:"data-value",type:String})],yr.prototype,"value",1);tn([a({type:Boolean})],yr.prototype,"selected",2);tn([a({type:Boolean})],yr.prototype,"checked",2);tn([a({attribute:"data-disabled",type:Boolean})],yr.prototype,"disabled",2);yr=tn([p("pont-dropdown-menu-radio-item")],yr);var Vv=Object.getOwnPropertyDescriptor,Hv=(e,t,r,o)=>{for(var n=o>1?void 0:o?Vv(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let Ad=class extends
|
|
1322
|
+
`}};tn([a({type:String})],yr.prototype,"_id",2);tn([a({attribute:"aria-hidden",type:String})],yr.prototype,"_hidden",2);tn([a({attribute:"data-value",type:String})],yr.prototype,"value",1);tn([a({type:Boolean})],yr.prototype,"selected",2);tn([a({type:Boolean})],yr.prototype,"checked",2);tn([a({attribute:"data-disabled",type:Boolean})],yr.prototype,"disabled",2);yr=tn([p("pont-dropdown-menu-radio-item")],yr);var Vv=Object.getOwnPropertyDescriptor,Hv=(e,t,r,o)=>{for(var n=o>1?void 0:o?Vv(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let Ad=class extends _{get _containerElement(){return this.querySelector("div[part=dropdown-menu-seperator]")}createRenderRoot(){return this}firstUpdated(e){this.moveLightDomChildrenInto(this._containerElement)}render(){return l`<div
|
|
1323
1323
|
rtgcmd-separator
|
|
1324
1324
|
part="dropdown-menu-seperator"
|
|
1325
1325
|
role="separator"
|
|
1326
1326
|
class=${m(Lt.separator,this.className)}
|
|
1327
|
-
></div>`}};Ad=Hv([p("pont-dropdown-menu-separator")],Ad);var Gv=Object.getOwnPropertyDescriptor,Kv=(e,t,r,o)=>{for(var n=o>1?void 0:o?Gv(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let Td=class extends
|
|
1327
|
+
></div>`}};Ad=Hv([p("pont-dropdown-menu-separator")],Ad);var Gv=Object.getOwnPropertyDescriptor,Kv=(e,t,r,o)=>{for(var n=o>1?void 0:o?Gv(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let Td=class extends _{get _containerElement(){return this.querySelector("span[part=dropdown-menu-shortcut]")}firstUpdated(e){this.moveLightDomChildrenInto(this._containerElement)}createRenderRoot(){return this.classList=m(Lt.shortcut),this}render(){return l`
|
|
1328
1328
|
<span
|
|
1329
1329
|
part="dropdown-menu-shortcut"
|
|
1330
1330
|
class=${m(Lt.shortcut,this.className)}
|
|
1331
1331
|
>
|
|
1332
1332
|
</span>
|
|
1333
|
-
`}};Td=Kv([p("pont-dropdown-menu-shortcut")],Td);var Wv=Object.getOwnPropertyDescriptor,Yv=(e,t,r,o)=>{for(var n=o>1?void 0:o?Wv(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let Dd=class extends f{createRenderRoot(){return this}render(){return l``}};Dd=Yv([p("pont-dropdown-menu-trigger")],Dd);var Qv=Object.defineProperty,Zv=Object.getOwnPropertyDescriptor,eh=(e,t,r,o)=>{for(var n=o>1?void 0:o?Zv(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&Qv(t,r,n),n};let Pt=class extends
|
|
1333
|
+
`}};Td=Kv([p("pont-dropdown-menu-shortcut")],Td);var Wv=Object.getOwnPropertyDescriptor,Yv=(e,t,r,o)=>{for(var n=o>1?void 0:o?Wv(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let Dd=class extends f{createRenderRoot(){return this}render(){return l``}};Dd=Yv([p("pont-dropdown-menu-trigger")],Dd);var Qv=Object.defineProperty,Zv=Object.getOwnPropertyDescriptor,eh=(e,t,r,o)=>{for(var n=o>1?void 0:o?Zv(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&Qv(t,r,n),n};let Pt=class extends _{constructor(){super(...arguments),this.isOpen=!1,this.handleClickOutside=e=>{var r,o;const t=e.target;!((r=this._containerElement)!=null&&r.contains(t))&&!((o=this._triggerElement)!=null&&o.contains(t))&&(this.isOpen=!1,Pt._openInstance===this&&(Pt._openInstance=null))}}get _triggerElement(){return this.querySelector("pont-dropdown-menu-trigger")}get _containerElement(){return this.querySelector("div[part=dropdown-menu]")}get _content(){return this.querySelector("pont-dropdown-menu-content")}connectedCallback(){super.connectedCallback(),document.addEventListener("click",this.handleClickOutside),this.addEventListener("radio-selected",this._handleRadioSelected)}toggleDropdown(e){e.stopPropagation();const t=this.isOpen;this.isOpen=!this.isOpen,this.isOpen?(Pt._openInstance&&Pt._openInstance!==this&&(Pt._openInstance.isOpen=!1),Pt._openInstance=this):t&&Pt._openInstance===this&&(Pt._openInstance=null)}disconnectedCallback(){Pt._openInstance===this&&(Pt._openInstance=null),document.removeEventListener("click",this.handleClickOutside),super.disconnectedCallback()}updated(e){super.updated(e);const t=this._content;t&&(t.dataset.state=this.isOpen?"open":"close")}firstUpdated(e){var t;this.moveLightDomChildrenInto(this._containerElement),(t=this._triggerElement)==null||t.addEventListener("click",r=>this.toggleDropdown(r))}_handleRadioSelected(e){this.isOpen=!1,this.querySelectorAll("pont-dropdown-menu-radio-item").forEach(t=>{t!==e.target&&(t.checked=!1)})}createRenderRoot(){return this}render(){return l`
|
|
1334
1334
|
<div
|
|
1335
1335
|
part="dropdown-menu"
|
|
1336
1336
|
class=${m(Lt.root,this.className)}
|
|
@@ -1398,26 +1398,26 @@
|
|
|
1398
1398
|
data-slot="field-error"
|
|
1399
1399
|
role="alert"
|
|
1400
1400
|
>${t}</div>
|
|
1401
|
-
`:(this.style.display="none",h)}};lh([a({type:Array})],ua.prototype,"errors",2);ua=lh([p("pont-field-error")],ua);class dh{constructor(){this.values={},this.errors={},this.validators={},this.subscribers=new Set}registerField({name:t,defaultValue:r="",validator:o}){t in this.values||(this.values[t]=r),o&&(this.validators[t]=o)}unregisterField(t){delete this.values[t],delete this.errors[t],delete this.validators[t]}setValue(t,r){t in this.validators||console.warn(`[FormController] setValue called before validator was registered for "${t}"`),this.values[t]=r,this.validateField(t),this.notify()}getValue(t){return this.values[t]}getError(t){return this.errors[t]??null}validateField(t){const r=this.validators[t],o=this.values[t],n=r?r(o):null;return this.errors[t]=n,this.notify(),!n}validateAll(){let t=!0;return Object.keys(this.validators).forEach(r=>{this.validateField(r)||(t=!1)}),t}subscribe(t){return this.subscribers.add(t),()=>this.subscribers.delete(t)}notify(){this.subscribers.forEach(t=>t())}getValues(){return{...this.values}}getErrors(){return{...this.errors}}}const To="pont-form-context",us=new WeakMap,Tb=Xr(class extends Lp{render(e){return h}update(e,[t]){var o;const r=t!==this.G;return r&&this.rt(void 0),(r||this.lt!==this.ct)&&(this.G=t,this.ht=(o=e.options)==null?void 0:o.host,this.rt(this.ct=e.element)),h}rt(e){if(this.G!==void 0)if(this.isConnected||(e=void 0),typeof this.G=="function"){const t=this.ht??globalThis;let r=us.get(t);r===void 0&&(r=new WeakMap,us.set(t,r)),r.get(this.G)!==void 0&&this.G.call(this.ht,void 0),r.set(this.G,e),e!==void 0&&this.G.call(this.ht,e)}else this.G.value=e}get lt(){var e,t;return typeof this.G=="function"?(e=us.get(this.ht??globalThis))==null?void 0:e.get(this.G):(t=this.G)==null?void 0:t.value}disconnected(){this.lt===this.ct&&this.rt(void 0)}reconnected(){this.rt(this.ct)}});var Db=Object.defineProperty,Lb=Object.getOwnPropertyDescriptor,ch=(e,t,r,o)=>{for(var n=o>1?void 0:o?Lb(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&Db(t,r,n),n};let ma=class extends
|
|
1401
|
+
`:(this.style.display="none",h)}};lh([a({type:Array})],ua.prototype,"errors",2);ua=lh([p("pont-field-error")],ua);class dh{constructor(){this.values={},this.errors={},this.validators={},this.subscribers=new Set}registerField({name:t,defaultValue:r="",validator:o}){t in this.values||(this.values[t]=r),o&&(this.validators[t]=o)}unregisterField(t){delete this.values[t],delete this.errors[t],delete this.validators[t]}setValue(t,r){t in this.validators||console.warn(`[FormController] setValue called before validator was registered for "${t}"`),this.values[t]=r,this.validateField(t),this.notify()}getValue(t){return this.values[t]}getError(t){return this.errors[t]??null}validateField(t){const r=this.validators[t],o=this.values[t],n=r?r(o):null;return this.errors[t]=n,this.notify(),!n}validateAll(){let t=!0;return Object.keys(this.validators).forEach(r=>{this.validateField(r)||(t=!1)}),t}subscribe(t){return this.subscribers.add(t),()=>this.subscribers.delete(t)}notify(){this.subscribers.forEach(t=>t())}getValues(){return{...this.values}}getErrors(){return{...this.errors}}}const To="pont-form-context",us=new WeakMap,Tb=Xr(class extends Lp{render(e){return h}update(e,[t]){var o;const r=t!==this.G;return r&&this.rt(void 0),(r||this.lt!==this.ct)&&(this.G=t,this.ht=(o=e.options)==null?void 0:o.host,this.rt(this.ct=e.element)),h}rt(e){if(this.G!==void 0)if(this.isConnected||(e=void 0),typeof this.G=="function"){const t=this.ht??globalThis;let r=us.get(t);r===void 0&&(r=new WeakMap,us.set(t,r)),r.get(this.G)!==void 0&&this.G.call(this.ht,void 0),r.set(this.G,e),e!==void 0&&this.G.call(this.ht,e)}else this.G.value=e}get lt(){var e,t;return typeof this.G=="function"?(e=us.get(this.ht??globalThis))==null?void 0:e.get(this.G):(t=this.G)==null?void 0:t.value}disconnected(){this.lt===this.ct&&this.rt(void 0)}reconnected(){this.rt(this.ct)}});var Db=Object.defineProperty,Lb=Object.getOwnPropertyDescriptor,ch=(e,t,r,o)=>{for(var n=o>1?void 0:o?Lb(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&Db(t,r,n),n};let ma=class extends _{constructor(){super(...arguments),this.form=new dh,this.handleSubmit=e=>{if(e.preventDefault(),this.form.validateAll()){const r=this.form.getValues();alert(JSON.stringify(r,null,2))}}}createRenderRoot(){return this}async firstUpdated(e){await this.updateComplete,Array.from(this.childNodes).forEach(t=>{t!==this.formElement&&this.formElement.appendChild(t)}),this.querySelectorAll("pont-form-field").forEach(t=>{const r=t.getAttribute("name"),o=t.validators,n=o==null?void 0:o[0];this.form.registerField({name:r,validator:n})})}render(){return l`
|
|
1402
1402
|
<form
|
|
1403
1403
|
part="form-controller"
|
|
1404
1404
|
class="${m("",this.className)}"
|
|
1405
1405
|
@submit=${this.handleSubmit}
|
|
1406
1406
|
${Tb(e=>this.formElement=e)}
|
|
1407
1407
|
></form>
|
|
1408
|
-
`}};ch([g(),Jt({context:To})],ma.prototype,"form",2);ma=ch([p("pont-form-controller")],ma);const ph="pont-form-item-context",Fb="pont-space-form-space-y",kb="pont-text-form-description-font pont-text-form-description-color-text pont-mt-form-description-space-mt",Nb="pont-space-y-form-field-space-y",Mb="pont-space-y-form-item-space-y",Bb="pont-text-form-label-font pont-mb-form-label-space-mb pont-font-form-label-font-weight pont-peer-disabled:pont-cursor-not-allowed peer-disabled:pont-opacity-form-label-opacity-peer-disabled",Ub="pont-text-form-label-color-text-error",qb="pont-text-form-message-font-size pont-text-form-message-color-text";var jb=Object.defineProperty,zb=Object.getOwnPropertyDescriptor,hh=(e,t,r,o)=>{for(var n=o>1?void 0:o?zb(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&jb(t,r,n),n};let ga=class extends
|
|
1408
|
+
`}};ch([g(),Jt({context:To})],ma.prototype,"form",2);ma=ch([p("pont-form-controller")],ma);const ph="pont-form-item-context",Fb="pont-space-form-space-y",kb="pont-text-form-description-font pont-text-form-description-color-text pont-mt-form-description-space-mt",Nb="pont-space-y-form-field-space-y",Mb="pont-space-y-form-item-space-y",Bb="pont-text-form-label-font pont-mb-form-label-space-mb pont-font-form-label-font-weight pont-peer-disabled:pont-cursor-not-allowed peer-disabled:pont-opacity-form-label-opacity-peer-disabled",Ub="pont-text-form-label-color-text-error",qb="pont-text-form-message-font-size pont-text-form-message-color-text";var jb=Object.defineProperty,zb=Object.getOwnPropertyDescriptor,hh=(e,t,r,o)=>{for(var n=o>1?void 0:o?zb(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&jb(t,r,n),n};let ga=class extends _{createRenderRoot(){return this}get _desc(){return this.querySelector("p[part=form-description]")}firstUpdated(){this.moveLightDomChildrenInto(this._desc)}render(){return l`
|
|
1409
1409
|
<p
|
|
1410
1410
|
id="${this.itemContext.id}-description"
|
|
1411
1411
|
part="form-description"
|
|
1412
1412
|
class="${m(kb,this.className)}"
|
|
1413
1413
|
></p>
|
|
1414
|
-
`}};hh([yt({context:ph})],ga.prototype,"itemContext",2);ga=hh([p("pont-form-description")],ga);const Vb="pont-form-field-context";var Hb=Object.defineProperty,Gb=Object.getOwnPropertyDescriptor,Hn=(e,t,r,o)=>{for(var n=o>1?void 0:o?Gb(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&Hb(t,r,n),n};let er=class extends
|
|
1414
|
+
`}};hh([yt({context:ph})],ga.prototype,"itemContext",2);ga=hh([p("pont-form-description")],ga);const Vb="pont-form-field-context";var Hb=Object.defineProperty,Gb=Object.getOwnPropertyDescriptor,Hn=(e,t,r,o)=>{for(var n=o>1?void 0:o?Gb(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&Hb(t,r,n),n};let er=class extends _{constructor(){super(...arguments),this.name="",this.validators=[],this.defaultValue="",this.fieldName="",this.registered=!1}createRenderRoot(){return this}get _container(){return this.querySelector("div[part=form-field]")}updated(){var t;if(this.registered||!this.form||!this.name)return;this.form.registerField({name:this.name,validator:r=>{for(const o of this.validators??[]){const n=o(r);if(n)return n}return null},defaultValue:this.defaultValue}),this.registered=!0,this.moveLightDomChildrenInto(this._container);const e=(t=this._container)==null?void 0:t.querySelector("pont-input, input, textarea, select");e&&(e.value=this.defaultValue??"",this.form.setValue(this.name,this.defaultValue??""),e.addEventListener("input",()=>{this.form.setValue(this.name,e.value)}))}disconnectedCallback(){var e;super.disconnectedCallback(),this.isConnected||(e=this.form)==null||e.unregisterField(this.name)}render(){return l`<div
|
|
1415
1415
|
part="form-field"
|
|
1416
1416
|
class="${m(Nb,this.className)}"
|
|
1417
|
-
></div>`}};Hn([yt({context:To})],er.prototype,"form",2);Hn([a({type:String})],er.prototype,"name",2);Hn([a({type:Array})],er.prototype,"validators",2);Hn([a({type:String})],er.prototype,"defaultValue",2);Hn([Jt({context:Vb})],er.prototype,"fieldName",2);er=Hn([p("pont-form-field")],er);var Kb=Object.defineProperty,Wb=Object.getOwnPropertyDescriptor,uh=(e,t,r,o)=>{for(var n=o>1?void 0:o?Wb(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&Kb(t,r,n),n};let fa=class extends
|
|
1417
|
+
></div>`}};Hn([yt({context:To})],er.prototype,"form",2);Hn([a({type:String})],er.prototype,"name",2);Hn([a({type:Array})],er.prototype,"validators",2);Hn([a({type:String})],er.prototype,"defaultValue",2);Hn([Jt({context:Vb})],er.prototype,"fieldName",2);er=Hn([p("pont-form-field")],er);var Kb=Object.defineProperty,Wb=Object.getOwnPropertyDescriptor,uh=(e,t,r,o)=>{for(var n=o>1?void 0:o?Wb(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&Kb(t,r,n),n};let fa=class extends _{constructor(){super(...arguments),this._generatedId=crypto.randomUUID(),this.itemContext={id:this._generatedId}}createRenderRoot(){return this}get _container(){return this.querySelector("div[part=form-item]")}firstUpdated(){this.moveLightDomChildrenInto(this._container)}render(){return l`<div
|
|
1418
1418
|
part="form-item"
|
|
1419
1419
|
class="${m(Mb,this.className)}"
|
|
1420
|
-
></div>`}};uh([Jt({context:ph})],fa.prototype,"itemContext",2);fa=uh([p("pont-form-item")],fa);var Yb=Object.defineProperty,Qb=Object.getOwnPropertyDescriptor,il=(e,t,r,o)=>{for(var n=o>1?void 0:o?Qb(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&Yb(t,r,n),n};let vi=class extends
|
|
1420
|
+
></div>`}};uh([Jt({context:ph})],fa.prototype,"itemContext",2);fa=uh([p("pont-form-item")],fa);var Yb=Object.defineProperty,Qb=Object.getOwnPropertyDescriptor,il=(e,t,r,o)=>{for(var n=o>1?void 0:o?Qb(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&Yb(t,r,n),n};let vi=class extends _{constructor(){super(...arguments),this.hasError=!1,this.unsubscribe=null}get _field(){let e=this.parentElement;for(;e&&!(e instanceof er);)e=e.parentElement;return e}createRenderRoot(){return this}get _label(){return this.querySelector("label[part=form-label]")}firstUpdated(){this.moveLightDomChildrenInto(this._label)}connectedCallback(){super.connectedCallback();const e=this._field.name;this.hasError=!!this.form.getError(e),this.unsubscribe=this.form.subscribe(()=>{const t=this.form.getError(e);this.hasError=!!t,this.requestUpdate()})}disconnectedCallback(){super.disconnectedCallback(),this.unsubscribe&&this.unsubscribe()}render(){return l`
|
|
1421
1421
|
<label
|
|
1422
1422
|
part="form-label"
|
|
1423
1423
|
for="${this._field.name}"
|
|
@@ -1428,21 +1428,21 @@
|
|
|
1428
1428
|
class="${m(qb,this.className)}"
|
|
1429
1429
|
>
|
|
1430
1430
|
${this.error}
|
|
1431
|
-
</p>`:null}};sl([yt({context:To})],bi.prototype,"form",2);sl([g()],bi.prototype,"error",2);bi=sl([p("pont-form-message")],bi);var Xb=Object.defineProperty,ty=Object.getOwnPropertyDescriptor,al=(e,t,r,o)=>{for(var n=o>1?void 0:o?ty(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&Xb(t,r,n),n};let yi=class extends
|
|
1431
|
+
</p>`:null}};sl([yt({context:To})],bi.prototype,"form",2);sl([g()],bi.prototype,"error",2);bi=sl([p("pont-form-message")],bi);var Xb=Object.defineProperty,ty=Object.getOwnPropertyDescriptor,al=(e,t,r,o)=>{for(var n=o>1?void 0:o?ty(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&Xb(t,r,n),n};let yi=class extends _{constructor(){super(...arguments),this.form=new dh,this.onSubmit=()=>{},this.handleSubmit=t=>{t.preventDefault(),this.form.validateAll()&&this.onSubmit(this.form.getValues())}}createRenderRoot(){return this}get _formElement(){return this.querySelector("form[part=form-root]")}firstUpdated(){this.moveLightDomChildrenInto(this._formElement)}render(){return l`
|
|
1432
1432
|
<form
|
|
1433
1433
|
part="form-root"
|
|
1434
1434
|
id="pont-form-root"
|
|
1435
1435
|
@submit=${this.handleSubmit}
|
|
1436
1436
|
class="${m(Fb,this.className)}"
|
|
1437
1437
|
></form>
|
|
1438
|
-
`}};al([Jt({context:To})],yi.prototype,"form",2);al([a({type:Function})],yi.prototype,"onSubmit",2);yi=al([p("pont-form-root")],yi);const ll={root:[""],trigger:[""],content:["pont-fixed pont-z-50","pont-p-hover-card-content-space-p","pont-w-hover-card-content-space-w","pont-text-hover-card-content-color-text","pont-bg-hover-card-content-color-bg","pont-rounded-hover-card-content-radius pont-border-hover-card-content-width-border pont-border-hover-card-content-color-border pont-outline-hidden","pont-shadow-hover-card-content-shadow","data-[state=open]:pont-animate-in data-[state=open]:pont-fade-in-0 data-[state=open]:pont-zoom-in-95","data-[state=closed]:pont-animate-out data-[state=closed]:pont-fade-out-0 data-[state=closed]:pont-zoom-out-95","data-[side=bottom]:pont-slide-in-from-top-2 data-[side=left]:pont-slide-in-from-right-2 data-[side=right]:pont-slide-in-from-left-2 data-[side=top]:pont-slide-in-from-bottom-2"]};var ey=Object.defineProperty,ry=Object.getOwnPropertyDescriptor,dl=(e,t,r,o)=>{for(var n=o>1?void 0:o?ry(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&ey(t,r,n),n};let _i=class extends
|
|
1438
|
+
`}};al([Jt({context:To})],yi.prototype,"form",2);al([a({type:Function})],yi.prototype,"onSubmit",2);yi=al([p("pont-form-root")],yi);const ll={root:[""],trigger:[""],content:["pont-fixed pont-z-50","pont-p-hover-card-content-space-p","pont-w-hover-card-content-space-w","pont-text-hover-card-content-color-text","pont-bg-hover-card-content-color-bg","pont-rounded-hover-card-content-radius pont-border-hover-card-content-width-border pont-border-hover-card-content-color-border pont-outline-hidden","pont-shadow-hover-card-content-shadow","data-[state=open]:pont-animate-in data-[state=open]:pont-fade-in-0 data-[state=open]:pont-zoom-in-95","data-[state=closed]:pont-animate-out data-[state=closed]:pont-fade-out-0 data-[state=closed]:pont-zoom-out-95","data-[side=bottom]:pont-slide-in-from-top-2 data-[side=left]:pont-slide-in-from-right-2 data-[side=right]:pont-slide-in-from-left-2 data-[side=top]:pont-slide-in-from-bottom-2"]};var ey=Object.defineProperty,ry=Object.getOwnPropertyDescriptor,dl=(e,t,r,o)=>{for(var n=o>1?void 0:o?ry(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&ey(t,r,n),n};let _i=class extends _{constructor(){super(...arguments),this.state="closed",this.isOpen=!1,this.onStateChange=e=>{const t=e.detail.isOpen;this.state=t?"open":"closed"},this.handlePointerLeaveCheck=e=>{this.contains(e.relatedTarget)||(this.isOpen=!1)}}connectedCallback(){super.connectedCallback(),document.addEventListener("hover-card-state-change",this.onStateChange),this.addEventListener("mouseenter",this.handlePointerLeaveCheck),this.addEventListener("mouseleave",this.handlePointerLeaveCheck)}disconnectedCallback(){document.removeEventListener("hover-card-state-change",this.onStateChange),this.removeEventListener("mouseenter",this.handlePointerLeaveCheck),this.removeEventListener("mouseleave",this.handlePointerLeaveCheck),super.disconnectedCallback()}updated(e){super.updated(e),this.isOpen=this.state==="open"}createRenderRoot(){return this}getAttributesToExclude(){return[]}firstUpdated(e){this.moveLightDomChildrenInto(this.renderRoot.querySelector("#pont-hover-card-content"))}render(){return l`
|
|
1439
1439
|
<div
|
|
1440
1440
|
id="pont-hover-card-content"
|
|
1441
1441
|
part="hover-card-content"
|
|
1442
1442
|
class=${m(ll.content,this.className)}
|
|
1443
1443
|
style="display: ${this.isOpen?"block":"none"};"
|
|
1444
1444
|
></div>
|
|
1445
|
-
`}};dl([a({attribute:"data-state",type:String})],_i.prototype,"state",2);dl([g()],_i.prototype,"isOpen",2);_i=dl([p("pont-hover-card-content")],_i);var ny=Object.getOwnPropertyDescriptor,oy=(e,t,r,o)=>{for(var n=o>1?void 0:o?ny(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let zd=class extends
|
|
1445
|
+
`}};dl([a({attribute:"data-state",type:String})],_i.prototype,"state",2);dl([g()],_i.prototype,"isOpen",2);_i=dl([p("pont-hover-card-content")],_i);var ny=Object.getOwnPropertyDescriptor,oy=(e,t,r,o)=>{for(var n=o>1?void 0:o?ny(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let zd=class extends _{getAttributesToExclude(){return["value","defaultValue"]}createRenderRoot(){return this}firstUpdated(e){this.removeDuplicateContent()}render(){return l`
|
|
1446
1446
|
<div
|
|
1447
1447
|
id="pont-hover-card-trigger"
|
|
1448
1448
|
part="pont-hover-card-trigger"
|
|
@@ -1450,7 +1450,7 @@
|
|
|
1450
1450
|
>
|
|
1451
1451
|
${Array.from(this.children)}
|
|
1452
1452
|
</div>
|
|
1453
|
-
`}};zd=oy([p("pont-hover-card-trigger")],zd);var iy=Object.defineProperty,sy=Object.getOwnPropertyDescriptor,mh=(e,t,r,o)=>{for(var n=o>1?void 0:o?sy(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&iy(t,r,n),n};let va=class extends
|
|
1453
|
+
`}};zd=oy([p("pont-hover-card-trigger")],zd);var iy=Object.defineProperty,sy=Object.getOwnPropertyDescriptor,mh=(e,t,r,o)=>{for(var n=o>1?void 0:o?sy(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&iy(t,r,n),n};let va=class extends _{constructor(){super(...arguments),this.isOpen=!1,this.hoverTimeout=null,this.openCard=()=>{var e;this.hoverTimeout&&(clearTimeout(this.hoverTimeout),this.hoverTimeout=null),this.isOpen||(this.isOpen=!0,(e=this._content)==null||e.dispatchEvent(new CustomEvent("hover-card-state-change",{detail:{isOpen:!0}})))},this.closeCard=()=>{this.hoverTimeout=setTimeout(()=>{var e;this.isOpen=!1,(e=this._content)==null||e.dispatchEvent(new CustomEvent("hover-card-state-change",{detail:{isOpen:!1}}))},150)}}get _containerElement(){return this.renderRoot.querySelector("#pont-hover-card-container")}get _content(){return this.renderRoot.querySelector("pont-hover-card-content")}get _trigger(){return this.renderRoot.querySelector("pont-hover-card-trigger")}getAttributesToExclude(){return[]}updated(e){super.updated(e);const t=this._content;t&&(t.dataset.state=this.isOpen?"open":"closed")}connectedCallback(){super.connectedCallback()}disconnectedCallback(){const e=this._trigger,t=this._content;e==null||e.removeEventListener("mouseenter",this.openCard),e==null||e.removeEventListener("mouseleave",this.closeCard),t==null||t.removeEventListener("mouseenter",this.openCard),t==null||t.removeEventListener("mouseleave",this.closeCard),this.hoverTimeout&&clearTimeout(this.hoverTimeout),super.disconnectedCallback()}createRenderRoot(){return this}firstUpdated(e){const t=this._containerElement;this.moveLightDomChildrenInto(t);const r=this._trigger,o=this._content;r==null||r.addEventListener("mouseenter",this.openCard),r==null||r.addEventListener("mouseleave",this.closeCard),o==null||o.addEventListener("mouseenter",this.openCard),o==null||o.addEventListener("mouseleave",this.closeCard)}render(){return l`
|
|
1454
1454
|
<div
|
|
1455
1455
|
id="pont-hover-card-container"
|
|
1456
1456
|
part="hover-card"
|
|
@@ -1645,7 +1645,7 @@
|
|
|
1645
1645
|
data-slot="item-separator"
|
|
1646
1646
|
orientation="horizontal"
|
|
1647
1647
|
></pont-separator>
|
|
1648
|
-
`}};tc=Wy([p("pont-item-separator")],tc);var Yy=Object.getOwnPropertyDescriptor,Qy=(e,t,r,o)=>{for(var n=o>1?void 0:o?Yy(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let ec=class extends f{createRenderRoot(){return this}get _titleSlot(){return this.querySelector('[data-slot="item-title"]')}firstUpdated(){const e=this._titleSlot;if(!e)return;Array.from(this.childNodes).filter(r=>r!==e).forEach(r=>e.appendChild(r))}render(){return l`<div data-slot="item-title"></div>`}};ec=Qy([p("pont-item-title")],ec);var Zy=Object.getOwnPropertyDescriptor,Jy=(e,t,r,o)=>{for(var n=o>1?void 0:o?Zy(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let rc=class extends f{createRenderRoot(){return this}get _rootSlot(){return this.querySelector('[data-slot="kbd"]')}firstUpdated(){const e=this._rootSlot;if(!e)return;Array.from(this.childNodes).filter(r=>r!==e).forEach(r=>e.appendChild(r))}render(){return l`<kbd data-slot="kbd"></kbd>`}};rc=Jy([p("pont-kbd")],rc);var Xy=Object.getOwnPropertyDescriptor,t_=(e,t,r,o)=>{for(var n=o>1?void 0:o?Xy(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let nc=class extends f{createRenderRoot(){return this}get _groupSlot(){return this.querySelector('[data-slot="kbd-group"]')}firstUpdated(){const e=this._groupSlot;if(!e)return;Array.from(this.childNodes).filter(r=>r!==e).forEach(r=>e.appendChild(r))}render(){return l`<kbd data-slot="kbd-group"></kbd>`}};nc=t_([p("pont-kbd-group")],nc);const St={root:["pont-flex","pont-gap-menubar-space-gap pont-items-center","pont-p-menubar-space-p","pont-h-menubar-space-h","pont-bg-menubar-color-bg","pont-rounded-menubar-radius pont-border-menubar-width-border pont-border-menubar-color-border"],menu:[""],group:[""],trigger:["pont-flex","pont-items-center","pont-px-menubar-trigger-space-px pont-py-menubar-trigger-space-py","pont-text-menubar-trigger-font pont-font-menubar-trigger-font-weight","pont-rounded-menubar-trigger-radius pont-outline-hidden","pont-select-none","focus:pont-text-menubar-trigger-color-text-focus focus:pont-bg-menubar-trigger-color-bg-focus","hover:pont-text-menubar-trigger-color-text-active hover:pont-bg-menubar-trigger-color-bg-active"],content:["pont-absolute pont-overflow-hidden pont-z-50","pont-p-menubar-content-space-p","pont-min-w-menubar-content-space-min-w","pont-text-menubar-content-color-text","pont-bg-menubar-content-color-bg","pont-rounded-menubar-content-radius pont-border-menubar-content-width-border pont-border-menubar-content-color-border","pont-shadow-menubar-content-shadow","pont-translate-y-2","pont-slide-in-from-top-2","data-[state=open]:pont-animate-in data-[state=open]:pont-fade-in-0 data-[state=open]:pont-zoom-in-95","data-[state=closed]:pont-animate-out data-[state=closed]:pont-fade-out-0 data-[state=closed]:pont-zoom-out-95"],item:["pont-flex pont-relative","pont-gap-menubar-item-space-gap pont-items-center","pont-px-menubar-item-space-px pont-py-menubar-item-space-py","pont-text-menubar-item-font","pont-rounded-menubar-item-radius pont-outline-hidden","pont-cursor-default pont-select-none","aria-selected:pont-text-menubar-item-color-text-active aria-selected:pont-bg-menubar-item-color-bg-active","data-[disabled]:pont-opacity-menubar-item-opacity-disabled data-[disabled]:pont-pointer-events-none",'[&_svg]:pont-shrink-0 [&_svg:not([class*="pont-size-"])]:pont-size-menubar-item-icon-space-size [&_svg:not([class*="pont-text-"])]:pont-text-menubar-item-icon-color-text [&_svg]:pont-pointer-events-none'],checkboxItem:{base:["pont-flex pont-relative","pont-gap-menubar-checkbox-item-space-gap pont-items-center","pont-pl-menubar-checkbox-item-space-pl pont-pr-menubar-checkbox-item-space-pr pont-py-menubar-checkbox-item-space-py","pont-text-menubar-checkbox-item-font","pont-rounded-menubar-checkbox-item-radius pont-outline-hidden","pont-cursor-default pont-select-none","aria-selected:pont-text-menubar-checkbox-item-color-text-active aria-selected:pont-bg-menubar-checkbox-item-color-bg-active","data-[disabled]:pont-opacity-menubar-checkbox-item-opacity-disabled data-[disabled]:pont-pointer-events-none"],indicator:["pont-flex pont-absolute pont-left-2","pont-justify-center pont-items-center","pont-size-menubar-checkbox-item-indicator-space-size","pont-pointer-events-none"],icon:["pont-shrink-0","pont-size-menubar-checkbox-item-icon-space-size","pont-pointer-events-none"]},radioItem:{base:["pont-flex pont-relative","pont-gap-menubar-radio-item-space-gap pont-items-center","pont-pl-menubar-radio-item-space-pl pont-pr-menubar-radio-item-space-pr pont-py-menubar-radio-item-space-py","pont-text-menubar-radio-item-font","pont-rounded-menubar-radio-item-radius pont-outline-hidden","pont-cursor-default pont-select-none","aria-selected:pont-text-menubar-radio-item-color-text-active aria-selected:pont-bg-menubar-radio-item-color-bg-active","data-[disabled]:pont-opacity-menubar-radio-item-opacity-disabled data-[disabled]:pont-pointer-events-none"],indicator:["pont-flex pont-absolute pont-left-2","pont-justify-center pont-items-center","pont-size-menubar-radio-item-indicator-space-size","pont-pointer-events-none"],icon:["pont-shrink-0","pont-size-menubar-radio-item-icon-space-size","pont-pointer-events-none","pont-fill-current"]},label:["pont-px-menubar-label-space-px pont-py-menubar-label-space-py","pont-text-menubar-label-font pont-font-menubar-label-font-weight"],separator:["pont-mx-menubar-separator-space-mx pont-my-menubar-separator-space-my","pont-h-menubar-separator-space-h","pont-bg-menubar-separator-color-bg"],shortcut:["pont-ml-auto","pont-text-menubar-shortcut-font pont-text-menubar-shortcut-color-text"]};var e_=Object.defineProperty,r_=Object.getOwnPropertyDescriptor,en=(e,t,r,o)=>{for(var n=o>1?void 0:o?r_(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&e_(t,r,n),n};let ae=class extends
|
|
1648
|
+
`}};tc=Wy([p("pont-item-separator")],tc);var Yy=Object.getOwnPropertyDescriptor,Qy=(e,t,r,o)=>{for(var n=o>1?void 0:o?Yy(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let ec=class extends f{createRenderRoot(){return this}get _titleSlot(){return this.querySelector('[data-slot="item-title"]')}firstUpdated(){const e=this._titleSlot;if(!e)return;Array.from(this.childNodes).filter(r=>r!==e).forEach(r=>e.appendChild(r))}render(){return l`<div data-slot="item-title"></div>`}};ec=Qy([p("pont-item-title")],ec);var Zy=Object.getOwnPropertyDescriptor,Jy=(e,t,r,o)=>{for(var n=o>1?void 0:o?Zy(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let rc=class extends f{createRenderRoot(){return this}get _rootSlot(){return this.querySelector('[data-slot="kbd"]')}firstUpdated(){const e=this._rootSlot;if(!e)return;Array.from(this.childNodes).filter(r=>r!==e).forEach(r=>e.appendChild(r))}render(){return l`<kbd data-slot="kbd"></kbd>`}};rc=Jy([p("pont-kbd")],rc);var Xy=Object.getOwnPropertyDescriptor,t_=(e,t,r,o)=>{for(var n=o>1?void 0:o?Xy(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let nc=class extends f{createRenderRoot(){return this}get _groupSlot(){return this.querySelector('[data-slot="kbd-group"]')}firstUpdated(){const e=this._groupSlot;if(!e)return;Array.from(this.childNodes).filter(r=>r!==e).forEach(r=>e.appendChild(r))}render(){return l`<kbd data-slot="kbd-group"></kbd>`}};nc=t_([p("pont-kbd-group")],nc);const St={root:["pont-flex","pont-gap-menubar-space-gap pont-items-center","pont-p-menubar-space-p","pont-h-menubar-space-h","pont-bg-menubar-color-bg","pont-rounded-menubar-radius pont-border-menubar-width-border pont-border-menubar-color-border"],menu:[""],group:[""],trigger:["pont-flex","pont-items-center","pont-px-menubar-trigger-space-px pont-py-menubar-trigger-space-py","pont-text-menubar-trigger-font pont-font-menubar-trigger-font-weight","pont-rounded-menubar-trigger-radius pont-outline-hidden","pont-select-none","focus:pont-text-menubar-trigger-color-text-focus focus:pont-bg-menubar-trigger-color-bg-focus","hover:pont-text-menubar-trigger-color-text-active hover:pont-bg-menubar-trigger-color-bg-active"],content:["pont-absolute pont-overflow-hidden pont-z-50","pont-p-menubar-content-space-p","pont-min-w-menubar-content-space-min-w","pont-text-menubar-content-color-text","pont-bg-menubar-content-color-bg","pont-rounded-menubar-content-radius pont-border-menubar-content-width-border pont-border-menubar-content-color-border","pont-shadow-menubar-content-shadow","pont-translate-y-2","pont-slide-in-from-top-2","data-[state=open]:pont-animate-in data-[state=open]:pont-fade-in-0 data-[state=open]:pont-zoom-in-95","data-[state=closed]:pont-animate-out data-[state=closed]:pont-fade-out-0 data-[state=closed]:pont-zoom-out-95"],item:["pont-flex pont-relative","pont-gap-menubar-item-space-gap pont-items-center","pont-px-menubar-item-space-px pont-py-menubar-item-space-py","pont-text-menubar-item-font","pont-rounded-menubar-item-radius pont-outline-hidden","pont-cursor-default pont-select-none","aria-selected:pont-text-menubar-item-color-text-active aria-selected:pont-bg-menubar-item-color-bg-active","data-[disabled]:pont-opacity-menubar-item-opacity-disabled data-[disabled]:pont-pointer-events-none",'[&_svg]:pont-shrink-0 [&_svg:not([class*="pont-size-"])]:pont-size-menubar-item-icon-space-size [&_svg:not([class*="pont-text-"])]:pont-text-menubar-item-icon-color-text [&_svg]:pont-pointer-events-none'],checkboxItem:{base:["pont-flex pont-relative","pont-gap-menubar-checkbox-item-space-gap pont-items-center","pont-pl-menubar-checkbox-item-space-pl pont-pr-menubar-checkbox-item-space-pr pont-py-menubar-checkbox-item-space-py","pont-text-menubar-checkbox-item-font","pont-rounded-menubar-checkbox-item-radius pont-outline-hidden","pont-cursor-default pont-select-none","aria-selected:pont-text-menubar-checkbox-item-color-text-active aria-selected:pont-bg-menubar-checkbox-item-color-bg-active","data-[disabled]:pont-opacity-menubar-checkbox-item-opacity-disabled data-[disabled]:pont-pointer-events-none"],indicator:["pont-flex pont-absolute pont-left-2","pont-justify-center pont-items-center","pont-size-menubar-checkbox-item-indicator-space-size","pont-pointer-events-none"],icon:["pont-shrink-0","pont-size-menubar-checkbox-item-icon-space-size","pont-pointer-events-none"]},radioItem:{base:["pont-flex pont-relative","pont-gap-menubar-radio-item-space-gap pont-items-center","pont-pl-menubar-radio-item-space-pl pont-pr-menubar-radio-item-space-pr pont-py-menubar-radio-item-space-py","pont-text-menubar-radio-item-font","pont-rounded-menubar-radio-item-radius pont-outline-hidden","pont-cursor-default pont-select-none","aria-selected:pont-text-menubar-radio-item-color-text-active aria-selected:pont-bg-menubar-radio-item-color-bg-active","data-[disabled]:pont-opacity-menubar-radio-item-opacity-disabled data-[disabled]:pont-pointer-events-none"],indicator:["pont-flex pont-absolute pont-left-2","pont-justify-center pont-items-center","pont-size-menubar-radio-item-indicator-space-size","pont-pointer-events-none"],icon:["pont-shrink-0","pont-size-menubar-radio-item-icon-space-size","pont-pointer-events-none","pont-fill-current"]},label:["pont-px-menubar-label-space-px pont-py-menubar-label-space-py","pont-text-menubar-label-font pont-font-menubar-label-font-weight"],separator:["pont-mx-menubar-separator-space-mx pont-my-menubar-separator-space-my","pont-h-menubar-separator-space-h","pont-bg-menubar-separator-color-bg"],shortcut:["pont-ml-auto","pont-text-menubar-shortcut-font pont-text-menubar-shortcut-color-text"]};var e_=Object.defineProperty,r_=Object.getOwnPropertyDescriptor,en=(e,t,r,o)=>{for(var n=o>1?void 0:o?r_(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&e_(t,r,n),n};let ae=class extends _{constructor(){super(...arguments),this._id="",this._hidden="",this.selected=!1,this.checked=!1,this.disabled=!1}get _containerElement(){return this.querySelector("div[part=menubar-checkbox-item]")}getAttributesToExclude(){return["date-testid"]}createRenderRoot(){return this}firstUpdated(e){this.moveLightDomChildrenInto(this._containerElement)}get identifier(){var t,r;if(this._id!=="")return this._id;const e=(r=(t=this.parentElement)==null?void 0:t.shadowRoot)==null?void 0:r.querySelector("div[rtgcmd-group]");return e?this._id=`${e.getAttribute("id")}li${ae._counter++}`:this._id=`rtgcmdrxgxli${ae._counter++}`,this._id}get value(){var e;return((e=this.textContent)==null?void 0:e.trim())||""}handleMouseEvent(e){(e.type==="mouseover"||e.type==="focus")&&(this.selected=!0),e.type==="mouseleave"&&(this.selected=!1)}toggleChecked(){this.checked=!this.checked}render(){return l`
|
|
1649
1649
|
<div
|
|
1650
1650
|
part="menubar-checkbox-item"
|
|
1651
1651
|
class=${m(St.checkboxItem.base,this.disabled&&"pont-opacity-menubar-item-opacity-disabled pont-pointer-events-none",this.className)}
|
|
@@ -1680,7 +1680,7 @@
|
|
|
1680
1680
|
`:h}
|
|
1681
1681
|
</span>
|
|
1682
1682
|
</div>
|
|
1683
|
-
`}};ae._counter=0;en([a({type:String})],ae.prototype,"_id",2);en([a({attribute:"aria-hidden",type:String})],ae.prototype,"_hidden",2);en([a({attribute:"data-value",type:String})],ae.prototype,"value",1);en([a({type:Boolean})],ae.prototype,"selected",2);en([a({type:Boolean})],ae.prototype,"checked",2);en([a({type:Boolean})],ae.prototype,"disabled",2);ae=en([p("pont-menubar-checkbox-item")],ae);var n_=Object.defineProperty,o_=Object.getOwnPropertyDescriptor,Gn=(e,t,r,o)=>{for(var n=o>1?void 0:o?o_(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&n_(t,r,n),n};let _r=class extends
|
|
1683
|
+
`}};ae._counter=0;en([a({type:String})],ae.prototype,"_id",2);en([a({attribute:"aria-hidden",type:String})],ae.prototype,"_hidden",2);en([a({attribute:"data-value",type:String})],ae.prototype,"value",1);en([a({type:Boolean})],ae.prototype,"selected",2);en([a({type:Boolean})],ae.prototype,"checked",2);en([a({type:Boolean})],ae.prototype,"disabled",2);ae=en([p("pont-menubar-checkbox-item")],ae);var n_=Object.defineProperty,o_=Object.getOwnPropertyDescriptor,Gn=(e,t,r,o)=>{for(var n=o>1?void 0:o?o_(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&n_(t,r,n),n};let _r=class extends _{constructor(){super(...arguments),this.isOpen=!1,this.uniqueIds=[],this.selectedMenu="",this.isHovering=!1,this.id="",this.closeTimeout=null,this.toggleMenubar=e=>{e.stopPropagation(),document.querySelectorAll("pont-menubar-menu").forEach(r=>{r!==this&&(r.isOpen=!1)}),this.isOpen=!this.isOpen},this.handleClickOutside=e=>{const t=e.target;this.contains(t)||(this.isOpen=!1)},this.handleMenuMouseEnter=()=>{this.clearCloseTimeout(),this.closeAllMenus(),this.isOpen=!0,this.isHovering=!0},this.handleMenuMouseLeave=e=>{const t=e.relatedTarget;if(this.isDescendant(t,"pont-menubar-content")){this.clearCloseTimeout();return}this.scheduleClose()}}get _content(){return this.querySelector("pont-menubar-content")}get _button(){return this.querySelector("pont-menubar-trigger")}getAttributesToExclude(){return["date-testid"]}createRenderRoot(){return this}connectedCallback(){super.connectedCallback(),document.addEventListener("click",this.handleClickOutside),this.addEventListener("radio-selected",this._handleRadioSelected)}disconnectedCallback(){document.removeEventListener("click",this.handleClickOutside),this.clearCloseTimeout(),super.disconnectedCallback()}clearCloseTimeout(){this.closeTimeout!==null&&(clearTimeout(this.closeTimeout),this.closeTimeout=null)}updated(e){super.updated(e);const t=this._content;t&&(t.dataset.state=this.isOpen?"open":"close")}_handleRadioSelected(e){this.querySelectorAll("pont-menubar-radio-item").forEach(t=>{const r=t;t!==e.target&&(r.checked=!1)})}firstUpdated(){this.setupContentListeners();const e=this.querySelector("div[part=menubar-menu-slot]"),t=this.querySelector("div[part=button-slot]");e&&this._content&&e.appendChild(this._content),t&&this._button&&t.appendChild(this._button)}raiseEvent(){const e=new CustomEvent("unique-ids-generated",{detail:{ids:this.uniqueIds},bubbles:!0,composed:!0});this.dispatchEvent(e)}closeAllMenus(){document.querySelectorAll("pont-menubar-menu").forEach(t=>{t.isOpen=!1,t.isHovering=!1})}scheduleClose(){this.clearCloseTimeout(),this.closeTimeout=window.setTimeout(()=>{this.isOpen=!1,this.isHovering=!1,this.closeTimeout=null},150)}isDescendant(e,t){let r=e.parentElement;for(;r;){if(r.tagName.toLowerCase()===t.toLowerCase())return!0;r=r.parentElement}return!1}setupContentListeners(){const e=this._content;e&&(e.addEventListener("mouseenter",()=>{this.clearCloseTimeout(),this.isOpen=!0}),e.addEventListener("mouseleave",()=>{this.scheduleClose()}))}render(){return l`
|
|
1684
1684
|
<div class=${m(St.menu,this.className)}>
|
|
1685
1685
|
<div
|
|
1686
1686
|
id="${this.id}"
|
|
@@ -1699,7 +1699,7 @@
|
|
|
1699
1699
|
|
|
1700
1700
|
<div part="menubar-menu-slot"></div>
|
|
1701
1701
|
</div>
|
|
1702
|
-
`}};Gn([g()],_r.prototype,"isOpen",2);Gn([g()],_r.prototype,"uniqueIds",2);Gn([g()],_r.prototype,"selectedMenu",2);Gn([g()],_r.prototype,"isHovering",2);Gn([a({type:String})],_r.prototype,"id",2);_r=Gn([p("pont-menubar-menu")],_r);var i_=Object.defineProperty,s_=Object.getOwnPropertyDescriptor,Lo=(e,t,r,o)=>{for(var n=o>1?void 0:o?s_(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&i_(t,r,n),n};let Dn=class extends
|
|
1702
|
+
`}};Gn([g()],_r.prototype,"isOpen",2);Gn([g()],_r.prototype,"uniqueIds",2);Gn([g()],_r.prototype,"selectedMenu",2);Gn([g()],_r.prototype,"isHovering",2);Gn([a({type:String})],_r.prototype,"id",2);_r=Gn([p("pont-menubar-menu")],_r);var i_=Object.defineProperty,s_=Object.getOwnPropertyDescriptor,Lo=(e,t,r,o)=>{for(var n=o>1?void 0:o?s_(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&i_(t,r,n),n};let Dn=class extends _{constructor(){super(...arguments),this.state=nl,this.id="",this.side="bottom",this.isOpen=!1}get _menubarMenu(){let e=this.parentElement;for(;e&&!(e instanceof _r);)e=e.parentElement;return e}get _containerElement(){return this.querySelector("div[part=menubar-content]")}getAttributesToExclude(){return["date-testid"]}createRenderRoot(){return this}firstUpdated(e){requestAnimationFrame(()=>{this.moveLightDomChildrenInto(this._containerElement)})}connectedCallback(){super.connectedCallback(),this.isOpen&&document.addEventListener("mousedown",this.handleClickOutside)}disconnectedCallback(){document.removeEventListener("mousedown",this.handleClickOutside),super.disconnectedCallback()}updated(e){super.updated(e),this.state==="open"?this.isOpen=!0:this.isOpen=!1,e.has("isOpen")&&(this.isOpen?document.addEventListener("mousedown",this.handleClickOutside):document.removeEventListener("mousedown",this.handleClickOutside))}handleClickOutside(e){const t=this.querySelector("button");this&&!this.contains(e.target)&&!(t!=null&&t.contains(e.target))&&(this.isOpen=!1)}render(){return l`
|
|
1703
1703
|
<div
|
|
1704
1704
|
class=${m(St.content,this.className)}
|
|
1705
1705
|
id="${this.id}"
|
|
@@ -1713,7 +1713,7 @@
|
|
|
1713
1713
|
dir="ltr"
|
|
1714
1714
|
style="display: ${this.isOpen?"block":"none"};"
|
|
1715
1715
|
></div>
|
|
1716
|
-
`}};Lo([a({attribute:"data-state",type:String})],Dn.prototype,"state",2);Lo([a({type:String})],Dn.prototype,"id",2);Lo([a({type:String})],Dn.prototype,"side",2);Lo([g()],Dn.prototype,"isOpen",2);Dn=Lo([p("pont-menubar-content")],Dn);var a_=Object.defineProperty,l_=Object.getOwnPropertyDescriptor,Bi=(e,t,r,o)=>{for(var n=o>1?void 0:o?l_(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&a_(t,r,n),n};let wr=class extends
|
|
1716
|
+
`}};Lo([a({attribute:"data-state",type:String})],Dn.prototype,"state",2);Lo([a({type:String})],Dn.prototype,"id",2);Lo([a({type:String})],Dn.prototype,"side",2);Lo([g()],Dn.prototype,"isOpen",2);Dn=Lo([p("pont-menubar-content")],Dn);var a_=Object.defineProperty,l_=Object.getOwnPropertyDescriptor,Bi=(e,t,r,o)=>{for(var n=o>1?void 0:o?l_(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&a_(t,r,n),n};let wr=class extends _{constructor(){super(...arguments),this.heading="",this._id="",this._hidden=""}get _containerElement(){return this.querySelector("div[part=menubar-group-slot]")}getAttributesToExclude(){return["date-testid"]}createRenderRoot(){return this}firstUpdated(e){this.moveLightDomChildrenInto(this._containerElement)}get identifier(){var t,r;if(this._id!=="")return this._id;const e=(r=(t=this.parentElement)==null?void 0:t.shadowRoot)==null?void 0:r.querySelector("div[rtgcmd-list]");return e?this._id=`${e.getAttribute("id")}g${wr._counter++}`:this._id=`rtgcmdrxlxg${wr._counter++}`,this._id}render(){return l`${this._hidden==="true"?h:l`
|
|
1717
1717
|
<div
|
|
1718
1718
|
class=${m(St.group,this.className)}
|
|
1719
1719
|
id="${this.identifier}"
|
|
@@ -1734,7 +1734,7 @@
|
|
|
1734
1734
|
aria-labelledby="${this.identifier}h"
|
|
1735
1735
|
></div>
|
|
1736
1736
|
</div>
|
|
1737
|
-
`}`}};wr._counter=0;Bi([a({type:String})],wr.prototype,"heading",2);Bi([a({attribute:"id",type:String})],wr.prototype,"_id",2);Bi([a({attribute:"aria-hidden",type:String})],wr.prototype,"_hidden",2);wr=Bi([p("pont-menubar-group")],wr);var d_=Object.defineProperty,c_=Object.getOwnPropertyDescriptor,Kn=(e,t,r,o)=>{for(var n=o>1?void 0:o?c_(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&d_(t,r,n),n};let Le=class extends
|
|
1737
|
+
`}`}};wr._counter=0;Bi([a({type:String})],wr.prototype,"heading",2);Bi([a({attribute:"id",type:String})],wr.prototype,"_id",2);Bi([a({attribute:"aria-hidden",type:String})],wr.prototype,"_hidden",2);wr=Bi([p("pont-menubar-group")],wr);var d_=Object.defineProperty,c_=Object.getOwnPropertyDescriptor,Kn=(e,t,r,o)=>{for(var n=o>1?void 0:o?c_(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&d_(t,r,n),n};let Le=class extends _{constructor(){super(...arguments),this._id="",this._hidden="",this.disabled=!1,this.selected=!1}get _containerElement(){return this.querySelector("div[part=menubar-item]")}getAttributesToExclude(){return["date-testid"]}createRenderRoot(){return this}firstUpdated(e){this.moveLightDomChildrenInto(this._containerElement)}get identifier(){var t,r;if(this._id!=="")return this._id;const e=(r=(t=this.parentElement)==null?void 0:t.shadowRoot)==null?void 0:r.querySelector("div[rtgcmd-group]");return e?this._id=`${e.getAttribute("id")}li${Le._counter++}`:this._id=`rtgcmdrxgxli${Le._counter++}`,this._id}get value(){var e;return((e=this.textContent)==null?void 0:e.trim())||""}handleMouseEvent(e){(e.type==="mouseover"||e.type==="focus")&&(this.selected=!0),e.type==="mouseleave"&&(this.selected=!1)}render(){return l` ${this._hidden==="true"?h:l`
|
|
1738
1738
|
<div
|
|
1739
1739
|
part="menubar-item"
|
|
1740
1740
|
class=${m(St.item,this.disabled&&"pont-opacity-menubar-item-opacity-disabled pont-pointer-events-none",this.className)}
|
|
@@ -1748,7 +1748,7 @@
|
|
|
1748
1748
|
id="${this.identifier}"
|
|
1749
1749
|
aria-hidden="${this.hidden}"
|
|
1750
1750
|
></div>
|
|
1751
|
-
`}`}};Le._counter=0;Kn([a({type:String})],Le.prototype,"_id",2);Kn([a({attribute:"aria-hidden",type:String})],Le.prototype,"_hidden",2);Kn([a({type:Boolean})],Le.prototype,"disabled",2);Kn([a({attribute:"data-value",type:String})],Le.prototype,"value",1);Kn([a({type:Boolean})],Le.prototype,"selected",2);Le=Kn([p("pont-menubar-item")],Le);var p_=Object.defineProperty,h_=Object.getOwnPropertyDescriptor,rn=(e,t,r,o)=>{for(var n=o>1?void 0:o?h_(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&p_(t,r,n),n};let le=class extends
|
|
1751
|
+
`}`}};Le._counter=0;Kn([a({type:String})],Le.prototype,"_id",2);Kn([a({attribute:"aria-hidden",type:String})],Le.prototype,"_hidden",2);Kn([a({type:Boolean})],Le.prototype,"disabled",2);Kn([a({attribute:"data-value",type:String})],Le.prototype,"value",1);Kn([a({type:Boolean})],Le.prototype,"selected",2);Le=Kn([p("pont-menubar-item")],Le);var p_=Object.defineProperty,h_=Object.getOwnPropertyDescriptor,rn=(e,t,r,o)=>{for(var n=o>1?void 0:o?h_(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&p_(t,r,n),n};let le=class extends _{constructor(){super(...arguments),this._id="",this._hidden="",this.selected=!1,this.checked=!1,this.disabled=!1}get _containerElement(){return this.querySelector("div[part=menubar-radio-item]")}getAttributesToExclude(){return["date-testid"]}createRenderRoot(){return this}firstUpdated(e){this.moveLightDomChildrenInto(this._containerElement)}get identifier(){var t,r;if(this._id!=="")return this._id;const e=(r=(t=this.parentElement)==null?void 0:t.shadowRoot)==null?void 0:r.querySelector("div[rtgcmd-group]");return e?this._id=`${e.getAttribute("id")}li${le._counter++}`:this._id=`rtgcmdrxgxli${le._counter++}`,this._id}get value(){var e;return((e=this.textContent)==null?void 0:e.trim())||""}handleMouseEvent(e){(e.type==="mouseover"||e.type==="focus")&&(this.selected=!0),e.type==="mouseleave"&&(this.selected=!1)}toggleChecked(){this.checked||(this.checked=!0,this.dispatchEvent(new CustomEvent("radio-selected",{bubbles:!0,composed:!0})))}render(){return l`
|
|
1752
1752
|
<div
|
|
1753
1753
|
part="menubar-radio-item"
|
|
1754
1754
|
class=${m(St.radioItem.base,this.disabled&&"pont-opacity-menubar-item-opacity-disabled pont-pointer-events-none",this.className)}
|
|
@@ -1781,7 +1781,7 @@
|
|
|
1781
1781
|
</svg>`:h}
|
|
1782
1782
|
</span>
|
|
1783
1783
|
</div>
|
|
1784
|
-
`}};le._counter=0;rn([a({type:String})],le.prototype,"_id",2);rn([a({attribute:"aria-hidden",type:String})],le.prototype,"_hidden",2);rn([a({attribute:"data-value",type:String})],le.prototype,"value",1);rn([a({type:Boolean})],le.prototype,"selected",2);rn([a({type:Boolean})],le.prototype,"checked",2);rn([a({type:Boolean})],le.prototype,"disabled",2);le=rn([p("pont-menubar-radio-item")],le);var u_=Object.defineProperty,m_=Object.getOwnPropertyDescriptor,hl=(e,t,r,o)=>{for(var n=o>1?void 0:o?m_(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&u_(t,r,n),n};let Wr=class extends
|
|
1784
|
+
`}};le._counter=0;rn([a({type:String})],le.prototype,"_id",2);rn([a({attribute:"aria-hidden",type:String})],le.prototype,"_hidden",2);rn([a({attribute:"data-value",type:String})],le.prototype,"value",1);rn([a({type:Boolean})],le.prototype,"selected",2);rn([a({type:Boolean})],le.prototype,"checked",2);rn([a({type:Boolean})],le.prototype,"disabled",2);le=rn([p("pont-menubar-radio-item")],le);var u_=Object.defineProperty,m_=Object.getOwnPropertyDescriptor,hl=(e,t,r,o)=>{for(var n=o>1?void 0:o?m_(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&u_(t,r,n),n};let Wr=class extends _{constructor(){super(...arguments),this._id="",this._hidden=""}get _containerElement(){return this.querySelector("div[part=menubar-separator]")}getAttributesToExclude(){return["date-testid"]}createRenderRoot(){return this}get identifier(){var t;if(this._id!=="")return this._id;const e=(t=this.parentElement)==null?void 0:t.querySelector("div[rtgcmd-list]");return e?this._id=`${e.getAttribute("id")}s${Wr._counter++}`:this._id=`rtgcmdrxlxs${Wr._counter++}`,this._id}firstUpdated(e){this.moveLightDomChildrenInto(this._containerElement)}render(){return l`${this._hidden==="true"?h:l`
|
|
1785
1785
|
<div
|
|
1786
1786
|
class=${m(St.separator,this.className)}
|
|
1787
1787
|
id="${this.identifier}"
|
|
@@ -1789,20 +1789,20 @@
|
|
|
1789
1789
|
part="menubar-separator"
|
|
1790
1790
|
rtgcmd-separator
|
|
1791
1791
|
></div>
|
|
1792
|
-
`}`}};Wr._counter=0;hl([a({type:String})],Wr.prototype,"_id",2);hl([a({attribute:"aria-hidden",type:String})],Wr.prototype,"_hidden",2);Wr=hl([p("pont-menubar-separator")],Wr);var g_=Object.getOwnPropertyDescriptor,f_=(e,t,r,o)=>{for(var n=o>1?void 0:o?g_(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let oc=class extends
|
|
1792
|
+
`}`}};Wr._counter=0;hl([a({type:String})],Wr.prototype,"_id",2);hl([a({attribute:"aria-hidden",type:String})],Wr.prototype,"_hidden",2);Wr=hl([p("pont-menubar-separator")],Wr);var g_=Object.getOwnPropertyDescriptor,f_=(e,t,r,o)=>{for(var n=o>1?void 0:o?g_(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let oc=class extends _{get _containerElement(){return this.querySelector("span[part=menubar-shortcut]")}getAttributesToExclude(){return["date-testid"]}createRenderRoot(){return this.classList=m(St.shortcut),this}firstUpdated(e){this.moveLightDomChildrenInto(this._containerElement)}render(){return l`
|
|
1793
1793
|
<span
|
|
1794
1794
|
class=${m(St.shortcut,this.className)}
|
|
1795
1795
|
part="menubar-shortcut"
|
|
1796
1796
|
>
|
|
1797
1797
|
</span>
|
|
1798
|
-
`}};oc=f_([p("pont-menubar-shortcut")],oc);var v_=Object.getOwnPropertyDescriptor,b_=(e,t,r,o)=>{for(var n=o>1?void 0:o?v_(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let ic=class extends
|
|
1798
|
+
`}};oc=f_([p("pont-menubar-shortcut")],oc);var v_=Object.getOwnPropertyDescriptor,b_=(e,t,r,o)=>{for(var n=o>1?void 0:o?v_(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let ic=class extends _{get _containerElement(){return this.querySelector("button[part=menubar-trigger]")}createRenderRoot(){return this}firstUpdated(e){this.moveLightDomChildrenInto(this._containerElement)}getAttributesToExclude(){return["data-testid"]}render(){return l`
|
|
1799
1799
|
<button
|
|
1800
1800
|
class=${m(St.trigger,this.className)}
|
|
1801
1801
|
type="button"
|
|
1802
1802
|
role="menuitem"
|
|
1803
1803
|
part="menubar-trigger"
|
|
1804
1804
|
></button>
|
|
1805
|
-
`}};ic=b_([p("pont-menubar-trigger")],ic);var y_=Object.getOwnPropertyDescriptor,__=(e,t,r,o)=>{for(var n=o>1?void 0:o?y_(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let sc=class extends
|
|
1805
|
+
`}};ic=b_([p("pont-menubar-trigger")],ic);var y_=Object.getOwnPropertyDescriptor,__=(e,t,r,o)=>{for(var n=o>1?void 0:o?y_(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let sc=class extends _{get _containerElement(){return this.querySelector("div[part=menubar]")}getAttributesToExclude(){return["date-testid"]}createRenderRoot(){return this}firstUpdated(e){this.moveLightDomChildrenInto(this._containerElement)}render(){return l`
|
|
1806
1806
|
<div
|
|
1807
1807
|
role="menubar"
|
|
1808
1808
|
part="menubar"
|
|
@@ -1810,7 +1810,7 @@
|
|
|
1810
1810
|
tabindex="0"
|
|
1811
1811
|
data-orientation="horizontal"
|
|
1812
1812
|
></div>
|
|
1813
|
-
`}};sc=__([p("pont-menubar")],sc);const Yr={content:["pont-absolute","pont-top-navigation-menu-content-space-top","pont-flex","pont-justify-center"],menu:["pont-relative","pont-z-10","pont-flex","pont-max-w-navigation-menu-space-max-w","pont-flex-1","pont-items-center","pont-justify-center"],menuList:["pont-flex","pont-flex-1","pont-list-none","pont-items-center","pont-justify-center","pont-space-x-navigation-menu-list-space-x","group"],menuItem:["pont-flex","pont-cursor-pointer","pont-items-center","pont-rounded-navigation-menu-item-radius","pont-bg-navigation-menu-item-color-bg","pont-py-navigation-menu-list-space-py","pont-px-navigation-menu-list-space-px","hover:pont-bg-navigation-menu-item-color-bg-hover"],menuItemIcon:["lucide","lucide-chevron-down","pont-relative","pont-ml-navigation-menu-item-icon-space-ml","pont-h-navigation-menu-item-icon-space-h","pont-w-navigation-menu-item-icon-space-w","pont-transition-transform","pont-duration-navigation-menu-item-icon-motion-duration"],link:["pont-flex","pont-h-navigation-menu-link-space-h","pont-bg-navigation-menu-link-color-bg","hover:pont-bg-navigation-menu-link-color-bg-hover","pont-rounded-navigation-menu-link-radius","pont-px-navigation-menu-link-space-px","pont-py-navigation-menu-link-space-py","pont-w-navigation-menu-link-space-w","pont-select-none","pont-flex-col","pont-justify-end","pont-no-underline","pont-outline-none"],contentContainer:["pont-bg-navigation-menu-content-container-color-bg","origin-top-center","pont-relative","pont-mt-navigation-menu-content-container-space-mt","pont-w-navigation-menu-content-container-space-w","pont-overflow-hidden","pont-rounded-navigation-menu-content-container-radius","pont-border-navigation-menu-content-container-width-border","pont-border-navigation-menu-content-container-color-border","pont-navigation-menu-content-container-shadow"]};var w_=Object.getOwnPropertyDescriptor,$_=(e,t,r,o)=>{for(var n=o>1?void 0:o?w_(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let ac=class extends
|
|
1813
|
+
`}};sc=__([p("pont-menubar")],sc);const Yr={content:["pont-absolute","pont-top-navigation-menu-content-space-top","pont-flex","pont-justify-center"],menu:["pont-relative","pont-z-10","pont-flex","pont-max-w-navigation-menu-space-max-w","pont-flex-1","pont-items-center","pont-justify-center"],menuList:["pont-flex","pont-flex-1","pont-list-none","pont-items-center","pont-justify-center","pont-space-x-navigation-menu-list-space-x","group"],menuItem:["pont-flex","pont-cursor-pointer","pont-items-center","pont-rounded-navigation-menu-item-radius","pont-bg-navigation-menu-item-color-bg","pont-py-navigation-menu-list-space-py","pont-px-navigation-menu-list-space-px","hover:pont-bg-navigation-menu-item-color-bg-hover"],menuItemIcon:["lucide","lucide-chevron-down","pont-relative","pont-ml-navigation-menu-item-icon-space-ml","pont-h-navigation-menu-item-icon-space-h","pont-w-navigation-menu-item-icon-space-w","pont-transition-transform","pont-duration-navigation-menu-item-icon-motion-duration"],link:["pont-flex","pont-h-navigation-menu-link-space-h","pont-bg-navigation-menu-link-color-bg","hover:pont-bg-navigation-menu-link-color-bg-hover","pont-rounded-navigation-menu-link-radius","pont-px-navigation-menu-link-space-px","pont-py-navigation-menu-link-space-py","pont-w-navigation-menu-link-space-w","pont-select-none","pont-flex-col","pont-justify-end","pont-no-underline","pont-outline-none"],contentContainer:["pont-bg-navigation-menu-content-container-color-bg","origin-top-center","pont-relative","pont-mt-navigation-menu-content-container-space-mt","pont-w-navigation-menu-content-container-space-w","pont-overflow-hidden","pont-rounded-navigation-menu-content-container-radius","pont-border-navigation-menu-content-container-width-border","pont-border-navigation-menu-content-container-color-border","pont-navigation-menu-content-container-shadow"]};var w_=Object.getOwnPropertyDescriptor,$_=(e,t,r,o)=>{for(var n=o>1?void 0:o?w_(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let ac=class extends _{get _containerElement(){return this.querySelector("ul[part=navigation-menu-list]")}createRenderRoot(){return this}firstUpdated(e){this.moveLightDomChildrenInto(this._containerElement)}render(){return l`
|
|
1814
1814
|
<div class="${m("relative",this.className)}">
|
|
1815
1815
|
<ul
|
|
1816
1816
|
part="navigation-menu-list"
|
|
@@ -1820,7 +1820,7 @@
|
|
|
1820
1820
|
></ul>
|
|
1821
1821
|
<div></div>
|
|
1822
1822
|
</div>
|
|
1823
|
-
`}};ac=$_([p("pont-navigation-menu-list")],ac);var P_=Object.defineProperty,C_=Object.getOwnPropertyDescriptor,Wn=(e,t,r,o)=>{for(var n=o>1?void 0:o?C_(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&P_(t,r,n),n};let $r=class extends
|
|
1823
|
+
`}};ac=$_([p("pont-navigation-menu-list")],ac);var P_=Object.defineProperty,C_=Object.getOwnPropertyDescriptor,Wn=(e,t,r,o)=>{for(var n=o>1?void 0:o?C_(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&P_(t,r,n),n};let $r=class extends _{constructor(){super(...arguments),this.value="",this.navigationLink=!0,this.isOpen=!1,this.uniqueIds=[],this.isHovering=!1,this.handleClickOutside=e=>{const t=e.target;this.contains(t)||(this.isOpen=!1)}}raiseEvent(){const e=new CustomEvent("unique-ids-generated",{detail:{ids:this.uniqueIds},bubbles:!0,composed:!0});this.dispatchEvent(e)}firstUpdated(){this.moveLightDomChildrenInto(this.querySelector("div[part=content-slot]"),[this._content]),this.moveLightDomChildrenInto(this.querySelector("div[part=button-slot]"),[this._button])}closeAllMenus(){document.querySelectorAll("pont-navigation-menu-item").forEach(t=>{t.isOpen=!1,t.isHovering=!1})}toggleMenubar(e){e.stopPropagation(),document.querySelectorAll("pont-navigation-menu-item").forEach(r=>{r!==this&&(r.isOpen=!1)}),this.isOpen=!this.isOpen}get _content(){return this.querySelector("pont-navigation-menu-content")}get _button(){return this.querySelector("pont-navigation-menu-trigger")}updated(e){super.updated(e);const t=this._content;t&&(t.dataset.state=this.isOpen?"open":"close")}connectedCallback(){super.connectedCallback(),document.addEventListener("click",this.handleClickOutside)}disconnectedCallback(){document.removeEventListener("click",this.handleClickOutside),super.disconnectedCallback()}handleHover(){this.closeAllMenus(),this.isHovering||(this.isHovering=!0,this.isOpen=!0)}handleMouseLeave(){this.isHovering=!1,this.isOpen=!1}createRenderRoot(){return this}render(){return l`
|
|
1824
1824
|
<li
|
|
1825
1825
|
@mouseenter="${this.handleHover}"
|
|
1826
1826
|
@mouseleave="${this.handleMouseLeave}"
|
|
@@ -1850,7 +1850,7 @@
|
|
|
1850
1850
|
</div>
|
|
1851
1851
|
<div part="content-slot" style="position:absolute"></div>`:""}
|
|
1852
1852
|
</li>
|
|
1853
|
-
`}};Wn([a({type:String})],$r.prototype,"value",2);Wn([a({type:Boolean})],$r.prototype,"navigationLink",2);Wn([g()],$r.prototype,"isOpen",2);Wn([g()],$r.prototype,"uniqueIds",2);Wn([g()],$r.prototype,"isHovering",2);$r=Wn([p("pont-navigation-menu-item")],$r);var E_=Object.defineProperty,S_=Object.getOwnPropertyDescriptor,Fo=(e,t,r,o)=>{for(var n=o>1?void 0:o?S_(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&E_(t,r,n),n};let Ln=class extends
|
|
1853
|
+
`}};Wn([a({type:String})],$r.prototype,"value",2);Wn([a({type:Boolean})],$r.prototype,"navigationLink",2);Wn([g()],$r.prototype,"isOpen",2);Wn([g()],$r.prototype,"uniqueIds",2);Wn([g()],$r.prototype,"isHovering",2);$r=Wn([p("pont-navigation-menu-item")],$r);var E_=Object.defineProperty,S_=Object.getOwnPropertyDescriptor,Fo=(e,t,r,o)=>{for(var n=o>1?void 0:o?S_(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&E_(t,r,n),n};let Ln=class extends _{constructor(){super(...arguments),this.state="close",this.id="",this.side="bottom",this.isOpen=!0}get _menubarMenu(){let e=this.parentElement;for(;e&&!(e instanceof $r);)e=e.parentElement;return e}get _containerElement(){return this.querySelector("div[part=navigation-menu-content-container]")}getAttributesToExclude(){return["data-testid"]}connectedCallback(){super.connectedCallback(),this.isOpen&&document.addEventListener("mousedown",this.handleClickOutside)}disconnectedCallback(){document.removeEventListener("mousedown",this.handleClickOutside),super.disconnectedCallback()}updated(e){super.updated(e),this.state==="open"?this.isOpen=!0:this.isOpen=!1,e.has("isOpen")&&(this.isOpen?document.addEventListener("mousedown",this.handleClickOutside):document.removeEventListener("mousedown",this.handleClickOutside))}handleClickOutside(e){const t=this.querySelector("button");this&&!this.contains(e.target)&&!(t!=null&&t.contains(e.target))&&(this.isOpen=!1)}createRenderRoot(){return this}firstUpdated(e){requestAnimationFrame(()=>{this.moveLightDomChildrenInto(this._containerElement)})}render(){return l`
|
|
1854
1854
|
<div
|
|
1855
1855
|
class="${m(Yr.content,this.className)}"
|
|
1856
1856
|
style="display: ${this.isOpen?"block":"none"};top:0px;left:0px;"
|
|
@@ -1870,7 +1870,7 @@
|
|
|
1870
1870
|
></div>
|
|
1871
1871
|
</div>
|
|
1872
1872
|
</div>
|
|
1873
|
-
`}};Fo([a({attribute:"data-state",type:String})],Ln.prototype,"state",2);Fo([a({type:String})],Ln.prototype,"id",2);Fo([a({type:String})],Ln.prototype,"side",2);Fo([g()],Ln.prototype,"isOpen",2);Ln=Fo([p("pont-navigation-menu-content")],Ln);var x_=Object.defineProperty,O_=Object.getOwnPropertyDescriptor,fh=(e,t,r,o)=>{for(var n=o>1?void 0:o?O_(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&x_(t,r,n),n};let ya=class extends
|
|
1873
|
+
`}};Fo([a({attribute:"data-state",type:String})],Ln.prototype,"state",2);Fo([a({type:String})],Ln.prototype,"id",2);Fo([a({type:String})],Ln.prototype,"side",2);Fo([g()],Ln.prototype,"isOpen",2);Ln=Fo([p("pont-navigation-menu-content")],Ln);var x_=Object.defineProperty,O_=Object.getOwnPropertyDescriptor,fh=(e,t,r,o)=>{for(var n=o>1?void 0:o?O_(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&x_(t,r,n),n};let ya=class extends _{constructor(){super(...arguments),this.href="/"}get _containerElement(){return this.querySelector("a[part=navigation-menu-link]")}createRenderRoot(){return this}firstUpdated(e){this.moveLightDomChildrenInto(this._containerElement)}render(){return l`
|
|
1874
1874
|
<a
|
|
1875
1875
|
part="navigation-menu-link"
|
|
1876
1876
|
class="${m(Yr.link,this.className)}"
|
|
@@ -1880,9 +1880,9 @@
|
|
|
1880
1880
|
tabindex="-1"
|
|
1881
1881
|
>
|
|
1882
1882
|
</a>
|
|
1883
|
-
`}};fh([a({type:String})],ya.prototype,"href",2);ya=fh([p("pont-navigation-menu-link")],ya);var R_=Object.getOwnPropertyDescriptor,I_=(e,t,r,o)=>{for(var n=o>1?void 0:o?R_(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let lc=class extends
|
|
1883
|
+
`}};fh([a({type:String})],ya.prototype,"href",2);ya=fh([p("pont-navigation-menu-link")],ya);var R_=Object.getOwnPropertyDescriptor,I_=(e,t,r,o)=>{for(var n=o>1?void 0:o?R_(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let lc=class extends _{get _containerElement(){return this.querySelector("div[part=navigation-menu-trigger]")}createRenderRoot(){return this}firstUpdated(e){this.moveLightDomChildrenInto(this._containerElement)}getAttributesToExclude(){return["data-testid"]}render(){return l`
|
|
1884
1884
|
<div part="navigation-menu-trigger" class="${m(this.className)}"></div>
|
|
1885
|
-
`}};lc=I_([p("pont-navigation-menu-trigger")],lc);var A_=Object.getOwnPropertyDescriptor,T_=(e,t,r,o)=>{for(var n=o>1?void 0:o?A_(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let dc=class extends
|
|
1885
|
+
`}};lc=I_([p("pont-navigation-menu-trigger")],lc);var A_=Object.getOwnPropertyDescriptor,T_=(e,t,r,o)=>{for(var n=o>1?void 0:o?A_(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let dc=class extends _{get _containerElement(){return this.querySelector("nav[part=navigation-menu]")}createRenderRoot(){return this}firstUpdated(e){}render(){return l`
|
|
1886
1886
|
<nav
|
|
1887
1887
|
part="navigation-menu"
|
|
1888
1888
|
aria-label="Main"
|
|
@@ -1890,13 +1890,13 @@
|
|
|
1890
1890
|
dir="ltr"
|
|
1891
1891
|
class="${m(Yr.menu,this.className)}"
|
|
1892
1892
|
></nav>
|
|
1893
|
-
`}};dc=T_([p("pont-navigation-menu")],dc);const Oe={root:["pont-flex","pont-justify-center","pont-mx-auto","pont-w-full"],content:["pont-flex","pont-flex-row pont-gap-pagination-content-space-gap pont-items-center"],item:[""],previous:{base:["pont-gap-pagination-previous-space-gap","pont-px-pagination-previous-space-px sm:pont-pl-pagination-previous-space-px"],span:["pont-hidden sm:pont-block"]},next:{base:["pont-gap-pagination-next-space-gap","pont-px-pagination-next-space-px sm:pont-pr-pagination-next-space-px"],span:["pont-hidden sm:pont-block"]},ellipsis:{base:["pont-flex pont-justify-center pont-items-center","pont-size-pagination-ellipsis-space-size"],icon:["pont-size-pagination-ellipsis-icon-space-size"],span:["pont-sr-only"]}};var D_=Object.getOwnPropertyDescriptor,L_=(e,t,r,o)=>{for(var n=o>1?void 0:o?D_(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let cc=class extends
|
|
1893
|
+
`}};dc=T_([p("pont-navigation-menu")],dc);const Oe={root:["pont-flex","pont-justify-center","pont-mx-auto","pont-w-full"],content:["pont-flex","pont-flex-row pont-gap-pagination-content-space-gap pont-items-center"],item:[""],previous:{base:["pont-gap-pagination-previous-space-gap","pont-px-pagination-previous-space-px sm:pont-pl-pagination-previous-space-px"],span:["pont-hidden sm:pont-block"]},next:{base:["pont-gap-pagination-next-space-gap","pont-px-pagination-next-space-px sm:pont-pr-pagination-next-space-px"],span:["pont-hidden sm:pont-block"]},ellipsis:{base:["pont-flex pont-justify-center pont-items-center","pont-size-pagination-ellipsis-space-size"],icon:["pont-size-pagination-ellipsis-icon-space-size"],span:["pont-sr-only"]}};var D_=Object.getOwnPropertyDescriptor,L_=(e,t,r,o)=>{for(var n=o>1?void 0:o?D_(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let cc=class extends _{get _containerElement(){return this.querySelector("ul[part=pagination-content]")}createRenderRoot(){return this}firstUpdated(e){this.moveLightDomChildrenInto(this._containerElement)}render(){return l`
|
|
1894
1894
|
<ul
|
|
1895
1895
|
data-slot="pagination-content"
|
|
1896
1896
|
part="pagination-content"
|
|
1897
1897
|
class=${m(Oe.content,this.className)}
|
|
1898
1898
|
></ul>
|
|
1899
|
-
`}};cc=L_([p("pont-pagination-content")],cc);var F_=Object.getOwnPropertyDescriptor,k_=(e,t,r,o)=>{for(var n=o>1?void 0:o?F_(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let pc=class extends
|
|
1899
|
+
`}};cc=L_([p("pont-pagination-content")],cc);var F_=Object.getOwnPropertyDescriptor,k_=(e,t,r,o)=>{for(var n=o>1?void 0:o?F_(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let pc=class extends _{get _containerElement(){return this.querySelector("span[part=pagination-ellipsis]")}createRenderRoot(){return this}firstUpdated(e){this.moveLightDomChildrenInto(this._containerElement)}render(){return l`
|
|
1900
1900
|
<span
|
|
1901
1901
|
aria-hidden
|
|
1902
1902
|
data-slot="pagination-ellipsis"
|
|
@@ -1922,7 +1922,7 @@
|
|
|
1922
1922
|
|
|
1923
1923
|
<span class=${m(Oe.ellipsis.span)}>More pages</span>
|
|
1924
1924
|
</span>
|
|
1925
|
-
`}};pc=k_([p("pont-pagination-ellipsis")],pc);var N_=Object.defineProperty,M_=Object.getOwnPropertyDescriptor,ko=(e,t,r,o)=>{for(var n=o>1?void 0:o?M_(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&N_(t,r,n),n};let Qr=class extends
|
|
1925
|
+
`}};pc=k_([p("pont-pagination-ellipsis")],pc);var N_=Object.defineProperty,M_=Object.getOwnPropertyDescriptor,ko=(e,t,r,o)=>{for(var n=o>1?void 0:o?M_(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&N_(t,r,n),n};let Qr=class extends _{constructor(){super(...arguments),this.state="close",this.isActive=!1,this.size="icon",this.href="javascript:void(0)"}get _containerElement(){return this.querySelector("[data-pont-pagination-link]")}createRenderRoot(){return this}firstUpdated(e){this.moveLightDomChildrenInto(this._containerElement)}updated(e){super.updated(e),this.state==="open"?this.isActive=!0:this.isActive=!1}render(){return l`
|
|
1926
1926
|
<pont-button
|
|
1927
1927
|
data-pont-pagination-link
|
|
1928
1928
|
id="${this.id}"
|
|
@@ -1934,14 +1934,14 @@
|
|
|
1934
1934
|
size=${this.size??h}
|
|
1935
1935
|
href="${this.href}"
|
|
1936
1936
|
></pont-button>
|
|
1937
|
-
`}};ko([a({attribute:"data-state",type:String})],Qr.prototype,"state",2);ko([a({type:Boolean})],Qr.prototype,"isActive",2);ko([a({type:String})],Qr.prototype,"size",2);ko([a({type:String})],Qr.prototype,"href",2);Qr=ko([p("pont-pagination-link")],Qr);var B_=Object.defineProperty,U_=Object.getOwnPropertyDescriptor,ul=(e,t,r,o)=>{for(var n=o>1?void 0:o?U_(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&B_(t,r,n),n};let Pi=class extends
|
|
1937
|
+
`}};ko([a({attribute:"data-state",type:String})],Qr.prototype,"state",2);ko([a({type:Boolean})],Qr.prototype,"isActive",2);ko([a({type:String})],Qr.prototype,"size",2);ko([a({type:String})],Qr.prototype,"href",2);Qr=ko([p("pont-pagination-link")],Qr);var B_=Object.defineProperty,U_=Object.getOwnPropertyDescriptor,ul=(e,t,r,o)=>{for(var n=o>1?void 0:o?U_(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&B_(t,r,n),n};let Pi=class extends _{constructor(){super(...arguments),this.uniqueIds=[],this.isActive=!1}get _containerElement(){return this.querySelector("li[part=pagination-item]")}get _content(){var t;const e=(t=this._containerElement)==null?void 0:t.children;if(e){for(let r=0;r<e.length;r++)if(e[r]instanceof Qr)return e[r]}return null}updated(e){super.updated(e);const t=this._content;t&&(t.dataset.state=this.isActive?"open":"close")}handleClick(e){e.stopPropagation(),document.querySelectorAll("pont-pagination-item").forEach(r=>{r!==this&&(r.isActive=!1)}),this.isActive=!this.isActive}firstUpdated(){var r;this.moveLightDomChildrenInto(this._containerElement);const e=(r=this._containerElement)==null?void 0:r.children,t=[];for(let o=0;o<e.length-1;o+=1){const n=e[o],i=crypto.randomUUID();t.push(i),n.dataset.pairId=i}this.uniqueIds=t,this._content&&this._content.removeEventListener("unique-ids-generated",()=>{this.requestUpdate()})}raiseEvent(){const e=new CustomEvent("unique-ids-generated",{detail:{ids:this.uniqueIds},bubbles:!0,composed:!0});this.dispatchEvent(e)}createRenderRoot(){return this}render(){return l`
|
|
1938
1938
|
<li
|
|
1939
1939
|
data-slot="pagination-item"
|
|
1940
1940
|
part="pagination-item"
|
|
1941
1941
|
class=${m(Oe.item,this.className)}
|
|
1942
1942
|
@click="${this.handleClick}"
|
|
1943
1943
|
></li>
|
|
1944
|
-
`}};ul([g()],Pi.prototype,"uniqueIds",2);ul([a({type:Boolean})],Pi.prototype,"isActive",2);Pi=ul([p("pont-pagination-item")],Pi);var q_=Object.defineProperty,j_=Object.getOwnPropertyDescriptor,vh=(e,t,r,o)=>{for(var n=o>1?void 0:o?j_(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&q_(t,r,n),n};let _a=class extends
|
|
1944
|
+
`}};ul([g()],Pi.prototype,"uniqueIds",2);ul([a({type:Boolean})],Pi.prototype,"isActive",2);Pi=ul([p("pont-pagination-item")],Pi);var q_=Object.defineProperty,j_=Object.getOwnPropertyDescriptor,vh=(e,t,r,o)=>{for(var n=o>1?void 0:o?j_(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&q_(t,r,n),n};let _a=class extends _{constructor(){super(...arguments),this.href="javascript:void(0)"}get _containerElement(){return this.querySelector("div[part=pagination-next]")}createRenderRoot(){return this}firstUpdated(e){this.moveLightDomChildrenInto(this._containerElement)}render(){return l`
|
|
1945
1945
|
<pont-pagination-link
|
|
1946
1946
|
aria-label="Go to next page"
|
|
1947
1947
|
size="default"
|
|
@@ -1967,7 +1967,7 @@
|
|
|
1967
1967
|
|
|
1968
1968
|
<div part="pagination-next"></div>
|
|
1969
1969
|
</pont-pagination-link>
|
|
1970
|
-
`}};vh([a({type:String})],_a.prototype,"href",2);_a=vh([p("pont-pagination-next")],_a);var z_=Object.defineProperty,V_=Object.getOwnPropertyDescriptor,bh=(e,t,r,o)=>{for(var n=o>1?void 0:o?V_(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&z_(t,r,n),n};let wa=class extends
|
|
1970
|
+
`}};vh([a({type:String})],_a.prototype,"href",2);_a=vh([p("pont-pagination-next")],_a);var z_=Object.defineProperty,V_=Object.getOwnPropertyDescriptor,bh=(e,t,r,o)=>{for(var n=o>1?void 0:o?V_(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&z_(t,r,n),n};let wa=class extends _{constructor(){super(...arguments),this.href="javascript:void(0)"}get _containerElement(){return this.querySelector("div[part=pagination-previous]")}createRenderRoot(){return this}firstUpdated(e){this.moveLightDomChildrenInto(this._containerElement)}render(){return l`
|
|
1971
1971
|
<pont-pagination-link
|
|
1972
1972
|
aria-label="Go to previous page"
|
|
1973
1973
|
size="default"
|
|
@@ -1993,7 +1993,7 @@
|
|
|
1993
1993
|
|
|
1994
1994
|
<div part="pagination-previous"></div>
|
|
1995
1995
|
</pont-pagination-link>
|
|
1996
|
-
`}};bh([a({type:String})],wa.prototype,"href",2);wa=bh([p("pont-pagination-previous")],wa);var H_=Object.getOwnPropertyDescriptor,G_=(e,t,r,o)=>{for(var n=o>1?void 0:o?H_(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let hc=class extends
|
|
1996
|
+
`}};bh([a({type:String})],wa.prototype,"href",2);wa=bh([p("pont-pagination-previous")],wa);var H_=Object.getOwnPropertyDescriptor,G_=(e,t,r,o)=>{for(var n=o>1?void 0:o?H_(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let hc=class extends _{get _containerElement(){return this.querySelector("nav[part=pagination]")}createRenderRoot(){return this}firstUpdated(e){this.moveLightDomChildrenInto(this._containerElement)}render(){return l`
|
|
1997
1997
|
<nav
|
|
1998
1998
|
role="navigation"
|
|
1999
1999
|
aria-label="pagination"
|
|
@@ -2167,7 +2167,7 @@
|
|
|
2167
2167
|
</span>
|
|
2168
2168
|
|
|
2169
2169
|
${this._renderInput()}
|
|
2170
|
-
`}};de.formAssociated=!0;de.GROUP_TAG="pont-radio-group";nn([a({type:String})],de.prototype,"value",2);nn([a({type:Boolean})],de.prototype,"disabled",2);nn([a({type:Boolean})],de.prototype,"readonly",2);nn([a({type:Boolean})],de.prototype,"required",2);nn([a({type:Boolean})],de.prototype,"invalid",2);nn([g()],de.prototype,"_formDisabled",2);de=nn([p("pont-radio-group-item")],de);const rw=["pont-relative","pont-border pont-border-scrollarea-color-border","pont-bg-scrollarea-color-bg"];var nw=Object.defineProperty,ow=Object.getOwnPropertyDescriptor,_h=(e,t,r,o)=>{for(var n=o>1?void 0:o?ow(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&nw(t,r,n),n};let Pa=class extends
|
|
2170
|
+
`}};de.formAssociated=!0;de.GROUP_TAG="pont-radio-group";nn([a({type:String})],de.prototype,"value",2);nn([a({type:Boolean})],de.prototype,"disabled",2);nn([a({type:Boolean})],de.prototype,"readonly",2);nn([a({type:Boolean})],de.prototype,"required",2);nn([a({type:Boolean})],de.prototype,"invalid",2);nn([g()],de.prototype,"_formDisabled",2);de=nn([p("pont-radio-group-item")],de);const rw=["pont-relative","pont-border pont-border-scrollarea-color-border","pont-bg-scrollarea-color-bg"];var nw=Object.defineProperty,ow=Object.getOwnPropertyDescriptor,_h=(e,t,r,o)=>{for(var n=o>1?void 0:o?ow(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&nw(t,r,n),n};let Pa=class extends _{createRenderRoot(){return this}firstUpdated(){this.moveLightDomChildrenInto(this.viewportEl)}render(){return l`
|
|
2171
2171
|
<div
|
|
2172
2172
|
dir="ltr"
|
|
2173
2173
|
data-slot="scroll-area"
|
|
@@ -2204,7 +2204,7 @@
|
|
|
2204
2204
|
style="overflow: hidden scroll;"
|
|
2205
2205
|
></div>
|
|
2206
2206
|
</div>
|
|
2207
|
-
`}};_h([So("[data-radix-scroll-area-viewport]")],Pa.prototype,"viewportEl",2);Pa=_h([p("pont-scroll-area")],Pa);class iw{constructor(){this.state={isOpen:!1,selectedValue:"",selectedText:""},this.listeners=new Set}subscribe(t){this.listeners.add(t)}unsubscribe(t){this.listeners.delete(t)}notify(){this.listeners.forEach(t=>t())}get isOpen(){return this.state.isOpen}get selectedValue(){return this.state.selectedValue}get selectedText(){return this.state.selectedText}open(){this.state.isOpen||(this.state.isOpen=!0,this.notify())}close(){this.state.isOpen&&(this.state.isOpen=!1,this.notify())}toggle(){this.state.isOpen=!this.state.isOpen,this.notify()}select(t,r,o){this.state.selectedValue=t,this.state.selectedText=r,this.state.isOpen=!1,this.notify()}}const ie={root:["pont-font-select-font-family"],value:["pont-flex","pont-gap-select-value-space-gap pont-items-center","pont-line-clamp-1"],trigger:{trigger:["pont-flex","pont-gap-select-trigger-space-gap pont-justify-between pont-items-center","pont-px-select-trigger-space-px pont-py-select-trigger-space-py","pont-w-full pont-h-select-trigger-space-h","pont-text-select-trigger-font pont-whitespace-nowrap","pont-bg-select-trigger-color-bg","pont-rounded-select-trigger-radius pont-border-select-trigger-width-border pont-border-select-trigger-color-border pont-outline-none","pont-transition-[color,box-shadow]","hover:pont-bg-select-trigger-color-bg-hover","focus-visible:pont-border-select-trigger-color-border-focus focus-visible:pont-ring-select-trigger-width-ring-focus focus-visible:pont-ring-select-trigger-color-ring-focus","pont-select-disabled:pont-opacity-select-trigger-opacity-disabled pont-select-disabled:pont-cursor-not-allowed","aria-invalid:pont-border-select-trigger-color-border-invalid aria-invalid:pont-ring-select-trigger-width-ring-invalid aria-invalid:pont-ring-select-trigger-color-ring-invalid","data-[placeholder]:pont-text-select-trigger-placeholder-color-text"],icon:["pont-shrink-0","pont-size-select-trigger-icon-space-size","pont-text-select-trigger-icon-color-text","pont-opacity-select-trigger-icon-opacity","pont-pointer-events-none"]},content:{content:["pont-fixed pont-overflow-x-hidden pont-overflow-y-auto pont-z-50","pont-w-fit","pont-text-select-content-color-text","pont-bg-select-content-color-bg","pont-rounded-select-content-radius pont-border-select-content-width-border pont-border-select-content-color-border","pont-shadow-select-content-shadow","pont-slide-in-from-top-2","pont-translate-y-1","data-[state=open]:pont-animate-in data-[state=open]:pont-fade-in-0 data-[state=open]:pont-zoom-in-95","data-[state=closed]:pont-animate-out data-[state=closed]:pont-fade-out-0 data-[state=closed]:pont-zoom-out-95"],viewport:["pont-p-select-content-viewport-space-p","pont-w-full","pont-scroll-my-1"]},label:["pont-px-select-label-space-px pont-py-select-label-space-py","pont-text-select-label-font pont-text-select-label-color-text"],item:{item:["pont-flex pont-relative","pont-gap-select-item-space-gap pont-items-center","pont-pl-select-item-space-pl pont-pr-select-item-space-pr pont-py-select-item-space-py","pont-w-full","pont-text-select-item-font","pont-rounded-select-item-radius pont-outline-hidden","pont-cursor-default pont-select-none","hover:pont-text-select-item-color-text-hover hover:pont-bg-select-item-color-bg-hover","focus:pont-text-select-item-color-text-focus focus:pont-bg-select-item-color-bg-focus","data-[disabled]:pont-opacity-select-item-opacity-disabled data-[disabled]:pont-pointer-events-none"],indicator:["pont-flex pont-absolute pont-right-2","pont-justify-center pont-items-center","pont-size-select-item-indicator-space-size"],icon:["pont-shrink-0","pont-size-select-item-icon-space-size","pont-text-select-item-icon-color-text","pont-pointer-events-none"]},separator:["pont-mx-select-separator-space-mx pont-my-select-separator-space-my","pont-h-select-separator-space-h","pont-bg-select-separator-color-bg","pont-pointer-events-none"]};var sw=Object.defineProperty,aw=Object.getOwnPropertyDescriptor,ml=(e,t,r,o)=>{for(var n=o>1?void 0:o?aw(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&sw(t,r,n),n};let Pr=class extends
|
|
2207
|
+
`}};_h([So("[data-radix-scroll-area-viewport]")],Pa.prototype,"viewportEl",2);Pa=_h([p("pont-scroll-area")],Pa);class iw{constructor(){this.state={isOpen:!1,selectedValue:"",selectedText:""},this.listeners=new Set}subscribe(t){this.listeners.add(t)}unsubscribe(t){this.listeners.delete(t)}notify(){this.listeners.forEach(t=>t())}get isOpen(){return this.state.isOpen}get selectedValue(){return this.state.selectedValue}get selectedText(){return this.state.selectedText}open(){this.state.isOpen||(this.state.isOpen=!0,this.notify())}close(){this.state.isOpen&&(this.state.isOpen=!1,this.notify())}toggle(){this.state.isOpen=!this.state.isOpen,this.notify()}select(t,r,o){this.state.selectedValue=t,this.state.selectedText=r,this.state.isOpen=!1,this.notify()}}const ie={root:["pont-font-select-font-family"],value:["pont-flex","pont-gap-select-value-space-gap pont-items-center","pont-line-clamp-1"],trigger:{trigger:["pont-flex","pont-gap-select-trigger-space-gap pont-justify-between pont-items-center","pont-px-select-trigger-space-px pont-py-select-trigger-space-py","pont-w-full pont-h-select-trigger-space-h","pont-text-select-trigger-font pont-whitespace-nowrap","pont-bg-select-trigger-color-bg","pont-rounded-select-trigger-radius pont-border-select-trigger-width-border pont-border-select-trigger-color-border pont-outline-none","pont-transition-[color,box-shadow]","hover:pont-bg-select-trigger-color-bg-hover","focus-visible:pont-border-select-trigger-color-border-focus focus-visible:pont-ring-select-trigger-width-ring-focus focus-visible:pont-ring-select-trigger-color-ring-focus","pont-select-disabled:pont-opacity-select-trigger-opacity-disabled pont-select-disabled:pont-cursor-not-allowed","aria-invalid:pont-border-select-trigger-color-border-invalid aria-invalid:pont-ring-select-trigger-width-ring-invalid aria-invalid:pont-ring-select-trigger-color-ring-invalid","data-[placeholder]:pont-text-select-trigger-placeholder-color-text"],icon:["pont-shrink-0","pont-size-select-trigger-icon-space-size","pont-text-select-trigger-icon-color-text","pont-opacity-select-trigger-icon-opacity","pont-pointer-events-none"]},content:{content:["pont-fixed pont-overflow-x-hidden pont-overflow-y-auto pont-z-50","pont-w-fit","pont-text-select-content-color-text","pont-bg-select-content-color-bg","pont-rounded-select-content-radius pont-border-select-content-width-border pont-border-select-content-color-border","pont-shadow-select-content-shadow","pont-slide-in-from-top-2","pont-translate-y-1","data-[state=open]:pont-animate-in data-[state=open]:pont-fade-in-0 data-[state=open]:pont-zoom-in-95","data-[state=closed]:pont-animate-out data-[state=closed]:pont-fade-out-0 data-[state=closed]:pont-zoom-out-95"],viewport:["pont-p-select-content-viewport-space-p","pont-w-full","pont-scroll-my-1"]},label:["pont-px-select-label-space-px pont-py-select-label-space-py","pont-text-select-label-font pont-text-select-label-color-text"],item:{item:["pont-flex pont-relative","pont-gap-select-item-space-gap pont-items-center","pont-pl-select-item-space-pl pont-pr-select-item-space-pr pont-py-select-item-space-py","pont-w-full","pont-text-select-item-font","pont-rounded-select-item-radius pont-outline-hidden","pont-cursor-default pont-select-none","hover:pont-text-select-item-color-text-hover hover:pont-bg-select-item-color-bg-hover","focus:pont-text-select-item-color-text-focus focus:pont-bg-select-item-color-bg-focus","data-[disabled]:pont-opacity-select-item-opacity-disabled data-[disabled]:pont-pointer-events-none"],indicator:["pont-flex pont-absolute pont-right-2","pont-justify-center pont-items-center","pont-size-select-item-indicator-space-size"],icon:["pont-shrink-0","pont-size-select-item-icon-space-size","pont-text-select-item-icon-color-text","pont-pointer-events-none"]},separator:["pont-mx-select-separator-space-mx pont-my-select-separator-space-my","pont-h-select-separator-space-h","pont-bg-select-separator-color-bg","pont-pointer-events-none"]};var sw=Object.defineProperty,aw=Object.getOwnPropertyDescriptor,ml=(e,t,r,o)=>{for(var n=o>1?void 0:o?aw(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&sw(t,r,n),n};let Pr=class extends _{constructor(){super(...arguments),this.uuid=za(),this.selectStore=new iw,this.value="",this.disabled=!1,this.handleClickOutside=e=>{const t=this.querySelector("[data-select-uuid]"),r=e.target;t!=null&&t.contains(r)||this.selectStore.close()}}updated(e){super.updated(e),e.has("value")&&this.value!==this.selectStore.selectedValue&&this.syncValueToStore()}connectedCallback(){super.connectedCallback(),document.addEventListener("mousedown",this.handleClickOutside)}disconnectedCallback(){document.removeEventListener("mousedown",this.handleClickOutside),super.disconnectedCallback()}firstUpdated(){const e=this.querySelector("div[part=select]");this.moveLightDomChildrenInto(e),this.syncValueToStore()}syncValueToStore(){var e;if(this.value){const t=this.querySelector(`pont-select-item[value="${this.value}"]`),r=((e=t==null?void 0:t.textContent)==null?void 0:e.trim())||this.value;this.selectStore.select(this.value,r)}else this.selectStore.select("","")}createRenderRoot(){return this}render(){return l`
|
|
2208
2208
|
<div
|
|
2209
2209
|
part="select"
|
|
2210
2210
|
data-select-uuid=${this.uuid}
|
|
@@ -2214,7 +2214,7 @@
|
|
|
2214
2214
|
* @license
|
|
2215
2215
|
* Copyright 2018 Google LLC
|
|
2216
2216
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
2217
|
-
*/const wh="important",lw=" !"+wh,dw=Xr(class extends xo{constructor(e){var t;if(super(e),e.type!==Xe.ATTRIBUTE||e.name!=="style"||((t=e.strings)==null?void 0:t.length)>2)throw Error("The `styleMap` directive must be used in the `style` attribute and must be the only part in the attribute.")}render(e){return Object.keys(e).reduce((t,r)=>{const o=e[r];return o==null?t:t+`${r=r.includes("-")?r:r.replace(/(?:^(webkit|moz|ms|o)|)(?=[A-Z])/g,"-$&").toLowerCase()}:${o};`},"")}update(e,[t]){const{style:r}=e.element;if(this.ft===void 0)return this.ft=new Set(Object.keys(t)),this.render(t);for(const o of this.ft)t[o]==null&&(this.ft.delete(o),o.includes("-")?r.removeProperty(o):r[o]=null);for(const o in t){const n=t[o];if(n!=null){this.ft.add(o);const i=typeof n=="string"&&n.endsWith(lw);o.includes("-")||i?r.setProperty(o,i?n.slice(0,-11):n,i?wh:""):r[o]=n}}return Gt}});var cw=Object.defineProperty,pw=Object.getOwnPropertyDescriptor,gl=(e,t,r,o)=>{for(var n=o>1?void 0:o?pw(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&cw(t,r,n),n};let Ci=class extends
|
|
2217
|
+
*/const wh="important",lw=" !"+wh,dw=Xr(class extends xo{constructor(e){var t;if(super(e),e.type!==Xe.ATTRIBUTE||e.name!=="style"||((t=e.strings)==null?void 0:t.length)>2)throw Error("The `styleMap` directive must be used in the `style` attribute and must be the only part in the attribute.")}render(e){return Object.keys(e).reduce((t,r)=>{const o=e[r];return o==null?t:t+`${r=r.includes("-")?r:r.replace(/(?:^(webkit|moz|ms|o)|)(?=[A-Z])/g,"-$&").toLowerCase()}:${o};`},"")}update(e,[t]){const{style:r}=e.element;if(this.ft===void 0)return this.ft=new Set(Object.keys(t)),this.render(t);for(const o of this.ft)t[o]==null&&(this.ft.delete(o),o.includes("-")?r.removeProperty(o):r[o]=null);for(const o in t){const n=t[o];if(n!=null){this.ft.add(o);const i=typeof n=="string"&&n.endsWith(lw);o.includes("-")||i?r.setProperty(o,i?n.slice(0,-11):n,i?wh:""):r[o]=n}}return Gt}});var cw=Object.defineProperty,pw=Object.getOwnPropertyDescriptor,gl=(e,t,r,o)=>{for(var n=o>1?void 0:o?pw(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&cw(t,r,n),n};let Ci=class extends _{constructor(){super(...arguments),this.focusedIndex=0,this._dropdownStyle={display:"none",top:"0px",left:"0px",minWidth:"128px"},this.childrenArray=[],this._handleScrollResize=()=>{this._select.selectStore.isOpen&&this._updateDropdownPosition()},this.onStoreChange=()=>{const e=this._containerElement;e&&(e.style.display=this._select.selectStore.isOpen?"block":"none"),this._select.selectStore.isOpen?(requestAnimationFrame(()=>{this._updateDropdownPosition()}),window.addEventListener("scroll",this._handleScrollResize,!0),window.addEventListener("resize",this._handleScrollResize)):(window.removeEventListener("scroll",this._handleScrollResize,!0),window.removeEventListener("resize",this._handleScrollResize),this._dropdownStyle={...this._dropdownStyle,display:"none"}),this._select.selectStore.isOpen&&this._select.selectStore.selectedValue&&(this.focusedIndex=this.childrenArray.findIndex(t=>t.value===this._select.selectStore.selectedValue)),this.updateFocusedItem(),this.requestUpdate()},this.handleKeyDown=e=>{var t;if(this._select.selectStore.isOpen)switch(e.preventDefault(),e.key){case"ArrowDown":this.focusedIndex=(this.focusedIndex+1)%this.childrenArray.length,this.updateFocusedItem();break;case"ArrowUp":this.focusedIndex=(this.focusedIndex-1+this.childrenArray.length)%this.childrenArray.length,this.updateFocusedItem();break;case"Enter":const r=this.childrenArray[this.focusedIndex],o=r.value,n=((t=r.textContent)==null?void 0:t.trim())||"";this._select.selectStore.select(o,n);break}}}get _select(){let e=this.parentElement;for(;e&&!(e instanceof Pr);)e=e.parentElement;return e}connectedCallback(){super.connectedCallback(),this._select.selectStore.subscribe(this.onStoreChange),document.addEventListener("keydown",this.handleKeyDown)}disconnectedCallback(){this._select.selectStore.unsubscribe(this.onStoreChange),document.removeEventListener("keydown",this.handleKeyDown),window.removeEventListener("scroll",this._handleScrollResize,!0),window.removeEventListener("resize",this._handleScrollResize),super.disconnectedCallback()}getTriggerButton(){const e=this._select;return e?e.querySelector("button[part=select-trigger]"):null}_updateDropdownPosition(){const e=this.getTriggerButton();if(!e)return;const t=e.getBoundingClientRect(),r=Math.max(128,t.width);this._dropdownStyle={display:this._select.selectStore.isOpen?"block":"none",top:`${t.bottom}px`,left:`${t.left}px`,minWidth:`${r}px`}}get _containerElement(){return this.querySelector("div[part=select-viewport]")}firstUpdated(){const e=Array.from(this.children).filter(t=>t.tagName.toLowerCase()==="pont-select-item");this.childrenArray=e,e.forEach((t,r)=>{t.tabIndex=r,t.selectItemIndex=r,t.isFocus=r===this.focusedIndex||t.value===this._select.selectStore.selectedValue,t.addEventListener("mouseover",o=>this.handleMouseOver(o,r))}),this.moveLightDomChildrenInto(this._containerElement),this._select.selectStore.isOpen&&requestAnimationFrame(()=>{this._updateDropdownPosition()})}updateFocusedItem(){this.childrenArray.forEach((e,t)=>{var r;e.isFocus=t===this.focusedIndex,(r=e.requestUpdate)==null||r.call(e)})}handleMouseOver(e,t){e.preventDefault(),this.focusedIndex=t}createRenderRoot(){return this}render(){return l`
|
|
2218
2218
|
<div
|
|
2219
2219
|
part="select-group"
|
|
2220
2220
|
data-slot="select-content"
|
|
@@ -2226,7 +2226,7 @@
|
|
|
2226
2226
|
class="${m(ie.content.viewport)}"
|
|
2227
2227
|
></div>
|
|
2228
2228
|
</div>
|
|
2229
|
-
`}};gl([g()],Ci.prototype,"focusedIndex",2);gl([g()],Ci.prototype,"_dropdownStyle",2);Ci=gl([p("pont-select-group")],Ci);var hw=Object.defineProperty,uw=Object.getOwnPropertyDescriptor,on=(e,t,r,o)=>{for(var n=o>1?void 0:o?uw(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&hw(t,r,n),n};let Cr=class extends
|
|
2229
|
+
`}};gl([g()],Ci.prototype,"focusedIndex",2);gl([g()],Ci.prototype,"_dropdownStyle",2);Ci=gl([p("pont-select-group")],Ci);var hw=Object.defineProperty,uw=Object.getOwnPropertyDescriptor,on=(e,t,r,o)=>{for(var n=o>1?void 0:o?uw(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&hw(t,r,n),n};let Cr=class extends _{constructor(){super(...arguments),this.value="",this.isSelected=!1,this.isFocus=!1,this.selectItemIndex=-1,this.onSelect=(e,t)=>{},this.class="",this._onStoreChange=()=>{var e,t;this.isSelected=this.value.toLowerCase()===((t=(e=this._select.selectStore.selectedValue)==null?void 0:e.toLowerCase)==null?void 0:t.call(e)),this.requestUpdate()},this.handleClick=e=>{e.stopPropagation();const t=this.getTextContent();this._select.selectStore.select(this.value,t),this.onSelect(this.value,this.selectItemIndex),this.dispatchEvent(new CustomEvent("change",{detail:{value:this.value},bubbles:!0,composed:!0}))}}get _select(){let e=this.parentElement;for(;e&&!(e instanceof Pr);)e=e.parentElement;return e}connectedCallback(){super.connectedCallback(),this._select.selectStore.subscribe(this._onStoreChange)}disconnectedCallback(){this._select.selectStore.unsubscribe(this._onStoreChange),super.disconnectedCallback()}firstUpdated(e){this.moveLightDomChildrenInto(this._containerElement)}get _containerElement(){return this.querySelector("div[part=select-item-container]")}createRenderRoot(){return this}getTextContent(){var o;const e=this._containerElement;if(e&&e.textContent)return e.textContent.trim();const t=this.querySelector("[part=select-item-indicator]"),r=this.cloneNode(!0);if(t){const n=r.querySelector("[part=select-item-indicator]");n==null||n.remove()}return((o=r.textContent)==null?void 0:o.trim())||""}render(){const e=this.getFilteredAttributes();return l`
|
|
2230
2230
|
<div
|
|
2231
2231
|
${xt(e)}
|
|
2232
2232
|
part="select-item"
|
|
@@ -2260,12 +2260,12 @@
|
|
|
2260
2260
|
|
|
2261
2261
|
<div part="select-item-container"></div>
|
|
2262
2262
|
</div>
|
|
2263
|
-
`}};on([a()],Cr.prototype,"value",2);on([a()],Cr.prototype,"isSelected",2);on([a()],Cr.prototype,"isFocus",2);on([a()],Cr.prototype,"selectItemIndex",2);on([a({type:Function})],Cr.prototype,"onSelect",2);on([a()],Cr.prototype,"class",2);Cr=on([p("pont-select-item")],Cr);var mw=Object.getOwnPropertyDescriptor,gw=(e,t,r,o)=>{for(var n=o>1?void 0:o?mw(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let mc=class extends
|
|
2263
|
+
`}};on([a()],Cr.prototype,"value",2);on([a()],Cr.prototype,"isSelected",2);on([a()],Cr.prototype,"isFocus",2);on([a()],Cr.prototype,"selectItemIndex",2);on([a({type:Function})],Cr.prototype,"onSelect",2);on([a()],Cr.prototype,"class",2);Cr=on([p("pont-select-item")],Cr);var mw=Object.getOwnPropertyDescriptor,gw=(e,t,r,o)=>{for(var n=o>1?void 0:o?mw(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let mc=class extends _{get _containerElement(){return this.querySelector("div[part=select-label]")}firstUpdated(e){this.moveLightDomChildrenInto(this._containerElement)}createRenderRoot(){return this}render(){return l`
|
|
2264
2264
|
<div
|
|
2265
2265
|
part="select-label"
|
|
2266
2266
|
class=${m(ie.label,this.className)}
|
|
2267
2267
|
></div>
|
|
2268
|
-
`}};mc=gw([p("pont-select-label")],mc);var fw=Object.defineProperty,vw=Object.getOwnPropertyDescriptor,fl=(e,t,r,o)=>{for(var n=o>1?void 0:o?vw(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&fw(t,r,n),n};let Ei=class extends
|
|
2268
|
+
`}};mc=gw([p("pont-select-label")],mc);var fw=Object.defineProperty,vw=Object.getOwnPropertyDescriptor,fl=(e,t,r,o)=>{for(var n=o>1?void 0:o?vw(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&fw(t,r,n),n};let Ei=class extends _{constructor(){super(...arguments),this.state=nl,this.isOpen=!1}get _containerElement(){return this.querySelector("div[part=select-list]")}firstUpdated(e){this.moveLightDomChildrenInto(this._containerElement)}createRenderRoot(){return this}render(){return l`
|
|
2269
2269
|
<div
|
|
2270
2270
|
part="select-list"
|
|
2271
2271
|
class="${m("pont-absolute pont-z-50 pont-max-h-72 pont-w-full pont-overflow-hidden pont-overflow-y-auto pont-rounded-lg pont-border pont-border-input pont-bg-background p-1 [&::-webkit-scrollbar-thumb]:pont-rounded-full [&::-webkit-scrollbar-thumb]:pont-bg-accent [&::-webkit-scrollbar-track]:pont-bg-gray-100 [&::-webkit-scrollbar]:pont-w-2",this.className)}"
|
|
@@ -2280,7 +2280,7 @@
|
|
|
2280
2280
|
role="separator"
|
|
2281
2281
|
class=${m(ie.separator,this.className)}
|
|
2282
2282
|
></div>
|
|
2283
|
-
`}};vl([a({type:String})],Si.prototype,"_id",2);vl([a({attribute:"aria-hidden",type:String})],Si.prototype,"_hidden",2);Si=vl([p("pont-select-separator")],Si);var _w=Object.defineProperty,ww=Object.getOwnPropertyDescriptor,$h=(e,t,r,o)=>{for(var n=o>1?void 0:o?ww(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&_w(t,r,n),n};let Ca=class extends
|
|
2283
|
+
`}};vl([a({type:String})],Si.prototype,"_id",2);vl([a({attribute:"aria-hidden",type:String})],Si.prototype,"_hidden",2);Si=vl([p("pont-select-separator")],Si);var _w=Object.defineProperty,ww=Object.getOwnPropertyDescriptor,$h=(e,t,r,o)=>{for(var n=o>1?void 0:o?ww(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&_w(t,r,n),n};let Ca=class extends _{constructor(){super(...arguments),this.id="",this._triggerId="",this.onStoreChange=()=>{this.requestUpdate()},this.handleClick=e=>{e.stopPropagation(),!(this._select&&this._select.disabled)&&this._select&&this._select.selectStore.toggle()}}get _select(){let e=this.parentElement;for(;e&&!(e instanceof Pr);)e=e.parentElement;return e}connectedCallback(){super.connectedCallback(),this._select.selectStore.subscribe(this.onStoreChange),this.classObserver=new MutationObserver(()=>{this.requestUpdate()}),this.classObserver.observe(this,{attributes:!0,attributeFilter:["class"]}),this._select&&(this.parentObserver=new MutationObserver(()=>{this.requestUpdate()}),this.parentObserver.observe(this._select,{attributes:!0,attributeFilter:["disabled"]}))}disconnectedCallback(){var e,t;this._select.selectStore.unsubscribe(this.onStoreChange),(e=this.classObserver)==null||e.disconnect(),(t=this.parentObserver)==null||t.disconnect()}get _containerElement(){return this.querySelector("span[part=select-trigger-container]")}firstUpdated(e){var t;super.firstUpdated(e),this._adoptId(),this.moveLightDomChildrenInto(this._containerElement),(t=this._containerElement)==null||t.addEventListener("click",this.handleClick)}updated(e){var t;(t=super.updated)==null||t.call(this,e),e.has("id")&&this._adoptId()}_adoptId(){this.id&&(this._triggerId=this.id),this.removeAttribute("id")}createRenderRoot(){return this}getAttributesToExclude(){return["data-testid"]}getClassAttribute(){const e=this.getAttribute("class")||"",t=this.customClass||"",r=this.className||"";return e||t||r||""}filterConflictingWidthClasses(e,t){const r=/pont-w-[\w-[\]]+/;return r.test(t)?e.map(n=>n.split(/\s+/).filter(i=>!r.test(i)).join(" ")):e}render(){var o;const e=this.getClassAttribute(),t=this.filterConflictingWidthClasses(ie.trigger.trigger,e),r=((o=this._select)==null?void 0:o.disabled)||!1;return l`
|
|
2284
2284
|
<button
|
|
2285
2285
|
type="button"
|
|
2286
2286
|
id=${this._triggerId!==""?this._triggerId:h}
|
|
@@ -2311,11 +2311,11 @@
|
|
|
2311
2311
|
<path d="m6 9 6 6 6-6" />
|
|
2312
2312
|
</svg>
|
|
2313
2313
|
</button>
|
|
2314
|
-
`}};$h([a({type:String})],Ca.prototype,"id",2);Ca=$h([p("pont-select-trigger")],Ca);var $w=Object.defineProperty,Pw=Object.getOwnPropertyDescriptor,Ph=(e,t,r,o)=>{for(var n=o>1?void 0:o?Pw(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&$w(t,r,n),n};let Ea=class extends
|
|
2314
|
+
`}};$h([a({type:String})],Ca.prototype,"id",2);Ca=$h([p("pont-select-trigger")],Ca);var $w=Object.defineProperty,Pw=Object.getOwnPropertyDescriptor,Ph=(e,t,r,o)=>{for(var n=o>1?void 0:o?Pw(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&$w(t,r,n),n};let Ea=class extends _{constructor(){super(...arguments),this.placeholder="select a value",this.onStoreChange=()=>{this.requestUpdate()},this.renderLabel=()=>{var t;const e=(t=this._select)==null?void 0:t.selectStore;return e&&e.selectedValue!==void 0&&e.selectedValue!==""?e.selectedText||e.selectedValue:this.placeholder}}get _select(){let e=this.parentElement;for(;e&&!(e instanceof Pr);)e=e.parentElement;return e}connectedCallback(){super.connectedCallback(),this._select.selectStore.subscribe(this.onStoreChange),document.addEventListener("clicked-select-item",()=>{this.requestUpdate()})}disconnectedCallback(){this._select.selectStore.unsubscribe(this.onStoreChange)}createRenderRoot(){return this}render(){return l`
|
|
2315
2315
|
<span part="select-value" class=${m(ie.value,this.className)}>
|
|
2316
2316
|
${this.renderLabel()}
|
|
2317
2317
|
</span>
|
|
2318
|
-
`}};Ph([a({type:String})],Ea.prototype,"placeholder",2);Ea=Ph([p("pont-select-value")],Ea);const Cw="pont-bg-skeleton-color-bg pont-animate-skeleton-animate pont-rounded-skeleton-radius";var Ew=Object.getOwnPropertyDescriptor,Sw=(e,t,r,o)=>{for(var n=o>1?void 0:o?Ew(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let gc=class extends
|
|
2318
|
+
`}};Ph([a({type:String})],Ea.prototype,"placeholder",2);Ea=Ph([p("pont-select-value")],Ea);const Cw="pont-bg-skeleton-color-bg pont-animate-skeleton-animate pont-rounded-skeleton-radius";var Ew=Object.getOwnPropertyDescriptor,Sw=(e,t,r,o)=>{for(var n=o>1?void 0:o?Ew(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let gc=class extends _{createRenderRoot(){return this}render(){return l` <div class=${m(Cw,this.className)}></div> `}};gc=Sw([p("pont-skeleton")],gc);var xw=Object.defineProperty,Ow=Object.getOwnPropertyDescriptor,Ch=(e,t,r,o)=>{for(var n=o>1?void 0:o?Ow(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&xw(t,r,n),n};let Sa=class extends f{constructor(){super(...arguments),this.variant="circle"}createRenderRoot(){return this}render(){return this.variant==="basic"?l`
|
|
2319
2319
|
<svg
|
|
2320
2320
|
data-slot="spinner"
|
|
2321
2321
|
data-variant="basic"
|
|
@@ -2410,7 +2410,7 @@
|
|
|
2410
2410
|
?data-dirty=${this._dirty}
|
|
2411
2411
|
></span>
|
|
2412
2412
|
</span>
|
|
2413
|
-
`}};Ct.formAssociated=!0;Ct.CHECKED_CHANGE_EVENT="pont-switch:checked-change";jt([a({attribute:"default-checked",type:Boolean})],Ct.prototype,"defaultChecked",2);jt([a({type:Boolean})],Ct.prototype,"checked",2);jt([a({attribute:!1})],Ct.prototype,"onCheckedChange",2);jt([a({type:Boolean})],Ct.prototype,"disabled",2);jt([a({type:Boolean})],Ct.prototype,"readonly",2);jt([a({type:Boolean})],Ct.prototype,"required",2);jt([a({type:Boolean})],Ct.prototype,"invalid",2);jt([a({type:String,reflect:!0})],Ct.prototype,"name",2);jt([a({type:String})],Ct.prototype,"value",2);jt([a({type:String,attribute:"unchecked-value"})],Ct.prototype,"uncheckedValue",2);jt([g()],Ct.prototype,"_checked",2);jt([g()],Ct.prototype,"_formDisabled",2);Ct=jt([p("pont-switch")],Ct);const $t={preview:["pont-flex pont-bg-table-preview-color-bg pont-w-table-preview-space-w pont-items-center pont-justify-center pont-px-table-preview-space-px pont-py-table-preview-space-py"],container:["pont-relative pont-w-table-container-space-w pont-overflow-auto"],table:["pont-w-table-space-w pont-caption-bottom pont-text-table-font"],caption:["pont-mt-table-caption-space-mt pont-text-table-caption-font pont-text-table-caption-color-text"],head:{root:["[&_tr]:pont-border-table-head-color-border [&_tr]:pont-border-b-table-head-width-border"],row:["pont-border-b-table-head-width-border pont-border-table-head-color-border pont-transition-colors hover:pont-bg-table-head-row-color-bg-hover"],cell:{base:["pont-h-table-head-cell-space-h pont-px-table-head-cell-space-px pont-align-middle pont-font-table-head-cell-font-weight pont-text-table-head-cell-color-text"],align:{left:"pont-text-left",right:"pont-text-right"}}},body:{root:["[&_tr:last-child]:pont-border-0"],row:["pont-border-b-table-body-width-border pont-border-table-body-color-border pont-transition-colors hover:pont-bg-table-body-row-color-bg-hover"],cell:{base:["pont-px-table-body-cell-space-px pont-py-table-body-cell-space-py pont-align-middle"],align:{right:"pont-text-right"}}},footer:{root:["pont-border-t-table-footer-width-border pont-border-table-footer-color-border pont-bg-table-footer-color-bg pont-font-table-footer-font-weight [&>tr]:pont-last:border-b-0"],row:["pont-border-b-table-footer-width-border pont-border-table-footer-color-border pont-transition-colors hover:pont-bg-table-footer-row-color-bg-hover"],cell:{base:["pont-px-table-footer-cell-space-px pont-py-table-footer-cell-space-py pont-align-middle"],align:{right:"pont-text-right"}}}};var Aw=Object.defineProperty,Tw=Object.getOwnPropertyDescriptor,Ui=(e,t,r,o)=>{for(var n=o>1?void 0:o?Tw(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&Aw(t,r,n),n};let $o=class extends
|
|
2413
|
+
`}};Ct.formAssociated=!0;Ct.CHECKED_CHANGE_EVENT="pont-switch:checked-change";jt([a({attribute:"default-checked",type:Boolean})],Ct.prototype,"defaultChecked",2);jt([a({type:Boolean})],Ct.prototype,"checked",2);jt([a({attribute:!1})],Ct.prototype,"onCheckedChange",2);jt([a({type:Boolean})],Ct.prototype,"disabled",2);jt([a({type:Boolean})],Ct.prototype,"readonly",2);jt([a({type:Boolean})],Ct.prototype,"required",2);jt([a({type:Boolean})],Ct.prototype,"invalid",2);jt([a({type:String,reflect:!0})],Ct.prototype,"name",2);jt([a({type:String})],Ct.prototype,"value",2);jt([a({type:String,attribute:"unchecked-value"})],Ct.prototype,"uncheckedValue",2);jt([g()],Ct.prototype,"_checked",2);jt([g()],Ct.prototype,"_formDisabled",2);Ct=jt([p("pont-switch")],Ct);const $t={preview:["pont-flex pont-bg-table-preview-color-bg pont-w-table-preview-space-w pont-items-center pont-justify-center pont-px-table-preview-space-px pont-py-table-preview-space-py"],container:["pont-relative pont-w-table-container-space-w pont-overflow-auto"],table:["pont-w-table-space-w pont-caption-bottom pont-text-table-font"],caption:["pont-mt-table-caption-space-mt pont-text-table-caption-font pont-text-table-caption-color-text"],head:{root:["[&_tr]:pont-border-table-head-color-border [&_tr]:pont-border-b-table-head-width-border"],row:["pont-border-b-table-head-width-border pont-border-table-head-color-border pont-transition-colors hover:pont-bg-table-head-row-color-bg-hover"],cell:{base:["pont-h-table-head-cell-space-h pont-px-table-head-cell-space-px pont-align-middle pont-font-table-head-cell-font-weight pont-text-table-head-cell-color-text"],align:{left:"pont-text-left",right:"pont-text-right"}}},body:{root:["[&_tr:last-child]:pont-border-0"],row:["pont-border-b-table-body-width-border pont-border-table-body-color-border pont-transition-colors hover:pont-bg-table-body-row-color-bg-hover"],cell:{base:["pont-px-table-body-cell-space-px pont-py-table-body-cell-space-py pont-align-middle"],align:{right:"pont-text-right"}}},footer:{root:["pont-border-t-table-footer-width-border pont-border-table-footer-color-border pont-bg-table-footer-color-bg pont-font-table-footer-font-weight [&>tr]:pont-last:border-b-0"],row:["pont-border-b-table-footer-width-border pont-border-table-footer-color-border pont-transition-colors hover:pont-bg-table-footer-row-color-bg-hover"],cell:{base:["pont-px-table-footer-cell-space-px pont-py-table-footer-cell-space-py pont-align-middle"],align:{right:"pont-text-right"}}}};var Aw=Object.defineProperty,Tw=Object.getOwnPropertyDescriptor,Ui=(e,t,r,o)=>{for(var n=o>1?void 0:o?Tw(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&Aw(t,r,n),n};let $o=class extends _{constructor(){super(...arguments),this.dataTable=[],this.footerData=[],this.captionText=""}get _containerElement(){return this.querySelector("table[part=table]")}getAttributesToExclude(){return["data-testid"]}createRenderRoot(){return this}firstUpdated(e){this.moveLightDomChildrenInto(this._containerElement)}get columnKeys(){var t;const e=(t=this.dataTable)==null?void 0:t[0];return e?Object.keys(e).filter(r=>r!=="id"):[]}capitalizeLabel(e){return e.charAt(0).toUpperCase()+e.slice(1)}render(){const e=this.columnKeys;return l`
|
|
2414
2414
|
<div class=${m($t.preview)}>
|
|
2415
2415
|
<div class=${m($t.container)}>
|
|
2416
2416
|
<table part="table" class=${m($t.table)}>
|
|
@@ -2495,7 +2495,7 @@
|
|
|
2495
2495
|
tabindex="0"
|
|
2496
2496
|
hidden
|
|
2497
2497
|
></div>
|
|
2498
|
-
`}};Sh([a({type:String})],Oa.prototype,"value",2);Oa=Sh([p("pont-tabs-content")],Oa);const No={viewportRoot:["pont-fixed pont-top-0 pont-z-[100] pont-flex pont-max-h-screen pont-w-toast-viewport-root-space-w pont-flex-col-reverse pont-px-toast-viewport-root-space-px pont-py-toast-viewport-root-space-py sm:pont-bottom-0 sm:pont-right-0 sm:pont-top-auto sm:pont-flex-col md:pont-max-w-toast-viewport-root-space-w-md"],viewportItem:{base:["group pont-pointer-events-auto pont-relative pont-flex pont-w-toast-viewport-item-space-w pont-items-center pont-justify-between pont-gap-toast-viewport-item-space-gap pont-overflow-hidden pont-rounded-toast-viewport-item-radius pont-px-toast-viewport-item-space-px pont-py-toast-viewport-item-space-py pont-shadow-toast-viewport-item-shadow pont-transition-all","data-[swipe=cancel]:pont-translate-x-0","data-[swipe=end]:pont-translate-x-[var(--radix-toast-swipe-end-x)]","data-[swipe=move]:pont-translate-x-[var(--radix-toast-swipe-move-x)]","data-[swipe=move]:pont-transition-none","data-[state=open]:pont-animate-toast-animate-in","data-[state=closed]:pont-animate-toast-animate-out","data-[swipe=end]:pont-animate-toast-animate-out","data-[state=closed]:pont-opacity-80","data-[state=open]:pont-translate-y-toast-viewport-item-translate-y-enter-desktop","data-[state=open]:sm:pont-translate-y-toast-viewport-item-translate-y-enter-mobile","data-[state=closed]:pont-translate-x-toast-viewport-item-translate-x-exit"],variants:{default:["pont-border pont-border-toast-viewport-default-color-border pont-bg-toast-viewport-default-color-bg pont-text-toast-viewport-default-color-text"],destructive:["pont-bg-toast-viewport-destructive-color-bg pont-text-toast-viewport-destructive-color-text"]}},action:{base:["pont-text-toast-action-font pont-font-toast-action-font-weight pont-text-toast-action-color-text","pont-h-toast-action-space-h pont-px-toast-action-space-px pont-py-toast-action-space-py","pont-inline-flex pont-border pont-border-toast-action-color-border pont-shrink-0 pont-items-center pont-justify-center pont-rounded-toast-action-radius pont-transition-colors","focus:pont-outline-none focus:pont-ring-toast-action-width-ring-focus focus:pont-ring-toast-action-color-ring-focus","disabled:pont-pointer-events-none disabled:pont-opacity-toast-action-opacity-disabled"],variants:{default:["pont-bg-toast-action-default-color-bg hover:pont-bg-toast-action-default-color-bg-hover"],destructive:["pont-bg-toast-action-destructive-color-bg hover:pont-bg-toast-action-destructive-color-bg-hover pont-text-toast-action-destructive-color-text focus:pont-ring-toast-action-destructive-color-ring-focus"]}},title:["pont-text-toast-title-font pont-font-toast-title-font-weight [&+div]:pont-text-toast-title-font"],description:["pont-text-toast-description-font pont-opacity-toast-description-opacity"]};var Yw=Object.defineProperty,Qw=Object.getOwnPropertyDescriptor,yl=(e,t,r,o)=>{for(var n=o>1?void 0:o?Qw(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&Yw(t,r,n),n};const vc="closed";let Zr=class extends
|
|
2498
|
+
`}};Sh([a({type:String})],Oa.prototype,"value",2);Oa=Sh([p("pont-tabs-content")],Oa);const No={viewportRoot:["pont-fixed pont-top-0 pont-z-[100] pont-flex pont-max-h-screen pont-w-toast-viewport-root-space-w pont-flex-col-reverse pont-px-toast-viewport-root-space-px pont-py-toast-viewport-root-space-py sm:pont-bottom-0 sm:pont-right-0 sm:pont-top-auto sm:pont-flex-col md:pont-max-w-toast-viewport-root-space-w-md"],viewportItem:{base:["group pont-pointer-events-auto pont-relative pont-flex pont-w-toast-viewport-item-space-w pont-items-center pont-justify-between pont-gap-toast-viewport-item-space-gap pont-overflow-hidden pont-rounded-toast-viewport-item-radius pont-px-toast-viewport-item-space-px pont-py-toast-viewport-item-space-py pont-shadow-toast-viewport-item-shadow pont-transition-all","data-[swipe=cancel]:pont-translate-x-0","data-[swipe=end]:pont-translate-x-[var(--radix-toast-swipe-end-x)]","data-[swipe=move]:pont-translate-x-[var(--radix-toast-swipe-move-x)]","data-[swipe=move]:pont-transition-none","data-[state=open]:pont-animate-toast-animate-in","data-[state=closed]:pont-animate-toast-animate-out","data-[swipe=end]:pont-animate-toast-animate-out","data-[state=closed]:pont-opacity-80","data-[state=open]:pont-translate-y-toast-viewport-item-translate-y-enter-desktop","data-[state=open]:sm:pont-translate-y-toast-viewport-item-translate-y-enter-mobile","data-[state=closed]:pont-translate-x-toast-viewport-item-translate-x-exit"],variants:{default:["pont-border pont-border-toast-viewport-default-color-border pont-bg-toast-viewport-default-color-bg pont-text-toast-viewport-default-color-text"],destructive:["pont-bg-toast-viewport-destructive-color-bg pont-text-toast-viewport-destructive-color-text"]}},action:{base:["pont-text-toast-action-font pont-font-toast-action-font-weight pont-text-toast-action-color-text","pont-h-toast-action-space-h pont-px-toast-action-space-px pont-py-toast-action-space-py","pont-inline-flex pont-border pont-border-toast-action-color-border pont-shrink-0 pont-items-center pont-justify-center pont-rounded-toast-action-radius pont-transition-colors","focus:pont-outline-none focus:pont-ring-toast-action-width-ring-focus focus:pont-ring-toast-action-color-ring-focus","disabled:pont-pointer-events-none disabled:pont-opacity-toast-action-opacity-disabled"],variants:{default:["pont-bg-toast-action-default-color-bg hover:pont-bg-toast-action-default-color-bg-hover"],destructive:["pont-bg-toast-action-destructive-color-bg hover:pont-bg-toast-action-destructive-color-bg-hover pont-text-toast-action-destructive-color-text focus:pont-ring-toast-action-destructive-color-ring-focus"]}},title:["pont-text-toast-title-font pont-font-toast-title-font-weight [&+div]:pont-text-toast-title-font"],description:["pont-text-toast-description-font pont-opacity-toast-description-opacity"]};var Yw=Object.defineProperty,Qw=Object.getOwnPropertyDescriptor,yl=(e,t,r,o)=>{for(var n=o>1?void 0:o?Qw(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&Yw(t,r,n),n};const vc="closed";let Zr=class extends _{constructor(){super(...arguments),this.variant="default",this.state=vc}get _containerElement(){return this.querySelector("li[part=toast-view-port-li]")}createRenderRoot(){return this}firstUpdated(e){this.moveLightDomChildrenInto(this._containerElement)}render(){return l` <ol
|
|
2499
2499
|
part="toast-view-port"
|
|
2500
2500
|
tabindex="-1"
|
|
2501
2501
|
@click="${e=>e.stopPropagation()}"
|
|
@@ -2513,32 +2513,32 @@
|
|
|
2513
2513
|
data-radix-collection-item=""
|
|
2514
2514
|
style="user-select: none; touch-action: none;"
|
|
2515
2515
|
></li>
|
|
2516
|
-
</ol>`}};Zr.toastVariants=No.viewportItem;yl([a({type:String})],Zr.prototype,"variant",2);yl([a({attribute:"data-state",type:String})],Zr.prototype,"state",2);Zr=yl([p("pont-toast-view-port")],Zr);var Zw=Object.defineProperty,Jw=Object.getOwnPropertyDescriptor,xh=(e,t,r,o)=>{for(var n=o>1?void 0:o?Jw(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&Zw(t,r,n),n};let Fn=class extends
|
|
2516
|
+
</ol>`}};Zr.toastVariants=No.viewportItem;yl([a({type:String})],Zr.prototype,"variant",2);yl([a({attribute:"data-state",type:String})],Zr.prototype,"state",2);Zr=yl([p("pont-toast-view-port")],Zr);var Zw=Object.defineProperty,Jw=Object.getOwnPropertyDescriptor,xh=(e,t,r,o)=>{for(var n=o>1?void 0:o?Jw(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&Zw(t,r,n),n};let Fn=class extends _{constructor(){super(...arguments),this.variant="default"}get _containerElement(){return this.querySelector("button[part=toast-action]")}getAttributesToExclude(){return["click","type","variant"]}firstUpdated(e){this.moveLightDomChildrenInto(this._containerElement)}getFilteredAttributes(){const e=this.getAttributesToExclude(),t={};for(const r of this.attributes)e.includes(r.name)||(t[r.name]=r.value);return t}createRenderRoot(){return this}render(){const e=this.getFilteredAttributes();return l`
|
|
2517
2517
|
<button
|
|
2518
2518
|
${xt(e)}
|
|
2519
2519
|
part="toast-action"
|
|
2520
2520
|
type="button"
|
|
2521
2521
|
class="${m(Fn.toastVariants.base,Fn.toastVariants.variants[this.variant],this.className,"pont-w-max")}"
|
|
2522
2522
|
></button>
|
|
2523
|
-
`}};Fn.toastVariants=No.action;xh([a({type:String})],Fn.prototype,"variant",2);Fn=xh([p("pont-toast-action")],Fn);var Xw=Object.getOwnPropertyDescriptor,t$=(e,t,r,o)=>{for(var n=o>1?void 0:o?Xw(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let bc=class extends
|
|
2523
|
+
`}};Fn.toastVariants=No.action;xh([a({type:String})],Fn.prototype,"variant",2);Fn=xh([p("pont-toast-action")],Fn);var Xw=Object.getOwnPropertyDescriptor,t$=(e,t,r,o)=>{for(var n=o>1?void 0:o?Xw(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let bc=class extends _{get _containerElement(){return this.querySelector("div[part=toast-description]")}createRenderRoot(){return this}firstUpdated(e){this.moveLightDomChildrenInto(this._containerElement)}render(){return l`
|
|
2524
2524
|
<div
|
|
2525
2525
|
class="${m(No.description,this.className)}"
|
|
2526
2526
|
part="toast-description"
|
|
2527
2527
|
>
|
|
2528
2528
|
<slot></slot>
|
|
2529
2529
|
</div>
|
|
2530
|
-
`}};bc=t$([p("pont-toast-description")],bc);var e$=Object.getOwnPropertyDescriptor,r$=(e,t,r,o)=>{for(var n=o>1?void 0:o?e$(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let yc=class extends
|
|
2530
|
+
`}};bc=t$([p("pont-toast-description")],bc);var e$=Object.getOwnPropertyDescriptor,r$=(e,t,r,o)=>{for(var n=o>1?void 0:o?e$(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let yc=class extends _{get _containerElement(){return this.querySelector("div[part=toast-title]")}createRenderRoot(){return this}firstUpdated(e){this.moveLightDomChildrenInto(this._containerElement)}render(){return l`
|
|
2531
2531
|
<div
|
|
2532
2532
|
part="toast-title"
|
|
2533
2533
|
class="${m(No.title,this.className)}"
|
|
2534
2534
|
></div>
|
|
2535
|
-
`}};yc=r$([p("pont-toast-title")],yc);var n$=Object.getOwnPropertyDescriptor,o$=(e,t,r,o)=>{for(var n=o>1?void 0:o?n$(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let _c=class extends
|
|
2535
|
+
`}};yc=r$([p("pont-toast-title")],yc);var n$=Object.getOwnPropertyDescriptor,o$=(e,t,r,o)=>{for(var n=o>1?void 0:o?n$(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let _c=class extends _{constructor(){super(),this.handleClick=this.handleClick.bind(this)}get _containerElement(){return this.querySelector("div[part=toast-trigger]")}get _toast(){let e=this.parentElement;for(;e&&!(e instanceof Oi);)e=e.parentElement;return e}createRenderRoot(){return this}firstUpdated(e){this.moveLightDomChildrenInto(this._containerElement)}handleClick(e){e.stopPropagation(),this.dispatchEvent(new CustomEvent("open-toast",{bubbles:!0})),this._toast.isOpen=!0}render(){return l`
|
|
2536
2536
|
<div
|
|
2537
2537
|
@click=${this.handleClick}
|
|
2538
2538
|
part="toast-trigger"
|
|
2539
2539
|
class="${m(this.className)}"
|
|
2540
2540
|
></div>
|
|
2541
|
-
`}};_c=o$([p("pont-toast-trigger")],_c);var i$=Object.defineProperty,s$=Object.getOwnPropertyDescriptor,Oh=(e,t,r,o)=>{for(var n=o>1?void 0:o?s$(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&i$(t,r,n),n};let Oi=class extends
|
|
2541
|
+
`}};_c=o$([p("pont-toast-trigger")],_c);var i$=Object.defineProperty,s$=Object.getOwnPropertyDescriptor,Oh=(e,t,r,o)=>{for(var n=o>1?void 0:o?s$(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&i$(t,r,n),n};let Oi=class extends _{constructor(){super(...arguments),this.isOpen=!1}get _containerElement(){return this.querySelector("div[part=toast]")}onClick(){this.isOpen=!this.isOpen}connectedCallback(){super.connectedCallback(),this.addEventListener("close-toast",()=>{this.isOpen=!1}),this.addEventListener("open-toast",()=>{this.isOpen=!0})}get _content(){return this.querySelector("pont-toast-view-port")}updated(e){super.updated(e);const t=this._content;t&&(t.dataset.state=this.isOpen?"open":"closed")}firstUpdated(e){this.moveLightDomChildrenInto(this._containerElement)}createRenderRoot(){return this}render(){return l` <div class="${m("",this.className)}" part="toast"></div> `}};Oh([g()],Oi.prototype,"isOpen",2);Oi=Oh([p("pont-toast")],Oi);var Ri=(e=>(e.MULTIPLE="multiple",e.SINGLE="single",e))(Ri||{}),Ii=(e=>(e.DEFAULT="default",e.OUTLINE="outline",e))(Ii||{}),Ai=(e=>(e.SMALL="sm",e.MEDIUM="md",e.LARGE="lg",e))(Ai||{});const wc=e=>typeof e=="boolean"?`${e}`:e===0?"0":e,$c=Va,Rh=(e,t)=>r=>{var o;if((t==null?void 0:t.variants)==null)return $c(e,r==null?void 0:r.class,r==null?void 0:r.className);const{variants:n,defaultVariants:i}=t,s=Object.keys(n).map(u=>{const v=r==null?void 0:r[u],y=i==null?void 0:i[u];if(v===null)return null;const w=wc(v)||wc(y);return n[u][w]}),d=r&&Object.entries(r).reduce((u,v)=>{let[y,w]=v;return w===void 0||(u[y]=w),u},{}),c=t==null||(o=t.compoundVariants)===null||o===void 0?void 0:o.reduce((u,v)=>{let{class:y,className:w,...b}=v;return Object.entries(b).every(C=>{let[P,O]=C;return Array.isArray(O)?O.includes({...i,...d}[P]):{...i,...d}[P]===O})?[...u,y,w]:u},[]);return $c(e,s,c,r==null?void 0:r.class,r==null?void 0:r.className)},a$=Rh("pont-inline-flex pont-items-center pont-justify-center pont-rounded-toggle-group-item-radius pont-text-toggle-group-item-font pont-font-toggle-group-item-font-weight pont-transition-colors focus-visible:pont-outline-none focus-visible:pont-ring-toggle-group-item-width-ring-focus focus-visible:pont-ring-toggle-group-item-color-ring-focus focus-visible:pont-ring-offset-toggle-group-item-width-ring-offset-focus disabled:pont-pointer-events-none disabled:pont-opacity-toggle-group-item-opacity-disabled data-[state=on]:pont-bg-toggle-group-item-color-bg-on data-[state=on]:pont-text-toggle-group-item-color-text-on pont-bg-transparent",{variants:{variant:{default:"hover:pont-bg-toggle-group-item-default-color-bg-hover hover:pont-text-toggle-group-item-default-color-text-hover",outline:"pont-border pont-border-toggle-group-item-outline-color-border hover:pont-bg-toggle-group-item-outline-color-bg-hover hover:pont-text-toggle-group-item-outline-color-text-hover"},size:{sm:"pont-h-toggle-group-item-space-h-sm pont-px-toggle-group-item-space-px-sm",md:"pont-h-toggle-group-item-space-h-md pont-px-toggle-group-item-space-px-md",lg:"pont-h-toggle-group-item-space-h-lg pont-px-toggle-group-item-space-px-lg"}}}),l$="pont-flex pont-items-center pont-justify-center pont-gap-toggle-group-space-gap";var d$=Object.defineProperty,c$=Object.getOwnPropertyDescriptor,sn=(e,t,r,o)=>{for(var n=o>1?void 0:o?c$(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&d$(t,r,n),n};let Fe=class extends _{constructor(){super(),this.checked=!1,this.id=za(),this.variant=Ii.DEFAULT,this.size=Ai.SMALL,this.disabled=!1,this.type=Ri.SINGLE,this.variant=Ii.DEFAULT,this.size=Ai.SMALL}get _parent(){let e=this.parentElement;for(;e&&!(e instanceof nr);)e=e.parentElement;return e}get _containerElement(){return this.querySelector("button[part=toggle-group-item]")}get _siblings(){var e;return Array.from(((e=this.parentElement)==null?void 0:e.children)||[]).filter(t=>t!==this)}getAttributesToExclude(){return["disabled","type"]}createRenderRoot(){return this}firstUpdated(e){this.syncFromParent(),this.moveLightDomChildrenInto(this._containerElement)}syncFromParent(){const e=this._parent;if(!e)return;this.variant!==e.variant&&(this.variant=e.variant),this.size!==e.size&&(this.size=e.size);const t=e.selectedItems.includes(this.id);this.checked!==t&&(this.checked=t),this.type!==e.type&&(this.type=e.type)}syncSelection(){const e=this._parent;if(!e)return;const t=e.selectedItems.includes(this.id);this.checked!==t&&(this.checked=t)}toggleSelection(e){if(this.disabled||!this._parent)return;const t=this._parent,r=t.selectedItems.indexOf(e);this.type===Ri.SINGLE?(r!==-1?t.selectedItems.splice(r,1):t.selectedItems[0]=e,this._siblings.forEach(o=>o.syncSelection())):r!==-1?t.selectedItems.splice(r,1):t.selectedItems.push(e),this.syncSelection()}render(){return console.log({variant:this.variant,size:this.size,className:this.className}),l`
|
|
2542
2542
|
<button
|
|
2543
2543
|
part="toggle-group-item"
|
|
2544
2544
|
id=${this.id}
|
|
@@ -2549,7 +2549,7 @@
|
|
|
2549
2549
|
?disabled=${this.disabled}
|
|
2550
2550
|
@click=${()=>this.toggleSelection(this.id)}
|
|
2551
2551
|
></button>
|
|
2552
|
-
`}};Fe.toggleGroupVariants=a$;sn([a({attribute:!0,type:Boolean,reflect:!0})],Fe.prototype,"checked",2);sn([a({attribute:!0,type:String,reflect:!0})],Fe.prototype,"id",2);sn([a()],Fe.prototype,"variant",2);sn([a()],Fe.prototype,"size",2);sn([a({type:Boolean})],Fe.prototype,"disabled",2);sn([a({type:String})],Fe.prototype,"type",2);Fe=sn([p("pont-toggle-group-item")],Fe);var p$=Object.defineProperty,h$=Object.getOwnPropertyDescriptor,an=(e,t,r,o)=>{for(var n=o>1?void 0:o?h$(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&p$(t,r,n),n};let nr=class extends
|
|
2552
|
+
`}};Fe.toggleGroupVariants=a$;sn([a({attribute:!0,type:Boolean,reflect:!0})],Fe.prototype,"checked",2);sn([a({attribute:!0,type:String,reflect:!0})],Fe.prototype,"id",2);sn([a()],Fe.prototype,"variant",2);sn([a()],Fe.prototype,"size",2);sn([a({type:Boolean})],Fe.prototype,"disabled",2);sn([a({type:String})],Fe.prototype,"type",2);Fe=sn([p("pont-toggle-group-item")],Fe);var p$=Object.defineProperty,h$=Object.getOwnPropertyDescriptor,an=(e,t,r,o)=>{for(var n=o>1?void 0:o?h$(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&p$(t,r,n),n};let nr=class extends _{constructor(){super(...arguments),this.disabled=!1,this.type=Ri.SINGLE,this.required=!1,this.variant=Ii.DEFAULT,this.size=Ai.SMALL,this.selectedItems=[]}get _containerElement(){return this.querySelector("div[part=toggle-group]")}getAttributesToExclude(){return["disabled","type","data-testid"]}connectedCallback(){super.connectedCallback()}firstUpdated(e){super.firstUpdated(e),this.moveLightDomChildrenInto(this._containerElement)}updated(e){(e.has("variant")||e.has("size")||e.has("disabled")||e.has("type"))&&this.querySelectorAll("pont-toggle-group-item").forEach(t=>{t.variant=this.variant,t.size=this.size,t.disabled=this.disabled,t.type=this.type})}createRenderRoot(){return this}render(){const e=this.getFilteredAttributes();return console.log({variant:this.variant,size:this.size,className:this.className}),l`
|
|
2553
2553
|
<div
|
|
2554
2554
|
part="toggle-group"
|
|
2555
2555
|
role="group"
|
|
@@ -2557,7 +2557,7 @@
|
|
|
2557
2557
|
class="${m(l$,this.className)}"
|
|
2558
2558
|
?disable="${this.disabled}"
|
|
2559
2559
|
></div>
|
|
2560
|
-
`}};an([a({type:Boolean})],nr.prototype,"disabled",2);an([a({type:String})],nr.prototype,"type",2);an([a({attribute:!0,type:Boolean,reflect:!0})],nr.prototype,"required",2);an([a()],nr.prototype,"variant",2);an([a()],nr.prototype,"size",2);an([a({type:Array})],nr.prototype,"selectedItems",2);nr=an([p("pont-toggle-group")],nr);var ti=(e=>(e.SMALL="sm",e.MEDIUM="md",e.LARGE="lg",e))(ti||{}),ei=(e=>(e.DEFAULT="default",e.OUTLINE="outline",e))(ei||{});const u$=Rh("pont-inline-flex pont-items-center pont-justify-center pont-rounded-toggle-radius pont-text-toggle-font pont-font-toggle-font-weight pont-transition-colors focus-visible:pont-outline-none focus-visible:pont-ring-toggle-width-ring-focus focus-visible:pont-ring-toggle-color-ring-focus focus-visible:pont-ring-offset-toggle-width-ring-offset-focus disabled:pont-pointer-events-none disabled:pont-opacity-toggle-opacity-disabled data-[state=on]:pont-bg-toggle-color-bg-on data-[state=on]:pont-text-toggle-color-text-on pont-bg-transparent",{variants:{variant:{default:"hover:pont-bg-toggle-default-color-bg-hover hover:pont-text-toggle-default-color-text-hover",outline:"pont-border pont-border-toggle-outline-color-border hover:pont-bg-toggle-outline-color-bg-hover hover:pont-text-toggle-outline-color-text-hover"},size:{sm:"pont-h-toggle-space-h-sm pont-px-toggle-space-px-sm",md:"pont-h-toggle-space-h-md pont-px-toggle-space-px-md",lg:"pont-h-toggle-space-h-lg pont-px-toggle-space-px-lg"}}});var m$=Object.defineProperty,g$=Object.getOwnPropertyDescriptor,Yn=(e,t,r,o)=>{for(var n=o>1?void 0:o?g$(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&m$(t,r,n),n};let or=class extends
|
|
2560
|
+
`}};an([a({type:Boolean})],nr.prototype,"disabled",2);an([a({type:String})],nr.prototype,"type",2);an([a({attribute:!0,type:Boolean,reflect:!0})],nr.prototype,"required",2);an([a()],nr.prototype,"variant",2);an([a()],nr.prototype,"size",2);an([a({type:Array})],nr.prototype,"selectedItems",2);nr=an([p("pont-toggle-group")],nr);var ti=(e=>(e.SMALL="sm",e.MEDIUM="md",e.LARGE="lg",e))(ti||{}),ei=(e=>(e.DEFAULT="default",e.OUTLINE="outline",e))(ei||{});const u$=Rh("pont-inline-flex pont-items-center pont-justify-center pont-rounded-toggle-radius pont-text-toggle-font pont-font-toggle-font-weight pont-transition-colors focus-visible:pont-outline-none focus-visible:pont-ring-toggle-width-ring-focus focus-visible:pont-ring-toggle-color-ring-focus focus-visible:pont-ring-offset-toggle-width-ring-offset-focus disabled:pont-pointer-events-none disabled:pont-opacity-toggle-opacity-disabled data-[state=on]:pont-bg-toggle-color-bg-on data-[state=on]:pont-text-toggle-color-text-on pont-bg-transparent",{variants:{variant:{default:"hover:pont-bg-toggle-default-color-bg-hover hover:pont-text-toggle-default-color-text-hover",outline:"pont-border pont-border-toggle-outline-color-border hover:pont-bg-toggle-outline-color-bg-hover hover:pont-text-toggle-outline-color-text-hover"},size:{sm:"pont-h-toggle-space-h-sm pont-px-toggle-space-px-sm",md:"pont-h-toggle-space-h-md pont-px-toggle-space-px-md",lg:"pont-h-toggle-space-h-lg pont-px-toggle-space-px-lg"}}});var m$=Object.defineProperty,g$=Object.getOwnPropertyDescriptor,Yn=(e,t,r,o)=>{for(var n=o>1?void 0:o?g$(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&m$(t,r,n),n};let or=class extends _{constructor(){super(...arguments),this.disabled=!1,this.checked=!1,this.required=!1,this.variant=ei.DEFAULT,this.size=ti.SMALL}willUpdate(e){e.has("variant")&&(this.variant=this.normalizeEnum(this.variant,ei,ei.DEFAULT)),e.has("size")&&(this.size=this.normalizeEnum(this.size,ti,ti.SMALL))}get _containerElement(){return this.querySelector("button[part=toggle]")}getAttributesToExclude(){return["disabled","checked","variant","size","required","data-testid"]}toggle(){this.disabled||(this.checked=!this.checked)}createRenderRoot(){return this}firstUpdated(e){this.moveLightDomChildrenInto(this._containerElement)}render(){const e=this.getFilteredAttributes();return l`
|
|
2561
2561
|
<button
|
|
2562
2562
|
type="button"
|
|
2563
2563
|
part="toggle"
|
|
@@ -2576,7 +2576,7 @@
|
|
|
2576
2576
|
<h3 data-slot="typography-h" data-level="${this.level}"></h3>
|
|
2577
2577
|
`:this.level==="h4"?l`
|
|
2578
2578
|
<h4 data-slot="typography-h" data-level="${this.level}"></h4>
|
|
2579
|
-
`:l`<h1 data-slot="typography-h" data-level="${this.level}"></h1>`}};Ih([a({type:String})],Ra.prototype,"level",2);Ra=Ih([p("pont-typography-h")],Ra);var $$=Object.getOwnPropertyDescriptor,P$=(e,t,r,o)=>{for(var n=o>1?void 0:o?$$(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let Ec=class extends f{createRenderRoot(){return this}get _largeSlot(){return this.querySelector('[data-slot="typography-large"]')}firstUpdated(){const e=this._largeSlot;if(!e)return;Array.from(this.childNodes).filter(r=>r!==e).forEach(r=>e.appendChild(r))}render(){return l`<div data-slot="typography-large"></div>`}};Ec=P$([p("pont-typography-large")],Ec);var C$=Object.getOwnPropertyDescriptor,E$=(e,t,r,o)=>{for(var n=o>1?void 0:o?C$(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let Sc=class extends f{createRenderRoot(){return this}get _leadSlot(){return this.querySelector('[data-slot="typography-lead"]')}firstUpdated(){const e=this._leadSlot;if(!e)return;Array.from(this.childNodes).filter(r=>r!==e).forEach(r=>e.appendChild(r))}render(){return l`<p data-slot="typography-lead"></p>`}};Sc=E$([p("pont-typography-lead")],Sc);var S$=Object.getOwnPropertyDescriptor,x$=(e,t,r,o)=>{for(var n=o>1?void 0:o?S$(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let xc=class extends f{createRenderRoot(){return this}get _listSlot(){return this.querySelector('[data-slot="typography-list"]')}firstUpdated(){const e=this._listSlot;if(!e)return;Array.from(this.childNodes).filter(r=>r!==e).forEach(r=>e.appendChild(r))}render(){return l`<ul data-slot="typography-list"></ul>`}};xc=x$([p("pont-typography-list")],xc);var O$=Object.getOwnPropertyDescriptor,R$=(e,t,r,o)=>{for(var n=o>1?void 0:o?O$(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let Oc=class extends f{createRenderRoot(){return this}get _mutedSlot(){return this.querySelector('[data-slot="typography-muted"]')}firstUpdated(){const e=this._mutedSlot;if(!e)return;Array.from(this.childNodes).filter(r=>r!==e).forEach(r=>e.appendChild(r))}render(){return l`<p data-slot="typography-muted"></p>`}};Oc=R$([p("pont-typography-muted")],Oc);var I$=Object.getOwnPropertyDescriptor,A$=(e,t,r,o)=>{for(var n=o>1?void 0:o?I$(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let Rc=class extends f{createRenderRoot(){return this}get _pSlot(){return this.querySelector('[data-slot="typography-p"]')}firstUpdated(){const e=this._pSlot;if(!e)return;Array.from(this.childNodes).filter(r=>r!==e).forEach(r=>e.appendChild(r))}render(){return l`<p data-slot="typography-p"></p>`}};Rc=A$([p("pont-typography-p")],Rc);var T$=Object.getOwnPropertyDescriptor,D$=(e,t,r,o)=>{for(var n=o>1?void 0:o?T$(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let Ic=class extends f{createRenderRoot(){return this}get _smallSlot(){return this.querySelector('[data-slot="typography-small"]')}firstUpdated(){const e=this._smallSlot;if(!e)return;Array.from(this.childNodes).filter(r=>r!==e).forEach(r=>e.appendChild(r))}render(){return l`<small data-slot="typography-small"></small>`}};Ic=D$([p("pont-typography-small")],Ic);var L$=Object.getOwnPropertyDescriptor,F$=(e,t,r,o)=>{for(var n=o>1?void 0:o?L$(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let Ac=class extends f{createRenderRoot(){return this}};Ac=F$([p("pont-typography-table")],Ac);var k$=Object.defineProperty,N$=Object.getOwnPropertyDescriptor,ft=(e,t,r,o)=>{for(var n=o>1?void 0:o?N$(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&k$(t,r,n),n};let dt=class extends
|
|
2579
|
+
`:l`<h1 data-slot="typography-h" data-level="${this.level}"></h1>`}};Ih([a({type:String})],Ra.prototype,"level",2);Ra=Ih([p("pont-typography-h")],Ra);var $$=Object.getOwnPropertyDescriptor,P$=(e,t,r,o)=>{for(var n=o>1?void 0:o?$$(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let Ec=class extends f{createRenderRoot(){return this}get _largeSlot(){return this.querySelector('[data-slot="typography-large"]')}firstUpdated(){const e=this._largeSlot;if(!e)return;Array.from(this.childNodes).filter(r=>r!==e).forEach(r=>e.appendChild(r))}render(){return l`<div data-slot="typography-large"></div>`}};Ec=P$([p("pont-typography-large")],Ec);var C$=Object.getOwnPropertyDescriptor,E$=(e,t,r,o)=>{for(var n=o>1?void 0:o?C$(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let Sc=class extends f{createRenderRoot(){return this}get _leadSlot(){return this.querySelector('[data-slot="typography-lead"]')}firstUpdated(){const e=this._leadSlot;if(!e)return;Array.from(this.childNodes).filter(r=>r!==e).forEach(r=>e.appendChild(r))}render(){return l`<p data-slot="typography-lead"></p>`}};Sc=E$([p("pont-typography-lead")],Sc);var S$=Object.getOwnPropertyDescriptor,x$=(e,t,r,o)=>{for(var n=o>1?void 0:o?S$(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let xc=class extends f{createRenderRoot(){return this}get _listSlot(){return this.querySelector('[data-slot="typography-list"]')}firstUpdated(){const e=this._listSlot;if(!e)return;Array.from(this.childNodes).filter(r=>r!==e).forEach(r=>e.appendChild(r))}render(){return l`<ul data-slot="typography-list"></ul>`}};xc=x$([p("pont-typography-list")],xc);var O$=Object.getOwnPropertyDescriptor,R$=(e,t,r,o)=>{for(var n=o>1?void 0:o?O$(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let Oc=class extends f{createRenderRoot(){return this}get _mutedSlot(){return this.querySelector('[data-slot="typography-muted"]')}firstUpdated(){const e=this._mutedSlot;if(!e)return;Array.from(this.childNodes).filter(r=>r!==e).forEach(r=>e.appendChild(r))}render(){return l`<p data-slot="typography-muted"></p>`}};Oc=R$([p("pont-typography-muted")],Oc);var I$=Object.getOwnPropertyDescriptor,A$=(e,t,r,o)=>{for(var n=o>1?void 0:o?I$(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let Rc=class extends f{createRenderRoot(){return this}get _pSlot(){return this.querySelector('[data-slot="typography-p"]')}firstUpdated(){const e=this._pSlot;if(!e)return;Array.from(this.childNodes).filter(r=>r!==e).forEach(r=>e.appendChild(r))}render(){return l`<p data-slot="typography-p"></p>`}};Rc=A$([p("pont-typography-p")],Rc);var T$=Object.getOwnPropertyDescriptor,D$=(e,t,r,o)=>{for(var n=o>1?void 0:o?T$(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let Ic=class extends f{createRenderRoot(){return this}get _smallSlot(){return this.querySelector('[data-slot="typography-small"]')}firstUpdated(){const e=this._smallSlot;if(!e)return;Array.from(this.childNodes).filter(r=>r!==e).forEach(r=>e.appendChild(r))}render(){return l`<small data-slot="typography-small"></small>`}};Ic=D$([p("pont-typography-small")],Ic);var L$=Object.getOwnPropertyDescriptor,F$=(e,t,r,o)=>{for(var n=o>1?void 0:o?L$(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(n)||n);return n};let Ac=class extends f{createRenderRoot(){return this}};Ac=F$([p("pont-typography-table")],Ac);var k$=Object.defineProperty,N$=Object.getOwnPropertyDescriptor,ft=(e,t,r,o)=>{for(var n=o>1?void 0:o?N$(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&k$(t,r,n),n};let dt=class extends _{constructor(){super(...arguments),this.placeholder="Filter emails...",this.dataTable=[],this.hasDefaultSelect=!0,this.hasDefaultPagination=!0,this.hasDefaultSearch=!0,this.checkedRows={},this.searchTerm="",this.columnVisibility={},this.sortColumn=null,this.sortDirection="asc",this.cellRenderers={},this.rowActions=[],this.paginationLabels=["Previous","Next"],this.pageSize=5,this.currentPage=1,this.sortableColumns=["email"],this.columnOrder=[]}get _chevronDownIcon(){return l`
|
|
2580
2580
|
<svg
|
|
2581
2581
|
xmlns="http://www.w3.org/2000/svg"
|
|
2582
2582
|
width="24"
|
|
@@ -2761,7 +2761,7 @@
|
|
|
2761
2761
|
</div>
|
|
2762
2762
|
${this.hasDefaultPagination&&this.hasDefaultSelect?this._renderPagination():h}
|
|
2763
2763
|
</div>
|
|
2764
|
-
`}};ft([a({type:String})],dt.prototype,"placeholder",2);ft([a({type:Array})],dt.prototype,"dataTable",2);ft([a({type:Boolean})],dt.prototype,"hasDefaultSelect",2);ft([a({type:Boolean})],dt.prototype,"hasDefaultPagination",2);ft([a({type:Boolean})],dt.prototype,"hasDefaultSearch",2);ft([a({type:Object})],dt.prototype,"checkedRows",2);ft([a({type:String})],dt.prototype,"searchTerm",2);ft([a({type:Object})],dt.prototype,"columnVisibility",2);ft([a({type:String})],dt.prototype,"sortColumn",2);ft([a({type:String})],dt.prototype,"sortDirection",2);ft([a({type:Object})],dt.prototype,"cellRenderers",2);ft([a({type:Object})],dt.prototype,"headerRenderers",2);ft([a({type:Array})],dt.prototype,"rowActions",2);ft([a({type:Array})],dt.prototype,"paginationLabels",2);ft([a({type:Number})],dt.prototype,"pageSize",2);ft([a({type:Number})],dt.prototype,"currentPage",2);ft([a({type:Array})],dt.prototype,"sortableColumns",2);ft([a({type:Array})],dt.prototype,"columnOrder",2);ft([a({type:Function})],dt.prototype,"isRowDisabled",2);dt=ft([p("pont-data-table")],dt);var H=class extends Error{constructor(t,r,o,n){super(r);E(this,"code");E(this,"details");E(this,"status");this.name="LoginflowError",this.code=t,this.details=o,this.status=n}};function Ah(e){const t=(e??"").trim();if(!t)throw new H("CONFIG_ERROR","domain is required");if(t.startsWith("/")){if(typeof location>"u")throw new H("CONFIG_ERROR",`domain "${t}" is relative to the page origin, and there is no page here`);return Tc(new URL(t,location.origin))}const r=/^https?:\/\//i.test(t)?"":`${B$(M$(t))?"http":"https"}://`;try{return Tc(new URL(`${r}${t}`))}catch{throw new H("CONFIG_ERROR",`domain "${t}" is not a hostname, an origin, or a path`)}}function Tc(e){return`${e.origin}${e.pathname}`.replace(/\/+$/,"")}function M$(e){return e.split("/")[0]}function B$(e){return/^(localhost|127\.0\.0\.1|\[::1\])(:\d+)?$/i.test(e)}var Ce,U$=(Ce=class{constructor(){E(this,"data",new Map)}static get Instance(){return Ce.instance||(Ce.instance=new Ce),Ce.instance}get(t){return this.data.get(t)}set(t,r){this.data.set(t,r)}setConfig(t){this.data.set("config",t)}getConfig(){return this.data.get("config")}getApiBaseUrl(){return Ah(this.getConfig().domain)}apiIsSameOrigin(){if(typeof location>"u")return!1;try{return new URL(this.getApiBaseUrl()).host===location.host}catch{return!1}}remove(t){this.data.delete(t)}clear(){this.data.clear()}},E(Ce,"instance"),Ce),G=U$.Instance,Ee,ho=(Ee=class{constructor(){}static get Instance(){return Ee.instance||(Ee.instance=new Ee),Ee.instance}async request(t,r={}){const o=G.getConfig(),n=`${G.getApiBaseUrl()}${t}`,i=5e4,s=new AbortController,d=setTimeout(()=>s.abort(),i);try{const c=await fetch(n,{...r,signal:s.signal,headers:{"Content-Type":"application/json",...o.headers,...r.headers}});if(clearTimeout(d),!c.ok){const u=await c.json().catch(()=>({}));throw new H(u.code||u.error||"API_ERROR",u.message||u.error_description||`HTTP ${c.status}: ${c.statusText}`,u.details,c.status)}return await c.json()}catch(c){throw clearTimeout(d),c instanceof H?c:c instanceof Error?c.name==="AbortError"?new H("TIMEOUT","Request timeout"):new H("NETWORK_ERROR",c.message):new H("UNKNOWN_ERROR","An unknown error occurred")}}async post(t,r){return this.request(t,{credentials:"include",method:"POST",body:r?JSON.stringify(r):void 0})}async get(t){return this.request(t,{credentials:"include",method:"GET"})}async getOptional(t){const r=G.getConfig(),o=await fetch(`${G.getApiBaseUrl()}${t}`,{credentials:"include",method:"GET",headers:{...r.headers}});if(o.status===204)return null;if(!o.ok)throw new H("API_ERROR",`HTTP ${o.status}: ${o.statusText}`,void 0,o.status);return await o.json()}async postForm(t,r){return this.request(t,{credentials:"include",method:"POST",headers:{"Content-Type":"application/x-www-form-urlencoded"},body:new URLSearchParams(r).toString()})}},E(Ee,"instance"),Ee),Th="__Secure-pontive_session_state",ms="__Secure-pontive_session_probe";function q$(){return Dh(Th)?"present":j$()?"absent":"unknown"}function Ia(){if(!(typeof document>"u"||typeof location>"u"))for(const e of["",...H$(location.hostname)])Aa(Th,"",e,0)}function j$(){if(typeof document>"u"||typeof location>"u")return!1;const e=V$();try{Aa(ms,"1",e,60);const t=Dh(ms)==="1";return Aa(ms,"",e,0),t&&z$(e)}catch{return!1}}function z$(e){return e!==""||G.apiIsSameOrigin()}function V$(){let e;try{e=new URL(G.getApiBaseUrl()).hostname}catch{return""}const t=location.hostname;if(!e||!t||e.toLowerCase()===t.toLowerCase())return"";const r=t.split("."),o=e.split(".");let n=0;for(;n<r.length&&n<o.length&&r[r.length-1-n].toLowerCase()===o[o.length-1-n].toLowerCase();)n+=1;return n<2?"":o.slice(o.length-n).join(".")}function H$(e){const t=e.split("."),r=[];for(let o=1;o+2<=t.length;o+=1)r.push(t.slice(o).join("."));return r}function Aa(e,t,r,o){const n=G$()?"; Secure":"",i=r?`; Domain=${r}`:"";document.cookie=`${e}=${t}; Path=/; Max-Age=${o}; SameSite=Lax${i}${n}`}function G$(){return typeof globalThis.isSecureContext=="boolean"?globalThis.isSecureContext:location.protocol==="https:"}function Dh(e){if(typeof document>"u"||!document.cookie)return null;for(const t of document.cookie.split(";")){const r=t.indexOf("=");if(!(r<0)&&t.slice(0,r).trim()===e)return t.slice(r+1).trim()||null}return null}var Et,Ot=(Et=class{constructor(){E(this,"AUTH_SESSION_STORAGE_KEY","pontive_auth_session");E(this,"memorySession",null);E(this,"refreshTimeoutId",null);E(this,"refreshPromise",null);E(this,"refreshRetryCount",0);E(this,"refreshBlockedUntil",0);E(this,"sessionGeneration",0);E(this,"channel",null);E(this,"channelName","");E(this,"applyingBroadcast",!1);E(this,"restorePromise",null)}static get Instance(){return Et.instance||(Et.instance=new Et),Et.instance}setCurrentSession(t){this.sessionGeneration+=1,this.write(JSON.stringify(t)),this.publish({type:"session",session:t})}async withRefreshLock(t){const r=typeof navigator<"u"?navigator.locks:void 0;return r?r.request(this.channelKey("refresh"),t):t()}channelKey(t){const r=G.getConfig();return`pontive-${t}:${(r==null?void 0:r.domain)??""}:${(r==null?void 0:r.appId)??""}`}ensureChannel(){var r;if(typeof BroadcastChannel>"u")return null;const t=this.channelKey("session");return this.channel&&this.channelName===t?this.channel:((r=this.channel)==null||r.close(),this.channelName=t,this.channel=new BroadcastChannel(t),this.channel.onmessage=o=>this.receive(o.data),this.channel)}publish(t){var r;this.applyingBroadcast||(r=this.ensureChannel())==null||r.postMessage(t)}receive(t){this.applyingBroadcast=!0;try{if(t.type==="cleared"){this.clearSession();return}this.setCurrentSession(t.session),this.scheduleTokenRefresh()}finally{this.applyingBroadcast=!1}}isCurrentGeneration(t){return this.sessionGeneration===t}getCurrentSession(){const t=this.getStoredSession();return t?this.isSessionExpired(t)?(this.clearSession(),null):(this.shouldRefreshToken(t)&&this.triggerBackgroundRefresh(t),t):null}peekSession(){return this.getStoredSession()}isAuthenticated(){return this.getCurrentSession()!==null}getAuthenticatedUser(){const t=this.getCurrentSession();if(!t)return null;const r=t.id_token?this.decodeJWT(t.id_token):null;return r||(t.user??null)}cleanup(){var t;this.refreshTimeoutId&&(clearTimeout(this.refreshTimeoutId),this.refreshTimeoutId=null),this.refreshPromise=null,(t=this.channel)==null||t.close(),this.channel=null,this.channelName=""}clearSession(){this.sessionGeneration+=1,this.memorySession=null,localStorage.removeItem(this.AUTH_SESSION_STORAGE_KEY),this.refreshTimeoutId&&(clearTimeout(this.refreshTimeoutId),this.refreshTimeoutId=null),this.refreshRetryCount=0,this.refreshBlockedUntil=0,this.publish({type:"cleared"})}isSessionExpired(t){return!t||!t.expires_at?!0:Date.now()>=t.expires_at}cleanExpiredSession(){const t=this.getStoredSession();t&&this.isSessionExpired(t)&&this.clearSession()}getStoredSession(){const t=this.read();if(!t)return null;try{return JSON.parse(t)}catch{return this.clearSession(),null}}write(t){this.memorySession=t,localStorage.removeItem(this.AUTH_SESSION_STORAGE_KEY)}read(){return this.memorySession}decodeJWT(t){try{const o=t.split(".")[1].replace(/-/g,"+").replace(/_/g,"/"),n=decodeURIComponent(atob(o).split("").map(i=>"%"+("00"+i.charCodeAt(0).toString(16)).slice(-2)).join(""));return JSON.parse(n)}catch{return null}}shouldRefreshToken(t){if(!t||!t.expires_at)return!1;const r=Date.now(),o=t.expires_at,n=t.expires_in||3600,i=r+n*1e3*.2;return o<=i}scheduleTokenRefresh(){this.refreshTimeoutId&&(clearTimeout(this.refreshTimeoutId),this.refreshTimeoutId=null);const t=this.getCurrentSession();if(!t||!t.expires_at)return;const r=Date.now(),o=t.expires_at,n=t.expires_in||3600,i=o-r-n*1e3*.2;i>0&&(this.refreshTimeoutId=setTimeout(()=>{this.triggerBackgroundRefresh(t)},i))}triggerBackgroundRefresh(t){this.refreshPromise||Date.now()<this.refreshBlockedUntil||(this.refreshPromise=this.withRefreshLock(()=>{const r=this.getStoredSession();return r&&!this.shouldRefreshToken(r)?(this.scheduleTokenRefresh(),Promise.resolve(null)):this.refreshTokens(r??t)}).then(r=>(r&&(this.setCurrentSession(r),this.refreshRetryCount=0,this.refreshBlockedUntil=0,this.scheduleTokenRefresh()),r)).catch(r=>(console.error("Background token refresh failed:",r),null)).finally(()=>{this.refreshPromise=null}))}async switchOrganization(t){if(!t)throw new H("INVALID_REQUEST","organizationId is required");return this.withRefreshLock(async()=>{const r=this.sessionGeneration,o=this.getCurrentSession(),n=await this.requestTokens(o,{organization_id:t});if(!this.isCurrentGeneration(r))throw new H("SESSION_CHANGED","the session changed while switching organization");return this.setCurrentSession(n),this.scheduleTokenRefresh(),n})}getOrganization(){const t=this.getCurrentSession(),r=t!=null&&t.access_token?this.decodeJWT(t.access_token):null,o=r==null?void 0:r.org_id;if(typeof o!="string"||o==="")return null;const n=i=>Array.isArray(i)?i.filter(s=>typeof s=="string"):[];return{id:o,roles:n(r==null?void 0:r.roles),permissions:n(r==null?void 0:r.permissions)}}async refreshTokens(t){const r=this.sessionGeneration;try{const o=await this.requestTokens(t);return this.isCurrentGeneration(r)?o:(console.warn("Token refresh returned after the session changed; discarding it"),null)}catch(o){return this.isCurrentGeneration(r)?K$(o)?(console.error("Token refresh rejected, signing out:",oo(o)),Ia(),this.clearSession(),null):(console.warn("Token refresh failed, keeping session and retrying:",oo(o)),this.scheduleRefreshRetry(t),null):(console.warn("Token refresh failed after the session changed; ignoring:",oo(o)),null)}}async fetchUserInfo(t){try{return await ho.Instance.request("/oauth2/userinfo",{method:"GET",credentials:"include",headers:{Authorization:`Bearer ${t}`}})}catch(r){return console.debug("Could not read user info for the restored session:",oo(r)),null}}async requestTokens(t,r={}){var i;const o={...r,grant_type:"refresh_token",client_id:(i=G.getConfig())==null?void 0:i.appId};t!=null&&t.refresh_token&&(o.refresh_token=t.refresh_token);const n=await ho.Instance.postForm("/oauth2/token",o);return{id_token:n.id_token??(t==null?void 0:t.id_token)??"",access_token:n.access_token,refresh_token:n.refresh_token??(t==null?void 0:t.refresh_token),expires_in:n.expires_in,expires_at:Date.now()+n.expires_in*1e3}}async readCurrentToken(){var r;const t=(r=G.getConfig())==null?void 0:r.appId;if(!t)return null;try{const o=await ho.Instance.getOptional(`/oauth2/session/token?client_id=${encodeURIComponent(t)}`);return!(o!=null&&o.access_token)||!(o.expires_in>0)?null:{id_token:"",access_token:o.access_token,expires_in:o.expires_in,expires_at:Date.now()+o.expires_in*1e3}}catch{return null}}async restoreSession(){const t=this.getStoredSession();return t&&!this.isSessionExpired(t)?t:q$()==="absent"?null:this.restorePromise?this.restorePromise:(this.restorePromise=this.withRefreshLock(async()=>{const r=this.getStoredSession();if(r&&!this.isSessionExpired(r))return r;try{const o=await this.readCurrentToken()??await this.requestTokens(null);return o.id_token||(o.user=await this.fetchUserInfo(o.access_token)??void 0),this.setCurrentSession(o),this.scheduleTokenRefresh(),o}catch(o){return Y$(o)&&Ia(),console.debug("No session to restore:",oo(o)),null}}).finally(()=>{this.restorePromise=null}),this.restorePromise)}scheduleRefreshRetry(t){if(this.refreshTimeoutId&&(clearTimeout(this.refreshTimeoutId),this.refreshTimeoutId=null),this.refreshRetryCount>=Et.MAX_REFRESH_RETRIES){console.warn("Token refresh gave up after",this.refreshRetryCount,"attempts"),this.refreshRetryCount=0,this.refreshBlockedUntil=0;return}const r=Math.min(Et.REFRESH_RETRY_BASE_MS*2**this.refreshRetryCount,Et.MAX_REFRESH_RETRY_DELAY_MS);this.refreshRetryCount+=1,this.refreshBlockedUntil=Date.now()+r,this.refreshTimeoutId=setTimeout(()=>{this.refreshBlockedUntil=0,this.triggerBackgroundRefresh(t)},r)}},E(Et,"MAX_REFRESH_RETRIES",5),E(Et,"REFRESH_RETRY_BASE_MS",5e3),E(Et,"MAX_REFRESH_RETRY_DELAY_MS",6e4),E(Et,"instance"),Et);function K$(e){return!(e instanceof H)||e.status===void 0?!1:e.status===401?!0:e.status===400&&W$.has(e.code)}var W$=new Set(["invalid_grant","invalid_client"]);function Y$(e){return e instanceof H&&e.status!==void 0&&e.status>=400&&e.status<500}function oo(e){return e instanceof H?`${e.code} (status ${e.status??"none"}): ${e.message}`:String(e)}var Lh=class{constructor(e=sessionStorage){E(this,"storage");E(this,"FLOW_STATE_KEY","pontive_loginflow_state");E(this,"FLOW_EXPIRY_MS",540*1e3);this.storage=e}getFlowState(){const e=this.storage.getItem(this.FLOW_STATE_KEY);if(!e)return null;try{const t=JSON.parse(e);return this.isExpired(t)?(this.clearFlowState(),null):t}catch{return this.clearFlowState(),null}}saveFlowState(e,t,r){const o=Date.now(),n=this.getFlowState(),i={flowType:e,flow_id:t,state:r.state,startedAt:(n==null?void 0:n.startedAt)||o,lastUpdatedAt:o,render_spec:r.render_spec};this.storage.setItem(this.FLOW_STATE_KEY,JSON.stringify(i))}restoreFromHistory(e){const t={flowType:e.flowType,flow_id:e.flow_id,state:e.state,startedAt:e.timestamp,lastUpdatedAt:e.timestamp,render_spec:void 0};this.storage.setItem(this.FLOW_STATE_KEY,JSON.stringify(t))}clearFlowState(){this.storage.removeItem(this.FLOW_STATE_KEY)}isExpired(e){return Date.now()-e.lastUpdatedAt>this.FLOW_EXPIRY_MS}get expiryMs(){return this.FLOW_EXPIRY_MS}},gr,Ti=(gr=class{static detect(t,r=window.location){if(gr.hasInviteToken(r))return"invitation";const o=r.pathname.toLowerCase();return t.invitationUrl&&o.includes(t.invitationUrl)?"invitation":o.includes(t.signinUrl)?"signin":o.includes(t.signupUrl)?"signup":"custom"}static hasInviteToken(t){try{return new URLSearchParams(t.search).has(gr.INVITE_TOKEN_PARAM)}catch{return!1}}},E(gr,"INVITE_TOKEN_PARAM","invite_token"),gr),Fh=class{constructor(){E(this,"listeners",new Map)}on(e,t){this.listeners.has(e)||this.listeners.set(e,new Set),this.listeners.get(e).add(t)}off(e,t){var r;(r=this.listeners.get(e))==null||r.delete(t)}emit(e,t){const r=this.listeners.get(e);r&&r.forEach(o=>{try{o(t)}catch(n){console.error(`[FlowEventBus] Error in event handler for ${e}:`,n)}})}clear(){this.listeners.clear()}clearEvent(e){this.listeners.delete(e)}},Q$=class{getNavigationType(){const e=performance.getEntriesByType("navigation");if(e.length>0)return e[0].type;const t=performance.navigation;if(t)switch(t.type){case 1:return"reload";case 2:return"back_forward";default:return"navigate"}return"navigate"}},Ht,Z$=(Ht=class{constructor(t,r,o=window.location,n,i){E(this,"httpClient",ho.Instance);E(this,"flowId");E(this,"redirectTimeoutId",null);E(this,"flowStateManager");E(this,"flowEventBus");E(this,"location");E(this,"navigationTypeDetector");E(this,"eventHandlers",new Map([["switch_to_signin",this.handleSwitchToSignin.bind(this)],["switch_to_signup",this.handleSwitchToSignup.bind(this)],["continue_here",this.handleContinueHere.bind(this)]]));E(this,"linkWatchTimer",null);E(this,"linkWatchGeneration",0);E(this,"waitingForLink",!1);const s=G.getConfig();if(!s.domain)throw new H("CONFIG_ERROR","Domain is required");if(!s.appId)throw new H("CONFIG_ERROR","App ID is required");this.flowId=t,this.location=o,this.flowStateManager=n||new Lh,this.flowEventBus=r||new Fh,this.navigationTypeDetector=i||new Q$,Ot.Instance.cleanExpiredSession(),Ot.Instance.scheduleTokenRefresh()}static async init(t,r,o,n,i){const s=new Ht(t,r,o,n,i),d=await s.initializeFlowInternal();return{sdk:s,flowType:d.flowType,isResumed:d.isResumed,state:d.state,render_spec:d.render_spec,auth_result:d.auth_result}}async startFlow(t,r){if(!r.app_id)throw new H("VALIDATION_ERROR","Client ID is required");const o=`/auth/v1/authflows/${t}/start`;return this.executeFlowRequest(()=>this.httpClient.post(o,r),"START_FLOW_ERROR","Failed to start flow")}async resumeFlow(t,r){const o=r?`?continue=${encodeURIComponent(r)}`:"",n=`/auth/v1/authflows/${t}/resume${o}`;return this.executeFlowRequest(()=>this.httpClient.post(n),"RESUME_FLOW_ERROR","Failed to resume flow")}async processEvent(t,r){if(!t.event)throw new H("VALIDATION_ERROR","Event type is required");const o=this.eventHandlers.get(t.event);return o?await o():await this.processServerEvent(t,r)}async executeFlowRequest(t,r,o,n){try{const i=await t();return n&&await n(i),this.processAuthResult(i.auth_result),i.redirection&&this.redirect(i.redirection),i}catch(i){throw i instanceof H?i:new H(r,o,i instanceof Error?{originalError:i.message,stack:i.stack}:i)}}async processServerEvent(t,r){let o=this.flowStateManager.getFlowState();if(!o&&(console.warn("Flow state expired, restarting flow before processing event"),await this.initializeFlowInternal(),o=this.flowStateManager.getFlowState(),!o))throw new H("FLOW_RESTART_ERROR","Failed to restart flow - no flow state after initialization");const n=o.state,i=`/auth/v1/authflows/${o.flowType}/events`,s=this.waitingForLink;this.stopWatchingForLink();let d;try{d=await this.executeFlowRequest(()=>this.httpClient.post(i,t),"PROCESS_EVENT_ERROR","Failed to process event",r)}catch(c){if(s&&Ht.flowIsGone(c))return this.announceContinuedElsewhere(o.flowType,""),{state:""};throw c}if(this.watchForLink(o.flowType,d),!d.auth_result){this.flowStateManager.saveFlowState(o.flowType,o.flow_id,d);const c=this.flowStateManager.getFlowState();if(c){const u=n!==d.state;this.flowEventBus.emit("flow:updated",{flowState:c,isNewStep:u})}}return d}processAuthResult(t){if(t){const r={id_token:t.id_token,access_token:t.access_token,refresh_token:t.refresh_token,expires_in:t.expires_in,expires_at:Date.now()+t.expires_in*1e3};Ot.Instance.setCurrentSession(r),Ot.Instance.scheduleTokenRefresh(),this.flowStateManager.clearFlowState();const{onAuthenticated:o}=G.getConfig();if(o){o(r);return}console.warn("pontive: signed in, but no onAuthenticated was supplied, so the SDK cannot route the user. Supply onAuthenticated to handle the handoff.")}}async initializeFlowInternal(){const t=G.getConfig(),r=Ti.detect(t,this.location);this.validateFlowType(r);const o=this.flowStateManager.getFlowState();return this.shouldResumeFlow(o,r)?await this.resumeExistingFlow(o,r):await this.startNewFlow(r)}validateFlowType(t){if(t==="custom"&&!this.flowId)throw new H("FLOW_ID_ERROR","Flow ID is required for custom flows")}shouldResumeFlow(t,r){const n=new URLSearchParams(this.location.search).get("resume")==="true";if(!t)return n;const i=this.navigationTypeDetector.getNavigationType();if(i==="navigate"&&!n)return this.flowStateManager.clearFlowState(),console.log(`Fresh navigation detected (type: ${i}), starting new flow`),!1;if(t.flowType!==r)return this.flowStateManager.clearFlowState(),console.log(`Flow type changed from ${t.flowType} to ${r}, starting new flow, flow_id: ${this.flowId}`),!1;if(r==="custom"&&t.flow_id!==this.flowId)return this.flowStateManager.clearFlowState(),console.log(`Custom flow ID changed, starting new flow, flow_id: ${this.flowId}`),!1;const s=n?"explicit resume=true":`navigation type: ${i}`;return console.log(`Resuming existing flow (${s})`),!0}async resumeExistingFlow(t,r){try{const o=await this.resumeFlow(r,this.continueParam());if(this.watchForLink(r,o),!o.auth_result){this.flowStateManager.saveFlowState(r,(t==null?void 0:t.flow_id)??this.determineFlowId(r),o);const n=this.flowStateManager.getFlowState();n&&this.flowEventBus.emit("flow:resumed",{flowState:n})}return{flowType:r,isResumed:!0,state:o.state,render_spec:o.render_spec,auth_result:o.auth_result}}catch(o){return this.flowStateManager.clearFlowState(),console.warn("Failed to resume flow, starting fresh:",o),await this.startNewFlow(r)}}async startNewFlow(t){const r=G.getConfig(),o=new URLSearchParams(this.location.search),n={};o.forEach((c,u)=>{n[u]=c}),r.organizationId&&!n.organization_id&&(n.organization_id=r.organizationId),console.log("metadata",n);const i=o.get("locales")||r.locales||void 0,s={app_id:r.appId,origin_url:this.location.href,signin_url:r.signinUrl,signup_url:r.signupUrl,locales:i,flow_id:this.determineFlowId(t),metadata:n,auth_base_url:G.getApiBaseUrl()},d=await this.startFlow(t,s);if(this.watchForLink(t,d),!d.auth_result){this.flowStateManager.saveFlowState(t,s.flow_id,d);const c=this.flowStateManager.getFlowState();c&&this.flowEventBus.emit("flow:started",{flowState:c})}return{flowType:t,isResumed:!1,state:d.state,render_spec:d.render_spec,auth_result:d.auth_result}}determineFlowId(t){switch(t){case"signin":return this.flowId||"signin-flow";case"signup":return this.flowId||"signup-flow";case"invitation":return this.flowId||"invitation-flow";case"custom":if(!this.flowId)throw new H("FLOW_ID_ERROR","Flow ID is required for custom flows");return this.flowId}}continueParam(){const t=new URLSearchParams(this.location.search);if(t.get("resume")==="true")return t.get("continue")??void 0}watchForLink(t,r){if(this.stopWatchingForLink(),this.waitingForLink=r.waiting_for_link===!0,!this.waitingForLink)return;const o=this.linkWatchGeneration,n=Date.now()+Ht.LINK_POLL_LIMIT_MS,i=()=>{this.linkWatchTimer=setTimeout(s,Ht.LINK_POLL_INTERVAL_MS)},s=async()=>{if(o!==this.linkWatchGeneration||Date.now()>n)return;if(typeof document<"u"&&document.hidden){i();return}let d;try{d=await this.httpClient.post(`/auth/v1/authflows/${t}/resume`)}catch(c){o===this.linkWatchGeneration&&Ht.flowIsGone(c)&&this.announceContinuedElsewhere(t,"");return}if(o===this.linkWatchGeneration){if(d.waiting_for_link){i();return}this.announceContinuedElsewhere(t,d.state)}};i()}announceContinuedElsewhere(t,r){var o,n;this.stopWatchingForLink(),this.flowStateManager.clearFlowState(),(n=(o=G.getConfig()).onFlowStateChange)==null||n.call(o,{eventType:"flow_continued_elsewhere",flowType:t,state:r})}static flowIsGone(t){return t instanceof H&&t.status===401}stopWatchingForLink(){this.waitingForLink=!1,this.linkWatchGeneration++,this.linkWatchTimer!==null&&(clearTimeout(this.linkWatchTimer),this.linkWatchTimer=null)}async handleContinueHere(){const{continueHereUrl:t}=G.getConfig();this.flowStateManager.clearFlowState();let r=t;if(!r){const o=new URL(this.location.href);o.searchParams.delete("resume"),o.searchParams.delete("continue"),r=o.toString()}return this.redirect({url:r,redirect_delay:0}),{state:"End"}}async handleSwitchToSignin(){const t=G.getConfig();return this.redirect({url:this.withCurrentQuery(t.signinUrl),redirect_delay:0}),{state:"End"}}async handleSwitchToSignup(){const t=G.getConfig();return this.redirect({url:this.withCurrentQuery(t.signupUrl),redirect_delay:0}),{state:"End"}}withCurrentQuery(t){const r=this.location.search;return!r||r==="?"?t:t.includes("?")?`${t}&${r.slice(1)}`:`${t}${r}`}redirect(t){t.url&&(this.redirectTimeoutId!==null&&(console.log("Clearing existing redirect timeout before scheduling new redirect to:",t.url),clearTimeout(this.redirectTimeoutId),this.redirectTimeoutId=null),this.redirectTimeoutId=setTimeout(()=>{this.location.href=t.url},t.redirect_delay*1e3))}reloadPage(){setTimeout(()=>{this.location.reload()},0)}getEventBus(){return this.flowEventBus}cleanup(){this.stopWatchingForLink(),this.redirectTimeoutId&&(clearTimeout(this.redirectTimeoutId),this.redirectTimeoutId=null),this.flowEventBus.clear()}},E(Ht,"LINK_POLL_INTERVAL_MS",3e3),E(Ht,"LINK_POLL_LIMIT_MS",900*1e3),Ht),J$=class{constructor(e){E(this,"delayMs");E(this,"timerId",null);this.delayMs=e}debounce(e){this.timerId&&clearTimeout(this.timerId),this.timerId=setTimeout(()=>{e(),this.timerId=null},this.delayMs)}cancel(){this.timerId&&(clearTimeout(this.timerId),this.timerId=null)}isPending(){return this.timerId!==null}},X$=class{pushState(e,t,r){history.pushState(e,t,r)}replaceState(e,t,r){history.replaceState(e,t,r)}get state(){return history.state}},tP=class{constructor(e,t,r=!1,o=window.location,n,i){E(this,"popstateListener",null);E(this,"pageshowListener",null);E(this,"debouncer");E(this,"isProcessing",!1);E(this,"isHandlingNavigationEvent",!1);E(this,"onFlowRestartNeeded",null);E(this,"skipHistoryTracking");E(this,"flowStateManager");E(this,"historyAdapter");E(this,"location");this.onFlowRestartNeeded=t,this.skipHistoryTracking=r,this.debouncer=new J$(200),this.location=o,this.flowStateManager=n||new Lh,this.historyAdapter=i||new X$,this.subscribeToFlowEvents(e),this.initializeListener()}subscribeToFlowEvents(e){e.on("flow:started",this.handleFlowStart.bind(this)),e.on("flow:updated",this.handleFlowUpdate.bind(this)),e.on("flow:resumed",this.handleFlowResume.bind(this))}initializeListener(){this.popstateListener=e=>{console.log("[NavigationManager] popstate event received"),this.debouncer.debounce(()=>{console.log("[NavigationManager] Debounce timeout fired, handling popstate"),this.handlePopState(e)})},this.pageshowListener=e=>{e.persisted&&(console.log("[NavigationManager] Page restored from bfcache"),this.debouncer.debounce(()=>{console.log("[NavigationManager] Handling bfcache restoration"),this.handleBfcacheRestoration()}))},window.addEventListener("popstate",this.popstateListener),window.addEventListener("pageshow",this.pageshowListener)}async handlePopState(e){if(this.isProcessing){console.log("[NavigationManager] Already processing popstate, skipping");return}console.log("[NavigationManager] Starting popstate processing"),this.isProcessing=!0,this.isHandlingNavigationEvent=!0;try{const t=e.state,r=this.flowStateManager.getFlowState(),o=G.getConfig(),n=Ti.detect(o,this.location);if(t&&this.restoreHistoryStateToSession(t),this.shouldRestartFlow(t,r,n)){await this.triggerFlowRestart();return}console.log("[NavigationManager] Valid state restored from history")}finally{this.isProcessing=!1,this.isHandlingNavigationEvent=!1}}async handleBfcacheRestoration(){if(this.isProcessing){console.log("[NavigationManager] Already processing bfcache restoration, skipping");return}console.log("[NavigationManager] Starting bfcache restoration processing"),this.isProcessing=!0,this.isHandlingNavigationEvent=!0;try{const e=this.historyAdapter.state,t=this.flowStateManager.getFlowState(),r=G.getConfig(),o=Ti.detect(r,this.location);if(e&&this.restoreHistoryStateToSession(e),this.shouldRestartFlow(e,t,o)){await this.triggerFlowRestart();return}console.log("[NavigationManager] Valid state restored from bfcache")}finally{this.isProcessing=!1,this.isHandlingNavigationEvent=!1}}restoreHistoryStateToSession(e){console.log("[NavigationManager] Restoring history state to session storage:",e),this.flowStateManager.restoreFromHistory(e)}shouldRestartFlow(e,t,r){return e&&e.flowType!==r?(console.log("[NavigationManager] Flow type changed via navigation:",e.flowType,"→",r),this.flowStateManager.clearFlowState(),!0):e?Date.now()-e.timestamp>this.flowStateManager.expiryMs?(console.log("[NavigationManager] History state expired, clearing and restarting flow"),this.flowStateManager.clearFlowState(),!0):(console.log("[NavigationManager] Valid history state restored, triggering restart to resume flow"),!0):(console.log("[NavigationManager] No history state, skipping"),!1)}async triggerFlowRestart(){this.onFlowRestartNeeded&&await this.onFlowRestartNeeded()}createHistoryState(e){return{flowType:e.flowType,flow_id:e.flow_id,state:e.state,timestamp:Date.now()}}updateBrowserHistory(e,t){if(this.skipHistoryTracking){console.log("[NavigationManager] Skipping history tracking (created from navigation)");return}const r=this.createHistoryState(e);try{t==="push"?(this.historyAdapter.pushState(r,"",this.location.href),console.log("[NavigationManager] Pushed state to history")):(this.historyAdapter.replaceState(r,"",this.location.href),console.log("[NavigationManager] Replaced state in history"))}catch(o){console.error("[NavigationManager] Failed to update history:",o)}}handleFlowStart(e){this.updateBrowserHistory(e.flowState,"replace")}handleFlowUpdate(e){const t=this.isHandlingNavigationEvent||!e.isNewStep?"replace":"push";this.updateBrowserHistory(e.flowState,t)}handleFlowResume(e){this.updateBrowserHistory(e.flowState,"replace")}destroy(){this.debouncer.cancel(),this.popstateListener&&(window.removeEventListener("popstate",this.popstateListener),this.popstateListener=null),this.pageshowListener&&(window.removeEventListener("pageshow",this.pageshowListener),this.pageshowListener=null),this.onFlowRestartNeeded=null}},Dr=new AbortController,eP=class{constructor(){E(this,"httpClient",ho.Instance);E(this,"capabilities",{webauthn:!1});E(this,"capabilitiesDetected",!1)}async detectCapabilities(){if(!this.capabilitiesDetected)try{if(typeof window.PublicKeyCredential=="function"?this.capabilities.webauthn=!0:this.capabilities.webauthn=!1,typeof PublicKeyCredential.getClientCapabilities=="function"){const e=await PublicKeyCredential.getClientCapabilities();this.capabilities={...this.capabilities,...e};return}typeof PublicKeyCredential.isUserVerifyingPlatformAuthenticatorAvailable=="function"&&(this.capabilities.userVerifyingPlatformAuthenticator=await PublicKeyCredential.isUserVerifyingPlatformAuthenticatorAvailable()),(PublicKeyCredential==null?void 0:PublicKeyCredential.isConditionalMediationAvailable)!==void 0&&typeof PublicKeyCredential.isConditionalMediationAvailable=="function"?this.capabilities.conditionalGet=await PublicKeyCredential.isConditionalMediationAvailable():this.capabilities.conditionalGet=!1}finally{this.capabilitiesDetected=!0}}async fetchPublicKeyCredentialRequestOptions(e,t){try{return this.httpClient.post("/auth/v1/webauthn/login/options",{conditional:t,flow_type:e})}catch(r){return console.error("error",r),null}}async fetchPublicKeyCredentialCreationOptions(e,t){try{return this.httpClient.post("/auth/v1/webauthn/register/options",{conditional:t,flow_type:e})}catch(r){return console.error("error",r),null}}async startRegistration(e,t){if(await this.detectCapabilities(),!e)return console.error("No PublicKeyCredentialCreationOptionsJSON provided"),null;Dr.abort(),Dr=new AbortController;const r=this.toPublicKeyCredentialCreationOptions(e),o={signal:Dr.signal,publicKey:r};if(t){if(!this.isConditionalCreateAvailable())return console.error("Conditional create mediation not supported in this browser"),null;o.mediation="conditional"}try{const n=await navigator.credentials.create(o);if(!n){console.error("no credential returned by authenticator");return}const{id:i,rawId:s,response:d,type:c}=n;let u;typeof d.getTransports=="function"&&(u=d.getTransports());let v;if(typeof d.getPublicKeyAlgorithm=="function")try{v=d.getPublicKeyAlgorithm()}catch(_){gs("getPublicKeyAlgorithm()",_)}let b;if(typeof d.getPublicKey=="function")try{const _=d.getPublicKey();_!==null&&(b=this.bufferToBase64URLString(_))}catch(_){gs("getPublicKey()",_)}let w;if(typeof d.getAuthenticatorData=="function")try{w=this.bufferToBase64URLString(d.getAuthenticatorData())}catch(_){gs("getAuthenticatorData()",_)}return{id:i,rawId:this.bufferToBase64URLString(s),response:{attestationObject:this.bufferToBase64URLString(d.attestationObject),clientDataJSON:this.bufferToBase64URLString(d.clientDataJSON),transports:u,publicKeyAlgorithm:v,publicKey:b,authenticatorData:w},type:c,clientExtensionResults:n.getClientExtensionResults(),authenticatorAttachment:this.toAuthenticatorAttachment(n.authenticatorAttachment)}}catch(n){const i=this.identifyAuthenticationError({error:n,options:o});return i instanceof Lr?console.error(`WebAuthn authentication failed with code: ${i.code}, message: ${i.message}`):console.error("WebAuthn authentication failed with error:",n),null}}async startAuthentication(e,t){if(await this.detectCapabilities(),!e)return console.error("No PublicKeyCredentialRequestOptionsJSON provided"),null;if(!this.isWebAuthnAvailable())return console.error("WebAuthn not supported in this browser"),null;Dr.abort(),Dr=new AbortController;const r=this.toPublicKeyCredentialRequestOptions(e),o={signal:Dr.signal,publicKey:r};if(t){if(!this.isConditionalGetAvailable())return console.error("Conditional mediation not supported in this browser"),null;o.mediation="conditional",o.publicKey&&(o.publicKey.allowCredentials=[])}try{const n=await navigator.credentials.get(o);return this.toPublicKeyCredentialJSON(n)}catch(n){const i=this.identifyAuthenticationError({error:n,options:o});return i instanceof Lr?console.error(`WebAuthn authentication failed with code: ${i.code}, message: ${i.message}`):console.error("WebAuthn authentication failed with error:",n),null}}async signalUnknownCredential(e,t){if(await this.detectCapabilities(),this.isSignalUnknownCredentialAvailable())try{await PublicKeyCredential.signalUnknownCredential({rpId:e,credentialId:t})}catch(r){console.error("Failed to signal unknown credential:",r)}else console.warn("signalUnknownCredential not supported in this browser")}async signalCurrentUserDetails(e){if(await this.detectCapabilities(),this.isSignalCurrentUserDetailsAvailable())try{await PublicKeyCredential.signalCurrentUserDetails(e)}catch(t){console.error("Failed to signal current user details:",t)}else console.warn("signalCurrentUserDetails not supported. Ask user to update manually.")}toPublicKeyCredentialDescriptor(e){const{id:t}=e;return{...e,id:this.base64URLStringToBuffer(t),type:e.type,transports:e.transports}}toAuthenticatorAttachment(e){const t=["cross-platform","platform"];if(e&&!(t.indexOf(e)<0))return e}bufferToBase64URLString(e){const t=new Uint8Array(e);let r="";for(const n of t)r+=String.fromCharCode(n);return btoa(r).replace(/\+/g,"-").replace(/\//g,"_").replace(/=/g,"")}base64URLStringToBuffer(e){const t=e.replace(/-/g,"+").replace(/_/g,"/"),r=(4-t.length%4)%4,o=t.padEnd(t.length+r,"="),n=atob(o),i=new ArrayBuffer(n.length),s=new Uint8Array(i);for(let d=0;d<n.length;d++)s[d]=n.charCodeAt(d);return i}toPublicKeyCredentialJSON(e){if(typeof e.toJSON=="function")return e.toJSON();const t=e.response;return{id:e.id,type:e.type,rawId:this.bufferToBase64URLString(e.rawId),authenticatorAttachment:this.toAuthenticatorAttachment(e.authenticatorAttachment),clientExtensionResults:e==null?void 0:e.getClientExtensionResults(),response:{clientDataJSON:this.bufferToBase64URLString(t.clientDataJSON),authenticatorData:this.bufferToBase64URLString(t.authenticatorData),signature:this.bufferToBase64URLString(t.signature),userHandle:t.userHandle?this.bufferToBase64URLString(t.userHandle):void 0}}}toPublicKeyCredentialCreationOptions(e){var r;if(typeof PublicKeyCredential.parseCreationOptionsFromJSON=="function")return PublicKeyCredential.parseCreationOptionsFromJSON(e);const t={challenge:this.base64URLStringToBuffer(e.challenge),rp:{id:e.rp.id,name:e.rp.name},user:{displayName:e.user.displayName,id:this.base64URLStringToBuffer(e.user.id),name:e.user.name},pubKeyCredParams:e.pubKeyCredParams.map(o=>({alg:o.alg,type:o.type})),timeout:e.timeout};if(e.attestation&&(t.attestation=e.attestation),e.extensions!==void 0&&(t.extensions=e.extensions),e.authenticatorSelection){const o={};e.authenticatorSelection.authenticatorAttachment&&(o.authenticatorAttachment=e.authenticatorSelection.authenticatorAttachment),e.authenticatorSelection.requireResidentKey&&(o.requireResidentKey=e.authenticatorSelection.requireResidentKey),e.authenticatorSelection.residentKey&&(o.residentKey=e.authenticatorSelection.residentKey),e.authenticatorSelection.userVerification&&(o.userVerification=e.authenticatorSelection.userVerification),t.authenticatorSelection=o}return(r=e.excludeCredentials)!=null&&r.length&&(t.excludeCredentials=e.excludeCredentials.map(o=>this.toPublicKeyCredentialDescriptor(o))),t}toPublicKeyCredentialRequestOptions(e){var r;if(typeof PublicKeyCredential.parseRequestOptionsFromJSON=="function")return PublicKeyCredential.parseRequestOptionsFromJSON(e);const t={challenge:this.base64URLStringToBuffer(e.challenge)};return e.rpId!==void 0&&(t.rpId=e.rpId),e.timeout!==void 0&&(t.timeout=e.timeout),e.userVerification!==void 0&&(t.userVerification=e.userVerification),e.extensions!==void 0&&(t.extensions=e.extensions),(r=e.allowCredentials)!=null&&r.length&&(t.allowCredentials=e.allowCredentials.map(o=>this.toPublicKeyCredentialDescriptor(o))),t}identifyAuthenticationError({error:e,options:t}){const{publicKey:r}=t;if(!r)throw Error("options was missing required publicKey property");if(e.name==="AbortError"){if(t.signal instanceof AbortSignal)return new Lr({message:"Authentication ceremony was sent an abort signal",code:"ERROR_CEREMONY_ABORTED",cause:e})}else{if(e.name==="NotAllowedError")return new Lr({message:e.message,code:"ERROR_PASSTHROUGH_SEE_CAUSE_PROPERTY",cause:e});if(e.name==="SecurityError"){const o=window.location.hostname;if(rP(o)){if(r.rpId!==o)return new Lr({message:`The RP ID "${r.rpId}" is invalid for this domain`,code:"ERROR_INVALID_RP_ID",cause:e})}else return new Lr({message:`${window.location.hostname} is an invalid domain`,code:"ERROR_INVALID_DOMAIN",cause:e})}else if(e.name==="UnknownError")return new Lr({message:"The authenticator was unable to process the specified options, or could not create a new assertion signature",code:"ERROR_AUTHENTICATOR_GENERAL_ERROR",cause:e})}return e}isPublicKeyCredentialRequestOptionsJSON(e){return typeof e=="object"&&e!==null&&"challenge"in e}isWebAuthnAvailable(){return this.capabilities.webauthn}isSignalAllAcceptedCredentialsAvailable(){return!!this.capabilities.signalAllAcceptedCredentials}isSignalCurrentUserDetailsAvailable(){return!!this.capabilities.signalCurrentUserDetails}isSignalUnknownCredentialAvailable(){return!!this.capabilities.signalUnknownCredential}isConditionalGetAvailable(){return!!this.capabilities.conditionalGet}isConditionalCreateAvailable(){return!!this.capabilities.conditionalCreate}isHybridTransportAvailable(){return!!this.capabilities.hybridTransport}destroy(){Dr.abort()}};function gs(e,t){console.warn(`The browser extension that intercepted this WebAuthn API call incorrectly implemented ${e}. You should report this error to them.
|
|
2764
|
+
`}};ft([a({type:String})],dt.prototype,"placeholder",2);ft([a({type:Array})],dt.prototype,"dataTable",2);ft([a({type:Boolean})],dt.prototype,"hasDefaultSelect",2);ft([a({type:Boolean})],dt.prototype,"hasDefaultPagination",2);ft([a({type:Boolean})],dt.prototype,"hasDefaultSearch",2);ft([a({type:Object})],dt.prototype,"checkedRows",2);ft([a({type:String})],dt.prototype,"searchTerm",2);ft([a({type:Object})],dt.prototype,"columnVisibility",2);ft([a({type:String})],dt.prototype,"sortColumn",2);ft([a({type:String})],dt.prototype,"sortDirection",2);ft([a({type:Object})],dt.prototype,"cellRenderers",2);ft([a({type:Object})],dt.prototype,"headerRenderers",2);ft([a({type:Array})],dt.prototype,"rowActions",2);ft([a({type:Array})],dt.prototype,"paginationLabels",2);ft([a({type:Number})],dt.prototype,"pageSize",2);ft([a({type:Number})],dt.prototype,"currentPage",2);ft([a({type:Array})],dt.prototype,"sortableColumns",2);ft([a({type:Array})],dt.prototype,"columnOrder",2);ft([a({type:Function})],dt.prototype,"isRowDisabled",2);dt=ft([p("pont-data-table")],dt);var H=class extends Error{constructor(t,r,o,n){super(r);E(this,"code");E(this,"details");E(this,"status");this.name="LoginflowError",this.code=t,this.details=o,this.status=n}};function Ah(e){const t=(e??"").trim();if(!t)throw new H("CONFIG_ERROR","domain is required");if(t.startsWith("/")){if(typeof location>"u")throw new H("CONFIG_ERROR",`domain "${t}" is relative to the page origin, and there is no page here`);return Tc(new URL(t,location.origin))}const r=/^https?:\/\//i.test(t)?"":`${B$(M$(t))?"http":"https"}://`;try{return Tc(new URL(`${r}${t}`))}catch{throw new H("CONFIG_ERROR",`domain "${t}" is not a hostname, an origin, or a path`)}}function Tc(e){return`${e.origin}${e.pathname}`.replace(/\/+$/,"")}function M$(e){return e.split("/")[0]}function B$(e){return/^(localhost|127\.0\.0\.1|\[::1\])(:\d+)?$/i.test(e)}var Ce,U$=(Ce=class{constructor(){E(this,"data",new Map)}static get Instance(){return Ce.instance||(Ce.instance=new Ce),Ce.instance}get(t){return this.data.get(t)}set(t,r){this.data.set(t,r)}setConfig(t){this.data.set("config",t)}getConfig(){return this.data.get("config")}getApiBaseUrl(){return Ah(this.getConfig().domain)}apiIsSameOrigin(){if(typeof location>"u")return!1;try{return new URL(this.getApiBaseUrl()).host===location.host}catch{return!1}}remove(t){this.data.delete(t)}clear(){this.data.clear()}},E(Ce,"instance"),Ce),G=U$.Instance,Ee,ho=(Ee=class{constructor(){}static get Instance(){return Ee.instance||(Ee.instance=new Ee),Ee.instance}async request(t,r={}){const o=G.getConfig(),n=`${G.getApiBaseUrl()}${t}`,i=5e4,s=new AbortController,d=setTimeout(()=>s.abort(),i);try{const c=await fetch(n,{...r,signal:s.signal,headers:{"Content-Type":"application/json",...o.headers,...r.headers}});if(clearTimeout(d),!c.ok){const u=await c.json().catch(()=>({}));throw new H(u.code||u.error||"API_ERROR",u.message||u.error_description||`HTTP ${c.status}: ${c.statusText}`,u.details,c.status)}return await c.json()}catch(c){throw clearTimeout(d),c instanceof H?c:c instanceof Error?c.name==="AbortError"?new H("TIMEOUT","Request timeout"):new H("NETWORK_ERROR",c.message):new H("UNKNOWN_ERROR","An unknown error occurred")}}async post(t,r){return this.request(t,{credentials:"include",method:"POST",body:r?JSON.stringify(r):void 0})}async get(t){return this.request(t,{credentials:"include",method:"GET"})}async getOptional(t){const r=G.getConfig(),o=await fetch(`${G.getApiBaseUrl()}${t}`,{credentials:"include",method:"GET",headers:{...r.headers}});if(o.status===204)return null;if(!o.ok)throw new H("API_ERROR",`HTTP ${o.status}: ${o.statusText}`,void 0,o.status);return await o.json()}async postForm(t,r){return this.request(t,{credentials:"include",method:"POST",headers:{"Content-Type":"application/x-www-form-urlencoded"},body:new URLSearchParams(r).toString()})}},E(Ee,"instance"),Ee),Th="__Secure-pontive_session_state",ms="__Secure-pontive_session_probe";function q$(){return Dh(Th)?"present":j$()?"absent":"unknown"}function Ia(){if(!(typeof document>"u"||typeof location>"u"))for(const e of["",...H$(location.hostname)])Aa(Th,"",e,0)}function j$(){if(typeof document>"u"||typeof location>"u")return!1;const e=V$();try{Aa(ms,"1",e,60);const t=Dh(ms)==="1";return Aa(ms,"",e,0),t&&z$(e)}catch{return!1}}function z$(e){return e!==""||G.apiIsSameOrigin()}function V$(){let e;try{e=new URL(G.getApiBaseUrl()).hostname}catch{return""}const t=location.hostname;if(!e||!t||e.toLowerCase()===t.toLowerCase())return"";const r=t.split("."),o=e.split(".");let n=0;for(;n<r.length&&n<o.length&&r[r.length-1-n].toLowerCase()===o[o.length-1-n].toLowerCase();)n+=1;return n<2?"":o.slice(o.length-n).join(".")}function H$(e){const t=e.split("."),r=[];for(let o=1;o+2<=t.length;o+=1)r.push(t.slice(o).join("."));return r}function Aa(e,t,r,o){const n=G$()?"; Secure":"",i=r?`; Domain=${r}`:"";document.cookie=`${e}=${t}; Path=/; Max-Age=${o}; SameSite=Lax${i}${n}`}function G$(){return typeof globalThis.isSecureContext=="boolean"?globalThis.isSecureContext:location.protocol==="https:"}function Dh(e){if(typeof document>"u"||!document.cookie)return null;for(const t of document.cookie.split(";")){const r=t.indexOf("=");if(!(r<0)&&t.slice(0,r).trim()===e)return t.slice(r+1).trim()||null}return null}var Et,Ot=(Et=class{constructor(){E(this,"AUTH_SESSION_STORAGE_KEY","pontive_auth_session");E(this,"memorySession",null);E(this,"refreshTimeoutId",null);E(this,"refreshPromise",null);E(this,"refreshRetryCount",0);E(this,"refreshBlockedUntil",0);E(this,"sessionGeneration",0);E(this,"channel",null);E(this,"channelName","");E(this,"applyingBroadcast",!1);E(this,"restorePromise",null)}static get Instance(){return Et.instance||(Et.instance=new Et),Et.instance}setCurrentSession(t){this.sessionGeneration+=1,this.write(JSON.stringify(t)),this.publish({type:"session",session:t})}async withRefreshLock(t){const r=typeof navigator<"u"?navigator.locks:void 0;return r?r.request(this.channelKey("refresh"),t):t()}channelKey(t){const r=G.getConfig();return`pontive-${t}:${(r==null?void 0:r.domain)??""}:${(r==null?void 0:r.appId)??""}`}ensureChannel(){var r;if(typeof BroadcastChannel>"u")return null;const t=this.channelKey("session");return this.channel&&this.channelName===t?this.channel:((r=this.channel)==null||r.close(),this.channelName=t,this.channel=new BroadcastChannel(t),this.channel.onmessage=o=>this.receive(o.data),this.channel)}publish(t){var r;this.applyingBroadcast||(r=this.ensureChannel())==null||r.postMessage(t)}receive(t){this.applyingBroadcast=!0;try{if(t.type==="cleared"){this.clearSession();return}this.setCurrentSession(t.session),this.scheduleTokenRefresh()}finally{this.applyingBroadcast=!1}}isCurrentGeneration(t){return this.sessionGeneration===t}getCurrentSession(){const t=this.getStoredSession();return t?this.isSessionExpired(t)?(this.clearSession(),null):(this.shouldRefreshToken(t)&&this.triggerBackgroundRefresh(t),t):null}peekSession(){return this.getStoredSession()}isAuthenticated(){return this.getCurrentSession()!==null}getAuthenticatedUser(){const t=this.getCurrentSession();if(!t)return null;const r=t.id_token?this.decodeJWT(t.id_token):null;return r||(t.user??null)}cleanup(){var t;this.refreshTimeoutId&&(clearTimeout(this.refreshTimeoutId),this.refreshTimeoutId=null),this.refreshPromise=null,(t=this.channel)==null||t.close(),this.channel=null,this.channelName=""}clearSession(){this.sessionGeneration+=1,this.memorySession=null,localStorage.removeItem(this.AUTH_SESSION_STORAGE_KEY),this.refreshTimeoutId&&(clearTimeout(this.refreshTimeoutId),this.refreshTimeoutId=null),this.refreshRetryCount=0,this.refreshBlockedUntil=0,this.publish({type:"cleared"})}isSessionExpired(t){return!t||!t.expires_at?!0:Date.now()>=t.expires_at}cleanExpiredSession(){const t=this.getStoredSession();t&&this.isSessionExpired(t)&&this.clearSession()}getStoredSession(){const t=this.read();if(!t)return null;try{return JSON.parse(t)}catch{return this.clearSession(),null}}write(t){this.memorySession=t,localStorage.removeItem(this.AUTH_SESSION_STORAGE_KEY)}read(){return this.memorySession}decodeJWT(t){try{const o=t.split(".")[1].replace(/-/g,"+").replace(/_/g,"/"),n=decodeURIComponent(atob(o).split("").map(i=>"%"+("00"+i.charCodeAt(0).toString(16)).slice(-2)).join(""));return JSON.parse(n)}catch{return null}}shouldRefreshToken(t){if(!t||!t.expires_at)return!1;const r=Date.now(),o=t.expires_at,n=t.expires_in||3600,i=r+n*1e3*.2;return o<=i}scheduleTokenRefresh(){this.refreshTimeoutId&&(clearTimeout(this.refreshTimeoutId),this.refreshTimeoutId=null);const t=this.getCurrentSession();if(!t||!t.expires_at)return;const r=Date.now(),o=t.expires_at,n=t.expires_in||3600,i=o-r-n*1e3*.2;i>0&&(this.refreshTimeoutId=setTimeout(()=>{this.triggerBackgroundRefresh(t)},i))}triggerBackgroundRefresh(t){this.refreshPromise||Date.now()<this.refreshBlockedUntil||(this.refreshPromise=this.withRefreshLock(()=>{const r=this.getStoredSession();return r&&!this.shouldRefreshToken(r)?(this.scheduleTokenRefresh(),Promise.resolve(null)):this.refreshTokens(r??t)}).then(r=>(r&&(this.setCurrentSession(r),this.refreshRetryCount=0,this.refreshBlockedUntil=0,this.scheduleTokenRefresh()),r)).catch(r=>(console.error("Background token refresh failed:",r),null)).finally(()=>{this.refreshPromise=null}))}async switchOrganization(t){if(!t)throw new H("INVALID_REQUEST","organizationId is required");return this.withRefreshLock(async()=>{const r=this.sessionGeneration,o=this.getCurrentSession(),n=await this.requestTokens(o,{organization_id:t});if(!this.isCurrentGeneration(r))throw new H("SESSION_CHANGED","the session changed while switching organization");return this.setCurrentSession(n),this.scheduleTokenRefresh(),n})}getOrganization(){const t=this.getCurrentSession(),r=t!=null&&t.access_token?this.decodeJWT(t.access_token):null,o=r==null?void 0:r.org_id;if(typeof o!="string"||o==="")return null;const n=i=>Array.isArray(i)?i.filter(s=>typeof s=="string"):[];return{id:o,roles:n(r==null?void 0:r.roles),permissions:n(r==null?void 0:r.permissions)}}async refreshTokens(t){const r=this.sessionGeneration;try{const o=await this.requestTokens(t);return this.isCurrentGeneration(r)?o:(console.warn("Token refresh returned after the session changed; discarding it"),null)}catch(o){return this.isCurrentGeneration(r)?K$(o)?(console.error("Token refresh rejected, signing out:",oo(o)),Ia(),this.clearSession(),null):(console.warn("Token refresh failed, keeping session and retrying:",oo(o)),this.scheduleRefreshRetry(t),null):(console.warn("Token refresh failed after the session changed; ignoring:",oo(o)),null)}}async fetchUserInfo(t){try{return await ho.Instance.request("/oauth2/userinfo",{method:"GET",credentials:"include",headers:{Authorization:`Bearer ${t}`}})}catch(r){return console.debug("Could not read user info for the restored session:",oo(r)),null}}async requestTokens(t,r={}){var i;const o={...r,grant_type:"refresh_token",client_id:(i=G.getConfig())==null?void 0:i.appId};t!=null&&t.refresh_token&&(o.refresh_token=t.refresh_token);const n=await ho.Instance.postForm("/oauth2/token",o);return{id_token:n.id_token??(t==null?void 0:t.id_token)??"",access_token:n.access_token,refresh_token:n.refresh_token??(t==null?void 0:t.refresh_token),expires_in:n.expires_in,expires_at:Date.now()+n.expires_in*1e3}}async readCurrentToken(){var r;const t=(r=G.getConfig())==null?void 0:r.appId;if(!t)return null;try{const o=await ho.Instance.getOptional(`/oauth2/session/token?client_id=${encodeURIComponent(t)}`);return!(o!=null&&o.access_token)||!(o.expires_in>0)?null:{id_token:"",access_token:o.access_token,expires_in:o.expires_in,expires_at:Date.now()+o.expires_in*1e3}}catch{return null}}async restoreSession(){const t=this.getStoredSession();return t&&!this.isSessionExpired(t)?t:q$()==="absent"?null:this.restorePromise?this.restorePromise:(this.restorePromise=this.withRefreshLock(async()=>{const r=this.getStoredSession();if(r&&!this.isSessionExpired(r))return r;try{const o=await this.readCurrentToken()??await this.requestTokens(null);return o.id_token||(o.user=await this.fetchUserInfo(o.access_token)??void 0),this.setCurrentSession(o),this.scheduleTokenRefresh(),o}catch(o){return Y$(o)&&Ia(),console.debug("No session to restore:",oo(o)),null}}).finally(()=>{this.restorePromise=null}),this.restorePromise)}scheduleRefreshRetry(t){if(this.refreshTimeoutId&&(clearTimeout(this.refreshTimeoutId),this.refreshTimeoutId=null),this.refreshRetryCount>=Et.MAX_REFRESH_RETRIES){console.warn("Token refresh gave up after",this.refreshRetryCount,"attempts"),this.refreshRetryCount=0,this.refreshBlockedUntil=0;return}const r=Math.min(Et.REFRESH_RETRY_BASE_MS*2**this.refreshRetryCount,Et.MAX_REFRESH_RETRY_DELAY_MS);this.refreshRetryCount+=1,this.refreshBlockedUntil=Date.now()+r,this.refreshTimeoutId=setTimeout(()=>{this.refreshBlockedUntil=0,this.triggerBackgroundRefresh(t)},r)}},E(Et,"MAX_REFRESH_RETRIES",5),E(Et,"REFRESH_RETRY_BASE_MS",5e3),E(Et,"MAX_REFRESH_RETRY_DELAY_MS",6e4),E(Et,"instance"),Et);function K$(e){return!(e instanceof H)||e.status===void 0?!1:e.status===401?!0:e.status===400&&W$.has(e.code)}var W$=new Set(["invalid_grant","invalid_client"]);function Y$(e){return e instanceof H&&e.status!==void 0&&e.status>=400&&e.status<500}function oo(e){return e instanceof H?`${e.code} (status ${e.status??"none"}): ${e.message}`:String(e)}var Lh=class{constructor(e=sessionStorage){E(this,"storage");E(this,"FLOW_STATE_KEY","pontive_loginflow_state");E(this,"FLOW_EXPIRY_MS",540*1e3);this.storage=e}getFlowState(){const e=this.storage.getItem(this.FLOW_STATE_KEY);if(!e)return null;try{const t=JSON.parse(e);return this.isExpired(t)?(this.clearFlowState(),null):t}catch{return this.clearFlowState(),null}}saveFlowState(e,t,r){const o=Date.now(),n=this.getFlowState(),i={flowType:e,flow_id:t,state:r.state,startedAt:(n==null?void 0:n.startedAt)||o,lastUpdatedAt:o,render_spec:r.render_spec};this.storage.setItem(this.FLOW_STATE_KEY,JSON.stringify(i))}restoreFromHistory(e){const t={flowType:e.flowType,flow_id:e.flow_id,state:e.state,startedAt:e.timestamp,lastUpdatedAt:e.timestamp,render_spec:void 0};this.storage.setItem(this.FLOW_STATE_KEY,JSON.stringify(t))}clearFlowState(){this.storage.removeItem(this.FLOW_STATE_KEY)}isExpired(e){return Date.now()-e.lastUpdatedAt>this.FLOW_EXPIRY_MS}get expiryMs(){return this.FLOW_EXPIRY_MS}},gr,Ti=(gr=class{static detect(t,r=window.location){if(gr.hasInviteToken(r))return"invitation";const o=r.pathname.toLowerCase();return t.invitationUrl&&o.includes(t.invitationUrl)?"invitation":o.includes(t.signinUrl)?"signin":o.includes(t.signupUrl)?"signup":"custom"}static hasInviteToken(t){try{return new URLSearchParams(t.search).has(gr.INVITE_TOKEN_PARAM)}catch{return!1}}},E(gr,"INVITE_TOKEN_PARAM","invite_token"),gr),Fh=class{constructor(){E(this,"listeners",new Map)}on(e,t){this.listeners.has(e)||this.listeners.set(e,new Set),this.listeners.get(e).add(t)}off(e,t){var r;(r=this.listeners.get(e))==null||r.delete(t)}emit(e,t){const r=this.listeners.get(e);r&&r.forEach(o=>{try{o(t)}catch(n){console.error(`[FlowEventBus] Error in event handler for ${e}:`,n)}})}clear(){this.listeners.clear()}clearEvent(e){this.listeners.delete(e)}},Q$=class{getNavigationType(){const e=performance.getEntriesByType("navigation");if(e.length>0)return e[0].type;const t=performance.navigation;if(t)switch(t.type){case 1:return"reload";case 2:return"back_forward";default:return"navigate"}return"navigate"}},Ht,Z$=(Ht=class{constructor(t,r,o=window.location,n,i){E(this,"httpClient",ho.Instance);E(this,"flowId");E(this,"redirectTimeoutId",null);E(this,"flowStateManager");E(this,"flowEventBus");E(this,"location");E(this,"navigationTypeDetector");E(this,"eventHandlers",new Map([["switch_to_signin",this.handleSwitchToSignin.bind(this)],["switch_to_signup",this.handleSwitchToSignup.bind(this)],["continue_here",this.handleContinueHere.bind(this)]]));E(this,"linkWatchTimer",null);E(this,"linkWatchGeneration",0);E(this,"waitingForLink",!1);const s=G.getConfig();if(!s.domain)throw new H("CONFIG_ERROR","Domain is required");if(!s.appId)throw new H("CONFIG_ERROR","App ID is required");this.flowId=t,this.location=o,this.flowStateManager=n||new Lh,this.flowEventBus=r||new Fh,this.navigationTypeDetector=i||new Q$,Ot.Instance.cleanExpiredSession(),Ot.Instance.scheduleTokenRefresh()}static async init(t,r,o,n,i){const s=new Ht(t,r,o,n,i),d=await s.initializeFlowInternal();return{sdk:s,flowType:d.flowType,isResumed:d.isResumed,state:d.state,render_spec:d.render_spec,auth_result:d.auth_result}}async startFlow(t,r){if(!r.app_id)throw new H("VALIDATION_ERROR","Client ID is required");const o=`/auth/v1/authflows/${t}/start`;return this.executeFlowRequest(()=>this.httpClient.post(o,r),"START_FLOW_ERROR","Failed to start flow")}async resumeFlow(t,r){const o=r?`?continue=${encodeURIComponent(r)}`:"",n=`/auth/v1/authflows/${t}/resume${o}`;return this.executeFlowRequest(()=>this.httpClient.post(n),"RESUME_FLOW_ERROR","Failed to resume flow")}async processEvent(t,r){if(!t.event)throw new H("VALIDATION_ERROR","Event type is required");const o=this.eventHandlers.get(t.event);return o?await o():await this.processServerEvent(t,r)}async executeFlowRequest(t,r,o,n){try{const i=await t();return n&&await n(i),this.processAuthResult(i.auth_result),i.redirection&&this.redirect(i.redirection),i}catch(i){throw i instanceof H?i:new H(r,o,i instanceof Error?{originalError:i.message,stack:i.stack}:i)}}async processServerEvent(t,r){let o=this.flowStateManager.getFlowState();if(!o&&(console.warn("Flow state expired, restarting flow before processing event"),await this.initializeFlowInternal(),o=this.flowStateManager.getFlowState(),!o))throw new H("FLOW_RESTART_ERROR","Failed to restart flow - no flow state after initialization");const n=o.state,i=`/auth/v1/authflows/${o.flowType}/events`,s=this.waitingForLink;this.stopWatchingForLink();let d;try{d=await this.executeFlowRequest(()=>this.httpClient.post(i,t),"PROCESS_EVENT_ERROR","Failed to process event",r)}catch(c){if(s&&Ht.flowIsGone(c))return this.announceContinuedElsewhere(o.flowType,""),{state:""};throw c}if(this.watchForLink(o.flowType,d),!d.auth_result){this.flowStateManager.saveFlowState(o.flowType,o.flow_id,d);const c=this.flowStateManager.getFlowState();if(c){const u=n!==d.state;this.flowEventBus.emit("flow:updated",{flowState:c,isNewStep:u})}}return d}processAuthResult(t){if(t){const r={id_token:t.id_token,access_token:t.access_token,refresh_token:t.refresh_token,expires_in:t.expires_in,expires_at:Date.now()+t.expires_in*1e3};Ot.Instance.setCurrentSession(r),Ot.Instance.scheduleTokenRefresh(),this.flowStateManager.clearFlowState();const{onAuthenticated:o}=G.getConfig();if(o){o(r);return}console.warn("pontive: signed in, but no onAuthenticated was supplied, so the SDK cannot route the user. Supply onAuthenticated to handle the handoff.")}}async initializeFlowInternal(){const t=G.getConfig(),r=Ti.detect(t,this.location);this.validateFlowType(r);const o=this.flowStateManager.getFlowState();return this.shouldResumeFlow(o,r)?await this.resumeExistingFlow(o,r):await this.startNewFlow(r)}validateFlowType(t){if(t==="custom"&&!this.flowId)throw new H("FLOW_ID_ERROR","Flow ID is required for custom flows")}shouldResumeFlow(t,r){const n=new URLSearchParams(this.location.search).get("resume")==="true";if(!t)return n;const i=this.navigationTypeDetector.getNavigationType();if(i==="navigate"&&!n)return this.flowStateManager.clearFlowState(),console.log(`Fresh navigation detected (type: ${i}), starting new flow`),!1;if(t.flowType!==r)return this.flowStateManager.clearFlowState(),console.log(`Flow type changed from ${t.flowType} to ${r}, starting new flow, flow_id: ${this.flowId}`),!1;if(r==="custom"&&t.flow_id!==this.flowId)return this.flowStateManager.clearFlowState(),console.log(`Custom flow ID changed, starting new flow, flow_id: ${this.flowId}`),!1;const s=n?"explicit resume=true":`navigation type: ${i}`;return console.log(`Resuming existing flow (${s})`),!0}async resumeExistingFlow(t,r){try{const o=await this.resumeFlow(r,this.continueParam());if(this.watchForLink(r,o),!o.auth_result){this.flowStateManager.saveFlowState(r,(t==null?void 0:t.flow_id)??this.determineFlowId(r),o);const n=this.flowStateManager.getFlowState();n&&this.flowEventBus.emit("flow:resumed",{flowState:n})}return{flowType:r,isResumed:!0,state:o.state,render_spec:o.render_spec,auth_result:o.auth_result}}catch(o){return this.flowStateManager.clearFlowState(),console.warn("Failed to resume flow, starting fresh:",o),await this.startNewFlow(r)}}async startNewFlow(t){const r=G.getConfig(),o=new URLSearchParams(this.location.search),n={};o.forEach((c,u)=>{n[u]=c}),r.organizationId&&!n.organization_id&&(n.organization_id=r.organizationId),console.log("metadata",n);const i=o.get("locales")||r.locales||void 0,s={app_id:r.appId,origin_url:this.location.href,signin_url:r.signinUrl,signup_url:r.signupUrl,locales:i,flow_id:this.determineFlowId(t),metadata:n,auth_base_url:G.getApiBaseUrl()},d=await this.startFlow(t,s);if(this.watchForLink(t,d),!d.auth_result){this.flowStateManager.saveFlowState(t,s.flow_id,d);const c=this.flowStateManager.getFlowState();c&&this.flowEventBus.emit("flow:started",{flowState:c})}return{flowType:t,isResumed:!1,state:d.state,render_spec:d.render_spec,auth_result:d.auth_result}}determineFlowId(t){switch(t){case"signin":return this.flowId||"signin-flow";case"signup":return this.flowId||"signup-flow";case"invitation":return this.flowId||"invitation-flow";case"custom":if(!this.flowId)throw new H("FLOW_ID_ERROR","Flow ID is required for custom flows");return this.flowId}}continueParam(){const t=new URLSearchParams(this.location.search);if(t.get("resume")==="true")return t.get("continue")??void 0}watchForLink(t,r){if(this.stopWatchingForLink(),this.waitingForLink=r.waiting_for_link===!0,!this.waitingForLink)return;const o=this.linkWatchGeneration,n=Date.now()+Ht.LINK_POLL_LIMIT_MS,i=()=>{this.linkWatchTimer=setTimeout(s,Ht.LINK_POLL_INTERVAL_MS)},s=async()=>{if(o!==this.linkWatchGeneration||Date.now()>n)return;if(typeof document<"u"&&document.hidden){i();return}let d;try{d=await this.httpClient.post(`/auth/v1/authflows/${t}/resume`)}catch(c){o===this.linkWatchGeneration&&Ht.flowIsGone(c)&&this.announceContinuedElsewhere(t,"");return}if(o===this.linkWatchGeneration){if(d.waiting_for_link){i();return}this.announceContinuedElsewhere(t,d.state)}};i()}announceContinuedElsewhere(t,r){var o,n;this.stopWatchingForLink(),this.flowStateManager.clearFlowState(),(n=(o=G.getConfig()).onFlowStateChange)==null||n.call(o,{eventType:"flow_continued_elsewhere",flowType:t,state:r})}static flowIsGone(t){return t instanceof H&&t.status===401}stopWatchingForLink(){this.waitingForLink=!1,this.linkWatchGeneration++,this.linkWatchTimer!==null&&(clearTimeout(this.linkWatchTimer),this.linkWatchTimer=null)}async handleContinueHere(){const{continueHereUrl:t}=G.getConfig();this.flowStateManager.clearFlowState();let r=t;if(!r){const o=new URL(this.location.href);o.searchParams.delete("resume"),o.searchParams.delete("continue"),r=o.toString()}return this.redirect({url:r,redirect_delay:0}),{state:"End"}}async handleSwitchToSignin(){const t=G.getConfig();return this.redirect({url:this.withCurrentQuery(t.signinUrl),redirect_delay:0}),{state:"End"}}async handleSwitchToSignup(){const t=G.getConfig();return this.redirect({url:this.withCurrentQuery(t.signupUrl),redirect_delay:0}),{state:"End"}}withCurrentQuery(t){const r=this.location.search;return!r||r==="?"?t:t.includes("?")?`${t}&${r.slice(1)}`:`${t}${r}`}redirect(t){t.url&&(this.redirectTimeoutId!==null&&(console.log("Clearing existing redirect timeout before scheduling new redirect to:",t.url),clearTimeout(this.redirectTimeoutId),this.redirectTimeoutId=null),this.redirectTimeoutId=setTimeout(()=>{this.location.href=t.url},t.redirect_delay*1e3))}reloadPage(){setTimeout(()=>{this.location.reload()},0)}getEventBus(){return this.flowEventBus}cleanup(){this.stopWatchingForLink(),this.redirectTimeoutId&&(clearTimeout(this.redirectTimeoutId),this.redirectTimeoutId=null),this.flowEventBus.clear()}},E(Ht,"LINK_POLL_INTERVAL_MS",3e3),E(Ht,"LINK_POLL_LIMIT_MS",900*1e3),Ht),J$=class{constructor(e){E(this,"delayMs");E(this,"timerId",null);this.delayMs=e}debounce(e){this.timerId&&clearTimeout(this.timerId),this.timerId=setTimeout(()=>{e(),this.timerId=null},this.delayMs)}cancel(){this.timerId&&(clearTimeout(this.timerId),this.timerId=null)}isPending(){return this.timerId!==null}},X$=class{pushState(e,t,r){history.pushState(e,t,r)}replaceState(e,t,r){history.replaceState(e,t,r)}get state(){return history.state}},tP=class{constructor(e,t,r=!1,o=window.location,n,i){E(this,"popstateListener",null);E(this,"pageshowListener",null);E(this,"debouncer");E(this,"isProcessing",!1);E(this,"isHandlingNavigationEvent",!1);E(this,"onFlowRestartNeeded",null);E(this,"skipHistoryTracking");E(this,"flowStateManager");E(this,"historyAdapter");E(this,"location");this.onFlowRestartNeeded=t,this.skipHistoryTracking=r,this.debouncer=new J$(200),this.location=o,this.flowStateManager=n||new Lh,this.historyAdapter=i||new X$,this.subscribeToFlowEvents(e),this.initializeListener()}subscribeToFlowEvents(e){e.on("flow:started",this.handleFlowStart.bind(this)),e.on("flow:updated",this.handleFlowUpdate.bind(this)),e.on("flow:resumed",this.handleFlowResume.bind(this))}initializeListener(){this.popstateListener=e=>{console.log("[NavigationManager] popstate event received"),this.debouncer.debounce(()=>{console.log("[NavigationManager] Debounce timeout fired, handling popstate"),this.handlePopState(e)})},this.pageshowListener=e=>{e.persisted&&(console.log("[NavigationManager] Page restored from bfcache"),this.debouncer.debounce(()=>{console.log("[NavigationManager] Handling bfcache restoration"),this.handleBfcacheRestoration()}))},window.addEventListener("popstate",this.popstateListener),window.addEventListener("pageshow",this.pageshowListener)}async handlePopState(e){if(this.isProcessing){console.log("[NavigationManager] Already processing popstate, skipping");return}console.log("[NavigationManager] Starting popstate processing"),this.isProcessing=!0,this.isHandlingNavigationEvent=!0;try{const t=e.state,r=this.flowStateManager.getFlowState(),o=G.getConfig(),n=Ti.detect(o,this.location);if(t&&this.restoreHistoryStateToSession(t),this.shouldRestartFlow(t,r,n)){await this.triggerFlowRestart();return}console.log("[NavigationManager] Valid state restored from history")}finally{this.isProcessing=!1,this.isHandlingNavigationEvent=!1}}async handleBfcacheRestoration(){if(this.isProcessing){console.log("[NavigationManager] Already processing bfcache restoration, skipping");return}console.log("[NavigationManager] Starting bfcache restoration processing"),this.isProcessing=!0,this.isHandlingNavigationEvent=!0;try{const e=this.historyAdapter.state,t=this.flowStateManager.getFlowState(),r=G.getConfig(),o=Ti.detect(r,this.location);if(e&&this.restoreHistoryStateToSession(e),this.shouldRestartFlow(e,t,o)){await this.triggerFlowRestart();return}console.log("[NavigationManager] Valid state restored from bfcache")}finally{this.isProcessing=!1,this.isHandlingNavigationEvent=!1}}restoreHistoryStateToSession(e){console.log("[NavigationManager] Restoring history state to session storage:",e),this.flowStateManager.restoreFromHistory(e)}shouldRestartFlow(e,t,r){return e&&e.flowType!==r?(console.log("[NavigationManager] Flow type changed via navigation:",e.flowType,"→",r),this.flowStateManager.clearFlowState(),!0):e?Date.now()-e.timestamp>this.flowStateManager.expiryMs?(console.log("[NavigationManager] History state expired, clearing and restarting flow"),this.flowStateManager.clearFlowState(),!0):(console.log("[NavigationManager] Valid history state restored, triggering restart to resume flow"),!0):(console.log("[NavigationManager] No history state, skipping"),!1)}async triggerFlowRestart(){this.onFlowRestartNeeded&&await this.onFlowRestartNeeded()}createHistoryState(e){return{flowType:e.flowType,flow_id:e.flow_id,state:e.state,timestamp:Date.now()}}updateBrowserHistory(e,t){if(this.skipHistoryTracking){console.log("[NavigationManager] Skipping history tracking (created from navigation)");return}const r=this.createHistoryState(e);try{t==="push"?(this.historyAdapter.pushState(r,"",this.location.href),console.log("[NavigationManager] Pushed state to history")):(this.historyAdapter.replaceState(r,"",this.location.href),console.log("[NavigationManager] Replaced state in history"))}catch(o){console.error("[NavigationManager] Failed to update history:",o)}}handleFlowStart(e){this.updateBrowserHistory(e.flowState,"replace")}handleFlowUpdate(e){const t=this.isHandlingNavigationEvent||!e.isNewStep?"replace":"push";this.updateBrowserHistory(e.flowState,t)}handleFlowResume(e){this.updateBrowserHistory(e.flowState,"replace")}destroy(){this.debouncer.cancel(),this.popstateListener&&(window.removeEventListener("popstate",this.popstateListener),this.popstateListener=null),this.pageshowListener&&(window.removeEventListener("pageshow",this.pageshowListener),this.pageshowListener=null),this.onFlowRestartNeeded=null}},Dr=new AbortController,eP=class{constructor(){E(this,"httpClient",ho.Instance);E(this,"capabilities",{webauthn:!1});E(this,"capabilitiesDetected",!1)}async detectCapabilities(){if(!this.capabilitiesDetected)try{if(typeof window.PublicKeyCredential=="function"?this.capabilities.webauthn=!0:this.capabilities.webauthn=!1,typeof PublicKeyCredential.getClientCapabilities=="function"){const e=await PublicKeyCredential.getClientCapabilities();this.capabilities={...this.capabilities,...e};return}typeof PublicKeyCredential.isUserVerifyingPlatformAuthenticatorAvailable=="function"&&(this.capabilities.userVerifyingPlatformAuthenticator=await PublicKeyCredential.isUserVerifyingPlatformAuthenticatorAvailable()),(PublicKeyCredential==null?void 0:PublicKeyCredential.isConditionalMediationAvailable)!==void 0&&typeof PublicKeyCredential.isConditionalMediationAvailable=="function"?this.capabilities.conditionalGet=await PublicKeyCredential.isConditionalMediationAvailable():this.capabilities.conditionalGet=!1}finally{this.capabilitiesDetected=!0}}async fetchPublicKeyCredentialRequestOptions(e,t){try{return this.httpClient.post("/auth/v1/webauthn/login/options",{conditional:t,flow_type:e})}catch(r){return console.error("error",r),null}}async fetchPublicKeyCredentialCreationOptions(e,t){try{return this.httpClient.post("/auth/v1/webauthn/register/options",{conditional:t,flow_type:e})}catch(r){return console.error("error",r),null}}async startRegistration(e,t){if(await this.detectCapabilities(),!e)return console.error("No PublicKeyCredentialCreationOptionsJSON provided"),null;Dr.abort(),Dr=new AbortController;const r=this.toPublicKeyCredentialCreationOptions(e),o={signal:Dr.signal,publicKey:r};if(t){if(!this.isConditionalCreateAvailable())return console.error("Conditional create mediation not supported in this browser"),null;o.mediation="conditional"}try{const n=await navigator.credentials.create(o);if(!n){console.error("no credential returned by authenticator");return}const{id:i,rawId:s,response:d,type:c}=n;let u;typeof d.getTransports=="function"&&(u=d.getTransports());let v;if(typeof d.getPublicKeyAlgorithm=="function")try{v=d.getPublicKeyAlgorithm()}catch(b){gs("getPublicKeyAlgorithm()",b)}let y;if(typeof d.getPublicKey=="function")try{const b=d.getPublicKey();b!==null&&(y=this.bufferToBase64URLString(b))}catch(b){gs("getPublicKey()",b)}let w;if(typeof d.getAuthenticatorData=="function")try{w=this.bufferToBase64URLString(d.getAuthenticatorData())}catch(b){gs("getAuthenticatorData()",b)}return{id:i,rawId:this.bufferToBase64URLString(s),response:{attestationObject:this.bufferToBase64URLString(d.attestationObject),clientDataJSON:this.bufferToBase64URLString(d.clientDataJSON),transports:u,publicKeyAlgorithm:v,publicKey:y,authenticatorData:w},type:c,clientExtensionResults:n.getClientExtensionResults(),authenticatorAttachment:this.toAuthenticatorAttachment(n.authenticatorAttachment)}}catch(n){const i=this.identifyAuthenticationError({error:n,options:o});return i instanceof Lr?console.error(`WebAuthn authentication failed with code: ${i.code}, message: ${i.message}`):console.error("WebAuthn authentication failed with error:",n),null}}async startAuthentication(e,t){if(await this.detectCapabilities(),!e)return console.error("No PublicKeyCredentialRequestOptionsJSON provided"),null;if(!this.isWebAuthnAvailable())return console.error("WebAuthn not supported in this browser"),null;Dr.abort(),Dr=new AbortController;const r=this.toPublicKeyCredentialRequestOptions(e),o={signal:Dr.signal,publicKey:r};if(t){if(!this.isConditionalGetAvailable())return console.error("Conditional mediation not supported in this browser"),null;o.mediation="conditional",o.publicKey&&(o.publicKey.allowCredentials=[])}try{const n=await navigator.credentials.get(o);return this.toPublicKeyCredentialJSON(n)}catch(n){const i=this.identifyAuthenticationError({error:n,options:o});return i instanceof Lr?console.error(`WebAuthn authentication failed with code: ${i.code}, message: ${i.message}`):console.error("WebAuthn authentication failed with error:",n),null}}async signalUnknownCredential(e,t){if(await this.detectCapabilities(),this.isSignalUnknownCredentialAvailable())try{await PublicKeyCredential.signalUnknownCredential({rpId:e,credentialId:t})}catch(r){console.error("Failed to signal unknown credential:",r)}else console.warn("signalUnknownCredential not supported in this browser")}async signalCurrentUserDetails(e){if(await this.detectCapabilities(),this.isSignalCurrentUserDetailsAvailable())try{await PublicKeyCredential.signalCurrentUserDetails(e)}catch(t){console.error("Failed to signal current user details:",t)}else console.warn("signalCurrentUserDetails not supported. Ask user to update manually.")}toPublicKeyCredentialDescriptor(e){const{id:t}=e;return{...e,id:this.base64URLStringToBuffer(t),type:e.type,transports:e.transports}}toAuthenticatorAttachment(e){const t=["cross-platform","platform"];if(e&&!(t.indexOf(e)<0))return e}bufferToBase64URLString(e){const t=new Uint8Array(e);let r="";for(const n of t)r+=String.fromCharCode(n);return btoa(r).replace(/\+/g,"-").replace(/\//g,"_").replace(/=/g,"")}base64URLStringToBuffer(e){const t=e.replace(/-/g,"+").replace(/_/g,"/"),r=(4-t.length%4)%4,o=t.padEnd(t.length+r,"="),n=atob(o),i=new ArrayBuffer(n.length),s=new Uint8Array(i);for(let d=0;d<n.length;d++)s[d]=n.charCodeAt(d);return i}toPublicKeyCredentialJSON(e){if(typeof e.toJSON=="function")return e.toJSON();const t=e.response;return{id:e.id,type:e.type,rawId:this.bufferToBase64URLString(e.rawId),authenticatorAttachment:this.toAuthenticatorAttachment(e.authenticatorAttachment),clientExtensionResults:e==null?void 0:e.getClientExtensionResults(),response:{clientDataJSON:this.bufferToBase64URLString(t.clientDataJSON),authenticatorData:this.bufferToBase64URLString(t.authenticatorData),signature:this.bufferToBase64URLString(t.signature),userHandle:t.userHandle?this.bufferToBase64URLString(t.userHandle):void 0}}}toPublicKeyCredentialCreationOptions(e){var r;if(typeof PublicKeyCredential.parseCreationOptionsFromJSON=="function")return PublicKeyCredential.parseCreationOptionsFromJSON(e);const t={challenge:this.base64URLStringToBuffer(e.challenge),rp:{id:e.rp.id,name:e.rp.name},user:{displayName:e.user.displayName,id:this.base64URLStringToBuffer(e.user.id),name:e.user.name},pubKeyCredParams:e.pubKeyCredParams.map(o=>({alg:o.alg,type:o.type})),timeout:e.timeout};if(e.attestation&&(t.attestation=e.attestation),e.extensions!==void 0&&(t.extensions=e.extensions),e.authenticatorSelection){const o={};e.authenticatorSelection.authenticatorAttachment&&(o.authenticatorAttachment=e.authenticatorSelection.authenticatorAttachment),e.authenticatorSelection.requireResidentKey&&(o.requireResidentKey=e.authenticatorSelection.requireResidentKey),e.authenticatorSelection.residentKey&&(o.residentKey=e.authenticatorSelection.residentKey),e.authenticatorSelection.userVerification&&(o.userVerification=e.authenticatorSelection.userVerification),t.authenticatorSelection=o}return(r=e.excludeCredentials)!=null&&r.length&&(t.excludeCredentials=e.excludeCredentials.map(o=>this.toPublicKeyCredentialDescriptor(o))),t}toPublicKeyCredentialRequestOptions(e){var r;if(typeof PublicKeyCredential.parseRequestOptionsFromJSON=="function")return PublicKeyCredential.parseRequestOptionsFromJSON(e);const t={challenge:this.base64URLStringToBuffer(e.challenge)};return e.rpId!==void 0&&(t.rpId=e.rpId),e.timeout!==void 0&&(t.timeout=e.timeout),e.userVerification!==void 0&&(t.userVerification=e.userVerification),e.extensions!==void 0&&(t.extensions=e.extensions),(r=e.allowCredentials)!=null&&r.length&&(t.allowCredentials=e.allowCredentials.map(o=>this.toPublicKeyCredentialDescriptor(o))),t}identifyAuthenticationError({error:e,options:t}){const{publicKey:r}=t;if(!r)throw Error("options was missing required publicKey property");if(e.name==="AbortError"){if(t.signal instanceof AbortSignal)return new Lr({message:"Authentication ceremony was sent an abort signal",code:"ERROR_CEREMONY_ABORTED",cause:e})}else{if(e.name==="NotAllowedError")return new Lr({message:e.message,code:"ERROR_PASSTHROUGH_SEE_CAUSE_PROPERTY",cause:e});if(e.name==="SecurityError"){const o=window.location.hostname;if(rP(o)){if(r.rpId!==o)return new Lr({message:`The RP ID "${r.rpId}" is invalid for this domain`,code:"ERROR_INVALID_RP_ID",cause:e})}else return new Lr({message:`${window.location.hostname} is an invalid domain`,code:"ERROR_INVALID_DOMAIN",cause:e})}else if(e.name==="UnknownError")return new Lr({message:"The authenticator was unable to process the specified options, or could not create a new assertion signature",code:"ERROR_AUTHENTICATOR_GENERAL_ERROR",cause:e})}return e}isPublicKeyCredentialRequestOptionsJSON(e){return typeof e=="object"&&e!==null&&"challenge"in e}isWebAuthnAvailable(){return this.capabilities.webauthn}isSignalAllAcceptedCredentialsAvailable(){return!!this.capabilities.signalAllAcceptedCredentials}isSignalCurrentUserDetailsAvailable(){return!!this.capabilities.signalCurrentUserDetails}isSignalUnknownCredentialAvailable(){return!!this.capabilities.signalUnknownCredential}isConditionalGetAvailable(){return!!this.capabilities.conditionalGet}isConditionalCreateAvailable(){return!!this.capabilities.conditionalCreate}isHybridTransportAvailable(){return!!this.capabilities.hybridTransport}destroy(){Dr.abort()}};function gs(e,t){console.warn(`The browser extension that intercepted this WebAuthn API call incorrectly implemented ${e}. You should report this error to them.
|
|
2765
2765
|
`,t)}var Lr=class extends Error{constructor({message:t,code:r,cause:o,name:n}){super(t);E(this,"code");this.name=n??o.name,this.code=r}};function rP(e){return e==="localhost"||/^([a-z0-9]+(-[a-z0-9]+)*\.)+[a-z]{2,}$/i.test(e)}var Se,nP=(Se=class{constructor(){E(this,"configured",!1);E(this,"configuredResolve");E(this,"configuredPromise",new Promise(t=>{this.configuredResolve=t}));E(this,"loginflow",null);E(this,"navigationManager",null);E(this,"flowEventBus",null);E(this,"webauthnService",null)}static get Instance(){return Se.instance||(Se.instance=new Se),Se.instance}ensureConfigured(){if(!this.configured)throw new H("NOT_CONFIGURED","Auth.configure() must be called before using Auth methods")}ensureLoginflowInitialized(){if(!this.loginflow)throw new H("LOGINFLOW_NOT_INITIALIZED","Call Auth.startLoginflow() first")}async startLoginflowInternal(t,r=!1){this.ensureConfigured(),this.webauthnService&&(console.log("[AuthService] Cleaning up and aborting ongoing webauthn flows"),this.webauthnService.destroy(),this.webauthnService=null),this.loginflow&&(console.log("[AuthService] Cleaning up old loginflow instance"),this.loginflow.cleanup(),this.loginflow=null),this.navigationManager&&(console.log("[AuthService] Cleaning up old navigation manager instance"),this.navigationManager.destroy(),this.navigationManager=null),this.webauthnService=new eP,this.webauthnService.detectCapabilities(),this.flowEventBus=new Fh,this.navigationManager=new tP(this.flowEventBus,async()=>{console.log("[AuthService] Navigation restart triggered, restarting loginflow"),await this.startLoginflowInternal(void 0,!1)},r);const o=await Z$.init(t,this.flowEventBus),n=G.getConfig();this.startPasskeyAuthentication(o.flowType,!0),this.loginflow=o.sdk;const i={flowType:o.flowType,isResumed:o.isResumed,state:o.state,render_spec:o.render_spec,auth_result:o.auth_result};return n.onFlowStateChange&&n.onFlowStateChange({eventType:o.isResumed?"flow_resumed":"flow_started",flowType:o.flowType,state:o.state,render_spec:o.render_spec,auth_result:o.auth_result,isResumed:o.isResumed}),i}configure(t){if(!t.domain||!t.appId)throw new H("CONFIG_ERROR","domain and appId are required");G.setConfig(t),this.configured=!0,this.configuredResolve()}whenConfigured(){return this.configuredPromise}isAuthenticated(){return this.ensureConfigured(),Ot.Instance.isAuthenticated()}getCurrentSession(){return this.ensureConfigured(),Ot.Instance.getCurrentSession()}async restoreSession(){return this.ensureConfigured(),Ot.Instance.restoreSession()}getAuthenticatedUser(){return this.ensureConfigured(),Ot.Instance.getAuthenticatedUser()}getOrganization(){return this.ensureConfigured(),Ot.Instance.getOrganization()}async switchOrganization(t){return this.ensureConfigured(),Ot.Instance.switchOrganization(t)}async startLoginflow(t){return this.startLoginflowInternal(t,!1)}async processLoginflowEvent(t){var i,s;this.ensureConfigured(),this.ensureLoginflowInitialized();const r=G.getConfig(),o=Ti.detect(r,location);if(t.event==="signin_with_passkey"&&!((i=t.data)!=null&&i.credential_request)){const d=await this.getPasskeyCredential(o,!1);if(!d||!d.cred)return console.error("no credential returned by browser"),{state:""};t.data={credential_request:d.cred}}if(t.event==="register_passkey"&&!((s=t.data)!=null&&s.conditional)){console.log("attempt to register a passkey");const d=await this.createPasskeyCredential(o,!1);if(!d)return console.error("no credential created by browser"),{state:""};t.data={credential_creation_response:d,conditional:!1}}const n=await this.loginflow.processEvent(t,async d=>{var c;if((c=d.data)!=null&&c.conditional_create_enabled){console.log("attempt to register a passkey conditionally");const u=await this.registerPasskey(o,!0);u&&(u.render_spec=void 0,d.render_spec=void 0)}});if(console.log("render spec",n.render_spec),r.onFlowStateChange){const d=sessionStorage.getItem("pontive_loginflow_state");let c="custom";if(d)try{c=JSON.parse(d).flowType}catch(u){console.error("Failed to parse flow state:",u)}r.onFlowStateChange({eventType:"flow_updated",flowType:c,state:n.state,render_spec:n.render_spec,auth_result:n.auth_result})}return n}async getPasskeyCredential(t,r){var n,i;const o=await((n=this.webauthnService)==null?void 0:n.fetchPublicKeyCredentialRequestOptions(t,r));if(!o)return console.error("failed to fetch public key request options"),null;try{return{cred:await((i=this.webauthnService)==null?void 0:i.startAuthentication(o,r)),options:o}}catch(s){return console.error("error starting authentication",s),null}}async startPasskeyAuthentication(t,r=!1){var s,d;const o=await this.getPasskeyCredential(t,r);if(!o||!o.cred){console.error("no credential found");return}const{cred:n,options:i}=o;try{((s=(await this.processLoginflowEvent({event:"signin_with_passkey",data:{credential_request:n}})).data)==null?void 0:s.error)==="CredentialNotFound"&&(i.rpId&&n.id?(d=this.webauthnService)==null||d.signalUnknownCredential(i.rpId,n.id):console.log("missing rpId or credential id for signalUnknownCredential"))}catch(c){console.error("failed to signin with passkey",c)}}async createPasskeyCredential(t,r){var o,n;try{const i=await((o=this.webauthnService)==null?void 0:o.fetchPublicKeyCredentialCreationOptions(t,r));if(!i){console.warn("no credential creation option returned by webauthn service"),console.log("skipping conditional passkey registration...");return}return(n=this.webauthnService)==null?void 0:n.startRegistration(i,r)}catch(i){console.log("error",i)}}async registerPasskey(t,r=!1){try{const o=await this.createPasskeyCredential(t,r),n=await this.processLoginflowEvent({event:"register_passkey",data:{credential_creation_response:o,conditional:r}});return console.log("passkey creation res",n),n}catch(o){console.log("error",o)}}invalidateSession(){Ot.Instance.clearSession()}async signOut(t){var n;this.ensureConfigured();const r=oP(Ot.Instance.peekSession()),o=((n=G.getConfig())==null?void 0:n.appId)??"";if(Ia(),Ot.Instance.clearSession(),Ot.Instance.cleanup(),this.loginflow&&(this.loginflow.cleanup(),this.loginflow=null),this.navigationManager&&(this.navigationManager.destroy(),this.navigationManager=null),this.flowEventBus&&(this.flowEventBus.clear(),this.flowEventBus=null),!G.apiIsSameOrigin()){window.location.assign(this.logoutUrl(r,o,t==null?void 0:t.returnTo));return}await this.endServerSession(r,o),window.location.reload()}async endServerSession(t,r){try{await fetch(`${G.getApiBaseUrl()}/oauth2/logout`,{method:"POST",credentials:"include",headers:{"Content-Type":"application/x-www-form-urlencoded"},body:new URLSearchParams({client_id:r,...t?{logout_hint:t}:{}}).toString()})}catch(o){console.warn("Could not end the session at the authorization server:",o)}}logoutUrl(t,r,o){const n=new URLSearchParams({post_logout_redirect_uri:o??`${window.location.origin}${window.location.pathname}`,client_id:r});return t&&n.set("logout_hint",t),`${G.getApiBaseUrl()}/oauth2/logout?${n.toString()}`}},E(Se,"instance"),Se);function oP(e){for(const t of[e==null?void 0:e.id_token,e==null?void 0:e.access_token]){if(!t)continue;const r=Ot.Instance.decodeJWT(t);if(typeof(r==null?void 0:r.sid)=="string"&&r.sid)return r.sid}}var K=nP.Instance,iP=Object.defineProperty,sP=(e,t,r,o)=>{for(var n=void 0,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=s(t,r,n)||n);return n&&iP(t,r,n),n};class zt extends f{constructor(){super(),this.shadow=!1,this.__initialAttributesCache=null}parseJsonAttribute(t){try{const r=this.getAttribute(t);return r?JSON.parse(r):{}}catch{return{}}}get sbStyle(){return this.parseJsonAttribute("pont-style")}getAttributesToExclude(){return[]}getFilteredAttributes(){const t={};return Array.from(this.attributes).forEach(r=>{this.getAttributesToExclude().includes(r.name)||(t[r.name]=r.value??"")}),t}isCustomPropertySet(t){const r=getComputedStyle(this).getPropertyValue(t).trim();return r!=="inherit"&&r.length>0}applyCustomClass(t,r,o=""){var n,i;t.some(s=>this.isCustomPropertySet(s))&&((i=(n=this.shadowRoot)==null?void 0:n.querySelector(r))==null||i.classList.add(o))}moveAttributesToElement(t,r=["id","class"]){t&&r.forEach(o=>{const n=this.getAttribute(o);n!==null&&(t.setAttribute(o,n),this.removeAttribute(o))})}removeAttributesFromHost(t=["id","class"]){t.forEach(r=>{this.hasAttribute(r)&&this.removeAttribute(r)})}captureHostAttributes(){if(this.__initialAttributesCache)return this.__initialAttributesCache;const t={};return Array.from(this.attributes).forEach(r=>{t[r.name]=r.value}),this.__initialAttributesCache=t,t}getHostClass(){return this.captureHostAttributes().class??""}removeDuplicateContent(){var i;const t=document.createTreeWalker(this,NodeFilter.SHOW_TEXT|NodeFilter.SHOW_ELEMENT,{acceptNode:s=>{var d;return s.nodeType===Node.COMMENT_NODE||s.nodeType===Node.TEXT_NODE&&!((d=s.textContent)!=null&&d.trim())?NodeFilter.FILTER_REJECT:NodeFilter.FILTER_ACCEPT}}),r=new Map,o=[];let n;for(;n=t.nextNode();){let s;if(n.nodeType===Node.TEXT_NODE){const d=(i=n.textContent)==null?void 0:i.trim();if(!d)continue;s=`text:${d}`}else if(n instanceof HTMLElement){const d=Array.from(n.attributes).map(c=>`${c.name}=${c.value}`).sort().join(":");s=`element:${n.tagName}:${d}`}else continue;if(r.has(s)){const d=r.get(s);d!=null&&d.parentNode&&o.push(d),r.set(s,n)}else r.set(s,n)}o.forEach(s=>{var d;return(d=s.parentNode)==null?void 0:d.removeChild(s)})}moveLightDomChildrenInto(t,r){let o;r!=null&&r.length?(o=r.filter(n=>this.contains(n)&&n!==t&&!n.contains(t)),o.forEach(n=>{const i=Array.from(t.childNodes).find(s=>{var d;return(d=s.isEqualNode)==null?void 0:d.call(s,n)});i&&t.removeChild(i)})):o=Array.from(this.childNodes).filter(n=>n!==t&&!t.contains(n)&&!n.contains(t)),o.forEach(n=>t.appendChild(n))}}sP([a({type:Boolean})],zt.prototype,"shadow");const xr="pont:auth",Mo={showWatermark:!0},qi="pont:branding";class aP{constructor(t){this.consumer=new ni(t,{context:qi,subscribe:!0})}get showWatermark(){var t;return((t=this.consumer.value)==null?void 0:t.showWatermark)??Mo.showWatermark}}const kh="pont:design-mode";class Bo{constructor(t){this.host=t,this.consumer=new ni(t,{context:kh,subscribe:!0})}get active(){return this.host.hasAttribute("design-mode")?this.host.getAttribute("design-mode")!=="false":this.consumer.value??!1}}const Nh="pont:env",Mh=Symbol("renderSpecContext"),Uo="pont-user-context",Bh="";function Kt(...e){return Ip(Va(e))}function lP(e){return Object.entries(e).filter(([t,r])=>typeof r!="object"&&r!=null).map(([t,r])=>`${t}: ${r};`).join(" ")}function dP(e){document.documentElement.setAttribute("data-theme",e)}function cP(){const e=document.documentElement.getAttribute("data-theme");(!e||e!=="light"&&e!=="dark")&&dP("light")}function pP(e,t){return e?e.includes("{{theme}}")?e.replace("{{theme}}",t):e:""}function Ta(){return new Promise(e=>{requestAnimationFrame(()=>requestAnimationFrame(()=>e()))})}const Dc="abcdefghijklmnopqrstuvwxyz0123456789",hP=6;function uP(e){let t="";for(let r=0;r<hP;r++)t+=Dc.charAt(Math.floor(Math.random()*Dc.length));return t}const _t=()=>uP();function ji(e){const t=document.createElement("pont-toast"),r=document.createElement("pont-toast-view-port");r.part="user-profile-toast",r.setAttribute("variant","destructive"),t.dataset.state="open";const o=document.createElement("div");o.className="pont-grid pont-gap-1";const n=document.createElement("pont-toast-title");n.textContent="Uh oh! Something went wrong.";const i=document.createElement("pont-toast-description");i.textContent=e,o.appendChild(n),o.appendChild(i),r.appendChild(o),t.appendChild(r),document.body.appendChild(t),setTimeout(()=>{t.dataset.state="open",r.dataset.state="open"},10),setTimeout(()=>{t.parentNode&&t.parentNode.removeChild(t)},3.5*1e3)}async function mP(e,t=5e3){if(!e)return;let r;const o=new Promise(n=>{r=setTimeout(()=>n("timeout"),t)});try{await Promise.race([e.whenConfigured(),o])==="timeout"&&console.warn(`pontive: Auth.configure() has not been called after ${t}ms. Is this widget mounted inside <pont-provider>?`)}finally{clearTimeout(r)}}function gP(e){if(!(e!=null&&e.startsWith("data:image/svg+xml;base64,")))return null;try{const t=e.replace("data:image/svg+xml;base64,","");return atob(t)}catch(t){return console.error("Invalid base64 SVG:",t),null}}function fP(e){return/^https?:\/\//.test(e)||e!=null&&e.startsWith("data:image/svg+xml;base64,")?e:`data:image/svg+xml;base64,${e}`}function ue(){var e;return(e=K.getCurrentSession())==null?void 0:e.access_token}function Da(e,t=!1){if(!e&&e!==0)return"N/A";const r=typeof e=="string"?new Date(e):new Date(t?e:e*1e3);if(isNaN(r.getTime()))return"Invalid Date";const o=new Date,n=new Date(o.getFullYear(),o.getMonth(),o.getDate()),i=new Date(r.getFullYear(),r.getMonth(),r.getDate()),s=Math.floor((n.getTime()-i.getTime())/(1e3*60*60*24));return s===0?"Today":s===1?"Yesterday":s>1&&s<=6?r.toLocaleDateString("en-US",{weekday:"long"}):r.toLocaleDateString("en-US",{year:"numeric",month:"short",day:"numeric"})}function La(e,t=!1){if(!e&&e!==0)return"N/A";const r=typeof e=="string"?new Date(e):new Date(t?e:e*1e3);return isNaN(r.getTime())?"Invalid Time":r.toLocaleTimeString("en-US",{hour:"2-digit",minute:"2-digit",hour12:!1})}function zi(e){if(!e)return"";const r=(e.includes("@")?e.split("@")[0]:e).split(/[\s._-]+/).filter(Boolean);return r.length===0?"":r.length===1?r[0].slice(0,2).toUpperCase():`${r[0][0]}${r[r.length-1][0]}`.toUpperCase()}function vP(e){return e instanceof Error&&"status"in e}function Vi(e,t){var r,o;return vP(e)?((o=(r=e.data)==null?void 0:r.error)==null?void 0:o.message)??e.message??t:e instanceof Error&&e.message||t}const fn={variant:"secondary",size:"default",content:"label",iconAlign:"start",label:"Continue with Passkey"},vn={variant:"outline",size:"default",content:"icon-label",iconAlign:"start",prompt:"Continue with"},bn={variant:"default",size:"default",content:"label",iconAlign:"end",label:"Submit"},bP={apple:"Apple",discord:"Discord",facebook:"Facebook",github:"GitHub",google:"Google",linkedin:"LinkedIn",meta:"Meta",microsoft:"Microsoft",x:"X"},yP={apple:U`<path d="M12.152 6.896c-.948 0-2.415-1.078-3.96-1.04-2.04.027-3.91 1.183-4.961 3.014-2.117 3.675-.546 9.103 1.519 12.09 1.013 1.454 2.208 3.09 3.792 3.039 1.52-.065 2.09-.987 3.935-.987 1.831 0 2.35.987 3.96.948 1.637-.026 2.676-1.48 3.676-2.948 1.156-1.688 1.636-3.325 1.662-3.415-.039-.013-3.182-1.221-3.22-4.857-.026-3.04 2.48-4.494 2.597-4.559-1.429-2.09-3.623-2.324-4.39-2.376-2-.156-3.675 1.09-4.61 1.09zM15.53 3.83c.843-1.012 1.4-2.427 1.245-3.83-1.207.052-2.662.805-3.532 1.818-.78.896-1.454 2.338-1.273 3.714 1.338.104 2.715-.688 3.559-1.701" />`,discord:U`<path d="M20.317 4.3698a19.7913 19.7913 0 00-4.8851-1.5152.0741.0741 0 00-.0785.0371c-.211.3753-.4447.8648-.6083 1.2495-1.8447-.2762-3.68-.2762-5.4868 0-.1636-.3933-.4058-.8742-.6177-1.2495a.077.077 0 00-.0785-.037 19.7363 19.7363 0 00-4.8852 1.515.0699.0699 0 00-.0321.0277C.5334 9.0458-.319 13.5799.0992 18.0578a.0824.0824 0 00.0312.0561c2.0528 1.5076 4.0413 2.4228 5.9929 3.0294a.0777.0777 0 00.0842-.0276c.4616-.6304.8731-1.2952 1.226-1.9942a.076.076 0 00-.0416-.1057c-.6528-.2476-1.2743-.5495-1.8722-.8923a.077.077 0 01-.0076-.1277c.1258-.0943.2517-.1923.3718-.2914a.0743.0743 0 01.0776-.0105c3.9278 1.7933 8.18 1.7933 12.0614 0a.0739.0739 0 01.0785.0095c.1202.099.246.1981.3728.2924a.077.077 0 01-.0066.1276 12.2986 12.2986 0 01-1.873.8914.0766.0766 0 00-.0407.1067c.3604.698.7719 1.3628 1.225 1.9932a.076.076 0 00.0842.0286c1.961-.6067 3.9495-1.5219 6.0023-3.0294a.077.077 0 00.0313-.0552c.5004-5.177-.8382-9.6739-3.5485-13.6604a.061.061 0 00-.0312-.0286zM8.02 15.3312c-1.1825 0-2.1569-1.0857-2.1569-2.419 0-1.3332.9555-2.4189 2.157-2.4189 1.2108 0 2.1757 1.0952 2.1568 2.419 0 1.3332-.9555 2.4189-2.1569 2.4189zm7.9748 0c-1.1825 0-2.1569-1.0857-2.1569-2.419 0-1.3332.9554-2.4189 2.1569-2.4189 1.2108 0 2.1757 1.0952 2.1568 2.419 0 1.3332-.946 2.4189-2.1568 2.4189Z" />`,facebook:U`<path d="M9.101 23.691v-7.98H6.627v-3.667h2.474v-1.58c0-4.085 1.848-5.978 5.858-5.978.401 0 .955.042 1.468.103a8.68 8.68 0 0 1 1.141.195v3.325a8.623 8.623 0 0 0-.653-.036 26.805 26.805 0 0 0-.733-.009c-.707 0-1.259.096-1.675.309a1.686 1.686 0 0 0-.679.622c-.258.42-.374.995-.374 1.752v1.297h3.919l-.386 2.103-.287 1.564h-3.246v8.245C19.396 23.238 24 18.179 24 12.044c0-6.627-5.373-12-12-12s-12 5.373-12 12c0 5.628 3.874 10.35 9.101 11.647Z" />`,github:U`<path d="M12 .297c-6.63 0-12 5.373-12 12 0 5.303 3.438 9.8 8.205 11.385.6.113.82-.258.82-.577 0-.285-.01-1.04-.015-2.04-3.338.724-4.042-1.61-4.042-1.61C4.422 18.07 3.633 17.7 3.633 17.7c-1.087-.744.084-.729.084-.729 1.205.084 1.838 1.236 1.838 1.236 1.07 1.835 2.809 1.305 3.495.998.108-.776.417-1.305.76-1.605-2.665-.3-5.466-1.332-5.466-5.93 0-1.31.465-2.38 1.235-3.22-.135-.303-.54-1.523.105-3.176 0 0 1.005-.322 3.3 1.23.96-.267 1.98-.399 3-.405 1.02.006 2.04.138 3 .405 2.28-1.552 3.285-1.23 3.285-1.23.645 1.653.24 2.873.12 3.176.765.84 1.23 1.91 1.23 3.22 0 4.61-2.805 5.625-5.475 5.92.42.36.81 1.096.81 2.22 0 1.606-.015 2.896-.015 3.286 0 .315.21.69.825.57C20.565 22.092 24 17.592 24 12.297c0-6.627-5.373-12-12-12" />`,google:U`<path d="M12.48 10.92v3.28h7.84c-.24 1.84-.853 3.187-1.787 4.133-1.147 1.147-2.933 2.4-6.053 2.4-4.827 0-8.6-3.893-8.6-8.72s3.773-8.72 8.6-8.72c2.6 0 4.507 1.027 5.907 2.347l2.307-2.307C18.747 1.44 16.133 0 12.48 0 5.867 0 .307 5.387.307 12s5.56 12 12.173 12c3.573 0 6.267-1.173 8.373-3.36 2.16-2.16 2.84-5.213 2.84-7.667 0-.76-.053-1.467-.173-2.053H12.48z" />`,linkedin:U`<path d="M20.447 20.452h-3.554v-5.569c0-1.328-.027-3.037-1.852-3.037-1.853 0-2.136 1.445-2.136 2.939v5.667H9.351V9h3.414v1.561h.046c.477-.9 1.637-1.85 3.37-1.85 3.601 0 4.267 2.37 4.267 5.455v6.286zM5.337 7.433a2.062 2.062 0 0 1-2.063-2.065 2.064 2.064 0 1 1 2.063 2.065zm1.782 13.019H3.555V9h3.564v11.452zM22.225 0H1.771C.792 0 0 .774 0 1.729v20.542C0 23.227.792 24 1.771 24h20.451C23.2 24 24 23.227 24 22.271V1.729C24 .774 23.2 0 22.222 0h.003z" />`,meta:U`<path d="M6.915 4.03c-1.968 0-3.683 1.28-4.871 3.113C.704 9.208 0 11.883 0 14.449c0 .706.07 1.369.21 1.973a6.624 6.624 0 0 0 .265.86 5.297 5.297 0 0 0 .371.761c.696 1.159 1.818 1.927 3.593 1.927 1.497 0 2.633-.671 3.965-2.444.76-1.012 1.144-1.626 2.663-4.32l.756-1.339.186-.325c.061.1.121.196.183.3l2.152 3.595c.724 1.21 1.665 2.556 2.47 3.314 1.046.987 1.992 1.22 3.06 1.22 1.075 0 1.876-.355 2.455-.843a3.743 3.743 0 0 0 .81-.973c.542-.939.861-2.127.861-3.745 0-2.72-.681-5.357-2.084-7.45-1.282-1.912-2.957-2.93-4.716-2.93-1.047 0-2.088.467-3.053 1.308-.652.57-1.257 1.29-1.82 2.05-.69-.875-1.335-1.547-1.958-2.056-1.182-.966-2.315-1.303-3.454-1.303zm10.16 2.053c1.147 0 2.188.758 2.992 1.999 1.132 1.748 1.647 4.195 1.647 6.4 0 1.548-.368 2.9-1.839 2.9-.58 0-1.027-.23-1.664-1.004-.496-.601-1.343-1.878-2.832-4.358l-.617-1.028a44.908 44.908 0 0 0-1.255-1.98c.07-.109.141-.224.211-.327 1.12-1.667 2.118-2.602 3.358-2.602zm-10.201.553c1.265 0 2.058.791 2.675 1.446.307.327.737.871 1.234 1.579l-1.02 1.566c-.757 1.163-1.882 3.017-2.837 4.338-1.191 1.649-1.81 1.817-2.486 1.817-.524 0-1.038-.237-1.383-.794-.263-.426-.464-1.13-.464-2.046 0-2.221.63-4.535 1.66-6.088.454-.687.964-1.226 1.533-1.533a2.264 2.264 0 0 1 1.088-.285z" />`,microsoft:U`<path d="M11.4 24H0V12.6h11.4V24zM24 24H12.6V12.6H24V24zM11.4 11.4H0V0h11.4v11.4zM24 11.4H12.6V0H24v11.4z" />`,x:U`<path d="M18.244 2.25h3.308l-7.227 8.26 8.502 11.24H16.17l-4.714-6.231-5.401 6.231H2.763l7.726-8.835L1.254 2.25H8.08l4.713 6.231 5.45-6.231zm-1.161 17.52h1.833L7.084 4.126H5.117L17.083 19.77z" />`};var _P=Object.defineProperty,wP=Object.getOwnPropertyDescriptor,Xt=(e,t,r,o)=>{for(var n=o>1?void 0:o?wP(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&_P(t,r,n),n};exports.PontPasskeyButton=class extends f{constructor(){super(...arguments),this.seed=_t(),this.variant=fn.variant,this.size=fn.size,this.content=fn.content,this.iconAlign=fn.iconAlign,this._label=fn.label,this._loading=!1,this._handleClick=async()=>{if(!this.isDisabled){this._loading=!0,this.dispatchEvent(new CustomEvent(exports.PontPasskeyButton.CLICK_EVENT,{detail:{id:this.rootId,event:this.event},bubbles:!0,composed:!0}));try{if(this.event){const t=await K.processLoginflowEvent({event:this.event});this.dispatchEvent(new CustomEvent(exports.PontPasskeyButton.SUCCESS_EVENT,{detail:{id:this.rootId,event:this.event,result:t},bubbles:!0,composed:!0}))}}catch(t){const r=t instanceof Error?t.message:String(t);this.dispatchEvent(new CustomEvent(exports.PontPasskeyButton.ERROR_EVENT,{detail:{id:this.rootId,event:this.event,message:r,error:t},bubbles:!0,composed:!0}))}finally{this._loading=!1}}}}get label(){return this._label}set label(t){const r=this._label;this._label=t.length?t:fn.label,this.requestUpdate("label",r)}createRenderRoot(){return this}get rootId(){return this.customId??`${exports.PontPasskeyButton.TAG}-${this.seed}`}get iconId(){return`${this.rootId}-${exports.PontPasskeyButton.ICON}`}get isLoading(){return this.loading||this._loading}get isDisabled(){return this.disabled||this.isLoading}connectedCallback(){super.connectedCallback(),this.addEventListener("click",this._handleClick)}disconnectedCallback(){super.disconnectedCallback(),this.removeEventListener("click",this._handleClick)}_renderIcon(){const t=this.content==="icon"?"":`pont-icon-align-${this.iconAlign}`;return this.isLoading?l`
|
|
2766
2766
|
<pont-spinner
|
|
2767
2767
|
id="${this.iconId}"
|
|
@@ -3366,14 +3366,14 @@
|
|
|
3366
3366
|
>
|
|
3367
3367
|
</div>
|
|
3368
3368
|
</div>
|
|
3369
|
-
`}};exports.PontEditIdentifier.ROOT="edit-identifier";exports.PontEditIdentifier.ICON="icon";exports.PontEditIdentifier.TAG=`${rt}-${exports.PontEditIdentifier.ROOT}`;exports.PontEditIdentifier.CLICK_EVENT=`${exports.PontEditIdentifier.TAG}:click`;exports.PontEditIdentifier.PARTS={root:exports.PontEditIdentifier.ROOT,icon:`${exports.PontEditIdentifier.ROOT}-${exports.PontEditIdentifier.ICON}`};qo([a({type:String})],exports.PontEditIdentifier.prototype,"seed",2);qo([a({type:String,attribute:"custom-id"})],exports.PontEditIdentifier.prototype,"customId",2);qo([a({type:String})],exports.PontEditIdentifier.prototype,"identifier",2);qo([a({type:String})],exports.PontEditIdentifier.prototype,"event",2);exports.PontEditIdentifier=qo([p("pont-edit-identifier")],exports.PontEditIdentifier);function r1(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var Pn={},vs,Fc;function n1(){return Fc||(Fc=1,vs=function(){return typeof Promise=="function"&&Promise.prototype&&Promise.prototype.then}),vs}var bs={},hr={},kc;function ln(){if(kc)return hr;kc=1;let e;const t=[0,26,44,70,100,134,172,196,242,292,346,404,466,532,581,655,733,815,901,991,1085,1156,1258,1364,1474,1588,1706,1828,1921,2051,2185,2323,2465,2611,2761,2876,3034,3196,3362,3532,3706];return hr.getSymbolSize=function(o){if(!o)throw new Error('"version" cannot be null or undefined');if(o<1||o>40)throw new Error('"version" should be in range from 1 to 40');return o*4+17},hr.getSymbolTotalCodewords=function(o){return t[o]},hr.getBCHDigit=function(r){let o=0;for(;r!==0;)o++,r>>>=1;return o},hr.setToSJISFunction=function(o){if(typeof o!="function")throw new Error('"toSJISFunc" is not a valid function.');e=o},hr.isKanjiModeEnabled=function(){return typeof e<"u"},hr.toSJIS=function(o){return e(o)},hr}var ys={},Nc;function _l(){return Nc||(Nc=1,(function(e){e.L={bit:1},e.M={bit:0},e.Q={bit:3},e.H={bit:2};function t(r){if(typeof r!="string")throw new Error("Param is not a string");switch(r.toLowerCase()){case"l":case"low":return e.L;case"m":case"medium":return e.M;case"q":case"quartile":return e.Q;case"h":case"high":return e.H;default:throw new Error("Unknown EC Level: "+r)}}e.isValid=function(o){return o&&typeof o.bit<"u"&&o.bit>=0&&o.bit<4},e.from=function(o,n){if(e.isValid(o))return o;try{return t(o)}catch{return n}}})(ys)),ys}var _s,Mc;function o1(){if(Mc)return _s;Mc=1;function e(){this.buffer=[],this.length=0}return e.prototype={get:function(t){const r=Math.floor(t/8);return(this.buffer[r]>>>7-t%8&1)===1},put:function(t,r){for(let o=0;o<r;o++)this.putBit((t>>>r-o-1&1)===1)},getLengthInBits:function(){return this.length},putBit:function(t){const r=Math.floor(this.length/8);this.buffer.length<=r&&this.buffer.push(0),t&&(this.buffer[r]|=128>>>this.length%8),this.length++}},_s=e,_s}var ws,Bc;function i1(){if(Bc)return ws;Bc=1;function e(t){if(!t||t<1)throw new Error("BitMatrix size must be defined and greater than 0");this.size=t,this.data=new Uint8Array(t*t),this.reservedBit=new Uint8Array(t*t)}return e.prototype.set=function(t,r,o,n){const i=t*this.size+r;this.data[i]=o,n&&(this.reservedBit[i]=!0)},e.prototype.get=function(t,r){return this.data[t*this.size+r]},e.prototype.xor=function(t,r,o){this.data[t*this.size+r]^=o},e.prototype.isReserved=function(t,r){return this.reservedBit[t*this.size+r]},ws=e,ws}var $s={},Uc;function s1(){return Uc||(Uc=1,(function(e){const t=ln().getSymbolSize;e.getRowColCoords=function(o){if(o===1)return[];const n=Math.floor(o/7)+2,i=t(o),s=i===145?26:Math.ceil((i-13)/(2*n-2))*2,d=[i-7];for(let c=1;c<n-1;c++)d[c]=d[c-1]-s;return d.push(6),d.reverse()},e.getPositions=function(o){const n=[],i=e.getRowColCoords(o),s=i.length;for(let d=0;d<s;d++)for(let c=0;c<s;c++)d===0&&c===0||d===0&&c===s-1||d===s-1&&c===0||n.push([i[d],i[c]]);return n}})($s)),$s}var Ps={},qc;function a1(){if(qc)return Ps;qc=1;const e=ln().getSymbolSize,t=7;return Ps.getPositions=function(o){const n=e(o);return[[0,0],[n-t,0],[0,n-t]]},Ps}var Cs={},jc;function l1(){return jc||(jc=1,(function(e){e.Patterns={PATTERN000:0,PATTERN001:1,PATTERN010:2,PATTERN011:3,PATTERN100:4,PATTERN101:5,PATTERN110:6,PATTERN111:7};const t={N1:3,N2:3,N3:40,N4:10};e.isValid=function(n){return n!=null&&n!==""&&!isNaN(n)&&n>=0&&n<=7},e.from=function(n){return e.isValid(n)?parseInt(n,10):void 0},e.getPenaltyN1=function(n){const i=n.size;let s=0,d=0,c=0,u=null,v=null;for(let
|
|
3370
|
-
]))+`;_e.KANJI=new RegExp(r,"g"),_e.BYTE_KANJI=new RegExp("[^A-Z0-9 $%*+\\-./:]+","g"),_e.BYTE=new RegExp(o,"g"),_e.NUMERIC=new RegExp(e,"g"),_e.ALPHANUMERIC=new RegExp(t,"g");const n=new RegExp("^"+r+"$"),i=new RegExp("^"+e+"$"),s=new RegExp("^[A-Z0-9 $%*+\\-./:]+$");return _e.testKanji=function(c){return n.test(c)},_e.testNumeric=function(c){return i.test(c)},_e.testAlphanumeric=function(c){return s.test(c)},_e}var Yc;function dn(){return Yc||(Yc=1,(function(e){const t=zh(),r=Vh();e.NUMERIC={id:"Numeric",bit:1,ccBits:[10,12,14]},e.ALPHANUMERIC={id:"Alphanumeric",bit:2,ccBits:[9,11,13]},e.BYTE={id:"Byte",bit:4,ccBits:[8,16,16]},e.KANJI={id:"Kanji",bit:8,ccBits:[8,10,12]},e.MIXED={bit:-1},e.getCharCountIndicator=function(i,s){if(!i.ccBits)throw new Error("Invalid mode: "+i);if(!t.isValid(s))throw new Error("Invalid version: "+s);return s>=1&&s<10?i.ccBits[0]:s<27?i.ccBits[1]:i.ccBits[2]},e.getBestModeForData=function(i){return r.testNumeric(i)?e.NUMERIC:r.testAlphanumeric(i)?e.ALPHANUMERIC:r.testKanji(i)?e.KANJI:e.BYTE},e.toString=function(i){if(i&&i.id)return i.id;throw new Error("Invalid mode")},e.isValid=function(i){return i&&i.bit&&i.ccBits};function o(n){if(typeof n!="string")throw new Error("Param is not a string");switch(n.toLowerCase()){case"numeric":return e.NUMERIC;case"alphanumeric":return e.ALPHANUMERIC;case"kanji":return e.KANJI;case"byte":return e.BYTE;default:throw new Error("Unknown mode: "+n)}}e.from=function(i,s){if(e.isValid(i))return i;try{return o(i)}catch{return s}}})(Os)),Os}var Qc;function h1(){return Qc||(Qc=1,(function(e){const t=ln(),r=jh(),o=_l(),n=dn(),i=zh(),s=7973,d=t.getBCHDigit(s);function c(w,
|
|
3371
|
-
Make sure your charset is UTF-8`);i=(i>>>8&255)*192+(i&255),o.put(i,13)}},Fs=r,Fs}var ks={exports:{}},rp;function b1(){return rp||(rp=1,(function(e){var t={single_source_shortest_paths:function(r,o,n){var i={},s={};s[o]=0;var d=t.PriorityQueue.make();d.push(o,0);for(var c,u,v,
|
|
3372
|
-
Suggested mode is: `+t.toString(I));switch(L===t.KANJI&&!d.isKanjiModeEnabled()&&(L=t.BYTE),L){case t.NUMERIC:return new r(S);case t.ALPHANUMERIC:return new o(S);case t.KANJI:return new i(S);case t.BYTE:return new n(S)}}e.fromArray=function(D){return D.reduce(function(L,I){return typeof I=="string"?L.push(O(I,null)):I.data&&L.push(O(I.data,I.mode)),L},[])},e.fromString=function(D,L){const I=
|
|
3369
|
+
`}};exports.PontEditIdentifier.ROOT="edit-identifier";exports.PontEditIdentifier.ICON="icon";exports.PontEditIdentifier.TAG=`${rt}-${exports.PontEditIdentifier.ROOT}`;exports.PontEditIdentifier.CLICK_EVENT=`${exports.PontEditIdentifier.TAG}:click`;exports.PontEditIdentifier.PARTS={root:exports.PontEditIdentifier.ROOT,icon:`${exports.PontEditIdentifier.ROOT}-${exports.PontEditIdentifier.ICON}`};qo([a({type:String})],exports.PontEditIdentifier.prototype,"seed",2);qo([a({type:String,attribute:"custom-id"})],exports.PontEditIdentifier.prototype,"customId",2);qo([a({type:String})],exports.PontEditIdentifier.prototype,"identifier",2);qo([a({type:String})],exports.PontEditIdentifier.prototype,"event",2);exports.PontEditIdentifier=qo([p("pont-edit-identifier")],exports.PontEditIdentifier);function r1(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var Pn={},vs,Fc;function n1(){return Fc||(Fc=1,vs=function(){return typeof Promise=="function"&&Promise.prototype&&Promise.prototype.then}),vs}var bs={},hr={},kc;function ln(){if(kc)return hr;kc=1;let e;const t=[0,26,44,70,100,134,172,196,242,292,346,404,466,532,581,655,733,815,901,991,1085,1156,1258,1364,1474,1588,1706,1828,1921,2051,2185,2323,2465,2611,2761,2876,3034,3196,3362,3532,3706];return hr.getSymbolSize=function(o){if(!o)throw new Error('"version" cannot be null or undefined');if(o<1||o>40)throw new Error('"version" should be in range from 1 to 40');return o*4+17},hr.getSymbolTotalCodewords=function(o){return t[o]},hr.getBCHDigit=function(r){let o=0;for(;r!==0;)o++,r>>>=1;return o},hr.setToSJISFunction=function(o){if(typeof o!="function")throw new Error('"toSJISFunc" is not a valid function.');e=o},hr.isKanjiModeEnabled=function(){return typeof e<"u"},hr.toSJIS=function(o){return e(o)},hr}var ys={},Nc;function _l(){return Nc||(Nc=1,(function(e){e.L={bit:1},e.M={bit:0},e.Q={bit:3},e.H={bit:2};function t(r){if(typeof r!="string")throw new Error("Param is not a string");switch(r.toLowerCase()){case"l":case"low":return e.L;case"m":case"medium":return e.M;case"q":case"quartile":return e.Q;case"h":case"high":return e.H;default:throw new Error("Unknown EC Level: "+r)}}e.isValid=function(o){return o&&typeof o.bit<"u"&&o.bit>=0&&o.bit<4},e.from=function(o,n){if(e.isValid(o))return o;try{return t(o)}catch{return n}}})(ys)),ys}var _s,Mc;function o1(){if(Mc)return _s;Mc=1;function e(){this.buffer=[],this.length=0}return e.prototype={get:function(t){const r=Math.floor(t/8);return(this.buffer[r]>>>7-t%8&1)===1},put:function(t,r){for(let o=0;o<r;o++)this.putBit((t>>>r-o-1&1)===1)},getLengthInBits:function(){return this.length},putBit:function(t){const r=Math.floor(this.length/8);this.buffer.length<=r&&this.buffer.push(0),t&&(this.buffer[r]|=128>>>this.length%8),this.length++}},_s=e,_s}var ws,Bc;function i1(){if(Bc)return ws;Bc=1;function e(t){if(!t||t<1)throw new Error("BitMatrix size must be defined and greater than 0");this.size=t,this.data=new Uint8Array(t*t),this.reservedBit=new Uint8Array(t*t)}return e.prototype.set=function(t,r,o,n){const i=t*this.size+r;this.data[i]=o,n&&(this.reservedBit[i]=!0)},e.prototype.get=function(t,r){return this.data[t*this.size+r]},e.prototype.xor=function(t,r,o){this.data[t*this.size+r]^=o},e.prototype.isReserved=function(t,r){return this.reservedBit[t*this.size+r]},ws=e,ws}var $s={},Uc;function s1(){return Uc||(Uc=1,(function(e){const t=ln().getSymbolSize;e.getRowColCoords=function(o){if(o===1)return[];const n=Math.floor(o/7)+2,i=t(o),s=i===145?26:Math.ceil((i-13)/(2*n-2))*2,d=[i-7];for(let c=1;c<n-1;c++)d[c]=d[c-1]-s;return d.push(6),d.reverse()},e.getPositions=function(o){const n=[],i=e.getRowColCoords(o),s=i.length;for(let d=0;d<s;d++)for(let c=0;c<s;c++)d===0&&c===0||d===0&&c===s-1||d===s-1&&c===0||n.push([i[d],i[c]]);return n}})($s)),$s}var Ps={},qc;function a1(){if(qc)return Ps;qc=1;const e=ln().getSymbolSize,t=7;return Ps.getPositions=function(o){const n=e(o);return[[0,0],[n-t,0],[0,n-t]]},Ps}var Cs={},jc;function l1(){return jc||(jc=1,(function(e){e.Patterns={PATTERN000:0,PATTERN001:1,PATTERN010:2,PATTERN011:3,PATTERN100:4,PATTERN101:5,PATTERN110:6,PATTERN111:7};const t={N1:3,N2:3,N3:40,N4:10};e.isValid=function(n){return n!=null&&n!==""&&!isNaN(n)&&n>=0&&n<=7},e.from=function(n){return e.isValid(n)?parseInt(n,10):void 0},e.getPenaltyN1=function(n){const i=n.size;let s=0,d=0,c=0,u=null,v=null;for(let y=0;y<i;y++){d=c=0,u=v=null;for(let w=0;w<i;w++){let b=n.get(y,w);b===u?d++:(d>=5&&(s+=t.N1+(d-5)),u=b,d=1),b=n.get(w,y),b===v?c++:(c>=5&&(s+=t.N1+(c-5)),v=b,c=1)}d>=5&&(s+=t.N1+(d-5)),c>=5&&(s+=t.N1+(c-5))}return s},e.getPenaltyN2=function(n){const i=n.size;let s=0;for(let d=0;d<i-1;d++)for(let c=0;c<i-1;c++){const u=n.get(d,c)+n.get(d,c+1)+n.get(d+1,c)+n.get(d+1,c+1);(u===4||u===0)&&s++}return s*t.N2},e.getPenaltyN3=function(n){const i=n.size;let s=0,d=0,c=0;for(let u=0;u<i;u++){d=c=0;for(let v=0;v<i;v++)d=d<<1&2047|n.get(u,v),v>=10&&(d===1488||d===93)&&s++,c=c<<1&2047|n.get(v,u),v>=10&&(c===1488||c===93)&&s++}return s*t.N3},e.getPenaltyN4=function(n){let i=0;const s=n.data.length;for(let c=0;c<s;c++)i+=n.data[c];return Math.abs(Math.ceil(i*100/s/5)-10)*t.N4};function r(o,n,i){switch(o){case e.Patterns.PATTERN000:return(n+i)%2===0;case e.Patterns.PATTERN001:return n%2===0;case e.Patterns.PATTERN010:return i%3===0;case e.Patterns.PATTERN011:return(n+i)%3===0;case e.Patterns.PATTERN100:return(Math.floor(n/2)+Math.floor(i/3))%2===0;case e.Patterns.PATTERN101:return n*i%2+n*i%3===0;case e.Patterns.PATTERN110:return(n*i%2+n*i%3)%2===0;case e.Patterns.PATTERN111:return(n*i%3+(n+i)%2)%2===0;default:throw new Error("bad maskPattern:"+o)}}e.applyMask=function(n,i){const s=i.size;for(let d=0;d<s;d++)for(let c=0;c<s;c++)i.isReserved(c,d)||i.xor(c,d,r(n,c,d))},e.getBestMask=function(n,i){const s=Object.keys(e.Patterns).length;let d=0,c=1/0;for(let u=0;u<s;u++){i(u),e.applyMask(u,n);const v=e.getPenaltyN1(n)+e.getPenaltyN2(n)+e.getPenaltyN3(n)+e.getPenaltyN4(n);e.applyMask(u,n),v<c&&(c=v,d=u)}return d}})(Cs)),Cs}var Go={},zc;function jh(){if(zc)return Go;zc=1;const e=_l(),t=[1,1,1,1,1,1,1,1,1,1,2,2,1,2,2,4,1,2,4,4,2,4,4,4,2,4,6,5,2,4,6,6,2,5,8,8,4,5,8,8,4,5,8,11,4,8,10,11,4,9,12,16,4,9,16,16,6,10,12,18,6,10,17,16,6,11,16,19,6,13,18,21,7,14,21,25,8,16,20,25,8,17,23,25,9,17,23,34,9,18,25,30,10,20,27,32,12,21,29,35,12,23,34,37,12,25,34,40,13,26,35,42,14,28,38,45,15,29,40,48,16,31,43,51,17,33,45,54,18,35,48,57,19,37,51,60,19,38,53,63,20,40,56,66,21,43,59,70,22,45,62,74,24,47,65,77,25,49,68,81],r=[7,10,13,17,10,16,22,28,15,26,36,44,20,36,52,64,26,48,72,88,36,64,96,112,40,72,108,130,48,88,132,156,60,110,160,192,72,130,192,224,80,150,224,264,96,176,260,308,104,198,288,352,120,216,320,384,132,240,360,432,144,280,408,480,168,308,448,532,180,338,504,588,196,364,546,650,224,416,600,700,224,442,644,750,252,476,690,816,270,504,750,900,300,560,810,960,312,588,870,1050,336,644,952,1110,360,700,1020,1200,390,728,1050,1260,420,784,1140,1350,450,812,1200,1440,480,868,1290,1530,510,924,1350,1620,540,980,1440,1710,570,1036,1530,1800,570,1064,1590,1890,600,1120,1680,1980,630,1204,1770,2100,660,1260,1860,2220,720,1316,1950,2310,750,1372,2040,2430];return Go.getBlocksCount=function(n,i){switch(i){case e.L:return t[(n-1)*4+0];case e.M:return t[(n-1)*4+1];case e.Q:return t[(n-1)*4+2];case e.H:return t[(n-1)*4+3];default:return}},Go.getTotalCodewordsCount=function(n,i){switch(i){case e.L:return r[(n-1)*4+0];case e.M:return r[(n-1)*4+1];case e.Q:return r[(n-1)*4+2];case e.H:return r[(n-1)*4+3];default:return}},Go}var Es={},so={},Vc;function d1(){if(Vc)return so;Vc=1;const e=new Uint8Array(512),t=new Uint8Array(256);return(function(){let o=1;for(let n=0;n<255;n++)e[n]=o,t[o]=n,o<<=1,o&256&&(o^=285);for(let n=255;n<512;n++)e[n]=e[n-255]})(),so.log=function(o){if(o<1)throw new Error("log("+o+")");return t[o]},so.exp=function(o){return e[o]},so.mul=function(o,n){return o===0||n===0?0:e[t[o]+t[n]]},so}var Hc;function c1(){return Hc||(Hc=1,(function(e){const t=d1();e.mul=function(o,n){const i=new Uint8Array(o.length+n.length-1);for(let s=0;s<o.length;s++)for(let d=0;d<n.length;d++)i[s+d]^=t.mul(o[s],n[d]);return i},e.mod=function(o,n){let i=new Uint8Array(o);for(;i.length-n.length>=0;){const s=i[0];for(let c=0;c<n.length;c++)i[c]^=t.mul(n[c],s);let d=0;for(;d<i.length&&i[d]===0;)d++;i=i.slice(d)}return i},e.generateECPolynomial=function(o){let n=new Uint8Array([1]);for(let i=0;i<o;i++)n=e.mul(n,new Uint8Array([1,t.exp(i)]));return n}})(Es)),Es}var Ss,Gc;function p1(){if(Gc)return Ss;Gc=1;const e=c1();function t(r){this.genPoly=void 0,this.degree=r,this.degree&&this.initialize(this.degree)}return t.prototype.initialize=function(o){this.degree=o,this.genPoly=e.generateECPolynomial(this.degree)},t.prototype.encode=function(o){if(!this.genPoly)throw new Error("Encoder not initialized");const n=new Uint8Array(o.length+this.degree);n.set(o);const i=e.mod(n,this.genPoly),s=this.degree-i.length;if(s>0){const d=new Uint8Array(this.degree);return d.set(i,s),d}return i},Ss=t,Ss}var xs={},Os={},Rs={},Kc;function zh(){return Kc||(Kc=1,Rs.isValid=function(t){return!isNaN(t)&&t>=1&&t<=40}),Rs}var _e={},Wc;function Vh(){if(Wc)return _e;Wc=1;const e="[0-9]+",t="[A-Z $%*+\\-./:]+";let r="(?:[u3000-u303F]|[u3040-u309F]|[u30A0-u30FF]|[uFF00-uFFEF]|[u4E00-u9FAF]|[u2605-u2606]|[u2190-u2195]|u203B|[u2010u2015u2018u2019u2025u2026u201Cu201Du2225u2260]|[u0391-u0451]|[u00A7u00A8u00B1u00B4u00D7u00F7])+";r=r.replace(/u/g,"\\u");const o="(?:(?![A-Z0-9 $%*+\\-./:]|"+r+`)(?:.|[\r
|
|
3370
|
+
]))+`;_e.KANJI=new RegExp(r,"g"),_e.BYTE_KANJI=new RegExp("[^A-Z0-9 $%*+\\-./:]+","g"),_e.BYTE=new RegExp(o,"g"),_e.NUMERIC=new RegExp(e,"g"),_e.ALPHANUMERIC=new RegExp(t,"g");const n=new RegExp("^"+r+"$"),i=new RegExp("^"+e+"$"),s=new RegExp("^[A-Z0-9 $%*+\\-./:]+$");return _e.testKanji=function(c){return n.test(c)},_e.testNumeric=function(c){return i.test(c)},_e.testAlphanumeric=function(c){return s.test(c)},_e}var Yc;function dn(){return Yc||(Yc=1,(function(e){const t=zh(),r=Vh();e.NUMERIC={id:"Numeric",bit:1,ccBits:[10,12,14]},e.ALPHANUMERIC={id:"Alphanumeric",bit:2,ccBits:[9,11,13]},e.BYTE={id:"Byte",bit:4,ccBits:[8,16,16]},e.KANJI={id:"Kanji",bit:8,ccBits:[8,10,12]},e.MIXED={bit:-1},e.getCharCountIndicator=function(i,s){if(!i.ccBits)throw new Error("Invalid mode: "+i);if(!t.isValid(s))throw new Error("Invalid version: "+s);return s>=1&&s<10?i.ccBits[0]:s<27?i.ccBits[1]:i.ccBits[2]},e.getBestModeForData=function(i){return r.testNumeric(i)?e.NUMERIC:r.testAlphanumeric(i)?e.ALPHANUMERIC:r.testKanji(i)?e.KANJI:e.BYTE},e.toString=function(i){if(i&&i.id)return i.id;throw new Error("Invalid mode")},e.isValid=function(i){return i&&i.bit&&i.ccBits};function o(n){if(typeof n!="string")throw new Error("Param is not a string");switch(n.toLowerCase()){case"numeric":return e.NUMERIC;case"alphanumeric":return e.ALPHANUMERIC;case"kanji":return e.KANJI;case"byte":return e.BYTE;default:throw new Error("Unknown mode: "+n)}}e.from=function(i,s){if(e.isValid(i))return i;try{return o(i)}catch{return s}}})(Os)),Os}var Qc;function h1(){return Qc||(Qc=1,(function(e){const t=ln(),r=jh(),o=_l(),n=dn(),i=zh(),s=7973,d=t.getBCHDigit(s);function c(w,b,C){for(let P=1;P<=40;P++)if(b<=e.getCapacity(P,C,w))return P}function u(w,b){return n.getCharCountIndicator(w,b)+4}function v(w,b){let C=0;return w.forEach(function(P){const O=u(P.mode,b);C+=O+P.getBitsLength()}),C}function y(w,b){for(let C=1;C<=40;C++)if(v(w,C)<=e.getCapacity(C,b,n.MIXED))return C}e.from=function(b,C){return i.isValid(b)?parseInt(b,10):C},e.getCapacity=function(b,C,P){if(!i.isValid(b))throw new Error("Invalid QR Code version");typeof P>"u"&&(P=n.BYTE);const O=t.getSymbolTotalCodewords(b),S=r.getTotalCodewordsCount(b,C),D=(O-S)*8;if(P===n.MIXED)return D;const L=D-u(P,b);switch(P){case n.NUMERIC:return Math.floor(L/10*3);case n.ALPHANUMERIC:return Math.floor(L/11*2);case n.KANJI:return Math.floor(L/13);case n.BYTE:default:return Math.floor(L/8)}},e.getBestVersionForData=function(b,C){let P;const O=o.from(C,o.M);if(Array.isArray(b)){if(b.length>1)return y(b,O);if(b.length===0)return 1;P=b[0]}else P=b;return c(P.mode,P.getLength(),O)},e.getEncodedBits=function(b){if(!i.isValid(b)||b<7)throw new Error("Invalid QR Code version");let C=b<<12;for(;t.getBCHDigit(C)-d>=0;)C^=s<<t.getBCHDigit(C)-d;return b<<12|C}})(xs)),xs}var Is={},Zc;function u1(){if(Zc)return Is;Zc=1;const e=ln(),t=1335,r=21522,o=e.getBCHDigit(t);return Is.getEncodedBits=function(i,s){const d=i.bit<<3|s;let c=d<<10;for(;e.getBCHDigit(c)-o>=0;)c^=t<<e.getBCHDigit(c)-o;return(d<<10|c)^r},Is}var As={},Ts,Jc;function m1(){if(Jc)return Ts;Jc=1;const e=dn();function t(r){this.mode=e.NUMERIC,this.data=r.toString()}return t.getBitsLength=function(o){return 10*Math.floor(o/3)+(o%3?o%3*3+1:0)},t.prototype.getLength=function(){return this.data.length},t.prototype.getBitsLength=function(){return t.getBitsLength(this.data.length)},t.prototype.write=function(o){let n,i,s;for(n=0;n+3<=this.data.length;n+=3)i=this.data.substr(n,3),s=parseInt(i,10),o.put(s,10);const d=this.data.length-n;d>0&&(i=this.data.substr(n),s=parseInt(i,10),o.put(s,d*3+1))},Ts=t,Ts}var Ds,Xc;function g1(){if(Xc)return Ds;Xc=1;const e=dn(),t=["0","1","2","3","4","5","6","7","8","9","A","B","C","D","E","F","G","H","I","J","K","L","M","N","O","P","Q","R","S","T","U","V","W","X","Y","Z"," ","$","%","*","+","-",".","/",":"];function r(o){this.mode=e.ALPHANUMERIC,this.data=o}return r.getBitsLength=function(n){return 11*Math.floor(n/2)+6*(n%2)},r.prototype.getLength=function(){return this.data.length},r.prototype.getBitsLength=function(){return r.getBitsLength(this.data.length)},r.prototype.write=function(n){let i;for(i=0;i+2<=this.data.length;i+=2){let s=t.indexOf(this.data[i])*45;s+=t.indexOf(this.data[i+1]),n.put(s,11)}this.data.length%2&&n.put(t.indexOf(this.data[i]),6)},Ds=r,Ds}var Ls,tp;function f1(){if(tp)return Ls;tp=1;const e=dn();function t(r){this.mode=e.BYTE,typeof r=="string"?this.data=new TextEncoder().encode(r):this.data=new Uint8Array(r)}return t.getBitsLength=function(o){return o*8},t.prototype.getLength=function(){return this.data.length},t.prototype.getBitsLength=function(){return t.getBitsLength(this.data.length)},t.prototype.write=function(r){for(let o=0,n=this.data.length;o<n;o++)r.put(this.data[o],8)},Ls=t,Ls}var Fs,ep;function v1(){if(ep)return Fs;ep=1;const e=dn(),t=ln();function r(o){this.mode=e.KANJI,this.data=o}return r.getBitsLength=function(n){return n*13},r.prototype.getLength=function(){return this.data.length},r.prototype.getBitsLength=function(){return r.getBitsLength(this.data.length)},r.prototype.write=function(o){let n;for(n=0;n<this.data.length;n++){let i=t.toSJIS(this.data[n]);if(i>=33088&&i<=40956)i-=33088;else if(i>=57408&&i<=60351)i-=49472;else throw new Error("Invalid SJIS character: "+this.data[n]+`
|
|
3371
|
+
Make sure your charset is UTF-8`);i=(i>>>8&255)*192+(i&255),o.put(i,13)}},Fs=r,Fs}var ks={exports:{}},rp;function b1(){return rp||(rp=1,(function(e){var t={single_source_shortest_paths:function(r,o,n){var i={},s={};s[o]=0;var d=t.PriorityQueue.make();d.push(o,0);for(var c,u,v,y,w,b,C,P,O;!d.empty();){c=d.pop(),u=c.value,y=c.cost,w=r[u]||{};for(v in w)w.hasOwnProperty(v)&&(b=w[v],C=y+b,P=s[v],O=typeof s[v]>"u",(O||P>C)&&(s[v]=C,d.push(v,C),i[v]=u))}if(typeof n<"u"&&typeof s[n]>"u"){var S=["Could not find a path from ",o," to ",n,"."].join("");throw new Error(S)}return i},extract_shortest_path_from_predecessor_list:function(r,o){for(var n=[],i=o;i;)n.push(i),r[i],i=r[i];return n.reverse(),n},find_path:function(r,o,n){var i=t.single_source_shortest_paths(r,o,n);return t.extract_shortest_path_from_predecessor_list(i,n)},PriorityQueue:{make:function(r){var o=t.PriorityQueue,n={},i;r=r||{};for(i in o)o.hasOwnProperty(i)&&(n[i]=o[i]);return n.queue=[],n.sorter=r.sorter||o.default_sorter,n},default_sorter:function(r,o){return r.cost-o.cost},push:function(r,o){var n={value:r,cost:o};this.queue.push(n),this.queue.sort(this.sorter)},pop:function(){return this.queue.shift()},empty:function(){return this.queue.length===0}}};e.exports=t})(ks)),ks.exports}var np;function y1(){return np||(np=1,(function(e){const t=dn(),r=m1(),o=g1(),n=f1(),i=v1(),s=Vh(),d=ln(),c=b1();function u(S){return unescape(encodeURIComponent(S)).length}function v(S,D,L){const I=[];let Q;for(;(Q=S.exec(L))!==null;)I.push({data:Q[0],index:Q.index,mode:D,length:Q[0].length});return I}function y(S){const D=v(s.NUMERIC,t.NUMERIC,S),L=v(s.ALPHANUMERIC,t.ALPHANUMERIC,S);let I,Q;return d.isKanjiModeEnabled()?(I=v(s.BYTE,t.BYTE,S),Q=v(s.KANJI,t.KANJI,S)):(I=v(s.BYTE_KANJI,t.BYTE,S),Q=[]),D.concat(L,I,Q).sort(function(A,T){return A.index-T.index}).map(function(A){return{data:A.data,mode:A.mode,length:A.length}})}function w(S,D){switch(D){case t.NUMERIC:return r.getBitsLength(S);case t.ALPHANUMERIC:return o.getBitsLength(S);case t.KANJI:return i.getBitsLength(S);case t.BYTE:return n.getBitsLength(S)}}function b(S){return S.reduce(function(D,L){const I=D.length-1>=0?D[D.length-1]:null;return I&&I.mode===L.mode?(D[D.length-1].data+=L.data,D):(D.push(L),D)},[])}function C(S){const D=[];for(let L=0;L<S.length;L++){const I=S[L];switch(I.mode){case t.NUMERIC:D.push([I,{data:I.data,mode:t.ALPHANUMERIC,length:I.length},{data:I.data,mode:t.BYTE,length:I.length}]);break;case t.ALPHANUMERIC:D.push([I,{data:I.data,mode:t.BYTE,length:I.length}]);break;case t.KANJI:D.push([I,{data:I.data,mode:t.BYTE,length:u(I.data)}]);break;case t.BYTE:D.push([{data:I.data,mode:t.BYTE,length:u(I.data)}])}}return D}function P(S,D){const L={},I={start:{}};let Q=["start"];for(let R=0;R<S.length;R++){const A=S[R],T=[];for(let x=0;x<A.length;x++){const N=A[x],F=""+R+x;T.push(F),L[F]={node:N,lastCount:0},I[F]={};for(let $=0;$<Q.length;$++){const k=Q[$];L[k]&&L[k].node.mode===N.mode?(I[k][F]=w(L[k].lastCount+N.length,N.mode)-w(L[k].lastCount,N.mode),L[k].lastCount+=N.length):(L[k]&&(L[k].lastCount=N.length),I[k][F]=w(N.length,N.mode)+4+t.getCharCountIndicator(N.mode,D))}}Q=T}for(let R=0;R<Q.length;R++)I[Q[R]].end=0;return{map:I,table:L}}function O(S,D){let L;const I=t.getBestModeForData(S);if(L=t.from(D,I),L!==t.BYTE&&L.bit<I.bit)throw new Error('"'+S+'" cannot be encoded with mode '+t.toString(L)+`.
|
|
3372
|
+
Suggested mode is: `+t.toString(I));switch(L===t.KANJI&&!d.isKanjiModeEnabled()&&(L=t.BYTE),L){case t.NUMERIC:return new r(S);case t.ALPHANUMERIC:return new o(S);case t.KANJI:return new i(S);case t.BYTE:return new n(S)}}e.fromArray=function(D){return D.reduce(function(L,I){return typeof I=="string"?L.push(O(I,null)):I.data&&L.push(O(I.data,I.mode)),L},[])},e.fromString=function(D,L){const I=y(D,d.isKanjiModeEnabled()),Q=C(I),R=P(Q,L),A=c.find_path(R.map,"start","end"),T=[];for(let x=1;x<A.length-1;x++)T.push(R.table[A[x]].node);return e.fromArray(b(T))},e.rawSplit=function(D){return e.fromArray(y(D,d.isKanjiModeEnabled()))}})(As)),As}var op;function _1(){if(op)return bs;op=1;const e=ln(),t=_l(),r=o1(),o=i1(),n=s1(),i=a1(),s=l1(),d=jh(),c=p1(),u=h1(),v=u1(),y=dn(),w=y1();function b(R,A){const T=R.size,x=i.getPositions(A);for(let N=0;N<x.length;N++){const F=x[N][0],$=x[N][1];for(let k=-1;k<=7;k++)if(!(F+k<=-1||T<=F+k))for(let M=-1;M<=7;M++)$+M<=-1||T<=$+M||(k>=0&&k<=6&&(M===0||M===6)||M>=0&&M<=6&&(k===0||k===6)||k>=2&&k<=4&&M>=2&&M<=4?R.set(F+k,$+M,!0,!0):R.set(F+k,$+M,!1,!0))}}function C(R){const A=R.size;for(let T=8;T<A-8;T++){const x=T%2===0;R.set(T,6,x,!0),R.set(6,T,x,!0)}}function P(R,A){const T=n.getPositions(A);for(let x=0;x<T.length;x++){const N=T[x][0],F=T[x][1];for(let $=-2;$<=2;$++)for(let k=-2;k<=2;k++)$===-2||$===2||k===-2||k===2||$===0&&k===0?R.set(N+$,F+k,!0,!0):R.set(N+$,F+k,!1,!0)}}function O(R,A){const T=R.size,x=u.getEncodedBits(A);let N,F,$;for(let k=0;k<18;k++)N=Math.floor(k/3),F=k%3+T-8-3,$=(x>>k&1)===1,R.set(N,F,$,!0),R.set(F,N,$,!0)}function S(R,A,T){const x=R.size,N=v.getEncodedBits(A,T);let F,$;for(F=0;F<15;F++)$=(N>>F&1)===1,F<6?R.set(F,8,$,!0):F<8?R.set(F+1,8,$,!0):R.set(x-15+F,8,$,!0),F<8?R.set(8,x-F-1,$,!0):F<9?R.set(8,15-F-1+1,$,!0):R.set(8,15-F-1,$,!0);R.set(x-8,8,1,!0)}function D(R,A){const T=R.size;let x=-1,N=T-1,F=7,$=0;for(let k=T-1;k>0;k-=2)for(k===6&&k--;;){for(let M=0;M<2;M++)if(!R.isReserved(N,k-M)){let ne=!1;$<A.length&&(ne=(A[$]>>>F&1)===1),R.set(N,k-M,ne),F--,F===-1&&($++,F=7)}if(N+=x,N<0||T<=N){N-=x,x=-x;break}}}function L(R,A,T){const x=new r;T.forEach(function(M){x.put(M.mode.bit,4),x.put(M.getLength(),y.getCharCountIndicator(M.mode,R)),M.write(x)});const N=e.getSymbolTotalCodewords(R),F=d.getTotalCodewordsCount(R,A),$=(N-F)*8;for(x.getLengthInBits()+4<=$&&x.put(0,4);x.getLengthInBits()%8!==0;)x.putBit(0);const k=($-x.getLengthInBits())/8;for(let M=0;M<k;M++)x.put(M%2?17:236,8);return I(x,R,A)}function I(R,A,T){const x=e.getSymbolTotalCodewords(A),N=d.getTotalCodewordsCount(A,T),F=x-N,$=d.getBlocksCount(A,T),k=x%$,M=$-k,ne=Math.floor(x/$),ye=Math.floor(F/$),Ho=ye+1,un=ne-ye,Ar=new c(un);let mn=0;const Tt=new Array($),Al=new Array($);let ns=0;const iu=new Uint8Array(R.buffer);for(let gn=0;gn<$;gn++){const is=gn<M?ye:Ho;Tt[gn]=iu.slice(mn,mn+is),Al[gn]=Ar.encode(Tt[gn]),mn+=is,ns=Math.max(ns,is)}const os=new Uint8Array(x);let Tl=0,We,Ye;for(We=0;We<ns;We++)for(Ye=0;Ye<$;Ye++)We<Tt[Ye].length&&(os[Tl++]=Tt[Ye][We]);for(We=0;We<un;We++)for(Ye=0;Ye<$;Ye++)os[Tl++]=Al[Ye][We];return os}function Q(R,A,T,x){let N;if(Array.isArray(R))N=w.fromArray(R);else if(typeof R=="string"){let ne=A;if(!ne){const ye=w.rawSplit(R);ne=u.getBestVersionForData(ye,T)}N=w.fromString(R,ne||40)}else throw new Error("Invalid data");const F=u.getBestVersionForData(N,T);if(!F)throw new Error("The amount of data is too big to be stored in a QR Code");if(!A)A=F;else if(A<F)throw new Error(`
|
|
3373
3373
|
The chosen QR Code version cannot contain this amount of data.
|
|
3374
3374
|
Minimum version required to store current data is: `+F+`.
|
|
3375
|
-
`);const $=L(A,T,N),k=e.getSymbolSize(A),M=new o(k);return
|
|
3376
|
-
`;return typeof d=="function"&&d(null,O),O},Bs}var lp;function P1(){if(lp)return Pn;lp=1;const e=n1(),t=_1(),r=w1(),o=$1();function n(i,s,d,c,u){const v=[].slice.call(arguments,1),
|
|
3375
|
+
`);const $=L(A,T,N),k=e.getSymbolSize(A),M=new o(k);return b(M,A),C(M),P(M,A),S(M,T,0),A>=7&&O(M,A),D(M,$),isNaN(x)&&(x=s.getBestMask(M,S.bind(null,M,T))),s.applyMask(x,M),S(M,T,x),{modules:M,version:A,errorCorrectionLevel:T,maskPattern:x,segments:N}}return bs.create=function(A,T){if(typeof A>"u"||A==="")throw new Error("No input text");let x=t.M,N,F;return typeof T<"u"&&(x=t.from(T.errorCorrectionLevel,t.M),N=u.from(T.version),F=s.from(T.maskPattern),T.toSJISFunc&&e.setToSJISFunction(T.toSJISFunc)),Q(A,N,x,F)},bs}var Ns={},Ms={},ip;function Hh(){return ip||(ip=1,(function(e){function t(r){if(typeof r=="number"&&(r=r.toString()),typeof r!="string")throw new Error("Color should be defined as hex string");let o=r.slice().replace("#","").split("");if(o.length<3||o.length===5||o.length>8)throw new Error("Invalid hex color: "+r);(o.length===3||o.length===4)&&(o=Array.prototype.concat.apply([],o.map(function(i){return[i,i]}))),o.length===6&&o.push("F","F");const n=parseInt(o.join(""),16);return{r:n>>24&255,g:n>>16&255,b:n>>8&255,a:n&255,hex:"#"+o.slice(0,6).join("")}}e.getOptions=function(o){o||(o={}),o.color||(o.color={});const n=typeof o.margin>"u"||o.margin===null||o.margin<0?4:o.margin,i=o.width&&o.width>=21?o.width:void 0,s=o.scale||4;return{width:i,scale:i?4:s,margin:n,color:{dark:t(o.color.dark||"#000000ff"),light:t(o.color.light||"#ffffffff")},type:o.type,rendererOpts:o.rendererOpts||{}}},e.getScale=function(o,n){return n.width&&n.width>=o+n.margin*2?n.width/(o+n.margin*2):n.scale},e.getImageWidth=function(o,n){const i=e.getScale(o,n);return Math.floor((o+n.margin*2)*i)},e.qrToImageData=function(o,n,i){const s=n.modules.size,d=n.modules.data,c=e.getScale(s,i),u=Math.floor((s+i.margin*2)*c),v=i.margin*c,y=[i.color.light,i.color.dark];for(let w=0;w<u;w++)for(let b=0;b<u;b++){let C=(w*u+b)*4,P=i.color.light;if(w>=v&&b>=v&&w<u-v&&b<u-v){const O=Math.floor((w-v)/c),S=Math.floor((b-v)/c);P=y[d[O*s+S]?1:0]}o[C++]=P.r,o[C++]=P.g,o[C++]=P.b,o[C]=P.a}}})(Ms)),Ms}var sp;function w1(){return sp||(sp=1,(function(e){const t=Hh();function r(n,i,s){n.clearRect(0,0,i.width,i.height),i.style||(i.style={}),i.height=s,i.width=s,i.style.height=s+"px",i.style.width=s+"px"}function o(){try{return document.createElement("canvas")}catch{throw new Error("You need to specify a canvas element")}}e.render=function(i,s,d){let c=d,u=s;typeof c>"u"&&(!s||!s.getContext)&&(c=s,s=void 0),s||(u=o()),c=t.getOptions(c);const v=t.getImageWidth(i.modules.size,c),y=u.getContext("2d"),w=y.createImageData(v,v);return t.qrToImageData(w.data,i,c),r(y,u,v),y.putImageData(w,0,0),u},e.renderToDataURL=function(i,s,d){let c=d;typeof c>"u"&&(!s||!s.getContext)&&(c=s,s=void 0),c||(c={});const u=e.render(i,s,c),v=c.type||"image/png",y=c.rendererOpts||{};return u.toDataURL(v,y.quality)}})(Ns)),Ns}var Bs={},ap;function $1(){if(ap)return Bs;ap=1;const e=Hh();function t(n,i){const s=n.a/255,d=i+'="'+n.hex+'"';return s<1?d+" "+i+'-opacity="'+s.toFixed(2).slice(1)+'"':d}function r(n,i,s){let d=n+i;return typeof s<"u"&&(d+=" "+s),d}function o(n,i,s){let d="",c=0,u=!1,v=0;for(let y=0;y<n.length;y++){const w=Math.floor(y%i),b=Math.floor(y/i);!w&&!u&&(u=!0),n[y]?(v++,y>0&&w>0&&n[y-1]||(d+=u?r("M",w+s,.5+b+s):r("m",c,0),c=0,u=!1),w+1<i&&n[y+1]||(d+=r("h",v),v=0)):c++}return d}return Bs.render=function(i,s,d){const c=e.getOptions(s),u=i.modules.size,v=i.modules.data,y=u+c.margin*2,w=c.color.light.a?"<path "+t(c.color.light,"fill")+' d="M0 0h'+y+"v"+y+'H0z"/>':"",b="<path "+t(c.color.dark,"stroke")+' d="'+o(v,u,c.margin)+'"/>',C='viewBox="0 0 '+y+" "+y+'"',O='<svg xmlns="http://www.w3.org/2000/svg" '+(c.width?'width="'+c.width+'" height="'+c.width+'" ':"")+C+' shape-rendering="crispEdges">'+w+b+`</svg>
|
|
3376
|
+
`;return typeof d=="function"&&d(null,O),O},Bs}var lp;function P1(){if(lp)return Pn;lp=1;const e=n1(),t=_1(),r=w1(),o=$1();function n(i,s,d,c,u){const v=[].slice.call(arguments,1),y=v.length,w=typeof v[y-1]=="function";if(!w&&!e())throw new Error("Callback required as last argument");if(w){if(y<2)throw new Error("Too few arguments provided");y===2?(u=d,d=s,s=c=void 0):y===3&&(s.getContext&&typeof u>"u"?(u=c,c=void 0):(u=c,c=d,d=s,s=void 0))}else{if(y<1)throw new Error("Too few arguments provided");return y===1?(d=s,s=c=void 0):y===2&&!s.getContext&&(c=d,d=s,s=void 0),new Promise(function(b,C){try{const P=t.create(d,c);b(i(P,s,c))}catch(P){C(P)}})}try{const b=t.create(d,c);u(null,i(b,s,c))}catch(b){u(b)}}return Pn.create=t.create,Pn.toCanvas=n.bind(null,r.render),Pn.toDataURL=n.bind(null,r.renderToDataURL),Pn.toString=n.bind(null,function(i,s,d){return o.render(i,d)}),Pn}var C1=P1();const E1=r1(C1),Ko={url:"",timeout:10,reappearButtonText:"Show QR Code",errorCorrection:"M"};var S1=Object.defineProperty,x1=Object.getOwnPropertyDescriptor,ar=(e,t,r,o)=>{for(var n=o>1?void 0:o?x1(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&S1(t,r,n),n};exports.PontQrCode=class extends f{constructor(){super(...arguments),this.seed=_t(),this.url=Ko.url,this.timeout=Ko.timeout,this.reappearButtonText=Ko.reappearButtonText,this.disabled=!1,this.errorCorrection=Ko.errorCorrection,this._obscured=!1,this._canvasElement=null,this._handleReappear=()=>{this.disabled||(this._obscured=!1,this._clearTimer(),this._startTimer(),this.emit("pont-qr:reappear",{id:this.rootId,url:this.url}))}}createRenderRoot(){return this}get rootId(){return this.customId??`${exports.PontQrCode.TAG}-${this.seed}`}get canvasId(){return`${this.rootId}-${exports.PontQrCode.QR_CANVAS}`}get overlayId(){return`${this.rootId}-${exports.PontQrCode.OVERLAY}`}get reappearButtonId(){return`${this.rootId}-${exports.PontQrCode.REAPPEAR_BUTTON}`}connectedCallback(){super.connectedCallback(),this._startTimer()}disconnectedCallback(){super.disconnectedCallback(),this._clearTimer()}firstUpdated(){const t=this.querySelector(`#${this.canvasId}`);t&&(this._canvasElement=t,this._renderQR())}updated(t){(t.has("url")||t.has("errorCorrection"))&&(this._renderQR(),this._obscured=!1,this._clearTimer(),this._startTimer()),t.has("timeout")&&(this._clearTimer(),this._startTimer())}_startTimer(){this.timeout<=0||(this._clearTimer(),this._timer=window.setTimeout(()=>{this._obscured=!0,this._timer=void 0,this.emit("pont-qr:obscured",{id:this.rootId,url:this.url})},this.timeout*1e3))}_clearTimer(){this._timer&&(clearTimeout(this._timer),this._timer=void 0)}_renderQR(){if(!this._canvasElement||!this.url)return;const t=getComputedStyle(this),r=parseInt(t.getPropertyValue("--pont-qr-code-canvas-render-width"))||200,o=parseInt(t.getPropertyValue("--pont-qr-code-canvas-render-height"))||200;this._canvasElement.width=r,this._canvasElement.height=o;const n={errorCorrectionLevel:this.errorCorrection};E1.toCanvas(this._canvasElement,this.url,n,i=>{i&&(console.warn("QR generation failed:",i),this.emit("pont-qr:error",{error:i,url:this.url}))})}emit(t,r){this.dispatchEvent(new CustomEvent(t,{detail:r,bubbles:!0,composed:!0}))}render(){const t=this._obscured&&!this.disabled;return l`
|
|
3377
3377
|
<div
|
|
3378
3378
|
part=${exports.PontQrCode.PARTS.root}
|
|
3379
3379
|
id=${this.rootId}
|
|
@@ -4009,7 +4009,7 @@ Minimum version required to store current data is: `+F+`.
|
|
|
4009
4009
|
</pont-dropdown-menu-group>
|
|
4010
4010
|
</pont-dropdown-menu-content>
|
|
4011
4011
|
</pont-dropdown-menu>
|
|
4012
|
-
`}createRenderRoot(){return this}};jo([a({type:Array})],exports.PontMultiSelectFilter.prototype,"options",2);jo([a({type:Array})],exports.PontMultiSelectFilter.prototype,"selected",2);jo([a({type:String})],exports.PontMultiSelectFilter.prototype,"placeholder",2);jo([a({type:String})],exports.PontMultiSelectFilter.prototype,"label",2);exports.PontMultiSelectFilter=jo([p("pont-multi-select-filter")],exports.PontMultiSelectFilter);var $e=(e=>(e.PROFILE="Profile",e.SECURITY="Security",e.APPEARANCE="Appearance",e.NOTIFICATION="Notification",e))($e||{}),vr=(e=>(e.MODAL="MODAL",e.PAGE="PAGE",e))(vr||{}),tr=(e=>(e.BURGER="BURGER",e.REGULAR="REGULAR",e))(tr||{}),Mr=(e=>(e.VERTICAL="VERTICAL",e.HORIZONTAL="HORIZONTAL",e))(Mr||{}),nt=(e=>(e.COLUMN="COLUMN",e.ROW="ROW",e))(nt||{});const Qi="pont-account-settings-card-header-container",Po="pont-account-settings-card-title",Re="pont-account-settings-input-label pont-shrink-0 md:pont-block",Zi="pont-account-settings-card-container",Co=()=>l`<pont-typography-muted>Not Added</pont-typography-muted>`;let Na=null;function _0(e){Na=e}function w0(){return Na||console.warn("SDK environment not initialized. Call initSdk({...}) before using <pont-provider>."),Na}class $0 extends Error{constructor(t,r,o){super(t),this.name="ApiError",this.status=r,this.data=o}}const P0="/mgmt/v1";async function ge(e,t={}){var v,
|
|
4012
|
+
`}createRenderRoot(){return this}};jo([a({type:Array})],exports.PontMultiSelectFilter.prototype,"options",2);jo([a({type:Array})],exports.PontMultiSelectFilter.prototype,"selected",2);jo([a({type:String})],exports.PontMultiSelectFilter.prototype,"placeholder",2);jo([a({type:String})],exports.PontMultiSelectFilter.prototype,"label",2);exports.PontMultiSelectFilter=jo([p("pont-multi-select-filter")],exports.PontMultiSelectFilter);var $e=(e=>(e.PROFILE="Profile",e.SECURITY="Security",e.APPEARANCE="Appearance",e.NOTIFICATION="Notification",e))($e||{}),vr=(e=>(e.MODAL="MODAL",e.PAGE="PAGE",e))(vr||{}),tr=(e=>(e.BURGER="BURGER",e.REGULAR="REGULAR",e))(tr||{}),Mr=(e=>(e.VERTICAL="VERTICAL",e.HORIZONTAL="HORIZONTAL",e))(Mr||{}),nt=(e=>(e.COLUMN="COLUMN",e.ROW="ROW",e))(nt||{});const Qi="pont-account-settings-card-header-container",Po="pont-account-settings-card-title",Re="pont-account-settings-input-label pont-shrink-0 md:pont-block",Zi="pont-account-settings-card-container",Co=()=>l`<pont-typography-muted>Not Added</pont-typography-muted>`;let Na=null;function _0(e){Na=e}function w0(){return Na||console.warn("SDK environment not initialized. Call initSdk({...}) before using <pont-provider>."),Na}class $0 extends Error{constructor(t,r,o){super(t),this.name="ApiError",this.status=r,this.data=o}}const P0="/mgmt/v1";async function ge(e,t={}){var v,y;const{token:r,headers:o,...n}=t,i=w0(),s=((v=i==null?void 0:i.apiBaseUrl)==null?void 0:v.replace(/\/+$/,""))??"",d={"Content-Type":"application/json",...i==null?void 0:i.headers,...r?{Authorization:`Bearer ${r}`}:{}};o&&(o instanceof Headers?o.forEach((w,b)=>{d[b]=w}):Array.isArray(o)?o.forEach(([w,b])=>{d[w]=b}):Object.assign(d,o));const c=await fetch(`${s}${P0}${e}`,{...n,headers:d});let u=null;try{u=await c.json()}catch{}if(!c.ok){const w=(y=u==null?void 0:u.error)==null?void 0:y.message;throw new $0(w||c.statusText||"Something went wrong",c.status,u)}return u}const C0=100,E0=5;async function S0(){var t,r;const e=[];for(let o=1;o<=E0;o++){const n=await ge(`/me/organizations?page=${o}&limit=${C0}`,{method:"GET",token:ue()});if(e.push(...n.data??[]),!((t=n.data)!=null&&t.length)||o>=(((r=n.pagination)==null?void 0:r.total_pages)??1))break}return e}async function x0(){return ge("/me",{method:"GET",token:ue()})}async function Ji(e){return ge("/me",{method:"PATCH",body:JSON.stringify(e),token:ue()})}async function O0(e,t){var i,s;const r=new URLSearchParams;t&&(t.search&&r.append("search",t.search),t.page!==void 0&&r.append("page",t.page.toString()),t.limit!==void 0&&r.append("limit",t.limit.toString()),t.order&&r.append("order",t.order),(i=t.user_ids)!=null&&i.length&&t.user_ids.forEach(d=>r.append("user_ids",d)),(s=t.emails)!=null&&s.length&&t.emails.forEach(d=>r.append("emails",d)),t.roles&&r.append("roles",t.roles));const o=r.toString(),n=`/organizations/${encodeURIComponent(e)}/members${o?`?${o}`:""}`;return ge(n,{method:"GET",token:ue()})}async function R0(e,t,r){const o=`/organizations/${encodeURIComponent(e)}/members/${encodeURIComponent(t)}/roles`;await ge(o,{method:"PUT",token:ue(),headers:{"Content-Type":"application/json"},body:JSON.stringify(r)})}async function I0(e,t){const r=`/organizations/${encodeURIComponent(e)}/members/${encodeURIComponent(t)}`;await ge(r,{method:"DELETE",token:ue(),headers:{"Content-Type":"application/json"}})}async function A0(e,t){const r=`/organizations/${encodeURIComponent(e)}/invitations`;return ge(r,{method:"POST",token:ue(),headers:{"Content-Type":"application/json"},body:JSON.stringify(t)})}async function T0(e,t){const r=`/organizations/${encodeURIComponent(e)}/invitations/${encodeURIComponent(t)}/resend`;return ge(r,{method:"POST",token:ue(),headers:{"Content-Type":"application/json"}})}async function D0(e,t,r){const o=`/organizations/${encodeURIComponent(e)}/invitations/${encodeURIComponent(t)}`;await ge(o,{method:"DELETE",token:ue()})}async function L0(e,t){var i;const r=new URLSearchParams;t&&(t.search&&r.append("search",t.search),t.invited_by&&r.append("invited_by",t.invited_by),t.page!==void 0&&r.append("page",t.page.toString()),t.limit!==void 0&&r.append("limit",t.limit.toString()),t.order&&r.append("order",t.order),(i=t.invitee_emails)!=null&&i.length&&t.invitee_emails.forEach(s=>r.append("invitee_emails",s)),t.roles&&r.append("roles",t.roles));const o=r.toString(),n=`/organizations/${encodeURIComponent(e)}/invitations${o?`?${o}`:""}`;return ge(n,{method:"GET",token:ue()})}const Di="org";async function Sl(e){const t=new URLSearchParams;e&&(e.type&&t.append("type",e.type),e.name&&t.append("name",e.name),e.resource_type&&t.append("resource_type",e.resource_type),e.resource_id&&t.append("resource_id",e.resource_id),e.include_instance_scoped!==void 0&&t.append("include_instance_scoped",e.include_instance_scoped.toString()),e.permission&&t.append("permission",e.permission),e.page!==void 0&&t.append("page",e.page.toString()),e.limit!==void 0&&t.append("limit",e.limit.toString()),e.order&&t.append("order",e.order));const r=t.toString(),o=`/roles${r?`?${r}`:""}`;return ge(o,{method:"GET",token:ue()})}var F0=Object.defineProperty,k0=Object.getOwnPropertyDescriptor,Rt=(e,t,r,o)=>{for(var n=o>1?void 0:o?k0(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&F0(t,r,n),n};exports.PontAccountInfo=class extends f{constructor(){super(...arguments),this.showAvatarMenu=!1,this.showIcons=!0,this.content=null,this.layout=nt.ROW,this.isUploadingImage=!1,this.isEditingAvatarMobile=!1,this.isMobile=!1,this._isAvatarEditorOpen=!1,this._popoverObserver=null,this._intentionalClose=!1,this.avatarDraft="",this._committedAvatar="",this._onMobileChange=t=>{this.isMobile=t.matches,t.matches||(this.isEditingAvatarMobile=!1)},this.handleAvatarInput=t=>{this.avatarDraft=t.target.value,this.account={...this.account,avatar:this.avatarDraft}},this.handleSaveAvatar=async()=>{if(!this.isUploadingImage){this.isUploadingImage=!0;try{const t=await Ji({picture:this.avatarDraft});this.account={...this.account,avatar:t.picture??""},this._committedAvatar=this.account.avatar,this.avatarDraft=this.account.avatar,this._isAvatarEditorOpen=!1,this.isMobile?this.isEditingAvatarMobile=!1:(this._intentionalClose=!0,this.querySelector("pont-popover-content").state="closed")}catch(t){this.account={...this.account,avatar:this._committedAvatar},this.avatarDraft=this._committedAvatar,this._isAvatarEditorOpen=!1,ji(Vi(t,"Failed to update your photo.")),this.isMobile?this.isEditingAvatarMobile=!1:(this._intentionalClose=!0,this.querySelector("pont-popover-content").state="closed")}finally{this.isUploadingImage=!1}}}}firstUpdated(){this._setupPopoverObserver()}_setupPopoverObserver(){const t=this.querySelector("pont-popover-content");if(!t)return;const r=new MutationObserver(n=>{for(const i of n)if(i.type==="childList"){const s=t.firstElementChild;if(s&&s.hasAttribute("data-state")){this._attachAttributeObserver(s),r.disconnect();break}}});r.observe(t,{childList:!0,subtree:!1});const o=t.firstElementChild;o&&o.hasAttribute("data-state")&&(this._attachAttributeObserver(o),r.disconnect())}_attachAttributeObserver(t){this._popoverObserver&&this._popoverObserver.disconnect(),this._popoverObserver=new MutationObserver(r=>{for(const o of r)if(o.type==="attributes"&&o.attributeName==="data-state"){const n=t.getAttribute("data-state");n==="open"?this.openAvatarEditor():n==="closed"&&(this._intentionalClose?this._intentionalClose=!1:(this.account={...this.account,avatar:this._committedAvatar},this.avatarDraft=this._committedAvatar,this._isAvatarEditorOpen=!1))}}),this._popoverObserver.observe(t,{attributes:!0})}updated(t){t.has("account")&&this.account.avatar&&!this._isAvatarEditorOpen&&(this.avatarDraft=this.account.avatar,this._committedAvatar=this.account.avatar)}connectedCallback(){super.connectedCallback(),this._mobileQuery=window.matchMedia("(max-width: 767px)"),this.isMobile=this._mobileQuery.matches,this._mobileQuery.addEventListener("change",this._onMobileChange)}disconnectedCallback(){super.disconnectedCallback(),this._mobileQuery.removeEventListener("change",this._onMobileChange),this._popoverObserver&&(this._popoverObserver.disconnect(),this._popoverObserver=null)}openAvatarEditor(){this._isAvatarEditorOpen=!0,this._committedAvatar=this.account.avatar,this.avatarDraft=this.account.avatar}resetAvatarDraft(){this.avatarDraft=this.account.avatar}handleCancelAvatar(){this.isUploadingImage||(this.account={...this.account,avatar:this._committedAvatar},this.avatarDraft=this._committedAvatar,this._isAvatarEditorOpen=!1,this.isMobile?this.isEditingAvatarMobile=!1:(this._intentionalClose=!0,this.querySelector("pont-popover-content").state="closed"))}renderRow(t,r){const o=this.layout===nt.COLUMN;return l`
|
|
4013
4013
|
<div
|
|
4014
4014
|
class=${Kt("pont-account-settings-display-row",o?"":"pont-account-settings-account-grid")}
|
|
4015
4015
|
>
|
|
@@ -5820,7 +5820,7 @@ Minimum version required to store current data is: `+F+`.
|
|
|
5820
5820
|
* @license
|
|
5821
5821
|
* Copyright 2020 Google LLC
|
|
5822
5822
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
5823
|
-
*/const tu=Symbol.for(""),FC=e=>{if((e==null?void 0:e.r)===tu)return e==null?void 0:e._$litStatic$},kC=e=>({_$litStatic$:e,r:tu}),mp=new Map,NC=e=>(t,...r)=>{const o=r.length;let n,i;const s=[],d=[];let c,u=0,v=!1;for(;u<o;){for(c=t[u];u<o&&(i=r[u],(n=FC(i))!==void 0);)c+=n+t[++u],v=!0;u!==o&&d.push(i),s.push(c),u++}if(u===o&&s.push(t[o]),v){const
|
|
5823
|
+
*/const tu=Symbol.for(""),FC=e=>{if((e==null?void 0:e.r)===tu)return e==null?void 0:e._$litStatic$},kC=e=>({_$litStatic$:e,r:tu}),mp=new Map,NC=e=>(t,...r)=>{const o=r.length;let n,i;const s=[],d=[];let c,u=0,v=!1;for(;u<o;){for(c=t[u];u<o&&(i=r[u],(n=FC(i))!==void 0);)c+=n+t[++u],v=!0;u!==o&&d.push(i),s.push(c),u++}if(u===o&&s.push(t[o]),v){const y=s.join("$$lit$$");(t=mp.get(y))===void 0&&(s.raw=s,mp.set(y,t=s)),r=d}return e(t,...r)},js=NC(l);var MC=Object.defineProperty,BC=Object.getOwnPropertyDescriptor,bt=(e,t,r,o)=>{for(var n=o>1?void 0:o?BC(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&MC(t,r,n),n};exports.PontOtp=class extends zt{constructor(){super(...arguments),this.excludeFromForm=!1,this.required=!1,this.requiredError="Code is required.",this.incompleteError="Please enter the complete verification code.",this.variant="with_separator",this.length=6,this.timeout=300,this.dataKey="code",this.name="",this.disabled=!1,this.autoSubmit=!1,this.event="",this.resendText="",this.resendButtonText="",this.resendEvent="",this.id="otp",this._invalid=!1,this._error="",this._value="",this.handleComplete=async t=>{if(this._value=t,this.autoSubmit&&this.event){const r={};r[this.dataKey]=t;try{await K.processLoginflowEvent({event:this.event,data:r})}finally{this.emit("pont-otp:complete",{id:this.id,dataKey:this.dataKey,value:t,event:this.event})}return}this.emit("pont-otp:complete",{id:this.id,dataKey:this.dataKey,value:t,event:null})},this.handleFocus=()=>{this.emit("pont-otp:focus",{id:this.id,dataKey:this.dataKey})},this.handleBlur=()=>{this.emit("pont-otp:blur",{id:this.id,dataKey:this.dataKey})},this.handleResend=async()=>{if(this.resendEvent)try{await K.processLoginflowEvent({event:this.resendEvent})}finally{this.emit("pont-otp:resend",{id:this.id,event:this.resendEvent})}}}get _containerElement(){return this.querySelector(`pont-input-otp[part=${this.id?this.id:"otp"}]`)}get isFormField(){return!this.excludeFromForm}createRenderRoot(){return this}get value(){return this._value}validate(){const t=this._value.trim();return this.required&&!t?(this._invalid=!0,this._error=this.requiredError,!1):t.length!==this.length?(this._invalid=!0,this._error=this.incompleteError,!1):(this._invalid=!1,this._error="",!0)}emit(t,r){this.dispatchEvent(new CustomEvent(t,{detail:r,bubbles:!0,composed:!0}))}buildOTPContentHTML(){const t=this.variant,r=this.length,o=(s,d)=>Array.from({length:d-s},(c,u)=>`<pont-input-otp-slot index="${s+u}"></pont-input-otp-slot>`).join(""),n=s=>`<pont-input-otp-group>${s}</pont-input-otp-group>`,i="<pont-input-otp-separator></pont-input-otp-separator>";if(t==="simple"){const s=Math.ceil(r/2);return n(o(0,s))+i+n(o(s,r))}if(t==="with_separator"){const s=Math.ceil(r/3);return n(o(0,s))+i+n(o(s,s*2))+i+n(o(s*2,r))}return t==="with_spacing"?Array.from({length:r},(s,d)=>n(`<pont-input-otp-slot index="${d}"></pont-input-otp-slot>`)).join(""):n(o(0,r))}render(){const t=this.variant||"digits_only";return js`
|
|
5824
5824
|
<pont-field ?disabled=${this.disabled} ?invalid=${this._invalid}>
|
|
5825
5825
|
<pont-input-otp
|
|
5826
5826
|
part=${this.id?this.id:"otp"}
|
|
@@ -5876,7 +5876,7 @@ Minimum version required to store current data is: `+F+`.
|
|
|
5876
5876
|
</pont-button>
|
|
5877
5877
|
`}
|
|
5878
5878
|
</div>
|
|
5879
|
-
`}};exports.PontOtpResend.ROOT="otp-resend";exports.PontOtpResend.COUNTDOWN="countdown";exports.PontOtpResend.RESEND_BUTTON="resend-button";exports.PontOtpResend.TAG=`${rt}-${exports.PontOtpResend.ROOT}`;exports.PontOtpResend.PARTS={root:exports.PontOtpResend.ROOT,countdown:`${exports.PontOtpResend.ROOT}-${exports.PontOtpResend.COUNTDOWN}`,resendButton:`${exports.PontOtpResend.ROOT}-${exports.PontOtpResend.RESEND_BUTTON}`};Rr([a({type:String})],exports.PontOtpResend.prototype,"seed",2);Rr([a({type:String,attribute:"custom-id"})],exports.PontOtpResend.prototype,"customId",2);Rr([a({type:Number})],exports.PontOtpResend.prototype,"duration",2);Rr([a({type:String,attribute:"resend-event"})],exports.PontOtpResend.prototype,"resend_event",2);Rr([a({type:String,attribute:"resend-button-label"})],exports.PontOtpResend.prototype,"resend_button_label",2);Rr([a({type:String,attribute:"count-down-text"})],exports.PontOtpResend.prototype,"count_down_text",2);Rr([g()],exports.PontOtpResend.prototype,"_remaining",2);exports.PontOtpResend=Rr([p("pont-otp-resend")],exports.PontOtpResend);const jC=[exports.PontEmailField,exports.PontPhoneField,exports.PontUsernameField,exports.PontIdentifierField,exports.PontNameField,exports.PontPasswordField,exports.PontConfirmField,exports.PontOtp],zC=[exports.PontPasskeyButton,exports.PontProviderButton,exports.PontLink];var VC=Object.defineProperty,HC=Object.getOwnPropertyDescriptor,zo=(e,t,r,o)=>{for(var n=o>1?void 0:o?HC(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&VC(t,r,n),n};exports.PontForm=class extends f{constructor(){super(...arguments),this.seed=_t(),this._loading=!1,this._handleSubmitClick=t=>{var
|
|
5879
|
+
`}};exports.PontOtpResend.ROOT="otp-resend";exports.PontOtpResend.COUNTDOWN="countdown";exports.PontOtpResend.RESEND_BUTTON="resend-button";exports.PontOtpResend.TAG=`${rt}-${exports.PontOtpResend.ROOT}`;exports.PontOtpResend.PARTS={root:exports.PontOtpResend.ROOT,countdown:`${exports.PontOtpResend.ROOT}-${exports.PontOtpResend.COUNTDOWN}`,resendButton:`${exports.PontOtpResend.ROOT}-${exports.PontOtpResend.RESEND_BUTTON}`};Rr([a({type:String})],exports.PontOtpResend.prototype,"seed",2);Rr([a({type:String,attribute:"custom-id"})],exports.PontOtpResend.prototype,"customId",2);Rr([a({type:Number})],exports.PontOtpResend.prototype,"duration",2);Rr([a({type:String,attribute:"resend-event"})],exports.PontOtpResend.prototype,"resend_event",2);Rr([a({type:String,attribute:"resend-button-label"})],exports.PontOtpResend.prototype,"resend_button_label",2);Rr([a({type:String,attribute:"count-down-text"})],exports.PontOtpResend.prototype,"count_down_text",2);Rr([g()],exports.PontOtpResend.prototype,"_remaining",2);exports.PontOtpResend=Rr([p("pont-otp-resend")],exports.PontOtpResend);const jC=[exports.PontEmailField,exports.PontPhoneField,exports.PontUsernameField,exports.PontIdentifierField,exports.PontNameField,exports.PontPasswordField,exports.PontConfirmField,exports.PontOtp],zC=[exports.PontPasskeyButton,exports.PontProviderButton,exports.PontLink];var VC=Object.defineProperty,HC=Object.getOwnPropertyDescriptor,zo=(e,t,r,o)=>{for(var n=o>1?void 0:o?HC(t,r):t,i=e.length-1,s;i>=0;i--)(s=e[i])&&(n=(o?s(t,r,n):s(n))||n);return o&&n&&VC(t,r,n),n};exports.PontForm=class extends f{constructor(){super(...arguments),this.seed=_t(),this._loading=!1,this._handleSubmitClick=t=>{var o;this._pendingEvent=(o=t.detail)==null?void 0:o.event;const r=t.composedPath()[0];this._pendingSubmit=r instanceof exports.PontSubmitButton?r:void 0},this._handleSubmit=async t=>{if(t.preventDefault(),this._loading)return;const r=this._fields;if(!r.map(b=>b.validate()).every(Boolean))return;const i={};r.forEach(b=>{i[b.name]=b.value});const s=this._pendingEvent;if(this.onSubmit){this.onSubmit(i,s);return}if(!s)return;const d=new CustomEvent(exports.PontForm.SUBMIT_EVENT,{detail:{id:this.rootId,data:i,event:s},bubbles:!0,composed:!0,cancelable:!0});if(this.dispatchEvent(d),d.defaultPrevented)return;const c=this._interactives,u=this._submits,v=r.map(b=>!!b.disabled),y=c.map(b=>!!b.disabled),w=u.map(b=>!!b.disabled);this._setLoading(!0,r,v,c,y,u,w);try{const b=await K.processLoginflowEvent({event:s,...Object.keys(i).length?{data:i}:{}});this._dispatch(exports.PontForm.SUCCESS_EVENT,{id:this.rootId,data:i,event:s,result:b})}catch(b){const C=b instanceof Error?b.message:String(b);this._dispatch(exports.PontForm.ERROR_EVENT,{id:this.rootId,data:i,event:s,message:C,error:b})}finally{this._setLoading(!1,r,v,c,y,u,w),this._pendingEvent=void 0,this._pendingSubmit=void 0}},this._handleReset=t=>{this._pendingEvent=void 0,this._pendingSubmit=void 0,this.onReset&&this.onReset(t),this._dispatch(exports.PontForm.RESET_EVENT,{id:this.rootId})}}createRenderRoot(){return this}get rootId(){return this.customId??`${exports.PontForm.TAG}-${this.seed}`}get _form(){const t=`form[part="${exports.PontForm.PARTS.root}"]`;return this.querySelector(t)}get _fields(){const t=this._form;return t?Array.from(t.querySelectorAll(jC.map(o=>o.TAG).join(", "))).filter(o=>typeof o.isFormField>"u"?!0:o.isFormField):[]}get _submits(){const t=this._form;if(!t)return[];const r=exports.PontSubmitButton.TAG;return Array.from(t.querySelectorAll(r))}get _interactives(){const t=this._form;if(!t)return[];const r=zC.map(o=>o.TAG).join(", ");return Array.from(t.querySelectorAll(r))}connectedCallback(){super.connectedCallback();const t=exports.PontSubmitButton.CLICK_EVENT;this.addEventListener(t,this._handleSubmitClick)}disconnectedCallback(){super.disconnectedCallback();const t=exports.PontSubmitButton.CLICK_EVENT;this.removeEventListener(t,this._handleSubmitClick)}firstUpdated(){const t=this._form;if(!t)return;Array.from(this.childNodes).filter(o=>o!==t).forEach(o=>t.appendChild(o))}_dispatch(t,r={}){this.dispatchEvent(new CustomEvent(t,{detail:r,bubbles:!0,composed:!0}))}_setLoading(t,r,o,n,i,s,d){r.forEach((u,v)=>{u.disabled=t?!0:o[v]}),n.forEach((u,v)=>{u.disabled=t?!0:i[v]});const c=this._pendingSubmit??s[0];s.forEach((u,v)=>{if(u===c){u.loading=t;return}u.disabled=t?!0:d[v]}),this._loading=t}render(){return l`
|
|
5880
5880
|
<form
|
|
5881
5881
|
id="${this.rootId}"
|
|
5882
5882
|
part="${exports.PontForm.PARTS.root}"
|