PageSourceSearch

https://www.kits.com/_nuxtpdp/4tUov0EK.js

js kits.com collected 2026-09-28 08:07:44 UTC 1,885,998 bytes, 2,445 lines download raw bytes

1const __vite__fileDeps=["./Bda8R690.js","./CexZAvtB.js","./swiper-vue.Bs3d9ZnH.css","./index.BFZObMPg.css","./5KEikvZV.js","./B3n1fCuR.js","./_name_.VvdFP56h.css","./Duzeq3F8.js","./index.Dys3oNoD.css","./CwkE8VYG.js","./CyPYQ9in.js","./index.DWDTAUv1.css","./B3hWyaqc.js","./index.DyYAF3Ls.css","./1tW4jX9G.js","./C9pwv-If.js","./DypS-_Sb.js","./AnagramLoading.Bv34_Ud7.css","./aimerce-integration.to0oh9Iu.css","./_name_.CEc6IFXw.css","./iG2CScgL.js","./BEc24eAb.js","./_name_.DEztLiRX.css","./CXh-LY0I.js","./VUgtgRsR.js","./BF__syA1.js","./DnqEuG2X.js","./Dos7FDjZ.js","./Glasses.C6YL8Eiq.css","./guaEpqMv.js","./BYUyUjjW.js","./44MW41sq.js","./DUC9Gzc_.js","./n8Qk7tLl.js","./AdD-efXu.js","./DO59wRwY.js","./DbxUZWKD.js","./CQzxtUtJ.js","./Cs_C8Twa.js","./BsvVIdSy.js","./AnagramHero.h7ZODNEq.css","./index.CtmQdzwA.css","./CDK89QUH.js","./index.D_1BeEJ6.css","./BiTKH9Fa.js","./index.C_e93BSL.css","./ByJsQKfS.js","./index.DDPB297E.css","./BkZctTWL.js","./D9dzkrbY.js","./index.EznxazR6.css","./Kb_ZbF-J.js","./index.DLoZ4nM_.css","./DuJGHjBz.js","./CMlrFKEy.js","./RVoRsIfp.js","./index.JCJJ4plU.css","./DSwFCs-S.js","./index.B_E3uq-1.css","./CgUBmoW0.js","./Db3Jp0s1.js","./vto-widget.xFiz27vC.css"],__vite__mapDeps=i=>i.map(i=>__vite__fileDeps[i]);
2var Vg=Object.defineProperty;var Bg=(e,t,n)=>t in e?Vg(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n;var en=(e,t,n)=>(Bg(e,typeof t!="symbol"?t+"":t,n),n);import{e as Si,r as Wt,h as Bo,g as ln,i as Ft,t as $o,n as kt,v as $g,u as k,a as Re,w as Ci,b as We,o as Cr,c as Bu,d as $u,s as Kn,f as Ir,j as Ge,k as ee,l as gn,p as Hn,K as Ug,m as Uu,q as Hu,x as Jt,y as Uo,z as Hg,A as Ii,B as Is,C as zg,D as zu,E as cn,F as is,G as Kg,H as vt,I as S,J,L as de,T as Gg,M as R,N as g,O as f,P as ye,Q,R as _e,S as N,U as M,V as Ee,W as Ne,X as mt,Y as $t,Z as he,_ as le,$ as Xe,a0 as Oe,a1 as Tr,a2 as ke,a3 as Je,a4 as jg,a5 as ii,a6 as xi,a7 as ft,a8 as st,a9 as Tt,aa as Yg,ab as cs,ac as Ku,ad as us,ae as hs,af as Gu,ag as ju,ah as Yu,ai as Wg,aj as Qg,ak as Zg,al as qg}from"./CexZAvtB.js";const Jg=/"(?:_|\\u0{2}5[Ff]){2}(?:p|\\u0{2}70)(?:r|\\u0{2}72)(?:o|\\u0{2}6[Ff])(?:t|\\u0{2}74)(?:o|\\u0{2}6[Ff])(?:_|\\u0{2}5[Ff]){2}"\s*:/,Xg=/"(?:c|\\u0063)(?:o|\\u006[Ff])(?:n|\\u006[Ee])(?:s|\\u0073)(?:t|\\u0074)(?:r|\\u0072)(?:u|\\u0075)(?:c|\\u0063)(?:t|\\u0074)(?:o|\\u006[Ff])(?:r|\\u0072)"\s*:/,ey=/^\s*["[{]|^\s*-?\d{1,16}(\.\d{1,17})?([Ee][+-]?\d+)?\s*$/;function ty(e,t){if(e==="__proto__"||e==="constructor"&&t&&typeof t=="object"&&"prototype"in t){ny(e);return}return t}function ny(e){console.warn(`[destr] Dropping "${e}" key to prevent prototype pollution.`)}function ri(e,t={}){if(typeof e!="string")return e;const n=e.trim();if(e[0]==='"'&&e.endsWith('"')&&!e.includes("\\"))return n.slice(1,-1);if(n.length<=9){const i=n.toLowerCase();if(i==="true")return!0;if(i==="false")return!1;if(i==="undefined")return;if(i==="null")return null;if(i==="nan")return Number.NaN;if(i==="infinity")return Number.POSITIVE_INFINITY;if(i==="-infinity")return Number.NEGATIVE_INFINITY}if(!ey.test(e)){if(t.strict)throw new SyntaxError("[destr] Invalid JSON");return e}try{if(Jg.test(e)||Xg.test(e)){if(t.strict)throw new Error("[destr] Possible prototype pollution");return JSON.parse(e,ty)}return JSON.parse(e)}catch(i){if(t.strict)throw i;return e}}const sy=/#/g,iy=/&/g,ry=/\//g,ay=/=/g,Ho=/\+/g,oy=/%5e/gi,ly=/%60/gi,cy=/%7c/gi,dy=/%20/gi;function uy(e){return encodeURI(""+e).replace(cy,"|")}function Ha(e){return uy(typeof e=="string"?e:JSON.stringify(e)).replace(Ho,"%2B").replace(dy,"+").replace(sy,"%23").replace(iy,"%26").replace(ly,"`").replace(oy,"^").replace(ry,"%2F")}function ha(e){return Ha(e).replace(ay,"%3D")}function ir(e=""){try{return decodeURIComponent(""+e)}catch{return""+e}}function hy(e){return ir(e.replace(Ho," "))}function py(e){return ir(e.replace(Ho," "))}function Wu(e=""){const t={};e[0]==="?"&&(e=e.slice(1));for(const n of e.split("&")){const i=n.match(/([^=]+)=?(.*)/)||[];if(i.length<2)continue;const r=hy(i[1]);if(r==="__proto__"||r==="constructor")continue;const s=py(i[2]||"");t[r]===void 0?t[r]=s:Array.isArray(t[r])?t[r].push(s):t[r]=[t[r],s]}return t}function fy(e,t){return(typeof t=="number"||typeof t=="boolean")&&(t=String(t)),t?Array.isArray(t)?t.map(n=>`${ha(e)}=${Ha(n)}`).join("&"):`${ha(e)}=${Ha(t)}`:ha(e)}function my(e){return Object.keys(e).filter(t=>e[t]!==void 0).map(t=>
2fy(t,e[t])).filter(Boolean).join("&")}const gy=/^[\s\w\0+.-]{2,}:([/\\]{1,2})/,yy=/^[\s\w\0+.-]{2,}:([/\\]{2})?/,by=/^([/\\]\s*){2,}[^/\\]/,vy=/^[\s\0]*(blob|data|javascript|vbscript):$/i,_y=/\/$|\/\?|\/#/,wy=/^\.?\//;function vn(e,t={}){return typeof t=="boolean"&&(t={acceptRelative:t}),t.strict?gy.test(e):yy.test(e)||(t.acceptRelative?by.test(e):!1)}function Ey(e){return!!e&&vy.test(e)}function za(e="",t){return t?_y.test(e):e.endsWith("/")}function Pr(e="",t){if(!t)return(za(e)?e.slice(0,-1):e)||"/";if(!za(e,!0))return e||"/";let n=e,i="";const r=e.indexOf("#");r>=0&&(n=e.slice(0,r),i=e.slice(r));const[s,...a]=n.split("?");return((s.endsWith("/")?s.slice(0,-1):s)||"/")+(a.length>0?`?${a.join("?")}`:"")+i}function rr(e="",t){if(!t)return e.endsWith("/")?e:e+"/";if(za(e,!0))return e||"/";let n=e,i="";const r=e.indexOf("#");if(r>=0&&(n=e.slice(0,r),i=e.slice(r),!n))return i;const[s,...a]=n.split("?");return s+"/"+(a.length>0?`?${a.join("?")}`:"")+i}function Sy(e=""){return e.startsWith("/")}function Vl(e=""){return Sy(e)?e:"/"+e}function Cy(e,t){if(Zu(t)||vn(e))return e;const n=Pr(t);return e.startsWith(n)?e:Ms(n,e)}function Bl(e,t){if(Zu(t))return e;const n=Pr(t);if(!e.startsWith(n))return e;const i=e.slice(n.length);return i[0]==="/"?i:"/"+i}function Qu(e,t){const n=Or(e),i={...Wu(n.search),...t};return n.search=my(i),Ty(n)}function Zu(e){return!e||e==="/"}function Iy(e){return e&&e!=="/"}function Ms(e,...t){let n=e||"";for(const i of t.filter(r=>Iy(r)))if(n){const r=i.replace(wy,"");n=rr(n)+r}else n=i;return n}function qu(...e){var a,o,l,c;const t=/\/(?!\/)/,n=e.filter(Boolean),i=[];let r=0;for(const d of n)if(!(!d||d==="/")){for(const[u,p]of d.split(t).entries())if(!(!p||p===".")){if(p===".."){if(i.length===1&&vn(i[0]))continue;i.pop(),r--;continue}if(u===1&&((a=i[i.length-1])!=null&&a.endsWith(":/"))){i[i.length-1]+="/"+p;continue}i.push(p),r++}}let s=i.join("/");return r>=0?(o=n[0])!=null&&o.startsWith("/")&&!s.startsWith("/")?s="/"+s:(l=n[0])!=null&&l.startsWith("./")&&!s.startsWith("./")&&(s="./"+s):s="../".repeat(-1*r)+s,(c=n[n.length-1])!=null&&c.endsWith("/")&&!s.endsWith("/")&&(s+="/"),s}function Ka(e,t,n={}){return n.trailingSlash||(e=rr(e),t=rr(t)),n.leadingSlash||(e=Vl(e),t=Vl(t)),n.encoding||(e=ir(e),t=ir(t)),e===t}const Ju=Symbol.for("ufo:protocolRelative");function Or(e="",t){const n=e.match(/^[\s\0]*(blob:|data:|javascript:|vbscript:)(.*)/i);if(n){const[,u,p=""]=n;return{protocol:u.toLowerCase(),pathname:p,href:u+p,auth:"",host:"",search:"",hash:""}}if(!vn(e,{acceptRelative:!0}))return t?Or(t+e):Ga(e);const[,i="",r,s=""]=e.replace(/\\/g,"/").match(/^[\s\0]*([\w+.-]{2,}:)?\/\/([^/@]+@)?(.*)/)||[],[,a="",o=""]=s.match(/([^#/?]*)(.*)?/)||[],{pathname:l,search:c,hash:d}=Ga(o.replace(/\/(?=[A-Za-z]:)/,""));return{protocol:i.toLowerCase(),auth:r?r.slice(0,Math.max(0,r.length-1)):"",host:a,pathname:l,search:c,hash:d,[Ju]:!i}}function Ga(e=""){const[t="",n="",i=""]=(e.match(/([^#?]*)(\?[^#]*)?(#.*)?/)||[]).splice(1);return{pathname:t,search:n,hash:i}}function Ty(e){const t=e.pathname||"",n=e.search?(e.search.startsWith("?")?"":"?")+e.search:"",i=e.hash||"",r=e.auth?e.auth+"@":"",s=e.host||"";return(e.protocol||e[Ju]?(e.protocol||"")+"//":"")+r+s+t+n+i}class Py extends Error{constructor(t,n){super(t,n),this.name="FetchError",n!=null&&n.cause&&!this.cause&&(this.cause=n.cause)}}function Oy(e){var l,c,d,u,p;const t=((l=e.error)==null?void 0:l.message)||((c=e.error)==null?void 0:c.toString())||"",n=((d=e.request)==null?void 0:d.method)||((u=e.options)==null?void 0:u.method)||"GET",i=((p=e.request)==null?void 0:p.url)||String(e.request)||"/",r=`[${n}] ${JSON.stringify(i)}`,s=e.response?`${e.response.status} ${e.response.statusText}`:"<no response>",a=`${r}: ${s}${t?` ${t}`:""}`,o=new Py(a,e.error?{cause:e.error}:void 0);for(const h of["request","options","response"])Object.defineProperty(o,h,{get(){return e[h]}});for(const[h,m]of[["data","_data"],["status","status"],["statusCode","status"],["statusText","statusText"],["statusMessage","statusText"]])Object.defineProperty(o,h,{get(){return e.response&&e.response[m]}});return o}const Ay=new Set(Object.freeze(["PATCH","POST","PUT","DELETE"]));function $l(e="GET"){return Ay.has(e.toUpperCase())}function ky(e){if(e===void 0)return!1;const t=typeof e;return t==="string"||t==="number"||t==="boolean"||t===null?!0:t!=="object"?!1:Array.isArray(e)?!0:e.buffer?!1:e.constructor&&e.constructor.name==="Object"||typeof e.toJSON=="function"}const Ry=new Set(["image/svg","application/xml","application/xhtml","application/html"]),Ly=/^application\/(?:[\w!#$%&*.^`~-]*\+)?json(;.+)?$/i;function Ny(e=""){if(!e)return"json";const t=e.split(";").shift()||"";return Ly.test(t)?"json":Ry.has(t)||t.startsWith("text/")?"text":"blob"}function Dy(e,t,n=globalThis.Headers){const i={...t,...e};if(t!=null&&t.params&&(e!=null&&e.params)&&(i.params={...t==null?void 0:t.params,...e==null?void 0:e.params}),t!=null&&t.query&&(e!=null&&e.query)&&(i.query={...t==null?void 0:t.query,...e==null?void 0:e.query}),t!=null&&t.headers&&(e!=null&&e.headers)){i.headers=new n((t==null?void 0:t.headers)||{});for(const[r,s]of new n((e==null?void 0:e.headers)||{}))i.headers.set(r,s)}return i}const xy=new Set([408,409,425,429,500,502,503,504]),My=new Set([101,204,205,304]);function Xu(e={}){const{fetch:t=globalThis.fetch,Headers:n=globalThis.Headers,AbortController:i=globalThis.AbortController}=e;async function r(o){const l=o.error&&o.error.name==="AbortError"&&!o.options.timeout||!1;if(o.options.retry!==!1&&!l){let d;typeof o.options.retry=="number"?d=o.options.retry:d=$l(o.options.method)?0:1;const u=o.response&&o.response.status||500;if(d>0&&(Array.isArray(o.options.retryStatusCodes)?o.options.retryStatusCodes.includes(u):xy.has(u))){const p=o.options.retryDelay||0;return p>0&&await new Promise(h=>setTimeout(h,p)),s(o.request,{...o.options,retry:d-1})}}const c=Oy(o);throw Error.captureStackTrace&&Error.captureStackTrace(c,s),c}const s=async function(l,c={}){var h;const d={request:l,options:Dy(c,e.defaults,n),response:void 0,error:void 0};d.options.method=(h=d.options.method)==null?void 0:h.toUpperCase(),d.options.onRequest&&await d.options.onRequest(d),typeof d.request=="string"&&(d.options.baseURL&&(d.request=Cy(d.request,d.options.baseURL)),(d.options.query||d.options.params)&&(d.request=Qu(d.request,{...d.options.params,...d.options.query}))),d.options.body&&$l(d.options.method)&&(ky(d.options.body)?(d.options.body=typeof d.options.body=="str
2ing"?d.options.body:JSON.stringify(d.options.body),d.options.headers=new n(d.options.headers||{}),d.options.headers.has("content-type")||d.options.headers.set("content-type","application/json"),d.options.headers.has("accept")||d.options.headers.set("accept","application/json")):("pipeTo"in d.options.body&&typeof d.options.body.pipeTo=="function"||typeof d.options.body.pipe=="function")&&("duplex"in d.options||(d.options.duplex="half")));let u;if(!d.options.signal&&d.options.timeout){const m=new i;u=setTimeout(()=>m.abort(),d.options.timeout),d.options.signal=m.signal}try{d.response=await t(d.request,d.options)}catch(m){return d.error=m,d.options.onRequestError&&await d.options.onRequestError(d),await r(d)}finally{u&&clearTimeout(u)}if(d.response.body&&!My.has(d.response.status)&&d.options.method!=="HEAD"){const m=(d.options.parseResponse?"json":d.options.responseType)||Ny(d.response.headers.get("content-type")||"");switch(m){case"json":{const v=await d.response.text(),_=d.options.parseResponse||ri;d.response._data=_(v);break}case"stream":{d.response._data=d.response.body;break}default:d.response._data=await d.response[m]()}}return d.options.onResponse&&await d.options.onResponse(d),!d.options.ignoreResponseError&&d.response.status>=400&&d.response.status<600?(d.options.onResponseError&&await d.options.onResponseError(d),await r(d)):d.response},a=async function(l,c){return(await s(l,c))._data};return a.raw=s,a.native=(...o)=>t(...o),a.create=(o={})=>Xu({...e,defaults:{...e.defaults,...o}}),a}const zo=function(){if(typeof globalThis<"u")return globalThis;if(typeof self<"u")return self;if(typeof window<"u")return window;if(typeof global<"u")return global;throw new Error("unable to locate global object")}(),Fy=zo.fetch||(()=>Promise.reject(new Error("[ofetch] global.fetch is not supported!"))),Vy=zo.Headers,By=zo.AbortController,$y=Xu({fetch:Fy,Headers:Vy,AbortController:By}),Uy=$y,Hy=()=>{var e;return((e=window==null?void 0:window.__NUXT__)==null?void 0:e.config)||{}},ar=Hy().app,zy=()=>ar.baseURL,Ky=()=>ar.buildAssetsDir,Ko=(...e)=>qu(eh(),Ky(),...e),eh=(...e)=>{const t=ar.cdnURL||ar.baseURL;return e.length?qu(t,...e):t};globalThis.__buildAssetsURL=Ko,globalThis.__publicAssetsURL=eh;globalThis.$fetch||(globalThis.$fetch=Uy.create({baseURL:zy()}));function ja(e,t={},n){for(const i in e){const r=e[i],s=n?`${n}:${i}`:i;typeof r=="object"&&r!==null?ja(r,t,s):typeof r=="function"&&(t[s]=r)}return t}const Gy={run:e=>e()},jy=()=>Gy,th=typeof console.createTask<"u"?console.createTask:jy;function Yy(e,t){const n=t.shift(),i=th(n);return e.reduce((r,s)=>r.then(()=>i.run(()=>s(...t))),Promise.resolve())}function Wy(e,t){const n=t.shift(),i=th(n);return Promise.all(e.map(r=>i.run(()=>r(...t))))}function pa(e,t){for(const n of[...e])n(t)}class Qy{constructor(){this._hooks={},this._before=void 0,this._after=void 0,this._deprecatedMessages=void 0,this._deprecatedHooks={},this.hook=this.hook.bind(this),this.callHook=this.callHook.bind(this),this.callHookWith=this.callHookWith.bind(this)}hook(t,n,i={}){if(!t||typeof n!="function")return()=>{};const r=t;let s;for(;this._deprecatedHooks[t];)s=this._deprecatedHooks[t],t=s.to;if(s&&!i.allowDeprecated){let a=s.message;a||(a=`${r} hook has been deprecated`+(s.to?`, please use ${s.to}`:"")),this._deprecatedMessages||(this._deprecatedMessages=new Set),this._deprecatedMessages.has(a)||(console.warn(a),this._deprecatedMessages.add(a))}if(!n.name)try{Object.defineProperty(n,"name",{get:()=>"_"+t.replace(/\W+/g,"_")+"_hook_cb",configurable:!0})}catch{}return this._hooks[t]=this._hooks[t]||[],this._hooks[t].push(n),()=>{n&&(this.removeHook(t,n),n=void 0)}}hookOnce(t,n){let i,r=(...s)=>(typeof i=="function"&&i(),i=void 0,r=void 0,n(...s));return i=this.hook(t,r),i}removeHook(t,n){if(this._hooks[t]){const i=this._hooks[t].indexOf(n);i!==-1&&this._hooks[t].splice(i,1),this._hooks[t].length===0&&delete this._hooks[t]}}deprecateHook(t,n){this._deprecatedHooks[t]=typeof n=="string"?{to:n}:n;const i=this._hooks[t]||[];delete this._hooks[t];for(const r of i)this.hook(t,r)}deprecateHooks(t){Object.assign(this._deprecatedHooks,t);for(const n in t)this.deprecateHook(n,t[n])}addHooks(t){const n=ja(t),i=Object.keys(n).map(r=>this.hook(r,n[r]));return()=>{for(const r of i.splice(0,i.length))r()}}removeHooks(t){const n=ja(t);for(const i in n)this.removeHook(i,n[i])}removeAllHooks(){for(const t in this._hooks)delete this._hooks[t]}callHook(t,...n){return n.unshift(t),this.callHookWith(Yy,t,...n)}callHookParallel(t,...n){return n.unshift(t),this.callHookWith(Wy,t,...n)}callHookWith(t,n,...i){const r=this._before||this._after?{name:n,args:i,context:{}}:void 0;this._before&&pa(this._before,r);const s=t(n in this._hooks?[...this._hooks[n]]:[],i);return s instanceof Promise?s.finally(()=>{this._after&&r&&pa(this._after,r)}):(this._after&&r&&pa(this._after,r),s)}beforeEach(t){return this._before=this._before||[],this._before.push(t),()=>{if(this._before!==void 0){const n=this._before.indexOf(t);n!==-1&&this._before.splice(n,1)}}}afterEach(t){return this._after=this._after||[],this._after.push(t),()=>{if(this._after!==void 0){const n=this._after.indexOf(t);n!==-1&&this._after.splice(n,1)}}}}function nh(){return new Qy}function Zy(e={}){let t,n=!1;const i=a=>
2{if(t&&t!==a)throw new Error("Context conflict")};let r;if(e.asyncContext){const a=e.AsyncLocalStorage||globalThis.AsyncLocalStorage;a?r=new a:console.warn("[unctx] `AsyncLocalStorage` is not provided.")}const s=()=>{if(r&&t===void 0){const a=r.getStore();if(a!==void 0)return a}return t};return{use:()=>{const a=s();if(a===void 0)throw new Error("Context is not available");return a},tryUse:()=>s(),set:(a,o)=>{o||i(a),t=a,n=!0},unset:()=>{t=void 0,n=!1},call:(a,o)=>{i(a),t=a;try{return r?r.run(a,o):o()}finally{n||(t=void 0)}},async callAsync(a,o){t=a;const l=()=>{t=a},c=()=>t===a?l:void 0;Ya.add(c);try{const d=r?r.run(a,o):o();return n||(t=void 0),await d}finally{Ya.delete(c)}}}}function qy(e={}){const t={};return{get(n,i={}){return t[n]||(t[n]=Zy({...e,...i})),t[n],t[n]}}}const or=typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof global<"u"?global:typeof window<"u"?window:{},Ul="__unctx__",Jy=or[Ul]||(or[Ul]=qy()),Xy=(e,t={})=>Jy.get(e,t),Hl="__unctx_async_handlers__",Ya=or[Hl]||(or[Hl]=new Set);function fn(e){const t=[];for(const r of Ya){const s=r();s&&t.push(s)}const n=()=>{for(const r of t)r()};let i=e();return i&&typeof i=="object"&&"catch"in i&&(i=i.catch(r=>{throw n(),r})),[i,n]}const sh=Xy("nuxt-app",{asyncContext:!1}),eb="__nuxt_plugin";function tb(e){let t=0;const n={_scope:Si(),provide:void 0,globalName:"nuxt",versions:{get nuxt(){return"3.11.2"},get vue(){return n.vueApp.version}},payload:Wt({data:{},state:{},once:new Set,_errors:{},...window.__NUXT__??{}}),static:{data:{}},runWithContext:r=>n._scope.run(()=>ib(n,r)),isHydrating:!0,deferHydration(){if(!n.isHydrating)return()=>{};t++;let r=!1;return()=>{if(!r&&(r=!0,t--,t===0))return n.isHydrating=!1,n.callHook("app:suspense:resolve")}},_asyncDataPromises:{},_asyncData:{},_payloadRevivers:{},...e};n.hooks=nh(),n.hook=n.hooks.hook,n.callHook=n.hooks.callHook,n.provide=(r,s)=>{const a="$"+r;Mi(n,a,s),Mi(n.vueApp.config.globalProperties,a,s)},Mi(n.vueApp,"$nuxt",n),Mi(n.vueApp.config.globalProperties,"$nuxt",n);{window.addEventListener("nuxt.preloadError",s=>{n.callHook("app:chunkError",{error:s.payload})}),window.useNuxtApp=window.useNuxtApp||ct;const r=n.hook("app:error",(...s)=>{console.error("[nuxt] error caught during app initialization",...s)});n.hook("app:mounted",r)}const i=n.payload.config;return n.provide("config",i),n}async function nb(e,t){if(t.hooks&&e.hooks.addHooks(t.hooks),typeof t=="function"){const{provide:n}=await e.runWithContext(()=>t(e))||{};if(n&&typeof n=="object")for(const i in n)e.provide(i,n[i])}}async function sb(e,t){const n=[],i=[],r=[],s=[];let a=0;async function o(l){var d;const c=((d=l.dependsOn)==null?void 0:d.filter(u=>t.some(p=>p._name===u)&&!n.includes(u)))??[];if(c.length>0)i.push([new Set(c),l]);else{const u=nb(e,l).then(async()=>{l._name&&(n.push(l._name),await Promise.all(i.map(async([p,h])=>{p.has(l._name)&&(p.delete(l._name),p.size===0&&(a++,await o(h)))})))});l.parallel?r.push(u.catch(p=>s.push(p))):await u}}for(const l of t)await o(l);if(await Promise.all(r),a)for(let l=0;l<a;l++)await Promise.all(r);if(s.length)throw s[0]}function _t(e){if(typeof e=="function")return e;const t=e._name||e.name;return delete e.name,Object.assign(e.setup||(()=>{}),e,{[eb]:!0,_name:t})}function ib(e,t,n){const i=()=>t();return sh.set(e),e.vueApp.runWithContext(i)}function rb(){var t;let e;return Bo()&&(e=(t=ln())==null?void 0:t.appContext.app.$nuxt),e=e||sh.tryUse(),e||null}function ct(){const e=rb();if(!e)throw new Error("[nuxt] instance unavailable");return e}function Be(e){return ct().$config}function Mi(e,t,n){Object.defineProperty(e,t,{get:()=>n})}const Fi=/^[\u0009\u0020-\u007E\u0080-\u00FF]+$/;function ab(e,t){if(typeof e!="string")throw new TypeError("argument str must be a string");const n={},r=(t||{}).decode||cb;let s=0;for(;s<e.length;){const a=e.indexOf("=",s);if(a===-1)break;let o=e.indexOf(";",s);if(o===-1)o=e.length;else if(o<a){s=e.lastIndexOf(";",a-1)+1;continue}const l=e.slice(s,a).trim();if(n[l]===void 0){let c=e.slice(a+1,o).trim();c.codePointAt(0)===34&&(c=c.slice(1,-1)),n[l]=lb(c,r)}s=o+1}return n}function zl(e,t,n){const i=n||{},r=i.encode||db;if(typeof r!="function")throw new TypeError("option encode is invali
2d");if(!Fi.test(e))throw new TypeError("argument name is invalid");const s=r(t);if(s&&!Fi.test(s))throw new TypeError("argument val is invalid");let a=e+"="+s;if(i.maxAge!==void 0&&i.maxAge!==null){const o=i.maxAge-0;if(Number.isNaN(o)||!Number.isFinite(o))throw new TypeError("option maxAge is invalid");a+="; Max-Age="+Math.floor(o)}if(i.domain){if(!Fi.test(i.domain))throw new TypeError("option domain is invalid");a+="; Domain="+i.domain}if(i.path){if(!Fi.test(i.path))throw new TypeError("option path is invalid");a+="; Path="+i.path}if(i.expires){if(!ob(i.expires)||Number.isNaN(i.expires.valueOf()))throw new TypeError("option expires is invalid");a+="; Expires="+i.expires.toUTCString()}if(i.httpOnly&&(a+="; HttpOnly"),i.secure&&(a+="; Secure"),i.priority)switch(typeof i.priority=="string"?i.priority.toLowerCase():i.priority){case"low":{a+="; Priority=Low";break}case"medium":{a+="; Priority=Medium";break}case"high":{a+="; Priority=High";break}default:throw new TypeError("option priority is invalid")}if(i.sameSite)switch(typeof i.sameSite=="string"?i.sameSite.toLowerCase():i.sameSite){case!0:{a+="; SameSite=Strict";break}case"lax":{a+="; SameSite=Lax";break}case"strict":{a+="; SameSite=Strict";break}case"none":{a+="; SameSite=None";break}default:throw new TypeError("option sameSite is invalid")}return i.partitioned&&(a+="; Partitioned"),a}function ob(e){return Object.prototype.toString.call(e)==="[object Date]"||e instanceof Date}function lb(e,t){try{return t(e)}catch{return e}}function cb(e){return e.includes("%")?decodeURIComponent(e):e}function db(e){return encodeURIComponent(e)}const Kl=Object.freeze({ignoreUnknown:!1,respectType:!1,respectFunctionNames:!1,respectFunctionProperties:!1,unorderedObjects:!0,unorderedArrays:!1,unorderedSets:!1,excludeKeys:void 0,excludeValues:void 0,replacer:void 0});function Wa(e,t){t?t={...Kl,...t}:t=Kl;const n=ih(t);return n.dispatch(e),n.toString()}const ub=Object.freeze(["prototype","__proto__","constructor"]);function ih(e){let t="",n=new Map;const i=r=>{t+=r};return{toString(){return t},getContext(){return n},dispatch(r){return e.replacer&&(r=e.replacer(r)),this[r===null?"null":typeof r](r)},object(r){if(r&&typeof r.toJSON=="function")return this.object(r.toJSON());const s=Object.prototype.toString.call(r);let a="";const o=s.length;o<10?a="unknown:["+s+"]":a=s.slice(8,o-1),a=a.toLowerCase();let l=null;if((l=n.get(r))===void 0)n.set(r,n.size);else return this.dispatch("[CIRCULAR:"+l+"]");if(typeof Buffer<"u"&&Buffer.isBuffer&&Buffer.isBuffer(r))return i("buffer:"),i(r.toString("utf8"));if(a!=="object"&&a!=="function"&&a!=="asyncfunction")this[a]?this[a](r):e.ignoreUnknown||this.unkown(r,a);else{let c=Object.keys(r);e.unorderedObjects&&(c=c.sort());let d=[];e.respectType!==!1&&!Gl(r)&&(d=ub),e.excludeKeys&&(c=c.filter(p=>!e.excludeKeys(p)),d=d.filter(p=>!e.excludeKeys(p))),i("object:"+(c.length+d.length)+":");const u=p=>{this.dispatch(p),i(":"),e.excludeValues||this.dispatch(r[p]),i(",")};for(const p of c)u(p);for(const p of d)u(p)}},array(r,s){if(s=s===void 0?e.unorderedArrays!==!1:s,i("array:"+r.length+":"),!s||r.length<=1){for(const l of r)this.dispatch(l);return}const a=new Map,o=r.map(l=>{const c=ih(e);c.dispatch(l);for(const[d,u]of c.getContext())a.set(d,u);return c.toString()});return n=a,o.sort(),this.array(o,!1)},date(r){return i("date:"+r.toJSON())},symbol(r){return i("symbol:"+r.toString())},unkown(r,s){if(i(s),!!r&&(i(":"),r&&typeof r.entries=="function"))return this.array(Array.from(r.entries()),!0)},error(r){return i("error:"+r.toString())},boolean(r){return i("bool:"+r)},string(r){i("string:"+r.length+":"),i(r)},function(r){i("fn:"),Gl(r)?this.dispatch("[native]"):this.dispatch(r.toString()),e.respectFunctionNames!==!1&&this.dispatch("function-name:"+String(r.name)),e.respectFunctionProperties&&this.object(r)},number(r){return i("number:"+r)},xml(r){return i("xml:"+r.toString())},null(){return i("Null")},undefined(){return i("Undefined")},regexp(r){return i("regex:"+r.toString())},uint8array(r){return i("uint8array:"),this.dispatch(Array.prototype.slice.call(r))},uint8clampedarray(r){return i("uint8clampedarray:"),this.dispatch(Array.prototype.slice.call(r))},int8array(r){return i("int8array:"),this.dispatch(Array.prototype.slice.call(r))},uint16array(r){return i("uint16array:"),this.dispatch(Array.prototype.slice.call(r))},int16array(r){return i("int16array:"),this.dispatch(Array.prototype.slice.call(r))},uint32array(r){return i("uint32array:"),this.dispatch(Array.prototype.slice.call(r))},int32array(r){return i("int32array:"),this.dispatch(Array.prototype.slice.call(r))},float32array(r){return i("float32array:"),this.dispatch(Array.prototype.slice.call(r))},float64array(r){return i("float64array:"),this.dispatch(Array.prototype.slice.call(r))},arraybuffer(r){return i("arraybuffer:"),this.dispatch(new Uint8Array(r))},url(r){return i("url:"+r.toString())},map(r){i("map:");const s=[...r];return this.array(s,e.unorderedSets!==!1)},set(r){i("set:");const s=[...r];return this.array(s,e.unorderedSets!==!1)},file(r){return i("file:"),this.dispatch([r.name,r.size,r.type,r.lastModfied])},blob(){if(e.ignoreUnknown)return i("[blob]");throw new Error(`Hashing Blob objects is currently not supported
3Use "options.replacer" or "options.ignoreUnknown"
4`)},domwindow(){return i("domwindow")},bigint(r){return i("bigint:"+r.toString())},process(){return i("process")},timer(){return i("timer")},pipe(){return i("pipe")},tcp(){return i("tcp")},udp(){return i("udp")},tty(){return i("tty")},statwatcher(){return i("statwatcher")},securecontext(){return i("securecontext")},connection(){return i("connection")},zlib(){return i("zlib")}
4,context(){return i("context")},nodescript(){return i("nodescript")},httpparser(){return i("httpparser")},dataview(){return i("dataview")},signal(){return i("signal")},fsevent(){return i("fsevent")},tlswrap(){return i("tlswrap")}}}const rh="[native code] }",hb=rh.length;function Gl(e){return typeof e!="function"?!1:Function.prototype.toString.call(e).slice(-hb)===rh}class zn{constructor(t,n){t=this.words=t||[],this.sigBytes=n===void 0?t.length*4:n}toString(t){return(t||pb).stringify(this)}concat(t){if(this.clamp(),this.sigBytes%4)for(let n=0;n<t.sigBytes;n++){const i=t.words[n>>>2]>>>24-n%4*8&255;this.words[this.sigBytes+n>>>2]|=i<<24-(this.sigBytes+n)%4*8}else for(let n=0;n<t.sigBytes;n+=4)this.words[this.sigBytes+n>>>2]=t.words[n>>>2];return this.sigBytes+=t.sigBytes,this}clamp(){this.words[this.sigBytes>>>2]&=4294967295<<32-this.sigBytes%4*8,this.words.length=Math.ceil(this.sigBytes/4)}clone(){return new zn([...this.words])}}const pb={stringify(e){const t=[];for(let n=0;n<e.sigBytes;n++){const i=e.words[n>>>2]>>>24-n%4*8&255;t.push((i>>>4).toString(16),(i&15).toString(16))}return t.join("")}},fb={stringify(e){const t="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789",n=[];for(let i=0;i<e.sigBytes;i+=3){const r=e.words[i>>>2]>>>24-i%4*8&255,s=e.words[i+1>>>2]>>>24-(i+1)%4*8&255,a=e.words[i+2>>>2]>>>24-(i+2)%4*8&255,o=r<<16|s<<8|a;for(let l=0;l<4&&i*8+l*6<e.sigBytes*8;l++)n.push(t.charAt(o>>>6*(3-l)&63))}return n.join("")}},mb={parse(e){const t=e.length,n=[];for(let i=0;i<t;i++)n[i>>>2]|=(e.charCodeAt(i)&255)<<24-i%4*8;return new zn(n,t)}},gb={parse(e){return mb.parse(unescape(encodeURIComponent(e)))}};class yb{constructor(){this._data=new zn,this._nDataBytes=0,this._minBufferSize=0,this.blockSize=512/32}reset(){this._data=new zn,this._nDataBytes=0}_append(t){typeof t=="string"&&(t=gb.parse(t)),this._data.concat(t),this._nDataBytes+=t.sigBytes}_doProcessBlock(t,n){}_process(t){let n,i=this._data.sigBytes/(this.blockSize*4);t?i=Math.ceil(i):i=Math.max((i|0)-this._minBufferSize,0);const r=i*this.blockSize,s=Math.min(r*4,this._data.sigBytes);if(r){for(let a=0;a<r;a+=this.blockSize)this._doProcessBlock(this._data.words,a);n=this._data.words.splice(0,r),this._data.sigBytes-=s}return new zn(n,s)}}class bb extends yb{update(t){return this._append(t),this._process(),this}finalize(t){t&&this._append(t)}}const jl=[1779033703,-1150833019,1013904242,-1521486534,1359893119,-1694144372,528734635,1541459225],vb=[1116352408,1899447441,-1245643825,-373957723,961987163,1508970993,-1841331548,-1424204075,-670586216,310598401,607225278,1426881987,1925078388,-2132889090,-1680079193,-1046744716,-459576895,-272742522,264347078,604807628,770255983,1249150122,1555081692,1996064986,-1740746414,-1473132947,-1341970488,-1084653625,-958395405,-710438585,113926993,338241895,666307205,773529912,1294757372,1396182291,1695183700,1986661051,-2117940946,-1838011259,-1564481375,-1474664885,-1035236496,-949202525,-778901479,-694614492,-200395387,275423344,430227734,506948616,659060556,883997877,958139571,1322822218,1537002063,1747873779,1955562222,2024104815,-2067236844,-1933114872,-1866530822,-1538233109,-1090935817,-965641998],Jn=[];class _b extends bb{constructor(){super(...arguments),this._hash=new zn([...jl])}reset(){super.reset(),this._hash=new zn([...jl])}_doProcessBlock(t,n){const i=this._hash.words;let r=i[0],s=i[1],a=i[2],o=i[3],l=i[4],c=i[5],d=i[6],u=i[7];for(let p=0;p<64;p++){if(p<16)Jn[p]=t[n+p]|0;else{const C=Jn[p-15],O=(C<<25|C>>>7)^(C<<14|C>>>18)^C>>>3,T=Jn[p-2],E=(T<<15|T>>>17)^(T<<13|T>>>19)^T>>>10;Jn[p]=O+Jn[p-7]+E+Jn[p-16]}const h=l&c^~l&d,m=r&s^r&a^s&a,v=(r<<30|r>>>2)^(r<<19|r>>>13)^(r<<10|r>>>22),_=(l<<26|l>>>6)^(l<<21|l>>>11)^(l<<7|l>>>25),b=u+_+h+vb[p]+Jn[p],w=v+m;u=d,d=c,c=l,l=o+b|0,o=a,a=s,s=r,r=b+w|0}i[0]=i[0]+r|0,i[1]=i[1]+s|0,i[2]=i[2]+a|0,i[3]=i[3]+o|0,i[4]=i[4]+l|0,i[5]=i[5]+c|0,i[6]=i[6]+d|0,i[7]=i[7]+u|0}finalize(t){super.finalize(t);const n=this._nDataBytes*8,i=this._data.sigBytes*8;return this._data.words[i>>>5]|=128<<24-i%32,this._data.words[(i+64>>>9<<4)+14]=Math.floor(n/4294967296),this._data.words[(i+64>>>9<<4)+15]=n,this._data.sigBytes=this._data.words.length*4,this._process(),this._hash}}function wb(e){return new _b().finalize(e).toString(fb)}
4function Eb(e,t={}){const n=typeof e=="string"?e:Wa(e,t);return wb(n).slice(0,10)}function Sb(e,t,n={}){return e===t||Wa(e,n)===Wa(t,n)}function Cb(e,t){return{ctx:{table:e},matchAll:n=>oh(n,e)}}function ah(e){const t={};for(const n in e)t[n]=n==="dynamic"?new Map(Object.entries(e[n]).map(([i,r])=>[i,ah(r)])):new Map(Object.entries(e[n]));return t}function Ib(e){return Cb(ah(e))}function oh(e,t,n){e.endsWith("/")&&(e=e.slice(0,-1)||"/");const i=[];for(const[s,a]of Yl(t.wildcard))(e===s||e.startsWith(s+"/"))&&i.push(a);for(const[s,a]of Yl(t.dynamic))if(e.startsWith(s+"/")){const o="/"+e.slice(s.length).split("/").splice(2).join("/");i.push(...oh(o,a))}const r=t.static.get(e);return r&&i.push(r),i.filter(Boolean)}function Yl(e){return[...e.entries()].sort((t,n)=>t[0].length-n[0].length)}function fa(e){if(e===null||typeof e!="object")return!1;const t=Object.getPrototypeOf(e);return t!==null&&t!==Object.prototype&&Object.getPrototypeOf(t)!==null||Symbol.iterator in e?!1:Symbol.toStringTag in e?Object.prototype.toString.call(e)==="[object Module]":!0}function Qa(e,t,n=".",i){if(!fa(t))return Qa(e,{},n,i);const r=Object.assign({},t);for(const s in e){if(s==="__proto__"||s==="constructor")continue;const a=e[s];a!=null&&(i&&i(r,s,a,n)||(Array.isArray(a)&&Array.isArray(r[s])?r[s]=[...a,...r[s]]:fa(a)&&fa(r[s])?r[s]=Qa(a,r[s],(n?`${n}.`:"")+s.toString(),i):r[s]=a))}return r}function lh(e){return(...t)=>t.reduce((n,i)=>Qa(n,i,"",e),{})}const ch=lh(),Tb=lh((e,t,n)=>{if(e[t]!==void 0&&typeof n=="function")return e[t]=n(e[t]),!0});function Pb(e,t){try{return t in e}catch{return!1}}var Ob=Object.defineProperty,Ab=(e,t,n)=>t in e?Ob(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,ns=(e,t,n)=>(Ab(e,typeof t!="symbol"?t+"":t,n),n);class Za extends Error{constructor(t,n={}){super(t,n),ns(this,"statusCode",500),ns(this,"fatal",!1),ns(this,"unhandled",!1),ns(this,"statusMessage"),ns(this,"data"),ns(this,"cause"),n.cause&&!this.cause&&(this.cause=n.cause)}toJSON(){const t={message:this.message,statusCode:Ja(this.statusCode,500)};return this.statusMessage&&(t.statusMessage=dh(this.statusMessage)),this.data!==void 0&&(t.data=this.data),t}}ns(Za,"__h3_error__",!0);function qa(e){if(typeof e=="string")return new Za(e);if(kb(e))return e;const t=new Za(e.message??e.statusMessage??"",{cause:e.cause||e});if(Pb(e,"stack"))try{Object.defineProperty(t,"stack",{get(){return e.stack}})}catch{try{t.stack=e.stack}catch{}}if(e.data&&(t.data=e.data),e.statusCode?t.statusCode=Ja(e.statusCode,t.statusCode):e.status&&(t.statusCode=Ja(e.status,t.statusCode)),e.statusMessage?t.statusMessage=e.statusMessage:e.statusText&&(t.statusMessage=e.statusText),t.statusMessage){const n=t.statusMessage;dh(t.statusMessage)!==n&&console.warn("[h3] Please prefer using `message` for longer error messages instead of `statusMessage`. In the future, `statusMessage` will be sanitized by default.")}return e.fatal!==void 0&&(t.fatal=e.fatal),e.unhandled!==void 0&&(t.unhandled=e.unhandled),t}function kb(e){var t;return((t=e==null?void 0:e.constructor)==null?void 0:t.__h3_error__)===!0}const Rb=/[^\u0009\u0020-\u007E]/g;function dh(e=""){return e.replace(Rb,"")}function Ja(e,t=200){return!e||(typeof e=="string"&&(e=Number.parseInt(e,10)),e<100||e>999)?t:e}const Lb=Symbol("layout-meta"),Ar=Symbol("route"),dn=()=>{var e;return(e=ct())==null?void 0:e.$router},On=()=>Bo()?Ft(Ar,ct()._route):ct()._route;const Nb=(e,t,n={})=>{const i=ct(),r=n.global||typeof e!="string",s=t;if(!s){console.warn("[nuxt] No route middleware passed to `addRouteMiddleware`.",e);return}r?i._middleware.global.push(s):i._middleware.named[e]=s},Db=()=>{try{if(ct()._processingMiddleware)return!0}catch{return!1}return!1},kr=(e,t)=>{e||(e="/");const n=typeof e=="string"?e:Qu(e.path||"/",e.query||{})+(e.hash||"");if(t!=null&&t.open){const{target:o="_blank",windowFeatures:l={}}=t.open,c=Object.entries(l).filter(([d,u])=>u!==void 0).map(([d,u])=>`${d.toLowerCase()}=${u}`).join(", ");return open(n,o,c),Promise.resolve()}const i=(t==null?void 0:t.external)||vn(n,{acceptRelative:!0});if(i){if(!(t!=null&&t.external))throw new Error("Navigating to an external URL is not allowed by default. Use `navigateTo(url, { external: true })`.");const o=Or(n).protocol;if(o&&Ey(o))throw new Error(`Cannot navigate to a URL with '${o}' protocol.`)}const r=Db();if(!i&&r)return e;const s=dn(),a=ct();return i?(a._scope.stop(),t!=null&&t.replace?location.replace(n):location.href=n,r?a.isHydrating?new Promise(()=>{}
4):!1:Promise.resolve()):t!=null&&t.replace?s.replace(e):s.push(e)},uh="__nuxt_error",Rr=()=>$o(ct().payload,"error"),Es=e=>{const t=Ti(e);try{const n=ct(),i=Rr();n.hooks.callHook("app:error",t),i.value=i.value||t}catch{throw t}return t},xb=async(e={})=>{const t=ct(),n=Rr();t.callHook("app:error:cleared",e),e.redirect&&await dn().replace(e.redirect),n.value=null},Mb=e=>!!e&&typeof e=="object"&&uh in e,Ti=e=>{const t=qa(e);return Object.defineProperty(t,uh,{value:!0,configurable:!1,writable:!1}),t},Fb=-1,Vb=-2,Bb=-3,$b=-4,Ub=-5,Hb=-6;function zb(e,t){return Kb(JSON.parse(e),t)}function Kb(e,t){if(typeof e=="number")return r(e,!0);if(!Array.isArray(e)||e.length===0)throw new Error("Invalid input");const n=e,i=Array(n.length);function r(s,a=!1){if(s===Fb)return;if(s===Bb)return NaN;if(s===$b)return 1/0;if(s===Ub)return-1/0;if(s===Hb)return-0;if(a)throw new Error("Invalid input");if(s in i)return i[s];const o=n[s];if(!o||typeof o!="object")i[s]=o;else if(Array.isArray(o))if(typeof o[0]=="string"){const l=o[0],c=t==null?void 0:t[l];if(c)return i[s]=c(r(o[1]));switch(l){case"Date":i[s]=new Date(o[1]);break;case"Set":const d=new Set;i[s]=d;for(let h=1;h<o.length;h+=1)d.add(r(o[h]));break;case"Map":const u=new Map;i[s]=u;for(let h=1;h<o.length;h+=2)u.set(r(o[h]),r(o[h+1]));break;case"RegExp":i[s]=new RegExp(o[1],o[2]);break;case"Object":i[s]=Object(o[1]);break;case"BigInt":i[s]=BigInt(o[1]);break;case"null":const p=Object.create(null);i[s]=p;for(let h=1;h<o.length;h+=2)p[o[h]]=r(o[h+1]);break;default:throw new Error(`Unknown type ${l}`)}}else{const l=new Array(o.length);i[s]=l;for(let c=0;c<o.length;c+=1){const d=o[c];d!==Vb&&(l[c]=r(d))}}else{const l={};i[s]=l;for(const c in o){const d=o[c];l[c]=r(d)}}return i[s]}return r(0)}function Gb(e){return Array.isArray(e)?e:[e]}const jb=["title","titleTemplate","script","style","noscript"],Zi=["base","meta","link","style","script","noscript"],Yb=["title","titleTemplate","templateParams","base","htmlAttrs","bodyAttrs","meta","link","style","script","noscript"],Wb=["base","title","titleTemplate","bodyAttrs","htmlAttrs","templateParams"],hh=["tagPosition","tagPriority","tagDuplicateStrategy","children","innerHTML","textContent","processTemplateParams"],Qb=typeof window<"u";function Go(e){let t=9;for(let n=0;n<e.length;)t=Math.imul(t^e.charCodeAt(n++),9**9);return((t^t>>>9)+65536).toString(16).substring(1,8).toLowerCase()}function Wl(e){return e._h||Go(e._d?e._d:`${e.tag}:${e.textContent||e.innerHTML||""}:${Object.entries(e.props).map(([t,n])=>`${t}:${String(n)}`).join(",")}`)}function ph(e,t){const{props:n,tag:i}=e;if(Wb.includes(i))return i;if(i==="link"&&n.rel==="canonical")return"canonical";if(n.charset)return"charset";const r=["id"];i==="meta"&&r.push("name","property","http-equiv");for(const s of r)if(typeof n[s]<"u"){const a=String(n[s]);return`${i}:${s}:${a}`}return!1}function Ql(e,t){return e==null?t||null:typeof e=="function"?e(t):e}function fh(e,t){const n=[],i=t.resolveKeyData||(s=>s.key),r=t.resolveValueData||(s=>s.value);for(const[s,a]of Object.entries(e))n.push(...(Array.isArray(a)?a:[a]).map(o=>{const l={key:s,value:o},c=r(l);return typeof c=="object"?fh(c,t):Array.isArray(c)?c:{[typeof t.key=="function"?t.key(l):t.key]:i(l),[typeof t.value=="function"?t.value(l):t.value]:c}}).flat());return n}function mh(e,t){return Object.entries(e).map(([n,i])=>{if(typeof i=="object"&&(i=mh(i,t)),t.resolve){const r=t.resolve({key:n,value:i});if(typeof r<"u")return r}return typeof i=="number"&&(i=i.toString()),typeof i=="string"&&t.wrapValue&&(i=i.replace(new RegExp(t.wrapValue,"g"),`\\${t.wrapValue}`),i=`${t.wrapValue}${i}${t.wrapValue}`),`${n}${t.keyValueSeparator||""}${i}`}).join(t.entrySeparator||"")}const Ut=e=>({keyValue:e,metaKey:"property"}),ma=e=>({keyValue:e}),jo={appleItunesApp:{unpack:{entrySeparator:", ",resolve({key:e,value:t}){return`${Cn(e)}=${t}`}}},articleExpirationTime:Ut("article:expiration_time"),articleModifiedTime:Ut("article:modified_time"),articlePublishedTime:Ut("article:published_time"),bookReleaseDate:Ut("book:release_date"),charset:{metaKey:"charset"},contentSecurityPolicy:{unpack:{entrySeparator:"; ",resolve({key:e,value:t}){return`${Cn(e)} ${t}`}},metaKey:"http-equiv"},contentType:{metaKey:"http-equiv"},defaultStyle:{metaKey:"http-equiv"},fbAppId:Ut("fb:app_id"),msapplicationConfig:ma("msapplication-Config"),msapplicationTileColor:ma("msapplication-TileColor"),msapplicationTileImage:ma("msapplication-TileImage"),ogAudioSecureUrl:Ut("og:audio:secure_url"),ogAudioUrl:Ut("og:audio"),ogImageSecureUrl:Ut("og:image:secure_url"),ogImageUrl:Ut("og:image"),ogSiteName:Ut("og:site_name"),ogVideoSecureUrl:Ut("og:video:secure_url"),ogVideoUrl:Ut("og:video"),profileFirstName:Ut("profile:first_name"),profileLastName:Ut("profile:last_name"),profileUsername:Ut("profile:username"),refresh:{metaKey:"http-equiv",unpack:{entrySeparator:";",resolve({key:e,value:t}
4){if(e==="seconds")return`${t}`}}},robots:{unpack:{entrySeparator:", ",resolve({key:e,value:t}){return typeof t=="boolean"?`${Cn(e)}`:`${Cn(e)}:${t}`}}},xUaCompatible:{metaKey:"http-equiv"}},gh=["og","book","article","profile"];function yh(e){var n;const t=Cn(e).split(":")[0];return gh.includes(t)?"property":((n=jo[e])==null?void 0:n.metaKey)||"name"}function Zb(e){var t;return((t=jo[e])==null?void 0:t.keyValue)||Cn(e)}function Cn(e){const t=e.replace(/([A-Z])/g,"-$1").toLowerCase(),n=t.split("-")[0];return gh.includes(n)||n==="twitter"?e.replace(/([A-Z])/g,":$1").toLowerCase():t}function Xa(e){if(Array.isArray(e))return e.map(n=>Xa(n));if(typeof e!="object"||Array.isArray(e))return e;const t={};for(const[n,i]of Object.entries(e))t[Cn(n)]=Xa(i);return t}function qb(e,t){const n=jo[t];return t==="refresh"?`${e.seconds};url=${e.url}`:mh(Xa(e),{keyValueSeparator:"=",entrySeparator:", ",resolve({value:i,key:r}){if(i===null)return"";if(typeof i=="boolean")return`${r}`},...n==null?void 0:n.unpack})}const bh=["og:image","og:video","og:audio","twitter:image"];function vh(e){const t={};return Object.entries(e).forEach(([n,i])=>{String(i)!=="false"&&n&&(t[n]=i)}),t}function Zl(e,t){const n=vh(t),i=Cn(e),r=yh(i);if(bh.includes(i)){const s={};return Object.entries(n).forEach(([a,o])=>{s[`${e}${a==="url"?"":`${a.charAt(0).toUpperCase()}${a.slice(1)}`}`]=o}),Yo(s).sort((a,o)=>{var l,c;return(((l=a[r])==null?void 0:l.length)||0)-(((c=o[r])==null?void 0:c.length)||0)})}return[{[r]:i,...n}]}function Yo(e){const t=[],n={};Object.entries(e).forEach(([r,s])=>{if(!Array.isArray(s)){if(typeof s=="object"&&s){if(bh.includes(Cn(r))){t.push(...Zl(r,s));return}n[r]=vh(s)}else n[r]=s;return}s.forEach(a=>{t.push(...typeof a=="string"?Yo({[r]:a}):Zl(r,a))})});const i=fh(n,{key({key:r}){return yh(r)},value({key:r}){return r==="charset"?"charset":"content"},resolveKeyData({key:r}){return Zb(r)},resolveValueData({value:r,key:s}){return r===null?"_null":typeof r=="object"?qb(r,s):typeof r=="number"?r.toString():r}});return[...t,...i].map(r=>(r.content==="_null"&&(r.content=null),r))}async function Jb(e,t,n){const i={tag:e,props:await _h(typeof t=="object"&&typeof t!="function"&&!(t instanceof Promise)?{...t}:{[["script","noscript","style"].includes(e)?"innerHTML":"textContent"]:t},["templateParams","titleTemplate"].includes(e))};return hh.forEach(r=>{const s=typeof i.props[r]<"u"?i.props[r]:n[r];typeof s<"u"&&((!["innerHTML","textContent","children"].includes(r)||jb.includes(i.tag))&&(i[r==="children"?"innerHTML":r]=s),delete i.props[r])}),i.props.body&&(i.tagPosition="bodyClose",delete i.props.body),i.tag==="script"&&typeof i.innerHTML=="object"&&(i.innerHTML=JSON.stringify(i.innerHTML),i.props.type=i.props.type||"application/json"),Array.isArray(i.props.content)?i.props.content.map(r=>({...i,props:{...i.props,content:r}})):i}function Xb(e,t){var i;const n=e==="class"?" ":";";return typeof t=="object"&&!Array.isArray(t)&&(t=Object.entries(t).filter(([,r])=>r).map(([r,s])=>e==="style"?`${r}:${s}`:r)),(i=String(Array.isArray(t)?t.join(n):t))==null?void 0:i.split(n).filter(r=>r.trim()).filter(Boolean).join(n)}async function _h(e,t){for(const n of Object.keys(e)){if(["class","style"].includes(n)){e[n]=Xb(n,e[n]);continue}if(e[n]instanceof Promise&&(e[n]=await e[n]),!t&&!hh.includes(n)){const i=String(e[n]),r=n.startsWith("data-");i==="true"||i===""?e[n]=r?"true":!0:e[n]||(r&&i==="false"?e[n]="false":delete e[n])}}return e}const e1=10;async function t1(e){const t=[];return Object.entries(e.resolvedInput).filter(([n,i])=>typeof i<"u"&&Yb.includes(n)).forEach(([n,i])=>{const r=Gb(i);t.push(...r.map(s=>Jb(n,s,e)).flat())}),(await Promise.all(t)).flat().filter(Boolean).map((n,i)=>(n._e=e._i,e.mode&&(n._m=e.mode),n._p=(e._i<<e1)+i,n))}const ql={base:-10,title:10},Jl={critical:-80,high:-10,low:20};function lr(e){let t=100;const n=e.tagPriority;return typeof n=="number"?n:(e.tag==="meta"?(e.props["http-equiv"]==="content-security-policy"&&(t=-30),e.props.charset&&(t=-20),e.props.name==="viewport"&&(t=-15)):e.tag==="link"&&e.props.rel==="preconnect"?t=20:e.tag in ql&&(t=ql[e.tag]),typeof n=="string"&&n in Jl?t+Jl[n]:t)}const n1=[{prefix:"before:",offset:-1},{prefix:"after:",offset:1}],Xl=["onload","onerror","onabort","onprogress","onloadstart"],Ln="%separator";
4function qi(e,t,n){if(typeof e!="string"||!e.includes("%"))return e;function i(a){let o;return["s","pageTitle"].includes(a)?o=t.pageTitle:a.includes(".")?o=a.split(".").reduce((l,c)=>l&&l[c]||void 0,t):o=t[a],typeof o<"u"?(o||"").replace(/"/g,'\\"'):!1}let r=e;try{r=decodeURI(e)}catch{}return(r.match(/%(\w+\.+\w+)|%(\w+)/g)||[]).sort().reverse().forEach(a=>{const o=i(a.slice(1));typeof o=="string"&&(e=e.replace(new RegExp(`\\${a}(\\W|$)`,"g"),(l,c)=>`${o}${c}`).trim())}),e.includes(Ln)&&(e.endsWith(Ln)&&(e=e.slice(0,-Ln.length).trim()),e.startsWith(Ln)&&(e=e.slice(Ln.length).trim()),e=e.replace(new RegExp(`\\${Ln}\\s*\\${Ln}`,"g"),Ln),e=qi(e,{separator:n},n)),e}async function wh(e,t={}){var d;const n=t.document||e.resolvedOptions.document;if(!n||!e.dirty)return;const i={shouldRender:!0,tags:[]};if(await e.hooks.callHook("dom:beforeRender",i),!i.shouldRender)return;const r=(await e.resolveTags()).map(u=>({tag:u,id:Zi.includes(u.tag)?Wl(u):u.tag,shouldRender:!0}));let s=e._dom;if(!s){s={elMap:{htmlAttrs:n.documentElement,bodyAttrs:n.body}};for(const u of["body","head"]){const p=(d=n[u])==null?void 0:d.children,h=[];for(const m of[...p].filter(v=>Zi.includes(v.tagName.toLowerCase()))){const v={tag:m.tagName.toLowerCase(),props:await _h(m.getAttributeNames().reduce((w,C)=>({...w,[C]:m.getAttribute(C)}),{})),innerHTML:m.innerHTML};let _=1,b=ph(v);for(;b&&h.find(w=>w._d===b);)b=`${b}:${_++}`;v._d=b||void 0,h.push(v),s.elMap[m.getAttribute("data-hid")||Wl(v)]=m}}}s.pendingSideEffects={...s.sideEffects||{}},s.sideEffects={};function a(u,p,h){const m=`${u}:${p}`;s.sideEffects[m]=h,delete s.pendingSideEffects[m]}function o({id:u,$el:p,tag:h}){const m=h.tag.endsWith("Attrs");s.elMap[u]=p,m||(["textContent","innerHTML"].forEach(v=>{h[v]&&h[v]!==p[v]&&(p[v]=h[v])}),a(u,"el",()=>{var v;(v=s.elMap[u])==null||v.remove(),delete s.elMap[u]}));for(const[v,_]of Object.entries(h._eventHandlers||{}))p.getAttribute(`data-${v}`)!==""&&((h.tag==="bodyAttrs"?n.defaultView:p).addEventListener(v.replace("on",""),_.bind(p)),p.setAttribute(`data-${v}`,""));Object.entries(h.props).forEach(([v,_])=>{const b=`attr:${v}`;if(v==="class")for(const w of(_||"").split(" ").filter(Boolean))m&&a(u,`${b}:${w}`,()=>p.classList.remove(w)),!p.classList.contains(w)&&p.classList.add(w);else if(v==="style")for(const w of(_||"").split(";").filter(Boolean)){const[C,...O]=w.split(":").map(T=>T.trim());a(u,`${b}:${w}:${C}`,()=>{p.style.removeProperty(C)}),p.style.setProperty(C,O.join(":"))}else p.getAttribute(v)!==_&&p.setAttribute(v,_===!0?"":String(_)),m&&a(u,b,()=>p.removeAttribute(v))})}const l=[],c={bodyClose:void 0,bodyOpen:void 0,head:void 0};for(const u of r){const{tag:p,shouldRender:h,id:m}=u;if(h){if(p.tag==="title"){n.title=p.textContent;continue}u.$el=u.$el||s.elMap[m],u.$el?o(u):Zi.includes(p.tag)&&l.push(u)}}for(const u of l){const p=u.tag.tagPosition||"head";u.$el=n.createElement(u.tag.tag),o(u),c[p]=c[p]||n.createDocumentFragment(),c[p].appendChild(u.$el)}for(const u of r)await e.hooks.callHook("dom:renderTag",u,n,a);c.head&&n.head.appendChild(c.head),c.bodyOpen&&n.body.insertBefore(c.bodyOpen,n.body.firstChild),c.bodyClose&&n.body.appendChild(c.bodyClose),Object.values(s.pendingSideEffects).forEach(u=>u()),e._dom=s,e.dirty=!1,await e.hooks.callHook("dom:rendered",{renders:r})}async function s1(e,t={}){const n=t.delayFn||(i=>setTimeout(i,10));return e._domUpdatePromise=e._domUpdatePromise||new Promise(i=>n(async()=>{await wh(e,t),delete e._domUpdatePromise,i()}))}function i1(e){return t=>{var i,r;const n=((r=(i=t.resolvedOptions.document)==null?void 0:i.head.querySelector('script[id="unhead:payload"]'))==null?void 0:r.innerHTML)||!1;return n&&t.push(JSON.parse(n)),{mode:"client",hooks:{"entries:updated":function(s){s1(s,e)}}}}}const r1=["templateParams","htmlAttrs","bodyAttrs"],a1={hooks:{"tag:normalise":function({tag:e}){["hid","vmid","key"].forEach(i=>{e.props[i]&&(e.key=e.props[i],delete e.props[i])});const n=ph(e)||(e.key?`${e.tag}:${e.key}`:!1);n&&(e._d=n)},"tags:resolve":function(e){const t={};e.tags.forEach(i=>{const r=(i.key?`${i.tag}:${i.key}`:i._d)||i._p,s=t[r];
4if(s){let o=i==null?void 0:i.tagDuplicateStrategy;if(!o&&r1.includes(i.tag)&&(o="merge"),o==="merge"){const l=s.props;["class","style"].forEach(c=>{l[c]&&(i.props[c]?(c==="style"&&!l[c].endsWith(";")&&(l[c]+=";"),i.props[c]=`${l[c]} ${i.props[c]}`):i.props[c]=l[c])}),t[r].props={...l,...i.props};return}else if(i._e===s._e){s._duped=s._duped||[],i._d=`${s._d}:${s._duped.length+1}`,s._duped.push(i);return}else if(lr(i)>lr(s))return}const a=Object.keys(i.props).length+(i.innerHTML?1:0)+(i.textContent?1:0);if(Zi.includes(i.tag)&&a===0){delete t[r];return}t[r]=i});const n=[];Object.values(t).forEach(i=>{const r=i._duped;delete i._duped,n.push(i),r&&n.push(...r)}),e.tags=n,e.tags=e.tags.filter(i=>!(i.tag==="meta"&&(i.props.name||i.props.property)&&!i.props.content))}}},o1={mode:"server",hooks:{"tags:resolve":function(e){const t={};e.tags.filter(n=>["titleTemplate","templateParams","title"].includes(n.tag)&&n._m==="server").forEach(n=>{t[n.tag]=n.tag.startsWith("title")?n.textContent:n.props}),Object.keys(t).length&&e.tags.push({tag:"script",innerHTML:JSON.stringify(t),props:{id:"unhead:payload",type:"application/json"}})}}},l1=["script","link","bodyAttrs"],c1=e=>({hooks:{"tags:resolve":function(t){for(const n of t.tags.filter(i=>l1.includes(i.tag)))Object.entries(n.props).forEach(([i,r])=>{i.startsWith("on")&&typeof r=="function"&&(e.ssr&&Xl.includes(i)?n.props[i]=`this.dataset.${i}fired = true`:delete n.props[i],n._eventHandlers=n._eventHandlers||{},n._eventHandlers[i]=r)}),e.ssr&&n._eventHandlers&&(n.props.src||n.props.href)&&(n.key=n.key||Go(n.props.src||n.props.href))},"dom:renderTag":function({$el:t,tag:n}){var i,r;for(const s of Object.keys((t==null?void 0:t.dataset)||{}).filter(a=>Xl.some(o=>`${o}fired`===a))){const a=s.replace("fired","");(r=(i=n._eventHandlers)==null?void 0:i[a])==null||r.call(t,new Event(a.replace("on","")))}}}}),d1=["link","style","script","noscript"],u1={hooks:{"tag:normalise":({tag:e})=>{e.key&&d1.includes(e.tag)&&(e.props["data-hid"]=e._h=Go(e.key))}}},h1={hooks:{"tags:resolve":e=>{const t=n=>{var i;return(i=e.tags.find(r=>r._d===n))==null?void 0:i._p};for(const{prefix:n,offset:i}of n1)for(const r of e.tags.filter(s=>typeof s.tagPriority=="string"&&s.tagPriority.startsWith(n))){const s=t(r.tagPriority.replace(n,""));typeof s<"u"&&(r._p=s+i)}e.tags.sort((n,i)=>n._p-i._p).sort((n,i)=>lr(n)-lr(i))}}},p1={meta:"content",link:"href",htmlAttrs:"lang"},f1=e=>({hooks:{"tags:resolve":t=>{var o;const{tags:n}=t,i=(o=n.find(l=>l.tag==="title"))==null?void 0:o.textContent,r=n.findIndex(l=>l.tag==="templateParams"),s=r!==-1?n[r].props:{},a=s.separator||"|";delete s.separator,s.pageTitle=qi(s.pageTitle||i||"",s,a);for(const l of n.filter(c=>c.processTemplateParams!==!1)){const c=p1[l.tag];c&&typeof l.props[c]=="string"?l.props[c]=qi(l.props[c],s,a):(l.processTemplateParams===!0||["titleTemplate","title"].includes(l.tag))&&["innerHTML","textContent"].forEach(d=>{typeof l[d]=="string"&&(l[d]=qi(l[d],s,a))})}e._templateParams=s,e._separator=a,t.tags=n.filter(l=>l.tag!=="templateParams")}}}),m1={hooks:{"tags:resolve":e=>{const{tags:t}=e;let n=t.findIndex(r=>r.tag==="titleTemplate");const i=t.findIndex(r=>r.tag==="title");if(i!==-1&&n!==-1){const r=Ql(t[n].textContent,t[i].textContent);r!==null?t[i].textContent=r||t[i].textContent:delete t[i]}else if(n!==-1){const r=Ql(t[n].textContent);r!==null&&(t[n].textContent=r,t[n].tag="title",n=-1)}n!==-1&&delete t[n],e.tags=t.filter(Boolean)}}},g1={hooks:{"tags:afterResolve":function(e){for(const t of e.tags)typeof t.innerHTML=="string"&&(t.innerHTML&&["application/ld+json","application/json"].includes(t.props.type)?t.innerHTML=t.innerHTML.replace(/</g,"\\u003C"):t.innerHTML=t.innerHTML.replace(new RegExp(`</${t.tag}`,"g"),`<\\/${t.tag}`))}}};let Eh;function y1(e={}){const t=b1(e);return t.use(i1()),Eh=t}function ec(e,t){return!e||e==="server"&&t||e==="client"&&!t}function b1(e={}){const t=nh();t.addHooks(e.hooks||{}),e.document=e.document||(Qb?document:void 0);const n=!e.document,i=()=>{o.dirty=!0,t.callHook("entries:updated",o)};let r=0,s=[];const a=[],o={plugins:a,dirty:!1,resolvedOptions:e,hooks:t,headEntries(){return s},use(l){const c=typeof l=="function"?l(o):l;(!c.key||!a.some(d=>d.key===c.key))&&(a.push(c),ec(c.mode,n)&&t.addHooks(c.hooks||{}))},push(l,c){c==null||delete c.head;const d={_i:r++,input:l,...c};return ec(d.mode,n)&&(s.push(d),i()),{dispose(){s=s.filter(u=>u._i!==d._i),t.callHook("entries:updated",o),i()},patch(u){s=s.map(p=>(p._i===d._i&&(p.input=d.input=u),p)),i()}}},async resolveTags(){const l={tags:[],entries:[...s]};await t.callHook("entries:resolve",l);for(const c of l.entries){const d=c.resolvedInput||c.input;if(c.resolvedInput=await(c.transform?c.transform(d):d),c.resolvedInput)for(const u of await t1(c)){const p={tag:u,entry:c,resolvedOptions:o.resolvedOptions};await t.callHook("tag:normalise",p),l.tags.push(p.tag)}}return await t.callHook("tags:beforeResolve",l),await t.callHook("tags:resolve",l),await t.callHook("tags:afterResolve",l),l.tags},ssr:n};return[a1,o1,c1,u1,h1,f1,m1,g1,...(e==null?void 0:e.plugins)||[]].forEac
4h(l=>o.use(l)),o.hooks.callHook("init",o),o}function v1(){return Eh}const _1=$g.startsWith("3");function w1(e){return typeof e=="function"?e():k(e)}function cr(e,t=""){if(e instanceof Promise)return e;const n=w1(e);return!e||!n?n:Array.isArray(n)?n.map(i=>cr(i,t)):typeof n=="object"?Object.fromEntries(Object.entries(n).map(([i,r])=>i==="titleTemplate"||i.startsWith("on")?[i,k(r)]:[i,cr(r,i)])):n}const E1={hooks:{"entries:resolve":function(e){for(const t of e.entries)t.resolvedInput=cr(t.input)}}},Sh="usehead";function S1(e){return{install(n){_1&&(n.config.globalProperties.$unhead=e,n.config.globalProperties.$head=e,n.provide(Sh,e))}}.install}function C1(e={}){e.domDelayFn=e.domDelayFn||(n=>kt(()=>setTimeout(()=>n(),0)));const t=y1(e);return t.use(E1),t.install=S1(t),t}const eo=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{},to="__unhead_injection_handler__";function I1(e){eo[to]=e}function T1(){if(to in eo)return eo[to]();const e=Ft(Sh);return e||v1()}function Me(e,t={}){const n=t.head||T1();if(n)return n.ssr?n.push(e,t):P1(n,e,t)}function P1(e,t,n={}){const i=Re(!1),r=Re({});Ci(()=>{r.value=i.value?{}:cr(t)});const s=e.push(r.value,n);return We(r,o=>{s.patch(o)}),ln()&&(Cr(()=>{s.dispose()}),Bu(()=>{i.value=!0}),$u(()=>{i.value=!1})),s}function O1(e,t){const{title:n,titleTemplate:i,...r}=e;return Me({title:n,titleTemplate:i,_flatMeta:r},{...t,transform(s){const a=Yo({...s._flatMeta});return delete s._flatMeta,{...s,meta:a}}})}function hn(e){if(typeof e!="object")return e;var t,n,i=Object.prototype.toString.call(e);if(i==="[object Object]"){if(e.constructor!==Object&&typeof e.constructor=="function"){n=new e.constructor;for(t in e)e.hasOwnProperty(t)&&n[t]!==e[t]&&(n[t]=hn(e[t]))}else{n={};for(t in e)t==="__proto__"?Object.defineProperty(n,t,{value:hn(e[t]),configurable:!0,enumerable:!0,writable:!0}):n[t]=hn(e[t])}return n}if(i==="[object Array]"){for(t=e.length,n=Array(t);t--;)n[t]=hn(e[t]);return n}return i==="[object Set]"?(n=new Set,e.forEach(function(r){n.add(hn(r))}),n):i==="[object Map]"?(n=new Map,e.forEach(function(r,s){n.set(hn(s),hn(r))}),n):i==="[object Date]"?new Date(+e):i==="[object RegExp]"?(n=new RegExp(e.source,e.flags),n.lastIndex=e.lastIndex,n):i==="[object DataView]"?new e.constructor(hn(e.buffer)):i==="[object ArrayBuffer]"?e.slice(0):i.slice(-6)==="Array]"?new e.constructor(e):e}const A1={nuxt:{buildId:"6c8d8a6f-89a2-435d-a1e9-162bc834427c"}},k1=Tb(A1);function Ch(){const e=ct();return e._appConfig||(e._appConfig=Wt(k1)),e._appConfig}const no=!1,R1=!1,L1={deep:!0},N1={},D1="#__nuxt";let Ji,Ih;function x1(){var t;const e=(t=Ch().nuxt)==null?void 0:t.buildId;return Ji=$fetch(Ko(`builds/meta/${e}.json`)),Ji.then(n=>{Ih=Ib(n.matcher)}),Ji}function Lr(){return Ji||x1()}async function Wo(e){return await Lr(),ch({},...Ih.matchAll(e).reverse())}function tc(e,t={}){const n=F1(e,t),i=ct(),r=i._payloadCache=i._payloadCache||{};return n in r||(r[n]=V1(e).then(s=>s?Th(n).then(a=>a||(delete r[n],null)):(r[n]=null,null))),r[n]}const M1="_payload.json";function F1(e,t={}){var r;const n=new URL(e,"http://localhost");if(n.host!=="localhost"||vn(n.pathname,{acceptRelative:!0}))throw new Error("Payload URL must not include hostname: "+e);const i=t.hash||(t.fresh?Date.now():(r=Ch().nuxt)==null?void 0:r.buildId);return Ms(Be().app.baseURL,n.pathname,M1+(i?`?${i}`:""))}async function Th(e){const t=fetch(e).then(n=>n.text().then(Ph));try{return await t}catch(n){console.warn("[nuxt] Cannot load payload ",e,n)}return null}async function V1(e=On().path){if(e=Pr(e),(await Lr()).prerendered.includes(e))return!0;const n=await Wo(e);return!!n.prerender&&!n.redirect}let Vi=null;async function B1(){if(Vi)return Vi;const e=document.getElementById("__NUXT_DATA__");if(!e)return{};const t=await Ph(e.textContent||""),n=e.dataset.src?await Th(e.dataset.src):void 0;return Vi={...t,...n,...window.__NUXT__},Vi}async function Ph(e){return await zb(e,ct()._payloadRevivers)}function $1(e,t){ct()._payloadRevivers[e]=t}const nc={NuxtError:e=>Ti(e),EmptyShallowRef:e=>Kn(e==="_"?void 0:e==="0n"?BigInt(0):ri(e)),EmptyRef:e=>Re(e==="_"?void 0:e==="0n"?BigInt(0):ri(e)),ShallowRef:e=>Kn(e),ShallowReactive:e=>Ir(e),Ref:e=>Re(e),Reactive:e=>Wt(e)},U1=_t({name:"nuxt:revive-payload:client",order:-30,async setup(e){let t,n;for(const i in nc)$1(i,nc[i]);Object.assign(e.payload,([t,n]=fn(()=>
vendor: 21,475 bytes, lines 4-8
4e.runWithContext(B1)),t=await t,n(),t)),window.__NUXT__=e.payload}}),H1=[],z1=_t({name:"nuxt:head",enforce:"pre",setup(e){const t=C1({plugins:H1});I1(()=>ct().vueApp._context.provides.usehead),e.vueApp.use(t);{let n=!0;const i=async()=>{n=!1,await wh(t)};t.hooks.hook("dom:beforeRender",r=>{r.shouldRender=!n}),e.hooks.hook("page:start",()=>{n=!0}),e.hooks.hook("page:finish",()=>{e.isHydrating||i()}),e.hooks.hook("app:error",i),e.hooks.hook("app:suspense:resolve",i)}}});/*!
5  * vue-router v4.3.2
6  * (c) 2024 Eduardo San Martin Morote
7  * @license MIT
8  */const _s=typeof document<"u";function K1(e){return e.__esModule||e[Symbol.toStringTag]==="Module"}const at=Object.assign;function ga(e,t){const n={};for(const i in t){const r=t[i];n[i]=an(r)?r.map(e):e(r)}return n}const qs=()=>{},an=Array.isArray,Oh=/#/g,G1=/&/g,j1=/\//g,Y1=/=/g,W1=/\?/g,Ah=/\+/g,Q1=/%5B/g,Z1=/%5D/g,kh=/%5E/g,q1=/%60/g,Rh=/%7B/g,J1=/%7C/g,Lh=/%7D/g,X1=/%20/g;function Qo(e){return encodeURI(""+e).replace(J1,"|").replace(Q1,"[").replace(Z1,"]")}function ev(e){return Qo(e).replace(Rh,"{").replace(Lh,"}").replace(kh,"^")}function so(e){return Qo(e).replace(Ah,"%2B").replace(X1,"+").replace(Oh,"%23").replace(G1,"%26").replace(q1,"`").replace(Rh,"{").replace(Lh,"}").replace(kh,"^")}function tv(e){return so(e).replace(Y1,"%3D")}function nv(e){return Qo(e).replace(Oh,"%23").replace(W1,"%3F")}function sv(e){return e==null?"":nv(e).replace(j1,"%2F")}function ai(e){try{return decodeURIComponent(""+e)}catch{}return""+e}const iv=/\/$/,rv=e=>e.replace(iv,"");function ya(e,t,n="/"){let i,r={},s="",a="";const o=t.indexOf("#");let l=t.indexOf("?");return o<l&&o>=0&&(l=-1),l>-1&&(i=t.slice(0,l),s=t.slice(l+1,o>-1?o:t.length),r=e(s)),o>-1&&(i=i||t.slice(0,o),a=t.slice(o,t.length)),i=cv(i??t,n),{fullPath:i+(s&&"?")+s+a,path:i,query:r,hash:ai(a)}}function av(e,t){const n=t.query?e(t.query):"";return t.path+(n&&"?")+n+(t.hash||"")}function sc(e,t){return!t||!e.toLowerCase().startsWith(t.toLowerCase())?e:e.slice(t.length)||"/"}function ov(e,t,n){const i=t.matched.length-1,r=n.matched.length-1;return i>-1&&i===r&&Ts(t.matched[i],n.matched[r])&&Nh(t.params,n.params)&&e(t.query)===e(n.query)&&t.hash===n.hash}function Ts(e,t){return(e.aliasOf||e)===(t.aliasOf||t)}function Nh(e,t){if(Object.keys(e).length!==Object.keys(t).length)return!1;for(const n in e)if(!lv(e[n],t[n]))return!1;return!0}function lv(e,t){return an(e)?ic(e,t):an(t)?ic(t,e):e===t}function ic(e,t){return an(t)?e.length===t.length&&e.every((n,i)=>n===t[i]):e.length===1&&e[0]===t}function cv(e,t){if(e.startsWith("/"))return e;if(!e)return t;const n=t.split("/"),i=e.split("/"),r=i[i.length-1];(r===".."||r===".")&&i.push("");let s=n.length-1,a,o;for(a=0;a<i.length;a++)if(o=i[a],o!==".")if(o==="..")s>1&&s--;else break;return n.slice(0,s).join("/")+"/"+i.slice(a).join("/")}var oi;(function(e){e.pop="pop",e.push="push"})(oi||(oi={}));var Js;(function(e){e.back="back",e.forward="forward",e.unknown=""})(Js||(Js={}));function dv(e){if(!e)if(_s){const t=document.querySelector("base");e=t&&t.getAttribute("href")||"/",e=e.replace(/^\w+:\/\/[^\/]+/,"")}else e="/";return e[0]!=="/"&&e[0]!=="#"&&(e="/"+e),rv(e)}const uv=/^[^#]+#/;function hv(e,t){return e.replace(uv,"#")+t}function pv(e,t){const n=document.documentElement.getBoundingClientRect(),i=e.getBoundingClientRect();return{behavior:t.behavior,left:i.left-n.left-(t.left||0),top:i.top-n.top-(t.top||0)}}const Nr=()=>({left:window.scrollX,top:window.scrollY});function fv(e){let t;if("el"in e){const n=e.el,i=typeof n=="string"&&n.startsWith("#"),r=typeof n=="string"?i?document.getElementById(n.slice(1)):document.querySelector(n):n;if(!r)return;t=pv(r,e)}else t=e;"scrollBehavior"in document.documentElement.style?window.scrollTo(t):window.scrollTo(t.left!=null?t.left:window.scrollX,t.top!=null?t.top:window.scrollY)}function rc(e,t){return(history.state?history.state.position-t:-1)+e}const io=new Map;function mv(e,t){io.set(e,t)}function gv(e){const t=io.get(e);return io.delete(e),t}let yv=()=>location.protocol+"//"+location.host;function Dh(e,t){const{pathname:n,search:i,hash:r}=t,s=e.indexOf("#");if(s>-1){let o=r.includes(e.slice(s))?e.slice(s).length:1,l=r.slice(o);return l[0]!=="/"&&(l="/"+l),sc(l,"")}return sc(n,e)+i+r}function bv(e,t,n,i){let r=[],s=[],a=null;const o=({state:p})=>{const h=Dh(e,location),m=n.value,v=t.value;let _=0;if(p){if(n.value=h,t.value=p,a&&a===m){a=null;return}_=v?p.position-v.position:0}else i(h);r.forEach(b=>{b(n.value,m,{delta:_,type:oi.pop,direction:_?_>0?Js.forward:Js.back:Js.unknown})})};function l(){a=n.value}function c(p){r.push(p);const h=()=>{const m=r.indexOf(p);m>-1&&r.splice(m,1)};return s.push(h),h}function d(){const{history:p}=window;p.state&&p.replaceState(at({},p.state,{scroll:Nr()}),"")}function u(){for(const p of s)p();s=[],window.removeEventListener("popstate",o),window.removeEventListener("beforeunload",d)}return window.addEventListener("popstate",o),window.addEventListener("beforeunload",d,{passive:!0}),{pauseListeners:l,listen:c,destroy:u}}function ac(e,t,n,i=!1,r=!1){return{back:e,current:t,forward:n,replaced:i,position:window.history.length,scroll:r?Nr():null}}function vv(e){const{history:t,location:n}=window,i={value:Dh(e,n)},r={value:t.state};r.value||s(i.value,{back:null,current:i.value,forward:null,position:t.length-1,replaced:!0,scroll:null},!0);function s(l,c,d){const u=e.indexOf("#"),p=u>-1?(n.host&&document.querySelector("base")?e:e.slice(u))+l:yv()+e+l;try{t[d?"replaceState":"pushState"](c,"",p),r.value=c}catch(h){console.error(h),n[d?"replace":"assign"](p)}}function a(l,c){const d=at({},t.state,ac(r.value.back,l,r.value.forward,!0),c,{position:r.value.position});s(l,d,!0),i.value=l}function o(l,c){const d=at({},r.value,t.state,{forward:l,scroll:Nr()});s(d.current,d,!0);const u=at({},ac(i.value,l,null),{position:d.position+1},c);s(l,u,!1),i.value=l}return{location:i,state:r,push:o,replace:a}}function xh(e){e=dv(e);const t=vv(e),n=bv(e,t.state,t.location,t.replace);function i(s,a=!0){a||n.pauseListeners(),history.go(s)}const r=at({location:"",base:e,go:i,createHref:hv.bind(null,e)},t,n);return Object.defineProperty(r,"location",{enumerable:!0,get:()=>t.location.value}),Object.defineProperty(r,"state",{enumerable:!0,get:()=>t.state.value}),r}function _v(e){return e=location.host?e||location.pathname+location.search:"",e.includes("#")||(e+="#"),xh(e)}function wv(e){return typeof e=="string"||e&&typeof e=="object"}function Mh(e){return typeof e=="string"||typeof e=="symbol"}const nn={path:"/",name:void 0,params:{},query:{},hash:"",fullPath:"/",matched:[],meta:{},redirectedFrom:void 0},Fh=Symbol("");var oc;(function(e){e[e.aborted=4]="aborted",e[e.cancelled=8]="cancelled",e[e.duplicated=16]="duplicated"})(oc||(oc={}));function Ps(e,t){return at(new Error,{type:e,[Fh]:!0},t)}function wn(e,t){return e instanceof Error&&Fh in e&&(t==null||!!(e.type&t))}const lc="[^/]+?",Ev={sensitive:!1,strict:!1,start:!0,end:!0},Sv=/[.+*?^${}()[\]/\\]/g;function Cv(e,t){const n=at({},Ev,t),i=[];let r=n.start?"^":"";const s=[];for(const c of e){const d=c.length?[]:[90];n.strict&&!c.length&&(r+="/");for(let u=0;u<c.length;u++){const p=c[u];let h=40+(n.sensitive?.25:0);if(p.type===0)u||(r+="/"),r+=p.value.replace(Sv,"\\$&"),h+=40;else if(p.type===1){const{value:m,repeatable:v,optional:_,regexp:b}=p;s.push({name:m,repeatable:v,optional:_});const w=b||lc;if(w!==lc){h+=10;try{new RegExp(`(${w})`)}catch(O){throw new Error(`Invalid custom RegExp for param "${m}" (${w}): `+O.message)}}let C=v?`((?:${w})(?:/(?:${w}))*)`:`(${w})`;u||(C=_&&c.length<2?`(?:/${C})`:"/"+C),_&&(C+="?"),r+=C,h+=20,_&&(h+=-8),v&&(h+=-20),w===".*"&&(h+=-50)}d.push(h)}i.push(d)}if(n.strict&&n.end){const c=i.length-1;i[c][i[c].length-1]+=.7000000000000001}n.strict||(r+="/?"),n.end?r+="$":n.strict&&(r+="(?:/|$)");const a=new RegExp(r,n.sensitive?"":"i");function o(c){const d=c.match(a),u={};if(!d)return null;for(let p=1;p<d.length;p++){const h=d[p]||"",m=s[p-1];u[m.name]=h&&m.repeatable?h.split("/"):h}return u}function l(c){let d="",u=!1;for(const p of e){(!u||!d.endsWith("/"))&&(d+="/"),u=!1;for(const h of p)if(h.type===0)d+=h.value;else if(h.type===1){const{value:m,repeatable:v,optional:_}=h,b=m in c?c[m]:"";if(an(b)&&!v)throw new Error(`Provided param "${m}" is an array but it is not repeatable (* or + modifiers)`);const w=an(b)?b.join("/"):b;if(!w)if(_)p.length<2&&(d.endsWith("/")?d=d.slice(0,-1):u=!0);else throw new Error(`Missing required param "${m}"`);d+=w}}return d||"/"}return{re:a,score:i,keys:s,parse:o,stringify:l}}function Iv(e,t){let n=0;for(;n<e.length&&n<t.length;){const i=t[n]-e[n];if(i)return i;n++}return e.length<t.length?e.length===1&&e[0]===80?-1:1:e.length>t.length?t.length===1&&t[0]===80?1:-1:0}function Tv(e,t){let n=0;const i=e.score,r=t.score;for(;n<i.length&&n<r.length;){const s=Iv(i[n],r[n]);if(s)return s;n++}if(Math.abs(r.length-i.length)===1){if(cc(i))return 1;if(cc(r))return-1}return r.length-i.length}function cc(e){const t=e[e.length-1];return e.length>0&&t[t.length-1]<0}const Pv={type:0,value:""},Ov=/[a-zA-Z0-9_]/;function Av(e){if(!e)return[[]];if(e==="/")return[[Pv]];if(!e.startsWith("/"))throw new Error(`Invalid path "${e}"`);function t(h){throw new Error(`ERR (${n})/"${c}": ${h}`)}let n=0,i=n;const r=[];let s;function a(){s&&r.push(s),s=[]}let o=0,l,c="",d="";function u(){c&&(n===0?s.push({type:0,value:c}):n===1||n===2||n===3?(s.length>1&&(l==="*"||l==="+")&&t(`A repeatable param (${c}) must be alone in its segment. eg: '/:ids+.`),s.push({type:1,value:c,regexp:d,repeatable:l==="*"||l==="+",optional:l==="*"||l==="?"})):t("Invalid state to consume buffer"),c="")}function p(){c+=l}for(;o<e.length;){if(l=e[o++],l==="\\"&&n!==2){i=n,n=4;continue}switch(n){case 0:l==="/"?(c&&u(),a()):l===":"?(u(),n=1):p();break;case 4:p(),n=i;break;case 1:l==="("?n=2:Ov.test(l)?p():(u(),n=0,l!=="*"&&l!=="?"&&l!=="+"&&o--);break;case 2:l===")"?d[d.length-1]=="\\"?d=d.slice(0,-1)+l:n=3:d+=l;break;case 3:u(),n=0,l!=="*"&&l!=="?"&&l!=="+"&&o--,d="";break;default:t("Unknown state");break}}return n===2&&t(`Unfinished custom RegExp for param "${c}"`),u(),a(),r}function kv(e,t,n){const i=Cv(Av(e.path),n),r=at(i,{record:e,parent:t,children:[],alias:[]});return t&&!r.record.aliasOf==!t.record.aliasOf&&t.children.push(r),r}function Rv(e,t){const n=[],i=new Map;t=hc({strict:!1,end:!0,sensitive:!1},t);function r(d){return i.get(d)}function s(d,u,p){const h=!p,m=Lv(d);m.aliasOf=p&&p.record;const v=hc(t,d),_=[m];if("alias"in d){const C=typeof d.alias=="string"?[d.alias]:d.alias;for(const O of C)_.push(at({},m,{components:p?p.record.components:m.components,path:O,aliasOf:p?p.record:m}))}let b,w;for(const C of _){const{path:O}=C;if(u&&O[0]!=="/"){const T=u.record.path,E=T[T.length-1]==="/"?"":"/";C.path=u.record.path+(O&&E+O)}if(b=kv(C,u,v),p?p.alias.push(b):(w=w||b,w!==b&&w.alias.push(b),h&&d.name&&!uc(b)&&a(d.name)),m.children){const T=m.children;for(let E=0;E<T.length;E++)s(T[E],b,p&&p.children[E])}p=p||b,(b.record.components&&Object.keys(b.record.components).length||b.record.name||b.record.redirect)&&l(b)}return w?()=>{a(w)}:qs}function a(d){if(Mh(d)){const u=i.get(d);u&&(i.delete(d),n.splice(n.indexOf(u),1),u.children.forEach(a),u.alias.forEach(a))}else{const u=n.indexOf(d);u>-1&&(n.splice(u,1),d.record.name&&i.delete(d.record.name),d.children.forEach(a),d.alias.forEach(a))}}function o(){return n}function l(d){let u=0;for(;u<n.length&&Tv(d,n[u])>=0&&(d.record.path!==n[u].record.path||!Vh(d,n[u]));)u++;n.splice(u,0,d),d.record.name&&!uc(d)&&i.set(d.record.name,d)}function c(d,u){let p,h={},m,v;if("name"in d&&d.name){if(p=i.get(d.name),!p)throw Ps(1,{location:d});v=p.record.name,h=at(dc(u.params,p.keys.filter(w=>!w.optional).concat(p.parent?p.parent.keys.filter(w=>w.optional):[]).map(w=>w.name)),d.params&&dc(d.params,p.keys.map(w=>w.name))),m=p.stringify(h)}else if(d.path!=null)m=d.path,p=n.find(w=>w.re.test(m)),p&&(h=p.parse(m),v=p.record.name);else{if(p=u.name?i.get(u.name):n.find(w=>w.re.test(u.path)),!p)throw Ps(1,{location:d,currentLocation:u});v=p.record.name,h=at({},u.params,d.params),m=p.stringify(h)}const _=[];let b=p;for(;b;)_.unshift(b.record),b=b.parent;return{name:v,path:m,params:h,matched:_,meta:Dv(_)}}return e.forEach(d=>s(d)),{addRoute:s,resolve:c,removeRoute:a,getRoutes:o,getRecordMatcher:r}}function dc(e,t){const n={};for(const i of t)i in e&&(n[i]=e[i]);return n}function Lv(e){return{path:e.path,redirect:e.redirect,name:e.name,meta:e.meta||{},aliasOf:void 0,beforeEnter:e.beforeEnter,props:Nv(e),children:e.children||[],instances:{},leaveGuards:new Set,updateGuards:new Set,enterCallbacks:{},components:"components"in e?e.components||null:e.component&&{default:e.component}}}function Nv(e){const t={},n=e.props||!1;if("component"in e)t.default=n;else for(const i in e.components)t[i]=typeof n=="object"?n[i]:n;return t}function uc(e){for(;e;){if(e.record.aliasOf)return!0;e=e.parent}return!1}function Dv(e){return e.reduce((t,n)=>at(t,n.meta),{})}function hc(e,t){const n={};for(const i in e)n[i]=i in t?t[i]:e[i];return n}function Vh(e,t){return t.children.some(n=>n===e||Vh(e,n))}function xv(e){const t={};if(e===""||e==="?")return t;const i=(e[0]==="?"?e.slice(1):e).split("&");for(let r=0;r<i.length;++r){const s=i[r].replace(Ah," "),a=s.indexOf("="),o=ai(a<0?s:s.slice(0,a)),l=a<0?null:ai(s.slice(a+1));if(o in t){let c=t[o];an(c)||(c=t[o]=[c]),c.push(l)}else t[o]=l}return t}function pc(e){let t="";for(let n in e){const i=e[n];if(n=tv(n),i==null){i!==void 0&&(t+=(t.length?"&":"")+n);continue}(an(i)?i.map(s=>s&&so(s)):[i&&so(i)]).forEach(s=>{s!==void 0&&(t+=(t.length?"&":"")+n,s!=null&&(t+="="+s))})}return t}function Mv(e){const t={};for(const n in e){const i=e[n];i!==void 0&&(t[n]=an(i)?i.map(r=>r==null?null:""+r):i==null?i:""+i)}return t}const Fv=Symbol(""),fc=Symbol(""),Dr=Symbol(""),Zo=Symbol(""),ro=Symbol("");function Hs(){let e=[];function t(i){return e.push(i),()=>{const r=e.indexOf(i);r>-1&&e.splice(r,1)}}function n(){e=[]}return{add:t,list:()=>e.slice(),reset:n}}function Mn(e,t,n,i,r,s=a=>a()){const a=i&&(i.enterCallbacks[r]=i.enterCallbacks[r]||[]);return()=>new Promise((o,l)=>{const c=p=>{p===!1?l(Ps(4,{from:n,to:t})):p instanceof Error?l(p):wv(p)?l(Ps(2,{from:t,to:p})):(a&&i.enterCallbacks[r]===a&&typeof p=="function"&&a.push(p),o())},d=s(()=>e.call(i&&i.instances[r],t,n,c));let u=Promise.resolve(d);e.length<3&&(u=u.then(c)),u.catch(p=>l(p))})}function ba(e,t,n,i,r=s=>s()){const s=[];for(const a of e)for(const o in a.components){let l=a.components[o];if(!(t!=="beforeRouteEnter"&&!a.instances[o]))if(Vv(l)){const d=(l.__vccOpts||l)[t];d&&s.push(Mn(d,n,i,a,o,r))}else{let c=l();s.push(()=>c.then(d=>{if(!d)return Promise.reject(new Error(`Couldn't resolve component "${o}" at "${a.path}"`));const u=K1(d)?d.default:d;a.components[o]=u;const h=(u.__vccOpts||u)[t];return h&&Mn(h,n,i,a,o,r)()}))}}return s}function Vv(e){return typeof e=="object"||"displayName"in e||"props"in e||"__vccOpts"in e}function mc(e){const t=Ft(Dr),n=Ft(Zo),i=ee(()=>{const l=k(e.to);return t.resolve(l)}),r=ee(()=>{const{matched:l}=i.value,{length:c}=l,d=l[c-1],u=n.matched;if(!d||!u.length)return-1;const p=u.findIndex(Ts.bind(null,d));if(p>-1)return p;const h=gc(l[c-2]);return c>1&&gc(d)===h&&u[u.length-1].path!==h?u.findIndex(Ts.bind(null,l[c-2])):p}),s=ee(()=>r.value>-1&&Hv(n.params,i.value.params)),a=ee(()=>r.value>-1&&r.value===n.matched.length-1&&Nh(n.params,i.value.params));function o(l={}){return Uv(l)?t[k(e.replace)?"replace":"push"](k(e.to)).catch(qs):Promise.resolve()}return{route:i,href:ee(()=>i.value.href),isActive:s,isExactActive:a,navigate:o}}const Bv=Ge({name:"RouterLink",compatConfig:{MODE:3},props:{to:{type:[String,Object],required:!0},replace:Boolean,activeClass:String,exactActiveClass:String,custom:Boolean,ariaCurrentValue:{type:String,default:"page"}},useLink:mc,setup(e,{slots:t}){const n=Wt(mc(e)),{options:i}=Ft(Dr),r=ee(()=>({[yc(e.activeClass,i.linkActiveClass,"router-link-active")]:n.isActive,[yc(e.exactActiveClass,i.linkExactActiveClass,"router-link-exact-active")]:n.isExactActive}));return()=>{const s=t.default&&t.default(n);return e.custom?s:gn("a",{"aria-current":n.isExactActive?e.ariaCurrentValue:null,href:n.href,onClick:n.navigate,class:r.value},s)}}}),$v=Bv;function Uv(e){if(!(e.metaKey||e.altKey||e.ctrlKey||e.shiftKey)&&!e.defaultPrevented&&!(e.button!==void 0&&e.button!==0)){if(e.currentTarget&&e.currentTarget.getAttribute){const t=e.currentTarget.getAttribute("target");if(/\b_blank\b/i.test(t))return}return e.preventDefault&&e.preventDefault(),!0}}function Hv(e,t){for(const n in t){const i=t[n],r=e[n];if(typeof i=="string"){if(i!==r)return!1}else if(!an(r)||r.length!==i.length||i.some((s,a)=>s!==r[a]))return!1}return!0}function gc(e){return e?e.aliasOf?e.aliasOf.path:e.path:""}const yc=(e,t,n)=>e??t??n,zv=Ge({name:"RouterView",inheritAttrs:!1,props:{name:{type:String,default:"default"},route:Object},compatConfig:{MODE:3},setup(e,{attrs:t,slots:n}){const i=Ft(ro),r=ee(()=>e.route||i.value),s=Ft(fc,0),a=ee(()=>{let c=k(s);const{matched:d}=r.value;let u;for(;(u=d[c])&&!u.components;)c++;return c}),o=ee(()=>r.value.matched[a.value]);Hn(fc,ee(()=>a.value+1)),Hn(Fv,o),Hn(ro,r);const l=Re();return We(()=>[l.value,o.value,e.name],([c,d,u],[p,h,m])=>{d&&(d.instances[u]=c,h&&h!==d&&c&&c===p&&(d.leaveGuards.size||(d.leaveGuards=h.leaveGuards),d.updateGuards.size||(d.updateGuards=h.updateGuards))),c&&d&&(!h||!Ts(d,h)||!p)&&(d.enterCallbacks[u]||[]).forEach(v=>v(c))},{flush:"post"}),()=>{const c=r.value,d=e.name,u=o.value,p=u&&u.components[d];if(!p)return bc(n.default,{Component:p,route:c});const h=u.props[d],m=h?h===!0?c.params:typeof h=="function"?h(c):h:null,_=gn(p,at({},m,t,{onVnodeUnmounted:b=>{b.component.isUnmounted&&(u.instances[d]=null)},ref:l}));return bc(n.default,{Component:_,route:c})||_}}});function bc(e,t){if(!e)return null;const n=e(t);return n.length===1?n[0]:n}const Bh=zv;function Kv(e){const t=Rv(e.routes,e),n=e.parseQuery||xv,i=e.stringifyQuery||pc,r=e.history,s=Hs(),a=Hs(),o=Hs(),l=Kn(nn);let c=nn;_s&&e.scrollBehavior&&"scrollRestoration"in history&&(history.scrollRestoration="manual");const d=ga.bind(null,K=>""+K),u=ga.bind(null,sv),p=ga.bind(null,ai);function h(K,Z){let me,q;return Mh(K)?(me=t.getRecordMatcher(K),q=Z):q=K,t.addRoute(q,me)}function m(K){const Z=t.getRecordMatcher(K);Z&&t.removeRoute(Z)}function v(){return t.getRoutes().map(K=>K.record)}function _(K){return!!t.getRecordMatcher(K)}function b(K,Z){if(Z=at({},Z||l.value),typeof K=="string"){const X=ya(n,K,Z.path),B=t.resolve({path:X.path},Z),Se=r.createHref(X.fullPath);return at(X,B,{params:p(B.params),hash:ai(X.hash),redirectedFrom:void 0,href:Se})}let me;if(K.path!=null)me=at({},K,{path:ya(n,K.path,Z.path).path});else{const X=at({},K.params);for(const B in X)X[B]==null&&delete X[B];me=at({},K,{params:u(X)}),Z.params=u(Z.params)}const q=t.resolve(me,Z),ae=K.hash||"";q.params=d(p(q.params));const ge=av(i,at({},K,{hash:ev(ae),path:q.path})),we=r.createHref(ge);return at({fullPath:ge,hash:ae,query:i===pc?Mv(K.query):K.query||{}},q,{redirectedFrom:void 0,href:we})}function w(K){return typeof K=="string"?ya(n,K,l.value.path):at({},K)}function C(K,Z){if(c!==K)return Ps(8,{from:Z,to:K})}function O(K){return y(K)}function T(K){return O(at(w(K),{replace:!0}))}function E(K){const Z=K.matched[K.matched.length-1];if(Z&&Z.redirect){const{redirect:me}=Z;let q=typeof me=="function"?me(K):me;return typeof q=="string"&&(q=q.includes("?")||q.includes("#")?q=w(q):{path:q},q.params={}),at({query:K.query,hash:K.hash,params:q.path!=null?{}:K.params},q)}}function y(K,Z){const me=c=b(K),q=l.value,ae=K.state,ge=K.force,we=K.replace===!0,X=E(me);if(X)return y(at(w(X),{state:typeof X=="object"?at({},ae,X.state):ae,force:ge,replace:we}),Z||me);const B=me;B.redirectedFrom=Z;let Se;return!ge&&ov(i,q,me)&&(Se=Ps(16,{to:B,from:q}),te(q,q,!0,!1)),(Se?Promise.resolve(Se):I(B,q)).catch(Ce=>wn(Ce)?wn(Ce,2)?Ce:V(Ce):H(Ce,B,q)).then(Ce=>{if(Ce){if(wn(Ce,2))return y(at({replace:we},w(Ce.to),{state:typeof Ce.to=="object"?at({},ae,Ce.to.state):ae,force:ge}),Z||B)}else Ce=D(B,q,!0,we,ae);return L(B,q,Ce),Ce})}function P(K,Z){const me=C(K,Z);return me?Promise.reject(me):Promise.resolve()}function A(K){const Z=be.values().next().value;return Z&&typeof Z.runWithContext=="function"?Z.runWithContext(K):K()}function I(K,Z){let me;const[q,ae,ge]=Gv(K,Z);me=ba(q.reverse(),"beforeRouteLeave",K,Z);for(const X of q)X.leaveGuards.forEach(B=>{me.push(Mn(B,K,Z))});const we=P.bind(null,K,Z);return me.push(we),oe(me).then(()=>{me=[];for(const X of s.list())me.push(Mn(X,K,Z));return me.push(we),oe(me)}).then(()=>{me=ba(ae,"beforeRouteUpdate",K,Z);for(const X of ae)X.updateGuards.forEach(B=>{me.push(Mn(B,K,Z))});return me.push(we),oe(me)}).then(()=>{me=[];for(const X of ge)if(X.beforeEnter)if(an(X.beforeEnter))for(const B of X.beforeEnter)me.push(Mn(B,K,Z));else me.push(Mn(X.beforeEnter,K,Z));return me.push(we),oe(me)}).then(()=>(K.matched.forEach(X=>X.enterCallbacks={}),me=ba(ge,"beforeRouteEnter",K,Z,A),me.push(we),oe(me))).then(()=>{me=[];for(const X of a.list())me.push(Mn(X,K,Z));return me.push(we),oe(me)}).catch(X=>wn(X,8)?X:Promise.reject(X))}function L(K,Z,me){o.list().forEach(q=>A(()=>q(K,Z,me)))}function D(K,Z,me,q,ae){const ge=C(K,Z);if(ge)return ge;const we=Z===nn,X=_s?history.state:{};me&&(q||we?r.replace(K.fullPath,at({scroll:we&&X&&X.scroll},ae)):r.push(K.fullPath,ae)),l.value=K,te(K,Z,me,we),V()}let z;function G(){z||(z=r.listen((K,Z,me)=>{if(!Y.listening)return;const q=b(K),ae=E(q);
8if(ae){y(at(ae,{replace:!0}),q).catch(qs);return}c=q;const ge=l.value;_s&&mv(rc(ge.fullPath,me.delta),Nr()),I(q,ge).catch(we=>wn(we,12)?we:wn(we,2)?(y(we.to,q).then(X=>{wn(X,20)&&!me.delta&&me.type===oi.pop&&r.go(-1,!1)}).catch(qs),Promise.reject()):(me.delta&&r.go(-me.delta,!1),H(we,q,ge))).then(we=>{we=we||D(q,ge,!1),we&&(me.delta&&!wn(we,8)?r.go(-me.delta,!1):me.type===oi.pop&&wn(we,20)&&r.go(-1,!1)),L(q,ge,we)}).catch(qs)}))}let ne=Hs(),W=Hs(),ue;function H(K,Z,me){V(K);const q=W.list();return q.length?q.forEach(ae=>ae(K,Z,me)):console.error(K),Promise.reject(K)}function x(){return ue&&l.value!==nn?Promise.resolve():new Promise((K,Z)=>{ne.add([K,Z])})}function V(K){return ue||(ue=!K,G(),ne.list().forEach(([Z,me])=>K?me(K):Z()),ne.reset()),K}function te(K,Z,me,q){const{scrollBehavior:ae}=e;if(!_s||!ae)return Promise.resolve();const ge=!me&&gv(rc(K.fullPath,0))||(q||!me)&&history.state&&history.state.scroll||null;return kt().then(()=>ae(K,Z,ge)).then(we=>we&&fv(we)).catch(we=>H(we,K,Z))}const fe=K=>r.go(K);let re;const be=new Set,Y={currentRoute:l,listening:!0,addRoute:h,removeRoute:m,hasRoute:_,getRoutes:v,resolve:b,options:e,push:O,replace:T,go:fe,back:()=>fe(-1),forward:()=>fe(1),beforeEach:s.add,beforeResolve:a.add,afterEach:o.add,onError:W.add,isReady:x,install(K){const Z=this;K.component("RouterLink",$v),K.component("RouterView",Bh),K.config.globalProperties.$router=Z,Object.defineProperty(K.config.globalProperties,"$route",{enumerable:!0,get:()=>k(l)}),_s&&!re&&l.value===nn&&(re=!0,O(r.location).catch(ae=>{}));const me={};for(const ae in nn)Object.defineProperty(me,ae,{get:()=>l.value[ae],enumerable:!0});K.provide(Dr,Z),K.provide(Zo,Ir(me)),K.provide(ro,l);const q=K.unmount;be.add(K),K.unmount=function(){be.delete(K),be.size<1&&(c=nn,z&&z(),z=null,l.value=nn,re=!1,ue=!1),q()}}};function oe(K){return K.reduce((Z,me)=>Z.then(()=>A(me)),Promise.resolve())}return Y}function Gv(e,t){const n=[],i=[],r=[],s=Math.max(t.matched.length,e.matched.length);for(let a=0;a<s;a++){const o=t.matched[a];o&&(e.matched.find(c=>Ts(c,o))?i.push(o):n.push(o));const l=e.matched[a];l&&(t.matched.find(c=>Ts(c,l))||r.push(l))}return[n,i,r]}function jv(){return Ft(Dr)}function Yv(){return Ft(Zo)}const Wv=(e,t)=>t.path.replace(/(:\w+)\([^)]+\)/g,"$1").replace(/(:\w+)[?+*]/g,"$1").replace(/:\w+/g,n=>{var i;return((i=e.params[n.slice(1)])==null?void 0:i.toString())||""}),ao=(e,t)=>{const n=e.route.matched.find(r=>{var s;return((s=r.components)==null?void 0:s.default)===e.Component.type}),i=t??(n==null?void 0:n.meta.key)??(n&&Wv(e.route,n));return typeof i=="function"?i(e.route):i},Qv=(e,t)=>({default:()=>e?gn(Ug,e===!0?{}:e,t):t});function qo(e){return Array.isArray(e)?e:[e]}const Zv="modulepreload",qv=function(e,t){return e[0]==="."?new URL(e,t).href:e},vc={},Jv=function(t,n,i){let r=Promise.resolve();if(n&&n.length>0){const s=document.getElementsByTagName("link"),a=document.querySelector("meta[property=csp-nonce]"),o=(a==null?void 0:a.nonce)||(a==null?void 0:a.getAttribute("nonce"));r=Promise.all(n.map(l=>{if(l=qv(l,i),l in vc)return;vc[l]=!0;const c=l.endsWith(".css"),d=c?'[rel="stylesheet"]':"";if(!!i)for(let h=s.length-1;h>=0;h--){const m=s[h];if(m.href===l&&(!c||m.rel==="stylesheet"))return}else if(document.querySelector(`link[href="${l}"]${d}`))return;const p=document.createElement("link");if(p.rel=c?"stylesheet":Zv,c||(p.as="script",p.crossOrigin=""),p.href=l,o&&p.setAttribute("nonce",o),document.head.appendChild(p),c)return new Promise((h,m)=>{p.addEventListener("load",h),p.addEventListener("error",()=>m(new Error(`Unable to preload CSS for ${l}`)))})}))}return r.then(()=>t()).catch(s=>{const a=new Event("vite:preloadError",{cancelable:!0});if(a.payload=s,window.dispatchEvent(a),!a.defaultPrevented)throw s})},Qe=(...e)=>Jv(...e).catch(t=>{const n=new Event("nuxt.preloadError");throw n.payload=t,window.dispatchEvent(n),t}),_c=[{name:"locale-aboutus___en",path:"/:locale?/aboutus",component:()=>Qe(()=>import("./Bda8R690.js"),__vite__mapDeps([0,1,2,3]),import.meta.url).then(e=>e.default||e)},{name:"locale-accessories-id-name___en",path:"/:locale?/accessories/:id?/:name?",component:()=>Qe(()=>import("./5KEikvZV.js"),__vite__mapDeps([4,1,2,5,6]),import.meta.url).then(e=>e.default||e)},{name:"locale-autoship___en",path:"/:locale?/autoship",component:()=>Qe(()=>import("./Duzeq3F8.js"),__vite__mapDeps([7,1,2,8]),import.meta.url).then(e=>e.default||e)},{name:"locale-black-friday-summer-sale___en",path:"/:locale?/black-friday-summer-sale",component:()=>Qe(()=>import("./CwkE8VYG.js"),__vite__mapDeps([9,1,2,10,11]),import.meta.url).then(e=>e.default||e)},{name:"locale-canadian-vision-credit___en",path:"/:locale?/canadian-vision-credit",component:()=>Qe(()=>import("./B3hWyaqc.js"),__vite__mapDeps([12,1,2,13]),import.meta.url).then(e=>e.default||e)},{name:"locale-contact_lenses-id-name___en",path:"/:locale?/contact_lenses/:id?/:name?",component:()=>Qe(()=>import("./1tW4jX9G.js"),__vite__mapDeps([14,1,2,15,16,17,10,18,19]),import.meta.url).then(e=>e.default||e)},{name:"locale-contactus___en",path:"/:locale?/contactus",component:()=>Qe(()=>import("./iG2CScgL.js"),__vite__mapDeps([20,1,2]),import.meta.url).then(e=>e.default||e)},{name:"locale-deals-id-name___en",path:"/:locale?/deals/:id?/:name()",component:()=>Qe(()=>import("./BEc24eAb.js"),__vite__mapDeps([21,1,2,5,22]),import.meta.url).then(e=>e.default||e)},{name:"locale-eye-care___en",path:"/:locale?/eye-care",component:()=>Qe(()=>import("./CXh-LY0I.js"),__vite__mapDeps([23,1,2]),import.meta.url).then(e=>e.default||e)},{name:"locale-faq___en",path:"/:locale?/faq",component:()=>Qe(()=>import("./VUgtgRsR.js"),__vite__mapDeps([24,1,2]),import.meta.url).then(e=>e.default||e)}
8,{name:"locale-glasses-catchall___en",path:"/:locale?/glasses/:catchall(.*)*",component:()=>Qe(()=>import("./BF__syA1.js"),__vite__mapDeps([25,1,2]),import.meta.url).then(e=>e.default||e)},{name:"locale-glasses-id___en",path:"/:locale?/glasses/:id?",component:()=>Qe(()=>import("./DnqEuG2X.js"),__vite__mapDeps([26,27,1,2,5,15,16,17,10,18,28]),import.meta.url).then(e=>e.default||e),children:[{name:"locale-glasses-id-name___en",path:":name?",component:()=>Qe(()=>import("./guaEpqMv.js"),__vite__mapDeps([29,27,1,2,5,15,16,17,10,18,28]),import.meta.url).then(e=>e.default||e)}]},{name:"locale-glasses-progressive-readers-id___en",path:"/:locale?/glasses/progressive-readers/:id?",component:()=>Qe(()=>import("./BYUyUjjW.js"),__vite__mapDeps([30,27,1,2,5,15,16,17,10,18,28]),import.meta.url).then(e=>e.default||e),children:[{name:"locale-glasses-progressive-readers-id-name___en",path:":name?",component:()=>Qe(()=>import("./44MW41sq.js"),__vite__mapDeps([31,27,1,2,5,15,16,17,10,18,28]),import.meta.url).then(e=>e.default||e)}]},{name:"locale-glasses-readers-id___en",path:"/:locale?/glasses/readers/:id?",component:()=>Qe(()=>import("./DUC9Gzc_.js"),__vite__mapDeps([32,27,1,2,5,15,16,17,10,18,28]),import.meta.url).then(e=>e.default||e),children:[{name:"locale-glasses-readers-id-name___en",path:":name?",component:()=>Qe(()=>import("./n8Qk7tLl.js"),__vite__mapDeps([33,27,1,2,5,15,16,17,10,18,28]),import.meta.url).then(e=>e.default||e)}]},{name:"locale-glasses-sun-progressive-readers-id___en",path:"/:locale?/glasses/sun-progressive-readers/:id?",component:()=>Qe(()=>import("./AdD-efXu.js"),__vite__mapDeps([34,27,1,2,5,15,16,17,10,18,28]),import.meta.url).then(e=>e.default||e),children:[{name:"locale-glasses-sun-progressive-readers-id-name___en",path:":name?",component:()=>Qe(()=>import("./DO59wRwY.js"),__vite__mapDeps([35,27,1,2,5,15,16,17,10,18,28]),import.meta.url).then(e=>e.default||e)}]},{name:"locale-glasses-sun-readers-id___en",path:"/:locale?/glasses/sun-readers/:id?",component:()=>Qe(()=>import("./DbxUZWKD.js"),__vite__mapDeps([36,27,1,2,5,15,16,17,10,18,28]),import.meta.url).then(e=>e.default||e),children:[{name:"locale-glasses-sun-readers-id-name___en",path:":name?",component:()=>Qe(()=>import("./CQzxtUtJ.js"),__vite__mapDeps([37,27,1,2,5,15,16,17,10,18,28]),import.meta.url).then(e=>e.default||e)}]},{name:"locale-insurance___en",path:"/:locale?/insurance",component:()=>Qe(()=>import("./Cs_C8Twa.js"),__vite__mapDeps([38,39,1,2,16,17,40,41]),import.meta.url).then(e=>e.default||e)},{name:"locale-kits-pixa___en",path:"/:locale?/kits-pixa",component:()=>Qe(()=>import("./CDK89QUH.js"),__vite__mapDeps([42,1,2,43]),import.meta.url).then(e=>e.default||e)},{name:"locale-kits-plus___en",path:"/:locale?/kits-plus",component:()=>Qe(()=>import("./BiTKH9Fa.js"),__vite__mapDeps([44,1,2,45]),import.meta.url).then(e=>e.default||e)},{name:"locale-optician-ai___en",path:"/:locale?/optician-ai",component:()=>Qe(()=>import("./ByJsQKfS.js"),__vite__mapDeps([46,1,2,47]),import.meta.url).then(e=>e.default||e)},{name:"locale-pd-tool___en",path:"/:locale?/pd-tool",component:()=>Qe(()=>import("./BkZctTWL.js"),__vite__mapDeps([48,1,2]),import.meta.url).then(e=>e.default||e)},{name:"locale-shipping___en",path:"/:locale?/shipping",component:()=>Qe(()=>import("./D9dzkrbY.js"),__vite__mapDeps([49,1,2,50]),import.meta.url).then(e=>e.default||e)},{name:"locale-stores___en",path:"/:locale?/stores",component:()=>Qe(()=>import("./Kb_ZbF-J.js"),__vite__mapDeps([51,1,2,52]),import.meta.url).then(e=>e.default||e)},{name:"optician-vto___en",path:"/optician-vto",component:()=>Qe(()=>import("./DuJGHjBz.js"),__vite__mapDeps([53,1,2]),import.meta.url).then(e=>e.default||e)},{name:"optician___en",path:"/optician",component:()=>Qe(()=>import("./CMlrFKEy.js"),__vite__mapDeps([54,1,2,55,56]),import.meta.url).then(e=>e.default||e)},{name:"plugins-barcode-scanner___en",path:"/plugins/barcode-scanner",component:()=>Qe(()=>import("./DSwFCs-S.js"),__vite__mapDeps([57,1,2,55,58]),import.meta.url).then(e=>e.default||e)},{name:"plugins-us-insurance-widget___en",path:"/plugins/us-insurance-widget",component:()=>Qe(()=>import("./CgUBmoW0.js"),__vite__mapDeps([59,39,1,2,16,17,40]),import.meta.url).then(e=>e.default||e)},{name:"plugins-vto-widget___en",path:"/plugins/vto-widget",component:()=>Qe(()=>import("./Db3Jp0s1.js"),__vite__mapDeps([60,1,2,61]),import.meta.url).then(e=>e.default||e)}],Xv=(e,t,n)=>(t=t===!0?{}:t,{default:()=>{var i;return t?gn(e,t,n):(i=n.default)==null?void 0:i.call(n)}});function wc(e){const t=(e==null?void 0:e.meta.key)??e.path.replace(/(:\w+)\([^)]+\)/g,"$1").replace(/(:\w+)[?+*]/g,"$1").replace(/:\w+/g,n=>{var i;return((i=e.params[n.slice(1)])==null?void 0:i.toString())||""});return typeof t=="function"?t(e):t}function e_(e,t){return e===t||t===nn?!1:wc(e)!==wc(t)?!0:!e.matched.every((i,r)=>{var s,a;return i.components&&i.components.default===((a=(s=t.matched[r])==null?void 0:s.components)==null?void 0:a.default)})}const t_={scrollBehavior(e,t,n){var c;const i=ct(),r=((c=dn().options)==null?void 0:c.scrollBehaviorType)??"auto";let s=n||void 0;const a=typeof e.meta.scrollToTop=="function"?e.meta.scrollToTop(e,t):e.meta.scrollToTop;if(!s&&t&&e&&a!==!1&&e_(e,t)&&(s={left:0,top:0}),e.path===t.path)return t.hash&&!e.hash?{left:0,top:0}:e.hash?{el:e.hash,top:Ec(e.hash),behavior:r}:!1;const o=d=>!!(d.meta.pageTransition??no),l=o(t)&&o(e)?"page:transition:finish":"page:finish";return new Promise(d=>{i.hooks.hookOnce(l,async()=>{await new Promise(u=>setTimeout(u,0)),e.hash&&(s={el:e.hash,top:Ec(e.hash),behavior:r}),d(s)})})}};function Ec(e){try{const t=document.querySelector(e);
8if(t)return parseFloat(getComputedStyle(t).scrollMarginTop)}catch{}return 0}const n_={hashMode:!1,scrollBehaviorType:"auto"},Gt={...n_,...t_},s_=async e=>{var l;let t,n;if(!((l=e.meta)!=null&&l.validate))return;const i=ct(),r=dn();if(([t,n]=fn(()=>Promise.resolve(e.meta.validate(e))),t=await t,n(),t)===!0)return;const a=Ti({statusCode:404,statusMessage:`Page Not Found: ${e.fullPath}`,data:{path:e.fullPath}}),o=r.beforeResolve(c=>{if(o(),c===e){const d=r.afterEach(async()=>{d(),await i.runWithContext(()=>Es(a)),window.history.pushState({},"",e.fullPath)});return!1}})},i_=async e=>{let t,n;const i=([t,n]=fn(()=>Wo(e.path)),t=await t,n(),t);if(i.redirect)return vn(i.redirect,{acceptRelative:!0})?(window.location.href=i.redirect,!1):i.redirect},r_=[s_,i_],Xs={};function a_(e,t,n){const{pathname:i,search:r,hash:s}=t,a=e.indexOf("#");if(a>-1){const c=s.includes(e.slice(a))?e.slice(a).length:1;let d=s.slice(c);return d[0]!=="/"&&(d="/"+d),Bl(d,"")}const o=Bl(i,e),l=!n||Ka(o,n,{trailingSlash:!0})?o:n;return l+(l.includes("?")?"":r)+s}const o_=_t({name:"nuxt:router",enforce:"pre",async setup(e){var _,b;let t,n,i=Be().app.baseURL;Gt.hashMode&&!i.includes("#")&&(i+="#");const r=((_=Gt.history)==null?void 0:_.call(Gt,i))??(Gt.hashMode?_v(i):xh(i)),s=((b=Gt.routes)==null?void 0:b.call(Gt,_c))??_c;let a;const o=Kv({...Gt,scrollBehavior:(w,C,O)=>{if(C===nn){a=O;return}if(Gt.scrollBehavior){if(o.options.scrollBehavior=Gt.scrollBehavior,"scrollRestoration"in window.history){const T=o.beforeEach(()=>{T(),window.history.scrollRestoration="manual"})}return Gt.scrollBehavior(w,nn,a||O)}},history:r,routes:s});"scrollRestoration"in window.history&&(window.history.scrollRestoration="auto"),e.vueApp.use(o);const l=Kn(o.currentRoute.value);o.afterEach((w,C)=>{l.value=C}),Object.defineProperty(e.vueApp.config.globalProperties,"previousRoute",{get:()=>l.value});const c=a_(i,window.location,e.payload.path),d=Kn(o.currentRoute.value),u=()=>{d.value=o.currentRoute.value};e.hook("page:finish",u),o.afterEach((w,C)=>{var O,T,E,y;((T=(O=w.matched[0])==null?void 0:O.components)==null?void 0:T.default)===((y=(E=C.matched[0])==null?void 0:E.components)==null?void 0:y.default)&&u()});const p={};for(const w in d.value)Object.defineProperty(p,w,{get:()=>d.value[w]});e._route=Ir(p),e._middleware=e._middleware||{global:[],named:{}};try{[t,n]=fn(()=>o.isReady()),await t,n()}catch(w){[t,n]=fn(()=>e.runWithContext(()=>Es(w))),await t,n()}const h=c!==o.currentRoute.value.fullPath?o.resolve(c):o.currentRoute.value;u();const m=e.payload.state._layout;o.beforeEach(async(w,C)=>{var O;await e.callHook("page:loading:start"),w.meta=Wt(w.meta),e.isHydrating&&m&&!Uu(w.meta.layout)&&(w.meta.layout=m),e._processingMiddleware=!0;{const T=new Set([...r_,...e._middleware.global]);for(const E of w.matched){const y=E.meta.middleware;if(y)for(const P of qo(y))T.add(P)}{const E=await e.runWithContext(()=>Wo(w.path));if(E.appMiddleware)for(const y in E.appMiddleware)E.appMiddleware[y]?T.add(y):T.delete(y)}for(const E of T){const y=typeof E=="string"?e._middleware.named[E]||await((O=Xs[E])==null?void 0:O.call(Xs).then(A=>A.default||A)):E;if(!y)throw new Error(`Unknown route middleware: '${E}'.`);const P=await e.runWithContext(()=>y(w,C));if(!e.payload.serverRendered&&e.isHydrating&&(P===!1||P instanceof Error)){const A=P||qa({statusCode:404,statusMessage:`Page Not Found: ${c}`});return await e.runWithContext(()=>Es(A)),!1}if(P!==!0&&(P||P===!1))return P}}}),o.onError(async()=>{delete e._processingMiddleware,await e.callHook("page:loading:end")});const v=Rr();return o.afterEach(async(w,C,O)=>{delete e._processingMiddleware,!e.isHydrating&&v.value&&await e.runWithContext(xb),O&&await e.callHook("page:loading:end"),w.matched.length===0&&await e.runWithContext(()=>Es(qa({statusCode:404,fatal:!1,statusMessage:`Page not found: ${w.fullPath}`,data:{path:w.fullPath}})))}),e.hooks.hookOnce("app:created",async()=>{try{"name"in h&&(h.name=void 0),await o.replace({...h,force:!0}),o.options.scrollBehavior=Gt.scrollBehavior}catch(w){await e.runWithContext(()=>Es(w))}}),{provide:{router:o}}}}),Sc=globalThis.requestIdleCallback||(e=>{const t=Date.now(),n={didTimeout:!1,timeRemaining:()=>Math.max(0,50-(Date.now()-t))};return setTimeout(()=>{e(n)},1)}),$h=e=>{const t=ct();t.isHydrating?t.hooks.hookOnce("app:suspense:resolve",()=>{Sc(e)}):Sc(e)}
vendor: 4,241 bytes, lines 8-12
8,l_=_t({name:"nuxt:payload",setup(e){dn().beforeResolve(async(t,n)=>{if(t.path===n.path)return;const i=await tc(t.path);i&&Object.assign(e.static.data,i.data)}),$h(()=>{var t;e.hooks.hook("link:prefetch",async n=>{Or(n).protocol||await tc(n)}),((t=navigator.connection)==null?void 0:t.effectiveType)!=="slow-2g"&&setTimeout(Lr,1e3)})}}),c_=_t(e=>{let t;async function n(){const i=await Lr();t&&clearTimeout(t),t=setTimeout(n,1e3*60*60);try{const r=await $fetch(Ko("builds/latest.json")+`?${Date.now()}`);r.id!==i.id&&e.hooks.callHook("app:manifest:update",r)}catch{}}$h(()=>{t=setTimeout(n,1e3*60*60)})}),d_=!1;/*!
9 * pinia v2.1.7
10 * (c) 2023 Eduardo San Martin Morote
11 * @license MIT
12 */let Uh;const Pi=e=>Uh=e,Hh=Symbol();function oo(e){return e&&typeof e=="object"&&Object.prototype.toString.call(e)==="[object Object]"&&typeof e.toJSON!="function"}var ei;(function(e){e.direct="direct",e.patchObject="patch object",e.patchFunction="patch function"})(ei||(ei={}));function u_(){const e=Si(!0),t=e.run(()=>Re({}));let n=[],i=[];const r=Hu({install(s){Pi(r),r._a=s,s.provide(Hh,r),s.config.globalProperties.$pinia=r,i.forEach(a=>n.push(a)),i=[]},use(s){return!this._a&&!d_?i.push(s):n.push(s),this},_p:n,_a:null,_e:e,_s:new Map,state:t});return r}const zh=()=>{};function Cc(e,t,n,i=zh){e.push(t);const r=()=>{const s=e.indexOf(t);s>-1&&(e.splice(s,1),i())};return!n&&Ii()&&Is(r),r}function ys(e,...t){e.slice().forEach(n=>{n(...t)})}const h_=e=>e();function lo(e,t){e instanceof Map&&t instanceof Map&&t.forEach((n,i)=>e.set(i,n)),e instanceof Set&&t instanceof Set&&t.forEach(e.add,e);for(const n in t){if(!t.hasOwnProperty(n))continue;const i=t[n],r=e[n];oo(r)&&oo(i)&&e.hasOwnProperty(n)&&!Jt(i)&&!Uo(i)?e[n]=lo(r,i):e[n]=i}return e}const p_=Symbol();function f_(e){return!oo(e)||!e.hasOwnProperty(p_)}const{assign:Dn}=Object;function m_(e){return!!(Jt(e)&&e.effect)}function g_(e,t,n,i){const{state:r,actions:s,getters:a}=t,o=n.state.value[e];let l;function c(){o||(n.state.value[e]=r?r():{});const d=zg(n.state.value[e]);return Dn(d,s,Object.keys(a||{}).reduce((u,p)=>(u[p]=Hu(ee(()=>{Pi(n);const h=n._s.get(e);return a[p].call(h,h)})),u),{}))}return l=Kh(e,c,t,n,i,!0),l}function Kh(e,t,n={},i,r,s){let a;const o=Dn({actions:{}},n),l={deep:!0};let c,d,u=[],p=[],h;const m=i.state.value[e];!s&&!m&&(i.state.value[e]={}),Re({});let v;function _(P){let A;c=d=!1,typeof P=="function"?(P(i.state.value[e]),A={type:ei.patchFunction,storeId:e,events:h}):(lo(i.state.value[e],P),A={type:ei.patchObject,payload:P,storeId:e,events:h});const I=v=Symbol();kt().then(()=>{v===I&&(c=!0)}),d=!0,ys(u,A,i.state.value[e])}const b=s?function(){const{state:A}=n,I=A?A():{};this.$patch(L=>{Dn(L,I)})}:zh;function w(){a.stop(),u=[],p=[],i._s.delete(e)}function C(P,A){return function(){Pi(i);const I=Array.from(arguments),L=[],D=[];function z(W){L.push(W)}function G(W){D.push(W)}ys(p,{args:I,name:P,store:T,after:z,onError:G});let ne;try{ne=A.apply(this&&this.$id===e?this:T,I)}catch(W){throw ys(D,W),W}return ne instanceof Promise?ne.then(W=>(ys(L,W),W)).catch(W=>(ys(D,W),Promise.reject(W))):(ys(L,ne),ne)}}const O={_p:i,$id:e,$onAction:Cc.bind(null,p),$patch:_,$reset:b,$subscribe(P,A={}){const I=Cc(u,P,A.detached,()=>L()),L=a.run(()=>We(()=>i.state.value[e],D=>{(A.flush==="sync"?d:c)&&P({storeId:e,type:ei.direct,events:h},D)},Dn({},l,A)));return I},$dispose:w},T=Wt(O);i._s.set(e,T);const y=(i._a&&i._a.runWithContext||h_)(()=>i._e.run(()=>(a=Si()).run(t)));for(const P in y){const A=y[P];if(Jt(A)&&!m_(A)||Uo(A))s||(m&&f_(A)&&(Jt(A)?A.value=m[P]:lo(A,m[P])),i.state.value[e][P]=A);else if(typeof A=="function"){const I=C(P,A);y[P]=I,o.actions[P]=A}}return Dn(T,y),Dn(Hg(T),y),Object.defineProperty(T,"$state",{get:()=>i.state.value[e],set:P=>{_(A=>{Dn(A,P)})}}),i._p.forEach(P=>{Dn(T,a.run(()=>P({store:T,app:i._a,pinia:i,options:o})))}),m&&s&&n.hydrate&&n.hydrate(T.$state,m),c=!0,d=!0,T}function Rt(e,t,n){let i,r;const s=typeof t=="function";typeof e=="string"?(i=e,r=s?n:t):(r=e,i=e.id);function a(o,l){const c=Bo();return o=o||(c?Ft(Hh,null):null),o&&Pi(o),o=Uh,o._s.has(i)||(s?Kh(i,t,r,o):g_(i,r,o)),o._s.get(i)}return a.$id=i,a}const y_=e=>e==="defer"||e===!1;function b_(...e){var m;const t=typeof e[e.length-1]=="string"?e.pop():void 0;
12typeof e[0]!="string"&&e.unshift(t);let[n,i,r={}]=e;if(typeof n!="string")throw new TypeError("[nuxt] [asyncData] key must be a string.");if(typeof i!="function")throw new TypeError("[nuxt] [asyncData] handler must be a function.");const s=ct(),a=i,o=()=>null,l=()=>s.isHydrating?s.payload.data[n]:s.static.data[n];r.server=r.server??!0,r.default=r.default??o,r.getCachedData=r.getCachedData??l,r.lazy=r.lazy??!1,r.immediate=r.immediate??!0,r.deep=r.deep??L1.deep,r.dedupe=r.dedupe??"cancel";const c=()=>r.getCachedData(n,s)!=null;if(!s._asyncData[n]||!r.immediate){(m=s.payload._errors)[n]??(m[n]=null);const v=r.deep?Re:Kn;s._asyncData[n]={data:v(r.getCachedData(n,s)??r.default()),pending:Re(!c()),error:$o(s.payload._errors,n),status:Re("idle")}}const d={...s._asyncData[n]};d.refresh=d.execute=(v={})=>{if(s._asyncDataPromises[n]){if(y_(v.dedupe??r.dedupe))return s._asyncDataPromises[n];s._asyncDataPromises[n].cancelled=!0}if((v._initial||s.isHydrating&&v._initial!==!1)&&c())return Promise.resolve(r.getCachedData(n,s));d.pending.value=!0,d.status.value="pending";const _=new Promise((b,w)=>{try{b(a(s))}catch(C){w(C)}}).then(async b=>{if(_.cancelled)return s._asyncDataPromises[n];let w=b;r.transform&&(w=await r.transform(b)),r.pick&&(w=__(w,r.pick)),s.payload.data[n]=w,d.data.value=w,d.error.value=null,d.status.value="success"}).catch(b=>{if(_.cancelled)return s._asyncDataPromises[n];d.error.value=Ti(b),d.data.value=k(r.default()),d.status.value="error"}).finally(()=>{_.cancelled||(d.pending.value=!1,delete s._asyncDataPromises[n])});return s._asyncDataPromises[n]=_,s._asyncDataPromises[n]},d.clear=()=>v_(s,n);const u=()=>d.refresh({_initial:!0}),p=r.server!==!1&&s.payload.serverRendered;{const v=ln();if(v&&!v._nuxtOnBeforeMountCbs){v._nuxtOnBeforeMountCbs=[];const w=v._nuxtOnBeforeMountCbs;zu(()=>{w.forEach(C=>{C()}),w.splice(0,w.length)}),cn(()=>w.splice(0,w.length))}p&&s.isHydrating&&(d.error.value||c())?(d.pending.value=!1,d.status.value=d.error.value?"error":"success"):v&&(s.payload.serverRendered&&s.isHydrating||r.lazy)&&r.immediate?v._nuxtOnBeforeMountCbs.push(u):r.immediate&&u();const _=Ii();if(r.watch){const w=We(r.watch,()=>d.refresh());_&&Is(w)}const b=s.hook("app:data:refresh",async w=>{(!w||w.includes(n))&&await d.refresh()});_&&Is(b)}const h=Promise.resolve(s._asyncDataPromises[n]).then(()=>d);return Object.assign(h,d),h}function v_(e,t){t in e.payload.data&&(e.payload.data[t]=void 0),t in e.payload._errors&&(e.payload._errors[t]=null),e._asyncData[t]&&(e._asyncData[t].data.value=void 0,e._asyncData[t].error.value=null,e._asyncData[t].pending.value=!1,e._asyncData[t].status.value="idle"),t in e._asyncDataPromises&&(e._asyncDataPromises[t].cancelled=!0,e._asyncDataPromises[t]=void 0)}function __(e,t){const n={};for(const i of t)n[i]=e[i];return n}const w_="$s";function Gh(...e){const t=typeof e[e.length-1]=="string"?e.pop():void 0;typeof e[0]!="string"&&e.unshift(t);const[n,i]=e;if(!n||typeof n!="string")throw new TypeError("[nuxt] [useState] key must be a string: "+n);if(i!==void 0&&typeof i!="function")throw new Error("[nuxt] [useState] init must be a function: "+i);const r=w_+n,s=ct(),a=$o(s.payload.state,r);if(a.value===void 0&&i){const o=i();if(Jt(o))return s.payload.state[r]=o,o;a.value=o}return a}function E_(e){return{}}function xr(e,t,n){const[i={},r]=typeof t=="string"?[{},t]:[t,n],s=ee(()=>is(e)),a=i.key||Eb([r,typeof s.value=="string"?s.value:"",...S_(i)]);if(!a||typeof a!="string")throw new TypeError("[nuxt] [useFetch] key must be a string: "+a);if(!e)throw new Error("[nuxt] [useFetch] request is missing.");const o=a===r?"$f"+a:a;if(!i.baseURL&&typeof s.value=="string"&&s.value[0]==="/"&&s.value[1]==="/")throw new Error('[nuxt] [useFetch] the request URL must not start with "//".');const{server:l,lazy:c,default:d,transform:u,pick:p,watch:h,immediate:m,getCachedData:v,deep:_,dedupe:b,...w}=i,C=Wt({...N1,...w,cache:typeof i.cache=="boolean"?void 0:i.cache}),O={server:l,lazy:c,default:d,transform:u,pick:p,immediate:m,getCachedData:v,deep:_,dedupe:b,watch:h===!1?[]:[C,s,...h||[]]};let T;return b_(o,()=>{var A;(A=T==null?void 0:T.abort)==null||A.call(T),T=typeof AbortController<"u"?new AbortController:{};const y=is(i.timeout);return y&&setTimeout(()=>T.abort(),y),(i.$fetch||globalThis.$fetch)(s.value,{signal:T.signal,...C})},O)}function S_(e){var n;const t=[((n=is(e.method))==null?void 0:n.toUpperCase())||"GET",is(e.baseURL)];for(const i of[e.params||e.query]){const r=is(i);if(!r)continue;const s={};
12for(const[a,o]of Object.entries(r))s[is(a)]=is(o);t.push(s)}return t}const C_={path:"/",watch:!0,decode:e=>ri(decodeURIComponent(e)),encode:e=>encodeURIComponent(typeof e=="string"?e:JSON.stringify(e))},I_=void 0;function jh(e,t){var l;const n={...C_,...t},i=Ic(n)||{};let r;n.maxAge!==void 0?r=n.maxAge*1e3:n.expires&&(r=n.expires.getTime()-Date.now());const s=r!==void 0&&r<=0,a=hn(s?void 0:i[e]??((l=n.default)==null?void 0:l.call(n))),o=r&&!s?O_(a,r,n.watch&&n.watch!=="shallow"):Re(a);{let c=null;try{!I_&&typeof BroadcastChannel<"u"&&(c=new BroadcastChannel(`nuxt:cookies:${e}`))}catch{}const d=()=>{n.readonly||Sb(o.value,i[e])||(P_(e,o.value,n),i[e]=hn(o.value),c==null||c.postMessage({value:n.encode(o.value)}))},u=h=>{var v;const m=h.refresh?(v=Ic(n))==null?void 0:v[e]:n.decode(h.value);p=!0,i[e]=o.value=m,kt(()=>{p=!1})};let p=!1;Ii()&&Is(()=>{p=!0,d(),c==null||c.close()}),c&&(c.onmessage=({data:h})=>u(h)),n.watch?We(o,()=>{p||d()},{deep:n.watch!=="shallow"}):d()}return o}function Ic(e={}){return ab(document.cookie,e)}function T_(e,t,n={}){return t==null?zl(e,t,{...n,maxAge:-1}):zl(e,t,n)}function P_(e,t,n={}){document.cookie=T_(e,t,n)}const Tc=2147483647;function O_(e,t,n){let i,r,s=0;const a=n?Re(e):{value:e};return Ii()&&Is(()=>{r==null||r(),clearTimeout(i)}),Kg((o,l)=>{n&&(r=We(a,l));function c(){clearTimeout(i);const d=t-s,u=d<Tc?d:Tc;i=setTimeout(()=>{if(s+=u,s<t)return c();a.value=void 0,l()},u)}return{get(){return o(),a.value},set(d){c(),a.value=d,l()}}})}function A_(e={}){const t=e.path||window.location.pathname;let n={};try{n=ri(sessionStorage.getItem("nuxt:reload")||"{}")}catch{}if(e.force||(n==null?void 0:n.path)!==t||(n==null?void 0:n.expires)<Date.now()){try{sessionStorage.setItem("nuxt:reload",JSON.stringify({path:t,expires:Date.now()+(e.ttl??1e4)}))}catch{}if(e.persistState)try{sessionStorage.setItem("nuxt:reload:state",JSON.stringify({state:ct().payload.state}))}catch{}window.location.pathname!==t?window.location.href=t:window.location.reload()}}function It(){return new URL(window.location.href)}const k_=Symbol.for("nuxt:client-only"),Yh=Ge({name:"ClientOnly",inheritAttrs:!1,props:["fallback","placeholder","placeholderTag","fallbackTag"],setup(e,{slots:t,attrs:n}){const i=Re(!1);return vt(()=>{i.value=!0}),Hn(k_,!0),r=>{var l;if(i.value)return(l=t.default)==null?void 0:l.call(t);const s=t.fallback||t.placeholder;if(s)return s();const a=r.fallback||r.placeholder||"",o=r.fallbackTag||r.placeholderTag||"span";return S(o,n,a)}}}),R_=_t(e=>{const t=u_();return e.vueApp.use(t),Pi(t),e.payload&&e.payload.pinia&&(t.state.value=e.payload.pinia),{provide:{pinia:t}}}),L_=_t({name:"nuxt:global-components"}),Bi={},N_=_t({name:"nuxt:prefetch",setup(e){const t=dn();e.hooks.hook("app:mounted",()=>{t.beforeEach(async n=>{var r;const i=(r=n==null?void 0:n.meta)==null?void 0:r.layout;i&&typeof Bi[i]=="function"&&await Bi[i]()})}),e.hooks.hook("link:prefetch",n=>{if(vn(n))return;const i=t.resolve(n);if(!i)return;const r=i.meta.layout;let s=qo(i.meta.middleware);s=s.filter(a=>typeof a=="string");for(const a of s)typeof Xs[a]=="function"&&Xs[a]();r&&typeof Bi[r]=="function"&&Bi[r]()})}});/*!
13  * shared v10.0.5
14  * (c) 2024 kazuya kawaguchi
15  * Released under the MIT License.
16  */const dr=typeof window<"u",Gn=(e,t=!1)=>t?Symbol.for(e):Symbol(e),D_=(e,t,n)=>x_({l:e,k:t,s:n}),x_=e=>JSON.stringify(e).replace(/\u2028/g,"\\u2028").replace(/\u2029/g,"\\u2029").replace(/\u0027/g,"\\u0027"),Pt=e=>typeof e=="number"&&isFinite(e),M_=e=>Xo(e)==="[object Date]",ur=e=>Xo(e)==="[object RegExp]",Mr=e=>Ye(e)&&Object.keys(e).length===0,Ot=Object.assign,F_=Object.create,ut=(e=null)=>F_(e);let Pc;const Jo=()=>Pc||(Pc=typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:typeof global<"u"?global:ut());function Oc(e){return e.replace(/</g,"&lt;").replace(/>/g,"&gt;").replace(/"/g,"&quot;").replace(/'/g,"&apos;")}const V_=Object.prototype.hasOwnProperty;function sn(e,t){return V_.call(e,t)}const Ct=Array.isArray,lt=e=>typeof e=="function",Fe=e=>typeof e=="string",bt=e=>typeof e=="boolean",B_=e=>typeof e=="symbol",je=e=>e!==null&&typeof e=="object",$_=e=>je(e)&&lt(e.then)&&lt(e.catch),Wh=Object.prototype.toString,Xo=e=>Wh.call(e),Ye=e=>Xo(e)==="[object Object]",U_=e=>e==null?"":Ct(e)||Ye(e)&&e.toString===Wh?JSON.stringify(e,null,2):String(e);function el(e,t=""){return e.reduce((n,i,r)=>r===0?n+i:n+t+i,"")}function H_(e,t){typeof console<"u"&&(console.warn("[intlify] "+e),t&&console.warn(t.stack))}const $i=e=>!je(e)||Ct(e);function ls(e,t){if($i(e)||$i(t))throw new Error("Invalid value");const n=[{src:e,des:t}];for(;n.length;){const{src:i,des:r}=n.pop();
16Object.keys(i).forEach(s=>{s!=="__proto__"&&(je(i[s])&&!je(r[s])&&(r[s]=Array.isArray(i[s])?[]:ut()),$i(r[s])||$i(i[s])?r[s]=i[s]:n.push({src:i[s],des:r[s]}))})}}const z_={toast:{system:{"service-unavailable":{t:0,b:{t:2,i:[{t:3}],s:"Subscribe Service is not available at the moment. Please try again later!"}}},glasses:{"prescription-saved":{t:0,b:{t:2,i:[{t:3}],s:"Previous Prescription saved."}},"upload-success":{t:0,b:{t:2,i:[{t:3}],s:"Upload successful."}},"file-deleted":{t:0,b:{t:2,i:[{t:3}],s:"File deleted."}}},contacts:{"upload-success":{t:0,b:{t:2,i:[{t:3}],s:"Upload successful."}},"file-deleted":{t:0,b:{t:2,i:[{t:3}],s:"File deleted."}}}}},Os=["en"],hr={en:[{key:"../locales/en.json",load:()=>Promise.resolve(z_),cache:!0}]},K_=[],Fr=[{code:"en",iso:"en-EN",name:"English",files:[{path:"C:/kits-nuxt-pdp/locales/en.json"}]}],Qh="@nuxtjs/i18n",G_=!1,j_="nuxtI18nInternal",Y_="i18n_redirected",Ac="nuxt-i18n-slp",W_=typeof window<"u";function Q_(e){e=e||[];const t=[];for(const n of e)Fe(n)?t.push({code:n}):t.push(n);return t}function Vr(e){return Fe(e)?e:B_(e)?e.toString():"(null)"}function kc(e,t,{defaultLocale:n,strategy:i,routesNameSeparator:r,defaultLocaleRouteNameSuffix:s,differentDomains:a}){const o=i!=="no_prefix"||a;let l=Vr(e)+(o?r+t:"");return t===n&&i==="prefix_and_default"&&(l+=r+s),l}function Rc(e,t){return lt(e)?e(t):e}function Z_(e,t){const n=[];for(const[i,r]of t.entries()){const s=e.find(a=>a.language.toLowerCase()===r.toLowerCase());if(s){n.push({code:s.code,score:1-i/t.length});break}}for(const[i,r]of t.entries()){const s=r.split("-")[0].toLowerCase(),a=e.find(o=>o.language.split("-")[0].toLowerCase()===s);if(a){n.push({code:a.code,score:.999-i/t.length});break}}return n}const q_=Z_;function J_(e,t){return e.score===t.score?t.code.length-e.code.length:t.score-e.score}const X_=J_;function e0(e,t,{matcher:n=q_,comparer:i=X_}={}){const r=[];for(const a of e){const{code:o}=a,l=a.language||o;r.push({code:o,language:l})}const s=n(r,t);return s.length>1&&s.sort(i),s.length?s[0].code:""}function tl(e){return new RegExp(`^/(${e.join("|")})(?:/|$)`,"i")}const ti=new Map;async function t0(e,t){const n={messages:{}};for(const i of e){const{default:r}=await i(),s=lt(r)?await t.runWithContext(async()=>await r()):r;ls(s,n)}return n}function Zh(e,t){let n=[];if(Ct(e))n=e;else if(je(e)){const i=[...t,"default"];for(const r of i)e[r]&&(n=[...n,...e[r].filter(Boolean)])}else Fe(e)&&t.every(i=>i!==e)&&n.push(e);return n}async function n0(e,t,n){const{defaultLocale:i,initialLocale:r,localeCodes:s,fallbackLocale:a,lazy:o}=n;if(o&&a){const c=Zh(a,[i,r]);await Promise.all(c.map(d=>Lc(d,t,e)))}const l=o?[...new Set().add(i).add(r)]:s;return await Promise.all(l.map(c=>Lc(c,t,e))),e}async function s0(e,{key:t,load:n}){let i=null;try{const r=await n().then(s=>"default"in s?s.default:s);lt(r)?i=await r(e):(i=r,i!=null&&ti&&ti.set(t,i))}catch(r){console.error("Failed locale loading: "+r.message)}return i}async function pr(e,t,n){const i=t[e];if(i==null){console.warn("Could not find messages for locale code: "+e);return}const r={};for(const s of i){let a=null;ti&&ti.has(s.key)&&s.cache?a=ti.get(s.key):a=await s0(e,s),a!=null&&ls(a,r)}n(e,r)}async function Lc(e,t,n){await pr(e,t,(r,s)=>{const a=n[r]||{};ls(s,a),n[r]=a})}function i0(e){return e!=null&&"global"in e&&"mode"in e}function r0(e){return e!=null&&!("__composer"in e)&&"locale"in e&&Jt(e.locale)}function qh(e){return e!=null&&"__composer"in e}function jn(e){return i0(e)?e.global:e}function Ss(e){const t=jn(e);return r0(t)?t:qh(t)?t.__composer:t}function a0(e,t){return k(e[t])}function Br(e,t){return a0(jn(e),t)}function Jh(e,t){const n=jn(e);Jt(n.locale)?n.locale.value=t:n.locale=t}function $r(e){return Br(e,"locale")}function o0(e){return Br(e,"locales")}function l0(e){return Br(e,"localeCodes")}function c0(e,t){return jn(e).setLocaleCookie(t)}function Xh(e,t,n){return jn(e).mergeLocaleMessage(t,n)}async function d0(e,t,n,i,r){return jn(e).onBeforeLanguageSwitch(t,n,i,r)}function u0(e,t,n){return jn(e).onLanguageSwitched(t,n)}function h0(e,t){return[e.slice(0,t),e.slice(t)]}function p0(e){const{fullPath:t,query:n,hash:i,name:r,path:s,params:a,meta:o,redirectedFrom:l,matched:c}=e;return{fullPath:t,params:a,query:n,hash:i,name:r,path:s,meta:o,matched:c,redirectedFrom:l}}function f0({router:e},t,n,i){var c,d;if(n!=="prefix")return e.resolve(t);const[r,s]=h0(t.path,1),a=`${r}${i}${s===""?s:`/${s}`}`,o=(d=(c=e.options)==null?void 0:c.routes)==null?void 0:d.find(u=>u.path===a);if(o==null)return t;const l=Ot({},t,o);return l.path=a,e.resolve(l)}const m0=new Set(["prefix_and_default","prefix_except_default"]);function g0(e){const{currentLocale:t,defaultLocale:n,strategy:i}=e;return!(t===n&&m0.has(i))&&i!=="no_prefix"}const y0=g0;function As(e,t){const{routesNameSeparator:n}=e.runtimeConfig.public.i18n,i=k(t);return i==null||!i.name?void 0:Vr(i.name).split(n)[0]}function Ur(e,t,n){var r;if(typeof t=="string"&&vn(t,{acceptRelative:!0}))return t;const i=Hr(e,t,n);return i==null?"":((r=i.redirectedFrom)==null?void 0:r.fullPath)||i.fullPath}function nl(e,t,n){return Hr(e,t,n)??void 0}
16function b0(e,t,n){return Hr(e,t,n)??void 0}function Hr(e,t,n){const{router:i,i18n:r}=e,s=n||$r(r),{defaultLocale:a,strategy:o,trailingSlash:l}=e.runtimeConfig.public.i18n,c=A0(e.runtimeConfig);let d;if(Fe(t))if(t[0]==="/"){const{pathname:h,search:m,hash:v}=Ga(t),_=Wu(m);d={path:h,query:_,hash:v}}else d={name:t};else d=t;let u=Ot({},d);if((h=>"path"in h&&!!h.path&&!("name"in h))(u)){const h=f0(e,u,o,s),m=As(e,h);Fe(m)?(u={name:kc(m,s,e.runtimeConfig.public.i18n),params:h.params,query:h.query,hash:h.hash},u.state=h.state):(c({currentLocale:s,defaultLocale:a,strategy:o})&&(u.path=`/${s}${u.path}`),u.path=l?rr(u.path,!0):Pr(u.path,!0))}else!u.name&&!("path"in u)&&(u.name=As(e,i.currentRoute.value)),u.name=kc(u.name,s,e.runtimeConfig.public.i18n);try{const h=i.resolve(u);return h.name?h:i.resolve(t)}catch(h){if(typeof h=="object"&&"type"in h&&h.type===1)return null}}function v0(e,t){var i;if(e.runtimeConfig.public.i18n.experimental.switchLocalePathLinkSSR)return k(e.metaState.value);const n=t.meta||{};return((i=k(n))==null?void 0:i[j_])||{}}function ks(e,t,n){const i=n??e.router.currentRoute.value,r=As(e,i);if(!r)return"";const s=k0(e.runtimeConfig),a=p0(i),o=v0(e,i)[t],l={...a,name:r,params:{...a.params,...o}},c=Ur(e,l,t);return s(c,t)}function ep(e,{dir:t=!0,lang:n=!0,seo:i=!0,key:r="hid"}){const{defaultDirection:s}=Be().public.i18n,a=Ss(e.i18n),o={htmlAttrs:{},link:[],meta:[]},l=k(a.baseUrl);if(l||console.warn("I18n `baseUrl` is required to generate valid SEO tag links."),k(a.locales)==null||l==null)return o;const c=$r(e.i18n),d=o0(e.i18n),u=Q_(d).find(m=>m.code===c)||{code:c},p=u.language,h=u.dir||s;return t&&(o.htmlAttrs.dir=h),n&&p&&(o.htmlAttrs.lang=p),i&&c&&k(a.locales)&&(o.link.push(..._0(e,k(d),r),...w0(e,r,i)),o.meta.push(...E0(e,r,i),...S0(u,p,r),...C0(k(d),p,r))),o}function sl(){const e=ct(),t=Ss(e.$i18n);return Ms(k(t.baseUrl),e.$config.app.baseURL)}function _0(e,t,n){const i=sl(),{defaultLocale:r,strategy:s}=Be().public.i18n,a=[];if(s==="no_prefix")return a;const o=new Map;for(const l of t){const c=l.language;if(!c){console.warn("Locale `language` ISO code is required to generate alternate link");continue}const[d,u]=c.split("-");d&&u&&(l.isCatchallLocale||!o.has(d))&&o.set(d,l),o.set(c,l)}for(const[l,c]of o.entries()){const d=ks(e,c.code);d&&a.push({[n]:`i18n-alt-${l}`,rel:"alternate",href:co(d,i),hreflang:l})}if(r){const l=ks(e,r);l&&a.push({[n]:"i18n-xd",rel:"alternate",href:co(l,i),hreflang:"x-default"})}return a}function tp(e,t,n){const i=e.router.currentRoute.value,r=nl(e,{...i,path:void 0,name:As(e,i)});if(!r)return"";let s=co(r.path,t);const a=je(n)&&n.canonicalQueries||[],o=r.query,l=new URLSearchParams;for(const d of a)if(d in o){const u=o[d];Ct(u)?u.forEach(p=>l.append(d,p||"")):l.append(d,u||"")}const c=l.toString();return c&&(s=`${s}?${c}`),s}function w0(e,t,n){const i=sl(),r=tp(e,i,n);return r?[{[t]:"i18n-can",rel:"canonical",href:r}]:[]}function E0(e,t,n){const i=sl(),r=tp(e,i,n);return r?[{[t]:"i18n-og-url",property:"og:url",content:r}]:[]}function S0(e,t,n){return!e||!t?[]:[{[n]:"i18n-og",property:"og:locale",content:np(t)}]}function C0(e,t,n){return e.filter(r=>r.language&&r.language!==t).map(r=>({[n]:`i18n-og-alt-${r.language}`,property:"og:locale:alternate",content:np(r.language)}))}function np(e){return(e||"").replace(/-/g,"_")}function co(e,t){return e.match(/^https?:\/\//)?e:Ms(t,e)}const I0=`(${Os.join("|")})`,Nc=tl(Os);function sp(){const{routesNameSeparator:e,defaultLocaleRouteNameSuffix:t}=Be().public.i18n,n=`(?:${e}${t})?`,i=new RegExp(`${e}${I0}${n}$`,"i");return s=>{let a=null;return typeof s=="string"?(a=s.match(Nc),(a==null?void 0:a[1])??""):(s.name?a=Vr(s.name).match(i):s.path&&(a=s.path.match(Nc)),(a==null?void 0:a[1])??"")}}function il(e){return{i18n:e??ct().$i18n,router:dn(),runtimeConfig:Be(),metaState:Gh("nuxt-i18n-meta",()=>({}))}}async function Dc(e,t,n,i=!1){const{differentDomains:r,skipSettingLocaleOnNavigate:s,lazy:a}=n,o=Oi(n),l=ct(),c=$r(t),d=l0(t);function u(h=c){o===!1||!o.useCookie||s||c0(t,h)}if(!e||!i&&r||c===e)return u(),!1;const p=await d0(t,c,e,i,l);if(p&&d.includes(p)){if(c===p)return u(),!1;e=p}
16if(a){const h=Br(t,"fallbackLocale"),m=Xh.bind(null,t);if(h){const v=Zh(h,[e]);await Promise.all(v.map(_=>pr(_,hr,m)))}await pr(e,hr,m)}return s?!1:(u(e),Jh(t,e),await u0(t,c,e),!0)}function xc(e,t,n,i,r){const{strategy:s,defaultLocale:a,differentDomains:o,multiDomainLocales:l}=r,{localeCookie:c}=i,d=Oi(r),u=lt(n)?n():n,p=x0(e,i,u);if(p.reason===ap.SSG_IGNORE)return u;if(p.locale&&p.from!=null)return p.locale;let h="";o||l?h||(h=M0(Fr,s,e)):s!=="no_prefix"&&(h||(h=t));const m=d&&d.useCookie&&c;return h||(h=m||u||a||""),h}function Mc({route:e,locale:t,routeLocale:n,strategy:i},r=!1){if(n===t||i==="no_prefix")return"";const s=il();let a=ks(s,t,e.to);return r&&!a&&(a=Ur(s,e.to.fullPath,t)),Ka(a,e.to.fullPath)||e.from&&Ka(a,e.from.fullPath)?"":a}function T0(e){return je(e)&&"path"in e&&"statusCode"in e}const P0=()=>Gh(Qh+":redirect",()=>"");function bs(e,t){return kr(e,{redirectCode:t})}async function Fc(e,{status:t=302,enableNavigate:n=!1}={}){const{nuxtApp:i,i18n:r,locale:s,route:a}=e,{rootRedirect:o,differentDomains:l,multiDomainLocales:c,skipSettingLocaleOnNavigate:d,locales:u,strategy:p}=i.$config.public.i18n;let{redirectPath:h}=e;if(a.path==="/"&&o)return Fe(o)?h="/"+o:T0(o)&&(h="/"+o.path,t=o.statusCode),h=i.$localePath(h,s),bs(h,t);if(!(d&&(r.__pendingLocale=s,r.__pendingLocalePromise=new Promise(m=>{r.__resolvePendingLocalePromise=m}),!n))){if(c&&p==="prefix_except_default"){const m=zr(),v=u.find(b=>{var w;return typeof b!="string"?(w=b.defaultForDomains)==null?void 0:w.find(C=>C===m):!1}),_=typeof v!="string"?v==null?void 0:v.code:void 0;if(a.path.startsWith(`/${_}`))return bs(a.path.replace(`/${_}`,""),t);if(!a.path.startsWith(`/${s}`)&&s!==_){const w=sp()(a.path);return bs(w!==""?`/${s+a.path.replace(`/${w}`,"")}`:`/${s+(a.path==="/"?"":a.path)}`,t)}else if(h&&a.path!==h)return bs(h,t);return}if(l){const m=P0();m.value&&m.value!==h&&(m.value="",window.location.assign(h))}else if(h)return bs(h,t)}}function O0(e,t){vs(e,"$i18n",jn(t)),vs(e,"$getRouteBaseName",jt(As)),vs(e,"$localePath",jt(Ur)),vs(e,"$localeRoute",jt(nl)),vs(e,"$switchLocalePath",jt(ks)),vs(e,"$localeHead",jt(ep))}function A0(e=Be()){return t=>y0(t)&&!e.public.i18n.differentDomains}function k0(e=Be()){return(t,n)=>{if(!e.public.i18n.differentDomains)return t;const i=op(n);return i&&Ms(i,t)||t}}function R0(){return()=>{const e=ct(),{baseUrl:t,defaultLocale:n,differentDomains:i}=e.$config.public.i18n;if(lt(t))return t(e);const r=lt(n)?n():n;if(i&&r){const s=op(r);if(s)return s}return t}}function ip(e){return Qh+" "+e}function vs(e,t,n){Object.defineProperty(e,t,{get:()=>n})}function jt(e,t=il()){return(...n)=>e(t,...n)}function rp(){let e;return navigator.languages&&(e=e0(Fr,navigator.languages)),e}function L0(){const e=Oi(),t=e&&e.cookieKey||Y_,n=new Date,i={expires:new Date(n.setDate(n.getDate()+365)),path:"/",sameSite:e&&e.cookieCrossOrigin?"none":"lax",secure:e&&e.cookieCrossOrigin||e&&e.cookieSecure};return e&&e.cookieDomain&&(i.domain=e.cookieDomain),jh(t,i)}function va(e,t,n){if(t===!1||!t.useCookie)return;const i=e.value??void 0;if(i!=null){if(Os.includes(i))return i;if(n)return e.value=n,n;e.value=void 0}}function N0(e,t,n){n===!1||!n.useCookie||(e.value=t)}var ap=(e=>(e.NOT_FOUND="not_found_match",e.FIRST_ACCESS="first_access_only",e.NO_REDIRECT_ROOT="not_redirect_on_root",e.NO_REDIRECT_NO_PREFIX="not_redirect_on_no_prefix",e.SSG_IGNORE="detect_ignore_on_ssg",e))(ap||{});const D0={locale:""};function x0(e,t,n=""){const i=Oi();if(!i)return D0;const{strategy:r}=Be().public.i18n,{ssg:s,callType:a,firstAccess:o,localeCookie:l}=t;if(!o)return{locale:r==="no_prefix"?n:"",reason:"first_access_only"};const{redirectOn:c,alwaysRedirect:d,useCookie:u,fallbackLocale:p}=i,h=Fe(e)?e:e.path;if(r!=="no_prefix"){if(c==="root"&&h!=="/")return{locale:"",reason:"not_redirect_on_root"};if(c==="no prefix"&&!d&&h.match(tl(Os)))return{locale:"",reason:"not_redirect_on_no_prefix"}}let m;const v=u&&l||void 0;u&&(m="cookie");const _=rp();v||(m="navigator_or_header");const b=v||_,w=b||p||"";return!b&&p&&(m="fallback"),{locale:w,from:m}}function zr(){let e;return e=window.location.host,e}function M0(e,t,n){let i=zr()||"";const r=je(n)?n.path:Fe(n)?n:"";if(i){let s;const a=e.filter(o=>{if(o&&o.domain){let l=o.domain;return vn(o.domain)&&(l=o.domain.replace(/(http|https):\/\//,"")),l===i}else if(Array.isArray(o==null?void 0:o.domains))return o.domains.includes(i);return!1});if(a.length===1)s=a[0];else if(a.length>1)if(t==="no_prefix")console.warn(ip("Multiple matching domains found! This is not supported for no_prefix strategy in combination with differentDomains!")),s=a[0];else{if(n&&r&&r!==""){const o=r.match(tl(a.map(l=>l.code)));o&&o.length>1&&(s=a.find(l=>l.code===o[1]))}s||(s=a.find(o=>Array.isArray(o.defaultForDomains)?o.defaultForDomains.includes(i):o.domainDefault))}if(s)return s.code;i=""}return i}function op(e){var a,o,l;const t=Be(),n=zr(),i=t.public.i18n,r=Fr.find(c=>c.code===e),s=((o=(a=i==null?void 0:i.domainLocales)==null?void 0:a[e])==null?void 0:o.domain)||(r==null?void 0:r.domain)||((l=r==null?void 0:r.domains)==null?void 0:l.find(c=>c===n));if(s){if(vn(s,{strict:!0}))return s;let c;return c=new URL(window.location.origin).protocol,c+"//"+s}console.warn(ip("Could not find domain name for locale "+e))}const Oi=(e=Be().public.i18n)=>(e==null?void 0:e.detectBrowserLanguage)===!1?!1:e==null?void 0:e.detectBrowserLanguage;function F0(e,t){const{multiDomainLocales:n,strategy:i,routesNameSeparator:r,defaultLocaleRouteNameSuffix:s}=e.$config.public.i18n;if(!n||!(i==="prefix_except_default"||i==="prefix_and_default"))return;const a=dn(),o=[r,s].join("");for(const l of a.getRoutes()){const c=Vr(l.name);if(!c.includes(o))continue;if(c.split(r)[1]===t){l.name=c.replace(o,"");continue}a.removeRoute(l.name)}
16}function V0(e){const{locales:t,defaultLocale:n,multiDomainLocales:i}=e.$config.public.i18n;let r=n||"";if(!i)return r;const s=zr();if(t.some(o=>typeof o!="string"&&Array.isArray(o.defaultForDomains))){const o=t.find(l=>typeof l=="string"||!Array.isArray(l.defaultForDomains)?!1:l.defaultForDomains.includes(s??""));r=(o==null?void 0:o.code)??""}return r}/*!
17  * message-compiler v10.0.5
18  * (c) 2024 kazuya kawaguchi
19  * Released under the MIT License.
20  */function B0(e,t,n){return{line:e,column:t,offset:n}}function uo(e,t,n){return{start:e,end:t}}const ot={EXPECTED_TOKEN:1,INVALID_TOKEN_IN_PLACEHOLDER:2,UNTERMINATED_SINGLE_QUOTE_IN_PLACEHOLDER:3,UNKNOWN_ESCAPE_SEQUENCE:4,INVALID_UNICODE_ESCAPE_SEQUENCE:5,UNBALANCED_CLOSING_BRACE:6,UNTERMINATED_CLOSING_BRACE:7,EMPTY_PLACEHOLDER:8,NOT_ALLOW_NEST_PLACEHOLDER:9,INVALID_LINKED_FORMAT:10,MUST_HAVE_MESSAGES_IN_PLURAL:11,UNEXPECTED_EMPTY_LINKED_MODIFIER:12,UNEXPECTED_EMPTY_LINKED_KEY:13,UNEXPECTED_LEXICAL_ANALYSIS:14,UNHANDLED_CODEGEN_NODE_TYPE:15,UNHANDLED_MINIFIER_NODE_TYPE:16},$0=17;function Kr(e,t,n={}){const{domain:i,messages:r,args:s}=n,a=e,o=new SyntaxError(String(a));return o.code=e,t&&(o.location=t),o.domain=i,o}function U0(e){throw e}const En=" ",H0="\r",Ht=`
21`,z0="\u2028",K0="\u2029";function G0(e){const t=e;let n=0,i=1,r=1,s=0;const a=y=>t[y]===H0&&t[y+1]===Ht,o=y=>t[y]===Ht,l=y=>t[y]===K0,c=y=>t[y]===z0,d=y=>a(y)||o(y)||l(y)||c(y),u=()=>n,p=()=>i,h=()=>r,m=()=>s,v=y=>a(y)||l(y)||c(y)?Ht:t[y],_=()=>v(n),b=()=>v(n+s);function w(){return s=0,d(n)&&(i++,r=0),a(n)&&n++,n++,r++,t[n]}function C(){return a(n+s)&&s++,s++,t[n+s]}function O(){n=0,i=1,r=1,s=0}function T(y=0){s=y}function E(){const y=n+s;for(;y!==n;)w();s=0}return{index:u,line:p,column:h,peekOffset:m,charAt:v,currentChar:_,currentPeek:b,next:w,peek:C,reset:O,resetPeek:T,skipToPeek:E}}const Nn=void 0,j0=".",Vc="'",Y0="tokenizer";function W0(e,t={}){const n=t.location!==!1,i=G0(e),r=()=>i.index(),s=()=>B0(i.line(),i.column(),i.index()),a=s(),o=r(),l={currentType:13,offset:o,startLoc:a,endLoc:a,lastType:13,lastOffset:o,lastStartLoc:a,lastEndLoc:a,braceNest:0,inLinked:!1,text:""},c=()=>l,{onError:d}=t;function u(U,j,ce,...Ie){const De=c();if(j.column+=ce,j.offset+=ce,d){const Te=n?uo(De.startLoc,j):null,pe=Kr(U,Te,{domain:Y0,args:Ie});d(pe)}}function p(U,j,ce){U.endLoc=s(),U.currentType=j;const Ie={type:j};return n&&(Ie.loc=uo(U.startLoc,U.endLoc)),ce!=null&&(Ie.value=ce),Ie}const h=U=>p(U,13);function m(U,j){return U.currentChar()===j?(U.next(),j):(u(ot.EXPECTED_TOKEN,s(),0,j),"")}function v(U){let j="";for(;U.currentPeek()===En||U.currentPeek()===Ht;)j+=U.currentPeek(),U.peek();return j}function _(U){const j=v(U);return U.skipToPeek(),j}function b(U){if(U===Nn)return!1;const j=U.charCodeAt(0);return j>=97&&j<=122||j>=65&&j<=90||j===95}function w(U){if(U===Nn)return!1;const j=U.charCodeAt(0);return j>=48&&j<=57}function C(U,j){const{currentType:ce}=j;if(ce!==2)return!1;v(U);const Ie=b(U.currentPeek());return U.resetPeek(),Ie}function O(U,j){const{currentType:ce}=j;if(ce!==2)return!1;v(U);const Ie=U.currentPeek()==="-"?U.peek():U.currentPeek(),De=w(Ie);return U.resetPeek(),De}function T(U,j){const{currentType:ce}=j;if(ce!==2)return!1;v(U);const Ie=U.currentPeek()===Vc;return U.resetPeek(),Ie}function E(U,j){const{currentType:ce}=j;if(ce!==7)return!1;v(U);const Ie=U.currentPeek()===".";return U.resetPeek(),Ie}function y(U,j){const{currentType:ce}=j;if(ce!==8)return!1;v(U);const Ie=b(U.currentPeek());return U.resetPeek(),Ie}function P(U,j){const{currentType:ce}=j;if(!(ce===7||ce===11))return!1;v(U);const Ie=U.currentPeek()===":";return U.resetPeek(),Ie}function A(U,j){const{currentType:ce}=j;if(ce!==9)return!1;const Ie=()=>{const Te=U.currentPeek();return Te==="{"?b(U.peek()):Te==="@"||Te==="|"||Te===":"||Te==="."||Te===En||!Te?!1:Te===Ht?(U.peek(),Ie()):L(U,!1)},De=Ie();return U.resetPeek(),De}function I(U){v(U);const j=U.currentPeek()==="|";return U.resetPeek(),j}function L(U,j=!0){const ce=(De=!1,Te="")=>{const pe=U.currentPeek();return pe==="{"||pe==="@"||!pe?De:pe==="|"?!(Te===En||Te===Ht):pe===En?(U.peek(),ce(!0,En)):pe===Ht?(U.peek(),ce(!0,Ht)):!0},Ie=ce();return j&&U.resetPeek(),Ie}function D(U,j){const ce=U.currentChar();return ce===Nn?Nn:j(ce)?(U.next(),ce):null}function z(U){const j=U.charCodeAt(0);return j>=97&&j<=122||j>=65&&j<=90||j>=48&&j<=57||j===95||j===36}function G(U){return D(U,z)}function ne(U){const j=U.charCodeAt(0);return j>=97&&j<=122||j>=65&&j<=90||j>=48&&j<=57||j===95||j===36||j===45}function W(U){return D(U,ne)}function ue(U){const j=U.charCodeAt(0);return j>=48&&j<=57}function H(U){return D(U,ue)}function x(U){const j=U.charCodeAt(0);return j>=48&&j<=57||j>=65&&j<=70||j>=97&&j<=102}function V(U){return D(U,x)}function te(U){let j="",ce="";for(;j=H(U);)ce+=j;return ce}function fe(U){let j="";for(;;){const ce=U.currentChar();if(ce==="{"||ce==="}"||ce==="@"||ce==="|"||!ce)break;if(ce===En||ce===Ht)if(L(U))j+=ce,U.next();else{if(I(U))break;j+=ce,U.next()}else j+=ce,U.next()}return j}function re(U){_(U);let j="",ce="";for(;j=W(U);)ce+=j;return U.currentChar()===Nn&&u(ot.UNTERMINATED_CLOSING_BRACE,s(),0),ce}function be(U){_(U);let j="";return U.currentChar()==="-"?(U.next(),j+=`-${te(U)}`):j+=te(U),U.currentChar()===Nn&&u(ot.UNTERMINATED_CLOSING_BRACE,s(),0),j}function Y(U){return U!==Vc&&U!==Ht}function oe(U){_(U),m(U,"'");let j="",ce="";for(;j=D(U,Y);)j==="\\"?ce+=K(U):ce+=j;const Ie=U.currentChar();return Ie===Ht||Ie===Nn?(u(ot.UNTERMINATED_SINGLE_QUOTE_IN_PLACEHOLDER,s(),0),Ie===Ht&&(U.next(),m(U,"'")),ce):(m(U,"'"),ce)}function K(U){const j=U.currentChar();switch(j){case"\\":case"'":return U.next(),`\\${j}`;case"u":return Z(U,j,4);case"U":return Z(U,j,6);default:return u(ot.UNKNOWN_ESCAPE_SEQUENCE,s(),0,j),""}}function Z(U,j,ce){m(U,j);let Ie="";for(let De=0;De<ce;De++){const Te=V(U);if(!Te){u(ot.INVALID_UNICODE_ESCAPE_SEQUENCE,s(),0,`\\${j}${Ie}${U.currentChar()}`);break}Ie+=Te}return`\\${j}${Ie}`}function me(U){return U!=="{"&&U!=="}"&&U!==En&&U!==Ht}function q(U){_(U);let j="",ce="";for(;j=D(U,me);)ce+=j;return ce}function ae(U){let j="",ce="";for(;j=G(U);)ce+=j;return ce}function ge(U){const j=ce=>{const Ie=U.currentChar();return Ie==="{"||Ie==="@"||Ie==="|"||Ie==="("||Ie===")"||!Ie||Ie===En?ce:(ce+=Ie,U.next(),j(ce))};return j("")}function we(U){_(U);const j=m(U,"|");return _(U),j}function X(U,j){let ce=null;
21switch(U.currentChar()){case"{":return j.braceNest>=1&&u(ot.NOT_ALLOW_NEST_PLACEHOLDER,s(),0),U.next(),ce=p(j,2,"{"),_(U),j.braceNest++,ce;case"}":return j.braceNest>0&&j.currentType===2&&u(ot.EMPTY_PLACEHOLDER,s(),0),U.next(),ce=p(j,3,"}"),j.braceNest--,j.braceNest>0&&_(U),j.inLinked&&j.braceNest===0&&(j.inLinked=!1),ce;case"@":return j.braceNest>0&&u(ot.UNTERMINATED_CLOSING_BRACE,s(),0),ce=B(U,j)||h(j),j.braceNest=0,ce;default:{let De=!0,Te=!0,pe=!0;if(I(U))return j.braceNest>0&&u(ot.UNTERMINATED_CLOSING_BRACE,s(),0),ce=p(j,1,we(U)),j.braceNest=0,j.inLinked=!1,ce;if(j.braceNest>0&&(j.currentType===4||j.currentType===5||j.currentType===6))return u(ot.UNTERMINATED_CLOSING_BRACE,s(),0),j.braceNest=0,Se(U,j);if(De=C(U,j))return ce=p(j,4,re(U)),_(U),ce;if(Te=O(U,j))return ce=p(j,5,be(U)),_(U),ce;if(pe=T(U,j))return ce=p(j,6,oe(U)),_(U),ce;if(!De&&!Te&&!pe)return ce=p(j,12,q(U)),u(ot.INVALID_TOKEN_IN_PLACEHOLDER,s(),0,ce.value),_(U),ce;break}}return ce}function B(U,j){const{currentType:ce}=j;let Ie=null;const De=U.currentChar();switch((ce===7||ce===8||ce===11||ce===9)&&(De===Ht||De===En)&&u(ot.INVALID_LINKED_FORMAT,s(),0),De){case"@":return U.next(),Ie=p(j,7,"@"),j.inLinked=!0,Ie;case".":return _(U),U.next(),p(j,8,".");case":":return _(U),U.next(),p(j,9,":");default:return I(U)?(Ie=p(j,1,we(U)),j.braceNest=0,j.inLinked=!1,Ie):E(U,j)||P(U,j)?(_(U),B(U,j)):y(U,j)?(_(U),p(j,11,ae(U))):A(U,j)?(_(U),De==="{"?X(U,j)||Ie:p(j,10,ge(U))):(ce===7&&u(ot.INVALID_LINKED_FORMAT,s(),0),j.braceNest=0,j.inLinked=!1,Se(U,j))}}function Se(U,j){let ce={type:13};if(j.braceNest>0)return X(U,j)||h(j);if(j.inLinked)return B(U,j)||h(j);switch(U.currentChar()){case"{":return X(U,j)||h(j);case"}":return u(ot.UNBALANCED_CLOSING_BRACE,s(),0),U.next(),p(j,3,"}");case"@":return B(U,j)||h(j);default:{if(I(U))return ce=p(j,1,we(U)),j.braceNest=0,j.inLinked=!1,ce;if(L(U))return p(j,0,fe(U));break}}return ce}function Ce(){const{currentType:U,offset:j,startLoc:ce,endLoc:Ie}=l;return l.lastType=U,l.lastOffset=j,l.lastStartLoc=ce,l.lastEndLoc=Ie,l.offset=r(),l.startLoc=s(),i.currentChar()===Nn?p(l,13):Se(i,l)}return{nextToken:Ce,currentOffset:r,currentPosition:s,context:c}}const Q0="parser",Z0=/(?:\\\\|\\'|\\u([0-9a-fA-F]{4})|\\U([0-9a-fA-F]{6}))/g;function q0(e,t,n){switch(e){case"\\\\":return"\\";case"\\'":return"'";default:{const i=parseInt(t||n,16);return i<=55295||i>=57344?String.fromCodePoint(i):"�"}}}function J0(e={}){const t=e.location!==!1,{onError:n}=e;function i(b,w,C,O,...T){const E=b.currentPosition();if(E.offset+=O,E.column+=O,n){const y=t?uo(C,E):null,P=Kr(w,y,{domain:Q0,args:T});n(P)}}function r(b,w,C){const O={type:b};return t&&(O.start=w,O.end=w,O.loc={start:C,end:C}),O}function s(b,w,C,O){t&&(b.end=w,b.loc&&(b.loc.end=C))}function a(b,w){const C=b.context(),O=r(3,C.offset,C.startLoc);return O.value=w,s(O,b.currentOffset(),b.currentPosition()),O}function o(b,w){const C=b.context(),{lastOffset:O,lastStartLoc:T}=C,E=r(5,O,T);return E.index=parseInt(w,10),b.nextToken(),s(E,b.currentOffset(),b.currentPosition()),E}function l(b,w){const C=b.context(),{lastOffset:O,lastStartLoc:T}=C,E=r(4,O,T);return E.key=w,b.nextToken(),s(E,b.currentOffset(),b.currentPosition()),E}function c(b,w){const C=b.context(),{lastOffset:O,lastStartLoc:T}=C,E=r(9,O,T);return E.value=w.replace(Z0,q0),b.nextToken(),s(E,b.currentOffset(),b.currentPosition()),E}function d(b){const w=b.nextToken(),C=b.context(),{lastOffset:O,lastStartLoc:T}=C,E=r(8,O,T);return w.type!==11?(i(b,ot.UNEXPECTED_EMPTY_LINKED_MODIFIER,C.lastStartLoc,0),E.value="",s(E,O,T),{nextConsumeToken:w,node:E}):(w.value==null&&i(b,ot.UNEXPECTED_LEXICAL_ANALYSIS,C.lastStartLoc,0,un(w)),E.value=w.value||"",s(E,b.currentOffset(),b.currentPosition()),{node:E})}function u(b,w){const C=b.context(),O=r(7,C.offset,C.startLoc);return O.value=w,s(O,b.currentOffset(),b.currentPosition()),O}function p(b){const w=b.context(),C=r(6,w.offset,w.startLoc);let O=b.nextToken();if(O.type===8){const T=d(b);C.modifier=T.node,O=T.nextConsumeToken||b.nextToken()}switch(O.type!==9&&i(b,ot.UNEXPECTED_LEXICAL_ANALYSIS,w.lastStartLoc,0,un(O)),O=b.
21nextToken(),O.type===2&&(O=b.nextToken()),O.type){case 10:O.value==null&&i(b,ot.UNEXPECTED_LEXICAL_ANALYSIS,w.lastStartLoc,0,un(O)),C.key=u(b,O.value||"");break;case 4:O.value==null&&i(b,ot.UNEXPECTED_LEXICAL_ANALYSIS,w.lastStartLoc,0,un(O)),C.key=l(b,O.value||"");break;case 5:O.value==null&&i(b,ot.UNEXPECTED_LEXICAL_ANALYSIS,w.lastStartLoc,0,un(O)),C.key=o(b,O.value||"");break;case 6:O.value==null&&i(b,ot.UNEXPECTED_LEXICAL_ANALYSIS,w.lastStartLoc,0,un(O)),C.key=c(b,O.value||"");break;default:{i(b,ot.UNEXPECTED_EMPTY_LINKED_KEY,w.lastStartLoc,0);const T=b.context(),E=r(7,T.offset,T.startLoc);return E.value="",s(E,T.offset,T.startLoc),C.key=E,s(C,T.offset,T.startLoc),{nextConsumeToken:O,node:C}}}return s(C,b.currentOffset(),b.currentPosition()),{node:C}}function h(b){const w=b.context(),C=w.currentType===1?b.currentOffset():w.offset,O=w.currentType===1?w.endLoc:w.startLoc,T=r(2,C,O);T.items=[];let E=null;do{const A=E||b.nextToken();switch(E=null,A.type){case 0:A.value==null&&i(b,ot.UNEXPECTED_LEXICAL_ANALYSIS,w.lastStartLoc,0,un(A)),T.items.push(a(b,A.value||""));break;case 5:A.value==null&&i(b,ot.UNEXPECTED_LEXICAL_ANALYSIS,w.lastStartLoc,0,un(A)),T.items.push(o(b,A.value||""));break;case 4:A.value==null&&i(b,ot.UNEXPECTED_LEXICAL_ANALYSIS,w.lastStartLoc,0,un(A)),T.items.push(l(b,A.value||""));break;case 6:A.value==null&&i(b,ot.UNEXPECTED_LEXICAL_ANALYSIS,w.lastStartLoc,0,un(A)),T.items.push(c(b,A.value||""));break;case 7:{const I=p(b);T.items.push(I.node),E=I.nextConsumeToken||null;break}}}while(w.currentType!==13&&w.currentType!==1);const y=w.currentType===1?w.lastOffset:b.currentOffset(),P=w.currentType===1?w.lastEndLoc:b.currentPosition();return s(T,y,P),T}function m(b,w,C,O){const T=b.context();let E=O.items.length===0;const y=r(1,w,C);y.cases=[],y.cases.push(O);do{const P=h(b);E||(E=P.items.length===0),y.cases.push(P)}while(T.currentType!==13);return E&&i(b,ot.MUST_HAVE_MESSAGES_IN_PLURAL,C,0),s(y,b.currentOffset(),b.currentPosition()),y}function v(b){const w=b.context(),{offset:C,startLoc:O}=w,T=h(b);return w.currentType===13?T:m(b,C,O,T)}function _(b){const w=W0(b,Ot({},e)),C=w.context(),O=r(0,C.offset,C.startLoc);return t&&O.loc&&(O.loc.source=b),O.body=v(w),e.onCacheKey&&(O.cacheKey=e.onCacheKey(b)),C.currentType!==13&&i(w,ot.UNEXPECTED_LEXICAL_ANALYSIS,C.lastStartLoc,0,b[C.offset]||""),s(O,w.currentOffset(),w.currentPosition()),O}return{parse:_}}function un(e){if(e.type===13)return"EOF";const t=(e.value||"").replace(/\r?\n/gu,"\\n");return t.length>10?t.slice(0,9)+"…":t}function X0(e,t={}){const n={ast:e,helpers:new Set};return{context:()=>n,helper:s=>(n.helpers.add(s),s)}}function Bc(e,t){for(let n=0;n<e.length;n++)rl(e[n],t)}function rl(e,t){switch(e.type){case 1:Bc(e.cases,t),t.helper("plural");break;case 2:Bc(e.items,t);break;case 6:{rl(e.key,t),t.helper("linked"),t.helper("type");break}case 5:t.helper("interpolate"),t.helper("list");break;case 4:t.helper("interpolate"),t.helper("named");break}}function ew(e,t={}){const n=X0(e);n.helper("normalize"),e.body&&rl(e.body,n);const i=n.context();e.helpers=Array.from(i.helpers)}function tw(e){const t=e.body;return t.type===2?$c(t):t.cases.forEach(n=>$c(n)),e}function $c(e){if(e.items.length===1){const t=e.items[0];(t.type===3||t.type===9)&&(e.static=t.value,delete t.value)}else{const t=[];for(let n=0;n<e.items.length;n++){const i=e.items[n];if(!(i.type===3||i.type===9)||i.value==null)break;t.push(i.value)}if(t.length===e.items.length){e.static=el(t);for(let n=0;n<e.items.length;n++){const i=e.items[n];(i.type===3||i.type===9)&&delete i.value}}}}function ws(e){switch(e.t=e.type,e.type){case 0:{const t=e;ws(t.body),t.b=t.body,delete t.body;break}case 1:{const t=e,n=t.cases;for(let i=0;i<n.length;i++)ws(n[i]);t.c=n,delete t.cases;break}case 2:{const t=e,n=t.items;for(let i=0;i<n.length;i++)ws(n[i]);t.i=n,delete t.items,t.static&&(t.s=t.static,delete t.static);break}case 3:case 9:case 8:case 7:{const t=e;t.value&&(t.v=t.value,delete t.value);break}case 6:{const t=e;ws(t.key),t.k=t.key,delete t.key,t.modifier&&(ws(t.modifier),t.m=t.modifier,delete t.modifier);break}case 5:{const t=e;t.i=t.index,delete t.index;break}case 4:{const t=e;t.k=t.key,delete t.key;break}}delete e.type}function nw(e,t){const{sourceMap:n,filename:i,breakLineCode:r,needIndent:s}=t,a=t.location!==!1,o={filename:i,code:"",column:1,line:1,offset:0,map:void 0,breakLineCode:r,needIndent:s,indentLevel:0};a&&e.loc&&(o.source=e.loc.source);const l=()=>o;function c(_,b){o.code+=_}function d(_,b=!0){const w=b?r:"";c(s?w+"  ".repeat(_):w)}function u(_=!0){const b=++o.indentLevel;_&&d(b)}function p(_=!0){const b=--o.indentLevel;_&&d(b)}function h(){d(o.indentLevel)}return{context:l,push:c,indent:u,deindent:p,newline:h,helper:_=>`_${_}`,needIndent:()=>o.needIndent}}function sw(e,t){const{helper:n}=e;e.push(`${n("linked")}(`),Rs(e,t.key),t.modifier?(e.push(", "),Rs(e,t.modifier),e.push(", _type")):e.push(", undefined, _type"),e.push(")")}function iw(e,t){const{helper:n,needIndent:i}=e;e.push(`${n("normalize")}([`),e.indent(i());const r=t.items.length;for(let s=0;s<r&&(Rs(e,t.items[s]),s!==r-1);s++)e.push(", ");e.deindent(i()),e.push("])")}function rw(e,t){const{helper:n,needIndent:i}=e;if(t.cases.length>1){e.push(`${n("plural")}([`),e.indent(i());const r=t.cases.length;for(let s=0;s<r&&(Rs(e,t.cases[s]),s!==r-1);s++)e.push(", ");e.deindent(i()),e.push("])")}}function aw(e,t){t.body?Rs(e,t.body):e.push("null")}function Rs(e,t){const{helper:n}=e;switch(t.type){case 0:aw(e,t);break;case 1:rw(e,t);break;case 2:iw(e,t);break;case 6:sw(e,t);break;case 8:e.push(JSON.stringify(t.value),t);break;case 7:e.push(JSON.stringify(t.value),t);break;case 5:e.push(`${n("interpolate")}(${n("list")}(${t.index}))`,t);break;case 4:e.push(`${n("interpolate")}(${n("named")}(${JSON.stringify(t.key)}))`,t);break;case 9:e.push(JSON.stringify(t.value),t);break;case 3:e.push(JSON.stringify(t.value),t);break}}const ow=(e,t={})=>{const n=Fe(t.mode)?t.mode:"normal",i=Fe(t.filename)?t.filename:"message.intl",r=!!t.sourceMap,s=t.breakLineCode!=null?t.breakLineCode:n==="arrow"?";":`
22`,a=t.needIndent?t.needIndent:n!=="arrow",o=e.helpers||[],l=nw(e,{mode:n,filename:i,sourceMap:r,breakLineCode:s,needIndent:a});l.push(n==="normal"?"function __msg__ (ctx) {":"(ctx) => {"),l.indent(a),o.length>0&&(l.push(`const { ${el(o.map(u=>`${u}: _${u}`),", ")} } = ctx`),l.newline()),l.push("return "),Rs(l,e),l.deindent(a),l.push("}"),delete e.helpers;const{code:c,map:d}=l.context();return{ast:e,code:c,map:d?d.toJSON():void 0}};function lw(e,t={}){const n=Ot({},t),i=!!n.jit,r=!!n.minify,s=n.optimize==null?!0:n.optimize,o=J0(n).parse(e);
22return i?(s&&tw(o),r&&ws(o),{ast:o,code:""}):(ew(o,n),ow(o,n))}/*!
23  * core-base v10.0.5
24  * (c) 2024 kazuya kawaguchi
25  * Released under the MIT License.
26  */function cw(){typeof __INTLIFY_PROD_DEVTOOLS__!="boolean"&&(Jo().__INTLIFY_PROD_DEVTOOLS__=!1)}function _a(e){return n=>dw(n,e)}function dw(e,t){const n=hw(t);if(n==null)throw li(0);if(al(n)===1){const s=fw(n);return e.plural(s.reduce((a,o)=>[...a,Uc(e,o)],[]))}else return Uc(e,n)}const uw=["b","body"];function hw(e){return Yn(e,uw)}const pw=["c","cases"];function fw(e){return Yn(e,pw,[])}function Uc(e,t){const n=gw(t);if(n!=null)return e.type==="text"?n:e.normalize([n]);{const i=bw(t).reduce((r,s)=>[...r,ho(e,s)],[]);return e.normalize(i)}}const mw=["s","static"];function gw(e){return Yn(e,mw)}const yw=["i","items"];function bw(e){return Yn(e,yw,[])}function ho(e,t){const n=al(t);switch(n){case 3:return Ui(t,n);case 9:return Ui(t,n);case 4:{const i=t;if(sn(i,"k")&&i.k)return e.interpolate(e.named(i.k));if(sn(i,"key")&&i.key)return e.interpolate(e.named(i.key));throw li(n)}case 5:{const i=t;if(sn(i,"i")&&Pt(i.i))return e.interpolate(e.list(i.i));if(sn(i,"index")&&Pt(i.index))return e.interpolate(e.list(i.index));throw li(n)}case 6:{const i=t,r=Ew(i),s=Cw(i);return e.linked(ho(e,s),r?ho(e,r):void 0,e.type)}case 7:return Ui(t,n);case 8:return Ui(t,n);default:throw new Error(`unhandled node on format message part: ${n}`)}}const vw=["t","type"];function al(e){return Yn(e,vw)}const _w=["v","value"];function Ui(e,t){const n=Yn(e,_w);if(n)return n;throw li(t)}const ww=["m","modifier"];function Ew(e){return Yn(e,ww)}const Sw=["k","key"];function Cw(e){const t=Yn(e,Sw);if(t)return t;throw li(6)}function Yn(e,t,n){for(let i=0;i<t.length;i++){const r=t[i];if(sn(e,r)&&e[r]!=null)return e[r]}return n}function li(e){return new Error(`unhandled node type: ${e}`)}const Iw=e=>e;let Hi=ut();function Ls(e){return je(e)&&al(e)===0&&(sn(e,"b")||sn(e,"body"))}function Tw(e,t={}){let n=!1;const i=t.onError||U0;return t.onError=r=>{n=!0,i(r)},{...lw(e,t),detectError:n}}function Pw(e,t){if(Fe(e)){bt(t.warnHtmlMessage)&&t.warnHtmlMessage;const i=(t.onCacheKey||Iw)(e),r=Hi[i];if(r)return r;const{ast:s,detectError:a}=Tw(e,{...t,location:!1,jit:!0}),o=_a(s);return a?o:Hi[i]=o}else{const n=e.cacheKey;if(n){const i=Hi[n];return i||(Hi[n]=_a(e))}else return _a(e)}}let ci=null;function Ow(e){ci=e}function Aw(e,t,n){ci&&ci.emit("i18n:init",{timestamp:Date.now(),i18n:e,version:t,meta:n})}const kw=Rw("function:translate");function Rw(e){return t=>ci&&ci.emit(e,t)}const In={INVALID_ARGUMENT:$0,INVALID_DATE_ARGUMENT:18,INVALID_ISO_DATE_ARGUMENT:19,NOT_SUPPORT_NON_STRING_MESSAGE:20,NOT_SUPPORT_LOCALE_PROMISE_VALUE:21,NOT_SUPPORT_LOCALE_ASYNC_FUNCTION:22,NOT_SUPPORT_LOCALE_TYPE:23},Lw=24;function Tn(e){return Kr(e,null,void 0)}function ol(e,t){return t.locale!=null?Hc(t.locale):Hc(e.locale)}let wa;function Hc(e){if(Fe(e))return e;if(lt(e)){if(e.resolvedOnce&&wa!=null)return wa;if(e.constructor.name==="Function"){const t=e();if($_(t))throw Tn(In.NOT_SUPPORT_LOCALE_PROMISE_VALUE);return wa=t}else throw Tn(In.NOT_SUPPORT_LOCALE_ASYNC_FUNCTION)}else throw Tn(In.NOT_SUPPORT_LOCALE_TYPE)}function Nw(e,t,n){return[...new Set([n,...Ct(t)?t:je(t)?Object.keys(t):Fe(t)?[t]:[n]])]}function lp(e,t,n){const i=Fe(n)?n:fr,r=e;r.__localeChainCache||(r.__localeChainCache=new Map);let s=r.__localeChainCache.get(i);if(!s){s=[];let a=[n];for(;Ct(a);)a=zc(s,a,t);const o=Ct(t)||!Ye(t)?t:t.default?t.default:null;a=Fe(o)?[o]:o,Ct(a)&&zc(s,a,!1),r.__localeChainCache.set(i,s)}return s}function zc(e,t,n){let i=!0;for(let r=0;r<t.length&&bt(i);r++){const s=t[r];Fe(s)&&(i=Dw(e,t[r],n))}return i}function Dw(e,t,n){let i;const r=t.split("-");do{const s=r.join("-");i=xw(e,s,n),r.splice(-1,1)}while(r.length&&i===!0);return i}function xw(e,t,n){let i=!1;if(!e.includes(t)&&(i=!0,t)){i=t[t.length-1]!=="!";const r=t.replace(/!/g,"");e.push(r),(Ct(n)||Ye(n))&&n[r]&&(i=n[r])}return i}const Wn=[];Wn[0]={w:[0],i:[3,0],"[":[4],o:[7]};Wn[1]={w:[1],".":[2],"[":[4],o:[7]};Wn[2]={w:[2],i:[3,0],0:[3,0]};Wn[3]={i:[3,0],0:[3,0],w:[1,1],".":[2,1],"[":[4,1],o:[7,1]};Wn[4]={"'":[5,0],'"':[6,0],"[":[4,2],"]":[1,3],o:8,l:[4,0]};Wn[5]={"'":[4,0],o:8,l:[5,0]};Wn[6]={'"':[4,0],o:8,l:[6,0]};const Mw=/^\s?(?:true|false|-?[\d.]+|'[^']*'|"[^"]*")\s?$/;function Fw(e){return Mw.test(e)}function Vw(e){const t=e.charCodeAt(0),n=e.charCodeAt(e.length-1);return t===n&&(t===34||t===39)?e.slice(1,-1):e}function Bw(e){if(e==null)return"o";switch(e.charCodeAt(0)){case 91:case 93:case 46:case 34:case 39:return e;case 95:case 36:case 45:return"i";case 9:case 10:case 13:case 160:case 65279:case 8232:case 8233:return"w"}return"i"}function $w(e){const t=e.trim();return e.charAt(0)==="0"&&isNaN(parseInt(e))?!1:Fw(t)?Vw(t):"*"+t}function Uw(e){const t=[];let n=-1,i=0,r=0,s,a,o,l,c,d,u;const p=[];p[0]=()=>{a===void 0?a=o:a+=o},p[1]=()=>{a!==void 0&&(t.push(a),a=void 0)},p[2]=()=>{p[0](),r++},p[3]=()=>
26{if(r>0)r--,i=4,p[0]();else{if(r=0,a===void 0||(a=$w(a),a===!1))return!1;p[1]()}};function h(){const m=e[n+1];if(i===5&&m==="'"||i===6&&m==='"')return n++,o="\\"+m,p[0](),!0}for(;i!==null;)if(n++,s=e[n],!(s==="\\"&&h())){if(l=Bw(s),u=Wn[i],c=u[l]||u.l||8,c===8||(i=c[0],c[1]!==void 0&&(d=p[c[1]],d&&(o=s,d()===!1))))return;if(i===7)return t}}const Kc=new Map;function Hw(e,t){return je(e)?e[t]:null}function zw(e,t){if(!je(e))return null;let n=Kc.get(t);if(n||(n=Uw(t),n&&Kc.set(t,n)),!n)return null;const i=n.length;let r=e,s=0;for(;s<i;){const a=r[n[s]];if(a===void 0||lt(r))return null;r=a,s++}return r}const Kw="10.0.5",Gr=-1,fr="en-US",Gc="",jc=e=>`${e.charAt(0).toLocaleUpperCase()}${e.substr(1)}`;function Gw(){return{upper:(e,t)=>t==="text"&&Fe(e)?e.toUpperCase():t==="vnode"&&je(e)&&"__v_isVNode"in e?e.children.toUpperCase():e,lower:(e,t)=>t==="text"&&Fe(e)?e.toLowerCase():t==="vnode"&&je(e)&&"__v_isVNode"in e?e.children.toLowerCase():e,capitalize:(e,t)=>t==="text"&&Fe(e)?jc(e):t==="vnode"&&je(e)&&"__v_isVNode"in e?jc(e.children):e}}let cp;function jw(e){cp=e}let dp;function Yw(e){dp=e}let up;function Ww(e){up=e}let hp=null;const Qw=e=>{hp=e},Zw=()=>hp;let pp=null;const Yc=e=>{pp=e},qw=()=>pp;let Wc=0;function Jw(e={}){const t=lt(e.onWarn)?e.onWarn:H_,n=Fe(e.version)?e.version:Kw,i=Fe(e.locale)||lt(e.locale)?e.locale:fr,r=lt(i)?fr:i,s=Ct(e.fallbackLocale)||Ye(e.fallbackLocale)||Fe(e.fallbackLocale)||e.fallbackLocale===!1?e.fallbackLocale:r,a=Ye(e.messages)?e.messages:Ea(r),o=Ye(e.datetimeFormats)?e.datetimeFormats:Ea(r),l=Ye(e.numberFormats)?e.numberFormats:Ea(r),c=Ot(ut(),e.modifiers,Gw()),d=e.pluralRules||ut(),u=lt(e.missing)?e.missing:null,p=bt(e.missingWarn)||ur(e.missingWarn)?e.missingWarn:!0,h=bt(e.fallbackWarn)||ur(e.fallbackWarn)?e.fallbackWarn:!0,m=!!e.fallbackFormat,v=!!e.unresolving,_=lt(e.postTranslation)?e.postTranslation:null,b=Ye(e.processor)?e.processor:null,w=bt(e.warnHtmlMessage)?e.warnHtmlMessage:!0,C=!!e.escapeParameter,O=lt(e.messageCompiler)?e.messageCompiler:cp,T=lt(e.messageResolver)?e.messageResolver:dp||Hw,E=lt(e.localeFallbacker)?e.localeFallbacker:up||Nw,y=je(e.fallbackContext)?e.fallbackContext:void 0,P=e,A=je(P.__datetimeFormatters)?P.__datetimeFormatters:new Map,I=je(P.__numberFormatters)?P.__numberFormatters:new Map,L=je(P.__meta)?P.__meta:{};Wc++;const D={version:n,cid:Wc,locale:i,fallbackLocale:s,messages:a,modifiers:c,pluralRules:d,missing:u,missingWarn:p,fallbackWarn:h,fallbackFormat:m,unresolving:v,postTranslation:_,processor:b,warnHtmlMessage:w,escapeParameter:C,messageCompiler:O,messageResolver:T,localeFallbacker:E,fallbackContext:y,onWarn:t,__meta:L};return D.datetimeFormats=o,D.numberFormats=l,D.__datetimeFormatters=A,D.__numberFormatters=I,__INTLIFY_PROD_DEVTOOLS__&&Aw(D,n,L),D}const Ea=e=>({[e]:ut()});function ll(e,t,n,i,r){const{missing:s,onWarn:a}=e;if(s!==null){const o=s(e,n,t,r);return Fe(o)?o:t}else return t}function zs(e,t,n){const i=e;i.__localeChainCache=new Map,e.localeFallbacker(e,n,t)}function Xw(e,t){return e===t?!1:e.split("-")[0]===t.split("-")[0]}function eE(e,t){const n=t.indexOf(e);if(n===-1)return!1;for(let i=n+1;i<t.length;i++)if(Xw(e,t[i]))return!0;return!1}function Qc(e,...t){const{datetimeFormats:n,unresolving:i,fallbackLocale:r,onWarn:s,localeFallbacker:a}=e,{__datetimeFormatters:o}=e,[l,c,d,u]=po(...t),p=bt(d.missingWarn)?d.missingWarn:e.missingWarn;bt(d.fallbackWarn)?d.fallbackWarn:e.fallbackWarn;const h=!!d.part,m=ol(e,d),v=a(e,r,m);if(!Fe(l)||l==="")return new Intl.DateTimeFormat(m,u).format(c);let _={},b,w=null;const C="datetime format";for(let E=0;E<v.length&&(b=v[E],_=n[b]||{},w=_[l],!Ye(w));E++)ll(e,l,b,p,C);if(!Ye(w)||!Fe(b))return i?Gr:l;let O=`${b}__${l}`;Mr(u)||(O=`${O}__${JSON.stringify(u)}`);let T=o.get(O);return T||(T=new Intl.DateTimeFormat(b,Ot({},w,u)),o.set(O,T)),h?T.formatToParts(c):T.format(c)}const fp=["localeMatcher","weekday","era","year","month","day","hour","minute","second","timeZoneName","formatMatcher","hour12","timeZone","dateStyle","timeStyle","calendar","dayPeriod","numberingSystem","hourCycle","fractionalSecondDigits"];function po(...e){const[t,n,i,r]=e,s=ut();let a=ut(),o;if(Fe(t)){const l=t.match(/(\d{4}-\d{2}-\d{2})(T|\s)?(.*)/);if(!l)throw Tn(In.INVALID_ISO_DATE_ARGUMENT);const c=l[3]?l[3].trim().startsWith("T")?`${l[1].trim()}${l[3].trim()}`:`${l[1].trim()}T${l[3].trim()}`:l[1].trim();o=new Date(c);try{o.toISOString()}catch{throw Tn(In.INVALID_ISO_DATE_ARGUMENT)}}else if(M_(t)){if(isNaN(t.getTime()))throw Tn(In.INVALID_DATE_ARGUMENT);o=t}else if(Pt(t))o=t;else throw Tn(In.INVALID_ARGUMENT);
26return Fe(n)?s.key=n:Ye(n)&&Object.keys(n).forEach(l=>{fp.includes(l)?a[l]=n[l]:s[l]=n[l]}),Fe(i)?s.locale=i:Ye(i)&&(a=i),Ye(r)&&(a=r),[s.key||"",o,s,a]}function Zc(e,t,n){const i=e;for(const r in n){const s=`${t}__${r}`;i.__datetimeFormatters.has(s)&&i.__datetimeFormatters.delete(s)}}function qc(e,...t){const{numberFormats:n,unresolving:i,fallbackLocale:r,onWarn:s,localeFallbacker:a}=e,{__numberFormatters:o}=e,[l,c,d,u]=fo(...t),p=bt(d.missingWarn)?d.missingWarn:e.missingWarn;bt(d.fallbackWarn)?d.fallbackWarn:e.fallbackWarn;const h=!!d.part,m=ol(e,d),v=a(e,r,m);if(!Fe(l)||l==="")return new Intl.NumberFormat(m,u).format(c);let _={},b,w=null;const C="number format";for(let E=0;E<v.length&&(b=v[E],_=n[b]||{},w=_[l],!Ye(w));E++)ll(e,l,b,p,C);if(!Ye(w)||!Fe(b))return i?Gr:l;let O=`${b}__${l}`;Mr(u)||(O=`${O}__${JSON.stringify(u)}`);let T=o.get(O);return T||(T=new Intl.NumberFormat(b,Ot({},w,u)),o.set(O,T)),h?T.formatToParts(c):T.format(c)}const mp=["localeMatcher","style","currency","currencyDisplay","currencySign","useGrouping","minimumIntegerDigits","minimumFractionDigits","maximumFractionDigits","minimumSignificantDigits","maximumSignificantDigits","compactDisplay","notation","signDisplay","unit","unitDisplay","roundingMode","roundingPriority","roundingIncrement","trailingZeroDisplay"];function fo(...e){const[t,n,i,r]=e,s=ut();let a=ut();if(!Pt(t))throw Tn(In.INVALID_ARGUMENT);const o=t;return Fe(n)?s.key=n:Ye(n)&&Object.keys(n).forEach(l=>{mp.includes(l)?a[l]=n[l]:s[l]=n[l]}),Fe(i)?s.locale=i:Ye(i)&&(a=i),Ye(r)&&(a=r),[s.key||"",o,s,a]}function Jc(e,t,n){const i=e;for(const r in n){const s=`${t}__${r}`;i.__numberFormatters.has(s)&&i.__numberFormatters.delete(s)}}const tE=e=>e,nE=e=>"",sE="text",iE=e=>e.length===0?"":el(e),rE=U_;function Xc(e,t){return e=Math.abs(e),t===2?e?e>1?1:0:1:e?Math.min(e,2):0}function aE(e){const t=Pt(e.pluralIndex)?e.pluralIndex:-1;return e.named&&(Pt(e.named.count)||Pt(e.named.n))?Pt(e.named.count)?e.named.count:Pt(e.named.n)?e.named.n:t:t}function oE(e,t){t.count||(t.count=e),t.n||(t.n=e)}function lE(e={}){const t=e.locale,n=aE(e),i=je(e.pluralRules)&&Fe(t)&&lt(e.pluralRules[t])?e.pluralRules[t]:Xc,r=je(e.pluralRules)&&Fe(t)&&lt(e.pluralRules[t])?Xc:void 0,s=b=>b[i(n,b.length,r)],a=e.list||[],o=b=>a[b],l=e.named||ut();Pt(e.pluralIndex)&&oE(n,l);const c=b=>l[b];function d(b,w){const C=lt(e.messages)?e.messages(b,!!w):je(e.messages)?e.messages[b]:!1;return C||(e.parent?e.parent.message(b):nE)}const u=b=>e.modifiers?e.modifiers[b]:tE,p=Ye(e.processor)&&lt(e.processor.normalize)?e.processor.normalize:iE,h=Ye(e.processor)&&lt(e.processor.interpolate)?e.processor.interpolate:rE,m=Ye(e.processor)&&Fe(e.processor.type)?e.processor.type:sE,_={list:o,named:c,plural:s,linked:(b,...w)=>{const[C,O]=w;let T="text",E="";w.length===1?je(C)?(E=C.modifier||E,T=C.type||T):Fe(C)&&(E=C||E):w.length===2&&(Fe(C)&&(E=C||E),Fe(O)&&(T=O||T));const y=d(b,!0)(_),P=T==="vnode"&&Ct(y)&&E?y[0]:y;return E?u(E)(P,T):P},message:d,type:m,interpolate:h,normalize:p,values:Ot(ut(),a,l)};return _}const ed=()=>"",qt=e=>lt(e);function td(e,...t){const{fallbackFormat:n,postTranslation:i,unresolving:r,messageCompiler:s,fallbackLocale:a,messages:o}=e,[l,c]=mo(...t),d=bt(c.missingWarn)?c.missingWarn:e.missingWarn,u=bt(c.fallbackWarn)?c.fallbackWarn:e.fallbackWarn,p=bt(c.escapeParameter)?c.escapeParameter:e.escapeParameter,h=!!c.resolvedMessage,m=Fe(c.default)||bt(c.default)?bt(c.default)?s?l:()=>l:c.default:n?s?l:()=>l:null,v=n||m!=null&&(Fe(m)||lt(m)),_=ol(e,c);p&&cE(c);let[b,w,C]=h?[l,_,o[_]||ut()]:gp(e,l,_,a,u,d),O=b,T=l;if(!h&&!(Fe(O)||Ls(O)||qt(O))&&v&&(O=m,T=O),!h&&(!(Fe(O)||Ls(O)||qt(O))||!Fe(w)))return r?Gr:l;let E=!1;const y=()=>{E=!0},P=qt(O)?O:yp(e,l,w,O,T,y);if(E)return O;const A=hE(e,w,C,c),I=lE(A),L=dE(e,P,I),D=i?i(L,l):L;if(__INTLIFY_PROD_DEVTOOLS__){const z={timestamp:Date.now(),key:Fe(l)?l:qt(O)?O.key:"",locale:w||(qt(O)?O.locale:""),format:Fe(O)?O:qt(O)?O.source:"",message:D};z.meta=Ot({},e.__meta,Zw()||{}),kw(z)}return D}function cE(e){Ct(e.list)?e.list=e.list.map(t=>
26Fe(t)?Oc(t):t):je(e.named)&&Object.keys(e.named).forEach(t=>{Fe(e.named[t])&&(e.named[t]=Oc(e.named[t]))})}function gp(e,t,n,i,r,s){const{messages:a,onWarn:o,messageResolver:l,localeFallbacker:c}=e,d=c(e,i,n);let u=ut(),p,h=null;const m="translate";for(let v=0;v<d.length&&(p=d[v],u=a[p]||ut(),(h=l(u,t))===null&&(h=u[t]),!(Fe(h)||Ls(h)||qt(h)));v++)if(!eE(p,d)){const _=ll(e,t,p,s,m);_!==t&&(h=_)}return[h,p,u]}function yp(e,t,n,i,r,s){const{messageCompiler:a,warnHtmlMessage:o}=e;if(qt(i)){const c=i;return c.locale=c.locale||n,c.key=c.key||t,c}if(a==null){const c=()=>i;return c.locale=n,c.key=t,c}const l=a(i,uE(e,n,r,i,o,s));return l.locale=n,l.key=t,l.source=i,l}function dE(e,t,n){return t(n)}function mo(...e){const[t,n,i]=e,r=ut();if(!Fe(t)&&!Pt(t)&&!qt(t)&&!Ls(t))throw Tn(In.INVALID_ARGUMENT);const s=Pt(t)?String(t):(qt(t),t);return Pt(n)?r.plural=n:Fe(n)?r.default=n:Ye(n)&&!Mr(n)?r.named=n:Ct(n)&&(r.list=n),Pt(i)?r.plural=i:Fe(i)?r.default=i:Ye(i)&&Ot(r,i),[s,r]}function uE(e,t,n,i,r,s){return{locale:t,key:n,warnHtmlMessage:r,onError:a=>{throw s&&s(a),a},onCacheKey:a=>D_(t,n,a)}}function hE(e,t,n,i){const{modifiers:r,pluralRules:s,messageResolver:a,fallbackLocale:o,fallbackWarn:l,missingWarn:c,fallbackContext:d}=e,p={locale:t,modifiers:r,pluralRules:s,messages:(h,m)=>{let v=a(n,h);if(v==null&&(d||m)){const[,,_]=gp(d||e,h,t,o,l,c);v=a(_,h)}if(Fe(v)||Ls(v)){let _=!1;const w=yp(e,h,t,v,h,()=>{_=!0});return _?ed:w}else return qt(v)?v:ed}};return e.processor&&(p.processor=e.processor),i.list&&(p.list=i.list),i.named&&(p.named=i.named),Pt(i.plural)&&(p.pluralIndex=i.plural),p}cw();/*!
27  * vue-i18n v10.0.5
28  * (c) 2024 kazuya kawaguchi
29  * Released under the MIT License.
30  */const pE="10.0.5";function fE(){typeof __INTLIFY_PROD_DEVTOOLS__!="boolean"&&(Jo().__INTLIFY_PROD_DEVTOOLS__=!1)}const Xt={UNEXPECTED_RETURN_TYPE:Lw,INVALID_ARGUMENT:25,MUST_BE_CALL_SETUP_TOP:26,NOT_INSTALLED:27,REQUIRED_VALUE:28,INVALID_VALUE:29,CANNOT_SETUP_VUE_DEVTOOLS_PLUGIN:30,NOT_INSTALLED_WITH_PROVIDE:31,UNEXPECTED_ERROR:32,NOT_COMPATIBLE_LEGACY_VUE_I18N:33,NOT_AVAILABLE_COMPOSITION_IN_LEGACY:34};function on(e,...t){return Kr(e,null,void 0)}const go=Gn("__translateVNode"),yo=Gn("__datetimeParts"),bo=Gn("__numberParts"),mE=Gn("__setPluralRules"),gE=Gn("__injectWithOption"),vo=Gn("__dispose");function di(e){if(!je(e))return e;for(const t in e)if(sn(e,t))if(!t.includes("."))je(e[t])&&di(e[t]);else{const n=t.split("."),i=n.length-1;let r=e,s=!1;for(let a=0;a<i;a++){if(n[a]in r||(r[n[a]]=ut()),!je(r[n[a]])){s=!0;break}r=r[n[a]]}s||(r[n[i]]=e[t],delete e[t]),je(r[n[i]])&&di(r[n[i]])}return e}function bp(e,t){const{messages:n,__i18n:i,messageResolver:r,flatJson:s}=t,a=Ye(n)?n:Ct(i)?ut():{[e]:ut()};if(Ct(i)&&i.forEach(o=>{if("locale"in o&&"resource"in o){const{locale:l,resource:c}=o;l?(a[l]=a[l]||ut(),ls(c,a[l])):ls(c,a)}else Fe(o)&&ls(JSON.parse(o),a)}),r==null&&s)for(const o in a)sn(a,o)&&di(a[o]);return a}function vp(e){return e.type}function yE(e,t,n){let i=je(t.messages)?t.messages:ut();"__i18nGlobal"in n&&(i=bp(e.locale.value,{messages:i,__i18n:n.__i18nGlobal}));const r=Object.keys(i);r.length&&r.forEach(s=>{e.mergeLocaleMessage(s,i[s])});{if(je(t.datetimeFormats)){const s=Object.keys(t.datetimeFormats);s.length&&s.forEach(a=>{e.mergeDateTimeFormat(a,t.datetimeFormats[a])})}if(je(t.numberFormats)){const s=Object.keys(t.numberFormats);s.length&&s.forEach(a=>{e.mergeNumberFormat(a,t.numberFormats[a])})}}}function nd(e){return de(Gg,null,e,0)}const sd="__INTLIFY_META__",id=()=>[],bE=()=>!1;let rd=0;function ad(e){return(t,n,i,r)=>e(n,i,ln()||void 0,r)}const vE=()=>{const e=ln();let t=null;return e&&(t=vp(e)[sd])?{[sd]:t}:null};function _p(e={}){const{__root:t,__injectWithOption:n}=e,i=t===void 0,r=e.flatJson,s=dr?Re:Kn;let a=bt(e.inheritLocale)?e.inheritLocale:!0;const o=s(t&&a?t.locale.value:Fe(e.locale)?e.locale:fr),l=s(t&&a?t.fallbackLocale.value:Fe(e.fallbackLocale)||Ct(e.fallbackLocale)||Ye(e.fallbackLocale)||e.fallbackLocale===!1?e.fallbackLocale:o.value),c=s(bp(o.value,e)),d=s(Ye(e.datetimeFormats)?e.datetimeFormats:{[o.value]:{}}),u=s(Ye(e.numberFormats)?e.numberFormats:{[o.value]:{}});let p=t?t.missingWarn:bt(e.missingWarn)||ur(e.missingWarn)?e.missingWarn:!0,h=t?t.fallbackWarn:bt(e.fallbackWarn)||ur(e.fallbackWarn)?e.fallbackWarn:!0,m=t?t.fallbackRoot:bt(e.fallbackRoot)?e.fallbackRoot:!0,v=!!e.fallbackFormat,_=lt(e.missing)?e.missing:null,b=lt(e.missing)?ad(e.missing):null,w=lt(e.postTranslation)?e.postTranslation:null,C=t?t.warnHtmlMessage:bt(e.warnHtmlMessage)?e.warnHtmlMessage:!0,O=!!e.escapeParameter;const T=t?t.modifiers:Ye(e.modifiers)?e.modifiers:{};let E=e.pluralRules||t&&t.pluralRules,y;y=(()=>{i&&Yc(null);const pe={version:pE,locale:o.value,fallbackLocale:l.value,messages:c.value,modifiers:T,pluralRules:E,missing:b===null?void 0:b,missingWarn:p,fallbackWarn:h,fallbackFormat:v,unresolving:!0,postTranslation:w===null?void 0:w,warnHtmlMessage:C,escapeParameter:O,messageResolver:e.messageResolver,messageCompiler:e.messageCompiler,__meta:{framework:"vue"}};pe.datetimeFormats=d.value,pe.numberFormats=u.value,pe.__datetimeFormatters=Ye(y)?y.__datetimeFormatters:void 0,pe.__numberFormatters=Ye(y)?y.__numberFormatters:void 0;const Pe=Jw(pe);return i&&Yc(Pe),Pe})(),zs(y,o.value,l.value);function A(){return[o.value,l.value,c.value,d.value,u.value]}const I=ee({get:()=>o.value,set:pe=>{o.value=pe,y.locale=o.value}}),L=ee({get:()=>l.value,set:pe=>{l.value=pe,y.fallbackLocale=l.value,zs(y,o.value,pe)}}),D=ee(()=>c.value),z=ee(()=>d.value),G=ee(()=>u.value);function ne(){return lt(w)?w:null}function W(pe){w=pe,y.postTranslation=pe}function ue(){return _}function H(pe){pe!==null&&(b=ad(pe)),_=pe,y.missing=b}const x=(pe,Pe,et,wt,qn,Di)=>{A();let gs;try{__INTLIFY_PROD_DEVTOOLS__,i||(y.fallbackContext=t?qw():void 0),gs=pe(y)}finally{__INTLIFY_PROD_DEVTOOLS__,i||(y.fallbackContext=void 0)}if(et!=="translate exists"&&Pt(gs)&&gs===Gr||et==="translate exists"&&!gs){const[Fg,SJ]=Pe();return t&&m?wt(t):qn(Fg)}else{if(Di(gs))return gs;throw on(Xt.UNEXPECTED_RETURN_TYPE)}};function V(...pe){return x(Pe=>Reflect.apply(td,null,[Pe,...pe]),()=>mo(...pe),"translate",Pe=>Reflect.apply(Pe.t,Pe,[...pe]),Pe=>Pe,Pe=>Fe(Pe))}function te(...pe){const[Pe,et,wt]=pe;if(wt&&!je(wt))throw on(Xt.INVALID_ARGUMENT);return V(Pe,et,Ot({resolvedMessage:!0},wt||{}))}function fe(...pe){return x(Pe=>Reflect.apply(Qc,null,[Pe,...pe]),()=>po(...pe),"datetime format",Pe=>Reflect.apply(Pe.d,Pe,[...pe]),()=>Gc,Pe=>Fe(Pe))}function re(...pe){return x(Pe=>Reflect.apply(qc,null,[Pe,...pe]),()=>fo(...pe),"number format",Pe=>Reflect.apply(Pe.n,Pe,[...pe]),()=>Gc,Pe=>Fe(Pe))}function be(pe){return pe.map(Pe=>Fe(Pe)||Pt(Pe)||bt(Pe)?nd(String(Pe)):Pe)}const oe={normalize:be,interpolate:pe=>pe,type:"vnode"};function K(...pe){return x(Pe=>{let et;const wt=Pe;try{wt.processor=oe,et=Reflect.apply(td,null,[wt,...pe])}finally{wt.processor=null}return et},()=>mo(...pe),"translate",Pe=>Pe[go](...pe),Pe=>[nd(Pe)],Pe=>Ct(Pe))}function Z(...pe){return x(Pe=>Reflect.apply(qc,null,[Pe,...pe]),()=>fo(...pe),"number format",Pe=>Pe[bo](...pe),id,Pe=>Fe(Pe)||Ct(Pe))}function me(...pe){return x(Pe=>Reflect.apply(Qc,null,[Pe,...pe]),()=>po(...pe),"datetime format",Pe=>Pe[yo](...pe),id,Pe=>Fe(Pe)||Ct(Pe))}function q(pe){E=pe,y.pluralRules=E}function ae(pe,Pe){return x(()=>
30{if(!pe)return!1;const et=Fe(Pe)?Pe:o.value,wt=X(et),qn=y.messageResolver(wt,pe);return Ls(qn)||qt(qn)||Fe(qn)},()=>[pe],"translate exists",et=>Reflect.apply(et.te,et,[pe,Pe]),bE,et=>bt(et))}function ge(pe){let Pe=null;const et=lp(y,l.value,o.value);for(let wt=0;wt<et.length;wt++){const qn=c.value[et[wt]]||{},Di=y.messageResolver(qn,pe);if(Di!=null){Pe=Di;break}}return Pe}function we(pe){const Pe=ge(pe);return Pe??(t?t.tm(pe)||{}:{})}function X(pe){return c.value[pe]||{}}function B(pe,Pe){if(r){const et={[pe]:Pe};for(const wt in et)sn(et,wt)&&di(et[wt]);Pe=et[pe]}c.value[pe]=Pe,y.messages=c.value}function Se(pe,Pe){c.value[pe]=c.value[pe]||{};const et={[pe]:Pe};if(r)for(const wt in et)sn(et,wt)&&di(et[wt]);Pe=et[pe],ls(Pe,c.value[pe]),y.messages=c.value}function Ce(pe){return d.value[pe]||{}}function U(pe,Pe){d.value[pe]=Pe,y.datetimeFormats=d.value,Zc(y,pe,Pe)}function j(pe,Pe){d.value[pe]=Ot(d.value[pe]||{},Pe),y.datetimeFormats=d.value,Zc(y,pe,Pe)}function ce(pe){return u.value[pe]||{}}function Ie(pe,Pe){u.value[pe]=Pe,y.numberFormats=u.value,Jc(y,pe,Pe)}function De(pe,Pe){u.value[pe]=Ot(u.value[pe]||{},Pe),y.numberFormats=u.value,Jc(y,pe,Pe)}rd++,t&&dr&&(We(t.locale,pe=>{a&&(o.value=pe,y.locale=pe,zs(y,o.value,l.value))}),We(t.fallbackLocale,pe=>{a&&(l.value=pe,y.fallbackLocale=pe,zs(y,o.value,l.value))}));const Te={id:rd,locale:I,fallbackLocale:L,get inheritLocale(){return a},set inheritLocale(pe){a=pe,pe&&t&&(o.value=t.locale.value,l.value=t.fallbackLocale.value,zs(y,o.value,l.value))},get availableLocales(){return Object.keys(c.value).sort()},messages:D,get modifiers(){return T},get pluralRules(){return E||{}},get isGlobal(){return i},get missingWarn(){return p},set missingWarn(pe){p=pe,y.missingWarn=p},get fallbackWarn(){return h},set fallbackWarn(pe){h=pe,y.fallbackWarn=h},get fallbackRoot(){return m},set fallbackRoot(pe){m=pe},get fallbackFormat(){return v},set fallbackFormat(pe){v=pe,y.fallbackFormat=v},get warnHtmlMessage(){return C},set warnHtmlMessage(pe){C=pe,y.warnHtmlMessage=pe},get escapeParameter(){return O},set escapeParameter(pe){O=pe,y.escapeParameter=pe},t:V,getLocaleMessage:X,setLocaleMessage:B,mergeLocaleMessage:Se,getPostTranslationHandler:ne,setPostTranslationHandler:W,getMissingHandler:ue,setMissingHandler:H,[mE]:q};return Te.datetimeFormats=z,Te.numberFormats=G,Te.rt=te,Te.te=ae,Te.tm=we,Te.d=fe,Te.n=re,Te.getDateTimeFormat=Ce,Te.setDateTimeFormat=U,Te.mergeDateTimeFormat=j,Te.getNumberFormat=ce,Te.setNumberFormat=Ie,Te.mergeNumberFormat=De,Te[gE]=n,Te[go]=K,Te[yo]=me,Te[bo]=Z,Te}const cl={tag:{type:[String,Object]},locale:{type:String},scope:{type:String,validator:e=>e==="parent"||e==="global",default:"parent"},i18n:{type:Object}};function _E({slots:e},t){return t.length===1&&t[0]==="default"?(e.default?e.default():[]).reduce((i,r)=>[...i,...r.type===J?r.children:[r]],[]):t.reduce((n,i)=>{const r=e[i];return r&&(n[i]=r()),n},ut())}function wp(){return J}const wE=Ge({name:"i18n-t",props:Ot({keypath:{type:String,required:!0},plural:{type:[Number,String],validator:e=>Pt(e)||!isNaN(e)}},cl),setup(e,t){const{slots:n,attrs:i}=t,r=e.i18n||rt({useScope:e.scope,__useComponent:!0});return()=>{const s=Object.keys(n).filter(u=>u!=="_"),a=ut();e.locale&&(a.locale=e.locale),e.plural!==void 0&&(a.plural=Fe(e.plural)?+e.plural:e.plural);const o=_E(t,s),l=r[go](e.keypath,o,a),c=Ot(ut(),i),d=Fe(e.tag)||je(e.tag)?e.tag:wp();return gn(d,c,l)}}}),od=wE;function EE(e){return Ct(e)&&!Fe(e[0])}function Ep(e,t,n,i){const{slots:r,attrs:s}=t;return()=>{const a={part:!0};let o=ut();e.locale&&(a.locale=e.locale),Fe(e.format)?a.key=e.format:je(e.format)&&(Fe(e.format.key)&&(a.key=e.format.key),o=Object.keys(e.format).reduce((p,h)=>n.includes(h)?Ot(ut(),p,{[h]:e.format[h]}):p,ut()));const l=i(e.value,a,o);let c=[a.key];Ct(l)?c=l.map((p,h)=>{const m=r[p.type],v=m?m({[p.type]:p.value,index:h,parts:l}):[p.value];return EE(v)&&(v[0].key=`${p.type}-${h}`),v}):Fe(l)&&(c=[l]);const d=Ot(ut(),s),u=Fe(e.tag)||je(e.tag)?e.tag:wp();return gn(u,d,c)}}const SE=Ge({name:"i18n-n",props:Ot({value:{type:Number,required:!0},format:{type:[String,Object]}},cl),setup(e,t){const n=e.i18n||rt({useScope:e.scope,__useComponent:!0});return Ep(e,t,mp,(...i)=>n[bo](...i))}}),ld=SE,CE=Ge({name:"i18n-d",props:Ot({value:{type:[Number,Date],required:!0},format:{type:[String,Object]}},cl),setup(e,t){const n=e.i18n||rt({useScope:e.scope,__useComponent:!0});return Ep(e,t,fp,(...i)=>n[yo](...i))}}),cd=CE;function IE(e,t){const n=e;if(e.mode==="composition")return n.__getInstance(t)||e.global;{const i=n.__getInstance(t);return i!=null?i.__composer:e.global.__composer}}function TE(e){const t=a=>{const{instance:o,value:l}=a;if(!o||!o.$)throw on(Xt.UNEXPECTED_ERROR);const c=IE(e,o.$),d=dd(l);return[Reflect.apply(c.t,c,[...ud(d)]),c]};return{created:(a,o)=>{const[l,c]=t(o);dr&&e.global===c&&(a.__i18nWatcher=We(c.locale,()=>{o.instance&&o.instance.$forceUpdate()})),a.__composer=c,a.textContent=l},unmounted:a=>{dr&&a.__i18nWatcher&&(a.__i18nWatcher(),a.__i18nWatcher=void 0,delete a.__i18nWatcher),a.__composer&&(a.__composer=void 0,delete a.__composer)},beforeUpdate:(a,{value:o})=>{if(a.__composer){const l=a.__composer,c=dd(o);a.textContent=Reflect.apply(l.t,l,[...ud(c)])}},getSSRProps:a=>{const[o]=t(a);return{textContent:o}}}}function dd(e){if(Fe(e))return{path:e};if(Ye(e)){if(!("path"in e))throw on(Xt.REQUIRED_VALUE,"path");return e}else throw on(Xt.INVALID_VALUE)}function ud(e){const{path:t,locale:n,args:i,choice:r,plural:s}=e,a={},o=i||{};return Fe(n)&&(a.locale=n),Pt(r)&&(a.plural=r),Pt(s)&&(a.plural=s),[t,o,a]}function PE(e,t,...n){const i=Ye(n[0])?n[0]:{};(bt(i.globalInstall)?i.globalInstall:!0)&&([od.name,"I18nT"].forEach(s=>e.component(s,od)),[ld.name,"I18nN"].forEach(s=>e.component(s,ld)),[cd.name,"I18nD"].forEach(s=>e.component(s,cd))),e.directive("t",TE(t))}const OE=Gn("global-vue-i18n");function AE(e={},t){const n=bt(e.globalInjection)?e.globalInjection:!0,i=new Map,[r,s]=kE(e),a=Gn("");function o(u){return i.get(u)||null}function l(u,p){i.set(u,p)}function c(u){i.delete(u)}const d={get mode(){return"composition"}
30,async install(u,...p){if(u.__VUE_I18N_SYMBOL__=a,u.provide(u.__VUE_I18N_SYMBOL__,d),Ye(p[0])){const v=p[0];d.__composerExtend=v.__composerExtend,d.__vueI18nExtend=v.__vueI18nExtend}let h=null;n&&(h=VE(u,d.global)),PE(u,d,...p);const m=u.unmount;u.unmount=()=>{h&&h(),d.dispose(),m()}},get global(){return s},dispose(){r.stop()},__instances:i,__getInstance:o,__setInstance:l,__deleteInstance:c};return d}function rt(e={}){const t=ln();if(t==null)throw on(Xt.MUST_BE_CALL_SETUP_TOP);if(!t.isCE&&t.appContext.app!=null&&!t.appContext.app.__VUE_I18N_SYMBOL__)throw on(Xt.NOT_INSTALLED);const n=RE(t),i=NE(n),r=vp(t),s=LE(e,r);if(s==="global")return yE(i,e,r),i;if(s==="parent"){let l=DE(n,t,e.__useComponent);return l==null&&(l=i),l}const a=n;let o=a.__getInstance(t);if(o==null){const l=Ot({},e);"__i18n"in r&&(l.__i18n=r.__i18n),i&&(l.__root=i),o=_p(l),a.__composerExtend&&(o[vo]=a.__composerExtend(o)),ME(a,t,o),a.__setInstance(t,o)}return o}function kE(e,t,n){const i=Si(),r=i.run(()=>_p(e));if(r==null)throw on(Xt.UNEXPECTED_ERROR);return[i,r]}function RE(e){const t=Ft(e.isCE?OE:e.appContext.app.__VUE_I18N_SYMBOL__);if(!t)throw on(e.isCE?Xt.NOT_INSTALLED_WITH_PROVIDE:Xt.UNEXPECTED_ERROR);return t}function LE(e,t){return Mr(e)?"__i18n"in t?"local":"global":e.useScope?e.useScope:"local"}function NE(e){return e.mode==="composition"?e.global:e.global.__composer}function DE(e,t,n=!1){let i=null;const r=t.root;let s=xE(t,n);for(;s!=null;){const a=e;if(e.mode==="composition"&&(i=a.__getInstance(s)),i!=null||r===s)break;s=s.parent}return i}function xE(e,t=!1){return e==null?null:t&&e.vnode.ctx||e.parent}function ME(e,t,n){vt(()=>{},t),cn(()=>{const i=n;e.__deleteInstance(t);const r=i[vo];r&&(r(),delete i[vo])},t)}const FE=["locale","fallbackLocale","availableLocales"],hd=["t","rt","d","n","tm","te"];function VE(e,t){const n=Object.create(null);return FE.forEach(r=>{const s=Object.getOwnPropertyDescriptor(t,r);if(!s)throw on(Xt.UNEXPECTED_ERROR);const a=Jt(s.value)?{get(){return s.value.value},set(o){s.value.value=o}}:{get(){return s.get&&s.get()}};Object.defineProperty(n,r,a)}),e.config.globalProperties.$i18n=n,hd.forEach(r=>{const s=Object.getOwnPropertyDescriptor(t,r);if(!s||!s.value)throw on(Xt.UNEXPECTED_ERROR);Object.defineProperty(e.config.globalProperties,`$${r}`,s)}),()=>{delete e.config.globalProperties.$i18n,hd.forEach(r=>{delete e.config.globalProperties[`$${r}`]})}}fE();jw(Pw);Yw(zw);Ww(lp);if(__INTLIFY_PROD_DEVTOOLS__){const e=Jo();e.__INTLIFY__=!0,Ow(e.__INTLIFY_DEVTOOLS_GLOBAL_HOOK__)}function BE(){return jt(ks)}const $E=_t({name:"i18n:plugin:switch-locale-path-ssr",dependsOn:["i18n:plugin"],setup(e){if(e.$config.public.i18n.experimental.switchLocalePathLinkSSR!==!0)return;const t=BE(),n=new RegExp([`<!--${Ac}-\\[(\\w+)\\]-->`,".+?",`<!--/${Ac}-->`].join(""),"g");e.hook("app:rendered",i=>{var r;((r=i.renderResult)==null?void 0:r.html)!=null&&(i.renderResult.html=i.renderResult.html.replaceAll(n,(s,a)=>s.replace(/href="([^"]+)"/,`href="${encodeURI(t(a??""))}"`)))})}});function UE(e,{extendComposer:t,extendComposerInstance:n}){const i=Si(),r=e.install.bind(e);return e.install=(s,...a)=>{const o=Object.assign({},a[0]);o.inject??(o.inject=!0),o.__composerExtend=c=>(n(c,Ss(e)),()=>{}),e.mode==="legacy"&&(o.__vueI18nExtend=c=>(n(c,Ss(c)),()=>{})),Reflect.apply(r,e,[s,o]);const l=Ss(e);if(i.run(()=>{t(l),e.mode==="legacy"&&qh(e.global)&&n(e.global,Ss(e.global))}),e.mode==="composition"&&s.config.globalProperties.$i18n!=null&&n(s.config.globalProperties.$i18n,l),o.inject){const c=il(e);s.mixin({methods:{$getRouteBaseName:jt(As,c),$resolveRoute:jt(Hr,c),$localePath:jt(Ur,c),$localeRoute:jt(nl,c),$localeLocation:jt(b0,c),$switchLocalePath:jt(ks,c),$localeHead:jt(ep,c)}})}if(s.unmount){const c=s.unmount.bind(s);s.unmount=()=>{i.stop(),c()}}},i}const HE=_t({name:"i18n:plugin",parallel:G_,async setup(e){let t,n;const i=On(),{vueApp:r}=e,s=e,a=V0(s);F0(s,a);const o={...s.$config.public.i18n,defaultLocale:a};o.baseUrl=R0();const l=Oi(),c=([t,n]=fn(()=>t0(K_,ct())),t=await t,n(),t);c.messages=c.messages||{},c.fallbackLocale=c.fallbackLocale??!1;const d=sp(),u=w=>w||c.locale||"en-US",p=L0();let h=xc(i,d(i),u(o.defaultLocale),{ssg:"normal",callType:"setup",firstAccess:!0,localeCookie:va(p,l,o.defaultLocale)},o);c.messages=([t,n]=fn(()=>n0(c.messages,hr,{localeCodes:Os,initialLocale:h,lazy:o.lazy,defaultLocale:o.defaultLocale,fallbackLocale:c.fallbackLocale}
30)),t=await t,n(),t),h=u(h);const m=AE({...c,locale:h});let v=!0;const _=w=>h!==w&&v;UE(m,{extendComposer(w){const C=On(),O=Re(o.locales),T=Re(Os),E=Re("");w.locales=ee(()=>O.value),w.localeCodes=ee(()=>T.value),w.baseUrl=ee(()=>E.value),W_?We(w.locale,()=>{E.value=Rc(o.baseUrl,s)},{immediate:!0}):E.value=Rc(o.baseUrl,s),w.strategy=o.strategy,w.localeProperties=ee(()=>Fr.find(y=>y.code===w.locale.value)||{code:w.locale.value}),w.setLocale=async y=>{const P=_(y);await Dc(y,m,o,P)&&P&&(v=!1);const I=await s.runWithContext(()=>Mc({route:{to:C},locale:y,routeLocale:d(C),strategy:o.strategy}));await s.runWithContext(async()=>await Fc({nuxtApp:s,i18n:m,redirectPath:I,locale:y,route:C},{enableNavigate:!0}))},w.loadLocaleMessages=async y=>{const P=Xh.bind(null,m);await pr(y,hr,P)},w.differentDomains=o.differentDomains,w.defaultLocale=o.defaultLocale,w.getBrowserLocale=()=>rp(),w.getLocaleCookie=()=>va(p,l,o.defaultLocale),w.setLocaleCookie=y=>N0(p,y,l),w.onBeforeLanguageSwitch=(y,P,A,I)=>e.callHook("i18n:beforeLocaleSwitch",{oldLocale:y,newLocale:P,initialSetup:A,context:I}),w.onLanguageSwitched=(y,P)=>e.callHook("i18n:localeSwitched",{oldLocale:y,newLocale:P}),w.finalizePendingLocaleChange=async()=>{m.__pendingLocale&&(Jh(m,m.__pendingLocale),m.__resolvePendingLocalePromise&&await m.__resolvePendingLocalePromise(),m.__pendingLocale=void 0)},w.waitForPendingLocaleChange=async()=>{m.__pendingLocale&&m.__pendingLocalePromise&&await m.__pendingLocalePromise}},extendComposerInstance(w,C){const O={locales:{get:()=>C.locales.value},localeCodes:{get:()=>C.localeCodes.value},baseUrl:{get:()=>C.baseUrl.value},strategy:{get:()=>C.strategy},localeProperties:{get:()=>C.localeProperties.value},setLocale:{get:()=>async T=>Reflect.apply(C.setLocale,C,[T])},loadLocaleMessages:{get:()=>async T=>Reflect.apply(C.loadLocaleMessages,C,[T])},differentDomains:{get:()=>C.differentDomains},defaultLocale:{get:()=>C.defaultLocale},getBrowserLocale:{get:()=>()=>Reflect.apply(C.getBrowserLocale,C,[])},getLocaleCookie:{get:()=>()=>Reflect.apply(C.getLocaleCookie,C,[])},setLocaleCookie:{get:()=>T=>Reflect.apply(C.setLocaleCookie,C,[T])},onBeforeLanguageSwitch:{get:()=>(T,E,y,P)=>Reflect.apply(C.onBeforeLanguageSwitch,C,[T,E,y,P])},onLanguageSwitched:{get:()=>(T,E)=>Reflect.apply(C.onLanguageSwitched,C,[T,E])},finalizePendingLocaleChange:{get:()=>()=>Reflect.apply(C.finalizePendingLocaleChange,C,[])},waitForPendingLocaleChange:{get:()=>()=>Reflect.apply(C.waitForPendingLocaleChange,C,[])}};for(const[T,E]of Object.entries(O))Object.defineProperty(w,T,E)}}),r.use(m),O0(s,m);let b=0;Nb("locale-changing",async(w,C)=>{let O,T;const E=d(w),y=xc(w,E,()=>$r(m)||u(o.defaultLocale),{ssg:"normal",callType:"routing",firstAccess:b===0,localeCookie:va(p,l,o.defaultLocale)},o),P=_(y);([O,T]=fn(()=>Dc(y,m,o,P)),O=await O,T(),O)&&P&&(v=!1);const I=([O,T]=fn(()=>s.runWithContext(()=>Mc({route:{to:w,from:C},locale:y,routeLocale:E,strategy:o.strategy},!0))),O=await O,T(),O);return b++,[O,T]=fn(()=>s.runWithContext(async()=>Fc({nuxtApp:s,i18n:m,redirectPath:I,locale:y,route:w}))),O=await O,T(),O},{global:!0})}}),zE=/(android|bb\d+|meego).+mobile|avantgo|bada\/|blackberry|blazer|compal|elaine|FBAN|FBAV|fennec|hiptop|iemobile|ip(hone|od)|Instagram|iris|kindle|lge |maemo|midp|mmp|mobile.+firefox|netfront|opera m(ob|in)i|palm( os)?|phone|p(ixi|re)\/|plucker|pocket|psp|series(4|6)0|symbian|treo|up\.(browser|link)|vodafone|wap|windows ce|xda|xiino/i,KE=/1207|6310|6590|3gso|4thp|50[1-6]i|770s|802s|a wa|abac|ac(er|oo|s\-)|ai(ko|rn)|al(av|ca|co)|amoi|an(ex|ny|yw)|aptu|ar(ch|go)|as(te|us)|attw|au(di|\-m|r |s )|avan|be(ck|ll|nq)|bi(lb|rd)|bl(ac|az)|br(e|v)w|bumb|bw\-(n|u)|c55\/|capi|ccwa|cdm\-|cell|chtm|cldc|cmd\-|co(mp|nd)|craw|da(it|ll|ng)|dbte|dc\-s|devi|dica|dmob|do(c|p)o|ds(12|\-d)|el(49|ai)|em(l2|ul)|er(ic|k0)|esl8|ez([4-7]0|os|wa|ze)|fetc|fly(\-|_)|g1 u|g560|gene|gf\-5|g\-mo|go(\.w|od)|gr(ad|un)|haie|hcit|hd\-(m|p|t)|hei\-|hi(pt|ta)|hp( i|ip)|hs\-c|ht(c(\-| |_|a|g|p|s|t)|tp)|hu(aw|tc)|i\-(20|go|ma)|i230|iac( |\-|\/)|ibro|idea|ig01|ikom|im1k|inno|ipaq|iris|ja(t|v)a|jbro|jemu|jigs|kddi|keji|kgt( |\/)|klon|kpt |kwc\-|kyo(c|k)|le(no|xi)|lg( g|\/(k|l|u)|50|54|\-[a-w])|libw|lynx|m1\-w|m3ga|m50\/|ma(te|ui|xo)|mc(01|21|ca)|m\-cr|me(rc|ri)|mi(o8|oa|ts)|mmef|mo(01|02|bi|de|do|t(\-| |o|v)|zz)|mt(50|p1|v )|mwbp|mywa|n10[0-2]|n20[2-3]|n30(0|2)|n50(0|2|5)|n7(0(0|1)|10)|ne((c|m)\-|on|tf|wf|wg|wt)|nok(6|i)|nzph|o2im|op(ti|wv)|oran|owg1|p800|pan(a|d|t)|pdxg|pg(13|\-([1-8]|c))|phil|pire|pl(ay|uc)|pn\-2|po(ck|rt|se)|prox|psio|pt\-g|qa\-a|qc(07|12|21|32|60|\-[2-7]|i\-)|qtek|r380|r600|raks|rim9|ro(ve|zo)|s55\/|sa(ge|ma|mm|ms|ny|va)|sc(01|h\-|oo|p\-)|sdk\/|se(c(\-|0|1)|47|mc|nd|ri)|sgh\-|shar|sie(\-|m)|sk\-0|sl(45|id)|sm(al|ar|b3|it|t5)|so(ft|ny)|sp(01|h\-|v\-|v )|
30sy(01|mb)|t2(18|50)|t6(00|10|18)|ta(gt|lk)|tcl\-|tdg\-|tel(i|m)|tim\-|t\-mo|to(pl|sh)|ts(70|m\-|m3|m5)|tx\-9|up(\.b|g1|si)|utst|v400|v750|veri|vi(rg|te)|vk(40|5[0-3]|\-v)|vm40|voda|vulc|vx(52|53|60|61|70|80|81|83|85|98)|w3c(\-| )|webc|whit|wi(g |nc|nw)|wmlb|wonu|x700|yas\-|your|zeto|zte\-/i;function GE(e){return zE.test(e)||KE.test(e.slice(0,4))}const jE=/(android|bb\d+|meego).+mobile|avantgo|bada\/|blackberry|blazer|compal|elaine|FBAN|FBAV|fennec|hiptop|iemobile|ip(hone|od)|Instagram|iris|kindle|lge |maemo|midp|mmp|mobile.+firefox|netfront|opera m(ob|in)i|palm( os)?|phone|p(ixi|re)\/|plucker|pocket|psp|series(4|6)0|symbian|treo|up\.(browser|link)|vodafone|wap|windows ce|xda|xiino|android|ipad|playbook|silk/i,YE=/1207|6310|6590|3gso|4thp|50[1-6]i|770s|802s|a wa|abac|ac(er|oo|s\-)|ai(ko|rn)|al(av|ca|co)|amoi|an(ex|ny|yw)|aptu|ar(ch|go)|as(te|us)|attw|au(di|\-m|r |s )|avan|be(ck|ll|nq)|bi(lb|rd)|bl(ac|az)|br(e|v)w|bumb|bw\-(n|u)|c55\/|capi|ccwa|cdm\-|cell|chtm|cldc|cmd\-|co(mp|nd)|craw|da(it|ll|ng)|dbte|dc\-s|devi|dica|dmob|do(c|p)o|ds(12|\-d)|el(49|ai)|em(l2|ul)|er(ic|k0)|esl8|ez([4-7]0|os|wa|ze)|fetc|fly(\-|_)|g1 u|g560|gene|gf\-5|g\-mo|go(\.w|od)|gr(ad|un)|haie|hcit|hd\-(m|p|t)|hei\-|hi(pt|ta)|hp( i|ip)|hs\-c|ht(c(\-| |_|a|g|p|s|t)|tp)|hu(aw|tc)|i\-(20|go|ma)|i230|iac( |\-|\/)|ibro|idea|ig01|ikom|im1k|inno|ipaq|iris|ja(t|v)a|jbro|jemu|jigs|kddi|keji|kgt( |\/)|klon|kpt |kwc\-|kyo(c|k)|le(no|xi)|lg( g|\/(k|l|u)|50|54|\-[a-w])|libw|lynx|m1\-w|m3ga|m50\/|ma(te|ui|xo)|mc(01|21|ca)|m\-cr|me(rc|ri)|mi(o8|oa|ts)|mmef|mo(01|02|bi|de|do|t(\-| |o|v)|zz)|mt(50|p1|v )|mwbp|mywa|n10[0-2]|n20[2-3]|n30(0|2)|n50(0|2|5)|n7(0(0|1)|10)|ne((c|m)\-|on|tf|wf|wg|wt)|nok(6|i)|nzph|o2im|op(ti|wv)|oran|owg1|p800|pan(a|d|t)|pdxg|pg(13|\-([1-8]|c))|phil|pire|pl(ay|uc)|pn\-2|po(ck|rt|se)|prox|psio|pt\-g|qa\-a|qc(07|12|21|32|60|\-[2-7]|i\-)|qtek|r380|r600|raks|rim9|ro(ve|zo)|s55\/|sa(ge|ma|mm|ms|ny|va)|sc(01|h\-|oo|p\-)|sdk\/|se(c(\-|0|1)|47|mc|nd|ri)|sgh\-|shar|sie(\-|m)|sk\-0|sl(45|id)|sm(al|ar|b3|it|t5)|so(ft|ny)|sp(01|h\-|v\-|v )|sy(01|mb)|t2(18|50)|t6(00|10|18)|ta(gt|lk)|tcl\-|tdg\-|tel(i|m)|tim\-|t\-mo|to(pl|sh)|ts(70|m\-|m3|m5)|tx\-9|up(\.b|g1|si)|utst|v400|v750|veri|vi(rg|te)|vk(40|5[0-3]|\-v)|vm40|voda|vulc|vx(52|53|60|61|70|80|81|83|85|98)|w3c(\-| )|webc|whit|wi(g |nc|nw)|wmlb|wonu|x700|yas\-|your|zeto|zte\-/i,WE=/Googlebot\/|Googlebot-Mobile|Googlebot-Image|Googlebot-News|Googlebot-Video|AdsBot-Google([^-]|$)|AdsBot-Google-Mobile|Feedfetcher-Google|Mediapartners-Google|Mediapartners \(Googlebot\)|APIs-Google|bingbot|Slurp|[wW]get|LinkedInBot|Python-urllib|python-requests|aiohttp|httpx|libwww-perl|httpunit|nutch|Go-http-client|phpcrawl|msnbot|jyxobot|FAST-WebCrawler|FAST Enterprise Crawler|BIGLOTRON|Teoma|convera|seekbot|Gigabot|Gigablast|exabot|ia_archiver|GingerCrawler|webmon |HTTrack|grub.org|UsineNouvelleCrawler|antibot|netresearchserver|speedy|fluffy|findlink|msrbot|panscient|yacybot|AISearchBot|ips-agent|tagoobot|MJ12bot|woriobot|yanga|buzzbot|mlbot|YandexBot|YandexImages|YandexAccessibilityBot|YandexMobileBot|YandexMetrika|YandexTurbo|YandexImageResizer|YandexVideo|YandexAdNet|YandexBlogs|YandexCalendar|YandexDirect|YandexFavicons|YaDirectFetcher|YandexForDomain|YandexMarket|YandexMedia|YandexMobileScreenShotBot|YandexNews|YandexOntoDB|YandexPagechecker|YandexPartner|YandexRCA|YandexSearchShop|YandexSitelinks|YandexSpravBot|YandexTracker|YandexVertis|YandexVerticals|YandexWebmaster|YandexScreenshotBot|purebot|Linguee Bot|CyberPatrol|voilabot|Baiduspider|citeseerxbot|spbot|twengabot|postrank|TurnitinBot|scribdbot|page2rss|sitebot|linkdex|Adidxbot|ezooms|dotbot|Mail.RU_Bot|discobot|heritrix|findthatfile|europarchive.org|NerdByNature.Bot|sistrix crawler|Ahrefs(Bot|SiteAudit)|fuelbot|CrunchBot|IndeedBot|mappydata|woobot|ZoominfoBot|PrivacyAwareBot|Multiviewbot|SWIMGBot|Grobbot|eright|Apercite|semanticbot|Aboundex|domaincrawler|wbsearchbot|summify|CCBot|edisterbot|seznambot|ec2linkfinder|gslfbot|aiHitBot|intelium_bot|facebookexternalhit|Yeti|RetrevoPageAnalyzer|lb-spider|Sogou|lssbot|careerbot|wotbox|wocbot|ichiro|DuckDuckBot|lssrocketcrawler|drupact|webcompanycrawler|acoonbot|openindexspider|gnam gnam spider|web-archive-net.com.bot|backlinkcrawler|coccoc|integromedb|content crawler spider|toplistbot|it2media-domain-crawler|ip-web-crawler.com|siteexplorer.info|elisabot|proximic|changedetection|arabot|WeSEE:Search|niki-bot|CrystalSemanticsBot|rogerbot|360Spider|psbot|InterfaxScanBot|CC Metadata Scaper|g00g1e.net|GrapeshotCrawler|urlappendbot|brainobot|fr-crawler|binlar|SimpleCrawler|Twitterbot|cXensebot|smtbot|bnf.fr_bot|A6-Indexer|ADmantX|Facebot|OrangeBot\/|memorybot|AdvBot|MegaIndex|SemanticScholarBot|ltx71|nerdybot|xovibot|BUbiNG|Qwantify|archive.org_bot|Applebot|TweetmemeBot|crawler4j|findxbot|S[eE][mM]rushBot|yoozBot|lipperhey|Y!J|Domain Re-Animator Bot|AddThis|Screaming Frog SEO Spider|MetaURI|Scrapy|Livelap[bB]ot|OpenHoseBot|CapsuleChecker|[email protected]|IstellaBot|DeuSu\/|betaBot|Cliqzbot\/|MojeekBot\/|netEstate NE Crawler|SafeSearch microdata crawler|Gluten Free Crawler\/|Sonic|Sysomos|Trove|deadlinkchecker|Slack-ImgProxy|Embedly|RankActiveLinkBot|iskanie|SafeDNSBot|SkypeUriPreview|Veoozbot|Slackbot|redditbot|datagnionbot|Google-Adwords-Instant|adbeat_bot|WhatsApp|contxbot|pinterest.com.bot|electricmonk|GarlikCrawler|BingPreview\/|vebidoobot|FemtosearchBot|Yahoo Link Preview|MetaJobBot|DomainStatsBot|mindUpBot|Daum\/|Jugendschutzprogramm-Crawler|Xenu Link Sleuth|Pcore-HTTP|moatbot|KosmioBot|pingdom|AppInsights|PhantomJS|Gowikibot|PiplBot|Discordbot|TelegramBot|Jetslide|newsharecounts|James BOT|Bark[rR]owler|TinEye|SocialRankIOBot|trendictionbot|Ocarinabot|epicbot|Primalbot|DuckDuckGo-Favicons-Bot|GnowitNewsbot|Leikibot|LinkArchiver|YaK\/|PaperLiBot|Digg Deeper|dcrawl|Snacktory|AndersPinkBot|Fyrebot|EveryoneSocialBot|Mediatoolkitbot|Luminator-robots|ExtLinksBot|SurveyBot|NING\/|okhttp|Nuzzel|omgili|PocketParser|YisouSpider|um-LN|ToutiaoSpider|MuckRack|Jamie's Spider|AHC\/|NetcraftSurveyAgent|Laserlikebot|^Apache-HttpClient|AppEngine-Google|Jetty|Upflow|Thinklab|Traackr.com|Twurly|Mastodon|http_get|DnyzBot|botify|007ac9 Crawler|BehloolBot|BrandVerity|check_http|BDCbot|ZumBot|EZID|ICC-Crawler|ArchiveBot|^LCC |filterdb.iss.net\/crawler|BLP_bbot|BomboraBot|Buck\/|Companybook-Crawler|Genieo|magpie-crawler|Meltw
30aterNews|Moreover|newspaper\/|ScoutJet|(^| )sentry\/|StorygizeBot|UptimeRobot|OutclicksBot|seoscanners|Hatena|Google Web Preview|MauiBot|AlphaBot|SBL-BOT|IAS crawler|adscanner|Netvibes|acapbot|Baidu-YunGuanCe|bitlybot|blogmuraBot|Bot.AraTurka.com|bot-pge.chlooe.com|BoxcarBot|BTWebClient|ContextAd Bot|Digincore bot|Disqus|Feedly|Fetch\/|Fever|Flamingo_SearchEngine|FlipboardProxy|g2reader-bot|G2 Web Services|imrbot|K7MLWCBot|Kemvibot|Landau-Media-Spider|linkapediabot|vkShare|Siteimprove.com|BLEXBot\/|DareBoost|ZuperlistBot\/|Miniflux\/|Feedspot|Diffbot\/|SEOkicks|tracemyfile|Nimbostratus-Bot|zgrab|PR-CY.RU|AdsTxtCrawler|Datafeedwatch|Zabbix|TangibleeBot|google-xrawler|axios|Amazon CloudFront|Pulsepoint|CloudFlare-AlwaysOnline|Google-Structured-Data-Testing-Tool|WordupInfoSearch|WebDataStats|HttpUrlConnection|Seekport Crawler|ZoomBot|VelenPublicWebCrawler|MoodleBot|jpg-newsbot|outbrain|W3C_Validator|Validator\.nu|W3C-checklink|W3C-mobileOK|W3C_I18n-Checker|FeedValidator|W3C_CSS_Validator|W3C_Unicorn|Google-PhysicalWeb|Blackboard|ICBot\/|BazQux|Twingly|Rivva|Experibot|awesomecrawler|Dataprovider.com|GroupHigh\/|theoldreader.com|AnyEvent|Uptimebot\.org|Nmap Scripting Engine|2ip.ru|Clickagy|Caliperbot|MBCrawler|online-webceo-bot|B2B Bot|AddSearchBot|Google Favicon|HubSpot|Chrome-Lighthouse|HeadlessChrome|CheckMarkNetwork\/|www\.uptime\.com|Streamline3Bot\/|serpstatbot\/|MixnodeCache\/|^curl|SimpleScraper|RSSingBot|Jooblebot|fedoraplanet|Friendica|NextCloud|Tiny Tiny RSS|RegionStuttgartBot|Bytespider|Datanyze|Google-Site-Verification|TrendsmapResolver|tweetedtimes|NTENTbot|Gwene|SimplePie|SearchAtlas|Superfeedr|feedbot|UT-Dorkbot|Amazonbot|SerendeputyBot|Eyeotabot|officestorebot|Neticle Crawler|SurdotlyBot|LinkisBot|AwarioSmartBot|AwarioRssBot|RyteBot|FreeWebMonitoring SiteChecker|AspiegelBot|NAVER Blog Rssbot|zenback bot|SentiBot|Domains Project\/|Pandalytics|VKRobot|bidswitchbot|tigerbot|NIXStatsbot|Atom Feed Robot|Curebot|PagePeeker\/|Vigil\/|rssbot\/|startmebot\/|JobboerseBot|seewithkids|NINJA bot|Cutbot|BublupBot|BrandONbot|RidderBot|Taboolabot|Dubbotbot|FindITAnswersbot|infoobot|Refindbot|BlogTraffic\/\d\.\d+ Feed-Fetcher|SeobilityBot|Cincraw|Dragonbot|VoluumDSP-content-bot|FreshRSS|BitBot|^PHP-Curl-Class|Google-Certificates-Bridge/;function QE(e){return jE.test(e)||YE.test(e.slice(0,4))}function ZE(e){return/iPad|iPhone|iPod/.test(e)}function qE(e){return/android/i.test(e)}function JE(e){return/Windows/.test(e)}function XE(e){return/Mac OS X/.test(e)}const eS=[{name:"Samsung",test:/SamsungBrowser/i},{name:"Edge",test:/edg([ea]|ios|)\//i},{name:"Firefox",test:/firefox|iceweasel|fxios/i},{name:"Chrome",test:/chrome|crios|crmo/i},{name:"Safari",test:/safari|applewebkit/i}];function tS(e){for(const t of eS)if(t.test.test(e))return t.name;return""}function Sa(e,t){let n=!1,i=!1,r=!1,s=!1;if(t==="Amazon CloudFront")e["cloudfront-is-mobile-viewer"]==="true"&&(n=!0,i=!0),e["cloudfront-is-tablet-viewer"]==="true"&&(n=!1,i=!0),e["cloudfront-is-desktop-viewer"]==="true"&&(n=!1,i=!1),e["cloudfront-is-ios-viewer"]==="true"&&(r=!0),e["cloudfront-is-android-viewer"]==="true"&&(s=!0);else if(e&&e["cf-device-type"])switch(e["cf-device-type"]){case"mobile":n=!0,i=!0;break;case"tablet":n=!1,i=!0;break;case"desktop":n=!1,i=!1;break}else n=GE(t),i=QE(t),r=ZE(t),s=qE(t);const a=JE(t),o=XE(t),l=tS(t),c=l==="Safari",d=l==="Firefox",u=l==="Edge",p=l==="Chrome",h=l==="Samsung",m=WE.test(t);return{userAgent:t,isMobile:n,isMobileOrTablet:i,isTablet:!n&&i,isDesktop:!i,isIos:r,isAndroid:s,isWindows:a,isMacOS:o,isApple:o||r,isDesktopOrTablet:!n,isSafari:c,isFirefox:d,isEdge:u,isChrome:p,isSamsung:h,isCrawler:m}}const nS=_t(e=>{const t=Be(),n=t.public.device.defaultUserAgent,i=t.public.device.refreshOnResize;if(e.ssrContext){const a=E_(),o=a["user-agent"]||n;return{provide:{device:Wt(Sa(a,o))}}}const r=navigator.userAgent||n,s=Wt(Sa({},r));return i&&window.addEventListener("resize",()=>{setTimeout(()=>{const a=Sa({},navigator.userAgent||n);Object.entries(a).forEach(o=>{const[l,c]=o;s[l]=c})},50)}),{provide:{device:s}}});var sS,iS=()=>sS;function rS(e){return typeof e=="function"?e():k(e)}function _o(e,t=""){if(e instanceof Promise)return e;const n=rS(e);return!e||!n?n:Array.isArray(n)?n.map(i=>_o(i,t)):typeof n=="object"?Object.fromEntries(Object.entries(n).map(([i,r])=>i==="titleTemplate"||i.startsWith("on")?[i,k(r)]:[i,_o(r,i)])):n}var aS=typeof window<"u",oS="usehead";function dl(){return ln()&&Ft(oS)||iS()}function lS(e,t={}){const n=dl(),i=Re(!1),r=Re({});Ci(()=>{r.value=i.value?{}:_o(e)});const s=n.push(r.value,t);return We(r,o=>{s.patch(o)}),ln()&&(Cr(()=>{s.dispose()}),Bu(()=>{i.value=!0}),$u(()=>{i.value=!1})),s}function cS(e,t={}){return dl().push(e,t)}function dS(e,t={}){var i;const n=dl();if(n){const r=aS||!!((i=n.resolvedOptions)!=null&&i.document);return t.mode==="server"&&r||t.mode==="client"&&!r?void 0:r?lS(e,t):cS(e,t)}}var uS=e=>{const t={created(){var r;if(typeof((r=this.$options)==null?void 0:r.jsonld)!="function")return;const i=ee(()=>this.$options.jsonld.call(this));dS(()=>({script:[{type:"application/ld+json",children:i.value?JSON.stringify(i.value,
30null,""):void 0}]}))}},n={install(i){i.mixin(t)}};e.vueApp.use(n)},hS=_t(uS);const pS=_t({name:"nuxt:chunk-reload",setup(e){const t=dn(),n=Be(),i=new Set;t.beforeEach(()=>{i.clear()}),e.hook("app:chunkError",({error:s})=>{i.add(s)});function r(s){const o="href"in s&&s.href[0]==="#"?n.app.baseURL+s.href:Ms(n.app.baseURL,s.fullPath);A_({path:o,persistState:!0})}e.hook("app:manifest:update",()=>{t.beforeResolve(r)}),t.onError((s,a)=>{i.has(s)&&r(a)})}}),fS={loadingFullData:!1,loadingFetchData:!0,lensTechLoading:!0,loadingAddToCart:!1,loadingFetchSimilarFrames:!0,loadingUploadedRxFiles:!0,loadingCheckContactsRx:!1,loadingAnagram:!1,loadingShippingMethods:!1,subscribeUserLoading:!1,customerExpressCheckoutLoading:!1,customerSavedPrescriptionLoading:!1,genericSiteMetadata:{autoship_status:!1,email_support:"",free_shipping_threshold:!1,is_anagram_insurance_active:!1,is_logged_in:!1,kits_membership:{allowed:!1,has_membership:!1},phone_support:"",shipping_status:"",side_cart:{items:[],totals:{},discounts:{}},user:{fname:"",lname:"",last_purchase:""},support:{progressives_specialist_phone:"",autoship_specialist_phone:"",mailing_address:"",work_hours:{monday_to_friday:{open:"",close:""},saturday:{open:"",close:""},timezone:""}},website_name:"",free_shipping_threshold:99},shouldShowAnagram:!1,invalidCoupon:"",displayHeaderSearch:!1,displayHeaderSearchMenu:!1,displayHeaderNavDetails:!1,headerNavType:"",headerInformation:{logo:"",type:""},headerNavMenuType:"",hamburgerMenuType:"",isAccordionVisible:!1,searchResults:{response:{numberOfProducts:0,products:[],start:0},searchMetaData:{queryParams:{q:""},queryTime:0,status:0}},trendingResults:{item:[],store_id:""},trendingContacts:{numberOfProducts:0,start:0,products:[]},selectedProductType:"trending",searchInputText:"",searchResultsLoading:!1,searchSuggestionsLoading:!1,isOpticianSearch:!1,isProductNotFound:!1,toastMessage:{payload:"",type:""},confirmDialog:{isVisible:!1,title:"",message:"",resolver:null,onSkipButtonClick:null,onTopButtonClick:null,onBottomButtonClick:null},offersSiteStripe:[],error404BestSellers:{glassesBestSellers:[],sunglassesBestSellers:[],designerBestSellers:[],contactsBestSellers:[]},glassesBestSellers:[],contactsBestSellers:[],searchValue:"",aiSearchSuggestions:[],isScannerOpened:!1,contactsByUpc:{brand:"",image:"",name:"",price:60,rx_info:{},sku:"",upc:""}},mS={getLoadingFullData(e){return e.loadingFullData},getLoadingFetchData(e){return e.loadingFetchData},getLoadingAddToCart(e){return e.loadingAddToCart},getLoadingFetchSimilarFrames(e){return e.loadingFetchSimilarFrames},getLoadingCheckContactsRx(e){return e.loadingCheckContactsRx},getLensTechLoading(e){return e.lensTechLoading},getLoadingUploadedRxFiles(e){return e.loadingUploadedRxFiles},getLoadingAnagramCheck(e){return e.loadingAnagram},getDisplayHeaderSearch(e){return e.displayHeaderSearch},getDisplayHeaderSearchMenu(e){return e.displayHeaderSearchMenu},getDisplayHeaderNavDetails(e){return e.displayHeaderNavDetails},getHeaderNavType(e){return e.headerNavType},getHeaderNavMenuType(e){return e.headerNavMenuType},getHeaderInformation(e){return e.headerInformation},getHamburgerMenuType(e){return e.hamburgerMenuType},getIsAccordionVisible(e){return e.isAccordionVisible},getSearchResults(e){return e.searchResults},getTrendingResults(e){return e.trendingResults},getTrendingContacts(e){return e.trendingContacts},getSelectedProductType(e){return e.selectedProductType},getSearchResultsLoading(e){return e.searchResultsLoading},getIsProductNotFound(e){return e.isProductNotFound},getGenericSiteMetadata(e){return e.genericSiteMetadata},getSubscribeUserLoading(e){return e.subscribeUserLoading},getCustomerExpressCheckoutLoading(e){return e.customerExpressCheckoutLoading},getCustomerSavedPrescriptionLoading(e){return e.customerSavedPrescriptionLoading},getInvalidCoupon(e){return e.invalidCoupon},getShouldShowAnagram(e){return e.shouldShowAnagram},getConfirmDialog(e){return e.confirmDialog},getOffersSiteStripe(e){return e.offersSiteStripe},getNewGlassesBestSellers(e){return e.error404BestSellers.glassesBestSellers},getNewSunglassesBestSellers(e){return e.error404BestSellers.sunglassesBestSellers}
30,getNewDesignerBestSellers(e){return e.error404BestSellers.designerBestSellers},getNewContactsBestSellers(e){return e.error404BestSellers.contactsBestSellers},getGlassesBestSellers(e){return e.glassesBestSellers},getContactsBestSellers(e){return e.contactsBestSellers},getIsOpticianSearch(e){return e.isOpticianSearch},getSearchValue(e){return e.searchValue},getAiSearchSuggestions(e){return e.aiSearchSuggestions},getSearchSuggestionsLoading(e){return e.searchSuggestionsLoading},getSearchInputText(e){return e.searchInputText},getIsScannerOpened(e){return e.isScannerOpened},getContactsByUpc(e){return e.contactsByUpc}},Sp=window.setInterval;/*! js-cookie v3.0.5 | MIT */function zi(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var i in n)e[i]=n[i]}return e}var gS={read:function(e){return e[0]==='"'&&(e=e.slice(1,-1)),e.replace(/(%[\dA-F]{2})+/gi,decodeURIComponent)},write:function(e){return encodeURIComponent(e).replace(/%(2[346BF]|3[AC-F]|40|5[BDE]|60|7[BCD])/g,decodeURIComponent)}};function wo(e,t){function n(r,s,a){if(!(typeof document>"u")){a=zi({},t,a),typeof a.expires=="number"&&(a.expires=new Date(Date.now()+a.expires*864e5)),a.expires&&(a.expires=a.expires.toUTCString()),r=encodeURIComponent(r).replace(/%(2[346B]|5E|60|7C)/g,decodeURIComponent).replace(/[()]/g,escape);var o="";for(var l in a)a[l]&&(o+="; "+l,a[l]!==!0&&(o+="="+a[l].split(";")[0]));return document.cookie=r+"="+e.write(s,r)+o}}function i(r){if(!(typeof document>"u"||arguments.length&&!r)){for(var s=document.cookie?document.cookie.split("; "):[],a={},o=0;o<s.length;o++){var l=s[o].split("="),c=l.slice(1).join("=");try{var d=decodeURIComponent(l[0]);if(a[d]=e.read(c,d),r===d)break}catch{}}return r?a[r]:a}}return Object.create({set:n,get:i,remove:function(r,s){n(r,"",zi({},s,{expires:-1}))},withAttributes:function(r){return wo(this.converter,zi({},this.attributes,r))},withConverter:function(r){return wo(zi({},this.converter,r),this.attributes)}},{attributes:{value:Object.freeze(t)},converter:{value:Object.freeze(e)}})}var it=wo(gS,{path:"/"});function xe(e,t,n){return(t=bS(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function yS(e,t){if(typeof e!="object"||e===null)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var i=n.call(e,t||"default");if(typeof i!="object")return i;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function bS(e){var t=yS(e,"string");return typeof t=="symbol"?t:String(t)}function vS(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function pd(e,t){for(var n=0;n<t.length;n++){var i=t[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(e,i.key,i)}}function _S(e,t,n){return t&&pd(e.prototype,t),n&&pd(e,n),e}function wS(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function fd(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);t&&(i=i.filter(function(r){return Object.getOwnPropertyDescriptor(e,r).enumerable})),n.push.apply(n,i)}return n}function md(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?fd(Object(n),!0).forEach(function(i){wS(e,i,n[i])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):fd(Object(n)).forEach(function(i){Object.defineProperty(e,i,Object.getOwnPropertyDescriptor(n,i))})}return e}var gd={addCSS:!0,thumbWidth:15,watch:!0};function ES(e,t){return(function(){return Array.from(document.querySelectorAll(t)).includes(this)}).call(e,t)}function SS(e,t){if(e&&t){var n=new Event(t,{bubbles:!0});e.dispatchEvent(n)}}var Ai=function(e){return e!=null?e.constructor:null},ul=function(e,t){return!!(e&&t&&e instanceof t)},Cp=function(e){return e==null},Ip=function(e){return Ai(e)===Object},CS=function(e){return Ai(e)===Number&&!Number.isNaN(e)},Tp=function(e){return Ai(e)===String},IS=function(e){return Ai(e)===Boolean},TS=function(e){return Ai(e)===Function},Pp=function(e){return Array.isArray(e)},Op=function(e){return ul(e,NodeList)},PS=function(e){return ul(e,Element)},OS=function(e){return ul(e,Event)},AS=function(e){return Cp(e)||(Tp(e)||Pp(e)||Op(e))&&!e.length||Ip(e)&&!Object.keys(e).length},Vt={nullOrUndefined:Cp,object:Ip,number:CS,string:Tp,boolean:IS,function:TS,array:Pp,nodeList:Op,element:PS,event:OS,empty:AS};function kS(e){var t="".concat(e).match(/(?:\.(\d+))?(?:[eE]([+-]?\d+))?$/);return t?Math.max(0,(t[1]?t[1].length:0)-(t[2]?+t[2]:0)):0}function RS(e,t){if(1>t){var n=kS(t);return parseFloat(e.toFixed(n))}return Math.round(e/t)*t}var LS=function(){function e(t,n){vS(this,e),Vt.element(t)?this.element=t:Vt.string(t)&&(this.element=document.querySelector(t)),Vt.element(this.element)&&Vt.empty(this.element.rangeTouch)&&(this.config=md({},gd,{},n),this.init())}return _S(e,[{key:"init",value:function(){e.enabled&&(this.config.addCSS&&(this.element.style.userSelect="none",this.element.style.webKitUserSelect="none",this.element.style.touchAction="manipulation"),this.listeners(!0),this.element.rangeTouch=this)}},{key:"destroy",value:function(){e.enabled&&(this.config.addCSS&&(this.element.style.userSelect="",this.element.style.webKitUserSelect="",this.element.style.touchAction=""),this.listeners(!1),this.element.rangeTouch=null)}},{key:"listeners",value:function(t){var n=this,i=t?"addEventListener":"removeEventListener";["touchstart","touchmove","touchend"].forEach(function(r){n.element[i](r,function(s){return n.set(s)},!1)})}},{key:"get",value:function(t){if(!e.enabled||!Vt.event(t))return null;var n,i=t.target,r=t.changedTouches[0],s=parseFloat(i.getAttribute("min"))||0,a=parseFloat(i.getAttribute("max"))||100,o=parseFloat(i.getAttribute("step"))||1,l=i.getBoundingClientRect(),c=100/l.width*(this.config.thumbWidth/2)/100;return 0>(n=100/l.width*(r.clientX-l.left))?n=0:100<n&&(n=100),50>n?n-=(100-2*n)*c:50<n&&(n+=2*(n-50)*c),s+RS(n/100*(a-s),o)}},{key:"set",value:function(t){e.enabled&&Vt.event(t)&&!t.target.disabled&&(t.preventDefault(),t.target.value=this.get(t),SS(t.target,t.type==="touchend"?"change":"input"))}}],[{key:"setup",value:function(t){var n=1<arguments.length&&arguments[1]!==void 0?arguments[1]:{},i=null;if(Vt.empty(t)||Vt.string(t)?i=Array.from(document.querySelectorAll(Vt.string(t)?t:'input[type="range"]')):Vt.element(t)?i=[t]:Vt.nodeList(t)?i=Array.from(t):Vt.array(t)&&(i=t.filter(Vt.element)),Vt.empty(i))return null;var r=md({},gd,{},n);
30if(Vt.string(t)&&r.watch){var s=new MutationObserver(function(a){Array.from(a).forEach(function(o){Array.from(o.addedNodes).forEach(function(l){Vt.element(l)&&ES(l,t)&&new e(l,r)})})});s.observe(document.body,{childList:!0,subtree:!0})}return i.map(function(a){return new e(a,n)})}},{key:"enabled",get:function(){return"ontouchstart"in document.documentElement}}]),e}();const ki=e=>e!=null?e.constructor:null,An=(e,t)=>!!(e&&t&&e instanceof t),hl=e=>e==null,Ap=e=>ki(e)===Object,NS=e=>ki(e)===Number&&!Number.isNaN(e),jr=e=>ki(e)===String,DS=e=>ki(e)===Boolean,kp=e=>typeof e=="function",Rp=e=>Array.isArray(e),xS=e=>An(e,WeakMap),Lp=e=>An(e,NodeList),MS=e=>ki(e)===Text,FS=e=>An(e,Event),VS=e=>An(e,KeyboardEvent),BS=e=>An(e,window.TextTrackCue)||An(e,window.VTTCue),$S=e=>An(e,TextTrack)||!hl(e)&&jr(e.kind),US=e=>An(e,Promise)&&kp(e.then),HS=e=>e!==null&&typeof e=="object"&&e.nodeType===1&&typeof e.style=="object"&&typeof e.ownerDocument=="object",Np=e=>hl(e)||(jr(e)||Rp(e)||Lp(e))&&!e.length||Ap(e)&&!Object.keys(e).length,zS=e=>{if(An(e,window.URL))return!0;if(!jr(e))return!1;let t=e;e.startsWith("http://")&&e.startsWith("https://")||(t=`http://${e}`);try{return!Np(new URL(t).hostname)}catch{return!1}};var $={nullOrUndefined:hl,object:Ap,number:NS,string:jr,boolean:DS,function:kp,array:Rp,weakMap:xS,nodeList:Lp,element:HS,textNode:MS,event:FS,keyboardEvent:VS,cue:BS,track:$S,promise:US,url:zS,empty:Np};const Eo=(()=>{const e=document.createElement("span"),t={WebkitTransition:"webkitTransitionEnd",MozTransition:"transitionend",OTransition:"oTransitionEnd otransitionend",transition:"transitionend"},n=Object.keys(t).find(i=>e.style[i]!==void 0);return!!$.string(n)&&t[n]})();function Dp(e,t){setTimeout(()=>{try{e.hidden=!0,e.offsetHeight,e.hidden=!1}catch{}},t)}const KS=!!window.document.documentMode,GS=/Edge/g.test(navigator.userAgent),jS="WebkitAppearance"in document.documentElement.style&&!/Edge/g.test(navigator.userAgent),YS=/iPhone|iPod/gi.test(navigator.userAgent)&&navigator.maxTouchPoints>1,WS=navigator.platform==="MacIntel"&&navigator.maxTouchPoints>1,QS=/iPad|iPhone|iPod/gi.test(navigator.userAgent)&&navigator.maxTouchPoints>1;var Dt={isIE:KS,isEdge:GS,isWebKit:jS,isIPhone:YS,isIPadOS:WS,isIos:QS};function ZS(e){return JSON.parse(JSON.stringify(e))}function xp(e,t){return t.split(".").reduce((n,i)=>n&&n[i],e)}function Et(e={},...t){if(!t.length)return e;const n=t.shift();return $.object(n)?(Object.keys(n).forEach(i=>{$.object(n[i])?(Object.keys(e).includes(i)||Object.assign(e,{[i]:{}}),Et(e[i],n[i])):Object.assign(e,{[i]:n[i]})}),Et(e,...t)):e}function Mp(e,t){const n=e.length?e:[e];Array.from(n).reverse().forEach((i,r)=>{const s=r>0?t.cloneNode(!0):t,a=i.parentNode,o=i.nextSibling;s.appendChild(i),o?a.insertBefore(s,o):a.appendChild(s)})}function So(e,t){$.element(e)&&!$.empty(t)&&Object.entries(t).filter(([,n])=>!$.nullOrUndefined(n)).forEach(([n,i])=>e.setAttribute(n,i))}function $e(e,t,n){const i=document.createElement(e);return $.object(t)&&So(i,t),$.string(n)&&(i.innerText=n),i}function qS(e,t){$.element(e)&&$.element(t)&&t.parentNode.insertBefore(e,t.nextSibling)}function yd(e,t,n,i){$.element(t)&&t.appendChild($e(e,n,i))}function Pn(e){$.nodeList(e)||$.array(e)?Array.from(e).forEach(Pn):$.element(e)&&$.element(e.parentNode)&&e.parentNode.removeChild(e)}function Xi(e){if(!$.element(e))return;let{length:t}=e.childNodes;for(;t>0;)e.removeChild(e.lastChild),t-=1}function mr(e,t){return $.element(t)&&$.element(t.parentNode)&&$.element(e)?(t.parentNode.replaceChild(e,t),e):null}function pn(e,t){if(!$.string(e)||$.empty(e))return{};const n={},i=Et({},t);return e.split(",").forEach(r=>{const s=r.trim(),a=s.replace(".",""),o=s.replace(/[[\]]/g,"").split("="),[l]=o,c=o.length>1?o[1].replace(/["']/g,""):"";switch(s.charAt(0)){case".":$.string(i.class)?n.class=`${i.class} ${a}`:n.class=a;break;case"#":n.id=s.replace("#","");break;case"[":n[l]=c}}),Et(i,n)}function Xn(e,t){if(!$.element(e))return;let n=t;$.boolean(n)||(n=!e.hidden),e.hidden=n}function nt(e,t,n){if($.nodeList(e))return Array.from(e).map(i=>nt(i,t,n));if($.element(e)){let i="toggle";return n!==void 0&&(i=n?"add":"remove"),e.classList[i](t),e.classList.contains(t)}return!1}function gr(e,t){return $.element(e)&&e.classList.contains(t)}function rs(e,t){const{prototype:n}=Element;return(n.matches||n.webkitMatchesSelector||n.mozMatchesSelector||n.msMatchesSelector||function(){return Array.from(document.querySelectorAll(t)).includes(this)}).call(e,t)}function JS(e,t){const{prototype:n}=Element;return(n.closest||function(){let i=this;do{if(rs.matches(i,t))return i;i=i.parentElement||i.parentNode}while(i!==null&&i.nodeType===1);return null}).call(e,t)}function ui(e){return this.elements.container.querySelectorAll(e)}function At(e){return this.elements.container.querySelector(e)}function Ca(e=null,t=!1){$.element(e)&&e.focus({preventScroll:!0,focusVisible:t})}const bd={"audio/ogg":"vorbis","audio/wav":"1","video/webm":"vp8, vorbis","video/mp4":"avc1.42E01E, mp4a.40.2","video/ogg":"theora"},St={audio:"canPlayType"in document.createElement("audio"),video:"canPlayType"in document.createElement("video"),check(e,t){const n=St[e]||t!=="html5";return{api:n,ui:n&&St.rangeInput}},pip:!(Dt.isIPhone||!$.function($e("video").webkitSetPresentationMode)&&(!document.pictureInPictureEnabled||$e("video").disablePictureInPicture)),airplay:$.function(window.WebKitPlaybackTargetAvailabilityEvent),playsinline:"playsInl
30ine"in document.createElement("video"),mime(e){if($.empty(e))return!1;const[t]=e.split("/");let n=e;if(!this.isHTML5||t!==this.type)return!1;Object.keys(bd).includes(n)&&(n+=`; codecs="${bd[e]}"`);try{return!!(n&&this.media.canPlayType(n).replace(/no/,""))}catch{return!1}},textTracks:"textTracks"in document.createElement("video"),rangeInput:(()=>{const e=document.createElement("input");return e.type="range",e.type==="range"})(),touch:"ontouchstart"in document.documentElement,transitions:Eo!==!1,reducedMotion:"matchMedia"in window&&window.matchMedia("(prefers-reduced-motion)").matches},XS=(()=>{let e=!1;try{const t=Object.defineProperty({},"passive",{get:()=>(e=!0,null)});window.addEventListener("test",null,t),window.removeEventListener("test",null,t)}catch{}return e})();function hi(e,t,n,i=!1,r=!0,s=!1){if(!e||!("addEventListener"in e)||$.empty(t)||!$.function(n))return;const a=t.split(" ");let o=s;XS&&(o={passive:r,capture:s}),a.forEach(l=>{this&&this.eventListeners&&i&&this.eventListeners.push({element:e,type:l,callback:n,options:o}),e[i?"addEventListener":"removeEventListener"](l,n,o)})}function Ze(e,t="",n,i=!0,r=!1){hi.call(this,e,t,n,!0,i,r)}function Yr(e,t="",n,i=!0,r=!1){hi.call(this,e,t,n,!1,i,r)}function pl(e,t="",n,i=!0,r=!1){const s=(...a)=>{Yr(e,t,s,i,r),n.apply(this,a)};hi.call(this,e,t,s,!0,i,r)}function Ue(e,t="",n=!1,i={}){if(!$.element(e)||$.empty(t))return;const r=new CustomEvent(t,{bubbles:n,detail:{...i,plyr:this}});e.dispatchEvent(r)}function eC(){this&&this.eventListeners&&(this.eventListeners.forEach(e=>{const{element:t,type:n,callback:i,options:r}=e;t.removeEventListener(n,i,r)}),this.eventListeners=[])}function tC(){return new Promise(e=>this.ready?setTimeout(e,0):Ze.call(this,this.elements.container,"ready",e)).then(()=>{})}function mn(e){$.promise(e)&&e.then(null,()=>{})}function Co(e){return $.array(e)?e.filter((t,n)=>e.indexOf(t)===n):e}function Fp(e,t){return $.array(e)&&e.length?e.reduce((n,i)=>Math.abs(i-t)<Math.abs(n-t)?i:n):null}function Vp(e){return!(!window||!window.CSS)&&window.CSS.supports(e)}const vd=[[1,1],[4,3],[3,4],[5,4],[4,5],[3,2],[2,3],[16,10],[10,16],[16,9],[9,16],[21,9],[9,21],[32,9],[9,32]].reduce((e,[t,n])=>({...e,[t/n]:[t,n]}),{});function Bp(e){return $.array(e)||$.string(e)&&e.includes(":")?($.array(e)?e:e.split(":")).map(Number).every($.number):!1}function yr(e){if(!$.array(e)||!e.every($.number))return null;const[t,n]=e,i=(s,a)=>a===0?s:i(a,s%a),r=i(t,n);return[t/r,n/r]}function fl(e){const t=i=>Bp(i)?i.split(":").map(Number):null;let n=t(e);if(n===null&&(n=t(this.config.ratio)),n===null&&!$.empty(this.embed)&&$.array(this.embed.ratio)&&({ratio:n}=this.embed),n===null&&this.isHTML5){const{videoWidth:i,videoHeight:r}=this.media;n=[i,r]}return yr(n)}function Ns(e){if(!this.isVideo)return{};const{wrapper:t}=this.elements,n=fl.call(this,e);if(!$.array(n))return{};const[i,r]=yr(n),s=100/i*r;if(Vp(`aspect-ratio: ${i}/${r}`)?t.style.aspectRatio=`${i}/${r}`:t.style.paddingBottom=`${s}%`,this.isVimeo&&!this.config.vimeo.premium&&this.supported.ui){const a=100/this.media.offsetWidth*parseInt(window.getComputedStyle(this.media).paddingBottom,10),o=(a-s)/(a/50);this.fullscreen.active?t.style.paddingBottom=null:this.media.style.transform=`translateY(-${o}%)`}else this.isHTML5&&t.classList.add(this.config.classNames.videoFixedRatio);return{padding:s,ratio:n}}function $p(e,t,n=.05){const i=e/t,r=Fp(Object.keys(vd),i);return Math.abs(r-i)<=n?vd[r]:[e,t]}function nC(){return[Math.max(document.documentElement.clientWidth||0,window.innerWidth||0),Math.max(document.documentElement.clientHeight||0,window.innerHeight||0)]}const Bn={getSources(){return this.isHTML5?Array.from(this.media.querySelectorAll("source")).filter(e=>{const t=e.getAttribute("type");return!!$.empty(t)||St.mime.call(this,t)}):[]},getQualityOptions(){return this.config.quality.forced?this.config.quality.options:Bn.getSources.call(this).map(e=>Number(e.getAttribute("size"))).filter(Boolean)},setup(){if(!this.isHTML5)return;const e=this;e.options.speed=e.config.speed.options,$.empty(this.config.ratio)||Ns.call(e),Object.defineProperty(e.media,"quality",{get(){const t=Bn.getSources.call(e).find(n=>n.getAttribute("src")===e.source);return t&&Number(t.getAttribute("size"))},set(t){if(e.quality!==t){if(e.config.quality.forced&&$.function(e.config.quality.onChange))e.config.quality.onChange(t);else{const n=Bn.getSources.call(e).find(l=>Number(l.getAttribute("size"))===t);if(!n)return;const{currentTime:i,paused:r,preload:s,readyState:a,playbackRate:o}=e.media;e.media.src=n.getAttribute("src"),(s!=="none"||a)&&(e.once("loadedmetadata",()=>{e.speed=o,e.currentTime=i,r||mn(e.play())}),e.media.load())}Ue.call(e,e.media,"qualitychange",!1,{quality:t})}}})},cancelRequests(){this.isHTML5&&(Pn(Bn.getSources.call(this)),this.media.setAttribute("src",this.config.blankVideo),this.media.load(),this.debug.log("Cancelled network requests"))}};function sC(e){return`${e}-${Math.floor(1e4*Math.random())}`}function Io(e,...t){return $.empty(e)?e:e.toString().replace(/{(\d+)}/g,(n,i)=>t[i].toString())}function iC(e,t){return e===0||t===0||Number.isNaN(e)||Number.isNaN(t)?0:(e/t*100).toFixed(2)}const ni=(e="",t="",n="")=>e.replace(new RegExp(t.toString().replace(/([.*+?^=!:${}()|[\]/\\])/g,"\\$1"),"g"),n.toString()),Up=(e="")=>e.toString().replace(/\w\S*/g,t=>t.charAt(0).toUpperCase()+t.slice(1).toLowerCase());function rC(e=""){let t=e.toString();return t=ni(t,"-"," "),t=ni(t,"_"," "),t=Up(t),ni(t," ","")}function aC(e=""){let t=e.toString();return t=rC(t),t.charAt(0).toLowerCase()+t.slice(1)}function oC(e){const t=document.createDocumentFragment(),n=document.createElement("div");return t.appendChild(n),n.innerHTML=e,t.firstChild.innerText}function lC(e){const t=document.createElement("div");return t.appendChild(e),t.innerHTML}const _d={pip:"PIP",airplay:"AirPlay",html5:"HTML5",vimeo:"Vimeo",youtube:"YouTube"},Nt={get(e="",t={}){if($.empty(e)||$.empty(t))return"";let n=xp(t.i18n,e);if($.empty(n))return Object.keys(_d).includes(e)?_d[e]:"";const i={"{seektime}":t.seekTime,"{title}":t.title};
vendor: 4,206 bytes, line 30
30return Object.entries(i).forEach(([r,s])=>{n=ni(n,r,s)}),n}};class pi{constructor(t){xe(this,"get",n=>{if(!pi.supported||!this.enabled)return null;const i=window.localStorage.getItem(this.key);if($.empty(i))return null;const r=JSON.parse(i);return $.string(n)&&n.length?r[n]:r}),xe(this,"set",n=>{if(!pi.supported||!this.enabled||!$.object(n))return;let i=this.get();$.empty(i)&&(i={}),Et(i,n);try{window.localStorage.setItem(this.key,JSON.stringify(i))}catch{}}),this.enabled=t.config.storage.enabled,this.key=t.config.storage.key}static get supported(){try{if(!("localStorage"in window))return!1;const t="___test";return window.localStorage.setItem(t,t),window.localStorage.removeItem(t),!0}catch{return!1}}}function Ri(e,t="text"){return new Promise((n,i)=>{try{const r=new XMLHttpRequest;if(!("withCredentials"in r))return;r.addEventListener("load",()=>{if(t==="text")try{n(JSON.parse(r.responseText))}catch{n(r.responseText)}else n(r.response)}),r.addEventListener("error",()=>{throw new Error(r.status)}),r.open("GET",e,!0),r.responseType=t,r.send()}catch(r){i(r)}})}function Hp(e,t){if(!$.string(e))return;const n="cache",i=$.string(t);let r=!1;const s=()=>document.getElementById(t)!==null,a=(o,l)=>{o.innerHTML=l,i&&s()||document.body.insertAdjacentElement("afterbegin",o)};if(!i||!s()){const o=pi.supported,l=document.createElement("div");if(l.setAttribute("hidden",""),i&&l.setAttribute("id",t),o){const c=window.localStorage.getItem(`${n}-${t}`);if(r=c!==null,r){const d=JSON.parse(c);a(l,d.content)}}Ri(e).then(c=>{if(!$.empty(c)){if(o)try{window.localStorage.setItem(`${n}-${t}`,JSON.stringify({content:c}))}catch{}a(l,c)}}).catch(()=>{})}}const zp=e=>Math.trunc(e/60/60%60,10),cC=e=>Math.trunc(e/60%60,10),dC=e=>Math.trunc(e%60,10);function Wr(e=0,t=!1,n=!1){if(!$.number(e))return Wr(void 0,t,n);const i=o=>`0${o}`.slice(-2);let r=zp(e);const s=cC(e),a=dC(e);return r=t||r>0?`${r}:`:"",`${n&&e>0?"-":""}${r}${i(s)}:${i(a)}`}const Le={getIconUrl(){const e=new URL(this.config.iconUrl,window.location),t=window.location.host?window.location.host:window.top.location.host,n=e.host!==t||Dt.isIE&&!window.svg4everybody;return{url:this.config.iconUrl,cors:n}},findElements(){try{return this.elements.controls=At.call(this,this.config.selectors.controls.wrapper),this.elements.buttons={play:ui.call(this,this.config.selectors.buttons.play),pause:At.call(this,this.config.selectors.buttons.pause),restart:At.call(this,this.config.selectors.buttons.restart),rewind:At.call(this,this.config.selectors.buttons.rewind),fastForward:At.call(this,this.config.selectors.buttons.fastForward),mute:At.call(this,this.config.selectors.buttons.mute),pip:At.call(this,this.config.selectors.buttons.pip),airplay:At.call(this,this.config.selectors.buttons.airplay),settings:At.call(this,this.config.selectors.buttons.settings),captions:At.call(this,this.config.selectors.buttons.captions),fullscreen:At.call(this,this.config.selectors.buttons.fullscreen)},this.elements.progress=At.call(this,this.config.selectors.progress),this.elements.inputs={seek:At.call(this,this.config.selectors.inputs.seek),volume:At.call(this,this.config.selectors.inputs.volume)},this.elements.display={buffer:At.call(this,this.config.selectors.display.buffer),currentTime:At.call(this,this.config.selectors.display.currentTime),duration:At.call(this,this.config.selectors.display.duration)},$.element(this.elements.progress)&&(this.elements.display.seekTooltip=this.elements.progress.querySelector(`.${this.config.classNames.tooltip}`)),!0}catch(e){return this.debug.warn("It looks like there is a problem with your custom controls HTML",e),this.toggleNativeControls(!0),!1}},createIcon(e,t){const n="http://www.w3.org/2000/svg",i=Le.getIconUrl.call(this),r=`${i.cors?"":i.url}#${this.config.iconPrefix}`,s=document.createElementNS(n,"svg");So(s,Et(t,{"aria-hidden":"true",focusable:"false"}));const a=document.createElementNS(n,"use"),o=`${r}-${e}`;return"href"in a&&a.setAttributeNS("http://www.w3.org/1999/xlink","href",o),a.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",o),s.appendChild(a),s},createLabel(e,t={}){const n=Nt.get(e,this.config);return $e("span",{...t,class:[t.class,this.config.classNames.hidden].filter(
30Boolean).join(" ")},n)},createBadge(e){if($.empty(e))return null;const t=$e("span",{class:this.config.classNames.menu.value});return t.appendChild($e("span",{class:this.config.classNames.menu.badge},e)),t},createButton(e,t){const n=Et({},t);let i=aC(e);const r={element:"button",toggle:!1,label:null,icon:null,labelPressed:null,iconPressed:null};switch(["element","icon","label"].forEach(a=>{Object.keys(n).includes(a)&&(r[a]=n[a],delete n[a])}),r.element!=="button"||Object.keys(n).includes("type")||(n.type="button"),Object.keys(n).includes("class")?n.class.split(" ").some(a=>a===this.config.classNames.control)||Et(n,{class:`${n.class} ${this.config.classNames.control}`}):n.class=this.config.classNames.control,e){case"play":r.toggle=!0,r.label="play",r.labelPressed="pause",r.icon="play",r.iconPressed="pause";break;case"mute":r.toggle=!0,r.label="mute",r.labelPressed="unmute",r.icon="volume",r.iconPressed="muted";break;case"captions":r.toggle=!0,r.label="enableCaptions",r.labelPressed="disableCaptions",r.icon="captions-off",r.iconPressed="captions-on";break;case"fullscreen":r.toggle=!0,r.label="enterFullscreen",r.labelPressed="exitFullscreen",r.icon="enter-fullscreen",r.iconPressed="exit-fullscreen";break;case"play-large":n.class+=` ${this.config.classNames.control}--overlaid`,i="play",r.label="play",r.icon="play";break;default:$.empty(r.label)&&(r.label=i),$.empty(r.icon)&&(r.icon=e)}const s=$e(r.element);return r.toggle?(s.appendChild(Le.createIcon.call(this,r.iconPressed,{class:"icon--pressed"})),s.appendChild(Le.createIcon.call(this,r.icon,{class:"icon--not-pressed"})),s.appendChild(Le.createLabel.call(this,r.labelPressed,{class:"label--pressed"})),s.appendChild(Le.createLabel.call(this,r.label,{class:"label--not-pressed"}))):(s.appendChild(Le.createIcon.call(this,r.icon)),s.appendChild(Le.createLabel.call(this,r.label))),Et(n,pn(this.config.selectors.buttons[i],n)),So(s,n),i==="play"?($.array(this.elements.buttons[i])||(this.elements.buttons[i]=[]),this.elements.buttons[i].push(s)):this.elements.buttons[i]=s,s},createRange(e,t){const n=$e("input",Et(pn(this.config.selectors.inputs[e]),{type:"range",min:0,max:100,step:.01,value:0,autocomplete:"off",role:"slider","aria-label":Nt.get(e,this.config),"aria-valuemin":0,"aria-valuemax":100,"aria-valuenow":0},t));return this.elements.inputs[e]=n,Le.updateRangeFill.call(this,n),LS.setup(n),n},createProgress(e,t){const n=$e("progress",Et(pn(this.config.selectors.display[e]),{min:0,max:100,value:0,role:"progressbar","aria-hidden":!0},t));if(e!=="volume"){n.appendChild($e("span",null,"0"));const i={played:"played",buffer:"buffered"}[e],r=i?Nt.get(i,this.config):"";n.innerText=`% ${r.toLowerCase()}`}return this.elements.display[e]=n,n},createTime(e,t){const n=pn(this.config.selectors.display[e],t),i=$e("div",Et(n,{class:`${n.class?n.class:""} ${this.config.classNames.display.time} `.trim(),"aria-label":Nt.get(e,this.config),role:"timer"}),"00:00");return this.elements.display[e]=i,i},bindMenuItemShortcuts(e,t){Ze.call(this,e,"keydown keyup",n=>{if(![" ","ArrowUp","ArrowDown","ArrowRight"].includes(n.key)||(n.preventDefault(),n.stopPropagation(),n.type==="keydown"))return;const i=rs(e,'[role="menuitemradio"]');if(!i&&[" ","ArrowRight"].includes(n.key))Le.showMenuPanel.call(this,t,!0);else{let r;n.key!==" "&&(n.key==="ArrowDown"||i&&n.key==="ArrowRight"?(r=e.nextElementSibling,$.element(r)||(r=e.parentNode.firstElementChild)):(r=e.previousElementSibling,$.element(r)||(r=e.parentNode.lastElementChild)),Ca.call(this,r,!0))}},!1),Ze.call(this,e,"keyup",n=>{n.key==="Return"&&Le.focusFirstMenuItem.call(this,null,!0)})},createMenuItem({value:e,list:t,type:n,title:i,badge:r=null,checked:s=!1}){const a=pn(this.config.selectors.inputs[n]),o=$e("button",Et(a,{type:"button",role:"menuitemradio",class:`${this.config.classNames.control} ${a.class?a.class:""}`.trim(),"aria-checked":s,value:e})),l=$e("span");l.innerHTML=i,$.element(r)&&l.appendChild(r),o.appendChild(l),Object.defineProperty(o,"checked",{enumerable:!0,get:()=>o.getAttribute("aria-checked")==="true",set(c){c&&Array.from(o.parentNode.children).filter(d=>
30rs(d,'[role="menuitemradio"]')).forEach(d=>d.setAttribute("aria-checked","false")),o.setAttribute("aria-checked",c?"true":"false")}}),this.listeners.bind(o,"click keyup",c=>{if(!$.keyboardEvent(c)||c.key===" "){switch(c.preventDefault(),c.stopPropagation(),o.checked=!0,n){case"language":this.currentTrack=Number(e);break;case"quality":this.quality=e;break;case"speed":this.speed=parseFloat(e)}Le.showMenuPanel.call(this,"home",$.keyboardEvent(c))}},n,!1),Le.bindMenuItemShortcuts.call(this,o,n),t.appendChild(o)},formatTime(e=0,t=!1){return $.number(e)?Wr(e,zp(this.duration)>0,t):e},updateTimeDisplay(e=null,t=0,n=!1){$.element(e)&&$.number(t)&&(e.innerText=Le.formatTime(t,n))},updateVolume(){this.supported.ui&&($.element(this.elements.inputs.volume)&&Le.setRange.call(this,this.elements.inputs.volume,this.muted?0:this.volume),$.element(this.elements.buttons.mute)&&(this.elements.buttons.mute.pressed=this.muted||this.volume===0))},setRange(e,t=0){$.element(e)&&(e.value=t,Le.updateRangeFill.call(this,e))},updateProgress(e){if(!this.supported.ui||!$.event(e))return;let t=0;const n=(i,r)=>{const s=$.number(r)?r:0,a=$.element(i)?i:this.elements.display.buffer;if($.element(a)){a.value=s;const o=a.getElementsByTagName("span")[0];$.element(o)&&(o.childNodes[0].nodeValue=s)}};if(e)switch(e.type){case"timeupdate":case"seeking":case"seeked":t=iC(this.currentTime,this.duration),e.type==="timeupdate"&&Le.setRange.call(this,this.elements.inputs.seek,t);break;case"playing":case"progress":n(this.elements.display.buffer,100*this.buffered)}},updateRangeFill(e){const t=$.event(e)?e.target:e;if($.element(t)&&t.getAttribute("type")==="range"){if(rs(t,this.config.selectors.inputs.seek)){t.setAttribute("aria-valuenow",this.currentTime);const n=Le.formatTime(this.currentTime),i=Le.formatTime(this.duration),r=Nt.get("seekLabel",this.config);t.setAttribute("aria-valuetext",r.replace("{currentTime}",n).replace("{duration}",i))}else if(rs(t,this.config.selectors.inputs.volume)){const n=100*t.value;t.setAttribute("aria-valuenow",n),t.setAttribute("aria-valuetext",`${n.toFixed(1)}%`)}else t.setAttribute("aria-valuenow",t.value);(Dt.isWebKit||Dt.isIPadOS)&&t.style.setProperty("--value",t.value/t.max*100+"%")}},updateSeekTooltip(e){var t,n;if(!this.config.tooltips.seek||!$.element(this.elements.inputs.seek)||!$.element(this.elements.display.seekTooltip)||this.duration===0)return;const i=this.elements.display.seekTooltip,r=`${this.config.classNames.tooltip}--visible`,s=d=>nt(i,r,d);if(this.touch)return void s(!1);let a=0;const o=this.elements.progress.getBoundingClientRect();if($.event(e))a=100/o.width*(e.pageX-o.left);else{if(!gr(i,r))return;a=parseFloat(i.style.left,10)}a<0?a=0:a>100&&(a=100);const l=this.duration/100*a;i.innerText=Le.formatTime(l);const c=(t=this.config.markers)===null||t===void 0||(n=t.points)===null||n===void 0?void 0:n.find(({time:d})=>d===Math.round(l));c&&i.insertAdjacentHTML("afterbegin",`${c.label}<br>`),i.style.left=`${a}%`,$.event(e)&&["mouseenter","mouseleave"].includes(e.type)&&s(e.type==="mouseenter")},timeUpdate(e){const t=!$.element(this.elements.display.duration)&&this.config.invertTime;Le.updateTimeDisplay.call(this,this.elements.display.currentTime,t?this.duration-this.currentTime:this.currentTime,t),e&&e.type==="timeupdate"&&this.media.seeking||Le.updateProgress.call(this,e)},durationUpdate(){if(!this.supported.ui||!this.config.invertTime&&this.currentTime)return;if(this.duration>=2**32)return Xn(this.elements.display.currentTime,!0),void Xn(this.elements.progress,!0);$.element(this.elements.inputs.seek)&&this.elements.inputs.seek.setAttribute("aria-valuemax",this.duration);const e=$.element(this.elements.display.duration);!e&&this.config.displayDuration&&this.paused&&Le.updateTimeDisplay.call(this,this.elements.display.currentTime,this.duration),e&&Le.updateTimeDisplay.call(this,this.elements.display.duration,this.duration),this.config.markers.enabled&&Le.setMarkers.call(this),Le.updateSeekTooltip.call(this)},toggleMenuButton(e,t){Xn(this.elements.settings.buttons[e],!t)},updateSetting(e,t,n){const i=this.elements.settings.panels[e];let r=null,s=t;if(e==="captions")r=this.currentTrack;else{if(r=$.empty(n)?this[e]:n,$.empty(r)&&(r=this.config[e].default),!$.empty(this.options[e])&&!this.options[e].includes(r))return void this.debug.warn(`Unsupported value of '${r}' for ${e}`);if(!this.config[e].options.includes(r))return void this.debug.warn(`Disabled value of '${r}' for ${e}`)}if($.element(s)||(s=i&&i.querySelector('[role="menu"]')),!$.element(s))return;this.elements.settings.buttons[e].querySelector(`.${this.config.classNames.menu.value}`).innerHTML=Le.getLabel.call(this,e,r);const a=s&&s.querySelector(`[value="${r}"]`);$.element(a)&&(a.checked=!0)},getLabel(e,t){switch(e){case"speed":return t===1?Nt.get("normal",this.config):`${t}&times;`;case"quality":if($.number(t)){const n=Nt.get(`qualityLabel.${t}`,this.config);return n.length?n:`${t}p`}return Up(t);case"captions":return qe.getLabel.call(this);default:return null}},setQualityMenu(e){if(!$.element(this.elements.settings.panels.quality))return;const t="quality",n=this.elements.settings.panels.quality.querySelector('[role="menu"]');$.array(e)&&(this.options.quality=Co(e).filter(s=>this.config.quality.options.includes(s)));const i=!$.empty(this.options.quality)&&this.options.quality.length>1;if(Le.toggleMenuButton.call(this,t,i),Xi(n),Le.checkMenu.call(this),!i)return;const r=s=>{const a=Nt.get(`qualityBadge.${s}`,this.config);return a.length?Le.createBadge.call(this,a):null};this.options.quality.sort((s,a)=>{const o=this.config.quality.options;return o.indexOf(s)>o.indexOf(a)?1:-1}
vendor: 3,070 bytes, line 30
30).forEach(s=>{Le.createMenuItem.call(this,{value:s,list:n,type:t,title:Le.getLabel.call(this,"quality",s),badge:r(s)})}),Le.updateSetting.call(this,t,n)},setCaptionsMenu(){if(!$.element(this.elements.settings.panels.captions))return;const e="captions",t=this.elements.settings.panels.captions.querySelector('[role="menu"]'),n=qe.getTracks.call(this),i=!!n.length;if(Le.toggleMenuButton.call(this,e,i),Xi(t),Le.checkMenu.call(this),!i)return;const r=n.map((s,a)=>({value:a,checked:this.captions.toggled&&this.currentTrack===a,title:qe.getLabel.call(this,s),badge:s.language&&Le.createBadge.call(this,s.language.toUpperCase()),list:t,type:"language"}));r.unshift({value:-1,checked:!this.captions.toggled,title:Nt.get("disabled",this.config),list:t,type:"language"}),r.forEach(Le.createMenuItem.bind(this)),Le.updateSetting.call(this,e,t)},setSpeedMenu(){if(!$.element(this.elements.settings.panels.speed))return;const e="speed",t=this.elements.settings.panels.speed.querySelector('[role="menu"]');this.options.speed=this.options.speed.filter(i=>i>=this.minimumSpeed&&i<=this.maximumSpeed);const n=!$.empty(this.options.speed)&&this.options.speed.length>1;Le.toggleMenuButton.call(this,e,n),Xi(t),Le.checkMenu.call(this),n&&(this.options.speed.forEach(i=>{Le.createMenuItem.call(this,{value:i,list:t,type:e,title:Le.getLabel.call(this,"speed",i)})}),Le.updateSetting.call(this,e,t))},checkMenu(){const{buttons:e}=this.elements.settings,t=!$.empty(e)&&Object.values(e).some(n=>!n.hidden);Xn(this.elements.settings.menu,!t)},focusFirstMenuItem(e,t=!1){if(this.elements.settings.popup.hidden)return;let n=e;$.element(n)||(n=Object.values(this.elements.settings.panels).find(r=>!r.hidden));const i=n.querySelector('[role^="menuitem"]');Ca.call(this,i,t)},toggleMenu(e){const{popup:t}=this.elements.settings,n=this.elements.buttons.settings;if(!$.element(t)||!$.element(n))return;const{hidden:i}=t;let r=i;if($.boolean(e))r=e;else if($.keyboardEvent(e)&&e.key==="Escape")r=!1;else if($.event(e)){const s=$.function(e.composedPath)?e.composedPath()[0]:e.target,a=t.contains(s);if(a||!a&&e.target!==n&&r)return}n.setAttribute("aria-expanded",r),Xn(t,!r),nt(this.elements.container,this.config.classNames.menu.open,r),r&&$.keyboardEvent(e)?Le.focusFirstMenuItem.call(this,null,!0):r||i||Ca.call(this,n,$.keyboardEvent(e))},getMenuSize(e){const t=e.cloneNode(!0);t.style.position="absolute",t.style.opacity=0,t.removeAttribute("hidden"),e.parentNode.appendChild(t);const n=t.scrollWidth,i=t.scrollHeight;return Pn(t),{width:n,height:i}},showMenuPanel(e="",t=!1){const n=this.elements.container.querySelector(`#plyr-settings-${this.id}-${e}`);if(!$.element(n))return;const i=n.parentNode,r=Array.from(i.children).find(s=>!s.hidden);if(St.transitions&&!St.reducedMotion){i.style.width=`${r.scrollWidth}px`,i.style.height=`${r.scrollHeight}px`;const s=Le.getMenuSize.call(this,n),a=o=>{o.target===i&&["width","height"].includes(o.propertyName)&&(i.style.width="",i.style.height="",Yr.call(this,i,Eo,a))};Ze.call(this,i,Eo,a),i.style.width=`${s.width}px`,i.style.height=`${s.height}px`}
30Xn(r,!0),Xn(n,!1),Le.focusFirstMenuItem.call(this,n,t)},setDownloadUrl(){const e=this.elements.buttons.download;$.element(e)&&e.setAttribute("href",this.download)},create(e){const{bindMenuItemShortcuts:t,createButton:n,createProgress:i,createRange:r,createTime:s,setQualityMenu:a,setSpeedMenu:o,showMenuPanel:l}=Le;this.elements.controls=null,$.array(this.config.controls)&&this.config.controls.includes("play-large")&&this.elements.container.appendChild(n.call(this,"play-large"));const c=$e("div",pn(this.config.selectors.controls.wrapper));this.elements.controls=c;const d={class:"plyr__controls__item"};return Co($.array(this.config.controls)?this.config.controls:[]).forEach(u=>{if(u==="restart"&&c.appendChild(n.call(this,"restart",d)),u==="rewind"&&c.appendChild(n.call(this,"rewind",d)),u==="play"&&c.appendChild(n.call(this,"play",d)),u==="fast-forward"&&c.appendChild(n.call(this,"fast-forward",d)),u==="progress"){const p=$e("div",{class:`${d.class} plyr__progress__container`}),h=$e("div",pn(this.config.selectors.progress));if(h.appendChild(r.call(this,"seek",{id:`plyr-seek-${e.id}`})),h.appendChild(i.call(this,"buffer")),this.config.tooltips.seek){const m=$e("span",{class:this.config.classNames.tooltip},"00:00");h.appendChild(m),this.elements.display.seekTooltip=m}this.elements.progress=h,p.appendChild(this.elements.progress),c.appendChild(p)}if(u==="current-time"&&c.appendChild(s.call(this,"currentTime",d)),u==="duration"&&c.appendChild(s.call(this,"duration",d)),u==="mute"||u==="volume"){let{volume:p}=this.elements;if($.element(p)&&c.contains(p)||(p=$e("div",Et({},d,{class:`${d.class} plyr__volume`.trim()})),this.elements.volume=p,c.appendChild(p)),u==="mute"&&p.appendChild(n.call(this,"mute")),u==="volume"&&!Dt.isIos&&!Dt.isIPadOS){const h={max:1,step:.05,value:this.config.volume};p.appendChild(r.call(this,"volume",Et(h,{id:`plyr-volume-${e.id}`})))}}if(u==="captions"&&c.appendChild(n.call(this,"captions",d)),u==="settings"&&!$.empty(this.config.settings)){const p=$e("div",Et({},d,{class:`${d.class} plyr__menu`.trim(),hidden:""}));p.appendChild(n.call(this,"settings",{"aria-haspopup":!0,"aria-controls":`plyr-settings-${e.id}`,"aria-expanded":!1}));const h=$e("div",{class:"plyr__menu__container",id:`plyr-settings-${e.id}`,hidden:""}),m=$e("div"),v=$e("div",{id:`plyr-settings-${e.id}-home`}),_=$e("div",{role:"menu"});v.appendChild(_),m.appendChild(v),this.elements.settings.panels.home=v,this.config.settings.forEach(b=>{const w=$e("button",Et(pn(this.config.selectors.buttons.settings),{type:"button",class:`${this.config.classNames.control} ${this.config.classNames.control}--forward`,role:"menuitem","aria-haspopup":!0,hidden:""}));t.call(this,w,b),Ze.call(this,w,"click",()=>{l.call(this,b,!1)});const C=$e("span",null,Nt.get(b,this.config)),O=$e("span",{class:this.config.classNames.menu.value});O.innerHTML=e[b],C.appendChild(O),w.appendChild(C),_.appendChild(w);const T=$e("div",{id:`plyr-settings-${e.id}-${b}`,hidden:""}),E=$e("button",{type:"button",class:`${this.config.classNames.control} ${this.config.classNames.control}--back`});E.appendChild($e("span",{"aria-hidden":!0},Nt.get(b,this.config))),E.appendChild($e("span",{class:this.config.classNames.hidden},Nt.get("menuBack",this.config))),Ze.call(this,T,"keydown",y=>{y.key==="ArrowLeft"&&(y.preventDefault(),y.stopPropagation(),l.call(this,"home",!0))},!1),Ze.call(this,E,"click",()=>{l.call(this,"home",!1)}),T.appendChild(E),T.appendChild($e("div",{role:"menu"})),m.appendChild(T),this.elements.settings.buttons[b]=w,this.elements.settings.panels[b]=T}),h.appendChild(m),p.appendChild(h),c.appendChild(p),this.elements.settings.popup=h,this.elements.settings.menu=p}if(u==="pip"&&St.pip&&c.appendChild(n.call(this,"pip",d)),u==="airplay"&&St.airplay&&c.appendChild(n.call(this,"airplay",d)),u==="download"){const p=Et({},d,{element:"a",href:this.download,target:"_blank"});this.isHTML5&&(p.download="");const{download:h}=this.config.urls;!$.url(h)&&this.isEmbed&&Et(p,{icon:`logo-${this.provider}`,label:this.provider}),c.appendChild(n.call(this,"download",p))}u==="fullscreen"&&c.appendChild(n.call(this,"fullscreen",d))}),this.isHTML5&&a.call(this,Bn.getQualityOptions.call(this)),o.call(this),c},inject(){if(this.config.loadSprite){const r=Le.getIconUrl.call(this);r.cors&&Hp(r.url,"sprite-plyr")}this.id=Math.floor(1e4*Math.random());let e=null;this.elements.controls=null;const t={id:this.id,seektime:this.config.seekTime,title:this.config.title};let n=!0;
vendor: 4,482 bytes, line 30
30$.function(this.config.controls)&&(this.config.controls=this.config.controls.call(this,t)),this.config.controls||(this.config.controls=[]),$.element(this.config.controls)||$.string(this.config.controls)?e=this.config.controls:(e=Le.create.call(this,{id:this.id,seektime:this.config.seekTime,speed:this.speed,quality:this.quality,captions:qe.getLabel.call(this)}),n=!1);let i;if(n&&$.string(this.config.controls)&&(e=(r=>{let s=r;return Object.entries(t).forEach(([a,o])=>{s=ni(s,`{${a}}`,o)}),s})(e)),$.string(this.config.selectors.controls.container)&&(i=document.querySelector(this.config.selectors.controls.container)),$.element(i)||(i=this.elements.container),i[$.element(e)?"insertAdjacentElement":"insertAdjacentHTML"]("afterbegin",e),$.element(this.elements.controls)||Le.findElements.call(this),!$.empty(this.elements.buttons)){const r=s=>{const a=this.config.classNames.controlPressed;s.setAttribute("aria-pressed","false"),Object.defineProperty(s,"pressed",{configurable:!0,enumerable:!0,get:()=>gr(s,a),set(o=!1){nt(s,a,o),s.setAttribute("aria-pressed",o?"true":"false")}})};Object.values(this.elements.buttons).filter(Boolean).forEach(s=>{$.array(s)||$.nodeList(s)?Array.from(s).filter(Boolean).forEach(r):r(s)})}if(Dt.isEdge&&Dp(i),this.config.tooltips.controls){const{classNames:r,selectors:s}=this.config,a=`${s.controls.wrapper} ${s.labels} .${r.hidden}`,o=ui.call(this,a);Array.from(o).forEach(l=>{nt(l,this.config.classNames.hidden,!1),nt(l,this.config.classNames.tooltip,!0)})}},setMediaMetadata(){try{"mediaSession"in navigator&&(navigator.mediaSession.metadata=new window.MediaMetadata({title:this.config.mediaMetadata.title,artist:this.config.mediaMetadata.artist,album:this.config.mediaMetadata.album,artwork:this.config.mediaMetadata.artwork}))}catch{}},setMarkers(){var e,t;if(!this.duration||this.elements.markers)return;const n=(e=this.config.markers)===null||e===void 0||(t=e.points)===null||t===void 0?void 0:t.filter(({time:l})=>l>0&&l<this.duration);if(n==null||!n.length)return;const i=document.createDocumentFragment(),r=document.createDocumentFragment();let s=null;const a=`${this.config.classNames.tooltip}--visible`,o=l=>nt(s,a,l);n.forEach(l=>{const c=$e("span",{class:this.config.classNames.marker},""),d=l.time/this.duration*100+"%";s&&(c.addEventListener("mouseenter",()=>{l.label||(s.style.left=d,s.innerHTML=l.label,o(!0))}),c.addEventListener("mouseleave",()=>{o(!1)})),c.addEventListener("click",()=>{this.currentTime=l.time}),c.style.left=d,r.appendChild(c)}),i.appendChild(r),this.config.tooltips.seek||(s=$e("span",{class:this.config.classNames.tooltip},""),i.appendChild(s)),this.elements.markers={points:r,tip:s},this.elements.progress.appendChild(i)}};function Kp(e,t=!0){let n=e;if(t){const i=document.createElement("a");i.href=n,n=i.href}try{return new URL(n)}catch{return null}}function Gp(e){const t=new URLSearchParams;return $.object(e)&&Object.entries(e).forEach(([n,i])=>{t.set(n,i)}),t}const qe={setup(){if(!this.supported.ui)return;if(!this.isVideo||this.isYouTube||this.isHTML5&&!St.textTracks)return void($.array(this.config.controls)&&this.config.controls.includes("settings")&&this.config.settings.includes("captions")&&Le.setCaptionsMenu.call(this));if($.element(this.elements.captions)||(this.elements.captions=$e("div",pn(this.config.selectors.captions)),this.elements.captions.setAttribute("dir","auto"),qS(this.elements.captions,this.elements.wrapper)),Dt.isIE&&window.URL){const i=this.media.querySelectorAll("track");Array.from(i).forEach(r=>{const s=r.getAttribute("src"),a=Kp(s);a!==null&&a.hostname!==window.location.href.hostname&&["http:","https:"].includes(a.protocol)&&Ri(s,"blob").then(o=>{r.setAttribute("src",window.URL.createObjectURL(o))}).catch(()=>{Pn(r)})})}const e=Co((navigator.languages||[navigator.language||navigator.userLanguage||"en"]).map(i=>i.split("-")[0]));let t=(this.storage.get("language")||this.config.captions.language||"auto").toLowerCase();t==="auto"&&([t]=e);let n=this.storage.get("captions");if($.boolean(n)||({active:n}=this.config.captions),Object.assign(this.captions,{toggled:!1,active:n,language:t,languages:e}),this.isHTML5){const i=this.config.captions.update?"addtrack removetrack":"removetrack";Ze.call(this,this.media.textTracks,i,qe.update.bind(this))}setTimeout(qe.update.bind(this),0)},update(){const e=qe.getTracks.call(this,!0),{active:t,language:n,meta:i,currentTrackNode:r}=this.captions,s=!!e.find(a=>a.language===n);this.isHTML5&&this.isVideo&&e.filter(a=>
vendor: 5,161 bytes, lines 30-31
30!i.get(a)).forEach(a=>{this.debug.log("Track added",a),i.set(a,{default:a.mode==="showing"}),a.mode==="showing"&&(a.mode="hidden"),Ze.call(this,a,"cuechange",()=>qe.updateCues.call(this))}),(s&&this.language!==n||!e.includes(r))&&(qe.setLanguage.call(this,n),qe.toggle.call(this,t&&s)),this.elements&&nt(this.elements.container,this.config.classNames.captions.enabled,!$.empty(e)),$.array(this.config.controls)&&this.config.controls.includes("settings")&&this.config.settings.includes("captions")&&Le.setCaptionsMenu.call(this)},toggle(e,t=!0){if(!this.supported.ui)return;const{toggled:n}=this.captions,i=this.config.classNames.captions.active,r=$.nullOrUndefined(e)?!n:e;if(r!==n){if(t||(this.captions.active=r,this.storage.set({captions:r})),!this.language&&r&&!t){const s=qe.getTracks.call(this),a=qe.findTrack.call(this,[this.captions.language,...this.captions.languages],!0);return this.captions.language=a.language,void qe.set.call(this,s.indexOf(a))}this.elements.buttons.captions&&(this.elements.buttons.captions.pressed=r),nt(this.elements.container,i,r),this.captions.toggled=r,Le.updateSetting.call(this,"captions"),Ue.call(this,this.media,r?"captionsenabled":"captionsdisabled")}setTimeout(()=>{r&&this.captions.toggled&&(this.captions.currentTrackNode.mode="hidden")})},set(e,t=!0){const n=qe.getTracks.call(this);if(e!==-1)if($.number(e))if(e in n){if(this.captions.currentTrack!==e){this.captions.currentTrack=e;const i=n[e],{language:r}=i||{};this.captions.currentTrackNode=i,Le.updateSetting.call(this,"captions"),t||(this.captions.language=r,this.storage.set({language:r})),this.isVimeo&&this.embed.enableTextTrack(r),Ue.call(this,this.media,"languagechange")}qe.toggle.call(this,!0,t),this.isHTML5&&this.isVideo&&qe.updateCues.call(this)}else this.debug.warn("Track not found",e);else this.debug.warn("Invalid caption argument",e);else qe.toggle.call(this,!1,t)},setLanguage(e,t=!0){if(!$.string(e))return void this.debug.warn("Invalid language argument",e);const n=e.toLowerCase();this.captions.language=n;const i=qe.getTracks.call(this),r=qe.findTrack.call(this,[n]);qe.set.call(this,i.indexOf(r),t)},getTracks(e=!1){return Array.from((this.media||{}).textTracks||[]).filter(t=>!this.isHTML5||e||this.captions.meta.has(t)).filter(t=>["captions","subtitles"].includes(t.kind))},findTrack(e,t=!1){const n=qe.getTracks.call(this),i=a=>Number((this.captions.meta.get(a)||{}).default),r=Array.from(n).sort((a,o)=>i(o)-i(a));let s;return e.every(a=>(s=r.find(o=>o.language===a),!s)),s||(t?r[0]:void 0)},getCurrentTrack(){return qe.getTracks.call(this)[this.currentTrack]},getLabel(e){let t=e;return!$.track(t)&&St.textTracks&&this.captions.toggled&&(t=qe.getCurrentTrack.call(this)),$.track(t)?$.empty(t.label)?$.empty(t.language)?Nt.get("enabled",this.config):e.language.toUpperCase():t.label:Nt.get("disabled",this.config)},updateCues(e){if(!this.supported.ui)return;if(!$.element(this.elements.captions))return void this.debug.warn("No captions element to render to");if(!$.nullOrUndefined(e)&&!Array.isArray(e))return void this.debug.warn("updateCues: Invalid input",e);let t=e;if(!t){const i=qe.getCurrentTrack.call(this);t=Array.from((i||{}).activeCues||[]).map(r=>r.getCueAsHTML()).map(lC)}const n=t.map(i=>i.trim()).join(`
31`);if(n!==this.elements.captions.innerHTML){Xi(this.elements.captions);const i=$e("span",pn(this.config.selectors.caption));i.innerHTML=n,this.elements.captions.appendChild(i),Ue.call(this,this.media,"cuechange")}}},jp={enabled:!0,title:"",debug:!1,autoplay:!1,autopause:!0,playsinline:!0,seekTime:10,volume:1,muted:!1,duration:null,displayDuration:!0,invertTime:!0,toggleInvert:!0,ratio:null,clickToPlay:!0,hideControls:!0,resetOnEnd:!1,disableContextMenu:!0,loadSprite:!0,iconPrefix:"plyr",iconUrl:"https://cdn.plyr.io/3.7.8/plyr.svg",blankVideo:"https://cdn.plyr.io/static/blank.mp4",quality:{default:576,options:[4320,2880,2160,1440,1080,720,576,480,360,240],forced:!1,onChange:null},loop:{active:!1},speed:{selected:1,options:[.5,.75,1,1.25,1.5,1.75,2,4]},keyboard:{focused:!0,global:!1},tooltips:{controls:!1,seek:!0},captions:{active:!1,language:"auto",update:!1},fullscreen:{enabled:!0,fallback:!0,iosNative:!1},storage:{enabled:!0,key:"plyr"},controls:["play-large","play","progress","current-time","mute","volume","captions","settings","pip","airplay","fullscreen"],settings:["captions","quality","speed"],i18n:{restart:"Restart",rewind:"Rewind {seektime}s",play:"Play",pause:"Pause",fastForward:"Forward {seektime}s",seek:"Seek",seekLabel:"{currentTime} of {duration}",played:"Played",buffered:"Buffered",currentTime:"Current time",duration:"Duration",volume:"Volume",mute:"Mute",unmute:"Unmute",enableCaptions:"Enable captions",disableCaptions:"Disable captions",download:"Download",enterFullscreen:"Enter fullscreen",exitFullscreen:"Exit fullscreen",frameTitle:"Player for {title}",captions:"Captions",settings:"Settings",pip:"PIP",menuBack:"Go back to previous menu",speed:"Speed",normal:"Normal",quality:"Quality",loop:"Loop",start:"Start",end:"End",all:"All",reset:"Reset",disabled:"Disabled",enabled:"Enabled",advertisement:"Ad",qualityBadge:{2160:"4K",1440:"HD",1080:"HD",720:"HD",576:"SD",480:"S
31D"}},urls:{download:null,vimeo:{sdk:"https://player.vimeo.com/api/player.js",iframe:"https://player.vimeo.com/video/{0}?{1}",api:"https://vimeo.com/api/oembed.json?url={0}"},youtube:{sdk:"https://www.youtube.com/iframe_api",api:"https://noembed.com/embed?url=https://www.youtube.com/watch?v={0}"},googleIMA:{sdk:"https://imasdk.googleapis.com/js/sdkloader/ima3.js"}},listeners:{seek:null,play:null,pause:null,restart:null,rewind:null,fastForward:null,mute:null,volume:null,captions:null,download:null,fullscreen:null,pip:null,airplay:null,speed:null,quality:null,loop:null,language:null},events:["ended","progress","stalled","playing","waiting","canplay","canplaythrough","loadstart","loadeddata","loadedmetadata","timeupdate","volumechange","play","pause","error","seeking","seeked","emptied","ratechange","cuechange","download","enterfullscreen","exitfullscreen","captionsenabled","captionsdisabled","languagechange","controlshidden","controlsshown","ready","statechange","qualitychange","adsloaded","adscontentpause","adscontentresume","adstarted","adsmidpoint","adscomplete","adsallcomplete","adsimpression","adsclick"],selectors:{editable:"input, textarea, select, [contenteditable]",container:".plyr",controls:{container:null,wrapper:".plyr__controls"},labels:"[data-plyr]",buttons:{play:'[data-plyr="play"]',pause:'[data-plyr="pause"]',restart:'[data-plyr="restart"]',rewind:'[data-plyr="rewind"]',fastForward:'[data-plyr="fast-forward"]',mute:'[data-plyr="mute"]',captions:'[data-plyr="captions"]',download:'[data-plyr="download"]',fullscreen:'[data-plyr="fullscreen"]',pip:'[data-plyr="pip"]',airplay:'[data-plyr="airplay"]',settings:'[data-plyr="settings"]',loop:'[data-plyr="loop"]'},inputs:{seek:'[data-plyr="seek"]',volume:'[data-plyr="volume"]',speed:'[data-plyr="speed"]',language:'[data-plyr="language"]',quality:'[data-plyr="quality"]'},display:{currentTime:".plyr__time--current",duration:".plyr__time--duration",buffer:".plyr__progress__buffer",loop:".plyr__progress__loop",volume:".plyr__volume--display"},progress:".plyr__progress",captions:".plyr__captions",caption:".plyr__caption"},classNames:{type:"plyr--{0}",provider:"plyr--{0}",video:"plyr__video-wrapper",embed:"plyr__video-embed",videoFixedRatio:"plyr__video-wrapper--fixed-ratio",embedContainer:"plyr__video-embed__container",poster:"plyr__poster",posterEnabled:"plyr__poster-enabled",ads:"plyr__ads",control:"plyr__control",controlPressed:"plyr__control--pressed",playing:"plyr--playing",paused:"plyr--paused",stopped:"plyr--stopped",loading:"plyr--loading",hover:"plyr--hover",tooltip:"plyr__tooltip",cues:"plyr__cues",marker:"plyr__progress__marker",hidden:"plyr__sr-only",hideControls:"plyr--hide-controls",isTouch:"plyr--is-touch",uiSupported:"plyr--full-ui",noTransition:"plyr--no-transition",display:{time:"plyr__time"},menu:{value:"plyr__menu__value",badge:"plyr__badge",open:"plyr--menu-open"},captions:{enabled:"plyr--captions-enabled",active:"plyr--captions-active"},fullscreen:{enabled:"plyr--fullscreen-enabled",fallback:"plyr--fullscreen-fallback"},pip:{supported:"plyr--pip-supported",active:"plyr--pip-active"},airplay:{supported:"plyr--airplay-supported",active:"plyr--airplay-active"},previewThumbnails:{thumbContainer:"plyr__preview-thumb",thumbContainerShown:"plyr__preview-thumb--is-shown",imageContainer:"plyr__preview-thumb__image-container",timeContainer:"plyr__preview-thumb__time-container",scrubbingContainer:"plyr__preview-scrubbing",scrubbingContainerShown:"plyr__preview-scrubbing--is-shown"}},attributes:{embed:{provider:"data-plyr-provider",id:"data-plyr-embed-id",hash:"data-plyr-embed-hash"}},ads:{enabled:!1,publisherId:"",tagUrl:""},previewThumbnails:{enabled:!1,src:""},vimeo:{byline:!1,portrait:!1,title:!1,speed:!0,transparent:!1,customControls:!0,referrerPolicy:null,premium:!1},youtube:{rel:0,showinfo:0,iv_load_policy:3,modestbranding:1,customControls:!0,noCookie:!1},mediaMetadata:{title:"",artist:"",album:"",artwork:[]},markers:{enabled:!1,points:[]}},Ia={active:"picture-in-picture",inactive:"inline"},Vn={html5:"html5",youtube:"youtube",vimeo:"vimeo"},Ta={audio:"audio",video:"video"};function uC(e){return/^(https?:\/\/)?(www\.)?(youtube\.com|youtube-nocookie\.com|youtu\.?be)\/.+$/.test(e)?Vn.youtube:/^https?:\/\/player.vimeo.com\/video\/\d{0,9}(?=\b|\/)/.test(e)?Vn.vimeo:null}const Pa=()=>{};class hC{constructor(t=!1){this.enabled=window.console&&t,this.enabled&&this.log("Debugging enabled")}get log(){return this.enabled?Function.prototype.bind.call(console.log,console):Pa}get warn(){return this.enabled?Function.prototype.bind.call(console.warn,console):Pa}get error(){return this.enabled?Function.prototype.bind.call(console.error,console):Pa}}class tn{constructor(t){xe(this,"onChange",()=>{if(!this.supported)return;const n=this.player.elements.buttons.fullscreen;$.element(n)&&(n.pressed=this.active);const i=this.target===this.player.media?this.target:this.player.elements.container;Ue.call(this.player,i,this.active?"enterfullscreen":"exitfullscreen",!0)}),xe(this,"toggleFallback",(n=!1)=>
31{if(n?this.scrollPosition={x:window.scrollX??0,y:window.scrollY??0}:window.scrollTo(this.scrollPosition.x,this.scrollPosition.y),document.body.style.overflow=n?"hidden":"",nt(this.target,this.player.config.classNames.fullscreen.fallback,n),Dt.isIos){let i=document.head.querySelector('meta[name="viewport"]');const r="viewport-fit=cover";i||(i=document.createElement("meta"),i.setAttribute("name","viewport"));const s=$.string(i.content)&&i.content.includes(r);n?(this.cleanupViewport=!s,s||(i.content+=`,${r}`)):this.cleanupViewport&&(i.content=i.content.split(",").filter(a=>a.trim()!==r).join(","))}this.onChange()}),xe(this,"trapFocus",n=>{if(Dt.isIos||Dt.isIPadOS||!this.active||n.key!=="Tab")return;const i=document.activeElement,r=ui.call(this.player,"a[href], button:not(:disabled), input:not(:disabled), [tabindex]"),[s]=r,a=r[r.length-1];i!==a||n.shiftKey?i===s&&n.shiftKey&&(a.focus(),n.preventDefault()):(s.focus(),n.preventDefault())}),xe(this,"update",()=>{if(this.supported){let n;n=this.forceFallback?"Fallback (forced)":tn.nativeSupported?"Native":"Fallback",this.player.debug.log(`${n} fullscreen enabled`)}else this.player.debug.log("Fullscreen not supported and fallback disabled");nt(this.player.elements.container,this.player.config.classNames.fullscreen.enabled,this.supported)}),xe(this,"enter",()=>{this.supported&&(Dt.isIos&&this.player.config.fullscreen.iosNative?this.player.isVimeo?this.player.embed.requestFullscreen():this.target.webkitEnterFullscreen():!tn.nativeSupported||this.forceFallback?this.toggleFallback(!0):this.prefix?$.empty(this.prefix)||this.target[`${this.prefix}Request${this.property}`]():this.target.requestFullscreen({navigationUI:"hide"}))}),xe(this,"exit",()=>{if(this.supported)if(Dt.isIos&&this.player.config.fullscreen.iosNative)this.player.isVimeo?this.player.embed.exitFullscreen():this.target.webkitEnterFullscreen(),mn(this.player.play());else if(!tn.nativeSupported||this.forceFallback)this.toggleFallback(!1);else if(this.prefix){if(!$.empty(this.prefix)){const n=this.prefix==="moz"?"Cancel":"Exit";document[`${this.prefix}${n}${this.property}`]()}}else(document.cancelFullScreen||document.exitFullscreen).call(document)}),xe(this,"toggle",()=>{this.active?this.exit():this.enter()}),this.player=t,this.prefix=tn.prefix,this.property=tn.property,this.scrollPosition={x:0,y:0},this.forceFallback=t.config.fullscreen.fallback==="force",this.player.elements.fullscreen=t.config.fullscreen.container&&JS(this.player.elements.container,t.config.fullscreen.container),Ze.call(this.player,document,this.prefix==="ms"?"MSFullscreenChange":`${this.prefix}fullscreenchange`,()=>{this.onChange()}),Ze.call(this.player,this.player.elements.container,"dblclick",n=>{$.element(this.player.elements.controls)&&this.player.elements.controls.contains(n.target)||this.player.listeners.proxy(n,this.toggle,"fullscreen")}),Ze.call(this,this.player.elements.container,"keydown",n=>this.trapFocus(n)),this.update()}static get nativeSupported(){return!!(document.fullscreenEnabled||document.webkitFullscreenEnabled||document.mozFullScreenEnabled||document.msFullscreenEnabled)}get useNative(){return tn.nativeSupported&&!this.forceFallback}static get prefix(){if($.function(document.exitFullscreen))return"";let t="";return["webkit","moz","ms"].some(n=>!(!$.function(document[`${n}ExitFullscreen`])&&!$.function(document[`${n}CancelFullScreen`]))&&(t=n,!0)),t}static get property(){return this.prefix==="moz"?"FullScreen":"Fullscreen"}get supported(){return[this.player.config.fullscreen.enabled,this.player.isVideo,tn.nativeSupported||this.player.config.fullscreen.fallback,!this.player.isYouTube||tn.nativeSupported||!Dt.isIos||this.player.config.playsinline&&!this.player.config.fullscreen.iosNative].every(Boolean)}get active(){if(!this.supported)return!1;if(!tn.nativeSupported||this.forceFallback)return gr(this.target,this.player.config.classNames.fullscreen.fallback);const t=this.prefix?this.target.getRootNode()[`${this.prefix}${this.property}Element`]:this.target.getRootNode().fullscreenElement;return t&&t.shadowRoot?t===this.target.getRootNode().host:t===this.target}get target(){return Dt.isIos&&this.player.config.fullscreen.iosNative?this.player.media:this.player.elements.fullscreen??this.player.elements.container}}
vendor: 4,762 bytes, line 31
31function er(e,t=1){return new Promise((n,i)=>{const r=new Image,s=()=>{delete r.onload,delete r.onerror,(r.naturalWidth>=t?n:i)(r)};Object.assign(r,{onload:s,onerror:s,src:e})})}const dt={addStyleHook(){nt(this.elements.container,this.config.selectors.container.replace(".",""),!0),nt(this.elements.container,this.config.classNames.uiSupported,this.supported.ui)},toggleNativeControls(e=!1){e&&this.isHTML5?this.media.setAttribute("controls",""):this.media.removeAttribute("controls")},build(){if(this.listeners.media(),!this.supported.ui)return this.debug.warn(`Basic support only for ${this.provider} ${this.type}`),void dt.toggleNativeControls.call(this,!0);$.element(this.elements.controls)||(Le.inject.call(this),this.listeners.controls()),dt.toggleNativeControls.call(this),this.isHTML5&&qe.setup.call(this),this.volume=null,this.muted=null,this.loop=null,this.quality=null,this.speed=null,Le.updateVolume.call(this),Le.timeUpdate.call(this),Le.durationUpdate.call(this),dt.checkPlaying.call(this),nt(this.elements.container,this.config.classNames.pip.supported,St.pip&&this.isHTML5&&this.isVideo),nt(this.elements.container,this.config.classNames.airplay.supported,St.airplay&&this.isHTML5),nt(this.elements.container,this.config.classNames.isTouch,this.touch),this.ready=!0,setTimeout(()=>{Ue.call(this,this.media,"ready")},0),dt.setTitle.call(this),this.poster&&dt.setPoster.call(this,this.poster,!1).catch(()=>{}),this.config.duration&&Le.durationUpdate.call(this),this.config.mediaMetadata&&Le.setMediaMetadata.call(this)},setTitle(){let e=Nt.get("play",this.config);if($.string(this.config.title)&&!$.empty(this.config.title)&&(e+=`, ${this.config.title}`),Array.from(this.elements.buttons.play||[]).forEach(t=>{t.setAttribute("aria-label",e)}),this.isEmbed){const t=At.call(this,"iframe");if(!$.element(t))return;const n=$.empty(this.config.title)?"video":this.config.title,i=Nt.get("frameTitle",this.config);t.setAttribute("title",i.replace("{title}",n))}},togglePoster(e){nt(this.elements.container,this.config.classNames.posterEnabled,e)},setPoster(e,t=!0){return t&&this.poster?Promise.reject(new Error("Poster already set")):(this.media.setAttribute("data-poster",e),this.elements.poster.removeAttribute("hidden"),tC.call(this).then(()=>er(e)).catch(n=>{throw e===this.poster&&dt.togglePoster.call(this,!1),n}).then(()=>{if(e!==this.poster)throw new Error("setPoster cancelled by later call to setPoster")}).then(()=>(Object.assign(this.elements.poster.style,{backgroundImage:`url('${e}')`,backgroundSize:""}),dt.togglePoster.call(this,!0),e)))},checkPlaying(e){nt(this.elements.container,this.config.classNames.playing,this.playing),nt(this.elements.container,this.config.classNames.paused,this.paused),nt(this.elements.container,this.config.classNames.stopped,this.stopped),Array.from(this.elements.buttons.play||[]).forEach(t=>{Object.assign(t,{pressed:this.playing}),t.setAttribute("aria-label",Nt.get(this.playing?"pause":"play",this.config))}),$.event(e)&&e.type==="timeupdate"||dt.toggleControls.call(this)},checkLoading(e){this.loading=["stalled","waiting"].includes(e.type),clearTimeout(this.timers.loading),this.timers.loading=setTimeout(()=>{nt(this.elements.container,this.config.classNames.loading,this.loading),dt.toggleControls.call(this)},this.loading?250:0)},toggleControls(e){const{controls:t}=this.elements;if(t&&this.config.hideControls){const n=this.touch&&this.lastSeekTime+2e3>Date.now();this.toggleControls(!!(e||this.loading||this.paused||t.pressed||t.hover||n))}},migrateStyles(){Object.values({...this.media.style}).filter(e=>!$.empty(e)&&$.string(e)&&e.startsWith("--plyr")).forEach(e=>{this.elements.container.style.setProperty(e,this.media.style.getPropertyValue(e)),this.media.style.removeProperty(e)}),$.empty(this.media.style)&&this.media.removeAttribute("style")}};class pC{constructor(t){xe(this,"firstTouch",()=>{const{player:n}=this,{elements:i}=n;n.touch=!0,nt(i.container,n.config.classNames.isTouch,!0)}),xe(this,"global",(n=!0)=>{const{player:i}=this;i.config.keyboard.global&&hi.call(i,window,"keydown keyup",this.handleKey,n,!1),hi.call(i,document.body,"click",this.toggleMenu,n),pl.call(i,document.body,"touchstart",this.firstTouch)}),xe(this,"container",()=>{const{player:n}=this,{config:i,elements:r,timers:s}=n;!i.keyboard.global&&i.keyboard.focused&&Ze.call(n,r.container,"keydown keyup",this.handleKey,!1),Ze.call(n,r.container,"mousemove mouseleave touchstart touchmove enterfullscreen exitfullscreen",l=>{const{controls:c}=r;c&&l.type==="enterfullscreen"&&(c.pressed=!1,c.hover=!1);let d=0;["touchstart","touchmove","mousemove"].includes(l.type)&&(dt.toggleControls.call(n,!0),d=n.touch?3e3:2e3),clearTimeout(s.controls),s.controls=setTimeout(()=>dt.toggleControls.call(n,!1),d)});const a=()=>
31{if(!n.isVimeo||n.config.vimeo.premium)return;const l=r.wrapper,{active:c}=n.fullscreen,[d,u]=fl.call(n),p=Vp(`aspect-ratio: ${d} / ${u}`);if(!c)return void(p?(l.style.width=null,l.style.height=null):(l.style.maxWidth=null,l.style.margin=null));const[h,m]=nC(),v=h/m>d/u;p?(l.style.width=v?"auto":"100%",l.style.height=v?"100%":"auto"):(l.style.maxWidth=v?m/u*d+"px":null,l.style.margin=v?"0 auto":null)},o=()=>{clearTimeout(s.resized),s.resized=setTimeout(a,50)};Ze.call(n,r.container,"enterfullscreen exitfullscreen",l=>{const{target:c}=n.fullscreen;c===r.container&&(!n.isEmbed&&$.empty(n.config.ratio)||(a(),(l.type==="enterfullscreen"?Ze:Yr).call(n,window,"resize",o)))})}),xe(this,"media",()=>{const{player:n}=this,{elements:i}=n;if(Ze.call(n,n.media,"timeupdate seeking seeked",s=>Le.timeUpdate.call(n,s)),Ze.call(n,n.media,"durationchange loadeddata loadedmetadata",s=>Le.durationUpdate.call(n,s)),Ze.call(n,n.media,"ended",()=>{n.isHTML5&&n.isVideo&&n.config.resetOnEnd&&(n.restart(),n.pause())}),Ze.call(n,n.media,"progress playing seeking seeked",s=>Le.updateProgress.call(n,s)),Ze.call(n,n.media,"volumechange",s=>Le.updateVolume.call(n,s)),Ze.call(n,n.media,"playing play pause ended emptied timeupdate",s=>dt.checkPlaying.call(n,s)),Ze.call(n,n.media,"waiting canplay seeked playing",s=>dt.checkLoading.call(n,s)),n.supported.ui&&n.config.clickToPlay&&!n.isAudio){const s=At.call(n,`.${n.config.classNames.video}`);
vendor: 2,173 bytes, line 31
31if(!$.element(s))return;Ze.call(n,i.container,"click",a=>{([i.container,s].includes(a.target)||s.contains(a.target))&&(n.touch&&n.config.hideControls||(n.ended?(this.proxy(a,n.restart,"restart"),this.proxy(a,()=>{mn(n.play())},"play")):this.proxy(a,()=>{mn(n.togglePlay())},"play")))})}n.supported.ui&&n.config.disableContextMenu&&Ze.call(n,i.wrapper,"contextmenu",s=>{s.preventDefault()},!1),Ze.call(n,n.media,"volumechange",()=>{n.storage.set({volume:n.volume,muted:n.muted})}),Ze.call(n,n.media,"ratechange",()=>{Le.updateSetting.call(n,"speed"),n.storage.set({speed:n.speed})}),Ze.call(n,n.media,"qualitychange",s=>{Le.updateSetting.call(n,"quality",null,s.detail.quality)}),Ze.call(n,n.media,"ready qualitychange",()=>{Le.setDownloadUrl.call(n)});const r=n.config.events.concat(["keyup","keydown"]).join(" ");Ze.call(n,n.media,r,s=>{let{detail:a={}}=s;s.type==="error"&&(a=n.media.error),Ue.call(n,i.container,s.type,!0,a)})}),xe(this,"proxy",(n,i,r)=>{const{player:s}=this,a=s.config.listeners[r];let o=!0;$.function(a)&&(o=a.call(s,n)),o!==!1&&$.function(i)&&i.call(s,n)}),xe(this,"bind",(n,i,r,s,a=!0)=>{const{player:o}=this,l=o.config.listeners[s],c=$.function(l);Ze.call(o,n,i,d=>this.proxy(d,r,s),a&&!c)}),xe(this,"controls",()=>{const{player:n}=this,{elements:i}=n,r=Dt.isIE?"change":"input";if(i.buttons.play&&Array.from(i.buttons.play).forEach(s=>{this.bind(s,"click",()=>{mn(n.togglePlay())},"play")}),this.bind(i.buttons.restart,"click",n.restart,"restart"),this.bind(i.buttons.rewind,"click",()=>{n.lastSeekTime=Date.now(),n.rewind()},"rewind"),this.bind(i.buttons.fastForward,"click",()=>{n.lastSeekTime=Date.now(),n.forward()},"fastForward"),this.bind(i.buttons.mute,"click",()=>{n.muted=!n.muted},"mute"),this.bind(i.buttons.captions,"click",()=>n.toggleCaptions()),this.bind(i.buttons.download,"click",()=>{Ue.call(n,n.media,"download")},"download"),this.bind(i.buttons.fullscreen,"click",()=>{n.fullscreen.toggle()},"fullscreen"),this.bind(i.buttons.pip,"click",()=>{n.pip="toggle"},"pip"),this.bind(i.buttons.airplay,"click",n.airplay,"airplay"),this.bind(i.buttons.settings,"click",s=>{s.stopPropagation(),s.preventDefault(),Le.toggleMenu.call(n,s)}
31,null,!1),this.bind(i.buttons.settings,"keyup",s=>{[" ","Enter"].includes(s.key)&&(s.key!=="Enter"?(s.preventDefault(),s.stopPropagation(),Le.toggleMenu.call(n,s)):Le.focusFirstMenuItem.call(n,null,!0))},null,!1),this.bind(i.settings.menu,"keydown",s=>{s.key==="Escape"&&Le.toggleMenu.call(n,s)}),this.bind(i.inputs.seek,"mousedown mousemove",s=>{const a=i.progress.getBoundingClientRect(),o=100/a.width*(s.pageX-a.left);s.currentTarget.setAttribute("seek-value",o)}),this.bind(i.inputs.seek,"mousedown mouseup keydown keyup touchstart touchend",s=>{const a=s.currentTarget,o="play-on-seeked";if($.keyboardEvent(s)&&!["ArrowLeft","ArrowRight"].includes(s.key))return;n.lastSeekTime=Date.now();const l=a.hasAttribute(o),c=["mouseup","touchend","keyup"].includes(s.type);l&&c?(a.removeAttribute(o),mn(n.play())):!c&&n.playing&&(a.setAttribute(o,""),n.pause())}),Dt.isIos){const s=ui.call(n,'input[type="range"]');Array.from(s).forEach(a=>this.bind(a,r,o=>Dp(o.target)))}this.bind(i.inputs.seek,r,s=>{const a=s.currentTarget;let o=a.getAttribute("seek-value");$.empty(o)&&(o=a.value),a.removeAttribute("seek-value"),n.currentTime=o/a.max*n.duration},"seek"),this.bind(i.progress,"mouseenter mouseleave mousemove",s=>Le.updateSeekTooltip.call(n,s)),this.bind(i.progress,"mousemove touchmove",s=>{const{previewThumbnails:a}=n;a&&a.loaded&&a.startMove(s)}),this.bind(i.progress,"mouseleave touchend click",()=>{const{previewThumbnails:s}=n;s&&s.loaded&&s.endMove(!1,!0)}),this.bind(i.progress,"mousedown touchstart",s=>{const{previewThumbnails:a}=n;a&&a.loaded&&a.startScrubbing(s)}),this.bind(i.progress,"mouseup touchend",s=>{const{previewThumbnails:a}=n;a&&a.loaded&&a.endScrubbing(s)}),Dt.isWebKit&&Array.from(ui.call(n,'input[type="range"]')).forEach(s=>{this.bind(s,"input",a=>Le.updateRangeFill.call(n,a.target))}),n.config.toggleInvert&&!$.element(i.display.duration)&&this.bind(i.display.currentTime,"click",()=>{n.currentTime!==0&&(n.config.invertTime=!n.config.invertTime,Le.timeUpdate.call(n))}),this.bind(i.inputs.volume,r,s=>{n.volume=s.target.value},"volume"),this.bind(i.controls,"mouseenter mouseleave",s=>{i.controls.hover=!n.touch&&s.type==="mouseenter"}),i.fullscreen&&Array.from(i.fullscreen.children).filter(s=>
31!s.contains(i.container)).forEach(s=>{this.bind(s,"mouseenter mouseleave",a=>{i.controls&&(i.controls.hover=!n.touch&&a.type==="mouseenter")})}),this.bind(i.controls,"mousedown mouseup touchstart touchend touchcancel",s=>{i.controls.pressed=["mousedown","touchstart"].includes(s.type)}),this.bind(i.controls,"focusin",()=>{const{config:s,timers:a}=n;nt(i.controls,s.classNames.noTransition,!0),dt.toggleControls.call(n,!0),setTimeout(()=>{nt(i.controls,s.classNames.noTransition,!1)},0);const o=this.touch?3e3:4e3;clearTimeout(a.controls),a.controls=setTimeout(()=>dt.toggleControls.call(n,!1),o)}),this.bind(i.inputs.volume,"wheel",s=>{const a=s.webkitDirectionInvertedFromDevice,[o,l]=[s.deltaX,-s.deltaY].map(u=>a?-u:u),c=Math.sign(Math.abs(o)>Math.abs(l)?o:l);n.increaseVolume(c/50);const{volume:d}=n.media;(c===1&&d<1||c===-1&&d>0)&&s.preventDefault()},"volume",!1)}),this.player=t,this.lastKey=null,this.focusTimer=null,this.lastKeyDown=null,this.handleKey=this.handleKey.bind(this),this.toggleMenu=this.toggleMenu.bind(this),this.firstTouch=this.firstTouch.bind(this)}handleKey(t){const{player:n}=this,{elements:i}=n,{key:r,type:s,altKey:a,ctrlKey:o,metaKey:l,shiftKey:c}=t,d=s==="keydown",u=d&&r===this.lastKey;if(!(a||o||l||c)&&r){if(d){const h=document.activeElement;if($.element(h)){const{editable:m}=n.config.selectors,{seek:v}=i.inputs;if(h!==v&&rs(h,m)||t.key===" "&&rs(h,'button, [role^="menuitem"]'))return}switch([" ","ArrowLeft","ArrowUp","ArrowRight","ArrowDown","0","1","2","3","4","5","6","7","8","9","c","f","k","l","m"].includes(r)&&(t.preventDefault(),t.stopPropagation()),r){case"0":case"1":case"2":case"3":case"4":case"5":case"6":case"7":case"8":case"9":u||(p=parseInt(r,10),n.currentTime=n.duration/10*p);break;case" ":case"k":u||mn(n.togglePlay());break;case"ArrowUp":n.increaseVolume(.1);break;case"ArrowDown":n.decreaseVolume(.1);break;case"m":u||(n.muted=!n.muted);break;case"ArrowRight":n.forward();break;case"ArrowLeft":n.rewind();break;case"f":n.fullscreen.toggle();break;case"c":u||n.toggleCaptions();break;case"l":n.loop=!n.loop}r==="Escape"&&!n.fullscreen.usingNative&&n.fullscreen.active&&n.fullscreen.toggle(),this.lastKey=r}else this.lastKey=null;var p}}toggleMenu(t){Le.toggleMenu.call(this.player,t)}}function fC(e,t){return e(t={exports:{}},t.exports),t.exports}var mC=fC(function(e,t){e.exports=function(){var n=function(){},i={},r={},s={};function a(p,h){p=p.push?p:[p];var m,v,_,b=[],w=p.length,C=w;for(m=function(O,T){T.length&&b.push(O),--C||h(b)};w--;)v=p[w],(_=r[v])?m(v,_):(s[v]=s[v]||[]).push(m)}function o(p,h){if(p){var m=s[p];if(r[p]=h,m)for(;m.length;)m[0](p,h),m.splice(0,1)}}function l(p,h){p.call&&(p={success:p}),h.length?(p.error||n)(h):(p.success||n)(p)}function c(p,h,m,v){var _,b,w=document,C=m.async,O=(m.numRetries||0)+1,T=m.before||n,E=p.replace(/[\?|#].*$/,""),y=p.replace(/^(css|img)!/,"");v=v||0,/(^css!|\.css$)/.test(E)?((b=w.createElement("link")).rel="stylesheet",b.href=y,(_="hideFocus"in b)&&b.relList&&(_=0,b.rel="preload",b.as="style")):/(^img!|\.(png|gif|jpg|svg|webp)$)/.test(E)?(b=w.createElement("img")).src=y:((b=w.createElement("script")).src=p,b.async=C===void 0||C),b.onload=b.onerror=b.onbeforeload=function(P){var A=P.type[0];if(_)try{b.sheet.cssText.length||(A="e")}catch(I){I.code!=18&&(A="e")}if(A=="e"){if((v+=1)<O)return c(p,h,m,v)}else if(b.rel=="preload"&&b.as=="style")return b.rel="stylesheet";h(p,A,P.defaultPrevented)},T(p,b)!==!1&&w.head.appendChild(b)}function d(p,h,m){var v,_,b=(p=p.push?p:[p]).length,w=b,C=[];for(v=function(O,T,E){if(T=="e"&&C.push(O),T=="b"){if(!E)return;C.push(O)}--b||h(C)},_=0;_<w;_++)c(p[_],v,m)}function u(p,h,m){var v,_;if(h&&h.trim&&(v=h),_=(v?m:h)||{},v){if(v in i)throw"LoadJS";i[v]=!0}function b(w,C){d(p,function(O){l(_,O),w&&l({success:w,error:C},O),o(v,O)},_)}if(_.returnPromise)return new Promise(b);b()}return u.ready=function(p,h){return a(p,function(m){l(h,m)}),u},u.done=function(p){o(p,[])},u.reset=function(){i={},r={},s={}},u.isDefined=function(p){return p in i},u}()});function ml(e){return new Promise((t,n)=>{mC(e,{success:t,error:n})})}function gC(e){return $.empty(e)?null:$.number(Number(e))?e:e.match(/^.*(vimeo.com\/|video\/)(\d+).*/)?RegExp.$2:e}function yC(e){const t=e.match(/^.*(vimeo.com\/|video\/)(\d+)(\?.*&*h=|\/)+([\d,a-f]+)/);return t&&t.length===5?t[4]:null}function Ks(e){e&&!this.embed.hasPlayed&&(this.embed.hasPlayed=!0),this.media.paused===e&&(this.media.paused=!e,Ue.call(this,this.media,e?"play":"pause"))}const To={setup(){const e=this;nt(e.elements.wrapper,e.config.classNames.embed,!0),e.options.speed=e.config.speed.options,Ns.call(e),$.object(window.Vimeo)?To.ready.call(e):ml(e.config.urls.vimeo.sdk).then(()=>{To.ready.call(e)}).catch(t=>{e.debug.warn("Vimeo SDK (player.js) failed to load",t)})},ready(){const e=this,t=e.config.vimeo,{premium:n,referrerPolicy:i,...r}=t;let s=e.media.getAttribute("src"),a="";$.empty(s)?(s=e.media.getAttribute(e.config.attributes.embed.id),a=e.media.getAttribute(e.config.attributes.embed.hash)):a=yC(s);const o=a?{h:a}:{};n&&Object.assign(r,{controls:!1,sidedock:!1});const l=Gp({loop:e.config.loop.active,autoplay:e.autoplay,muted:e.muted,gesture:"media",playsinline:e.config.playsinline,...o,...r}),c=gC(s),d=$e("iframe"),u=Io(e.config.urls.vimeo.iframe,c,l);if(d.setAttribute("src",u),d.setAttribute("allowfullscreen",""),d.setAttribute("allow",["auto
31play","fullscreen","picture-in-picture","encrypted-media","accelerometer","gyroscope"].join("; ")),$.empty(i)||d.setAttribute("referrerPolicy",i),n||!t.customControls)d.setAttribute("data-poster",e.poster),e.media=mr(d,e.media);else{const w=$e("div",{class:e.config.classNames.embedContainer,"data-poster":e.poster});w.appendChild(d),e.media=mr(w,e.media)}t.customControls||Ri(Io(e.config.urls.vimeo.api,u)).then(w=>{!$.empty(w)&&w.thumbnail_url&&dt.setPoster.call(e,w.thumbnail_url).catch(()=>{})}),e.embed=new window.Vimeo.Player(d,{autopause:e.config.autopause,muted:e.muted}),e.media.paused=!0,e.media.currentTime=0,e.supported.ui&&e.embed.disableTextTrack(),e.media.play=()=>(Ks.call(e,!0),e.embed.play()),e.media.pause=()=>(Ks.call(e,!1),e.embed.pause()),e.media.stop=()=>{e.pause(),e.currentTime=0};let{currentTime:p}=e.media;Object.defineProperty(e.media,"currentTime",{get:()=>p,set(w){const{embed:C,media:O,paused:T,volume:E}=e,y=T&&!C.hasPlayed;O.seeking=!0,Ue.call(e,O,"seeking"),Promise.resolve(y&&C.setVolume(0)).then(()=>C.setCurrentTime(w)).then(()=>y&&C.pause()).then(()=>y&&C.setVolume(E)).catch(()=>{})}});let h=e.config.speed.selected;Object.defineProperty(e.media,"playbackRate",{get:()=>h,set(w){e.embed.setPlaybackRate(w).then(()=>{h=w,Ue.call(e,e.media,"ratechange")}).catch(()=>{e.options.speed=[1]})}});let{volume:m}=e.config;Object.defineProperty(e.media,"volume",{get:()=>m,set(w){e.embed.setVolume(w).then(()=>{m=w,Ue.call(e,e.media,"volumechange")})}});let{muted:v}=e.config;Object.defineProperty(e.media,"muted",{get:()=>v,set(w){const C=!!$.boolean(w)&&w;e.embed.setMuted(!!C||e.config.muted).then(()=>{v=C,Ue.call(e,e.media,"volumechange")})}});let _,{loop:b}=e.config;Object.defineProperty(e.media,"loop",{get:()=>b,set(w){const C=$.boolean(w)?w:e.config.loop.active;e.embed.setLoop(C).then(()=>{b=C})}}),e.embed.getVideoUrl().then(w=>{_=w,Le.setDownloadUrl.call(e)}).catch(w=>{this.debug.warn(w)}),Object.defineProperty(e.media,"currentSrc",{get:()=>_}),Object.defineProperty(e.media,"ended",{get:()=>e.currentTime===e.duration}),Promise.all([e.embed.getVideoWidth(),e.embed.getVideoHeight()]).then(w=>{const[C,O]=w;e.embed.ratio=$p(C,O),Ns.call(this)}),e.embed.setAutopause(e.config.autopause).then(w=>{e.config.autopause=w}),e.embed.getVideoTitle().then(w=>{e.config.title=w,dt.setTitle.call(this)}),e.embed.getCurrentTime().then(w=>{p=w,Ue.call(e,e.media,"timeupdate")}),e.embed.getDuration().then(w=>{e.media.duration=w,Ue.call(e,e.media,"durationchange")}),e.embed.getTextTracks().then(w=>{e.media.textTracks=w,qe.setup.call(e)}),e.embed.on("cuechange",({cues:w=[]})=>{const C=w.map(O=>oC(O.text));qe.updateCues.call(e,C)}),e.embed.on("loaded",()=>{e.embed.getPaused().then(w=>{Ks.call(e,!w),w||Ue.call(e,e.media,"playing")}),$.element(e.embed.element)&&e.supported.ui&&e.embed.element.setAttribute("tabindex",-1)}),e.embed.on("bufferstart",()=>{Ue.call(e,e.media,"waiting")}),e.embed.on("bufferend",()=>{Ue.call(e,e.media,"playing")}),e.embed.on("play",()=>{Ks.call(e,!0),Ue.call(e,e.media,"playing")}),e.embed.on("pause",()=>{Ks.call(e,!1)}),e.embed.on("timeupdate",w=>{e.media.seeking=!1,p=w.seconds,Ue.call(e,e.media,"timeupdate")}),e.embed.on("progress",w=>{e.media.buffered=w.percent,Ue.call(e,e.media,"progress"),parseInt(w.percent,10)===1&&Ue.call(e,e.media,"canplaythrough"),e.embed.getDuration().then(C=>{C!==e.media.duration&&(e.media.duration=C,Ue.call(e,e.media,"durationchange"))})}),e.embed.on("seeked",()=>{e.media.seeking=!1,Ue.call(e,e.media,"seeked")}),e.embed.on("ended",()=>{e.media.paused=!0,Ue.call(e,e.media,"ended")}),e.embed.on("error",w=>{e.media.error=w,Ue.call(e,e.media,"error")}),t.customControls&&setTimeout(()=>dt.build.call(e),0)}};function bC(e){return $.empty(e)?null:e.match(/^.*(youtu.be\/|v\/|u\/\w\/|embed\/|watch\?v=|&v=)([^#&?]*).*/)?RegExp.$2:e}function Gs(e){e&&!this.embed.hasPlayed&&(this.embed.hasPlayed=!0),this.media.paused===e&&(this.media.paused=!e,Ue.call(this,this.media,e?"play":"pause"))}function vC(e){return e.noCookie?"https://www.youtube-nocookie.com":window.location.protocol==="http:"?"http://www.youtube.com":void 0}const tr={setup(){if(nt(this.elements.wrapper,this.config.classNames.embed,!0),$.object(window.YT)&&$.function(window.YT.Player))tr.ready.call(this);else{const e=window.onYouTubeIframeAPIReady;window.onYouTubeIframeAPIReady=()=>{$.function(e)&&e(),tr.ready.call(this)},ml(this.config.urls.youtube.sdk).catch(t=>{this.debug.warn("YouTube API failed to load",t)})}},getTitle(e){Ri(Io(this.config.urls.youtube.api,e)).then(t=>{if($.object(t)){const{title:n,height:i,width:r}=t;this.config.title=n,dt.setTitle.call(this),this.embed.ratio=$p(r,i)}Ns.call(this)}).catch(()=>{Ns.call(this)})},ready(){const e=this,t=e.config.youtube,n=e.media&&e.media.getAttribute("id");if(!$.empty(n)&&n.startsWith("youtube-"))return;let i=e.media.getAttribute("src");$.empty(i)&&(i=e.media.getAttribute(this.config.attributes.embed.id));const r=bC(i),s=$e("div",{id:sC(e.provider),"data-poster":t.customControls?e.poster:void 0});if(e.media=mr(s,e.media),t.customControls){const a=o=>`https://i.ytimg.com/vi/${r}/${o}default.jpg`;er(a("maxres"),121).catch(()=>
vendor: 11,663 bytes, line 31
31er(a("sd"),121)).catch(()=>er(a("hq"))).then(o=>dt.setPoster.call(e,o.src)).then(o=>{o.includes("maxres")||(e.elements.poster.style.backgroundSize="cover")}).catch(()=>{})}e.embed=new window.YT.Player(e.media,{videoId:r,host:vC(t),playerVars:Et({},{autoplay:e.config.autoplay?1:0,hl:e.config.hl,controls:e.supported.ui&&t.customControls?0:1,disablekb:1,playsinline:e.config.playsinline&&!e.config.fullscreen.iosNative?1:0,cc_load_policy:e.captions.active?1:0,cc_lang_pref:e.config.captions.language,widget_referrer:window?window.location.href:null},t),events:{onError(a){if(!e.media.error){const o=a.data,l={2:"The request contains an invalid parameter value. For example, this error occurs if you specify a video ID that does not have 11 characters, or if the video ID contains invalid characters, such as exclamation points or asterisks.",5:"The requested content cannot be played in an HTML5 player or another error related to the HTML5 player has occurred.",100:"The video requested was not found. This error occurs when a video has been removed (for any reason) or has been marked as private.",101:"The owner of the requested video does not allow it to be played in embedded players.",150:"The owner of the requested video does not allow it to be played in embedded players."}[o]||"An unknown error occurred";e.media.error={code:o,message:l},Ue.call(e,e.media,"error")}},onPlaybackRateChange(a){const o=a.target;e.media.playbackRate=o.getPlaybackRate(),Ue.call(e,e.media,"ratechange")},onReady(a){if($.function(e.media.play))return;const o=a.target;tr.getTitle.call(e,r),e.media.play=()=>{Gs.call(e,!0),o.playVideo()},e.media.pause=()=>{Gs.call(e,!1),o.pauseVideo()},e.media.stop=()=>{o.stopVideo()},e.media.duration=o.getDuration(),e.media.paused=!0,e.media.currentTime=0,Object.defineProperty(e.media,"currentTime",{get:()=>Number(o.getCurrentTime()),set(u){e.paused&&!e.embed.hasPlayed&&e.embed.mute(),e.media.seeking=!0,Ue.call(e,e.media,"seeking"),o.seekTo(u)}}),Object.defineProperty(e.media,"playbackRate",{get:()=>o.getPlaybackRate(),set(u){o.setPlaybackRate(u)}});let{volume:l}=e.config;Object.defineProperty(e.media,"volume",{get:()=>l,set(u){l=u,o.setVolume(100*l),Ue.call(e,e.media,"volumechange")}});let{muted:c}=e.config;Object.defineProperty(e.media,"muted",{get:()=>c,set(u){const p=$.boolean(u)?u:c;c=p,o[p?"mute":"unMute"](),o.setVolume(100*l),Ue.call(e,e.media,"volumechange")}}),Object.defineProperty(e.media,"currentSrc",{get:()=>o.getVideoUrl()}),Object.defineProperty(e.media,"ended",{get:()=>e.currentTime===e.duration});const d=o.getAvailablePlaybackRates();e.options.speed=d.filter(u=>e.config.speed.options.includes(u)),e.supported.ui&&t.customControls&&e.media.setAttribute("tabindex",-1),Ue.call(e,e.media,"timeupdate"),Ue.call(e,e.media,"durationchange"),clearInterval(e.timers.buffering),e.timers.buffering=setInterval(()=>{e.media.buffered=o.getVideoLoadedFraction(),(e.media.lastBuffered===null||e.media.lastBuffered<e.media.buffered)&&Ue.call(e,e.media,"progress"),e.media.lastBuffered=e.media.buffered,e.media.buffered===1&&(clearInterval(e.timers.buffering),Ue.call(e,e.media,"canplaythrough"))},200),t.customControls&&setTimeout(()=>dt.build.call(e),50)},onStateChange(a){const o=a.target;switch(clearInterval(e.timers.playing),e.media.seeking&&[1,2].includes(a.data)&&(e.media.seeking=!1,Ue.call(e,e.media,"seeked")),a.data){case-1:Ue.call(e,e.media,"timeupdate"),e.media.buffered=o.getVideoLoadedFraction(),Ue.call(e,e.media,"progress");break;case 0:Gs.call(e,!1),e.media.loop?(o.stopVideo(),o.playVideo()):Ue.call(e,e.media,"ended");break;case 1:t.customControls&&!e.config.autoplay&&e.media.paused&&!e.embed.hasPlayed?e.media.pause():(Gs.call(e,!0),Ue.call(e,e.media,"playing"),e.timers.playing=setInterval(()=>{Ue.call(e,e.media,"timeupdate")},50),e.media.duration!==o.getDuration()&&(e.media.duration=o.getDuration(),Ue.call(e,e.media,"durationchange")));break;case 2:e.muted||e.embed.unMute(),Gs.call(e,!1);break;case 3:Ue.call(e,e.media,"waiting")}Ue.call(e,e.elements.container,"statechange",!1,{code:a.data})}}})}},Yp={setup(){this.media?(nt(this.elements.container,this.config.classNames.type.replace("{0}",this.type),!0),nt(this.elements.container,this.config.classNames.provider.replace("{0}",this.provider),!0),this.isEmbed&&nt(this.elements.container,this.config.classNames.type.replace("{0}","video"),!0),this.isVideo&&(this.elements.wrapper=$e("div",{class:this.config.classNames.video}),Mp(this.media,this.elements.wrapper),this.elements.poster=$e("div",{class:this.config.classNames.poster}),this.elements.wrapper.appendChild(this.elements.poster)),this.isHTML5?Bn.setup.call(this):this.isYouTube?tr.setup.call(this):this.isVimeo&&To.setup.call(this)):this.debug.warn("No media element found!")}};class _C{constructor(t){xe(this,"load",()=>{this.enabled&&($.object(window.google)&&$.object(window.google.ima)?this.ready():ml(this.player.config.urls.googleIMA.sdk).then(()=>{this.ready()}).catch(()=>{this.trigger("error",new Error("Google IMA SDK failed to load"))}))}),xe(this,"ready",()=>{var n;this.enabled||((n=this).manager&&n.manager.destroy(),n.elements.displayContainer&&n.elements.displayContainer.destroy(),n.elements.container.remove()),this.startSafetyTimer(12e3,"ready()"),this.managerPromise.then(()=>{this.clearSafetyTimer("onAdsManagerLoaded()")}),this.listeners(),this.setupIMA()}),xe(this,"setupIMA",()=>{this.elements.container=$e("div",{class:this.player.config.classNames.ads}),this.player.elements.container.appendChild(this.elements.container),google.ima.settings.setVpaidMode(google.ima.ImaSdkSettings.VpaidMode.ENABLED),google.ima.settings.setLocale(this.player.config.ads.language),google.ima.settings.setDisableCustomPlaybackForIOS10Plus(this.player.config.playsinline),this.elements.displayContainer=new google.ima.AdDisplayContainer(this.elements.container,this.player.media),this.loader=new google.ima.AdsLoader(this.elements.displayContainer),this.loader.addEventListener(google.ima.AdsManagerLoadedEvent.Type.ADS_MANAGER_LOADED,n=>this.onAdsManagerLoaded(n),!1),this.loader.addEventListener(google.ima.AdErrorEvent.Type.AD_ERROR,n=>this.onAdError(n),!1),this.requestAds()}),xe(this,"requestAds",()=>{const{container:n}=this.player.elements;try{const i=new google.ima.AdsRequest;i.adTagUrl=this.tagUrl,i.linearAdSlotWidth=n.offsetWidth,i.linearAdSlotHeight=n.offsetHeight,i.nonLinearAdSlotWidth=n.offsetWidth,i.nonLinearAdSlotHeight=n.offsetHeight,i.forceNonLinearFullSlot=!1,i.setAdWillPlayMuted(!this.player.muted),this.loader.requestAds(i)}catch(i){this.onAdError(i)}}),xe(this,"pollCountdown",(n=!1)=>{if(!n)return clearInterval(this.countdownTimer),void this.elements.container.removeAttribute("data-badge-text");this.countdownTimer=setInterval(()=>{const i=Wr(Math.max(this.manager.getRemainingTime(),0)),r=`${Nt.get("advertisement",this.player.config)} - ${i}`;this.elements.container.setAttribute("data-badge-text",r)},100)}),xe(this,"onAdsManagerLoaded",n=>{if(!this.enabled)return;const i=new google.ima.AdsRenderingSettings;i.restoreCustomPlaybackStateOnAdBreakComplete=!0,i.enablePreloading=!0,this.manager=n.getAdsManager(this.player,i),this.cuePoints=this.manager.getCuePoints(),this.manager.addEventListener(google.ima.AdErrorEvent.Type.AD_ERROR,r=>this.onAdError(r)),Object.keys(google.ima.AdEvent.Type).forEach(r=>{this.manager.addEventListener(google.ima.AdEvent.Type[r],s=>this.onAdEvent(s))}),this.trigger("loaded")}),xe(this,"addCuePoints",()=>{$.empty(this.cuePoints)||this.cuePoints.forEach(n=>{if(n!==0&&n!==-1&&n<this.player.duration){const i=this.player.elements.progress;if($.element(i)){const r=100/this.player.duration*n,s=$e("span",{class:this.player.config.classNames.cues});s.style.left=`${r.toString()}%`,i.appendChild(s)}}})}),xe(this,"onAdEvent",n=>{const{container:i}=this.player.elements,r=n.getAd(),s=n.getAdData();switch((a=>{Ue.call(this.player,this.player.media,`ads${a.replace(/_/g,"").toLowerCase()}`)})(n.type),n.type){case google.ima.AdEvent.Type.LOADED:this.trigger("loaded"),this.pollCountdown(!0),r.isLinear()||(r.width=i.offsetWidth,r.height=i.offsetHeight);break;case google.ima.AdEvent.Type.STARTED:this.manager.setVolume(this.player.volume);break;case google.ima.AdEvent.Type.ALL_ADS_COMPLETED:this.player.ended?this.loadAds():this.loader.contentComplete();break;case google.ima.AdEvent.Type.CONTENT_PAUSE_REQUESTED:this.pauseContent();break;case google.ima.AdEvent.Type.CONTENT_RESUME_REQUESTED:this.pollCountdown(),this.resumeContent();break;case google.ima.AdEvent.Type.LOG:s.adError&&this.player.debug.warn(`Non-fatal ad error: ${s.adError.getMessage()}`)}}),xe(this,"onAdError",n=>{this.cancel(),this.player.debug.warn("Ads error",n)}),xe(this,"listeners",()=>{const{container:n}=this.player.elements;let i;this.player.on("canplay",()=>{this.addCuePoints()}),this.player.on("ended",()=>{this.loader.contentComplete()}),this.player.on("timeupdate",()=>{i=this.player.currentTime}),this.player.on("seeked",()=>{const r=this.player.currentTime;$.empty(this.cuePoints)||this.cuePoints.forEach((s,a)=>{i<s&&s<r&&(this.manager.discardAdBreak(),this.cuePoints.splice(a,1))})}),window.addEventListener("resize",()=>{this.manager&&this.manager.resize(n.offsetWidth,n.offsetHeight,google.ima.ViewMode.NORMAL)})}),xe(this,"play",()=>{const{container:n}=this.player.elements;this.managerPromise||this.resumeContent(),this.managerPromise.then(()=>{this.manager.setVolume(this.player.volume),this.elements.displayContainer.initialize();try{this.initialized||(this.manager.init(n.offsetWidth,n.offsetHeight,google.ima.ViewMode.NORMAL),this.manager.start()),this.initialized=!0}catch(i){this.onAdError(i)}}).catch(()=>{})}),xe(this,"resumeContent",()=>{this.elements.container.style.zIndex="",this.playing=!1,mn(this.player.media.play())}),xe(this,"pauseContent",()=>{this.elements.container.style.zIndex=3,this.playing=!0,this.player.media.pause()}),xe(this,"cancel",()=>{this.initialized&&this.resumeContent(),this.trigger("error"),this.loadAds()}),xe(this,"loadAds",()=>{this.managerPromise.then(()=>{this.manager&&this.manager.destroy(),this.managerPromise=new Promise(n=>{this.on("loaded",n),this.player.debug.log(this.manager)}),this.initialized=!1,this.requestAds()}).catch(()=>{})}),xe(this,"trigger",(n,...i)=>{const r=this.events[n];$.array(r)&&r.forEach(s=>{$.function(s)&&s.apply(this,i)})}),xe(this,"on",(n,i)=>($.array(this.events[n])||(this.events[n]=[]),this.events[n].push(i),this)),xe(this,"startSafetyTimer",(n,i)=>{this.player.debug.log(`Safety timer invoked from: ${i}`),this.safetyTimer=setTimeout(()=>{this.cancel(),this.clearSafetyTimer("startSafetyTimer()")},n)}),xe(this,"clearSafetyTimer",n=>{$.nullOrUndefined(this.safetyTimer)||(this.player.debug.log(`Safety timer cleared from: ${n}`),clearTimeout(this.safetyTimer),this.safetyTimer=null)}),this.player=t,this.config=t.config.ads,this.playing=!1,this.initialized=!1,this.elements={container:null,displayContainer:null},this.manager=null,this.loader=null,this.cuePoints=null,this.events={},this.safetyTimer=null,this.countdownTimer=null,this.managerPromise=new Promise((n,i)=>{this.on("loaded",n),this.on("error",i)}),this.load()}get enabled(){const{config:t}=this;return this.player.isHTML5&&this.player.isVideo&&t.enabled&&(!$.empty(t.publisherId)||$.url(t.tagUrl))}get tagUrl(){const{config:t}=this;return $.url(t.tagUrl)?t.tagUrl:`https://go.aniview.com/api/adserver6/vast/?${Gp({AV_PUBLISHERID:"58c25bb0073ef448b1087ad6",AV_CHANNELID:"5a0458dc28a06145e4519d21",AV_URL:window.location.hostname,cb:Date.now(),AV_WIDTH:640,AV_HEIGHT:480,AV_CDIM2:t.publisherId})}`}}function Wp(e=0,t=0,n=255){return Math.min(Math.max(e,t),n)}const wC=e=>{const t=[];
31return e.split(/\r\n\r\n|\n\n|\r\r/).forEach(n=>{const i={};n.split(/\r\n|\n|\r/).forEach(r=>{if($.number(i.startTime)){if(!$.empty(r.trim())&&$.empty(i.text)){const s=r.trim().split("#xywh=");[i.text]=s,s[1]&&([i.x,i.y,i.w,i.h]=s[1].split(","))}}else{const s=r.match(/([0-9]{2})?:?([0-9]{2}):([0-9]{2}).([0-9]{2,3})( ?--> ?)([0-9]{2})?:?([0-9]{2}):([0-9]{2}).([0-9]{2,3})/);s&&(i.startTime=60*Number(s[1]||0)*60+60*Number(s[2])+Number(s[3])+ +`0.${s[4]}`,i.endTime=60*Number(s[6]||0)*60+60*Number(s[7])+Number(s[8])+ +`0.${s[9]}`)}}),i.text&&t.push(i)}),t},wd=(e,t)=>{const n={};return e>t.width/t.height?(n.width=t.width,n.height=1/e*t.width):(n.height=t.height,n.width=e*t.height),n};class Po{constructor(t){xe(this,"load",()=>{this.player.elements.display.seekTooltip&&(this.player.elements.display.seekTooltip.hidden=this.enabled),this.enabled&&this.getThumbnails().then(()=>{this.enabled&&(this.render(),this.determineContainerAutoSizing(),this.listeners(),this.loaded=!0)})}),xe(this,"getThumbnails",()=>new Promise(n=>{const{src:i}=this.player.config.previewThumbnails;if($.empty(i))throw new Error("Missing previewThumbnails.src config attribute");const r=()=>{this.thumbnails.sort((s,a)=>s.height-a.height),this.player.debug.log("Preview thumbnails",this.thumbnails),n()};if($.function(i))i(s=>{this.thumbnails=s,r()});else{const s=($.string(i)?[i]:i).map(a=>this.getThumbnail(a));Promise.all(s).then(r)}})),xe(this,"getThumbnail",n=>new Promise(i=>{Ri(n).then(r=>{const s={frames:wC(r),height:null,urlPrefix:""};s.frames[0].text.startsWith("/")||s.frames[0].text.startsWith("http://")||s.frames[0].text.startsWith("https://")||(s.urlPrefix=n.substring(0,n.lastIndexOf("/")+1));const a=new Image;a.onload=()=>{s.height=a.naturalHeight,s.width=a.naturalWidth,this.thumbnails.push(s),i()},a.src=s.urlPrefix+s.frames[0].text})})),xe(this,"startMove",n=>{if(this.loaded&&$.event(n)&&["touchmove","mousemove"].includes(n.type)&&this.player.media.duration){if(n.type==="touchmove")this.seekTime=this.player.media.duration*(this.player.elements.inputs.seek.value/100);else{var i,r;const s=this.player.elements.progress.getBoundingClientRect(),a=100/s.width*(n.pageX-s.left);this.seekTime=this.player.media.duration*(a/100),this.seekTime<0&&(this.seekTime=0),this.seekTime>this.player.media.duration-1&&(this.seekTime=this.player.media.duration-1),this.mousePosX=n.pageX,this.elements.thumb.time.innerText=Wr(this.seekTime);const o=(i=this.player.config.markers)===null||i===void 0||(r=i.points)===null||r===void 0?void 0:r.find(({time:l})=>l===Math.round(this.seekTime));o&&this.elements.thumb.time.insertAdjacentHTML("afterbegin",`${o.label}<br>`)}this.showImageAtCurrentTime()}}),xe(this,"endMove",()=>{this.toggleThumbContainer(!1,!0)}),xe(this,"startScrubbing",n=>{($.nullOrUndefined(n.button)||n.button===!1||n.button===0)&&(this.mouseDown=!0,this.player.media.duration&&(this.toggleScrubbingContainer(!0),this.toggleThumbContainer(!1,!0),this.showImageAtCurrentTime()))}),xe(this,"endScrubbing",()=>{this.mouseDown=!1,Math.ceil(this.lastTime)===Math.ceil(this.player.media.currentTime)?this.toggleScrubbingContainer(!1):pl.call(this.player,this.player.media,"timeupdate",()=>{this.mouseDown||this.toggleScrubbingContainer(!1)})}),xe(this,"listeners",()=>{this.player.on("play",()=>{this.toggleThumbContainer(!1,!0)}),this.player.on("seeked",()=>{this.toggleThumbContainer(!1)}),this.player.on("timeupdate",()=>{this.lastTime=this.player.media.currentTime})}),xe(this,"render",()=>{this.elements.thumb.container=$e("div",{class:this.player.config.classNames.previewThumbnails.thumbContainer}),this.elements.thumb.imageContainer=$e("div",{class:this.player.config.classNames.previewThumbnails.imageContainer}),this.elements.thumb.container.appendChild(this.elements.thumb.imageContainer);const n=$e("div",{class:this.player.config.classNames.previewThumbnails.timeContainer});this.elements.thumb.time=$e("span",{},"00:00"),n.appendChild(this.elements.thumb.time),this.elements.thumb.imageContainer.appendChild(n),$.element(this.player.elements.progress)&&this.player.elements.progress.appendChild(this.elements.thumb.container),this.elements.scrubbing.container=$e("div",{class:this.player.config.classNames.previewThumbnails.scrubbingContainer}),this.player.elements.wrapper.appendChild(this.elements.scrubbing.container)}),xe(this,"destroy",()=>{this.elements.thumb.container&&this.elements.thumb.container.remove(),this.elements.scrubbing.container&&this.elements.scrubbing.container.remove()}),xe(this,"showImageAtCurrentTime",()=>{this.mouseDown?this.setScrubbingContainerSize():this.setThumbContainerSizeAndPos();
vendor: 9,213 bytes, line 31
31const n=this.thumbnails[0].frames.findIndex(s=>this.seekTime>=s.startTime&&this.seekTime<=s.endTime),i=n>=0;let r=0;this.mouseDown||this.toggleThumbContainer(i),i&&(this.thumbnails.forEach((s,a)=>{this.loadedImages.includes(s.frames[n].text)&&(r=a)}),n!==this.showingThumb&&(this.showingThumb=n,this.loadImage(r)))}),xe(this,"loadImage",(n=0)=>{const i=this.showingThumb,r=this.thumbnails[n],{urlPrefix:s}=r,a=r.frames[i],o=r.frames[i].text,l=s+o;if(this.currentImageElement&&this.currentImageElement.dataset.filename===o)this.showImage(this.currentImageElement,a,n,i,o,!1),this.currentImageElement.dataset.index=i,this.removeOldImages(this.currentImageElement);else{this.loadingImage&&this.usingSprites&&(this.loadingImage.onload=null);const c=new Image;c.src=l,c.dataset.index=i,c.dataset.filename=o,this.showingThumbFilename=o,this.player.debug.log(`Loading image: ${l}`),c.onload=()=>this.showImage(c,a,n,i,o,!0),this.loadingImage=c,this.removeOldImages(c)}}),xe(this,"showImage",(n,i,r,s,a,o=!0)=>{this.player.debug.log(`Showing thumb: ${a}. num: ${s}. qual: ${r}. newimg: ${o}`),this.setImageSizeAndOffset(n,i),o&&(this.currentImageContainer.appendChild(n),this.currentImageElement=n,this.loadedImages.includes(a)||this.loadedImages.push(a)),this.preloadNearby(s,!0).then(this.preloadNearby(s,!1)).then(this.getHigherQuality(r,n,i,a))}),xe(this,"removeOldImages",n=>{Array.from(this.currentImageContainer.children).forEach(i=>{if(i.tagName.toLowerCase()!=="img")return;const r=this.usingSprites?500:1e3;if(i.dataset.index!==n.dataset.index&&!i.dataset.deleting){i.dataset.deleting=!0;const{currentImageContainer:s}=this;setTimeout(()=>{s.removeChild(i),this.player.debug.log(`Removing thumb: ${i.dataset.filename}`)},r)}})}),xe(this,"preloadNearby",(n,i=!0)=>new Promise(r=>{setTimeout(()=>{const s=this.thumbnails[0].frames[n].text;if(this.showingThumbFilename===s){let a;a=i?this.thumbnails[0].frames.slice(n):this.thumbnails[0].frames.slice(0,n).reverse();let o=!1;a.forEach(l=>{const c=l.text;if(c!==s&&!this.loadedImages.includes(c)){o=!0,this.player.debug.log(`Preloading thumb filename: ${c}`);const{urlPrefix:d}=this.thumbnails[0],u=d+c,p=new Image;p.src=u,p.onload=()=>{this.player.debug.log(`Preloaded thumb filename: ${c}`),this.loadedImages.includes(c)||this.loadedImages.push(c),r()}}}),o||r()}},300)})),xe(this,"getHigherQuality",(n,i,r,s)=>{if(n<this.thumbnails.length-1){let a=i.naturalHeight;this.usingSprites&&(a=r.h),a<this.thumbContainerHeight&&setTimeout(()=>{this.showingThumbFilename===s&&(this.player.debug.log(`Showing higher quality thumb for: ${s}`),this.loadImage(n+1))},300)}}),xe(this,"toggleThumbContainer",(n=!1,i=!1)=>{const r=this.player.config.classNames.previewThumbnails.thumbContainerShown;this.elements.thumb.container.classList.toggle(r,n),!n&&i&&(this.showingThumb=null,this.showingThumbFilename=null)}),xe(this,"toggleScrubbingContainer",(n=!1)=>{const i=this.player.config.classNames.previewThumbnails.scrubbingContainerShown;this.elements.scrubbing.container.classList.toggle(i,n),n||(this.showingThumb=null,this.showingThumbFilename=null)}),xe(this,"determineContainerAutoSizing",()=>{(this.elements.thumb.imageContainer.clientHeight>20||this.elements.thumb.imageContainer.clientWidth>20)&&(this.sizeSpecifiedInCSS=!0)}),xe(this,"setThumbContainerSizeAndPos",()=>{const{imageContainer:n}=this.elements.thumb;if(this.sizeSpecifiedInCSS){if(n.clientHeight>20&&n.clientWidth<20){const i=Math.floor(n.clientHeight*this.thumbAspectRatio);n.style.width=`${i}px`}else if(n.clientHeight<20&&n.clientWidth>20){const i=Math.floor(n.clientWidth/this.thumbAspectRatio);n.style.height=`${i}px`}}else{const i=Math.floor(this.thumbContainerHeight*this.thumbAspectRatio);n.style.height=`${this.thumbContainerHeight}px`,n.style.width=`${i}px`}this.setThumbContainerPos()}),xe(this,"setThumbContainerPos",()=>{const n=this.player.elements.progress.getBoundingClientRect(),i=this.player.elements.container.getBoundingClientRect(),{container:r}=this.elements.thumb,s=i.left-n.left+10,a=i.right-n.left-r.clientWidth-10,o=this.mousePosX-n.left-r.clientWidth/2,l=Wp(o,s,a);r.style.left=`${l}px`,r.style.setProperty("--preview-arrow-offset",o-l+"px")}),xe(this,"setScrubbingContainerSize",()=>{const{width:n,height:i}=wd(this.thumbAspectRatio,{width:this.player.media.clientWidth,height:this.player.media.clientHeight});this.elements.scrubbing.container.style.width=`${n}px`,this.elements.scrubbing.container.style.height=`${i}px`}),xe(this,"setImageSizeAndOffset",(n,i)=>{if(!this.usingSprites)return;const r=this.thumbContainerHeight/i.h;n.style.height=n.naturalHeight*r+"px",n.style.width=n.naturalWidth*r+"px",n.style.left=`-${i.x*r}px`,n.style.top=`-${i.y*r}px`}),this.player=t,this.thumbnails=[],this.loaded=!1,this.lastMouseMoveTime=Date.now(),this.mouseDown=!1,this.loadedImages=[],this.elements={thumb:{},scrubbing:{}},this.load()}get enabled(){return this.player.isHTML5&&this.player.isVideo&&this.player.config.previewThumbnails.enabled}get currentImageContainer(){return this.mouseDown?this.elements.scrubbing.container:this.elements.thumb.imageContainer}get usingSprites(){return Object.keys(this.thumbnails[0].frames[0]).includes("w")}get thumbAspectRatio(){return this.usingSprites?this.thumbnails[0].frames[0].w/this.thumbnails[0].frames[0].h:this.thumbnails[0].width/this.thumbnails[0].height}get thumbContainerHeight(){if(this.mouseDown){const{height:t}=wd(this.thumbAspectRatio,{width:this.player.media.clientWidth,height:this.player.media.clientHeight});return t}return this.sizeSpecifiedInCSS?this.elements.thumb.imageContainer.clientHeight:Math.floor(this.player.media.clientWidth/this.thumbAspectRatio/4)}get currentImageElement(){return this.mouseDown?this.currentScrubbingImageElement:this.currentThumbnailImageElement}set currentImageElement(t){this.mouseDown?this.currentScrubbingImageElement=t:this.currentThumbnailImageElement=t}}const Oo={insertElements(e,t){$.string(t)?yd(e,this.media,{src:t}):$.array(t)&&t.forEach(n=>{yd(e,this.media,n)})},change(e){xp(e,"sources.length")?(Bn.cancelRequests.call(this),this.destroy.call(this,()=>{this.options.quality=[],Pn(this.media),this.media=null,$.element(this.elements.container)&&this.elements.container.removeAttribute("class");const{sources:t,type:n}=e,[{provider:i=Vn.html5,src:r}]=t,s=i==="html5"?n:"div",a=i==="html5"?{}:{src:r};Object.assign(this,{provider:i,type:n,supported:St.check(n,i,this.config.playsinline),media:$e(s,a)}),this.elements.container.appendChild(this.media),$.boolean(e.autoplay)&&(this.config.autoplay=e.autoplay),this.isHTML5&&(this.config.crossorigin&&this.media.setAttribute("crossorigin",""),this.config.autoplay&&this.media.setAttribute("autoplay",""),$.empty(e.poster)||(this.poster=e.poster),this.config.loop.active&&this.media.setAttribute("loop",""),this.config.muted&&this.media.setAttribute("muted",""),this.config.playsinline&&this.media.setAttribute("playsinline","")),dt.addStyleHook.call(this),this.isHTML5&&Oo.insertElements.call(this,"source",t),this.config.title=e.title,Yp.setup.call(this),this.isHTML5&&Object.keys(e).includes("tracks")&&Oo.insertElements.call(this,"track",e.tracks),(this.isHTML5||this.isEmbed&&!this.supported.ui)&&dt.build.call(this),this.isHTML5&&this.media.load(),$.empty(e.previewThumbnails)||(Object.assign(this.config.previewThumbnails,e.previewThumbnails),this.previewThumbnails&&this.previewThumbnails.loaded&&(this.previewThumbnails.destroy(),this.previewThumbnails=null),this.config.previewThumbnails.enabled&&(this.previewThumbnails=new Po(this))),this.fullscreen.update()},!0)):this.debug.warn("Invalid source format")}};class fi{constructor(t,n){if(xe(this,"play",()=>$.function(this.media.play)?(this.ads&&this.ads.enabled&&this.ads.managerPromise.then(()=>this.ads.play()).catch(()=>mn(this.media.play())),this.media.play()):null),xe(this,"pause",()=>this.playing&&$.function(this.media.pause)?this.media.pause():null),xe(this,"togglePlay",o=>($.boolean(o)?o:!this.playing)?this.play():this.pause()),xe(this,"stop",()=>{this.isHTML5?(this.pause(),this.restart()):$.function(this.media.stop)&&this.media.stop()}),xe(this,"restart",()=>{this.currentTime=0}),xe(this,"rewind",o=>{this.currentTime-=$.number(o)?o:this.config.seekTime}),xe(this,"forward",o=>{this.currentTime+=$.number(o)?o:this.config.seekTime}),xe(this,"increaseVolume",o=>{const l=this.media.muted?0:this.volume;this.volume=l+($.number(o)?o:0)}),xe(this,"decreaseVolume",o=>{this.increaseVolume(-o)}),xe(this,"airplay",()=>{St.airplay&&this.media.webkitShowPlaybackTargetPicker()}),xe(this,"toggleControls",o=>{if(this.supported.ui&&!this.isAudio){const l=gr(this.elements.container,this.config.classNames.hideControls),c=o===void 0?void 0:!o,d=nt(this.elements.container,this.config.classNames.hideControls,c);if(d&&$.array(this.config.controls)&&this.config.controls.includes("settings")&&!$.empty(this.config.settings)&&Le.toggleMenu.call(this,!1),d!==l){const u=d?"controlshidden":"controlsshown";Ue.call(this,this.media,u)}return!d}return!1}),xe(this,"on",(o,l)=>{Ze.call(this,this.elements.container,o,l)}),xe(this,"once",(o,l)=>{pl.call(this,this.elements.container,o,l)}),xe(this,"off",(o,l)=>{Yr(this.elements.container,o,l)}),xe(this,"destroy",(o,l=!1)=>
vendor: 9,299 bytes, line 31
31{if(!this.ready)return;const c=()=>{document.body.style.overflow="",this.embed=null,l?(Object.keys(this.elements).length&&(Pn(this.elements.buttons.play),Pn(this.elements.captions),Pn(this.elements.controls),Pn(this.elements.wrapper),this.elements.buttons.play=null,this.elements.captions=null,this.elements.controls=null,this.elements.wrapper=null),$.function(o)&&o()):(eC.call(this),Bn.cancelRequests.call(this),mr(this.elements.original,this.elements.container),Ue.call(this,this.elements.original,"destroyed",!0),$.function(o)&&o.call(this.elements.original),this.ready=!1,setTimeout(()=>{this.elements=null,this.media=null},200))};this.stop(),clearTimeout(this.timers.loading),clearTimeout(this.timers.controls),clearTimeout(this.timers.resized),this.isHTML5?(dt.toggleNativeControls.call(this,!0),c()):this.isYouTube?(clearInterval(this.timers.buffering),clearInterval(this.timers.playing),this.embed!==null&&$.function(this.embed.destroy)&&this.embed.destroy(),c()):this.isVimeo&&(this.embed!==null&&this.embed.unload().then(c),setTimeout(c,200))}),xe(this,"supports",o=>St.mime.call(this,o)),this.timers={},this.ready=!1,this.loading=!1,this.failed=!1,this.touch=St.touch,this.media=t,$.string(this.media)&&(this.media=document.querySelectorAll(this.media)),(window.jQuery&&this.media instanceof jQuery||$.nodeList(this.media)||$.array(this.media))&&(this.media=this.media[0]),this.config=Et({},jp,fi.defaults,n||{},(()=>{try{return JSON.parse(this.media.getAttribute("data-plyr-config"))}catch{return{}}})()),this.elements={container:null,fullscreen:null,captions:null,buttons:{},display:{},progress:{},inputs:{},settings:{popup:null,menu:null,panels:{},buttons:{}}},this.captions={active:null,currentTrack:-1,meta:new WeakMap},this.fullscreen={active:!1},this.options={speed:[],quality:[]},this.debug=new hC(this.config.debug),this.debug.log("Config",this.config),this.debug.log("Support",St),$.nullOrUndefined(this.media)||!$.element(this.media))return void this.debug.error("Setup failed: no suitable element passed");if(this.media.plyr)return void this.debug.warn("Target already setup");if(!this.config.enabled)return void this.debug.error("Setup failed: disabled by config");if(!St.check().api)return void this.debug.error("Setup failed: no support");const i=this.media.cloneNode(!0);i.autoplay=!1,this.elements.original=i;const r=this.media.tagName.toLowerCase();let s=null,a=null;switch(r){case"div":if(s=this.media.querySelector("iframe"),$.element(s)){if(a=Kp(s.getAttribute("src")),this.provider=uC(a.toString()),this.elements.container=this.media,this.media=s,this.elements.container.className="",a.search.length){const o=["1","true"];o.includes(a.searchParams.get("autoplay"))&&(this.config.autoplay=!0),o.includes(a.searchParams.get("loop"))&&(this.config.loop.active=!0),this.isYouTube?(this.config.playsinline=o.includes(a.searchParams.get("playsinline")),this.config.youtube.hl=a.searchParams.get("hl")):this.config.playsinline=!0}}else this.provider=this.media.getAttribute(this.config.attributes.embed.provider),this.media.removeAttribute(this.config.attributes.embed.provider);if($.empty(this.provider)||!Object.values(Vn).includes(this.provider))return void this.debug.error("Setup failed: Invalid provider");this.type=Ta.video;break;case"video":case"audio":this.type=r,this.provider=Vn.html5,this.media.hasAttribute("crossorigin")&&(this.config.crossorigin=!0),this.media.hasAttribute("autoplay")&&(this.config.autoplay=!0),(this.media.hasAttribute("playsinline")||this.media.hasAttribute("webkit-playsinline"))&&(this.config.playsinline=!0),this.media.hasAttribute("muted")&&(this.config.muted=!0),this.media.hasAttribute("loop")&&(this.config.loop.active=!0);break;default:return void this.debug.error("Setup failed: unsupported type")}this.supported=St.check(this.type,this.provider),this.supported.api?(this.eventListeners=[],this.listeners=new pC(this),this.storage=new pi(this),this.media.plyr=this,$.element(this.elements.container)||(this.elements.container=$e("div"),Mp(this.media,this.elements.container)),dt.migrateStyles.call(this),dt.addStyleHook.call(this),Yp.setup.call(this),this.config.debug&&Ze.call(this,this.elements.container,this.config.events.join(" "),o=>{this.debug.log(`event: ${o.type}`)}),this.fullscreen=new tn(this),(this.isHTML5||this.isEmbed&&!this.supported.ui)&&dt.build.call(this),this.listeners.container(),this.listeners.global(),this.config.ads.enabled&&(this.ads=new _C(this)),this.isHTML5&&this.config.autoplay&&this.once("canplay",()=>mn(this.play())),this.lastSeekTime=0,this.config.previewThumbnails.enabled&&(this.previewThumbnails=new Po(this))):this.debug.error("Setup failed: no support")}get isHTML5(){return this.provider===Vn.html5}get isEmbed(){return this.isYouTube||this.isVimeo}get isYouTube(){return this.provider===Vn.youtube}get isVimeo(){return this.provider===Vn.vimeo}get isVideo(){return this.type===Ta.video}get isAudio(){return this.type===Ta.audio}get playing(){return!!(this.ready&&!this.paused&&!this.ended)}get paused(){return!!this.media.paused}get stopped(){return!!(this.paused&&this.currentTime===0)}get ended(){return!!this.media.ended}set currentTime(t){if(!this.duration)return;const n=$.number(t)&&t>0;this.media.currentTime=n?Math.min(t,this.duration):0,this.debug.log(`Seeking to ${this.currentTime} seconds`)}get currentTime(){return Number(this.media.currentTime)}get buffered(){const{buffered:t}=this.media;return $.number(t)?t:t&&t.length&&this.duration>0?t.end(0)/this.duration:0}get seeking(){return!!this.media.seeking}get duration(){const t=parseFloat(this.config.duration),n=(this.media||{}).duration,i=$.number(n)&&n!==1/0?n:0;return t||i}set volume(t){let n=t;$.string(n)&&(n=Number(n)),$.number(n)||(n=this.storage.get("volume")),$.number(n)||({volume:n}=this.config),n>1&&(n=1),n<0&&(n=0),this.config.volume=n,this.media.volume=n,!$.empty(t)&&this.muted&&n>0&&(this.muted=!1)}get volume(){return Number(this.media.volume)}set muted(t){let n=t;$.boolean(n)||(n=this.storage.get("muted")),$.boolean(n)||(n=this.config.muted),this.config.muted=n,this.media.muted=n}get muted(){return!!this.media.muted}get hasAudio(){return!this.isHTML5||!!this.isAudio||!!this.media.mozHasAudio||!!this.media.webkitAudioDecodedByteCount||!!(this.media.audioTracks&&this.media.audioTracks.length)}set speed(t){let n=null;$.number(t)&&(n=t),$.number(n)||(n=this.storage.get("speed")),$.number(n)||(n=this.config.speed.selected);const{minimumSpeed:i,maximumSpeed:r}=this;n=Wp(n,i,r),this.config.speed.selected=n,setTimeout(()=>{this.media&&(this.media.playbackRate=n)},0)}get speed(){return Number(this.media.playbackRate)}get minimumSpeed(){return this.isYouTube?Math.min(...this.options.speed):this.isVimeo?.5:.0625}get maximumSpeed(){return this.isYouTube?Math.max(...this.options.speed):this.isVimeo?2:16}set quality(t){const n=this.config.quality,i=this.options.quality;if(!i.length)return;let r=[!$.empty(t)&&Number(t),this.storage.get("quality"),n.selected,n.default].find($.number),s=!0;if(!i.includes(r)){const a=Fp(i,r);this.debug.warn(`Unsupported quality option: ${r}, using ${a} instead`),r=a,s=!1}n.selected=r,this.media.quality=r,s&&this.storage.set({quality:r})}get quality(){return this.media.quality}set loop(t){const n=$.boolean(t)?t:this.config.loop.active;this.config.loop.active=n,this.media.loop=n}get loop(){return!!this.media.loop}set source(t){Oo.change.call(this,t)}get source(){return this.media.currentSrc}get download(){const{download:t}=this.config.urls;return $.url(t)?t:this.source}set download(t){$.url(t)&&(this.config.urls.download=t,Le.setDownloadUrl.call(this))}set poster(t){this.isVideo?dt.setPoster.call(this,t,!1).catch(()=>{}):this.debug.warn("Poster can only be set for video")}get poster(){return this.isVideo?this.media.getAttribute("poster")||this.media.getAttribute("data-poster"):null}get ratio(){if(!this.isVideo)return null;const t=yr(fl.call(this));return $.array(t)?t.join(":"):t}set ratio(t){this.isVideo?$.string(t)&&Bp(t)?(this.config.ratio=yr(t),Ns.call(this)):this.debug.error(`Invalid aspect ratio specified (${t})`):this.debug.warn("Aspect ratio can only be set for video")}set autoplay(t){this.config.autoplay=$.boolean(t)?t:this.config.autoplay}get autoplay(){return!!this.config.autoplay}toggleCaptions(t){qe.toggle.call(this,t,!1)}set currentTrack(t){qe.set.call(this,t,!1),qe.setup.call(this)}get currentTrack(){const{toggled:t,currentTrack:n}=this.captions;return t?n:-1}set language(t){qe.setLanguage.call(this,t,!1)}get language(){return(qe.getCurrentTrack.call(this)||{}).language}set pip(t){if(!St.pip)return;const n=$.boolean(t)?t:!this.pip;$.function(this.media.webkitSetPresentationMode)&&this.media.webkitSetPresentationMode(n?Ia.active:Ia.inactive),$.function(this.media.requestPictureInPicture)&&(!this.pip&&n?this.media.requestPictureInPicture():this.pip&&!n&&document.exitPictureInPicture())}get pip(){return St.pip?$.empty(this.media.webkitPresentationMode)?this.media===document.pictureInPictureElement:this.media.webkitPresentationMode===Ia.active:null}setPreviewThumbnails(t){this.previewThumbnails&&this.previewThumbnails.loaded&&(this.previewThumbnails.destroy(),this.previewThumbnails=null),Object.assign(this.config.previewThumbnails,t),this.config.previewThumbnails.enabled&&(this.previewThumbnails=new Po(this))}
31static supported(t,n){return St.check(t,n)}static loadSprite(t,n){return Hp(t,n)}static setup(t,n={}){let i=null;return $.string(t)?i=Array.from(document.querySelectorAll(t)):$.nodeList(t)?i=Array.from(t):$.array(t)&&(i=t.filter($.element)),$.empty(i)?null:i.map(r=>new fi(r,n))}}fi.defaults=ZS(jp);const TJ=e=>e,PJ=e=>e.endsWith("_1")?e.slice(0,-2):e,EC=(e,t)=>e?[{eye:"OD",sku:e,quantity:t.OD_QUANTITY},{eye:"OS",sku:e,quantity:t.OS_QUANTITY}].filter(n=>n.quantity>0):[],OJ=e=>!["CLKITSDCSBR","CLKITSDCOBL","CLKITSDCSGY","CLKITSDCTPR","CLKITSDCLGR","CLKITSDA30","CLKITSDA90"].includes(e),AJ=e=>!!["CLKITSDCSBR","CLKITSDCOBL","CLKITSDCSGY","CLKITSDCTPR","CLKITSDCLGR"].includes(e),kJ={CL1DAVO90JJ:{alconSku:"CLP190AL",subhead:"Precise vision and dependable comfort in an easy-to-love daily.",name:"Precision 1 (90 Pack)"},CL1DAVOT90JJ:{alconSku:"CLP1AS90AL",subhead:"Uniquely designed to correct astigmatism with excellent vision.",name:"Precision 1 for Astigmatism (90 Pack)"},CLBICV:{alconSku:"CLTOTAL30AL",subhead:"The only monthly Water Gradient lens - feels like nothing, even at day 30.",name:"Total30 6 pack"},CLBITCV:{alconSku:"CLTOTAL30TAL",subhead:"Exceptionally clear, stable vision and total comfort, all month.",name:"Total30 for Astigmatism"},CL1DAVM90JJ:{alconSku:"CLP190AL",subhead:"Step up to a silicone-hydrogel daily with SMARTSURFACE® moisture.",name:"Precision 1 (90 Pack)"},CLAVO12JJ:{alconSku:"CLP712AL",subhead:"Weekly-fresh comfort that lasts up to 16 hours, even on day 7.",name:"Precision7 (12 pack)"},CLAOAJJ:{alconSku:"CLP7AS12AL",subhead:"Weekly-fresh, stable vision for astigmatism in a breathable SiHy toric.",name:"Precision7 for Astigmatism (12 pack)"},CLDAC90CV:{alconSku:"CLP190AL",subhead:"Upgrade from hydrogel to a silicone-hydrogel daily with SMARTSURFACE® moisture.",name:"Precision 1 (90 Pack)"},CLO2AHGCV:{alconSku:"CLTOTAL30AL",subhead:"Same monthly routine, now Water Gradient - silky-smooth from day 1 to day 30.",name:"Total30 6 pack"},CLAONDACV:{alconSku:"CLP712AL",subhead:"Weekly-fresh silicone-hydrogel comfort.",name:"Precision7 (12 pack)"},CLDACT90AL:{alconSku:"CLP1AS90AL",subhead:"A silicone-hydrogel daily toric with excellent vision.",name:"Precision 1 for Astigmatism (90 Pack)"},CLO2AHGTCV:{alconSku:"CLTOTAL30TAL",subhead:"Upgraded Water Gradient comfort, same monthly schedule.",name:"Total30 for Astigmatism"},CLO2AHGMCV:{alconSku:"CLTOTAL30MF",subhead:"The only monthly multifocal Water Gradient lens - seamless near through far.",name:"Total30 Multifocal"}},RJ={CLP130AL:{acuvueSku:"CL1DAVO30JJ",subhead:"ACUVUE&reg; OASYS 1-Day helps bring your vision into focus with exceptional comfort, every day.",name:"Acuvue Oasys 1-Day 30 Pack with HydraLuxe"},CLP190AL:{acuvueSku:"CL1DAVO90JJ",subhead:"ACUVUE&reg; OASYS 1-Day helps bring your vision into focus with exceptional comfort, every day.",name:"Acuvue Oasys 1-Day 90 Pack with HydraLuxe"},CLP1AS30AL:{acuvueSku:"CL1DAVOT30JJ",subhead:"ACUVUE&reg; OASYS 1-Day helps bring your vision into focus with exceptional comfort, every day.",name:"Acuvue Oasys 1-Day for Astigmatism 30 pack with HydraLuxe"},CLP1AS90AL:{acuvueSku:"CL1DAVOT90JJ",subhead:"ACUVUE&reg; OASYS 1-Day helps bring your vision into focus with exceptional comfort, every day.",name:"Acuvue Oasys 1-Day for Astigmatism 90 pack with HydraLuxe"},CLDT130CACV:{acuvueSku:"CL1DAVOMX30JJ",subhead:"Designed with innovative technologies to help with today's digitally intense lifestyle.",name:"Acuvue Oasys MAX 1-Day 30 Pack"},CLDT190CACV:{acuvueSku:"CL1DAVOMX90JJ",subhead:"Designed with innovative technologies to help with today's digitally intense lifestyle.",name:"Acuvue Oasys MAX 1-Day 90 Pack"},CLDT1M30AL:{acuvueSku:"CL1DAVOMXMF30JJ",subhead:"Designed with innovative technologies to help with today's digitally intense lifestyle.",name:"Acuvue Oasys MAX 1-Day Multifocal 30 Pack"},CLDT1M90AL:{acuvueSku:"CL1DAVOMXMF90JJ",subhead:"Designed with innovative technologies to help with today's digitally intense lifestyle.",name:"Acuvue Oasys MAX 1-Day Multifocal 90 Pack"},CLDT1T30CV:{acuvueSku:"CL1DAVOMXAS30JJ",subhead:"Designed with innovative technologies to help with today's digitally intense lifestyle.",name:"Acuvue Oasys MAX 1-Day for Astigmatism 30 Pack"}};var br=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};
31function Qp(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var Zp={},Qr={};Object.defineProperty(Qr,"__esModule",{value:!0});Qr.regionAPIs=void 0;Qr.regionAPIs=new Map([["us","https://api-iam.intercom.io"],["eu","https://api-iam.eu.intercom.io"],["ap","https://api-iam.au.intercom.io"]]);var Ds={},SC=br&&br.__awaiter||function(e,t,n,i){function r(s){return s instanceof n?s:new n(function(a){a(s)})}return new(n||(n=Promise))(function(s,a){function o(d){try{c(i.next(d))}catch(u){a(u)}}function l(d){try{c(i.throw(d))}catch(u){a(u)}}function c(d){d.done?s(d.value):r(d.value).then(o,l)}c((i=i.apply(e,t||[])).next())})};Object.defineProperty(Ds,"__esModule",{value:!0});Ds.ref=Ds.init=void 0;const Ed="_intercom_npm_loader",mi=function(){mi.loaderQueue(arguments)};mi.q=[];mi.loaderQueue=function(e){mi.q.push(e)};const Ki=function(){var e,t,n=document;if(!n.getElementById(Ed)){var i=n.createElement("script");i.type="text/javascript",i.async=!0,i.id=Ed,i.src="https://widget.intercom.io/widget/"+((e=window.intercomSettings)===null||e===void 0?void 0:e.app_id);var r=n.getElementsByTagName("script")[0];(t=r.parentNode)===null||t===void 0||t.insertBefore(i,r)}},Sd=()=>document.readyState==="complete"||document.readyState==="interactive",CC=()=>SC(void 0,void 0,void 0,function*(){var e=window,t=e.Intercom;e.intercomSettings&&(e.intercomSettings.installation_type="npm-package"),typeof t=="function"?(t("reattach_activator"),t("update",e.intercomSettings)):(e.Intercom=mi,Sd()?Ki():(document.addEventListener("readystatechange",function(){Sd()&&Ki()}),e.attachEvent?e.attachEvent("onload",Ki):e.addEventListener("load",Ki,!1)))});Ds.init=CC;Ds.ref=void 0;(function(e){var t=br&&br.__rest||function(L,D){var z={};for(var G in L)Object.prototype.hasOwnProperty.call(L,G)&&D.indexOf(G)<0&&(z[G]=L[G]);if(L!=null&&typeof Object.getOwnPropertySymbols=="function")for(var ne=0,G=Object.getOwnPropertySymbols(L);ne<G.length;ne++)D.indexOf(G[ne])<0&&Object.prototype.propertyIsEnumerable.call(L,G[ne])&&(z[G[ne]]=L[G[ne]]);return z};Object.defineProperty(e,"__esModule",{value:!0}),e.onUserEmailSupplied=e.showConversation=e.showTicket=e.startChecklist=e.startSurvey=e.showNews=e.showArticle=e.startTour=e.getVisitorId=e.trackEvent=e.onUnreadCountChange=e.onShow=e.onHide=e.showNewMessage=e.showMessages=e.showSpace=e.show=e.hide=e.update=e.shutdown=e.boot=e.Intercom=void 0;const n=Qr,i=Ds,r=(L,...D)=>{typeof window!==void 0&&window.Intercom?window.Intercom(L,...D):console.warn("Please ensure Intercom is setup and running on client-side!")},s=L=>{if(typeof L!="object"){console.warn("Intercom initialiser called with invalid parameters.");return}const{region:D="us"}=L,z=t(L,["region"]);typeof window<"u"&&!i.ref&&(window.intercomSettings=Object.assign(Object.assign({},z),{api_base:n.regionAPIs.get(D)}),(0,i.init)())};e.Intercom=s,e.default=e.Intercom;const a=L=>r("boot",L);e.boot=a;const o=()=>r("shutdown");e.shutdown=o;const l=L=>r("update",L);e.update=l;const c=()=>r("hide");e.hide=c;const d=()=>r("show");e.show=d;const u=L=>r("showSpace",L);e.showSpace=u;const p=()=>r("showMessages");e.showMessages=p;const h=L=>r("showNewMessage",L);e.showNewMessage=h;const m=L=>r("onHide",L);e.onHide=m;const v=L=>r("onShow",L);e.onShow=v;const _=L=>r("onUnreadCountChange",L);e.onUnreadCountChange=_;const b=(...L)=>r("trackEvent",...L);e.trackEvent=b;const w=()=>r("getVisitorId");e.getVisitorId=w;const C=L=>r("startTour",L);e.startTour=C;const O=L=>r("showArticle",L);e.showArticle=O;const T=L=>r("showNews",L);e.showNews=T;const E=L=>r("startSurvey",L);e.startSurvey=E;const y=L=>r("startChecklist",L);e.startChecklist=y;const P=L=>r("showTicket",L);e.showTicket=P;const A=L=>r("showConversation",L);e.showConversation=A;const I=L=>r("onUserEmailSupplied",L);e.onUserEmailSupplied=I})(Zp);const qp=Qp(Zp),se=()=>{let e=It(),t=e.hostname,n=e.host,i=t.split("."),{apiEndpoint:r}=Be().public;switch(i.length>1?i.slice(-2).join("."):t){case"localhost":n=r;break}return n},IC=()=>{const t=It().hostname,n=t.split("."),i=n.length>1?n.slice(-2).join("."):t,s=t.includes("localhost")||t.includes(".camp.")?{"kits.com":"https://search.unbxd.io/864d1797bfd230ef72d5cfdde5868364/ss-unbxd-gcp-kits-com-stage16621684171061/","kits.ca":"https://search.unbxd.io/0f58cac691ea94fdd83d50440eb950c6/ss-unbxd-gcp-kits-ca-stage16621696961026/","contactsexpress.ca":"https://search.unbxd.io/c7c85f54618539555be1ca0f5402aad9/ss-unbxd-gcp-contactsexpress-ca-stage16621696961318/","opticontacts.com":"https://search.unbxd.io/29e04e532beaf1fe1047d95a8deb51cd/ss-unbxd-gcp-opticontacts-stage16621696961246/","postalcontacts.com":"https://search.unbxd.io/caa77561c61341ce1a520350046a16fe/ss-unbxd-gcp-postalcontacts-stage16621696963125/"}:{"kits.com":"https://search.unbxd.io/fa194145848a3180eb26f41f4a855e05/ss-unbxd-gcp-kits-com-prod16621689373955/","kits.ca":"https://search.unbxd.io/7615ffb6e3e55bd1e0878257222a6eba/ss-unbxd-gcp-kits-ca-prod16621689373059/","contactsexpress.ca":"https://search.unbxd.io/e268fcf0345cfee4ff9e9d09c1b78a8e/ss-unbxd-gcp-contactsexpress-ca-prod16621689373366/","opticontacts.com":"https://search.unbxd.io/e011aa641d247fc0da0dfe7e243c931a/ss-unbxd-gcp-opticontacts-prod16621689373264/","postalcontacts.com":"https://search.unbxd.io/f9ee220008a18dcf64b29195adeae481/ss-unbxd-gcp-postalcontacts-prod16621689373314/"};return s[i]??s["kits.ca"]},Bt=()=>{let e=It(),t=e.hostname,n=e.host,i=t.split(".");switch(i.length>1?i.slice(-2).join("."):t){case"localhost":n=t==="localhost"?"http://localhost:3000":`https://${t}`;break;default:n=`https://${n}`;break}return n},ht=e=>{const n=e.split(":")[0].split(".");return n.includes("camp")&&n.splice(n.indexOf("camp"),1),n.slice(n.length-2).join(".")},TC=e=>typeof e=="string"&&e.toLowerCase().endsWith(".ca"),LJ=()=>{switch(ht(se())){case"kits.ca":return"KITS";case"kits.com":return"KITS";case"opticontacts.com":return"Opticontacts";case"postalcontacts.com":return"Postalcontacts";case"contactsexpress.ca":return"Contactsexpress";default:return""}},vr=(e,t)=>
31{const n=(e||"").toLowerCase().trim().split(/\s+/).filter(Boolean),r={readers:["readers","reading"],progressive:["progressive"]}[t]||[t],s={readers:3,reading:3,progressive:4};return n.some(a=>r.some(o=>{const l=s[o]||1;return a.length<l?!1:o.startsWith(a)||a===o}))},NJ=(e,t)=>{if(e){const n={controls:[],displayDuration:!0,autoplay:!0,muted:!0,volume:0,tooltips:{controls:!0,seek:!0},clickToPlay:!0,hideControls:!0,quality:{default:720,options:[1080,720,480,360]},hasAudio:!1},i=new fi(e,n);i.on("ended",()=>{i.play()})}},PC=(e,t)=>{if(e.length===0)return 0;if(t===0)return e[0].price;const n=e.find((i,r)=>{const s=r<e.length-1?e[r+1].quantity:1/0;return t>=i.quantity&&t<s});return n?n.price:0},ss=e=>parseFloat(e).toFixed(2),OC=()=>{const e={timeZone:"America/New_York",hour:"2-digit",minute:"2-digit",weekday:"short",hour12:!1},t=new Date,i=new Intl.DateTimeFormat("en-US",e).format(t),[r,s]=i.split(" "),[a,o]=s.split(":").map(c=>parseInt(c,10));return["Mon","Tue","Wed","Thu","Fri"].includes(r)?(a>10||a===10&&o>=0)&&(a<20||a===20&&o<=45):r==="Sat"?(a>10||a===10&&o>=0)&&(a<17||a===17&&o<=45):!1},AC=()=>{try{qp("show")}catch{console.log("Intercom not found")}},DJ=e=>
31{const{targetDate:t,timeZone:n="America/New_York",onComplete:i=()=>{},updateInterval:r=1e3}=e;let s=null;const a=()=>{let l=new Date(new Date().toLocaleString("en-US",{timeZone:n,year:"numeric",month:"numeric",day:"numeric",hour:"numeric",minute:"numeric",second:"numeric"}));l.setYear(t.year||l.getFullYear()),l.setMonth((t.month||1)-1),l.setDate(t.day||l.getDate()),l.setHours(t.hours||23),l.setMinutes(t.minutes||59),l.setSeconds(t.seconds||59);let c=new Date().toLocaleString("en-US",{timeZone:n});c=new Date(c).getTime();let d=l.getTime()-c;if(d<=0)return clearInterval(s),i(),{days:"00",hours:"00",minutes:"00",seconds:"00",isComplete:!0};let u=Math.floor(d/(1e3*60*60*24)),p=Math.floor(d%(1e3*60*60*24)/(1e3*60*60)),h=Math.floor(d%(1e3*60*60)/(1e3*60)),m=Math.floor(d%(1e3*60)/1e3);return{days:String(u).padStart(2,"0"),hours:String(p).padStart(2,"0"),minutes:String(h).padStart(2,"0"),seconds:String(m).padStart(2,"0"),isComplete:!1,raw:{days:u,hours:p,minutes:h,seconds:m,totalMilliseconds:d}}};return{start:l=>{let c=a();return l&&l(c),c.isComplete||(s=Sp(()=>{c=a(),l&&l(c)},r)),{stop:()=>{s&&(clearInterval(s),s=null)},getTimeRemaining:a}}}},kC=(e,t,n)=>{var s;if(t&&t.includes("_")||qr()||Zr())return 0;let i=e.contacts_discounts.environment[gl()],r=0;return r=i.general.discount_percentage,((s=i.special)==null?void 0:s.length)>0&&i.special.forEach(a=>{a.group==n&&(r=a.discount_percentage)}),r},Cd=e=>({products:e.products.map(t=>{const n=Object.fromEntries(Object.entries(t.options).filter(([i,r])=>r!==""&&r!=="Select a colour"));return{...t,options:n}})}),Jp=(e,t,n)=>{var s;if(e===null||e.length===0||t&&t.includes("_")||qr()||Zr())return null;let i=e.contacts_discounts.environment[gl()],r=null;return r=i.general,((s=i.special)==null?void 0:s.length)>0&&i.special.forEach(a=>{a.group==n&&(r=a)}),r},gl=()=>it.get("norders_contacts")==="1"&&it.get("norders_contacts_pla")==="0"?"first_contacts_reorder":it.get("norders_1r")>=1?"first_pla_reorder":it.get("norders_contacts")>=1?"repeat":"new",RC=()=>it.get("norders_glasses")>=1?"repeat":"new",xJ=e=>{const t=new Date(e);return Number.isNaN(t.getTime())?"":t.toLocaleDateString("en-US",{month:"short",day:"numeric",year:"numeric"})},yl=()=>{const e=document.getElementById("header-new");if(e){const n=`${e.clientHeight}px`;document.body.style.setProperty("margin-top",n,"important")}},Id=e=>[{sku:"GL02899",type:"hybrid"},{sku:"GL02898",type:"hybrid"},{sku:"GL02902",type:"hybrid"},{sku:"GL02903",type:"hybrid"},{sku:"GL02900",type:"hybrid"},{sku:"GL02901",type:"hybrid"},{sku:"GL02904",type:"hybrid"},{sku:"GL02680",type:"metalFrame"},{sku:"GL02679",type:"metalFrame"},{sku:"GL02682",type:"metalFrame"},{sku:"GL02681",type:"metalFrame"},{sku:"GL02049",type:"rimlessFrames"},{sku:"GL02048",type:"rimlessFrames"},{sku:"GL02046",type:"rimlessFrames"},{sku:"GL02044",type:"rimlessFrames"},{sku:"GL02045",type:"rimlessFrames"},{sku:"GL02047",type:"rimlessFrames"},{sku:"GL02592",type:"rimlessFrames"},{sku:"GL02595",type:"rimlessFrames"},{sku:"GL02593",type:"rimlessFrames"},{sku:"GL02596",type:"rimlessFrames"},{sku:"GL02594",type:"rimlessFrames"},{sku:"GL02597",type:"rimlessFrames"},{sku:"GL02704",type:"doubleBridgeMetalFrame"},{sku:"GL02703",type:"doubleBridgeMetalFrame"},{sku:"GL02706",type:"doubleBridgeMetalFrame"},{sku:"GL02705",type:"doubleBridgeMetalFrame"},{sku:"GL02712",type:"doubleBridgeMetalFrame"},{sku:"GL02711",type:"doubleBridgeMetalFrame"},{sku:"GL02714",type:"doubleBridgeMetalFrame"},{sku:"GL02713",type:"doubleBridgeMetalFrame"},{sku:"GL02715",type:"geometricFrame"},{sku:"GL02716",type:"geometricFrame"},{sku:"GL02718",type:"geometricFrame"},{sku:"GL02717",type:"geometricFrame"},{sku:"GL02684",type:"flexibleMetalFrame"},{sku:"GL02683",type:"flexibleMetalFrame"},{sku:"GL02686",type:"flexibleMetalFrame"},{sku:"GL02685",type:"flexibleMetalFrame"}].find(n=>n.sku==e),MJ=e=>{var n;return(n=[{type:"hybrid",text:"Ultra-lightweight hybrid frame"},{type:"metalFrame",text:"Flexible ultra-lightweight metal frame"},{type:"rimlessFrames",text:"Feather-weight"},{type:"doubleBridgeMetalFrame",text:"Ultra-lightweight double-bridge metal frame"},{type:"geometricFrame",text:"Ultra -lightweight geometric metal frame"},{type:"flexibleMetalFrame",text:"Flexible ultra-lightweight metal frame"}].find(i=>i.type===e))==null?void 0:n.text},LC=e=>e.charAt(0).toUpperCase()+e.slice(1),Ae=()=>{const e=window.location.pathname;return e.includes("fr_CA")||e.toLowerCase().includes("fr_ca")?"/fr_CA":""},NC=e=>{switch(!0){case(e.includes("BLUE")&&!e.includes("BLP")&&!e.includes("TINT")):return{displayName:"Blue Light Blocking",value:"blue_light_simple",backendValue:"BLUELIGHT",description:"Standard protection from blue light emitted by electronic devices.",image:"blue_light.svg",learnMore:{title:"Blue Light Blocking",text:"Protect your eyes from the harmful effects of blue light and from digital screen fatigue.",image:"blue_light_cover_standard.jpg"},cheapestPriceValue:"cheapest_bluelight_lens_price"};case e.includes("BLP"):return{displayName:"Blue Light Blocking Plus",value:"blue_light_plus",backendValue:"BLUELIGHTPLUS",description:"Filters out blue light emitted by digital screens, LED lights, and sunlight and reduces eye strain, fatigue from blue light.",image:"blue_light.svg",learnMore:{title:"Blue Light Blocking Plus",text:"Blue light glasses offer benefits such as reducing eye strain and fatigue from digital screens, alleviating symptoms of digital eye strain, improving sleep quality by minimizing melatonin disruption, and potentially helping with migraine prevention. They provide a practical solution to mitigate the negative effects of excessive blue light exposure, promoting visual comfort and overall well-being.",image:"blue_light_plus_cover.png"},cheapestPriceValue:"cheapest_bluelight_lens_price"};case(e.includes("PHOTOGREY")||e.includes("PHOTOBROWN")||e.includes("PROG2PTBROWN")||e.includes("PROGPTBROWN")):return{displayName:"Light Transitioning",value:"light_transitioning",backendValue:"PHOTOCHROMIC",description:"Lenses that adapt to changing light conditions, offering UV protection and glare reduction.",learnMore:{title:"Light Transitioning",text:"Light transitioning lenses offer convenient and versatile eyewear benef
31its. They automatically adjust their tint in response to changing light conditions, providing UV protection, glare reduction, and improved visual comfort. With light transitioning lenses, wearers can enjoy all-day eye protection and optimal vision without the need to switch between different pairs of glasses.",image:"light_transitioning_cover.jpg"},children:[],image:"light_adaptiveve_light.svg",title:"Choose your lens options",cheapestPriceValue:"cheapest_light_transition_lens_price"};case(e.includes("POLARIZEDGREY")||e.includes("POLGREY")):return{displayName:"Polarized Grey",value:"polarized_grey",backendValue:"POLARIZEDGREY",description:"Reduce glare, improve visual clarity, and enhance color perception.",image:"polarized_grey.svg",learnMore:null,cheapestPriceValue:"cheapest_sun_lens_price"};case(e.includes("POLARIZEDBROWN")||e.includes("POLBROWN")):return{displayName:"Polarized Brown",value:"polarized_brown",backendValue:"POLARIZEDBROWN",description:"Reduce glare, improve visual clarity, and enhance color perception.",image:"polarized_brown.svg",learnMore:null,cheapestPriceValue:"cheapest_sun_lens_price"};case(e.includes("POLARIZEDGREEN")||e.includes("POLGREEN")):return{displayName:"Polarized Green",value:"polarized_green",backendValue:"POLARIZEDGREEN",de
31scription:"Reduce glare, improve visual clarity, and enhance color perception.",image:"polarized_green.svg",learnMore:null,cheapestPriceValue:"cheapest_sun_lens_price"};case(e.includes("TINTEDBLUE")||e.includes("TINTBLUE")):return{displayName:"Tinted Blue",value:"tinted_blue",backendValue:"TINTEDBLUE",description:"Improve visual clarity and enhance color perception.",image:"LENSTINTPLBLUE.svg",learnMore:null,colorHex:"#CDECF4",cheapestPriceValue:"cheapest_sun_lens_price"};case e.includes("LENSTINTGREY"):return{displayName:"Tinted Grey",value:"tinted_grey",backendValue:"TINTEDGREY",description:"Improve visual clarity and enhance color perception.",image:"LENSTINTGREY.svg",learnMore:null,colorHex:"#76787D",cheapestPriceValue:"cheapest_sun_lens_price"};case e.includes("LENSTINTBROWN"):return{displayName:"Tinted Brown",value:"tinted_brown",backendValue:"TINTEDBROWN",description:"Improve visual clarity and enhance color perception.",image:"LENSTINTBROWN.svg",learnMore:null,colorHex:"#99682C",cheapestPriceValue:"cheapest_sun_lens_price"};case e.includes("LENSTINTPLBLUE"):return{displayName:"Tinted Blue",value:"tinted_blue",backendValue:"TINTEDBLUE",description:"Improve visual clarity and enhance color perception.",image:"LENSTINTPLBLUE.svg",learnMore:null,colorHex:"#CDECF4",cheapestPriceValue:"cheapest_sun_lens_price"};case e.includes("LENSTINTPLGREY"):return;case e.includes("LENSTINTPLPINK"):return{displayName:"Tinted Pink",value:"tinted_pink",backendValue:"TINTEDPINK",description:"Improve visual clarity and enhance color perception.",image:"LENSTINTPLPINK.svg",learnMore:null,colorHex:"#FECDCA",cheapestPriceValue:"cheapest_sun_lens_price"};case e.includes("LENSTINTPLBROWN"):return{displayName:"Tinted Brown",value:"tinted_brown",backendValue:"TINTEDBROWN",description:"Improve visual clarity and enhance color perception.",image:"LENSTINTBROWN.svg",colorHex:"#99682C",learnMore:null,cheapestPriceValue:"cheapest_sun_lens_price"};case e.includes("LENSTINTPLDGREEN"):return{displayName:"Tinted Dark Green",value:"tinted_dark_green",backendValue:"TINTEDDGREEN",description:"Improve visual clarity and enhance color perception.",image:"LENSTINTPLDGREEN.svg",learnMore:null,colorHex:"#879B5E",cheapestPriceValue:"cheapest_sun_lens_price"};case e.includes("LENSTINTPLORANGE"):return{displayName:"Tinted Orange",value:"tinted_orange",backendValue:"TINTEDORANGE",description:"Improve visual clarity and enhance color perception.",image:"LENSTINTPLORANGE.svg",learnMore:null,colorHex:"#FFD8C2",cheapestPriceValue:"cheapest_sun_lens_price"};case e.includes("LENSTINTPLPURPLE"):return{displayName:"Tinted Purple",value:"tinted_purple",backendValue:"TINTEDPURPLE",description:"Improve visual clarity and enhance color perception.",image:"LENSTINTPLPURPLE.svg",learnMore:null,colorHex:"#D4C7E4",cheapestPriceValue:"cheapest_sun_lens_price"};default:return{displayName:"Clear",value:"clear",backendValue:"CLEAR",description:"Transparent lenses for everyday use.",learnMore:null,children:[],image:"clear_lenses.svg",title:"Choose your lens options",cheapestPriceValue:"cheapest_clear_lens_price"}}},DC=e=>{let t={prodGroup:"",displayName:"",type:"",backendValue:"",parentValueName:"",cookieValue:""};switch(e){case"distance":return{...t,prodGroup:"Single Vision",displayName:"Single Vision",type:"distance",backendValue:"Single Vision",cookieValue:"distance"};case"progressive":return{...t,prodGroup:"Progressive",displayName:"Standard Progressives",type:"progressives",backendValue:"Progressive",parentValueName:"",cookieValue:"progressive"};case"progressive2":return{...t,prodGroup:"Progressive2",displayName:"Enhanced Progressives",type:"progressives",backendValue:"Progressive2",parentValueName:"",cookieValue:"progressive"};case"simple-readers":return{...t,prodGroup:"Single Vision",displayName:"Simple readers",type:"readers",backendValue:"Single Vision",cookieValue:"reading"};case"prescription-readers":return{...t,prodGroup:"Single Vision",displayName:"Prescription readers",type:"readers",backendValue:"Single Vision",cookieValue:"reading"};case"non-prescription":return{...t,prodGroup:"Single Vision",displayName:"Non-Prescription",type:"non-prescription",backendValue:"Single Vision",cookieValue:"non-prescription"};default:return t}},xC=e=>{let t="";return e.startsWith("blue_light")?t=e:e.startsWith("polarized")?t="polarized_sun_lenses":e.startsWith("tinted")&&(t="tinted_sun_lenses"),t},FJ=(e,t)=>{if(e&&e.name){let n=document.createElement("script");n.setAttribute("src",`//www.resellerratings.com/productreviews/widget/javascript/Kits.js?sku=${t}`),document.head.appendChild(n);let i=document.createElement("script");i.textContent=`var __RRPRWidget_Settings = {
32          name: "${e.name}",
33          sku: '${t}',
34          img: "${e.product_images.find(r=>r.type=="primary").image}",
35          url: "",
36          brand: "",
37          category: "Glasses",
38          load: function() {
39          }
40    }; `,document.head.appendChild(i)}},VJ=e=>{const t=jv(),n=Yv(),{[e]:i,...r}=n.query;t.push({query:r})},Oa=Re({});function BJ(){function e(n,i){Oa.value={event:n,data:i,timestamp:new Date}}function t(n,i){Ci(()=>{Oa.value.event===n&&i(Oa.value.data)})}return{emit:e,on:t}}const MC=e=>{const t=h=>{let m=h.replace("-","+");return m=m.replace(" ","+"),m=m.toLowerCase(),m=m.split("+").map(v
40=>v.charAt(0).toUpperCase()+v.slice(1)).join("+"),m.toLowerCase()==="kits"&&(m="KITS"),m.toLowerCase()==="ray ban"&&(m="Ray-Ban"),m.toLowerCase()==="ray+ban"&&(m="Ray-Ban"),m.toLowerCase()==="kits+x-vasuma"&&(m='KITS%20x%20Vasuma"'),m.toLowerCase()==="kits x vasuma"&&(m='KITS%20x%20Vasuma"'),m.toLowerCase()==="kits-x-vasuma"&&(m='KITS%20x%20Vasuma"'),m.toLowerCase()==="kits+x+vasuma"&&(m='KITS%20x%20Vasuma"'),`filter=brand_name_uFilter:+"${m}"`},n=h=>{let m=h.replace("-","+");return m=m.replace(" ","+"),m=m.toLowerCase(),m=m.split("+").map(v=>v.charAt(0).toUpperCase()+v.slice(1)).join("+"),`filter=collections_name_uFilter:+"${m}"`},i=h=>{let m=h.toLowerCase();return m=m.charAt(0).toUpperCase()+m.slice(1),`filter=gender_uFilter:+"${m}"+OR+gender_uFilter:+"Unisex"`},r=h=>{let m=h.toLowerCase();return m=m.charAt(0).toUpperCase()+m.slice(1),`filter=v_generic_color_uFilter:+"${m}"`},s=h=>{let m=h;return m=m.toLowerCase(),m=m.replace("-","+"),m=m.replace(" ","+"),m=m.split("+").map(v=>v.charAt(0).toUpperCase()+v.slice(1)).join("+"),`filter=material_uFilter:+"${m}"`},a=h=>{let m=h;return m=m.toLowerCase(),m=m.replace("-","+"),m=m.replace(" ","+"),m=m.split("+").map(v=>v.charAt(0).toUpperCase()+v.slice(1)).join("+"),`filter=rim_shape_uFilter:+"${m}"`},o=h=>{let m=h;return m=m.toLowerCase(),m=m.replace("-","+"),m=m.replace(" ","+"),m=m.split("+").map(v=>v.charAt(0).toUpperCase()+v.slice(1)).join("+"),`filter=features_uFilter:+"${m}"`};let l=e.split("/");l=l.filter(h=>h!=="fr_CA"),l=l.filter(h=>h!=="");let c={product_group:"",brand:"",collection:"",color:"",feature:"",material:"",shape:"",gender:""};c.product_group="product_type=Glasses",l[0]==="glasses"?c.product_group="product_type=Glasses":l[0]==="sunglasses"&&(c.product_group="product_type=Sunglasses"),l=l.filter(h=>h!=="glasses"),l.forEach(h=>{h.includes("brand-")?c.brand=t(h.replace("brand-","")):h.includes("color-")?c.color=r(h.replace("color-","")):h.includes("feature-")?c.feature=o(h.replace("feature-","")):h.includes("progressive-eligible")?c.gender=o(h):h.includes("material-")?c.material=s(h.replace("material-","")):h.includes("shape-")?c.shape=a(h.replace("shape-","")):h.includes("gender-")?c.gender=i(h.replace("gender-","")):h.includes("collection-")?c.gender=n(h.replace("collection-","")):c.collection=n(h)});const u=`&filters=%26${Object.entries(c).filter(([h,m])=>h!=="product_group"&&m!=="").map(([,h])=>h).join("%26")}`;let p=`/glasses?${c.product_group}`;return u!==""&&(p=p+u),/\d/.test(l[0])?"/glasses":`${p}&page=1`},Zr=()=>it.get("from_sunlife")==null?!1:it.get("from_sunlife")==="1",qr=()=>it.get("from_mbc")==null?!1:it.get("from_mbc")==="1",gi=ee(()=>it.get("norders_1r")>=1),FC=()=>{const e=It().pathname.split("/");return(e[e.indexOf("contact_lenses")+1]??"").replace(/\.html$/,"")},$J=async e=>{try{return await new Promise((n,i)=>{const r=new FileReader;
40r.readAsDataURL(e),r.onload=()=>{const s=e.type.split("/")[1]||"",a=r.result.split(",")[1];n({name:e.name,size:e.size,format:s,base64:a})},r.onerror=s=>i(s)})}catch(t){console.error("Error converting file:",t)}},VC=e=>{const t={role:"user",content:[]};if(!e)return t;const{name:n,size:i,format:r,base64:s}=e;return r==="pdf"?t.content.push({type:"input_file",filename:n,file_data:`data:application/${r};base64,${s}`,file_size:i,format:r}):t.content.push({type:"input_image",image_url:`data:image/${r};base64,${s}`,...n&&{image_name:n},...i&&{file_size:i}}),t},BC=()=>{const e=ie(),t=ht(se()),n=e.systemStore.getGenericSiteMetadata,i=TC(t),r=window.location.pathname.toLowerCase().includes("fr_ca"),s=n.AFFIRM_PUBLIC_KEY,a=n.AFFIRM_SDK;(function(d,u,p,h,m,v,_){var b,w=d[p]||{},C=document.createElement(v),O=document.getElementsByTagName(v)[0],T=function(E,y,P){return function(){E[y]._.push([P,arguments])}};for(w[h]=T(w,h,"set"),b=w[h],w[m]={},w[m]._=[],b._=[],w[m][_]=T(w,m,_),m=0,_="set add save post open empty reset on off trigger ready setProduct".split(" ");m<_.length;m++)b[_[m]]=T(w,h,_[m]);for(m=0,_=["get","token","url","items"];m<_.length;m++)b[_[m]]=function(){};C.async=!0,C.src=u[v],O.parentNode.insertBefore(C,O),delete u[v],b(u),d[p]=w})(window,{public_api_key:s,script:a,locale:r&&i?"fr_CA":i?"en_CA":"en_US",country_code:`${i?"CA":"USA"}`},"affirm","checkout","ui","script","ready")},$C=e=>e.map(t=>(`${t.color}${t.image_url}${t.configuration_id}${t.color}${t.price}${t.promo_price||""}${t.tshirt_size}${t.bridge}${t.temple}${t.screw_to_screw}${t.upc}${t.eye}${t.b_size}`,{products_sku:t.products_sku,configuration_id:t.configuration_id,is_parent:"1",product_group:t.product_group,accepts_lenses:t.accepts_lenses,style_code:"",brand_name:t.brand_name,collections_name:t.collections_name||[],name:t.name,discontinued:"0",complete_price:t.price,inner_frame_width:t.inner_frame_width,image_tag:t.image_url,origin_country:"",gender:Array.isArray(t.gender)?t.gender:[t.gender],material:t.material,rim:"",rim_shape:t.rim_shape,soldout:String(t.soldout??"0"),last_modified:"",angle_image:"",vto_alt_full:t.vto_alt_full||t.upc||"",inventory:"",promo_price:t.promo_price||"",price:t.price,is_3d_available:"0",uniqueId:t.products_sku,category:t.product_group==="Sunglasses"?["Sunglasses"]:["Eyeglasses"],imageUrl:[t.image_url],features:[],ColorImageMapping:[],doctype:"POPULAR_PRODUCTS",autosuggest:t.name,autosuggest_unstemmed:t.name,variantCount:1,variantTotal:1,parent_unbxd:!0,_root_:t.products_sku,score:1,relevantDocument:"parent"})),Td=e=>e&&e.replace(/ü/g,"ü").replace(/â„¢/g,"™").replace(/™/g,"™"),$n=(e,t="")=>{const n=o=>o==null?void 0:o.toString().normalize("NFKD").replace(/[\u0300-\u036f]/g,"").toLowerCase().trim().replace(/\blift-off\S*\b/gi,"lift-off").replace(/\bkar\S*n\b/gi,l=>l!=="karlsson"?"karun":l).replace(/\/|\\|\s+|-+/g,"-").replace(/[^a-z0-9\s-]/g,"").replace(/-+/g,"-").replace(/^-|-$/g,"").replace(/\bpumalan\b/gi,"pumalin").replace(/aa14/gi,"u"),i=o=>{if(o!=="kits-x-vasuma"&&o!=="kits-x-vasuma-karlsson")return(o||"").split("-").filter(l=>l!=="kits").join("-")},r=i(n(e)),s=i(n(t));return s?r?new RegExp(`(^|-)${s}(-|$)`).test(r)?r:`${s}-${r}`:s:r},UJ=(e,t="",n="")=>{const r=ie().systemCheckoutStore.getCartGenericData.BASE_URL;let s="";window.location.href.indexOf("fr_CA")>-1&&(s="fr_CA");const a=/\b(?!https?:)\/{2,}/g;let o=e;return t&&n!=="Sunglasses"&&(o=o.replace(/^\/glasses\/(?![^/]+\/)/,`/glasses/${t}/`)),(r+s+o).replace(a,"/")},UC=async(e,t)=>$fetch(`${Bt()}${t}/optician-ai/get-optician-metadata`,{method:"POST",body:{originUrl:e}}).then(n=>n).catch(n=>{console.log(n)}),Pd=async(e,t,n,i)=>$fetch(`${Bt()}${i}/resellerratings/get-reviews`,{method:"POST",body:{sku:e,perPage:t,page:n}}).then(r=>r).catch(r=>{console.log(r)}),Xp=async e=>$fetch(`https://${se()}/api/products/contacts/upc?upc=${e}`,{method:"GET",credentials:"include"}).then(t=>t).catch(t=>{console.log(t)}),HC=async e=>$fetch(`https://${se()}/api/optician/thread/${e}`,{method:"POST",body:{},credentials:"include"}).then(t=>t).catch(t=>{console.log(t)}),zC=async e=>$fetch(`https://${se()}/api/optician/thread`,{method:"POST",credentials:"include",body:e}).then(t=>t).catch(t=>{console.log(t)}),KC=async()=>$fetch(`https://${se()}/api/optician/threads`,{method:"GET",credentials:"include"}).then(e=>e).catch(e=>{console.log(e)}),GC=async e=>$fetch(`https://${se()}/api/optician/conversation/?thread_id=${e}`,{method:"GET",credentials:"include"}).then(t=>t).catch(t=>{console.log(t)}),jC=async e=>$fetch(`https://${se()}/api/optician/conversation`,{method:"POST",body:e,credentials:"include"}).then(t=>t).catch(t=>{console.log(t)}),Od=async(e,t)=>
40{try{return await $fetch(`https://product-api.fittingbox.com/glasses-metadata/availability?apiKey=${e}&uidList=${t.join(",")}`,{method:"GET"})}catch(n){throw console.error("Error fetching availability:",n),n}},HJ=async(e,t,n="")=>{if(!e||e.length===0)return n;try{return(await $fetch(`${Bt()}${t}/optician-ai/context/summary`,{method:"POST",body:{messages:e,summaryContext:n}})).summaryContext??n}catch(i){return console.warn("[optician] summary context failed:",i==null?void 0:i.message),n}},zJ=async(e,t,n=[])=>{if(!e||e.length===0)return n;try{return(await $fetch(`${Bt()}${t}/optician-ai/context/user-preferences`,{method:"POST",body:{messages:e,userPreferencesContext:n}})).userPreferencesContext??n}catch(i){return console.warn("[optician] user preferences context failed:",i==null?void 0:i.message),n}},YC=async(e,t,n)=>{if(e)try{await $fetch(`https://${se()}/api/optician/context`,{method:"POST",credentials:"include",body:{thread_id:e,summaryContext:t,userPreferencesContext:n}})}catch(i){console.warn("[optician] save thread context failed:",i==null?void 0:i.message)}},WC=async e=>$fetch(`https://${se()}/api/products/add`,{method:"POST",credentials:"include",body:e}).then(t=>t).catch(t=>{console.log(t)}),Ad=async(e,t,n)=>{let i="https://search.unbxd.io/fa194145848a3180eb26f41f4a855e05/ss-unbxd-gcp-kits-com-prod16621689373955";return t==="kits.ca"?i="https://search.unbxd.io/7615ffb6e3e55bd1e0878257222a6eba/ss-unbxd-gcp-kits-ca-prod16621689373059":t==="kits.com"?i="https://search.unbxd.io/fa194145848a3180eb26f41f4a855e05/ss-unbxd-gcp-kits-com-prod16621689373955":t==="opticontacts.com"?i="https://search.unbxd.io/e011aa641d247fc0da0dfe7e243c931a/ss-unbxd-gcp-opticontacts-prod16621689373264":t==="contactsexpress.ca"?i="https://search.unbxd.io/e268fcf0345cfee4ff9e9d09c1b78a8e/ss-unbxd-gcp-contactsexpress-ca-prod16621689373366":t==="postalcontacts.com"&&(i="https://search.unbxd.io/f9ee220008a18dcf64b29195adeae481/ss-unbxd-gcp-postalcontacts-prod16621689373314"),$fetch(`${i}/autosuggest?popularProducts.filter=v_soldout_uFilter:%20%220%22&popularProducts.filter=v_enabled_uFilter:%20%221%22&q=${e}&version=V2&popularProducts.count=8&variants.relevant=true&keywordSuggestions.count=4&topQueries.count=4`,{method:"GET",signal:n}).then(r=>r).catch(r=>{console.error(r)})},QC=async e=>{let t="e011aa641d247fc0da0dfe7e243c931a/ss-unbxd-gcp-opticontacts-prod16621689373264";return e==="opticontacts.com"?t="e011aa641d247fc0da0dfe7e243c931a/ss-unbxd-gcp-opticontacts-prod16621689373264":e==="contactsexpress.ca"?t="e268fcf0345cfee4ff9e9d09c1b78a8e/ss-unbxd-gcp-contactsexpress-ca-prod16621689373366":e==="postalcontacts.com"&&(t="f9ee220008a18dcf64b29195adeae481/ss-unbxd-gcp-postalcontacts-prod16621689373314"),$fetch(`https://search.unbxd.io/${t}/category?p=product_group:%22Contact%20Lenses%22&pagetype=boolean&rows=6&fields=products_sku,product_group,price,brand_name,name,relevantDocument,collections_name,imageUrl,sort_order,price_1r&facet.multiselect:true&version=V2`,{method:"GET"}).then(n=>n).catch(n=>{console.error(n)})},ZC=async()=>$fetch(`https://${se()}/api/products/trending`,{method:"GET"}).then(e=>e).catch(e=>{console.error(e)}),qC=async e=>$fetch(`https://${se()}/api/customer/type`,{method:"POST",credentials:"include",body:e}).then(t=>t).catch(t=>{console.error(t)}),JC=async()=>$fetch(`https://${se()}/api/generic/metadata`,{method:"GET",credentials:"include"}).then(e=>e).catch(e=>{console.error(e)}),XC=async()=>$fetch(`https://${se()}/api/products/glasses/brands`,{method:"GET",credentials:"include"}).then(e=>e).catch(e=>{console.error(e)}),eI=async e=>$fetch(`https://${se()}/api/side-cart/delete?index=${e}`,{method:"GET",credentials:"include"}).then(t=>t).catch(t=>{console.error(t)}),tI=async e=>$fetch(`https://${se()}/api/side-cart/delete_coupon`,{method:"POST",credentials:"include",headers:{"Content-Type":"application/json"},body:{code:e,type:"coupon"}}).then(t=>t).catch(t=>{console.error(t)}),nI=async e=>$fetch(`https://${se()}/api/side-cart/add_coupon?code=${e}`,{method:"GET",credentials:"include"}).then(t=>t).catch(t=>{console.error(t)}),sI=async e=>$fetch(`https://${se()}/api/customer/subscribe`,{method:"POST",body:e}).then(t=>t).catch(t=>{console.error(t)}),iI=async e=>$fetch(`https://${se()}/api/iterable/favorites`,{method:"POST",credentials:"include",body:e}).then(t=>t).catch(t=>{console.error(t)}),rI=async e=>$fetch(`https://${se()}/api/iterable/vto`,{method:"POST",credentials:"include",body:e}).then(t=>t).catch(t=>{console.error(t)}),aI=async()=>$fetch(`https://${se()}/api/offers/site-stripe`,{method:"GET"}).then(e=>e).catch(e=>{console.error(e)}),Ao=["CLKITSDA90","CL1DAVO90JJ","CLDT190CACV","CLAOAJJ","CL1DAVM90JJ","CLAVO12JJ","CLBITCV","CLP190AL"],Gi=async e=>{const t=jh("uid").value||"",n="&rows=12",i="&pagetype=boolean",r="&facet.multiselect=true",s="&version=V2",a='&filter=v_enabled_uFilter: "1"',o='&filter=v_soldout_uFilter: "0"',l="&variants.relevant=true",c=`&uid=${t}`,d="&fields=v_enabled,features,v_soldout,imageUrl,category,rim_shape,material,ColorImageMapping,product_group,price,promo_price,v_generic_color,v_a_size,v_b_size,bridge,temple,screw_to_screw,configuration_id,v_configuration_id,v_upc,products_sku,brand_name,image_tag,name,angle_image,v_color,tshirt_size,vto_alt_full,collections_name,discontinued,price_1r,accepts_lenses";let u="",p="";return e==="Eyeglasses"?(u=`p=${encodeURIComponent('product_group:"Glasses"')}`,p='&filter=category:"Eyeglasses"&filter=collections_name:Popular'):e==="Sunglasses"?(u=`p=${encodeURIComponent('product_group:"Glasses"')}`,p='&filter=category:"Sunglasses"&filter=collections_name:Popular'):e==="Designer"?(u=`p=${encodeURIComponent('product_group:"Glasses"')}`,p='&filter=collections_name:"Designer Bestsellers"'):e==="Contacts"&&(u=`p=${encodeURIComponent('product_group:"Contact Lenses"')}`,p=`&filter=products_sku:(${Ao.map(m=>`"${m}"`).join(" OR ")})`),$fetch(`${IC()}category?${u}${i}${p}${n}${d}${r}${s}${a}${o}${l}${c}`,{method:"GET"}).then(h=>h).catch(h=>{console.log(h)})},oI=async(e,t)=>$fetch(`${Bt()}${Be().public.serviceApi}/optician-ai/search`,{method:"POST",body:e,signal:t}),lI=async(e,t)=>$fetch(`${Bt()}${Be().public.serviceApi}/optician-ai/get-search-suggestions`,{method:"POST",body:e,signal:t}),cI=async e=>{try{const{data:t}=await xr(`https://${se()}/api/products/contacts?sku=${e}`,"$buACf4y4WF");if(t&&t.value)return t.value;console.error("Error fetching product contacts:",error.message)}catch(t){return console.error("Error fetching product contacts:",t.message),null}},dI=async()=>$fetch(`https://${se()}/api/products/listing_discounts`),uI=async e=>$fetch(`https://${se()}/api/products/add`,{method:"POST",credentials:"include",body:e}).then(t=>t).catch(t=>{console.log(t)}),hI=async e=>$fetch(`https://${se()}/api/products/validation`,{method:"POST",credentials:"include",body:e}).then(t=>t).catch(t=>{console.log(t)}),pI=async e=>$fetch(`https://${se()}/api/products/upload`,{method:"POST",credentials:"include",body:e}).then(t=>t).catch(t=>{console.log(t)}),fI=async()=>$fetch(`https://${se()}/api/products/uploads`,{method:"GET",credentials:"include"}).then(e=>e).catch(e=>{console.log(e)}),mI=async e=>$fetch(`https://${se()}/api/products/upload/delete`,{method:"POST",credentials:"include",body:e}).then(t=>t).catch(t=>{console.log(t)}),gI=async e=>$fetch(`https://${se()}/api/prescription-contacts/ai`,{method:"POST",credentials:"include",body:e}).then(t=>t).catch(t=>{console.log(t)}),yI=async()=>$fetch(`https://${se()}/api/products/contacts/dailies/similars`,{method:"GET",credentials:"include"}).then(e=>e).catch(e=>{console.log(e)}),bI=async()=>$fetch(`https://${se()}/api/cart/autoship/status`,{method:"GET",credentials:"include"}).then(e=>e).catch(e=>{console.log(e)}),vI=async e=>$fetch(`https://${se()}/api/products/autoship/frequency`,{method:"POST",credentials:"include",body:{items:e}}).then(t=>t).catch(t=>{console.log(t)});let as=null;const _I=async()=>
40{if("wakeLock"in navigator){try{as=await navigator.wakeLock.request("screen"),console.log("success",as)}catch(e){console.log("Wake lock not supported",e.message)}return as}},wI=()=>{typeof as<"u"&&as!=null&&as.release().then(()=>{as=null})},EI=async({onDataMessage:e,onRemoteAudioTrack:t})=>{const n=new RTCPeerConnection,i=document.createElement("audio");i.autoplay=!0,n.ontrack=o=>{i.srcObject=o.streams[0];const l=o.streams[0].getAudioTracks()[0];t&&t(l)};const s=(await navigator.mediaDevices.getUserMedia({audio:{echoCancellation:!0,noiseSuppression:!0,autoGainControl:!0}})).getTracks()[0];n.addTrack(s);const a=n.createDataChannel("oai-events");return e&&a.addEventListener("message",o=>{const l=JSON.parse(o.data);e(l,a)}),{peerConnection:n,dataChannel:a,audioEl:i,localTrack:s}};class SI{constructor({onDataMessage:t,opticianMetadata:n,cartCount:i=0,tokenEndpoint:r=null,tokenBody:s=null}){en(this,"config",Be());en(this,"peerConnection",null);en(this,"dataChannel",null);en(this,"audioEl",null);en(this,"localTrack",null);en(this,"EPHEMERAL_KEY",null);this.onDataMessage=t,this.opticianMetadata=n,this.cartCount=i,this.tokenEndpoint=r,this.tokenBody=s}async start(){await _I();const t=this.tokenEndpoint??`${Bt()}${this.config.public.serviceApi}/optician-ai/realtime-token`,n=this.tokenBody??{opticianMetadata:this.opticianMetadata,cartCount:this.cartCount},i=await $fetch(t,{method:"POST",body:n});this.EPHEMERAL_KEY=i.value||"";const r=await EI({onDataMessage:(c,d)=>this.onDataMessage(c,d,this),onRemoteAudioTrack:c=>{this.audioTrack=c}});this.peerConnection=r.peerConnection,this.dataChannel=r.dataChannel,this.audioEl=r.audioEl,this.localTrack=r.localTrack;const s=await this.peerConnection.createOffer();await this.peerConnection.setLocalDescription(s);const a=new FormData;a.append("sdp",s.sdp),a.append("session",JSON.stringify({type:"realtime",model:"gpt-realtime-mini"}));const l={type:"answer",sdp:await(await fetch("https://api.openai.com/v1/realtime/calls",{method:"POST",body:a,headers:{Authorization:`Bearer ${this.EPHEMERAL_KEY}`}})).text()};await this.peerConnection.setRemoteDescription(l)}createConversationItem(t){const n={type:"conversation.item.create",item:{type:"message",role:"system",content:[{type:"input_text",text:`Say this out loud: ${t}`}]}};this.dataChannel.readyState==="open"&&(this.dataChannel.send(JSON.stringify(n)),this.dataChannel.send(JSON.stringify({type:"response.create"})))}createContextItem(t){const n={event_id:"event_1",type:"conversation.item.create",previous_item_id:null,item:{id:"msg_1",type:"message",role:"system",content:[{type:"input_text",text:t}]}};this.dataChannel.readyState==="oppen"&&dataChannel.send(JSON.stringify(n))}stop(){wI();try{this.localTrack&&(this.localTrack.stop(),this.localTrack=null),this.dataChannel&&(this.dataChannel.readyState==="open"&&this.dataChannel.close(),this.dataChannel=null),this.peerConnection&&(this.peerConnection.getSenders().forEach(t=>{if(t.track)try{t.track.stop()}catch(n){console.warn("Error stopping sender track:",n)}}),this.peerConnection.close(),this.peerConnection=null),this.audioEl&&this.audioEl.parentNode&&(this.audioEl.parentNode.removeChild(this.audioEl),this.audioEl=null)}catch(t){console.error("Error closing connection:",t)}}async pause(){this.localTrack&&(this.localTrack.enabled=!1,console.log("Microphone muted."))}async resume(){this.localTrack&&(this.localTrack.enabled=!0,console.log("Microphone unmuted."))}async pauseOptician(){this.audioTrack&&(this.audioTrack.enabled=!1,console.log("Optician muted."))}async resumeOptician(){this.audioTrack&&(this.audioTrack.enabled=!0,console.log("Optician unmuted."))}}const tt=(e,t,n)=>{const i={type:"conversation.item.create",item:{type:"function_call_output",call_id:t.call_id,output:JSON.stringify({text:n})}};e.send(JSON.stringify(i)),e.send(JSON.stringify({type:"response.create"}))};let zt=[];const CI=(e,t,n,i,r,s={faceDetected:!1,isVtoAnalysisFeedback:!0})=>{const a=ie();if(!window.FitMix){console.error("FitMix not available");return}const o=t.vto_alt_full,l=`fitmix-container-${n}`,c=document.getElementById(l);if(!o){console.warn("No product available for VTO");return}if(!c){console.warn(`Missing container: #${l}`);return}const d=()=>
40{zt[3]!==void 0&&o!==void 0&&zt[3].setFrame(o)},u=()=>{a.opticianStore.setIsFitmixReady(!0);let p=localStorage.getItem("vtoGenderOption"),h=localStorage.getItem("pd"),m=localStorage.getItem("vtoMode");localStorage.setItem("vtoMode",""),d(),m!=null&&m!=""?zt[3].startVto(m):zt[3].startVto("live"),p!=null&&p!=""&&zt[3].setUserInfo({gender:p}),h!=null&&h!=""&&zt[3].setPupillaryDistance(Number(h))};if(!zt[3]||i){const p=window.FitMix.createWidget(l,{apiKey:e,lang:"en",uiConfiguration:{livePhotoButton:!1,photoLiveButton:!1,liveRelaunchDetectionButton:!1},...r,css:`
41          [data-style="vto-adv-live-action-left"] {  
42            display: none !important;  
43          } 
44
45          [data-style="vto-adv-right-action"] { 
46            display: none !important; 
47          }
48
49          [data-style="vto-adv-error-top"] { 
50            top: 50px !important; 
51          }
52
53          [_ngcontent-ng-c2353250874] { 
54            margin-top: 50px; 
55          }
56
57          [data-style="vto-adv-live"] {
58            margin-top: 1000px;
59          }
60
61          [class="rounded-[1.3vh] transition-all duration-700 ease-in-out shadow-[0_0_0_3000px_rgba(0,0,0,0.6)]"] {
62            margin-bottom: 200px !important; 
63            max-height: 60% !important;
64          }
65
66          [class="rounded-[1.3vh] transition-all duration-700 ease-in-out"] {
67            margin-bottom: 200px !important; 
68            max-height: 60% !important;
69          }
70
71          /* Center the error block vertically */
72          .absolute.inset-0.flex.flex-col {
73            justify-content: center !important;
74          }
75        `},u);zt[3]=p}else d(),a.opticianStore.setBubbleMessage(null),PI(s.faceDetected,s.isVtoAnalysisFeedback)},KJ=()=>{zt[3].setMode("viewer")},GJ=()=>{zt[3].setMode("live")},Aa=()=>{zt=[]},jJ=()=>{zt[3].stopVto(),zt=[]},ko=()=>{zt[3].getSnapshot()},YJ=()=>{let e=document.createElement("script");e.setAttribute("defer",""),e.setAttribute("id","veero-location"),e.setAttribute("src","https://app.veero.ai/js/veero.main.js?b=NKzVP6wZO"),document.head.appendChild(e)},WJ=async(e,t,n,i)=>{await EyeSize.launch({eyeSizeCallback:e,eyeSizeExitCallback:t,vendorID:"NKzVP6wZO",initialMeasurementIdx:!1,customLoadingImageURL:n,ctaIndex:i})},II=(e,t,n,i)=>new Promise((r,s)=>{const a=async o=>{try{await e(o,n,i),r()}catch(l){s(l)}};EyeSize.launch(a,t,"NKzVP6wZO",!1)}),kd=e=>{const t=Math.round((e.face_width*1e3).toFixed(2));return{veeroEyeWidth:Math.round((e.eye_width*1e3).toFixed(2)),veeroPD:Math.round(e.mono_pd*1e3*2)/2,veeroFaceWidth:t,veeroBridge:Math.round((e.bridge_width*1e3).toFixed(2)),veeroTemple:Math.round((e.temple_length*1e3).toFixed(2)),veeroResult:e,minFrameWidth:Math.round(t*.975),maxFrameWidth:Math.round(t*1.05)}},TI=()=>new Promise((e,t)=>{const n=i=>{const{type:r,payload:s}=i.data||{};r==="measurePdResults"&&(e(s),window.removeEventListener("message",n)),r==="measurePdError"&&(window.removeEventListener("message",n),t(s))};window.addEventListener("message",n),window.parent.postMessage({type:"startMeasurePd"},"*")}),QJ=e=>{window.self!==window.top?window.parent.postMessage({type:"contextNavigation",url:e},"*"):window.location.href=Ae()+e},bl=(e,t)=>{let n;return function(...i){clearTimeout(n),n=setTimeout(()=>e.apply(this,i),t)}},PI=bl((e,t)=>{e&&t&&ko()},1500),ZJ=async e=>{const t=ie();try{await navigator.clipboard.writeText(e),t.systemStore.addToastMessage("SUCCESS",`${e} Copied to clipboard`)}catch(n){t.systemStore.addToastMessage("ERROR",`${e}  Failed to copy`),console.error("Failed to copy: ",n)}},Rd=e=>{for(;e!=null&&e.firstChild;)e.removeChild(e.firstChild)},OI=async(e,t)=>new Promise((n,i)=>{const r=indexedDB.open(e);r.onerror=()=>{i("Failed to open IndexedDB")},r.onsuccess=()=>{const l=r.result.transaction([t],"readwrite").objectStore(t).clear();l.onsuccess=()=>{n()},l.onerror=()=>{i("Failed to clear object store")}}}),xn=(e,t)=>{const n=t?{event:e,parameters:t}:{event:e},i=window.location.hostname;(i.includes("localhost")||i.includes(".camp."))&&console.log(`[optician event] ${e}`,n);try{dataLayer.push(n)}catch{console.log(`Datalayer not found ${e}`)}},ka=e=>({item_brand:e==null?void 0:e.brand_name,item_category:e==null?void 0:e.product_group,item_id:e==null?void 0:e.products_sku,item_variant:e==null?void 0:e.configuration_id,item_name:e!=null&&e.name?AI(e.name):e==null?void 0:e.name,price:Number(e==null?void 0:e.price)}),AI=e=>e.replace(/™/g,"™").replace(/â™/g,"™").replace(/™/g,"™").replace(/&trade;/gi,"™"),qJ=e=>{let t;return e>1024*1024?t=`${(e/1048576).toFixed(1)} MB`:t=`${Math.round(e/1024)} KB`,t},JJ=e=>{const t=sessionStorage.getItem("optician-user-id");if(t)e=t;else{const n=`user-${Math.random().toString(36).substring(2,10)}`;sessionStorage.setItem("optician-user-id",n),e=n}return e};async function XJ(e){await kt(),e&&e.scrollTo({top:e.scrollHeight,behavior:"smooth"})}const kI=async()=>{const e=ie();return new Promise(t=>{e.opticianStore.setSelfieWatcherResolver(t)})},RI=(e,t="",n=512)=>{const i=atob(e),r=[];for(let s=0;s<i.length;s+=n){const a=i.slice(s,s+n),o=new Array(a.length);for(let c=0;c<a.length;
75c++)o[c]=a.charCodeAt(c);const l=new Uint8Array(o);r.push(l)}return new Blob(r,{type:t})},eX=e=>new Promise((t,n)=>{const i=new FileReader;i.onloadend=()=>t(i.result),i.onerror=n,i.readAsDataURL(e)}),tX=e=>{const t=e||"",n=/(https?:\/\/[^\s]+)/g;return t.split(n).map(i=>n.test(i)?{type:"link",value:i}:{type:"text",value:i})},nX=async e=>{let t,n=Number.MAX_SAFE_INTEGER,i=!1;for(const r of e)try{const s=await LI(r),a=NI(s);if(!a)continue;const o=DI(s),l=(o==null?void 0:o.min)===1;(!t||l&&!i||l===i&&a.min<n&&a.min!==0)&&(t=r.deviceId,n=a.min,i=l)}catch{}return t},LI=async e=>{const n=(await navigator.mediaDevices.getUserMedia({video:{deviceId:{exact:e.deviceId}}})).getTracks(),i=n.map(r=>r.getCapabilities());return n.forEach(r=>r.stop()),i},NI=e=>e.map(t=>"focusDistance"in t?t.focusDistance:void 0).find(t=>t!==void 0),DI=e=>e.map(t=>"zoom"in t?t.zoom:void 0).find(t=>t!==void 0),xI="kits.ca",MI=["/plugins/barcode-scanner","/plugins/us-insurance-widget","/plugins/vto-widget","/optician","/optician-vto"],FI=e=>{const t=(e||"/").replace(/\/+$/,"")||"/";return MI.some(n=>t===n||t.startsWith(`${n}/`))},Ld=["https://www.facebook.com/kitseyecare/","https://www.instagram.com/kitseyecare/","https://ca.pinterest.com/kitseyecare/","https://x.com/kitseyecare","https://www.tiktok.com/@kitseyecare"],Nd={"kits.com":{siteName:"KITS",legalName:"KITS Eyecare Ltd.",origin:"https://www.kits.com",currency:"USD",locale:"en-US",logo:"kits.png",twitterHandle:"@kitseyecare",sameAs:Ld,alternates:[{hreflang:"en-US",prefix:"",xDefault:!0}],copy:{aboutus:{title:"About Us | Kits.com",description:"Learn more about Kits.com, your trusted source for contact lenses and eyewear since 2018. Authorized retailer and North American-owned. Shop now!"},contactus:{title:"Contact Us | Kits.com",description:"Need assistance? Contact the Kits.com support team for help with orders, returns, and more."},pdTool:{title:"Kits.com -- PD Tool",description:"PD Tool"},eyeCare:{title:"Kits.com -- Learn how to take the best care of your contacts and your eyes.",description:"Kits Eyewear. North America's Top Eyewear Store. High-quality eyewear at affordable prices. All KITS glasses and sunglasses are now available starting at $38."},stores:{title:"KITS Stores | Find a KITS Eyewear Store Near You",description:"Find a KITS store for eye exams, glasses, and expert service. Visit us in Vancouver or Toronto, check store hours, locations, and book your appointment today."},autoship:{title:"Subscribe & Save | Contact Lens Autoship | Kits.com",description:"Sign up for Kits.com's autoship program and enjoy convenient, timely deliveries. Save more on every order."},kitsPlus:{title:"Kits.com | Kits+ Membership",description:"Kits Eyewear. North America's Top Eyewear Store. High-quality eyewear at affordable prices. All KITS glasses and sunglasses are now available starting at $38."},shipping:{title:"Kits.com -- Shipping Info",description:"Kits Eyewear. North America's Top Eyewear Store. High-quality eyewear at affordable prices. All KITS glasses and sunglasses are now available starting at $38."},default:{title:"KITS Eyewear | Glasses, Sunglasses & Contact Lenses",description:"Kits Eyewear.  North America's Top Eyewear Store.  High-quality eyewear at affordable prices.  All KITS glasses and sunglasses are now available starting at $38."},contactsPdp:{description:"Contact Lenses. Lowest Price Guarantee We take Vision Insurance, FSA, HSA Free US Shipping on orders over $99 Hassle Free Returns Authorized Retailer Free Torn Lens Replacement North American Owned & Operated. Shop now!"},blackFridaySummerSale:{title:"Black Friday Summer Sale, Glasses, Sunglasses, Designer & Contacts Deals | KITS",description:"Shop KITS Black Friday Summer Sale, North America's mid-year sale on glasses, sunglasses, designer frames and contact lenses. Save on Ray-Ban, Oakley and more at KITS.com."}}},"kits.ca":{siteName:"KITS",legalName:"KITS Eyecare Ltd.",origin:"https://www.kits.ca",currency:"CAD",locale:"en-CA",logo:"kits.png",twitterHandle:"@kitseyecare",sameAs:Ld,alternates:[{hreflang:"en-CA",prefix:"",xDefault:!0},{hreflang:"fr-CA",prefix:"/fr_CA"}
75],copy:{aboutus:{title:"About Us | Kits.ca",description:"KITS.CA: Proudly Canadian and dedicated to your vision. Discover exclusive eyewear collections, locally crafted lenses, designer frames, and leading contact lens brands. Affordable, reliable, and customer-focused"},contactus:{title:"Contact Us | Kits.ca",description:"Need assistance? Contact the KITS.ca team for help with orders, returns, or general inquiries. We're here to make your shopping experience seamless."},pdTool:{title:"Kits.ca -- PD Tool",description:"PD Tool"},eyeCare:{title:"Kits.ca -- Learn how to take the best care of your contacts and your eyes.",description:"Kits Eyewear. Canada's #1 Eyewear Store. High-quality eyewear at affordable prices. All KITS glasses and sunglasses are now available starting at $28."},stores:{title:"KITS Stores | Find a KITS Eyewear Store Near You",description:"Find a KITS store for eye exams, glasses, and expert service. Visit us in Vancouver or Toronto, check store hours, locations, and book your appointment today."},autoship:{title:"Subscribe & Save | KITS.ca",description:"Sign up for KITS.ca's autoship program and never run out of contact lenses again! Enjoy free shipping, discounts, and flexible delivery schedules"},kitsPlus:{title:"Kits.ca | Kits+ Membership",description:"Kits Eyewear. Canada's #1 Eyewear Store. High-quality eyewear at affordable prices. All KITS glasses and sunglasses are now available starting at $28."},shipping:{title:"Kits.ca -- Shipping Info",description:"Kits Eyewear. Canada's #1 Eyewear Store. High-quality eyewear at affordable prices. All KITS glasses and sunglasses are now available starting at $28."},default:{title:"KITS Eyewear | Glasses, Sunglasses & Contact Lenses",description:"KITS Eyewear. High-quality glasses, sunglasses and contact lenses at affordable prices, shipped fast from Vancouver, B.C."},contactsPdp:{description:"Contact Lenses with free shipping across Canada on orders $179+, direct billing, and the best pricing guaranteed. Ships fast from Vancouver, B.C. Shop with exclusive offers today!"},blackFridaySummerSale:{title:"Black Friday Summer Sale, Glasses, Sunglasses, Designer & Contacts Deals | KITS",description:"Shop KITS Black Friday Summer Sale, Canada's mid-year sale on glasses, sunglasses, designer frames and contact lenses. Save on Ray-Ban, Oakley and more at KITS.ca."}}},"opticontacts.com":{siteName:"Opticontacts",legalName:"Opticontacts",origin:"https://www.opticontacts.com",currency:"USD",locale:"en-US",logo:"opticontacts.png",twitterHandle:null,sameAs:[],alternates:[{hreflang:"en-US",prefix:"",xDefault:!0}],copy:{aboutus:{title:"About Us | OptiContacts.com",description:"Learn more about OptiContacts.com, your trusted source for contact lenses and eyewear since 2004."},contactus:{title:"Contact Us | OptiContacts.com",description:"Need assistance? Contact the OptiContacts.com support team for help with orders, returns, and more."},pdTool:{title:"OptiContacts.com -- PD Tool",description:"PD Tool"},eyeCare:{title:"OptiContacts.com -- Learn how to take the best care of your contacts and your eyes.",description:"Save on your contact lenses. Free shipping available within USA. Up to 70% off on contact lenses by acuvue, ciba, coopervision, bausch and more."},autoship:{title:"Subscribe & Save | Contact Lens Autoship | OptiContacts.com",description:"Sign up for OptiContacts.com's autoship program and enjoy convenient, timely deliveries. Save more on every order."},kitsPlus:{title:"OptiContacts.com | Kits+ Membership",description:"Save on your contact lenses. Free shipping available within USA. Up to 70% off on contact lenses by acuvue, ciba, coopervision, bausch and more."},shipping:{title:"OptiContacts.com -- Shipping Info",description:"Save on your contact lenses. Free shipping available within USA. Up to 70% off on contact lenses by acuvue, ciba, coopervision, bausch and more."},default:{title:"Opticontacts | Contact Lenses at the Lowest Prices",description:"Contact Lenses with best pricing guaranteed. Enjoy Lowest Prices Guarantee, We take vision insurance, FSA, HSA, Free US shipping on orders over $99, Hassle-free returns. Shop now!"},contactsPdp:{description:"Contact Lenses with best pricing guaranteed. Enjoy Lowest Prices Guarantee, We take vision insurance, FSA, HSA, Free US shipping on orders over $99, Hassle-free returns. Shop now!"}}},"postalcontacts.com":{siteName:"Postalcontacts",legalName:"Postalcontacts",origin:"https://www.postalcontacts.com",currency:"USD",locale:"en-US",logo:"postalcontacts.png",twitterHandle:null,sameAs:[],alternates:[{hreflang:"en-US",prefix:"",xDefault:!0}],copy:{aboutus:{title:"PostalContacts.com",description:"Save on your contact lenses. Free shipping available within USA. Up to 70% off on contact lenses by acuvue, ciba, coopervision, bausch and more."},contactus:{title:"Contact Us | PostalContacts.com",description:"Need assistance? Contact the PostalContacts.com support team for help with orders, returns, and more."},pdTool:{title:"PostalContacts.com -- PD Tool",description:"PD Tool"},eyeCare:{title:"PostalContacts.com -- Learn how to take the best care of your contacts and your eyes.",description:"Save on your contact lenses. Free shipping available within USA. Up to 70% off on contact lenses by acuvue, ciba, coopervision, bausch and more."},autoship:{title:"Subscribe & Save | KITS.ca",description:"Sign up for KITS.ca's autoship program and never run out of contact lenses again! Enjoy free shipping, discounts, and flexible delivery schedules"},kitsPlus:{title:"Kits.ca | Kits+ Membership",description:"Kits Eyewear. Canada's #1 Eyewear Store. High-quality eyewear at affordable prices. All KITS glasses and sunglasses are now available starting at $28."},shipping:{title:"Kits.ca -- Shipping Info",description:"Kits Eyewear. Canada's #1 Eyewear Store. High-quality eyewear at affordable prices. All KITS glasses and sunglasses are now available starting at $28."},default:{title:"Postalcontacts | Contact Lenses Delivered",description:"Contact Lenses with best pricing guaranteed. Enjoy Lowest Prices Guarantee, We take vision insurance, FSA, HSA, Free US shipping on orders over $99, Hassle-free returns. Shop now!"}}},"contactsexpress.ca":{siteName:"Contactsexpress",legalName:"Contactsexpress",origin:"https://www.contactsexpress.ca",currency:"CAD",locale:"en-CA",logo:"contactsexpress.png",twitterHandle:null,sameAs:[],alternates:[{hreflang:"en-CA",prefix:"",xDefault:!0}
75],copy:{aboutus:{title:"About Us | ContactsExpress.ca",description:"Learn more about ContactsExpress.ca, your trusted Canadian source for contact lenses, eyeglasses, and sunglasses. Discover our story, our commitment to customer satisfaction, and why millions choose us for their eye care needs."},contactus:{title:"Contact Us | ContactsExpress.ca",description:"Need assistance? Contact the ContactsExpress.ca team for help with orders, returns, or general inquiries. We're here to make your shopping experience seamless."},pdTool:{title:"ContactsExpress.ca -- PD Tool",description:"PD Tool"},eyeCare:{title:"ContactsExpress.ca -- Learn how to take the best care of your contacts and your eyes.",description:"Save on your contact lenses. Free shipping available within Canada. Up to 70% off on contact lenses by acuvue, ciba, coopervision, bausch and more."},autoship:{title:"Subscribe & Save | Contact Lens Autoship | ContactsExpress.ca",description:"Sign up for ContactsExpress.ca's autoship program and never run out of contact lenses again! Enjoy free shipping, discounts, and flexible delivery schedules"},kitsPlus:{title:"ContactsExpress.ca | Kits+ Membership",description:"Save on your contact lenses. Free shipping available within Canada. Up to 70% off on contact lenses by acuvue, ciba, coopervision, bausch and more."},shipping:{title:"ContactsExpress.ca -- Shipping Info",description:"Save on your contact lenses. Free shipping available within Canada. Up to 70% off on contact lenses by acuvue, ciba, coopervision, bausch and more."},default:{title:"Contactsexpress | Contact Lenses Shipped Across Canada",description:"Contact Lenses with best pricing guaranteed. Enjoy free Canada-wide shipping over $179, hassle-free returns, and free torn lens replacement. Special offers available now!"},contactsPdp:{description:"Contact Lenses with best pricing guaranteed. Enjoy free Canada-wide shipping over $179, hassle-free returns, and free torn lens replacement. Special offers available now! Feel confident and comfortable every day."}}}},Jr=()=>{const e=ht(se()),t=Nd[e]??Nd[xI],n=It(),i=!n.hostname.includes(".camp.")&&!n.hostname.includes("localhost")&&!n.hostname.includes("127.0.0.1"),r=ef(t),s=(t.alternates??[]).find(a=>(a.prefix??"")===r);return{...t,locale:(s==null?void 0:s.hreflang)??t.locale,defaultLocale:t.locale,baseDomain:e,isProduction:i}},ef=e=>{const{pathname:t}=It(),n=(e.alternates??[]).find(i=>i.prefix&&t.toLowerCase().startsWith(i.prefix.toLowerCase()));return(n==null?void 0:n.prefix)??""},VI=(e,t)=>{const n=(t.alternates??[]).map(r=>r.prefix).filter(Boolean);let i=e||"/";return n.forEach(r=>{const s=i.toLowerCase();s===r.toLowerCase()?i="/":s.startsWith(`${r.toLowerCase()}/`)&&(i=i.slice(r.length))}),i.startsWith("/")?i:`/${i}`},rn=(e,t)=>{if(!t)return e.origin;if(/^https?:\/\//i.test(t))return t.replace(/ /g,"%20");if(t.startsWith("//"))return`https:${t}`.replace(/ /g,"%20");const n=t.startsWith("/")?t:`/${t}`;return`${e.origin}${n==="/"?"":n}`.replace(/ /g,"%20")},Dd=(e,t,n)=>{var i,r,s,a;return((r=(i=e.copy)==null?void 0:i[t])==null?void 0:r[n])??((a=(s=e.copy)==null?void 0:s.default)==null?void 0:a[n])??null},tf=160,BI={130:",",132:'"',133:"…",145:"‘",146:"’",147:"“",148:"”",149:"•",150:"–",151:"—"},nf=e=>String(e??"").replace(/[\u0080-\u009F]/g,t=>BI[t.charCodeAt(0)]??""),$I=(e,t=tf)=>{const n=nf(e).replace(/\s+/g," ").trim();if(n.length<=t)return n;const i=n.slice(0,t);let r=-1;const s=/[a-z0-9)][.!?](?=\s)/gi;let a;for(;(a=s.exec(i))!==null;)r=a.index+2;return r>0?i.slice(0,r).trim():i.slice(0,i.lastIndexOf(" ")).replace(/[\s,;:.\-–—]+$/,"")},yi=e=>{if(e==null||e==="")return null;const t=Number(e);return Number.isFinite(t)?`$${t%1===0?t:t.toFixed(2)}`:null},Xr=(...e)=>{const[t,...n]=e.filter(Boolean);return t?n.reduce((i,r)=>{const s=`${i} ${r}`;return s.length<=tf?s:i},$I(t)):""},os=e=>typeof e=="string"&&e?e.toLowerCase():null,vl=(e,t)=>{if(!e)return null;const n=String(e).split(/<br\s*\/?>\s*<br\s*\/?>/i),i=[];for(const r of n){const s=r.replace(/<[^>]+>/g," ").replace(/\s+/g," ").trim();if(!(s.length>=20&&!s.startsWith("-")&&!s.endsWith(":")&&s.toLowerCase()!==os(t)))break;i.push(s.replace(/[.\s]+$/,""))}return i.length?`${i.join(". ")}.`:null},sf=(e,t)=>
75yi(t)??yi(e),rf=e=>{const t=yi(e==null?void 0:e.free_shipping_threshold);return t?`Free shipping over ${t}.`:null},UI=(e,t={})=>{const n=os(t.product_group)==="sunglasses"?"Sunglasses":"Eyeglasses",r=[[t.color,t.name].filter(Boolean).join(" "),n].filter(Boolean).join(" "),s=t.rim_shape?`${r} — ${t.rim_shape}`:r;return nf(`${s} | ${e.siteName}`)},HI=(e,t={})=>{const n=os(t.product_group)??"glasses",i=[os(t.rim_shape),os(t.material)].filter(Boolean).join(" "),r=vl(t.description,t.name)??(i?`${t.name} - ${i} ${n}.`:`${t.name} - ${n}.`),s=sf(t.price,t.discounted_price),o={female:"Women's frames",male:"Men's frames",unisex:"Unisex frames"}[os(t.gender)]??"Frames",l=t.color?` in ${t.color}`:"",c=s?`${o}${l} from ${s} at ${e.siteName}.`:`${o}${l} at ${e.siteName}.`,d=t.accepts_lenses===!1?null:"Prescription lenses available.";return Xr(r,c,d,rf(t))},sX=(e,t={})=>{var c,d;const n=os(t.prod_category),i=t.pack_qty?`${t.pack_qty} lenses per box`:null,r=[n,i].filter(Boolean).join(", "),s=vl(t.product_description,t.name)??(r?`${t.name} - ${r}.`:`${t.name}.`),a=t.price_1R??((d=(c=t.price)==null?void 0:c[0])==null?void 0:d.price),o=yi(a),l=o?`From ${o} at ${e.siteName}.`:`Available at ${e.siteName}.`;return Xr(s,l,rf(t),"Hassle-free returns.")},iX=(e,t={})=>{var a;const n=sf(t.price,t.discounted_price),r=t.brand&&t.brand!==e.siteName&&!((a=t.name)!=null&&a.startsWith(t.brand))?` by ${t.brand}`:"",s=vl(t.description,t.name)??(n?`${t.name}${r} - ${n} at ${e.siteName}.`:`${t.name}${r} at ${e.siteName}.`);return Xr(s,"Eyewear accessories and care essentials.","Hassle-free returns.")},rX=(e,t={})=>{const n=yi(t.price),i=n?` Worth ${n}.`:"";return Xr(`${t.name} - give the gift of better vision.${i}`,`Redeemable on glasses, sunglasses and contact lenses at ${e.siteName}.`,"Delivered by email.")},zI=e=>e.some(t=>t.collection_name==="smart-glasses-x"),aX=e=>{switch(e){case"L":return"Large";case"M":return"Medium";case"S":return"Small";case"XS":return"Extra Small";case"XL":return"Extra Large";default:return e}},KI=()=>{const e=new URL(window.location.href);return it.get("isFromStore")==="true"?!0:e.searchParams.get("isFromStore")==="true"?(it.set("isFromStore","true",{expires:182}),!0):!1},GI=["GL14437","GL14438","GL22088","GL22089","GL22090","GL22091","GL28472","GL28473","GL28872","GL28873"],oX=(e,t)=>!GI.includes(e)||/AI\s+Smart\s+(Sun)?glasses\s*$/i.test(t)?t:`${t.replace(/\s+Smart\s+(Sun)?glasses\s*$/i,"")} AI Smart Glasses`,lX=(e,t,n,i={})=>{switch(e){case"GL07749":Me({title:"KITS MANIS Smart Glasses | Hands-Free Smart Glasses for Calls, Music & Voice Assistance"});break;case"GL07750":Me({title:"KITS PHATAGINUS Smart Glasses | Smart Glasses for Hands-Free Calls, Music & Voice Control"});break;case"GL07751":Me({title:"KITS SMUTSIA Smart Glasses | Hands-Free Smart Glasses for Calls & Music"});break;case"GL14437":Me({title:"KITS Pangolin 3 Smart Glasses | Music, Calls & Rx Ready",meta:[{name:"description",content:"Meet the Pangolin 3. Prescription smart glasses with a built-in AI assistant. The smartest way to see. Add your prescription at KITS today."}]});break;case"GL22090":Me({title:"KITS Pangolin 3 Sprint Smart Sunglasses | Music, Calls & Rx Ready",meta:[{name:"description",content:"The ultimate eyewear upgrade. Pangolin 3 Sprint features glare protection, open-ear AI audio, and an AI assistant for voice control. Buy now at KITS."}]});break;case"GL22091":Me({title:"KITS Pangolin 3 Velo Smart Sunglasses | Music, Calls & Rx Ready",meta:[{name:"description",content:"The ultimate eyewear upgrade. Pangolin 3 Velo features glare protection, open-ear AI audio, and an AI assistant for voice control. Buy now at KITS."}]});break;case"GL22088":Me({title:"KITS Pangolin 3 Rivo Smart Glasses | Music, Calls & Rx Ready",meta:[{name:"description",content:"Meet the Pangolin 3 Rivo. Prescription smart glasses with a built-in AI assistant. The smartest way to see. Add your prescription at KITS today."}]});break;case"GL14438":Me({title:"KITS Pangolin 3 Smart Sunglasses | Music, Calls & Rx Ready",meta:[{name:"description",content:"The ultimate eyewear upgrade. Pangolin 3 features glare protection, open-ear AI audio, and an AI assistant for voice control. Buy now at KITS."}]});break;case"GL22089":Me({title:"KITS Pangolin 3 Rivo Smart Sunglasses | Music, Calls & Rx Ready",meta:[{name:"description",content:"The ultimate eyewear upgrade. Pangolin 3 Rivo features glare protection, open-ear AI audio, and an AI assistant for voice control. Buy now at KITS."}]});break;case"GL28472":Me({title:"KITS Pangolin 3 Soren AI Smart Glasses | Music, Calls & Prescription Ready",meta:[{name:"description",content:"Meet the Pangolin 3 Soren. AI smart glasses with a built-in AI assistant, designed for the ones who prefer their tech understated. Capture, call, and listen hands-free. Shop KITS today."}]});break;case"GL28872":Me({title:"KITS Pangolin 3 Soren AI Smart Sunglasses | Music, Calls & Prescription Ready",meta:[{name:"description",content:"Meet the Pangolin 3 Soren. AI smart sunglasses with a built-in AI assistant, designed for the ones who prefer their tech understated. Capture, call, and listen hands-free. Shop KITS today."}]});break;case"GL28473":Me({title:"KITS Pangolin 3 Odin Smart Glasses | Music, Calls & Prescription Ready",meta:[{name:"description",content:"Meet the Pangolin 3 Odin. Everyday AI smart glasses with a built-in AI assistant in a classic square frame. Capture, call, and listen hands-free, all day long. Shop KITS today."}]});break;case"GL28873":Me({title:"KITS Pangolin 3 Odin Smart Sunglasses | Music, Calls & Prescription Ready",meta:[{name:"description",content:"Meet the Pangolin 3 Odin. Everyday AI smart sunglasses with a built-in AI assistant in a classic square frame. Capture, call, and listen hands-free, all day long. Shop KITS today."}]});break;case"GL14156":Me({title:"OAKLEY META HSTN AI Glasses | Meta AI Smart Glasses for photo capture, hands free video, calls, Music & Voice Assistance",meta:[{name:"description",content:"Oakley Meta HSTN Limited Edition features gold accents and gold Prizm 24 Polarized lenses, the glasses feature Meta AI, hands-free video, photo capture and more."}]});break;case"GL14157":Me({title:"OAKLEY META HSTN AI Glasses | Meta AI Smart Glasses for photo capture, hands free video, calls, Music & Voice Assistance",meta:[{name:"description",content:"Oakley Meta HSTN Limited Edition features gold accents and gold Prizm 24 Polarized lenses, the glasses feature Meta AI, hands-free video, photo capture and more."}]});break;case"GL14158":Me({title:"OAKLEY META HSTN AI Glasses | Meta AI Smart Glasses for photo capture, hands free video, calls, Music & Voice Assistance",meta:[{name:"description",content:"Oakley Meta HSTN Limited Edition features gold accents and gold Prizm 24 Polarized lenses, the glasses feature Meta AI, hands-free video, photo capture and more."}]});break;case"GL14159":Me({title:"OAKLEY META HSTN AI Glasses | Meta AI Smart Glasses for photo capture, hands free video, calls, Music & Voice Assistance",meta:[{name:"description",content:"Oakley Meta HSTN Limited Edition features gold accents and gold Prizm 24 Polarized lenses, the glasses feature Meta AI, hands-free video, photo capture and more."}]});break;
75case"GL17428":Me({title:"Oakley Meta Vanguard Black PRIZM 24K Sport Sunglasses | KITS",meta:[{name:"description",content:"Explore Oakley Meta Vanguard in Black with PRIZM 24K lenses. High-contrast optics, gold finish, and sport-ready performance ideal for training and outdoor activities."}]});break;case"GL17429":Me({title:"Oakley Meta Vanguard White PRIZM Black Performance Sunglasses | KITS",meta:[{name:"description",content:"Shop Oakley Meta Vanguard in White with PRIZM Black lenses. Lightweight sport design with enhanced contrast and clarity for bright outdoor conditions."}]});break;case"GL18338":Me({title:"Oakley Meta Vanguard Black PRIZM Road Performance Sunglasses | KITS",meta:[{name:"description",content:"Shop Oakley Meta Vanguard in Black with PRIZM Road lenses. Lightweight sport design with enhanced contrast and clarity for bright outdoor conditions."}]});break;case"GL17426":Me({title:"Meta Ray-Ban Headliner Shiny Black Transitions Glasses - Graph Green | KITS",meta:[{name:"description",content:"Shop the Meta Ray-Ban Headliner in Shiny Black with Transitions Graph Green lenses. Adaptive tint for indoor and outdoor comfort. Stylish, durable, and perfect for daily wear."}]});break;case"GL17427":Me({title:"Wayfarer Meta Ray-Ban Matte Black Polarized Gradient Graphite Sunglasses | KITS",meta:[{name:"description",content:"Discover Wayfarer Meta Ray-Ban in Matte Black with Polarized Gradient Graphite lenses. Reduced glare, high clarity, and timeless style for everyday wear."}]});break;case"GL18326":Me({title:"Wayfarer Meta Ray-Ban Matte Black | KITS",meta:[{name:"description",content:"Discover Wayfarer Meta Ray-Ban in Matte Black."}]});break;case"GL18327":Me({title:"Wayfarer Meta Ray-Ban Matte Black | KITS",meta:[{name:"description",content:"Discover Wayfarer Meta Ray-Ban in Matte Black."}]});break;case"GL18328":Me({title:"Wayfarer Meta Ray-Ban Matte Black | KITS",meta:[{name:"description",content:"Discover Wayfarer Meta Ray-Ban in Matte Black."}]});break;case"GL18329":Me({title:"Wayfarer Meta Ray-Ban Matte Black | KITS",meta:[{name:"description",content:"Discover Wayfarer Meta Ray-Ban in Matte Black."}]});break;case"GL18330":Me({title:"Wayfarer Meta Ray-Ban Matte Black | KITS",meta:[{name:"description",content:"Discover Wayfarer Meta Ray-Ban in Matte Black with G-15 Green lenses."}]});break;case"GL18331":Me({title:"Wayfarer Meta Ray-Ban Matte Black | KITS",meta:[{name:"description",content:"Discover Wayfarer Meta Ray-Ban in Matte Black with G-15 Green lenses."}]});break;case"GL18332":Me({title:"Headliner Meta Ray-Ban Matte Black | KITS",meta:[{name:"description",content:"Discover Headliner Meta Ray-Ban in Matte Black with G-15 Green lenses."}]});break;case"GL18333":Me({title:"Skyler Meta Ray-Ban Matte Black | KITS",meta:[{name:"description",content:"Discover Skyler Meta Ray-Ban in Matte Black."}]});break;case"GL18334":Me({title:"Skyler Meta Ray-Ban Matte Black | KITS",meta:[{name:"description",content:"Discover Skyler Meta Ray-Ban in Matte Black with G-15 Green lenses."}]});break;case"GL23867":Me({title:"Headliner Meta Ray-Ban Asteroid Grey | KITS",meta:[{name:"description",content:"Discover Headliner Meta Ray-Ban in Matte Black with Clear/Emerald lenses."}]});break;case"GL23868":Me({title:"Headliner Meta Ray-Ban Black | KITS",meta:[{name:"description",content:"Discover Headliner Meta Ray-Ban in Black with Clear/Sapphire lenses."}]});break;case"GL23870":Me({title:"Headliner Meta Ray-Ban Black | KITS",meta:[{name:"description",content:"Discover Headliner Meta Ray-Ban in Black."}]});break;case"GL23871":Me({title:"Headliner Meta Ray-Ban Black | KITS",meta:[{name:"description",content:"Discover Headliner Meta Ray-Ban in Black with Graphite lenses."}]});break;case"GL23869":Me({title:"Headliner Meta Ray-Ban Black | KITS",meta:[{name:"description",content:"Discover Headliner Meta Ray-Ban in Black with Graphite lenses."}]});break;case"GL22130":Me({title:"Skyler Meta Ray-Ban Mystic Violet | KITS",meta:[{name:"description",content:"Discover Skyler Meta Ray-Ban in Mystic Violet with Clear/Amethyst lenses."}]});break;case"GL22131":Me({title:"Skyler Meta Ray-Ban Black | KITS",meta:[{name:"description",content:"Discover Skyler Meta Ray-Ban in Black with Clear/Amethyst lenses."}]});break;case"GL23866":Me({title:"Wayfarer Meta Ray-Ban Black | KITS",meta:[{name:"description",content:"Discover Wayfarer Meta Ray-Ban in Black."}]});break;case"GL25778":Me({title:"Ray-Ban Meta Blayzer Optics - Gen 2 Glasses in Transparent Black | KITS",meta:[{name:"description",content:"Shop Ray-Ban Meta Blayzer Optics - Gen 2 glasses with Transparent Black Injected frame and Demo Lens lenses. Prescription available on KIT
75S online store."}]});break;case"GL25779":Me({title:"Ray-Ban Meta Blayzer Optics - Gen 2 Glasses in Transparent Black | KITS",meta:[{name:"description",content:"Shop Ray-Ban Meta Blayzer Optics - Gen 2 glasses with Transparent Black Injected frame and Demo Lens lenses. Prescription available on KITS online store."}]});break;case"GL25780":Me({title:"Ray-Ban Meta Blayzer Optics - Gen 2 Glasses in Transparent Dark Olive | KITS",meta:[{name:"description",content:"Shop Ray-Ban Meta Blayzer Optics - Gen 2 glasses with Transparent Dark Olive Injected frame and Demo Lens lenses. Prescription available on KITS online store."}]});break;case"GL25781":Me({title:"Ray-Ban Meta Blayzer Optics - Gen 2 Glasses in Transparent Dark Olive | KITS",meta:[{name:"description",content:"Shop Ray-Ban Meta Blayzer Optics - Gen 2 glasses with Transparent Dark Olive Injected frame and Demo Lens lenses. Prescription available on KITS online store."}]});break;case"GL25782":Me({title:"RAY-BAN META SCRIBER OPTICS - GEN 2 Glasses in Transparent Black and Demo Lens | KITS",meta:[{name:"description",content:"Shop RAY-BAN META SCRIBER OPTICS - GEN 2 glasses with Transparent Black Injected frame and Demo Lens lenses. Prescription available on KITS online store."}]});break;case"GL25783":Me({title:"RAY-BAN META SCRIBER OPTICS - GEN 2 Glasses in Black and Demo Lens | KITS",meta:[{name:"description",content:"Shop RAY-BAN META SCRIBER OPTICS - GEN 2 glasses with Black Injected frame and Demo Lens lenses. Prescription available on KITS online store."}]});break;case"GL25784":Me({title:"RAY-BAN META SCRIBER OPTICS - GEN 2 Glasses in Transparent Umber and Demo Lens | KITS",meta:[{name:"description",content:"Shop RAY-BAN META SCRIBER OPTICS - GEN 2 glasses with Transparent Umber Injected frame and Demo Lens lenses. Prescription available on KITS online store."}]});break;case"GL25785":Me({title:"Ray-Ban Meta Blayzer Optics - Gen 2 Glasses in Black | KITS",meta:[{name:"description",content:"Shop Ray-Ban Meta Blayzer Optics - Gen 2 glasses with Black Injected frame and Demo Lens lenses. Prescription available on KITS online store."}]});break;case"GL22133":Me({title:"KITS Soren SE Eyeglasses - Limited Edition Frames | KITS",meta:[{name:"description",content:"Shop the Soren SE - a limited special edition of our bestselling frame in 6 exclusive colourways. Lightweight, iconic, and made to order. Exclusively at KITS."}]});break;case"GL22134":Me({title:"KITS Soren SE Sunglasses - Limited Edition | KITS",meta:[{name:"description",content:"Shop the Soren SE Sun - 6 limited-edition colourways on our bestselling silhouette. Prescription-ready sunglasses, made to order. Exclusively at KITS."}]});break;case"GL25629":case"GL25670":case"GL25591":console.log("yex"),Me({title:"Nuance Audio Hearing Glasses — Smart Eyewear | KITS",meta:[{name:"description",content:"Hear better with Nuance Audio, invisible hearing aids in premium frames. Prescription-ready, Transitions-compatible smart eyewear. Exclusively at KITS."}]});break;default:{const r=Jr();Me({title:UI(r,i),meta:[{name:"description",content:HI(r,i)}]});break}}},cX=()=>{const e=On(),t=(e.path??"").toLowerCase(),i=((Array.isArray(e.params.id)?e.params.id[0]:e.params.id)??"").toString().toLowerCase(),s=["sun-progressive-readers","sun-readers","progressive-readers","readers"].find(a=>i===a||t.includes(`/${a}/`))??"";return{readersType:s,isFromReaders:s==="readers",isFromProgressiveReaders:s==="progressive-readers",isFromSunReaders:s==="sun-readers",isFromSunProgressiveReaders:s==="sun-progressive-readers"}},_l=()=>{const e=On(),t=(e.path??"").toLowerCase(),i=((Array.isArray(e.params.id)?e.params.id[0]:e.params.id)??"").toString().toLowerCase(),r=["sun-progressive-readers","sun-readers","progressive-readers","readers"];for(const s of r)if(i===s||t.includes(`/${s}/`))return s;return""},wl=e=>e?/1\.50\s*index/i.test(e)?"1.50":/1\.59\s*index/i.test(e)?"1.59":/1\.67\s*index/i.test(e)?"1.67":/1\.74\s*index/i.test(e)?"1.74":"":"",jI=e=>{const{lensColor:t,blueLightFilter:n,polarized:i,progressive:r,isRimless:s,isSafetyCollection:a,lensPower:o}=e,l=t==null?void 0:t.toUpperCase(),c=Math.max(Number(o.OS),Number(o.OD)),d=s||a,u=c>=3.25&&c<=3.75,p=c>=4;if(r)return l==="BROWN"?"":l==="GREY"?"LENSREADPGTINTGREY":"LENSREADPGBLUE";if(!r)return"LENSOPTI";if(n)return u?"LENSBLUE3READ":p&&!a?"LENSULTRATHINBLUEREAD":d?"LENSBLUE3READ":"LENSBLUEBASICREAD";if(i&&!d&&l){if(l==="BROWN")return"LENSPOLBROWNREAD";if(l==="GREY")return"LENSPOLGREYREAD"}return l?d?l==="BROWN"?"LENSPOLBROWNREAD2":"LENSPOLGREYREAD2":l==="BROWN"?"LENSTINTBROWNREAD":"LENSTINTGREYREAD":"LENSOPTI"},dX=e=>{const t=ie(),n=_l(),i=t.glassesStore.getReaders.progressive,r=t.glassesStore.getLensFlowSelectedOptions.lensType;let s=0,a=17;n==="progressive-readers"||i||r.type==="progressive-readers"?(s=4,a=15):(n==="sun-readers"||n==="sun-progressive-readers")&&(s=0,a=15);const l=e.map(c=>c.startsWith("=")?c.substring(1):c).slice(s,a).map(c=>({option:c,label:c}));return l[0].option==="--"?[l[0],{option:"--",label:0 .toFixed(2)},...l.slice(1)]:l},uX=e=>{const t=[e,...e.variations],i=t.reduce((r,s)=>s.customers>r.customers?s:r,t[0]).color||null;return{product_group:e.product_group,collections_name:e.product_tags,gender:e.gender,material:e.material,brand_name:e.brand_name,rim_shape:e.rim_shape,price:e.price,generic_color:e.generic_color,tshirt_size:e.sizes.map(r=>r.tshirt_size),b_size:e.frame_sizes.find(r=>r.type==="lens_height").size,eye:e.frame_sizes.find(r=>r.type==="lens_width").size,bridge:e.frame_sizes.find(r=>r.type==="bridge_size").size,screw_to_screw:e.frame_sizes.find(r=>r.type==="arm_length").size,temple:e.frame_sizes.find(r=>r.type==="arm_length").size,inner_frame_width:e.frame_sizes.find(r=>r.type==="frame_width").size,name:e.name,image_url:e.product_images[0].image,soldout:e.soldout,upc:e.upc,vto_alt_full:e.vto_id,products_sku:e.product_sku,configuration_id:e.config_id,promo_price:e.discounted_price,color:e.color,color_code:e.color_code,accepts_lenses:e.accepts_lenses?"1":"0",lens_color:e.lens_color,polarized_lenses:e.lens_type==="Polarized",description:e.description,customers:e.units_last_30_days,most_popular_color:i,variations:e.variations?e.variations.filter(r=>!r.soldout).map(({vto_id:r,...s})=>({...s,products_sku:e.product_sku,brand_name:e.brand_name,name:e.name,price:s.discounted_price?s.discounted_price:s.price,promo_price:s.discounted_price?s.price:null,product_group:e.product_group,polarized_lenses:e.lens_type==="Polarized",accepts_lenses:e.accepts_lenses?"1":"0",vto_alt_full:r,customers:s.units_last_30_days})):[]}},YI=(e,t)=>{if(t.calculated_pd<80)return e<t.min_pd||e>t.max_pd},WI=({key:e,value:t})=>{const r=ie().glassesStore.getFrameDetails.rx_inputs.find(s=>s.name===e);if(!r||!Array.isArray(r.options))return{key:e,value:"--"};{const s=String(t).trim(),a=r.options.includes(s);return{key:e,value:a?s:"--"}}},QI=({PD_OD:e,PD_OS:t})=>{const n=["40.0","40.5","41.0","41.5","42.0","42.5","43.0","43.5","44.0","44.5","45.0","45.5","46.0","46.5","47.0","47.5","48.0","48.5","49.0","49.5","50.0","50.5","51.0","51.5","52.0","52.5","53.0","53.5","54.0","54.5","55.0","55.5","56.0","56.5","57.0","57.5","58.0","58.5","59.0","59.5","60.0","60.5","61.0","61.5","62.0","62.5","63.0","63.5","64.0","64.5","65.0","65.5","66.0","66.5","67.0","67.5","68.0","68.5","69.0","69.5","70.0","70.5","71.0","71.5","72.0","72.5","73.0","73.5","74.0","74.5","75.0","75.5","76.0"],i=["20.0","20.5","21.0","21.5","22.0","22.5","23.0","23.5","24.0","24.5","25.0","25.5","26.0","26.5","27.0","27.5","28.0","28.5","29.0","29.5","30.0","30.5","31.0","31.5","32.0","32.5","33.0","33.5","34.0","34.5","35.0","35.5","36.0","36.5","37.0","37.5","38.0"],r=e!=="",s=t!=="";if(r&&s){const a=i.includes(e),o=i.includes(t);return a&&o?{PD_OD:e,PD_OS:t}:{PD_OD:"--",PD_OS:"--"}}if(r||s){const a=r?e:t,o=n.includes(a);return{PD_OD:r&&o?a:"--",PD_OS:s&&o?a:"--"}}return{PD_OD:"--",PD_OS:"--"}},ZI=e=>!((e.ADD_OS==="--"||e.ADD_OS==="")&&(e.ADD_OD==="--"||e.ADD_OD==="")),qI=e=>ZI(e)?"progressives":(e.SPH_OS>0&&e.SPH_OD>
750,"distance"),JI=e=>{const t={distance:{value:"distance",displayName:"Single Vision",type:"distance",backendValue:"Single Vision",cookieValue:"distance"},readers:{value:"prescription-readers",displayName:"Prescription Readers",type:"readers",backendValue:"Single Vision",cookieValue:"reading"},progressives:{value:"progressive",displayName:"Standard Progressives",type:"progressives",backendValue:"Progressive",parentValueName:"",cookieValue:"progressive"}},n=qI(e);return t[n]},hX=e=>{ie();const t=JSON.stringify(e),n=it.get("lensFlowOpticianOptions");t!==n&&it.set("lensFlowOpticianOptions",t,{expires:365})},pX=()=>{it.remove("lensFlowOpticianOptions")};let Ro=null,El=!1,Sl=!1;const fX=()=>{Ro=null,El=!1,Sl=!1},mX=()=>Sl,gX=()=>{El=!0},yX=()=>El,bX=e=>{e==="manual_rx"&&(Sl=!0),Ro!==e&&(Ro=e,Un(e,"glassesFlowEnterRxData"))},Un=(e,t=null)=>{var n,i,r,s;if(t==="glassesFlowWithEccomerceData"){const a=ie(),o=a.glassesStore.getFrameDetails,l=a.glassesStore.getLensFlowSelectedOptions,c=a.glassesStore.getLensTechnologies,d=a.glassesStore.getCurrentLensStep,u=a.glassesStore.getUpgradeLens,p=a.glassesStore.getIsUpgradeSelected,h=c==null?void 0:c.find(y=>y.sku===l.lensTechnology.value),m=(h==null?void 0:h.price)||0,v=(h==null?void 0:h.lens_color)||null;let _=o.discounted_price?o.discounted_price:o.price;m&&(_=_+m),p&&(_=_+u.price);const b={distance:"Single Vision","anti-fatigue":"anti-fatigue",progressive:"Progressives Standard",progressive2:"Enhanced Progressives","simple-readers":"Simple Reader","prescription-readers":"Prescription Reader","progressive-readers":"Progressive Reader","non-prescription":"Non-prescription"},w={PHOTOCHROMIC:"Light Transitioning",CLEAR:"Clear",BLUELIGHT:"Blue Light",BLUELIGHTPLUS:"Blue Light Plus",POLARIZEDGREEN:"Polarized Green",POLARIZEDBROWN:"Polarized Brown",POLARIZEDGREY:"Polarized Grey",TINTEDBROWN:"Tinted Brown",TINTEDGREY:"Tinted Grey",TINTEDPLBROWN:"Tinted Brown",TINTEDPLGREY:"Tinted Grey",TINTEDBLUE:"Tinted Blue",TINTEDDGREEN:"Tinted Green",TINTEDORANGE:"Tinted Orange",TINTEDPINK:"Tinted Pink",TINTEDPURPLE:"Tinted Purple"},C=d==="lensTechnologies"||d==="lensReview",O=d==="lensReview",T=C?w[l.lensOption.backendValue]??w[v]??null:null,E=O&&((i=(n=l==null?void 0:l.lensTechnology)==null?void 0:n.displayName)==null?void 0:i.length)>0?l.lensTechnology.displayName:null;try{dataLayer.push({event:e,items:[{item_brand:o==null?void 0:o.brand_name,item_category:o==null?void 0:o.product_group,item_id:o==null?void 0:o.product_sku,item_variant:o==null?void 0:o.config_id,item_name:o==null?void 0:o.name,quantity:1,price:Number.isFinite(_)?_:null,glassesType:(b==null?void 0:b[(r=l==null?void 0:l.lensType)==null?void 0:r.value])??null,lensType:T,lensTechnology:E,...e==="lens_bluelight_upsell"&&{upsell_price:(u==null?void 0:u.price)??null}}]})}catch{console.log("Datalayer not found:",{event:e,items:[{item_brand:o==null?void 0:o.brand_name,item_category:o==null?void 0:o.product_group,item_id:o==null?void 0:o.product_sku,item_variant:o==null?void 0:o.config_id,item_name:o==null?void 0:o.name,quantity:1,price:Number.isFinite(_)?_:null,glassesType:(b==null?void 0:b[(s=l==null?void 0:l.lensType)==null?void 0:s.value])??null,lensType:T,lensTechnology:E,...e==="lens_bluelight_upsell"&&{upsell_price:(u==null?void 0:u.price)??0}}]})}}else if(t==="glassesFlowEnterRxData")try{dataLayer.push({event:"rx_entry_method_selected",parameters:{method:e,flow_context:"lensflow_enter_prescription"}})}catch{console.log("Datalayer not found:",{event:"rx_entry_method_selected",parameters:{method:e,flow_context:"lensflow_enter_prescription"}})}else try{dataLayer.push({event:e})}catch{console.log("Datalayer not found:",e)}},vX=e=>{const t={event:"virtual-try-on-pdp",parameters:{item_brand:e==null?void 0:e.brand_name,item_category:e==null?void 0:e.product_group,item_id:e==null?void 0:e.product_sku,item_variant:e==null?void 0:e.config_id,item_name:e==null?void 0:e.name,price:Number(e!=null&&e.discounted_price?e.discounted_price:e==null?void 0:e.price)}};try{dataLayer.push(t)}catch{console.log("Datalayer not found:",t)}},_X=e=>{const t=document.getElementById("vtoApp");if(!t)return()=>{};let n=!!document.getElementById("vto-type-product");const i=new MutationObserver(()=>{const r=!!document.getElementById("vto-type-product");n&&!r&&e(),n=r});return i.observe(t,{childList:!0,subtree:!0}),()=>i.disconnect()},ea=(e,t)=>{try{dataLayer.push({event:e,searchTerm:t.query.trim(),search_source:t.source})}catch{console.log("Datalayer not found:",{event:e,searchTerm:t.query.trim(),search_source:t.source})}},XI=["LENSBLUE3READ","LENSBLUEBASICREAD"],eT=["LENSPHOTOBROWN2","LENSPHOTOGREY2","LENSAFPHOTOBROWN2","LENSAFPHOTOGREY2","LENSPROGPTBROWN2","LENSPROGPTBROWNTHIN2","LENSPROGPHOTOGREY2","LENSPROGPHOTOGREYTHIN2","LENSPROG2PTBROWN2","LENSPROG2PTBROWNTHIN2","LENSPROG2PHOTOGREY2","LENSPROG2PHOTOGREYTHIN2"],wX=e=>{const n=ie().glassesStore.getLensFlowSelectedOptions.lensTechnology,i=new Set(eT),r=e.filter(a=>i.has(a.sku)),s={};return r.forEach(a=>{var u,p;const o=(u=a.display_name)==null?void 0:u.match(/\d\.\d{2}/);if(!o)return;const l=o[0];s[l]||(s[l]={index:l,variants:[],is_recommended:!1,price:null});const c=(p=a.display_name)==null?void 0:p.match(/Brown|Grey/i),d={...a,color:c?c[0]:null,transition:!0};s[l].variants.push(d),a.is_recommended&&(s[l].is_recommended=!0),n!=null&&n.value&&n.value===a.sku&&(s[l].price=a.price)}),Object.values(s).map(a=>{var o;return{...a,price:a.price??((o=a.variants[0])==null?void 0:o.price)??null}})},tT=bl((e,t)=>{ea("predictive_search",{query:e,source:t?"Optician AI":"Regular"})},2e3),EX=e=>{const t=ie(),n=t.glassesStore.getLensOptionPrice,i=t.glassesStore.getGlassesTypePrice;return it.get("glasses-flow-progressive-calculation")==="true"?e-n-i:e},xd=(e,t,n,i)=>it.get("glasses-flow-progressive-calculation")==="true"?n>0?e+n+i:e+t+i:e,Cl=e=>{var s,a;const t=e==null?void 0:e.material,n=t==="metal"||t==="titanium"||t==="stainless steel",i=(s=e==null?void 0:e.collections)==null?void 0:s.some(o=>o.collection_name==="rimless"),r=(a=e==null?void 0:e.collections)==null?void 0:a.some(o=>o.collection_id===55);return!n&&!i&&!r},nT=e=>Cl(e)&&(e==null?void 0:e.product_group)!=="Sunglasses"&&!zI((e==null?void 0:e.collections)??[]),sT=e=>{const t=n=>!n||n==="--"||n==="None"||n==="-None";return!t(e==null?void 0:e.SPH_OD)||!t(e==null?void 0:e.SPH_OS)},iT=(e,t)=>{const n=new Map((e??[]).map(i=>[i.sku,i]));return(t??[]).map(i=>{const r=n.get(i.sku);return r?{...r,is_unavailable:!1}:{...i,is_unavailable:!0,is_recommended:!1,price:0}})};let es=null,ts=null,Ra=null;const rT=["kits.ca","kits.com"],Md=e=>{if(!e)return null;const t=ht(se());return rT.includes(t)?t:null},aT=e=>{const t=e.split(":");return{color:t[0],image:`${t[1]}:${t[2]}`,image_url:`${t[3]}:${t[4]}`,configuration_id:t[5],generic_color:t[6],enabled:!0,soldout:!1}},oT=(e,t)=>!e||e==="KITS"||t!=null&&t.toLowerCase().startsWith(e.toLowerCase())?t:`${e} ${t}`,La=e=>{var i;const t=(e.ColorImageMapping||[]).map(aT),n=t.find(r=>r.configuration_id===e.configuration_id);return{sku:e.products_sku,name:e.name,displayName:oT(e.brand_name,e.name),brand:e.brand_name,price:e.price,price_1r:e.price_1r,promo_price:e.promo_price,configuration_id:e.configuration_id,image:Array.isArray(e.imageUrl)?e.imageUrl[0]:e.imageUrl,altImage:(n==null?void 0:n.image_url)||((i=t[0])==null?void 0:i.image_url)||"",variations:t}},lT=e=>({sku:e.products_sku,name:e.name,brand:e.brand_name,price:e.price,price_1r:e.price_1r,image:Array.isArray(e.imageUrl)?e.imageUrl[0]:e.imageUrl}),ji=e=>{var t;return((t=e==null?void 0:e.response)==null?void 0:t.products)||[]},cT=()=>ht(se())==="opticontacts.com",dT=async()=>
75{if(!(await qC({type:"pla",sku:FC()})).success)throw new Error("Couldn't fetch the customer type.")},uT={abortOpticianSearch(){es&&(es.abort(),es=null),ts&&(ts.abort(),ts=null)},async fetchOpticianSearch(e){es&&es.abort(),es=new AbortController;const t=es.signal;return oI(e,t)},async fetchOpticianSearchSuggestions(e){ts&&ts.abort(),ts=new AbortController;const t=ts.signal;return lI(e,t)},async fetchSearchProduct(e,t,n=!1){var r;let i=!1;try{this.searchResultsLoading=!0,this.searchInputText=e;const a=(e||"").trim().split(/\s+/).filter(o=>{const l=o.toLowerCase();return!(vr(l,"progressive")||vr(l,"readers"))}).join(" ").replace(/\s+/g," ").trim();if(n){this.aiSearchSuggestions=[],this.searchSuggestionsLoading=!0;const o=this.fetchOpticianSearchSuggestions({search_query:a}).then(p=>{if(p!=null&&p.functionArgs)try{const h=JSON.parse(p.functionArgs),m=Array.isArray(h.filters)?h.filters.map(_=>({text:_.charAt(0).toUpperCase()+_.slice(1).toLowerCase(),type:"filter"})):[],v=Array.isArray(h.continuations)?h.continuations.map(_=>({text:_,type:"continuation"})):[];(m.length||v.length)&&(this.aiSearchSuggestions=[...m,...v])}catch{}}).catch(p=>{var h;p.name!=="AbortError"&&((h=p.cause)==null?void 0:h.name)!=="AbortError"&&console.error("Suggestions error",p)}).finally(()=>{this.searchSuggestionsLoading=!1}),[l,c]=await Promise.all([this.fetchOpticianSearch({search_query:a}),Ad(a,t)]),d=$C(l),u=c.response.products.filter(p=>p.doctype==="KEYWORD_SUGGESTION"||p.doctype==="TOP_SEARCH_QUERIES");this.searchResults={response:{numberOfProducts:d.length,products:[...d,...u],start:0},searchMetaData:{queryParams:{q:a},queryTime:0,status:0}},await o}else{const o=await Ad(a,t);this.searchResults=o}n?ea("predictive_search",{query:e,source:n?"Optician AI":"Regular"}):tT(e,n)}catch(s){s.name==="AbortError"||((r=s.cause)==null?void 0:r.name)==="AbortError"?i=!0:console.error("Error",s)}finally{i||(this.searchResultsLoading=!1)}},async fetchTrendingProducts(){try{this.searchResultsLoading=!0;const e=await ZC();this.trendingResults=e.data}catch(e){console.error("Error",e)}finally{this.searchResultsLoading=!1}},async fetchTrendingContacts(e){try{this.searchResultsLoading=!0;const t=await QC(e);this.trendingContacts=t.response}catch(t){console.error("Error",t)}finally{this.searchResultsLoading=!1}},async fetchCustomerType(){if(cT())try{Ra||(Ra=dT()),await Ra}catch(e){console.error("Error",e)}},async fetchGenericSiteMetadata(){const e=ie();try{await this.fetchCustomerType();const t=await JC();t.success?(this.genericSiteMetadata=t.data,e.anagramStore.setIsAnagramFormCompleted(t.data.is_anagram_insurance_active),t.data.is_anagram_insurance_active&&e.anagramStore.fetchContinueSubmission()):e.systemStore.addToastMessage("ERROR",t.error)}catch(t){console.error("Error",t)}finally{}},async fetchDesignerBrands(){try{const e=await XC();if(e.success)return e.data;store.systemStore.addToastMessage("ERROR",e.error)}catch(e){console.error("Error",e)}finally{}},async removeCartItem(e){const t=ie();try{const n=await eI(e);n.success?this.genericSiteMetadata=n.metadata:t.systemStore.addToastMessage("ERROR",n.error)}catch(n){console.error("Error",n)}finally{}},async addCoupon(e){ie();try{this.setLoadingFetchData(!0);const t=await nI(e);t.success?(this.genericSiteMetadata=t.metadata,this.invalidCoupon=""):this.invalidCoupon=t.error}catch(t){console.error("Error",t)}finally{this.setLoadingFetchData(!1)}},async removeCoupon(e){const t=ie();try{this.setLoadingFetchData(!0);const n=await tI(e);n.success?this.genericSiteMetadata=n.metadata:t.systemStore.addToastMessage("ERROR",n.error)}catch(n){console.error("Error",n)}finally{this.setLoadingFetchData(!1)}},async subscribeUserToNewsletter(e){const t=ie();try{this.subscribeUserLoading=!0;const n=await sI(e);return n.success?!0:(t.systemStore.addToastMessage("ERROR",n.error),!1)}catch(n){return console.error("Error",n),t.systemStore.addToastMessage("ERROR",this.$i18n.t("toast.system.service-unavailable")),!1}finally{this.subscribeUserLoading=!1}},async trackIterableFavorite(e){if(Md(this.genericSiteMetadata.is_logged_in))try{await iI(e)}catch(t){console.error("Error tracking Iterable favourite",t)}},async trackIterableVto(e){if(Md(this.genericSiteMetadata.is_logged_in))try{await rI(e)}catch(t){console.error("Error tracking Iterable VTO",t)}},async fetchOffersSiteStripe(){const e=ie();try{const t=await aI();t.success?this.offersSiteStripe=t.data:e.systemStore.addToastMessage("ERROR",t.error)}catch(t){console.error("Error",t),e.systemStore.addToastMessage("ERROR",this.$i18n.t("toast.system.service-unavailable"))}finally{}},async fetchNewGlassesBestSellers(){try{const e=await Gi("Eyeglasses");this.error404BestSellers.glassesBestSellers=ji(e).map(La)}catch(e){console.error(e)}},async fetchNewSunglassesBestSellers(){try{const e=await Gi("Sunglasses");this.error404BestSellers.sunglassesBestSellers=ji(e).map(La)}catch(e){console.error(e)}}
75,async fetchNewDesignerBestSellers(){try{const e=await Gi("Designer");this.error404BestSellers.designerBestSellers=ji(e).map(La)}catch(e){console.error(e)}},async fetchContactsBestSellers(){try{const e=await Gi("Contacts"),t=ji(e).map(lT).sort((n,i)=>Ao.indexOf(n.sku)-Ao.indexOf(i.sku));this.contactsBestSellers=t,this.error404BestSellers.contactsBestSellers=t}catch(e){console.error(e)}},closeSearchBar(){this.isOpticianSearch&&(this.abortOpticianSearch(),this.setOpticianSearchSuggestions([])),this.setSearchResultLoading(!1),this.setSearchValue(""),this.searchInputText="",this.setDisplayHeaderSearch(!1),this.setDisplayHeaderSearchMenu(!1),this.setIsOpticianSearch(!1),this.setSearchResults({numberOfProducts:0,products:[],start:0}),yl()},setShouldShowAnagram(e){this.shouldShowAnagram=e},setSearchResultLoading(e){this.searchResultsLoading=e},setLoadingFullData(e){this.loadingFullData=e},setLoadingFetchData(e){this.loadingFetchData=e},setLensTechLoading(e){this.lensTechLoading=e},setLoadingAddToCart(e){this.loadingAddToCart=e},setLoadingFetchSimilarFrames(e){this.loadingFetchSimilarFrames=e},setLoadingUploadedRxFiles(e){this.loadingUploadedRxFiles=e},setLoadingAnagram(e){this.loadingAnagram=e},setDisplayHeaderSearch(e){this.displayHeaderSearch=e},setDisplayHeaderSearchMenu(e){this.displayHeaderSearchMenu=e,e?(document.body.style.overflow="hidden",document.body.style.position="fixed"):(document.body.style.overflow="auto",document.body.style.position="")},setDisplayHeaderNavDetails(e){this.displayHeaderNavDetails=e},setHeaderInformation(e){const t={"kits.ca":{logo:"kitsca_logo-v2.svg",type:"normal"},"kits.com":{logo:"kits_logo.svg",type:"normal"},"opticontacts.com":{logo:"opti-logo-2.svg",type:"legacy"},"contactsexpress.ca":{logo:"contacts-express-logo.svg",type:"legacy"},"postalcontacts.com":{logo:"postal_contacts_logo.svg",type:"legacy"}};this.headerInformation=t[e]||{logo:"kits_logo.svg",type:"normal"}},setHeaderNavType(e){this.headerNavType=e},setHeaderNavMenuType(e){this.headerNavMenuType=e},setHamburgerMenuType(e){this.hamburgerMenuType=e},setIsAccordionVisible(e){this.isAccordionVisible=e},setIsProductNotFound(e){this.isProductNotFound=e},setCheckingContactsRxLoading(e){this.loadingCheckContactsRx=e},setUserAsLoggedIn(){this.genericSiteMetadata={...this.genericSiteMetadata,is_logged_in:!0}},setSelectedProductType(e){this.selectedProductType=e},setCustomerExpressCheckoutLoading(e){this.customerExpressCheckoutLoading=e},setCustomerSavedPrescriptionLoading(e){this.customerSavedPrescriptionLoading=e},setSearchResults(e){this.searchResults.response=e,this.searchResults.searchMetaData.queryParams={q:""},this.searchResults.searchMetaData.queryTime=0},showConfirmDialog(e){return this.confirmDialog.title=e.title,this.confirmDialog.message=e.message,this.confirmDialog.topButtonText=e.topButtonText,this.confirmDialog.bottomButtonText=e.bottomButtonText,this.confirmDialog.showSkip=e.showSkip,this.confirmDialog.iconType=e.iconType,this.confirmDialog.onSkipButtonClick=e.onSkipButtonClick||null,this.confirmDialog.onTopButtonClick=e.onTopButtonClick||null,this.confirmDialog.onBottomButtonClick=e.onBottomButtonClick||null,this.confirmDialog.isVisible=!0,new Promise(t=>{this.confirmDialog.resolver=t})},resolveConfirm(e){this.confirmDialog.isVisible=!1,this.confirmDialog.resolver&&(this.confirmDialog.resolver(e),this.confirmDialog.resolver=null),this.confirmDialog.onSkipButtonClick=null,this.confirmDialog.onTopButtonClick=null,this.confirmDialog.onBottomButtonClick=null},setIsOpticianSearch(e){this.isOpticianSearch=e},setSearchValue(e){this.searchValue=e},setOpticianSearchSuggestions(e){this.aiSearchSuggestions=e},setIsScannerOpened(e){this.isScannerOpened=e},async fetchContactsByUpc(e){try{const t=await Xp(e);return t.success?(this.contactsByUpc=t.data,{success:t.success,message:t==null?void 0:t.message,data:t==null?void 0:t.data}):t.data.in_stock&&t.data.brand&&t.data.rx_info==null?(this.contactsByUpc=t.data,{success:!t.success,message:"rx_info null"}):!t.data.in_stock&&t.data.brand?(this.contactsByUpc=t.data,{success:!t.success,message:t==null?void 0:t.message}):{success:t.success,message:t==null?void 0:t.message}}catch(t){console.error("Error",t)}},addToastMessage(e,t,n=5e3){this.$patch({toastMessage:{payload:t,type:e,life:n}})}},hT=Rt("system",{state:()=>fS,getters:mS,actions:uT}),pT={product:{sku:null,name:null,brand_image:null,variants:[],price:[],regular_price:[],is_pla:!1,colored_lenses:!1,colors:[],product_information:[],product_description:"",product_images:[],rx_inputs:[],prod_category:"",days_supply:0,free_shipping_threshold:99,discontinued:{status:!1,alternate:{sku:"",name:"",price:0,image:"",url:""}}},checkContactsRxState:{rx_pass_check:!1,warning_message:""},visibleStep:1,rxMethod:"",discounts:{contacts_discounts:{environment:{new:{general:{active:!1,coupon_name:null,discount_percentage:null,max_discount:null}},repeat:{general:{active:!1,coupon_name:null,discount_percentage:null,max_discount:null}},first_contacts_reorder:{general:{active:!1,coupon_name:null,discount_percentage:null,max_discount:null}},first_pla_reorder:{general:{active:!1,coupon_name:null,discount_percentage:null,max_discount:null}}}}},uploadedRxFiles:[],selectedOptions:{OD_QUANTITY:2,OS_QUANTITY:2,OD_COLOR:"Select a colour",OS_COLOR:"Select a colour",P_Cyl_OS:"",P_Cyl_OD:"",BC_OS:"",BC_OD:"",Dia_OS:"",Dia_OD:"",P_Cyl_Axis_OS:"",P_Cyl_Axis_OD:"",P_OS:"",P_OD:"",P_Add_OS:"",P_Add_OD:""},aiResponseRx:{},selectedSlideMainSwiper:0,isBothEyesChecked:!1,isUploadSelected:!1,isAutoshipChecked:!1,replenOption:3,frequencyMode:"one_time",hasCommittedFrequencySelection:!1,autoshipStatus:{autoship_discount_for_cart:null,autoship_reorder_discount:null,autoship_coupon:null,autoreorder:!1,autoreorder_frequency_key:null,frequency_options:[]},autoshipFrequency:{loading:!1,lastRequest:null},hasUploadSizeError:!1},fT={getContactsData(e){return e.product},getVisibleStep(e){return e.visibleStep},getRxMethod(e){return e.rxMethod},getDiscounts(e){return e.discounts},getSelectedOptions(e){return e.selectedOptions},getUploadedRxFiles(e){return e.uploadedRxFiles},getCheckContactsRxState(e){return e.checkContactsRxState},getAiResponseRx(e){return e.aiResponseRx},getSelectedSlideMainSwiper(e){return e.selectedSlideMainSwiper},getIsBothEyesChecked(e){return e.isBothEyesChecked},getIsUploadSelected(e){return e.isUploadSelected},getIsAutoshipChecked(e){return e.isAutoshipChecked},getReplenOption(e){return e.replenOption},getFrequencyMode(e){return e.frequencyMode},getHasCommittedFrequencySelection(e){return e.hasCommittedFrequencySelection},getAutoshipStatus(e){return e.autoshipStatus},getSubscribeDiscountPercent(e){return e.autoshipStatus.autoship_discount_for_cart??0},getSubscribeReturnDiscountPercent(e){return e.autoshipStatus.autoship_reorder_discount??0},getFrequencyOptions(e){return e.autoshipStatus.frequency_options||[]},getIsFrequencyLoading(e){return e.autoshipFrequency.loading},getHasUploadSizeError(e){return e.hasUploadSizeError}},Fd=(e,t)=>{const n=ie(),i=new Set;t=t.filter(a=>i.has(a.display_name)?!1:(i.add(a.display_name),a.name=a.name.replace(/_OD|_OS/g,""),!0));let r=[];return t.forEach(a=>{r.push(a.name)}),r.push("eye"),r.push("quantity"),n.contactsStore.getContactsData.colors.length>0&&r.push("Clr"),e.products=e.products.map(a=>{const o=Object.fromEntries(Object.entries(a.options).filter(([l])=>r.includes(l)));return{...a,options:o}}
75),e.products.forEach(a=>{for(let o in a.options)typeof a.options[o]=="string"&&(a.options[o]=a.options[o].replace(/\s+/g,"").replace(/\(PL\)/g,""))}),e},mT={async fetchContactsData(e){const t=ie();try{t.systemStore.setIsProductNotFound(!1),t.systemStore.setLoadingFetchData(!0);const n=await cI(e);if(n.success)this.product=n.data,n.data.rx_inputs.forEach(i=>{i.options.length===1?this.selectedOptions[i.name]=i.options[0]:this.selectedOptions[i.name]="Select"});else return kr("/contacts",{redirectCode:301})}catch(n){console.error("Error",n)}finally{t.systemStore.setLoadingFetchData(!1)}},async fetchDiscounts(){try{const e=await dI();e.success&&(this.discounts=e)}catch(e){console.error("Error",e)}},async fetchAutoshipStatus(){try{const e=await bI();e!=null&&e.success&&(this.autoshipStatus=e.data)}catch(e){console.error("Error",e)}},async fetchAutoshipFrequency(){var n;const e=EC(this.product.sku,this.selectedOptions);if(!e.length)return;const t=JSON.stringify(e);this.autoshipFrequency.lastRequest=t;try{this.autoshipFrequency.loading=!0;const i=await vI(e);if(this.autoshipFrequency.lastRequest!==t)return;const r=(n=i==null?void 0:i.data)==null?void 0:n.autoreorder_frequency_key;i!=null&&i.success&&r&&(this.replenOption=r)}catch(i){console.error("Error",i)}finally{this.autoshipFrequency.lastRequest===t&&(this.autoshipFrequency.loading=!1)}},async addContactsToCart(e,t,n){let i={...e},r=JSON.parse(JSON.stringify(t));const s=ie();try{const a=s.contactsStore.getDiscounts,o=s.contactsStore.getIsAutoshipChecked,l=s.contactsStore.getReplenOption;let c=Jp(a,e.products[0].sku,n);s.systemStore.setLoadingAddToCart(!0),i.products.forEach(p=>{p.options.Clr==="Select a colour"&&(p.options.Clr="Select")});let d=Fd(Cd(i),r);c!=null&&c.coupon_name&&(d.coupon_code=c.coupon_name),Zr()&&(d.coupon_code="SL50"),qr()&&(d.coupon_code="MBCCONTACTS"),o&&(d.autoreorder_frequency_key=l,delete d.coupon_code),gi.value&&delete d.coupon_code,d.enable_autoship=!1,d.enable_pla_autoship=!1,d.enable_general_autoship=!1,it.get("enable_pla_autoship")==="true"&&(d.enable_pla_autoship=!0),it.get("enable_pla_autoship")==="false"&&(d.enable_pla_autoship=!1),it.get("enable_general_autoship")==="true"&&(d.enable_general_autoship=!0),it.get("enable_general_autoship")==="false"&&(d.enable_general_autoship=!1),sessionStorage.getItem("autoship_action")&&sessionStorage.getItem("autoship_action")==="enroll"&&(d.enable_autoship=!0),d.products.sort((p,h)=>p.options.eye==="OD"?-1:h.options.eye==="OD"?1:0);const u=await uI(d);if(u.success){try{dataLayer.push(u.ga_data.gtfour)}catch{console.log("Datalayer not found add to cart event",u.ga_data.gtfour)}let p=`${Ae()}${u.redirect_url}`;window.location.href=p}else s.systemStore.addToastMessage("ERROR",u.error)}catch(a){console.error("Error",a)}finally{s.systemStore.setLoadingAddToCart(!1)}},async checkContactsRxOptions(e,t){const n=ie();try{n.systemStore.setCheckingContactsRxLoading(!0);let i={...e},r=JSON.parse(JSON.stringify(t));const s=await hI(Fd(Cd(i),r));s.success?this.checkContactsRxState=s.data:n.systemStore.addToastMessage("ERROR",s.error)}catch(i){console.error("Error",i)}finally{n.systemStore.setCheckingContactsRxLoading(!1)}},resetCheckContactsRxState(){this.checkContactsRxState={rx_pass_check:!1,warning_message:""}},async uploadContactsRxFile(e){const t=ie();try{const n=await pI(e);n.success?(this.uploadedRxFiles=n.data.rx_user_uploads,t.systemStore.addToastMessage("SUCCESS",this.$i18n.t("toast.contacts.upload-success"))):t.systemStore.addToastMessage("ERROR",n.error)}catch(n){console.error("Error",n)}},async fetchUploadedRxFiles(){const e=ie();try{e.systemStore.setLoadingUploadedRxFiles(!0);const t=await fI();t.success?this.uploadedRxFiles=t.data.rx_user_uploads:console.error("ERROR",t.error)}catch(t){console.error("Error",t)}finally{e.systemStore.setLoadingUploadedRxFiles(!1)}},async fetchContactsSimilars(){ie();try{const e=await yI();if(e.success)return e.data;console.error("ERROR",e.error)}catch(e){console.error("Error",e)}},async deleteUploadedRxFile(e){const t=ie();try{const n=await mI(e);n.success?(this.uploadedRxFiles=n.data.rx_user_uploads,t.systemStore.addToastMessage("SUCCESS",this.$i18n.t("toast.contacts.file-deleted"))):t.systemStore.addToastMessage("ERROR",n.error)}catch(n){console.error("Error",n)}},async identifyContactsPrescriptionByAI(e){const t=ie();try{const n=await gI(e);if(n.success)return this.aiResponseRx=JSON.parse(n.data),JSON.parse(n.data);t.systemStore.addToastMessage("ERROR","Timeout exceeded. Please try again")}catch(n){console.error("Error",n)}},saveContactsOptions(e,t){this.selectedOptions[t]=e},setVisibleStep(e){this.visibleStep=e},setRxMethod(e){this.rxMethod=e},setSelectedSlideMainSwiper(e){this.selectedSlideMainSwiper=e},setIsBothEyesChecked(e){this.isBothEyesChecked=e},setIsUploadSelected(e){this.isUploadSelected=e},setIsAutoshipChecked(e){this.isAutoshipChecked=e},setReplenOption(e){this.replenOption=e},setFrequencyMode(e){this.frequencyMode=e,this.isAutoshipChecked=e==="subscribe",this.hasCommittedFrequencySelection=!0}
75,setHasUploadSizeError(e){this.hasUploadSizeError=e},resetProduct(){this.product={sku:null,name:null,brand_image:null,variants:[],price:[],regular_price:[],is_pla:!1,colored_lenses:!1,colors:[],product_information:[],product_description:"",product_images:[],rx_inputs:[],prod_category:"",days_supply:0,free_shipping_threshold:99,discontinued:{status:!1,alternate:{sku:"",name:"",price:0,image:"",url:""}}}}},gT=Rt("contacts",{state:()=>pT,getters:fT,actions:mT}),yT={frameDetails:{product_sku:"",product_images:[],name:"",description:"",product_tags:[],price:0,discounted_price:0,variations:[],color:"",color_code:"",style_code:"",vto_id:"",sizes:[],frame_sizes:[],frame_size:null,shipping_status:"",gender:"",accepts_lenses:!0,material:"",is_meta:!1,is_liftoff:!1,brand_name:"",rx_inputs:[],product_group:"",generic_color:"",config_id:"",soldout:0,progressive_price:0,free_shipping_threshold:0,is_rimless:!1,has_clipon_available:!1,is_from_lux:!1,clippons:[],is_external_frame:!1,upsells:[],collections:[],calculated_pd:"",max_pd:"",min_pd:"",upc:null,country:null,parent_collections:null},lightWeightCollection:{},tacOverlay:{designer:!1,kits:!1},lensesPrices:{lenses:{normal:{progressives:{cheapest_bluelight_lens_price:null,cheapest_clear_lens_price:null,cheapest_light_transition_lens_price:null,cheapest_sun_lens_price:null,cheapest_bluelight_lens_plus_price:null},progressives2:{cheapest_bluelight_lens_price:null,cheapest_clear_lens_price:null,cheapest_light_transition_lens_price:null,cheapest_sun_lens_price:null,cheapest_bluelight_lens_plus_price:null},single_vision:{cheapest_bluelight_lens_price:null,cheapest_clear_lens_price:null,cheapest_light_transition_lens_price:null,cheapest_sun_lens_price:null,cheapest_tinted_lens_price:null,cheapest_bluelight_lens_plus_price:null}},rimless:{progressives:{cheapest_bluelight_lens_price:null,cheapest_clear_lens_price:null,cheapest_light_transition_lens_price:null,cheapest_sun_lens_price:null,cheapest_bluelight_lens_plus_price:null},progressives2:{cheapest_bluelight_lens_price:null,cheapest_clear_lens_price:null,cheapest_light_transition_lens_price:null,cheapest_sun_lens_price:null,cheapest_bluelight_lens_plus_price:null},single_vision:{cheapest_bluelight_lens_price:null,cheapest_clear_lens_price:null,cheapest_light_transition_lens_price:null,cheapest_sun_lens_price:null,cheapest_tinted_lens_price:null,cheapest_bluelight_lens_plus_price:null}}}},defaultLensesPrices:null,isUploadRxSubmission:!1,productSimilarFrames:{similars_by_shape:[],similars_by_shape_count:0,similars_by_sku:[],similars_by_sku_count:0},couponDetails:[],recentlyViewedFrames:[],rr_reviews:"",productShowCaseLearnMoreInfo:null,lensFlowActive:!1,startLensFlowLoading:!1,currentLensStep:"glassesType",lensFlowTotalSteps:5,isScanActive:!1,prescriptionCompatibility:!0,uploadedRxFiles:[],errorModalPD:{isModalShowing:!1,isPDOutOfRange:!1},pdMessage:"",rxMessage:"",isPDWarning:!1,lensFlowSelectedOptions:{lensType:{value:"",displayName:"",type:"",backendValue:"",parentValueName:"",cookieValue:""},lensOption:{value:"",backendValue:"",backendColorValue:"",displayName:"",type:"",colorParent:"",parentValueName:""},lensTechnology:{value:"",displayName:"",comment:""}},preselectedLensTint:null,preselectedLensTintPrice:0,preselectedLensTintPriceLoading:!1,preselectedLensTintUnavailable:!1,pangolinGlassesTypePricesLoading:!1,lensFlowOptician:!1,lensPrescriptionStatus:{},lensOptions:[],expectedLensSkus:{expectedSkus:[],recommendedSku:""},lensTechnologies:[],localLensTechnology:null,isDoublePdActive:!1,isRxSunUpsell:!1,showRxForm:!0,progressiveChoice:!1,bitzCharms:[],selectedClipponSkus:[],selectedCharmOption:[],selectedIndividualBitz:[],selectedRxOptions:{SINGLE_PD:"",PD_OS:"",PD_OD:"",SPH_OS:"--",SPH_OD:"--",CYL_OS:"--",CYL_OD:"--",AXIS_OS:"--",AXIS_OD:"--",ADD_OS:"--",ADD_OD:"--",OC_OS:"--",OC_OD:"--",Seg_Height_OD:"--",Seg_Height_OS:"--"},rxAdditionalComments:"",previousPrescriptions:[],showChoosePrevious:!1,readers:{lensPower:"",lensPowerOS:"",lensPowerOD:"",lensSku:"",rx_type:"",lensColor:"",blueLightFilter:!0,polarized:"",progressive:"",showSelectPowerError:!1,isAdvancedSelection:!1},didSelectExpress:!1,selectedSlide:0,reviewUpsell:[],rxHasPrism:!1,rxConfidenceScore:0,rxOptionsConfidence:{SINGLE_PD_ACCURACY:0,PD_OS_ACCURACY:0,PD_OD_ACCURACY:0,SPH_OS_ACCURACY:0,SPH_OD_ACCURACY:0,CYL_OS_ACCURACY:0,CYL_OD_ACCURACY:0,AXIS_OS_ACCURACY:0,AXIS_OD_ACCURACY:0,ADD_OS_ACCURACY:0,ADD_OD_ACCURACY:0,OC_OS_ACCURACY:0,OC_OD_ACCURACY:0},opticianAnswers:{q1:{question:"",answer:""},q2:{question:"",answer:""}},isVtoActive:!1,uploadSelected:null,isSameADDBothEyes:!0,expandedType:null,VTO3DAvailability:!1,lensOptionPrice:0,lensTechnologyPrice:0,glassesTypePrice
75:0,frameCases:[],showCaseDialog:!1,pickedCase:null,loadingCase:!1,upgrade_lens:{new_lens_sku:"",price:0,orig_price:0},is_upgrade_selected:!1},bT={getFrameDetails(e){return e.frameDetails},getLensesPrices(e){return e.lensesPrices},getProductSimilarFrames(e){return e.productSimilarFrames},getRecentlyViewedFrames(e){return e.recentlyViewedFrames},getLightWeightCollection(e){return e.lightWeightCollection},getCouponDetails(e){return e.couponDetails},getLensFlowActive(e){return e.lensFlowActive},getStartLensFlowLoading(e){return e.startLensFlowLoading},getProductShowCaseLearnMoreInfo(e){return e.productShowCaseLearnMoreInfo},getLensFlowOptician(e){return e.lensFlowOptician},getLensPrescriptionStatus(e){return e.lensPrescriptionStatus},getLensFlowSelectedOptions(e){return e.lensFlowSelectedOptions},getPreselectedLensTint(e){return e.preselectedLensTint},getPreselectedLensTintPrice(e){return e.preselectedLensTintPrice},getPreselectedLensTintPriceLoading(e){return e.preselectedLensTintPriceLoading},getPreselectedLensTintUnavailable(e){return e.preselectedLensTintUnavailable},getPangolinGlassesTypePricesLoading(e){return e.pangolinGlassesTypePricesLoading},getLensTechnologies(e){return e.lensTechnologies},getLocalLensTechnology(e){return e.localLensTechnology},getCurrentLensStep(e){return e.currentLensStep},getShowRxForm(e){return e.showRxForm},getDoublePdActive(e){return e.isDoublePdActive},getPrescriptionCompatibility(e){return e.prescriptionCompatibility},getSelectedRxOptions(e){return e.selectedRxOptions},getRxAdditionalComments(e){return e.rxAdditionalComments},getRxSunUpsell(e){return e.isRxSunUpsell},getUploadedRxFiles(e){return e.uploadedRxFiles},getErrorModalPD(e){return e.errorModalPD},getPdMessage(e){return e.pdMessage},getRxMessage(e){return e.rxMessage},getIsPDWarning(e){return e.isPDWarning},getProgressiveChoice(e){return e.progressiveChoice},getLensFlowTotalSteps(e){return e.lensFlowTotalSteps},getSelectedCharmOption(e){return e.selectedCharmOption},getSelectedIndividualBitz(e){return e.selectedIndividualBitz},getBitzCharms(e){return e.bitzCharms},getSelectedClipponSkus(e){return e.selectedClipponSkus},getSelectedSlide(e){return e.selectedSlide},getReviewUpsell(e){return e.reviewUpsell},getRRContent(e){return e.rr_reviews},getTACOverlay(e){return e.tacOverlay},getDidSelectExpress(e){return e.didSelectExpress},getReaders(e){return e.readers},getHasOpticianLoaded(e){return e.hasOpticianLoaded},getMeasuredPdResults(e){return e.measuredPdResults},getRxFormFields(e){return e.selectedRxOptions},getLensOptions(e){return e.lensOptions},getExpectedLensSkus(e){return e.expectedLensSkus},getOpticianAnswers(e){return e.opticianAnswers},getRxHasPrism(e){return e.rxHasPrism},getRxConfidenceScore(e){return e.rxConfidenceScore},getIsVtoActive(e){return e.isVtoActive},getPreviousPrescriptions(e){return e.previousPrescriptions},getShowChoosePrevious(e){return e.showChoosePrevious},getIsScanActive(e){return e.isScanActive},getUploadSelected(e){return e.uploadSelected},getIsSameADDBothEyes(e){return e.isSameADDBothEyes},getExpandedType(e){return e.expandedType},getVTO3DAvailability(e){return e.VTO3DAvailability},getPickedCase(e){return e.pickedCase},getShowCaseDialog(e){return e.showCaseDialog},getFrameCases(e){return e.frameCases},getLoadingCase(e){return e.loadingCase},getLensOptionPrice(e){return e.lensOptionPrice},getLensTechnologyPrice(e){return e.lensTechnologyPrice},getGlassesTypePrice(e){return e.glassesTypePrice},getUpgradeLens(e){return e.upgrade_lens},getIsUpgradeSelected(e){return e.is_upgrade_selected}},vT=async(e,t)=>{const{data:n}=await xr(`https://${se()}/api/products/glasses?sku=${e}&config_id=${t}`,"$ONeB9n1ra9");return(n==null?void 0:n.value)||null},af=async(e,t)=>$fetch(`https://${se()}/api/products/glasses?sku=${e}&config_id=${t}`,{method:"GET"}).then(n=>n).catch(n=>{console.log(n)}),_T=async(e,t)=>{const n=r=>{const s=String(r??"").trim();return s===""||s==="--"||s==="None"||s==="-None"},i=Object.entries(t||{}).filter(([,r])=>!n(r)).map(([r,s])=>`&${r.toLowerCase()}=${String(s).trim()}`).join("");return $fetch(`https://${se()}/api/glasses/generic?sku=${e}${i}`,{method:"GET"}).then(r=>r).catch(r=>{console.log(r)})},wT=async e=>$fetch(`https://${se()}/api/products/glasses/recently-viewed`,{method:"POST",body:e}).then(t=>t).catch(t=>{console.log(t)}),ET=async e=>$fetch(`https://${se()}/api/coupons/detail/${e}`,{method:"GET"}).then(t=>t).catch(t=>{console.log(t)}),Vd=async e=>$fetch(`https://${se()}/api/products/express?product_group=${e}`,{method:"GET",credentials:"include"}).then(t=>t).catch(t=>{console.log(t)}),ST=async e=>$fetch(`https://${se()}/api/customer/rx-files`,{method:"GET",credentials:"include"}).then(t=>t).catch(t=>{console.log(t)}),CT=async e=>$fetch(`https://${se()}/api/products/bulk/glasses`,{method:"POST",body:{glasses:e}}).then(t=>t).catch(t=>{console.log(t)}),IT=async(e,t)=>$fetch(`https://${se()}/api/products/glasses/similars?sku=${e}&config_id=${t}`,{method:"GET"}).then(n=>n).catch(n=>{console.log(n)}),Ws=async(e,t,n,i,r)=>$fetch(`https://${se()}/api/products/lenses`,{method:"POST",credentials:"include",body:{prod_group:e,lens_color:t,rx_options:n,sku:i,rx_limit:r}}).then(s=>s).catch(s=>{console.log(s)}),TT=async e=>$fetch(`https://${se()}
75/api/cart/glasses/details/${e}`,{method:"GET"}).then(t=>t).catch(t=>{console.log(t)}),PT=async()=>$fetch(`https://${se()}/api/products/bitz`,{method:"GET"}).then(e=>e).catch(e=>{console.log(e)}),OT=async e=>$fetch(`https://${se()}/api/glasses/rx-verification`,{method:"POST",body:e}).then(t=>t).catch(t=>{console.log(t)}),of=async e=>$fetch(`https://${se()}/api/products/add`,{method:"POST",credentials:"include",body:e}).then(t=>t).catch(t=>{console.log(t)}),AT=async e=>$fetch(`https://${se()}/api/customer/login`,{method:"POST",credentials:"include",body:e}).then(t=>t).catch(t=>{console.log(t)}),kT=async e=>$fetch(`https://${se()}/api/products/upload`,{method:"POST",credentials:"include",body:e}).then(t=>t).catch(t=>{console.log(t)}),RT=async()=>$fetch(`https://${se()}/api/products/uploads`,{method:"GET",credentials:"include"}).then(e=>e).catch(e=>{console.log(e)}),LT=async e=>$fetch(`https://${se()}/api/products/upload/delete`,{method:"POST",credentials:"include",body:e}).then(t=>t).catch(t=>{console.log(t)}),Na=(e,t,n,i="normal")=>{const r=it.get("savedRxParamsGL"),s=r?JSON.parse(r):{},a=l=>{switch(l){case"-0.00":return"0.00";case"-PL":case"PL":return"0.00";case"-Plano":case"Plano":return"0.00";case"-None":case"None":return"";case"--":return"";default:return l}},o={...s,lastProduct:{sku:e.product_sku},rxType:t.lensType.cookieValue,OD:{sph:a(n.SPH_OD),cyl:a(n.CYL_OD),axis:a(n.AXIS_OD),add:a(n.ADD_OD)},OS:{sph:a(n.SPH_OS),cyl:a(n.CYL_OS),axis:a(n.AXIS_OS),add:a(n.ADD_OS)},lens:{sku:t.lensTechnology.value},coatings:{}};i==="singlePD"&&(delete o.multiPD,o.singlePD={value:n.SINGLE_PD,type:"manual"}),i==="multiPD"&&(delete o.singlePD,o.multiPD={value:{PD_OD:n.PD_OD,PD_OS:n.PD_OS},type:"manual"}),it.set("savedRxParamsGL",JSON.stringify(o),{expires:365})},NT=async(e,t,n)=>$fetch(`https://${se()}/api/products/glasses/express-lenses`,{method:"POST",body:{rx_options:e,prod_group:t,lens_color:"CLEAR",sku:n}}).then(i=>i).catch(i=>{console.log(i)}),DT=async(e,t)=>{const{serviceApi:n}=Be().public;try{return await $fetch(`${Bt()}${n}/optician-ai/configurator-chat`,{method:"POST",body:{messages:e},signal:t})}catch(i){throw console.error("AI Service Error:",i),i}},xT=async e=>{const{serviceApi:t}=Be().public;try{return await $fetch(`${Bt()}${t}/optician-ai/lens-reasoning`,{method:"POST",body:{messages:e}})}catch(n){throw console.error("AI Service Error:",n),n}},MT=async e=>{const{appKey:t}=Be().public;return await $fetch(`https://product-api.fittingbox.com/glasses-metadata/availability?apiKey=${t}&uidList=${[e].join(",")}`).then(n=>n)},FT=async(e,t)=>$fetch(`https://${se()}/api/glasses/upgrade-lens?existing_lens=${e}&variation=${t}`,{method:"GET"}).then(n=>n).catch(n=>{console.log(n)}
75),Bd=[{id:"clear",label:"Clear lens",swatchColor:"#EDEFF1",lensOption:{value:"clear",displayName:"Clear",type:"",backendValue:"CLEAR"}},{id:"transitions_grey",label:"Grey Transitions® Gen S lens",swatchColor:"#76787D",lensOption:{value:"light_transitioning",displayName:"Light Transitioning",type:"",backendValue:"PHOTOCHROMIC"},technologyColorMatch:"grey",flowMode:"rxThenReview"},{id:"transitions_brown",label:"Brown Transitions® Gen S lens",swatchColor:"#7A5230",lensOption:{value:"light_transitioning",displayName:"Light Transitioning",type:"",backendValue:"PHOTOCHROMIC"},technologyColorMatch:"brown",flowMode:"rxThenReview"},{id:"gradient_clear",label:"Brown-Clear Gradient lens",swatchGradient:"linear-gradient(180deg, #A36A56 0%, #E8C7B4 51.92%, #F8ECE6 100%)",lensOption:{value:"tinted_gradient_clear",displayName:"Gradient Brown-Clear",type:"tinted_sun_lenses",backendValue:"TINTEDGRBROWNCLR"}}],$d=[{id:"tinted_grey",label:"Grey lens",swatchColor:"#76787D",lensOption:{value:"tinted_grey",displayName:"Tinted Grey",type:"tinted_sun_lenses",backendValue:"TINTEDPLGREY"},flowMode:"rxThenReview"},{id:"tinted_brown",label:"Brown lens",swatchColor:"#7A5230",lensOption:{value:"tinted_brown",displayName:"Tinted Brown",type:"tinted_sun_lenses",backendValue:"TINTEDPLBROWN"},flowMode:"rxThenReview"},{id:"polarized_grey",label:"Grey Polarized lens",swatchColor:"#5B5D61",lensOption:{value:"polarized_grey",displayName:"Polarized Grey",type:"polarized_sun_lenses",backendValue:"POLARIZEDGREY"},flowMode:"rxThenReview"},{id:"polarized_brown",label:"Brown Polarized lens",swatchColor:"#5C3A1E",lensOption:{value:"polarized_brown",displayName:"Polarized Brown",type:"polarized_sun_lenses",backendValue:"POLARIZEDBROWN"},flowMode:"rxThenReview"},{id:"polarized_green",label:"Green Polarized lens",swatchColor:"#3F5D45",lensOption:{value:"polarized_green",displayName:"Polarized Green",type:"polarized_sun_lenses",backendValue:"POLARIZEDGREEN"},flowMode:"rxThenReview"},{id:"transitions_grey",label:"Grey Transitions® Gen S lens",swatchColor:"#76787D",lensOption:{value:"light_transitioning",displayName:"Light Transitioning",type:"",backendValue:"PHOTOCHROMIC"},technologyColorMatch:"grey",flowMode:"rxThenReview"},{id:"transitions_brown",label:"Brown Transitions® Gen S lens",swatchColor:"#7A5230",lensOption:{value:"light_transitioning",displayName:"Light Transitioning",type:"",backendValue:"PHOTOCHROMIC"},technologyColorMatch:"brown",flowMode:"rxThenReview"}],VT={GL28472:Bd,GL28473:Bd,GL28872:$d,GL28873:$d},BT={transitions_grey:"pangolin-3-soren-transitions-grey.jpg",transitions_brown:"pangolin-3-soren-transitions-brown.jpg",polarized_grey:"pangolin-3-soren-polarized-grey.jpg",polarized_brown:"pangolin-3-soren-polarized-brown.jpg",polarized_green:"pangolin-3-soren-polarized-green.jpg",tinted_grey:"pangolin-3-soren-polarized-grey.jpg",tinted_brown:"pangolin-3-soren-polarized-brown.jpg"},$T={transitions_grey:"pangolin-3-odin-transitions-grey.jpg",transitions_brown:"pangolin-3-odin-transitions-brown.jpg",polarized_grey:"pangolin-3-odin-polarized-grey.jpg",polarized_brown:"pangolin-3-odin-polarized-brown.jpg",polarized_green:"pangolin-3-odin-polarized-green.jpg",tinted_grey:"pangolin-3-odin-polarized-grey.jpg",tinted_brown:"pangolin-3-odin-polarized-brown.jpg"},UT={GL28472:{clear:"pangolin-3-soren-clear.jpg",transitions_grey:"pangolin-3-soren-transitions-grey.jpg",transitions_brown:"pangolin-3-soren-transitions-brown.jpg",gradient_blue:"pangolin-3-soren-gradient-brown-blue.jpg",gradient_pink:"pangolin-3-soren-gradient-brown-pink.jpg",gradient_clear:"pangolin-3-soren-gradient-brown-clear.jpg"},GL28473:{clear:"pangolin-3-odin-clear.jpg",transitions_grey:"pangolin-3-odin-transitions-grey.jpg",transitions_brown:"pangolin-3-odin-transitions-brown.jpg",gradient_blue:"pangolin-3-odin-gradient-brown-blue.jpg",gradient_pink:"pangolin-3-odin-gradient-brown-pink.jpg",gradient_clear:"pangolin-3-odin-gradient-brown-clear.jpg"},GL28872:BT,GL28873:$T},Yt=e=>{const t=VT[e];if(!t)return null;const n=UT[e];return n?t.map(i=>{if(!n[i.id])return i;const r=`images/pangolin/${n[i.id]}`,s=r.replace(/\.jpg$/i,"-side.jpg"),a=r.replace(/\.jpg$/i,"-profile.jpg");return{...i,image:r,imageSide:s,imageProfile:a}}):t},HT=["clear","tinted_grey"],SX=e=>!!e&&!!e.image&&!HT.includes(e.id),zT=["clear","tinted_grey"],KT=e=>
75!e||zT.includes(e.id),CX=["clear","tinted_grey","tinted_brown"],lf=["tinted_grey","tinted_brown"],Ud=e=>lf.includes(e==null?void 0:e.id),cf={tinted_grey:{plano:"TINTEDPLGREY",power:"TINTEDGREY"},tinted_brown:{plano:"TINTEDPLBROWN",power:"TINTEDBROWN"}},IX=(e,t)=>{var i;const n=cf[e==null?void 0:e.id];return n?(t==null?void 0:t.value)==="non-prescription"?n.plano:n.power:(i=e==null?void 0:e.lensOption)==null?void 0:i.backendValue},Hd=e=>{const t=Object.values(cf).find(n=>n.plano===e||n.power===e);return t?t.plano:e},GT=(e,t,n)=>{const i=Yt(e);if(!i||!(t!=null&&t.backendValue))return null;const r=Hd(t.backendValue),s=i.filter(a=>Hd(a.lensOption.backendValue)===r);return s.length<=1?s[0]||null:s.find(a=>a.technologyColorMatch&&new RegExp(a.technologyColorMatch,"i").test(n||""))||null},TX=(e,t,n,i)=>!t||t.id==="clear"?null:GT(e,n,i),jT=(e,t)=>{const n=e||[],i=s=>/GEN\s*S/i.test(s.display_name||""),r=s=>!t.technologyColorMatch||new RegExp(t.technologyColorMatch,"i").test(s.display_name||"");return n.find(s=>i(s)&&r(s))||n.find(s=>i(s))||n.find(s=>s.is_recommended&&r(s))||n.find(s=>s.is_recommended)||n[0]||null},Il={transitions_brown:{sph:[-4,4],cyl:[-3,3]},tinted_grey:{sph:[-3.5,1],cyl:[-2,0]},tinted_brown:{sph:[-3.5,1],cyl:[-2,0]}},YT=["Single Vision","Anti-Fatigue"],PX=(e,t,n)=>!!Yt(e)&&!!Il[t==null?void 0:t.id]&&YT.includes(n==null?void 0:n.backendValue)&&(n==null?void 0:n.value)!=="non-prescription",OX=e=>Il[e]||null,df=e=>{const t=parseFloat(e);return Number.isNaN(t)?0:t},WT=(e,t,n)=>{const i=Il[e];if(!i)return!1;const r=t.startsWith("SPH_"),s=t.startsWith("CYL_");if(!r&&!s)return!1;const[a,o]=r?i.sph:i.cyl,l=df(n);return l<a||l>o},QT=["SPH_OD","SPH_OS","CYL_OD","CYL_OS"],AX=(e,t)=>QT.some(n=>WT(e,n,t==null?void 0:t[n])),ZT=3.5,kX=(e,t,n)=>!!Yt(e)&&lf.includes(t==null?void 0:t.id)&&["simple-readers","progressive-readers"].includes(n==null?void 0:n.value),qT=(e,t)=>
75e.startsWith("ADD_")?df(t)>ZT:!1,JT=["ADD_OD","ADD_OS"],RX=e=>JT.some(t=>qT(t,e==null?void 0:e[t])),XT=["kits.com","kits.ca"],e2=["metal","titanium","stainless steel"],t2=55,Tl={plain:[{index:"1.59",range:[-4.5,4.5]},{index:"1.67",range:[-10,6]},{index:"1.74",range:[-10,-3.5]}],safety:[{index:"1.59",range:[-4.5,4.5]}]},n2=e=>{var t;return!!((t=e==null?void 0:e.collections)!=null&&t.some(n=>n.collection_name==="rimless"))},s2=e=>{var t;return!!((t=e==null?void 0:e.collections)!=null&&t.some(n=>n.collection_id===t2))},i2=()=>XT.includes(ht(se())),ta=e=>!i2()||!e2.includes(e==null?void 0:e.material)||n2(e)?null:s2(e)?"safety":"plain",r2=e=>!!ta(e)&&!Yt(e==null?void 0:e.product_sku),a2=(e,t)=>(e==null?void 0:e.product_group)!=="Sunglasses"?"CLEAR":t==="Single Vision"?"TINTEDBROWN":"POLARIZEDBROWN",o2=["OD","OS"],l2=e=>{const t=String(e??"").trim();return t===""||t==="--"||t==="None"||t==="-None"},zd=e=>{const t=parseFloat(e);return Number.isNaN(t)?0:t},c2=(e,t)=>l2(e==null?void 0:e[`SPH_${t}`])?null:zd(e[`SPH_${t}`])+zd(e[`CYL_${t}`]),d2=e=>{const t=[];for(const n of o2){const i=c2(e,n);i!==null&&t.push(i)}return t},uf=(e,t)=>{var n,i;return((i=(n=Tl[t])==null?void 0:n.find(r=>r.index===e))==null?void 0:i.range)??null},u2=(e,t)=>!!uf(e,t),Lo=(e,t,n)=>{const i=uf(e,t);if(!i)return!1;const[r,s]=i;return d2(n).every(a=>a>=r&&a<=s)},LX=(e,t)=>{const n=ta(e);if(!n)return null;const[i,...r]=Tl[n];if(Lo(i.index,n,t))return null;const s=r.find(a=>Lo(a.index,n,t));return(s==null?void 0:s.index)??null},h2=e=>{if(e.some(n=>n.is_recommended))return e;const t=e.find(n=>!n.is_unavailable);return t?e.map(n=>n.sku===t.sku?{...n,is_recommended:!0}:n):e},hf=(e,t,n)=>{var s,a;const i=ta(t);if(!i)return e;const r=[];for(const o of e??[]){const l=wl((a=(s=o.pos_list)==null?void 0:s.good_points)==null?void 0:a[0]);if(!l){r.push(o);continue}if(u2(l,i)){if(Lo(l,i,n)){r.push(o);continue}r.push({...o,is_unavailable:!0,is_recommended:!1,price:0})}}return h2(r)},p2=e=>!e.is_unavailable&&!XI.includes(e.sku),f2=(e,t,n)=>{const r=hf(e,t,n).filter(p2).map(s=>s.price);return r.length?Math.min(...r):null},NX=e=>{const t=Tl[e];return t?Math.max(...t.map(({range:n})=>n[1])):null},m2={async fetchGlassesProduct(e,t){e=e.replace(".html",""),t||(t="");const n=ie();try{n.systemStore.setLoadingFetchData(!0),n.systemStore.setIsProductNotFound(!1);const i=await vT(e,t);if(i.success)n.glassesStore.fetchSimilarFrames(e,t),this.frameDetails=i.data,this.clearForeignPreselectedLensTint(i.data.product_sku),this.lightWeightCollection=Id(e);else{const r=It(),s=r.pathname;let a=r.search,o=MC(s);return a&&(o.includes("?")&&(a=a.replace("?","&")),o=o+a),kr(o,{redirectCode:301})}}catch(i){console.error("Error",i)}finally{n.systemStore.setLoadingFetchData(!1)}},async fetchGlassesProductClient(e,t){const n=ie();e=e.replace(".html",""),t==null&&(t="");try{n.systemStore.setLoadingFetchData(!0),n.systemStore.setIsProductNotFound(!1);const i=await af(e,t);if(i.success)this.frameDetails=i.data,this.clearForeignPreselectedLensTint(i.data.product_sku),this.lightWeightCollection=Id(e),await n.glassesStore.fetchSimilarFrames(e,t);else if(n.systemStore.setIsProductNotFound(!0),!i)throw new Error(`Product with id ${productId} and config ${t} not found`)}catch(i){console.error("Error",i)}finally{n.systemStore.setLoadingFetchData(!1)}},async fetchSimilarFrames(e,t){e=e.replace(".html","");const n=ie();try{n.systemStore.setLoadingFetchSimilarFrames(!0);const i=await IT(e,t);i.success&&(this.productSimilarFrames=i.data)}catch(i){console.error(`No similar frames for product with id ${e} and config ${t}.`,i)}finally{n.systemStore.setLoadingFetchSimilarFrames(!1)}},async fetchGlassesBulk(e){try{const t=await CT(e);return t!=null&&t.success?t.data.glasses:(console.error("Failed to fetch bulk glasses products",e),[])}catch(t){return console.error("Error",t),[]}},async fetchLensesPrices(e,t){ie();try{const n=await _T(e,t);if(n.success)this.lensesPrices=n.data,t==null&&(this.defaultLensesPrices=n.data);else if(!n)throw new Error("No lenses prices were found.")}catch(n){console.error("Error",n)}},setIsUploadRxSubmission(e){this.isUploadRxSubmission=e},restoreDefaultLensesPrices(){return this.defaultLensesPrices?(this.lensesPrices=this.defaultLensesPrices,!0):!1},async fetchRecentlyViewed(e){ie();try{const t=await wT(e);if(t.success){const n=e.products.reduce((i,r)=>(i[r.config]=r.readersType,i),{});this.recentlyViewedFrames=t.data.products.map(i=>({...i,readersType:n[i.config_id]??""}))}
75else if(!t)throw new Error("No lenses recently viewed found")}catch(t){console.error("Error",t)}},async fetchCouponDetails(e){ie();try{const t=await ET(e);if(t.success)this.couponDetails=t.data;else if(!t)throw new Error("No lenses recently viewed found")}catch(t){console.error("Error",t)}},async fetchProductCustomerExpressCheckout(e){const t=ie();t.systemStore.setCustomerExpressCheckoutLoading(!0);try{const n=await Vd(e.product_group);if(n.success){const i=n.data;if(i===null){t.systemStore.addToastMessage("ERROR","You don't have a saved prescription. Continue configuring your prescription manually and you'll be able to use it for future purchases");return}const r=i.PD&&i.PD_OS?(Number(i.PD)+Number(i.PD_OS)).toString():i.PD||i.PD_OS;if(YI(r,e)){t.systemStore.addToastMessage("ERROR",`Unfortunately the PD from the previous order (${r}mm) doesn't fall in the range of PDs accepted by this frame (${e.min_pd} - ${e.max_pd}).`);return}this.isDoublePdActive=i.pd_type==="double",this.selectedRxOptions={...this.selectedRxOptions,SINGLE_PD:this.isDoublePdActive?"":i.PD,PD_OS:i.PD_OS,PD_OD:this.isDoublePdActive?i.PD:"",SPH_OS:i.SPH_OS,SPH_OD:i.SPH_OD,CYL_OS:i.CYL_OS,CYL_OD:i.CYL_OD,AXIS_OS:i.AXIS_OS,AXIS_OD:i.AXIS_OD,ADD_OS:i.ADD_OS,ADD_OD:i.ADD_OD};const s=DC(i.rx_type),a=this.resolveIndexSku(i.lens_sku),o=NC(a),l=xC(o.value);await this.fetchLensFlowTechnology(s.prodGroup,o.backendValue,this.selectedRxOptions);const c=this.lensTechnologies.find(u=>u.sku===a);let d={value:"",parentValueName:""};s.type!=="progressives"?o.value==="blue_light_simple"||o.value==="blue_light_plus"?d={...d,value:"blue_light",parentValueName:""}:d={...d,value:o.value,parentValueName:""}:d={...d,value:o.value,parentValueName:""},this.lensFlowSelectedOptions={...this.lensFlowSelectedOptions,lensType:{...this.lensFlowSelectedOptions.lensType,value:i.rx_type,displayName:s.displayName,type:s.type,backendValue:s.prodGroup,parentValueName:"",cookieValue:s.cookieValue},lensOption:{...this.lensFlowSelectedOptions.lensOption,value:d.value,backendValue:o.backendValue,displayName:o.displayName,type:l!==""?l:o.value,parentValueName:""},lensTechnology:{...this.lensFlowSelectedOptions.lensTechnology,value:a,displayName:c.display_name,comment:c.comments.length>0?c.comments[0]:""}},this.currentLensStep="lensReview",Un("express_lensflow","glassesFlowWithEccomerceData"),Un("choose_previous_rx","glassesFlowEnterRxData")}else throw new Error("Couldn't fetch customer express checkout.")}catch(n){console.error("Error",n)}finally{t.systemStore.setCustomerExpressCheckoutLoading(!1)}},async fetchProductCustomerSavedPrescription(e){const t=ie();t.systemStore.setCustomerSavedPrescriptionLoading(!0);try{const n=await Vd(e);if(n.success){const i=n.data;if(i===null){t.systemStore.addToastMessage("ERROR","You don't have a saved prescription. Continue configuring your prescription manually and you'll be able to use it for future purchases");return}if(this.lensFlowSelectedOptions.lensType.value!==i.rx_type){t.systemStore.addToastMessage("ERROR","You don't have a saved prescription for this type of glasses. Continue configuring your prescription manually and you'll be able to use it for future purchases");return}this.setDoublePdActive(i.pd_type==="double"),this.selectedRxOptions={...this.selectedRxOptions,SINGLE_PD:this.isDoublePdActive?"62.0":i.PD,PD_OS:i.PD_OS,PD_OD:this.isDoublePdActive?i.PD:"",SPH_OS:i.SPH_OS,SPH_OD:i.SPH_OD,CYL_OS:i.CYL_OS,CYL_OD:i.CYL_OD,AXIS_OS:i.AXIS_OS,AXIS_OD:i.AXIS_OD,ADD_OS:i.ADD_OS,ADD_OD:i.ADD_OD},Na(this.frameDetails,this.lensFlowSelectedOptions,this.selectedRxOptions),t.systemStore.addToastMessage("SUCCESS",this.$i18n.t("toast.glasses.prescription-saved"))}else throw new Error("Couldn't fetch customer's saved prescription.")}catch(n){console.error("Error",n),t.systemStore.addToastMessage("ERROR",responseAddToCart.error)}finally{t.systemStore.setCustomerSavedPrescriptionLoading(!1)}},async fetchPreviousPrescriptions(e){const t=ie();t.systemStore.setCustomerSavedPrescriptionLoading(!0);try{const n=await ST(e);if(n.success){const i=n.data.files;this.previousPrescriptions=i}else throw new Error("Couldn't fetch customer's saved prescriptions.")}catch(n){console.error("Error",n)}finally{t.systemStore.setCustomerSavedPrescriptionLoading(!1)}},async fetchCheapestSellableLensPrices(e,t){try{const n=await Promise.all(t.map(({prod_group:r,lens_color:s})=>Ws(r,s,this.selectedRxOptions,e,!1))),i={};for(const[r,{key:s}]of t.entries()){const a=n[r];a!=null&&a.success&&(i[s]=f2(a.data,this.frameDetails,this.selectedRxOptions))}return i}catch(n){return console.error("Error",n),{}}},async fetchLensFlowTechnology(e,t,n,i){const r=ie(),s=!this.isUploadRxSubmission&&Cl(this.frameDetails)&&sT(n);try{r.systemStore.setLensTechLoading(!0);const[a,o]=await Promise.all([Ws(e,t,n,i,s),s?Ws(e,t,n,i,!1):null]);if(a.success){const l=o!=null&&o.success?iT(a.data,o.data):a.data;this.lensTechnologies=hf(l,this.frameDetails,n)}else console.error("Error",a.error)}catch(a){console.error("Error",a)}finally{r.systemStore.setLensTechLoading(!1)}},async fetchMultipleLensFlowTechnologies(e,t,n){const i=ie();try{i.systemStore.setLensTechLoading(!0);const r=e.flatMap(({prod_group:d,lens_colors:u})=>u.map(p=>(async()=>{const h=await Ws(d,p,t,n,!1);return h.data.forEach(m=>{m.lens_color=p}),{...h}})())),s=await Promise.all(r),a=s.filter(d=>d.success).flatMap(d=>d.data),o=s.filter(d=>!d.success);o.length&&console.error("Some prod_groups failed",o);const c=a.filter(d=>this.expectedLensSkus.expectedSkus.includes(d.sku)).map(d=>({...d,is_recommended:d.sku===this.expectedLensSkus.recommendedSku}));this.lensTechnologies=c}catch(r){console.error("Error",r)}finally{i.systemStore.setLensTechLoading(!1)}},async fetchProductsBitz(){ie();try{const e=await PT();if(e.success)this.bitzCharms=e.data.items,e.data.items.length>0&&(this.selectedCharmOption=e.data.items[0].sku);else if(!responseGlassesProduct)throw new Error("No products bitz founded for product.")}catch(e){console.error("Error",e)}finally{}},async fetchCases(e){const t=ie();this.loadingCase=!0;try{const n=await TT(e);
75n.success?this.frameCases=n.felt_cases:t.systemStore.addToastMessage("ERROR",n.error)}catch(n){console.error("Error: ",n)}finally{this.loadingCase=!1}},fetchGlassesRxOptionsFromCookie(e){const t=it.get("savedRxParamsGL"),n=t?JSON.parse(t):null;if(n){switch(e){case"anti-fatigue":case"distance":this.selectedRxOptions={...this.selectedRxOptions,SPH_OS:n.OS.sph,SPH_OD:n.OD.sph,CYL_OS:n.OS.cyl,CYL_OD:n.OD.cyl,AXIS_OS:n.OS.axis,AXIS_OD:n.OD.axis,ADD_OS:"--",ADD_OD:"--"};break;case"progressives":case"progressive":case"progressive2":this.selectedRxOptions={...this.selectedRxOptions,SPH_OS:n.OS.sph,SPH_OD:n.OD.sph,CYL_OS:n.OS.cyl,CYL_OD:n.OD.cyl,AXIS_OS:n.OS.axis,AXIS_OD:n.OD.axis,ADD_OS:n.OS.add,ADD_OD:n.OD.add};break;case"simple-readers":this.selectedRxOptions={...this.selectedRxOptions,SPH_OS:"--",SPH_OD:"--",CYL_OS:"--",CYL_OD:"--",AXIS_OS:"--",AXIS_OD:"--",ADD_OS:"--",ADD_OD:"--"};break;case"prescription-readers":this.selectedRxOptions={...this.selectedRxOptions,SPH_OS:n.OS.sph,SPH_OD:n.OD.sph,CYL_OS:n.OS.cyl,CYL_OD:n.OD.cyl,AXIS_OS:n.OS.axis,AXIS_OD:n.OD.axis,ADD_OS:n.OS.add,ADD_OD:n.OD.add};break}n.singlePD&&n.singlePD.type==="manual"&&(this.setDoublePdActive(!1),this.selectedRxOptions={...this.selectedRxOptions,SINGLE_PD:n.singlePD.value}),n.multiPD&&n.multiPD.type==="manual"&&(this.setDoublePdActive(!0),this.selectedRxOptions={...this.selectedRxOptions,PD_OD:n.multiPD.value.PD_OD,PD_OS:n.multiPD.value.PD_OS})}},async addGlassesToCart(e,t="Source not known"){const n=ie();try{n.systemStore.setLoadingAddToCart(!0);let i=n.glassesStore.getLensFlowSelectedOptions.lensOption.backendValue;e.products.forEach(s=>{s.options.lens_type=i}),sessionStorage.getItem("link_coupon")&&(e.coupon_code=sessionStorage.getItem("link_coupon")),e.add_to_cart_source=t;const r=await of(e);if(r.success){const s=r.ga_data.gtfour;t==="Sunglasses PDP"&&(s.ecommerce.items[0].glassesType="Non-prescription");try{dataLayer.push(s)}catch{console.log("Datalayer not found addToCart",s)}sessionStorage.removeItem("link_coupon");let a=`${Ae()}${r.redirect_url}`;window.location.href=a}else n.systemStore.addToastMessage("ERROR",r.error)}catch(i){console.error("Error",i),n.systemStore.setLoadingAddToCart(!1)}finally{}},async loginLensFlow(e){const t=ie();try{const n=await AT(e);if(n.success)return t.systemStore.setUserAsLoggedIn(),t.systemStore.addToastMessage("SUCCESS","Successfully logged in"),n.success;t.systemStore.addToastMessage("ERROR",n.error)}catch(n){console.error("Error",n)}},async fetchUploadedRxFiles(){const e=ie();try{e.systemStore.setLoadingUploadedRxFiles(!0);const t=await RT();t.success?this.uploadedRxFiles=t.data.rx_user_uploads:console.error("ERROR",t.error)}catch(t){console.error("Error",t)}finally{e.systemStore.setLoadingUploadedRxFiles(!1)}},async uploadGlassesRxFile(e){const t=ie();try{const n=await kT(e);n.success?(this.uploadedRxFiles=n.data.rx_user_uploads,t.systemStore.addToastMessage("SUCCESS",this.$i18n.t("toast.glasses.upload-success"))):t.systemStore.addToastMessage("ERROR",n.error)}catch(n){console.error("Error",n)}},async deleteUploadedRxFile(e){const t=ie();try{const n=await LT(e);n.success?(this.uploadedRxFiles=n.data.rx_user_uploads,t.systemStore.addToastMessage("SUCCESS",this.$i18n.t("toast.glasses.file-deleted"))):t.systemStore.addToastMessage("ERROR",n.error)}catch(n){console.error("Error",n)}},async fetchGlassesRXCheck(e){ie();try{return(await OT(e)).data}catch(t){console.error("Error",t)}},async fetchSuitableLensesExpress(e,t,n){ie();try{return(await NT(e,t,n)).data}catch(i){console.error("Error",i)}},async fetch3DAvailability(e){try{const t=await MT(e);this.VTO3DAvailability=t[0]}catch(t){console.error("Err",t)}},async sendRxFileToAI(e,t){var i,r;const n=ie();if(!e)return{success:!1,message:"No file provided."};try{const s=VC(e),o=await DT([{role:"user",content:[{type:"input_text",text:"I want you to read my uploaded file and save my rx options from it"}]},s],t);if(e.format!=="pdf"&&e.format!=="png"&&e.format!=="jpeg"&&e.format!=="gif"&&e.format!=="webp")throw new Error("file formats supported are pdf, png, jpeg, gif or webp");const l=(i=o.output)==null?void 0:i[0];if(l.name===void 0)return{success:!1,message:"Unable to read the prescription. Please re-upload and try again."};if((l==null?void 0:l.name)==="save_rx_options_from_photo"){const c=JSON.parse(l.arguments),d=String(c.PD_OD||"").trim(),u=String(c.PD_OS||"").trim(),p=QI({PD_OD:d,PD_OS:u});this.saveRxOptions(p.PD_OD,"PD_OD"),this.saveRxOptions(p.PD_OS,"PD_OS");let h={};
75Object.entries(c).forEach(([E,y])=>{if(E==="PD_OD"||E==="PD_OS")return;if(E==="hasPrism"){this.setRxHasPrism(y);return}if(E.includes("ACCURACY")){this.saveRxOptionsConfidence(y,E);return}const P=`${E}_ACCURACY`,A=c[P];let I="--";if(y==="PL"||y==="Plano")I=y;else{const D=Number(y);!isNaN(D)&&y!==""&&(E==="AXIS_OS"||E==="AXIS_OD"?I=D:E==="PD_OD"||E==="PD_OS"?I=D.toFixed(1):D>=.25?I=`+${D.toFixed(2)}`:I=D.toFixed(2))}if(A>85){const D=WI({key:E,value:I});h[D.key]=D.value}else Object.assign(h,{[E]:"--"})});let m=!1;["OD","OS"].forEach(E=>{const y=h[`CYL_${E}`],P=!y||y==="--"||y==="None"||y==="-None",A=h[`AXIS_${E}`];P&&(A!==void 0&&A!==""&&A!=="--"&&(m=!0),h[`AXIS_${E}`]="--")}),m&&n.systemStore.addToastMessage("INFO","AXIS requires a CYL value, so we cleared it for you."),this.selectedRxOptions={PD_OD:this.selectedRxOptions.PD_OD,PD_OS:this.selectedRxOptions.PD_OS,...h};const{PD_OD:v,PD_OS:_}=this.selectedRxOptions,b=[v,_].find(E=>E!=="--");this.selectedRxOptions.PD_OD!=="--"&&this.selectedRxOptions.PD_OS!=="--"?(n.glassesStore.setDoublePdActive(!0),Na(this.frameDetails,this.lensFlowSelectedOptions,this.selectedRxOptions,"multipd")):(n.glassesStore.setDoublePdActive(!1),this.saveRxOptions(b,"SINGLE_PD"),this.saveRxOptions("--","PD_OD"),Na(this.frameDetails,this.lensFlowSelectedOptions,this.selectedRxOptions,"singlePD"));const C=JI(this.selectedRxOptions),O=this.lensFlowSelectedOptions.lensType;let T=null;return this.lensFlowOptician||(/progressive/i.test(C.backendValue)&&!/progressive/i.test(O.backendValue)&&(T=await n.systemStore.showConfirmDialog({title:"Switch to progressives?",message:`
76                Your current selected glasses type is "single vision",
77                but during analysis we found out your glasses type is "progressives".
78                Would you like to switch to "progressives"?
79              `}),T||(this.selectedRxOptions.ADD_OD="--",this.selectedRxOptions.ADD_OS="--")),!/progressive/i.test(C.backendValue)&&/progressive/i.test(O.backendValue)&&(T=await n.systemStore.showConfirmDialog({title:"Switch to single vision?",message:`
80                Your current selected glasses type is "progressives", 
81                but during analysis we found out your glasses type is "single vision".
82
83                Would you like to switch to "single vision"?
84              `})),T&&this.setSelectedGlassesType(C.value,C.displayName,C.type,C.backendValue,C.cookieValue,C.parentValueName)),{success:!0,message:"Prescription successfully analyzed. Please double check it."}}return{success:!1,message:"The AI did not return Rx recognition output."}}catch(s){return((r=s==null?void 0:s.cause)==null?void 0:r.name)==="AbortError"?void 0:(console.error("Error in sendRxFileToAI:",s),n.systemStore.addToastMessage("ERROR",s),{success:!1,message:"Failed to analyze your prescription."})}},async fetchLensReasoning(e){const t=ie();try{return{success:!0,message:(await xT([{role:"user",content:[{type:"input_text",text:e}]}])).output[0].content[0].text}}catch(n){return console.error("Error in lense reasoning:",n),t.systemStore.addToastMessage("ERROR",n),{success:!1,message:"Failed to give you a proper explanation."}}},resolveIndexSku(e){var a,o;const t={LENSOPTI:"LENSOPTI4",LENSBLUEBASIC:"LENSBLUE3",LENSPROGBASIC:"LENSPROGSTD2",LENSPROGSTDBLUE4:"LENSPROGSTDBLUE3",LENSPHOTOGREY:"LENSPHOTOGREY2",LENSPHOTOBROWN2_SWATCH:"LENSPHOTOBROWN2",LENSPROGPHOTOGREY:"LENSPROGPHOTOGREY2",LENSPROGPTBROWN2_SWATCH:"LENSPROGPTBROWN2",LENSPROG2PHOTOGREY:"LENSPROG2PHOTOGREY2",LENSPROG2PTBROWN2_SWATCH:"LENSPROG2PTBROWN2"},n=(o=(a=this.frameDetails)==null?void 0:a.collections)==null?void 0:o.some(l=>l.collection_name==="rimless"),i=this.frameDetails.material==="metal"||this.frameDetails.material==="titanium"||this.frameDetails.material==="stainless steel";return(Number(this.selectedRxOptions.SPH_OS)>4||Number(this.selectedRxOptions.SPH_OS)<-4||Number(this.selectedRxOptions.SPH_OD)>4||Number(this.selectedRxOptions.SPH_OD)<-4||n||i)&&t[e]?t[e]:e},handleSetExpectedLensSkus(e){var c,d;if(!e||!Array.isArray(e.expectedSkus)){this.setExpectedLensSkus({expectedSkus:[],recommendedSku:""});return}const t={LENSOPTI:"LENSOPTI4",LENSBLUEBASIC:"LENSBLUE3",LENSPROGBASIC:"LENSPROGSTD2",LENSPROGSTDBLUE4:"LENSPROGSTDBLUE3",LENSPHOTOGREY:"LENSPHOTOGREY2",LENSPHOTOBROWN2_SWATCH:"LENSPHOTOBROWN2",LENSPROGPHOTOGREY:"LENSPROGPHOTOGREY2",LENSPROGPTBROWN2_SWATCH:"LENSPROGPTBROWN2",LENSPROG2PHOTOGREY:"LENSPROG2PHOTOGREY2",LENSPROG2PTBROWN2_SWATCH:"LENSPROG2PTBROWN2"},n=(d=(c=this.frameDetails)==null?void 0:c.collections)==null?void 0:d.some(u=>u.collection_name==="rimless"),i=this.frameDetails.material==="metal"||this.frameDetails.material==="titanium"||this.frameDetails.material==="stainless steel",s=Number(this.selectedRxOptions.SPH_OS)>4||Number(this.selectedRxOptions.SPH_OS)<-4||Number(this.selectedRxOptions.SPH_OD)>4||Number(this.selectedRxOptions.SPH_OD)<-4||n||i,a=u=>t[u]&&s?t[u]:u,o=e.expectedSkus.map(a),l=e.recommendedSku?a(e.recommendedSku):"";this.setExpectedLensSkus({expectedSkus:o,recommendedSku:l})},lensUpgradeHighSph(e){const t=Number(this.selectedRxOptions.SPH_OS)>4||Number(this.selectedRxOptions.SPH_OS)<-4||Number(this.selectedRxOptions.SPH_OD)>4||Number(this.selectedRxOptions.SPH_OD)<-4,n=wl(e);return t&&n==="1.50"},async useSavedLensFlowOpticianOptions(){var n,i;const e=it.get("lensFlowOpticianOptions");
84if(!e)return;let t;try{t=JSON.parse(e)}catch{it.remove("lensFlowOpticianOptions");return}this.setLensFlowOptician(!0),t!=null&&t.lensFlowSelectedOptions&&this.setLensFlowSelectedOptions(t.lensFlowSelectedOptions),t!=null&&t.opticianAnswers&&(this.setOpticianAnswers(t==null?void 0:t.opticianAnswers),this.resolveOpticianAnswers()),t!=null&&t.lensOptions&&this.setLensOptions(t.lensOptions),(n=t.lensFlowSelectedOptions)!=null&&n.lensType&&this.fetchGlassesRxOptionsFromCookie((i=t.lensFlowSelectedOptions)==null?void 0:i.lensType.type),this.setFlowStep("lensTechnologies")},resolveOpticianAnswers(){const{q1:e,q2:t}=this.opticianAnswers,n=e.answer!==""&&t.answer!=="",i=this.lensFlowSelectedOptions.lensType.value==="distance",r=this.lensFlowSelectedOptions.lensType.value==="simple-readers",s=this.lensFlowSelectedOptions.lensType.value==="progressive";if(!n)return;const a=`${e.answer}-${t.answer}`;if(i)switch(a){case"yes-no":this.setLensOptions([{lens_colors:["CLEAR","BLUELIGHT"],prod_group:this.lensFlowSelectedOptions.lensType.backendValue}]),this.handleSetExpectedLensSkus({expectedSkus:["LENSOPTI","LENSBLUE3"],recommendedSku:"LENSBLUE3"});break;case"no-yes":this.setLensOptions([{lens_colors:["CLEAR","PHOTOCHROMIC"],prod_group:this.lensFlowSelectedOptions.lensType.backendValue}]),this.handleSetExpectedLensSkus({expectedSkus:["LENSOPTI","LENSPHOTOGREY","LENSPHOTOBROWN2_SWATCH"],recommendedSku:"LENSPHOTOGREY"});break;case"yes-yes":this.setLensOptions([{lens_colors:["BLUELIGHT","PHOTOCHROMIC"],prod_group:this.lensFlowSelectedOptions.lensType.backendValue}]),this.handleSetExpectedLensSkus({expectedSkus:["LENSBLUEBASIC","LENSPHOTOGREY2","LENSPHOTOBROWN2"],recommendedSku:"LENSPHOTOGREY2"});break;case"no-no":this.setLensOptions([{lens_colors:["CLEAR"],prod_group:this.lensFlowSelectedOptions.lensType.backendValue}]),this.handleSetExpectedLensSkus({expectedSkus:["LENSOPTI","LENSULTRATHIN"],recommendedSku:"LENSULTRATHIN"});break}if(r)switch(a){case"yes-no":this.setLensOptions([{lens_colors:["CLEAR","BLUELIGHT"],prod_group:this.lensFlowSelectedOptions.lensType.backendValue}]),this.handleSetExpectedLensSkus({expectedSkus:["LENSOPTI","LENSBLUE3"],recommendedSku:"LENSBLUE3"});break;case"no-yes":this.setLensOptions([{lens_colors:["CLEAR"],prod_group:this.lensFlowSelectedOptions.lensType.backendValue},{lens_colors:["CLEAR"],prod_group:"Progressive"}]),this.handleSetExpectedLensSkus({expectedSkus:["LENSOPTI","LENSPROGBASIC"],recommendedSku:"LENSPROGBASIC"});break;case"yes-yes":this.setLensOptions([{lens_colors:["CLEAR"],prod_group:this.lensFlowSelectedOptions.lensType.backendValue},{lens_colors:["BLUELIGHT"],prod_group:"Progressive"}]),this.handleSetExpectedLensSkus({expectedSkus:["LENSOPTI","LENSPROGSTDBLUE4"],recommendedSku:"LENSPROGSTDBLUE4"});break;case"no-no":this.setLensOptions([{lens_colors:["CLEAR"],prod_group:this.lensFlowSelectedOptions.lensType.backendValue}]),this.handleSetExpectedLensSkus({expectedSkus:["LENSOPTI","LENSULTRATHIN"],recommendedSku:"LENSULTRATHIN"});break}if(s)switch(a){case"yes-no":this.setLensOptions([{lens_colors:["CLEAR"],prod_group:"Progressive"},{lens_colors:["BLUELIGHTPLUS"],prod_group:"Progressive2"}]),this.handleSetExpectedLensSkus({expectedSkus:["LENSPROGBASIC","LENSPROG2STDBLP2"],recommendedSku:"LENSPROG2STDBLP2"});break;case"no-yes":this.setLensOptions([{lens_colors:["CLEAR","PHOTOCHROMIC"],prod_group:"Progressive"}]),this.handleSetExpectedLensSkus({expectedSkus:["LENSPROGBASIC","LENSPROGPHOTOGREY","LENSPROGPTBROWN2_SWATCH"],recommendedSku:"LENSPROGPHOTOGREY"});break;case"yes-yes":this.setLensOptions([{lens_colors:["CLEAR"],prod_group:"Progressive"},{lens_colors:["BLUELIGHTPLUS","PHOTOCHROMIC"],prod_group:"Progressive2"}]),this.handleSetExpectedLensSkus({expectedSkus:["LENSPROGBASIC","LENSPROG2STDBLP2","LENSPROG2PHOTOGREY","LENSPROG2PTBROWN2_SWATCH"],recommendedSku:"LENSPROG2PHOTOGREY"});break;case"no-no":this.setLensOptions([{lens_colors:["CLEAR"],prod_group:"Progressive"}]),this.handleSetExpectedLensSkus({expectedSkus:["LENSPROGBASIC","LENSPROGSUPERTHIN"],recommendedSku:"LENSPROGSUPERTHIN"});break}Un("optician_lensflow_features","glassesFlowWithEccomerceData"),this.setFlowStep("lensTechnologies")},async fetchUpgradeLens(e,t){ie();try{const n=await FT(e,t);n.success&&(this.upgrade_lens=n.data)}catch(n){console.error("Error",n)}},setIsUpgradeSelected(e){this.is_upgrade_selected=e}
84,setIsErrorModalShowing(e){this.errorModalPD.isModalShowing=e},setPdMessage(e){this.pdMessage=e},setRxMessage(e){this.rxMessage=e},setIsPDWarning(e){this.isPDWarning=e},setIsPDOutOfRange(e){this.errorModalPD.isPDOutOfRange=e},setLensFlowActive(){this.lensFlowActive=!this.lensFlowActive},setStartLensFlowLoading(e){this.startLensFlowLoading=e},setPreselectedLensTint(e){this.preselectedLensTint=e},setPreselectedLensTintPrice(e){this.preselectedLensTintPrice=e},setPreselectedLensTintPriceLoading(e){this.preselectedLensTintPriceLoading=e},setPreselectedLensTintUnavailable(e){this.preselectedLensTintUnavailable=e},setPangolinGlassesTypePricesLoading(e){this.pangolinGlassesTypePricesLoading=e},clearForeignPreselectedLensTint(e){var i;const t=Yt(e),n=(i=this.preselectedLensTint)==null?void 0:i.id;n&&(t!=null&&t.some(r=>r.id===n))||(this.preselectedLensTint=null,this.preselectedLensTintPrice=0,this.preselectedLensTintPriceLoading=!1,this.preselectedLensTintUnavailable=!1,this.pangolinGlassesTypePricesLoading=!1)},async applyLockedLensTint(e){var a;this.resetRxOptions(),this.saveRxOptions("62.0","SINGLE_PD"),this.setSelectedGlassesType("non-prescription","Non-Prescription","non-prescription","Single Vision","non-prescription");const{value:t,displayName:n,type:i,backendValue:r}=e.lensOption;this.setSelectedLensOption(t,n,i,r),this.setPreselectedLensTintUnavailable(!1),await this.fetchLensFlowTechnology("Single Vision",r,this.selectedRxOptions,this.frameDetails.product_sku);const s=jT(this.lensTechnologies,e);if(!s){this.setFlowStep("lensTechnologies");return}this.setSelectedLensTechnology(s.sku,s.display_name,((a=s.comments)==null?void 0:a[0])||""),this.setLocalLensTechnology(s),this.setLensTechnologyPrice(s.price-this.glassesTypePrice),this.setPreselectedLensTintUnavailable(!!s.is_unavailable),this.setFlowStep("lensReview")},async startPreselectedLensTintFlow(){if(!Yt(this.frameDetails.product_sku))return!1;const e=this.preselectedLensTint,t=e&&e.id!=="clear"&&e.flowMode!=="rxThen
84Review";if(this.setGlassesTypePrice(0),this.setlLensOptionPrice(0),this.setLensTechnologyPrice(0),t){this.setStartLensFlowLoading(!0);try{await this.applyLockedLensTint(e)}catch{this.setStartLensFlowLoading(!1)}finally{this.setStartLensFlowLoading(!1)}return this.setLensFlowActive(),!0}return this.setResetCurrentLensStep(),this.resetRxOptions(),!1},setDidSelectExpress(e){this.didSelectExpress=e},setResetCurrentLensStep(){this.currentLensStep="glassesType",this.preselectedLensTintUnavailable=!1,this.lensFlowSelectedOptions={lensType:{value:"",displayName:"",type:"",backendValue:"",parentValueName:""},lensOption:{value:"",backendValue:"",backendColorValue:"",displayName:"",type:"",children:[],colorParent:"",parentValueName:""},lensTechnology:{value:"",displayName:"",comment:""}}},setRRContent(e){this.rr_reviews=e},setLensFlowOptician(e){this.lensFlowOptician=e},setLensPrescriptionStatus(e){this.lensPrescriptionStatus=e},setLensFlowSelectedOptions(e){this.lensFlowSelectedOptions=e},setSelectedGlassesType(e,t,n,i,r){this.lensFlowSelectedOptions.lensType.value=e,this.lensFlowSelectedOptions.lensType.displayName=t,this.lensFlowSelectedOptions.lensType.type=n,this.lensFlowSelectedOptions.lensType.backendValue=i,this.lensFlowSelectedOptions.lensType.cookieValue=r},setSelectedLensOption(e,t,n,i){this.lensFlowSelectedOptions.lensOption.value=e,this.lensFlowSelectedOptions.lensOption.displayName=t,this.lensFlowSelectedOptions.lensOption.type=n,this.lensFlowSelectedOptions.lensOption.backendValue=i},setLocalLensTechnology(e){this.localLensTechnology=e}
84,setSelectedLensTechnology(e,t,n){this.lensFlowSelectedOptions.lensTechnology.value=e,this.lensFlowSelectedOptions.lensTechnology.displayName=t,this.lensFlowSelectedOptions.lensTechnology.comment=n},resetSelectedLensTechnology(){this.lensFlowSelectedOptions.lensTechnology={value:"",displayName:"",comment:""}},resetSelectedGlassesType(){this.lensFlowSelectedOptions.lensType={value:"",displayName:"",parentValueName:"",type:"",backendValue:"",cookieValue:""},this.glassesTypePrice=0},resetSelectedLensOption(){this.lensFlowSelectedOptions.lensOption={value:"",backendValue:"",backendColorValue:"",displayName:"",type:"",children:[],colorParent:"",parentValueName:""}},setGlassTypeParentValue(e){this.lensFlowSelectedOptions.lensType.parentValueName=e},setGlassType(e){this.lensFlowSelectedOptions.lensType.type=e},setLensOptionParentValue(e){this.lensFlowSelectedOptions.lensOption.parentValueName=e},setFlowStep(e){this.currentLensStep=e,this.productShowCaseLearnMoreInfo=null},setProductShowcaseLearnMoreInfo(e){this.productShowCaseLearnMoreInfo=e},setRxMethod(e){this.showRxForm=e},setDoublePdActive(e){this.isDoublePdActive=e},saveRxOptions(e,t){this.selectedRxOptions[t]=e},saveRxOptionsConfidence(e,t){this.rxOptionsConfidence[t]=e},resetRxOptions(){this.selectedRxOptions.SPH_OS="--",this.selectedRxOptions.SPH_OD="--",this.selectedRxOptions.CYL_OS="--",this.selectedRxOptions.CYL_OD="--",this.selectedRxOptions.AXIS_OS="--",this.selectedRxOptions.AXIS_OD="--",this.selectedRxOptions.ADD_OS="--",this.selectedRxOptions.ADD_OD="--",this.selectedRxOptions.OC_OS="--",this.selectedRxOptions.OC_OD="--",this.selectedRxOptions.Seg_Height_OD="--",this.selectedRxOptions.Seg_Height_OS="--"},setRxAdditionalComments(e){this.rxAdditionalComments=e},resetLensFlowOptician(){this.lensFlowOptician=!1,this.lensPrescriptionStatus={},this.lensOptions=[],this.expectedLensSkus=[]},setRxSunUpsell(){this.isRxSunUpsell=!this.isRxSunUpsell},setProgressiveChoice(e){this.progressiveChoice=e},setLensFlowTotalSteps(e){this.lensFlowTotalSteps=e},setSelectedCharmOption(e){this.selectedCharmOption=e},setSelectedIndividualBitz(e){this.selectedIndividualBitz=e},setSelectedClipponSkus(e){this.selectedClipponSkus=e},setSelectedSlide(e){this.selectedSlide=e},setReviewUpsell(e){this.reviewUpsell=e},setTACOverlay(e,t){e==="kits"?this.tacOverlay.kits=t:e==="designer"&&(this.tacOverlay.designer=t)},resetLensTechnologies(){this.lensTechnologies=[]},setLensSku(){var i,r,s,a,o;const e=l=>{var d;if(l==null)return"";const c=((d=l==null?void 0:l.trim)==null?void 0:d.call(l))??l;return c!==""&&c!=="--"?c:""},t={lensColor:this.readers.lensColor,blueLightFilter:this.readers.blueLightFilter,polarized:this.readers.polarized,progressive:this.readers.progressive,isRimless:(r=(i=this.frameDetails)==null?void 0:i.collections)==null?void 0:r.some(l=>l.collection_name==="rimless"),isSafetyCollection:(s=this.frameDetails)==null?void 0:s.collections.some(l=>l.collection_id===55),lensPower:{OS:e((a=this.readers.lensPowerOD)==null?void 0:a.label),OD:e((o=this.readers.lensPowerOS)==null?void 0:o.label)}},n=jI(t);this.readers.lensSku=n},setLensPower(e){this.readers.lensPower=e},setLensPowerOS(e){this.readers.lensPowerOS=e},setLensPowerOD(e){this.readers.lensPowerOD=e},setBlueLightFilter(e){this.readers.blueLightFilter=e},setPolarized(e){this.readers.polarized=e},setLensColor(e){this.readers.lensColor=e},setProgressiveReaders(e){this.readers.progressive=e},setShowSelectPowerError(e){this.readers.showSelectPowerError=e},setIsAdvancedSelection(e){this.readers.isAdvancedSelection=e},setHasOpticianLoaded(e){this.hasOpticianLoaded=e},setMeasuredPdResults(e){this.measuredPdResults=e},setLensOptions(e){this.lensOptions=e},setLensTechnologies(e){this.lensTechnologies=e},setExpectedLensSkus(e){this.expectedLensSkus=e},setOpticianAnswers(e){this.opticianAnswers=e},setRxHasPrism(e){this.rxHasPrism=e},setRxConfidenceScore(e){this.rxConfidenceScore=e},setRxOptionsConfidence(e){this.rxOptionsConfidence=e},setIsVtoActive(e){this.isVtoActive=e},setShowChoosePrevious(e){this.showChoosePrevious=e},setIsScanActive(e){this.isScanActive=e},setUploadSelected(e){this.uploadSelected=e},setIsSameADDBothEyes(e){this.isSameADDBothEyes=e},setExpandedType(e){this.expandedType=e},setShowCaseDialog(e){this.showCaseDialog=e},setPickedCase(e){this.pickedCase=e},setlLensOptionPrice(e){this.lensOptionPrice=e},setLensTechnologyPrice(e){this.lensTechnologyPrice=e},setGlassesTypePrice(e){this.glassesTypePrice=e}},g2=Rt("glasses",{state:()=>yT,getters:bT,actions:m2}),y2={giftcardsData:{sku:"",name:"",description:"",enabled:0,price:0,product_images:[]}},b2={getGiftCardsData(e){return e.giftcardsData}
84},v2=async e=>{try{const{data:t}=await xr(`https://${se()}/api/products/vouchers?sku=${e}`,"$9KhdU7QexK");return t&&t.value?t.value:(console.error("Error fetching accessories data:",error.message),null)}catch(t){return console.error("Error fetching accessories data:",t.message),null}},_2=async e=>$fetch(`https://${se()}/api/products/add`,{method:"POST",credentials:"include",body:e}).then(t=>t).catch(t=>{console.log(t)}),w2={async fetchGiftcardsData(e){const t=ie();try{t.systemStore.setIsProductNotFound(!1),t.systemStore.setLoadingFetchData(!0);const n=await v2(e);n.success?this.giftcardsData=n.data:(console.error("Error",n.error),t.systemStore.setIsProductNotFound(!0))}catch(n){console.error("Error",n)}finally{t.systemStore.setLoadingFetchData(!1)}},async addGiftcardsToCart(e){const t=ie();try{t.systemStore.setLoadingAddToCart(!0);const n=await _2(e);if(n.success){let i=`${Ae()}${n.redirect_url}`;window.location.href=i}else t.systemStore.addToastMessage("ERROR",n.error)}catch(n){console.error("Error",n)}finally{t.systemStore.setLoadingAddToCart(!1)}}},E2=Rt("giftcards",{state:()=>y2,getters:b2,actions:w2}),S2={accessoriesData:{name:"",description:"",sku:"",product_images:[],price:0},quantity:1},C2={getAccessoriesData(e){return e.accessoriesData},getQuantity(e){return e.quantity}},I2=async e=>{const{data:t}=await xr(`https://${se()}/api/products/accessories?sku=${e}`,"$T54aw9L4Xz");return(t==null?void 0:t.value)||null},T2=async e=>$fetch(`https://${se()}/api/products/add`,{method:"POST",credentials:"include",body:e}).then(t=>t).catch(t=>{console.log(t)}),P2={async fetchAccessoriesData(e){const t=ie();try{t.systemStore.setIsProductNotFound(!1),t.systemStore.setLoadingFetchData(!0);const n=await I2(e);if(n.success)this.accessoriesData=n.data;else return kr("/accessories",{redirectCode:301})}catch(n){console.error("Error",n)}finally{t.systemStore.setLoadingFetchData(!1)}},async addAccessoryToCart(e,t=!0){const n=ie();try{n.systemStore.setLoadingAddToCart(!0);const i=await T2(e);if(i.success)if(t){let r=`${Ae()}${i.redirect_url}`;window.location.href=r}else n.systemStore.fetchGenericSiteMetadata();else n.systemStore.addToastMessage("ERROR",i.error)}catch(i){console.error("Error",i)}finally{n.systemStore.setLoadingAddToCart(!1)}},setQuantity(e){this.quantity=e}},O2=Rt("accessories",{state:()=>S2,getters:C2,actions:P2}),A2={insuranceProviders:[],isAnagramFormCompleted:!1,anagramDialog:!1,anagramBenefits:[]},k2={getInsuranceProviders(e){return e.insuranceProviders},getIsAnagramFormCompleted(e){return e.isAnagramFormCompleted},getAnagramDialog(e){return e.anagramDialog},getAnagramBenefits(e){return e.anagramBenefits}},R2=async()=>$fetch(`https://${se()}/api/anagram/insurance-providers`,{method:"GET"}).then(e=>e).catch(e=>{console.error(e)}),L2=async e=>$fetch(`https://${se()}/api/anagram/start-submission`,{method:"POST",credentials:"include",body:e}).then(t=>t).catch(t=>{console.error(t)}),N2=async()=>$fetch(`https://${se()}/api/anagram/cancel-submission`,{method:"POST",credentials:"include",body:{}}).then(e=>e).catch(e=>{console.error(e)}),D2=async()=>$fetch(`https://${se()}/api/anagram/continue-submission`,{method:"GET",credentials:"include"}).then(e=>e).catch(e=>{console.error(e)}),x2={async fetchInsuranceProviders(){const e=ie();try{const t=await R2();t.success?this.insuranceProviders=t.data:e.systemStore.addToastMessage("ERROR",t.error)}catch(t){console.error("Error",t)}},async fetchStartSubmission(e){const t=ie();t.systemStore.setLoadingAnagram(!0);try{const n=await L2(e);
84if(n.success)return n;n.error===" patient dob must be in the past"?t.systemStore.addToastMessage("ERROR","Patient date of birth must be in the past"):t.systemStore.addToastMessage("ERROR",n.error),t.systemStore.setLoadingAnagram(!1)}catch(n){console.error("Error",n),t.systemStore.setLoadingAnagram(!1)}},async fetchCancelSubmission(){const e=ie();try{const t=await N2();t.success?await e.systemStore.fetchGenericSiteMetadata():e.systemStore.addToastMessage("ERROR",t.error)}catch(t){console.error("Error",t)}},async fetchContinueSubmission(){const e=ie();try{const t=await D2();return t.success?t.data.status==="complete"?(e.systemStore.setLoadingAnagram(!1),e.anagramStore.setAnagramBenefits(t.data.anagram_benefits),t):t.data.status==="processing"?(await new Promise(n=>setTimeout(n,1e4)),e.anagramStore.fetchContinueSubmission()):(t.data.status==="error",e.systemStore.setLoadingAnagram(!1),e.systemStore.addToastMessage("ERROR",t.message),!1):(e.systemStore.setLoadingAnagram(!1),!1)}catch(t){return console.error("Error:",t),e.systemStore.setLoadingAnagram(!1),e.systemStore.addToastMessage("ERROR","An error occurred while fetching submission."),!1}},setIsAnagramFormCompleted(e){this.isAnagramFormCompleted=e},setAnagramDialog(e){this.anagramDialog=e},setAnagramBenefits(e){this.anagramBenefits=e}},M2=Rt("anagram",{state:()=>A2,getters:k2,actions:x2}),F2={kitsPixaGlasses:[]},V2={getPixaGlasses(e){return e.kitsPixaGlasses}},B2=async()=>$fetch(`https://${se()}/api/products/pixa`,{method:"GET"}).then(e=>e).catch(e=>{console.log(e)}),$2=async e=>$fetch(`https://${se()}/api/products/glasses/add`,{method:"POST",body:e,credentials:"include"}).then(t=>t).catch(t=>{console.log(t)}),U2={async fetchPixaGlasses(){const e=ie();try{const t=await B2();t.success&&(this.kitsPixaGlasses=t.data)}catch(t){console.error("Error",t)}finally{e.systemStore.setLoadingFetchData(!1)}},async addProductPixaExpress(e){const t=ie();t.systemStore.setLoadingAddToCart(!0);try{(await $2(e)).success&&(t.systemStore.addToastMessage("SUCCESS","Successfully added to cart"),t.systemStore.fetchGenericSiteMetadata())}catch(n){console.error("Error",n)}finally{t.systemStore.setLoadingAddToCart(!1)}}},H2=Rt("pixa",{state:()=>F2,getters:V2,actions:U2}),z2={visionCreditMetadata:null,isLogInForm:!1,isFormSuccessful:!1,isEmailOrPasswordInvalid:!1,isSubmitLoading:!1,isEmailTaken:!1,isCreditUsed:!1},K2={getVisionCreditMetadata(e){return e.visionCreditMetadata},getIsLogInForm(e){return e.isLogInForm},getIsFormSuccessful(e){return e.isFormSuccessful},getIsEmailOrPasswordInvalid(e){return e.isEmailOrPasswordInvalid},getIsSubmitLoading(e){return e.isSubmitLoading},getIsEmailTaken(e){return e.isEmailTaken},getIsCreditUsed(e){return e.isCreditUsed}},G2=async e=>$fetch(`https://${se()}/api/customer/express/sign-up`,{method:"POST",body:e,credentials:"include"}).then(t=>t).catch(t=>{console.log(t)}),j2=async e=>$fetch(`https://${se()}/api/customer/express/sign-in`,{method:"POST",body:e,credentials:"include"}).then(t=>t).catch(t=>{console.log(t)}),Y2=async e=>$fetch(`https://${se()}/api/customer/promotion/onboard`,{method:"POST",body:e,credentials:"include"}).then(t=>t).catch(t=>{console.log(t)}),W2=async()=>$fetch(`https://${se()}/api/national-credit/metadata`,{method:"GET"}).then(e=>e).catch(e=>{console.log(e)}),Q2={async fetchCustomerSignUp(e){const t=ie();this.setIsSubmitLoading(!0);try{const n=await G2(e);n!=null&&n.success?(this.setIsFormSuccessful(!0),t.systemStore.addToastMessage("SUCCESS","Successfully unlocked your $28 credit ")):(n!=null&&n.error&&(n==null?void 0:n.error)==="There is already an account using this email! Please login!"&&(this.setIsEmailTaken(!0),this.setIsLogInForm(!0)),n!=null&&n.error&&(n==null?void 0:n.error)==="You have reached the maximum amount of vouchers!"&&this.setIsCreditUsed(!0),n!=null&&n.error&&t.systemStore.addToastMessage("ERROR",n==null?void 0:n.error))}catch{t.systemStore.addToastMessage("ERROR","Failed to sign up")}finally{this.setIsSubmitLoading(!1)}},async fetchNationalCreditMetadata(){try{const e=await W2();e!=null&&e.success&&(this.visionCreditMetadata=e.data)}catch(e){console.error(e)}finally{}},async fetchCustomerSignIn(e){var n;const t=ie();this.setIsSubmitLoading(!0);try{const i=await j2(e);i!=null&&i.success?(this.setIsFormSuccessful(!0),t.systemStore.addToastMessage("SUCCESS","Successfully unlocked your $28 credit ")):(i!=null&&i.error&&(i==null?void 0:i.error)==="You have reached the maximum amount of vouchers!"&&this.setIsCreditUsed(!0),i!=null&&i.error&&((n=i==null?void 0:i.error)!=null&&n.includes("Invalid email or password!"))&&(this.setIsEmailTaken(!1),this.setIsEmailOrPasswordInvalid(!0)),i!=null&&i.error&&t.systemStore.addToastMessage("ERROR",i==null?void 0:i.error),i!=null&&i.errors&&t.systemStore.addToastMessage("ERROR",i==null?void 0:i.errors[0]))}catch{t.systemStore.addToastMessage("ERROR","Failed to log in")}finally{this.setIsSubmitLoading(!1)}},async fetchPromotionOnboard(e){var n;const t=ie();this.setIsSubmitLoading(!0);try{const i=await Y2(e);i!=null&&i.success?(this.setIsFormSuccessful(!0),t.systemStore.addToastMessage("SUCCESS",i.message)):(i!=null&&i.error&&(i==null?void 0:i.error)==="You have reached the maximum amount of vouchers!"&&this.setIsCreditUsed(!0),i!=null&&i.error&&((n=i==null?void 0:i.error)!=null&&n.includes("Invalid email or password!"))&&(this.setIsEmailTaken(!1),this.setIsEmailOrPasswordInvalid(!0)),i!=null&&i.error&&t.systemStore.addToastMessage("ERROR",i==null?void 0:i.error),i!=null&&i.errors&&t.systemStore.addToastMessage("ERROR",i==null?void 0:i.errors[0]))}catch{t.systemStore.addToastMessage("ERROR","Failed to log in")}finally{this.setIsSubmitLoading(!1)}},setIsLogInForm(e){this.isLogInForm=e},setIsFormSuccessful(e){this.isFormSuccessful=e},setIsEmailOrPasswordInvalid(e){this.isEmailOrPasswordInvalid=e},setIsSubmitLoading(e){this.isSubmitLoading=e},setIsEmailTaken(e){this.isEmailTaken=e},setIsCreditUsed(e){this.isCreditUsed=e}},Z2=Rt("vision-credit",{state:()=>z2,getters:K2,actions:Q2}),q2={autoshipStatus:{firstOrderDiscount:30,futureDiscount:30}},J2={getAutoshipStatus(e){return e.autoshipStatus}},X2=async()=>$fetch(`https://${se()}/api/cart/autoship/status`,{method:"GET",credentials:"include"}).then(e=>e).catch(e=>{console.error(e)}),Kd=(e,t)=>{const n=Number(e);return Number.isFinite(n)&&n>0&&n<=100?n:t},eP={async fetchAutoshipStatus(){try{const e=await X2(),t=(e==null?void 0:e.data)??e;if(!t||typeof t!="object")return;this.autoshipStatus={firstOrderDiscount:Kd(t.autoship_discount_for_cart,this.autoshipStatus.firstOrderDiscount),futureDiscount:Kd(t.autoship_reorder_discount,this.autoshipStatus.futureDiscount)}}catch(e){console.error(e)}}},tP=Rt("autoship-status",{state:()=>q2,getters:J2,actions:eP}
84),nP={welcomeDialogVisible:!1},pf="MPKITS1",sP=async()=>$fetch(`https://${se()}/api/products/add`,{method:"POST",credentials:"include",body:{products:[{sku:pf,options:{quantity:1}}]}}).then(e=>e).catch(e=>{console.error(e)}),iP={getWelcomeDialogVisible(e){return e.welcomeDialogVisible},isMembershipInCart(){var n,i;return(((i=(n=ie().systemStore.getGenericSiteMetadata)==null?void 0:n.side_cart)==null?void 0:i.items)??[]).some(r=>(r==null?void 0:r.code)===pf)}},rP="JOINKITSPLUS",aP={setWelcomeDialogVisible(e){this.welcomeDialogVisible=e},async joinKitsPlus(){const e=ie();if(!e.systemStore.getLoadingAddToCart)try{if(e.systemStore.setLoadingAddToCart(!0),!this.isMembershipInCart){const t=await sP();if(!(t!=null&&t.success)){e.systemStore.addToastMessage("ERROR",(t==null?void 0:t.error)||"Something went wrong.");return}await e.systemStore.addCoupon(rP),await e.systemStore.fetchGenericSiteMetadata()}this.welcomeDialogVisible=!0}catch(t){console.error("Error",t)}finally{e.systemStore.setLoadingAddToCart(!1)}}},oP=Rt("kits-plus",{state:()=>nP,getters:iP,actions:aP}),lP={opticianData:{email:"",userId:""},chatData:{pills:[],showOffersPill:!0},context:{summaryContext:"",userPreferencesContext:[]},messages:[],coupons:[],chatMode:"",isTyping:!1,recommendedProducts:[],productVariations:[],similarFramesQuery:null,isTOSChecked:!0,isMuted:!1,isOpticianMuted:!1,conversationItems:[],optionsContextItemId:null,isRealtimeEnabled:!1,realtimeSession:null,isVoiceDialogVisible:!1,hasTrackedTextStart:!1,isLoadingOpticianData:!1,isLoadingOptician:!1,sidebarData:{isVtoEnabled:!1,isFavoriteEnabled:!1,isSideBySideToggled:!1,favoriteItems:[],vtoItems:[],vtoItemsIframe:{}},firstVtoOrigin:"suggestions",secondVtoOrigin:"suggestions",shouldRenderMobileVto:!1,isPopoverVisible:!1,isVtoTosAccepted:!0,vtoIssues:{detectionFailed:!1},isIframeReady:!1,firstVtoBlob:"",secondVtoBlob:"",isVtoAnalysisFeedback:!0,faceDetected:!1,selectedVtoItemIndex:0,currentSwatchIndex:0,isConfiguratorTyping:!1,isFirstLensFetch:!0,rxType:"",lensType:"",isDoublePdActive:!1,isRxFormDisabled:!1,selectedLense:{},isMultiPdActive:!1,errorModalPD:{isModalShowing:!1,isPDOutOfRange:!1},rxFormFields:{SINGLE_PD:"",PD_OS:"",PD_OD:"",SPH_OS:"--",SPH_OD:"--",CYL_OS:"--",CYL_OD:"--",AXIS_OS:"--",AXIS_OD:"--",ADD_OS:"--",ADD_OD:"--"},selectedFrameDetails:{product_sku:"",product_images:[],name:"",description:"",product_tags:[],price:0,discounted_price:0,variations:[],color:"",color_code:"",style_code:"",vto_id:"",sizes:[],frame_sizes:[],shipping_status:"",gender:"",accepts_lenses:!0,material:"",is_meta:!1,is_liftoff:!1,brand_name:"",rx_inputs:[],product_group:"",generic_color:"",config_id:"",soldout:0,progressive_price:0,free_shipping_threshold:0,is_rimless:!1,has_clipon_available:!1,clippons:[],is_external_frame:!1,upsells:[],collections:[],calculated_pd:"",max_pd:"",min_pd:"",upc:null},selectedProduct:null,veeroFaceParams:{veeroEyeWidth:0,veeroPD:0,veeroFaceWidth:0,veeroBridge:0,veeroTemple:0,veeroResult:{},minFrameWidth:0,maxFrameWidth:0},threads:{list:[],activeThread:0},isThreadsVisible:!1,selfie:null,isCameraEnabled:!1,selfieWatcherResolver:null,is3DEnabled:!1,is3DEnabledSecondVto:!1,isFitmixReady:!1,isOpticianWidgetOpen:null,opticianCtaPill:"",productsCategory:"suggestions",shouldAutoOpenCheckoutRealtime:!1,bubbleMessage:null,iframeWindow:null,isScannerOpened:!1,showPickEyeDialog:!1,contactsByUpc:{brand:"",image:"",name:"",price:60,rx_info:{},sku:"",upc:""}},cP={getIsVtoAnalysisFeedback(e){return e.isVtoAnalysisFeedback},getDetectionFailed(e){return e.vtoIssues.detectionFailed},getContext(e){return e.context},getMessages(e){return e.messages},getCoupons(e){return e.coupons},getChatMode(e){return e.chatMode},getThreads(e){return e.threads},getShouldRenderMobileVto(e){return e.shouldRenderMobileVto},getOpticianData(e){return e.opticianData},getSidebarData(e){return e.sidebarData},getIsVtoEnabled(e){return e.sidebarData.isVtoEnabled},getChatData(e){return e.chatData},getFavoriteItems(e){return e.sidebarData.favoriteItems},getVtoItems(e){return e.sidebarData.vtoItems},getVtoItemsIframe(e){return e.sidebarData.vtoItemsIframe},getVeeroFaceParams(e){return e.veeroFaceParams},getIsSideBySideToggled(e){return e.sidebarData.isSideBySideToggled},getIsMuted(e){return e.isMuted}
84,getIsTyping(e){return e.isTyping},getIsConfiguratorTyping(e){return e.isConfiguratorTyping},getSelfie(e){return e.selfie},getRecommendedProducts(e){return e.recommendedProducts},getSimilarFramesQuery(e){return e.similarFramesQuery},getSelectedProduct(e){return e.selectedProduct},getIsOpticianWidgetOpen(e){return e.isOpticianWidgetOpen},getOpticianCtaPill(e){return e.opticianCtaPill},getShowOffersPill(e){return e.chatData.showOffersPill},getLoadingOpticianData(e){return e.isLoadingOpticianData},getLoadingOptician(e){return e.isLoadingOptician},getSearchQuery(e){return e.searchQuery},getIsTOSChecked(e){return e.isTOSChecked},getIsRealtimeEnabled(e){return e.isRealtimeEnabled},getErrorModalPD(e){return e.errorModalPD},getRealtimeSession(e){return e.realtimeSession},getProductsCategory(e){return e.productsCategory},getShouldAutoOpenCheckoutRealtime(e){return e.shouldAutoOpenCheckoutRealtime},getIsVtoTosAccepted(e){return e.isVtoTosAccepted},getRxFormFields(e){return e.rxFormFields},getIsFirstLensFetch(e){return e.isFirstLensFetch},getRxType(e){return e.rxType},getLensType(e){return e.lensType},getSelectedFrameDetails(e){return e.selectedFrameDetails},getIsRxFormDisabled(e){return e.isRxFormDisabled},getMultiPdActive(e){return e.isMultiPdActive},getSelectedLense(e){return e.selectedLense},getIsCameraEnabled(e){return e.isCameraEnabled},getIsThreadsVisible(e){return e.isThreadsVisible},getIsPopoverVisible(e){return e.isPopoverVisible},getIsVoiceDialogVisible(e){return e.isVoiceDialogVisible},getHasTrackedTextStart(e){return e.hasTrackedTextStart},getProductVariations(e){return e.productVariations},getFirstVtoOrigin(e){return e.firstVtoOrigin},getSecondVtoOrigin(e){return e.secondVtoOrigin},getSelectedVtoItemIndex(e){return e.selectedVtoItemIndex},getCurrentSwatchIndex(e){return e.currentSwatchIndex},getAreOffersShown(e){return e.areOffersShown},getSelfieWatcherResolver(e){return e.selfieWatcherResolver},getIsOpticianMuted(e){return e.isOpticianMuted},getIs3DEnabled(e){return e.is3DEnabled},getIs3DEnabledSecondVto(e){return e.is3DEnabledSecondVto}
84,getIsFitmixReady(e){return e.isFitmixReady},getFirstVtoBlob(e){return e.firstVtoBlob},getSecondVtoBlob(e){return e.secondVtoBlob},getIsIframeReady(e){return e.isIframeReady},getBubbleMessage(e){return e.bubbleMessage},getIframeWindow(e){return e.iframeWindow},getFaceDetected(e){return e.faceDetected},getIsScannerOpened(e){return e.isScannerOpened},getShowPickEyeDialog(e){return e.showPickEyeDialog},getContactsByUpc(e){return e.contactsByUpc},getRxOptionsConfidence(e){return e.rxOptionsConfidence}},dP={async addGlassesToCart(e,t="Source not known"){const n=ie();try{n.systemStore.setLoadingAddToCart(!0),sessionStorage.getItem("link_coupon")&&(e.coupon_code=sessionStorage.getItem("link_coupon")),e.add_to_cart_source=t;const i=await of(e);if(i.success){try{dataLayer.push({event:"add_to_cart",ecommerce:i.ga_data.gtfour.ecommerce})}catch{console.log("Datalayer not found:",{event:"add_to_cart",ecommerce:i.ga_data.gtfour.ecommerce})}await n.cartStore.fetchCartProducts(),sessionStorage.removeItem("link_coupon"),n.opticianStore.setProductsCategory("suggestions"),n.opticianStore.getIsRealtimeEnabled||(await n.opticianStore.sendStatusMessage({type:"addedToCart"}),this.sendPillsMessage())}else n.systemStore.addToastMessage("ERROR",i.error);return i.success}catch(i){console.error("Error",i)}finally{n.systemStore.setLoadingAddToCart(!1)}},async addContactsToCart(e,t,n){const i=ie();try{const r=i.contactsStore.getDiscounts,s=i.contactsStore.getIsAutoshipChecked,a=i.contactsStore.getReplenOption;let o=Jp(r,n,t),l={products:e.products};o!=null&&o.coupon_name&&(l.coupon_code=o.coupon_name),Zr()&&(l.coupon_code="SL50"),qr()&&(l.coupon_code="MBCCONTACTS"),s&&(l.autoreorder_frequency_key=a,l.autoreorder=!0,delete l.coupon_code),gi.value&&delete l.coupon_code,l.products.sort((d,u)=>d.options.eye==="OD"?-1:u.options.eye==="OD"?1:0);const c=await WC(l);if(c.success){try{}catch{console.log("Datalayer not found")}i.systemStore.addToastMessage("SUCCESS","Successfully added to cart")}else i.systemStore.addToastMessage("ERROR",c.message)}catch(r){console.error("Error",r)}finally{i.systemStore.setLoadingAddToCart(!1)}},async fetchSelectedFrameDetails(e,t){const n=ie();try{const i=await af(e,t);i.success?this.selectedFrameDetails=i.data:n.systemStore.addToastMessage("ERROR","Failed to fetch selected frame details")}catch(i){console.error("Error",i)}finally{n.systemStore.setLoadingFetchData(!1)}},async fetchOpticianMetadata(e,t){ie(),this.setLoadingOptician(!0);try{const n=await UC(e,t);n?localStorage.setItem("opticianMetadata",JSON.stringify(n)):console.log("error: No optician metadata found")}catch(n){console.error("Error",n)}finally{this.setLoadingOptician(!1)}},async fetchContactsByUpc(e){ie();try{const t=await Xp(e);return t.success?(this.contactsByUpc=t.data,{success:t.success,message:t==null?void 0:t.message,data:t==null?void 0:t.data}):t.data.in_stock&&t.data.brand&&t.data.rx_info==null?(this.contactsByUpc=t.data,{success:!t.success,message:"rx_info null"}):!t.data.in_stock&&t.data.brand?(this.contactsByUpc=t.data,{success:!t.success,message:t==null?void 0:t.message}):{success:t.success,message:t==null?void 0:t.message}}catch(t){console.error("Error",t)}finally{this.setLoadingOptician(!1)}},async deleteThread(e){const t=ie();this.setLoadingOptician(!0);try{const n=await HC(e);n.success?(this.setThreadsList(n.data),t.systemStore.addToastMessage("SUCCESS","Successfully deleted the conversation")):t.systemStore.addToastMessage("ERROR","Unable to delete the conversation")}catch(n){console.error("Error",n)}finally{this.setLoadingOptician(!1)}},async createThread(e){var n;const t=ie();try{const i=await zC(e);i.success?(this.setThreadsList(i.data),this.setActiveThread(((n=this.threads.list.at(0))==null?void 0:n.thread_id)||0),localStorage.setItem("activeThread",this.threads.activeThread)):t.systemStore.addToastMessage("ERROR","Unable to create the conversation")}catch(i){console.error("Error",i)}finally{}},async fetchAllThreads(){const e=ie();try{const t=await KC();t.success?this.threads.list=t.data:e.systemStore.addToastMessage("ERROR","Unable to fetch the conversation")}catch(t){console.error("Error",t)}finally{}},async fetchThreadConversation(e){var t,n;ie(),this.setLoadingOptician(!0);try{const i=await GC(e);i.success?(this.setMessages(i.data.conversation),this.recommendedProducts=i.data.recommended_products,this.productVariations=i.data.product_variations,this.setContext({summaryContext:(t=i.data)==null?void 0:t.summaryContext,userPreferencesContext:(n=i.data)==null?void 0:n.userPreferencesContext}),this.setActiveThread(e),localStorage.setItem("activeThread",e)):console.error("Failed to fetch the thread")}catch(i){console.error("Error",i)}finally{this.setLoadingOptician(!1)}},async addConversationToThread(e){const t=ie();try{const n=await jC(e);if(n.success)return n;t.systemStore.addToastMessage("ERROR","Failed to add messages to the conversation")}catch(n){console.error("Error",n)}finally{}},async initVto(e,t,n=!1){this.setIsVtoEnabled(!0);const i=Be().public.appKey;await kt();const r={onAgreePrivacyTerms:()=>{this.setIsVtoTosAccepted(!0)},onDisagreePrivacyTerms:()=>{this.closeVto()},onPrivacyTermsShown:()=>{this.setIsVtoTosAccepted(!1)},onIssue:({protocolFailed:s})=>{s&&(this.vtoIssues.detectionFailed=!0),!s&&this.vtoIssues.detectionFailed&&(this.vtoIssues.detectionFailed=!1)},onOpenStream:({success:s})=>{},onSnapshot:s=>{const a=s.dataUrl.split(",")[1],l=RI(a,"image/png");
84this.firstVtoBlob.size!==l.size&&this.setFirstVtoBlob(l)}};if(this.isVtoAnalysisFeedback){let s=null;r.onLiveStatus=a=>{this.faceDetected=a.faceTracking,this.faceDetected&&s===null&&(setTimeout(()=>{ko()},1e3),s=this.sidebarData.vtoItems[0].configuration_id)}}CI(i,e,t,n,r,{faceDetected:this.faceDetected,isVtoAnalysisFeedback:this.isVtoAnalysisFeedback})},closeVto(e){const t=`fitmix-container-${e}`,n=document.getElementById(t);Aa(),Rd(n),this.setIs3DEnabled(!1),this.setVtoItems([]),this.setVtoItemsIframe([]),this.setFirstVtoOrigin(""),this.setSecondVtoOrigin(""),this.setIsSideBySideToggled(!1),this.setIsVtoEnabled(!1),this.faceDetected=!1},clearVto(e){const t=`fitmix-container-${e}`,n=document.getElementById(t);if(e===1){this.setIsIframeReady(!1);const i=document.getElementById("vtoIframeWrapper");if(i){const r=i.querySelector("iframe");r&&(r.src="about:blank",r.src="/optician-vto")}}Rd(n)},loadFavoriteItems(){try{const t=JSON.parse(localStorage.getItem("favoriteItems"));Array.isArray(t)&&(this.sidebarData.favoriteItems=t)}catch{this.sidebarData.favoriteItems=[]}const e=this.sidebarData.favoriteItems.length>0;this.setIsFavoriteEnabled(e)},isFavoriteItem(e){return this.sidebarData.favoriteItems.some(t=>t.configuration_id===e)},toggleFavoriteItem(e){var i,r;if(this.isFavoriteItem(e.configuration_id))this.sidebarData.favoriteItems=this.sidebarData.favoriteItems.filter(s=>s.configuration_id!==e.configuration_id),this.productsCategory.toLowerCase()==="favorites"&&(this.shouldRenderMobileVto&&this.sidebarData.isVtoEnabled&&this.sidebarData.favoriteItems.length===0&&(Aa(),this.closeVto(3),this.setVtoItems([]),this.setIs3DEnabled(!1),this.setFirstVtoBlob(""),this.setFirstVtoOrigin(""),this.setSelectedVtoItemIndex(0),this.setCurrentSwatchIndex(0),this.setBubbleMessage(null)),this.shouldRenderMobileVto||(Object.keys(this.sidebarData.vtoItemsIframe).length===0&&this.sidebarData.vtoItems.length===0&&(this.setIsSideBySideToggled(!1),this.setIsVtoEnabled(!1)),e.configuration_id===((i=this.sidebarData.vtoItems[0])==null?void 0:i.configuration_id)?(Aa(),this.setVtoItems([]),this.setIs3DEnabled(!1),this.setFirstVtoBlob(""),this.setFirstVtoOrigin("")):e.configuration_id===((r=this.sidebarData.vtoItemsIframe)==null?void 0:r.configuration_id)&&(this.setVtoItemsIframe({}),this.setSecondVtoOrigin(""),this.clearVto(1),this.setSecondVtoBlob(""))));else{let s=this.recommendedProducts.findIndex(a=>a.configuration_id===e.configuration_id);this.sidebarData.favoriteItems=[{...e,variations:this.productVariations[s]},...this.sidebarData.favoriteItems],ie().systemStore.trackIterableFavorite({sku:e.products_sku,config_id:e.configuration_id,source:"optician"})}this.sidebarData.favoriteItems=this.sidebarData.favoriteItems.map((s,a)=>({...s,optionNumber:a+1})),localStorage.setItem("favoriteItems",JSON.stringify(this.sidebarData.favoriteItems));const n=this.sidebarData.favoriteItems.length>0;this.setIsFavoriteEnabled(n)},async createImageAnalysis(e,t=null){var i,r;const n=Be();this.setIsTyping(!0);try{const s=await $fetch(`${Bt()}${n.public.serviceApi}/optician-ai/analyze-image`,{method:"POST",body:{userId:this.opticianData.userid,image:e,...t?{text:t}:{},summaryContext:((i=this.context)==null?void 0:i.summaryContext)??""}});if((s==null?void 0:s.role)==="recommendations"){let a=s.recommended_products??[];a=a.map((o,l)=>(o.optionNumber=this.recommendedProducts.length+l+1,o)),this.isRealtimeEnabled?(this.setMessages({role:"assistant",content:[{type:"output_text",role:"recommendations",text:"",coupons:s.coupons,recommended_products:s.recommended_products,has_more:s.has_more,search_query:s.search_query}]}),await this.setOpticianSuggestions(a),this.syncRealtimeOptionsContext((r=this.realtimeSession)==null?void 0:r.dataChannel),this.realtimeSession.createConversationItem(`YOU MUST READ THIS PART out loud: ${JSON.stringify(s.text)}`),s.coupons.length>0&&this.setAreOffersShown(!0)):(this.setMessages({role:"assistant",content:[{type:"output_text",role:"recommendations",text:s.text,coupons:s.coupons,recommended_products:s.recommended_products,has_more:s.has_more,search_query:s.search_query}]}),await this.setOpticianSuggestions(a))}else this.setMessages({role:"assistant",content:[{type:"output_text",text:s.text}
84]})}catch(s){console.error("Error creating image analysis:",s)}finally{this.setIsTyping(!1)}},async createVtoFaceAnalysis(e){const t=Be();try{const n=await $fetch(`${Bt()}${t.public.serviceApi}/optician-ai/vto-face-analyze`,{method:"POST",body:{userId:this.opticianData.userid,image:e}});return this.isRealtimeEnabled||this.setMessages({role:"assistant",content:[{type:"output_text",text:n,isVision:!0}]}),this.handleThreadMessages(-1),n}catch(n){console.error("Error creating image analysis:",n)}finally{this.setIsTyping(!1)}},async selectProduct(e){if(xn("optician_select_frame"),this.muteAudioInput(),e.accepts_lenses==="1")this.setSelectedProduct(e);else{const t={products:[{sku:e.products_sku,rx_sun_upsell:!1,bitz_sku:"",options:{quantity:1,configuration_id:e.configuration_id,color:e.color,color_code:e.color_code}}],upsells:[]};await this.addGlassesToCart(t,"Optician AI")}},getMatchedProduct(e,t){var n,i;return e==="suggestions"?(n=this.recommendedProducts)==null?void 0:n.find((r,s)=>Number(s+1)===Number(t)):e==="favorites"?(i=this.sidebarData.favoriteItems)==null?void 0:i.find((r,s)=>Number(s+1)===Number(t)):null},async toggleAudioInput(){this.realtimeSession&&(this.isMuted?(await this.realtimeSession.resume(),this.setIsMuted(!1)):(await this.realtimeSession.pause(),this.setIsMuted(!0)))},stopRealtimeSession(){this.realtimeSession&&(this.isTyping=!1,this.realtimeSession.stop(),this.setRealtimeSession(null),this.setIsMuted(!0),this.setIsRealtimeEnabled(!1),this._handledRealtimeResponses=new Set)},async muteAudioInput(){this.realtimeSession&&!this.isMuted&&(await this.realtimeSession.pause(),this.setIsMuted(!0))},async unmuteOpticianAudio(){this.realtimeSession&&this.isOpticianMuted&&(await this.realtimeSession.resumeOptician(),this.setIsOpticianMuted(!1))},async muteOpticianAudio(){this.realtimeSession&&!this.isOpticianMuted&&(await this.realtimeSession.pauseOptician(),this.setIsOpticianMuted(!0))},async unmuteAudioInput(){this.realtimeSession&&this.isMuted&&(await this.realtimeSession.resume(),this.setIsMuted(!1))},async switchToText(){this.realtimeSession&&await this.muteAudioInput(),this.setIsRealtimeEnabled(!1)},async switchToRealtime(){var e;if(xn("start_optician_voice"),this.setLoadingOptician(!0),this.realtimeSession)await this.unmuteAudioInput(),this.setIsRealtimeEnabled(!0);else try{(await navigator.mediaDevices.getUserMedia({audio:!0})).getTracks().forEach(n=>n.stop()),await this.startRealtimeSession(),this.setIsRealtimeEnabled(!0)}catch(t){if((t.name==="NotAllowedError"||t.name==="PermissionDeniedError")&&((e=this.messages[this.messages.length-1])==null?void 0:e.content[0].text)!=="To proceed, please enable microphone access in your browser settings."){const n={type:"output_text",text:"To proceed, please enable microphone access in your browser settings."};this.setMessages({role:"assistant",content:[n]})}this.setIsRealtimeEnabled(!1)}finally{this.setLoadingOptician(!1)}},handleDoubleVto(e,t,n){xn("optician_vto",ka(e[0])),this.setIsSideBySideToggled(!0),this.setIsVtoEnabled(!0),this.setVtoItems([e[0]]),this.setFirstVtoOrigin(t),this.initVto(this.sidebarData.vtoItems[0],0),xn("optician_vto",ka(e[1])),this.setVtoItemsIframe(e[1]),this.setSecondVtoOrigin(n)},handleInitVto(e){xn("optician_vto",ka(e)),this.setVtoItems([e]),this.shouldRenderMobileVto?this.initVto(this.sidebarData.vtoItems[0],3):this.initVto(this.sidebarData.vtoItems[0],0)},async startRealtimeSession(){var i;const e=ie(),t=((i=e.cartStore.getProducts)==null?void 0:i.length)??0,n=new SI({opticianMetadata:JSON.parse(localStorage.getItem("opticianMetadata")),cartCount:t,onDataMessage:async(r,s,a)=>{var o,l,c,d,u,p,h;
84if(r==null||r.type,r.type==="conversation.item.input_audio_transcription.completed"&&(this.setMessages({role:"user",content:[{type:"input_text",text:r.transcript}]}),await this.handleThreadMessages(-1)),r.type==="response.output_audio_transcript.delta"&&this.setIsTyping(!0),r.type==="response.output_audio_transcript.done"&&(this.setIsTyping(!1),this.setMessages({role:"assistant",content:[{type:"output_text",text:r.transcript,isVision:r.transcript===this.bubbleMessage}]}),await this.handleThreadMessages(-1)),r.type==="conversation.item.created"){if((o=r.item)!=null&&o.id&&r.item.id===this.optionsContextItemId)return;if(this.conversationItems.length>9){const m={type:"conversation.item.delete",item_id:this.conversationItems[0]};s.send(JSON.stringify(m)),this.conversationItems=this.conversationItems.slice(1),this.conversationItems.push(r.item.id)}else this.conversationItems.push(r.item.id)}if(r.type==="response.done"&&((c=(l=r.response)==null?void 0:l.output)!=null&&c.some(m=>m.type==="function_call"))){const m=(d=r.response)==null?void 0:d.id;if(this._handledRealtimeResponses||(this._handledRealtimeResponses=new Set),m&&this._handledRealtimeResponses.has(m))return;m&&this._handledRealtimeResponses.add(m);const v=r.response.output.find(w=>w.type==="function_call"),_=await $fetch(`${Bt()}${a.config.public.serviceApi}/optician-ai/call-function`,{method:"POST",body:{name:v.name,args:v==null?void 0:v.arguments,userId:this.userId,userEmail:this.userEmail,originUrl:Bt(),faceParams:{veeroPD:this.veeroFaceParams.veeroPD},opticianMetadata:{...JSON.parse(localStorage.getItem("opticianMetadata")),areOffersShown:this.areOffersShown}}}),b=v!=null&&v.arguments?JSON.parse(v.arguments):null;if(v.name==="measure_pd")xn("find_my_size_optician"),this.muteAudioInput(),tt(s,v,"TELL THE USER THAT: the face analysis process has started. Instruct them to follow the on-screen guidelines carefully to complete it. Reassure them that you'll wait patiently until they finish the entire process."),this.closeVto(0),this.setVtoItemsIframe({}),this.setSecondVtoOrigin(""),window.self!==window.top?TI().then(w=>{const C=kd(w);localStorage.setItem("pd",C.veeroPD),this.setVeeroFaceParams(C),tt(s,v,`TELL THE USER: the process of analyzing his face params and the measurment of the PD has ended,
85                      Tell the user that he got these values: min frame width: ${this.veeroFaceParams.minFrameWidth}mm and max frame width: ${this.veeroFaceParams.maxFrameWidth}mm and PD(pupilary distance): ${this.veeroFaceParams.veeroPD}
86                      Also tell the user that this will help us to find the perfect pair. Always mentioned that we also measured his PD(pupilary distance)`)}).catch(w=>{console.error("Measurement failed:",w)}):await II(this.eyeSizeCallback,this.eyeSizeExitCallback,s,v),this.unmuteAudioInput();else if(v.name==="file_search"){const w=await $fetch(`${Bt()}${a.config.public.serviceApi}/optician-ai/file-search`,{method:"POST",body:{message:b}});tt(s,v,`Read this out loud: ${w}`)}else if(v.name==="add_to_cart"){const w=e.opticianStore.getMatchedProduct(this.productsCategory.toLowerCase(),b.option);if((w==null?void 0:w.soldout)===1){tt(s,v,"TELL THE USER THAT: The product is sold out.");return}await(async O=>{if(!O){console.warn("Product not found"),tt(s,v,`TELL THE USER THAT: Unfortuantely we did not found this option from ${origin} list, please try on another frame`);return}await this.selectProduct(w),tt(s,v,`TELL THE USER THAT: option ${b.option}. has been selected for the text step. (do not tell him that his item has been added to the cart just yet)`)})(w)}else if(v.name==="add_to_favourites"){const w=async O=>{O?this.sidebarData.favoriteItems.some(E=>E.vto_alt_full===O.vto_alt_full)?tt(s,v,`This option is already added to favourite list. ${this.veeroFaceParams.veeroPD?"":" Also, ask the user if they want their pd measured."}`):(this.toggleFavoriteItem(O),this.setProductsCategory("Favorites"),tt(s,v,`The option ${b.option} added to favourite list! ${this.veeroFaceParams.veeroPD?"":" Also, ask the user if they want their pd measured."}`)):tt(s,v,"TELL THE USER: Unfortuantely I did not found the product")},C=this.getMatchedProduct("suggestions",b.option);await w(C)}else if(v.name==="remove_from_favourites"){const w=C=>{C?(this.toggleFavoriteItem(C),this.setProductsCategory("Favorites"),tt(s,v,`TELL THE USER: The option ${C} removed from favourite list!`)):tt(s,v,`TELL THE USER: The option ${C} is already removed from favourite list!`)};if(this.sidebarData.favoriteItems.length>0){const C=this.getMatchedProduct(this.productsCategory.toLowerCase(),b.option);w(C)}else console.warn("No recommendation message found"),tt(s,v,"TELL THE USER: No items found in favourite list");return}else if(v.name==="take_selfie"){await this.muteAudioInput(),this.setIsCameraEnabled(!0);const w=await kI();tt(s,v,`READ OUT LOUD THE FOLLOWING TEXT: ${w}`),await this.unmuteAudioInput()}else if(v.name==="compare_vto"){if(this.shouldRenderMobileVto)tt(s,v,"TELL THE USER: On mobile you can only try on 1 pair at a time, which one of those 2 pairs would you like to try on ? ");else{const w=b.first_frame.origin||this.productsCategory.toLowerCase(),C=b.second_frame.origin||this.productsCategory.toLowerCase(),O=this.getMatchedProduct(w,b.first_frame.option),T=this.getMatchedProduct(C,b.second_frame.option),E=[O,T].filter(y=>y&&y.vto_alt_full);E.length===2?(this.handleDoubleVto(E,w,C),tt(s,v,`TELL THE USER: You are now trying them both ${E[0].name} and ${E[1].name}.`)):tt(s,v,"TELL THE USER: One or both selected frames do not support VTO.")}return}else if(v.name==="open_vto"){const w=async(O,T)=>{if(!O){console.warn("Product not found for vto"),tt(s,v,`TELL THE USER: Unfortuantely we did not found option ${T}, please try on another frame.`);return}O.vto_alt_full?(this.handleInitVto(O),this.setFirstVtoOrigin(this.productsCategory.toLowerCase()),tt(s,v,`The user is trying on option ${b.option}
86`)):tt(s,v,"TELL THE USER: Unfortuantely this option do not leverage VTO, would you like to try-on another pair of glasses ? ")},C=this.getMatchedProduct(this.productsCategory.toLowerCase(),b.option);await w(C,b.option);return}else if(v.name==="close_vto")this.closeVto(0),this.setVtoItemsIframe({}),this.setSecondVtoOrigin(""),tt(s,v,`Tell ther user: The vto has been closed ${this.veeroFaceParams.veeroPD?"":" Also, ask the user if they want their pd measured."}`);else if(v.name==="get_product_reviews"){const w=await Pd(b.product_sku,15,1,a.config.public.serviceApi);tt(s,v,`Create a summary based on the following ${w.length} reviews: ${JSON.stringify(w)}.  If there are no reviews, tell the user that the product has no reviews. Include the number of reviews in your message (15 is usually not the total number of reviews, it is the maximum for creating a summary). Summarize based on reviews relating to the actual product, and NOT ordering experience, shipping or general site sentiments. Put more emphasis on the positive points. You don't know the reviews for other products before calling this function, so don't suggest recommending better frames.`)}else if(v.name==="search_products"){this.setIsTyping(!0);let w=_.output[0].content[0].recommended_products;w=w.map((C,O)=>(C.optionNumber=this.recommendedProducts.length+O+1,C)),await this.setOpticianSuggestions(w),(u=_.output[0])!=null&&u.content[0].recommended_products&&this.setMessages({role:"assistant",content:[{type:"output_text",role:"recommendations",text:"",coupons:_.output[0].content[0].coupons,recommended_products:_.output[0].content[0].recommended_products}]}),this.syncRealtimeOptionsContext(s),tt(s,v,`YOU MUST READ THIS PART out loud: ${JSON.stringify(_.output[0].content[0].text)}`),_.output[0].content[0].coupons.length>0&&this.setAreOffersShown(!0),this.setIsTyping(!1)}else if(v.name==="get_products_by_name"){this.setIsTyping(!0);let w=_.output[0].content[0].recommended_products;w=w.map((C,O)=>(C.optionNumber=this.recommendedProducts.length+O+1,C)),await this.setOpticianSuggestions(w),(p=_.output[0])!=null&&p.content[0].recommended_products&&this.setMessages({role:"assistant",content:[{type:"output_text",role:"recommendations",recommended_products:_.output[0].content[0].recommended_products}]}),this.syncRealtimeOptionsContext(s),tt(s,v,`YOU MUST READ THIS PART out loud: ${JSON.stringify(_.output[0].content[0].text)}`),this.setIsTyping(!1)}else if(v.name==="get_product_variations"){this.setIsTyping(!0);const w=this.getMatchedProduct(this.productsCategory.toLowerCase(),b.optionNumber);let C=this.recommendedProducts.findIndex(T=>T.optionNumber===w.optionNumber);this.productVariations[this.recommendedProducts[C].optionNumber-1].length===0&&(C=this.recommendedProducts.findIndex(T=>T.products_sku===this.recommendedProducts[C].products_sku));const O=this.productVariations[this.recommendedProducts[C].optionNumber-1].map((T,E)=>({...T,optionNumber:this.recommendedProducts.length+E+1}));await this.prepareRecommendations(O),tt(s,v,`These are the available color variations: ${O.map(T=>T.generic_color||T.name).filter(Boolean).join(", ")}. Let the user know they can try them on or add one to cart.`),this.setMessages({role:"assistant",content:[{type:"output_text",role:"recommendations",text:"",recommended_products:O}]}),this.setIsTyping(!1)}else v.name==="ai_opinions"?(this.setFirstVtoBlob(""),this.setSecondVtoBlob(""),((h=Object.keys(this.sidebarData.vtoItemsIframe))==null?void 0:h.length)!==0&&this.isIframeReady&&this.iframeWindow&&this.iframeWindow.postMessage({type:"getSnapshot",payload:{},reinit:!1},"*"),this.sidebarData.vtoItems.length!==0&&ko()):v.name==="scan_contacts_bar_code"?(this.setIsScannerOpened(!0),tt(s,v,"The camera has been opened, tell the user to show the bar code of their current contacts box to the camera, in order to provide the same box.")):v.name==="close_scan_contacts_bar_code"?(this.setIsScannerOpened(!1),tt(s,v,"The camera has been closed, ask user what they want to do next")):v.name==="proceed_to_checkout"?e.cartStore.getProducts.length>0?(tt(s,v,"Tell the user you're taking them to checkout now and that they can continue this conversation there."),this.stopRealtimeSession(),this.setShouldAutoOpenCheckoutRealtime(!0),this.setProductsCategory("Checkout")):tt(s,v,"TELL THE USER: Your cart is empty. Please add items before proceeding to checkout."):(tt(s,v,"TELL THE USER: I do not have such functionality, please try something else."),console.warn("No function calling name"))}r.type==="error"&&realtimeSession.value.stop()}});this.setRealtimeSession(n),await this.realtimeSession.start(),this.setIsMuted(!1)},async clearVeeroFaceParams(){this.setVeeroFaceParams({veeroEyeWidth:0,veeroPD:this.veeroFaceParams.veeroPD??0,veeroFaceWidth:0,veeroBridge:0,veeroTemple:0,veeroResult:{},minFrameWidth:0,maxFrameWidth:0}),localStorage.removeItem("pd"),await OI("firebaseLocalStorageDb","firebaseLocalStorage")},eyeSizeExitCallback(){}
86,async eyeSizeCallback(e,t=null,n=null){xn("find_my_size_optician_received_measurements");const i=kd(e);localStorage.setItem("pd",i.veeroPD),this.setVeeroFaceParams(i),this.isRealtimeEnabled?tt(t,n,`TELL THE USER: the process of analyzing his face params and the measurment of the PD has ended,
87          Tell the user that he got these values: min frame width: ${this.veeroFaceParams.minFrameWidth}mm and max frame width: ${this.veeroFaceParams.maxFrameWidth}mm and PD(pupilary distance): ${this.veeroFaceParams.veeroPD}
88          Also tell the user that this will help us to find the perfect pair. Always mentioned that we also measured his PD(pupilary distance)`):await this.sendStatusMessage({type:"pdMeasured",args:{veeroPD:this.veeroFaceParams.veeroPD}}),EyeSize.closeModal()},async getReviews(e){const n=await Pd(e,15,1,Be().public.serviceApi);await this.sendStatusMessage({type:"summarizedReviews",args:{reviews:n}})},clearConfiguratorChat(){this.rxFormFields={SINGLE_PD:"",PD_OS:"",PD_OD:"",SPH_OS:"--",SPH_OD:"--",CYL_OS:"--",CYL_OD:"--",AXIS_OS:"--",AXIS_OD:"--",ADD_OS:"--",ADD_OD:"--"},this.isFirstLensFetch=!0,this.rxType="",this.lensType="",this.selectedFrameDetails={product_sku:"",product_images:[],name:"",description:"",product_tags:[],price:0,discounted_price:0,variations:[],color:"",color_code:"",style_code:"",vto_id:"",sizes:[],frame_sizes:[],shipping_status:"",gender:"",accepts_lenses:!0,material:"",is_meta:!1,is_liftoff:!1,brand_name:"",rx_inputs:[],product_group:"",generic_color:"",config_id:"",soldout:0,progressive_price:0,free_shipping_threshold:0,is_rimless:!1,has_clipon_available:!1,clippons:[],is_external_frame:!1,upsells:[],collections:[],calculated_pd:"",max_pd:"",min_pd:"",upc:null},this.errorModalPD={isModalShowing:!1,isPDOutOfRange:!1},this.selectedProduct=null,this.isRxFormDisabled=!1,this.selectedLense={},this.isMultiPdActive=!1},async clearChat(){this.isTyping||(this.stopRealtimeSession(),localStorage.removeItem("activeThread"),this.chatData.pills=[],this.sidebarData.isVtoEnabled=!1,this.sidebarData.isFavoriteEnabled=!1,this.sidebarData.isSideBySideToggled=!1,this.setVtoItems([]),this.setVtoItemsIframe({}),this.threads.activeThread=0,this.messages=[],this.recommendedProducts=[],this.conversationItems=[],this.optionsContextItemId=null,this.hasTrackedTextStart=!1,this.productsCategory="suggestions",this.isVtoTosAccepted=!0,this.isCameraEnabled=!1,this.isOpticianMuted=!1,this.isDoublePdActive=!1,this.isPopoverVisible=!1,this.isVoiceDialogVisible=!1,this.productVariations=[],this.selectedVtoItemIndex=0,this.areOffersShown=!1,this.clearConfiguratorChat())},async handleThreadMessages(e=-2){var t,n,i,r,s;if(this.threads.activeThread===0){const a=this.messages[0],o=((t=a==null?void 0:a.content)==null?void 0:t.findIndex(u=>["input_text","output_text"].includes(u.type)))??-1,l=((n=a==null?void 0:a.content)==null?void 0:n.findIndex(u=>u.type==="input_file"))??-1,c=((i=a==null?void 0:a.content)==null?void 0:i.findIndex(u=>u.type==="input_image"))??-1;let d;l!==-1?d=a.content[l].filename||"User file":c!==-1?d=a.content[c].image_name||"User image":d=((s=(r=a.content[o])==null?void 0:r.text)==null?void 0:s.split(" ").slice(0,5).join(" "))||"",await this.createThread({title:d,recommended_products:this.recommendedProducts,product_variations:this.productVariations,conversations:this.messages})}else this.addConversationToThread({thread_id:this.threads.activeThread,recommended_products:this.recommendedProducts,product_variations:this.productVariations,conversations:this.messages.slice(e)})},async sendStatusMessage(e){var n;const t=Be();this.setIsTyping(!0);try{const i=await $fetch(`${Bt()}${t.public.serviceApi}/optician-ai/status-message`,{method:"POST",body:{payload:e}});this.setMessages({role:"assistant",content:(n=i.output[0])==null?void 0:n.content})}catch(i){console.error("Error sending status message:",i),this.setMessages({role:"assistant",content:[{type:"output_text",text:"There was an error sending your message. Please try again."}]})}finally{this.setIsTyping(!1)}},async sendPillsMessage(){var t,n;this.setIsTyping(!0);const{serviceApi:e}=Be().public;try{const r=((t=ie().cartStore.getProducts)==null?void 0:t.length)??0,s=await $fetch(`${Bt()}${e}/optician-ai/create-pills`,{method:"POST",body:{messages:[...this.messages],cartCount:r}}),a=s==null?void 0:s.pills;if(!a)return;
88const o=Array.isArray(a)?JSON.stringify(a):typeof a=="string"?((n=a.match(/\[.*\]/s))==null?void 0:n[0])??null:null;if(!o)return;const l=JSON.parse(o);if(!Array.isArray(l))return;const c=this.chatData.showOffersPill?["Show me the available offers",...l]:l;this.setPills(c)}catch(i){console.error("sendPillsMessage failed:",i)}finally{this.setIsTyping(!1)}},async saveThreadContext(e,t){const{summaryContext:n,userPreferencesContext:i}=t;await YC(e,n,i)},async getVariations(e){var r,s;let t=e.optionNumber-1,n=[];(((r=this.productVariations[t])==null?void 0:r.length)===0||this.productVariations[t]===void 0||((s=this.productVariations[t])==null?void 0:s.length)===1&&this.productVariations[t][0].configuration_id===e.configuration_id)&&(t=this.recommendedProducts.findIndex(a=>a.products_sku===e.products_sku)),n=this.productVariations[this.recommendedProducts[t].optionNumber-1].map((a,o)=>({...a,optionNumber:this.recommendedProducts.length+o+1})),await this.addVariations(n),await this.prepareRecommendations(n),await this.prepareProductVariations(n.length),await this.handleThreadMessages()},async addVariations(e){await this.sendStatusMessage({type:"presentVariations",args:{variations:e}}),this.setMessages({role:"assistant",content:[{type:"output_text",role:"recommendations",text:"",recommended_products:e}]})},async prepareProductVariations(e){const t=Be().public.appKey,n=[];if(e!==0&&!Array.isArray(e)){const r=Array.from({length:e},()=>[]);this.productVariations=[...this.productVariations,...r];return}e.forEach(r=>{r.variations.forEach(s=>{s.vto_alt_full&&n.push(s.vto_alt_full)})});let i=e.map(r=>{const s=r.optionNumber;return(r.variations||[]).map(a=>({...a,optionNumber:s}))});if(n.length>0){const r=await Od(t,n);i.forEach(s=>{s.forEach(a=>{if(a.vto_alt_full){const o=r.find(l=>l.uid===a.vto_alt_full);o&&(a.viewerCompatible=o.viewerCompatible)}})})}this.productVariations=[...this.productVariations,...i]},async prepareRecommendations(e){const t=Be().public.appKey,n=[];if(e.forEach(i=>{i.vto_alt_full&&n.push(i.vto_alt_full),delete i.variations}),n.length>0){const i=await Od(t,n);e.forEach(r=>{if(r.vto_alt_full){const s=i.find(a=>a.uid===r.vto_alt_full);s&&(r.viewerCompatible=s.viewerCompatible)}})}this.recommendedProducts=[...this.recommendedProducts,...e]},setLoadingOpticianData(e){this.isLoadingOpticianData=e},setLoadingOptician(e){this.isLoadingOptician=e},setIsVtoAnalysisFeedback(e){this.isVtoAnalysisFeedback=e},setDetectionFailed(e){this.vtoIssues.detectionFailed=e},setSelfieWatcherResolver(e){this.selfieWatcherResolver=e},setChatMode(e){this.chatMode=e},setContext(e){this.context.summaryContext=e.summaryContext,this.context.userPreferencesContext=e.userPreferencesContext},setMessages(e){Array.isArray(e)?this.messages=e:this.messages=[...this.messages,e]},setIsThreadsVisible(e){this.isThreadsVisible=e},setThreadsList(e){this.threads.list=e},setActiveThread(e){this.threads.activeThread=e},setFirstVtoOrigin(e){this.firstVtoOrigin=e},setSecondVtoOrigin(e){this.secondVtoOrigin=e},setShouldRenderMobileVto(e){this.shouldRenderMobileVto=e},setSelectedFrameDetails(e){this.selectedFrameDetails=e},setRecommendedProducts(e){this.recommendedProducts=[...this.recommendedProducts,...e]},setVtoItems(e){this.trackVtoSessionEnd(this.sidebarData.vtoItems,e),this.sidebarData.vtoItems=e},setVtoItemsIframe(e){this.trackVtoSessionEnd(this.sidebarData.vtoItemsIframe,e),this.sidebarData.vtoItemsIframe=e},trackVtoSessionEnd(e,t){const n=Array.isArray(e)?e[0]:e,i=Array.isArray(t)?t[0]:t;n!=null&&n.configuration_id&&(i==null?void 0:i.configuration_id)!==n.configuration_id&&ie().systemStore.trackIterableVto({sku:n.products_sku,config_id:n.configuration_id,source:"optician"})},setPills(e){this.chatData.pills=e},setShowOffersPill(e){this.chatData.showOffersPill=e},setEmail(e){this.opticianData.email=e},setVeeroFaceParams(e){this.veeroFaceParams=e},setVeeroPD(e){this.veeroFaceParams.veeroPD=e},setIsMuted(e){this.isMuted=e},setIsTyping(e){this.isTyping=e},setIsConfiguratorTyping(e){this.isConfiguratorTyping=e},setFavoriteItems(e){this.sidebarData.favoriteItems=e},setIsFavoriteEnabled(e){this.sidebarData.isFavoriteEnabled=e},setIsSideBySideToggled(e){this.sidebarData.isSideBySideToggled=e},setIsVtoEnabled(e){this.sidebarData.isVtoEnabled=e},setIsVtoTosAccepted(e){this.isVtoTosAccepted=e},setSelfie(e){this.selfie=e},setUserId(e){this.opticianData.userId=e},async setOpticianSuggestions(e){await this.prepareProductVariations(e),await this.prepareRecommendations(e)},syncRealtimeOptionsContext(e){if(!e||e.readyState!=="open"||(this.optionsContextItemId&&(e.send(JSON.stringify({type:"conversation.item.delete",item_id:this.optionsContextItemId})),this.optionsContextItemId=null),!this.recommendedProducts.length))return;const t=["soldout","upc","vto_alt_full"],n=this.recommendedProducts.map(s=>Object.fromEntries(Object.entries(s).filter(([a])=>!t.includes(a)))),i=n.map(s=>`Option ${s.optionNumber}
88: ${[s.name,s.brand_name,s.generic_color,s.rim_shape].filter(Boolean).join(", ")}`).join(`
89`),r=`opts_${Math.random().toString(36).substring(2,10)}`;this.optionsContextItemId=r,e.send(JSON.stringify({type:"conversation.item.create",item:{id:r,type:"message",role:"system",content:[{type:"input_text",text:`CURRENT PRODUCTS SHOWN TO THE USER (authoritative — always use these exact option numbers when the user refers to an option, and never claim an option number outside this list does not exist). There are ${n.length} frames currently shown:
90${i}
91
92Full details for these frames: ${JSON.stringify(n)}`}]}}))},setProductVariations(e){this.productVariations=e},setSimilarFramesQuery(e){this.similarFramesQuery=e},setSelectedProduct(e){this.selectedProduct=e},setIsOpticianWidgetOpen(e){this.isOpticianWidgetOpen=e},setOpticianCtaPill(e){this.opticianCtaPill=e},setIsTOSChecked(e){this.isTOSChecked=e},setIsRealtimeEnabled(e){this.isRealtimeEnabled=e},setRealtimeSession(e){this.realtimeSession=e},setProductsCategory(e){this.productsCategory=e},setShouldAutoOpenCheckoutRealtime(e){this.shouldAutoOpenCheckoutRealtime=e},setRxFormFields(e){this.rxFormFields=e},setIsPDOutOfRange(e){this.errorModalPD.isPDOutOfRange=e},setIsErrorModalShowing(e){this.errorModalPD.isModalShowing=e},saveRxFormFieldsOption(e,t){if(t==="PD_OS"||t==="PD_OD"||t==="SINGLE_PD"){this.rxFormFields[t]=String(e);return}if(e==="PL"||e==="Plano"||e==="-PL"||e==="-Plano"||e==="None"||e==="-None"){this.rxFormFields[t]=String(e);return}const n=this.selectedFrameDetails.rx_inputs.find(i=>i.name===t);if(n){const i=n.options.find(r=>Number(r)===Number(e));i!==void 0?this.rxFormFields[t]=i:this.rxFormFields[t]="--"}},setIsFirstLensFetch(e){this.isFirstLensFetch=e},setRxType(e){this.rxType=e},setLensType(e){this.lensType=e},setIsRxFormDisabled(e){this.isRxFormDisabled=e},setMultiPdActive(e){this.isMultiPdActive=e},setSelectedLense(e){this.selectedLense=e},setIsCameraEnabled(e){this.isCameraEnabled=e},setIsPopoverVisible(e){this.isPopoverVisible=e},setIsVoiceDialogVisible(e){this.isVoiceDialogVisible=e},setHasTrackedTextStart(e){this.hasTrackedTextStart=e},setIsThreadsVisible(e){this.isThreadsVisible=e},setSelectedVtoItemIndex(e){this.selectedVtoItemIndex=e},setCurrentSwatchIndex(e){this.currentSwatchIndex=e},setAreOffersShown(e){this.areOffersShown=e,sessionStorage.setItem("areOffersShown",e)},setIsOpticianMuted(e){this.isOpticianMuted=e},setIs3DEnabled(e){this.is3DEnabled=e},setIs3DEnabledSecondVto(e){this.is3DEnabledSecondVto=e},setIsFitmixReady(e){this.isFitmixReady=e},setFirstVtoBlob(e){this.firstVtoBlob=e},setSecondVtoBlob(e){this.secondVtoBlob=e},setIsIframeReady(e){this.isIframeReady=e},setBubbleMessage(e){this.bubbleMessage=e},setIframeWindow(e){this.iframeWindow=e},setFaceDetected(e){this.faceDetected=e},setIsScannerOpened(e){this.isScannerOpened=e},setShowPickEyeDialog(e){this.showPickEyeDialog=e}},uP=Rt("optician",{state:()=>lP,getters:cP,actions:dP}),hP={messages:[],isTyping:!1,pills:[]},pP={getMessages(e){return e.messages},getIsTyping(e){return e.isTyping},getPills(e){return e.pills},getPatientInfo(e){return e.patientInfo},getPatientsToBeVerified(e){return e.patientsToBeVerified},getIsMethodOpen(e){return e.isMethodOpen}},fP={setIsTyping(e){this.isTyping=e},setPills(e){this.pills=e},pushMessage(e){this.messages.push(e)},clearMessages(){this.messages=[]}},mP=Rt("opticianCheckout",{state:()=>hP,getters:pP,actions:fP}),gP={loadingFinishPayment:!1,cartGenericData:{STORE_ID:"",kits_membership:{allowed:!0,has_membership:!1},cart:{has_cl:!1,has_gl:!1,has_pla:!1},telus_claim:{submitted:!1,submitted_at:null,server_time:null,is_predetermination:!1},currency:null,faxto:null,mailto:null,minimum_order_value_for_offers:0,token:null,UPSELL_PRODUCTS_ENABLED:!1,TELUS_ENABLED:!1,insurance:{is_active:!1,type:null},paypal_token:null,BASE_URL:null,DEVELOPMENT:!1,is_admin_order_change:!1,is_anagram_insurance_active:!1}},yP={getHost(e){return e.host},getLocale(e){return e.locale},getActiveStep(e){return e.activeStep},getStepLabel(e){return e.nextStepLabel},getBanner(e){return e.banner},getLogInDialogState(e){return e.logInDialogState},getInsuranceDialogState(e){return e.insuranceDialogState},getHasAutoship(e){return e.hasAutoship},getAutoshipSubscription(e){return e.autoshipSubscription},getAnagramInsuranceStatus(e){return e.cartGenericData.is_anagram_insurance_active},getCartGenericData(e){return e.cartGenericData},getShippingDetailsValidation(e){return e.shippingDeatilsValidation},getComponentIsInTransition(e){return e.componentIsInTransition},getLoadingCartTotalsState(e){return e.loadingCartTotalsState}
92,getLoadingCartItemState(e){return e.loadingCartItemState},getLoadingCouponsState(e){return e.loadingCouponsState},getLoadingShippingMethodsState(e){return e.loadingShippingMethodsState},getLoadingShippingOptionsState(e){return e.loadingShippingOptionsState},getLoadingInsuranceState(e){return e.loadingInsuranceState},getLoadingUpsellsState(e){return e.loadingUpsellsState},getLoadingPatientVerificationState(e){return e.loadingPatientVerification},getLoadingPatientDoctorVerificationState(e){return e.loadingPatientDoctorVerification},getLoadingPatientRemoveUploadedRx(e){return e.loadingPatientRemoveUploadedRx},getLoadingFinishPayment(e){return e.loadingFinishPayment},getLoadingShippingAndBillingInfo(e){return e.loadingShippingAndBillingInfo},getLoadingAnagram(e){return e.loadingAnagram},getGlobalErrors(e){return e.globalErrors},getGlobalWarnings(e){return e.globalWarnings},getGlobalAlerts(e){return e.globalAlerts},getLoadingGereralAction(e){return e.loadingGeneralAction},getRecaptchaCode(e){return e.recaptchaCode},getMiniCartOpen(e){return e.miniCartOpen},getShopPayEmail(e){return e.shopPayEmail},getShowStickyCta(e){return e.showStickyCta},getRetailStoreMembers(e){return e.retailStoreMembers},getAnalyticsData(e){return e.analyticsData}},bP=async()=>$fetch(`https://${se()}/api/genericdata/list`,{method:"GET",credentials:"include"}).then(e=>e).catch(e=>{console.error(e)}),vP=async()=>$fetch(`https://${se()}/api/analytics/data`,{method:"GET",credentials:"include"}).then(e=>e).catch(e=>{console.error(e)}),_P={async fetchCartMetaData(){ie();try{const e=await bP();e.success?this.saveCartGenericData(e.data):this.addToastMessage("ERROR",e.error)}catch(e){console.error("Error: ",e)}finally{}},async fetchAnalyticsData(){ie();try{const e=await vP();if(e.success)return e.ga_data.gtfour}catch{}},saveCartGenericData(e){this.cartGenericData=e},setLoadingFinishPayment(e){this.loadingFinishPayment=e}},wP=Rt("systemCheckout",{state:()=>gP,getters:yP,actions:_P}),EP={products:null,cart_details:{has_cl:!1,has_gl:!1,has_nonpla_cl:!1,has_pla:!1},totals:{coupon_code:"",coupon_color:"",coupon_description:"",coupon_msg:"",discount:0,handling:0,pla_discount:0,shipping:0,shipping_status:"",subtotal:0,subtotal_without_taxes:0,tax_name:"",tax_price:0,total:0,total_carousel_savings:0,voucher_amount:0,voucher_info:""},isLoadingCartTotals:!1,uploads:[],membershipData:{allow_membership:!1,active:!1},shippingMethods:[],shippingMessage:""},SP={getProducts(e){return e.products},getCartDetails(e){return e.cart_details},getCartTotals(e){return e.totals},getIsLoadingCartTotals(e){return e.isLoadingCartTotals},getUploads(e){return e.uploads},getMembershipData(e){return e.membershipData},getCurrentLineItem(e){return e.currentLineItem}},Gd=async()=>$fetch(`https://${se()}/api/cart/items`,{method:"GET",credentials:"include"}).then(e=>e).catch(e=>{console.log(e)}),CP=async(e,t)=>$fetch(`https://${se()}/api/cart/change_quantity?index=${e}&quantity=${t}`,{method:"GET",credentials:"include"}).then(n=>n).catch(n=>{console.error(n)}),IP=async e=>$fetch(`https://${se()}/api/cart/delete?index=${e}`,{method:"GET",credentials:"include"}).then(t=>t).catch(t=>{console.error(t)}),jd=async()=>$fetch(`https://${se()}/api/cart/totals`,{method:"GET",credentials:"include"}).then(e=>e).catch(e=>{console.error(e)}),TP=async e=>$fetch(`https://${se()}/api/cart/item`,{method:"POST",credentials:"include",body:e}).then(t=>t).catch(t=>{console.error(t)}),PP=async e=>$fetch(`https://${se()}/api/cart/offers?user_type=${e}`,{method:"GET",credentials:"include"}).then(t=>t).catch(t=>{console.error(t)}),DX=e=>{if(e!=null)return`$${e.toFixed(2)}`},OP=e=>typeof e=="string"&&e.toLowerCase().endsWith(".ca"),xX=()=>(ie(),!0),Yd=99,AP={async fetchCartProducts(){this.isLoadingCart=!0;try{const e=await Gd();e&&e.success&&(this.storeCartProducts(e.items||[]),this.cart_details=e.cart_details||{},this.uploads=e.uploads||[],this.fetchCartTotals())}catch(e){console.error("Error fetching cart products:",e)}finally{this.isLoadingCart=!1}},async deleteCartItem(e){const t=ie();this.isLoadingCart=!0;try{const n=await IP(e);n!=null&&n.success?(t.couponStore.fetchCouponCode(),this.storeCartProducts(n.items),this.cart_details=n.cart_details,this.fetchCartTotals()):t.systemStore.addToastMessage("ERROR",n==null?void 0:n.error)}catch(n){console.error("Error deleting cart item:",n)}finally{this.isLoadingCart=!1}},async updateQuantity(e,t){const n=ie();if(t>Yd){n.systemStore.addToastMessage("ERROR",`Quantity cannot exceed ${Yd}`);return}this.isLoadingCart=!0;try{const i=await CP(e,t);i!=null&&i.success?(this.storeCartProducts(i.items||[]),i.cart_details&&(this.cart_details=i.cart_details,n.couponStore.fetchCouponCode(),this.fetchCartTotals())):n.systemStore.addToastMessage("ERROR",i==null?void 0:i.error)}catch(i){console.error("Error updating cart item quantity:",i)}finally{this.isLoadingCart=!1}},async fetchCartTotals(){const e=ie();this.isLoadingCartTotals=!0;try{if(e.systemCheckoutStore.getCartGenericData.insurance.is_active&&this.products.length>0&&(e.systemCheckoutStore.getCartGenericData.insurance.type==="greenshield"||e.systemCheckoutStore.getCartGenericData.insurance.type==="rbc")){const n=await jd();n.success?this.storeCartTotals(n.totals):e.systemStore.addToastMessage("ERROR",n.error)}const t=await jd();if(t.success){this.storeCartTotals(t.totals);const n=await Gd();this.storeCartProducts(n.items),this.cart_details=n.cart_details,this.uploads=n.uploads,window.location.href.includes("localhost")}else e.systemStore.addToastMessage("ERROR",t.error)}catch(t){console.error("Error fetching cart totals:",t)}finally{this.isLoadingCartTotals=!1}},async fetchBanner(e){if(e)try{const t=await PP(e);t.success?console.log(t):console.error(t.error)}catch(t){console.error("Error: ",t)}},async updateItemRxDetails(e){const t=ie();try{const n=await TP(e);return n.success?(this.storeCartProducts(n.items),this.fetchCartTotals(),t.rxVerificationStore.fetchPatient(),"success"):(t.systemStore.addToastMessage("ERROR",n.error),n.error)}catch(n){return console.error("Error fetching cart totals:",n),"error"}finally{}},storeCartTotals(e){this.totals=e},storeCartProducts(e){this.products=e}},kP=Rt("cart",{state:()=>EP,getters:SP,actions:AP}),RP={loadingShippingMethods:!1,loadingBillingInfo:!1,shippingMethods:[],shippingMessage:"",countriesAndStates:[],insurance:null,shippingInfo:{fname:null,lname:null,address1:null,country:null,
92state:null,city:null,zip:null,phone_day:null,email:null,setBilling:!0,rx_verification_required:!1},billingInfo:{b_fname:"",b_lname:"",b_address1:"",b_country:"",b_state:"",b_city:"",b_zip:"",billingInfoFilled:""},smsSignup:!1},LP={getShippingMethods(e){return e.shippingMethods},getShippingMessage(e){return e.shippingMessage},getCountriesAndStates(e){return e.countriesAndStates},getShippingInfo(e){return e.shippingInfo},getBillingInfo(e){return e.billingInfo},getShippingEmail(e){return e.shippingInfo.email},getShippingFirstName(e){return e.shippingInfo.fname},getShippingLastName(e){return e.shippingInfo.lname},getShippingAddress1(e){return e.shippingInfo.address1},getShippingCountry(e){return e.shippingInfo.country},getShippingState(e){return e.shippingInfo.state},getShippingCity(e){return e.shippingInfo.city},getShippingZip(e){return e.shippingInfo.zip},getShippingPhone(e){return e.shippingInfo.phone_day},getInsurance(e){return e.insurance}},NP=async()=>$fetch(`https://${se()}/api/customer/shipping_methods`,{method:"GET",credentials:"include"}).then(e=>e).catch(e=>{console.error(e)}),DP=async e=>$fetch(`https://${se()}
92/api/customer/shipping_methods`,{method:"POST",credentials:"include",body:{shipping_method:e}}).then(t=>t).catch(t=>{console.log(t)}),xP=async e=>$fetch(`https://${se()}/api/customer/billing_information`,{method:"POST",credentials:"include",body:{b_fname:e.b_fname,b_lname:e.b_lname,b_address1:e.b_address1,b_country:e.b_country,b_state:e.b_state,b_city:e.b_city,b_zip:e.b_zip}}).then(t=>t).catch(t=>{console.error(t)}),MP=async()=>$fetch(`https://${se()}/api/customer/billing_information`,{method:"GET",credentials:"include"}).then(e=>e).catch(e=>{console.error(e)}),FP=async(e,t)=>{let n={};return t==="partial"&&(n={country:e.shippingCountry,state:e.shippingState,address1:e.shippingAddress1,zip:e.shippingZip,setBilling:e.setBilling}),t==="quote"&&(n={email:e.shippingEmail}),t==="full"&&(n={fname:e.shippingFirstName,lname:e.shippingLastName,address1:e.shippingAddress1,address2:e.shippingAddress2,country:e.shippingCountry,state:e.shippingState,city:e.shippingCity,zip:e.shippingZip,phone_day:e.shippingPhone,email:e.shippingEmail,setBilling:e.setBilling,validate:!0}),$fetch(`https://${se()}
92/api/customer/shipping_information`,{method:"POST",credentials:"include",body:n}).then(i=>i).catch(i=>{console.log(i)})},VP=async()=>$fetch(`https://${se()}/api/customer/shipping_information`,{method:"GET",credentials:"include"}).then(e=>e).catch(e=>{console.error(e)}),BP=async()=>$fetch(`https://${se()}/api/customer/countries_states`,{credentials:"include"}),$P=async()=>$fetch(`https://${se()}/api/customer/shipping_insurance`,{method:"GET",credentials:"include"}).then(e=>e).catch(e=>{console.error(e)}),UP=async e=>$fetch(`https://${se()}/api/customer/shipping_insurance`,{method:"POST",credentials:"include",body:{shipping_insurance:e}}).then(t=>t).catch(t=>{console.error(t)}),HP=async()=>$fetch(`https://${se()}/api/customer/smsmarketing`,{method:"GET",credentials:"include"}).then(e=>e).catch(e=>{console.error(e)}),zP=async e=>$fetch(`https://${se()}/api/customer/smsmarketing`,{method:"POST",credentials:"include",body:{sms_signup:e}}).then(t=>t).catch(t=>{console.error(t)}),KP={async fetchShippingInfo(){const e=ie();try{const t=await VP();t.success?(this.saveShippingInfo(t.shipping_details),t.shipping_details.rx_verification_required&&(e.rxVerificationStore.fetchPatient(),e.rxVerificationStore.fetchDoctors(t.shipping_details.state))):e.systemStore.addToastMessage("ERROR",t.error)}catch(t){console.error("Error fetching data: ",t)}finally{}},async fetchShippingMethods(){const e=ie();this.setLoadingShippingMethodsState(!0);try{const t=await NP();t.success?(this.setShippingMethods(t.shipping_methods),this.setShippingMessage(t.shipping_status)):e.systemStore.addToastMessage("ERROR",t.error)}catch(t){console.error("Error fetching data: ",t)}finally{this.setLoadingShippingMethodsState(!1)}},async fetchBillingInfo(){const e=ie();this.loadingBillingInfo=!0;try{const t=await MP();t.success?this.saveBillingInfo(t.billing_details):e.systemStore.addToastMessage("ERROR",t.error)}catch(t){console.error("Error fetching data: ",t)}finally{this.loadingBillingInfo=!1}},async changeBillingInfo(e){const t=ie();this.loadingBillingInfo=!0;try{const n=await xP(e);n.success?(this.saveBillingInfo(n.billing_details),t.cartStore.fetchCartTotals()):t.systemStore.addToastMessage("ERROR",n.error)}catch(n){console.error("Error fetching data: ",n)}finally{this.loadingBillingInfo=!1}},async changeShippingInfo(e,t){var i;const n=ie();try{const r=await FP(e,t);return r.success?(t==="full"&&this.saveShippingInfo(r.shipping_details),n.cartStore.fetchCartProducts(),((i=r==null?void 0:r.shipping_details)==null?void 0:i.rx_verification_required)!==void 0&&(this.shippingInfo.rx_verification_required=r.shipping_details.rx_verification_required),r.shipping_details.rx_verification_required&&t!=="full"&&(n.rxVerificationStore.fetchPatient(),n.rxVerificationStore.fetchDoctors(r.shipping_details.state)),n.cartStore.fetchCartTotals()):(n.couponStore.fetchCouponCode(),n.cartStore.fetchCartTotals(),n.shippingStore.fetchShippingMethods(),(r.errors??[]).forEach(s=>{n.systemStore.addToastMessage("ERROR",s)})),r}catch(r){return console.error("Error fetching data: ",r),{success:!1}}},async changeShippingMethod(e){const t=ie();t.cartStore.isLoadingCartTotals=!0;try{const n=await DP(e);n.success?(this.setShippingMethods(n.shipping_methods),this.setShippingMessage(n.shipping_status),await t.cartStore.fetchCartTotals()):(t.systemStore.addToastMessage("ERROR",n.error),t.cartStore.isLoadingCartTotals=!1)}catch(n){console.error("Error fetching data: ",n),t.cartStore.isLoadingCartTotals=!1}},async fetchCountriesAndStates(){const e=ie();try{const t=await BP();t.success?this.setCountriesAndStates(t.countries_states):e.systemStore.addToastMessage("ERROR",t.error)}catch(t){console.error("Error fetching data: ",t)}},async fetchInsurance(){const e=ie();try{const t=await $P();t.success?this.setInsurance(t.details):e.systemStore.addToastMessage("ERROR",t.error)}catch(t){console.error("Error fetching data: ",t)}},async changeInsurance(e){const t=ie();try{const n=await UP(e);n.success?(t.shippingStore.fetchInsurance(),t.cartStore.fetchCartTotals(),t.shippingStore.fetchShippingMethods(),t.cartStore.storeCartProducts(n.items)):t.systemStore.addToastMessage("ERROR",n.error)}catch(n){console.error("Error fetching data: ",n)}},applyStructuredAddressToStore(e){e&&(e.address&&this.setShippingAddress1(e.address),e.city&&this.setShippingCity(e.city),e.state_province&&this.setShippingState(e.state_province),e.postal_code&&this.setShippingZip(e.postal_code),e.country&&this.setShippingCountry(e.country))},async fetchSmsTracking(){const e=ie();try{const t=await HP();t.success?this.setSMSTraking(t.details.sms_signup):e.systemStore.addToastMessage("ERROR",t.error)}catch(t){console.error("Error fetching data: ",t)}},async changeSmsTracking(e){try{await zP(e),this.setSMSTraking(e)}catch(t){console.error("Error fetching data: ",t)}},setCountriesAndStates(e){this.countriesAndStates=e},setInsurance(e){this.insurance=e},setLoadingShippingMethodsState(e){this.loadingShippingMethods=e},setShippingMethods(e){this.shippingMethods=e},setShippingMessage(e){this.shippingMessage=e},saveBillingInfo(e){this.billingInfo=e},saveShippingInfo(e){this.shippingInfo={...this.shippingInfo,...e}},setShippingEmail(e){this.shippingInfo.email=e},setShippingFirstName(e){this.shippingInfo.fname=e},setShippingLastName(e){this.shippingInfo.lname=e},setShippingAddress1(e){this.shippingInfo.address1=e},setShippingCountry(e){this.shippingInfo.country=e},setShippingState(e){this.shippingInfo.state=e},setShippingCity(e){this.shippingInfo.city=e},setShippingZip(e){this.shippingInfo.zip=e},setShippingPhone(e){this.shippingInfo.phone_day=e},setBillingFirstName(e){this.billingInfo.b_fname=e},setBillingLastName(e){this.billingInfo.b_lname=e},setBillingAddress1(e){this.billingInfo.b_address1=e},setBillingCountry(e){this.billingInfo.b_country=e},setBillingState(e){this.billingInfo.b_state=e},setBillingCity(e){this.billingInfo.b_city=e},setBillingZip(e){this.billingInfo.b_zip=e},setBillingSameAsShipping(e){this.shippingInfo.setBilling=e},setSMSTraking(e){this.smsSignup=e}},GP=Rt("shipping",{state:()=>RP,getters:LP,actions:KP}),jP={token:null,tacState:!0,selectedPayment:{cc:!0,affirm:!1,paybright:!1,paypal:!1,applepay:!1,gpay:!1,venmo:!1},brainTreeClientInstance:null,processString:null,applePayNonce:null,applePayExpressActive:!1,tacValidation:!1,affirmInfo:null},YP={getToken(e){return e.token},getTacState(e){return e.tacState},getSelectedPayment(e){return e.selectedPayment},getBrainTreeClientInstance(e){return e.brainTreeClientInstance},getProcessString(e){return e.processString},getApplePayExpressNonce(e){return e.applePayNonce},getApplePayExpressActive(e){return e.applePayExpressActive},getTacValidation(e){return e.tacValidation},getAffirmInfo(e){return e.affirmInfo}};function Yi(e){throw new Error('Could not dynamically require "'+e+'". Please configure the dynamicRequireTargets or/and ignoreDynamicRequires option of @rollup/plugin-commonjs appropriately for this require call to work.')}var ff={exports:{}};(function(e,t){(function(n){e.exports=n()})(function(){return function(){function n(i,r,s){function a(c,d){if(!r[c]){if(!i[c]){var u=typeof Yi=="function"&&Yi;
92if(!d&&u)return u(c,!0);if(o)return o(c,!0);var p=new Error("Cannot find module '"+c+"'");throw p.code="MODULE_NOT_FOUND",p}var h=r[c]={exports:{}};i[c][0].call(h.exports,function(m){var v=i[c][1][m];return a(v||m)},h,h.exports,n,i,r,s)}return r[c].exports}for(var o=typeof Yi=="function"&&Yi,l=0;l<s.length;l++)a(s[l]);return a}return n}()({1:[function(n,i,r){var s={};function a(o){var l,c=JSON.stringify(o);if(!o.forceScriptReload&&(l=s[c],l))return l;var d=document.createElement("script"),u=o.dataAttributes||{},p=o.container||document.head;return d.src=o.src,d.id=o.id||"",d.async=!0,o.type&&d.setAttribute("type","".concat(o.type)),o.crossorigin&&d.setAttribute("crossorigin","".concat(o.crossorigin)),o.integrity&&d.setAttribute("integrity","".concat(o.integrity)),Object.keys(u).forEach(function(h){d.setAttribute("data-".concat(h),"".concat(u[h]))}),l=new Promise(function(h,m){d.addEventListener("load",function(){h(d)}),d.addEventListener("error",function(){m(new Error("".concat(o.src," failed to load.")))}),d.addEventListener("abort",function(){m(new Error("".concat(o.src," has aborted.")))}),p.appendChild(d)}),s[c]=l,l}a.clearCache=function(){s={}},i.exports=a},{}],2:[function(n,i,r){i.exports=n("./dist/load-script")},{"./dist/load-script":1}],3:[function(n,i,r){i.exports=function(a){return a=a||window.navigator.userAgent,/Android/i.test(a)}},{}],4:[function(n,i,r){i.exports=function(a){return a=a||window.navigator.userAgent,/CrOS/i.test(a)}},{}],5:[function(n,i,r){var s=n("./is-edge"),a=n("./is-samsung"),o=n("./is-duckduckgo"),l=n("./is-opera"),c=n("./is-silk");i.exports=function(u){return u=u||window.navigator.userAgent,(u.indexOf("Chrome")!==-1||u.indexOf("CriOS")!==-1)&&!s(u)&&!a(u)&&!o(u)&&!l(u)&&!c(u)}},{"./is-duckduckgo":6,"./is-edge":7,"./is-opera":17,"./is-samsung":19,"./is-silk":20}],6:[function(n,i,r){i.exports=function(a){return a=a||window.navigator.userAgent,a.indexOf("DuckDuckGo/")!==-1}},{}],7:[function(n,i,r){i.exports=function(a){return a=a||window.navigator.userAgent,a.indexOf("Edge/")!==-1||a.indexOf("Edg/")!==-1}},{}],8:[function(n,i,r){i.exports=function(a){return a=a||window.navigator.userAgent,/Firefox/i.test(a)}},{}],9:[function(n,i,r){var s=n("detectincognitojs");i.exports=function(){return s.detectIncognito()}},{detectincognitojs:52}],10:[function(n,i,r){i.exports=function(a){return a=a||window.navigator.userAgent,/FxiOS/i.test(a)}},{}],11:[function(n,i,r){var s=n("./is-ios");function a(o){return/\bGSA\b/.test(o)}i.exports=function(l){return l=l||window.navigator.userAgent,s(l)&&a(l)}},{"./is-ios":15}],12:[function(n,i,r){var s=n("./is-ios"),a=n("./is-ios-firefox"),o=/webkit/i;function l(u){return o.test(u)}function c(u){return u.indexOf("CriOS")>-1}function d(u){return u.indexOf("FBAN")>-1}i.exports=function(p){return p=p||window.navigator.userAgent,s(p)&&l(p)&&!c(p)&&!a(p)&&!d(p)}},{"./is-ios":15,"./is-ios-firefox":10}],13:[function(n,i,r){var s=n("./is-ios"),a=n("./is-ios-google-search-app");i.exports=function(l){return l=l||window.navigator.userAgent,s(l)?a(l)?!0:/.+AppleWebKit(?!.*Safari)/i.test(l):!1}},{"./is-ios":15,"./is-ios-google-search-app":11}],14:[function(n,i,r){var s=n("./is-ios-webview");i.exports=function(o,l){return l=typeof l<"u"?l:window.statusbar.visible,s(o)&&l}},{"./is-ios-webview":13}],15:[function(n,i,r){var s=n("./is-ipados");i.exports=function(o,l,c){l===void 0&&(l=!0),o=o||window.navigator.userAgent;var d=/iPhone|iPod|iPad/i.test(o);return l?d||s(o,c):d}},{"./is-ipados":16}],16:[function(n,i,r){i.exports=function(a,o){return a=a||window.navigator.userAgent,o=o||window.document,/Mac|iPad/i.test(a)&&"ontouchend"in o}},{}],17:[function(n,i,r){i.exports=function(a){return a=a||window.navigator.userAgent,a.indexOf("OPR/")!==-1||a.indexOf("Opera/")!==-1||a.indexOf("OPT/")!==-1}},{}],18:[function(n,i,r){i.exports=function(a){return a=a||window.navigator.userAgent,/^Mozilla\/5\.0.*Safari\//.test(a)&&!/(iPhone|iPad|iPod|Android|SM-)/i.test(a)&&!/Chrome|CriOS|FxiOS|OPiOS|mercury/i.test(a)}},{}],19:[function(n,i,r){i.exports=function(a){return a=a||window.navigator.userAgent,/SamsungBrowser/i.test(a)}},{}],20:[function(n,i,r){i.exports=function(a){return a=a||window.navigator.userAgent,a.indexOf("Silk/")!==-1}},{}],21:[function(n,i,r){var s=48,a=n("./is-android"),o=n("./is-ios-firefox"),l=n("./is-ios-webview"),c=n("./is-chrome"),d=n("./is-samsung"),u=n("./is-duckduckgo");function p(_){_=_||window.navigator.userAgent;var b=_.match(/CriOS\/(\d+)\./);if(!b)return!1;var w=parseInt(b[1],10);return w<s}function h(_){return _=_||window.navigator.userAgent,_.indexOf("Opera Mini")>-1}function m(_){var b=/Version\/[\d.]+/i;return _=_||window.navigator.userAgent,a(_)?b.test(_)&&!h(_)&&!u(_):!1}function v(_){return!c(_)&&!d(_)&&/samsung/i.test(_)}i.exports=function(b){return b=b||window.navigator.userAgent,!(l(b)||o(b)||m(b)||h(b)||p(b)||v(b))}},{"./is-android":3,"./is-chrome":5,"./is-duckduckgo":6,"./is-ios-firefox":10,"./is-ios-webview":13,"./is-samsung":19}],22:[function(n,i,r){i.exports=n("./dist/is-android")},{"./dist/is-android":3}],23:[function(n,i,r){i.exports=n("./dist/is-chrome-os")},{"./dist/is-chrome-os":4}],24:[function(n,i,r){i.exports=n("./dist/is-chrome")},{"./dist/is-chrome":5}],25:[function(n,i,r){i.exports=n("./dist/is-firefox")},{"./dist/is-firefox":8}],26:[function(n,i,r){i.exports=n("./dist/is-incognito")},{"./dist/is-incognito":9}],27:[function(n,i,r){i.exports=n("./dist/is-ios-safari")},{"./dist/is-ios-safari":12}],28:[function(n,i,r){i.exports=n("./dist/is-ios-webview")},{"./dist/is-ios-webview":13}],29:[function(n,i,r){i.exports=n("./dist/is-ios-wkwebview")},{"./dist/is-ios-wkwebview":14}],30:[function(n,i,r){i.exports=n("./dist/is-ios")},{"./dist/is-ios":15}],31:[function(n,i,r){i.exports=n("./dist/is-safari")},{"./dist/is-safari":18}],32:[function(n,i,r){i.exports=n("./dist/supports-popups")},{"./dist/supports-popups":21}],33:[function(n,i,r){var s=function(){function a(){this._events={}}return a.prototype.on=function(o,l){this._events[o]?this._events[o].push(l):this._events[o]=[l]},a.prototype.off=function(o,l){var c=this._events[o];if(c){var d=c.indexOf(l);c.splice(d,1)}},a.prototype._emit=function(o){for(var l=[],c=1;c<arguments.length;c++)l[c-1]=arguments[c];var d=this._events[o];d&&d.forEach(function(u){u.apply(void 0,l)})},a.prototype.hasListener=function(o){var l=this._events[o];return l?l.length>0:!1},a.createChild=function(o){o.prototype=Object.create(a.prototype,{constructor:o})},a}();i.exports=s},{}],34:[function(n,i,r){var s=typeof Promise<"u"?Promise:null,a=function(){function o(l){var c=this;if(typeof l=="function"){this._promise=new o.Promise(l);return}this._promise=new o.Promise(function(d,u){c._resolveFunction=d,c._rejectFunction=u}),l=l||{}
92,this._onResolve=l.onResolve||o.defaultOnResolve,this._onReject=l.onReject||o.defaultOnReject,o.shouldCatchExceptions(l)&&this._promise.catch(function(){}),this._resetState()}return o.defaultOnResolve=function(l){return o.Promise.resolve(l)},o.defaultOnReject=function(l){return o.Promise.reject(l)},o.setPromise=function(l){o.Promise=l},o.shouldCatchExceptions=function(l){return l.hasOwnProperty("suppressUnhandledPromiseMessage")?!!l.suppressUnhandledPromiseMessage:!!o.suppressUnhandledPromiseMessage},o.all=function(l){return o.Promise.all(l)},o.allSettled=function(l){return o.Promise.allSettled(l)},o.race=function(l){return o.Promise.race(l)},o.reject=function(l){return o.Promise.reject(l)},o.resolve=function(l){return o.Promise.resolve(l)},o.prototype.then=function(){for(var l,c=[],d=0;d<arguments.length;d++)c[d]=arguments[d];return(l=this._promise).then.apply(l,c)},o.prototype.catch=function(){for(var l,c=[],d=0;d<arguments.length;d++)c[d]=arguments[d];return(l=this._promise).catch.apply(l,c)},o.prototype.resolve=function(l){var c=this;return this.isFulfilled?this:(this._setResolved(),o.Promise.resolve().then(function(){return c._onResolve(l)}).then(function(d){c._resolveFunction(d)}).catch(function(d){c._resetState(),c.reject(d)}),this)},o.prototype.reject=function(l){var c=this;return this.isFulfilled?this:(this._setRejected(),o.Promise.resolve().then(function(){return c._onReject(l)}).then(function(d){c._setResolved(),c._resolveFunction(d)}).catch(function(d){return c._rejectFunction(d)}),this)},o.prototype._resetState=function(){this.isFulfilled=!1,this.isResolved=!1,this.isRejected=!1},o.prototype._setResolved=function(){this.isFulfilled=!0,this.isResolved=!0,this.isRejected=!1},o.prototype._setRejected=function(){this.isFulfilled=!0,this.isResolved=!1,this.isRejected=!0},o.Promise=s,o}();i.exports=a},{}],35:[function(n,i,r){var s=n("./lib/set-attributes"),a=n("./lib/default-attributes"),o=n("./lib/assign");i.exports=function(c){c===void 0&&(c={});var d=document.createElement("iframe"),u=(0,o.assign)({},a.defaultAttributes,c);return u.style&&typeof u.style!="string"&&((0,o.assign)(d.style,u.style),delete u.style),(0,s.setAttributes)(d,u),d.getAttribute("id")||(d.id=d.name),d}},{"./lib/assign":36,"./lib/default-attributes":37,"./lib/set-attributes":38}],36:[function(n,i,r){Object.defineProperty(r,"__esModule",{value:!0}),r.assign=void 0;function s(a){for(var o=[],l=1;l<arguments.length;l++)o[l-1]=arguments[l];return o.forEach(function(c){typeof c=="object"&&Object.keys(c).forEach(function(d){a[d]=c[d]})}),a}r.assign=s},{}],37:[function(n,i,r){Object.defineProperty(r,"__esModule",{value:!0}),r.defaultAttributes=void 0,r.defaultAttributes={src:"about:blank",frameBorder:0,allowtransparency:!0,scrolling:"no"}},{}],38:[function(n,i,r){Object.defineProperty(r,"__esModule",{value:!0}),r.setAttributes=void 0;function s(a,o){for(var l in o)if(o.hasOwnProperty(l)){var c=o[l];c==null?a.removeAttribute(l):a.setAttribute(l,c)}}r.setAttributes=s},{}],39:[function(n,i,r){function s(){if(typeof crypto<"u"&&typeof crypto.randomUUID=="function")try{return crypto.randomUUID()}catch{}if(typeof crypto<"u"&&typeof crypto.getRandomValues=="function"){var a=new Uint8Array(16);crypto.getRandomValues(a),a[6]=a[6]&15|64,a[8]=a[8]&63|128;for(var o=new Array(256),l=0;l<256;l++)o[l]=(l<16?"0":"")+l.toString(16);return o[a[0]]+o[a[1]]+o[a[2]]+o[a[3]]+"-"+o[a[4]]+o[a[5]]+"-"+o[a[6]]+o[a[7]]+"-"+o[a[8]]+o[a[9]]+"-"+o[a[10]]+o[a[11]]+o[a[12]]+o[a[13]]+o[a[14]]+o[a[15]]}throw new Error("@braintree/uuid: No secure random source available")}i.exports=s},{}],40:[function(n,i,r){Object.defineProperty(r,"__esModule",{value:!0});function s(a){return function(){for(var o=[],l=0;l<arguments.length;l++)o[l]=arguments[l];setTimeout(function(){try{a.apply(void 0,o)}catch(c){console.log("Error in callback function"),console.log(c)}},1)}}r.deferred=s},{}],41:[function(n,i,r){Object.defineProperty(r,"__esModule",{value:!0});function s(a){var o=!1;return function(){for(var l=[],c=0;c<arguments.length;c++)l[c]=arguments[c];o||(o=!0,a.apply(void 0,l))}}r.once=s},{}
92],42:[function(n,i,r){Object.defineProperty(r,"__esModule",{value:!0});function s(a,o){if(!o)return a;a.then(function(l){return o(null,l)}).catch(function(l){return o(l)})}r.promiseOrCallback=s},{}],43:[function(n,i,r){var s=n("./lib/deferred"),a=n("./lib/once"),o=n("./lib/promise-or-callback");function l(c){return function(){for(var d=[],u=0;u<arguments.length;u++)d[u]=arguments[u];var p,h=d[d.length-1];return typeof h=="function"&&(p=d.pop(),p=a.once(s.deferred(p))),o.promiseOrCallback(c.apply(this,d),p)}}l.wrapPrototype=function(c,d){d===void 0&&(d={});var u=d.ignoreMethods||[],p=d.transformPrivateMethods===!0,h=Object.getOwnPropertyNames(c.prototype).filter(function(m){var v,_=m!=="constructor"&&typeof c.prototype[m]=="function",b=u.indexOf(m)===-1;return p?v=!0:v=m.charAt(0)!=="_",_&&v&&b});return h.forEach(function(m){var v=c.prototype[m];c.prototype[m]=l(v)}),c},i.exports=l},{"./lib/deferred":40,"./lib/once":41,"./lib/promise-or-callback":42}],44:[function(n,i,r){(function(s,a){a(typeof r=="object"&&typeof i<"u"?r:globalThis.loadAxo={})})(this,function(s){/*! *****************************************************************************
93	    Copyright (c) Microsoft Corporation.
94
95	    Permission to use, copy, modify, and/or distribute this software for any
96	    purpose with or without fee is hereby granted.
97
98	    THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
99	    REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
100	    AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
101	    INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
102	    LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
103	    OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
104	    PERFORMANCE OF THIS SOFTWARE.
105	    ***************************************************************************** */function a(re,be,Y,oe){function K(Z){return Z instanceof Y?Z:new Y(function(me){me(Z)})}return new(Y||(Y=Promise))(function(Z,me){function q(we){try{ge(oe.next(we))}catch(X){me(X)}}function ae(we){try{ge(oe.throw(we))}catch(X){me(X)}}function ge(we){we.done?Z(we.value):K(we.value).then(q,ae)}ge((oe=oe.apply(re,[])).next())})}function o(re,be){var Y={label:0,sent:function(){if(Z[0]&1)throw Z[1];return Z[1]},trys:[],ops:[]},oe,K,Z,me;return me={next:q(0),throw:q(1),return:q(2)},typeof Symbol=="function"&&(me[Symbol.iterator]=function(){return this}),me;function q(ge){return function(we){return ae([ge,we])}}function ae(ge){if(oe)throw new TypeError("Generator is already executing.");for(;Y;)try{if(oe=1,K&&(Z=ge[0]&2?K.return:ge[0]?K.throw||((Z=K.return)&&Z.call(K),0):K.next)&&!(Z=Z.call(K,ge[1])).done)return Z;switch(K=0,Z&&(ge=[ge[0]&2,Z.value]),ge[0]){case 0:case 1:Z=ge;break;case 4:return Y.label++,{value:ge[1],done:!1};case 5:Y.label++,K=ge[1],ge=[0];continue;case 7:ge=Y.ops.pop(),Y.trys.pop();continue;default:if(Z=Y.trys,!(Z=Z.length>0&&Z[Z.length-1])&&(ge[0]===6||ge[0]===2)){Y=0;continue}if(ge[0]===3&&(!Z||ge[1]>Z[0]&&ge[1]<Z[3])){Y.label=ge[1];break}if(ge[0]===6&&Y.label<Z[1]){Y.label=Z[1],Z=ge;break}if(Z&&Y.label<Z[2]){Y.label=Z[2],Y.ops.push(ge);break}Z[2]&&Y.ops.pop(),Y.trys.pop();continue}ge=be.call(re,Y)}catch(we){ge=[6,we],K=0}finally{oe=Z=0}if(ge[0]&5)throw ge[1];return{value:ge[0]?ge[1]:void 0,done:!0}}}var l={},c={};function d(re){var be,Y=JSON.stringify(re);if(!re.forceScriptReload&&(be=c[Y],be))return be;var oe=document.createElement("script"),K=re.dataAttributes||{},Z=re.container||document.head;return oe.src=re.src,oe.id=re.id||"",oe.async=!0,re.type&&oe.setAttribute("type","".concat(re.type)),re.crossorigin&&oe.setAttribute("crossorigin","".concat(re.crossorigin)),Object.keys(K).forEach(function(me){oe.setAttribute("data-".concat(me),"".concat(K[me]))}),be=new Promise(function(me,q){oe.addEventListener("load",function(){me(oe)}),oe.addEventListener("error",function(){q(new Error("".concat(re.src," failed to load.")))}),oe.addEventListener("abort",function(){q(new Error("".concat(re.src," has aborted.")))}),Z.appendChild(oe)}),c[Y]=be,be}d.clearCache=function(){c={}};var u=d,p=function(be){var Y=document.querySelector('link[href="'.concat(be.href,'"]'));if(Y)return Promise.resolve(Y);Y=document.createElement("link");var oe=be.container||document.head;return Y.setAttribute("rel","stylesheet"),Y.setAttribute("type","text/css"),Y.setAttribute("href",be.href),Y.setAttribute("id",be.id),oe.firstChild?oe.insertBefore(Y,oe.firstChild):oe.appendChild(Y),Promise.resolve(Y)};
105Object.defineProperty(l,"__esModule",{value:!0}),l.loadStylesheet=m=l.loadScript=void 0;var h=u,m=l.loadScript=h,v=p;l.loadStylesheet=v;var _="https://www.paypalobjects.com",b={minified:"axo.min",unminified:"axo"},w="fastlane",C="connect-boba",O="".concat(C,"/locales/"),T={AXO_ASSET_NAME:b,AXO_ASSET_PATH:C,LOCALE_PATH:O,CDNX_PROD:_},E={BT:"BT",PPCP:"PPCP"};function y(){return typeof window.define=="function"&&!!window.define.amd}function P(){return y()&&typeof window.requirejs=="function"&&typeof window.requirejs.config=="function"}function A(re,be,Y){var oe,K;return Y===void 0&&(Y=!0),a(this,void 0,void 0,function(){var Z,me;return o(this,function(q){if(Z=L(),Z&&Z[re.module]){if(be&&((oe=Z[re.module])===null||oe===void 0?void 0:oe.VERSION)!==be)throw me=(K=Z[re.module])===null||K===void 0?void 0:K.VERSION,new Error("".concat(re.module," already loaded with version ").concat(me," cannot load version ").concat(be));return[2,!0]}if(!be)throw new Error("Attempted to load ".concat(re.module," without specifying version"));return[2,I(re,be,Y)]})})}function I(re,be,Y){if(Y===void 0&&(Y=!0),y()){var oe=Y?re.amdModule.minified:re.amdModule.unminified;return new Promise(function(Z,me){window.require([oe],Z,me)})}var K=Y?re.script.minified:re.script.unminified;return m({id:"".concat(re.id,"-").concat(be),src:"https://js.braintreegateway.com/web/".concat(be,"/js/").concat(K)})}function L(){return window==null?void 0:window.braintree}var D,z,G={Client:"client",HostedCardFields:"hostedFields"},ne="braintree",W=(D={},D[G.Client]="client",D[G.HostedCardFields]="hosted-fields",D),ue=(z={},z[G.Client]={id:"client",module:G.Client,amdModule:{unminified:"".concat(ne,"/").concat(W[G.Client]),minified:"".concat(ne,"/").concat(W[G.Client],".min")},script:{unminified:"".concat(W[G.Client],".js"),minified:"".concat(W[G.Client],".min.js")}},z[G.HostedCardFields]={id:"hcf",module:G.HostedCardFields,amdModule:{unminified:"".concat(ne,"/").concat(W[G.HostedCardFields]),minified:"".concat(ne,"/").concat(W[G.HostedCardFields],".min")},script:{unminified:"".concat(W[G.HostedCardFields],".js"),minified:"".concat(W[G.HostedCardFields],".min.js")}},z);function H(re){return a(this,void 0,void 0,function(){var be,Y,oe,K;return o(this,function(Z){switch(Z.label){case 0:return performance.mark("pp_axo_sdk_init_invoked"),be=re.btSdkVersion,Y=re.minified,oe=te(re),K=fe(re),re.platform!==E.BT?[3,2]:[4,Promise.all([A(ue.hostedFields,be,Y),x(oe,Y)])];case 1:return Z.sent(),[3,5];case 2:return re.platform!==E.PPCP?[3,4]:[4,Promise.all([A(ue.client,be,Y),A(ue.hostedFields,be,Y),x(oe,Y)])];case 3:return Z.sent(),[3,5];case 4:throw new Error("unsupported axo platform");case 5:return[2,{metadata:{localeUrl:K}}]}})})}function x(re,be){var Y;if(be===void 0&&(be=!0),y()){P()&&requirejs.config({paths:(Y={},Y[w]=re,Y)});var oe="".concat(w,"/").concat(be?T.AXO_ASSET_NAME.minified:T.AXO_ASSET_NAME.unminified);return new Promise(function(K,Z){window.require([oe],K,Z)})}return m({id:"axo-id",src:re,forceScriptReload:!0})}function V(re){var be=re.assetUrl,Y=re.bundleId;return Y?"https://cdn-".concat(Y,".static.engineering.dev.paypalinc.com/").concat(be):"".concat(T.CDNX_PROD,"/").concat(be)}function te(re){var be,Y=(re==null?void 0:re.minified)!==!1?T.AXO_ASSET_NAME.minified:T.AXO_ASSET_NAME.unminified,oe=y()?T.AXO_ASSET_PATH:"".concat(T.AXO_ASSET_PATH,"/").concat(Y,".js");return V({assetUrl:oe,bundleId:(be=re==null?void 0:re.metadata)===null||be===void 0?void 0:be.bundleIdOverride})}function fe(re){var be;return V({assetUrl:T.LOCALE_PATH,bundleId:(be=re==null?void 0:re.metadata)===null||be===void 0?void 0:be.bundleIdOverride})}s.constants=T,s.loadAxo=H})},{}],45:[function(n,i,r){var s=this&&this.__assign||function(){return s=Object.assign||function(C){for(var O,T=1,E=arguments.length;T<E;T++){O=arguments[T];for(var y in O)Object.prototype.hasOwnProperty.call(O,y)&&(C[y]=O[y])}return C},s.apply(this,arguments)},a=n("./lib/card-types"),o=n("./lib/add-matching-cards-to-results"),l=n("./lib/is-valid-input-type"),c=n("./lib/find-best-match"),d=n("./lib/clone"),u={},p={VISA:"visa",MASTERCARD:"mastercard",AMERICAN_EXPRESS:"american-express",DINERS_CLUB:"diners-club",DISCOVER:"discover",JCB:"jcb",UNIONPAY:"unionpay",VERVE:"verve",MAESTRO:"maestro",ELO:"elo",MIR:"mir",HIPER:"hiper",HIPERCARD:"hipercard"},h=[p.VISA,p.MASTERCARD,p.AMERICAN_EXPRESS,p.DINERS_CLUB,p.DISCOVER,p.JCB,p.UNIONPAY,p.VERVE,p.MAESTRO,p.ELO,p.MIR,p.HIPER,p.HIPERCARD],m=(0,d.clone)(h);function v(C){return u[C]||a[C]}function _(){return m.map(function(C){return(0,d.clone)(v(C))})}function b(C,O){O===void 0&&(O=!1);var T=m.indexOf(C);if(!O&&T===-1)throw new Error('"'+C+'" is not a supported card type.');return T}function w(C){var O=[];if(!(0,l.isValidInputType)(C))return O;if(C.length===0)return _();m.forEach(function(E){var y=v(E);(0,o.addMatchingCardsToResults)(C,y,O)});var T=(0,c.findBestMatch)(O);return T?[T]:O}w.getTypeInfo=function(C){return(0,d.clone)(v(C))},w.removeCard=function(C){var O=b(C);m.splice(O,1)},w.addCard=function(C){var O=b(C.type,!0);u[C.type]=C,O===-1&&m.push(C.type)},w.updateCard=function(C,O){var T=u[C]||a[C];if(!T)throw new Error('"'.concat(C,"\" is not a recognized type. Use `addCard` instead.'"));
105if(O.type&&T.type!==O.type)throw new Error("Cannot overwrite type parameter.");var E=(0,d.clone)(T);E=s(s({},E),O),u[E.type]=E},w.changeOrder=function(C,O){var T=b(C);m.splice(T,1),m.splice(O,0,C)},w.resetModifications=function(){m=(0,d.clone)(h),u={}},w.types=p,i.exports=w},{"./lib/add-matching-cards-to-results":46,"./lib/card-types":47,"./lib/clone":48,"./lib/find-best-match":49,"./lib/is-valid-input-type":50}],46:[function(n,i,r){Object.defineProperty(r,"__esModule",{value:!0}),r.addMatchingCardsToResults=void 0;var s=n("./clone"),a=n("./matches");function o(l,c,d){var u,p;for(u=0;u<c.patterns.length;u++){var h=c.patterns[u];if((0,a.matches)(l,h)){var m=(0,s.clone)(c);Array.isArray(h)?p=String(h[0]).length:p=String(h).length,l.length>=p&&(m.matchStrength=p),d.push(m);break}}}r.addMatchingCardsToResults=o},{"./clone":48,"./matches":51}],47:[function(n,i,r){var s={visa:{niceType:"Visa",type:"visa",patterns:[4],gaps:[4,8,12],lengths:[16,18,19],code:{name:"CVV",size:3}},mastercard:{niceType:"Mastercard",type:"mastercard",patterns:[[51,55],[2221,2229],[223,229],[23,26],[270,271],2720],gaps:[4,8,12],lengths:[16],code:{name:"CVC",size:3}},"american-express":{niceType:"American Express",type:"american-express",patterns:[34,37],gaps:[4,10],lengths:[15],code:{name:"CID",size:4}},"diners-club":{niceType:"Diners Club",type:"diners-club",patterns:[[300,305],36,38,39],gaps:[4,10],lengths:[14,16,19],code:{name:"CVV",size:3}},discover:{niceType:"Discover",type:"discover",patterns:[6011,[644,649],65],gaps:[4,8,12],lengths:[16,19],code:{name:"CID",size:3}},jcb:{niceType:"JCB",type:"jcb",patterns:[2131,1800,[3528,3589]],gaps:[4,8,12],lengths:[16,17,18,19],code:{name:"CVV",size:3}},unionpay:{niceType:"UnionPay",type:"unionpay",patterns:[620,[62100,62182],[62184,62187],[62185,62197],[62200,62205],[622010,622999],622018,[62207,62209],[623,626],6270,6272,6276,[627700,627779],[627781,627799],[6282,6289],6291,6292,810,[8110,8131],[8132,8151],[8152,8163],[8164,8171]],gaps:[4,8,12],lengths:[14,15,16,17,18,19],code:{name:"CVN",size:3}},maestro:{niceType:"Maestro",type:"maestro",patterns:[493698,[5e5,504174],[504176,506698],[506779,508999],[56,59],63,67,6],gaps:[4,8,12],lengths:[12,13,14,15,16,17,18,19],code:{name:"CVC",size:3}},elo:{niceType:"Elo",type:"elo",patterns:[401178,401179,438935,457631,457632,431274,451416,457393,504175,[506699,506778],[509e3,509999],627780,636297,636368,[650031,650033],[650035,650051],[650405,650439],[650485,650538],[650541,650598],[650700,650718],[650720,650727],[650901,650978],[651652,651679],[655e3,655019],[655021,655058]],gaps:[4,8,12],lengths:[16],code:{name:"CVE",size:3}},mir:{niceType:"Mir",type:"mir",patterns:[[2200,2204]],gaps:[4,8,12],lengths:[16,17,18,19],code:{name:"CVP2",size:3}},hiper:{niceType:"Hiper",type:"hiper",patterns:[637095,63737423,63743358,637568,637599,637609,637612],gaps:[4,8,12],lengths:[16],code:{name:"CVC",size:3}},hipercard:{niceType:"Hipercard",type:"hipercard",patterns:[606282],gaps:[4,8,12],lengths:[16],code:{name:"CVC",size:3}},verve:{niceType:"Verve",type:"verve",patterns:[[506099,506127],506129,[506133,506150],[506158,506163],506166,506168,506170,506173,[506176,506180],506184,[506187,506188],506191,506195,506197,507865,507866,[507868,507877],[507880,507888],507900,507941],gaps:[4,8,12],lengths:[16,18,19],code:{name:"CVV",size:3}}};i.exports=s},{}],48:[function(n,i,r){Object.defineProperty(r,"__esModule",{value:!0}),r.clone=void 0;function s(a){return a?JSON.parse(JSON.stringify(a)):null}r.clone=s},{}],49:[function(n,i,r){Object.defineProperty(r,"__esModule",{value:!0}),r.findBestMatch=void 0;function s(o){var l=o.filter(function(c){return c.matchStrength}).length;return l>0&&l===o.length}function a(o){return s(o)?o.reduce(function(l,c){return!l||Number(l.matchStrength)<Number(c.matchStrength)?c:l}):null}r.findBestMatch=a},{}],50:[function(n,i,r){Object.defineProperty(r,"__esModule",{value:!0}),r.isValidInputType=void 0;function s(a){return typeof a=="string"||a instanceof String}r.isValidInputType=s},{}],51:[function(n,i,r){Object.defineProperty(r,"__esModule",{value:!0}),r.matches=void 0;function s(l,c,d){var u=String(c).length,p=l.substr(0,u),h=parseInt(p,10);return c=parseInt(String(c).substr(0,p.length),10),d=parseInt(String(d).substr(0,p.length),10),h>=c&&h<=d}function a(l,c){return c=String(c),c.substring(0,l.length)===l.substring(0,c.length)}function o(l,c){return Array.isArray(c)?s(l,c[0],c[1]):a(l,c)}r.matches=o},{}],52:[function(n,i,r){var s=this&&this.__awaiter||function(l,c,d,u){function p(h){return h instanceof d?h:new d(function(m){m(h)})}return new(d||(d=Promise))(function(h,m){function v(w){try{b(u.next(w))}catch(C){m(C)}}function _(w){try{b(u.throw(w))}catch(C){m(C)}}function b(w){w.done?h(w.value):p(w.value).then(v,_)}b((u=u.apply(l,c||[])).next())})},a=this&&this.__generator||function(l,c){var d={label:0,sent:function(){if(h[0]&1)throw h[1];return h[1]},trys:[],ops:[]},u,p,h,m;return m={next:v(0),throw:v(1),return:v(2)},typeof Symbol=="function"&&(m[Symbol.iterator]=function(){return this}),m;function v(b){return function(w){return _([b,w])}}function _(b){if(u)throw new TypeError("Generator is already executing.");for(;m&&(m=0,b[0]&&(d=0)),d;)try{if(u=1,p&&(h=b[0]&2?p.return:b[0]?p.throw||((h=p.return)&&h.call(p),0):p.next)&&!(
105h=h.call(p,b[1])).done)return h;switch(p=0,h&&(b=[b[0]&2,h.value]),b[0]){case 0:case 1:h=b;break;case 4:return d.label++,{value:b[1],done:!1};case 5:d.label++,p=b[1],b=[0];continue;case 7:b=d.ops.pop(),d.trys.pop();continue;default:if(h=d.trys,!(h=h.length>0&&h[h.length-1])&&(b[0]===6||b[0]===2)){d=0;continue}if(b[0]===3&&(!h||b[1]>h[0]&&b[1]<h[3])){d.label=b[1];break}if(b[0]===6&&d.label<h[1]){d.label=h[1],h=b;break}if(h&&d.label<h[2]){d.label=h[2],d.ops.push(b);break}h[2]&&d.ops.pop(),d.trys.pop();continue}b=c.call(l,d)}catch(w){b=[6,w],p=0}finally{u=h=0}if(b[0]&5)throw b[1];return{value:b[0]?b[1]:void 0,done:!0}}};r.__esModule=!0,r.detectIncognito=void 0;function o(){return s(this,void 0,void 0,function(){return a(this,function(l){switch(l.label){case 0:return[4,new Promise(function(c,d){var u="Unknown",p=!1;function h(W){p||(p=!0,c({isPrivate:W,browserName:u}))}function m(){var W=navigator.userAgent;return W.match(/Chrome/)?navigator.brave!==void 0?"Brave":W.match(/Edg/)?"Edge":W.match(/OPR/)?"Opera":"Chrome":"Chromium"}function v(W){try{return W===eval.toString().length}catch{return!1}}function _(){var W=0,ue=parseInt("-1");try{ue.toFixed(ue)}catch(H){W=H.message.length}return W}function b(){return _()===44}function w(){return _()===51}function C(){return _()===25}function O(){return navigator.msSaveBlob!==void 0&&v(39)}function T(){var W;return s(this,void 0,void 0,function(){var ue,H,x;return a(this,function(V){switch(V.label){case 0:return V.trys.push([0,2,,3]),[4,navigator.storage.getDirectory()];case 1:return V.sent(),h(!1),[3,3];case 2:return ue=V.sent(),H=ue,ue instanceof Error&&(H=(W=ue.message)!==null&&W!==void 0?W:ue),typeof H!="string"?(h(!1),[2]):(x=H.includes("unknown transient reason"),h(!!x),[3,3]);case 3:return[2]}})})}function E(){var W=String(Math.random());try{var ue=indexedDB.open(W,1);ue.onupgradeneeded=function(H){var x=H.target.result,V=function(fe){h(fe)};try{x.createObjectStore("t",{autoIncrement:!0}).put(new Blob),V(!1)}catch(fe){var te=fe.message||"";te.includes("are not yet supported")?V(!0):V(!1)}finally{x.close(),indexedDB.deleteDatabase(W)}},ue.onerror=function(){return h(!1)}}catch{h(!1)}}function y(){var W=window.openDatabase,ue=window.localStorage;try{W(null,null,null,null)}catch{h(!0);return}try{ue.setItem("test","1"),ue.removeItem("test")}catch{h(!0);return}h(!1)}function P(){var W;return s(this,void 0,void 0,function(){return a(this,function(ue){switch(ue.label){case 0:return((W=navigator.storage)===null||W===void 0?void 0:W.getDirectory)===void 0?[3,2]:[4,T()];case 1:return ue.sent(),[3,3];case 2:navigator.maxTouchPoints!==void 0?E():y(),ue.label=3;case 3:return[2]}})})}function A(){var W=window;return W.performance!==void 0&&W.performance.memory!==void 0&&W.performance.memory.jsHeapSizeLimit!==void 0?performance.memory.jsHeapSizeLimit:1073741824}function I(){navigator.webkitTemporaryStorage.queryUsageAndQuota(function(W,ue){var H=Math.round(ue/1048576),x=Math.round(A()/(1024*1024))*2;h(H<x)},function(W){d(new Error("detectIncognito somehow failed to query storage quota: "+W.message))})}function L(){var W=window.webkitRequestFileSystem,ue=function(){h(!1)},H=function(){h(!0)};W(0,1,ue,H)}function D(){self.Promise!==void 0&&self.Promise.allSettled!==void 0?I():L()}function z(){return s(this,void 0,void 0,function(){var W,ue,H;return a(this,function(x){switch(x.label){case 0:if(!(navigator.storage&&navigator.storage.getDirectory))return[3,4];x.label=1;case 1:return x.trys.push([1,3,,4]),[4,navigator.storage.getDirectory()];case 2:return x.sent(),h(!1),[3,4];case 3:return W=x.sent(),ue=W instanceof Error&&typeof W.message=="string"?W.message:String(W),typeof ue!="string"?(h(!1),[2]):(H=ue.includes("Security error"),h(H),[2]);case 4:return h(navigator.serviceWorker===void 0),[2]}})})}function G(){h(window.indexedDB===void 0)}function ne(){return s(this,void 0,void 0,function(){return a(this,function(W){switch(W.label){case 0:return b()?(u="Safari",[4,P()]):[3,2];case 1:return W.sent(),[3,6];case 2:return w()?(u=m(),D(),[3,6]):[3,3];case 3:return C()?(u="Firefox",[4,z()]):[3,5];case 4:return W.sent(),[3,6];case 5:O()?(u="Internet Explorer",G()):d(new Error("detectIncognito cannot determine the browser")),W.label=6;case 6:return[2]}})})}ne().catch(d)})];case 1:return[2,l.sent()]}})})}r.detectIncognito=o,typeof window<"u"&&(window.detectIncognito=o),r.default=o},{}
105],53:[function(n,i,r){Object.defineProperty(r,"__esModule",{value:!0}),r.Framebus=void 0;var s=n("./lib"),a=typeof window<"u"&&window.Promise,o=function(){function l(c){c===void 0&&(c={}),this.origin=c.origin||"*",this.channel=c.channel||"",this.verifyDomain=c.verifyDomain,this.targetFrames=c.targetFrames||[],this.limitBroadcastToFramesArray=!!c.targetFrames,this.isDestroyed=!1,this.listeners=[],this.hasAdditionalChecksForOnListeners=!!(this.verifyDomain||this.limitBroadcastToFramesArray)}return l.setPromise=function(c){l.Promise=c},l.target=function(c){return new l(c)},l.prototype.addTargetFrame=function(c){this.limitBroadcastToFramesArray&&this.targetFrames.push(c)},l.prototype.include=function(c){return c==null||c.Window==null||c.constructor!==c.Window?!1:(s.childWindows.push(c),!0)},l.prototype.target=function(c){return l.target(c)},l.prototype.emit=function(c,d,u){if(this.isDestroyed)return!1;var p=this.origin;if(c=this.namespaceEvent(c),(0,s.isntString)(c)||(0,s.isntString)(p))return!1;typeof d=="function"&&(u=d,d=void 0);var h=(0,s.packagePayload)(c,p,d,u);return h?(this.limitBroadcastToFramesArray?this.targetFramesAsWindows().forEach(function(m){(0,s.sendMessage)(m,h,p)}):(0,s.broadcast)(h,{origin:p,frame:window.top||window.self}),!0):!1},l.prototype.emitAsPromise=function(c,d){var u=this;return new l.Promise(function(p,h){var m=u.emit(c,d,function(v){p(v)});m||h(new Error('Listener not added for "'.concat(c,'"')))})},l.prototype.on=function(c,d){if(this.isDestroyed)return!1;var u=this,p=this.origin,h=d;return c=this.namespaceEvent(c),(0,s.subscriptionArgsInvalid)(c,h,p)?!1:(this.hasAdditionalChecksForOnListeners&&(h=function(){for(var m=[],v=0;v<arguments.length;v++)m[v]=arguments[v];u.passesVerifyDomainCheck(this&&this.origin)&&u.hasMatchingTargetFrame(this&&this.source)&&d.apply(void 0,m)}),this.listeners.push({eventName:c,handler:h,originalHandler:d}),s.subscribers[p]=s.subscribers[p]||{},s.subscribers[p][c]=s.subscribers[p][c]||[],s.subscribers[p][c].push(h),!0)},l.prototype.off=function(c,d){var u=d;if(this.isDestroyed)return!1;if(this.hasAdditionalChecksForOnListeners)for(var p=0;p<this.listeners.length;p++){var h=this.listeners[p];h.originalHandler===d&&(u=h.handler)}c=this.namespaceEvent(c);var m=this.origin;if((0,s.subscriptionArgsInvalid)(c,u,m))return!1;var v=s.subscribers[m]&&s.subscribers[m][c];if(!v)return!1;for(var p=0;p<v.length;p++)if(v[p]===u)return v.splice(p,1),!0;return!1},l.prototype.teardown=function(){if(!this.isDestroyed){this.isDestroyed=!0;for(var c=0;c<this.listeners.length;c++){var d=this.listeners[c];this.off(d.eventName,d.handler)}this.listeners.length=0}},l.prototype.passesVerifyDomainCheck=function(c){return this.verifyDomain?this.checkOrigin(c):!0},l.prototype.targetFramesAsWindows=function(){return this.limitBroadcastToFramesArray?this.targetFrames.map(function(c){return c instanceof HTMLIFrameElement?c.contentWindow:c}).filter(function(c){return c}):[]},l.prototype.hasMatchingTargetFrame=function(c){if(!this.limitBroadcastToFramesArray)return!0;var d=this.targetFramesAsWindows().find(function(u){return u===c});return!!d},l.prototype.checkOrigin=function(c){var d,u=document.createElement("a");u.href=location.href,u.protocol==="https:"?d=u.host.replace(/:443$/,""):u.protocol==="http:"?d=u.host.replace(/:80$/,""):d=u.host;var p=u.protocol+"//"+d;return p===c?!0:this.verifyDomain?this.verifyDomain(c):!0},l.prototype.namespaceEvent=function(c){return this.channel?"".concat(this.channel,":").concat(c):c},l.Promise=a,l}();r.Framebus=o},{"./lib":61}],54:[function(n,i,r){var s=n("./lib"),a=n("./framebus");(0,s.attach)(),i.exports=a.Framebus},{"./framebus":53,"./lib":61}],55:[function(n,i,r){Object.defineProperty(r,"__esModule",{value:!0}),r.detach=r.attach=void 0;var s=n("./"),a=!1;function o(){a||typeof window>"u"||(a=!0,window.addEventListener("message",s.onMessage,!1))}r.attach=o;function l(){a=!1,window.removeEventListener("message",s.onMessage,!1)}r.detach=l},{"./":61}],56:[function(n,i,r){Object.defineProperty(r,"__esModule",{value:!0}),r.broadcastToChildWindows=void 0;var s=n("./");function a(o,l,c){for(var d=s.childWindows.length-1;d>=0;d--){var u=s.childWindows[d];u.closed?s.childWindows.splice(d,1):c!==u&&(0,s.broadcast)(o,{origin:l,frame:u.top})}}r.broadcastToChildWindows=a},{"./":61}
105],57:[function(n,i,r){Object.defineProperty(r,"__esModule",{value:!0}),r.broadcast=void 0;var s=n("./");function a(o,l){var c=0,d,u=l.origin,p=l.frame;try{for(p.postMessage(o,u),(0,s.hasOpener)(p)&&p.opener.top!==window.top&&a(o,{origin:u,frame:p.opener.top});d=p.frames[c];)a(o,{origin:u,frame:d}),c++}catch{}}r.broadcast=a},{"./":61}],58:[function(n,i,r){Object.defineProperty(r,"__esModule",{value:!0}),r.subscribers=r.childWindows=r.prefix=void 0,r.prefix="/*framebus*/",r.childWindows=[],r.subscribers={}},{}],59:[function(n,i,r){Object.defineProperty(r,"__esModule",{value:!0}),r.dispatch=void 0;var s=n("./");function a(o,l,c,d,u){if(s.subscribers[o]&&s.subscribers[o][l]){var p=[];c&&p.push(c),d&&p.push(d);for(var h=0;h<s.subscribers[o][l].length;h++)s.subscribers[o][l][h].apply(u,p)}}r.dispatch=a},{"./":61}],60:[function(n,i,r){Object.defineProperty(r,"__esModule",{value:!0}),r.hasOpener=void 0;function s(a){return!(a.top!==a||a.opener==null||a.opener===a||a.opener.closed===!0)}r.hasOpener=s},{}],61:[function(n,i,r){var s=this&&this.__createBinding||(Object.create?function(o,l,c,d){d===void 0&&(d=c);var u=Object.getOwnPropertyDescriptor(l,c);(!u||("get"in u?!l.__esModule:u.writable||u.configurable))&&(u={enumerable:!0,get:function(){return l[c]}}),Object.defineProperty(o,d,u)}:function(o,l,c,d){d===void 0&&(d=c),o[d]=l[c]}),a=this&&this.__exportStar||function(o,l){for(var c in o)c!=="default"&&!Object.prototype.hasOwnProperty.call(l,c)&&s(l,o,c)};Object.defineProperty(r,"__esModule",{value:!0}),a(n("./attach"),r),a(n("./broadcast-to-child-windows"),r),a(n("./broadcast"),r),a(n("./constants"),r),a(n("./dispatch"),r),a(n("./has-opener"),r),a(n("./is-not-string"),r),a(n("./message"),r),a(n("./package-payload"),r),a(n("./send-message"),r),a(n("./subscribe-replier"),r),a(n("./subscription-args-invalid"),r),a(n("./types"),r),a(n("./unpack-payload"),r)},{"./attach":55,"./broadcast":57,"./broadcast-to-child-windows":56,"./constants":58,"./dispatch":59,"./has-opener":60,"./is-not-string":62,"./message":63,"./package-payload":64,"./send-message":65,"./subscribe-replier":66,"./subscription-args-invalid":67,"./types":68,"./unpack-payload":69}],62:[function(n,i,r){Object.defineProperty(r,"__esModule",{value:!0}),r.isntString=void 0;function s(a){return typeof a!="string"}r.isntString=s},{}],63:[function(n,i,r){Object.defineProperty(r,"__esModule",{value:!0}),r.onMessage=void 0;var s=n("./");function a(o){if(!(0,s.isntString)(o.data)){var l=(0,s.unpackPayload)(o);if(l){var c=l.eventData,d=l.reply;(0,s.dispatch)("*",l.event,c,d,o),(0,s.dispatch)(o.origin,l.event,c,d,o),(0,s.broadcastToChildWindows)(o.data,l.origin,o.source)}}}r.onMessage=a},{"./":61}],64:[function(n,i,r){Object.defineProperty(r,"__esModule",{value:!0}),r.packagePayload=void 0;var s=n("./");function a(o,l,c,d){var u,p={event:o,origin:l};typeof d=="function"&&(p.reply=(0,s.subscribeReplier)(d,l)),p.eventData=c;try{u=s.prefix+JSON.stringify(p)}catch(h){throw new Error("Could not stringify event: ".concat(h.message))}return u}r.packagePayload=a},{"./":61}],65:[function(n,i,r){Object.defineProperty(r,"__esModule",{value:!0}),r.sendMessage=void 0;function s(a,o,l){try{a.postMessage(o,l)}catch{}}r.sendMessage=s},{}],66:[function(n,i,r){var s=this&&this.__importDefault||function(c){return c&&c.__esModule?c:{default:c}};Object.defineProperty(r,"__esModule",{value:!0}),r.subscribeReplier=void 0;var a=n("../framebus"),o=s(n("@braintree/uuid"));function l(c,d){var u=(0,o.default)();function p(h,m){c(h,m),a.Framebus.target({origin:d}).off(u,p)}return a.Framebus.target({origin:d}).on(u,p),u}r.subscribeReplier=l},{"../framebus":53,"@braintree/uuid":70}],67:[function(n,i,r){Object.defineProperty(r,"__esModule",{value:!0}),r.subscriptionArgsInvalid=void 0;var s=n("./");function a(o,l,c){return(0,s.isntString)(o)||typeof l!="function"?!0:(0,s.isntString)(c)}r.subscriptionArgsInvalid=a},{"./":61}],68:[function(n,i,r){Object.defineProperty(r,"__esModule",{value:!0})},{}],69:[function(n,i,r){Object.defineProperty(r,"__esModule",{value:!0}),r.unpackPayload=void 0;var s=n("./");function a(o){var l;if(o.data.slice(0,s.prefix.length)!==s.prefix)return!1;try{l=JSON.parse(o.data.slice(s.prefix.length))}catch{return!1}if(l.reply){var c=o.origin,d=o.source,u=l.reply;l.reply=function(h){if(d){var m=(0,s.packagePayload)(u,c,h);m&&d.postMessage(m,c)}}}return l}r.unpackPayload=a},{"./":61}],70:[function(n,i,r){function s(){return"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,function(a){var o=Math.random()*16|0,l=a==="x"?o:o&3|8;return l.toString(16)})}i.exports=s},{}
105],71:[function(n,i,r){Object.defineProperty(r,"__esModule",{value:!0}),r.isIos=r.isIE9=r.isSamsungBrowser=r.isAndroidChrome=r.isKitKatWebview=void 0;var s=typeof window<"u"&&window.navigator&&window.navigator.userAgent,a=n("@braintree/browser-detection/is-android"),o=n("@braintree/browser-detection/is-chrome-os"),l=n("@braintree/browser-detection/is-chrome"),c=n("@braintree/browser-detection/is-ios");r.isIos=c;var d=n("@braintree/browser-detection/is-ie9");r.isIE9=d;var u=/Version\/\d\.\d* Chrome\/\d*\.0\.0\.0/;function p(_){return!l(_)&&_.indexOf("Samsung")>-1}function h(_){return _===void 0&&(_=s),a(_)&&u.test(_)}r.isKitKatWebview=h;function m(_){return _===void 0&&(_=s),(a(_)||o(_))&&l(_)}r.isAndroidChrome=m;function v(_){return _===void 0&&(_=s),/SamsungBrowser/.test(_)||p(_)}r.isSamsungBrowser=v},{"@braintree/browser-detection/is-android":84,"@braintree/browser-detection/is-chrome":86,"@braintree/browser-detection/is-chrome-os":85,"@braintree/browser-detection/is-ie9":87,"@braintree/browser-detection/is-ios":88}],72:[function(n,i,r){var s=n("./lib/device");i.exports=function(){return!(0,s.isSamsungBrowser)()}},{"./lib/device":71}],73:[function(n,i,r){arguments[4][3][0].apply(r,arguments)},{dup:3}],74:[function(n,i,r){arguments[4][4][0].apply(r,arguments)},{dup:4}],75:[function(n,i,r){arguments[4][5][0].apply(r,arguments)},{"./is-duckduckgo":76,"./is-edge":77,"./is-opera":81,"./is-samsung":82,"./is-silk":83,dup:5}],76:[function(n,i,r){arguments[4][6][0].apply(r,arguments)},{dup:6}],77:[function(n,i,r){arguments[4][7][0].apply(r,arguments)},{dup:7}],78:[function(n,i,r){i.exports=function(a){return a=a||window.navigator.userAgent,a.indexOf("MSIE 9")!==-1}},{}],79:[function(n,i,r){arguments[4][15][0].apply(r,arguments)},{"./is-ipados":80,dup:15}],80:[function(n,i,r){arguments[4][16][0].apply(r,arguments)},{dup:16}],81:[function(n,i,r){arguments[4][17][0].apply(r,arguments)},{dup:17}],82:[function(n,i,r){arguments[4][19][0].apply(r,arguments)},{dup:19}],83:[function(n,i,r){arguments[4][20][0].apply(r,arguments)},{dup:20}],84:[function(n,i,r){arguments[4][22][0].apply(r,arguments)},{"./dist/is-android":73,dup:22}],85:[function(n,i,r){arguments[4][23][0].apply(r,arguments)},{"./dist/is-chrome-os":74,dup:23}],86:[function(n,i,r){arguments[4][24][0].apply(r,arguments)},{"./dist/is-chrome":75,dup:24}],87:[function(n,i,r){i.exports=n("./dist/is-ie9")},{"./dist/is-ie9":78}],88:[function(n,i,r){arguments[4][30][0].apply(r,arguments)},{"./dist/is-ios":79,dup:30}],89:[function(n,i,r){i.exports=n("./dist/supports-input-formatting")},{"./dist/supports-input-formatting":72}],90:[function(n,i,r){var s=n("../lib/braintree-error"),a=n("./errors"),o=n("../lib/assign").assign,l=n("../lib/methods"),c=n("../lib/convert-methods-to-error"),d=n("@braintree/wrap-promise");function u(p){this._client=p.client}u.prototype.getRewardsBalance=function(p){var h=p.nonce,m;return h?(m=o({_meta:{source:"american-express"},paymentMethodNonce:h},p),delete m.nonce,this._client.request({method:"get",endpoint:"payment_methods/amex_rewards_balance",data:m}).catch(function(v){return Promise.reject(new s({type:a.AMEX_NETWORK_ERROR.type,code:a.AMEX_NETWORK_ERROR.code,message:"A network error occurred when getting the American Express rewards balance.",details:{originalError:v}}))}
105)):Promise.reject(new s({type:a.AMEX_NONCE_REQUIRED.type,code:a.AMEX_NONCE_REQUIRED.code,message:"getRewardsBalance must be called with a nonce."}))},u.prototype.getExpressCheckoutProfile=function(p){return p.nonce?this._client.request({method:"get",endpoint:"payment_methods/amex_express_checkout_cards/"+p.nonce,data:{_meta:{source:"american-express"},paymentMethodNonce:p.nonce}}).catch(function(h){return Promise.reject(new s({type:a.AMEX_NETWORK_ERROR.type,code:a.AMEX_NETWORK_ERROR.code,message:"A network error occurred when getting the American Express Checkout nonce profile.",details:{originalError:h}}))}):Promise.reject(new s({type:a.AMEX_NONCE_REQUIRED.type,code:a.AMEX_NONCE_REQUIRED.code,message:"getExpressCheckoutProfile must be called with a nonce."}))},u.prototype.teardown=function(){return c(this,l(u.prototype)),Promise.resolve()},i.exports=d.wrapPrototype(u)},{"../lib/assign":146,"../lib/braintree-error":149,"../lib/convert-methods-to-error":151,"../lib/methods":181,"./errors":91,"@braintree/wrap-promise":43}],91:[function(n,i,r){var s=n("../lib/braintree-error");i.exports={AMEX_NONCE_REQUIRED:{type:s.types.MERCHANT,code:"AMEX_NONCE_REQUIRED"},AMEX_NETWORK_ERROR:{type:s.types.NETWORK,code:"AMEX_NETWORK_ERROR"}}},{"../lib/braintree-error":149}],92:[function(n,i,r){var s=n("./american-express"),a=n("../lib/basic-component-verification"),o=n("../lib/create-deferred-client"),l=n("../lib/create-assets-url"),c="3.140.0",d=n("@braintree/wrap-promise");function u(p){var h="American Express";return a.verify({name:h,client:p.client,authorization:p.authorization}).then(function(){return o.create({authorization:p.authorization,client:p.client,debug:p.debug,assetsUrl:l.create(p.authorization),name:h})}).then(function(m){return p.client=m,new s(p)})}i.exports={create:d(u),VERSION:c}},{"../lib/basic-component-verification":147,"../lib/create-assets-url":153,"../lib/create-deferred-client":155,"./american-express":90,"@braintree/wrap-promise":43}],93:[function(n,i,r){var s=n("../lib/braintree-error"),a=n("../lib/analytics"),o=n("./errors"),l=n("../lib/methods"),c=n("../lib/convert-methods-to-error"),d=n("@braintree/wrap-promise"),u=n("../lib/in-iframe");function p(h){this._instantiatedWithClient=!h.useDeferredClient,this._client=h.client,this._createPromise=h.createPromise,this._client&&this._setMerchantIdentifier()}p.prototype._waitForClient=function(){return this._client?Promise.resolve():this._createPromise.then((function(h){this._client=h,this._setMerchantIdentifier()}).bind(this))},p.prototype._setMerchantIdentifier=function(){var h=this._client.getConfiguration().gatewayConfiguration.applePayWeb;h&&Object.defineProperty(this,"merchantIdentifier",{value:h.merchantIdentifier,configurable:!1,writable:!1})},p.prototype.createPaymentRequest=function(h){return this._instantiatedWithClient?this._createPaymentRequestSynchronously(h):this._waitForClient().then((function(){return this._createPaymentRequestSynchronously(h)}).bind(this))},p.prototype._createPaymentRequestSynchronously=function(h){var m=this._client.getConfiguration().gatewayConfiguration.applePayWeb,v={countryCode:m.countryCode,currencyCode:m.currencyCode,merchantCapabilities:m.merchantCapabilities||["supports3DS"],supportedNetworks:m.supportedNetworks.map(function(_){return _==="mastercard"?"masterCard":_})};return Object.assign({},v,h)},p.prototype.performValidation=function(h){var m=this;return!h||!h.validationURL?Promise.reject(new s(o.APPLE_PAY_VALIDATION_URL_REQUIRED)):this._waitForClient().then(function(){var v={validationUrl:h.validationURL,domainName:h.domainName||(u()?window.parent.location.hostname:window.location.hostname),merchantIdentifier:h.merchantIdentifier||m.merchantIdentifier};return h.displayName!=null&&(v.displayName=h.displayName),m._client.request({method:"post",endpoint:"apple_pay_web/sessions",data:{_meta:{source:"apple-pay"},applePayWebSession:v}})}).then(function(v){return a.sendEvent(m._client,"applepay.performValidation.succeeded"),Promise.resolve(v)}).catch(function(v){return a.sendEvent(m._client,"applepay.performValidation.failed"),v.code==="CLIENT_REQUEST_ERROR"?Promise.reject(new s({type:o.APPLE_PAY_MERCHANT_VALIDATION_FAILED.type,code:o.APPLE_PAY_MERCHANT_VALIDATION_FAILED.code,message:o.APPLE_PAY_MERCHANT_VALIDATION_FAILED.message,details:{originalError:v.details.originalError}})):Promise.reject(new s({type:o.APPLE_PAY_MERCHANT_VALIDATION_NETWORK.type,code:o.APPLE_PAY_MERCHANT_VALIDATION_NETWORK.code,message:o.APPLE_PAY_MERCHANT_VALIDATION_NETWORK.message,details:{originalError:v}}))})},p.prototype.tokenize=function(h){var m=this;return h.token?this._waitForClient().then(function(){return m._client.request({method:"post",endpoint:"payment_methods/apple_payment_tokens",data:{_meta:{source:"apple-pay"},applePaymentToken:Object.assign({},h.token,{paymentData:btoa(JSON.stringify(h.token.paymentData))})}})}).then(function(v){return a.sendEvent(m._client,"applepay.tokenize.succeeded"),Promise.resolve(v.applePayCards[0])}).catch(function(v){return a.sendEvent(m._client,"applepay.tokenize.failed"),Promise.reject(new s({type:o.APPLE_PAY_TOKENIZATION.type,code:o.APPLE_PAY_TOKENIZATION.code,message:o.APPLE_PAY_TOKENIZATION.message,details:{originalError:v}}))}):Promise.reject(new s(o.APPLE_PAY_PAYMENT_TOKEN_REQUIRED))},p.prototype.teardown=function(){return c(this,l(p.prototype)),Promise.resolve()},i.exports=d.wrapPrototype(p)},{"../lib/analytics":144,"../lib/braintree-error":149,"../lib/convert-methods-to-error":151,"../lib/in-iframe":175,"../lib/methods":181,"./errors":94,"@braintree/wrap-promise":43}],94:[function(n,i,r){var s=n("../lib/braintree-error");i.exports={APPLE_PAY_NOT_ENABLED:{type:s.types.MERCHANT,code:"APPLE_PAY_NOT_ENABLED",message:"Apple Pay is not enabled for this merchant."},APPLE_PAY_VALIDATION_URL_REQUIRED:{type:s.types.MERCHANT,code:"APPLE_PAY_VALIDATION_URL_REQUIRED",message:"performValidation must be called with a validationURL."},APPLE_PAY_MERCHANT_VALIDATION_NETWORK:{type:s.types.NETWORK,code:"APPLE_PAY_MERCHANT_VALIDATION_NETWORK",message:"A network error occurred when validating the Apple Pay merchant."},APPLE_PAY_MERCHANT_VALIDATION_FAILED:{type:s.types.MERCHANT,code:"APPLE_PAY_MERCHANT_VALIDATION_FAILED",message:"Make sure you have registered your domain name in the Braintree Control Panel."},APPLE_PAY_PAYMENT_TOKEN_REQUIRED:{type:s.types.MERCHANT,code:"APPLE_PAY_PAYMENT_TOKEN_REQUIRED",message:"tokenize must be called with a payment token."},APPLE_PAY_TOKENIZATION:{type:s.types.NETWORK,code:"APPLE_PAY_TOKENIZATION",message:"A network error occurred when processing the Apple Pay payment."}}},{"../lib/braintree-error":149}],95:[function(n,i,r){var s=n("./apple-pay"),a=n("../lib/analytics"),o=n("../lib/braintree-error"),l=n("../lib/basic-component-verification"),c=n("../lib/create-assets-url"),d=n("../lib/create-deferred-client"),u=n("./errors"),p="3.140.0",h=n("@braintree/wrap-promise");
105function m(v){var _="Apple Pay";return l.verify({name:_,client:v.client,authorization:v.authorization}).then(function(){var b,w=d.create({authorization:v.authorization,client:v.client,debug:v.debug,assetsUrl:c.create(v.authorization),name:_}).then(function(C){return C.getConfiguration().gatewayConfiguration.applePayWeb?(a.sendEvent(C,"applepay.initialized"),C):Promise.reject(new o(u.APPLE_PAY_NOT_ENABLED))});return v.createPromise=w,b=new s(v),v.useDeferredClient?b:w.then(function(C){return b._client=C,b})})}i.exports={create:h(m),VERSION:p}},{"../lib/analytics":144,"../lib/basic-component-verification":147,"../lib/braintree-error":149,"../lib/create-assets-url":153,"../lib/create-deferred-client":155,"./apple-pay":93,"./errors":94,"@braintree/wrap-promise":43}],96:[function(n,i,r){var s=n("./constants").BRAINTREE_VERSION,a=n("./request/graphql"),o=n("./request"),l=n("../lib/is-verified-domain"),c=n("../lib/braintree-error"),d=n("../lib/convert-to-braintree-error"),u=n("./get-configuration").getConfiguration,p=n("../lib/create-authorization-data"),h=n("../lib/add-metadata"),m=n("@braintree/wrap-promise"),v=n("../lib/once"),_=n("../lib/deferred"),b=n("../lib/assign").assign,w=n("../lib/analytics"),C=n("./errors"),O=n("../lib/constants").VERSION,T=n("../lib/constants").GRAPHQL_URLS,E=n("../lib/methods"),y=n("../lib/convert-methods-to-error"),P=n("../lib/assets"),A=n("../lib/constants").FRAUDNET_FNCLS,I=n("../lib/constants").FRAUDNET_SOURCE,L=n("../lib/constants").FRAUDNET_URL,D={};function z(W){var ue,H;if(W=W||{},ue=JSON.stringify(W),H=W.gatewayConfiguration,!H)throw new c(C.CLIENT_MISSING_GATEWAY_CONFIGURATION);if(["assetsUrl","clientApiUrl","configUrl"].forEach(function(x){if(x in H&&!l(H[x]))throw new c({type:C.CLIENT_GATEWAY_CONFIGURATION_INVALID_DOMAIN.type,code:C.CLIENT_GATEWAY_CONFIGURATION_INVALID_DOMAIN.code,message:x+" property is on an invalid domain."})}),this.getConfiguration=function(){return JSON.parse(ue)},this._request=o,this._configuration=this.getConfiguration(),this._clientApiBaseUrl=H.clientApiUrl+"/v1/",H.graphQL){if(!l(H.graphQL.url))throw new c({type:C.CLIENT_GATEWAY_CONFIGURATION_INVALID_DOMAIN.type,code:C.CLIENT_GATEWAY_CONFIGURATION_INVALID_DOMAIN.code,message:"graphQL.url property is on an invalid domain."});this._graphQL=new a({graphQL:H.graphQL})}}z.initialize=function(W){var ue,H,x=D[W.authorization];if(x)return w.sendEvent(x,"custom.client.load.cached"),x;try{H=p(W.authorization)}catch{return Promise.reject(new c(C.CLIENT_INVALID_AUTHORIZATION))}return x=u(H,W.sessionId).then(function(V){return W.debug&&(V.isDebug=!0),V.authorization=W.authorization,ue=new z(V),ue}),D[W.authorization]=x,w.sendEvent(x,"custom.client.load.initialized"),x.then(function(V){return w.sendEvent(ue,"custom.client.load.succeeded"),V}).catch(function(V){return delete D[W.authorization],Promise.reject(V)})},z.clearCache=function(){D={}},z.prototype._findOrCreateFraudnetJSON=function(W){var ue=document.querySelector('script[fncls="'+A+'"]'),H,x,V,te;ue||(ue=document.body.appendChild(document.createElement("script")),ue.type="application/json",ue.setAttribute("fncls",A)),H=this.getConfiguration(),x={rda_tenant:"bt_card",mid:H.gatewayConfiguration.merchantId},V=H.authorizationFingerprint,V&&V.split("&").forEach(function(fe){var re=fe.split("=");re[0]==="customer_id"&&re.length>1&&(x.cid=re[1])}),te={f:W.substr(0,32),fp:x,bu:!1,s:I},ue.text=JSON.stringify(te)},z.prototype.request=function(W,ue){var H=this,x=new Promise(function(V,te){var fe,re,be,Y,oe=!!(W.endpoint==="payment_methods/credit_cards"&&H.getConfiguration().gatewayConfiguration.creditCards.collectDeviceData);if(W.api!=="graphQLApi"&&(W.method?W.endpoint||(fe="options.endpoint"):fe="options.method"),fe)throw new c({type:C.CLIENT_OPTION_REQUIRED.type,code:C.CLIENT_OPTION_REQUIRED.code,message:fe+" is required when making a request."});if("api"in W?re=W.api:re="clientApi",Y={method:W.method,graphQL:H._graphQL,timeout:W.timeout,metadata:H._configuration.analyticsMetadata},re==="clientApi")be=H._clientApiBaseUrl,Y.data=h.addMetadata(H._configuration,W.data);else if(re==="graphQLApi")be=T[H._configuration.gatewayConfiguration.environment],W.endpoint="",Y.method="post",Y.data=b({clientSdkMetadata:{platform:H._configuration.analyticsMetadata.platform,source:H._configuration.analyticsMetadata.source,integration:H._configuration.analyticsMetadata.integration,sessionId:H._configuration.analyticsMetadata.sessionId,version:O}},W.data),Y.headers=ne(H._configuration);
105else throw new c({type:C.CLIENT_OPTION_INVALID.type,code:C.CLIENT_OPTION_INVALID.code,message:"options.api is invalid."});Y.url=be+W.endpoint,Y.sendAnalyticsEvent=function(K,Z){Z?w.sendEventPlus(H,K,Z):w.sendEvent(H,K)},H._request(Y,function(K,Z,me){var q,ae;if(ae=G(me,K),ae){te(ae);return}if(re==="graphQLApi"&&Z.errors){te(d(Z.errors,{type:C.CLIENT_GRAPHQL_REQUEST_ERROR.type,code:C.CLIENT_GRAPHQL_REQUEST_ERROR.code,message:C.CLIENT_GRAPHQL_REQUEST_ERROR.message}));return}q=b({_httpStatus:me},Z),oe&&q.creditCards&&q.creditCards.length>0&&(H._findOrCreateFraudnetJSON(q.creditCards[0].nonce),P.loadScript({src:L,forceScriptReload:!0})),V(q)})});if(typeof ue=="function"){ue=v(_(ue)),x.then(function(V){ue(null,V,V._httpStatus)}).catch(function(V){var te=V&&V.details&&V.details.httpStatus;ue(V,null,te)});return}return x};function G(W,ue){var H;if(W===-1?H=new c(C.CLIENT_REQUEST_TIMEOUT):W===401?H=new c(C.CLIENT_AUTHORIZATION_INVALID):W===403?H=new c(C.CLIENT_AUTHORIZATION_INSUFFICIENT):W===429?H=new c(C.CLIENT_RATE_LIMITED):W>=500?H=new c(C.CLIENT_GATEWAY_NETWORK):(W<200||W>=400)&&(H=d(ue,{type:C.CLIENT_REQUEST_ERROR.type,code:C.CLIENT_REQUEST_ERROR.code,message:C.CLIENT_REQUEST_ERROR.message})),H)return H.details=H.details||{},H.details.httpStatus=W,H}z.prototype.toJSON=function(){return this.getConfiguration()},z.prototype.getVersion=function(){return O},z.prototype.teardown=m(function(){var W=this;return delete D[W.getConfiguration().authorization],y(W,E(z.prototype)),Promise.resolve()});function ne(W){var ue=W.authorizationFingerprint||W.authorization;return{Authorization:"Bearer "+ue,"Braintree-Version":s}}i.exports=z},{"../lib/add-metadata":143,"../lib/analytics":144,"../lib/assets":145,"../lib/assign":146,"../lib/braintree-error":149,"../lib/constants":150,"../lib/convert-methods-to-error":151,"../lib/convert-to-braintree-error":152,"../lib/create-authorization-data":154,"../lib/deferred":156,"../lib/is-verified-domain":179,"../lib/methods":181,"../lib/once":182,"./constants":97,"./errors":98,"./get-configuration":99,"./request":112,"./request/graphql":110,"@braintree/wrap-promise":43}],97:[function(n,i,r){i.exports={BRAINTREE_VERSION:"2018-05-10"}},{}],98:[function(n,i,r){var s=n("../lib/braintree-error");i.exports={CLIENT_GATEWAY_CONFIGURATION_INVALID_DOMAIN:{type:s.types.MERCHANT,code:"CLIENT_GATEWAY_CONFIGURATION_INVALID_DOMAIN"},CLIENT_OPTION_REQUIRED:{type:s.types.MERCHANT,code:"CLIENT_OPTION_REQUIRED"}
105,CLIENT_OPTION_INVALID:{type:s.types.MERCHANT,code:"CLIENT_OPTION_INVALID"},CLIENT_MISSING_GATEWAY_CONFIGURATION:{type:s.types.INTERNAL,code:"CLIENT_MISSING_GATEWAY_CONFIGURATION",message:"Missing gatewayConfiguration."},CLIENT_INVALID_AUTHORIZATION:{type:s.types.MERCHANT,code:"CLIENT_INVALID_AUTHORIZATION",message:"Authorization is invalid. Make sure your client token or tokenization key is valid."},CLIENT_GATEWAY_NETWORK:{type:s.types.NETWORK,code:"CLIENT_GATEWAY_NETWORK",message:"Cannot contact the gateway at this time."},CLIENT_REQUEST_TIMEOUT:{type:s.types.NETWORK,code:"CLIENT_REQUEST_TIMEOUT",message:"Request timed out waiting for a reply."},CLIENT_REQUEST_ERROR:{type:s.types.NETWORK,code:"CLIENT_REQUEST_ERROR",message:"There was a problem with your request."},CLIENT_GRAPHQL_REQUEST_ERROR:{type:s.types.NETWORK,code:"CLIENT_GRAPHQL_REQUEST_ERROR",message:"There was a problem with your request."},CLIENT_RATE_LIMITED:{type:s.types.MERCHANT,code:"CLIENT_RATE_LIMITED",message:"You are being rate-limited; please try again in a few minutes."},CLIENT_AUTHORIZATION_INSUFFICIENT:{type:s.types.MERCHANT,code:"CLIENT_AUTHORIZATION_INSUFFICIENT",message:"The authorization used has insufficient privileges."},CLIENT_AUTHORIZATION_INVALID:{type:s.types.MERCHANT,code:"CLIENT_AUTHORIZATION_INVALID",message:"Either the client token has expired and a new one should be generated or the tokenization key has been deactivated or deleted."}}},{"../lib/braintree-error":149}],99:[function(n,i,r){var s=n("../lib/braintree-error"),a=n("@braintree/wrap-promise"),o=n("./request"),l=n("@braintree/uuid"),c=n("../lib/constants"),d=n("./errors"),u=n("./request/graphql"),p=n("../lib/constants").GRAPHQL_URLS,h=n("../lib/is-date-string-before-or-on"),m=n("./constants").BRAINTREE_VERSION;function v(_,b){return new Promise(function(w,C){var O,T,E,y,P=b||l(),A={merchantAppId:window.location.host,platform:c.PLATFORM,sdkVersion:c.VERSION,source:c.SOURCE,integration:c.INTEGRATION,integrationType:c.INTEGRATION,sessionId:P};T=_.attrs,E=_.configUrl,T._meta=A,T.braintreeLibraryVersion=c.BRAINTREE_LIBRARY_VERSION,T.configVersion="3",y={url:E,method:"GET",data:T},T.authorizationFingerprint&&_.graphQL?(h(_.graphQL.date,m)&&(y.graphQL=new u({graphQL:{url:_.graphQL.url,features:["configuration"]}})),y.metadata=A):T.tokenizationKey&&(y.graphQL=new u({graphQL:{url:p[_.environment],features:["configuration"]}}),y.metadata=A),o(y,function(I,L,D){var z;if(I){D===403?z=d.CLIENT_AUTHORIZATION_INSUFFICIENT:D===401?z=d.CLIENT_AUTHORIZATION_INVALID:z=d.CLIENT_GATEWAY_NETWORK,C(new s({type:z.type,code:z.code,message:z.message,details:{originalError:I}}));return}O={authorizationType:T.tokenizationKey?"TOKENIZATION_KEY":"CLIENT_TOKEN",authorizationFingerprint:T.authorizationFingerprint,analyticsMetadata:A,gatewayConfiguration:L},w(O)})})}i.exports={getConfiguration:a(v)}},{"../lib/braintree-error":149,"../lib/constants":150,"../lib/is-date-string-before-or-on":176,"./constants":97,"./errors":98,"./request":112,"./request/graphql":110,"@braintree/uuid":39,"@braintree/wrap-promise":43}],100:[function(n,i,r){var s=n("../lib/braintree-error"),a=n("./client"),o="3.140.0",l=n("@braintree/wrap-promise"),c=n("../lib/errors");function d(u){return u.authorization?a.initialize(u):Promise.reject(new s({type:c.INSTANTIATION_OPTION_REQUIRED.type,code:c.INSTANTIATION_OPTION_REQUIRED.code,message:"options.authorization is required when instantiating a client."}))}i.exports={create:l(d),VERSION:o}},{"../lib/braintree-error":149,"../lib/errors":159,"./client":96,"@braintree/wrap-promise":43}],101:[function(n,i,r){var s=n("../../lib/querystring"),a=n("../../lib/assign").assign,o=n("./prep-body"),l=n("./parse-body"),c=n("./xhr"),d=c.isAvailable,u=n("./graphql/request"),p=n("./default-request"),h=1,m=408,v=/\/merchants\/[A-Za-z0-9_-]+\/client_api/,_=/payment_methods\/.*\/three_d_secure/;function b(E){return!E||E===m}function w(E,y){var P,A,I,L,D,z,G,ne,W,ue,H,x;try{L=new URL(E),P=L.hostname,A=L.pathname}catch{P=(E.match(/^https?:\/\/([^\/]+)/)||[])[1]||"",A=(E.match(/^https?:\/\/[^\/]+(\/.*)$/)||[])[1]||E}I=A.replace(v,"").replace(_,"payment_methods/three_d_secure"),I!=="/v1/tracking/batch/events"&&(D=E.replace(/:443(\/|$)/,"$1"),typeof window<"u"&&window.performance&&window.performance.getEntriesByName&&(H=window.performance.getEntriesByName(D),H&&H.length>0&&(x=H[H.length-1],z=x.connectStart?Math.round(x.connectStart):null,G=x.requestStart?Math.round(x.requestStart):null,W=Math.round(x.startTime),ne=Math.round(x.responseEnd),ue=x.duration?Math.round(x.duration):null,y.sendAnalyticsEvent("core.api-request-latency",{connection_start_time:z,domain:P,duration:ue,endpoint:I,end_time:ne,request_start_time:G,start_time:W}))))}function C(E){var y=!E.data&&E.errors&&E.errors[0]&&E.errors[0].extensions&&E.errors[0].extensions.errorClass;return y==="UNKNOWN"||y==="INTERNAL"}function O(E,y,P){var A,I,L,D,z,G,ne,W=E.url,ue=E.graphQL,H=E.timeout,x=c.getRequestObject(),V=P,te=!!(ue&&ue.isGraphQLRequest(W,E.data));E.headers=a({"Content-Type":"application/json"},E.headers),te?L=new u(E):L=new p(E),W=L.getUrl(),D=L.getBody(),z=L.getMethod(),G=L.getHeaders(),z==="GET"&&(W=s.queryify(W,D),D=null),d?x.onreadystatechange=function(){if(x.readyState===4){if(x.status===0&&te){delete E.graphQL,O(E,y,P);return}if(ne=l(x.responseText),I=L.adaptResponseBody(ne),A=L.determineStatus(x.status,ne),E.sendAnalyticsEvent&&w(W,E),A>=400||A<200){if(te&&C(ne)){delete E.graphQL,O(E,y,P);return}if(y<h&&b(A)){y++,O(E,y,P);return}V(I||"error",null,A||500)}else V(null,I,A)}}:(E.headers&&(W=s.queryify(W,G)),x.onload=function(){V(null,l(x.responseText),x.status)},x.onerror=function(){V("error",null,500)},x.onprogress=function(){},x.ontimeout=function(){V("timeout",null,-1)});try{x.open(z,W,!0)}catch(fe){if(!te)throw fe;delete E.graphQL,O(E,y,P);return}x.timeout=H,d&&Object.keys(G).forEach(function(fe){x.setRequestHeader(fe,G[fe])});try{x.send(o(z,D))}catch{}}function T(E,y){O(E,0,y)}i.exports={request:T}},{"../../lib/assign":146,"../../lib/querystring":183,"./default-request":102,"./graphql/request":111,"./parse-body":113,"./prep-body":114,"./xhr":115}],102:[function(n,i,r){function s(a){this._url=a.url,this._data=a.data,this._method=a.method,this._headers=a.headers}s.prototype.getUrl=function(){return this._url},s.prototype.getBody=function(){return this._data},s.prototype.getMethod=function(){return this._method},s.prototype.getHeaders=function(){return this._headers},s.prototype.adaptResponseBody=function(a){return a},s.prototype.determineStatus=function(a){return a},i.exports=s},{}],103:[function(n,i,r){var s=n("./error"),a=n("../../../../lib/assign").assign,o={creditCard:{AMERICAN_EXPRESS:"American Express",DISCOVER:"Discover",INTERNATIONAL_MAESTRO:"Maestro",JCB:"JCB",MASTERCARD:"MasterCard",SOLO:"Solo",UK_MAESTRO:"UK Maestro",UNION_PAY:"UnionPay",VISA:"Visa",ELO:"Elo",HIPER:"Hiper",HIPERCARD:"Hipercard"},applePayWeb:{VISA:"visa",MASTERCARD:"mastercard",DISCOVER:"discover",AMERICAN_EXPRESS:"amex",INTERNATIONAL_MAESTRO:"maestro",ELO:"elo"},visaCheckout:{VISA:"Visa",MASTERCARD:"MasterCard",DISCOVER:"Discover",AMERICAN_EXPRESS:"American Express"},googlePay:{VISA:"visa",MASTERCARD:"mastercard",DISCOVER:"discover",AMERICAN_EXPRESS:"amex",INTERNATIONAL_MAESTRO:"maestro",ELO:"elo"},masterpass:{VISA:"visa",MASTERCARD:"master",DISCOVER:"discover",AMERICAN_EXPRESS:"amex",DINERS:"diners",INTERNATIONAL_MAESTRO:"maestro",JCB:"jcb"}};function l(u,p){var h;return u.data&&!u.errors?h=c(u,p):h=s(u),h}function c(u,p){var h=u.data.clientConfiguration,m;return m={environment:h.environment.toLowerCase(),clientApiUrl:h.clientApiUrl,assetsUrl:h.assetsUrl,analytics:{url:h.analyticsUrl},merchantId:h.merchantId,venmo:"off"},h.supportedFeatures&&(m.graphQL={url:p._graphQL._config.url,features:h.supportedFeatures.map(function(v){return v.toLowerCase()})}),h.braintreeApi&&(m.braintreeApi=h.braintreeApi),h.applePayWeb&&(m.applePayWeb=h.applePayWeb,m.applePayWeb.supportedNetworks=d(h.applePayWeb.supportedCardBrands,o.applePayWeb),delete m.applePayWeb.supportedCardBrands),h.fastlane&&(m.fastlane=h.fastlane),h.ideal&&(m.ideal=h.ideal),h.creditCard?(m.challenges=h.creditCard.challenges.map(function(v){return v.toLowerCase()}
105),m.creditCards={supportedCardTypes:d(h.creditCard.supportedCardBrands,o.creditCard)},m.threeDSecureEnabled=h.creditCard.threeDSecureEnabled,m.threeDSecure=h.creditCard.threeDSecure):(m.challenges=[],m.creditCards={supportedCardTypes:[]},m.threeDSecureEnabled=!1),h.googlePay&&(m.androidPay={displayName:h.googlePay.displayName,enabled:!0,environment:h.googlePay.environment.toLowerCase(),googleAuthorizationFingerprint:h.googlePay.googleAuthorization,paypalClientId:h.googlePay.paypalClientId,supportedNetworks:d(h.googlePay.supportedCardBrands,o.googlePay)}),h.venmo&&(m.payWithVenmo={merchantId:h.venmo.merchantId,accessToken:h.venmo.accessToken,environment:h.venmo.environment.toLowerCase(),enrichedCustomerDataEnabled:h.venmo.enrichedCustomerDataEnabled}),h.paypal?(m.paypalEnabled=!0,m.paypal=a({},h.paypal),m.paypal.currencyIsoCode=m.paypal.currencyCode,m.paypal.environment=m.paypal.environment.toLowerCase(),delete m.paypal.currencyCode):m.paypalEnabled=!1,h.unionPay&&(m.unionPay={enabled:!0,merchantAccountId:h.unionPay.merchantAccountId}),h.visaCheckout&&(m.visaCheckout={apikey:h.visaCheckout.apiKey,encryptionKey:h.visaCheckout.encryptionKey,externalClientId:h.visaCheckout.externalClientId,supportedCardTypes:d(h.visaCheckout.supportedCardBrands,o.visaCheckout)}),h.masterpass&&(m.masterpass={merchantCheckoutId:h.masterpass.merchantCheckoutId,supportedNetworks:d(h.masterpass.supportedCardBrands,o.masterpass)}),h.usBankAccount&&(m.usBankAccount={routeId:h.usBankAccount.routeId,plaid:{publicKey:h.usBankAccount.plaidPublicKey}}),h.openBanking&&(m.openBanking={businessNames:h.openBanking.businessNames,allowListedDomains:h.openBanking.allowListedDomains,profileId:h.openBanking.profileId}),m}function d(u,p){return u.reduce(function(h,m){return p.hasOwnProperty(m)?h.concat(p[m]):h},[])}i.exports=l},{"../../../../lib/assign":146,"./error":106}],104:[function(n,i,r){var s=n("./error"),a={AMERICAN_EXPRESS:"American Express",DINERS:"Discover",DISCOVER:"Discover",ELO:"Elo",HIPER:"Hiper",HIPERCARD:"Hipercard",INTERNATIONAL_MAESTRO:"Maestro",JCB:"JCB",MASTERCARD:"MasterCard",UK_MAESTRO:"Maestro",UNION_PAY:"UnionPay",VISA:"Visa"},o={YES:"Yes",NO:"No",UNKNOWN:"Unknown"},l={PSDTWO:"psd2"};function c(u){var p;return u.data&&!u.errors?p=d(u):p=s(u),p}function d(u){var p=u.data.tokenizeCreditCardForPayPalConnect,h=p.paymentMethod.details,m=h.last4?h.last4.substr(2,4):"",v=h.binData,_,b;return v&&(["commercial","debit","durbinRegulated","healthcare","payroll","prepaid"].forEach(function(w){v[w]?v[w]=o[v[w]]:v[w]="Unknown"}),["issuingBank","countryOfIssuance","productId","business","consumer","purchase","corporate"].forEach(function(w){v[w]||(v[w]="Unknown")})),_={creditCards:[{binData:v,consumed:!1,description:m?"ending in "+m:"",nonce:p.paymentMethod.id,details:{cardholderName:h.cardholderName,expirationMonth:h.expirationMonth,expirationYear:h.expirationYear,bin:h.bin||"",cardType:a[h.brandCode]||"Unknown",lastFour:h.last4||"",lastTwo:m},type:"CreditCard",threeDSecureInfo:null}]},p.authenticationInsight&&(b=p.authenticationInsight.customerAuthenticationRegulationEnvironment,_.creditCards[0].authenticationInsight={regulationEnvironment:l[b]||b.toLowerCase()}),_}i.exports=c},{"./error":106}],105:[function(n,i,r){var s=n("./error"),a={AMERICAN_EXPRESS:"American Express",DINERS:"Discover",DISCOVER:"Discover",ELO:"Elo",HIPER:"Hiper",HIPERCARD:"Hipercard",INTERNATIONAL_MAESTRO:"Maestro",JCB:"JCB",MASTERCARD:"MasterCard",UK_MAESTRO:"Maestro",UNION_PAY:"UnionPay",VISA:"Visa"},o={YES:"Yes",NO:"No",UNKNOWN:"Unknown"},l={PSDTWO:"psd2"};function c(u){var p;return u.data&&!u.errors?p=d(u):p=s(u),p}function d(u){var p=u.data.tokenizeCreditCard,h=p.creditCard,m=h.last4?h.last4.substr(2,4):"",v=h.binData,_,b;return v&&(["commercial","debit","durbinRegulated","healthcare","payroll","prepaid"].forEach(function(w){v[w]?v[w]=o[v[w]]:v[w]="Unknown"}),["issuingBank","countryOfIssuance","productId","business","consumer","purchase","corporate"].forEach(function(w){v[w]||(v[w]="Unknown")})),_={creditCards:[{binData:v,consumed:!1,description:m?"ending in "+m:"",nonce:p.token,details:{cardholderName:h.cardholderName,expirationMonth:h.expirationMonth,expirationYear:h.expirationYear,bin:h.bin||"",cardType:a[h.brandCode]||"Unknown",lastFour:h.last4||"",lastTwo:m},type:"CreditCard",threeDSecureInfo:null}]},p.authenticationInsight&&(b=p.authenticationInsight.customerAuthenticationRegulationEnvironment,_.credit
105Cards[0].authenticationInsight={regulationEnvironment:l[b]||b.toLowerCase()}),_}i.exports=c},{"./error":106}],106:[function(n,i,r){function s(u){var p,h=u.errors&&u.errors[0]&&u.errors[0].extensions&&u.errors[0].extensions.errorClass;return h==="VALIDATION"?p=o(u):h?p=a(u):p={error:{message:"There was a problem serving your request"},fieldErrors:[]},p}function a(u){return{error:{message:u.errors[0].message},fieldErrors:[]}}function o(u){var p=l(u.errors);return p.length===0?{error:{message:u.errors[0].message}}:{error:{message:d(p)},fieldErrors:p}}function l(u){var p=[];return u.forEach(function(h){h.extensions&&h.extensions.inputPath&&c(h.extensions.inputPath.slice(1),h,p)}),p}function c(u,p,h){var m,v=p.extensions.legacyCode,_=u[0];if(u.length===1){h.push({code:v,field:_,message:p.message});return}h.forEach(function(b){b.field===_&&(m=b)}),m||(m={field:_,fieldErrors:[]},h.push(m)),c(u.slice(1),p,m.fieldErrors)}function d(u){var p={creditCard:"Credit card is invalid"},h=u[0].field;return p[h]}i.exports=s},{}],107:[function(n,i,r){var s="query ClientConfiguration {   clientConfiguration {     analyticsUrl     environment     merchantId     assetsUrl     clientApiUrl     creditCard {       supportedCardBrands       challenges       threeDSecureEnabled       threeDSecure {         cardinalAuthenticationJWT         cardinalSongbirdUrl         cardinalSongbirdIdentityHash       }     }     applePayWeb {       countryCode       currencyCode       merchantIdentifier       supportedCardBrands     }     fastlane {       enabled       tokensOnDemand {         enabled         tokenExchange {           enabled         }       }     }     googlePay {       displayName       supportedCardBrands       environment       googleAuthorization       paypalClientId     }     ideal {       routeId       assetsUrl     }     masterpass {       merchantCheckoutId       supportedCardBrands     }     openBanking {       businessNames       allowListedDomains       profileId     }     paypal {       displayName       clientId       assetsUrl       environment       environmentNoNetwork       unvettedMerchant       braintreeClientId       billingAgreementsEnabled       merchantAccountId       currencyCode       payeeEmail     }     unionPay {       merchantAccountId     }     usBankAccount {       routeId       plaidPublicKey     }     venmo {       merchantId       accessToken       environment       enrichedCustomerDataEnabled    }     visaCheckout {       apiKey       externalClientId       supportedCardBrands     }     braintreeApi {       accessToken       url     }     supportedFeatures   } }";function a(){return{query:s,operationName:"ClientConfiguration"}}i.exports=a},{}],108:[function(n,i,r){var s=n("../../../../lib/assign").assign;function a(u){var p=u.hasAuthenticationInsight,h="mutation TokenizeCreditCardForPayPalConnect($input: TokenizeCreditCardForPayPalConnectInput!";return p&&(h+=", $authenticationInsightInput: AuthenticationInsightInput!"),h+=") {   tokenizeCreditCardForPayPalConnect(input: $input) {     clientMutationId     paymentMethod {       id       details {         ... on CreditCardDetails {       bin       brandCode       last4       cardholderName       expirationMonth      expirationYear      binData {         prepaid         healthcare         debit         durbinRegulated         commercial         payroll         issuingBank         countryOfIssuance         productId         business         consumer         purchase         corporate       }         }       }     }",p&&(h+="    authenticationInsight(input: $authenticationInsightInput) {      customerAuthenticationRegulationEnvironment    }"),h+="  } }",h}function o(u,p){var h=u.creditCard,m=h.fastlane||{},v="fastlane"in h&&"termsAndConditionsVersion"in h.fastlane&&h.fastlane.termsAndConditionsVersion,_="fastlane"in h&&"termsAndConditionsCountry"in h.fastlane&&h.fastlane.termsAndConditionsCountry,b=h.email,w="hasBuyerConsent"in m&&m.hasBuyerConsent,C=h.shippingAddress,O=l(u,p),T=s({},O.input,{email:b,optIn:w,phone:h.phone});return v&&(T.termsAndConditionsVersion=v),_&&(T.termsAndConditionsCountry=_),"authAssertion"in m&&(T.authAssertion=m.authAssertion),C&&(T.shippingAddress=C),{input:T}}function l(u,p){var h=u.creditCard,m=h&&h.billingAddress,v=h&&h.expirationDate,_=h&&(h.expirationMonth||v&&v.split("/")[0].trim()),b=h&&(h.expirationYear||v&&v.split("/")[1].trim()),w={input:{credit
105Card:{number:h&&h.number,expirationMonth:_,expirationYear:b,cvv:h&&h.cvv,cardholderName:h&&h.cardholderName},options:{}}};return p.hasAuthenticationInsight&&(w.authenticationInsightInput={merchantAccountId:u.merchantAccountId}),m&&(w.input.creditCard.billingAddress=m),w.input=c(u,w.input),w}function c(u,p){var h;return u.creditCard&&u.creditCard.options&&typeof u.creditCard.options.validate=="boolean"?h=u.creditCard.options.validate:u.authorizationFingerprint&&u.tokenizationKey||u.authorizationFingerprint?h=!0:u.tokenizationKey&&(h=!1),typeof h=="boolean"&&(p.options=s({validate:h},p.options)),p}function d(u){var p={hasAuthenticationInsight:!!(u.authenticationInsight&&u.merchantAccountId)};return{query:a(p),variables:o(u,p),operationName:"TokenizeCreditCardForPayPalConnect"}}i.exports=d},{"../../../../lib/assign":146}],109:[function(n,i,r){var s=n("../../../../lib/assign").assign;function a(d){var u=d.hasAuthenticationInsight,p="mutation TokenizeCreditCard($input: TokenizeCreditCardInput!";return u&&(p+=", $authenticationInsightInput: AuthenticationInsightInput!"),p+=") {   tokenizeCreditCard(input: $input) {     token     creditCard {       bin       brandCode       last4       cardholderName       expirationMonth      expirationYear      binData {         prepaid         healthcare         debit         durbinRegulated         commercial         payroll         issuingBank         countryOfIssuance         productId         business         consumer         purchase         corporate       }     } ",u&&(p+="    authenticationInsight(input: $authenticationInsightInput) {      customerAuthenticationRegulationEnvironment    }"),p+="  } }",p}function o(d,u){var p=d.creditCard,h=p&&p.billingAddress,m=p&&p.expirationDate,v=p&&(p.expirationMonth||m&&m.split("/")[0].trim()),_=p&&(p.expirationYear||m&&m.split("/")[1].trim()),b={input:{creditCard:{number:p&&p.number,expirationMonth:v,expirationYear:_,cvv:p&&p.cvv,cardholderName:p&&p.cardholderName},options:{}}};return u.hasAuthenticationInsight&&(b.authenticationInsightInput={merchantAccountId:d.merchantAccountId}),h&&(b.input.creditCard.billingAddress=h),b.input=l(d,b.input),b}function l(d,u){var p;return d.creditCard&&d.creditCard.options&&typeof d.creditCard.options.validate=="boolean"?p=d.creditCard.options.validate:d.authorizationFingerprint&&d.tokenizationKey||d.authorizationFingerprint?p=!0:d.tokenizationKey&&(p=!1),typeof p=="boolean"&&(u.options=s({validate:p},u.options)),u}function c(d){var u={hasAuthenticationInsight:!!(d.authenticationInsight&&d.merchantAccountId)};return{query:a(u),variables:o(d,u),operationName:"TokenizeCreditCard"}}i.exports=c},{"../../../../lib/assign":146}],110:[function(n,i,r){var s={tokenize_credit_cards:"payment_methods/credit_cards",configuration:"configuration"},a=["creditCard.options.unionPayEnrollment"];function o(c){this._config=c.graphQL}o.prototype.getGraphQLEndpoint=function(){return this._config.url},o.prototype.isGraphQLRequest=function(c,d){var u,p=this.getClientApiPath(c);return!this._isGraphQLEnabled()||!p||(u=this._config.features.some(function(h){return s[h]===p}),l(d))?!1:u},o.prototype.getClientApiPath=function(c){var d,u="/client_api/v1/",p=c.split(u);return p.length>1&&(d=p[1].split("?")[0]),d},o.prototype._isGraphQLEnabled=function(){return!!this._config};function l(c){return a.some(function(d){var u=d.split(".").reduce(function(p,h){return p&&p[h]},c);return u!==void 0})}i.exports=o},{}],111:[function(n,i,r){var s=n("../../constants").BRAINTREE_VERSION,a=n("../../../lib/assign").assign,o=n("../../../lib/snake-case-to-camel-case"),l=n("../../../lib/is-fastlane-checkout"),c=n("./generators/credit-card-tokenization"),d=n("./adapters/credit-card-tokenization"),u=n("./adapters/credit-card-tokenization-fastlane"),p=n("./generators/credit-card-for-fastlane-tokenization"),h=n("./generators/configuration"),m=n("./adapters/configuration"),v={"payment_methods/credit_cards":function(O,T){return T?p(O):c(O)},configuration:h},_={"payment_methods/credit_cards":function(O,T,E){return E?u(O,T):d(O,T)},configuration:m};function b(O){var T=O.graphQL.getClientApiPath(O.url);this._graphQL=O.graphQL,this._data=O.data,this._method=O.method,this._headers=O.headers,this._clientSdkMetadata={source:O.metadata.source,integration:O.metadata.integration,sessionId:O.metadata.sessionId},this._sendAnalyticsEvent=O.sendAnalyticsEvent||Function.prototype,this._generator=v[T],this._adapter=_[T],this._sendAnalyticsEvent("graphql.init")}b.prototype.getUrl=function(){return this._graphQL.getGraphQLEndpoint()},b.prototype.getBody=function(){var O=C(this._data),T=this._generator(O,l(this._data.creditCard)),E=a({clientSdkMetadata:this._clientSdkMetadata},T);return JSON.stringify(E)},b.prototype.getMethod=function(){return"POST"},b.prototype.getHeaders=function(){var O,T;return this._data.authorizationFingerprint?(this._sendAnalyticsEvent("graphql.authorization-fingerprint"),O=this._data.authorizationFingerprint):(this._sendAnalyticsEvent("graphql.tokenization-key"),O=this._data.tokenizationKey),T={Authorization:"Bearer "+O,"Braintree-Version":s},a({},this._headers,T)},b.prototype.adaptResponseBody=function(O){return this._adapter(O,this,"creditCard"in this._data&&l(this._data.creditCard))},b.prototype.determineStatus=function(O,T){var E,y;return O===200?(y=T.errors&&T.errors[0]&&T.errors[0].extensions&&T.errors[0].extensions.errorClass,T.data&&!T.errors?E=200:y==="VALIDATION"?E=422:y==="AUTHORIZATION"?E=403:y==="AUTHENTICATION"?E=401:w(y,T)?E=403:E=500):O?E=O:E=500,this._sendAnalyticsEvent("graphql.
105status."+O),this._sendAnalyticsEvent("graphql.determinedStatus."+E),E};function w(O,T){return!O&&T.errors[0].message}function C(O){var T={};return Object.keys(O).forEach(function(E){var y=o(E);typeof O[E]=="object"?T[y]=C(O[E]):typeof O[E]=="number"?T[y]=String(O[E]):T[y]=O[E]}),T}i.exports=b},{"../../../lib/assign":146,"../../../lib/is-fastlane-checkout":177,"../../../lib/snake-case-to-camel-case":185,"../../constants":97,"./adapters/configuration":103,"./adapters/credit-card-tokenization":105,"./adapters/credit-card-tokenization-fastlane":104,"./generators/configuration":107,"./generators/credit-card-for-fastlane-tokenization":108,"./generators/credit-card-tokenization":109}],112:[function(n,i,r){var s=n("../../lib/once"),a=n("./ajax-driver");i.exports=function(o,l){l=s(l||Function.prototype),o.method=(o.method||"GET").toUpperCase(),o.timeout=o.timeout==null?6e4:o.timeout,o.data=o.data||{},a.request(o,l)}},{"../../lib/once":182,"./ajax-driver":101}],113:[function(n,i,r){i.exports=function(s){try{s=JSON.parse(s)}catch{}return s}},{}],114:[function(n,i,r){i.exports=function(s,a){if(typeof s!="string")throw new Error("Method must be a string");return s.toLowerCase()!=="get"&&a!=null&&(a=typeof a=="string"?a:JSON.stringify(a)),a}},{}],115:[function(n,i,r){var s=typeof window<"u"&&window.XMLHttpRequest&&"withCredentials"in new window.XMLHttpRequest;function a(){return s?new window.XMLHttpRequest:new window.XDomainRequest}i.exports={isAvailable:s,getRequestObject:a}},{}],116:[function(n,i,r){var s=n("../lib/braintree-error");i.exports={DATA_COLLECTOR_REQUIRES_CREATE_OPTIONS:{type:s.types.MERCHANT,code:"DATA_COLLECTOR_REQUIRES_CREATE_OPTIONS",message:"Data Collector must be created with Kount and/or PayPal."}}},{"../lib/braintree-error":149}],117:[function(n,i,r){var s=n("../lib/constants").FRAUDNET_FNCLS,a=n("../lib/constants").FRAUDNET_SOURCE,o=n("../lib/constants").FRAUDNET_URL,l=n("../lib/assets").loadScript,c=32,d;function u(b){var w=new h;return b=b||{},!b.sessionId&&d?(w.sessionId=d,Promise.resolve(w)):w.initialize(b)}function p(){d=null}function h(){}h.prototype.initialize=function(b){var w=this;this.sessionId=b.sessionId||b.clientSessionId,this.sessionId&&(this.sessionId=this.sessionId.substring(0,c)),b.sessionId||(d=this.sessionId);var C={f:this.sessionId,s:a};return!b.hasOwnProperty("beacon")||b.beacon===!0?C.b=v(this.sessionId):C.bu=!1,b.hasOwnProperty("cb1")&&(C.cb1=b.cb1),this._parameterBlock=_(C,b.environment),l({src:o}).then(function(O){return w._thirdPartyBlock=O,w}).catch(function(){return null})},h.prototype.teardown=function(){m(document.querySelector('iframe[title="ppfniframe"]')),m(document.querySelector('iframe[title="pbf"]')),m(this._parameterBlock),m(this._thirdPartyBlock)};function m(b){b&&b.parentNode&&b.parentNode.removeChild(b)}function v(b){var w=new Date().getTime()/1e3;return"https://b.stats.paypal.com/counter.cgi?i=127.0.0.1&p="+b+"&t="+w+"&a=14"}function _(b,w){var C=document.body.appendChild(document.createElement("script"));return w!=="production"&&(b.sandbox=!0),C.type="application/json",C.setAttribute("fncls",s),
105C.text=JSON.stringify(b),C}i.exports={setup:u,clearSessionIdCache:p}},{"../lib/assets":145,"../lib/constants":150}],118:[function(n,i,r){var s=n("./fraudnet"),a=n("../lib/braintree-error"),o=n("../lib/basic-component-verification"),l=n("../lib/create-deferred-client"),c=n("../lib/create-assets-url"),d=n("../lib/methods"),u=n("../lib/convert-methods-to-error"),p="3.140.0",h=n("@braintree/wrap-promise"),m=n("./errors");function v(w){var C="Data Collector",O={_instances:[]},T={};return o.verify({name:C,client:w.client,authorization:w.authorization}).then(function(){return O._instantiatedWithAClient=!w.useDeferredClient,O._createPromise=l.create({authorization:w.authorization,client:w.client,debug:w.debug,assetsUrl:c.create(w.authorization),name:C}).then(function(E){var y=E.getConfiguration(),P={sessionId:w.riskCorrelationId||w.clientMetadataId||w.correlationId,clientSessionId:y.analyticsMetadata.sessionId,environment:y.gatewayConfiguration.environment,cb1:w.cb1};return w.hasOwnProperty("beacon")&&(P.beacon=w.beacon),s.setup(P).then(function(A){A&&(T.correlation_id=A.sessionId,O._instances.push(A))})}).then(function(){return O._instances.length===0?Promise.reject(new a(m.DATA_COLLECTOR_REQUIRES_CREATE_OPTIONS)):(O.deviceData=JSON.stringify(T),O.rawDeviceData=T,O)}),O.teardown=_(O),O.getDeviceData=b(O),O._instantiatedWithAClient?O._createPromise:O})}function _(w){return h(function(){return w._createPromise.then(function(){w._instances.forEach(function(O){O&&O.teardown()}),u(w,d(w))})})}function b(w){return h(function(O){return O=O||{},w._createPromise.then(function(){return O.raw?Promise.resolve(w.rawDeviceData):Promise.resolve(w.deviceData)})})}i.exports={create:h(v),VERSION:p}},{"../lib/basic-component-verification":147,"../lib/braintree-error":149,"../lib/convert-methods-to-error":151,"../lib/create-assets-url":153,"../lib/create-deferred-client":155,"../lib/methods":181,"./errors":116,"./fraudnet":117,"@braintree/wrap-promise":43}],119:[function(n,i,r){var s=n("../lib/braintree-error");i.exports={FASTLANE_SDK_LOAD_ERROR:{type:s.types.MERCHANT,code:"FASTLANE_SDK_LOAD_ERROR"}}},{"../lib/braintree-error":149}],120:[function(n,i,r){var s=n("../lib/braintree-error"),a=n("./errors"),o=n("../lib/assets").loadFastlane,l=n("@braintree/wrap-promise"),c=n("../lib/assign").assign;function d(u){var p=u.client.getConfiguration(),h=u.client.getVersion(),m=p.gatewayConfiguration.environment,v=!0;return m!=="production"&&(v=!1),o(c({platform:"BT",btSdkVersion:h,minified:v},u)).then(function(_){var b={platform:"BT",authorization:u.authorization,client:u.client,deviceData:u.deviceData};delete u.authorization,delete u.client,delete u.deviceData,delete u.minified,delete u.btSdkVersion;var w;return window.braintree._fastlane&&window.braintree._fastlane.create?w=window.braintree._fastlane.create:w=window.braintree.fastlane.create,w(c({platformOptions:b},u,_.metadata))}).catch(function(_){return Promise.reject(new s({type:a.FASTLANE_SDK_LOAD_ERROR.type,code:a.FASTLANE_SDK_LOAD_ERROR.code,message:_.message}))})}i.exports=l(d)},{"../lib/assets":145,"../lib/assign":146,"../lib/braintree-error":149,"./errors":119,"@braintree/wrap-promise":43}],121:[function(n,i,r){var s=n("../lib/basic-component-verification"),a=n("./fastlane"),o=n("../lib/create-assets-url"),l=n("../lib/create-deferred-client"),c=n("@braintree/wrap-promise"),d="3.140.0",u=n("../lib/assign").assign;function p(h){var m="fastlane";return s.verify({name:m,client:h.client,authorization:h.authorization}).then(function(){return l.create({authorization:h.authorization,client:h.client,assetsUrl:o.create(h.authorization),name:m})}).then(function(v){return a(u({client:v,deviceData:h.deviceData},h))})}i.exports={create:c(p),VERSION:d}},{"../lib/assign":146,"../lib/basic-component-verification":147,"../lib/create-assets-url":153,"../lib/create-deferred-client":155,"./fastlane":120,"@braintree/wrap-promise":43}],122:[function(n,i,r){var s=n("../lib/braintree-error");i.exports={GOOGLE_PAYMENT_NOT_ENABLED:{type:s.types.MERCHANT,code:"GOOGLE_PAYMENT_NOT_ENABLED",message:"Google Pay is not enabled for this merchant."}
105,GOOGLE_PAYMENT_GATEWAY_ERROR:{code:"GOOGLE_PAYMENT_GATEWAY_ERROR",message:"There was an error when tokenizing the Google Pay payment method.",type:s.types.UNKNOWN},GOOGLE_PAYMENT_UNSUPPORTED_VERSION:{code:"GOOGLE_PAYMENT_UNSUPPORTED_VERSION",type:s.types.MERCHANT}}},{"../lib/braintree-error":149}],123:[function(n,i,r){var s=n("../lib/analytics"),a=n("../lib/assign").assign,o=n("../lib/convert-methods-to-error"),l=n("../lib/find"),c=n("../lib/generate-google-pay-configuration"),d=n("../lib/braintree-error"),u=n("./errors"),p=n("../lib/methods"),h=n("@braintree/wrap-promise"),m={1:"_createV1PaymentDataRequest",2:"_createV2PaymentDataRequest"};function v(b){if(this._createPromise=b.createPromise,this._client=b.client,this._useDeferredClient=b.useDeferredClient,this._googlePayVersion=b.googlePayVersion||1,this._googleMerchantId=b.googleMerchantId,this._isUnsupportedGooglePayAPIVersion())throw new d({code:u.GOOGLE_PAYMENT_UNSUPPORTED_VERSION.code,message:"The Braintree SDK does not support Google Pay version "+this._googlePayVersion+". Please upgrade the version of your Braintree SDK and contact support if this error persists.",type:u.GOOGLE_PAYMENT_UNSUPPORTED_VERSION.type})}v.prototype._waitForClient=function(){return this._client?Promise.resolve():this._createPromise.then((function(b){this._client=b}).bind(this))},v.prototype._isUnsupportedGooglePayAPIVersion=function(){return!(this._googlePayVersion in m)},v.prototype._getDefaultConfig=function(){return this._defaultConfig||(this._defaultConfig=c(this._client.getConfiguration(),this._googlePayVersion,this._googleMerchantId)),this._defaultConfig},v.prototype._createV1PaymentDataRequest=function(b){var w=this._getDefaultConfig(),C=b.cardRequirements&&b.cardRequirements.allowedCardNetworks,O=w.cardRequirements.allowedCardNetworks,T=C||O;return b=a({},w,b),b.cardRequirements.allowedCardNetworks=T,b},v.prototype._createV2PaymentDataRequest=function(b){var w=this._getDefaultConfig();return b.allowedPaymentMethods&&b.allowedPaymentMethods.forEach(function(C){var O=l(w.allowedPaymentMethods,"type",C.type);O&&_(C,O)}),b=a({},w,b),b},v.prototype.createPaymentDataRequest=function(b){return this._useDeferredClient?this._waitForClient().then((function(){return this._createPaymentDataRequestSyncronously(b)}).bind(this)):this._createPaymentDataRequestSyncronously(b)},v.prototype._createPaymentDataRequestSyncronously=function(b){var w=a({},b),C=this._googlePayVersion,O=m[C];return w.transactionInfo&&w.transactionInfo.totalPrice&&(w.transactionInfo.totalPrice=w.transactionInfo.totalPrice.toString()),s.sendEvent(this._createPromise,"google-payment.v"+C+".createPaymentDataRequest"),this[O](w)},v.prototype.parseResponse=function(b){var w=this;return Promise.resolve().then(function(){var C,O=b.apiVersion===2?b.paymentMethodData.tokenizationData.token:b.paymentMethodToken.token,T=JSON.parse(O),E=T.error;return E?Promise.reject(E):(s.sendEvent(w._createPromise,"google-payment.parseResponse.succeeded"),T.paypalAccounts?(C=T.paypalAccounts[0],s.sendEvent(w._createPromise,"google-payment.parseResponse.succeeded.paypal"),Promise.resolve({nonce:C.nonce,type:C.type,description:C.description})):(C=T.androidPayCards[0],s.sendEvent(w._createPromise,"google-payment.parseResponse.succeeded.google-payment"),Promise.resolve({nonce:C.nonce,type:C.type,description:C.description,details:{cardType:C.details.cardType,lastFour:C.details.lastFour,lastTwo:C.details.lastTwo,isNetworkTokenized:C.details.isNetworkTokenized,bin:C.details.bin},binData:C.binData})))}).catch(function(C){return s.sendEvent(w._createPromise,"google-payment.parseResponse.failed"),Promise.reject(new d({code:u.GOOGLE_PAYMENT_GATEWAY_ERROR.code,message:u.GOOGLE_PAYMENT_GATEWAY_ERROR.message,type:u.GOOGLE_PAYMENT_GATEWAY_ERROR.type,details:{originalError:C}}))})},v.prototype.teardown=function(){return o(this,p(v.prototype)),Promise.resolve()};
105function _(b,w){Object.keys(w).forEach(function(C){typeof w[C]=="object"?b[C]=a({},w[C],b[C]):b[C]=b[C]||w[C]})}i.exports=h.wrapPrototype(v)},{"../lib/analytics":144,"../lib/assign":146,"../lib/braintree-error":149,"../lib/convert-methods-to-error":151,"../lib/find":161,"../lib/generate-google-pay-configuration":173,"../lib/methods":181,"./errors":122,"@braintree/wrap-promise":43}],124:[function(n,i,r){var s=n("./google-payment"),a=n("../lib/braintree-error"),o=n("../lib/create-assets-url"),l=n("../lib/create-deferred-client"),c=n("../lib/basic-component-verification"),d=n("@braintree/wrap-promise"),u="3.140.0",p=n("./errors");function h(m){var v="Google Pay";return c.verify({name:v,client:m.client,authorization:m.authorization}).then(function(){var _,b;return _=l.create({authorization:m.authorization,client:m.client,debug:m.debug,assetsUrl:o.create(m.authorization),name:v}).then(function(w){var C=w.getConfiguration();return m.client=w,C.gatewayConfiguration.androidPay?w:Promise.reject(new a(p.GOOGLE_PAYMENT_NOT_ENABLED))}),m.createPromise=_,b=new s(m),m.useDeferredClient?b:_.then(function(w){return b._client=w,b})})}i.exports={create:d(h),VERSION:u}},{"../lib/basic-component-verification":147,"../lib/braintree-error":149,"../lib/create-assets-url":153,"../lib/create-deferred-client":155,"./errors":122,"./google-payment":123,"@braintree/wrap-promise":43}],125:[function(n,i,r){var s=n("../../lib/braintree-error"),a=n("../shared/errors"),o=n("../shared/constants").allowedAttributes;function l(d,u){var p;return o.hasOwnProperty(d)?u!=null&&!c(d,u)&&(p=new s({type:a.HOSTED_FIELDS_ATTRIBUTE_VALUE_NOT_ALLOWED.type,code:a.HOSTED_FIELDS_ATTRIBUTE_VALUE_NOT_ALLOWED.code,message:'Value "'+u+'" is not allowed for "'+d+'" attribute.'})):p=new s({type:a.HOSTED_FIELDS_ATTRIBUTE_NOT_SUPPORTED.type,code:a.HOSTED_FIELDS_ATTRIBUTE_NOT_SUPPORTED.code,message:'The "'+d+'" attribute is not supported in Hosted Fields.'}),p}
105function c(d,u){return o[d]==="string"?typeof u=="string"||typeof u=="number":o[d]==="boolean"?String(u)==="true"||String(u)==="false":!1}i.exports=l},{"../../lib/braintree-error":149,"../shared/constants":133,"../shared/errors":134}],126:[function(n,i,r){var s=n("../shared/constants"),a=n("../../lib/use-min");i.exports=function(l,c,d){return l+"/web/"+s.VERSION+"/html/hosted-fields-frame"+a(d)+".html#"+c}},{"../../lib/use-min":187,"../shared/constants":133}],127:[function(n,i,r){var s=n("../shared/constants").navigationDirections,a=n("../shared/browser-detection"),o=n("../shared/focus-intercept"),l=n("../shared/find-parent-tags"),c=["INPUT","SELECT","TEXTAREA"],d=["hidden","button","reset","submit","checkbox","radio","file"];function u(m){return a.hasSoftwareKeyboard()?c.indexOf(m.tagName)>-1&&d.indexOf(m.type)<0:m.type!=="hidden"}function p(m,v){switch(m){case s.BACK:return{checkIndexBounds:function(_){return _<0},indexChange:-1};case s.FORWARD:return{checkIndexBounds:function(_){return _>v-1},indexChange:1}}return{}}function h(m){var v,_;for(v=0;v<m.length;v++)if(_=m[v],u(_))return _;return null}i.exports={removeExtraFocusElements:function(m,v){var _=Array.prototype.slice.call(m.elements),b=h(_),w=h(_.reverse());[b,w].forEach(function(C){C&&o.matchFocusElement(C.getAttribute("id"))&&v(C.getAttribute("id"))})},createFocusChangeHandler:function(m,v){return function(_){var b,w,C,O,T=document.getElementById("bt-"+_.field+"-"+_.direction+"-"+m);if(T){if(C=l(T,"form")[0],document.forms.length<1||!C){v.onRemoveFocusIntercepts();return}C=[].slice.call(C.elements),b=C.indexOf(T),O=p(_.direction,C.length);do{if(b+=O.indexChange,O.checkIndexBounds(b))return;w=C[b]}while(!u(w));o.matchFocusElement(w.getAttribute("id"))?v.onTriggerInputFocus(w.getAttribute("data-braintree-type")):w.focus()}}}}},{"../shared/browser-detection":132,"../shared/constants":133,"../shared/find-parent-tags":135,"../shared/focus-intercept":136}],128:[function(n,i,r){var s=n("../shared/constants").allowedStyles;i.exports=function(o){var l=document.createElement("input"),c={},d;return o[0]==="."&&(o=o.substring(1)),l.className=o,l.style.display="none !important",l.style.position="fixed !important",l.style.left="-99999px !important",l.style.top="-99999px !important",document.body.appendChild(l),d=window.getComputedStyle(l),s.forEach(function(u){var p=d[u];p&&(c[u]=p)}),document.body.removeChild(l),c}},{"../shared/constants":133}],129:[function(n,i,r){var s=n("../../lib/assign").assign,a=n("../../lib/create-assets-url"),o=n("../../lib/is-verified-domain"),l=n("../../lib/destructor"),c=n("@braintree/iframer"),d=n("framebus"),u=n("../../lib/create-deferred-client"),p=n("../../lib/braintree-error"),h=n("./compose-url"),m=n("./get-styles-from-class"),v=n("../shared/constants"),_=n("../shared/errors"),b=n("../../lib/constants").INTEGRATION_TIMEOUT_MS,w=n("@braintree/uuid"),C=n("../shared/find-parent-tags"),O=n("../shared/browser-detection"),T=v.events,E=n("@braintree/event-emitter"),y=n("./inject-frame"),P=n("../../lib/analytics"),A=v.allowedFields,I=n("../../lib/methods"),L=n("../../lib/shadow"),D=n("../../lib/find-root-node"),z=n("../../lib/convert-methods-to-error"),G=n("../../lib/errors"),ne=n("../shared/get-card-types"),W=n("./attribute-validation-error"),ue=n("@braintree/wrap-promise"),H=n("./focus-change"),x=n("../shared/focus-intercept").destroy,V=5;function te(Y){return function(oe){var K,Z=oe.merchantPayload,me=Z.emittedBy,q=Y[me].containerElement;Object.keys(Z.fields).forEach(function(ae){Z.fields[ae].container=Y[ae].containerElement}),K=Z.fields[me],q.classList.toggle(v.externalClasses.FOCUSED,K.isFocused),q.classList.toggle(v.externalClasses.VALID,K.isValid),q.classList.toggle(v.externalClasses.INVALID,!K.isPotentiallyValid),this._state={cards:Z.cards,fields:Z.fields},this._emit(oe.type,Z)}}function fe(Y){var oe=Y.getBoundingClientRect(),K=Math.floor(oe.height/2),Z=Math.floor(oe.width/2);return oe.top<(window.innerHeight-K||document.documentElement.clientHeight-K)&&oe.right>Z&&oe.bottom>K&&oe.left<(window.innerWidth-Z||document.documentElement.clientWidth-Z)}function re(Y){var oe,K,Z,me,q,ae=this,ge={},we={},X=[],B=w(),Se=Y.sessionId;if(this._merchantConfigurationOptions=s({},Y),Y.client?(K=Y.client.getConfiguration(void 0,Se),Z=K.gatewayConfiguration.assetsUrl,me=K.isDebug):(Z=a.create(Y.authorization),me=!!Y.isDebug),this._clientPromise=u.create({client:Y.client,authorization:Y.authorization,debug:me,assetsUrl:Z,name:"Hosted Fields",sessionId:Se}),q=h(Z,B,me),!Y.fields||Object.keys(Y.fields).length===0)throw new p({type:G.INSTANTIATION_OPTION_REQUIRED.type,code:G.INSTANTIATION_OPTION_REQUIRED.code,message:"options.fields is required when instantiating Hosted Fields."});if(Y.binVerificationLength!==void 0&&(typeof Y.binVerificationLength!="number"||Y.binVerificationLength!==6&&Y.binVerificationLength!==8))throw new p({type:G.INSTANTIATION_OPTION_INVA
105LID.type,code:G.INSTANTIATION_OPTION_INVALID.code,message:"options.binVerificationLength must be either 6 or 8."});E.call(this),this._injectedNodes=[],this._destructor=new l,this._fields=ge,this._state={fields:{},cards:ne("")},this._bus=new d({channel:B,verifyDomain:o,targetFrames:[window]}),this._destructor.registerFunctionForTeardown(function(){ae._bus.teardown()}),Y.client?P.sendEvent(this._clientPromise,"custom.hosted-fields.initialized"):P.sendEvent(this._clientPromise,"custom.hosted-fields.initialized.deferred-client"),Object.keys(Y.fields).forEach((function(Ce){var U,j,ce,Ie,De;if(!v.allowedFields.hasOwnProperty(Ce))throw new p({type:_.HOSTED_FIELDS_INVALID_FIELD_KEY.type,code:_.HOSTED_FIELDS_INVALID_FIELD_KEY.code,message:'"'+Ce+'" is not a valid field.'});if(U=Y.fields[Ce],j=U.container||U.selector,typeof j=="string"&&(j=document.querySelector(j)),!j||j.nodeType!==1)throw new p({type:_.HOSTED_FIELDS_INVALID_FIELD_SELECTOR.type,code:_.HOSTED_FIELDS_INVALID_FIELD_SELECTOR.code,message:_.HOSTED_FIELDS_INVALID_FIELD_SELECTOR.message,details:{fieldSelector:U.selector,fieldContainer:U.container,fieldKey:Ce}});if(j.querySelector('iframe[name^="braintree-"]'))throw new p({type:_.HOSTED_FIELDS_FIELD_DUPLICATE_IFRAME.type,code:_.HOSTED_FIELDS_FIELD_DUPLICATE_IFRAME.code,message:_.HOSTED_FIELDS_FIELD_DUPLICATE_IFRAME.message,details:{fieldSelector:U.selector,fieldContainer:U.container,fieldKey:Ce}});if(ce=j,L.isShadowElement(ce)&&(ce=L.transformToSlot(ce,"height: 100%")),U.maxlength&&typeof U.maxlength!="number")throw new p({type:_.HOSTED_FIELDS_FIELD_PROPERTY_INVALID.type,code:_.HOSTED_FIELDS_FIELD_PROPERTY_INVALID.code,message:"The value for maxlength must be a number.",details:{fieldKey:Ce}});if(U.minlength&&typeof U.minlength!="number")throw new p({type:_.HOSTED_FIELDS_FIELD_PROPERTY_INVALID.type,code:_.HOSTED_FIELDS_FIELD_PROPERTY_INVALID.code,message:"The value for minlength must be a number.",details:{fieldKey:Ce}});Ie=c({type:Ce,name:"braintree-hosted-field-"+Ce,style:v.defaultIFrameStyle,title:U.iframeTitle||"Secure Credit Card Frame - "+v.allowedFields[Ce].label}),this._bus.addTargetFrame(Ie),this._injectedNodes.push.apply(this._injectedNodes,y(B,Ie,ce,function(){ae.focus(Ce)})),this._setupLabelFocus(Ce,j),ge[Ce]={frameElement:Ie,containerElement:j},De=new Promise(function(Te){we[Ce]=Te}),X.push(De),this._state.fields[Ce]={isEmpty:!0,isValid:!1,isPotentiallyValid:!0,isFocused:!1,container:j},setTimeout(function(){Ie.src=q},0)}).bind(this)),this._merchantConfigurationOptions.styles&&Object.keys(this._merchantConfigurationOptions.styles).forEach(function(Ce){var U=ae._merchantConfigurationOptions.styles[Ce];typeof U=="string"&&(ae._merchantConfigurationOptions.styles[Ce]=m(U))}),this._bus.on(T.REMOVE_FOCUS_INTERCEPTS,function(Ce){x(Ce&&Ce.id)}),this._bus.on(T.TRIGGER_FOCUS_CHANGE,H.createFocusChangeHandler(B,{onRemoveFocusIntercepts:function(Ce){ae._bus.emit(T.REMOVE_FOCUS_INTERCEPTS,{id:Ce})},onTriggerInputFocus:function(Ce){ae.focus(Ce)}})),this._bus.on(T.READY_FOR_CLIENT,function(Ce){ae._clientPromise.then(function(U){Ce(U)})}),this._bus.on(T.CARD_FORM_ENTRY_HAS_BEGUN,function(){P.sendEvent(ae._clientPromise,"hosted-fields.input.started")}),this._bus.on(T.BIN_AVAILABLE,function(Ce){ae._emit("binAvailable",{bin:Ce})}),oe=setTimeout(function(){P.sendEvent(ae._clientPromise,"custom.hosted-fields.load.timed-out"),ae._emit
105("timeout")},b),Promise.all(X).then(function(Ce){var U=Ce[0];clearTimeout(oe),U(be(ae._merchantConfigurationOptions)),ae._cleanUpFocusIntercepts(),ae._emit("ready")}),this._bus.on(T.FRAME_READY,function(Ce,U){we[Ce.field](U)}),this._bus.on(T.INPUT_EVENT,te(ge).bind(this)),this._destructor.registerFunctionForTeardown(function(){var Ce,U,j;for(Ce=0;Ce<ae._injectedNodes.length;Ce++)U=ae._injectedNodes[Ce],j=U.parentNode,j.removeChild(U),j.classList.remove(v.externalClasses.FOCUSED,v.externalClasses.INVALID,v.externalClasses.VALID)}),this._destructor.registerFunctionForTeardown(function(){x()}),this._destructor.registerFunctionForTeardown(function(){var Ce=I(re.prototype).concat(I(E.prototype));z(ae,Ce)})}E.createChild(re),re.prototype._setupLabelFocus=function(Y,oe){var K,Z,me=this,q=D(oe);if(oe.id==null)return;function ae(){me.focus(Y)}for(K=Array.prototype.slice.call(document.querySelectorAll('label[for="'+oe.id+'"]')),q!==document&&(K=K.concat(Array.prototype.slice.call(q.querySelectorAll('label[for="'+oe.id+'"]')))),K=K.concat(C(oe,"label")),K=K.filter(function(ge,we,X){return X.indexOf(ge)===we}),Z=0;Z<K.length;Z++)K[Z].addEventListener("click",ae,!1);this._destructor.registerFunctionForTeardown(function(){for(Z=0;Z<K.length;Z++)K[Z].removeEventListener("click",ae,!1)})},re.prototype._getAnyFieldContainer=function(){var Y=this;return Object.keys(this._fields).reduce(function(oe,K){return oe||Y._fields[K].containerElement},null)},re.prototype._cleanUpFocusIntercepts=function(){var Y,oe;document.forms.length<1?this._bus.emit(T.REMOVE_FOCUS_INTERCEPTS):(Y=this._getAnyFieldContainer(),oe=C(Y,"form")[0],oe?H.removeExtraFocusElements(oe,(function(K){this._bus.emit(T.REMOVE_FOCUS_INTERCEPTS,{id:K})}).bind(this)):this._bus.emit(T.REMOVE_FOCUS_INTERCEPTS))},re.prototype._attachInvalidFieldContainersToError=function(Y){Y.details&&Y.details.invalidFieldKeys&&Y.details.invalidFieldKeys.length>0&&(Y.details.invalidFields={},Y.details.invalidFieldKeys.forEach((function(oe){Y.details.invalidFields[oe]=this._fields[oe].containerElement}).bind(this)))},re.prototype.getChallenges=function(){return this._clientPromise.then(function(Y){return Y.getConfiguration().gatewayConfiguration.challenges})},re.prototype.getSupportedCardTypes=function(){return this._clientPromise.then(function(Y){var oe=Y.getConfiguration().gatewayConfiguration.creditCards.supportedCardTypes.map(function(K){return K==="MasterCard"?"Mastercard":K});return oe})},re.prototype.teardown=function(){var Y=this;return new Promise(function(oe,K){Y._destructor.teardown(function(Z){P.sendEvent(Y._clientPromise,"custom.hosted-fields.teardown-completed"),Z?K(Z):oe()})})},re.prototype.tokenize=function(Y){var oe=this;return Y||(Y={}),new Promise(function(K,Z){oe._bus.emit(T.TOKENIZATION_REQUEST,Y,function(me){var q=me[0],ae=me[1];q?(oe._attachInvalidFieldContainersToError(q),Z(new p(q))):K(ae)})})},re.prototype.addClass=function(Y,oe){var K;return A.hasOwnProperty(Y)?this._fields.hasOwnProperty(Y)?this._bus.emit(T.ADD_CLASS,{field:Y,classname:oe}):K=new p({type:_.HOSTED_FIELDS_FIELD_NOT_PRESENT.type,code:_.HOSTED_FIELDS_FIELD_NOT_PRESENT.code,message:'Cannot add class to "'+Y+'" field because it is not part of the current Hosted Fields options.'}):K=new p({type:_.HOSTED_FIELDS_FIELD_INVALID.type,code:_.HOSTED_FIELDS_FIELD_INVALID.code,message:'"'+Y+'" is not a valid field. You must use a valid field option when adding a class.'}),K?Promise.reject(K):Promise.resolve()},re.prototype.removeClass=function(Y,oe){var K;return A.hasOwnProperty(Y)?this._fields.hasOwnProperty(Y)?this._bus.emit(T.REMOVE_CLASS,{field:Y,classname:oe}):K=new p({type:_.HOSTED_FIELDS_FIELD_NOT_PRESENT.type,code:_.HOSTED_FIELDS_FIELD_NOT_PRESENT.code,message:'Cannot remove class from "'+Y+'" field because it is not part of the current Hosted Fields options.'}):K=new p({type:_.HOSTED_FIELDS_FIELD_INVALID.type,code:_.HOSTED_FIELDS_FIELD_INVALID.code,message:'"'+Y+'" is not a valid field. You must use a valid field option when removing a class.'}),K?Promise.reject(K):Promise.resolve()},re.prototype.setAttribute=function(Y){var oe,K;return A.hasOwnProperty(Y.field)?this._fields.hasOwnProperty(Y.field)?(oe=W(Y.attribute,Y.value),oe?K=oe:this._bus.emit(T.SET_ATTRIBUTE,{field:Y.field,attribute:Y.attribute,value:Y.value})):K=new p({type:_.HOSTED_FIELDS_FIELD_NOT_PRESENT.type,code:_.HOSTED_FIELDS_FIELD_NOT_PRESENT.code,message:'Cannot set attribute for "'+Y.field+'" field because it is not part of the current Hosted Fields options.'}):K=new p({type:_.HOSTED_FIELDS_FIELD_INVALID.type,code:_.HOSTED_FIELDS_FIELD_INVALID.code,message:'"'+Y.field+'" is not a valid field. You must use a valid field option when setting an attribute.'}),K?Promise.reject(K):Promise.resolve()},re.prototype.setMonthOptions=function(Y){var oe=this,K=this._merchantConfigurationOptions.fields,Z;return K.expirationMonth?K.expirationMonth.select||(Z="Expiration month field must be a select element."):Z="Expiration month field must exist to use setMonthOptions.",Z?Promise.reject(new p({type:_.HOSTED_FIELDS_FIELD_PROPERTY_INVALID.type,code:_.HOSTED_FIELDS_FIELD_PROPERTY_INVALID.code,message:Z})):new Promise(function(me){oe._bus.emit(T.SET_MONTH_OPTIONS,Y,me)})},re.prototype.setMessage=function(Y){this._bus.emit(T.SET_MESSAGE,{field:Y.field,message:Y.message})},re.prototype.removeAttribute=function(Y){var oe,K;return A.hasOwnProperty(Y.field)?this._fields.hasOwnProperty(Y.field)?(oe=W(Y.attribute),oe?K=oe:this._bus.emit(T.REMOVE_ATTRIBUTE,{field:Y.field,attribute:Y.attribute})):K=new p({type:_.HOSTED_FIELDS_FIELD_NOT_PRESENT.type,code:_.HOSTED_FIELDS_FIELD_NOT_PRESENT.code,message:'Cannot remove attribute for "'+Y.field+'" field because it is not part of the current Hosted Fields options.'}):K=new p({type:_.HOSTED_FIELDS_FIELD_INVALID.type,code:_.HOSTED_FIELDS_FIELD_INVALID.code,message:'"'+Y.field+'" is not a valid field. You must use a valid field option when removing an attribute.'}),K?Promise.reject(K):Promise.resolve()},re.prototype.setPlaceholder=function(Y,oe){return this.setAttribute({field:Y,attribute:"placeholder",value:oe})},re.prototype.clear=function(Y){var oe;return A.hasOwnProperty(Y)?this._fields.hasOwnProperty(Y)?this._bus.emit(T.CLEAR_FIELD,{field:Y}):oe=new p({type:_.HOSTED_FIELDS_FIELD_NOT_PRESENT.type,code:_.HOSTED_FIELDS_FIELD_NOT_PRESENT.code,message:'Cannot clear "'+Y+'" field because it is not part of the current Hosted Fields options.'}):oe=new p({type:_.HOSTED_FIELDS_FIELD_INVALID.type,code:_.HOSTED_FIELDS_FIELD_INVALID.code,message:'"'+Y+'" is not a valid field. You must use a valid field option when clearing a field.'}),oe?Promise.reject(oe):Promise.resolve()}
105,re.prototype.focus=function(Y){var oe,K=this._fields[Y];return A.hasOwnProperty(Y)?this._fields.hasOwnProperty(Y)?(K.frameElement.focus(),this._bus.emit(T.TRIGGER_INPUT_FOCUS,{field:Y}),O.isIos()&&setTimeout(function(){fe(K.containerElement)||K.containerElement.scrollIntoView()},V)):oe=new p({type:_.HOSTED_FIELDS_FIELD_NOT_PRESENT.type,code:_.HOSTED_FIELDS_FIELD_NOT_PRESENT.code,message:'Cannot focus "'+Y+'" field because it is not part of the current Hosted Fields options.'}):oe=new p({type:_.HOSTED_FIELDS_FIELD_INVALID.type,code:_.HOSTED_FIELDS_FIELD_INVALID.code,message:'"'+Y+'" is not a valid field. You must use a valid field option when focusing a field.'}),oe?Promise.reject(oe):Promise.resolve()},re.prototype.getState=function(){return this._state};function be(Y){var oe=s({},Y);return oe.fields=s({},oe.fields),Object.keys(oe.fields).forEach(function(K){oe.fields[K]=s({},oe.fields[K]),delete oe.fields[K].container}),oe}i.exports=ue.wrapPrototype(re)},{"../../lib/analytics":144,"../../lib/assign":146,"../../lib/braintree-error":149,"../../lib/constants":150,"../../lib/convert-methods-to-error":151,"../../lib/create-assets-url":153,"../../lib/create-deferred-client":155,"../../lib/destructor":157,"../../lib/errors":159,"../../lib/find-root-node":160,"../../lib/is-verified-domain":179,"../../lib/methods":181,"../../lib/shadow":184,"../shared/browser-detection":132,"../shared/constants":133,"../shared/errors":134,"../shared/find-parent-tags":135,"../shared/focus-intercept":136,"../shared/get-card-types":137,"./attribute-validation-error":125,"./compose-url":126,"./focus-change":127,"./get-styles-from-class":128,"./inject-frame":130,"@braintree/event-emitter":33,"@braintree/iframer":35,"@braintree/uuid":39,"@braintree/wrap-promise":43,framebus:54}],130:[function(n,i,r){var s=n("../shared/focus-intercept"),a=n("../shared/constants").navigationDirections;i.exports=function(l,c,d,u){var p=c.getAttribute("type"),h=document.createElement("div"),m=document.createDocumentFragment(),v=s.generate(l,p,a.BACK,u),_=s.generate(l,p,a.FORWARD,u);return h.style.clear="both",m.appendChild(v),m.appendChild(c),m.appendChild(_),m.appendChild(h),d.appendChild(m),[c,h]}},{"../shared/constants":133,"../shared/focus-intercept":136}],131:[function(n,i,r){var s=n("./external/hosted-fields"),a=n("../lib/basic-component-verification"),o=n("./shared/errors"),l=n("restricted-input/supports-input-formatting"),c=n("@braintree/wrap-promise"),d=n("../lib/braintree-error"),u="3.140.0";function p(h){return a.verify({name:"Hosted Fields",authorization:h.authorization,client:h.client}).then(function(){var m=new s(h);return new Promise(function(v,_){m.on("ready",function(){v(m)}),m.on("timeout",function(){_(new d(o.HOSTED_FIELDS_TIMEOUT))})})})}i.exports={supportsInputFormatting:l,create:c(p),VERSION:u}},{"../lib/basic-component-verification":147,"../lib/braintree-error":149,"./external/hosted-fields":129,"./shared/errors":134,"@braintree/wrap-promise":43,"restricted-input/supports-input-formatting":89}],132:[function(n,i,r){var s=n("@braintree/browser-detection/is-android"),a=n("@braintree/browser-detection/is-chrome-os"),o=n("@braintree/browser-detection/is-ios"),l=n("@braintree/browser-detection/is-chrome"),c=n("@braintree/browser-detection/is-safari"),d=n("@braintree/browser-detection/is-ios-safari");function u(){return s()||a()||o()}function p(){return l()&&o()}i.exports={isAndroid:s,isChromeOS:a,isChromeIos:p,isFirefox:n("@braintree/browser-detection/is-firefox"),isIos:o,isIosWebview:n("@braintree/browser-detection/is-ios-webview"),isSafari:c,isIosSafari:d,hasSoftwareKeyboard:u}},{"@braintree/browser-detection/is-android":22,"@braintree/browser-detection/is-chrome":24,"@braintree/browser-detection/is-chrome-os":23,"@braintree/browser-detection/is-firefox":25,"@braintree/browser-detection/is-ios":30,"@braintree/browser-detection/is-ios-safari":27,"@braintree/browser-detection/is-ios-webview":28,"@braintree/browser-detection/is-safari":31}],133:[function(n,i,r){var s=n("../../lib/enumerate"),a=n("./errors"),o="3.140.0",l={VERSION:o,maxExpirationYearAge:19,externalEvents:{FOCUS:"focus",BLUR:"blur",EMPTY:"empty",NOT_EMPTY:"notEmpty",VALIDITY_CHANGE:"validityChange",CARD_TYPE_CHANGE:"cardTypeChange"},defaultMaxLengths:{number:19,postalCode:8,expirationDate:7,expirationMonth:2,expirationYear:4,cvv:3},externalClasses:{FOCUSED:"braintree-hosted-fields-focused",INVALID:"braintree-hosted-fields-invalid",VALID:"braintree-hosted-fields-valid"},navigationDirections:{BACK:"before",FORWARD:"after"},defaultIFrameStyle:{border:"none",width:"100%",height:"100%",float:"left"},tokenizationErrorCodes:{81724:a.HOSTED_FIELDS_TOKENIZATION_FAIL_ON_DUPLICATE,81736:a.HOSTED_FIELDS_TOKENIZATION_CVV_VERIFICATION_FAILED},allowedStyles:["-moz-appearance","-moz-box-shadow","-moz-osx-font-smoothing","-moz-tap-highlight-color","-moz-transition","-webkit-appearance","-webkit-box-shadow","-webkit-font-smoothing","-webkit-tap-highlight-color","-webkit-text-fill-color","-webkit-transition","appearance","box-shadow","color","direction","font","font-family","font-size","font-size-adjust","font-stretch","font-style","font-variant","font-variant-alternates","font-variant-caps","font-variant-east-asian","font-variant-ligatures","font-variant-numeric","font-weight","letter-spacing","line-height","margin","margin-top","margin-right","margin-bottom","margin-left","opacity","outline","padding","padding-top","padding-right","padding-bottom","padding-left","text-align","text-shadow","transition"],allowedFields:{cardholderName:{name:"cardholder-name",label:"Cardholder Name"},number:{name:"credit-card-number",label:"Credit Card Number"},cvv:{name:"cvv",label:"CVV"},expirationDate:{name:"expiration",label:"Expiration Date"},expirationMonth:{name:"expiration-month",label:"Expiration Month"},expirationYear:{name:"expiration-year",label:"Expiration Year"},postalCode:{name:"postal-code",label:"Postal Code"}},allowedAttributes:{"aria-invalid":"boolean","aria-required":"boolean",disabled:"boolean",placeholder:"string"},allowedBillingAddressFields:["company","countryCodeNumeric","countryCodeAlpha2","countryCodeAlpha3","countryName","extendedAddress","locality","region","firstName","lastName","postalCode","streetAddress"],allowedShippingAddressFields:["company","countryCodeNumeric","countryCodeAlpha2","countryCodeAlpha3","countryName","extendedAddress","locality","region","firstName","lastName","postalCode","streetAddress"],autocompleteMappings:{"cardholder-name":"cc-name","credit-card-number":"cc-number",expiration:"cc-exp","expiration-month":"cc-exp-month","expiration-year":"cc-exp-year",cvv:"cc-csc","postal-code":"billing postal-code"}};l.events=s(["ADD_CLASS","AUTOFILL_DATA_AVAILABLE","BIN_AVAILABLE","CARD_FORM_ENTRY_HAS_BEGUN","CLEAR_FIELD","CONFIGURATION","FRAME_READY","INPUT_EVENT","READY_FOR_CLIENT","REMOVE_ATTRIBUTE","REMOVE_CLASS","REMOVE_FOCUS_INTERCEPTS","SET_ATTRIBUTE","SET_MESSAGE","SET_MONTH_OPTIONS","TOKENIZATION_REQUEST","TRIGGER_FOCUS_CHANGE","TRIGGER_INPUT_FOCUS","VALIDATE_STRICT"],"hosted-fields:"),i.exports=l},{"../../lib/enumerate":158,"./errors":134}],134:[function(n,i,r){var s=n("../../lib/braintree-error");i.exports={HOSTED_FIELDS_TIMEOUT:{type:s.types.UNKNOWN,code:"HOSTED_FIELDS_TIMEOUT",message:"Hosted Fields timed out when attempting to set up."},HOSTED_FIELDS_INVALID_FIELD_KEY:{type:s.types.MERCHANT,code:"HOSTED_FIELDS_INVALID_FIELD_KEY"},HOSTED_FIELDS_INVALID_FIELD_SELECTOR:{type:s.types.MERCHANT,code:"HOSTED_FIELDS_INVALID_FIELD_SELECTOR",message:"Selector does not reference a valid DOM node."},HOSTED_FIELDS_FIELD_DUPLICATE_IFRAME:{type:s.types.MERCHANT,code:"HOSTED_FIELDS_FIELD_DUPLICATE_IFRAME",message:"Element already contains a Braintree iframe."},HOSTED_FIELDS_FIELD_INVALID:{type:s.types.MERCHANT,code:"HOSTED_FIELDS_FIELD_INVALID"},HOSTED_FIELDS_FIELD_NOT_PRESENT:{type:s.types.MERCHANT,code:"HOSTED_FIELDS_FIELD_NOT_PRESENT"}
105,HOSTED_FIELDS_TOKENIZATION_NETWORK_ERROR:{type:s.types.NETWORK,code:"HOSTED_FIELDS_TOKENIZATION_NETWORK_ERROR",message:"A tokenization network error occurred."},HOSTED_FIELDS_TOKENIZATION_FAIL_ON_DUPLICATE:{type:s.types.CUSTOMER,code:"HOSTED_FIELDS_TOKENIZATION_FAIL_ON_DUPLICATE",message:"This credit card already exists in the merchant's vault."},HOSTED_FIELDS_TOKENIZATION_CVV_VERIFICATION_FAILED:{type:s.types.CUSTOMER,code:"HOSTED_FIELDS_TOKENIZATION_CVV_VERIFICATION_FAILED",message:"CVV verification failed during tokenization."},HOSTED_FIELDS_FAILED_TOKENIZATION:{type:s.types.CUSTOMER,code:"HOSTED_FIELDS_FAILED_TOKENIZATION",message:"The supplied card data failed tokenization."},HOSTED_FIELDS_FIELDS_EMPTY:{type:s.types.CUSTOMER,code:"HOSTED_FIELDS_FIELDS_EMPTY",message:"All fields are empty. Cannot tokenize empty card fields."},HOSTED_FIELDS_FIELDS_INVALID:{type:s.types.CUSTOMER,code:"HOSTED_FIELDS_FIELDS_INVALID",message:"Some payment input fields are invalid. Cannot tokenize invalid card fields."},HOSTED_FIELDS_ATTRIBUTE_NOT_SUPPORTED:{type:s.types.MERCHANT,code:"HOSTED_FIELDS_ATTRIBUTE_NOT_SUPPORTED"},HOSTED_FIELDS_ATTRIBUTE_VALUE_NOT_ALLOWED:{type:s.types.MERCHANT,code:"HOSTED_FIELDS_ATTRIBUTE_VALUE_NOT_ALLOWED"},HOSTED_FIELDS_FIELD_PROPERTY_INVALID:{type:s.types.MERCHANT,code:"HOSTED_FIELDS_FIELD_PROPERTY_INVALID"}}},{"../../lib/braintree-error":149}],135:[function(n,i,r){function s(a,o){for(var l=a.parentNode,c=[];l!=null;)l.tagName!=null&&l.tagName.toLowerCase()===o&&c.push(l),l=l.parentNode;return c}i.exports=s},{}],136:[function(n,i,r){var s=n("./browser-detection"),a=n("./constants"),o=Object.keys(a.allowedFields),l=a.navigationDirections,c={generate:function(d,u,p,h){var m=document.createElement("input"),v={border:"none !important",display:"block !important",height:"1px !important",left:"-1px !important",opacity:"0 !important",position:"absolute !important",top:"-1px !important",width:"1px !important"},_=s.hasSoftwareKeyboard()||s.isFirefox();return _?(m.setAttribute("aria-hidden","true"),m.setAttribute("autocomplete","off"),m.setAttribute("data-braintree-direction",p),m.setAttribute("data-braintree-type",u),m.setAttribute("id","bt-"+u+"-"+p+"-"+d),m.setAttribute("style",JSON.stringify(v).replace(/[{}"]/g,"").replace(/,/g,";")),m.classList.add("focus-intercept"),m.addEventListener("focus",function(b){h(b),s.hasSoftwareKeyboard()||m.blur()}),m):document.createDocumentFragment()},destroy:function(d){var u;d?u=[document.getElementById(d)]:(u=document.querySelectorAll("[data-braintree-direction]"),u=[].slice.call(u)),u.forEach(function(p){p&&p.nodeType===1&&c.matchFocusElement(p.getAttribute("id"))&&p.parentNode.removeChild(p)})},matchFocusElement:function(d){var u,p,h,m;return!d||(u=d.split("-"),u.length<4)?!1:(p=u[0]==="bt",h=o.indexOf(u[1])>-1,m=u[2]===l.BACK||u[2]===l.FORWARD,!!(p&&h&&m))}};i.exports=c},{"./browser-detection":132,"./constants":133}],137:[function(n,i,r){var s=n("credit-card-type");i.exports=function(a){var o=s(a);return o.forEach(function(l){l.type==="mastercard"&&(l.type="master-card")}),o}},{"credit-card-type":45}],138:[function(n,i,r){var s=n("./american-express"),a=n("./apple-pay"),o=n("./client"),l=n("./fastlane"),c=n("./data-collector"),d=n("./hosted-fields"),u=n("./local-payment"),p=n("./masterpass"),h=n("./instant-verification"),m=n("./payment-request"),v=n("./payment-ready"),_=n("./paypal"),b=n("./paypal-checkout"),w=n("./paypal-checkout-v6"),C=n("./google-payment"),O=n("./sepa"),T=n("./three-d-secure"),E=n("./unionpay"),y=n("./us-bank-account"),P=n("./vault-manager"),A=n("./venmo"),I=n("./visa-checkout"),L=n("./preferred-payment-methods"),D="3.140.0";i.exports={fastlane:l,americanExpress:s,applePay:a,client:o,dataCollector:c,hostedFields:d,instantVerification:h,localPayment:u,masterpass:p,googlePayment:C,paymentRequest:m,paymentReady:v,paypal:_,paypalCheckout:b,paypalCheckoutV6:w,threeDSecure:T,unionpay:E,usBankAccount:y,vaultManager:P,venmo:A,visaCheckout:I,sepa:O,preferredPaymentMethods:L,VERSION:D}},{"./american-express":92,"./apple-pay":95,"./client":100,"./data-collector":118,"./fastlane":121,"./google-payment":124,"./hosted-fields":131,"./instant-verification":141,"./local-payment":192,"./masterpass":196,"./payment-ready":202,"./payment-request":205,"./paypal":216,"./paypal-checkout":213,"./paypal-checkout-v6":210,"./preferred-
105payment-methods":219,"./sepa":223,"./three-d-secure":233,"./unionpay":237,"./us-bank-account":243,"./vault-manager":246,"./venmo":251,"./visa-checkout":261}],139:[function(n,i,r){var s={sandbox:"https://www.sandbox.paypal.com/openfinance/v1/bank/payment-method/create",production:"https://www.paypal.com/openfinance/v1/bank/payment-method/create"},a="query AchMandateDetails($id: ID!) { node(id: $id) { id ... on PaymentMethod { id legacyId usage createdAt verifications { edges { node { status } } } details { __typename ... on UsBankAccountDetails { accountholderName accountType ownershipType bankName last4 routingNumber verified } } } } }";i.exports={EXPERIENCE_URL:s,ACH_MANDATE_DETAILS_QUERY:a}},{}],140:[function(n,i,r){var s=n("../lib/braintree-error");i.exports={INSTANT_VERIFICATION_ERROR:{type:s.types.MERCHANT,code:"INSTANT_VERIFICATION_ERROR"},INSTANT_VERIFICATION_NOT_ENABLED:{type:s.types.MERCHANT,code:"INSTANT_VERIFICATION_NOT_ENABLED",message:"Instant Verification is not enabled for this merchant account."},INSTANT_VERIFICATION_CANCELED:{type:s.types.CUSTOMER,code:"INSTANT_VERIFICATION_CANCELED",message:"Customer canceled the Instant Verification payment before authorizing."},INSTANT_VERIFICATION_FAILURE:{type:s.types.UNKNOWN,code:"INSTANT_VERIFICATION_FAILURE",message:"Instant Verification payment failed during authorizing."},INSTANT_VERIFICATION_JWT_REQUIRED:{type:s.types.MERCHANT,code:"INSTANT_VERIFICATION_JWT_MISSING",message:"JWT is required for Instant Verification payment flow."},INSTANT_VERIFICATION_MANDATE_ID_REQUIRED:{type:s.types.MERCHANT,code:"INSTANT_VERIFICATION_MANDATE_ID_REQUIRED",message:"Mandate ID is required to fetch ACH mandate details."},INSTANT_VERIFICATION_MANDATE_DETAILS_FAILED:{type:s.types.NETWORK,code:"INSTANT_VERIFICATION_MANDATE_DETAILS_FAILED",message:"Failed to fetch ACH mandate details."}}},{"../lib/braintree-error":149}],141:[function(n,i,r){var s=n("../lib/basic-component-verification"),a=n("../lib/braintree-error"),o=n("../lib/create-assets-url"),l=n("../lib/create-deferred-client"),c=n("./errors"),d=n("./instant-verification"),u="3.140.0",p=n("@braintree/wrap-promise");function h(m){var v,_="Instant Verification";return s.verify({name:_,client:m.client,authorization:m.authorization}).then(function(){return l.create({authorization:m.authorization,client:m.client,debug:m.debug,assetsUrl:o.create(m.authorization),name:_})}).then(function(b){return m.client=b,v=m.client.getConfiguration().gatewayConfiguration.openBanking,v?new d(m):Promise.reject(new a(c.INSTANT_VERIFICATION_NOT_ENABLED))})}i.exports={create:p(h),VERSION:u}},{"../lib/basic-component-verification":147,"../lib/braintree-error":149,"../lib/create-assets-url":153,"../lib/create-deferred-client":155,"./errors":140,"./instant-verification":142,"@braintree/wrap-promise":43}],142:[function(n,i,r){var s=n("../lib/vendor/polyfill").atob,a=n("../lib/analytics"),o=n("../lib/braintree-error"),l=n("./constants"),c=n("./errors"),d=n("../lib/querystring"),u=n("@braintree/wrap-promise");function p(v){this._instantiatedWithClient=!v.useDeferredClient,this._client=v.client,this._createPromise=v.createPromise,a.sendEvent(this._client,"instant-verification.component.initialized")}p.prototype.startPayment=function(v){var _=this,b=_._client.getConfiguration().authorizationFingerprint,w="";return v.jwt?(w=h(_._client.getConfiguration())+"?"+d.stringify({ct:v.jwt,at:b}),typeof window<"u"&&window.location&&(a.sendEvent(_._client,"instant-verification.redirect.initiated"),window.location.href=w),Promise.resolve()):Promise.reject(new o(c.INSTANT_VERIFICATION_JWT_REQUIRED))};function h(v){var _=l.EXPERIENCE_URL.production;return v&&v.gatewayConfiguration&&v.gatewayConfiguration.environment&&l.EXPERIENCE_URL[v.gatewayConfiguration.environment]&&(_=l.EXPERIENCE_URL[v.gatewayConfiguration.environment]),_}p.prototype.handleRedirect=function(v){var _=this,b,w,C;return v.success?(w=JSON.parse(s(v.success)),a.sendEvent(_._client,"instant-verification.redirect.completed.success"),w.tokenizedAccounts&&w.tokenizedAccounts[0]&&(C=w.tokenizedAccounts[0].tokenized_account),Promise.resolve(C)):(v.cancel&&(w=JSON.parse(s(v.cancel)),a.sendEvent(_._client,"instant-verification.redirect.completed.canceled"),b=new o(c.INSTANT_VERIFICATION_CANCELED)),v.error&&(w=JSON.parse(s(v.error)),a.sendEvent(_._client,"instant-verification.redirect.completed.error"),b=new o(c.INSTANT_VERIFICATION_FAILURE)),Promise.reject(b))},p.prototype.getAchMandateDetails=function(v){var _=this,b=v&&v.mandateId;return new Promise(function(w,C){if(!b){C(new o(c.INSTANT_VERIFICATION_MANDATE_ID_REQUIRED));return}_._client.request({api:"graphQLApi",method:"post",data:{query:l.ACH_MANDATE_DETAILS_QUERY,variables:{id:b},operationName:"AchMandateDetails"}},function(O,T){if(O){a.sendEvent(_._client,"instant-verification.ach-mandate-details.failed"),C(new o({type:c.INSTANT_VERIFICATION_MANDATE_DETAILS_FAILED.type,code:c.INSTANT_VERIFICATION_MANDATE_DETAILS_FAILED.code,message:c.INSTANT_VERIFICATION_MANDATE_DETAILS_FAILED.message,details:{originalError:O}}));return}if(!T.data||!T.data.node){C(new o({type:c.INSTANT_VERIFICATION_MANDATE_DETAILS_FAILED.type,code:c.INSTANT_VERIFICATION_MANDATE_DETAILS_FAILED.code,message:"No mandate details found for the provided ID."}));return}var E=T.data.node;if(!E.details){C(new o({type:c.INSTANT_VERIFICATION_MANDATE_DETAILS_FAILED.type,code:c.INSTANT_VERIFICATION_MANDATE_DETAILS_FAILED.code,message:"Mandate details are missing in the response."}));return}a.sendEvent(_._client,"instant-verification.ach-mandate-details.succeeded"),w(m(E))})})};function m(v){return{accountHolderName:v.details.accountholderName,accountType:v.details.accountType,bankName:v.details.bankName,last4:v.details.last4,ownershipType:v.details.ownershipType,routingNumber:v.details.routingNumber}}i.exports=u.wrapPrototype(p)},{"../lib/analytics":144,"../lib/braintree-error":149,"../lib/querystring":183,"../lib/vendor/polyfill":188,"./constants":139,"./errors":14
1050,"@braintree/wrap-promise":43}],143:[function(n,i,r){var s=n("./create-authorization-data"),a=n("./json-clone"),o=n("./constants");function l(d,u){var p,h=u?a(u):{},m=s(d.authorization).attrs,v=a(d.analyticsMetadata);h.braintreeLibraryVersion=o.BRAINTREE_LIBRARY_VERSION;for(p in h._meta)h._meta.hasOwnProperty(p)&&(v[p]=h._meta[p]);return h._meta=v,m.tokenizationKey?h.tokenizationKey=m.tokenizationKey:h.authorizationFingerprint=m.authorizationFingerprint,h}function c(d){var u=d.getConfiguration(),p=s(u.authorization).attrs,h=u.gatewayConfiguration.environment==="production",m={api_integration_type:u.analyticsMetadata.integrationType,app_id:window.location.host,c_sdk_ver:o.VERSION,component:"braintreeclientsdk",merchant_sdk_env:h?"production":"sandbox",merchant_id:u.gatewayConfiguration.merchantId,event_source:"web",platform:o.PLATFORM,platform_version:window.navigator.userAgent,session_id:u.analyticsMetadata.sessionId,client_session_id:u.analyticsMetadata.sessionId,tenant_name:"braintree",product_name:"BT_DCC",space_key:"SKDUYK"};return p.tokenizationKey?m.tokenization_key=p.tokenizationKey:m.auth_fingerprint=p.authorizationFingerprint,m}i.exports={addMetadata:l,addEventMetadata:c}},{"./constants":150,"./create-authorization-data":154,"./json-clone":180}],144:[function(n,i,r){var s=n("./constants"),a=n("./add-metadata"),o=n("./assign").assign;function l(u,p,h){return c(u,p,{},h)}function c(u,p,h,m){var v=Date.now();return h.flow==="vault"?h.context_type="BA_Token":h.flow==="checkout"&&(h.context_type="EC_Token"),Promise.resolve(u).then(function(_){var b=_._request,w=s.ANALYTICS_URL,C=s.ANALYTICS_PREFIX+p,O=_.getConfiguration(),T=O.gatewayConfiguration.environment==="production",E={events:[],tracking:[]},y=a.addEventMetadata(_,E);return y.event_name=C,y.t=v,E.events=[{level:"info",event:C,payload:o({env:T?"production":"sandbox",timestamp:v},h)}],E.tracking=[y],h&&typeof h=="object"&&(E.tracking=[d(y,h)]),b({url:w,method:"post",data:E,timeout:s.ANALYTICS_REQUEST_TIMEOUT_MS},m)}).catch(function(_){m&&m(_)})}function d(u,p){var h={},m=o({},p);return Object.keys(m).forEach(function(v){s.ALLOWED_EXTRA_EVENT_FIELDS.indexOf(v)===-1&&delete m[v]}),h=o(u,m),h}i.exports={sendEvent:l,sendEventPlus:c}},{"./add-metadata":143,"./assign":146,"./constants":150}],145:[function(n,i,r){var s=n("@braintree/asset-loader/load-script"),a=n("@paypal/accelerated-checkout-loader");i.exports={loadScript:s,loadFastlane:a.loadAxo}},{"@braintree/asset-loader/load-script":2,"@paypal/accelerated-checkout-loader":44}],146:[function(n,i,r){var s=typeof Object.assign=="function"?Object.assign:a;function a(o){var l,c,d;for(l=1;l<arguments.length;l++){c=arguments[l];for(d in c)c.hasOwnProperty(d)&&(o[d]=c[d])}return o}i.exports={assign:s,_assign:a}},{}],147:[function(n,i,r){var s=n("./braintree-error"),a=n("./errors"),o="3.140.0";function l(c){var d,u,p;return c?(p=c.name,d=c.client,u=c.authorization,!d&&!u?Promise.reject(new s({type:a.INSTANTIATION_OPTION_REQUIRED.type,code:a.INSTANTIATION_OPTION_REQUIRED.code,message:"options.client is required when instantiating "+p+"."})):!u&&d.getVersion()!==o?Promise.reject(new s({type:a.INCOMPATIBLE_VERSIONS.type,code:a.INCOMPATIBLE_VERSIONS.code,message:"Client (version "+d.getVersion()+") and "+p+" (version "+o+") components must be from the same SDK version."})):Promise.resolve()):Promise.reject(new s({type:a.INVALID_USE_OF_INTERNAL_FUNCTION.type,code:a.INVALID_USE_OF_INTERNAL_FUNCTION.code,message:"Options must be passed to basicComponentVerification function."}))}i.exports={verify:l}},{"./braintree-error":149,"./errors":159}],148:[function(n,i,r){var s=n("./once");function a(o,l){var c=o.length===0;c?(o(),l(null)):o(l)}i.exports=function(o,l){var c,d=o.length,u=d,p=s(l);if(d===0){p(null);return}function h(m){if(m){p(m);return}u-=1,u===0&&p(null)}for(c=0;c<d;c++)a(o[c],h)}},{"./once":182}],149:[function(n,i,r){var s=n("./enumerate");function a(o){if(!a.types.hasOwnProperty(o.type))throw new Error(o.type+" is not a valid type.");if(!o.code)throw new Error("Error code required.");if(!o.message)throw new Error("Error message required.");
105this.name="BraintreeError",this.code=o.code,this.message=o.message,this.type=o.type,this.details=o.details}a.prototype=Object.create(Error.prototype),a.prototype.constructor=a,a.types=s(["CUSTOMER","MERCHANT","NETWORK","INTERNAL","UNKNOWN"]),a.findRootError=function(o){return o instanceof a&&o.details&&o.details.originalError?a.findRootError(o.details.originalError):o},i.exports=a},{"./enumerate":158}],150:[function(n,i,r){var s="3.140.0",a="web",o={production:"https://api.braintreegateway.com:443",sandbox:"https://api.sandbox.braintreegateway.com:443"},l={production:"https://assets.braintreegateway.com",sandbox:"https://assets.braintreegateway.com"},c={production:"https://payments.braintree-api.com/graphql",sandbox:"https://payments.sandbox.braintree-api.com/graphql"};i.exports={ANALYTICS_PREFIX:a+".",ANALYTICS_REQUEST_TIMEOUT_MS:2e3,ANALYTICS_URL:"https://www.paypal.com/xoplatform/logger/api/logger",ASSETS_URLS:l,CLIENT_API_URLS:o,FRAUDNET_SOURCE:"BRAINTREE_SIGNIN",FRAUDNET_FNCLS:"fnparams-dede7cc5-15fd-4c75-a9f4-36c430ee3a99",FRAUDNET_URL:"https://c.paypal.com/da/r/fb.js",BUS_CONFIGURATION_REQUEST_EVENT:"BUS_CONFIGURATION_REQUEST",GRAPHQL_URLS:c,INTEGRATION_TIMEOUT_MS:6e4,VERSION:s,INTEGRATION:"custom",SOURCE:"client",PLATFORM:a,BRAINTREE_LIBRARY_VERSION:"braintree/"+a+"/"+s,ALLOWED_EXTRA_EVENT_FIELDS:["context_id","context_type","payment_ready_button_order","payment_ready_experiment_type","payment_ready_page_type","payment_ready_session_id","button_type","connectionStartTime","domain","endpoint","endTime","requestStartTime","startTime"]}},{}],151:[function(n,i,r){var s=n("./braintree-error"),a=n("./errors");i.exports=function(o,l){l.forEach(function(c){o[c]=function(){throw new s({type:a.METHOD_CALLED_AFTER_TEARDOWN.type,code:a.METHOD_CALLED_AFTER_TEARDOWN.code,message:c+" cannot be called after teardown."})}})}},{"./braintree-error":149,"./errors":159}],152:[function(n,i,r){var s=n("./braintree-error");function a(o,l){return o instanceof s?o:new s({type:l.type,code:l.code,message:l.message,details:{originalError:o}})}i.exports=a},{"./braintree-error":149}],153:[function(n,i,r){var s=n("./constants").ASSETS_URLS;function a(o){return s.production}i.exports={create:a}},{"./constants":150}],154:[function(n,i,r){var s=n("../lib/vendor/polyfill").atob,a=n("../lib/constants").CLIENT_API_URLS;function o(d){return/^[a-zA-Z0-9]+_[a-zA-Z0-9]+_[a-zA-Z0-9_]+$/.test(d)}function l(d){var u=d.split("_"),p=u[0],h=u.slice(2).join("_");return{merchantId:h,environment:p}}function c(d){var u,p,h={attrs:{},configUrl:""};return o(d)?(p=l(d),h.environment=p.environment,h.attrs.tokenizationKey=d,h.configUrl=a[p.environment]+"/merchants/"+p.merchantId+"/client_api/v1/configuration"):(u=JSON.parse(s(d)),h.environment=u.environment,h.attrs.authorizationFingerprint=u.authorizationFingerprint,h.configUrl=u.configUrl,h.graphQL=u.graphQL),h}i.exports=c},{"../lib/constants":150,"../lib/vendor/polyfill":188}],155:[function(n,i,r){var s=n("./braintree-error"),a=n("./assets"),o=n("./errors"),l="3.140.0";function c(d){var u=Promise.resolve();return d.client?Promise.resolve(d.client):(window.braintree&&window.braintree.client||(u=a.loadScript({src:d.assetsUrl+"/web/"+l+"/js/client.min.js"}).catch(function(p){return Promise.reject(new s({type:o.CLIENT_SCRIPT_FAILED_TO_LOAD.type,code:o.CLIENT_SCRIPT_FAILED_TO_LOAD.code,message:o.CLIENT_SCRIPT_FAILED_TO_LOAD.message,details:{originalError:p}}))})),u.then(function(){return window.braintree.client.VERSION!==l?Promise.reject(new s({type:o.INCOMPATIBLE_VERSIONS.type,code:o.INCOMPATIBLE_VERSIONS.code,message:"Client (version "+window.braintree.client.VERSION+") and "+d.name+" (version "+l+") components must be from the same SDK version."})):window.braintree.client.create({authorization:d.authorization,debug:d.debug})}))}i.exports={create:c}},{"./assets":145,"./braintree-error":149,"./errors":159}],156:[function(n,i,r){i.exports=function(s){return function(){var a=arguments;setTimeout(function(){s.apply(null,a)},1)}}},{}],157:[function(n,i,r){var s=n("./batch-execute-functions");function a(){this._teardownRegistry=[],this._isTearingDown=!1}a.prototype.registerFunctionForTeardown=function(o){typeof o=="function"&&this._teardownRegistry.push(o)}
105,a.prototype.teardown=function(o){if(this._isTearingDown){o(new Error("Destructor is already tearing down"));return}this._isTearingDown=!0,s(this._teardownRegistry,(function(l){this._teardownRegistry=[],this._isTearingDown=!1,typeof o=="function"&&o(l)}).bind(this))},i.exports=a},{"./batch-execute-functions":148}],158:[function(n,i,r){function s(a,o){return o=o??"",a.reduce(function(l,c){return l[c]=o+c,l},{})}i.exports=s},{}],159:[function(n,i,r){var s=n("./braintree-error");i.exports={INVALID_USE_OF_INTERNAL_FUNCTION:{type:s.types.INTERNAL,code:"INVALID_USE_OF_INTERNAL_FUNCTION"},INSTANTIATION_OPTION_REQUIRED:{type:s.types.MERCHANT,code:"INSTANTIATION_OPTION_REQUIRED"},INCOMPATIBLE_VERSIONS:{type:s.types.MERCHANT,code:"INCOMPATIBLE_VERSIONS"},CLIENT_SCRIPT_FAILED_TO_LOAD:{type:s.types.NETWORK,code:"CLIENT_SCRIPT_FAILED_TO_LOAD",message:"Braintree client script could not be loaded."},METHOD_CALLED_AFTER_TEARDOWN:{type:s.types.MERCHANT,code:"METHOD_CALLED_AFTER_TEARDOWN"},INSTANTIATION_OPTION_INVALID:{type:s.types.MERCHANT,code:"INSTANTIATION_OPTION_INVALID"}}},{"./braintree-error":149}],160:[function(n,i,r){i.exports=function(a){for(;a.parentNode;)a=a.parentNode;return a}},{}],161:[function(n,i,r){i.exports=function(s,a,o){var l;for(l=0;l<s.length;l++)if(s[l].hasOwnProperty(a)&&s[l][a]===o)return s[l];return null}},{}],162:[function(n,i,r){var s=n("./strategies/popup"),a=n("./strategies/popup-bridge"),o=n("./strategies/modal"),l=n("framebus"),c=n("../shared/events"),d=n("../shared/errors"),u=n("../shared/constants"),p=n("@braintree/uuid"),h=n("@braintree/iframer"),m=n("../../braintree-error"),v=n("../shared/browser-detection"),_=n("./../../assign").assign,b=n("../../constants").BUS_CONFIGURATION_REQUEST_EVENT,w=["name","dispatchFrameUrl","openFrameUrl"];function C(){}function O(E){if(!E)throw new Error("Valid configuration is required");if(w.forEach(function(y){if(!E.hasOwnProperty(y))throw new Error("A valid frame "+y+" must be provided")}),!/^[\w_]+$/.test(E.name))throw new Error("A valid frame name must be provided")}function T(E){O(E),this._serviceId=p().replace(/-/g,""),this._options={name:E.name+"_"+this._serviceId,dispatchFrameUrl:E.dispatchFrameUrl,openFrameUrl:E.openFrameUrl,height:E.height,width:E.width,top:E.top,left:E.left},this.state=E.state||{},this._bus=new l({channel:this._serviceId}),this._setBusEvents()}T.prototype.initialize=function(E){var y=(function(){E(),this._bus.off(c.DISPATCH_FRAME_READY,y)}).bind(this);this._bus.on(c.DISPATCH_FRAME_READY,y),this._writeDispatchFrame()},T.prototype._writeDispatchFrame=function(){var E=u.DISPATCH_FRAME_NAME+"_"+this._serviceId,y=this._options.dispatchFrameUrl;this._dispatchFrame=h({"aria-hidden":!0,name:E,title:E,src:y,class:u.DISPATCH_FRAME_CLASS,height:0,width:0,style:{position:"absolute",left:"-9999px"}}),document.body.appendChild(this._dispatchFrame)},T.prototype._setBusEvents=function(){this._bus.on(c.DISPATCH_FRAME_REPORT,(function(E,y){this._onCompleteCallback&&this._onCompleteCallback.call(null,E.err,E.payload),this._frame.close(),this._onCompleteCallback=null,y&&y()}).bind(this)),this._bus.on(b,(function(E){E(this.state)}).bind(this))},T.prototype.open=function(E,y){if(E=E||{},this._frame=this._getFrameForEnvironment(E),this._frame.initialize(y),!(this._frame instanceof a)){if(_(this.state,E.state),this._onCompleteCallback=y,this._frame.open(),this.isFrameClosed()){this._cleanupFrame(),y&&y(new m(d.FRAME_SERVICE_FRAME_OPEN_FAILED));return}this._pollForPopupClose()}},T.prototype.redirect=function(E){this._frame&&!this.isFrameClosed()&&this._frame.redirect(E)},T.prototype.close=function(){this.isFrameClosed()||this._frame.close()},T.prototype.focus=function(){this.isFrameClosed()||this._frame.focus()},T.prototype.createHandler=function(E){return E=E||{},{close:(function(){E.beforeClose&&E.beforeClose(),this.close()}).bind(this),focus:(function(){E.beforeFocus&&E.beforeFocus(),this.focus()}).bind(this)}},T.prototype.createNoopHandler=function(){return{close:C,focus:C}},T.prototype.teardown=function(){this.close(),this._dispatchFrame.parentNode.removeChild(this._dispatchFrame),this._dispatchFrame=null,this._cleanupFrame()},T.prototype.isFrameClosed=function(){return this._frame==null||this._frame.isClosed()},T.prototype._cleanupFrame=function(){this._frame=null,clearInterval(this._popupInterval),this._popupInterval=null},T.prototype._pollForPopupClose=function(){return this._popupInterval=setInterval((function(){this.isFrameClosed()&&(this._cleanupFrame(),this._onCompleteCallback&&this._onCompleteCallback(new m(d.FRAME_SERVICE_FRAME_CLOSED)))}).bind(this),u.POPUP_POLL_INTERVAL),this._popupInterval},T.prototype._getFrameForEnvironment=function(E){var y=v.supportsPopups(),P=!!window.popupBridge,A=_({},this._options,E);return P?new a(A):y?new s(A):new o(A)},i.exports=T},{"../../braintree-error":149,"../../constants":150,"../shared/browser-detection":169,"../shared/constants":170,"../shared/errors":171,"../shared/events":172,"./../../assign":146,"./strategies/modal":164,"./strategies/popup":167,"./strategies/popup-bridge":165,"@braintree/iframer":35,"@braintree/uuid":39,framebus:54}],163:[function(n,i,r){var s=n("./frame-service");i.exports={create:function(o,l){var c=new s(o);c.initialize(function(){l(c)})}}},{"./frame-service":162}],164:[function(n,i,r){var s=n("@braintree/iframer"),a=n("../../../assign").assign,o=n("../../shared/browser-detection"),l={position:"fixed",top:0,left:0,bottom:0,padding:0,margin:0,border:0,outline:"none",zIndex:20001,background:"#FFFFFF"};function c(){}function d(u){this._closed=null,this._frame=null,this._options=u||{},this._container=this._options.container||document.body}d.prototype.initialize=c,d.prototype.open=function(){var u={src:this._options.openFrameUrl,name:this._options.name,scrolling:"yes",height:"100%",width:"100%",style:a({},l),title:"Lightbox Frame"};o.isIos()?(o.isIosWKWebview()&&(this._lockScrolling(),u.style={}),this._el=document.createElement("div"),a(this._el.style,l,{height:"100%",width:"100%",overflow:"auto","-webkit-overflow-scrolling":"touch"}),this._frame=s(u),this._el.appendChild(this._frame)):this._el=this._frame=s(u),this._closed=!1,this._container.appendChild(this._el)}
105,d.prototype.focus=c,d.prototype.close=function(){this._container.removeChild(this._el),this._frame=null,this._closed=!0,o.isIosWKWebview()&&this._unlockScrolling()},d.prototype.isClosed=function(){return!!this._closed},d.prototype.redirect=function(u){this._frame.src=u},d.prototype._unlockScrolling=function(){document.body.style.overflow=this._savedBodyProperties.overflowStyle,document.body.style.position=this._savedBodyProperties.positionStyle,window.scrollTo(this._savedBodyProperties.left,this._savedBodyProperties.top),delete this._savedBodyProperties},d.prototype._lockScrolling=function(){var u=document.documentElement;this._savedBodyProperties={left:(window.pageXOffset||u.scrollLeft)-(u.clientLeft||0),top:(window.pageYOffset||u.scrollTop)-(u.clientTop||0),overflowStyle:document.body.style.overflow,positionStyle:document.body.style.position},document.body.style.overflow="hidden",document.body.style.position="fixed",window.scrollTo(0,0)},i.exports=d},{"../../../assign":146,"../../shared/browser-detection":169,"@braintree/iframer":35}],165:[function(n,i,r){var s=n("../../../braintree-error"),a=n("../../shared/errors");function o(){}function l(c){this._closed=null,this._options=c}l.prototype.initialize=function(c){var d=this;window.popupBridge.onComplete=function(u,p){var h=!p&&!u;if(d._closed=!0,u||h){c(new s(a.FRAME_SERVICE_FRAME_CLOSED));return}c(null,p)}},l.prototype.open=function(c){var d;c=c||{},d=c.openFrameUrl||this._options.openFrameUrl,this._closed=!1,window.popupBridge.open(d)},l.prototype.focus=o,l.prototype.close=o,l.prototype.isClosed=function(){return!!this._closed},l.prototype.redirect=function(c){this.open({openFrameUrl:c})},i.exports=l},{"../../../braintree-error":149,"../../shared/errors":171}],166:[function(n,i,r){var s=n("../../../shared/constants"),a=n("./position");function o(l,c,d){return typeof c<"u"?c:a[l](d)}i.exports=function(c){var d=c.height||s.DEFAULT_POPUP_HEIGHT,u=c.width||s.DEFAULT_POPUP_WIDTH,p=o("top",c.top,d),h=o("left",c.left,u);return[s.POPUP_BASE_OPTIONS,"height="+d,"width="+u,"top="+p,"left="+h].join(",")}},{"../../../shared/constants":170,"./position":168}],167:[function(n,i,r){var s=n("./compose-options");function a(){}function o(l){this._frame=null,this._options=l||{}}o.prototype.initialize=a,o.prototype.open=function(){this._frame=window.open(this._options.openFrameUrl,this._options.name,s(this._options))},o.prototype.focus=function(){this._frame.focus()},o.prototype.close=function(){this._frame.closed||this._frame.close()},o.prototype.isClosed=function(){return!this._frame||!!this._frame.closed},o.prototype.redirect=function(l){this._frame.location.href=l},i.exports=o},{"./compose-options":166}],168:[function(n,i,r){function s(l){var c=window.outerHeight||document.documentElement.clientHeight,d=window.screenY==null?window.screenTop:window.screenY;return o(c,l,d)}function a(l){var c=window.outerWidth||document.documentElement.clientWidth,d=window.screenX==null?window.screenLeft:window.screenX;return o(c,l,d)}function o(l,c,d){return(l-c)/2+d}i.exports={top:s,left:a,center:o}},{}],169:[function(n,i,r){i.exports={isIos:n("@braintree/browser-detection/is-ios"),isIosWKWebview:n("@braintree/browser-detection/is-ios-wkwebview"),supportsPopups:n("@braintree/browser-detection/supports-popups")}},{"@braintree/browser-detection/is-ios":30,"@braintree/browser-detection/is-ios-wkwebview":29,"@braintree/browser-detection/supports-popups":32}],170:[function(n,i,r){i.exports={DISPATCH_FRAME_NAME:"dispatch",DISPATCH_FRAME_CLASS:"braintree-dispatch-frame",POPUP_BASE_OPTIONS:"resizable,scrollbars",DEFAULT_POPUP_WIDTH:450,DEFAULT_POPUP_HEIGHT:535,POPUP_POLL_INTERVAL:100,POPUP_CLOSE_TIMEOUT:100}},{}],171:[function(n,i,r){var s=n("../../braintree-error");i.exports={FRAME_SERVICE_FRAME_CLOSED:{type:s.types.INTERNAL,code:"FRAME_SERVICE_FRAME_CLOSED",message:"Frame closed before tokenization could occur."},FRAME_SERVICE_FRAME_OPEN_FAILED:{type:s.types.INTERNAL,code:"FRAME_SERVICE_FRAME_OPEN_FAILED",message:"Frame failed to open."}}},{"../../braintree-error":149}],172:[function(n,i,r){var s=n("../../enumerate");i.exports=s(["DISPATCH_FRAME_READY","DISPATCH_FRAME_REPORT"],"frameService:")},{"../../enumerate":158}],173:[function(n,i,r){var s="3.140.0",a=n("./assign").assign;function o(l,c){var d=l.analyticsMetadata,u={gateway:"braintree","braintree:merchantId":l.gatewayConfiguration.merchantId,"braintree:apiVersion":"v1","braintree:sdkVersion":s,"braintree:metadata":JSON.stringify({source:d.source,integration:d.integration,sessionId:d.sessionId,version:s,platform:d.platform})};return a({},u,c)}i.exports=function(l,c,d){var u,p,h=l.gatewayConfiguration.androidPay,m=l.gatewayConfiguration.environment==="production"?"PRODUCTION":"TEST";return c===2?(u={apiVersion:2,apiVersionMinor:0,environment:m,allowedPaymentMethods:[{type:"CARD",parameters:{allowedAuthMethods:["PAN_ONLY","CRYPTOGRAM_3DS"],allowedCardNetworks:h.supportedNetworks.map(function(v){return v.toUpperCase()})},tokenizationSpecification:{type:"PAYMENT_GATEWAY",parameters:o(l,{"braintree:authorizationFingerprint":h.googleAuthorizationFingerprint})}}]},d&&(u.merchantInfo={merchantId:d}),h.paypalClientId&&(p={type:"PAYPAL",parameters:{purchase_context:{purchase_units:[{payee:{client_id:h.paypalClientId},recurring_payment:!0}]}},tokenizationSpecification:{type:"PAYMENT_GATEWAY",parameters:o(l,{"braintree:paypalClientId":h.paypalClientId})}},u.allowedPaymentMethods.push(p))):(u={environment:m,allowedPaymentMethods:["CARD","TOKENIZED_CARD"],paymentMethodTokenizationParameters:{tokenizationType:"PAYMENT_GATEWAY",parameters:o(l,{"braintree:authorizationFingerprint":h.googleAuthorizationFingerprint})},cardRequirements:{allowedCardNetworks:h.supportedNetworks.map(function(v){return v.toUpperCase()})}},l.authorizationType==="TOKENIZATION_KEY"&&(u.paymentMethodTokenizationParameters.parameters["braintree:clientKey"]=l.authorization),d&&(u.merchantId=d),c&&(u.apiVersion=c)),u}},{"./assign":146}],174:[function(n,i,r){function s(a,o){var l,c;for(o=o||[],l=0;l<o.length;l++)if(c=o[l],!a.hasOwnProperty(c))return!0;return!1}i.exports=s},{}],175:[function(n,i,r){i.exports=function(a){a=a||window;try{return a.self!==a.top}catch{return!0}}},{}],176:[function(n,i,r){function s(o){var l=o.split("-");return new Date(l[0],l[1],l[2])}function a(o,l){return s(o)<=s(l)}i.exports=a},{}],177:[function(n,i,r){i.exports=function(s){return s&&s.hasOwnProperty("fastlane")&&s.fastlane}},{}],178:[function(n,i,r){function s(a){return a=a||window.location.protocol,a==="https:"}
105i.exports={isHTTPS:s}},{}],179:[function(n,i,r){var s,a={"paypal.com":1,"braintreepayments.com":1,"braintreegateway.com":1,"braintree-api.com":1};function o(c){return c.split(".").slice(-2).join(".")}function l(c){var d;return c=c.toLowerCase(),/^https:/.test(c)?(s=s||document.createElement("a"),s.href=c,d=o(s.hostname),a.hasOwnProperty(d)):!1}i.exports=l},{}],180:[function(n,i,r){i.exports=function(s){return JSON.parse(JSON.stringify(s))}},{}],181:[function(n,i,r){i.exports=function(s){return Object.keys(s).filter(function(a){return typeof s[a]=="function"})}},{}],182:[function(n,i,r){function s(a){var o=!1;return function(){o||(o=!0,a.apply(null,arguments))}}i.exports=s},{}],183:[function(n,i,r){function s(u){var p;for(p in u)if(u.hasOwnProperty(p))return!0;return!1}function a(u){return u&&typeof u=="object"&&typeof u.length=="number"&&Object.prototype.toString.call(u)==="[object Array]"||!1}function o(u){return u=u||window.location.href,/\?/.test(u)}function l(u){var p,h;return u=u||window.location.href,o(u)?(p=u.split("?")[1]||"",p=p.replace(/#.*$/,"").split("&"),h=p.reduce(function(m,v){var _=v.split("="),b=decodeURIComponent(_[0]),w=decodeURIComponent(_[1]);return m[b]=w,m},{}),h):{}}function c(u,p){var h,m,v,_=[];for(v in u)u.hasOwnProperty(v)&&(m=u[v],p?a(u)?h=p+"[]":h=p+"["+v+"]":h=v,typeof m=="object"?_.push(c(m,h)):_.push(encodeURIComponent(h)+"="+encodeURIComponent(m)));return _.join("&")}function d(u,p){return u=u||"",p!=null&&typeof p=="object"&&s(p)&&(u+=u.indexOf("?")===-1?"?":"",u+=u.indexOf("=")!==-1?"&":"",u+=c(p)),u}i.exports={parse:l,stringify:c,queryify:d,hasQueryParams:o}},{}],184:[function(n,i,r){var s=n("@braintree/uuid"),a=n("./find-root-node");function o(d){return d=a(d),d.toString()==="[object ShadowRoot]"}function l(d){return d=a(d),o(d)?d.host:null}function c(d,u){var p=a(d).querySelector("style"),h=l(d),m="shadow-slot-"+s(),v=document.createElement("slot"),_=document.createElement("div");return v.setAttribute("name",m),d.appendChild(v),_.setAttribute("slot",m),h.appendChild(_),u&&(p||(p=document.createElement("style"),d.appendChild(p)),p.sheet.insertRule('::slotted([slot="'+m+'"]) { '+u+" }")),o(h)?c(_,u):_}i.exports={isShadowElement:o,getShadowHost:l,transformToSlot:c}},{"./find-root-node":160,"@braintree/uuid":39}],185:[function(n,i,r){i.exports=function(s){return s.indexOf("_")===-1?s:s.toLowerCase().replace(/(\_\w)/g,function(a){return a[1].toUpperCase()})}},{}],186:[function(n,i,r){var s=n("./querystring");function a(){var o=window;try{window.top&&window.top!==window&&window.top.location&&(o=window.top)}catch{}return s.parse(o.location.href)}i.exports={getUrlParams:a}},{"./querystring":183}],187:[function(n,i,r){function s(a){return a?"":".min"}i.exports=s},{}],188:[function(n,i,r){var s=typeof atob=="function"?atob:a;function a(o){var l,c,d,u,p,h,m,v,_=/^(?:[A-Za-z0-9+/]{4})*(?:[A-Za-z0-9+/]{2}==|[A-Za-z0-9+/]{3}=|[A-Za-z0-9+/]{4})([=]{1,2})?$/,b="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=",w="";if(!_.test(o))throw new Error("Non base64 encoded input passed to window.atob polyfill");v=0;do u=b.indexOf(o.charAt(v++)),p=b.indexOf(o.charAt(v++)),h=b.indexOf(o.charAt(v++)),m=b.indexOf(o.charAt(v++)),l=(u&63)<<2|p>>4&3,c=(p&15)<<4|h>>2&15,d=(h&3)<<6|m&63,w+=String.fromCharCode(l)+(c?String.fromCharCode(c):"")+(d?String.fromCharCode(d):"");while(v<o.length);return w}i.exports={atob:function(o){return s.call(window,o)},_atob:a}},{}],189:[function(n,i,r){i.exports={REQUIRED_OPTIONS_FOR_START_PAYMENT:["givenName","surname","currencyCode","paymentType","amount","fallback"],REQUIRED_OPTIONS_FOR_PAY_UPON_INVOICE_PAYMENT_TYPE:["givenName","surname","currencyCode","onPaymentStart","paymentType","amount","address","billingAddress","birthDate","email","locale","customerServiceInstructions","correlationId","phone","phoneCountryCode","lineItems"],REQUIRED_OPTIONS_FOR_ADDRESS:["streetAddress","locality","postalCode","countryCode"],REQUIRED_OPTIONS_FOR_LINE_ITEMS:["category","name","quantity","unitAmount","unitTaxAmount"],REQUIRED_OPTIONS_FOR_BLIK_SEAMLESS_PAYMENT_TYPE:["givenName","surname","currencyCode","paymentType","amount"],REQUIRED_OPTIONS_FOR_BLIK_OPTIONS_LEVEL_0:["authCode"],REQUIRED_OPTIONS_FOR_BLIK_OPTIONS_ONE_CLICK_FIRST:["authCode","consumerReference","aliasLabel"],REQUIRED_OPTIONS_FOR_BLIK_OPTIONS_ONE_CLICK_SUBSEQUENT:["consumerReference","aliasKey"]}},{}],190:[function(n,i,r){var s=n("../../lib/braintree-error"),a=n("../shared/errors");function o(l,c){var d,u,p=/^([0-9a-zA-Z+/]{4})*(([0-9a-zA-Z+/]{2}==)|([0-9a-zA-Z+/]{3}=))?$/;if(!l||typeof l!="string"||!p.test(l))throw new s(a.LOCAL_PAYMENT_QR_CODE_INVALID_DATA);if(typeof c=="string"){if(d=document.querySelector(c),!d)throw new s({type:s.types.MERCHANT,code:"LOCAL_PAYMENT_QR_CODE_CONTAINER_NOT_FOUND",message:"QR code container element not found: "+c})}else if(c&&c.nodeType===Node.ELEMENT_NODE)d=c;else throw new s(a.LOCAL_PAYMENT_QR_CODE_INVALID_CONTAINER);return d.innerHTML="",u=document.createElement("img"),u.src="data:image/png;base64,"+l,u.alt="QR Code for payment",u.style.display="block",u.style.maxWidth="100%",u.style.height="auto",d.appendChild(u),u}i.exports=o},{"../../lib/braintree-error":149,"../shared/errors":194}],191:[function(n,i,r){var s=n("../../lib/frame-service/external"),a=n("../../lib/braintree-error"),o=n("../../lib/use-min"),l="3.140.0",c=n("../../lib/constants").INTEGRATION_TIMEOUT_MS,d=n("../../lib/analytics"),u=n("../../lib/methods"),p=n("../../lib/convert-methods-to-error"),h=n("../../lib/convert-to-braintree-error"),m=n("@braintree/extended-promise"),v=n("../../lib/querystring"),_=n("@braintree/wrap-promise"),b=n("./constants"),w=n("../shared/errors"),C=n("../../lib/assign").assign,O=n("../../lib/in-iframe"),T=n("../shared/browser-detection"),E=n("./inject-qr-code"),y=1282,P=720;m.suppressUnhandledPromiseMessage=!0;function A(H){this._client=H.client,this._assetsUrl=H.client.getConfiguration().gatewayConfiguration.assetsUrl+"/web/"+l,this._isDebug=H.client.getConfiguration().isDebug,this._loadingFrameUrl=this._assetsUrl+"/html/local-payment-landing-frame"+o(this._isDebug)+".html",this._authorizationInProgress=!1,this._paymentType="unknown",this._merchantAccountId=H.merchantAccountId,H.redirectUrl&&(this._redirectUrl=H.redirectUrl,this._isRedirectFlow=!0)}A.prototype._initialize=function(){var H=this,x=this._client,V=setTimeout(function(){d.sendEvent(x,"local-payment.load.timed-out")},c);return new Promise(function(te){s.create({name:"localpaymentlandingpage",dispatchFrameUrl:H._assetsUrl+"/html/dispatch-frame"+o(H._isDebug)+".html",openFrameUrl:H._loadingFrameUrl},function(fe){H._frameService=fe,clearTimeout(V),d.sendEvent(x,"local-payment.load.succeeded"),te(H)})})},A.prototype.startPayment=function(H){var x,V,te,fe,re,be,Y,oe,K,Z,me,q,ae=this;if(ae._isRedirectFlow?H.redirectUrl=ae._redirectUrl:Z=ae._frameService._serviceId,x=ue(H),x)return V=new a(w.LOCAL_PAYMENT_START_PAYMENT_MISSING_REQUIRED_OPTION),typeof x=="str
105ing"&&(V.details="Missing required '"+x+"' option."),Promise.reject(V);if(H.paymentType&&H.paymentType.toLowerCase()==="swish"&&H.swishOptions&&H.swishOptions.requestQrCode){if(T.isMobileDevice())return Promise.reject(new a(w.LOCAL_PAYMENT_QR_CODE_NOT_SUPPORTED));if(!H.swishOptions.qrContainer)return Promise.reject(new a(w.LOCAL_PAYMENT_START_PAYMENT_MISSING_REQUIRED_OPTION))}return oe=H.windowOptions||{},te=H.address||{},fe=H.fallback||{},Y=H.billingAddress||{},re={amount:H.amount,billingAddress:{line1:Y.streetAddress,line2:Y.extendedAddress,city:Y.locality,state:Y.region,postalCode:Y.postalCode,countryCode:Y.countryCode},birthDate:H.birthDate,blikOptions:H.blikOptions,city:te.locality,correlationId:H.correlationId,countryCode:te.countryCode,currencyIsoCode:H.currencyCode,discountAmount:H.discountAmount,experienceProfile:{brandName:H.displayName,customerServiceInstructions:H.customerServiceInstructions,locale:H.locale,noShipping:!H.shippingAddressRequired},firstName:H.givenName,fundingSource:H.paymentType,intent:"sale",lastName:H.surname,line1:te.streetAddress,line2:te.extendedAddress,lineItems:H.lineItems,merchantAccountId:ae._merchantAccountId,merchantOrPartnerCustomerId:H.customerId,payerEmail:H.email,paymentTypeCountryCode:H.paymentTypeCountryCode,phone:H.phone,phoneCountryCode:H.phoneCountryCode,postalCode:te.postalCode,recurrent:H.recurrent,shippingAmount:H.shippingAmount,state:te.region},ae._paymentType=H.paymentType.toLowerCase(),ae._paymentType==="swish"&&T.isMobileDevice()&&(re.redirectToApp=!0,ae._isRedirectFlow=!0),ae._paymentType==="crypto"&&(ae._isRedirectFlow=!0),ae._isRedirectFlow?ae._paymentType==="swish"&&H.swishOptions&&H.swishOptions.returnUrl&&T.isMobileDevice()?(me=v.queryify(H.swishOptions.returnUrl,{wasCanceled:!0}),q=H.swishOptions.returnUrl):(me=v.queryify(ae._redirectUrl,{wasCanceled:!0}),q=ae._redirectUrl):(me=v.queryify(ae._assetsUrl+"/html/local-payment-redirect-frame"+o(ae._isDebug)+".html",{channel:Z,r:fe.cancelUrl||fe.url,t:fe.cancelButtonText||fe.buttonText,c:1}),q=v.queryify(ae._assetsUrl+"/html/local-payment-redirect-frame"+o(ae._isDebug)+".html",{channel:Z,r:fe.url,t:fe.buttonText})),C(re,{cancelUrl:me,returnUrl:q}),ae._authorizationInProgress&&!ae._isRedirectFlow?(d.sendEvent(ae._client,ae._paymentType+".local-payment.start-payment.error.already-opened"),Promise.reject(new a(w.LOCAL_PAYMENT_ALREADY_IN_PROGRESS))):(ae._authorizationInProgress=!0,be=new m,!I(H)&&!ae._isRedirectFlow&&(ae._startPaymentCallback=ae._createStartPaymentCallback(function(ge){be.resolve(ge)},function(ge){be.reject(ge)}),ae._frameService.open({width:oe.width||y,height:oe.height||P},ae._startPaymentCallback)),ae._paymentType==="crypto"?(d.sendEvent(ae._client,ae._paymentType+".local-payment.start-payment.redirected"),ae._redirectToPaymentResource(H.cryptoOptions.approvalUrl),be.resolve(),be):(ae._client.request({method:"post",endpoint:"local_payments/create",data:re}).then(function(ge){var we=ge.paymentResource.redirectUrl;if(ae._isRedirectFlow?d.sendEvent(ae._client,ae._paymentType+".local-payment.start-payment.redirected"):d.sendEvent(ae._client,ae._paymentType+".local-payment.start-payment.opened"),ae._startPaymentOptions=H,W(H,ge,ae._paymentType)){ae._authorizationInProgress=!1;try{E(ge.paymentResource.qrDetails.qrImage,H.swishOptions.qrContainer)}catch(X){return be.reject(X)}typeof H.onPaymentStart=="function"?(K=H.onPaymentStart({paymentId:ge.paymentResource.paymentToken}),K instanceof Promise?K.then(function(){be.resolve()}).catch(function(X){be.reject(X)}):be.resolve()):be.resolve()}else I(H)?(ae._authorizationInProgress=!1,typeof we=="string"&&we.length?be.reject(new a(w.LOCAL_PAYMENT_START_PAYMENT_DEFERRED_PAYMENT_FAILED)):(K=H.onPaymentStart({paymentId:ge.paymentResource.paymentToken}),K instanceof Promise?K.then(function(){be.resolve()}).catch(function(X){be.reject(X)}):be.resolve())):typeof H.onPaymentStart=="function"?Promise.resolve(H.onPaymentStart({paymentId:ge.paymentResource.paymentToken},function(){ae._isRedirectFlow||ae._frameService.redirect(we)})).then(function(){ae._isRedirectFlow&&(ae._redirectToPaymentResource(we),be.resolve())}):ae._isRedirectFlow?(ae._redirectToPaymentResource(we),be.resolve()):ae._isRedirectFlow||ae._frameService.redirect(we);return be}).catch(function(ge){var we=ge.details&&ge.details.httpStatus;if(ae._isRedirectFlow||ae._frameService.close(),ae._authorizationInProgress=!1,we===422){be.reject(new a({type:w.LOCAL_PAYMENT_INVALID_PAYMENT_OPTION.type,code:w.LOCAL_PAYMENT_INVALID_PAYMENT_OPTION.code,message:w.LOCAL_PAYMENT_INVALID_PAYMENT_OPTION.message,details:{originalError:ge}}));return}be.reject(h(ge,{type:w.LOCAL_PAYMENT_START_PAYMENT_FAILED.type,code:w.LOCAL_PAYMENT_START_PAYMENT_FAILED.code,message:w.LOCAL_PAYMENT_START_PAYMENT_FAILED.message}))}),be))},A.prototype._redirectToPaymentResource=function(H){O()?window.top.location.href=H:window.location.href=H},A.prototype.tokenize=function(H){var x=this,V=this._client;return H=H||v.parse(),H.queryItems&&(H=H.queryItems),H.c||H.wasCanceled?Promise.reject(new a({type:w.LOCAL_PAYMENT_CANCELED.type,code:w.LOCAL_PAYMENT_CANCELED.code,message:w.LOCAL_PAYMENT_CANCELED.message,details:{originalError:{errorcode:H.errorcode,token:H.bt
105LpToken}}})):H.errorcode?Promise.reject(new a({type:w.LOCAL_PAYMENT_START_PAYMENT_FAILED.type,code:w.LOCAL_PAYMENT_START_PAYMENT_FAILED.code,message:w.LOCAL_PAYMENT_START_PAYMENT_FAILED.message,details:{originalError:{errorcode:H.errorcode,token:H.btLpToken}}})):V.request({endpoint:"payment_methods/paypal_accounts",method:"post",data:this._formatTokenizeData(H)}).then(function(te){var fe=x._formatTokenizePayload(te);return window.popupBridge?d.sendEvent(V,x._paymentType+".local-payment.tokenization.success-popupbridge"):d.sendEvent(V,x._paymentType+".local-payment.tokenization.success"),fe}).catch(function(te){return d.sendEvent(V,x._paymentType+".local-payment.tokenization.failed"),Promise.reject(h(te,{type:w.LOCAL_PAYMENT_TOKENIZATION_FAILED.type,code:w.LOCAL_PAYMENT_TOKENIZATION_FAILED.code,message:w.LOCAL_PAYMENT_TOKENIZATION_FAILED.message}))})},A.prototype.closeWindow=function(){this._authoriztionInProgress&&d.sendEvent(this._client,this._paymentType+".local-payment.start-payment.closed.by-merchant"),this._frameService.close()},A.prototype.focusWindow=function(){this._frameService.focus()},A.prototype._createStartPaymentCallback=function(H,x){var V=this,te=this._client;return function(fe,re){if(V._authorizationInProgress=!1,fe)if(fe.code==="FRAME_SERVICE_FRAME_CLOSED"){if(re&&re.errorcode==="processing_error"){d.sendEvent(te,V._paymentType+".local-payment.failed-in-window"),x(new a(w.LOCAL_PAYMENT_START_PAYMENT_FAILED));return}d.sendEvent(te,V._paymentType+".local-payment.tokenization.closed.by-user"),x(new a(w.LOCAL_PAYMENT_WINDOW_CLOSED))}else fe.code&&fe.code.indexOf("FRAME_SERVICE_FRAME_OPEN_FAILED")>-1&&x(new a({code:w.LOCAL_PAYMENT_WINDOW_OPEN_FAILED.code,type:w.LOCAL_PAYMENT_WINDOW_OPEN_FAILED.type,message:w.LOCAL_PAYMENT_WINDOW_OPEN_FAILED.message,details:{originalError:fe}}));else re&&(window.popupBridge||V._frameService.redirect(V._loadingFrameUrl),V.tokenize(re).then(H).catch(x).then(function(){V._frameService.close()}))}},A.prototype._formatTokenizePayload=function(H){var x,V={};return H.paypalAccounts&&(V=H.paypalAccounts[0]),x={nonce:V.nonce,details:{},type:V.type},V.details&&(V.details.payerInfo&&(x.details=V.details.payerInfo),V.details.correlationId&&(x.correlationId=V.details.correlationId)),x},A.prototype.hasTokenizationParams=function(){var H=v.parse();return H.errorcode||H.token?!0:!!(H.btLpToken&&H.btLpPaymentId&&H.btLpPayerId)},A.prototype._formatTokenizeData=function(H){var x=this._client.getConfiguration(),V=x.gatewayConfiguration,te={merchantAccountId:this._merchantAccountId,paypalAccount:{correlationId:H.btLpToken||H.token,paymentToken:H.btLpPaymentId||H.paymentId,payerId:H.btLpPayerId||H.PayerID,unilateral:V.paypal.unvettedMerchant,intent:"sale"}};return te};function I(H){var x=H.blikOptions||{},V=typeof H.paymentType=="string"?H.paymentType.toLowerCase():H.paymentType;return V==="blik"?x.hasOwnProperty("level_0")||x.hasOwnProperty("oneClick"):V==="swish"&&H.swishOptions&&H.swishOptions.requestQrCode?!0:["pay_upon_invoice","mbway","bancomatpay"].includes(V)}function L(H){var x,V;for(x=0;x<b.REQUIRED_OPTIONS_FOR_ADDRESS.length;x++)if(V=b.REQUIRED_OPTIONS_FOR_ADDRESS[x],!H.hasOwnProperty(V))return V;return!1}function D(H){var x,V,te,fe;for(V=0;V<H.length;V++)for(te=H[V],x=0;x<b.REQUIRED_OPTIONS_FOR_LINE_ITEMS.length;x++)if(fe=b.REQUIRED_OPTIONS_FOR_LINE_ITEMS[x],!te.hasOwnProperty(fe))return fe;return!1}function z(H){var x,V,te,fe=H.blikOptions||{};for(H.redirectUrl||b.REQUIRED_OPTIONS_FOR_BLIK_SEAMLESS_PAYMENT_TYPE.push("onPaymentStart"),x=0;x<b.REQUIRED_OPTIONS_FOR_BLIK_SEAMLESS_PAYMENT_TYPE.length;x++)if(V=b.REQUIRED_OPTIONS_FOR_BLIK_SEAMLESS_PAYMENT_TYPE[x],!H.hasOwnProperty(V))return V;if(fe.hasOwnProperty("level_0")){for(x=0;x<b.REQUIRED_OPTIONS_FOR_BLIK_OPTIONS_LEVEL_0.length;x++)if(V=b.REQUIRED_OPTIONS_FOR_BLIK_OPTIONS_LEVEL_0[x],!fe.level_0.hasOwnProperty(V))return"blikOptions.level_0."+V}else if(fe.hasOwnProperty("oneClick")){if(te=fe.oneClick||{},te.hasOwnProperty("aliasKey")){for(x=0;x<b.REQUIRED_OPTIONS_FOR_BLIK_OPTIONS_ONE_CLICK_SUBSEQUENT.length;x++)if(V=b.REQUIRED_OPTIONS_FOR_BLIK_OPTIONS_ONE_CLICK_SUBSEQUENT[x],!te.hasOwnProperty(V))return"blikOptions.oneClick."+V}else for(x=0;x<b.REQUIRED_OPTIONS_FOR_BLIK_OPTIONS_ONE_CLICK_FIRST.length;x++)if(V=b.REQUIRED_OPTIONS_FOR_BLIK_OPTIONS_ONE_CLICK_FIRST[x],!te.hasOwnProperty(V))return"blikOptions.oneClick."+V}return!1}
105function G(H){var x=H.cryptoOptions||{};return x.approvalUrl?!1:"cryptoOptions.approvalUrl"}function ne(H){var x,V,te=H.swishOptions||{},fe=["givenName","surname","currencyCode","paymentType","amount"];for(x=0;x<fe.length;x++)if(V=fe[x],!H.hasOwnProperty(V))return V;return te.requestQrCode&&!te.qrContainer?"swishOptions.qrContainer":!te.requestQrCode&&!te.returnUrl&&!H.redirectUrl&&T.isMobileDevice()?"swishOptions.returnUrl":!1}function W(H,x,V){return!!(V==="swish"&&H.swishOptions&&H.swishOptions.requestQrCode&&x.paymentResource.qrDetails&&x.paymentResource.qrDetails.qrImage)}function ue(H){var x,V,te,fe,re;if(!H)return!0;if(re=H.paymentType||"",re.toLowerCase()==="crypto")return G(H);if(re.toLowerCase()==="swish")return ne(H);if(I(H)){if(re.toLowerCase()==="pay_upon_invoice")for(x=0;x<b.REQUIRED_OPTIONS_FOR_PAY_UPON_INVOICE_PAYMENT_TYPE.length;x++){if(V=b.REQUIRED_OPTIONS_FOR_PAY_UPON_INVOICE_PAYMENT_TYPE[x],!H.hasOwnProperty(V))return V;if(V==="address"||V==="billingAddress"){if(te=L(H[V]),te)return V+"."+te}else if(V==="lineItems"&&(fe=D(H[V]),fe))return V+"."+fe}else if(re.toLowerCase()==="blik")return z(H)}else{for(H.redirectUrl||b.REQUIRED_OPTIONS_FOR_START_PAYMENT.push("onPaymentStart"),x=0;x<b.REQUIRED_OPTIONS_FOR_START_PAYMENT.length;x++)if(V=b.REQUIRED_OPTIONS_FOR_START_PAYMENT[x],!H.hasOwnProperty(V))return V;if(!H.fallback.url)return"fallback.url";if(!H.fallback.buttonText)return"fallback.buttonText";if(H.recurrent===!0&&!H.customerId)return"customerId"}return!1}A.prototype.teardown=function(){var H=this;return H._isRedirectFlow||H._frameService.teardown(),p(H,u(A.prototype)),d.sendEvent(H._client,"local-payment.teardown-completed"),Promise.resolve()},i.exports=_.wrapPrototype(A)},{"../../lib/analytics":144,"../../lib/assign":146,"../../lib/braintree-error":149,"../../lib/constants":150,"../../lib/convert-methods-to-error":151,"../../lib/convert-to-braintree-error":152,"../../lib/frame-service/external":163,"../../lib/in-iframe":175,"../../lib/methods":181,"../../lib/querystring":183,"../../lib/use-min":187,"../shared/browser-detection":193,"../shared/errors":194,"./constants":189,"./inject-qr-code":190,"@braintree/extended-promise":34,"@braintree/wrap-promise":43}],192:[function(n,i,r){var s=n("../lib/analytics"),a=n("../lib/basic-component-verification"),o=n("../lib/create-deferred-client"),l=n("../lib/create-assets-url"),c=n("./external/local-payment"),d="3.140.0",u=n("@braintree/wrap-promise"),p=n("../lib/braintree-error"),h=n("./shared/errors"),m=n("../lib/querystring").parse;function v(_){var b="Local Payment";return a.verify({name:b,client:_.client,authorization:_.authorization}).then(function(){return o.create({authorization:_.authorization,client:_.client,debug:_.debug,assetsUrl:l.create(_.authorization),name:b})}).then(function(w){var C,O,T=w.getConfiguration();return _.client=w,T.gatewayConfiguration.paypalEnabled!==!0?Promise.reject(new p(h.LOCAL_PAYMENT_NOT_ENABLED)):(s.sendEvent(w,"local-payment.initialized"),C=new c(_),_.redirectUrl?(O=m(window.location.href),O.token||O.wasCanceled?C.tokenize(O).then(function(E){return C.tokenizePayload=E,C}).catch(function(E){return console.log("Error while tokenizing: ",E),C}):C):C._initialize())})}i.exports={create:u(v),VERSION:d}},{"../lib/analytics":144,"../lib/basic-component-verification":147,"../lib/braintree-error":149,"../lib/create-assets-url":153,"../lib/create-deferred-client":155,"../lib/querystring":183,"./external/local-payment":191,"./shared/errors":194,"@braintree/wrap-promise":43}],193:[function(n,i,r){var s=n("@braintree/browser-detection/is-android"),a=n("@braintree/browser-detection/is-ios");function o(){return s()||a()}i.exports={isMobileDevice:o}},{"@braintree/browser-detection/is-android":22,"@braintree/browser-detection/is-ios":30}],194:[function(n,i,r){var s=n("../../lib/braintree-error");i.exports={LOCAL_PAYMENT_NOT_ENABLED:{type:s.types.MERCHANT,code:"LOCAL_PAYMENT_NOT_ENABLED",message:"LocalPayment is not enabled for this merchant."},LOCAL_PAYMENT_ALREADY_IN_PROGRESS:{type:s.types.MERCHANT,code:"LOCAL_PAYMENT_ALREADY_IN_PROGRESS",message:"LocalPayment payment is already in progress."},LOCAL_PAYMENT_CANCELED:{type:s.types.CUSTOMER,code:"LOCAL_PAYMENT_CANCELED",message:"Customer canceled the LocalPayment before authorizing."},LOCAL_PAYMENT_WINDOW_CLOSED:{type:s.types.CUSTOMER,code:"LOCAL_PAYMENT_WINDOW_CLOSED",message:"Customer closed LocalPayment window before authorizing."},LOCAL_PAYMENT_WINDOW_OPEN_FAILED:{type:s.types.MERCHANT,code:"LOCAL_PAYMENT_WINDOW_OPEN_FAILED",message:"LocalPayment window failed to open;
105 make sure startPayment was called in response to a user action."},LOCAL_PAYMENT_START_PAYMENT_FAILED:{type:s.types.NETWORK,code:"LOCAL_PAYMENT_START_PAYMENT_FAILED",message:"LocalPayment startPayment failed."},LOCAL_PAYMENT_START_PAYMENT_MISSING_REQUIRED_OPTION:{type:s.types.MERCHANT,code:"LOCAL_PAYMENT_START_PAYMENT_MISSING_REQUIRED_OPTION",message:"Missing required option for startPayment."},LOCAL_PAYMENT_START_PAYMENT_DEFERRED_PAYMENT_FAILED:{type:s.types.UNKNOWN,code:"LOCAL_PAYMENT_START_PAYMENT_DEFERRED_PAYMENT_FAILED",message:"LocalPayment startPayment deferred payment failed."},LOCAL_PAYMENT_TOKENIZATION_FAILED:{type:s.types.NETWORK,code:"LOCAL_PAYMENT_TOKENIZATION_FAILED",message:"Could not tokenize user's local payment method."},LOCAL_PAYMENT_INVALID_PAYMENT_OPTION:{type:s.types.MERCHANT,code:"LOCAL_PAYMENT_INVALID_PAYMENT_OPTION",message:"Local payment options are invalid."},LOCAL_PAYMENT_QR_CODE_INVALID_DATA:{type:s.types.MERCHANT,code:"LOCAL_PAYMENT_QR_CODE_INVALID_DATA",message:"QR code data must be a valid base64 string."},LOCAL_PAYMENT_QR_CODE_CONTAINER_NOT_FOUND:{type:s.types.MERCHANT,code:"LOCAL_PAYMENT_QR_CODE_CONTAINER_NOT_FOUND",message:"QR code container element not found."},LOCAL_PAYMENT_QR_CODE_INVALID_CONTAINER:{type:s.types.MERCHANT,code:"LOCAL_PAYMENT_QR_CODE_INVALID_CONTAINER",message:"QR code container must be a valid CSS selector string or HTML element."},LOCAL_PAYMENT_QR_CODE_NOT_SUPPORTED:{type:s.types.MERCHANT,code:"LOCAL_PAYMENT_QR_CODE_NOT_SUPPORTED",message:"QR code is only supported on desktop devices."}}},{"../../lib/braintree-error":149}],195:[function(n,i,r){var s=n("../../lib/frame-service/external"),a=n("../../lib/braintree-error"),o=n("../shared/errors"),l="3.140.0",c=n("../../lib/methods"),d=n("@braintree/wrap-promise"),u=n("../../lib/analytics"),p=n("../../lib/convert-methods-to-error"),h=n("../../lib/convert-to-braintree-error"),m=n("../shared/constants"),v=n("../../lib/constants").INTEGRATION_TIMEOUT_MS;function _(C){var O=C.client.getConfiguration();this._client=C.client,this._assetsUrl=O.gatewayConfiguration.assetsUrl+"/web/"+l,this._isDebug=O.isDebug,this._authInProgress=!1,window.popupBridge&&typeof window.popupBridge.getReturnUrlPrefix=="function"?this._callbackUrl=window.popupBridge.getReturnUrlPrefix()+"return":this._callbackUrl=this._assetsUrl+"/html/redirect-frame"+(this._isDebug?"":".min")+".html"}_.prototype._initialize=function(){var C=this;return new Promise(function(O){var T=setTimeout(function(){u.sendEvent(C._client,"masterpass.load.timed-out")},v);s.create({name:m.LANDING_FRAME_NAME,height:m.POPUP_HEIGHT,width:m.POPUP_WIDTH,dispatchFrameUrl:C._assetsUrl+"/html/dispatch-frame"+(C._isDebug?"":".min")+".html",openFrameUrl:C._assetsUrl+"/html/masterpass-landing-frame"+(C._isDebug?"":".min")+".html"},function(E){C._frameService=E,clearTimeout(T),u.sendEvent(C._client,"masterpass.load.succeeded"),O(C)})})},_.prototype.tokenize=function(C){var O=this;return!C||w(C)?Promise.reject(new a(o.MASTERPASS_TOKENIZE_MISSING_REQUIRED_OPTION)):O._authInProgress?Promise.reject(new a(o.MASTERPASS_TOKENIZATION_ALREADY_IN_PROGRESS)):new Promise(function(T,E){O._navigateFrameToLoadingPage(C).catch(E),O._frameService.open(C.frameOptions,O._createFrameOpenHandler(T,E))})},_.prototype._navigateFrameToLoadingPage=function(C){var O=this;return this._authInProgress=!0,this._client.request({method:"post",endpoint:"masterpass/request_token",data:{requestToken:{originUrl:window.location.protocol+"//"+window.location.hostname,subtotal:C.subtotal,currencyCode:C.currencyCode,callbackUrl:this._callbackUrl}}}).then(function(T){var E=O._assetsUrl+"/html/masterpass-loading-frame"+(O._isDebug?"":".min")+".html?",y=O._client.getConfiguration().gatewayConfiguration,P=C.config||{},A;A={environment:y.environment,requestToken:T.requestToken,callbackUrl:O._callbackUrl,merchantCheckoutId:y.masterpass.merchantCheckoutId,allowedCardTypes:y.masterpass.supportedNetworks,version:m.MASTERPASS_VERSION},Object.keys(P).forEach(function(I){typeof P[I]!="function"&&(A[I]=P[I])}),E+=Object.keys(A).map(function(I){return I+"="+A[I]}).join("&"),O._frameService.redirect(E)}).catch(function(T){var E=T.details&&T.details.httpStatus;return O._closeWindow(),E===422?Promise.reject(h(T,o.MASTERPASS_INVALID_PAYMENT_OPTION)):Promise.reject(h(T,o.MASTERPASS_FLOW_FAILED))})},_.prototype._createFrameOpenHandler=function(C,O){var T=this;return window.popupBridge?function(E,y){if(T._authInProgress=!1,E){u.sendEvent(T._client,"masterpass.tokenization.closed-popupbridge.by-user"),O(h(E,o.MASTERPASS_POPUP_CLOSED));return}if(!y.queryItems){u.sendEvent(T._client,"masterpass.tokenization.failed-popupbridge"),O(new a(o.MASTERPASS_FLOW_FAILED));return}T._tokenizeMasterpass(y.queryItems).then(C).catch(O)}:function(E,y){if(E){if(T._authInProgress=!1,E.code==="FRAME_SERVICE_FRAME_CLOSED"){u.sendEvent(T._client,"masterpass.tokenization.closed.by-user"),O(new a(o.MASTERPASS_POPUP_CLOSED));return}if(E.code&&E.code.indexOf("FRAME_SERVICE_FRAME_OPEN_FAILED")>-1){u.sendEvent(T._client,"masterpass.tokenization.failed.to-open"),O(new a({code:o.MASTERPASS_POPUP_OPEN_FAILED.code,type:o.MASTERPASS_POPUP_OPEN_FAILED.type,message:o.MASTERPASS_POPUP_OPEN_FAILED.message,details:{originalError:E}}));return}u.sendEvent(T._client,"masterpass.tokenization.failed"),T._closeWindow(),O(h(E,o.MASTERPASS_FLOW_FAILED));return}T._tokenizeMasterpass(y).then(C).catch(O)}},_.prototype._tokenizeMasterpass=function(C){var O=this;return C.mpstatus!=="success"?(u.sendEvent(O._client,"masterpass.tokenization.closed.by-user"),O._closeWindow(),Promise.reject(new a(o.MASTERPASS_POPUP_CLOSED))):b(C)?(u.sendEvent(O._client,"masterpass.tokenization.closed.missing-payload"),O._closeWindow(),Promise.reject(new a(o.MASTERPASS_POPUP_MISSING_REQUIRED_PARAMETERS))):O._client.request({endpoint:"payment_methods/masterpass_cards",method:"post",data:{masterpassCard:{checkoutRe
105sourceUrl:C.checkout_resource_url,requestToken:C.oauth_token,verifierToken:C.oauth_verifier}}}).then(function(T){return O._closeWindow(),window.popupBridge?u.sendEvent(O._client,"masterpass.tokenization.success-popupbridge"):u.sendEvent(O._client,"masterpass.tokenization.success"),T.masterpassCards[0]}).catch(function(T){return O._closeWindow(),window.popupBridge?u.sendEvent(O._client,"masterpass.tokenization.failed-popupbridge"):u.sendEvent(O._client,"masterpass.tokenization.failed"),Promise.reject(h(T,o.MASTERPASS_ACCOUNT_TOKENIZATION_FAILED))})};function b(C){return[C.oauth_verifier,C.oauth_token,C.checkout_resource_url].some(function(O){return O==null||O==="null"})}_.prototype._closeWindow=function(){this._authInProgress=!1,this._frameService.close()},_.prototype.teardown=function(){var C=this;return new Promise(function(O){C._frameService.teardown(),p(C,c(_.prototype)),u.sendEvent(C._client,"masterpass.teardown-completed"),O()})};function w(C){var O,T;for(O=0;O<m.REQUIRED_OPTIONS_FOR_TOKENIZE.length;O++)if(T=m.REQUIRED_OPTIONS_FOR_TOKENIZE[O],!C.hasOwnProperty(T))return!0;return!1}i.exports=d.wrapPrototype(_)},{"../../lib/analytics":144,"../../lib/braintree-error":149,"../../lib/constants":150,"../../lib/convert-methods-to-error":151,"../../lib/convert-to-braintree-error":152,"../../lib/frame-service/external":163,"../../lib/methods":181,"../shared/constants":198,"../shared/errors":199,"@braintree/wrap-promise":43}],196:[function(n,i,r){var s=n("../lib/braintree-error"),a=n("../lib/basic-component-verification"),o=n("./shared/browser-detection"),l=n("./external/masterpass"),c=n("../lib/create-deferred-client"),d=n("../lib/create-assets-url"),u="3.140.0",p=n("./shared/errors"),h=n("@braintree/wrap-promise");function m(_){var b="Masterpass";return a.verify({name:b,client:_.client,authorization:_.authorization}).then(function(){return v()?Promise.resolve():Promise.reject(new s(p.MASTERPASS_BROWSER_NOT_SUPPORTED))}).then(function(){return c.create({authorization:_.authorization,client:_.client,debug:_.debug,assetsUrl:d.create(_.authorization),name:b})}).then(function(w){var C,O;return _.client=w,O=_.client.getConfiguration().gatewayConfiguration,O.masterpass?(C=new l(_),C._initialize()):Promise.reject(new s(p.MASTERPASS_NOT_ENABLED))})}function v(){return!!(window.popupBridge||o.supportsPopups())}i.exports={create:h(m),isSupported:v,VERSION:u}},{"../lib/basic-component-verification":147,"../lib/braintree-error":149,"../lib/create-assets-url":153,"../lib/create-deferred-client":155,"./external/masterpass":195,"./shared/browser-detection":197,"./shared/errors":199,"@braintree/wrap-promise":43}],197:[function(n,i,r){i.exports={supportsPopups:n("@braintree/browser-detection/supports-popups")}},{"@braintree/browser-detection/supports-popups":32}],198:[function(n,i,r){i.exports={LANDING_FRAME_NAME:"braintreemasterpasslanding",POPUP_WIDTH:450,POPUP_HEIGHT:660,MASTERPASS_VERSION:"v6",REQUIRED_OPTIONS_FOR_TOKENIZE:["subtotal","currencyCode"]}},{}],199:[function(n,i,r){var s=n("../../lib/braintree-error");i.exports={MASTERPASS_BROWSER_NOT_SUPPORTED:{type:s.types.CUSTOMER,code:"MASTERPASS_BROWSER_NOT_SUPPORTED",message:"Browser is not supported."},MASTERPASS_NOT_ENABLED:{type:s.types.MERCHANT,code:"MASTERPASS_NOT_ENABLED",message:"Masterpass is not enabled for this merchant."},MASTERPASS_TOKENIZE_MISSING_REQUIRED_OPTION:{type:s.types.MERCHANT,code:"MASTERPASS_TOKENIZE_MISSING_REQUIRED_OPTION",message:"Missing required option for tokenize."},MASTERPASS_TOKENIZATION_ALREADY_IN_PROGRESS:{type:s.types.MERCHANT,code:"MASTERPASS_TOKENIZATION_ALREADY_IN_PROGRESS",message:"Masterpass tokenization is already in progress."},MASTERPASS_ACCOUNT_TOKENIZATION_FAILED:{type:s.types.NETWORK,code:"MASTERPASS_ACCOUNT_TOKENIZATION_FAILED",message:"Could not tokenize user's Masterpass account."},MASTERPASS_POPUP_OPEN_FAILED:{type:s.types.MERCHANT,code:"MASTERPASS_POPUP_OPEN_FAILED",message:"Masterpass popup failed to open. Make sure to tokenize in response to a user action, such as a click."},MASTERPASS_POPUP_MISSING_REQUIRED_PARAMETERS:{type:s.types.MERCHANT,code:"MASTERPASS_POPUP_MISSING_REQUIRED_PARAMETERS",message:"Masterpass popup failed to return all required parameters needed to continue tokenization."},MASTERPASS_POPUP_CLOSED:{type:s.types.CUSTOMER,code:"MASTERPASS_POPUP_CLOSED",message:"Customer closed Masterpass popup before authorizing."},MASTERPASS_INVALID_PAYMENT_OPTION:{type:s.types.MERCHANT,code:"MASTERPASS_INVALID_PAYMENT_OPTION",message:"Masterpass payment options are invalid."},MASTERPASS_FLOW_FAILED:{type:s.types.NETWORK,code:"MASTERPASS_FLOW_FAILED",message:"Could not initialize Masterpass flow."}}},{"../../lib/braintree-error":149}],200:[function(n,i,r){i.exports={CREATE_PAYMENT_READY_SESSION_QUERY:`mutation CreateCustomerSession($input: CreateCustomerSessionInput!) {
106  createCustomerSession(input: $input) {
107    sessionId
108 clientMutationId
109 }
110}
110`,BUTTON_ORDER:{FIRST:"first",SECOND:"second",THIRD:"third",FOURTH:"fourth",FIFTH:"fifth",SIXTH:"sixth",SEVENTH:"seventh",EIGHT:"eight",OTHER:"other"},BUTTON_TYPE:{PAYPAL:"paypal",VENMO:"venmo",OTHER:"other"},EVENT_BUTTON_PRESENTED:"payment-ready.button_presented",EVENT_BUTTON_SELECTED:"payment-ready.button_selected",EXPERIMENT_TYPE:{CONTROL:"control",TEST:"test"},PAGE_TYPE:{HOMEPAGE:"homepage",ABOUT:"about",PRODUCT_CATEGORY:"product_category",PRODUCT_DETAILS:"product_details",SEARCH:"search",CART:"cart",CHECKOUT:"checkout",ORDER_REVIEW:"order_review",ORDER_CONFIRMATION:"order_confirmation",MINICART:"minicart",OTHER:"other"},UPDATE_PAYMENT_READY_SESSION_QUERY:`mutation UpdateCustomerSession($input: UpdateCustomerSessionInput!) {
111  updateCustomerSession(input: $input) {
112    sessionId
113 clientMutationId
114 }
115}`,GENERATE_CUSTOMER_RECOMMENDATIONS_QUERY:`mutation GenerateCustomerRecommendations($input: GenerateCustomerRecommendationsInput!) {
116  generateCustomerRecommendations(input: $input) {
117     clientMutationId
118      sessionId
119      paymentRecommendations {
120        paymentOption
121        recommendedPriority
122      }
123      isInPayPalNetwork
124  }
125}`,REQUIRED_OPTIONS_CREATE_SESSION:["customer"],REQUIRED_OPTIONS_UPDATE_SESSION:["sessionId","customer"],REQUIRED_OPTIONS_GET_RECOMMENDATIONS:["sessionId"]}},{}],201:[function(n,i,r){var s=n("../lib/braintree-error");i.exports={PAYMENT_READY_ERROR:{type:s.types.MERCHANT,code:"PAYMENT_READY_ERROR"},PAYMENT_READY_MISSING_REQUIRED_OPTION:{type:s.types.MERCHANT,code:"PAYMENT_READY_MISSING_REQUIRED_OPTION",message:"Missing required option for Payment Ready method."},PAYMENT_READY_CREATE_SESSION_ERROR:{type:s.types.NETWORK,code:"PAYMENT_READY_CREATE_SESSION_ERROR",message:"Error creating customer session."},PAYMENT_READY_UPDATE_SESSION_ERROR:{type:s.types.NETWORK,code:"PAYMENT_READY_UPDATE_SESSION_ERROR",message:"Error updating customer session."},PAYMENT_READY_NO_SESSION_ID:{type:s.types.MERCHANT,code:"PAYMENT_READY_NO_SESSION_ID",message:"A session ID is required"},PAYMENT_READY_GET_RECOMMENDATIONS_ERROR:{type:s.types.NETWORK,code:"PAYMENT_READY_GET_RECOMMENDATIONS_ERROR",message:"Error getting customer recommendations"}}},{"../lib/braintree-error":149}],202:[function(n,i,r){var s=n("../lib/analytics"),a=n("./payment-ready"),o=n("../lib/create-assets-url"),l=n("../lib/create-deferred-client"),c=n("../lib/basic-component-verification"),d=n("@braintree/wrap-promise"),u="3.140.0";function p(h){var m="PAYMENT READY";return c.verify({name:m,client:h.client,authorization:h.authorization}).then(function(){return l.create({authorization:h.authorization,client:h.client,debug:h.debug,assetsUrl:o.create(h.authorization),name:m})}).then(function(v){return h.client=v,s.sendEvent(v,"payment-ready.client.initialized"),new a(h)})}i.exports={create:d(p),VERSION:u}},{"../lib/analytics":144,"../lib/basic-component-verification":147,"../lib/create-assets-url":153,"../lib/create-deferred-client":155,"./payment-ready":203,"@braintree/wrap-promise":43}],203:[function(n,i,r){var s=n("@braintree/wrap-promise"),a=n("../lib/analytics"),o=n("../lib/braintree-error"),l=n("./constants"),c=n("./errors"),d=n("../lib/has-missing-option");function u(h){this._instantiatedWithClient=!h.useDeferredClient,this._client=h.client,this._createPromise=h.createPromise}u.prototype.createCustomerSession=function(h){var m=this;return!h||d(h,l.REQUIRED_OPTIONS_CREATE_SESSION)?(a.sendEvent(m._client,"payment-ready.create-customer-session.missing-options"),Promise.reject(new o(c.PAYMENT_READY_MISSING_REQUIRED_OPTION))):m._client.request({api:"graphQLApi",data:{query:l.CREATE_PAYMENT_READY_SESSION_QUERY,variables:{input:{sessionId:h.sessionId,customer:h.customer}}}}).then(function(v){return a.sendEvent(m._client,"payment-ready.create-customer-session.succeeded"),v.data.createCustomerSession}).catch(function(v){return a.sendEvent(m._client,"payment-ready.create-customer-session.failed"),Promise.reject(new o({type:v.type||c.PAYMENT_READY_CREATE_SESSION_ERROR.type,code:v.code||c.PAYMENT_READY_CREATE_SESSION_ERROR.code,message:v.message||c.PAYMENT_READY_CREATE_SESSION_ERROR.message,details:{originalError:v}}))})},u.prototype.updateCustomerSession=function(h){var m=this;return!h||d(h,l.REQUIRED_OPTIONS_UPDATE_SESSION)?(a.sendEvent(m._client,"payment-ready.update-customer-session.missing-options"),Promise.reject(new o(c.PAYMENT_READY_MISSING_REQUIRED_OPTION))):m._client.request({api:"graphQLApi",data:{query:l.UPDATE_PAYMENT_READY_SESSION_QUERY,variables:{input:{sessionId:h.sessionId,customer:h.customer}}}}).then(function(v){return a.sendEvent(m._client,"payment-ready.update-customer-session.succeeded"),v.data.updateCustomerSession}
125).catch(function(v){return a.sendEvent(m._client,"payment-ready.update-customer-session.failed"),Promise.reject(new o({type:v.type||c.PAYMENT_READY_UPDATE_SESSION_ERROR.type,code:v.code||c.PAYMENT_READY_UPDATE_SESSION_ERROR.code,message:v.message||c.PAYMENT_READY_UPDATE_SESSION_ERROR.message,details:{originalError:v}}))})},u.prototype.getCustomerRecommendations=function(h){var m=this;return!h||d(h,l.REQUIRED_OPTIONS_GET_RECOMMENDATIONS)?(a.sendEvent(m._client,"payment-ready.get-customer-recommendations.missing-options"),Promise.reject(new o(c.PAYMENT_READY_NO_SESSION_ID))):m._client.request({api:"graphQLApi",data:{query:l.GENERATE_CUSTOMER_RECOMMENDATIONS_QUERY,variables:{input:{sessionId:h.sessionId,customer:h.customer,domain:h.domain,purchaseUnits:h.purchaseUnits}}}}).then(function(v){return a.sendEvent(m._client,"payment-ready.get-customer-recommendations.succeeded"),v.data.generateCustomerRecommendations}).catch(function(v){return a.sendEvent(m._client,"payment-ready.get-customer-recommendations.failed"),Promise.reject(new o({type:v.type||c.PAYMENT_READY_GET_RECOMMENDATIONS_ERROR.type,code:v.code||c.PAYMENT_READY_GET_RECOMMENDATIONS_ERROR.code,message:v.message||c.PAYMENT_READY_GET_RECOMMENDATIONS_ERROR.message,details:{originalError:v}}))})},u.prototype.sendPresentedEvent=function(h){var m=h.presentmentDetails?h.presentmentDetails.experimentType:null,v=h.presentmentDetails?h.presentmentDetails.pageType:null,_=h.presentmentDetails?h.presentmentDetails.buttonOrder:null;if(!h.paymentReadySessionId||typeof h.paymentReadySessionId!="string"){console.warn("sendPresentedEvent: paymentReadySessionId is missing or invalid");return}if(!h.buttonType||typeof h.buttonType!="string"){console.warn("sendPresentedEvent: buttonType is missing");return}var b=h.buttonType,w;Object.values(l.BUTTON_TYPE).includes(b)||(b=l.BUTTON_TYPE.OTHER),_&&!Object.values(l.BUTTON_ORDER).includes(_)&&(_=l.BUTTON_ORDER.OTHER),m&&!Object.values(l.EXPERIMENT_TYPE).includes(m)&&(m=l.EXPERIMENT_TYPE.TEST),v&&!Object.values(l.PAGE_TYPE).includes(v)&&(v=l.PAGE_TYPE.OTHER),w=p({buttonOrder:_,buttonType:b,experimentType:m,pageType:v,sessionId:h.paymentReadySessionId}),a.sendEventPlus(this._client,l.EVENT_BUTTON_PRESENTED,w)};function p(h){var m={button_type:h.buttonType,payment_ready_session_id:h.sessionId};return h.buttonOrder&&(m.payment_ready_button_order=h.buttonOrder),h.experimentType&&(m.payment_ready_experiment_type=h.experimentType),h.pageType&&(m.payment_ready_page_type=h.pageType),m}u.prototype.sendSelectedEvent=function(h){if(!h.paymentReadySessionId||typeof h.paymentReadySessionId!="string"){console.warn("sendSelectedEvent: paymentReadySessionId is missing or invalid");return}if(!h.buttonType||typeof h.buttonType!="string"){console.warn("sendSelectedEvent: buttonType is missing");return}var m=h.buttonType;Object.values(l.BUTTON_TYPE).includes(m)||(m=l.BUTTON_TYPE.OTHER),a.sendEventPlus(this._client,l.EVENT_BUTTON_SELECTED,{payment_ready_session_id:h.paymentReadySessionId,button_type:m})},i.exports=s.wrapPrototype(u)},{"../lib/analytics":144,"../lib/braintree-error":149,"../lib/has-missing-option":174,"./constants":200,"./errors":201,"@braintree/wrap-promise":43}],204:[function(n,i,r){var s=n("../../lib/analytics"),a=n("../../lib/assign").assign,o=n("framebus"),l=n("../../lib/convert-methods-to-error"),c=n("../../lib/generate-google-pay-configuration"),d=n("@braintree/iframer"),u=n("@braintree/uuid"),p=n("../../lib/use-min"),h=n("../../lib/methods"),m=n("@braintree/event-emitter"),v=n("../../lib/braintree-error"),_="3.140.0",b=n("../shared/constants"),w=b.events,C=b.errors,O=n("@braintree/wrap-promise"),T={Visa:"visa",MasterCard:"mastercard","American Express":"amex","Diners Club":"diners",Discover:"discover",JCB:"jcb",UnionPay:"unionpay",Maestro:"maestro"},E="18278000977346790994";function y(A,I,L){var D=A;return D+"/web/"+_+"/html/payment-request-frame"+p(L)+".html#"+I}function P(A){var I=A.enabledPaymentMethods||{};m.call(this),this._componentId=u(),this._client=A.client,this._enabledPaymentMethods={basicCard:I.basicCard!==!1,googlePay:I.googlePay!==!1},this._googlePayVersion=A.googlePayVersion===2?2:1,this._googleMerchantId=E,this._supportedPaymentMethods=this._constructDefaultSupp
125ortedPaymentMethods(),this._defaultSupportedPaymentMethods=Object.keys(this._supportedPaymentMethods).map((function(L){return this._supportedPaymentMethods[L]}).bind(this)),this._bus=new o({channel:this._componentId})}m.createChild(P),P.prototype._constructDefaultSupportedPaymentMethods=function(){var A=this._client.getConfiguration(),I=A.gatewayConfiguration.androidPay,L=A.gatewayConfiguration.creditCards,D={};return this._enabledPaymentMethods.basicCard&&L&&L.supportedCardTypes.length>0&&(D.basicCard={supportedMethods:"basic-card",data:{supportedNetworks:L.supportedCardTypes.reduce(function(z,G){return G in T&&z.push(T[G]),z},[])}}),this._enabledPaymentMethods.googlePay&&I&&I.enabled&&(D.googlePay={supportedMethods:"https://google.com/pay",data:c(A,this._googlePayVersion,this._googleMerchantId)}),D},P.prototype.initialize=function(){var A=this._client.getConfiguration(),I=this;return this._frame=d({allowPaymentRequest:!0,name:"braintree-payment-request-frame",class:"braintree-payment-request-frame",height:0,width:0,style:{position:"absolute",left:"-9999px"},title:"Secure Payment Frame"}
125),this._defaultSupportedPaymentMethods.length===0?Promise.reject(new v(C.PAYMENT_REQUEST_NO_VALID_SUPPORTED_PAYMENT_METHODS)):new Promise(function(L){I._bus.on(w.FRAME_READY,function(D){D(I._client)}),I._bus.on(w.FRAME_CAN_MAKE_REQUESTS,function(){s.sendEvent(I._client,"payment-request.initialized"),I._bus.on(w.SHIPPING_ADDRESS_CHANGE,function(D){var z={target:{shippingAddress:D},updateWith:function(G){I._bus.emit(w.UPDATE_SHIPPING_ADDRESS,G)}};I._emit("shippingAddressChange",z),I._emit("shippingaddresschange",z)}),I._bus.on(w.SHIPPING_OPTION_CHANGE,function(D){var z={target:{shippingOption:D},updateWith:function(G){I._bus.emit(w.UPDATE_SHIPPING_OPTION,G)}};I._emit("shippingOptionChange",z),I._emit("shippingoptionchange",z)}),L(I)}),I._frame.src=y(A.gatewayConfiguration.assetsUrl,I._componentId,A.isDebug),document.body.appendChild(I._frame)})},P.prototype.createSupportedPaymentMethodsConfiguration=function(A,I){var L;if(!A)throw new v(C.PAYMENT_REQUEST_CREATE_SUPPORTED_PAYMENT_METHODS_CONFIGURATION_MUST_INCLUDE_TYPE);if(!this._enabledPaymentMethods[A])throw new v(C.PAYMENT_REQUEST_CREATE_SUPPORTED_PAYMENT_METHODS_CONFIGURATION_TYPE_NOT_ENABLED);return L=a({},this._supportedPaymentMethods[A]),L.data=a({},L.data,I),L},P.prototype.tokenize=function(A){var I=this;return new Promise(function(L,D){I._bus.emit(w.PAYMENT_REQUEST_INITIALIZED,{supportedPaymentMethods:A.supportedPaymentMethods||I._defaultSupp
125ortedPaymentMethods,details:A.details,options:A.options},function(z){var G=z[0],ne=z[1];if(G){D(I._formatTokenizationError(G));return}s.sendEvent(I._client,"payment-request.tokenize.succeeded"),L({nonce:ne.nonce,type:ne.type,description:ne.description,details:{rawPaymentResponse:ne.details.rawPaymentResponse,cardType:ne.details.cardType,lastFour:ne.details.lastFour,lastTwo:ne.details.lastTwo},binData:ne.binData})})})},P.prototype.canMakePayment=function(A){var I=this,L;return window.PaymentRequest?A.supportedPaymentMethods&&(A.supportedPaymentMethods.forEach(function(D){var z=D.supportedMethods;z in b.SUPPORTED_METHODS||(L=z)}),L)?Promise.reject(new v({type:C.PAYMENT_REQUEST_UNSUPPORTED_PAYMENT_METHOD.type,code:C.PAYMENT_REQUEST_UNSUPPORTED_PAYMENT_METHOD.code,message:L+" is not a supported payment method."})):new Promise(function(D,z){I._bus.emit(w.CAN_MAKE_PAYMENT,{supportedPaymentMethods:A.supportedPaymentMethods||I._defaultSupportedPaymentMethods,details:A.details,options:A.options},function(G){var ne=G[0],W=G[1];if(ne){z(I._formatCanMakePaymentError(ne));return}s.sendEvent(I._client,"payment-request.can-make-payment."+W),D(W)})}):(s.sendEvent(I._client,"payment-request.can-make-payment.not-available"),Promise.resolve(!1))},P.prototype.teardown=function(){return this._bus.teardown(),this._frame.parentNode.removeChild(this._frame),l(this,h(P.prototype)),s.sendEvent(this._client,"payment-request.teardown-completed"),Promise.resolve()},P.prototype._formatTokenizationError=function(A){var I;switch(A.name){case"AbortError":return I=new v({type:C.PAYMENT_REQUEST_CANCELED.type,code:C.PAYMENT_REQUEST_CANCELED.code,message:C.PAYMENT_REQUEST_CANCELED.message,details:{originalError:A}}),s.sendEvent(this._client,"payment-request.tokenize.canceled"),I;case"PAYMENT_REQUEST_INITIALIZATION_FAILED":I=new v({type:C.PAYMENT_REQUEST_INITIALIZATION_MISCONFIGURED.type,code:C.PAYMENT_REQUEST_INITIALIZATION_MISCONFIGURED.code,message:C.PAYMENT_REQUEST_INITIALIZATION_MISCONFIGURED.message,details:{originalError:A}});break;case"BRAINTREE_GATEWAY_GOOGLE_PAYMENT_TOKENIZATION_ERROR":I=new v({type:C.PAYMENT_REQUEST_GOOGLE_PAYMENT_FAILED_TO_TOKENIZE.type,code:C.PAYMENT_REQUEST_GOOGLE_PAYMENT_FAILED_TO_TOKENIZE.code,message:C.PAYMENT_REQUEST_GOOGLE_PAYMENT_FAILED_TO_TOKENIZE.message,details:{originalError:A}});break;case"BRAINTREE_GATEWAY_GOOGLE_PAYMENT_PARSING_ERROR":I=new v({type:C.PAYMENT_REQUEST_GOOGLE_PAYMENT_PARSING_ERROR.type,code:C.PAYMENT_REQUEST_GOOGLE_PAYMENT_PARSING_ERROR.code,message:C.PAYMENT_REQUEST_GOOGLE_PAYMENT_PARSING_ERROR.message,details:{originalError:A}});break;default:I=new v({code:C.PAYMENT_REQUEST_NOT_COMPLETED.code,type:A.type||v.types.CUSTOMER,message:C.PAYMENT_REQUEST_NOT_COMPLETED.message,details:{originalError:A}})}return s.sendEvent(this._client,"payment-request.tokenize.failed"),I},P.prototype._formatCanMakePaymentError=function(A){var I;switch(A.name){case"PAYMENT_REQUEST_INITIALIZATION_FAILED":I=new v({type:C.PAYMENT_REQUEST_INITIALIZATION_MISCONFIGURED.type,code:C.PAYMENT_REQUEST_INITIALIZATION_MISCONFIGURED.code,message:C.PAYMENT_REQUEST_INITIALIZATION_MISCONFIGURED.message,details:{originalError:A}});break;case"NotAllowedError":I=new v({type:C.PAYMENT_REQUEST_CAN_MAKE_PAYMENT_NOT_ALLOWED.type,code:C.PAYMENT_REQUEST_CAN_MAKE_PAYMENT_NOT_ALLOWED.code,message:C.PAYMENT_REQUEST_CAN_MAKE_PAYMENT_NOT_ALLOWED.message,details:{originalError:A}});break;default:I=new v({code:C.PAYMENT_REQUEST_CAN_MAKE_PAYMENT_FAILED.code,type:C.PAYMENT_REQUEST_CAN_MAKE_PAYMENT_FAILED.type,message:C.PAYMENT_REQUEST_CAN_MAKE_PAYMENT_FAILED.message,details:{originalError:A}})}return s.sendEvent(this._client,"payment-request.can-make-payment.failed"),I},i.exports=O.wrapPrototype(P)},{"../../lib/analytics":144,"../../lib/assign":146,"../../lib/braintree-error":149,"../../lib/convert-methods-to-error":151,"../../lib/generate-google-pay-configuration":173,"../../lib/methods":181,"../../lib/use-min":187,"../shared/constants":206,"@braintree/event-emitter":33,"@braintree/iframer":35,"@braintree/uuid":39,"@braintree/wrap-promise":43,framebus:54}],205:[function(n,i,r){var s=n("./external/payment-request"),a=n("../lib/basic-component-verification"),o=n("../lib/create-deferred-client"),l=n("../lib/create-assets-url"),c=n("@braintree/wrap-promise"),d="3.140.0";function u(p){var h="Payment Request";return a.verify({name:h,client:p.client,authorization:p.authorization}).then(function(){return o.create({authorization:p.authorization,client:p.client,debug:p.debug,assetsUrl:l.create(p.authorization),name:h})}).then(function(m){var v;return p.client=m,v=new s(p),v.initialize()})}i.exports={create:c(u),VERSION:d}},{"../lib/basic-component-verification":147,"../lib/create-assets-url":153,"../lib/create-deferred-client":155,"./external/payment-request":204,"@braintree/wrap-promise":43}],206:[function(n,i,r){var s=n("../../lib/enumerate"),a=n("./errors"),o={};o.events=s(["CAN_MAKE_PAYMENT","FRAME_READY","FRAME_CAN_MAKE_REQUESTS","PAYMENT_REQUEST_INITIALIZED","SHIPPING_ADDRESS_CHANGE","UPDATE_SHIPPING_ADDRESS","SHIPPING_OPTION_CHANGE","UPDATE_SHIPPING_OPTION"],"payment-request:"),o.errors=a,o.SUPPORTED_METHODS={"basic-card":!0,"https://google.com/pay":!0},i.exports=o},{"../../lib/enumerate":158,"./errors":207}],207:[function(n,i,r){var s=n("../../lib/braintree-error");i.exports={PAYMENT_REQUEST_NO_VALID_SUPPORTED_PAYMENT_METHODS:{type:s.types.MERCHANT,code:"PAYMENT_REQUEST_NO_VALID_SUPPORTED_PAYMENT_METHODS",message:"There are no supported payment methods associated with this account."},PAYMENT_REQUEST_CANCELED:{type:s.types.CUSTOMER,code:"PAYMENT_REQUEST_CANCELED",message:"Payment request was canceled."},PAYMENT_REQUEST_INITIALIZATION_MISCONFIGURED:{type:s.types.MERCHANT,code:"PAYMENT_REQUEST_INITIALIZATION_MISCONFIGURED",message:"Something went wrong when configuring the payment request."},PAYMENT_REQUEST_CAN_MAKE_PAYMENT_FAILED:{type:s.types.UNKNOWN,code:"PAYMENT_REQUEST_CAN_MAKE_PAYMENT_FAILED",message:"Something went wrong when calling `canMakePayment`"},PAYMENT_REQUEST_CAN_MAKE_PAYMENT_NOT_ALLOWED:{type:s.types.MERCHANT,code:"PAYMENT_REQUEST_CAN_MAKE_PAYMENT_NOT_ALLOWED",message:"Something went wrong when calling `canMakePayment`. Most likely, `canMakePayment` was called multiple times with different supportedMethods configurations."},PAYMENT_REQUEST_UNSUPPORTED_PAYMENT_METHOD:{type:s.types.MERCHANT,code:"PAYMENT_REQUEST_UNSUPPORTED_PAYMENT_METHOD"}
125,PAYMENT_REQUEST_GOOGLE_PAYMENT_FAILED_TO_TOKENIZE:{type:s.types.MERCHANT,code:"PAYMENT_REQUEST_GOOGLE_PAYMENT_FAILED_TO_TOKENIZE",message:"Something went wrong when tokenizing the Google Pay card."},PAYMENT_REQUEST_GOOGLE_PAYMENT_PARSING_ERROR:{type:s.types.UNKNOWN,code:"PAYMENT_REQUEST_GOOGLE_PAYMENT_PARSING_ERROR",message:"Something went wrong when tokenizing the Google Pay card."},PAYMENT_REQUEST_NOT_COMPLETED:{code:"PAYMENT_REQUEST_NOT_COMPLETED",message:"Payment request could not be completed."},PAYMENT_REQUEST_CREATE_SUPPORTED_PAYMENT_METHODS_CONFIGURATION_MUST_INCLUDE_TYPE:{type:s.types.MERCHANT,code:"PAYMENT_REQUEST_CREATE_SUPPORTED_PAYMENT_METHODS_CONFIGURATION_MUST_INCLUDE_TYPE",message:"createSupportedPaymentMethodsConfiguration must include a type parameter."},PAYMENT_REQUEST_CREATE_SUPPORTED_PAYMENT_METHODS_CONFIGURATION_TYPE_NOT_ENABLED:{type:s.types.MERCHANT,code:"PAYMENT_REQUEST_CREATE_SUPPORTED_PAYMENT_METHODS_CONFIGURATION_TYPE_NOT_ENABLED",message:"createSupportedPaymentMethodsConfiguration type parameter must be valid or enabled."}}},{"../../lib/braintree-error":149}],208:[function(n,i,r){var s="3.140.0",a="https://www.{ENV}paypal.com/web-sdk/v6/core",o={stage:"https://www.msmaster.qa.paypal.com/web-sdk/v6/core",teBraintree:"https://www.braintree.stage.paypal.com/web-sdk/v6/core"},l="paypal-checkout-v6",c={INITIALIZED:l+".initialized",TEARDOWN:l+".teardown",SDK_ALREADY_LOADED:l+".sdk-already-loaded",SDK_LOAD_STARTED:l+".load-sdk.started",SDK_LOAD_SUCCEEDED:l+".sdk-load.succeeded",SDK_LOAD_FAILED:l+".sdk-load.failed",CREATE_INSTANCE_STARTED:l+".create-instance.started",CREATE_INSTANCE_SUCCEEDED:l+".create-instance.succeeded",CREATE_INSTANCE_FAILED:l+".create-instance.failed",SESSION_CHECKOUT_CREATED:l+".session.checkout.created",SESSION_VAULT_CREATED:l+".session.vault.created",SESSION_CHECKOUT_WITH_VAULT_CREATED:l+".session.checkout-with-vault.created",PAYMENT_STARTED:l+".payment.started",PAYMENT_APPROVED:l+".payment.approved",PAYMENT_CANCELED:l+".payment.canceled",CHECKOUT_WITH_VAULT_STARTED:l+".checkout-with-vault.started",CHECKOUT_WITH_VAULT_APPROVED:l+".checkout-with-vault.approved",CHECKOUT_WITH_VAULT_CANCELED:l+".checkout-with-vault.canceled",CREATE_ORDER_STARTED:l+".create-order.started",CREATE_ORDER_SUCCEEDED:l+".create-order.succeeded",CREATE_ORDER_FAILED:l+".create-order.failed",CREATE_BA_TOKEN_STARTED:l+".create-billing-agreement-token.started",CREATE_BA_TOKEN_SUCCEEDED:l+".create-billing-agreement-token.succeeded",CREATE_BA_TOKEN_FAILED:l+".create-billing-agreement-token.failed",CREATE_BA_SESSION_STARTED:l+".create-billing-agreement-session.started",CREATE_BA_SESSION_INSTANCE_CREATED:l+".create-billing-agreement-session.instance-created",CREATE_BA_SESSION_SDK_NOT_LOADED:l+".create-billing-agreement-session.sdk-not-loaded",CREATE_BA_SESSION_SESSION_CREATED:l+".create-billing-agreement-session.session-created",CREATE_BA_SESSION_APPROVED:l+".create-billing-agreement-session.approved",CREATE_BA_SESSION_CANCELED:l+".create-billing-agreement-session.canceled",CREATE_BA_SESSION_FAILED:l+".create-billing-agreement-session.failed",TOKENIZE_PAYMENT_PREFIX:l+".tokenize-payment",TOKENIZE_BA_PREFIX:l+".tokenize-billing-agreement",CREDIT_OFFERED:l+".credit.offered",CREDIT_ACCEPTED:l+".credit.accepted",PAY_LATER_OFFERED:l+".pay-later.offered",PAY_LATER_ACCEPTED:l+".pay-later.accepted",FIND_ELIGIBLE_METHODS_STARTED:l+".find-eligible-methods.started",FIND_ELIGIBLE_METHODS_SUCCEEDED:l+".find-eligible-methods.succeeded",FIND_ELIGIBLE_METHODS_FAILED:l+".find-eligible-methods.failed"};i.exports={VERSION:s,PAYPAL_V6_SDK_BASE_URL:a,PAYPAL_V6_ENVIRONMENT:o,ANALYTICS_PREFIX:l,ANALYTICS_EVENTS:c}},{}],209:[function(n,i,r){var s=n("../lib/braintree-error");i.exports={PAYPAL_CHECKOUT_V6_NOT_ENABLED:{type:s.types.MERCHANT,code:"PAYPAL_CHECKOUT_V6_NOT_ENABLED",message:"PayPal is not enabled for this merchant."},PAYPAL_CHECKOUT_V6_SANDBOX_ACCOUNT_NOT_LINKED:{type:s.types.MERCHANT,code:"PAYPAL_CHECKOUT_V6_SANDBOX_ACCOUNT_NOT_LINKED",message:"A linked PayPal Sandbox account is required to use PayPal Checkout V6 in Sandbox. See https://developer.paypal.com/braintree/docs/guides/paypal/testing-go-live#linked-paypal-testing for details on linking your PayPal sandbox with Braintree."},PAYPAL_CHECKOUT_V6_TOKENIZATION_KEY_NOT_SUPPORTED:{type:s.types.MERCHANT,code:"PAYPAL_CHECKOUT_V6_TOKENIZATION_KEY_NOT_SUPPORTED",message:"PayPal Checkout V6 requires a client token for authorization. Tokenization keys are not supported."},PAYPAL_CHECKOUT_V6_SDK_SCRIPT_LOAD_FAILED:{type:s.types.NETWORK,code:"PAYPAL_CHECKOUT_V6_SDK_SCRIPT_LOAD_FAILED",message:"PayPal V6 SDK script failed to load."},PAYPAL_CHECKOUT_V6_SDK_INITIALIZATION_FAILED:{type:s.types.NETWORK,code:"PAYPAL_CHECKOUT_V6_SDK_INITIALIZATION_FAILED",message:"PayPal V6 SDK instance creation failed."},PAYPAL_CHECKOUT_V6_CLIENT_TOKEN_INVALID:{type:s.types.MERCHANT,code:"PAYPAL_CHECKOUT_V6_CLIENT_TOKEN_INVALID",message:"Client token is invali
125d or expired."},PAYPAL_CHECKOUT_V6_SDK_NOT_INITIALIZED:{type:s.types.MERCHANT,code:"PAYPAL_CHECKOUT_V6_SDK_NOT_INITIALIZED",message:"PayPal SDK has not been initialized. Call loadPayPalSDK() before using this method."},PAYPAL_CHECKOUT_V6_ELIGIBILITY_CHECK_FAILED:{type:s.types.NETWORK,code:"PAYPAL_CHECKOUT_V6_ELIGIBILITY_CHECK_FAILED",message:"Failed to check payment method eligibility."},PAYPAL_CHECKOUT_V6_INVALID_ELIGIBILITY_OPTIONS:{type:s.types.MERCHANT,code:"PAYPAL_CHECKOUT_V6_INVALID_ELIGIBILITY_OPTIONS",message:"Eligibility check options are invalid or missing required fields (amount, currency)."},PAYPAL_CHECKOUT_V6_SESSION_CREATION_FAILED:{type:s.types.MERCHANT,code:"PAYPAL_CHECKOUT_V6_SESSION_CREATION_FAILED",message:"Failed to create PayPal payment session."},PAYPAL_CHECKOUT_V6_PAYMENT_START_FAILED:{type:s.types.MERCHANT,code:"PAYPAL_CHECKOUT_V6_PAYMENT_START_FAILED",message:"Failed to start PayPal payment flow."},PAYPAL_CHECKOUT_V6_PAYMENT_CANCELED:{type:s.types.CUSTOMER,code:"PAYPAL_CHECKOUT_V6_PAYMENT_CANCELED",message:"Customer canceled the PayPal payment."},PAYPAL_CHECKOUT_V6_INVALID_SESSION_OPTIONS:{type:s.types.MERCHANT,code:"PAYPAL_CHECKOUT_V6_INVALID_SESSION_OPTIONS",message:"PayPal session options are invalid or missing required fields."},PAYPAL_CHECKOUT_V6_APP_SWITCH_URLS_REQUIRED:{type:s.types.MERCHANT,code:"PAYPAL_CHECKOUT_V6_APP_SWITCH_URLS_REQUIRED",message:"returnUrl and cancelUrl are required when using direct-app-switch presentation mode."},PAYPAL_CHECKOUT_V6_INSTANCE_NOT_READY:{type:s.types.MERCHANT,code:"PAYPAL_CHECKOUT_V6_INSTANCE_NOT_READY",message:"PayPal SDK instance is not ready. Ensure loadPayPalSDK() has completed before calling start()."},PAYPAL_CHECKOUT_V6_ORDER_CREATION_FAILED:{type:s.types.NETWORK,code:"PAYPAL_CHECKOUT_V6_ORDER_CREATION_FAILED",message:"Could not create PayPal order."},PAYPAL_CHECKOUT_V6_INVALID_ORDER_OPTIONS:{type:s.types.MERCHANT,code:"PAYPAL_CHECKOUT_V6_INVALID_ORDER_OPTIONS",message:"PayPal order options are invalid or missing required fields."},PAYPAL_CHECKOUT_V6_TOKENIZATION_FAILED:{type:s.types.NETWORK,code:"PAYPAL_CHECKOUT_V6_TOKENIZATION_FAILED",message:"Could not tokenize PayPal account."},PAYPAL_CHECKOUT_V6_MISSING_TOKENIZATION_DATA:{type:s.types.MERCHANT,code:"PAYPAL_CHECKOUT_V6_MISSING_TOKENIZATION_DATA",message:"Missing required tokenization data (payerID or orderID)."},PAYPAL_CHECKOUT_V6_INVALID_UPDATE_OPTIONS:{type:s.types.MERCHANT,code:"PAYPAL_CHECKOUT_V6_INVALID_UPDATE_OPTIONS",message:"PayPal update options are invalid or missing required fields."},PAYPAL_CHECKOUT_V6_PAYMENT_NOT_FOUND:{type:s.types.MERCHANT,code:"PAYPAL_CHECKOUT_V6_PAYMENT_NOT_FOUND",message:"The specified payment ID cannot be found or is no longer active."},PAYPAL_CHECKOUT_V6_CURRENCY_MISMATCH:{type:s.types.MERCHANT,code:"PAYPAL_CHECKOUT_V6_CURRENCY_MISMATCH",message:"The currency provided for the update does not match the original payment currency."},PAYPAL_CHECKOUT_V6_UPDATE_FAILED:{type:s.types.NETWORK,code:"PAYPAL_CHECKOUT_V6_UPDATE_FAILED",message:"Could not update PayPal payment details."},PAYPAL_CHECKOUT_V6_INVALID_LINE_ITEMS:{type:s.types.MERCHANT,code:"PAYPAL_CHECKOUT_V6_INVALID_LINE_ITEMS",message:"Line items have invalid format or inconsistent currency."},PAYPAL_CHECKOUT_V6_BILLING_AGREEMENT_CREATION_FAILED:{type:s.types.NETWORK,code:"PAYPAL_CHECKOUT_V6_BILLING_AGREEMENT_CREATION_FAILED",message:"Could not create PayPal billing agreement."},PAYPAL_CHECKOUT_V6_INVALID_BILLING_AGREEMENT_OPTIONS:{type:s.types.MERCHANT,code:"PAYPAL_CHECKOUT_V6_INVALID_BILLING_AGREEMENT_OPTIONS",message:"Billing agreement options are invalid or missing required fields."},PAYPAL_CHECKOUT_V6_BILLING_AGREEMENT_CANCELED:{type:s.types.CUSTOMER,code:"PAYPAL_CHECKOUT_V6_BILLING_AGREEMENT_CANCELED",message:"Customer canceled the billing agreement."}}},{"../lib/braintree-error":149}],210:[function(n,i,r){var s=n("../lib/basic-component-verification"),a=n("@braintree/wrap-promise"),o=n("./paypal-checkout-v6"),l="3.140.0";function c(u){var p="PayPal Checkout V6";return s.verify({name:p,client:u.client,authorization:u.authorization}).then(function(){var h=new o(u);return h._initialize(u)})}function d(){return!0}i.exports={create:a(c),isSupported:d,VERSION:l}},{"../lib/basic-component-verification":147,"./paypal-checkout-v6":211,"@braintree/wrap-promise":43}],211:[function(n,i,r){var s=n("../lib/analytics"),a=n("../lib/assign").assign,o=n("../lib/braintree-error"),l=n("../lib/convert-to-braintree-error"),c=n("../lib/create-deferred-client"),d=n("../lib/create-assets-url"),u=n("../lib/create-authorization-data"),p=n("./errors"),h=n("../lib/frame-service/external"),m=n("../lib/methods"),v=n("../lib/convert-methods-to-error"),_=n("../lib/use-min"),b=n("@braintree/wrap-promise"),w=n("@braintree/extended-promise"),C=n("./constants"),O=n("../lib/constants").INTEGRATION_TIMEOUT_MS;w.suppressUnhandledPromiseMessage=!0;function T(E){this._merchantAccountId=E.merchantAccountId}T.prototype._initialize=function(E){var y;return E.client?(y=E.client.getConfiguration(),this._authorizationInformation={fingerprint:y.authorizationFingerprint,environment:y.gatewayConfiguration.environment}):(y=u(E.authorization),this._authorizationInformation={fingerprint:y.attrs.authorizationFingerprint,environment:y.environment}),this._clientPromise=c.create({authorization:E.authorization,client:E.client,debug:E.debug,assetsUrl:E.authorization?d.create(E.authorization):void 0,name:"PayPal Checkout V6"}).then((function(P){return this._configuration=P.getConfiguration(),this._configuration.authorizationType==="TOKENIZATION_KEY"?this._setupError=ne
125w o(p.PAYPAL_CHECKOUT_V6_TOKENIZATION_KEY_NOT_SUPPORTED):this._merchantAccountId||(this._configuration.gatewayConfiguration.paypalEnabled?this._configuration.gatewayConfiguration.paypal.environmentNoNetwork===!0&&(this._setupError=new o(p.PAYPAL_CHECKOUT_V6_SANDBOX_ACCOUNT_NOT_LINKED)):this._setupError=new o(p.PAYPAL_CHECKOUT_V6_NOT_ENABLED)),this._setupError?Promise.reject(this._setupError):(this._client=P,s.sendEvent(P,C.ANALYTICS_EVENTS.INITIALIZED),this._frameServicePromise=this._setupFrameService(P),P)}).bind(this)),E.client?this._clientPromise.then((function(){return this}).bind(this)):Promise.resolve(this)},T.prototype.getClientId=function(){return this._clientPromise.then(function(E){return E.getConfiguration().gatewayConfiguration.paypal.clientId})},T.prototype._setupFrameService=function(E){var y=new w,P=E.getConfiguration(),A=setTimeout(function(){s.sendEvent(E,"paypal-checkout-v6.frame-service.timed-out"),y.reject(new o(p.PAYPAL_CHECKOUT_V6_SESSION_CREATION_FAILED))},O);return this._assetsUrl=P.gatewayConfiguration.paypal.assetsUrl+"/web/"+C.VERSION,this._isDebug=P.isDebug,this._loadingFrameUrl=this._assetsUrl+"/html/paypal-landing-frame"+_(this._isDebug)+".html",h.create({name:"braintreepaypallanding",dispatchFrameUrl:this._assetsUrl+"/html/dispatch-frame"+_(this._isDebug)+".html",openFrameUrl:this._loadingFrameUrl},(function(I){this._frameService=I,clearTimeout(A),y.resolve()}).bind(this)),y},T.prototype._isPayPalSdkAvailable=function(){return!!(window.paypal&&window.paypal.createInstance)},T.prototype._validateAppSwitchUrls=function(E,y){return y==="direct-app-switch"&&(!E.returnUrl||!E.cancelUrl)?new o(p.PAYPAL_CHECKOUT_V6_APP_SWITCH_URLS_REQUIRED):null},T.prototype._formatPlanMetadata=function(E){var y=["currencyIsoCode","name","oneTimeFeeAmount","productDescription","productPrice","productQuantity","shippingAmount","taxAmount","totalAmount"],P=["billingFrequency","billingFrequencyUnit","numberOfExecutions","sequence","startDate","trial","pricingScheme"],A={billingCycles:[]},I,L,D,z,G;if(E.hasOwnProperty("billingCycles"))for(I=0;I<E.billingCycles.length;I++){for(L=E.billingCycles[I],D={},z=0;z<P.length;z++)D[P[z]]=L[P[z]];A.billingCycles.push(D)}for(G=0;G<y.length;G++)A[y[G]]=E[y[G]];return A},T.prototype.loadPayPalSDK=function(E){var y=this;return this._clientPromise.then(function(P){var A=new w,I=P.getConfiguration(),L=I.gatewayConfiguration.environment,D=L==="production"?"":"sandbox.",z;return E&&E.env&&C.PAYPAL_V6_ENVIRONMENT[E.env]?z=C.PAYPAL_V6_ENVIRONMENT[E.env]:z=C.PAYPAL_V6_SDK_BASE_URL.replace("{ENV}",D),window.paypal&&window.paypal.version?(s.sendEvent(P,C.ANALYTICS_EVENTS.SDK_ALREADY_LOADED),Promise.resolve(y)):(s.sendEvent(P,C.ANALYTICS_EVENTS.SDK_LOAD_STARTED),y._paypalScript=document.createElement("script"),y._paypalScript.src=z,y._paypalScript.async=!0,y._paypalScript.onload=function(){s.sendEvent(P,C.ANALYTICS_EVENTS.SDK_LOAD_SUCCEEDED),A.resolve(y)},y._paypalScript.onerror=function(){s.sendEvent(P,C.ANALYTICS_EVENTS.SDK_LOAD_FAILED),A.reject(new o(p.PAYPAL_CHECKOUT_V6_SDK_SCRIPT_LOAD_FAILED))},document.head.appendChild(y._paypalScript),A)})},T.prototype._createPayPalInstance=function(E){var y=this;return this._clientPromise.then(function(P){var A=P.getConfiguration(),I=A.gatewayConfiguration.paypal.clientId,L=E&&E.flow==="vault",D=L?["paypal-billing-agreements"]:["paypal-payments"];return E=a({clientId:I,components:D,pageType:"checkout"},E),A.analyticsMetadata&&A.analyticsMetadata.sessionId&&(E.clientMetadataId=A.analyticsMetadata.sessionId),s.sendEvent(P,C.ANALYTICS_EVENTS.CREATE_INSTANCE_STARTED),window.paypal.createInstance(E).then(function(z){return s.sendEvent(P,C.ANALYTICS_EVENTS.CREATE_INSTANCE_SUCCEEDED),y._paypalInstance=z,z}).catch(function(z){throw s.sendEvent(P,C.ANALYTICS_EVENTS.CREATE_INSTANCE_FAILED),l(z,{type:p.PAYPAL_CHECKOUT_V6_SDK_INITIALIZATION_FAILED.type,code:p.PAYPAL_CHECKOUT_V6_SDK_INITIALIZATION_FAILED.code,message:p.PAYPAL_CHECKOUT_V6_SDK_INITIALIZATION_FAILED.message})})})},T.prototype._buildBillingAgreementRequest=function(E){var y={planType:E.planType||"UNSCHEDULED"};return E.billingAgreementDescription&&(y.description=E.billingAgreementDescription),E.planMetadata&&(y.planMetadata=this._formatPlanMetadata(E.planMetadata)),E.amount&&E.currency&&(y.amount=E.amount,y.currency=E.currency),E.shippingAddressOverride&&(y.shippingAddressOverride=E.shippingAddressOverride),E.userAction&&(y.userAction=E.userAction),E.offerCredit&&(y.offerCredit=E.offerCredit),E.returnUrl&&(y.returnUrl=E.returnUrl),E.cancelUrl&&(y.cancelUrl=E.cancelUrl),y},T.prototype._createBillingAgreementToken=function(E){var y=this,P=this._configuration.gatewayConfiguration,A={returnUrl:E.returnUrl||"https://www.paypal.com/checkoutnow/error",cancelUrl:E.cancelUrl||"https://www.paypal.com/checkoutnow/error",offerPaypalCredit:E.offerCredit===!0,merchantAccountId:this._merchantAccountId,experienceProfile:{brandName:E.displayName||P.paypal.displayName,noShipping:(!E.enableShippingAddress).toString(),addressOverride:!1}};return E.planType&&(A.planType=E.planType),E.description&&(A.description=E.description),E.planMetadata&&(A.planMetadata=this._formatPlanMetadata(E.planMetadata)),E.amount&&E.currency&&(A.amount=E.amount,A.currencyIsoCode=E.currency),E.shippingAddressOverride&&(A.shippingAddress=E.shippingAddressOverride),E.userAction&&(A.experienceProfile.userAction=E.userAction),this._clientPromise.then(function(I){return s.sendEvent(I,C.ANALYTICS_EVENTS.CREATE_BA_TOKEN_STARTED),I.request({endpoint:"paypal_hermes/setup_billing_agreement",method:"post",data:A}).then(function(L){s.sendEvent(I,C.ANALYTICS_EVENTS.CREATE_BA_TOKEN_SUCCEEDED);var D=L.agreementSetup.tokenId;if(!D)throw new Error("Could not extract approval token from billing agreement setup");return{approvalTokenId:D,agreementSetup:L.agreementSetup}}).catch(function(L){throw s.sendEvent(I,C.ANALYTICS_EVENTS.CREATE_BA_TOKEN_FAILED),y._setupError?y._setupError:l(L,{type:p.PAYPAL_CHECKOUT_V6_BILLING_AGREEMENT_CREATION_FAILED.type,code:p.PAYPAL_CHECKOUT_V6_BILLING_AGREEMENT_CREATION_FAILED.code,message:p.PAYPAL_CHECKOUT_V6_BILLING_AGREEMENT_CREATION_FAILED.message})})})},T.prototype._createPaymentResource=function(E){var y=this,P=this._configuration.gatewayConfiguration,A=E.intent||"capture";A==="capture"&&(A="sale");var I={amount:E.amount,currencyIsoCode:E.currency,intent:A,returnUrl:E.returnUrl||"https://www.paypal.com/checkoutnow/error",cancelUrl:E.cancelUrl||"https://www.paypal.com/checkoutnow/error",experienceProfile:{brandName:E.displayName||P.paypal.displayName}};return this._merchantAccountId&&(I.merchantAccountId=this._merchantAccountId),E.lineItems&&(I.lineItems=E.lineItems),E.shippingOptions&&(I.shippingOptions=E.shippingOptions),E.userAuthenticationEmail&&(I.payer_email=E.userAuthenticationEmail),E.amountBreakdown&&(I.amountBreakdown=E.amountBreakdown),E.offerCredit===!0&&(I.offerPaypalCredit=!0),E.requestBillingAgreement&&(I.requestBillingAgreement=!0),E.billingAgreementDetails&&(I.billingAgreementDetails=E.billingAgreementDetails),this._clientPromise.then(function(L){return s.sendEvent(L,C.ANALYTICS_EVENTS.CREATE_ORDER_STARTED),L.request({endpoint:"paypal_hermes/create_payment_resource",method:"post",data:I}).then(function(D){s.sendEvent(L,C.ANALYTICS_EVENTS.CREATE_ORDER_SUCCEEDED);var z=D.paymentResource.redirectUrl,G=z.match(/token=([^&]+)/),ne=G?G[1]:null;if(!ne)throw new Error("Could not extract order ID from payment resource");return y._contextId=ne,{orderId:ne,paymentResource:D.paymentResource}}).catch(function(D){throw s.sendEvent(L,C.ANALYTICS_EVENTS.CREATE_ORDER_FAILED),y._setupError?y._setupError:l(D,{type:p.PAYPAL_CHECKOUT_V6_ORDER_CREATION_FAILED.type,code:p.PAYPAL_CHECKOUT_V6_ORDER_CREATION_FAILED.code,message:p.PAYPAL_CHECKOUT_V6_ORDER_CREATION_FAILED.message})})})},T.prototype._createCheckoutSessionOptions=function(E,y,P){var A=P?C.ANALYTICS_EVENTS.CHECKOUT_WITH_VAULT_APPROVED:C.ANALYTICS_EVENTS.PAYMENT_APPROVED,I=P?C.ANALYTICS_EVENTS.CHECKOUT_WITH_VAULT_CANCELED:C.ANALYTICS_EVENTS.PAYMENT_CANCELED,L=typeof y.commit=="boolean"?y.commit:!0,D={commit:L,onApprove:function(z){return s.sendEvent(E,A),y.onApprove(z)},onCancel:function(z){if(s.sendEvent(E,I),y&&typeof y.onCancel=="function")return y.onCancel(z)}};return y&&typeof y.onError=="function"&&(D.onError=function(z){return y.onError(z)}),y&&typeof y.onShippingAddressChange=="function"&&(D.onShippingAddressChange=function(z){return y.onShippingAddressChange(z)}),y&&typeof y.onShippingOptionsChange=="function"&&(D.onShippingOptionsChange=function(z){return y.onShippingOptionsChange(z)}),D},T.prototype._createOrderPromise=function(E,y){return this._createPaymentResource(E).then(function(P){return{orderId:P.orderId}}).catch(function(P){throw y&&y(P),P})},T.prototype._startCheckoutSession=function(E,y,P,A,I,L){var D;A==="paypal-credit"?D="createPayPalCreditOneTimePaymentSession":A==="pay-later"?D="createPayLaterOneTimePaymentSession":D="createPayPalOneTimePaymentSession";var z=!!L.requestBillingAgreement,G=z?C.ANALYTICS_EVENTS.CHECKOUT_WITH_VAULT_STARTED:C.ANALYTICS_EVENTS.PAYMENT_STARTED;s.sendEvent(y,G);var ne=E[D](this._createCheckoutSessionOptions(y,I,z));return ne.start({presentationMode:P},this._createOrderPromise(L,I.onError))},T.prototype._createBillingSessionCallbacks=function(E,y){return{onApprove:function(P){return s.sendEvent(E,C.ANALYTICS_EVENTS.CREATE_BA_SESSION_APPROVED),y.onApprove(P)},onCancel:function(P){s.sendEvent(E,C.ANALYTICS_EVENTS.CREATE_BA_SESSION_CANCELED),y.onCancel&&typeof y.onCancel=="function"&&y.onCancel(P)},onError:function(P){s.sendEvent(E,C.ANALYTICS_EVENTS.CREATE_BA_SESSION_FAILED),y.onError&&typeof y.onError=="function"&&y.onError(P)}}},T.prototype._createBillingTokenPromise=function(E){return this.createPayment({flow:"vault",billingAgreementDescription:E.description,planType:E.planType,planMetadata:E.planMetadata,amount:E.amount,currency:E.currency,shippingAddressOverride:E.shippingAddressOverride,userAction:E.userAction,offerCredit:E.offerCredit,returnUrl:E.returnUrl,cancelUrl:E.cancelUrl}).then(function(y){return{billingToken:y}})},T.prototype._startBillingSession=function(E,y,P,A,I,L){var D=this,z=A==="paypal-credit"?"createPayPalCreditBillingAgreementWithoutPurchase":"createPayPalBillingAgreementWithoutPurchase";s.sendEvent(y,C.ANALYTICS_EVENTS.CREATE_BA_SESSION_STARTED);var G=E[z](this._createBillingSessionCallbacks(y,L));s.sendEvent(y,C.ANALYTICS_EVENTS.CREATE_BA_SESSION_SESSION_CREATED);var ne=D._createBillingTokenPromise(I).catch(function(W){throw L.onError&&L.onError(W),W});return G.start({presentationMode:P},ne)},T.prototype._createPaymentSession=function(E,y){var P=this;this._flow="checkout",this._sessionType=y;var A={amount:E.amount,currency:E.currency,intent:E.intent||"capture"};return E.offerCredit&&(A.offerCredit=E.offerCredit),E.lineItems&&(A.lineItems=E.lineItems),E.shippingOptions&&(A.shippingOptions=E.shippingOptions),E.userAuthenticationEmail&&(A.userAuthenticationEmail=E.userAuthenticationEmail),E.amountBreakdown&&(A.amountBreakdown=E.amountBreakdown),E.returnUrl&&(A.returnUrl=E.returnUrl),E.cancelUrl&&(A.cancelUrl=E.cancelUrl),E.requestBillingAgreement&&(A.requestBillingAgreement=E.requestBillingAgreement),E.billingAgreementDetails&&(A.billingAgreementDetails=E.billingAgreementDetails),E.displayName&&(A.displayName=E.displayName),{start:function(I){I=I||{};var L=I.presentationMode||E.presentationMode||"auto",D=P._paypalInstance,z=P._validateAppSwitchUrls(E,L);return z?Promise.reject(z):D&&P._client?P._startCheckoutSession(D,P._client,L,y,E,A):P._checkoutInstancePromise?P._checkoutInstancePromise.then(function(G){return P._clientPromise.then(function(ne){return P._startCheckoutSession(G,ne,L,y,E,A)})}).catch(function(G){throw E.onError&&E.onError(G),G}):Promise.reject(new o(p.PAYPAL_CHECKOUT_V6_INSTANCE_NOT_READY))}}},T.prototype.createOneTimePaymentSession=function(E){var y=this;if(!E||!E.amount||!E.currency||!E.onApprove)throw new o(p.PAYPAL_CHECKOUT_V6_INVALID_SESSION_OPTIONS);s.sendEvent(y._clientPromise,C.ANALYTICS_EVENTS.SESSION_CHECKOUT_CREATED);var P=E.offerCredit===!0?"paypal-credit":"paypal";return E.offerCredit===!0&&s.sendEvent(y._clientPromise,C.ANALYTICS_EVENTS.CREDIT_OFFERED),!y._paypalInstance&&!y._checkoutInstancePromise&&y._isPayPalSdkAvailable()&&(y._checkoutInstancePromise=y._clientPromise.then(function(){return y._createPayPalInstance()}).then(function(A){return A})),this._createPaymentSession(E,P)},T.prototype.createPayLaterSession=function(E){var y=this;if(!E||!E.amount||!E.currency||!E.onApprove)throw new o(p.PAYPAL_CHECKOUT_V6_INVALID_SESSION_OPTIONS);return s.sendEvent(y._clientPromise,C.ANALYTICS_EVENTS.SESSION_CHECKOUT_CREATED),s.sendEvent(y._clientPromise,C.ANALYTICS_EVENTS.PAY_LATER_OFFERED),!y._paypalInstance&&!y._checkoutInstancePromise&&y._isPayPalSdkAvailable()&&(y._checkoutInstancePromise=y._clientPromise.then(function(){return y._createPayPalInstance()}).then(function(P){return P})),this._createPaymentSession(E,"pay-later")},T.prototype.createCheckoutWithVaultSession=function(E){var y=this;if(!E||!E.amount||!E.currency||!E.onApprove)throw new o(p.PAYPAL_CHECKOUT_V6_INVALID_SESSION_OPTIONS);s.sendEvent(y._clientPromise,C.ANALYTICS_EVENTS.SESSION_CHECKOUT_WITH_VAULT_CREATED);var P=a({},E,{requestBillingAgreement:!0});return!y._paypalInstance&&!y._checkoutInstancePromise&&y._isPayPalSdkAvailable()&&(y._checkoutInstancePromise=y._clientPromise.then(function(){return y._createPayPalInstance()}).then(function(A){return A})),this._createPaymentSession(P,"paypal")},T.prototype.createPayment=function(E){var y=this;return new Promise(function(P,A){var I;if(!E||!E.flow){A(new o(p.PAYPAL_CHECKOUT_V6_INVALID_SESSION_OPTIONS));return}if(y._flow=E.flow,E.flow==="vault"){I=y._buildBillingAgreementRequest(E),y._createBillingAgreementToken(I).then(function(L){P(L.approvalTokenId)}).catch(A);return}y._createPaymentResource(E).then(function(L){P(L.orderId)}).catch(A)})},T.prototype.createBillingAgreementSession=function(E){var y=this,P={};if(!E)throw new o(p.PAYPAL_CHECKOUT_V6_INVALID_BILLING_AGREEMENT_OPTIONS);if(!E.onApprove||typeof E.onApprove!="function")throw new o(p.PAYPAL_CHECKOUT_V6_INVALID_BILLING_AGREEMENT_OPTIONS);s.sendEvent(y._clientPromise,C.ANALYTICS_EVENTS.SESSION_VAULT_CREATED);var A=E.offerCredit===!0?"paypal-credit":"paypal";E.offerCredit===!0&&s.sendEvent(y._clientPromise,C.ANALYTICS_EVENTS.CREDIT_OFFERED),!y._paypalVaultInstance&&!y._vaultInstancePromise&&y._isPayPalSdkAvailable()&&(y._vaultInstancePromise=y._clientPromise.then(function(){return y._createPayPalInstance({flow:"vault"})}).then(function(L){return y._paypalVaultInstance=L,L}));var I=y._buildBillingAgreementRequest(E);return P.start=function(L){L=L||{};var D=L.presentationMode||E.presentationMode||"auto",z=y._paypalVaultInstance,G=y._validateAppSwitchUrls(E,D);return G?Promise.reject(G):z&&y._client?y._startBillingSession(z,y._client,D,A,I,E):y._vaultInstancePromise?y._vaultInstancePromise.then(function(ne){return y._clientPromise.then(function(W){if(!y._isPayPalSdkAvailable())throw s.sendEvent(W,C.ANALYTICS_EVENTS.CREATE_BA_SESSION_SDK_NOT_LOADED),new o(p.PAYPAL_CHECKOUT_V6_SDK_INITIALIZATION_FAILED);return s.sendEvent(W,C.ANALYTICS_EVENTS.CREATE_BA_SESSION_INSTANCE_CREATED),y._startBillingSession(ne,W,D,A,I,E)})}).catch(function(ne){return y._clientPromise.then(function(W){throw s.sendEvent(W,C.ANALYTICS_EVENTS.CREATE_BA_SESSION_FAILED),new o({type:p.PAYPAL_CHECKOUT_V6_BILLING_AGREEMENT_CREATION_FAILED.type,code:p.PAYPAL_CHECKOUT_V6_BILLING_AGREEMENT_CREATION_FAILED.code,message:p.PAYPAL_CHECKOUT_V6_BILLING_AGREEMENT_CREATION_FAILED.message,details:{originalError:ne}})})}):y._isPayPalSdkAvailable()?Promise.reject(new o(p.PAYPAL_CHECKOUT_V6_INSTANCE_NOT_READY)):y._clientPromise.then(function(ne){throw s.sendEvent(ne,C.ANALYTICS_EVENTS.CREATE_BA_SESSION_SDK_NOT_LOADED),new o(p.PAYPAL_CHECKOUT_V6_SDK_INITIALIZATION_FAILED)})},P},T.prototype.tokenizePayment=function(E){var y=this;return new Promise(function(P,A){var I=!0,L=!!(E&&E.billingToken);if(!E){A(new o(p.PAYPAL_CHECKOUT_V6_MISSING_TOKENIZATION_DATA));return}if(!L&&(!E.payerID||!E.orderID)){A(new o(p.PAYPAL_CHECKOUT_V6_MISSING_TOKENIZATION_DATA));return}E.hasOwnProperty("vault")&&(I=E.vault),y._clientPromise.then(function(D){var z,G,ne;return L?(ne=C.ANALYTICS_EVENTS.TOKENIZE_BA_PREFIX,s.sendEvent(D,ne+".start
125ed"),z="payment_methods/paypal_accounts",G={paypalAccount:{billingAgreementToken:E.billingToken,merchantAccountId:y._merchantAccountId}},I||(G.paypalAccount.vault=!1)):(ne=C.ANALYTICS_EVENTS.TOKENIZE_PAYMENT_PREFIX,s.sendEventPlus(y._clientPromise,ne+".started",{flow:y._flow,context_id:y._contextId}),G=y._formatTokenizeData({payerId:E.payerID,orderId:E.orderID}),z="payment_methods/paypal_accounts"),D.request({endpoint:z,method:"post",data:G}).then(function(W){var ue,H;return ue=y._formatTokenizePayload(W),L?s.sendEvent(D,ne+".succeeded"):(ue.creditFinancingOffered&&(H=y._sessionType==="pay-later"?C.ANALYTICS_EVENTS.PAY_LATER_ACCEPTED:C.ANALYTICS_EVENTS.CREDIT_ACCEPTED,s.sendEventPlus(y._clientPromise,H,{flow:y._flow,context_id:y._contextId})),s.sendEventPlus(y._clientPromise,ne+".success",{flow:y._flow,context_id:y._contextId})),ue}).catch(function(W){throw L?(s.sendEvent(D,ne+".failed"),new o({type:p.PAYPAL_CHECKOUT_V6_TOKENIZATION_FAILED.type,code:p.PAYPAL_CHECKOUT_V6_TOKENIZATION_FAILED.code,message:p.PAYPAL_CHECKOUT_V6_TOKENIZATION_FAILED.message,details:{originalError:W}})):(s.sendEventPlus(y._clientPromise,ne+".failed",{flow:y._flow,context_id:y._contextId}),y._setupError?y._setupError:l(W,{type:p.PAYPAL_CHECKOUT_V6_TOKENIZATION_FAILED.type,code:p.PAYPAL_CHECKOUT_V6_TOKENIZATION_FAILED.code,message:p.PAYPAL_CHECKOUT_V6_TOKENIZATION_FAILED.message}))}).then(P).catch(A)})})},T.prototype._formatTokenizeData=function(E){var y={paypalAccount:{paymentToken:E.paymentId||E.orderId,payerId:E.payerId,unilateral:this._configuration.gatewayConfiguration.paypal.unvettedMerchant}};return this._merchantAccountId&&(y.merchantAccountId=this._merchantAccountId),y},T.prototype._formatTokenizePayload=function(E){var y,P={};return E.paypalAccounts&&(P=E.paypalAccounts[0]),y={nonce:P.nonce,details:{},type:P.type},P.details&&P.details.payerInfo&&(y.details=P.details.payerInfo),P.details&&P.details.creditFinancingOffered&&(y.creditFinancingOffered=P.details.creditFinancingOffered),P.details&&P.details.shippingOptionId&&(y.shippingOptionId=P.details.shippingOptionId),P.details&&P.details.cobrandedCardLabel&&(y.cobrandedCardLabel=P.details.cobrandedCardLabel),y},T.prototype._verifyConsistentCurrency=function(E){var y=!0,P,A=["shippingCurrency","handlingCurrency","taxTotalCurrency","insuranceCurrency","shippingDiscountCurrency","discountCurrency"];return E.currency?E.hasOwnProperty("shippingOptions")&&Array.isArray(E.shippingOptions)&&(y=E.shippingOptions.every(function(I){return!I.amount||!I.amount.currency?!1:E.currency.toLowerCase()===I.amount.currency.toLowerCase()}),!y)||E.hasOwnProperty("lineItems")&&Array.isArray(E.lineItems)&&E.lineItems.length>0&&(y=E.lineItems.every(function(I){return I.unitTaxAmountCurrency?E.currency.toLowerCase()===I.unitTaxAmountCurrency.toLowerCase():!0}),!y)?!1:(E.hasOwnProperty("amountBreakdown")&&E.amountBreakdown&&(P=E.amountBreakdown,y=!A.some(function(I){return P.hasOwnProperty(I)&&P[I]&&E.currency.toLowerCase()!==P[I].toLowerCase()})),y):!0},T.prototype.updatePayment=function(E){var y=this,P,A=!0;return!E||!E.paymentId||!E.amount||!E.currency?Promise.reject(new o(p.PAYPAL_CHECKOUT_V6_INVALID_UPDATE_OPTIONS)):y._contextId!==E.paymentId?Promise.reject(new o(p.PAYPAL_CHECKOUT_V6_PAYMENT_NOT_FOUND)):y._verifyConsistentCurrency(E)?E.lineItems&&Array.isArray(E.lineItems)&&(A=E.lineItems.every(function(I){return I&&typeof I=="object"&&I.hasOwnProperty("quantity")&&I.hasOwnProperty("unitAmount")&&I.hasOwnProperty("name")&&I.hasOwnProperty("kind")}),!A)?Promise.reject(new o(p.PAYPAL_CHECKOUT_V6_INVALID_LINE_ITEMS)):(P={amount:E.amount,currencyIsoCode:E.currency,paymentId:E.paymentId},y._merchantAccountId&&(P.merchantAccountId=y._merchantAccountId),E.lineItems&&(P.lineItems=E.lineItems),E.shippingOptions&&(P.shippingOptions=E.shippingOptions),E.amountBreakdown&&(P.amountBreakdown=E.amountBreakdown),y._clientPromise.then(function(I){return s.sendEvent(I,"paypal-checkout-v6.update-payment.started"),I.request({endpoint:"paypal_hermes/patch_payment_resource",method:"post",data:P}).then(function(L){return s.sendEvent(I,"paypal-checkout-v6.update-payment.succeeded"),{success:!0,orderId:E.paymentId,updates:L.updates||{}}}).catch(function(L){return s.sendEvent(I,"paypal-checkout-v6.update-payment.failed"),Promise.reject(l(L,{type:p.PAYPAL_CHECKOUT_V6_UPDATE_FAILED.type,code:p.PAYPAL_CHECKOUT_V6_UPDATE_FAILED.code,message:p.PAYPAL_CHECKOUT_V6_UPDATE_FAILED.message}))})})):Promise.reject(new o(p.PAYPAL_CHECKOUT_V6_CURRENCY_MISMATCH))},T.prototype.findEligibleMethods=function(E){var y=this;return this._clientPromise.then(function(P){if(!E||!E.currency)return Promise.reject(new o(p.PAYPAL_CHECKOUT_V6_INVALID_ELIGIBILITY_OPTIONS));var A=y._paypalInstance?Promise.resolve(y._paypalInstance):y._createPayPalInstance();return A.then(function(I){if(!I||typeof I.findEligibleMethods!="function")return Promise.reject(new o(p.PAYPAL_CHECKOUT_V6_SDK_NOT_INITIALIZED));s.sendEvent(P,C.ANALYTICS_EVENTS.FIND_ELIGIBLE_METHODS_STARTED);var L={currencyCode:E.currency};return E.amount&&(L.amount=E.amount),E.countryCode&&(L.countryCode=E.countryCode),E.paymentFlow&&(L.paymentFlow=E.paymentFlow),I.findEligibleMethods(L).then(function(D){s.sendEvent(P,C.ANALYTICS_EVENTS.FIND_ELIGIBLE_METHODS_SUCCEEDED);var z=D&&typeof D.isEligible=="function",G={paypal:z?D.isEligible("paypal"):!!(D&&D.paypal),paylater:z?D.isEligible("paylater"):!!(D&&D.paylater),credit:z?D.isEligible("credit"):!!(D&&D.credit)};return G.getDetails=function(ne){return D.getDetails(ne)},G}).catch(function(D){throw s.sendEvent(P,C.ANALYTICS_EVENTS.FIND_ELIGIBLE_METHODS_FAILED),l(D,{type:p.PAYPAL_CHECKOUT_V6_ELIGIBILITY_CHECK_FAILED.type,code:p.PAYPAL_CHECKOUT_V6_ELIGIBILITY_CHECK_FAILED.code,message:p.PAYPAL_CHECKOUT_V6_ELIGIBILITY_CHECK_FAILED.message})})})})},T.prototype.teardown=function(){return v(this,m(T.prototype)),this._paypalScript&&this._paypalScript.parentNode&&this._paypalScript.parentNode.removeChild(this._paypalScript),this._clientPromise.then(function(E){s.sendEvent(E,C.ANALYTICS_EVENTS.TEARDOWN)})},i.exports=b.wrapPrototype(T)},{"../lib/analytics":144,"../lib/assign":146,"../lib/braintree-error":149,"../lib/constants":150,"../lib/convert-methods-to-error":151,"../lib/convert-to-braintree-error":152,"../lib/create-assets-url":153,"../lib/create-authorization-data":154,"../lib/create-deferred-client":155,"../lib/frame-service/external":163,"../lib/methods":181,"../lib/use-min":187,"./constants":208,"./errors":209,"@braintree/extended-promise":34,"@braintree/wrap-promise":43}],212:[function(n,i,r){var s=n("../lib/braintree-error");i.exports={PAYPAL_NOT_ENABLED:{type:s.types.MERCHANT,code:"PAYPAL_NOT_ENABLED",message:"PayPal is not enabled for this merchant."},PAYPAL_SANDBOX_ACCOUNT_NOT_LINKED:{type:s.types.MERCHANT,code:"PAYPAL_SANDBOX_ACCOUNT_NOT_LINKED",message:"A linked PayPal Sandbox account is required to use PayPal Checkout in Sandbox. See https://developer.paypal.com/braintree/docs/guides/paypal/testing-go-live#linked-paypal-testing for details on linking your PayPal sandbox with Braintree."},PAYPAL_ACCOUNT_TOKENIZATION_FAILED:{type:s.types.NETWORK,code:"PAYPAL_ACCOUNT_TOKENIZATION_FAILED",message:"Could not tokenize user's PayPal account."},PAYPAL_FLOW_FAILED:{type:s.types.NETWORK,code:"PAYPAL_FLOW_FAILED",message:"Could not initialize PayPal flow."},PAYPAL_FLOW_OPTION_REQUIRED:{type:s.types.MERCHANT,code:"PAYPAL_FLOW_OPTION_REQUIRED",message:"PayPal flow property is invali
125d or missing."},PAYPAL_START_VAULT_INITIATED_CHECKOUT_PARAM_REQUIRED:{type:s.types.MERCHANT,code:"PAYPAL_START_VAULT_INITIATED_CHECKOUT_PARAM_REQUIRED"},PAYPAL_START_VAULT_INITIATED_CHECKOUT_SETUP_FAILED:{type:s.types.NETWORK,code:"PAYPAL_START_VAULT_INITIATED_CHECKOUT_SETUP_FAILED",message:"Something went wrong when setting up the checkout workflow."},PAYPAL_START_VAULT_INITIATED_CHECKOUT_POPUP_OPEN_FAILED:{type:s.types.MERCHANT,code:"PAYPAL_START_VAULT_INITIATED_CHECKOUT_POPUP_OPEN_FAILED",message:"PayPal popup failed to open, make sure to initiate the vault checkout in response to a user action."},PAYPAL_START_VAULT_INITIATED_CHECKOUT_CANCELED:{type:s.types.CUSTOMER,code:"PAYPAL_START_VAULT_INITIATED_CHECKOUT_CANCELED",message:"Customer closed PayPal popup before authorizing."},PAYPAL_START_VAULT_INITIATED_CHECKOUT_IN_PROGRESS:{type:s.types.MERCHANT,code:"PAYPAL_START_VAULT_INITIATED_CHECKOUT_IN_PROGRESS",message:"Vault initiated checkout already in progress."},PAYPAL_INVALID_PAYMENT_OPTION:{type:s.types.MERCHANT,code:"PAYPAL_INVALID_PAYMENT_OPTION",message:"PayPal payment options are invalid."},PAYPAL_MISSING_REQUIRED_OPTION:{type:s.types.MERCHANT,code:"PAYPAL_MISSING_REQUIRED_OPTION",message:"Missing required option."}}},{"../lib/braintree-error":149}],213:[function(n,i,r){var s=n("../lib/basic-component-verification"),a=n("@braintree/wrap-promise"),o=n("./paypal-checkout"),l="3.140.0";function c(u){var p="PayPal Checkout";return s.verify({name:p,client:u.client,authorization:u.authorization}).then(function(){var h=new o(u);return h._initialize(u)})}function d(){return!0}i.exports={create:a(c),isSupported:d,VERSION:l}},{"../lib/basic-component-verification":147,"./paypal-checkout":214,"@braintree/wrap-promise":43}],214:[function(n,i,r){var s=n("../lib/analytics"),a=n("../lib/assign").assign,o=n("../lib/create-deferred-client"),l=n("../lib/create-assets-url"),c=n("@braintree/extended-promise"),d=n("@braintree/wrap-promise"),u=n("../lib/braintree-error"),p=n("../lib/convert-to-braintree-error"),h=n("./errors"),m=n("../paypal/shared/constants"),v=n("../lib/frame-service/external"),_=n("../lib/create-authorization-data"),b=n("../lib/methods"),w=n("../lib/use-min"),C=n("../lib/convert-methods-to-error"),O=n("../lib/querystring"),T="3.140.0",E=n("../lib/constants").INTEGRATION_TIMEOUT_MS,y=["amount","currency","vaultInitiatedCheckoutPaymentMethodToken"],P="https://www.{ENV}paypal.com/smart/buttons/preload";c.suppressUnhandledPromiseMessage=!0;function A(I){this._merchantAccountId=I.merchantAccountId,this._autoSetDataUserIdToken=!!I.autoSetDataUserIdToken}A.prototype._initialize=function(I){var L;return I.client?(L=I.client.getConfiguration(),this._authorizationInformation={fingerprint:L.authorizationFingerprint,environment:L.gatewayConfiguration.environment}):(L=_(I.authorization),this._authorizationInformation={fingerprint:L.attrs.authorizationFingerprint,environment:L.environment}),this._clientPromise=o.create({authorization:I.authorization,client:I.client,debug:I.debug,assetsUrl:l.create(I.authorization),name:"PayPal Checkout"}).then((function(D){return this._configuration=D.getConfiguration(),this._merchantAccountId||(this._configuration.gatewayConfiguration.paypalEnabled?this._configuration.gatewayConfiguration.paypal.environmentNoNetwork===!0&&(this._setupError=new u(h.PAYPAL_SANDBOX_ACCOUNT_NOT_LINKED)):this._setupError=new u(h.PAYPAL_NOT_ENABLED)),this._setupError?Promise.reject(this._setupError):(s.sendEvent(D,"paypal-checkout.initialized"),this._frameServicePromise=this._setupFrameService(D),D)}).bind(this)),I.client?this._clientPromise.then((function(){return this}).bind(this)):Promise.resolve(this)},A.prototype._setupFrameService=function(I){var L=new c,D=I.getConfiguration(),z=setTimeout(function(){s.sendEvent(I,"paypal-checkout.frame-service.timed-out"),L.reject(new u(h.PAYPAL_START_VAULT_INITIATED_CHECKOUT_SETUP_FAILED))},E);return this._assetsUrl=D.gatewayConfiguration.paypal.assetsUrl+"/web/"+T,this._isDebug=D.isDebug,this._loadingFrameUrl=this._assetsUrl+"/html/paypal-landing-frame"+w(this._isDebug)+".html",v.create({name:"braintreepaypallanding",dispatchFrameUrl:this._assetsUrl+"/html/dispatch-frame"+w(this._isDebug)+".html",openFrameUrl:this._loadingFrameUrl},(function(G){this._frameService=G,clearTimeout(z),L.resolve()}).bind(this)),L},A.prototype.createPayment=function(I){var L=this;return!I||!m.FLOW_ENDPOINTS.hasOwnProperty(I.flow)?Promise.reject(new u(h.PAYPAL_FLOW_OPTION_REQUIRED)):(s.sendEvent(this._clientPromise,"paypal-checkout.createPayment"),this._createPaymentResource(I).then(function(D){var z,G;return I.flow==="checkout"?(G=O.parse(D.paymentResource.redirectUrl),z=G.token):z=D.agreementSetup.tokenId,L._contextId=z,z}))},A.prototype._createPaymentResource=function(I,L){var D=this,z="paypal_hermes/"+m.FLOW_ENDPOINTS[I.flow];return this._flow=I.flow,delete this.intentFromCreatePayment,L=L||{},I.offerCredit===!0&&s.sendEvent(this._clientPromise,"paypal-checkout.credit.offered"),this._clientPromise.then(function(G){return G.request({endpoint:z,method:"post",data:D._formatPaymentResourceData(I,L)}).then(function(ne){return D.intentFromCreatePayment=I.intent,ne})}).catch(function(G){var ne;return D._setupError?Promise.reject(D._setupError):(ne=G.details&&G.details.httpStatus,ne===422?Promise.reject(new u({type:h.PAYPAL_INVALID_PAYMENT_OPTION.type,code:h.PAYPAL_INVALID_PAYMENT_OPTION.code,message:h.PAYPAL_INVALID_PAYMENT_OPTION.message,details:{originalError:G}})):Promise.reject(p(G,{type:h.PAYPAL_FLOW_FAILED.type,code:h.PAYPAL_FLOW_FAILED.code,message:h.PAYPAL_FLOW_FAILED.message})))})},A.prototype.updatePayment=function(I){var L=this,D="paypal_hermes/patch_payment_resource";return!I||this._hasMissingOption(I,m.REQUIRED_OPTIONS)?(s.sendEventPlus(L._clientPromise,"paypal-checkout.updatePayment.missing-options",{flow:L._flow,context_id:L._contextId}),Promise.reject(new u(h.PAYPAL_MISSING_REQUIRED_OPTION))):this._verifyConsistentCurrency(I)?(s.sendEventPlus(this._clientPromise,"paypal-checkout.updatePayment",{flow:L._flow,context_id:L._contextId}),this._clientPromise.then(function(z){return z.request({endpoint:D,method:"post",data:L._formatUpdatePaymentData(I)})}).catch(function(z){var G=z.details&&z.details.httpStatus;return G===422?(s.sendEventPlus(L._clientPromise,"paypal-checkout.updatePayment.invali
125d",{flow:L._flow,context_id:L._contextId}),Promise.reject(new u({type:h.PAYPAL_INVALID_PAYMENT_OPTION.type,code:h.PAYPAL_INVALID_PAYMENT_OPTION.code,message:h.PAYPAL_INVALID_PAYMENT_OPTION.message,details:{originalError:z}}))):(s.sendEventPlus(L._clientPromise,"paypal-checkout.updatePayment."+h.PAYPAL_FLOW_FAILED.code,{flow:L._flow,context_id:L._contextId}),Promise.reject(p(z,{type:h.PAYPAL_FLOW_FAILED.type,code:h.PAYPAL_FLOW_FAILED.code,message:h.PAYPAL_FLOW_FAILED.message})))})):(s.sendEventPlus(L._clientPromise,"paypal-checkout.updatePayment.inconsistent-currencies",{flow:L._flow,context_id:L._contextId}),Promise.reject(new u({type:h.PAYPAL_INVALID_PAYMENT_OPTION.type,code:h.PAYPAL_INVALID_PAYMENT_OPTION.code,message:h.PAYPAL_INVALID_PAYMENT_OPTION.message,details:{originalError:new Error("One or more shipping option currencies differ from checkout currency.")}})))},A.prototype.startVaultInitiatedCheckout=function(I){var L,D=this;return this._vaultInitiatedCheckoutInProgress?(s.sendEventPlus(this._clientPromise,"paypal-checkout.startVaultInitiatedCheckout.error.already-in-progress",{flow:D._flow,context_id:D._contextId}),Promise.reject(new u(h.PAYPAL_START_VAULT_INITIATED_CHECKOUT_IN_PROGRESS))):(y.forEach(function(z){I.hasOwnProperty(z)||(L=z)}),L?Promise.reject(new u({type:h.PAYPAL_START_VAULT_INITIATED_CHECKOUT_PARAM_REQUIRED.type,code:h.PAYPAL_START_VAULT_INITIATED_CHECKOUT_PARAM_REQUIRED.code,message:"Required param "+L+" is missing."})):(this._vaultInitiatedCheckoutInProgress=!0,this._addModalBackdrop(I),I=a({},I,{flow:"checkout"}),s.sendEventPlus(this._clientPromise,"paypal-checkout.startVaultInitiatedCheckout.started",{flow:D._flow,context_id:D._contextId}),this._waitForVaultInitiatedCheckoutDependencies().then(function(){var z=new c,G=D._createPaymentResource(I,{returnUrl:D._constructVaultCheckoutUrl("redirect-frame"),cancelUrl:D._constructVaultCheckoutUrl("cancel-frame")}).then(function(ne){var W=ne.paymentResource.redirectUrl;return D._frameService.redirect(W),z});return D._frameService.open({},D._createFrameServiceCallback(z)),G}).catch(function(z){return D._vaultInitiatedCheckoutInProgress=!1,D._removeModalBackdrop(),z.code==="FRAME_SERVICE_FRAME_CLOSED"?(s.sendEventPlus(D._clientPromise,"paypal-checkout.startVaultInitiatedCheckout.canceled.by-customer",{flow:D._flow,context_id:D._contextId}),Promise.reject(new u(h.PAYPAL_START_VAULT_INITIATED_CHECKOUT_CANCELED))):(D._frameService&&D._frameService.close(),z.code&&z.code.indexOf("FRAME_SERVICE_FRAME_OPEN_FAILED")>-1?(s.sendEventPlus(D._clientPromise,"paypal-checkout.startVaultInitiatedCheckout.failed.popup-not-opened",{flow:D._flow,context_id:D._contextId}),Promise.reject(new u({code:h.PAYPAL_START_VAULT_INITIATED_CHECKOUT_POPUP_OPEN_FAILED.code,type:h.PAYPAL_START_VAULT_INITIATED_CHECKOUT_POPUP_OPEN_FAILED.type,message:h.PAYPAL_START_VAULT_INITIATED_CHECKOUT_POPUP_OPEN_FAILED.message,details:{originalError:z}}))):Promise.reject(z))}).then(function(z){return D._frameService.close(),D._vaultInitiatedCheckoutInProgress=!1,D._removeModalBackdrop(),s.sendEventPlus(D._clientPromise,"paypal-checkout.startVaultInitiatedCheckout.succeeded",{flow:D._flow,context_id:D._contextId}),Promise.resolve(z)})))},A.prototype._addModalBackdrop=function(I){I.optOutOfModalBackdrop||(this._modalBackdrop||(this._modalBackdrop=document.createElement("div"),this._modalBackdrop.setAttribute("data-braintree-paypal-vault-initiated-checkout-modal",!0),this._modalBackdrop.style.position="fixed",this._modalBackdrop.style.top=0,this._modalBackdrop.style.bottom=0,this._modalBackdrop.style.left=0,this._modalBackdrop.style.right=0,this._modalBackdrop.style.zIndex=9999,this._modalBackdrop.style.background="black",this._modalBackdrop.style.opacity="0.7",this._modalBackdrop.addEventListener("click",(function(){this.focusVaultInitiatedCheckoutWindow()}).bind(this))),document.body.appendChild(this._modalBackdrop))},A.prototype._removeModalBackdrop=function(){this._modalBackdrop&&this._modalBackdrop.parentNode&&this._modalBackdrop.parentNode.removeChild(this._modalBackdrop)},A.prototype.closeVaultInitiatedCheckoutWindow=function(){return this._vaultInitiatedCheckoutInProgress&&s.sendEventPlus(this._clientPromise,"paypal-checkout.startVaultInitiatedCheckout.canceled.by-merchant",{flow:this._flow,context_id:this._contextId}),this._waitForVaultInitiatedCheckoutDependencies().then((function(){this._frameService.close()}).bind(this))}
125,A.prototype.focusVaultInitiatedCheckoutWindow=function(){return this._waitForVaultInitiatedCheckoutDependencies().then((function(){this._frameService.focus()}).bind(this))},A.prototype._createFrameServiceCallback=function(I){var L=this;return function(D,z){D?I.reject(D):z&&(L._frameService.redirect(L._loadingFrameUrl),L.tokenizePayment({paymentToken:z.token,payerID:z.PayerID,paymentID:z.paymentId,orderID:z.orderId}).then(function(G){I.resolve(G)}).catch(function(G){I.reject(G)}))}},A.prototype._waitForVaultInitiatedCheckoutDependencies=function(){var I=this;return this._clientPromise.then(function(){return I._frameServicePromise})},A.prototype._constructVaultCheckoutUrl=function(I){var L=this._frameService._serviceId;return this._assetsUrl+"/html/"+I+w(this._isDebug)+".html?channel="+L},A.prototype.tokenizePayment=function(I){var L=this,D=!0,z,G={flow:this._flow,intent:I.intent||this.intentFromCreatePayment},ne={ecToken:I.paymentToken,billingToken:I.billingToken,payerId:I.payerID,paymentId:I.paymentID,orderId:I.orderID,shippingOptionsId:I.shippingOptionsId};return I.hasOwnProperty("vault")&&(D=I.vault),G.vault=D,s.sendEventPlus(this._clientPromise,"paypal-checkout.tokenization.started",{flow:L._flow,context_id:L._contextId}),this._clientPromise.then(function(W){return W.request({endpoint:"payment_methods/paypal_accounts",method:"post",data:L._formatTokenizeData(G,ne)})}).then(function(W){return z=L._formatTokenizePayload(W),s.sendEventPlus(L._clientPromise,"paypal-checkout.tokenization.success",{flow:L._flow,context_id:L._contextId}),z.creditFinancingOffered&&s.sendEventPlus(L._clientPromise,"paypal-checkout.credit.accepted",{flow:L._flow,context_id:L._contextId}),z}).catch(function(W){return L._setupError?Promise.reject(L._setupError):(s.sendEventPlus(L._clientPromise,"paypal-checkout.tokenization.failed",{flow:L._flow,context_id:L._contextId}),Promise.reject(p(W,{type:h.PAYPAL_ACCOUNT_TOKENIZATION_FAILED.type,code:h.PAYPAL_ACCOUNT_TOKENIZATION_FAILED.code,message:h.PAYPAL_ACCOUNT_TOKENIZATION_FAILED.message})))})},A.prototype.getClientId=function(){return this._clientPromise.then(function(I){return I.getConfiguration().gatewayConfiguration.paypal.clientId})},A.prototype.loadPayPalSDK=function(I){var L,D,z=new c,G=I&&I.dataAttributes||{},ne=G["user-id-token"]||G["data-user-id-token"];return this._configuration&&(G["client-metadata-id"]=G["client-metadata-id"]?G["client-metadata-id"]:this._configuration.analyticsMetadata.sessionId,G["data-sdk-integration-source"]=m.BT_INTEGRATION_SOURCE),ne||(ne=this._authorizationInformation.fingerprint&&this._authorizationInformation.fingerprint.split("?")[0]),this._paypalScript=document.createElement("script"),I=a({},{components:"buttons"},I),delete I.dataAttributes,I.vault?I.intent=I.intent||"tokenize":(I.intent=I.intent||"authorize",I.currency=I.currency||"USD"),D=m.ENVIRONMENT[I.env]||"https://www.paypal.com/sdk/js?",delete I.env,this._paypalScript.onload=function(){z.resolve()},Object.keys(G).forEach((function(W){this._paypalScript.setAttribute("data-"+W.replace(/^data\-/,""),G[W])}).bind(this)),I["client-id"]?L=Promise.resolve(I["client-id"]):L=this.getClientId(),L.then((function(W){I["client-id"]=W,this._autoSetDataUserIdToken&&ne&&(this._paypalScript.setAttribute("data-user-id-token",ne),this._attachPreloadPixel({id:W,userIdToken:ne,amount:G.amount,currency:I.currency,merchantId:I["merchant-id"]})),this._paypalScript.src=O.queryify(D,I),document.head.insertBefore(this._paypalScript,document.head.firstElementChild)}).bind(this)),z.then((function(){return this}).bind(this))},A.prototype._attachPreloadPixel=function(I){var L,D=I.id,z=I.userIdToken,G=this._authorizationInformation.environment,ne=G==="production"?"":"sandbox.",W=P.replace("{ENV}",ne),ue={"client-id":D,"user-id-token":z};I.amount&&(ue.amount=I.amount),I.currency&&(ue.currency=I.currency),I.merchantId&&(ue["merchant-id"]=I.merchantId),L=new XMLHttpRequest,L.open("GET",O.queryify(W,ue)),L.send()},A.prototype._formatPaymentResourceData=function(I,L){var D=this,z=this._configuration.gatewayConfiguration,G={returnUrl:L.returnUrl||"https://www.paypal.com/checkoutnow/error",cancelUrl:L.cancelUrl||"https://www.paypal.com/checkoutnow/error",offerPaypalCredit:I.offerCredit===!0,merchantAccountId:this._merchantAccountId,experienceProfile:{brandName:I.displayName||z.paypal.displayName,localeCode:I.locale,noShipping:(!I.enableShippingAddress).toString(),addressOverride:I.shippingAddressEditable===!1,landingPageType:I.landingPageType},shippingOptions:I.shippingOptions,payer_email:I.userAuthenticationEmail};return I.hasOwnProperty("returnUrl")&&(G.returnUrl=I.returnUrl),I.hasOwnProperty("cancelUrl")&&(G.cancelUrl=I.cancelUrl),I.hasOwnProperty("appSwitchPreference")&&(G.appSwitchPreference=I.appSwitchPreference),I.hasOwnProperty("shippingCallbackUrl")&&(G.shippingCallbackUrl=I.shippingCallbackUrl),I.hasOwnProperty("paymentReadySessionId")&&(G.paymentReadySessionId=I.paymentReadySessionId),I.hasOwnProperty("amountBreakdown")&&(G.amountBreakdown=I.amountBreakdown),I.planType&&(G.planType=I.planType),I.planMetadata&&(G.planMetadata=this._formatPlanMetadata(I.planMetadata)),D._formatPaymentResourceCheckoutData(G,I),D._formatPaymentResourceVaultData(G,I),this._riskCorrelationId=I.riskCorrelationId,I.r
125iskCorrelationId&&(G.correlationId=this._riskCorrelationId),G},A.prototype._formatPaymentResourceVaultData=function(I,L){L.flow!=="checkout"&&(I.shippingAddress=L.shippingAddressOverride,L.billingAgreementDescription&&(I.description=L.billingAgreementDescription),L.hasOwnProperty("userAction")&&(I.experienceProfile.userAction=L.userAction))},A.prototype._formatPaymentResourceCheckoutData=function(I,L){var D,z=L.intent;if(L.flow==="checkout"){I.amount=L.amount,I.currencyIsoCode=L.currency,I.requestBillingAgreement=L.requestBillingAgreement,L.hasOwnProperty("userAction")&&(I.experienceProfile.userAction=L.userAction),z&&(z==="capture"&&(z="sale"),I.intent=z),L.hasOwnProperty("lineItems")&&(I.lineItems=L.lineItems),L.hasOwnProperty("vaultInitiatedCheckoutPaymentMethodToken")&&(I.vaultInitiatedCheckoutPaymentMethodToken=L.vaultInitiatedCheckoutPaymentMethodToken),L.hasOwnProperty("shippingOptions")&&(I.shippingOptions=L.shippingOptions);for(D in L.shippingAddressOverride)L.shippingAddressOverride.hasOwnProperty(D)&&(I[D]=L.shippingAddressOverride[D]);L.contactPreference&&(I.contactPreference=L.contactPreference),L.hasOwnProperty("billingAgreementDetails")&&(I.billingAgreementDetails=L.billingAgreementDetails)}},A.prototype._verifyConsistentCurrency=function(I){return I.currency&&I.hasOwnProperty("shippingOptions")&&Array.isArray(I.shippingOptions)?I.shippingOptions.every(function(L){return L.amount&&L.amount.currency&&I.currency.toLowerCase()===L.amount.currency.toLowerCase()}):!0},A.prototype._hasMissingOption=function(I,L){var D,z;if(L=L||[],!I.hasOwnProperty("amount")&&!I.hasOwnProperty("lineItems"))return!0;for(D=0;D<L.length;D++)if(z=L[D],!I.hasOwnProperty(z))return!0;return!1},A.prototype._formatPlanMetadata=function(I){var L,D,z,G,ne=["currencyIsoCode","name","oneTimeFeeAmount","productDescription","productPrice","productQuantity","shippingAmount","taxAmount","totalAmount"],W=["billingFrequency","billingFrequencyUnit","numberOfExecutions","sequence","startDate","trial","pricingScheme"],ue={billingCycles:[]};if(I.hasOwnProperty("billingCycles"))for(ue.billingCycles=[],L=0;L<I.billingCycles.length;L++){for(z=I.billingCycles[L],G={},D=0;D<W.length;D++)G[W[D]]=z[W[D]];ue.billingCycles.push(G)}for(L=0;L<ne.length;L++)ue[ne[L]]=I[ne[L]];return ue},A.prototype._formatUpdatePaymentData=function(I){var L=this,D={merchantAccountId:this._merchantAccountId,paymentId:I.paymentId||I.orderId,currencyIsoCode:I.currency};return I.hasOwnProperty("amount")&&(D.amount=I.amount),I.hasOwnProperty("lineItems")&&(D.lineItems=I.lineItems),I.hasOwnProperty("shippingOptions")&&(D.shippingOptions=I.shippingOptions),I.hasOwnProperty("amountBreakdown")&&(D.amountBreakdown=I.amountBreakdown),I.hasOwnProperty("shippingAddress")&&(s.sendEventPlus(L._clientPromise,"paypal-checkout.updatePayment.shippingAddress.provided.by-the-merchant",{flow:L._flow,context_id:L._contextId}),D.line1=I.shippingAddress.line1,I.shippingAddress.hasOwnProperty("line2")&&(D.line2=I.shippingAddress.line2),D.city=I.shippingAddress.city,D.state=I.shippingAddress.state,D.postalCode=I.shippingAddress.postalCode,D.countryCode=I.shippingAddress.countryCode,I.shippingAddress.hasOwnProperty("phone")&&(D.phone=I.shippingAddress.phone),I.shippingAddress.hasOwnProperty("recipientName")&&(D.recipientName=I.shippingAddress.recipientName)),D},A.prototype._formatTokenizeData=function(I,L){var D=this._configuration,z=D.gatewayConfiguration,G=D.authorizationType==="TOKENIZATION_KEY",ne=I.flow==="vault"||I.flow==null&&!L.paymentId,W=this._riskCorrelationId||L.billingToken||L.ecToken,ue={paypalAccount:{correlationId:W,options:{validate:ne&&!G&&I.vault}}};return ne?ue.paypalAccount.billingAgreementToken=L.billingToken:(ue.paypalAccount.paymentToken=L.paymentId||L.orderId,ue.paypalAccount.payerId=L.payerId,ue.paypalAccount.unilateral=z.paypal.unvettedMerchant,I.intent&&(ue.paypalAccount.intent=I.intent)),this._merchantAccountId&&(ue.merchantAccountId=this._merchantAccountId),ue},A.prototype._formatTokenizePayload=function(I){var L,D={};return I.paypalAccounts&&(D=I.paypalAccounts[0]),L={nonce:D.nonce,details:{},type:D.type},D.details&&D.details.payerInfo&&(L.details=D.details.payerInfo),D.details&&D.details.creditFinancingOffered&&(L.creditFinancingOffered=D.details.creditFinancingOffered),D.details&&D.details.shippingOptionId&&(L.shippingOptionId=D.details.shippingOptionId),D.details&&D.details.cobrandedCardLabel&&(L.cobrandedCardLabel=D.details.cobrandedCardLabel),L},A.prototype.teardown=function(){var I=this;return C(this,b(A.prototype)),this._paypalScript&&this._paypalScript.parentNode&&this._paypalScript.parentNode.removeChild(this._paypalScript),this._frameServicePromise.catch(function(){}).then(function(){return I._frameService?I._frameService.teardown():Promise.resolve()})},i.exports=d.wrapPrototype(A)},{"../lib/analytics":144,"../lib/assign":146,"../lib/braintree-error":149,"../lib/constants":150,"../lib/convert-methods-to-error":151,"../lib/convert-to-braintree-error":152,"../lib/create-assets-url":153,"../lib/create-authorization-data":154,"../lib/create-deferred-client":155,"../lib/frame-service/external":163,"../lib/methods":181,"../lib/querystring":183,"../lib/use-min":187,"../paypal/shared/constants":217,"./errors":212,"@braintree/extended-promise":34,"@braintree/wrap-promise":43}],215:[function(n,i,r){var s=n("../../lib/frame-service/external"),a=n("../../lib/braintree-error"),o=n("../../lib/convert-to-braintree-error"),l=n("../../lib/use-min"),c=n("../../lib/once"),d="3.140.0",u=n("../shared/constants"),p=n("../../lib/constants").INTEGRATION_TIMEOUT_MS,h=n("../../lib/analytics"),m=n("../../lib/methods"),v=n("../../lib/deferred"),_=n("../shared/errors"),b=n("../../lib/convert-methods-to-error"),w=n("../../lib/querystring"),C=n("@braintree/wrap-promise");function O(T){this._client=T.client,this._assetsUrl=T.client.getConfiguration().gatewayConfiguration.paypal.assetsUrl+"/web/"+d,this._isDebug=T.client.getConfiguration().isDebug,this._loadingFrameUrl=this._assetsUrl+"/html/paypal-landing-frame"+l(this._isDebug)+".html",this._authorizationInProgress=!1}O.prototype._initialize=function(){var T=this,E=this._client,y=setTimeout(function(){h.sendEvent(E,"paypal.load.timed-out")},p);return new Promise(function(P){s.create({name:u.LANDING_FRAME_NAME,dispatchFrameUrl:T._assetsUrl+"/html/dispatch-frame"+l(T._isDebug)+".html",openFrameUrl:T._loadingFrameUrl},function(A){T._frameService=A,clearTimeout(y),h.sendEvent(E,"paypal.load.succeeded"),P(T)})})},O.prototype.tokenize=function(T,E){var y=this,P=this._client,A,I;return E&&(E=c(v(E))),!T||!u.FLOW_ENDPOINTS.hasOwnProperty(T.flow)?(I=new a(_.PAYPAL_FLOW_OPTION_REQUIRED),E?(E(I),this._frameService.createNoopHandler()):Promise.reject(I)):(A=new Promise(function(L,D){y._authorizationInProgress?(h.sendEvent(P,"paypal.tokenization.error.already-opened"),D(new a(_.PAYPAL_TOKENIZATION_REQUEST_ACTIVE))):(y._authorizationInProgress=!0,window.popupBridge||h.sendEvent(P,"paypal.tokenization.opened"),T.offerCredit===!0&&h.sendEvent(P,"paypal.credit.offered"),T.offerPayLater===!0&&h.sendEvent(P,"paypal.paylater.offered"),y._navigateFrameToAuth(T).catch(D),y._frameService.open({},y._createFrameServiceCallback(T,L,D)))}),E?(A.then(function(L){E(null,L)}).catch(E),this._frameService.createHandler({beforeClose:function(){h.sendEvent(P,"paypal.tokenization.closed.by-merchant")}})):A)},O.prototype._createFrameServiceCallback=function(T,E,y){var P=this,A=this._client;return window.popupBridge?function(I,L){var D=L&&L.path&&L.path.substring(0,7)==="/cancel";P._authorizationInProgress=!1,I||D?(h.sendEvent(A,"popup-bridge:paypal:canceled"),y(new a(_.PAYPAL_POPUP_CLOSED))):L&&P._tokenizePayPal(T,L.queryItems).then(E).catch(y)}:function(I,L){P._authorizationInProgress=!1,I?I.code==="FRAME_SERVICE_FRAME_CLOSED"?(h.sendEvent(A,"paypal.tokenization.closed.by-user"),y(new a(_.PAYPAL_POPUP_CLOSED))):I.code&&I.code.indexOf("FRAME_SERVICE_FRAME_OPEN_FAILED")>-1&&y(new a({code:_.PAYPAL_POPUP_OPEN_FAILED.code,type:_.PAYPAL_POPUP_OPEN_FAILED.type,message:_.PAYPAL_POPUP_OPEN_FAILED.message,details:{originalError:I}})):L&&P._tokenizePayPal(T,L).then(E).catch(y)}},O.prototype._tokenizePayPal=function(T,E){var y=this,P=this._client;return window.popupBridge||this._frameService.redirect(this._loadingFrameUrl),P.request({endpoint:"payment_methods/paypal_accounts",method:"post",data:this._formatTokenizeData(T,E)}).then(function(A){var I=y._formatTokenizePayload(A);return window.popupBridge?h.sendEvent(P,"popup-bridge:paypal:succeeded"):h.sendEvent(P,"paypal.tokenization.success"),I.creditFinancingOffered&&h.sendEvent(P,"paypal.credit.accepted"),y._frameService.close(),I}).catch(function(A){return window.popupBridge?h.sendEvent(P,"popup-bridge:paypal:failed"):h.sendEvent(P,"paypal.tokenization.failed"),y._frameService.close(),Promise.reject(o(A,{type:_.PAYPAL_ACCOUNT_TOKENIZATION_FAILED.type,code:_.PAYPAL_ACCOUNT_TOKENIZATION_FAILED.code,message:_.PAYPAL_ACCOUNT_TOKENIZATION_FAILED.message}))})},O.prototype._formatTokenizePayload=function(T){var E,y={};return T.paypalAccounts&&(y=T.paypalAccounts[0]),E={nonce:y.nonce,details:{},type:y.type},y.details&&y.details.payerInfo&&(E.details=y.details.payerInfo),y.details&&y.details.creditFinancingOffered&&(E.creditFinancingOffered=y.details.creditFinancingOffered),E},O.prototype._formatTokenizeData=function(T,E){var y=this._client.getConfiguration(),P=y.gatewayConfiguration,A=y.authorizationType==="TOKENIZATION_KEY",I={payp
125alAccount:{correlationId:E.ba_token||E.token,options:{validate:T.flow==="vault"&&!A}}};return E.ba_token?I.paypalAccount.billingAgreementToken=E.ba_token:(I.paypalAccount.paymentToken=E.paymentId,I.paypalAccount.payerId=E.PayerID,I.paypalAccount.unilateral=P.paypal.unvettedMerchant,T.hasOwnProperty("intent")&&(I.paypalAccount.intent=T.intent)),I},O.prototype._navigateFrameToAuth=function(T){var E=this,y=this._client,P="paypal_hermes/"+u.FLOW_ENDPOINTS[T.flow];return y.request({endpoint:P,method:"post",data:this._formatPaymentResourceData(T)}).then(function(A){var I;T.flow==="checkout"?I=A.paymentResource.redirectUrl:I=A.agreementSetup.approvalUrl,T.useraction==="commit"&&(I=w.queryify(I,{useraction:"commit"})),window.popupBridge&&h.sendEvent(y,"popup-bridge:paypal:started"),E._frameService.redirect(I)}).catch(function(A){var I=A.details&&A.details.httpStatus;return E._frameService.close(),E._authorizationInProgress=!1,I===422?Promise.reject(new a({type:_.PAYPAL_INVALID_PAYMENT_OPTION.type,code:_.PAYPAL_INVALID_PAYMENT_OPTION.code,message:_.PAYPAL_INVALID_PAYMENT_OPTION.message,details:{originalError:A}})):Promise.reject(o(A,{type:_.PAYPAL_FLOW_FAILED.type,code:_.PAYPAL_FLOW_FAILED.code,message:_.PAYPAL_FLOW_FAILED.message}))})},O.prototype._formatPaymentResourceData=function(T){var E,y=this._client.getConfiguration().gatewayConfiguration,P=this._frameService._serviceId,A={returnUrl:y.paypal.assetsUrl+"/web/"+d+"/html/redirect-frame"+l(this._isDebug)+".html?channel="+P,cancelUrl:y.paypal.assetsUrl+"/web/"+d+"/html/cancel-frame"+l(this._isDebug)+".html?channel="+P,offerPaypalCredit:T.offerCredit===!0,offerPayLater:T.offerPayLater===!0,experienceProfile:{brandName:T.displayName||y.paypal.displayName,localeCode:T.locale,noShipping:(!T.enableShippingAddress).toString(),addressOverride:T.shippingAddressEditable===!1,landingPageType:T.landingPageType}};if(window.popupBridge&&typeof window.popupBridge.getReturnUrlPrefix=="function"&&(A.returnUrl=window.popupBridge.getReturnUrlPrefix()+"return",A.cancelUrl=window.popupBridge.getReturnUrlPrefix()+"cancel"),T.flow==="checkout"){A.amount=T.amount,A.currencyIsoCode=T.currency,T.hasOwnProperty("intent")&&(A.intent=T.intent);for(E in T.shippingAddressOverride)T.shippingAddressOverride.hasOwnProperty(E)&&(A[E]=T.shippingAddressOverride[E])}else A.shippingAddress=T.shippingAddressOverride,T.billingAgreementDescription&&(A.description=T.billingAgreementDescription);return A},O.prototype.closeWindow=function(){this._authorizationInProgress&&h.sendEvent(this._client,"paypal.tokenize.closed.by-merchant"),this._frameService.close()},O.prototype.focusWindow=function(){this._frameService.focus()},O.prototype.teardown=C(function(){var T=this;return T._frameService.teardown(),b(T,m(O.prototype)),h.sendEvent(T._client,"paypal.teardown-completed"),Promise.resolve()}),i.exports=O},{"../../lib/analytics":144,"../../lib/braintree-error":149,"../../lib/constants":150,"../../lib/convert-methods-to-error":151,"../../lib/convert-to-braintree-error":152,"../../lib/deferred":156,"../../lib/frame-service/external":163,"../../lib/methods":181,"../../lib/once":182,"../../lib/querystring":183,"../../lib/use-min":187,"../shared/constants":217,"../shared/errors":218,"@braintree/wrap-promise":43}],216:[function(n,i,r){var s=n("../lib/analytics"),a=n("../lib/basic-component-verification"),o=n("../lib/create-deferred-client"),l=n("../lib/create-assets-url"),c=n("../lib/braintree-error"),d=n("./shared/errors"),u=n("./external/paypal"),p="3.140.0",h=n("@braintree/wrap-promise");function m(_){var b="PayPal";return a.verify({name:b,client:_.client,authorization:_.authorization}).then(function(){return o.create({authorization:_.authorization,client:_.client,debug:_.debug,assetsUrl:l.create(_.authorization),name:b})}).then(function(w){var C,O=w.getConfiguration();return _.client=w,O.gatewayConfiguration.paypalEnabled!==!0?Promise.reject(new c(d.PAYPAL_NOT_ENABLED)):(s.sendEvent(_.client,"paypal.initialized"),C=new u(_),C._initialize())})}function v(){return!0}i.exports={create:h(m),isSupported:v,VERSION:p}},{"../lib/analytics":144,"../lib/basic-component-verification":147,"../lib/braintree-error":149,"../lib/create-assets-url":153,"../lib/create-deferred-client":155,"./external/paypal":215,"./shared/errors":218,"@braintree/wrap-promise":43}],217:[function(n,i,r){i.exports={LANDING_FRAME_NAME:"braintreepaypallanding",FLOW_ENDPOINTS:{checkout:"create_payment_resource",vault:"setup_billing_agreement"},REQUIRED_OPTIONS:["paymentId","currency"],ENVIRONMENT:{stage:"https://www.msmaster.qa.paypal.com/sdk/js?",sandbox:"https://www.sandbox.paypal.com/sdk/js?",teBraintree:"https://www.braintree.stage.paypal.com/sdk/js?"}
125,BT_INTEGRATION_SOURCE:"BRAINTREE_WEB_SDK"}},{}],218:[function(n,i,r){var s=n("../../lib/braintree-error");i.exports={PAYPAL_NOT_ENABLED:{type:s.types.MERCHANT,code:"PAYPAL_NOT_ENABLED",message:"PayPal is not enabled for this merchant."},PAYPAL_TOKENIZATION_REQUEST_ACTIVE:{type:s.types.MERCHANT,code:"PAYPAL_TOKENIZATION_REQUEST_ACTIVE",message:"Another tokenization request is active."},PAYPAL_ACCOUNT_TOKENIZATION_FAILED:{type:s.types.NETWORK,code:"PAYPAL_ACCOUNT_TOKENIZATION_FAILED",message:"Could not tokenize user's PayPal account."},PAYPAL_FLOW_FAILED:{type:s.types.NETWORK,code:"PAYPAL_FLOW_FAILED",message:"Could not initialize PayPal flow."},PAYPAL_FLOW_OPTION_REQUIRED:{type:s.types.MERCHANT,code:"PAYPAL_FLOW_OPTION_REQUIRED",message:"PayPal flow property is invalid or missing."},PAYPAL_POPUP_OPEN_FAILED:{type:s.types.MERCHANT,code:"PAYPAL_POPUP_OPEN_FAILED",message:"PayPal popup failed to open, make sure to tokenize in response to a user action."},PAYPAL_POPUP_CLOSED:{type:s.types.CUSTOMER,code:"PAYPAL_POPUP_CLOSED",message:"Customer closed PayPal popup before authorizing."},PAYPAL_INVALID_PAYMENT_OPTION:{type:s.types.MERCHANT,code:"PAYPAL_INVALID_PAYMENT_OPTION",message:"PayPal payment options are invalid."}}},{"../../lib/braintree-error":149}],219:[function(n,i,r){var s=n("@braintree/wrap-promise"),a=n("../lib/basic-component-verification"),o=n("./preferred-payment-methods"),l="3.140.0";function c(d){var u="PreferredPaymentMethods";return a.verify({name:u,client:d.client,authorization:d.authorization}).then(function(){var p=new o;return p.initialize(d)})}i.exports={create:s(c),VERSION:l}},{"../lib/basic-component-verification":147,"./preferred-payment-methods":220,"@braintree/wrap-promise":43}],220:[function(n,i,r){var s=n("@braintree/wrap-promise"),a=n("../lib/analytics"),o=n("../lib/create-assets-url"),l=n("../lib/create-deferred-client");function c(){}c.prototype.initialize=function(d){var u=this;return this._clientPromise=l.create({authorization:d.authorization,client:d.client,debug:d.debug,assetsUrl:o.create(d.authorization),name:"PreferredPaymentMethods"}).catch(function(p){return u._setupError=p,Promise.reject(p)}),a.sendEvent(this._clientPromise,"preferred-payment-methods.initialized"),Promise.resolve(this)},c.prototype.fetchPreferredPaymentMethods=function(){var d,u=this;return this._clientPromise.then(function(p){return d=p,d.request({api:"graphQLApi",data:{query:"query PreferredPaymentMethods { preferredPaymentMethods { paypalPreferred venmoPreferred } }"}})}).then(function(p){var h=p.data.preferredPaymentMethods.paypalPreferred,m=p.data.preferredPaymentMethods.venmoPreferred;return a.sendEvent(d,"preferred-payment-methods.paypal.api-detected."+h),a.sendEvent(d,"preferred-payment-methods.venmo.api-detected."+m),{paypalPreferred:h,venmoPreferred:m}}).catch(function(){return u._setupError?Promise.reject(u._setupError):(a.sendEvent(d,"preferred-payment-methods.api-error"),{paypalPreferred:!1,venmoPreferred:!1})})},i.exports=s.wrapPrototype(c)},{"../lib/analytics":144,"../lib/create-assets-url":153,"../lib/create-deferred-client":155,"@braintree/wrap-promise":43}],221:[function(n,i,r){var s=n("../../lib/braintree-error"),a=n("../shared/errors"),o=n("../../lib/frame-service/external"),l=n("../../lib/analytics"),c=n("../../lib/use-min"),d=n("../shared/constants").BILLING_ADDRESS_OPTIONS,u=n("../../lib/snake-case-to-camel-case"),p=n("../../lib/assign").assign,h=400,m=570;function v(y,P){var A={sepa_debit:{account_holder_name:P.accountHolderName,billing_address:{country_code:P.countryCode},iban:P.iban,merchant_or_partner_customer_id:P.customerId,mandate_type:P.mandateType},locale:P.locale,cancel_url:P.cancelUrl,return_url:P.returnUrl,merchant_account_id:P.merchantAccountId};return P.billingAddress&&d.forEach(function(I){var L=u(I);L in P.billingAddress&&(A.sepa_debit.billing_address[I]=P.billingAddress[L])}),y.request({api:"clientApi",method:"post",endpoint:"sepa_debit",data:A}).then(function(I){var L=I.message.body.sepaDebitAccount;if(!L)throw new s(a.SEPA_CREATE_MANDATE_FAILED);return{approvalUrl:L.approvalUrl,last4:L.last4,bankReferenceToken:L.bankReferenceToken}}).catch(function(){throw new s(a.SEPA_CREATE_MANDATE_FAILED)})}function _(y,P){var A="sepadirectdebit",I=P.assetsUrl+"/html",L=P.debug||!1;return new Promise(function(D,z){var G=O();o.create({name:A,dispatchFrameUrl:I+"/dispatch-frame"+c(L)+".html",openFrameUrl:I+"/sepa-landing-frame"+c(L)+".html",top:G.top,left
125:G.left,height:m,width:h},function(ne){l.sendEvent(y,"sepa.popup.initialized"),ne.open({},function(W,ue){return w(ue)?(ne.close(),D()):C(ue,W)?(ne.close(),z(new s(a.SEPA_CUSTOMER_CANCELED))):(ne.close(),z(new s(a.SEPA_TOKENIZATION_FAILED)))}),ne.redirect(P.approvalUrl)})})}function b(y){window.location.href=y}function w(y){return y&&y.success}function C(y,P){return y&&y.cancel||P&&P.code==="FRAME_SERVICE_FRAME_CLOSED"}function O(){var y=Math.round((window.outerHeight-m)/2)+window.screenTop,P=Math.round((window.outerWidth-h)/2)+window.screenLeft;return{top:y,left:P}}function T(y,P){var A={sepa_debit_account:{last_4:P.last4,merchant_or_partner_customer_id:P.customerId,bank_reference_token:P.bankReferenceToken,mandate_type:P.mandateType},merchant_account_id:P.merchantAccountId};return y.request({api:"clientApi",method:"post",endpoint:"payment_methods/sepa_debit_accounts",data:A}).then(function(I){if(!I.nonce)throw new s(a.SEPA_TRANSACTION_FAILED);return{nonce:I.nonce,ibanLastFour:P.last4,customerId:P.customerId,mandateType:P.mandateType}}).catch(function(){throw new s(a.SEPA_TRANSACTION_FAILED)})}function E(y,P){return y.request({api:"clientApi",method:"get",endpoint:"sepa_debit/"+P.cart_id}).then(function(A){var I=A.sepaDebitMandateDetail;return l.sendEvent(y,"sepa.redirect.mandate.approved"),p(P,{last4:I.last4,customerId:I.merchantOrPartnerCustomerId,mandateType:I.mandateType,bankReferenceToken:I.bankReferenceToken}),T(y,P)}).then(function(A){return l.sendEvent(y,"sepa.redirect.tokenization.success"),A}).catch(function(){throw l.sendEvent(y,"sepa.redirect.handle-approval.failed"),new s(a.SEPA_TRANSACTION_FAILED)})}i.exports={createMandate:v,openPopup:_,handleApproval:T,POPUP_WIDTH:h,POPUP_HEIGHT:m,redirectPage:b,handleApprovalForFullPageRedirect:E}},{"../../lib/analytics":144,"../../lib/assign":146,"../../lib/braintree-error":149,"../../lib/frame-service/external":163,"../../lib/snake-case-to-camel-case":185,"../../lib/use-min":187,"../shared/constants":224,"../shared/errors":225}],222:[function(n,i,r){var s=n("@braintree/wrap-promise"),a=n("../../lib/braintree-error"),o=n("../shared/errors"),l=n("../shared/constants"),c=n("./mandate"),d=n("../../lib/has-missing-option"),u=n("../../lib/analytics"),p="3.140.0",h=n("../../lib/assign").assign;function m(v){var _=v.client.getConfiguration();this._client=v.client,this._assetsUrl=_.gatewayConfiguration.assetsUrl+"/web/"+p,this._isDebug=_.isDebug,v.redirectUrl?(this._returnUrl=v.redirectUrl,this._cancelUrl=v.redirectUrl+"?cancel=1",this._isRedirectFlow=!0):(this._returnUrl=this._assetsUrl+"/html/redirect-frame.html?success=1",this._cancelUrl=this._assetsUrl+"/html/redirect-frame.html?cancel=1"),v.tokenizePayload&&(this.tokenizePayload=v.tokenizePayload),u.sendEvent(this._client,"sepa.component.initialized")}m.prototype.tokenize=function(v){var _=this,b,w=h({cancelUrl:_._cancelUrl,returnUrl:_._returnUrl},v);return!v||d(v,l.REQUIRED_OPTIONS)?(u.sendEvent(_._client,"sepa.input-validation.missing-options"),Promise.reject(new a(o.SEPA_TOKENIZE_MISSING_REQUIRED_OPTION))):l.MANDATE_TYPE_ENUM.includes(v.mandateType)?(b=c.createMandate(_._client,w).then(function(C){return u.sendEvent(_._client,"sepa.create-mandate.success"),_._isRedirectFlow?c.redirectPage(C.approvalUrl):(v.last4=C.last4,v.bankReferenceToken=C.bankReferenceToken,c.openPopup(_._client,{approvalUrl:C.approvalUrl,assetsUrl:_._assetsUrl}))}),_._isRedirectFlow?Promise.resolve():b.then(function(){return u.sendEvent(_._client,"sepa.mandate.approved"),c.handleApproval(_._client,{bankReferenceToken:v.bankReferenceToken,last4:v.last4,customerId:v.customerId,mandateType:v.mandateType,merchantAccountId:v.merchantAccountId})}).then(function(C){return u.sendEvent(_._client,"sepa.tokenization.success"),Promise.resolve(C)}).catch(function(C){return u.sendEvent(_._client,"sepa."+C.details+".failed"),Promise.reject(C)})):(u.sendEvent(_._client,"sepa.input-validation.invalid-mandate"),Promise.reject(new a(o.SEPA_INVALID_MANDATE_TYPE)))},i.exports=s.wrapPrototype(m)},{"../../lib/analytics":144,"../../lib/assign":146,"../../lib/braintree-error":149,"../../lib/has-missing-option":174,"../shared/constants":224,"../shared/errors":225,"./mandate":221,"@braintree/wrap-promise":43}],223:[function(n,i,r){var s=n("../lib/analytics"),a=n("./external/sepa"),o=n("../lib/create-assets-url"),l=n("../lib/create-deferred-client"),c=n("../lib/basic-component-verification"),d=n("@braintree/wrap-promise"),u="3.140.0",p=n("../lib/querystring").parse,h=n("../lib/assign").assign,m=n("./external/mandate");function v(_){var b="SEPA",w=p(window.location.href);return c.verify({name:b,client:_.client,authorization:_.authorization}).then(function(){return l.create({authorization:_.authorization,client:_.client,debug:_.debug,assetsUrl:o.create(_.authorization),name:b})}).then(function(C){return _.client=C,s.sendEvent(C,"sepa.client.initialized"),new a(_)}).then(function(C){var O=w.success&&w.success==="true"&&w.cart_id;return O?(_=h(_,w),m.handleApprovalForFullPageRedirect(_.client,_).then(function(T){return C.tokenizePayload=T,C}).catch(function(T){console.error("Problem while finishing tokenizing: ",T)})):(w.cancel&&s.sendEvent(_.client,"sepa.redirect.customer-canceled.failed"),C)})}i.exports={create:d(v),VERSION:u}},{"../lib/analytics":144,"../lib/assign":146,"../lib/basic-component-verification":147,"../lib/create-assets-url":153,"../lib/create-deferred-client":155,"../lib/querystring":183,"./external/mandate":221,"./external/sepa":222,"@braintree/wrap-promise":43}],224:[function(n,i,r){i.exports={REQUIRED_OPTIONS:["iban","merchantAccountId","mandateType","customerId","accountHolderName","countryCode"],BILLING_ADDRESS_OPTIONS:["address_line_1","address_line_2","admin_area_1","admin_area_2","postal_code"],MANDATE_TYPE_ENUM:["ONE_OFF","RECURRENT"]}},{}],225:[function(n,i,r){var s=n("../../lib/braintree-error");i.exports={SEPA_CREATE_MANDATE_FAILED:{type:s.types.MERCHANT,code:"SEPA_CREATE_MANDATE_FAILED",message:"SEPA create mandate failed.",details:"create-mandate"},SEPA_CUSTOMER_CANCELED:{type:s.types.CUSTOMER,code:"SEPA_CUSTOMER_CANCELED",message:"User canceled SEPA authorization",details:"customer-canceled"},SEPA_INVALID_MANDATE_TYPE:{type:s.types.MERCHANT,code:"SEPA_INVALID_MANDATE_TYPE",message:"SEPA mandate type is invali
125d"},SEPA_TOKENIZATION_FAILED:{type:s.types.UNKNOWN,code:"SEPA_TOKENIZATION_FAILED",message:"SEPA encountered a problem",details:"open-popup"},SEPA_TOKENIZE_MISSING_REQUIRED_OPTION:{type:s.types.MERCHANT,code:"SEPA_TOKENIZE_MISSING_REQUIRED_OPTION",message:"Missing required option for tokenize."},SEPA_TRANSACTION_FAILED:{type:s.types.UNKNOWN,code:"SEPA_TRANSACTION_FAILED",message:"SEPA transaction failed",details:"handle-approval"}}},{"../../lib/braintree-error":149}],226:[function(n,i,r){var s=n("../../../lib/assign").assign,a=n("../../../lib/analytics"),o=n("../../../lib/braintree-error"),l=n("../../../lib/is-verified-domain"),c=n("@braintree/extended-promise"),d=n("@braintree/event-emitter"),u=n("../../shared/errors"),p=n("@braintree/iframer"),h=n("framebus"),m=n("../../shared/constants"),v=n("@braintree/uuid"),_=n("../../shared/events"),b=n("../../../lib/use-min"),w=n("../../../lib/constants").BUS_CONFIGURATION_REQUEST_EVENT,C="3.140.0",O=400,T=400;c.suppressUnhandledPromiseMessage=!0;function E(y){d.call(this),this._client=y.client,this._createPromise=y.createPromise,this._createOptions=y,this._client?(this._isDebug=this._client.getConfiguration().isDebug,this._assetsUrl=this._client.getConfiguration().gatewayConfiguration.assetsUrl):(this._isDebug=!!y.isDebug,this._assetsUrl=y.assetsUrl),this._assetsUrl=this._assetsUrl+"/web/"+C}d.createChild(E),E.prototype._waitForClient=function(){return this._client?Promise.resolve():this._createPromise.then((function(y){this._client=y}).bind(this))},E.prototype.setUpEventListeners=function(){throw new o(u.THREEDS_FRAMEWORK_METHOD_NOT_IMPLEMENTED)},E.prototype.verifyCard=function(y,P){var A,I,L=this;return P=P||{},I=this._checkForVerifyCardError(y,P),I?Promise.reject(I):(this._verifyCardInProgress=!0,A=this._formatVerifyCardOptions(y),this._formatLookupData(A).then(function(D){return a.sendEvent(L._createPromise,"three-d-secure.verification-flow.started"),L._performLookup(A.nonce,D)}).then(function(D){return a.sendEvent(L._createPromise,"three-d-secure.verification-flow.3ds-version."+D.lookup.threeDSecureVersion),L._onLookupComplete(D,A)}).then(function(D){return L.initializeChallengeWithLookupResponse(D,A)}).then(function(D){return L._resetVerificationState(),a.sendEvent(L._createPromise,"three-d-secure.verification-flow.completed"),D}).catch(function(D){return L._resetVerificationState(),a.sendEvent(L._createPromise,"three-d-secure.verification-flow.failed"),Promise.reject(D)}))},E.prototype._checkForFrameworkSpecificVerifyCardErrors=function(){throw new o(u.THREEDS_FRAMEWORK_METHOD_NOT_IMPLEMENTED)},E.prototype._presentChallenge=function(){throw new o(u.THREEDS_FRAMEWORK_METHOD_NOT_IMPLEMENTED)},E.prototype.prepareLookup=function(){throw new o(u.THREEDS_FRAMEWORK_METHOD_NOT_IMPLEMENTED)},E.prototype._resetVerificationState=function(){this._verifyCardInProgress=!1,this._verifyCardPromisePlus=null,typeof this._reloadThreeDSecure=="function"&&this._reloadThreeDSecure()},E.prototype._performLookup=function(y,P){var A=this,I="payment_methods/"+y+"/three_d_secure/lookup";return this._waitForClient().then(function(){return A._client.request({endpoint:I,method:"post",data:P}).catch(function(L){var D=L&&L.details&&L.details.httpStatus,z="three-d-secure.verification-flow.lookup-failed",G;return D===404?(G=u.THREEDS_LOOKUP_TOKENIZED_CARD_NOT_FOUND_ERROR,z+=".404"):D===422?(G=u.THREEDS_LOOKUP_VALIDATION_ERROR,z+=".422"):G=u.THREEDS_LOOKUP_ERROR,a.sendEvent(A._createPromise,z),Promise.reject(new o({type:G.type,code:G.code,message:G.message,details:{originalError:L}}))})})},E.prototype._existsAndIsNumeric=function(y){return!(y==null||Array.isArray(y)||typeof y=="boolean"||typeof y=="string"&&y.trim()===""||isNaN(Number(y)))},E.prototype._checkForVerifyCardError=function(y,P){var A;return this._verifyCardInProgress===!0?new o(u.THREEDS_AUTHENTICATION_IN_PROGRESS):(y.nonce?this._existsAndIsNumeric(y.amount)||(A="an amount"):A="a nonce",A||(A=this._checkForFrameworkSpecificVerifyCardErrors(y,P)),A?new o({type:u.THREEDS_MISSING_VERIFY_CARD_OPTION.type,code:u.THREEDS_MISSING_VERIFY_CARD_OPTION.code,message:"verifyCard o
125ptions must include "+A+"."}):null)},E.prototype.initializeChallengeWithLookupResponse=function(y,P){var A=this;return P=P||{},this._lookupPaymentMethod=y.paymentMethod,A._verifyCardPromisePlus=A._verifyCardPromisePlus||new c,A._handleLookupResponse(y,P),A._verifyCardPromisePlus.then(function(I){return a.sendEvent(A._createPromise,"three-d-secure.verification-flow.liability-shifted."+String(I.liabilityShifted)),a.sendEvent(A._createPromise,"three-d-secure.verification-flow.liability-shift-possible."+String(I.liabilityShiftPossible)),I})},E.prototype._handleLookupResponse=function(y,P){var A=!!(y.lookup&&y.lookup.acsUrl),I;a.sendEvent(this._createPromise,"three-d-secure.verification-flow.challenge-presented."+String(A)),A?this._presentChallenge(y,P):(I=this._formatAuthResponse(y.paymentMethod,y.threeDSecureInfo),I.verificationDetails=y.threeDSecureInfo,this._verifyCardPromisePlus.resolve(I))},E.prototype._onLookupComplete=function(y){return this._lookupPaymentMethod=y.paymentMethod,this._verifyCardPromisePlus=new c,Promise.resolve(y)},E.prototype._formatAuthResponse=function(y,P){return{nonce:y.nonce,type:y.type,binData:y.binData,details:y.details,description:y.description&&y.description.replace(/\+/g," "),liabilityShifted:P&&P.liabilityShifted,liabilityShiftPossible:P&&P.liabilityShiftPossible,threeDSecureInfo:y.threeDSecureInfo}},E.prototype._formatVerifyCardOptions=function(y){return s({},y)},E.prototype._formatLookupData=function(y){var P={amount:y.amount};return y.collectDeviceData===!0&&(P.browserColorDepth=window.screen.colorDepth,P.browserJavaEnabled=window.navigator.javaEnabled(),P.browserJavascriptEnabled=!0,P.browserLanguage=window.navigator.language,P.browserScreenHeight=window.screen.height,P.browserScreenWidth=window.screen.width,P.browserTimeZone=new Date().getTimezoneOffset(),P.deviceChannel="Browser"),Promise.resolve(P)},E.prototype._handleV1AuthResponse=function(y){var P=JSON.parse(y.auth_response);P.success?this._verifyCardPromisePlus.resolve(this._formatAuthResponse(P.paymentMethod,P.threeDSecureInfo)):P.threeDSecureInfo&&P.threeDSecureInfo.liabilityShiftPossible?this._verifyCardPromisePlus.resolve(this._formatAuthResponse(this._lookupPaymentMethod,P.threeDSecureInfo)):this._verifyCardPromisePlus.reject(new o({type:o.types.UNKNOWN,code:"UNKNOWN_AUTH_RESPONSE",message:P.error.message}))},E.prototype.cancelVerifyCard=function(){var y,P;return this._verifyCardInProgress=!1,this._lookupPaymentMethod?(P=this._lookupPaymentMethod.threeDSecureInfo,y=s({},this._lookupPaymentMethod,{liabilityShiftPossible:P&&P.liabilityShiftPossible,liabilityShifted:P&&P.liabilityShifted,verificationDetails:P&&P.verificationDetails}),Promise.resolve(y)):Promise.reject(new o(u.THREEDS_NO_VERIFICATION_PAYLOAD))},E.prototype._setupV1Bus=function(y){var P=this._client.getConfiguration(),A=window.location.href.split("#")[0],I=y.lookupResponse,L=v(),D=new h({channel:L,verifyDomain:l}),z=this._assetsUrl+"/html/three-d-secure-authentication-complete-frame.html?channel="+encodeURIComponent(L)+"&";return D.on(w,function(G){G({clientConfiguration:P,nonce:y.nonce,acsUrl:I.acsUrl,pareq:I.pareq,termUrl:I.termUrl+"&three_d_secure_version="+C+"&authentication_complete_base_url="+encodeURIComponent(z),md:I.md,parentUrl:A})}),D.on(_.AUTHENTICATION_COMPLETE,y.handleAuthResponse),D},E.prototype._setupV1Iframe=function(y){var P=this._assetsUrl+"/html/three-d-secure-bank-frame"+b(this._isDebug)+".html?showLoader="+y.showLoader,A=p({src:P,height:O,width:T,name:m.LANDING_FRAME_NAME+"_"+this._v1Bus.channel,title:"3D Secure Authorization Frame"});return A},E.prototype._setupV1Elements=function(y){this._v1Bus=this._setupV1Bus(y),this._v1Iframe=this._setupV1Iframe(y)},E.prototype._teardownV1Elements=function(){this._v1Bus&&(this._v1Bus.teardown(),this._v1Bus=null),this._v1Iframe&&this._v1Iframe.parentNode&&(this._v1Iframe.parentNode.removeChild(this._v1Iframe),this._v1Iframe=null),this._onV1Keyup&&(document.removeEventListener("keyup",this._onV1Keyup),this._onV1Keyup=null)},E.prototype.teardown=function(){return a.sendEvent(this._createPromise,"three-d-secure.teardown-completed"),this._teardownV1Elements(),Promise.resolve()},i.exports=E},{"../../../lib/analytics":144,"../../../lib/assign":146,"../../../lib/braintree-error":149,"../../../lib/constants":150,"../../../lib/is-verified-domain":179,"../../../lib/use-min":187,"../../shared/constants":234,"../../shared/errors":235,"../../shared/events":236,"@braintree/event-emitter":33,"@braintree/extended-promise":34,"@braintree/iframer":35,"@braintree/uuid":39,framebus:54}],227:[function(n,i,r){var s=n("./songbird");function a(o){s.call(this,o)}a.prototype=Object.create(s.prototype,{constructor:s}),a.prototype._createV1IframeModalElement=function(o){var l=document.createElement("div");return l.innerHTML='<div class="modal fade in" tabindex="-1" role="dialog" aria-labelledby="CCAFrameModal-label" aria-hidden="true" style="display: block;"><div class="modal-dialog" style="width:440px;z-index:999999;"><div class="modal-content"><div class="modal-body" data-braintree-v1-fallback-iframe-container><button type="button" data-braintree-v1-fallback-close-button class="close" data-dismiss="modal" aria-hidden="true">×</button></div></div></div><div data-braintree-v1-fallback-backdrop style="position: fixed;cursor: pointer;z-index: 999998;top: 0;left: 0;width: 100%;height: 100%;"></div></div>',l.querySelector("[data-braintree-v1-fallback-iframe-container]").appendChild(o),l},a.prototype._createCardinalConfigurationOptions=function(o){var l=s.prototype._createCardinalConfigurationOptions.call(this,o);return l.payment.framework="bootstrap3",l},i.exports=a},{"./songbird":231}],228:[function(n,i,r){var s=n("./songbird");function a(o){s.call(this,o)}a.prototype=Object.create(s.prototype,{constructor:s}),a.prototype._createV1IframeModalElement=function(o){var l=document.createElement("div"),c=!!(this._createOptions&&this._createOptions.cardinalSDKConfig&&this._createOptions.cardinalSDKConfig.payment&&this._createOptions.cardinalSDKConfig.payment.displayExitButton);return l.innerHTML=`<div style="position: fixed;z-index: 999999;top: 50%;left: 50%;padding: 24px 20px;transform: translate(-50%,-50%);border-radius: 2px;background: #fff;max-width: 100%;overflow: auto;"><div><button data-braintree-v1-fallback-close-button style="font-family: Helvetica,Arial,sans-serif;font-size: 25px;line-height: 12px;position: absolute;top: 2px;right: 0px;cursor: pointer;color: #999;border: 0;outline: none;background: none;" onMouseOver="this.style.color='#000'" onMouseOut="this.style.color='#999'">×</button></div><div data-braintree-v1-fallback-iframe-container style="height: 400px;"></div></div><div data-braintree-v1-fallback-backdrop style="position: fixed;z-index: 999998;cursor: pointer;top: 0;left: 0;width: 100%;height: 100%;transition: opacity 1ms ease;background: rgba(0,0,0,.6);"></div>`,c||(l.querySelector("[data-braintree-v1-fallback-close-button]").style.display="none"),l.querySelector("[data-braintree-v1-fallback-iframe-container]").appendChild(o),l},i.exports=a},{"./songbird":231}],229:[function(n,i,r){var s=n("./cardinal-modal"),a=n("./bootstrap3-modal"),o=n("./inline-iframe");i.exports={"cardinal-modal":s,"bootstrap3-modal":a,"inline-iframe":o}},{"./bootstrap3-modal":227,"./cardinal-modal":228,"./inline-iframe":230}],230:[function(n,i,r){var s=n("./songbird"),a=n("../../../lib/braintree-error"),o=n("../../shared/errors"),l=n("../../../lib/enumerate");function c(d){s.call(this,d)}c.prototype=Object.create(s.prototype,{constructor:s}),c.events=l(["AUTHENTICATION_IFRAME_AVAILABLE"],"inline-iframe-framework:"),c.prototype.setUpEventListeners=function(d){s.prototype.setUpEventListeners.call(this,d),this.on(c.events.AUTHENTICATION_IFRAME_AVAILABLE,function(u,p){d("authentication-iframe-available",u,p)})},c.prototype._createCardinalConfigurationOptions=function(d){var u=s.prototype._createCardinalConfigurationOptions.call(this,d);return u.payment.framework="inline",u},c.prototype._addV1IframeToPage=function(){this._emit(c.events.AUTHENTICATION_IFRAME_AVAILABLE,{element:this._v1Modal},function(){})},c.prototype._setupFrameworkSpecificListeners=function(){this.setCardinalListener("ui.inline.setup",this._onInlineSetup.bind(this))},c.prototype._onInlineSetup=function(d,u,p,h){var m,v;
125if(!d||!u||u.paymentType!=="CCA"?v=!0:u.data.mode==="suppress"||u.data.mode==="static"||(v=!0),v){h(new a(o.THREEDS_INLINE_IFRAME_DETAILS_INCORRECT));return}m=document.createElement("div"),m.innerHTML=d,u.data.mode==="suppress"?(m.style.display="none",document.body.appendChild(m),p()):u.data.mode==="static"&&this._emit(c.events.AUTHENTICATION_IFRAME_AVAILABLE,{element:m},function(){p()})},i.exports=c},{"../../../lib/braintree-error":149,"../../../lib/enumerate":158,"../../shared/errors":235,"./songbird":231}],231:[function(n,i,r){var s=n("./base"),a=n("../../../lib/assign").assign,o=n("../../../lib/deferred"),l=n("../../../lib/braintree-error"),c=n("../../../lib/convert-to-braintree-error"),d=n("../../../lib/analytics"),u=n("../../../lib/assets"),p=n("../../shared/errors"),h=n("../../../lib/enumerate"),m=n("@braintree/extended-promise"),v=n("../../../lib/constants").INTEGRATION_TIMEOUT_MS,_=n("../../../lib/constants").PLATFORM,b="3.140.0",w="01",C=["ui.close","ui.render","ui.renderHidden","ui.loading.close","ui.loading.render"],O=["low_value","transaction_risk_analysis"];m.suppressUnhandledPromiseMessage=!0;function T(y){s.call(this,y),this._songbirdInitFailed=!1,this._clientMetadata={requestedThreeDSecureVersion:"2",sdkVersion:_+"/"+b},this.originalSetupOptions=y,this._getDfReferenceIdPromisePlus=new m,this.setupSongbird(y),this._cardinalEvents=[]}T.prototype=Object.create(s.prototype,{constructor:T}),T.events=h(["LOOKUP_COMPLETE","CUSTOMER_CANCELED","UI.CLOSE","UI.RENDER","UI.RENDERHIDDEN","UI.LOADING.CLOSE","UI.LOADING.RENDER"],"songbird-framework:"),T.prototype.setUpEventListeners=function(y){this.on(T.events.LOOKUP_COMPLETE,function(P,A){y("lookup-complete",P,A)}),this.on(T.events.CUSTOMER_CANCELED,function(){y("customer-canceled")}),this.on(T.events["UI.CLOSE"],function(){y("authentication-modal-close")}),this.on(T.events["UI.RENDER"],function(){y("authentication-modal-render")}),this.on(T.events["UI.RENDERHIDDEN"],function(){y("authentication-modal-render-hidden")}),this.on(T.events["UI.LOADING.CLOSE"],function(){y("authentication-modal-loader-close")}),this.on(T.events["UI.LOADING.RENDER"],function(){y("authentication-modal-loader-render")})},T.prototype.prepareLookup=function(y){var P=a({},y),A=this;return this.getDfReferenceId().then(function(I){P.dfReferenceId=I}).then(function(){return A._triggerCardinalBinProcess(y.bin)}).catch(function(){}).then(function(){return A._waitForClient()}).then(function(){return P.clientMetadata=A._clientMetadata,P.authorizationFingerprint=A._client.getConfiguration().authorizationFingerprint,P.braintreeLibraryVersion="braintree/web/"+b,P})},T.prototype.initializeChallengeWithLookupResponse=function(y,P){return this.setupSongbird().then((function(){return s.prototype.initializeChallengeWithLookupResponse.call(this,y,P)}).bind(this))},T.prototype.handleSongbirdError=function(y){this._songbirdInitFailed=!0,this._removeSongbirdListeners(),d.sendEvent(this._createPromise,"three-d-secure.cardinal-sdk.songbird-error."+y),this._songbirdPromise&&this._songbirdPromise.resolve()},T.prototype._triggerCardinalBinProcess=function(y){var P=this,A=Date.now();return window.Cardinal.trigger("bin.process",y).then(function(I){P._clientMetadata.issuerDeviceDataCollectionTimeElapsed=Date.now()-A,P._clientMetadata.issuerDeviceDataCollectionResult=I&&I.Status})},T.prototype.transformBillingAddress=function(y,P){return P&&(E(P,y,"billing"),y.billingPhoneNumber=P.phoneNumber,y.billingGivenName=P.givenName,y.billingSurname=P.surname),y},T.prototype.transformShippingAddress=function(y){var P=y.shippingAddress;return P&&(E(P,y,"shipping"),delete y.shippingAddress),y},T.prototype._createV1IframeModalElement=function(y){var P=document.createElement("div");return P.innerHTML='<div data-braintree-v1-fallback-iframe-container="true" style="height: 400px;"></div>',P.querySelector('[data-braintree-v1-fallback-iframe-container="true"]').appendChild(y),P},T.prototype._createV1IframeModal=function(y){var P=this._createV1IframeModalElement(y),A=P.querySelector("[data-braintree-v1-fallback-close-button]"),I=P.querySelector("[data-braintree-v1-fallback-backdrop]"),L=this;function D(){P.parentNode.removeChild(P),L.cancelVerifyCard(p.THREEDS_CARDINAL_SDK_CANCELED),document.removeEventListener("keyup",L._onV1Keyup),L._onV1Keyup=null}return this._onV1Keyup=function(z){z.key==="Escape"&&P.parentNode&&D()},A&&A.addEventListener("click",D),I&&I.addEventListener("click",D),document.addEventListener("keyup",this._onV1Keyup),P},T.prototype._addV1IframeToPage=function(){document.body.appendChild(this._v1Modal)},T.prototype.setupSongbird=function(y){var P=this,A=Date.now();return this._songbirdPromise?this._songbirdPromise:(y=y||{},this._songbirdPromise=new m,this._v2SetupFailureReason="reason-unknown",P._loadCardinalScript(y).then(function(){return window.Cardinal?P._configureCardinalSdk({setupOptions:y,setupStartTime:A}):(P._v2SetupFailureReason="cardinal-global-unavailable",Promise.reject(new l(p.THREEDS_CARDINAL_SDK_SETUP_FAILED)))}).catch(function(I){var L=c(I,{type:p.THREEDS_CARDINAL_SDK_SETUP_FAILED.type,code:p.THREEDS_CARDINAL_SDK_SETUP_FAILED.code,message:p.THREEDS_CARDINAL_SDK_SETUP_FAILED.message});P._getDfReferenceIdPromisePlus.reject(L),window.clearTimeout(P._songbirdSetupTimeoutReference),d.sendEvent(P._client,"three-d-secure.cardinal-sdk.init.setup-failed"),P.handleSongbirdError("cardinal-sdk-setup-failed."+P._v2SetupFailureReason)}),this._songbirdPromise)},T.prototype._configureCardinalSdk=function(y){var P=this;return this._waitForClient().then(function(){var A=P._client.getConfiguration().gatewayConfiguration.threeDSecure;return A}).then(function(A){var I=A.cardinalAuthenticationJWT,L=y.setupOptions,D=y.setupStartTime,z=P._createCardinalConfigurationOptions(L);
125C.forEach(function(G){P.setCardinalListener(G,function(){P._emit(T.events[G.toUpperCase()])})}),P.setCardinalListener("payments.setupComplete",P._createPaymentsSetupCompleteCallback()),P._setupFrameworkSpecificListeners(),window.Cardinal.configure(z),window.Cardinal.setup("init",{jwt:I}),P._clientMetadata.cardinalDeviceDataCollectionTimeElapsed=Date.now()-D,P.setCardinalListener("payments.validated",P._createPaymentsValidatedCallback())}).catch(function(A){return P._v2SetupFailureReason="cardinal-configuration-threw-error",Promise.reject(A)})},T.prototype.setCardinalListener=function(y,P){this._cardinalEvents.push(y),window.Cardinal.on(y,P)},T.prototype._setupFrameworkSpecificListeners=function(){},T.prototype._createCardinalConfigurationOptions=function(y){var P=y.cardinalSDKConfig||{},A=P.payment||{};return!P.logging&&y.loggingEnabled&&(P.logging={level:"verbose"}),P.payment={},A.hasOwnProperty("displayLoading")&&(P.payment.displayLoading=A.displayLoading),A.hasOwnProperty("displayExitButton")&&(P.payment.displayExitButton=A.displayExitButton),P},T.prototype._loadCardinalScript=function(y){var P=this,A={},I;return this._waitForClient().then(function(){return A.src=P._client.getConfiguration().gatewayConfiguration.threeDSecure.cardinalSongbirdUrl,I=P._client.getConfiguration().gatewayConfiguration.threeDSecure.cardinalSongbirdIdentityHash,I&&(A.crossorigin="anonymous",A.integrity=I),P._songbirdSetupTimeoutReference=window.setTimeout(function(){d.sendEvent(P._client,"three-d-secure.cardinal-sdk.init.setup-timeout"),P.handleSongbirdError("cardinal-sdk-setup-timeout")},y.timeout||v),u.loadScript(A)}).catch(function(L){return P._v2SetupFailureReason="songbird-js-failed-to-load",Promise.reject(c(L,p.THREEDS_CARDINAL_SDK_SCRIPT_LOAD_FAILED))})},T.prototype._createPaymentsSetupCompleteCallback=function(){var y=this;return function(P){y._getDfReferenceIdPromisePlus.resolve(P.sessionId),window.clearTimeout(y._songbirdSetupTimeoutReference),d.sendEvent(y._createPromise,"three-d-secure.cardinal-sdk.init.setup-completed"),y._songbirdPromise.resolve()}},T.prototype.getDfReferenceId=function(){return this._getDfReferenceIdPromisePlus},T.prototype._performJWTValidation=function(y,P){var A=this,I=this._lookupPaymentMethod.nonce,L="payment_methods/"+I+"/three_d_secure/authenticate_from_jwt",D=y&&y.Payment&&y.Payment.ExtendedData&&y.Payment.ExtendedData.ChallengeCancel;return D&&(d.sendEvent(this._createPromise,"three-d-secure.verification-flow.cardinal-sdk.cancel-code."+D),D===w&&this._emit(T.events.CUSTOMER_CANCELED)),d.sendEvent(this._createPromise,"three-d-secure.verification-flow.upgrade-payment-method.started"),this._waitForClient().then(function(){return A._client.request({method:"post",endpoint:L,data:{jwt:P,paymentMethodNonce:I}})}).then(function(z){var G=z.paymentMethod||A._lookupPaymentMethod,ne=A._formatAuthResponse(G,z.threeDSecureInfo);return ne.rawCardinalSDKVerificationData=y,d.sendEvent(A._client,"three-d-secure.verification-flow.upgrade-payment-method.succeeded"),Promise.resolve(ne)}).catch(function(z){var G=new l({type:p.THREEDS_JWT_AUTHENTICATION_FAILED.type,code:p.THREEDS_JWT_AUTHENTICATION_FAILED.code,message:p.THREEDS_JWT_AUTHENTICATION_FAILED.message,details:{originalError:z}});return d.sendEvent(A._client,"three-d-secure.verification-flow.upgrade-payment-method.errored"),Promise.reject(G)})},T.prototype._createPaymentsValidatedCallback=function(){var y=this;return function(P,A){var I;if(d.sendEvent(y._createPromise,"three-d-secure.verification-flow.cardinal-sdk.action-code."+P.ActionCode.toLowerCase()),!y._verifyCardPromisePlus){y.handleSongbirdError("cardinal-sdk-setup-error.number-"+P.ErrorNumber);return}switch(P.ActionCode){case"SUCCESS":case"NOACTION":case"FAILURE":y._performJWTValidation(P,A).then(function(L){y._verifyCardPromisePlus.resolve(L)}).catch(function(L){y._verifyCardPromisePlus.reject(L)});break;case"ERROR":switch(d.sendEvent(y._createPromise,"three-d-secure.verification-flow.cardinal-sdk-error."+P.ErrorNumber),P.ErrorNumber){case 10001:case 10002:I=new l(p.THREEDS_CARDINAL_SDK_SETUP_TIMEDOUT);break;case 10003:case 10007:case 10009:I=new l(p.THREEDS_CARDINAL_SDK_RESPONSE_TIMEDOUT);break;case 10005:case 10006:I=new l(p.THREEDS_CARDINAL_SDK_BAD_CONFIG);break;
125case 10008:case 10010:I=new l(p.THREEDS_CARDINAL_SDK_BAD_JWT);break;case 10011:d.sendEvent(y._createPromise,"three-d-secure.verification-flow.canceled"),I=new l(p.THREEDS_CARDINAL_SDK_CANCELED);break;default:I=new l(p.THREEDS_CARDINAL_SDK_ERROR)}I.details={originalError:{code:P.ErrorNumber,description:P.ErrorDescription}},y._verifyCardPromisePlus.reject(I);break}}},T.prototype._checkForVerifyCardError=function(y,P){return y.bin?s.prototype._checkForVerifyCardError.call(this,y,P):new l({type:p.THREEDS_MISSING_VERIFY_CARD_OPTION.type,code:p.THREEDS_MISSING_VERIFY_CARD_OPTION.code,message:"verifyCard options must include a BIN."})},T.prototype._checkForFrameworkSpecificVerifyCardErrors=function(y,P){var A;return typeof y.onLookupComplete!="function"&&!P.ignoreOnLookupCompleteRequirement&&(A="an onLookupComplete function"),A},T.prototype._formatVerifyCardOptions=function(y){var P=s.prototype._formatVerifyCardOptions.call(this,y),A=P.additionalInformation||{};return A=this.transformBillingAddress(A,y.billingAddress),A=this.transformShippingAddress(A),y.onLookupComplete&&(P.onLookupComplete=o(y.onLookupComplete)),y.email&&(A.email=y.email),y.mobilePhoneNumber&&(A.mobilePhoneNumber=y.mobilePhoneNumber),P.additionalInformation=A,P},T.prototype._onLookupComplete=function(y,P){var A=this;return s.prototype._onLookupComplete.call(this,y).then(function(I){return new Promise(function(L,D){I.requiresUserAuthentication=!!(I.lookup&&I.lookup.acsUrl);function z(){L(I)}A._verifyCardPromisePlus.catch(D),P.onLookupComplete?P.onLookupComplete(I,z):A._emit(T.events.LOOKUP_COMPLETE,I,z)})})},T.prototype._presentChallenge=function(y){this._songbirdInitFailed||!y.lookup.transactionId||window.Cardinal.continue("cca",{AcsUrl:y.lookup.acsUrl,Payload:y.lookup.pareq},{OrderDetails:{TransactionId:y.lookup.transactionId}})},T.prototype._formatLookupData=function(y){var P=this;return s.prototype._formatLookupData.call(this,y).then(function(A){if(A.additionalInfo=y.additionalInformation,y.accountType&&(A.accountType=y.accountType),y.challengeRequested&&(A.challengeRequested=y.challengeRequested),y.requestedExemptionType){if(!O.includes(y.requestedExemptionType))throw new l({code:p.THREEDS_REQUESTED_EXEMPTION_TYPE_INVALID.code,type:p.THREEDS_REQUESTED_EXEMPTION_TYPE_INVALID.type,message:"requestedExemptionType `"+y.requestedExemptionType+"` is not a valid exemption. The accepted values are: `"+O.join("`, `")+"`"});A.requestedExemptionType=y.requestedExemptionType}return y.customFields&&(A.customFields=y.customFields),y.dataOnlyRequested&&(A.dataOnlyRequested=y.dataOnlyRequested),y.exemptionRequested&&(A.exemptionRequested=y.exemptionRequested),y.requestVisaDAF&&(A.requestVisaDAF=y.requestVisaDAF),y.bin&&(A.bin=y.bin),y.cardAdd!=null&&(A.cardAdd=y.cardAdd),y.cardAddChallengeRequested!=null&&(A.cardAdd=y.cardAddChallengeRequested),y.merchantName&&(A.merchantName=y.merchantName),P.prepareLookup(A)})},T.prototype.cancelVerifyCard=function(y){var P=this;return s.prototype.cancelVerifyCard.call(this).then(function(A){return P._verifyCardPromisePlus&&(y=y||new l(p.THREEDS_VERIFY_CARD_CANCELED_BY_MERCHANT),P._verifyCardPromisePlus.reject(y)),A})},T.prototype._removeSongbirdListeners=function(){this._cardinalEvents.forEach(function(y){window.Cardinal.off(y)}),this._cardinalEvents=[]},T.prototype.teardown=function(){return window.Cardinal&&this._removeSongbirdListeners(),s.prototype.teardown.call(this)},T.prototype._reloadThreeDSecure=function(){var y=this,P=Date.now();return y.teardown().then(function(){y._configureCardinalSdk({setupOptions:y.originalSetupOptions,setupStartTime:P})})};function E(y,P,A){P[A+"Line1"]=y.streetAddress,P[A+"Line2"]=y.extendedAddress,P[A+"Line3"]=y.line3,P[A+"City"]=y.locality,P[A+"State"]=y.region,P[A+"PostalCode"]=y.postalCode,P[A+"CountryCode"]=y.countryCodeAlpha2}i.exports=T},{"../../../lib/analytics":144,"../../../lib/assets":145,"../../../lib/assign":146,"../../../lib/braintree-error":149,"../../../lib/constants":150,"../../../lib/convert-to-braintree-error":152,"../../../lib/deferred":156,"../../../lib/enumerate":158,"../../shared/errors":235,"./base":226,"@braintree/extended-promise":34}],232:[function(n,i,r){var s=n("@braintree/wrap-promise"),a=n("../../lib/methods"),o=n("../../lib/convert-methods-to-error"),l=n("@braintree/event-emitter"),c=n("./frameworks");function d(u){var p=this,h=c[u.framework];l.call(this),this._framework=new h(u),this._framework.setUpEventListeners(function(){p._emit.apply(p,arguments)})}l.createChild(d),d.prototype.verifyCard=function(u){var p;return this.hasListener("lookup-complete")&&(p={ignoreOnLookupCompleteRequirement:!0}),this._framework.verifyCard(u,p)},d.prototype.initializeChallengeWithLookupResponse=function(u){return typeof u=="string"&&(u=JSON.parse(u)),this._framework.initializeChallengeWithLookupResponse(u)},d.prototype.prepareLookup=function(u){return this._framework.prepareLookup(u).then(function(p){return JSON.stringify(p)})},d.prototype.cancelVerifyCard=function(){return this._framework.cancelVerifyCard()},d.prototype.teardown=function(){var u=a(d.prototype).concat(a(l.prototype));return o(this,u),this._framework.teardown()},i.exports=s.wrapPrototype(d)},{"../../lib/convert-methods-to-error":151,"../../lib/methods":181,"./frameworks":229,"@braintree/event-emitter":33,"@braintree/wrap-promise":43}],233:[function(n,i,r){var s=n("./external/three-d-secure"),a=n("../lib/is-https").isHTTPS,o=n("../lib/basic-component-verification"),l=n("../lib/create-deferred-client"),c=n("../lib/create-assets-url"),d=n("../lib/braintree-error"),u=n("../lib/analytics"),p=n("./shared/errors"),h="3.140.0",m=n("@braintree/wrap-promise");function v(b){var w="3D Secure",C=_(b);return o.verify({name:w,client:b.client,authorization:b.authorization}).then(function(){var O=c.create(b.authorization),T=l.create({authorization:b.authorization,client:b.client,debug:b.debug,assetsUrl:O,name:w}).then(function(y){var P,A,I=y.getConfiguration(),L=I.gatewayConfiguration;return b.client=y,L.threeDSecureEnabled||(P=p.THREEDS_NOT_ENABLED),I.authorizationType==="TOKENIZATION_KEY"&&(P=p.THREEDS_CAN_NOT_USE_TOKENIZATION_KEY),A=L.environment==="production",A&&!a()&&(P=p.THREEDS_HTTPS_REQUIRED),L.threeDSecure&&L.threeDSecure.cardinalAuthenticationJWT||(u.sendEvent(b.client,"three-d-secure.initialization.failed.missing-cardinalAuthenticationJWT"),P=p.THREEDS_NOT_ENABLED_FOR_V2),P?Promise.reject(new d(P)):(u.sendEvent(b.client,"three-d-secure.initialized"),y)}),E=new s({client:b.client,assetsUrl:O,createPromise:T,loggingEnabled:b.loggingEnabled,cardinalSDKConfig:b.cardinalSDKConfig,framework:C});return b.client?T.then(function(){return E}):E})}function _(b){var w=String(b.version||"");if(!w||w==="1")throw new d({code:p.THREEDS_UNSUPPORTED_VERSION.code,type:p.THREEDS_UNSUPPORTED_VERSION.type,message:p.THREEDS_UNSUPPORTED_VERSION.message});switch(w){case"2":case"2-cardinal-modal":return"cardinal-modal";case"2-bootstrap3-modal":return"bootstrap3-modal";case"2-inline-iframe":return"inline-iframe";default:throw new d({code:p.THREEDS_UNRECOGNIZED_VERSION.code,type:p.THREEDS_UNRECOGNIZED_VERSION.type,message:"Version `"+b.version+"` is not a recognized ver
125sion. You may need to update the version of your Braintree SDK to support this version."})}}i.exports={create:m(v),VERSION:h}},{"../lib/analytics":144,"../lib/basic-component-verification":147,"../lib/braintree-error":149,"../lib/create-assets-url":153,"../lib/create-deferred-client":155,"../lib/is-https":178,"./external/three-d-secure":232,"./shared/errors":235,"@braintree/wrap-promise":43}],234:[function(n,i,r){i.exports={LANDING_FRAME_NAME:"braintreethreedsecurelanding"}},{}],235:[function(n,i,r){var s=n("../../lib/braintree-error");i.exports={THREEDS_NOT_ENABLED:{type:s.types.MERCHANT,code:"THREEDS_NOT_ENABLED",message:"3D Secure is not enabled for this merchant."},THREEDS_CAN_NOT_USE_TOKENIZATION_KEY:{type:s.types.MERCHANT,code:"THREEDS_CAN_NOT_USE_TOKENIZATION_KEY",message:"3D Secure can not use a tokenization key for authorization."},THREEDS_HTTPS_REQUIRED:{type:s.types.MERCHANT,code:"THREEDS_HTTPS_REQUIRED",message:"3D Secure requires HTTPS."},THREEDS_NOT_ENABLED_FOR_V2:{type:s.types.MERCHANT,code:"THREEDS_NOT_ENABLED_FOR_V2",message:"3D Secure version 2 is not enabled for this merchant. Contact Braintree Support for assistance at https://help.braintreepayments.com/"},THREEDS_UNRECOGNIZED_VERSION:{type:s.types.MERCHANT,code:"THREEDS_UNRECOGNIZED_VERSION"},THREEDS_CARDINAL_SDK_SETUP_FAILED:{type:s.types.UNKNOWN,code:"THREEDS_CARDINAL_SDK_SETUP_FAILED",message:"Something went wrong setting up Cardinal's Songbird.js library."},THREEDS_CARDINAL_SDK_SCRIPT_LOAD_FAILED:{type:s.types.NETWORK,code:"THREEDS_CARDINAL_SDK_SCRIPT_LOAD_FAILED",message:"Cardinal's Songbird.js library could not be loaded."},THREEDS_CARDINAL_SDK_SETUP_TIMEDOUT:{type:s.types.UNKNOWN,code:"THREEDS_CARDINAL_SDK_SETUP_TIMEDOUT",message:"Cardinal's Songbird.js took too long to setup."},THREEDS_CARDINAL_SDK_RESPONSE_TIMEDOUT:{type:s.types.UNKNOWN,code:"THREEDS_CARDINAL_SDK_RESPONSE_TIMEDOUT",message:"Cardinal's API took too long to respond."},THREEDS_CARDINAL_SDK_BAD_CONFIG:{type:s.types.MERCHANT,code:"THREEDS_CARDINAL_SDK_BAD_CONFIG",message:"JWT or other required field missing. Please check your setup configuration."},THREEDS_CARDINAL_SDK_BAD_JWT:{type:s.types.MERCHANT,code:"THREEDS_CARDINAL_SDK_BAD_JWT",message:"Cardinal JWT missing or malformed. Please check your setup configuration."},THREEDS_CARDINAL_SDK_ERROR:{type:s.types.UNKNOWN,code:"THREEDS_CARDINAL_SDK_ERROR",message:"A general error has occurred with Cardinal. See description for more information."},THREEDS_CARDINAL_SDK_CANCELED:{type:s.types.CUSTOMER,code:"THREEDS_CARDINAL_SDK_CANCELED",message:"Canceled by user."},THREEDS_VERIFY_CARD_CANCELED_BY_MERCHANT:{type:s.types.MERCHANT,code:"THREEDS_VERIFY_CARD_CANCELED_BY_MERCHANT",message:"3D Secure verfication canceled by merchant."},THREEDS_AUTHENTICATION_IN_PROGRESS:{type:s.types.MERCHANT,code:"THREEDS_AUTHENTICATION_IN_PROGRESS",message:"Cannot call verifyCard while existing authentication is in progress."},THREEDS_MISSING_VERIFY_CARD_OPTION:{type:s.types.MERCHANT,code:"THREEDS_MISSING_VERIFY_CARD_OPTION"},THREEDS_JWT_AUTHENTICATION_FAILED:{type:s.types.UNKNOWN,code:"THREEDS_JWT_AUTHENTICATION_FAILED",message:"Something went wrong authenticating the JWT from Cardinal"},THREEDS_LOOKUP_TOKENIZED_CARD_NOT_FOUND_ERROR:{type:s.types.MERCHANT,code:"THREEDS_LOOKUP_TOKENIZED_CARD_NOT_FOUND_ERROR",message:"Either the payment method nonce passed to `verifyCard` does not exist, or it was already consumed"},THREEDS_LOOKUP_VALIDATION_ERROR:{type:s.types.CUSTOMER,code:"THREEDS_LOOKUP_VALIDATION_ERROR",message:"The data passed in `verifyCard` did not pass validation checks. See details for more info"},THREEDS_LOOKUP_ERROR:{type:s.types.UNKNOWN,code:"THREEDS_LOOKUP_ERROR",message:"Something went wrong during the 3D Secure lookup"},THREEDS_INLINE_IFRAME_DETAILS_INCORRECT:{type:s.types.UNKNOWN,code:"THREEDS_INLINE_IFRAME_DETAILS_INCORRECT",message:"Something went wrong when attempting to add the authentication iframe to the page."},THREEDS_NO_VERIFICATION_PAYLOAD:{type:s.types.MERCHANT,code:"THREEDS_NO_VERIFICATION_PAYLOAD",message:"No verification payload available."},THREEDS_TERM_URL_REQUIRES_BRAINTREE_DOMAIN:{type:s.types.INTERNAL,code:"THREEDS_TERM_URL_REQUIRES_BRAINTREE_DOMAIN",message:"Term Url must be on a Braintree domain."}
125,THREEDS_FRAMEWORK_METHOD_NOT_IMPLEMENTED:{type:s.types.INTERNAL,code:"THREEDS_FRAMEWORK_METHOD_NOT_IMPLEMENTED",message:"Method not implemented for this framework."},THREEDS_REQUESTED_EXEMPTION_TYPE_INVALID:{type:s.types.MERCHANT,code:"THREEDS_REQUESTED_EXEMPTION_TYPE_INVALID",message:"Requested Exemption Type is invalid."},THREEDS_UNSUPPORTED_VERSION:{type:s.types.MERCHANT,code:"THREEDS_UNSUPPORTED_VERSION",message:"3D Secure `1` is deprecated and no longer supported. See available versions at https://braintree.github.io/braintree-web/current/module-braintree-web_three-d-secure.html#.create"}}},{"../../lib/braintree-error":149}],236:[function(n,i,r){var s=n("../../lib/enumerate");i.exports=s(["AUTHENTICATION_COMPLETE"],"threedsecure:")},{"../../lib/enumerate":158}],237:[function(n,i,r){var s=n("./shared/unionpay"),a=n("../lib/basic-component-verification"),o=n("../lib/braintree-error"),l=n("../lib/create-deferred-client"),c=n("../lib/create-assets-url"),d=n("../lib/analytics"),u=n("./shared/errors"),p="3.140.0",h=n("@braintree/wrap-promise");function m(v){var _="UnionPay";return a.verify({name:_,client:v.client,authorization:v.authorization}).then(function(){return l.create({authorization:v.authorization,client:v.client,debug:v.debug,assetsUrl:c.create(v.authorization),name:_})}).then(function(b){var w=b.getConfiguration();return v.client=b,!w.gatewayConfiguration.unionPay||w.gatewayConfiguration.unionPay.enabled!==!0?Promise.reject(new o(u.UNIONPAY_NOT_ENABLED)):(d.sendEvent(v.client,"unionpay.initialized"),new s(v))})}i.exports={create:h(m),VERSION:p}},{"../lib/analytics":144,"../lib/basic-component-verification":147,"../lib/braintree-error":149,"../lib/create-assets-url":153,"../lib/create-deferred-client":155,"./shared/errors":239,"./shared/unionpay":240,"@braintree/wrap-promise":43}],238:[function(n,i,r){var s=n("../../lib/enumerate");i.exports={events:s(["HOSTED_FIELDS_FETCH_CAPABILITIES","HOSTED_FIELDS_ENROLL","HOSTED_FIELDS_TOKENIZE"],"union-pay:"),HOSTED_FIELDS_FRAME_NAME:"braintreeunionpayhostedfields"}},{"../../lib/enumerate":158}],239:[function(n,i,r){var s=n("../../lib/braintree-error");i.exports={UNIONPAY_NOT_ENABLED:{type:s.types.MERCHANT,code:"UNIONPAY_NOT_ENABLED",message:"UnionPay is not enabled for this merchant."},UNIONPAY_HOSTED_FIELDS_INSTANCE_INVALID:{type:s.types.MERCHANT,code:"UNIONPAY_HOSTED_FIELDS_INSTANCE_INVALID",message:"Found an invalid Hosted Fields instance. Please use a valid Hosted Fields instance."},UNIONPAY_HOSTED_FIELDS_INSTANCE_REQUIRED:{type:s.types.MERCHANT,code:"UNIONPAY_HOSTED_FIELDS_INSTANCE_REQUIRED",message:"Could not find the Hosted Fields instance."},UNIONPAY_CARD_OR_HOSTED_FIELDS_INSTANCE_REQUIRED:{type:s.types.MERCHANT,code:"UNIONPAY_CARD_OR_HOSTED_FIELDS_INSTANCE_REQUIRED",message:"A card or a Hosted Fields instance is required. Please supply a card or a Hosted Fields instance."},UNIONPAY_CARD_AND_HOSTED_FIELDS_INSTANCES:{type:s.types.MERCHANT,code:"UNIONPAY_CARD_AND_HOSTED_FIELDS_INSTANCES",message:"Please supply either a card or a Hosted Fields instance, not both."},UNIONPAY_EXPIRATION_DATE_INCOMPLETE:{type:s.types.MERCHANT,code:"UNIONPAY_EXPIRATION_DATE_INCOMPLETE",message:"You must supply expiration month and year or neither."},UNIONPAY_ENROLLMENT_CUSTOMER_INPUT_INVALID:{type:s.types.CUSTOMER,code:"UNIONPAY_ENROLLMENT_CUSTOMER_INPUT_INVALID",message:"Enrollment failed due to user input error."},UNIONPAY_ENROLLMENT_NETWORK_ERROR:{type:s.types.NETWORK,code:"UNIONPAY_ENROLLMENT_NETWORK_ERROR",message:"Could not enroll UnionPay card."},UNIONPAY_FETCH_CAPABILITIES_NETWORK_ERROR:{type:s.types.NETWORK,code:"UNIONPAY_FETCH_CAPABILITIES_NETWORK_ERROR",message:"Could not fetch card capabilities."},UNIONPAY_TOKENIZATION_NETWORK_ERROR:{type:s.types.NETWORK,code:"UNIONPAY_TOKENIZATION_NETWORK_ERROR",message:"A tokenization network error occurred."},UNIONPAY_MISSING_MOBILE_PHONE_DATA:{type:s.types.MERCHANT,code:"UNIONPAY_MISSING_MOBILE_PHONE_DATA",message:"A `mobile` with `countryCode` and `number` is required."},UNIONPAY_FAILED_TOKENIZATION:{type:s.types.CUSTOMER,code:"UNIONPAY_FAILED_TOKENIZATION",message:"The supplied card data failed tokenization."}}},{"../../lib/braintree-error":149}],240:[function(n,i,r){var s=n("../../lib/analytics"),a=n("../../lib/braintree-error"),o=n("framebus"),l=n("./constants"),c=n("../../lib/is-verified-domain"),d=n("../../lib/use-min"),u=n("../../lib/convert-methods-to-error"),p=n("./errors"),h=l.events,m=n("@braintree/iframer"),v=n("../../lib/methods"),_="3.140.0",b=n("@braintree/uuid"),w=n("@braintree/wrap-promise"),C=n("../../lib/constants").BUS_CONFIGURATION_REQUEST_EVENT;function O(T){this._options=T}O.prototype.fetchCapabilities=function(T){var E=this,y=this._options.client,P=T.card?T.card.number:null,A=T.hostedFields;return P&&A?Promise.reject(new a(p.UNIONPAY_CARD_AND_HOSTED_FIELDS_INSTANCES)):P?y.request({method:"get",endpoint:"payment_methods/credit_cards/capabilities",data:{_meta:{source:"unionpay"},creditCard:{number:P}}}).then(function(I){return s.sendEvent(y,"unionpay.capabilities-received"),I}
125).catch(function(I){var L=I.details&&I.details.httpStatus;return s.sendEvent(y,"unionpay.capabilities-failed"),L===403?Promise.reject(I):Promise.reject(new a({type:p.UNIONPAY_FETCH_CAPABILITIES_NETWORK_ERROR.type,code:p.UNIONPAY_FETCH_CAPABILITIES_NETWORK_ERROR.code,message:p.UNIONPAY_FETCH_CAPABILITIES_NETWORK_ERROR.message,details:{originalError:I}}))}):A?A._bus?E._initializeHostedFields().then(function(){return new Promise(function(I,L){E._bus.emit(h.HOSTED_FIELDS_FETCH_CAPABILITIES,{hostedFields:A},function(D){if(D.err){L(new a(D.err));return}I(D.payload)})})}):Promise.reject(new a(p.UNIONPAY_HOSTED_FIELDS_INSTANCE_INVALID)):Promise.reject(new a(p.UNIONPAY_CARD_OR_HOSTED_FIELDS_INSTANCE_REQUIRED))},O.prototype.enroll=function(T){var E=this,y=this._options.client,P=T.card,A=T.mobile,I=T.hostedFields,L;if(!A)return Promise.reject(new a(p.UNIONPAY_MISSING_MOBILE_PHONE_DATA));if(I)return I._bus?P?Promise.reject(new a(p.UNIONPAY_CARD_AND_HOSTED_FIELDS_INSTANCES)):new Promise(function(D,z){E._initializeHostedFields().then(function(){E._bus.emit(h.HOSTED_FIELDS_ENROLL,{hostedFields:I,mobile:A},function(G){if(G.err){z(new a(G.err));return}D(G.payload)})})}):Promise.reject(new a(p.UNIONPAY_HOSTED_FIELDS_INSTANCE_INVALID));if(P&&P.number){if(L={_meta:{source:"unionpay"},unionPayEnrollment:{number:P.number,mobileCountryCode:A.countryCode,mobileNumber:A.number}},P.expirationDate)L.unionPayEnrollment.expirationDate=P.expirationDate;else if(P.expirationMonth||P.expirationYear)if(P.expirationMonth&&P.expirationYear)L.unionPayEnrollment.expirationYear=P.expirationYear,L.unionPayEnrollment.expirationMonth=P.expirationMonth;else return Promise.reject(new a(p.UNIONPAY_EXPIRATION_DATE_INCOMPLETE));return y.request({method:"post",endpoint:"union_pay_enrollments",data:L}).then(function(D){return s.sendEvent(y,"unionpay.enrollment-succeeded"),{enrollmentId:D.unionPayEnrollmentId,smsCodeRequired:D.smsCodeRequired}}).catch(function(D){var z,G=D.details&&D.details.httpStatus;return G===403?z=D:G<500?(z=new a(p.UNIONPAY_ENROLLMENT_CUSTOMER_INPUT_INVALID),z.details={originalError:D}):(z=new a(p.UNIONPAY_ENROLLMENT_NETWORK_ERROR),z.details={originalError:D}),s.sendEvent(y,"unionpay.enrollment-failed"),Promise.reject(z)})}return Promise.reject(new a(p.UNIONPAY_CARD_OR_HOSTED_FIELDS_INSTANCE_REQUIRED))},O.prototype.tokenize=function(T){var E,y=this,P=this._options.client,A=T.card,I=T.hostedFields;return A&&I?Promise.reject(new a(p.UNIONPAY_CARD_AND_HOSTED_FIELDS_INSTANCES)):A?(E={_meta:{source:"unionpay"},creditCard:{number:T.card.number,options:{unionPayEnrollment:{id:T.enrollmentId}}}},T.smsCode&&(E.creditCard.options.unionPayEnrollment.smsCode=T.smsCode),A.expirationDate?E.creditCard.expirationDate=A.expirationDate:A.expirationMonth&&A.expirationYear&&(E.creditCard.expirationYear=A.expirationYear,E.creditCard.expirationMonth=A.expirationMonth),T.card.cvv&&(E.creditCard.cvv=T.card.cvv),P.request({method:"post",endpoint:"payment_methods/credit_cards",data:E}).then(function(L){var D=L.creditCards[0];return delete D.consumed,delete D.threeDSecureInfo,s.sendEvent(P,"unionpay.nonce-received"),D}).catch(function(L){var D,z=L.details&&L.details.httpStatus;return s.sendEvent(P,"unionpay.nonce-failed"),z===403?D=L:z<500?(D=new a(p.UNIONPAY_FAILED_TOKENIZATION),D.details={originalError:L}):(D=new a(p.UNIONPAY_TOKENIZATION_NETWORK_ERROR),D.details={originalError:L}),Promise.reject(D)})):I?I._bus?new Promise(function(L,D){y._initializeHostedFields().then(function(){y._bus.emit(h.HOSTED_FIELDS_TOKENIZE,T,function(z){if(z.err){D(new a(z.err));return}L(z.payload)})})}):Promise.reject(new a(p.UNIONPAY_HOSTED_FIELDS_INSTANCE_INVALID)):Promise.reject(new a(p.UNIONPAY_CARD_OR_HOSTED_FIELDS_INSTANCE_REQUIRED))},O.prototype.teardown=function(){return this._bus&&(this._hostedFieldsFrame.parentNode.removeChild(this._hostedFieldsFrame),this._bus.teardown()),u(this,v(O.prototype)),Promise.resolve()},O.prototype._initializeHostedFields=function(){var T,E,y=b(),P=this;return this._hostedFieldsInitializePromise?this._hostedFieldsInitializePromise:(this._hostedFieldsInitializePromise=new Promise(function(A){T=P._options.client.getConfiguration().gatewayConfiguration.assetsUrl,E=P._options.client.getConfiguration().isDebug,P._bus=new o({channel:y,verifyDomain:c}),P._hostedFieldsFrame=m({name:l.HOSTED_FIELDS_FRAME_NAME+"_"+y,src:T+"/web/"+_+"/html/unionpay-hosted-fields-frame"+d(E)+".html",height:0,width:0}),P._bus.on(C,function(I){I(P._options.client),A()}),document.body.appendChild(P._hostedFieldsFrame)}),this._hostedFieldsInitializePromise)},i.exports=w.wrapPrototype(O)},{"../../lib/analytics":144,"../../lib/braintree-error":149,"../../lib/constants":150,"../../lib/convert-methods-to-error":151,"../../lib/is-verified-domain":179,"../../lib/methods":181,"../../lib/use-min":187,"./constants":238,"./errors":239,"@braintree/iframer":35,"@braintree/uuid":39,"@braintree/wrap-promise":43,framebus:54}],241:[function(n,i,r){i.exports={PLAID_LINK_JS:"https://cdn.plaid.com/link/v2/stable/link-initialize.js"}},{}
125],242:[function(n,i,r){var s=n("../lib/braintree-error");i.exports={US_BANK_ACCOUNT_OPTION_REQUIRED:{type:s.types.MERCHANT,code:"US_BANK_ACCOUNT_OPTION_REQUIRED"},US_BANK_ACCOUNT_MUTUALLY_EXCLUSIVE_OPTIONS:{type:s.types.MERCHANT,code:"US_BANK_ACCOUNT_MUTUALLY_EXCLUSIVE_OPTIONS"},US_BANK_ACCOUNT_LOGIN_LOAD_FAILED:{type:s.types.NETWORK,code:"US_BANK_ACCOUNT_LOGIN_LOAD_FAILED",message:"Bank login flow failed to load."},US_BANK_ACCOUNT_LOGIN_CLOSED:{type:s.types.CUSTOMER,code:"US_BANK_ACCOUNT_LOGIN_CLOSED",message:"Customer closed bank login flow before authorizing."},US_BANK_ACCOUNT_LOGIN_REQUEST_ACTIVE:{type:s.types.MERCHANT,code:"US_BANK_ACCOUNT_LOGIN_REQUEST_ACTIVE",message:"Another bank login tokenization request is active."},US_BANK_ACCOUNT_TOKENIZATION_NETWORK_ERROR:{type:s.types.NETWORK,code:"US_BANK_ACCOUNT_TOKENIZATION_NETWORK_ERROR",message:"A tokenization network error occurred."},US_BANK_ACCOUNT_FAILED_TOKENIZATION:{type:s.types.CUSTOMER,code:"US_BANK_ACCOUNT_FAILED_TOKENIZATION",message:"The supplied data failed tokenization."},US_BANK_ACCOUNT_NOT_ENABLED:{type:s.types.MERCHANT,code:"US_BANK_ACCOUNT_NOT_ENABLED",message:"US bank account is not enabled."},US_BANK_ACCOUNT_BANK_LOGIN_NOT_ENABLED:{type:s.types.MERCHANT,code:"US_BANK_ACCOUNT_BANK_LOGIN_NOT_ENABLED",message:"Bank login is not enabled."}}},{"../lib/braintree-error":149}],243:[function(n,i,r){var s=n("../lib/basic-component-verification"),a=n("../lib/braintree-error"),o=n("../lib/create-deferred-client"),l=n("../lib/create-assets-url"),c=n("./errors"),d=n("./us-bank-account"),u="3.140.0",p=n("@braintree/wrap-promise");function h(m){var v="US Bank Account";return s.verify({name:v,client:m.client,authorization:m.authorization}).then(function(){return o.create({authorization:m.authorization,client:m.client,debug:m.debug,assetsUrl:l.create(m.authorization),name:v})}).then(function(_){var b;return m.client=_,b=m.client.getConfiguration().gatewayConfiguration.usBankAccount,b?new d(m):Promise.reject(new a(c.US_BANK_ACCOUNT_NOT_ENABLED))})}i.exports={create:p(h),VERSION:u}},{"../lib/basic-component-verification":147,"../lib/braintree-error":149,"../lib/create-assets-url":153,"../lib/create-deferred-client":155,"./errors":242,"./us-bank-account":244,"@braintree/wrap-promise":43}],244:[function(n,i,r){var s=n("../lib/braintree-error"),a=n("./constants"),o=n("./errors"),l=n("../lib/errors"),c=n("../lib/analytics"),d=n("../lib/once"),u=n("../lib/convert-methods-to-error"),p=n("../lib/methods"),h=n("@braintree/wrap-promise"),m=E("UsBankAccount"),v=E("UsBankLogin");function _(y){this._client=y.client,this._isTokenizingBankLogin=!1,c.sendEvent(this._client,"usbankaccount.initialized")}_.prototype.tokenize=function(y){return y=y||{},y.mandateText?y.bankDetails&&y.bankLogin?Promise.reject(new s({type:o.US_BANK_ACCOUNT_MUTUALLY_EXCLUSIVE_OPTIONS.type,code:o.US_BANK_ACCOUNT_MUTUALLY_EXCLUSIVE_OPTIONS.code,message:"tokenize must be called with bankDetail
125s or bankLogin, not both."})):y.bankDetails?this._tokenizeBankDetails(y):y.bankLogin?this._tokenizeBankLogin(y):Promise.reject(new s({type:o.US_BANK_ACCOUNT_OPTION_REQUIRED.type,code:o.US_BANK_ACCOUNT_OPTION_REQUIRED.code,message:"tokenize must be called with bankDetails or bankLogin."})):Promise.reject(new s({type:o.US_BANK_ACCOUNT_OPTION_REQUIRED.type,code:o.US_BANK_ACCOUNT_OPTION_REQUIRED.code,message:"mandateText property is required."}))},_.prototype._tokenizeBankDetails=function(y){var P=this._client,A=y.bankDetails,I={achMandate:y.mandateText,routingNumber:A.routingNumber,accountNumber:A.accountNumber,accountType:A.accountType.toUpperCase(),billingAddress:O(A.billingAddress||{})};return T(I,A),P.request({api:"graphQLApi",data:{query:m,variables:{input:{usBankAccount:I}}}}).then(function(L){return c.sendEvent(P,"usbankaccount.bankdetails.tokenization.succeeded"),Promise.resolve(w(L,"tokenizeUsBankAccount"))}).catch(function(L){var D=b(L);return c.sendEvent(P,"usbankaccount.bankdetails.tokenization.failed"),Promise.reject(D)})},_.prototype._tokenizeBankLogin=function(y){var P=this,A=this._client,I=A.getConfiguration().gatewayConfiguration,L=I.environment==="production",D=I.usBankAccount.plaid;return y.bankLogin.displayName?D?this._isTokenizingBankLogin?Promise.reject(new s(o.US_BANK_ACCOUNT_LOGIN_REQUEST_ACTIVE)):(this._isTokenizingBankLogin=!0,new Promise(function(z,G){P._loadPlaid(function(ne,W){if(ne){G(ne);return}W.create({clientName:y.bankLogin.displayName,apiVersion:"v2",env:L?"production":"sandbox",key:D.publicKey,product:"auth",selectAccount:!0,onExit:function(){P._isTokenizingBankLogin=!1,c.sendEvent(A,"usbankaccount.banklogin.tokenization.closed.by-user"),G(new s(o.US_BANK_ACCOUNT_LOGIN_CLOSED))},onSuccess:function(ue,H){var x=y.bankLogin,V={publicToken:ue,accountId:L?H.account_id:"plaid_account_id",accountType:H.account.subtype.toUpperCase(),achMandate:y.mandateText,billingAddress:O(x.billingAddress||{})};T(V,x),A.request({api:"graphQLApi",data:{query:v,variables:{input:{usBankLogin:V}}}}).then(function(te){P._isTokenizingBankLogin=!1,c.sendEvent(A,"usbankaccount.banklogin.tokenization.succeeded"),z(w(te,"tokenizeUsBankLogin"))}).catch(function(te){var fe;P._isTokenizingBankLogin=!1,fe=b(te),c.sendEvent(A,"usbankaccount.banklogin.tokenization.failed"),G(fe)})}}).open(),c.sendEvent(A,"usbankaccount.banklogin.tokenization.started")})})):Promise.reject(new s(o.US_BANK_ACCOUNT_BANK_LOGIN_NOT_ENABLED)):Promise.reject(new s({type:o.US_BANK_ACCOUNT_OPTION_REQUIRED.type,code:o.US_BANK_ACCOUNT_OPTION_REQUIRED.code,message:"displayName property is required when using bankLogin."}))};function b(y){var P,A=y.details&&y.details.httpStatus;return A===401?P=new s(l.BRAINTREE_API_ACCESS_RESTRICTED):A<500?P=new s(o.US_BANK_ACCOUNT_FAILED_TOKENIZATION):P=new s(o.US_BANK_ACCOUNT_TOKENIZATION_NETWORK_ERROR),P.details={originalError:y},P}function w(y,P){var A=y.data[P].paymentMethod,I=A.details.last4,L="US bank account ending in - "+I;return{nonce:A.id,details:{},description:L,type:"us_bank_account"}}_.prototype._loadPlaid=function(y){var P,A;if(y=d(y),window.Plaid){y(null,window.Plaid);return}P=document.querySelector('script[src="'+a.PLAID_LINK_JS+'"]'),P?C(P,y):(A=document.createElement("script"),A.src=a.PLAID_LINK_JS,A.async=!0,C(A,y),document.body.appendChild(A),this._plaidScript=A)};function C(y,P){function A(){var D=this.readyState;(!D||D==="loaded"||D==="complete")&&(L(),P(null,window.Plaid))}function I(){y.parentNode.removeChild(y),P(new s(o.US_BANK_ACCOUNT_LOGIN_LOAD_FAILED))}function L(){y.removeEventListener("error",I),y.removeEventListener("load",A),y.removeEventListener("readystatechange",A)}y.addEventListener("error",I),y.addEventListener("load",A),y.addEventListener("readystatechange",A)}function O(y){return{streetAddress:y.streetAddress,extendedAddress:y.extendedAddress,city:y.locality,state:y.region,zipCode:y.postalCode}}function T(y,P){P.ownershipType==="personal"?y.individualOwner={firstName:P.firstName,lastName:P.lastName}:P.ownershipType==="business"&&(y.businessOwner={businessName:P.businessName})}function E(y){return"mutation Tokenize"+y+"($input: Tokenize"+y+"Input!) {  tokenize"+y+"(input: $input) {    paymentMethod {      id      details {        ... on UsBankAccountDetails {          last4        }      }    }  }}"}_.prototype.teardown=function(){return this._plaidScript&&document.body.removeChild(this._plaidScript),u(this,p(_.prototype)),Promise.resolve()},i.exports=h.wrapPrototype(_)},{"../lib/analytics":144,"../lib/braintree-error":149,"../lib/convert-methods-to-error":151,"../lib/errors":159,"../lib/methods":181,"../lib/once":182,"./constants":241,"./errors":242,"@braintree/wrap-promise":43}],245:[function(n,i,r){var s=n("../lib/braintree-error");i.exports={VAULT_MANAGER_DELETE_PAYMENT_METHOD_NONCE_REQUIRES_CLIENT_TOKEN:{type:s.types.MERCHANT,code:"VAULT_MANAGER_DELETE_PAYMENT_METHOD_NONCE_REQUIRES_CLIENT_TOKEN",message:"A client token with a customer id must be used to delete a payment method nonce."},VAULT_MANAGER_PAYMENT_METHOD_NONCE_NOT_FOUND:{type:s.types.MERCHANT,code:"VAULT_MANAGER_PAYMENT_METHOD_NONCE_NOT_FOUND"},VAULT_MANAGER_DELETE_PAYMENT_METHOD_UNKNOWN_ERROR:{type:s.types.UNKNOWN,code:"VAULT_MANAGER_DELETE_PAYMENT_METHOD_UNKNOWN_ERROR"}}},{"../lib/braintree-error":149}],246:[function(n,i,r){var s=n("../lib/basic-component-verification"),a=n("../lib/create-deferred-client"),o=n("../lib/create-assets-url"),l=n("./vault-manager"),c="3.140.0",d=n("@braintree/wrap-promise");function u(p){var h="Vault Manager";return s.verify({name:h,client:p.client,authorization:p.authorization}).then(function(){return new l({createPromise:a.create({authorization:p.authorization,client:p.client,debug:p.debug,assetsUrl:o.create(p.authorization),name:h})})})}i.exports={create:d(u),VERSION:c}},{"../lib/basic-component-verification":147,"../lib/create-assets-url":153,"../lib/create-deferred-client":155,"./vault-manager"
125:247,"@braintree/wrap-promise":43}],247:[function(n,i,r){var s=n("../lib/analytics"),a=n("../lib/braintree-error"),o=n("./errors"),l=n("../lib/convert-methods-to-error"),c=n("../lib/methods"),d=n("@braintree/wrap-promise"),u="mutation DeletePaymentMethodFromSingleUseToken($input: DeletePaymentMethodFromSingleUseTokenInput!) {  deletePaymentMethodFromSingleUseToken(input: $input) {    clientMutationId  }}";function p(m){this._createPromise=m.createPromise}p.prototype.fetchPaymentMethods=function(m){var v;return m=m||{},v=m.defaultFirst===!0?1:0,this._createPromise.then(function(_){return _.request({endpoint:"payment_methods",method:"get",data:{defaultFirst:v}})}).then((function(_){return s.sendEvent(this._createPromise,"vault-manager.fetch-payment-methods.succeeded"),_.paymentMethods.map(h)}).bind(this))},p.prototype.deletePaymentMethod=function(m){return this._createPromise.then(function(v){var _=v.getConfiguration().authorizationType==="CLIENT_TOKEN";return _?v.request({api:"graphQLApi",data:{query:u,variables:{input:{singleUseTokenId:m}},operationName:"DeletePaymentMethodFromSingleUseToken"}}).then(function(){s.sendEvent(v,"vault-manager.delete-payment-method.succeeded")}).catch(function(b){var w=b.details.originalError,C;return s.sendEvent(v,"vault-manager.delete-payment-method.failed"),w[0]&&w[0].extensions.errorClass==="NOT_FOUND"&&(C=new a({type:o.VAULT_MANAGER_PAYMENT_METHOD_NONCE_NOT_FOUND.type,code:o.VAULT_MANAGER_PAYMENT_METHOD_NONCE_NOT_FOUND.code,message:"A payment method for payment method nonce `"+m+"` could not be found.",details:{originalError:w}})),C||(C=new a({type:o.VAULT_MANAGER_DELETE_PAYMENT_METHOD_UNKNOWN_ERROR.type,code:o.VAULT_MANAGER_DELETE_PAYMENT_METHOD_UNKNOWN_ERROR.code,message:"An unknown error occured when attempting to delete the payment method assocaited with the payment method nonce `"+m+"`.",details:{originalError:w}})),Promise.reject(C)}):Promise.reject(new a(o.VAULT_MANAGER_DELETE_PAYMENT_METHOD_NONCE_REQUIRES_CLIENT_TOKEN))})};function h(m){var v={nonce:m.nonce,default:m.default,details:m.details,hasSubscription:m.hasSubscription,type:m.type};return m.description&&(v.description=m.description),m.binData&&(v.binData=m.binData),v}p.prototype.teardown=function(){return l(this,c(p.prototype)),Promise.resolve()},i.exports=d.wrapPrototype(p)},{"../lib/analytics":144,"../lib/braintree-error":149,"../lib/convert-methods-to-error":151,"../lib/methods":181,"./errors":245,"@braintree/wrap-promise":43}],248:[function(n,i,r){var s=this&&this.__importDefault||function(o){return o&&o.__esModule?o:{default:o}},a=s(n("./venmo-desktop"));i.exports=function(l){var c=new a.default(l);return c.initialize()}},{"./venmo-desktop":250}],249:[function(n,i,r){Object.defineProperty(r,"__esModule",{value:!0}),r.VENMO_PAYMENT_CONTEXT_STATUS_QUERY=r.LEGACY_VENMO_PAYMENT_CONTEXT_STATUS_QUERY=r.UPDATE_PAYMENT_CONTEXT_QUERY=r.LEGACY_UPDATE_PAYMENT_CONTEXT_QUERY=r.CREATE_PAYMENT_CONTEXT_QUERY=r.LEGACY_CREATE_PAYMENT_CONTEXT_QUERY=void 0,r.LEGACY_CREATE_PAYMENT_CONTEXT_QUERY=`mutation CreateVenmoQRCodePaymentContext($input: CreateVenmoQRCodePaymentContextInput!) {
126  createVenmoQRCodePaymentContext(input: $input) {
127    clientMutationId
128    venmoQRCodePaymentContext {
129      id
130      merchantId
131      createdAt
132      expiresAt
133    }
134  }
135}`,r.CREATE_PAYMENT_CONTEXT_QUERY=`mutation CreateVenmoPaymentContext($input: CreateVenmoPaymentContextInput!) {
136  createVenmoPaymentContext(input: $input) {
137    clientMutationId
138    venmoPaymentContext {
139      id
140      merchantId
141      createdAt
142      expiresAt
143    }
144  }
145}`,r.LEGACY_UPDATE_PAYMENT_CONTEXT_QUERY=`mutation UpdateVenmoQRCodePaymentContext($input: UpdateVenmoQRCodePaymentContextInput!) {
146  updateVenmoQRCodePaymentContext(input: $input) {
147    clientMutationId
148  }
149}`,r.UPDATE_PAYMENT_CONTEXT_QUERY=`mutation UpdateVenmoPaymentContextStatus($input: UpdateVenmoPaymentContextStatusInput!) {
150  updateVenmoPaymentContextStatus(input: $input) {
151    clientMutationId
152  }
153}`,r.LEGACY_VENMO_PAYMENT_CONTEXT_STATUS_QUERY=`query PaymentContext($id: ID!) {
154  node(id: $id) {
155    ... on VenmoQRCodePaymentContext {
156      status
157      paymentMethodId
158      userName
159    }
160  }
161}`,r.VENMO_PAYMENT_CONTEXT_STATUS_QUERY=`query PaymentContext($id: ID!) {
162  node(id: $id) {
163    ... on VenmoPaymentContext {
164      status
165      paymentMethodId
166      userName
167      payerInfo {
168        firstName
169        lastName
170        phoneNumber
171        email
172        externalId
173        userName
174        billingAddress {
175          fullName
176          addressLine1
177          addressLine2
178          adminArea1
179          adminArea2
180          postalCode
181          countryCode
182        }
183        shippingAddress {
184          fullName
185          addressLine1
186          addressLine2
187          adminArea1
188          adminArea2
189          postalCode
190          countryCode
191        }
192      }
193    }
194  }
195}`},{}],250:[function(n,i,r){var s=this&&this.__assign||function(){return s=Object.assign||function(v){for(var _,b=1,w=arguments.length;b<w;b++){_=arguments[b];for(var C in _)Object.prototype.hasOwnProperty.call(_,C)&&(v[C]=_[C])}return v},s.apply(this,arguments)}
195,a=this&&this.__importDefault||function(v){return v&&v.__esModule?v:{default:v}};Object.defineProperty(r,"__esModule",{value:!0});var o=a(n("framebus")),l=a(n("@braintree/iframer")),c=a(n("@braintree/uuid")),d=n("../shared/events"),u=n("./queries"),p=1e3,h=2e3,m=function(){function v(_){this.isHidden=!0,this.env=_.environment,this.id=c.default(),this.profileId=_.profileId,this.displayName=_.displayName,this.paymentMethodUsage=_.paymentMethodUsage,this.riskCorrelationId=_.riskCorrelationId,this.shouldUseLegacyQRCodeMutation=!this.paymentMethodUsage;var b=_.url+"#"+this.env+"_"+this.id;this.bus=new o.default({channel:this.id,verifyDomain:_.verifyDomain,targetFrames:[]}),this.apiRequest=_.apiRequest,this.sendEvent=_.sendEvent,this.Promise=_.Promise,this.alertBox=document.createElement("div"),this.alertBox.setAttribute("data-venmo-desktop-id",this.id),this.alertBox.setAttribute("role","alert"),this.alertBox.style.position="fixed",this.alertBox.style.display="none",this.alertBox.style.height="1px",this.alertBox.style.width="1px",this.alertBox.style.overflow="hidden",this.alertBox.style.zIndex="0",this.iframe=l.default({src:b,name:"venmo-desktop-iframe",style:{display:"none",position:"fixed",top:"0",bottom:"0",right:"0",left:"0",height:"100%",width:"100%",zIndex:"9999999"},title:"Venmo Desktop"}),this.bus.addTargetFrame(this.iframe)}return v.prototype.initialize=function(){var _=this;return new this.Promise(function(b){_.bus.on(d.VENMO_DESKTOP_IFRAME_READY,function(){b(_)}),_.bus.on(d.VENMO_DESKTOP_REQUEST_NEW_QR_CODE,function(){_.sendEvent("venmo.tokenize.desktop.restarted-from-error-view"),_.startPolling()}),document.body.appendChild(_.iframe),document.body.appendChild(_.alertBox)})},v.prototype.launchDesktopFlow=function(){var _=this;this.isHidden=!1;var b=new this.Promise(function(w,C){_.launchDesktopPromiseRejectFunction=C;var O=function(){_.bus.off(d.VENMO_DESKTOP_CUSTOMER_CANCELED,E),_.bus.off(d.VENMO_DESKTOP_UNKNOWN_ERROR,T)},T=function(y){O(),_.sendEvent("venmo.tokenize.desktop.unknown-error"),C({allowUIToHandleError:!1,reason:"UNKNOWN_ERROR",err:y})},E=function(){O(),_.updateVenmoDesktopPaymentContext("CANCELED"),_.sendEvent("venmo.tokenize.desktop.status-change.canceled-from-modal"),C({allowUIToHandleError:!1,reason:"CUSTOMER_CANCELED"})};_.completedHandler=function(y){O(),w(y)},_.bus.on(d.VENMO_DESKTOP_CUSTOMER_CANCELED,E),_.bus.on(d.VENMO_DESKTOP_UNKNOWN_ERROR,T)});return this.iframe.style.display="block",this.setAlert("Generating a QR code, get your Venmo app ready"),this.iframe.focus(),this.startPolling(),b.then(function(w){return delete _.venmoContextId,delete _.launchDesktopPromiseRejectFunction,w}).catch(function(w){return delete _.venmoContextId,delete _.launchDesktopPromiseRejectFunction,_.Promise.reject(w)})},v.prototype.triggerCompleted=function(_){var b=this;this.isHidden||setTimeout(function(){b.completedHandler&&b.completedHandler(_),delete b.completedHandler},h)},v.prototype.triggerRejected=function(_){this.launchDesktopPromiseRejectFunction&&this.launchDesktopPromiseRejectFunction(_)},v.prototype.hideDesktopFlow=function(){this.setAlert(""),this.iframe.style.display="none",this.bus.emit(d.VENMO_DESKTOP_CLOSED_FROM_PARENT),this.isHidden=!0},v.prototype.displayError=function(_){this.isHidden||(this.bus.emit(d.VENMO_DESKTOP_DISPLAY_ERROR,{message:_}),this.setAlert(_))},v.prototype.displayQRCode=function(_,b){this.isHidden||(this.bus.emit(d.VENMO_DESKTOP_DISPLAY_QR_CODE,{id:_,merchantId:b}),this.setAlert("To scan the QR code, open your Venmo app"))},v.prototype.authorize=function(){this.isHidden||(this.bus.emit(d.VENMO_DESKTOP_AUTHORIZE),this.setAlert("Venmo account authorized"))},v.prototype.authorizing=function(){this.isHidden||(this.bus.emit(d.VENMO_DESKTOP_AUTHORIZING),this.setAlert("Authorize on your Venmo app"))},v.prototype.startPolling=function(){var _=this;return this.createVenmoDesktopPaymentContext().then(function(b){var w=new Date(b.expiresAt).getTime()-new Date(b.createdAt).getTime(),C=Date.now()+w;return _.displayQRCode(b.id,b.merchantId),_.pollForStatusChange(b.status,C)}).then(function(b){if(b){var w=b.userName||"";w="@"+w.replace("@",""),_.triggerCompleted({paymentMethodNonce:b.paymentMethodId,username:w,payerInfo:b.payerInfo,id:_.venmoContextId||""})}}).catch(function(b){b.allowUIToHandleError||(_.sendEvent("venmo.tokenize.desktop.unhandled-error"),_.triggerRe
195jected(b))})},v.prototype.pollForStatusChange=function(_,b){var w=this;return this.venmoContextId?Date.now()>b?this.updateVenmoDesktopPaymentContext("EXPIRED").then(function(){return w.displayError("Something went wrong"),w.sendEvent("venmo.tokenize.desktop.status-change.sdk-timeout"),w.Promise.reject({allowUIToHandleError:!0,reason:"TIMEOUT"})}):this.lookupVenmoDesktopPaymentContext().then(function(C){if(!w.venmoContextId||!C)return w.Promise.resolve();var O=C.status;if(O!==_)switch(_=O,w.sendEvent("venmo.tokenize.desktop.status-change."+_.toLowerCase()),_){case"CREATED":break;case"EXPIRED":case"FAILED":case"CANCELED":var T=_==="CANCELED"?"The authorization was canceled":"Something went wrong";return w.displayError(T),w.Promise.reject({allowUIToHandleError:!0,reason:_});case"SCANNED":w.authorizing();break;case"APPROVED":return w.authorize(),w.Promise.resolve(C)}return new w.Promise(function(E,y){setTimeout(function(){w.pollForStatusChange(_,b).then(E).catch(y)},p)})}):this.Promise.resolve()},v.prototype.teardown=function(){this.bus.teardown(),this.iframe.parentNode&&this.iframe.parentNode.removeChild(this.iframe),this.alertBox.parentNode&&this.alertBox.parentNode.removeChild(this.alertBox)},v.prototype.setAlert=function(_){this.alertBox.style.display=_?"block":"none",this.alertBox.textContent=_},v.prototype.createPaymentContextFromGraphqlLegacyQRCodeMutation=function(_){return this.apiRequest(u.LEGACY_CREATE_PAYMENT_CONTEXT_QUERY,{input:{environment:this.env,intent:_}}).then(function(b){return b.createVenmoQRCodePaymentContext.venmoQRCodePaymentContext})},v.prototype.createPaymentContextFromGraphQL=function(_){var b={intent:_,paymentMethodUsage:this.paymentMethodUsage,venmoRiskCorrelationId:this.riskCorrelationId,customerClient:"DESKTOP"};return this.profileId&&(b.merchantProfileId=this.profileId),this.displayName&&(b.displayName=this.displayName),this.apiRequest(u.CREATE_PAYMENT_CONTEXT_QUERY,{input:b}).then(function(w){return w.createVenmoPaymentContext.venmoPaymentContext})},v.prototype.createVenmoDesktopPaymentContext=function(){var _=this,b=this.shouldUseLegacyQRCodeMutation?this.createPaymentContextFromGraphqlLegacyQRCodeMutation("PAY_FROM_APP"):this.createPaymentContextFromGraphQL("PAY_FROM_APP");return b.then(function(w){_.venmoContextId=w.id;var C=_.profileId||w.merchantId;return{id:w.id,status:w.status,merchantId:C,createdAt:w.createdAt,expiresAt:w.expiresAt}})},v.prototype.updateVenmoDesktopPaymentContext=function(_,b){if(b===void 0&&(b={}),!this.venmoContextId)return this.Promise.resolve();var w={input:s({id:this.venmoContextId,status:_},b)},C=this.shouldUseLegacyQRCodeMutation?u.LEGACY_UPDATE_PAYMENT_CONTEXT_QUERY:u.UPDATE_PAYMENT_CONTEXT_QUERY;return this.apiRequest(C,w).then(function(){})},v.prototype.lookupVenmoDesktopPaymentContext=function(){if(!this.venmoContextId)return this.Promise.resolve();var _=this.shouldUseLegacyQRCodeMutation?u.LEGACY_VENMO_PAYMENT_CONTEXT_STATUS_QUERY:u.VENMO_PAYMENT_CONTEXT_STATUS_QUERY;return this.apiRequest(_,{id:this.venmoContextId}).then(function(b){return b.node})},v}();r.default=m},{"../shared/events":255,"./queries":249,"@braintree/iframer":35,"@braintree/uuid":39,framebus:54}],251:[function(n,i,r){var s=n("../lib/analytics"),a=n("../lib/basic-component-verification"),o=n("../lib/create-deferred-client"),l=n("../lib/create-assets-url"),c=n("./shared/errors"),d=n("@braintree/wrap-promise"),u=n("../lib/braintree-error"),p=n("./venmo"),h=n("./shared/supports-venmo"),m="3.140.0",v=n("./shared/browser-detection");function _(w){var C="Venmo";return a.verify({name:C,client:w.client,authorization:w.authorization}).then(function(){var O,T,E=v.isIncognito();return w.profileId&&typeof w.profileId!="string"?Promise.reject(new u(c.VENMO_INVALID_PROFILE_ID)):w.deepLinkReturnUrl&&typeof w.deepLinkReturnUrl!="string"?Promise.reject(new u(c.VENMO_INVALID_DEEP_LINK_RETURN_URL)):w.riskCorrelationId&&typeof w.riskCorrelationId!="string"?Promise.reject(new u(c.VENMO_INVALID_RISK_CORRELATION_ID)):(O=o.create({authorization:w.authorization,client:w.client,debug:w.debug,assetsUrl:l.create(w.authorization),name:C}).then(function(y){var P=y.getConfiguration();return w.client=y,P.gatewayConfiguration.payWithVenmo?y:Promise.reject(new u(c.VENMO_NOT_ENABLED))}),Promise.all([O,E]).then(function(y){var P=y[1];return w._isIncognito=P.isPrivate,w.createPromise=O,T=new p(w),s.sendEvent(O,"venmo.initialized"),T}))})}function b(w){return h.isBrowserSupported(w)}i.exports={create:d(_),isBrowserSupported:b,VERSION:m}},{"../lib/analytics":144,"../lib/basic-component-verification":147,"../lib/braintree-error":149,"../lib/create-assets-url":153,"../lib/create-deferred-client":155,"./shared/browser-detection":252,"./shared/errors":254,"./shared/supports-venmo":257,"./venmo":259,"@braintree/wrap-promise":43}],252:[function(n,i,r){var s=n("@braintree/browser-detection/is-android"),a=n("@braintree/browser-detection/is-chrome"),o=n("@braintree/browser-detection/is-ios"),l=n("@braintree/browser-detection/is-ios-safari"),c=n("@braintree/browser-detection/is-ios-webview"),d;try{d=n("@braintree/browser-detection/is-incognito")}catch{d=function(){return Promise.resolve({isPrivate:!1,browserName:"unknown"})}}function u(){return s()&&window.navigator.userAgent.toLowerCase().indexOf("wv")>-1}
195function p(){return o()?c()||!l():!1}function h(){var _=window.navigator.userAgent.toLowerCase();return _.indexOf("huawei")>-1&&_.indexOf("fban")>-1?!0:s()?_.indexOf("fb_iab")>-1||_.indexOf("instagram")>-1:!1}function m(){return o()&&a()}function v(){return u()||c()}i.exports={isAndroid:s,isAndroidWebview:u,isChrome:a,isIos:o,isIosChrome:m,isIosSafari:l,isIosWebview:c,isWebview:v,isFacebookOwnedBrowserOnAndroid:h,doesNotSupportWindowOpenInIos:p,isIncognito:d}},{"@braintree/browser-detection/is-android":22,"@braintree/browser-detection/is-chrome":24,"@braintree/browser-detection/is-incognito":26,"@braintree/browser-detection/is-ios":30,"@braintree/browser-detection/is-ios-safari":27,"@braintree/browser-detection/is-ios-webview":28}],253:[function(n,i,r){i.exports={DOCUMENT_VISIBILITY_CHANGE_EVENT_DELAY:500,DEFAULT_PROCESS_RESULTS_DELAY:1e3,VENMO_APP_OR_MOBILE_AUTH_URL:"https://venmo.com/go/checkout",VENMO_MOBILE_APP_AUTH_ONLY_URL:"https://venmo.com/braintree/checkout",VENMO_WEB_LOGIN_URL:"https://account.venmo.com/go/web",VENMO_WEB_LOGIN_SANDBOX_URL:"https://account.ext.live.venmo.com/go/web"}},{}],254:[function(n,i,r){var s=n("../../lib/braintree-error");i.exports={VENMO_NOT_ENABLED:{type:s.types.MERCHANT,code:"VENMO_NOT_ENABLED",message:"Venmo is not enabled for this merchant."},VENMO_TOKENIZATION_REQUEST_ACTIVE:{type:s.types.MERCHANT,code:"VENMO_TOKENIZATION_REQUEST_ACTIVE",message:"Another tokenization request is active."},VENMO_TOKENIZATION_REQUEST_NOT_ACTIVE:{type:s.types.MERCHANT,code:"VENMO_TOKENIZATION_REQUEST_NOT_ACTIVE",message:"No tokenization in progress."},VENMO_APP_FAILED:{type:s.types.UNKNOWN,code:"VENMO_APP_FAILED",message:"Venmo app encountered a problem."},VENMO_APP_CANCELED:{type:s.types.CUSTOMER,code:"VENMO_APP_CANCELED",message:"Venmo app authorization was canceled."},VENMO_CANCELED:{type:s.types.CUSTOMER,code:"VENMO_CANCELED",message:"User canceled Venmo authorization, or Venmo app is not available."},VENMO_CUSTOMER_CANCELED:{type:s.types.CUSTOMER,code:"VENMO_CUSTOMER_CANCELED",message:"User canceled Venmo authorization."},VENMO_NETWORK_ERROR:{type:s.types.NETWORK,code:"VENMO_NETWORK_ERROR",message:"Something went wrong making the request"},VENMO_DESKTOP_CANCELED:{type:s.types.CUSTOMER,code:"VENMO_DESKTOP_CANCELED",message:"User canceled Venmo authorization by closing the Venmo Desktop modal."},VENMO_TOKENIZATION_CANCELED_BY_MERCHANT:{type:s.types.MERCHANT,code:"VENMO_TOKENIZATION_CANCELED_BY_MERCHANT",message:"The Venmo tokenization was canceled by the merchant."},VENMO_DESKTOP_UNKNOWN_ERROR:{type:s.types.UNKNOWN,code:"VENMO_DESKTOP_UNKNOWN_ERROR",message:"Something went wrong with the Venmo Desktop flow."},VENMO_MOBILE_PAYMENT_CONTEXT_SETUP_FAILED:{type:s.types.NETWORK,code:"VENMO_MOBILE_PAYMENT_CONTEXT_SETUP_FAILED",message:"Something went wrong creating the Venmo Payment Context."},VENMO_MOBILE_POLLING_TOKENIZATION_NETWORK_ERROR:{type:s.types.UNKNOWN,code:"VENMO_MOBILE_POLLING_TOKENIZATION_NETWORK_ERROR",message:"Something went wrong during mobile polling."},VENMO_MOBILE_POLLING_TOKENIZATION_EXPIRED:{type:s.types.CUSTOMER,code:"VENMO_MOBILE_POLLING_TOKENIZATION_EXPIRED",message:"The Venmo authorization request is expired."},VENMO_MOBILE_POLLING_TOKENIZATION_CANCELED:{type:s.types.CUSTOMER,code:"VENMO_MOBILE_POLLING_TOKENIZATION_CANCELED",message:"The Venmo authorization was canceled"},VENMO_MOBILE_POLLING_TOKENIZATION_TIMEOUT:{type:s.types.CUSTOMER,code:"VENMO_MOBILE_POLLING_TOKENIZATION_TIMEOUT",message:"Customer took too long to authorize Venmo payment."},VENMO_MOBILE_POLLING_TOKENIZATION_NO_CONTEXT_ID:{type:s.types.UNKNOWN,code:"VENMO_MOBILE_POLLING_TOKENIZATION_NO_CONTEXT_ID",message:"No Venmo payment context ID available."},VENMO_MOBILE_POLLING_TOKENIZATION_FAILED:{type:s.types.UNKNOWN,code:"VENMO_MOBILE_POLLING_TOKENIZATION_FAILED",message:"The Venmo authorization failed."},VENMO_INVALID_PROFILE_ID:{type:s.types.MERCHANT,code:"VENMO_INVALID_PROFILE_ID",message:"Venmo profile ID is invali
195d."},VENMO_INVALID_DEEP_LINK_RETURN_URL:{type:s.types.MERCHANT,code:"VENMO_INVALID_DEEP_LINK_RETURN_URL",message:"Venmo deep link return URL is invalid."},VENMO_INVALID_RISK_CORRELATION_ID:{type:s.types.MERCHANT,code:"VENMO_INVALID_RISK_CORRELATION_ID",message:"Venmo risk correlation ID is invalid."},VENMO_TOKENIZATION_FAILED:{type:s.types.UNKNOWN,code:"VENMO_TOKENIZATION_FAILED",message:"Venmo encountered a problem"},VENMO_ECD_DISABLED:{type:s.types.MERCHANT,code:"ECD_DISABLED",message:"Cannot collect customer data when ECD is disabled. Enable this feature in the Control Panel to collect this data."}}},{"../../lib/braintree-error":149}],255:[function(n,i,r){Object.defineProperty(r,"__esModule",{value:!0}),r.VENMO_DESKTOP_UNKNOWN_ERROR=r.VENMO_DESKTOP_REQUEST_NEW_QR_CODE=r.VENMO_DESKTOP_CLOSED_FROM_PARENT=r.VENMO_DESKTOP_IFRAME_READY=r.VENMO_DESKTOP_DISPLAY_QR_CODE=r.VENMO_DESKTOP_DISPLAY_ERROR=r.VENMO_DESKTOP_CUSTOMER_CANCELED=r.VENMO_DESKTOP_AUTHORIZING=r.VENMO_DESKTOP_AUTHORIZE=r.VENMO_DESKTOP_AUTHORIZATION_TIMED_OUT=void 0,r.VENMO_DESKTOP_AUTHORIZATION_TIMED_OUT="VENMO_DESKTOP_AUTHORIZATION_TIMED_OUT",r.VENMO_DESKTOP_AUTHORIZE="VENMO_DESKTOP_AUTHORIZE",r.VENMO_DESKTOP_AUTHORIZING="VENMO_DESKTOP_AUTHORIZING",r.VENMO_DESKTOP_CUSTOMER_CANCELED="VENMO_DESKTOP_CUSTOMER_CANCELED",r.VENMO_DESKTOP_DISPLAY_ERROR="VENMO_DESKTOP_DISPLAY_ERROR",r.VENMO_DESKTOP_DISPLAY_QR_CODE="VENMO_DESKTOP_DISPLAY_QR_CODE",r.VENMO_DESKTOP_IFRAME_READY="VENMO_DESKTOP_IFRAME_READY",r.VENMO_DESKTOP_CLOSED_FROM_PARENT="VENMO_DESKTOP_CLOSED_FROM_PARENT",r.VENMO_DESKTOP_REQUEST_NEW_QR_CODE="VENMO_DESKTOP_REQUEST_NEW_QR_CODE",r.VENMO_DESKTOP_UNKNOWN_ERROR="VENMO_DESKTOP_UNKNOWN_ERROR"},{}],256:[function(n,i,r){var s=n("./constants");function a(o){return o.useAllowDesktopWebLogin?o.enableVenmoSandbox&&o.environment&&o.environment!=="production"?s.VENMO_WEB_LOGIN_SANDBOX_URL:s.VENMO_WEB_LOGIN_URL:o.mobileWebFallBack?s.VENMO_APP_OR_MOBILE_AUTH_URL:s.VENMO_MOBILE_APP_AUTH_ONLY_URL}i.exports=a},{"./constants":253}],257:[function(n,i,r){var s=n("./browser-detection"),a=n("../../lib/in-iframe");function o(h){return h=h||{},{merchantAllowsDesktopBrowsers:(h.allowDesktopWebLogin||h.allowDesktop)===!0,merchantAllowsReturningToNewBrowserTab:h.hasOwnProperty("allowNewBrowserTab")?h.allowNewBrowserTab:!0,merchantAllowsNonDefaultBrowsers:h.hasOwnProperty("allowNonDefaultBrowsers")?h.allowNonDefaultBrowsers:!0,merchantAllowsWebviews:h.hasOwnProperty("allowWebviews")?h.allowWebviews:!0}}function l(){var h=s.isAndroid(),m=h&&s.isChrome(),v=s.isIos(),_=s.isIosSafari(),b=h||v,w=_||m,C=s.isAndroidWebview()||s.isIosWebview();return{isAndroid:h,isAndroidChrome:m,isIos:v,isIosSafari:_,isMobileDevice:b,isMobileDeviceThatSupportsReturnToSameTab:w,isWebview:C}}function c(h,m){var v=(h.merchantAllowsNonDefaultBrowsers||h.merchantAllowsReturningToNewBrowserTab)&&!a();return v&&s.isIosChrome()?!1:m.isIos&&!m.isIosSafari||m.isAndroid&&!m.isAndroidChrome?!h.merchantAllowsReturningToNewBrowserTab:s.isFacebookOwnedBrowserOnAndroid()}function d(h,m){return!h.merchantAllowsWebviews&&m.isWebview}function u(){var h=l();return h.isMobileDevice&&!h.isIosSafari&&!h.isAndroidChrome}function p(h){var m=o(h),v=l();return u()&&!m.merchantAllowsNonDefaultBrowsers||d(m,v)||c(m,v)?!1:v.isMobileDevice?!0:m.merchantAllowsDesktopBrowsers}i.exports={isBrowserSupported:p,isNonDefaultBrowser:u}},{"../../lib/in-iframe":175,"./browser-detection":252}],258:[function(n,i,r){var s=n("../../lib/frame-service/external"),a=n("../../lib/use-min"),o=n("@braintree/extended-promise"),l=n("../shared/errors"),c=n("../../lib/braintree-error"),d="3.140.0",u=`<svg width="198" height="58" viewBox="0 0 198 58" fill="none" xmlns="http://www.w3.org/2000/svg">
196  <path fill-rule="evenodd" clip-rule="evenodd" d="M43.0702 13.6572C44.1935 15.4585 44.6999 17.3139 44.6999 19.6576C44.6999 27.1328 38.1277 36.8436 32.7935 43.6625H20.6099L15.7236 15.2939L26.3917 14.3105L28.9751 34.4966C31.389 30.6783 34.3678 24.6779 34.3678 20.587C34.3678 18.3477 33.9727 16.8225 33.3553 15.5666L43.0702 13.6572Z" fill="white"/>
197  <path fill-rule="evenodd" clip-rule="evenodd" d="M56.8965 26.1491C58.8596 26.1491 63.8018 25.2772 63.8018 22.5499C63.8018 21.2402 62.8481 20.587 61.7242 20.587C59.7579 20.587 57.1776 22.8763 56.8965 26.1491ZM56.6715 31.5506C56.6715 34.8807 58.5787 36.1873 61.107 36.1873C63.8603 36.1873 66.4966 35.534 69.923 33.8433L68.6324 42.3523C66.2183 43.4976 62.4559 44.2617 58.8039 44.2617C49.5403 44.2617 46.2249 38.8071 46.2249 31.9879C46.2249 23.1496 51.6179 13.765 62.7365 13.765C68.858 13.765 72.2809 17.0949 72.2809 21.7317C72.2815 29.2066 62.4005 31.4965 56.6715 31.5506Z" fill="white"/>
198  <path fill-rule="evenodd" clip-rule="evenodd" d="M103.067 20.3142C103.067 21.4052 102.897 22.9875 102.727 24.0216L99.5262 43.6622H89.1385L92.0585 25.658C92.1139 25.1696 92.284 24.1865 92.284 23.6411C92.284 22.3314 91.4414 22.0047 90.4282 22.0047C89.0826 22.0047 87.7337 22.6042 86.8354 23.0418L83.5234 43.6625H73.0772L77.8495 14.257H86.8908L87.0052 16.6041C89.1382 15.2404 91.9469 13.7656 95.932 13.7656C101.212 13.765 103.067 16.3845 103.067 20.3142Z" fill="white"/>
199  <path fill-rule="evenodd" clip-rule="evenodd" d="M133.906 16.9841C136.881 14.9131 139.69 13.765 143.563 13.765C148.897 13.765 150.753 16.3845 150.753 20.3142C150.753 21.4052 150.583 22.9875 150.413 24.0216L147.216 43.6622H136.825L139.801 25.2774C139.855 24.786 139.971 24.1865 139.971 23.8063C139.971 22.3317 139.128 22.0047 138.115 22.0047C136.824 22.0047 135.535 22.5501 134.577 23.0418L131.266 43.6625H120.878L123.854 25.2777C123.908 24.7863 124.02 24.1868 124.02 23.8065C124.02 22.332 123.177 22.0049 122.167 22.0049C120.819 22.0049 119.473 22.6045 118.574 23.0421L115.26 43.6628H104.817L109.589 14.2573H118.52L118.8 16.7122C120.878 15.241 123.684 13.7662 127.446 13.7662C130.704 13.765 132.837 15.129 133.906 16.9841Z" fill="white"/>
200  <path fill-rule="evenodd" clip-rule="evenodd" d="M171.426 25.5502C171.426 23.1496 170.808 21.513 168.956 21.513C164.857 21.513 164.015 28.55 164.015 32.1498C164.015 34.8807 164.802 36.5709 166.
200653 36.5709C170.528 36.5709 171.426 29.1497 171.426 25.5502ZM153.458 31.7152C153.458 22.442 158.511 13.765 170.136 13.765C178.896 13.765 182.098 18.7854 182.098 25.7148C182.098 34.8805 177.099 44.3723 165.194 44.3723C156.378 44.3723 153.458 38.7525 153.458 31.7152Z" fill="white"/>
201</svg>`,p="Tap cancel payment to cancel and return to the business. Continue payment will relaunch the payment window.",h=400,m=570,v={backdrop:"venmo-desktop-web-backdrop",backdropHidden:"venmo-desktop-web-backdrop.hidden",backdropContainer:"venmo-backdrop-container",cancelButton:"venmo-popup-cancel-button",continueButton:"venmo-popup-continue-button",message:"venmo-message",instructions:"venmo-instructions",venmoLogo:"venmo-full-logo"};o.suppressUnhandledPromiseMessage=!0;function _(y){var P=y.frameServiceInstance,A=y.venmoUrl,I=y.checkForStatusChange,L=y.cancelTokenization,D=y.checkPaymentContextStatus,z=new o;return document.getElementById(v.continueButton).addEventListener("click",function(){P.focus()}),document.getElementById(v.cancelButton).addEventListener("click",function(){P.close(),L(),w()}),P.open({},function(G){var ne=1;G?z.reject(G):I(ne).then(function(W){z.resolve(W)}).catch(function(W){D().then(function(ue){ue.status==="CREATED"?z.reject(new c(l.VENMO_CUSTOMER_CANCELED)):z.reject(W)})}),P.close(),w()}),P.redirect(A),z}function b(){var y=Math.round((window.outerHeight-m)/2)+window.screenTop,P=Math.round((window.outerWidth-h)/2)+window.screenLeft;return{top:y,left:P}}function w(){document.getElementById("venmo-desktop-web-backdrop").classList.add("hidden")}function C(){var y=["#"+v.backdropHidden+" {","display: none;","}","#"+v.backdrop+" {","z-index: 3141592632;","cursor: pointer;","position: fixed;","top: 0;","left: 0;","bottom: 0;","width: 100%;","background: rgba(0, 0, 0, 0.8);","}"],P=["#"+v.backdropContainer+" {","display: flex;","align-content: center;","justify-content: center;","align-items: center;","width: 100%;","height: 100%;","flex-direction: column;","}"],A=["#"+v.cancelButton+" {","height: 24px;","width: 380px;","font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif;","font-style: normal;","font-weight: 700;","font-size: 18px;","line-height: 24px;","text-align: center;","background-color: transparent;","border: none;","color: #FFFFFF;","margin-top: 28px;","}"],I=["#"+v.continueButton+" {","width: 400px;","height: 50px;","background: #0074DE;","border-radius: 24px;","border: none;","font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif;","font-style: normal;","font-weight: 700;","font-size: 18px;","color: #FFFFFF;","margin-top: 44px;","}"],L=["#"+v.message+" {","font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif;","font-style: normal;","font-weight: 500;","font-size: 24px;","line-height: 32px;","text-align: center;","color: #FFFFFF;","margin-top: 32px;","}"],D=["#"+v.instructions+" {","font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif;","font-style: normal;","font-weight: 400;","font-size: 16px;","line-height: 20px;","text-align: center;","color: #FFFFFF;","margin-top: 16px;","width: 400px;","}"],z=y.concat(P,A,I,L,D);return z.join(`
202`)}function O(y){var P=document.getElementById(v.backdrop),A,I,L,D,z,G,ne,W;if(P){P.classList.remove("hidden");return}A=document.createElement("style"),I=document.createElement("div"),L=document.createElement("div"),D=document.createElement("div"),z=document.createElement("div"),G=document.createElement("div"),ne=document.createElement("button"),W=document.createElement("button"),y&&(A.nonce=y),A.id="venmo-desktop-web__injected-styles",A.innerHTML=C(),I.id=v.backdrop,L.id=v.backdropContainer,D.id=v.venmoLogo,D.innerHTML=u,z.id=v.message,z.innerText="What would you like to do?",G.id=v.instructions,G.innerText=p,ne.id=v.continueButton,ne.innerText="Continue payment",W.id=v.cancelButton,W.innerText="Cancel payment",document.head.appendChild(A),L.appendChild(D),L.appendChild(z),L.appendChild(G),L.appendChild(ne),L.appendChild(W),I.appendChild(L),document.body.appendChild(I),I.addEventListener("click",function(ue){ue.stopPropagation()})}function T(y){return O(y.styleCspNonce),_(y)}function E(y){var P=new o,A="venmoDesktopWebLogin",I=y.assetsUrl,L=y.debug||!1,D=b(),z=I+"/web/"+d+"/html";return s.create({name:A,dispatchFrameUrl:z+"/dispatch-frame"+a(L)+".html",openFrameUrl:z+"/venmo-landing-frame"+a(L)+".html",top:D.top,left
202:D.left,height:m,width:h},function(G){P.resolve(G)}),P}i.exports={runWebLogin:T,openPopup:_,setupDesktopWebLogin:E,POPUP_WIDTH:h,POPUP_HEIGHT:m}},{"../../lib/braintree-error":149,"../../lib/frame-service/external":163,"../../lib/use-min":187,"../shared/errors":254,"@braintree/extended-promise":34}],259:[function(n,i,r){var s=n("../lib/analytics"),a=n("../lib/assign").assign,o=n("./shared/supports-venmo"),l=n("./shared/browser-detection"),c=n("./shared/constants"),d=n("./shared/errors"),u=n("../lib/querystring"),p=n("../lib/is-verified-domain"),h=n("../lib/methods"),m=n("../lib/convert-methods-to-error"),v=n("@braintree/wrap-promise"),_=n("../lib/braintree-error"),b=n("../lib/in-iframe"),w=n("@braintree/extended-promise"),C=n("./shared/get-venmo-url"),O=n("./shared/web-login-backdrop"),T=n("../lib/snake-case-to-camel-case"),E=n("../lib/url-params"),y=n("./external/"),P=n("./external/queries"),A="3.140.0",I=250,L=3e5;w.suppressUnhandledPromiseMessage=!0;function D(x){var V=this;this._allowDesktopWebLogin=x.allowDesktopWebLogin||!1,this._mobileWebFallBack=x.mobileWebFallBack||!1,this._createPromise=x.createPromise,this._allowNewBrowserTab=x.allowNewBrowserTab!==!1,this._allowWebviews=x.allowWebviews!==!1,this._allowDesktop=x.allowDesktop===!0,this._useRedirectForIOS=x.useRedirectForIOS===!0,this._profileId=x.profileId,this._displayName=x.displayName,this._deepLinkReturnUrl=x.deepLinkReturnUrl,this._ignoreHistoryChanges=x.ignoreHistoryChanges,this._paymentMethodUsage=(x.paymentMethodUsage||"").toUpperCase(),this._shouldUseLegacyFlow=!this._paymentMethodUsage,this._requireManualReturn=x.requireManualReturn===!0,this._useDesktopQRFlow=this._allowDesktop&&this._isDesktop()&&!this._allowDesktopWebLogin,this._useAllowDesktopWebLogin=this._allowDesktopWebLogin&&this._isDesktop(),this._cannotHaveReturnUrls=b()||this._requireManualReturn,this._allowAndroidRecreation=x.allowAndroidRecreation!==!1,this._allowNonDefaultBrowsers=x.allowNonDefaultBrowsers!==!1,this._maxRetryCount=3,this._collectCustomerBillingAddress=x.collectCustomerBillingAddress||!1,this._collectCustomerShippingAddress=x.collectCustomerShippingAddress||!1,this._cancelOnReturnToBrowser=x.cancelOnReturnToBrowser===!0,this._isFinalAmount=x.isFinalAmount||!1,this._lineItems=x.lineItems,this._subTotalAmount=x.subTotalAmount,this._discountAmount=x.discountAmount,this._taxAmount=x.taxAmount,this._shippingAmount=x.shippingAmount,this._totalAmount=x.totalAmount,this._cspNonce=(this._mobileWebFallBack||this._allowDesktopWebLogin)&&(x.styleCspNonce||!1),this._mobilePollingInterval=I,this._mobilePollingExpiresThreshold=L,this._pollCount=0,this._riskCorrelationId=x.riskCorrelationId,this._shouldCreateVenmoPaymentContext=this._cannotHaveReturnUrls||!this._shouldUseLegacyFlow,this._isIncognito=x._isIncognito,this._enableVenmoSandbox=x.enableVenmoSandbox||!1,s.sendEvent(this._createPromise,"venmo.options.is-incognito."+String(!!this._isIncognito)),s.sendEvent(this._createPromise,"venmo.desktop-flow.configured."+String(!!this._allowDesktop)),this.hasTokenizationResult()?s.sendEvent(this._createPromise,"venmo.appswitch.return-in-new-tab"):this._useDesktopQRFlow?this._createPromise=this._createPromise.then(function(te){var fe=te.getConfiguration().gatewayConfiguration;return y({url:fe.assetsUrl+"/web/"+A+"/html/venmo-desktop-frame.html",environment:fe.environment==="production"?"PRODUCTION":"SANDBOX",profileId:V._profileId||fe.payWithVenmo.merchantId,paymentMethodUsage:V._paymentMethodUsage,riskCorrelationId:V._riskCorrelationId,displayName:V._displayName,Promise,apiRequest:function(re,be){return te.request({api:"graphQLApi",data:{query:re,variables:be}}).then(function(Y){return Y.data})},sendEvent:function(re){s.sendEvent(V._createPromise,re)},verifyDomain:p}).then(function(re){return V._venmoDesktopInstance=re,s.sendEvent(V._createPromise,"venmo.desktop-flow.presented"),te}).catch(function(){return s.sendEvent(V._createPromise,"venmo.desktop-flow.setup-failed"),V._useDesktopQRFlow=!1,te})}):this._shouldCreateVenmoPaymentContext&&(this._createPromise=this._createPromise.then(function(te){var fe,re,be=V._cannotHaveReturnUrls?"manual-return":"mobile-payment-context",Y=te.getConfiguration();return re=O.setupDesktopWebLogin({assetsUrl:Y.gatewayConfiguration.assetsUrl,debug:Y.isDebug}).then(function(oe){V._frameServiceInstance=oe}).catch(function(oe){return oe}
202),V._mobilePollingContextEnvironment=Y.gatewayConfiguration.environment.toUpperCase(),fe=V._createVenmoPaymentContext(te).then(function(){return s.sendEvent(V._createPromise,"venmo."+be+".presented"),te}).catch(function(oe){return s.sendEvent(V._createPromise,"venmo."+be+".setup-failed"),Promise.reject(new _({type:d.VENMO_MOBILE_PAYMENT_CONTEXT_SETUP_FAILED.type,code:d.VENMO_MOBILE_PAYMENT_CONTEXT_SETUP_FAILED.code,message:z(oe)?oe.details.originalError[0].message:d.VENMO_MOBILE_PAYMENT_CONTEXT_SETUP_FAILED.message,details:{originalError:oe}}))}),w.all([re,fe]).then(function(oe){var K=oe[1];return Promise.resolve(K)}).catch(function(oe){return Promise.reject(oe)})}))}function z(x){return x.details&&x.details.originalError&&x.details.originalError[0]&&x.details.originalError[0].extensions&&x.details.originalError[0].extensions.errorClass==="VALIDATION"&&x.details.originalError[0].extensions.errorType==="user_error"}D.prototype._createVenmoPaymentContext=function(x,V){var te=this,fe,re,be=x.getConfiguration(),Y=be.gatewayConfiguration.payWithVenmo,oe=!1,K=te._useAllowDesktopWebLogin?"NATIVE_WEB":"MOBILE_WEB";if(!this._shouldCreateVenmoPaymentContext)return Promise.resolve();if(this._shouldUseLegacyFlow)fe=x.request({api:"graphQLApi",data:{query:P.LEGACY_CREATE_PAYMENT_CONTEXT_QUERY,variables:{input:{environment:this._mobilePollingContextEnvironment,intent:"PAY_FROM_APP"}}}}).then(function(Z){return Z.data.createVenmoQRCodePaymentContext.venmoQRCodePaymentContext});else{if((this._collectCustomerBillingAddress||this._collectCustomerShippingAddress)&&!Y.enrichedCustomerDataEnabled)return Promise.reject(new _(d.VENMO_ECD_DISABLED));this._lineItems&&this._lineItems.forEach(function(Z){Z.unitTaxAmount=Z.unitTaxAmount||"0"}),re={subTotalAmount:this._subTotalAmount,discountAmount:this._discountAmount,taxAmount:this._taxAmount,shippingAmount:this._shippingAmount,totalAmount:this._totalAmount,lineItems:this._lineItems},oe=Object.keys(re).some(function(Z){return re[Z]!==void 0}),fe=x.request({api:"graphQLApi",data:{query:P.CREATE_PAYMENT_CONTEXT_QUERY,variables:{input:{venmoRiskCorrelationId:this._riskCorrelationId,paymentMethodUsage:this._paymentMethodUsage,intent:"CONTINUE",customerClient:K,isFinalAmount:this._isFinalAmount,displayName:this._displayName,paysheetDetails:{collectCustomerBillingAddress:this._collectCustomerBillingAddress,collectCustomerShippingAddress:this._collectCustomerShippingAddress,transactionDetails:oe?re:void 0}}}}}).then(function(Z){return Z.data.createVenmoPaymentContext.venmoPaymentContext})}return fe.then(function(Z){var me=new Date(Z.expiresAt)-new Date(Z.createdAt),q=me*.6666;clearTimeout(te._refreshPaymentContextTimeout),te._refreshPaymentContextTimeout=setTimeout(function(){te._tokenizationInProgress||te._createVenmoPaymentContext(x,!0)},q),!(V&&te._tokenizationInProgress)&&(te._venmoPaymentContextStatus=Z.status,te._venmoPaymentContextId=Z.id)})},D.prototype._popupBridgeIsInstalled=function(){return window.popupBridge&&typeof window.popupBridge.open=="function"},D.prototype._venmoNativeAppIsInstalled=function(){return!!(window.popupBridge&&(window.parent&&window.parent.popupBridge.isVenmoInstalled||window.popupBridge.isVenmoInstalled))},D.prototype._handleDeepLinkAppSwitch=function(x){H()?this._handleIosWebviewDeepLink(x):this._popupBridgeIsInstalled()?this._handlePopupBridgeAppSwitch(x):l.isAndroidWebview()?(s.sendEvent(this._createPromise,"venmo.appswitch.start.android-webview-redirect"),b()?this._handleIFrameBreakout(x):window.location.href=x):l.isAndroid()&&!l.isWebview()?(s.sendEvent(this._createPromise,"venmo.appswitch.start.android-browser-redirect"),b()?this._handleIFrameBreakout(x):window.location.href=x):(s.sendEvent(this._createPromise,"venmo.appswitch.start.webview"),this._venmoWindow=window.open(x))},D.prototype._handleIosWebviewDeepLink=function(x){s.sendEvent(this._createPromise,"venmo.appswitch.start.ios-webview"),b()?this._handleIosWebviewInIframe(x):!this._venmoNativeAppIsInstalled()&&this._popupBridgeIsInstalled()?this._handlePopupBridgeAppSwitch(x):window.location.href=x},D.prototype._handleIosWebviewInIframe=function(x){this._venmoNativeAppIsInstalled()?this._handleIFrameBreakout(x):this._popupBridgeIsInstalled()?this._handlePopupBridgeAppSwitch(x):this._handleIFrameBreakout(x)},D.prototype._handlePopupBridgeAppSwitch=function(x){s.sendEvent(this._createPromise,"venmo.appswitch.start.popup-bridge"),window.popupBridge.open(x)},D.prototype._handleBrowserAppSwitch=function(x){s.sendEvent(this._createPromise,"venmo.appswitch.start.browser"),l.doesNotSupportWindowOpenInIos()||this._shouldUseRedirectStrategy()?window.location.href=x:b()&&l.isAndroid()&&l.isChrome()?(s.sendEvent(this._createPromise,"venmo.appswitch.start.chrome-android-iframe-breakout"),this._handleIFrameBreakout(x)):this._mobileWebFallBack&&l.isAndroid()&&l.isChrome()?window.location.href=x:this._venmoWindow=window.open(x)},D.prototype._handleIFrameBreakout=function(x){window.top.location.href=x},D.prototype.appSwitch=function(x){this._deepLinkReturnUrl?this._handleDeepLinkAppSwitch(x):this._handleBrowserAppSwitch(x)},D.prototype.getUrl=function(){return this._createPromise.then((function(x){var V=x.getConfiguration(),te={},fe=this._deepLinkReturnUrl||window.location.href.replace(window.location.hash,""),re=V.gatewayConfiguration.payWithVenmo,be=V.analyticsMetadata,Y=re.accessToken,oe={_meta:{version:be.sdkVersion,integration:be.integration,platform:be.platform,sessionId:be.sessionId}};return this._isDebug=V.isDebug,this._assetsUrl=V.gatewayConfiguration.assetsUrl,fe=fe.replace(/#*$/,""),this._venmoPaymentContextId&&(this._shouldUseLegacyFlow?Y+="|pcid:"+this._venmoPaymentContextId:te.resource_id=this._venmoPaymentContextId),this._riskCorrelationId&&(te["client-metadata-id"]=this._riskCorrelationId),this._shouldIncludeReturnUrls()||this._useAllowDesktopWebLogin?(this._useAllowDesktopWebLogin&&(fe=this._assetsUrl+"/web/"+A+"/html/redirect-frame.html"),te["x-success"]=fe+"#venmoSuccess=1",te["x-cancel"]=fe+"#venmoCancel=1",te["x-error"]=fe+"#venmoError=1"):(te["x-success"]="NOOP",te["x-cancel"]="NOOP",te["x-error"]="NOOP"),this._allowAndroidRecreation?te.allowAndroidRecreation=1:te.allowAndroidRecreation=0,te.ua=window.navigator.userAgent,te.braintree_merchant_id=this._profileId||re.merchantId,te.braintree_access_token=Y,te.braintree_environment=re.environment,te.braintree_sdk_data=btoa(JSON.stringify(oe)),C({useAllowDesktopWebLogin:this._useAllowDesktopWebLogin,mobileWebFallBack:this._mobileWebFallBack,enableVenmoSandbox:this._enableVenmoSandbox,environment:re.environment})+"?"+u.stringify(te)}).bind(this))},D.prototype.isBrowserSupported=function(){return o.isBrowserSupported({allowNewBrowserTab:this._allowNewBrowserTab,allowWebviews:this._allowWebviews,allowDesktop:this._allowDesktop,allowDesktopWebLogin:this._allowDesktopWebLogin,allowNonDefaultBrowsers:this._allowNonDefaultBrowsers})},D.prototype.hasTokenizationResult=function(){return this._hasTokenizationResult()},D.prototype._hasTokenizationResult=function(x){var V=G(x),te={},fe=E.getUrlParams(),re=window;try{window.top&&window.top!==window&&window.top.location&&(re=window.top,te=G(re.location.hash))}catch{}return fe.resource_id?this._venmoPaymentContextId=fe.resource_id:V.id?this._venmoPaymentContextId=V.id:te.id&&(this._venmoPaymentContextId=te.id),typeof(V.venmoSuccess||V.venmoError||V.venmoCancel||te.venmoSuccess||te.venmoError||te.venmoCancel)<"u"},D.prototype._shouldIncludeReturnUrls=function(){return o.isNonDefaultBrowser()&&!l.isWebview()&&!l.isAndroid()?!!this._deepLinkReturnUrl&&this._shouldUseRedirectStrategy():this._deepLinkReturnUrl?!0:this._cannotHaveReturnUrls?!1:this._isIncognito&&l.isIosSafari()?!0:!this._isIncognito},D.prototype._isDesktop=function(){return!(l.isIos()||l.isAndroid())},D.prototype._isIOSIframeWithoutVenmoApp=function(){return l.isIos()&&b()&&!this._venmoNativeAppIsInstalled()&&!this._requireManualReturn},D.prototype.tokenize=function(x){var V=this,te;return x=x||{},this._tokenizationInProgress===!0?Promise.reject(new _(d.VENMO_TOKENIZATION_REQUEST_ACTIVE)):(this._tokenizationInProgress=!0,this._useDesktopQRFlow?te=this._tokenizeForDesktopQRFlow(x):this._useAllowDesktopWebLogin?te=this._tokenizeWebLoginWithRedirect(x
202):this._cannotHaveReturnUrls&&!this._isIOSIframeWithoutVenmoApp()?te=this._tokenizeForMobileWithManualReturn():te=this._tokenizeForMobileWithHashChangeListeners(x),te.then(function(fe){return V._createPromise.then(function(re){return V._createVenmoPaymentContext(re)}).then(function(){return V._tokenizationInProgress=!1,V._venmoWindow=null,W(fe)})}).catch(function(fe){return V._createPromise.then(function(re){return V._createVenmoPaymentContext(re)}).then(function(){return V._tokenizationInProgress=!1,V._venmoWindow=null,Promise.reject(fe)})}))},D.prototype.cancelTokenization=function(){return this._tokenizationInProgress?(this._removeVisibilityEventListener(),this._tokenizePromise&&this._tokenizePromise.reject(new _(d.VENMO_TOKENIZATION_CANCELED_BY_MERCHANT)),this._pollingInProgress=!1,Promise.all([this._cancelMobilePaymentContext(),this._cancelVenmoDesktopContext()])):Promise.reject(new _(d.VENMO_TOKENIZATION_REQUEST_NOT_ACTIVE))},D.prototype._tokenizeWebLoginWithRedirect=function(){var x=this,V;return s.sendEventPlus(x._createPromise,"venmo.tokenize.web-login.start",{context_id:x._venmoPaymentContextId}),this._tokenizePromise=new w,this.getUrl().then(function(te){return V={checkForStatusChange:x._checkPaymentContextStatusAndProcessResult.bind(x),cancelTokenization:x.cancelTokenization.bind(x),frameServiceInstance:x._frameServiceInstance,venmoUrl:te,debug:x._isDebug,checkPaymentContextStatus:x._checkPaymentContextStatus.bind(x)},x._cspNonce&&(V=a({},V,{styleCspNonce:x._cspNonce})),O.runWebLogin(V).then(function(fe){s.sendEventPlus(x._createPromise,"venmo.tokenize.web-login.success",{context_id:x._venmoPaymentContextId}),x._tokenizePromise.resolve({paymentMethodNonce:fe.paymentMethodId,username:fe.userName,payerInfo:fe.payerInfo,id:x._venmoPaymentContextId})}).catch(function(fe){s.sendEventPlus(x._createPromise,"venmo.tokenize.web-login.failure",{context_id:x._venmoPaymentContextId}),x._tokenizePromise.reject(fe)}),x._tokenizePromise})},D.prototype._queryPaymentContextStatus=function(x){var V=this;return this._createPromise.then(function(te){var fe=V._shouldUseLegacyFlow?P.LEGACY_VENMO_PAYMENT_CONTEXT_STATUS_QUERY:P.VENMO_PAYMENT_CONTEXT_STATUS_QUERY;return te.request({api:"graphQLApi",data:{query:fe,variables:{id:x}}})}).then(function(te){return te.data.node})},D.prototype._checkPaymentContextStatusAndProcessResult=function(x){var V=this;return V._checkPaymentContextStatus().then(function(te){var fe=te.status;if(fe!==V._venmoPaymentContextStatus)switch(V._venmoPaymentContextStatus=fe,s.sendEventPlus(V._createPromise,"venmo.tokenize.web-login.status-change",{context_id:V._venmoPaymentContextId}),fe){case"APPROVED":return Promise.resolve(te);case"CANCELED":return Promise.reject(new _(d.VENMO_CUSTOMER_CANCELED));case"FAILED":return Promise.reject(new _(d.VENMO_TOKENIZATION_FAILED))}return new Promise(function(re,be){x<V._maxRetryCount?(x++,V._checkPaymentContextStatusAndProcessResult(x).then(re).catch(be)):be(new _(d.VENMO_TOKENIZATION_FAILED))})})},D.prototype._checkPaymentContextStatus=function(){var x=this;return x._queryPaymentContextStatus(x._venmoPaymentContextId).catch(function(V){return Promise.reject(new _({type:d.VENMO_NETWORK_ERROR.type,code:d.VENMO_NETWORK_ERROR.code,message:d.VENMO_NETWORK_ERROR.message,details:V}))}).then(function(V){return Promise.resolve(V)})},D.prototype._validatePollingContext=function(){return this._venmoPaymentContextId?Date.now()>this._mobilePollingContextExpiresIn?Promise.reject(new _(d.VENMO_MOBILE_POLLING_TOKENIZATION_TIMEOUT)):null:Promise.reject(new _(d.VENMO_MOBILE_POLLING_TOKENIZATION_NO_CONTEXT_ID))},D.prototype._handleWindowClosure=function(){var x=this;return x._venmoWindow&&x._venmoWindow.closed&&x._venmoPaymentContextStatus==="CREATED"&&x._cancelOnReturnToBrowser===!0?(s.sendEventPlus(x._createPromise,"venmo.appswitch.browser-window.closed",{context_id:x._venmoPaymentContextId}),x._cancelMobilePaymentContext().then(function(){s.sendEventPlus(x._createPromise,"venmo.tokenize.manual-return.canceled",{context_id:x._venmoPaymentContextId})}).catch(function(V){s.sendEventPlus(x._createPromise,"venmo.tokenize.manual-return.canceled.error",{context_id:x._venmoPaymentContextId})}),Promise.reject(new _(d.VENMO_MOBILE_POLLING_TOKENIZATION_CANCELED))):null},D.prototype._handleCancelOnReturn=function(){var x=this,V,te;return x._cancelOnReturnToBrowser?(V=Math.ceil(c.DEFAULT_PROCESS_RESULTS_DELAY/x._mobilePollingInterval),te=G(),x._pollCount++,typeof(te.venmoSuccess||te.venmoError||te.venmoCancel)>"u"&&x._venmoPaymentContextStatus==="CREATED"&&x._pollCount>=V?(s.sendEventPlus(x._createPromise,"venmo.appswitch.cancel-on-return-to-browser",{context_id:x._venmoPaymentContextId}),x._cancelMobilePaymentContext().then(function(){s.sendEventPlus(x._createPromise,"venmo.appswitch.cancel-on-return-to-browser.success",{context_id:x._venmoPaymentContextId})}).catch(function(){s.sendEventPlus(x._createPromise,"venmo.appswitch.cancel-on-return-to-browser.error",{context_id:x._venmoPaymentContextId})}).finally(function(){x._pollCount=0})):null):null},D.prototype._handleStatusChange=function(x){var V=this,te=x.status;if(te!==V._venmoPaymentContextStatus)switch(V._venmoPaymentContextStatus=te,s.sendEventPlus(V._createPromise,"venmo.tokenize.manual-return.status-change."+te.toLowerCase(),{context_id:V._venmoPaymentContextId}
202),te){case"EXPIRED":case"FAILED":case"CANCELED":return Promise.reject(new _(d["VENMO_MOBILE_POLLING_TOKENIZATION_"+te]));case"APPROVED":return Promise.resolve(x)}return V._continuePolling()},D.prototype._continuePolling=function(){var x=this;return new Promise(function(V,te){setTimeout(function(){x._pollForStatusChange().then(V).catch(te)},x._mobilePollingInterval)})},D.prototype._queryAndProcessStatus=function(){var x=this;return this._queryPaymentContextStatus(this._venmoPaymentContextId).catch(function(V){return Promise.reject(new _({type:d.VENMO_MOBILE_POLLING_TOKENIZATION_NETWORK_ERROR.type,code:d.VENMO_MOBILE_POLLING_TOKENIZATION_NETWORK_ERROR.code,message:d.VENMO_MOBILE_POLLING_TOKENIZATION_NETWORK_ERROR.message,details:{originalError:V}}))}).then(function(V){return x._handleStatusChange(V)})},D.prototype._pollForStatusChange=function(){var x=this._validatePollingContext();if(x)return x;var V=this._handleWindowClosure();return V||(this._handleCancelOnReturn(),this._queryAndProcessStatus())},D.prototype._startPolling=function(){var x=this;return this._pollingInProgress?this._tokenizePromise:(this._pollingInProgress=!0,this._pollForStatusChange().then(function(V){x._pollingInProgress=!1,s.sendEventPlus(x._createPromise,"venmo.tokenize.manual-return.success",{context_id:x._venmoPaymentContextId}),x._tokenizePromise.resolve({paymentMethodNonce:V.paymentMethodId,username:V.userName,payerInfo:V.payerInfo,id:x._venmoPaymentContextId})}).catch(function(V){x._pollingInProgress=!1,s.sendEventPlus(x._createPromise,"venmo.tokenize.manual-return.failure",{context_id:x._venmoPaymentContextId}),x._tokenizePromise.reject(V)}),this._tokenizePromise)},D.prototype._tokenizeForMobileWithManualReturn=function(){var x=this;return this._mobilePollingContextExpiresIn=Date.now()+this._mobilePollingExpiresThreshold,this.hasTokenizationResult()?this.processHashChangeFlowResults():(s.sendEventPlus(this._createPromise,"venmo.tokenize.manual-return.start",{context_id:x._venmoPaymentContextId}),this._tokenizePromise=new w,this._startPolling(),this.getUrl().then(function(V){return x.hasTokenizationResult()?x.processHashChangeFlowResults():(x.appSwitch(V),x._tokenizePromise)}))},D.prototype._shouldUseRedirectStrategy=function(){return l.isIos()?this._mobileWebFallBack===!0?!0:this._useRedirectForIOS:!1},D.prototype._tokenizeForMobileWithHashChangeListeners=function(x){var V=this,te,fe;if(this.hasTokenizationResult())return this.processHashChangeFlowResults();s.sendEvent(this._createPromise,"venmo.tokenize.mobile.start"),this._tokenizePromise=new w,this._previousHash=window.location.hash;function re(be){var Y;V.processHashChangeFlowResults(be).catch(function(oe){Y=oe}).then(function(oe){!V._ignoreHistoryChanges&&window.location.hash!==V._previousHash&&(window.location.hash=V._previousHash),V._removeVisibilityEventListener(),Y?V._tokenizePromise.reject(Y):V._tokenizePromise.resolve(oe),delete V._tokenizePromise})}return this._onHashChangeListener=function(be){var Y=be.newURL.split("#")[1];V._hasTokenizationResult(Y)&&(te=!0,clearTimeout(fe),re(Y))},window.addEventListener("hashchange",this._onHashChangeListener,!1),this._visibilityChangeListener=function(){var be=x.processResultsDelay||c.DEFAULT_PROCESS_RESULTS_DELAY;window.document.hidden||(V._venmoWindow&&!V._venmoWindow.closed&&V._venmoWindow.close(),te||(fe=setTimeout(re,be)))},this.getUrl().then(function(be){return V.hasTokenizationResult()?(re(),V._tokenizePromise):(V.appSwitch(be),setTimeout(function(){window.document.addEventListener(ue(),V._visibilityChangeListener)},c.DOCUMENT_VISIBILITY_CHANGE_EVENT_DELAY),V._tokenizePromise)})},D.prototype._tokenizeForDesktopQRFlow=function(){var x=this;return s.sendEvent(this._createPromise,"venmo.tokenize.desktop.start"),this._tokenizePromise=new w,this._createPromise.then(function(){return x._venmoDesktopInstance.launchDesktopFlow()}).then(function(V){x._venmoDesktopInstance.hideDesktopFlow(),s.sendEvent(x._createPromise,"venmo.tokenize.desktop.success"),x._tokenizePromise.resolve(V)}).catch(function(V){if(s.sendEvent(x._createPromise,"venmo.tokenize.desktop.failure"),x._venmoDesktopInstance&&x._venmoDesktopInstance.hideDesktopFlow(),V&&V.reason==="CUSTOMER_CANCELED"){x._tokenizePromise.reject(new _(d.VENMO_DESKTOP_CANCELED));return}x._tokenizePromise.reject(new _({type:d.VENMO_DESKTOP_UNKNOWN_ERROR.type,code:d.VENMO_DESKTOP_UNKNOWN_ERROR.code,message:d.VENMO_DESKTOP_UNKNOWN_ERROR.message,details:{originalError:V}}))}),this._tokenizePromise},D.prototype._cancelMobilePaymentContext=function(){var x=this;return this._createPromise.then(function(V){var te;return x._venmoPaymentContextId?(te=x._shouldUseLegacyFlow?P.LEGACY_UPDATE_PAYMENT_CONTEXT_QUERY:P.UPDATE_PAYMENT_CONTEXT_QUERY,V.request({api:"graphQLApi",data:{query:te,variables:{input:{id:x._venmoPaymentContextId,status:"CANCELED"}}}})):Promise.resolve()})},D.prototype._cancelVenmoDesktopContext=function(){var x=this;return this._createPromise.then(function(){return x._venmoDesktopInstance&&x._venmoDesktopInstance.updateVenmoDesktopPaymentContext("CANCELED"),Promise.resolve()})},D.prototype.teardown=function(){var x=this;return this._removeVisibilityEventListener(),this._createPromise.then((function(){x._venmoDesktopInstance&&x._venmoDesktopInstance.teardown(),clearTimeout(x._refreshPaymentContextTimeout),x._cancelMobilePaymentContext(),m(this,h(D.prototype))}).bind(this))},D.prototype._removeVisibilityEventListener=function(){window.removeEventListener("hashchange",this._onHashChangeListener),window.document.removeEventListener(ue(),this._visibilityChangeListener),delete this._visibilityChangeListener,delete this._onHashChangeListener},D.prototype.processHashChangeFlowResults=function(x){var V=this,te=G(x);return new Promise(function(fe,re){V._shouldUseLegacyFlow?te.venmoSuccess?(s.sendEvent(V._createPromise,"venmo.appswitch.handle.success"),window.popupBridge&&s.sendEvent(V._createPromise,"popup-bridge:venmo:succeeded"),fe(te)):te.venmoError?(s.sendEvent(V._createPromise,"venmo.appswitch.handle.error"),window.popupBridge&&s.sendEvent(V._createPromise,"popup-bridge:venmo:failed"),re(new _({type:d.VENMO_APP_FAILED.type,code:d.VENMO_APP_FAILED.code,message:d.VENMO_APP_FAILED.message,details:{originalError:{message:decodeURIComponent(te.errorMessage),code:te.errorCode}}}))):te.venmoCancel?(s.sendEvent(V._createPromise,"venmo.appswitch.handle.cancel"),window.popupBridge&&s.sendEvent(V._createPromise,"popup-bridge:venmo:canceled"),re(new _(d.VENMO_APP_CANCELED))):(s.sendEvent(V._createPromise,"venmo.appswitch.cancel-or-un
202available"),re(new _(d.VENMO_CANCELED))):(V._pollingInProgress||(V._pollingInProgress=!0),V._pollForStatusChange().then(function(be){return V._pollingInProgress=!1,s.sendEventPlus(V._createPromise,"venmo.appswitch.handle.payment-context-status-query.success",{context_id:V._venmoPaymentContextId}),window.popupBridge&&s.sendEvent(V._createPromise,"popup-bridge:venmo:succeeded"),fe({paymentMethodNonce:be.paymentMethodId,username:be.userName,payerInfo:be.payerInfo,id:V._venmoPaymentContextId})}).catch(function(be){V._pollingInProgress=!1,be.code===d.VENMO_MOBILE_POLLING_TOKENIZATION_CANCELED.code?(window.popupBridge&&s.sendEvent(V._createPromise,"popup-bridge:venmo:canceled"),re(be)):window.popupBridge&&s.sendEvent(V._createPromise,"popup-bridge:venmo:failed"),s.sendEventPlus(V._createPromise,"venmo.process-results.payment-context-status-query-failed",{context_id:V._venmoPaymentContextId}),fe(te)})),V._clearFragmentParameters()})},D.prototype._clearFragmentParameters=function(){this._ignoreHistoryChanges||typeof window.history.replaceState=="function"&&window.location.hash&&history.pushState({},"",window.location.href.slice(0,window.location.href.indexOf("#")))};function G(x){var V="",te="";if(x)V=x;else{V=window.location.hash.substring(1);try{window.top&&window.top!==window&&window.top.location&&(te=window.top.location.hash.substring(1),te&&(V=te))}catch{}}var fe=V.split("&"),re=fe.reduce(function(be,Y){var oe=Y.split("="),K=decodeURIComponent(oe[0]).replace(/\W/g,""),Z=T(K),me=decodeURIComponent(oe[1]);return be[Z]=me,be},{});return re.resourceId&&(re.id=re.resourceId),re}function ne(x){return x=x||"","@"+x.replace("@","")}function W(x){var V={nonce:x.paymentMethodNonce,type:"VenmoAccount",details:{username:ne(x.username),paymentContextId:x.id}};return x.payerInfo&&(V.details.payerInfo=x.payerInfo,V.details.payerInfo.userName=ne(x.payerInfo.userName)),V}function ue(){var x;return typeof window.document.hidden<"u"?x="visibilitychange":typeof window.document.msHidden<"u"?x="msvisibilitychange":typeof window.document.webkitHidden<"u"&&(x="webkitvisibilitychange"),x}function H(){return window.navigator.platform&&/iPhone|iPad|iPod/.test(window.navigator.platform)}i.exports=v.wrapPrototype(D)},{"../lib/analytics":144,"../lib/assign":146,"../lib/braintree-error":149,"../lib/convert-methods-to-error":151,"../lib/in-iframe":175,"../lib/is-verified-domain":179,"../lib/methods":181,"../lib/querystring":183,"../lib/snake-case-to-camel-case":185,"../lib/url-params":186,"./external/":248,"./external/queries":249,"./shared/browser-detection":252,"./shared/constants":253,"./shared/errors":254,"./shared/get-venmo-url":256,"./shared/supports-venmo":257,"./shared/web-login-backdrop":258,"@braintree/extended-promise":34,"@braintree/wrap-promise":43}],260:[function(n,i,r){var s=n("../lib/braintree-error");i.exports={VISA_CHECKOUT_NOT_ENABLED:{type:s.types.MERCHANT,code:"VISA_CHECKOUT_NOT_ENABLED",message:"Visa Checkout is not enabled for this merchant."},VISA_CHECKOUT_INIT_OPTIONS_REQUIRED:{type:s.types.MERCHANT,code:"VISA_CHECKOUT_INIT_OPTIONS_REQUIRED",message:"initOptions requires an object."},VISA_CHECKOUT_PAYMENT_REQUIRED:{type:s.types.MERCHANT,code:"VISA_CHECKOUT_PAYMENT_REQUIRED",message:"tokenize requires callid, encKey, and encPaymentData."},VISA_CHECKOUT_TOKENIZATION:{type:s.types.NETWORK,code:"VISA_CHECKOUT_TOKENIZATION",message:"A network error occurred when processing the Visa Checkout payment."}}},{"../lib/braintree-error":149}],261:[function(n,i,r){var s=n("../lib/basic-component-verification"),a=n("../lib/braintree-error"),o=n("../lib/create-deferred-client"),l=n("../lib/create-assets-url"),c=n("./visa-checkout"),d=n("../lib/analytics"),u=n("./errors"),p="3.140.0",h=n("@braintree/wrap-promise");function m(v){var _="Visa Checkout";return s.verify({name:_,client:v.client,authorization:v.authorization}).then(function(){return o.create({authorization:v.authorization,client:v.client,debug:v.debug,assetsUrl:l.create(v.authorization),name:_})}).then(function(b){return v.client=b,v.client.getConfiguration().gatewayConfiguration.visaCheckout?(d.sendEvent(v.client,"visacheckout.initialized"),new c(v)):Promise.reject(new a(u.VISA_CHECKOUT_NOT_ENABLED))})}i.exports={create:h(m),VERSION:p}},{"../lib/analytics":144,"../lib/basic-component-verification":147,"../lib/braintree-error":149,"../lib/create-assets-url":153,"../lib/create-deferred-client":155,"./errors":260,"./visa-checkout":262,"@braintree/wrap-promise":43}],262:[function(n,i,r){var s=n("../lib/braintree-error"),a=n("../lib/analytics"),o=n("./errors"),l=n("../lib/json-clone"),c=n("../lib/methods"),d=n("../lib/convert-methods-to-error"),u=n("@braintree/wrap-promise"),p={Visa:"VISA",MasterCard:"MASTERCARD",Discover:"DISCOVER","American Express":"AMEX"};function h(v){this._client=v.client}function m(v){return v.reduce(function(_,b){return p.hasOwnProperty(b)?_.concat(p[b]):_},[])}h.prototype.createInitOptions=function(v){var _,b=this._client.getConfiguration().gatewayConfiguration,w=b.visaC
202heckout;if(!v)throw new s(o.VISA_CHECKOUT_INIT_OPTIONS_REQUIRED);return _=l(v),_.apikey=_.apikey||w.apikey,_.encryptionKey=w.encryptionKey,_.externalClientId=_.externalClientId||w.externalClientId,_.settings=_.settings||{},_.settings.dataLevel="FULL",_.settings.payment=_.settings.payment||{},_.settings.payment.cardBrands||(_.settings.payment.cardBrands=m(b.visaCheckout.supportedCardTypes)),_},h.prototype.tokenize=function(v){var _=this;return!v.callid||!v.encKey||!v.encPaymentData?Promise.reject(new s(o.VISA_CHECKOUT_PAYMENT_REQUIRED)):this._client.request({method:"post",endpoint:"payment_methods/visa_checkout_cards",data:{_meta:{source:"visa-checkout"},visaCheckoutCard:{callId:v.callid,encryptedPaymentData:v.encPaymentData,encryptedKey:v.encKey}}}).then(function(b){return a.sendEvent(_._client,"visacheckout.tokenize.succeeded"),b.visaCheckoutCards[0]}).catch(function(b){return a.sendEvent(_._client,"visacheckout.tokenize.failed"),Promise.reject(new s({type:o.VISA_CHECKOUT_TOKENIZATION.type,code:o.VISA_CHECKOUT_TOKENIZATION.code,message:o.VISA_CHECKOUT_TOKENIZATION.message,details:{originalError:b}}))})},h.prototype.teardown=function(){return d(this,c(h.prototype)),Promise.resolve()},i.exports=u.wrapPrototype(h)},{"../lib/analytics":144,"../lib/braintree-error":149,"../lib/convert-methods-to-error":151,"../lib/json-clone":180,"../lib/methods":181,"./errors":260,"@braintree/wrap-promise":43}]},{},[138])(138)})})(ff);var WP=ff.exports;const QP=Qp(WP),ZP=async(e,t,n)=>{const i=ie();let r=window.location.href,s=null;if(n==="affirm_direct"||n==="paybright_direct"){const a={nonce:e,agreement1:1,payment_type:n,braintree_device_data:s,...n==="affirm_direct"&&{origin:"optician"}};return r.includes("localhost")&&(a.environment="local"),$fetch(`https://${se()}/api/payment/finish`,{method:"POST",credentials:"include",body:a}).then(o=>o).catch(function(o){return console.log("err",o),o})}else return QP.dataCollector.create({client:i.paymentStore.getBrainTreeClientInstance,paypal:!1}).then(function(a){s=a.deviceData;const o={nonce:e,agreement1:1,payment_type:n,braintree_device_data:s,origin:"optician"};return r.includes("localhost")&&(o.environment="local"),$fetch(`https://${se()}/api/payment/finish`,{method:"POST",credentials:"include",body:o}).then(l=>l)}).catch(function(a){return console.log("err",a),a})},qP=async(e,t,n)=>{const i=window.location.href,r={nonce:e,agreement1:1,payment_type:n,origin:"optician"};return i.includes("localhost")&&(r.environment="local"),$fetch(`https://${se()}/api/payment/finish`,{method:"POST",credentials:"include",body:r}).then(s=>s).catch(function(s){return console.log("err",s),s})},JP=async()=>$fetch(`https://${se()}/api/payment/paypal_logout`,{method:"POST",credentials:"include",body:{}}),XP=async()=>$fetch(`https://${se()}/api/payment/paypal_shipping`,{method:"POST",credentials:"include",body:{}}),eO=async()=>$fetch(`https://${se()}/api/shoppay/payment_request`,{method:"GET",credentials:"include"}).then(e=>e).catch(e=>{console.error(e)}),tO=async e=>$fetch(`https://${se()}/api/shoppay/payment/new`,{method:"POST",credentials:"include",body:{payment_request:e}}),nO=async e=>$fetch(`https://${se()}/api/shoppay/payment/new`,{method:"POST",credentials:"include",body:{delivery_code:e}}),sO=async e=>$fetch(`https://${se()}/api/shoppay/shipping_address`,{method:"POST",credentials:"include",body:e}),iO=async e=>$fetch(`https://${se()}/api/shoppay/coupon`,{method:"POST",credentials:"include",body:e}),rO=async e=>$fetch(`https://${se()}/api/shoppay/payment/confirm`,{method:"POST",credentials:"include",body:e}),aO=async e=>$fetch(`https://${se()}/api/shoppay/payment/complete`,{method:"POST",credentials:"include",body:{complete:e}}),oO=async()=>$fetch(`https://${se()}/api/shoppay/payment_status`,{method:"GET",credentials:"include"}),lO=async(e,t)=>$fetch(`https://${se()}/api/shoppay/payment_cancel`,{method:"POST",credentials:"include",body:{order_id:e,transaction_id:t}}),cO=async()=>$fetch(`https://${se()}
202/api/customer/shipping_information`,{method:"GET",credentials:"include"}),dO=async(e,t,n,i)=>{const s=(t==null?void 0:t.includes("sandbox"))?`sandbox.affirm.${e?"ca":"com"}`:`affirm.${e?"ca":"com"}`;return $fetch(`https://${s}/api/promos/v2/${n}?amount=${i}&field=modal&use_best_terms=true`,{method:"GET",credentials:"include"}).then(a=>a).catch(a=>{console.error(a)})},uO=async e=>$fetch(`https://${se()}/api/payment/string/${e}`,{method:"GET",credentials:"include"}).then(t=>t).catch(t=>{console.error(t)}),hO=async e=>$fetch(`https://${se()}/api/affirm/checkout`,{method:"POST",credentials:"include",body:{string:e,origin:"optician"}}),pO=async(e,t,n,i)=>{const r=window.location.href.includes("localhost");return $fetch(`https://${se()}/api/payment/finish`,{method:"POST",credentials:"include",body:{nonce:e,agreement1:t?1:0,payment_type:n,braintree_device_data:i,origin:"optician",...r&&{environment:"local"}}})},fO=async e=>$fetch(`https://${se()}/api/apple/shipping`,{method:"POST",credentials:"include",body:e}),mO={async finishPaymentProcess(e,t,n){const i=ie();i.systemCheckoutStore.setLoadingFinishPayment(!0);try{const r=i.systemCheckoutStore.getCartGenericData;r.insurance.is_active&&(r.insurance.type==="greenshield"&&(n="greenshield"),r.insurance.type==="rbc"&&(n="rbc"));const s=await ZP(e,t,n);s.success?(localStorage.removeItem("activeThread"),localStorage.removeItem("checkoutChatState"),n==="cc"&&(window.location.href=Ae()+"/ord/receipt"),n==="paypal"&&(s.data.redirect_url===null?window.location.href=Ae()+"/ord/receipt":window.location.href=s.data.redirect_url),n==="affirm_direct"&&(window.location.href=Ae()+"/ord/receipt"),n==="googlepay"&&(window.location.href=Ae()+"/ord/receipt"),n==="applepay"&&(window.location.href=Ae()+"/ord/receipt"),n==="venmo"&&(window.location.href=Ae()+"/ord/receipt"),n==="paypal_finish"&&(window.location.href=Ae()+"/ord/receipt")):(s.errors.forEach(a=>{i.systemStore.addToastMessage("ERROR",a)}),i.systemCheckoutStore.fetchCartMetaData(),i.cartStore.fetchCartProducts(),i.couponStore.fetchCouponCode(),i.cartStore.fetchCartTotals(),i.shippingStore.fetchShippingMethods())}catch{i.systemStore.addToastMessage("ERROR","Something went wrong while placing the order")}finally{i.systemCheckoutStore.setLoadingFinishPayment(!1)}},async finishPaymentProcessVenmo(e,t,n,i){const r=ie();try{(await pO(e,t,n,i)).success?(localStorage.removeItem("activeThread"),localStorage.removeItem("checkoutChatState"),window.location.href=Ae()+"/ord/receipt"):(r.systemStore.addToastMessage("ERROR","Something went wrong with Venmo Payment"),r.cartStore.fetchCartProducts(),r.couponStore.fetchCouponCode(),r.cartStore.fetchCartTotals(),r.shippingStore.fetchShippingMethods())}catch{r.systemStore.addToastMessage("ERROR","Something went wrong while placing the order")}finally{}},async finishPaymentProcessShoppay(e,t,n,i,r){const s=ie();s.systemStore.setLoadingFinishPayment(!0);try{(await qP(e,t,n)).success?(localStorage.removeItem("checkoutChatState"),window.location.href=generateURL("/ord/receipt")):(this.cancelShopifyPayment(i,r),s.systemStore.addToastMessage("ERROR","Something went wrong with Shop Pay Payment"),s.cartStore.fetchCartProducts(),s.couponStore.fetchCouponCode(),s.cartStore.fetchCartTotals(),s.shippingStore.fetchShippingMethods())}catch{s.systemStore.addToastMessage("ERROR","Something went wrong while placing the order"),s.systemStore.setGlobalErrors(["Something went wrong while placing the order"])}finally{s.systemStore.setLoadingFinishPayment(!1)}},async fetchAffirmInfo(e){const n=ie().systemCheckoutStore.getCartGenericData,i=n.STORE_ID,r=OP(i);try{const s=await dO(r,n.AFFIRM_SDK,n.AFFIRM_PUBLIC_KEY,e);this.affirmInfo=s.promo}catch(s){console.log(s)}},async finishPaymentProcessWithAffirm(e){const t=ie();try{return await hO(e)}catch{t.systemStore.addToastMessage("ERROR","Something went wrong with Affirm Payment Provider. Please try again.")}},async syncPayPallShippingAndBillingInformation(){const e=ie();try{const t=await XP();t.success?(t.data.shipping_details.rx_verification_required&&(e.rxVerificationStore.fetchPatient(),e.rxVerificationStore.fetchDoctors(t.data.shipping_details.state)),await e.shippingStore.fetchShippingInfo(),await e.shippingStore.fetchBillingInfo(),e.shippingStore.setFetchingInfoState(!1)):e.systemStore.addToastMessage("ERROR","Something went wrong fetching PayPal Shipping and Billing Details. Please contact us."),e.systemStore.setLoadingShippingAndBillingInfo(!1)}catch{e.systemStore.addToastMessage("ERROR","Something went wrong fetching PayPal Shipping and Billing Details. Please contact us."),e.systemStore.setLoadingShippingAndBillingInfo(!1)}},async fetchProcessString(e){const t=ie();try{const n=await uO(e);n.success?this.saveProcessString(n.string):t.systemStore.addToastMessage("ERROR","Something went wrong. Please try again.")}catch{t.systemStore.addToastMessage("ERROR","Something went wrong. Please try again.")}},async cancelPayPallExpressSession(){const e=ie();try{(await JP()).success?location.reload():e.systemStore.addToastMessage("ERROR","Something went wrong canceling PayPal Session. Please contact us.")}catch{e.systemStore.addToastMessage("ERROR","Something went wrong canceling PayPal Session. Please contact us.")}},async saveApplePayExpressShippingData(e){const t=ie();try{await fO(e),await t.shippingStore.fetchBillingInfo(),t.cartStore.fetchCartTotals(),t.shippingStore.fetchShippingInfo(),nextStepNavButtons(2),t.shippingStore.fetchShippingMethods(),t.upsellStore.fetchUpsells(),t.autoshipStore.fetchAutoshipData()}catch{t.systemStore.addToastMessage("ERROR","Something went wrong with Apple Pay payment. Please contact us.")}},async createShopifyInitialPaymentRequest(){const e=ie();try{const t=await eO();if(t.success)return t;e.systemStore.addToastMessage("ERROR","Something went wrong creating Shopify Initial Payment Request. Please try again.")}catch{e.systemStore.addToastMessage("ERROR","Something went wrong creating Shopify Initial Payment Request. Please try again.")}},async createShopifyPaymentRequest(e){const t=ie();try{const n=await tO(e);if(n.success)return n.data;t.systemStore.addToastMessage("ERROR","Something went wrong creating Shopify Payment Request. Please try again.")}catch{t.systemStore.addToastMessage("ERROR","Something went wrong creating Shopify Payment Request. Please try again.")}},async changeShopifyPaymentDeliveryMethods(e){const t=ie();try{const n=await nO(e);if(n.success)return n.data;t.systemStore.addToastMessage("ERROR","Something went wrong changing Shopify Payment Delivery Methods. Please try again.")}catch{t.systemStore.addToastMessage("ERROR","Something went wrong changing Shopify Payment Delivery Methods. Please try again.")}},async changeShopifyPaymentShippingAddress(e){const t=ie();try{return await sO(e)}catch{t.systemStore.addToastMessage("ERROR","Something went wrong changing Shopify Payment Shipping Address. Please try again.")}},async changeShopifyPaymentCoupon(e){const t=ie();try{const n=await iO(e);if(n.success)return n.data;t.systemStore.addToastMessage("ERROR","Something went wrong changing Shopify Payment Coupon. Please try again.")}catch{t.systemStore.addToastMessage("ERROR","Something went wrong changing Shopify Payment Coupon. Please try again.")}},async createShopifyPaymentConfirmation(e){const t=ie();try{const n=await rO(e);return n.success?n.data:!1}catch{t.systemStore.addToastMessage("ERROR","Something went wrong creating Shopify Payment Confirmation. Please try again.")}},async createShopifyPaymentCompletion(e){const t=ie();try{const n=await aO(e);
202if(n.success)return e&&(window.location.href.includes("localhost")?window.location.href="/ord/checkout?shoppay=processing":window.location.href=n.return_url),n;t.systemStore.addToastMessage("ERROR","Something went wrong creating Shopify Payment Completion. Please try again.")}catch{t.systemStore.addToastMessage("ERROR","Something went wrong creating Shopify Payment Completion. Please try again.")}},async checkShopifyPayment(){var t,n,i,r;const e=ie();try{const s=await oO();if(s.success)return((n=(t=s.payment)==null?void 0:t.status)==null?void 0:n.errorCode)===null&&((r=(i=s==null?void 0:s.payment)==null?void 0:i.status)==null?void 0:r.state)==="COMPLETED"?(s.success=!0,s):(s.success=!1,s);e.systemStore.addToastMessage("ERROR","Something went wrong checking Shopify Payment Status. Please try again. 1")}catch{e.systemStore.addToastMessage("ERROR","Something went wrong checking Shopify Payment Status. Please try again. 2")}},async cancelShopifyPayment(e,t){const n=ie();try{const i=await lO(e,t);if(i.success)return i;n.systemStore.addToastMessage("ERROR","Something went wrong canceling Shopify Payment. Please try again.")}catch{n.systemStore.addToastMessage("ERROR","Something went wrong canceling Shopify Payment. Please try again.")}},async getStateVerificationShopifyPayment(){const e=ie();try{const t=await cO();if(t.success)return t;e.systemStore.addToastMessage("ERROR","Something went wrong getting state verification for Shopify Payment. Please try again.")}catch{e.systemStore.addToastMessage("ERROR","Something went wrong getting state verification for Shopify Payment. Please try again.")}},saveTacToStore(e){this.tacState=e},changeSelectedPayment(e){this.selectedPayment=e},saveBrainTreeClientInstance(e){this.brainTreeClientInstance=e},saveProcessString(e){this.processString=e},setApplePayExpressNonce(e){this.applePayNonce=e},setApplePayExpressActive(e){this.applePayExpressActive=e},checkTacValidation(e){this.tacValidation=e}},gO=Rt("payment",{state:()=>jP,getters:YP,actions:mO}),yO={isLoadingCoupons:!1,activeCoupon:{added:!1,coupon_code:"",coupon_description:"",coupon_msg:"",success:!1},activeVoucher:{added:!1,balance_remaining:null,promo_err:null,promo_msg:null,redeem_need:!1,redeem_result:null,voucher_amount:null,voucher_code:null,voucher_error:null,voucher_source:""}},bO={getIsLoadingCoupons(e){return e.isLoadingCoupons},getActiveCoupon(e){return e.activeCoupon},getActiveVoucher(e){return e.activeVoucher}},vO=async()=>$fetch(`https://${se()}/api/cart/discount_codes`,{method:"GET",credentials:"include"}),_O=async e=>$fetch(`https://${se()}/api/cart/discount_codes`,{method:"POST",credentials:"include",body:{code:e}}),wO=async e=>$fetch(`https://${se()}/api/cart/discount_codes_del`,{method:"POST",credentials:"include",body:{code:e,type:"coupon"}}),EO={async fetchCouponCode(){const e=ie();this.isLoadingCoupons=!0,e.systemStore.loadingFetchData=!0;try{const t=await vO();t.success?(this.saveActiveCoupon(t.data.coupon),this.saveActiveVoucher(t.data.voucher)):e.systemStore.addToastMessage("ERROR",t.error)}catch(t){console.error("Error: ",t)}finally{this.isLoadingCoupons=!1,e.systemStore.loadingFetchData=!1}},async applyCouponCode(e){const t=ie();this.isLoadingCoupons=!0,t.systemStore.loadingFetchData=!0;const n=this.getActiveCoupon;let i;try{if(i=await _O(e),i.success){if(e.includes("AUTOSHIP")){const r=t.systemStore.getCartGenericData.paypal_token;r!==""&&r&&(t.systemStore.setGlobalWarnings(["Since you activated an Autoship subscription, you will need to return to PayPal to agree to the billing terms and conditions on final step of checkout."]),t.paymentStore.cancelPayPallExpressSession())}this.saveActiveCoupon(i.data.coupon),t.systemStore.addToastMessage("SUCCESS","Coupon code "+i.data.coupon.coupon_msg),t.cartStore.fetchCartTotals(),t.shippingStore.fetchShippingMethods(),t.cartStore.fetchCartProducts()}else{const r=(i==null?void 0:i.errors)||(i==null?void 0:i.coupon_msg)||"Coupon code could not be applied.";t.systemStore.addToastMessage("ERROR",r),i.error_code_descr==="redemption_needed"||i.error_code_descr==="voucher_related"?this.saveActiveCoupon({coupon_code:"",coupon_description:"",coupon_msg:i.errors,success:!1}):i.error_code_descr==="silent_error"?(t.cartStore.fetchCartTotals(),t.shippingStore.fetchShippingMethods(),t.cartStore.fetchCartProducts()):this.saveActiveCoupon({coupon_code:"",coupon_description:"",coupon_msg:i.errors,success:!1});const s=n==null?void 0:n.coupon_code;s&&await t.couponStore.applyCouponCode(s),i={...i,fallback:!0}}}catch(r){console.error("Error: ",r)}finally{return this.isLoadingCoupons=!1,t.systemStore.loadingFetchData=!1,i}},async removeCouponCode(e){const t=ie();this.isLoadingCoupons=!0;let n;try{n=await wO(e),n.success?(this.saveActiveCoupon({coupon_code:"",coupon_description:"",coupon_msg:"",success:null}),t.shippingStore.fetchShippingMethods(),t.cartStore.fetchCartProducts(),t.cartStore.fetchCartTotals(),t.systemStore.addToastMessage("SUCCESS","Coupon removed")):t.systemStore.addToastMessage("ERROR",n.error)}catch(i){console.error("Error: ",i)}finally{return this.isLoadingCoupons=!1,n}},saveActiveCoupon(e){this.activeCoupon=e},saveActiveVoucher(e){this.activeVoucher=e}},SO=Rt("coupon",{state:()=>yO,getters:bO,actions:EO}),CO={},IO={},TO=async()=>$fetch(`https://${se()}/api/insurance/telus_status`,{method:"POST",credentials:"include",body:{is_telus_insurance_active:!0}}),PO={async startTelusFlow(){const e=ie();try{const t=await TO();t.success&&(this.setIsTelusFlowActive(t.is_telus_insurance_active),window.location.href=Ae()+"/ord/checkout")}catch{e.systemStore.addToastMessage("ERROR","Something is wrong with Vision Care Insurance")}},setIsTelusFlowActive(e){this.isTelusFlowActive=e}},OO=Rt("insurance",{state:()=>CO,getters:IO,actions:PO}),AO={patientInfo:{all_patients_verification_option_key:null,doctor:{doctor_fax:null,doctor_id:null,doctor_name:null,doctor_phone:null},doctor_accurate_count:0,doctor_patient:"",enable_visionTest:!1,faxto:"",first_name:"",last_name:"",mailto:"",patients:[],patients_with_rxupload:[],state:"",total_doctors:0,total_patients:0,verification_options:[]},patientsToBeVerified:[],globalVerificationSelected:{is_selected:!1,patient_option_key:null,verification_name:""},patients_with_rxupload:[],doctors:[],visibleAddNewDoctor:!1,rxFormIsValid:!1,selectedVerificationMethodCode:null,isMethodOpen:!1,verificationForAllPatients:!1,currentVerificationCode:0,opticianActivePatientKey:null,opticianSelectedVerificationMethodCode:null,loadingPatientVerification:!1,loadingPatientDoctorVerification:!1,loadingPatientRemoveUploadedRx:!1},kO={getDoctorsList(e){return e.doctors},getPatientsToBeVerified(e){return e.patientsToBeVerified},getPatientInfo(e){return e.patientInfo},getVerificationForAllPatients(e){return e.verificationForAllPatients},getSelectedVerificationMethodCode(e){return e.selectedVerificationMethodCode},getOpticianActivePatientKey(e){return e.opticianActivePatientKey},getOpticianSelectedVerificationMethodCode(e){return e.opticianSelectedVerificationMethodCode},getIsMethodOpen(e){return e.isMethodOpen},getLoadingPatientVerificationState(e){return e.loadingPatientVerification},getLoadingPatientDoctorVerificationState(e){return e.loadingPatientDoctorVerification},getLoadingPatientRemoveUploadedRx(e){return e.loadingPatientRemoveUploadedRx},getUploadedRxPrescriptions(e){return e.patients_with_rxupload},getDisplayAddNewDoctorDialog(e){return e.visibleAddNewDoctor},getOpticianSelectedPatient(e){const t=(e.patientsToBeVerified??[]).find(n=>n.patient_key===e.opticianActivePatientKey);return{name:(t==null?void 0:t.patient_name)??"",patient_key:(t==null?void 0:t.patient_key)??e.opticianActivePatientKey??"all",patient_option_key:(t==null?void 0:t.patient_option_key)??null}}},MX=e=>{if(e.patients.length<=0)return[];let t=[];
202return e.patients.forEach(n=>{let i={};i.name=n.patient_name,i.patient_key=n.patient_key,i.patient_option_key=n.patient_option_key,t.push(i)}),t},Da=(e,t)=>{for(let n of t)if(n.option_key===e)return n.option_name;return null},RO=async e=>$fetch(`https://${se()}/api/rxverification/doctor/set`,{method:"POST",credentials:"include",body:e}).then(t=>t).catch(t=>{console.error(t)}),LO=async e=>$fetch(`https://${se()}/api/rxverification/doctor/new`,{method:"POST",credentials:"include",body:e}).then(t=>t).catch(t=>{console.error(t)}),NO=async()=>$fetch(`https://${se()}/api/rxverification/patient/list`,{method:"GET",credentials:"include"}).then(e=>e).catch(e=>{console.error(e)}),DO=async e=>$fetch(`https://${se()}/api/rxverification/patient/method`,{method:"POST",credentials:"include",body:e}).then(t=>t).catch(t=>{console.error(t)}),xO=async e=>$fetch(`https://${se()}/api/rxverification/doctor/searchall?max=1000&state=${e}`,{method:"GET",credentials:"include"}).then(t=>t).catch(t=>{console.error(t)}),MO=async(e,t,n)=>$fetch(`https://${se()}/api/rxverification/uploadrx/new`,{method:"POST",credentials:"include",body:{patient_key:e,filename:t,dataURL1:n}}).then(i=>i).catch(i=>{console.error(i)}),FO=async e=>$fetch(`https://${se()}/api/rxverification/patient/resetall`,{method:"POST",credentials:"include",body:{all_patients_context:e}}).then(t=>t).catch(t=>{console.error(t)}),VO=async e=>$fetch(`https://${se()}/api/rxverification/uploadrx/delete`,{method:"POST",credentials:"include",body:{upload_id:e}}).then(t=>t).catch(t=>{console.error(t)}),BO={async setDoctor(e){const t=ie();try{const n=await RO(e);n.success?(await this.fetchPatient(),this.setVerificationForAllPatients(n.data.all_patients_context)):t.systemStore.addToastMessage("ERROR",n.error)}catch(n){console.error(n)}},async addNewDoctor(e){const t=ie();this.setLoadingPatientDoctorVerificationState(!0);try{const n=await LO(e);if(n.success)this.fetchPatient(),this.setVerificationForAllPatients(n.data.all_patients_context);else return t.systemStore.addToastMessage("ERROR",n.error),n}catch(n){return console.error(n),n}},async fetchDoctors(e){const t=ie();try{const n=await xO(e);n.success?this.setDoctorsList(n.doctors):t.systemStore.addToastMessage("ERROR",n.error)}catch(n){console.error(n)}},async fetchPatient(){const e=ie();this.setLoadingPatientVerificationState(!0),this.setLoadingPatientDoctorVerificationState(!0);try{const t=await NO();t.success?(t.data.all_patients_verification_option_key!==null?this.globalVerificationSelected={is_selected:!0,patient_option_key:t.data.all_patients_verification_option_key,verification_name:Da(t.data.all_patients_verification_option_key,t.data.verification_options)}:this.globalVerificationSelected={is_selected:!1,patient_option_key:"",verification_name:""},this.setPatientInfo(t.data),this.setPatientsToBeVerified(t.data.patients),this.setUploadedRxPrescriptions(t.data.patients_with_rxupload)):e.systemStore.addToastMessage("ERROR",t.error)}catch(t){console.error(t)}finally{this.setLoadingPatientVerificationState(!1),this.setLoadingPatientDoctorVerificationState(!1),this.setLoadingPatientRemoveUploadedRx(!1)}},async changeVerificationMethod(e){const t=ie();try{const n=await DO({patients:e});n.success?(n.data.all_patients_verification_option_key!==null?this.globalVerificationSelected={is_selected:!0,patient_option_key:n.data.all_patients_verification_option_key,verification_name:Da(n.data.all_patients_verification_option_key,n.data.verification_options)}:this.globalVerificationSelected={is_selected:!1,patient_option_key:"",verification_name:""},this.setPatientInfo(n.data),this.setPatientsToBeVerified(n.data.patients),this.setUploadedRxPrescriptions(n.data.patients_with_rxupload),this.setVerificationForAllPatients(n.data.all_patients_context)):t.systemStore.addToastMessage("ERROR",n.error)}catch(n){console.error(n)}},async uploadPatientFile(e,t,n){const i=ie();try{const r=await MO(e,t,n);i.systemStore.addToastMessage("SUCCESS","File uploaded successfully"),r.success?this.fetchPatient():i.systemStore.addToastMessage("ERROR",r.error)}catch(r){console.error(r)}},async deletePatientFile(e){const t=ie();try{const n=await VO(e);n.success?await this.fetchPatient():t.systemStore.addToastMessage("ERROR",n.error)}catch(n){console.error(n),t.systemStore.addToastMessage("ERROR","Unable to delete uploaded file.")}},async resetAllPatients(e){try{const t=await FO(e);t.success?(t.data.all_patients_verification_option_key!==null?this.globalVerificationSelected={is_selected:!0,patient_option_key:t.data.all_patients_verification_option_key,verification_name:Da(t.data.all_patients_verification_option_key,t.data.verification_options)}:this.globalVerificationSelected={is_selected:e,patient_option_key:"",verification_name:""},this.setPatientInfo(t.data),this.setPatientsToBeVerified(t.data.patients),this.setUploadedRxPrescriptions(t.data.patients_with_rxupload)):store.systemStore.addToastMessage("ERROR",t.error)}catch(t){console.error(t)}},setDoctorsList(e){this.doctors=e},setDisplayAddNewDoctorDialog(e){this.visibleAddNewDoctor=e},setPatientInfo(e){this.patientInfo=e},setPatientsToBeVerified(e){this.patientsToBeVerified=e.map(t=>{switch(t.patient_option_key){case 1:t.verification_method_name="Verify by Doctor";break;case 2:t.verification_method_name="On File";break;case 3:t.verification_method_name="Fax Expected";break;case 4:t.verification_method_name="Email Expected";break;case 5:t.verification_method_name="Upload Rx";break;default:t.verification_method_name=null}return t})},setUploadedRxPrescriptions(e){this.patients_with_rxupload=e},setVerificationForAllPatients(e){this.verificationForAllPatients=e},setSelectedVerificationMethodCode(e){this.selectedVerificationMethodCode=e},setOpticianActivePatientKey(e){this.opticianActivePatientKey=e},setOpticianSelectedVerificationMethodCode(e){this.opticianSelectedVerificationMethodCode=e},setLoadingPatientVerificationState(e){this.loadingPatientVerification=e},setLoadingPatientDoctorVerificationState(e){this.loadingPatientDoctorVerification=e},setLoadingPatientRemoveUploadedRx(e){this.loadingPatientRemoveUploadedRx=e},setIsMethodOpen(e){this.isMethodOpen=e},getGlobalVerificationSelected(e){return e.globalVerificationSelected}},$O=Rt("rxverification",{state:()=>AO,getters:kO,actions:BO});function ie(){return{systemStore:hT(),contactsStore:gT(),glassesStore:g2(),giftCardsStore:E2(),accessoriesStore:O2(),anagramStore:M2(),pixaStore:H2(),visionCreditStore:Z2(),autoshipStatusStore:tP(),kitsPlusStore:oP(),opticianStore:uP(),opticianCheckoutStore:mP(),systemCheckoutStore:wP(),cartStore:kP(),shippingStore:GP(),paymentStore:gO(),couponStore:SO(),insuranceStore:OO(),rxVerificationStore:$O()}}const UO=_t(()=>{const e=globalThis.$fetch,t=i=>{const r=i==null?void 0:i.alerts;if(!(!Array.isArray(r)||r.length===0))try{const s=ie();r.forEach(a=>{if(!(a!=null&&a.message))return;const o=(a.level||"info").toUpperCase();s.systemStore.addToastMessage(o,a.message)})}catch(s){console.error("fetch-interceptor: failed to dispatch alerts",s)}},n=e.create({onResponse({response:i}){t(i==null?void 0:i._data)},onResponseError({response:i}){t(i==null?void 0:i._data)}});globalThis.$fetch=n});var F={innerWidth(e){if(e){let t=e.offsetWidth,n=getComputedStyle(e);return t+=parseFloat(n.paddingLeft)+parseFloat(n.paddingRight),t}return 0},width(e){if(e){let t=e.offsetWidth,n=getComputedStyle(e);return t-=parseFloat(n.paddingLeft)+parseFloat(n.paddingRight),t}return 0},getWindowScrollTop(){let e=document.documentElement;return(window.pageYOffset||e.scrollTop)-(e.clientTop||0)},getWindowScrollLeft(){let e=document.documentElement;return(window.pageXOffset||e.scrollLeft)-(e.clientLeft||0)},getOuterWidth(e,t){if(e){let n=e.offsetWidth;if(t){let i=getComputedStyle(e);n+=parseFloat(i.marginLeft)+parseFloat(i.marginRight)}return n}return 0},getOuterHeight(e,t){if(e){let n=e.offsetHeight;if(t){let i=getComputedStyle(e);n+=parseFloat(i.marginTop)+parseFloat(i.marginBottom)}return n}return 0},getClientHeight(e,t){if(e){let n=e.clientHeight;if(t){let i=getComputedStyle(e);n+=parseFloat(i.marginTop)+parseFloat(i.marginBottom)}return n}return 0},getViewport(){let e=window,t=document,n=t.documentElement,i=t.getElementsByTagName("body")[0],r=e.innerWidth||n.clientWidth||i.clientWidth,s=e.innerHe
202ight||n.clientHeight||i.clientHeight;return{width:r,height:s}},getOffset(e){if(e){let t=e.getBoundingClientRect();return{top:t.top+(window.pageYOffset||document.documentElement.scrollTop||document.body.scrollTop||0),left:t.left+(window.pageXOffset||document.documentElement.scrollLeft||document.body.scrollLeft||0)}}return{top:"auto",left:"auto"}},index(e){if(e){let t=e.parentNode.childNodes,n=0;for(let i=0;i<t.length;i++){if(t[i]===e)return n;t[i].nodeType===1&&n++}}return-1},addMultipleClasses(e,t){if(e&&t)if(e.classList){let n=t.split(" ");for(let i=0;i<n.length;i++)e.classList.add(n[i])}else{let n=t.split(" ");for(let i=0;i<n.length;i++)e.className+=" "+n[i]}},addClass(e,t){e&&t&&(e.classList?e.classList.add(t):e.className+=" "+t)},removeClass(e,t){e&&t&&(e.classList?e.classList.remove(t):e.className=e.className.replace(new RegExp("(^|\\b)"+t.split(" ").join("|")+"(\\b|$)","gi")," "))},hasClass(e,t){return e?e.classList?e.classList.contains(t):new RegExp("(^| )"+t+"( |$)","gi").test(e.className):!1},find(e,t){return this.isElement(e)?e.querySelectorAll(t):[]},findSingle(e,t){return this.isElement(e)?e.querySelector(t):null},getHeight(e){if(e){let t=e.offsetHeight,n=getComputedStyle(e);return t-=parseFloat(n.paddingTop)+parseFloat(n.paddingBottom)+parseFloat(n.borderTopWidth)+parseFloat(n.borderBottomWidth),t}return 0},getWidth(e){if(e){let t=e.offsetWidth,n=getComputedStyle(e);return t-=parseFloat(n.paddingLeft)+parseFloat(n.paddingRight)+parseFloat(n.borderLeftWidth)+parseFloat(n.borderRightWidth),t}return 0},absolutePosition(e,t){if(e){let n=e.offsetParent?{width:e.offsetWidth,height:e.offsetHeight}:this.getHiddenElementDimensions(e),i=n.height,r=n.width,s=t.offsetHeight,a=t.offsetWidth,o=t.getBoundingClientRect(),l=this.getWindowScrollTop(),c=this.getWindowScrollLeft(),d=this.getViewport(),u,p;o.top+s+i>d.height?(u=o.top+l-i,e.style.transformOrigin="bottom",u<0&&(u=l)):(u=s+o.top+l,e.style.transformOrigin="top"),o.left+r>d.width?p=Math.max(0,o.left+c+a-r):p=o.left+c,e.style.top=u+"px",e.style.left=p+"px"}},relativePosition(e,t){if(e){let n=e.offsetParent?{width:e.offsetWidth,height:e.offsetHeight}:this.getHiddenElementDimensions(e);const i=t.offsetHeight,r=t.getBoundingClientRect(),s=this.getViewport();let a,o;r.top+i+n.height>s.height?(a=-1*n.height,e.style.transformOrigin="bottom",r.top+a<0&&(a=-1*r.top)):(a=i,e.style.transformOrigin="top"),n.width>s.width?o=r.left*-1:r.left+n.width>s.width?o=(r.left+n.width-s.width)*-1:o=0,e.style.top=a+"px",e.style.left=o+"px"}},getParents(e,t=[]){return e.parentNode===null?t:this.getParents(e.parentNode,t.concat([e.parentNode]))},getScrollableParents(e){let t=[];if(e){let n=this.getParents(e);const i=/(auto|scroll)/,r=s=>{let a=window.getComputedStyle(s,null);return i.test(a.getPropertyValue("overflow"))||i.test(a.getPropertyValue("overflowX"))||i.test(a.getPropertyValue("overflowY"))};for(let s of n){let a=s.nodeType===1&&s.dataset.scrollselectors;if(a){let o=a.split(",");for(let l of o){let c=this.findSingle(s,l);c&&r(c)&&t.push(c)}}s.nodeType!==9&&r(s)&&t.push(s)}}return t},getHiddenElementOuterHeight(e){if(e){e.style.visibility="hidden",e.style.display="block";let t=e.offsetHeight;return e.style.display="none",e.style.visibility="visible",t}return 0},getHiddenElementOuterWidth(e){if(e){e.style.visibility="hidden",e.style.display="block";let t=e.offsetWidth;return e.style.display="none",e.style.visibility="visible",t}return 0},getHiddenElementDimensions(e){if(e){let t={};return e.style.visibility="hidden",e.style.display="block",t.width=e.offsetWidth,t.height=e.offsetHeight,e.style.display="none",e.style.visibility="visible",t}return 0},fadeIn(e,t){if(e){e.style.opacity=0;let n=+new Date,i=0,r=function(){i=+e.style.opacity+(new Date().getTime()-n)/t,e.style.opacity=i,n=+new Date,+i<1&&(window.requestAnimationFrame&&requestAnimationFrame(r)||setTimeout(r,16))};r()}},fadeOut(e,t){if(e){let n=1,i=50,r=t,s=i/r,a=setInterval(()=>{n-=s,n<=0&&(n=0,clearInterval(a)),e.style.opacity=n},i)}},getUserAgent(){return navigator.userAgent},appendChild(e,t){if(this.isElement(t))t.appendChild(e);else if(t.el&&t.elElement)t.elElement.appendChild(e);else throw new Error("Cannot append "+t+" to "+e)},isElement(e){return typeof HTMLElement=="object"?e instanceof HTMLElement:e&&typeof e=="object"&&e!==null&&e.nodeType===1&&typeof e.nodeName=="string"},scrollInView(e,t){let n=getComputedStyle(e).getPropertyValue("borderTopWidth"),i=n?parseFloat(n):0,r=getComputedStyle(e).getPropertyValue("paddingTop"),s=r?parseFloat(r):0,a=e.getBoundingClientRect(),l=t.getBoundingClientRect().top+document.body.scrollTop-(a.top+document.body.scrollTop)-i-s,c=e.scrollTop,d=e.clientHeight,u=this.getOuterHeight(t);l<0?e.scrollTop=c+l:l+u>d&&(e.scrollTop=c+l-d+u)},clearSelection(){if(window.getSelection)window.getSelection().empty?window.getSelection().empty():window.getSelection().removeAllRanges&&window.getSelection().rangeCount>0&&window.getSelection().getRangeAt(0).getClientRects().length>0&&window.getSelection().removeAllRanges();else if(document.selection&&document.selection.empty)try{document.selection.empty()}catch{}},getSelection(){return window.getSelection?window.getSelection().toString():document.getSelection?document.getSelection().toString():document.selection?document.selection.createRange().text:null},calculateScrollbarWidth(){if(this.calculatedScrollbarWidth!=null)return this.calculatedScrollbarWidth;let e=document.createElement("div");e.className="p-scrollbar-measure",document.body.appendChild(e);let t=e.offsetWidth-e.clientWidth;return document.body.removeChild(e),this.calculatedScrollbarWidth=t,t},getBrowser(){if(!this.browser){let e=this.resolveUserAgent();this.browser={},e.browser&&(this.browser[e.browser]=!0,this.browser.version=e.version),this.browser.chrome?this.browser.webkit=!0:this.browser.webkit&&(this.browser.safari=!0)}return this.browser},resolveUserAgent(){let e=navigator.userAgent.toLowerCase(),t=/(chrome)[ ]([\w.]+)/.exec(e)||/(webkit)[ ]([\w.]+)/.exec(e)||/(opera)(?:.*version|)[ ]([\w.]+)/.exec(e)||/(msie) ([\w.]+)/.exec(e)||e.indexOf("compatible")<0&&/(mozilla)(?:.*? rv:([\w.]+)|)/.exec(e)||[];return{browser:t[1]||"",version:t[2]||"0"}},isVisible(e){return e&&e.offsetParent!=null},invokeElementMethod(e,t,n){e[t].apply(e,n)},isExist(e){return!!(e!==null&&typeof e<"u"&&e.nodeName&&e.parentNode)},isClient(){return!!(typeof window<"u"&&window.document&&window.document.createElement)},focus(e,t){e&&document.activeElement!==e&&e.focus(t)}
202,isFocusableElement(e,t=""){return this.isElement(e)?e.matches(`button:not([tabindex = "-1"]):not([disabled]):not([style*="display:none"]):not([hidden])${t},
203                [href][clientHeight][clientWidth]:not([tabindex = "-1"]):not([disabled]):not([style*="display:none"]):not([hidden])${t},
204                input:not([tabindex = "-1"]):not([disabled]):not([style*="display:none"]):not([hidden])${t},
205                select:not([tabindex = "-1"]):not([disabled]):not([style*="display:none"]):not([hidden])${t},
206                textarea:not([tabindex = "-1"]):not([disabled]):not([style*="display:none"]):not([hidden])${t},
207                [tabIndex]:not([tabIndex = "-1"]):not([disabled]):not([style*="display:none"]):not([hidden])${t},
208                [contenteditable]:not([tabIndex = "-1"]):not([disabled]):not([style*="display:none"]):not([hidden])${t}`):!1},getFocusableElements(e,t=""){let n=this.find(e,`button:not([tabindex = "-1"]):not([disabled]):not([style*="display:none"]):not([hidden])${t},
209                [href][clientHeight][clientWidth]:not([tabindex = "-1"]):not([disabled]):not([style*="display:none"]):not([hidden])${t},
210                input:not([tabindex = "-1"]):not([disabled]):not([style*="display:none"]):not([hidden])${t},
211                select:not([tabindex = "-1"]):not([disabled]):not([style*="display:none"]):not([hidden])${t},
212                textarea:not([tabindex = "-1"]):not([disabled]):not([style*="display:none"]):not([hidden])${t},
213                [tabIndex]:not([tabIndex = "-1"]):not([disabled]):not([style*="display:none"]):not([hidden])${t},
214                [contenteditable]:not([tabIndex = "-1"]):not([disabled]):not([style*="display:none"]):not([hidden])${t}`),i=[];for(let r of n)getComputedStyle(r).display!="none"&&getComputedStyle(r).visibility!="hidden"&&i.push(r);return i},getFirstFocusableElement(e,t){const n=this.getFocusableElements(e,t);return n.length>0?n[0]:null},getLastFocusableElement(e,t){const n=this.getFocusableElements(e,t);return n.length>0?n[n.length-1]:null},getNextFocusableElement(e,t,n){const i=this.getFocusableElements(e,n),r=i.length>0?i.findIndex(a=>a===t):-1,s=r>-1&&i.length>=r+1?r+1:-1;return s>-1?i[s]:null},isClickable(e){if(e){const t=e.nodeName,n=e.parentElement&&e.parentElement.nodeName;return t==="INPUT"||t==="TEXTAREA"||t==="BUTTON"||t==="A"||n==="INPUT"||n==="TEXTAREA"||n==="BUTTON"||n==="A"||!!e.closest(".p-button, .p-checkbox, .p-radiobutton")}return!1},applyStyle(e,t){if(typeof t=="string")e.style.cssText=t;else for(let n in t)e.style[n]=t[n]},isIOS(){return/iPad|iPhone|iPod/.test(navigator.userAgent)&&!window.MSStream},isAndroid(){return/(android)/i.test(navigator.userAgent)},isTouchDevice(){return"ontouchstart"in window||navigator.maxTouchPoints>0||navigator.msMaxTouchPoints>0},exportCSV(e,t){let n=new Blob([e],{type:"application/csv;charset=utf-8;"});if(window.navigator.msSaveOrOpenBlob)navigator.msSaveOrOpenBlob(n,t+".csv");else{let i=document.createElement("a");i.download!==void 0?(i.setAttribute("href",URL.createObjectURL(n)),i.setAttribute("download",t+".csv"),i.style.display="none",document.body.appendChild(i),i.click(),document.body.removeChild(i)):(e="data:text/csv;charset=utf-8,"+e,window.open(encodeURI(e)))}}};class kn{constructor(t,n=()=>{}){this.element=t,this.listener=n}bindScrollListener(){this.scrollableParents=F.getScrollableParents(this.element);for(let t=0;t<this.scrollableParents.length;t++)this.scrollableParents[t].addEventListener("scroll",this.listener)}unbindScrollListener(){if(this.scrollableParents)for(let t=0;t<this.scrollableParents.length;t++)this.scrollableParents[t].removeEventListener("scroll",this.listener)}destroy(){this.unbindScrollListener(),this.element=null,this.listener=null,this.scrollableParents=null}}function mf(){const e=new Map;return{on(t,n){let i=e.get(t);i?i.push(n):i=[n],e.set(t,i)},off(t,n){let i=e.get(t);i&&i.splice(i.indexOf(n)>>>0,1)},emit(t,n){let i=e.get(t);i&&i.slice().map(r=>{r(n)})}}}var ve={equals(e,t,n){return n?this.resolveFieldData(e,n)===this.resolveFieldData(t,n):this.deepEquals(e,t)},deepEquals(e,t){if(e===t)return!0;
214if(e&&t&&typeof e=="object"&&typeof t=="object"){var n=Array.isArray(e),i=Array.isArray(t),r,s,a;if(n&&i){if(s=e.length,s!=t.length)return!1;for(r=s;r--!==0;)if(!this.deepEquals(e[r],t[r]))return!1;return!0}if(n!=i)return!1;var o=e instanceof Date,l=t instanceof Date;if(o!=l)return!1;if(o&&l)return e.getTime()==t.getTime();var c=e instanceof RegExp,d=t instanceof RegExp;if(c!=d)return!1;if(c&&d)return e.toString()==t.toString();var u=Object.keys(e);if(s=u.length,s!==Object.keys(t).length)return!1;for(r=s;r--!==0;)if(!Object.prototype.hasOwnProperty.call(t,u[r]))return!1;for(r=s;r--!==0;)if(a=u[r],!this.deepEquals(e[a],t[a]))return!1;return!0}return e!==e&&t!==t},resolveFieldData(e,t){if(e&&Object.keys(e).length&&t){if(this.isFunction(t))return t(e);if(t.indexOf(".")===-1)return e[t];{let r=t.split("."),s=e;for(var n=0,i=r.length;n<i;++n){if(s==null)return null;s=s[r[n]]}return s}}else return null},isFunction(e){return!!(e&&e.constructor&&e.call&&e.apply)},getItemValue(e,...t){return this.isFunction(e)?e(...t):e},filter(e,t,n){var i=[];if(e){for(let r of e)for(let s of t)if(String(this.resolveFieldData(r,s)).toLowerCase().indexOf(n.toLowerCase())>-1){i.push(r);break}}return i},reorderArray(e,t,n){e&&t!==n&&(n>=e.length&&(n%=e.length,t%=e.length),e.splice(n,0,e.splice(t,1)[0]))},findIndexInList(e,t){let n=-1;if(t){for(let i=0;i<t.length;i++)if(t[i]===e){n=i;break}}return n},contains(e,t){if(e!=null&&t&&t.length){for(let n of t)if(this.equals(e,n))return!0}return!1},insertIntoOrderedArray(e,t,n,i){if(n.length>0){let r=!1;for(let s=0;s<n.length;s++)if(this.findIndexInList(n[s],i)>t){n.splice(s,0,e),r=!0;break}r||n.push(e)}else n.push(e)},removeAccents(e){return e&&e.search(/[\xC0-\xFF]/g)>-1&&(e=e.replace(/[\xC0-\xC5]/g,"A").replace(/[\xC6]/g,"AE").replace(/[\xC7]/g,"C").replace(/[\xC8-\xCB]/g,"E").replace(/[\xCC-\xCF]/g,"I").replace(/[\xD0]/g,"D").replace(/[\xD1]/g,"N").replace(/[\xD2-\xD6\xD8]/g,"O").replace(/[\xD9-\xDC]/g,"U").replace(/[\xDD]/g,"Y").replace(/[\xDE]/g,"P").replace(/[\xE0-\xE5]/g,"a").replace(/[\xE6]/g,"ae").replace(/[\xE7]/g,"c").replace(/[\xE8-\xEB]/g,"e").replace(/[\xEC-\xEF]/g,"i").replace(/[\xF1]/g,"n").replace(/[\xF2-\xF6\xF8]/g,"o").replace(/[\xF9-\xFC]/g,"u").replace(/[\xFE]/g,"p").replace(/[\xFD\xFF]/g,"y")),e},getVNodeProp(e,t){let n=e.props;if(n){let i=t.replace(/([a-z])([A-Z])/g,"$1-$2").toLowerCase(),r=Object.prototype.hasOwnProperty.call(n,i)?i:t;return e.type.props[t].type===Boolean&&n[r]===""?!0:n[r]}return null},convertToFlatCase(e){return this.isNotEmpty(e)?e.replace(/(-|_)/g,"").toLowerCase():e},isEmpty(e){return e==null||e===""||Array.isArray(e)&&e.length===0||!(e instanceof Date)&&typeof e=="object"&&Object.keys(e).length===0},isNotEmpty(e){return!this.isEmpty(e)},isPrintableCharacter(e=""){return this.isNotEmpty(e)&&e.length===1&&e.match(/\S| /)},findLast(e,t){let n;if(this.isNotEmpty(e))try{n=e.findLast(t)}catch{n=[...e].reverse().find(t)}return n},findLastIndex(e,t){let n=-1;if(this.isNotEmpty(e))try{n=e.findLastIndex(t)}catch{n=e.lastIndexOf([...e].reverse().find(t))}return n}},Wd=0;function pt(e="pv_id_"){return Wd++,`${e}${Wd}`}function HO(){let e=[];const t=(a,o,l=999)=>{const c=r(a,o,l),d=c.value+(c.key===a?0:l)+1;return e.push({key:a,value:d}),d},n=a=>{e=e.filter(o=>o.value!==a)},i=(a,o)=>r(a).value,r=(a,o,l=0)=>[...e].reverse().find(c=>!0)||{key:a,value:l},s=a=>a&&parseInt(a.style.zIndex,10)||0;return{get:s,set:(a,o,l)=>{o&&(o.style.zIndex=String(t(a,!0,l)))},clear:a=>{a&&(n(s(a)),a.style.zIndex="")},getCurrent:a=>i(a)}}var He=HO(),Ve={name:"BaseComponent",props:{pt:{type:Object,default:void 0}},methods:{getOption(e={},t=""){const n=ve.convertToFlatCase(t);return e[Object.keys(e).find(i=>ve.convertToFlatCase(i)===n)||""]},getPTValue(e={},t="",n={}){const i=ve.getItemValue(this.getOption(e,t),n),r=ve.getItemValue(this.getOption(this.defaultPT,t),n);return R(i,r)},ptm(e="",t={}){return this.getPTValue(this.pt,e,{props:this.$props,state:this.$data,...t})},ptmo(e={},t="",n={}){return this.getPTValue(e,t,n)}},computed:{defaultPT(){return ve.getItemValue(this.getOption(this.$primevue.config.pt,this.$.type.n
214ame),this.defaultsParams)},defaultsParams(){return{instance:this.$}}}},ze={name:"BaseIcon",props:{label:{type:String,default:void 0},spin:{type:Boolean,default:!1}},methods:{pti(){const e=ve.isEmpty(this.label);return{class:["p-icon",{"p-icon-spin":this.spin}],role:e?void 0:"img","aria-label":e?void 0:this.label,"aria-hidden":e}}}};function zO(e,t){t===void 0&&(t={});var n=t.insertAt;if(!(typeof document>"u")){var i=document.head||document.getElementsByTagName("head")[0],r=document.createElement("style");r.type="text/css",n==="top"&&i.firstChild?i.insertBefore(r,i.firstChild):i.appendChild(r),r.styleSheet?r.styleSheet.cssText=e:r.appendChild(document.createTextNode(e))}}var KO=`
215.p-icon {
216    display: inline-block;
217}
218.p-icon-spin {
219    -webkit-animation: p-icon-spin 2s infinite linear;
220    animation: p-icon-spin 2s infinite linear;
221}
222@-webkit-keyframes p-icon-spin {
2230% {
224        -webkit-transform: rotate(0deg);
225        transform: rotate(0deg);
226}
227100% {
228        -webkit-transform: rotate(359deg);
229        transform: rotate(359deg);
230}
231}
232@keyframes p-icon-spin {
2330% {
234        -webkit-transform: rotate(0deg);
235        transform: rotate(0deg);
236}
237100% {
238        -webkit-transform: rotate(359deg);
239        transform: rotate(359deg);
240}
241}
242`;zO(KO);var _n={name:"ChevronDownIcon",extends:ze};const GO=f("path",{d:"M7.01744 10.398C6.91269 10.3985 6.8089 10.378 6.71215 10.3379C6.61541 10.2977 6.52766 10.2386 6.45405 10.1641L1.13907 4.84913C1.03306 4.69404 0.985221 4.5065 1.00399 4.31958C1.02276 4.13266 1.10693 3.95838 1.24166 3.82747C1.37639 3.69655 1.55301 3.61742 1.74039 3.60402C1.92777 3.59062 2.11386 3.64382 2.26584 3.75424L7.01744 8.47394L11.769 3.75424C11.9189 3.65709 12.097 3.61306 12.2748 3.62921C12.4527 3.64535 12.6199 3.72073 12.7498 3.84328C12.8797 3.96582 12.9647 4.12842 12.9912 4.30502C13.0177 4.48162 12.9841 4.662 12.8958 4.81724L7.58083 10.1322C7.50996 10.2125 7.42344 10.2775 7.32656 10.3232C7.22968 10.3689 7.12449 10.3944 7.01744 10.398Z",fill:"currentColor"},null,-1),jO=[GO];function YO(e,t,n,i,r,s){return g(),S("svg",R({width:"14",height:"14",viewBox:"0 0 14 14",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e.pti()),jO,16)}_n.render=YO;var Rn={name:"ChevronRightIcon",extends:ze};const WO=f("path",{d:"M4.38708 13C4.28408 13.0005 4.18203 12.9804 4.08691 12.9409C3.99178 12.9014 3.9055 12.8433 3.83313 12.7701C3.68634 12.6231 3.60388 12.4238 3.60388 12.2161C3.60388 12.0084 3.68634 11.8091 3.83313 11.6622L8.50507 6.99022L3.83313 2.31827C3.69467 2.16968 3.61928 1.97313 3.62287 1.77005C3.62645 1.56698 3.70872 1.37322 3.85234 1.22959C3.99596 1.08597 4.18972 1.00371 4.3928 1.00012C4.59588 0.996539 4.79242 1.07192 4.94102 1.21039L10.1669 6.43628C10.3137 6.58325 10.3962 6.78249 10.3962 6.99022C10.3962 7.19795 10.3137 7.39718 10.1669 7.54416L4.94102 12.7701C4.86865 12.8433 4.78237 12.9014 4.68724 12.9409C4.59212 12.9804 4.49007 13.0005 4.38708 13Z",fill:"currentColor"},null,-1),QO=[WO];function ZO(e,t,n,i,r,s){return g(),S("svg",R({width:"14",height:"14",viewBox:"0 0 14 14",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e.pti()),QO,16)}Rn.render=ZO;let No;function qO(e){e.addEventListener("mousedown",gf)}function JO(e){e.removeEventListener("mousedown",gf)}function XO(e){let t=document.createElement("span");t.className="p-ink",t.setAttribute("role","presentation"),t.setAttribute("aria-hidden","true"),e.appendChild(t),t.addEventListener("animationend",yf)}function eA(e){let t=bf(e);t&&(JO(e),t.removeEventListener("animationend",yf),t.remove())}function gf(e){let t=e.currentTarget,n=bf(t);if(!n||getComputedStyle(n,null).display==="none")return;if(F.removeClass(n,"p-ink-active"),!F.getHeight(n)&&!F.getWidth(n)){let a=Math.max(F.getOuterWidth(t),F.getOuterHeight(t));n.style.height=a+"px",n.style.width=a+"px"}let i=F.getOffset(t),r=e.pageX-i.left+document.body.scrollTop-F.getWidth(n)/2,s=e.pageY-i.top+document.body.scrollLeft-F.getHeight(n)/2;n.style.top=s+"px",n.style.left=r+"px",F.addClass(n,"p-ink-active"),No=setTimeout(()=>{n&&F.removeClass(n,"p-ink-active")},401)}function yf(e){No&&clearTimeout(No),F.removeClass(e.currentTarget,"p-ink-active")}function bf(e){for(let t=0;t<e.children.length;t++)if(typeof e.children[t].className=="string"&&e.children[t].className.indexOf("p-ink")!==-1)return e.children[t];return null}const gt={mounted(e,t){t.instance.$primevue&&t.instance.$primevue.config&&t.instance.$primevue.config.ripple&&(XO(e),qO(e))},unmounted(e){eA(e)}};var vf={name:"Accordion",extends:Ve,emits:["update:activeIndex","tab-open","tab-close","tab-click"],props:{multiple:{type:Boolean,default:!1},activeIndex:{type:[Number,Array],default:null},lazy:{type:Boolean,default:!1},expandIcon:{type:String,default:void 0},collapseIcon:{type:String,default:void 0},tabindex:{type:Number,default:0},selectOnFocus:{type:Boolean,default:!1}},data(){return{id:this.$attrs.id,d_activeIndex:this.activeIndex}},watch:{"$attrs.id":function(e){this.id=e||pt()},activeIndex(e){this.d_activeIndex=e}},mounted(){this.id=this.id||pt()},methods:{isAccordionTab(e){return e.type.name==="AccordionTab"},isTabActive(e){return this.multiple?this.d_activeIndex&&this.d_activeIndex.includes(e):this.d_activeIndex===e},getTabProp(e,t){return e.props?e.props[t]:void 0},getKey(e,t){return this.getTabProp(e,"header")||t},getTabHeaderActionId(e){return`${this.id}_${e}_header_action`},getTabContentId(e){return`${this.id}_${e}_content`},getTabPT(e,t){return this.ptmo(this.getTabProp(e,"pt"),t,{props:e.props,parent:{props:this.$props,state:this.$data}})},onTabClick(e,t,n){this.changeActiveIndex(e,t,n),this.$emit("tab-click",{originalEvent:e,index:n})},onTabKeyDown(e,t,n){switch(e.code){case"ArrowDown":this.onTabArrowDownKey(e);break;case"ArrowUp":this.onTabArrowUpKey(e);break;case"Home":this.onTabHomeKey(e);break;case"End":this.onTabEndKey(e);break;case"Enter":case"Space":this.onTabEnterKey(e,t,n);break}},onTabArrowDownKey(e){const t=this.findNextHeaderAction(e.target.parentElement.parentElement);t?this.changeFocusedTab(e,t):this.onTabHomeKey(e),e.preventDefault()},onTabArrowUpKey(e){const t=this.findPrevHeaderAction(e.target.parentElement.parentElement);t?this.changeFocusedTab(e,t):this.onTabEndKey(e),e.preventDefault()},onTabHomeKey(e){const t=this.findFirstHeaderAction();this.changeFocusedTab(e,t),e.preventDefault()},onTabEndKey(e){const t=this.findLastHeaderAction();this.changeFocusedTab(e,t),e.preventDefault()},onTabEnterKey(e,t,n){this.changeActiveIndex(e,t,n),e.preventDefault()},findNextHeaderAction(e,t=!1){const n=t?e:e.nextElementSibling,i=F.findSingle(n,".p-accordion-header");return i?F.hasClass(i,"p-disabled")?this.findNextHeaderAction(i.parentElement):F.findSingle(i,".p-accordion-header-action"):null},findPrevHeaderAction(e,t=!1){const n=t?e:e.previousElementSibling,i=F.findSingle(n,".p-accordion-header");return i?F.hasClass(i,"p-disabled")?this.findPrevHeaderAction(i.parentElement):F.findSingle(i,".p-accordion-header-action"):null},findFirstHeaderAction(){return this.findNextHeaderAction(this.$el.firstElementChild,!0)},findLastHeaderAction(){return this.findPrevHeaderAction(this.$el.lastElementChild,!0)},changeActiveIndex(e,t,n){if(!this.getTabProp(t,"disabled")){const i=this.isTabActive(n),r=i?"tab-close":"tab-open";this.multiple?i?this.d_activeIndex=this.d_activeIndex.filter(s=>s!==n):this.d_activeIndex?this.d_activeIndex.push(n):this.d_activeIndex=[n]:this.d_activeIndex=this.d_activeIndex===n?null:n,this.$emit("update:activeIndex",this.d_activeIndex),this.$emit(r,{originalEvent:e,index:n})}},changeFocusedTab(e,t){if(t&&(F.focus(t),this.selectOnFocus)){const n=parseInt(t.parentElement.parentElement.dataset.index,10),i=this.tabs[n];this.changeActiveIndex(e,i,n)}},getTabClass(e){return["p-accordion-tab",{"p-accordion-tab-active":this.isTabActive(e)}]},getTabHeaderClass(e,t){return["p-accordion-header",this.getTabProp(e,"headerClass"),{"p-highlight":this.isTabActive(t),"p-disabled":this.getTabProp(e,"disabled")}]},getTabContentClass(e){return["p-toggleable-content",this.getTabProp(e,"contentClass")]}},computed:{tabs(){return this.$slots.default().reduce((e,t)=>
242(this.isAccordionTab(t)?e.push(t):t.children&&t.children instanceof Array&&t.children.forEach(n=>{this.isAccordionTab(n)&&e.push(n)}),e),[])}},components:{ChevronDownIcon:_n,ChevronRightIcon:Rn},directives:{ripple:gt}};const tA=["data-index"],nA=["id","tabindex","aria-disabled","aria-expanded","aria-controls","onClick","onKeydown"],sA=["id","aria-labelledby"];function iA(e,t,n,i,r,s){return g(),S("div",R({class:"p-accordion p-component"},e.ptm("root")),[(g(!0),S(J,null,ye(s.tabs,(a,o)=>(g(),S("div",R({key:s.getKey(a,o),class:s.getTabClass(o),"data-index":o},s.getTabPT(a,"root")),[f("div",R({style:s.getTabProp(a,"headerStyle"),class:s.getTabHeaderClass(a,o)},{...s.getTabProp(a,"headerProps"),...s.getTabPT(a,"header")}),[f("a",R({id:s.getTabHeaderActionId(o),class:"p-accordion-header-link p-accordion-header-action",tabindex:s.getTabProp(a,"disabled")?-1:n.tabindex,role:"button","aria-disabled":s.getTabProp(a,"disabled"),"aria-expanded":s.isTabActive(o),"aria-controls":s.getTabContentId(o),onClick:l=>s.onTabClick(l,a,o),onKeydown:l=>s.onTabKeyDown(l,a,o)},{...s.getTabProp(a,"headeractionprops"),...s.getTabPT(a,"headeraction")}),[a.children&&a.children.headericon?(g(),Q(_e(a.children.headericon),{key:0,isTabActive:s.isTabActive(o),index:o},null,8,["isTabActive","index"])):s.isTabActive(o)?(g(),Q(_e(n.collapseIcon?"span":"ChevronDownIcon"),R({key:1,class:["p-accordion-toggle-icon",n.collapseIcon],"aria-hidden":"true"},s.getTabPT(a,"headericon")),null,16,["class"])):(g(),Q(_e(n.expandIcon?"span":"ChevronRightIcon"),R({key:2,class:["p-accordion-toggle-icon",n.expandIcon],"aria-hidden":"true"},s.getTabPT(a,"headericon")),null,16,["class"])),a.props&&a.props.header?(g(),S("span",R({key:3,class:"p-accordion-header-text"},s.getTabPT(a,"headertitle")),N(a.props.header),17)):M("",!0),a.children&&a.children.header?(g(),Q(_e(a.children.header),{key:4})):M("",!0)],16,nA)],16),de($t,{name:"p-toggleable-content"},{default:Ee(()=>[!n.lazy||s.isTabActive(o)?Ne((g(),S("div",R({key:0,id:s.getTabContentId(o),style:s.getTabProp(a,"contentStyle"),class:s.getTabContentClass(a),role:"region","aria-labelledby":s.getTabHeaderActionId(o)},{...s.getTabProp(a,"contentProps"),...s.getTabPT(a,"toggleablecontent")}),[f("div",R({class:"p-accordion-content"},s.getTabPT(a,"content")),[(g(),Q(_e(a)))],16)],16,sA)),[[mt,n.lazy?!0:s.isTabActive(o)]]):M("",!0)]),_:2},1024)],16,tA))),128))],16)}function rA(e,t){t===void 0&&(t={});var n=t.insertAt;if(!(typeof document>"u")){var i=document.head||document.getElementsByTagName("head")[0],r=document.createElement("style");r.type="text/css",n==="top"&&i.firstChild?i.insertBefore(r,i.firstChild):i.appendChild(r),r.styleSheet?r.styleSheet.cssText=e:r.appendChild(document.createTextNode(e))}}var aA=`
243.p-accordion-header-action {
244    cursor: pointer;
245    display: flex;
246    align-items: center;
247    user-select: none;
248    position: relative;
249    text-decoration: none;
250}
251.p-accordion-header-action:focus {
252    z-index: 1;
253}
254.p-accordion-header-text {
255    line-height: 1;
256}
257`;rA(aA);vf.render=iA;var _f={name:"AccordionTab",extends:Ve,props:{header:null,headerStyle:null,headerClass:null,headerProps:null,headerActionProps:null,contentStyle:null,contentClass:null,contentProps:null,disabled:Boolean}};function oA(e,t,n,i,r,s){return he(e.$slots,"default")}_f.render=oA;const Lt={STARTS_WITH:"startsWith",CONTAINS:"contains",NOT_CONTAINS:"notContains",ENDS_WITH:"endsWith",EQUALS:"equals",NOT_EQUALS:"notEquals",IN:"in",LESS_THAN:"lt",LESS_THAN_OR_EQUAL_TO:"lte",GREATER_THAN:"gt",GREATER_THAN_OR_EQUAL_TO:"gte",BETWEEN:"between",DATE_IS:"dateIs",DATE_IS_NOT:"dateIsNot",DATE_BEFORE:"dateBefore",DATE_AFTER:"dateAfter"},_r={AND:"and",OR:"or"},wr={filter(e,t,n,i,r){let s=[];if(e)for(let a of e)for(let o of t){let l=ve.resolveFieldData(a,o);if(this.filters[i](l,n,r)){s.push(a);break}}return s},filters:{startsWith(e,t,n){if(t==null||t.trim()==="")return!0;if(e==null)return!1;let i=ve.removeAccents(t.toString()).toLocaleLowerCase(n);return ve.removeAccents(e.toString()).toLocaleLowerCase(n).slice(0,i.length)===i},contains(e,t,n){if(t==null||typeof t=="string"&&t.trim()==="")return!0;
257if(e==null)return!1;let i=ve.removeAccents(t.toString()).toLocaleLowerCase(n);return ve.removeAccents(e.toString()).toLocaleLowerCase(n).indexOf(i)!==-1},notContains(e,t,n){if(t==null||typeof t=="string"&&t.trim()==="")return!0;if(e==null)return!1;let i=ve.removeAccents(t.toString()).toLocaleLowerCase(n);return ve.removeAccents(e.toString()).toLocaleLowerCase(n).indexOf(i)===-1},endsWith(e,t,n){if(t==null||t.trim()==="")return!0;if(e==null)return!1;let i=ve.removeAccents(t.toString()).toLocaleLowerCase(n),r=ve.removeAccents(e.toString()).toLocaleLowerCase(n);return r.indexOf(i,r.length-i.length)!==-1},equals(e,t,n){return t==null||typeof t=="string"&&t.trim()===""?!0:e==null?!1:e.getTime&&t.getTime?e.getTime()===t.getTime():ve.removeAccents(e.toString()).toLocaleLowerCase(n)==ve.removeAccents(t.toString()).toLocaleLowerCase(n)},notEquals(e,t,n){return t==null||typeof t=="string"&&t.trim()===""?!1:e==null?!0:e.getTime&&t.getTime?e.getTime()!==t.getTime():ve.removeAccents(e.toString()).toLocaleLowerCase(n)!=ve.removeAccents(t.toString()).toLocaleLowerCase(n)},in(e,t){if(t==null||t.length===0)return!0;for(let n=0;n<t.length;n++)if(ve.equals(e,t[n]))return!0;return!1},between(e,t){return t==null||t[0]==null||t[1]==null?!0:e==null?!1:e.getTime?t[0].getTime()<=e.getTime()&&e.getTime()<=t[1].getTime():t[0]<=e&&e<=t[1]},lt(e,t){return t==null?!0:e==null?!1:e.getTime&&t.getTime?e.getTime()<t.getTime():e<t},lte(e,t){return t==null?!0:e==null?!1:e.getTime&&t.getTime?e.getTime()<=t.getTime():e<=t},gt(e,t){return t==null?!0:e==null?!1:e.getTime&&t.getTime?e.getTime()>t.getTime():e>t},gte(e,t){return t==null?!0:e==null?!1:e.getTime&&t.getTime?e.getTime()>=t.getTime():e>=t},dateIs(e,t){return t==null?!0:e==null?!1:e.toDateString()===t.toDateString()},dateIsNot(e,t){return t==null?!0:e==null?!1:e.toDateString()!==t.toDateString()},dateBefore(e,t){return t==null?!0:e==null?!1:e.getTime()<t.getTime()},dateAfter(e,t){return t==null?!0:e==null?!1:e.getTime()>t.getTime()}},register(e,t){this.filters[e]=t}},Qd={ripple:!1,inputStyle:"outlined",locale:{startsWith:"Starts with",contains:"Contains",notContains:"Not contains",endsWith:"Ends with",equals:"Equals",notEquals:"Not equals",noFilter:"No Filter",lt:"Less than",lte:"Less than or equal to",gt:"Greater than",gte:"Greater than or equal to",dateIs:"Date is",dateIsNot:"Date is not",dateBefore:"Date is before",dateAfter:"Date is after",clear:"Clear",apply:"Apply",matchAll:"Match All",matchAny:"Match Any",addRule:"Add Rule",removeRule:"Remove Rule",accept:"Yes",reject:"No",choose:"Choose",upload:"Upload",cancel:"Cancel",completed:"Completed",pending:"Pending",dayNames:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],dayNamesShort:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],dayNamesMin:["Su","Mo","Tu","We","Th","Fr","Sa"],monthNames:["January","February","March","April","May","June","July","August","September","October","November","December"],monthNamesShort:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],chooseYear:"Choose Year",chooseMonth:"Choose Month",chooseDate:"Choose Date",prevDecade:"Previous Decade",nextDecade:"Next Decade",prevYear:"Previous Year",nextYear:"Next Year",prevMonth:"Previous Month",nextMonth:"Next Month",prevHour:"Previous Hour",nextHour:"Next Hour",prevMinute:"Previous Minute",nextMinute:"Next Minute",prevSecond:"Previous Second",nextSecond:"Next Second",am:"am",pm:"pm",today:"Today",weekHeader:"Wk",firstDayOfWeek:0,dateFormat:"mm/dd/yy",weak:"Weak",medium:"Medium",strong:"Strong",passwordPrompt:"Enter a password",emptyFilterMessage:"No results found",searchMessage:"{0} results are available",selectionMessage:"{0} items selected",emptySelectionMessage:"No selected item",emptySearchMessage:"No results found",emptyMessage:"No available options",aria:{trueLabel:"True",falseLabel:"False",nullLabel:"Not Selected",star:"1 star",stars:"{star} stars",selectAll:"All items selected",unselectAll:"All items unselected",close:"Close",previous:"Previous",next:"Next",navigation:"Navigation",scrollTop:"Scroll Top",moveTop:"Move Top",moveUp:"Move Up",moveDown:"Move Down",moveBottom:"Move Bottom",moveToTarget:"Move to Target",moveToSource:"Move to Source",moveAllToTarget:"Move All to Target",moveAllToSource:"Move All to Source",pageLabel:"{page}",firstPageLabel:"First Page",lastPageLabel:"Last Page",nextPageLabel:"Next Page",prevPageLabel:"Previous Page",rowsPerPageLabel:"Rows per page",jumpToPageDropdownLabel:"Jump to Page Dropdown",jumpToPageInputLabel:"Jump to Page Input",selectRow:"Row Selected",unselectRow:"Row Unselected",expandRow:"Row Expanded",collapseRow:"Row Collapsed",showFilterMenu:"Show Filter Menu",hideFilterMenu:"Hide Filter Menu",filterOperator:"Filter Operator",filterConstraint:"Filter Constraint",editRow:"Row Edit",saveEdit:"Save Edit",cancelEdit:"Cancel Edit",listView:"List View",gridView:"Grid View",slide:"Slide",slideNumber:"{slideNumber}",zoomImage:"Zoom Image",zoomIn:"Zoom In",zoomOut:"Zoom Out",rotateRight:"Rotate Right",rotateLeft:"Rotate Left"}},filterMatchModeOptions:{text:[Lt.STARTS_WITH,Lt.CONTAINS,Lt.NOT_CONTAINS,Lt.ENDS_WITH,Lt.EQUALS,Lt.NOT_EQUALS],numeric:[Lt.EQUALS,Lt.NOT_EQUALS,Lt.LESS_THAN,Lt.LESS_THAN_OR_EQUAL_TO,Lt.GREATER_THAN,Lt.GREATER_THAN_OR_EQUAL_TO],date:[Lt.DATE_IS,Lt.DATE_IS_NOT,Lt.DATE_BEFORE,Lt.DATE_AFTER]},zIndex:{modal:1100,overlay:1e3,menu:1e3,tooltip:1100},pt:void 0},lA=Symbol();function cA(e,t,n,i){const r=document.getElementById(n),s=r.cloneNode(!0),a=r.getAttribute("href").replace(e,t);
257s.setAttribute("id",n+"-clone"),s.setAttribute("href",a),s.addEventListener("load",()=>{r.remove(),s.setAttribute("id",n),i&&i()}),r.parentNode&&r.parentNode.insertBefore(s,r.nextSibling)}var dA={install:(e,t)=>{let n=t?{...Qd,...t}:{...Qd};const i={config:Wt(n),changeTheme:cA};e.config.globalProperties.$primevue=i,e.provide(lA,i)}},ps={name:"SpinnerIcon",extends:ze};const uA=f("g",{"clip-path":"url(#clip0_417_21408)"},[f("path",{d:"M6.99701 14C5.85441 13.999 4.72939 13.7186 3.72012 13.1832C2.71084 12.6478 1.84795 11.8737 1.20673 10.9284C0.565504 9.98305 0.165424 8.89526 0.041387 7.75989C-0.0826496 6.62453 0.073125 5.47607 0.495122 4.4147C0.917119 3.35333 1.59252 2.4113 2.46241 1.67077C3.33229 0.930247 4.37024 0.413729 5.4857 0.166275C6.60117 -0.0811796 7.76026 -0.0520535 8.86188 0.251112C9.9635 0.554278 10.9742 1.12227 11.8057 1.90555C11.915 2.01493 11.9764 2.16319 11.9764 2.31778C11.9764 2.47236 11.915 2.62062 11.8057 2.73C11.7521 2.78503 11.688 2.82877 11.6171 2.85864C11.5463 2.8885 11.4702 2.90389 11.3933 2.90389C11.3165 2.90389 11.2404 2.8885 11.1695 2.85864C11.0987 2.82877 11.0346 2.78503 10.9809 2.73C9.9998 1.81273 8.73246 1.26138 7.39226 1.16876C6.05206 1.07615 4.72086 1.44794 3.62279 2.22152C2.52471 2.99511 1.72683 4.12325 1.36345 5.41602C1.00008 6.70879 1.09342 8.08723 1.62775 9.31926C2.16209 10.5513 3.10478 11.5617 4.29713 12.1803C5.48947 12.7989 6.85865 12.988 8.17414 12.7157C9.48963 12.4435 10.6711 11.7264 11.5196 10.6854C12.3681 9.64432 12.8319 8.34282 12.8328 7C12.8328 6.84529 12.8943 6.69692 13.0038 6.58752C13.1132 6.47812 13.2616 6.41667 13.4164 6.41667C13.5712 6.41667 13.7196 6.47812 13.8291 6.58752C13.9385 6.69692 14 6.84529 14 7C14 8.85651 13.2622 10.637 11.9489 11.9497C10.6356 13.2625 8.85432 14 6.99701 14Z",fill:"currentColor"})],-1),hA=f("defs",null,[f("clipPath",{id:"clip0_417_21408"},[f("rect",{width:"14",height:"14",fill:"white"})])],-1),pA=[uA,hA];function fA(e,t,n,i,r,s){return g(),S("svg",R({width:"14",height:"14",viewBox:"0 0 14 14",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e.pti()),pA,16)}ps.render=fA;var Qn={name:"Button",extends:Ve,props:{label:{type:String,default:null},icon:{type:String,default:null},iconPos:{type:String,default:"left"},iconClass:{type:String,default:null},badge:{type:String,default:null},badgeClass:{type:String,default:null},loading:{type:Boolean,default:!1},loadingIcon:{type:String,default:void 0},link:{type:Boolean,default:!1},severity:{type:String,default:null},raised:{type:Boolean,default:!1},rounded:{type:Boolean,default:!1},text:{type:Boolean,default:!1},outlined:{type:Boolean,default:!1},size:{type:String,default:null},plain:{type:Boolean,default:!1}},computed:{buttonClass(){return["p-button p-component",{"p-button-icon-only":this.hasIcon&&!this.label,"p-button-vertical":(this.iconPos==="top"||this.iconPos==="bottom")&&this.label,"p-disabled":this.$attrs.disabled||this.loading,"p-button-loading":this.loading,"p-button-loading-label-only":this.loading&&!this.hasIcon&&this.label,"p-button-link":this.link,[`p-button-${this.severity}`]:this.severity,"p-button-raised":this.raised,"p-button-rounded":this.rounded,"p-button-text":this.text,"p-button-outlined":this.outlined,"p-button-sm":this.size==="small","p-button-lg":this.size==="large","p-button-plain":this.plain}]},iconStyleClass(){return["p-button-icon",this.iconClass,{"p-button-icon-left":this.iconPos==="left"&&this.label,"p-button-icon-right":this.iconPos==="right"&&this.label,"p-button-icon-top":this.iconPos==="top"&&this.label,"p-button-icon-bottom":this.iconPos==="bottom"&&this.label}]},loadingIconStyleClass(){return["p-button-loading-icon pi-spin",this.iconStyleClass]},badgeStyleClass(){return["p-badge p-component",this.badgeClass,{"p-badge-no-gutter":this.badge&&String(this.badge).length===1}]},disabled(){return this.$attrs.disabled||this.loading},defaultAriaLabel(){return this.label?this.label+(this.badge?" "+this.badge:""):this.$attrs["aria-label"]},hasIcon(){return this.icon||this.$slots.icon}},components:{SpinnerIcon:ps},directives:{ripple:gt}};const mA=["aria-label","disabled"];function gA(e,t,n,i,r,s){const a=le("SpinnerIcon"),o=Xe("ripple");return Ne((g(),S("button",R({class:s.buttonClass,type:"button","aria-label":s.defaultAr
257iaLabel,disabled:s.disabled},e.ptm("root")),[he(e.$slots,"default",{},()=>[n.loading?he(e.$slots,"loadingicon",{key:0,class:Oe(s.loadingIconStyleClass)},()=>[n.loadingIcon?(g(),S("span",R({key:0,class:[s.loadingIconStyleClass,n.loadingIcon]},e.ptm("loadingIcon")),null,16)):(g(),Q(a,R({key:1,class:s.loadingIconStyleClass,spin:""},e.ptm("loadingIcon")),null,16,["class"]))]):he(e.$slots,"icon",{key:1,class:Oe(s.iconStyleClass)},()=>[n.icon?(g(),S("span",R({key:0,class:[s.iconStyleClass,n.icon]},e.ptm("icon")),null,16)):M("",!0)]),f("span",R({class:"p-button-label"},e.ptm("label")),N(n.label||" "),17),n.badge?(g(),S("span",R({key:2,class:s.badgeStyleClass},e.ptm("badge")),N(n.badge),17)):M("",!0)])],16,mA)),[[o]])}Qn.render=gA;var Pl={name:"PlusIcon",extends:ze};const yA=f("g",{"clip-path":"url(#clip0_306_11939)"},[f("path",{d:"M7.67742 6.32258V0.677419C7.67742 0.497757 7.60605 0.325452 7.47901 0.198411C7.35197 0.0713707 7.17966 0 7 0C6.82034 0 6.64803 0.0713707 6.52099 0.198411C6.39395 0.325452 6.32258 0.497757 6.32258 0.677419V6.32258H0.677419C0.497757 6.32258 0.325452 6.39395 0.198411 6.52099C0.0713707 6.64803 0 6.82034 0 7C0 7.17966 0.0713707 7.35197 0.198411 7.47901C0.325452 7.60605 0.497757 7.67742 0.677419 7.67742H6.32258V13.3226C6.32492 13.5015 6.39704 13.6725 6.52358 13.799C6.65012 13.9255 6.82106 13.9977 7 14C7.17966 14 7.35197 13.9286 7.47901 13.8016C7.60605 13.6745 7.67742 13.5022 7.67742 13.3226V7.67742H13.3226C13.5022 7.67742 13.6745 7.60605 13.8016 7.47901C13.9286 7.35197 14 7.17966 14 7C13.9977 6.82106 13.9255 6.65012 13.799 6.52358C13.6725 6.39704 13.5015 6.32492 13.3226 6.32258H7.67742Z",fill:"currentColor"})],-1),bA=f("defs",null,[f("clipPath",{id:"clip0_306_11939"},[f("rect",{width:"14",height:"14",fill:"white"})])],-1),vA=[yA,bA];function _A(e,t,n,i,r,s){return g(),S("svg",R({width:"14",height:"14",viewBox:"0 0 14 14",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e.pti()),vA,16)}Pl.render=_A;var Qt={name:"TimesIcon",extends:ze};const wA=f("path",{d:"M8.01186 7.00933L12.27 2.75116C12.341 2.68501 12.398 2.60524 12.4375 2.51661C12.4769 2.42798 12.4982 2.3323 12.4999 2.23529C12.5016 2.13827 12.4838 2.0419 12.4474 1.95194C12.4111 1.86197 12.357 1.78024 12.2884 1.71163C12.2198 1.64302 12.138 1.58893 12.0481 1.55259C11.9581 1.51625 11.8617 1.4984 11.7647 1.50011C11.6677 1.50182 11.572 1.52306 11.4834 1.56255C11.3948 1.60204 11.315 1.65898 11.2488 1.72997L6.99067 5.98814L2.7325 1.72997C2.59553 1.60234 2.41437 1.53286 2.22718 1.53616C2.03999 1.53946 1.8614 1.61529 1.72901 1.74767C1.59663 1.88006 1.5208 2.05865 1.5175 2.24584C1.5142 2.43303 1.58368 2.61419 1.71131 2.75116L5.96948 7.00933L1.71131 11.2675C1.576 11.403 1.5 11.5866 1.5 11.7781C1.5 11.9696 1.576 12.1532 1.71131 12.2887C1.84679 12.424 2.03043 12.5 2.2219 12.5C2.41338 12.5 2.59702 12.424 2.7325 12.2887L6.99067 8.03052L11.2488 12.2887C11.3843 12.424 11.568 12.5 11.7594 12.5C11.9509 12.5 12.1346 12.424 12.27 12.2887C12.4053 12.1532 12.4813 11.9696 12.4813 11.7781C12.4813 11.5866 12.4053 11.403 12.27 11.2675L8.01186 7.00933Z",fill:"currentColor"},null,-1),EA=[wA];function SA(e,t,n,i,r,s){return g(),S("svg",R({width:"14",height:"14",viewBox:"0 0 14 14",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e.pti()),EA,16)}Qt.render=SA;var wf={name:"UploadIcon",extends:ze};const CA=f("g",{"clip-path":"url(#clip0_414_21072)"},[f("path",{"fill-rule":"evenodd","clip-rule":"evenodd",d:"M6.58942 9.82197C6.70165 9.93405 6.85328 9.99793 7.012 10C7.17071 9.99793 7.32234 9.93405 7.43458 9.82197C7.54681 9.7099 7.61079 9.55849 7.61286 9.4V2.04798L9.79204 4.22402C9.84752 4.28011 9.91365 4.32457 9.98657 4.35479C10.0595 4.38502 10.1377 4.40039 10.2167 4.40002C10.2956 4.40039 10.3738 4.38502 10.4467 4.35479C10.5197 4.32457 10.5858 4.28011 10.6413 4.22402C10.7538 4.11152 10.817 3.95902 10.817 3.80002C10.817 3.64102 10.7538 3.48852 10.6413 3.37602L7.45127 0.190618C7.44656 0.185584 7.44176 0.180622 7.43687 0.175736C7.32419 0.063214 7.17136 0 7.012 0C6.85264 0 6.69981 0.063214 6.58712 0.175736C6.58181 0.181045 6.5766 0.186443 6.5715 0.191927L3.38282 3.37602C3.27669 3.48976 3.2189 3.6402 3.22165 3.79564C3.2244 3.95108 3.28746 4.09939 3.39755 4.20932C3.50764 4.31925 3.65616 4.38222 3.81182 4.38496C3.96749 4.3877 4.11814 4.33001 4.23204 4.22402L6.41113 2.04807V9.4C6.41321 9.55849 6.47718 9.7099 6.58942 9.82197ZM11.9952 14H2.02883C1.751 13.9887 1.47813 13.9228 1.22584 13.8061C0.973545 13.6894 0.746779 13.5241 0.558517 13.3197C0.370254 13.1154 0.22419 12.876 0.128681 12.6152C0.
2570331723 12.3545 -0.00990605 12.0775 0.0019109 11.8V9.40005C0.0019109 9.24092 0.065216 9.08831 0.1779 8.97579C0.290584 8.86326 0.443416 8.80005 0.602775 8.80005C0.762134 8.80005 0.914966 8.86326 1.02765 8.97579C1.14033 9.08831 1.20364 9.24092 1.20364 9.40005V11.8C1.18295 12.0376 1.25463 12.274 1.40379 12.4602C1.55296 12.6463 1.76817 12.7681 2.00479 12.8H11.9952C12.2318 12.7681 12.447 12.6463 12.5962 12.4602C12.7453 12.274 12.817 12.0376 12.7963 11.8V9.40005C12.7963 9.24092 12.8596 9.08831 12.9723 8.97579C13.085 8.86326 13.2378 8.80005 13.3972 8.80005C13.5565 8.80005 13.7094 8.86326 13.8221 8.97579C13.9347 9.08831 13.998 9.24092 13.998 9.40005V11.8C14.022 12.3563 13.8251 12.8996 13.45 13.3116C13.0749 13.7236 12.552 13.971 11.9952 14Z",fill:"currentColor"})],-1),IA=f("defs",null,[f("clipPath",{id:"clip0_414_21072"},[f("rect",{width:"14",height:"14",fill:"white"})])],-1),TA=[CA,IA];function PA(e,t,n,i,r,s){return g(),S("svg",R({width:"14",height:"14",viewBox:"0 0 14 14",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e.pti()),TA,16)}wf.render=PA;var yn={name:"CheckIcon",extends:ze};const OA=f("path",{d:"M4.86199 11.5948C4.78717 11.5923 4.71366 11.5745 4.64596 11.5426C4.57826 11.5107 4.51779 11.4652 4.46827 11.4091L0.753985 7.69483C0.683167 7.64891 0.623706 7.58751 0.580092 7.51525C0.536478 7.44299 0.509851 7.361
25777 0.502221 7.27771C0.49459 7.19366 0.506156 7.10897 0.536046 7.03004C0.565935 6.95111 0.613367 6.88 0.674759 6.82208C0.736151 6.76416 0.8099 6.72095 0.890436 6.69571C0.970973 6.67046 1.05619 6.66385 1.13966 6.67635C1.22313 6.68886 1.30266 6.72017 1.37226 6.76792C1.44186 6.81567 1.4997 6.8786 1.54141 6.95197L4.86199 10.2503L12.6397 2.49483C12.7444 2.42694 12.8689 2.39617 12.9932 2.40745C13.1174 2.41873 13.2343 2.47141 13.3251 2.55705C13.4159 2.64268 13.4753 2.75632 13.4938 2.87973C13.5123 3.00315 13.4888 3.1292 13.4271 3.23768L5.2557 11.4091C5.20618 11.4652 5.14571 11.5107 5.07801 11.5426C5.01031 11.5745 4.9368 11.5923 4.86199 11.5948Z",fill:"currentColor"},null,-1),AA=[OA];function kA(e,t,n,i,r,s){return g(),S("svg",R({width:"14",height:"14",viewBox:"0 0 14 14",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e.pti()),AA,16)}yn.render=kA;var bi={name:"ExclamationTriangleIcon",extends:ze};const RA=Tr('<g clip-path="url(#clip0_323_12417)"><path d="M13.4018 13.1893H0.598161C0.49329 13.189 0.390283 13.1615 0.299143 13.1097C0.208003 13.0578 0.131826 12.9832 0.0780112 12.8932C0.0268539 12.8015 0 12.6982 0 12.5931C0 12.4881 0.0268539 12.3848 0.0780112 12.293L6.47985 1.08982C6.53679 1.00399 6.61408 0.933574 6.70484 0.884867C6.7956 0.836159 6.897 0.810669 7 0.810669C7.103 0.810669 7.2044 0.836159 7.29516 0.884867C7.38592 0.933574 7.46321 1.00399 7.52015 1.08982L13.922 12.293C13.9731 12.3848 14 12.4881 14 12.5931C14 12.6982 13.9731 12.8015 13.922 12.8932C13.8682 12.9832 13.792 13.0578 13.7009 13.1097C13.6097 13.1615 13.5067 13.189 13.4018 13.1893ZM1.63046 11.989H12.3695L7 2.59425L1.63046 11.989Z" fill="currentColor"></path><path d="M6.99996 8.78801C6.84143 8.78594 6.68997 8.72204 6.57787 8.60993C6.46576 8.49782 6.40186 8.34637 6.39979 8.18784V5.38703C6.39979 5.22786 6.46302 5.0752 6.57557 4.96265C6.68813 4.85009 6.84078 4.78686 6.99996 4.78686C7.15914 4.78686 7.31179 4.85009 7.42435 4.96265C7.5369 5.0752 7.60013 5.22786 7.60013 5.38703V8.18784C7.59806 8.34637 7.53416 8.49782 7.42205 8.60993C7.30995 8.72204 7.15849 8.78594 6.99996 8.78801Z" fill="currentColor"></path><path d="M6.99996 11.1887C6.84143 11.1866 6.68997 11.1227 6.57787 11.0106C6.46576 10.8985 6.40186 10.7471 6.39979 10.5885V10.1884C6.39979 10.0292 6.46302 9.87658 6.57557 9.76403C6.68813 9.65147 6.84078 9.58824 6.99996 9.58824C7.15914 9.58824 7.31179 9.65147 7.42435 9.76403C7.5369 9.87658 7.60013 10.0292 7.60013 10.1884V10.5885C7.59806 10.7471 7.53416 10.8985 7.42205 11.0106C7.30995 11.1227 7.15849 11.1866 6.99996 11.1887Z" fill="currentColor"></path></g><defs><clipPath id="clip0_323_12417"><rect width="14" height="14" fill="white"></rect></clipPath></defs>',2),LA=[RA];function NA(e,t,n,i,r,s){return g(),S("svg",R({width:"14",height:"14",viewBox:"0 0 14 14",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e.pti()),LA,16)}bi.render=NA;var vi={name:"InfoCircleIcon",extends:ze};const DA=f("g",{"clip-path":"url(#clip0_408_21102)"},[f("path",{"fill-rule":"evenodd","clip-rule":"evenodd",d:"M3.11101 12.8203C4.26215 13.5895 5.61553 14 7 14C8.85652 14 10.637 13.2625 11.9497 11.9497C13.2625 10.637 14 8.85652 14 7C14 5.61553 13.5895 4.26215 12.8203 3.11101C12.0511 1.95987 10.9579 1.06266 9.67879 0.532846C8.3997 0.00303296 6.99224 -0.13559 5.63437 0.134506C4.2765 0.404603 3.02922 1.07129 2.05026 2.05026C1.07129 3.02922 0.404603 4.2765 0.134506 5.63437C-0.13559 6.99224 0.00303296 8.3997 0.532846 9.67879C1.06266 10.9579 1.95987 12.0511 3.11101 12.8203ZM3.75918 2.14976C4.71846 1.50879 5.84628 1.16667 7 1.16667C8.5471 1.16667 10.0308 1.78125 11.1248 2.87521C12.2188 3.96918 12.8333 5.45291 12.8333 7C12.8333 8.15373 12.4912 9.28154 11.8502 10.2408C11.2093 11.2001 10.2982 11.9478 9.23232 12.3893C8.16642 12.8308 6.99353 12.9463 5.86198 12.7212C4.73042 12.4962 3.69102 11.9406 2.87521 11.1248C2.05941 10.309 1.50384 9.26958 1.27876 8.13803C1.05367 7.00647 1.16919 5.83358 1.61071 4.76768C2.05222 3.70178 2.79989 2.79074 3.75918 2.14976ZM7.00002 4.8611C6.84594 4.85908 6.69873 4.79698 6.58977 4.68801C6.48081 4.57905 6.4187 4.43185 6.41669 4.27776V3.88888C6.41669 3.73417 6.47815 3.58579 6.58754 3.4764C6.69694 3.367 6.84531 3.30554 7.00002 3.30554C7.15473 3.30554 7.3031 3.367 7.4125 3.4764C7.52189 3.58579 7.58335 3.73417 7.58335 3.88888V4.27776C7.58134 4.43185 7.51923 4.57905 7.41027 4.68801C7.30131 4.79698 7.1541 4.85908 7.00002 4.8611ZM7.00002 10.6945C6.84594 10.6925 6.69873 10.6304 6.58977 10.5214C6.48081 10.4124 6.4187 10.2652 6.41669 10.1111V6.22225C6.41669 6.06754 6.47815 5.91917 6.58754 5.80977C6.69694 5.70037 6.84531 5.63892 7.00002 5.63892C7.15473 5.63892 7.3031 5.70037 7.4125 5.80977C7.52189 5.91917 7.58335 6.06754 7.58335 6.22225V10.1111C7.58134 10.2652 7.51923 10.4124 7.41027 10.5214C7.30131 10.6304 7.1541 10.6925 7.00002 10.6945Z",fill:"currentColor"})],-1),xA=f("defs",null,[f("clipPath",{id:"clip0_408_21102"},[f("rect",{width:"14",height:"14",fill:"white"})])],-1),MA=[DA,xA];function FA(e,t,n,i,r,s){return g(),S("svg",R({width:"14",height:"14",viewBox:"0 0 14 14",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e.pti()),MA,16)}vi.render=FA;var ds={name:"TimesCircleIcon",extends:ze};const VA=f("g",{"clip-path":"url(#clip0_334_13179)"},[f("path",{"fill-rule":"evenodd","clip-rule":"evenodd",d:"M7 14C5.61553 14 4.26215 13.5895 3.11101 12.8203C1.95987 12.0511 1.06266 10.9579 0.532846 9.67879C0.00303296 8.3997 -0.13559 6.99224 0.134506 5.63437C0.404603 4.2765 1.07129 3.02922 2.05026 2.05026C3.02922 1.07129 4.2765 0.404603 5.63437 0.134506C6.99224 -0.13559 8.3997 0.00303296 9.67879 
2570.532846C10.9579 1.06266 12.0511 1.95987 12.8203 3.11101C13.5895 4.26215 14 5.61553 14 7C14 8.85652 13.2625 10.637 11.9497 11.9497C10.637 13.2625 8.85652 14 7 14ZM7 1.16667C5.84628 1.16667 4.71846 1.50879 3.75918 2.14976C2.79989 2.79074 2.05222 3.70178 1.61071 4.76768C1.16919 5.83358 1.05367 7.00647 1.27876 8.13803C1.50384 9.26958 2.05941 10.309 2.87521 11.1248C3.69102 11.9406 4.73042 12.4962 5.86198 12.7212C6.99353 12.9463 8.16642 12.8308 9.23232 12.3893C10.2982 11.9478 11.2093 11.2001 11.8502 10.2408C12.4912 9.28154 12.8333 8.15373 12.8333 7C12.8333 5.45291 12.2188 3.96918 11.1248 2.87521C10.0308 1.78125 8.5471 1.16667 7 1.16667ZM4.66662 9.91668C4.58998 9.91704 4.51404 9.90209 4.44325 9.87271C4.37246 9.84333 4.30826 9.8001 4.2544 9.74557C4.14516 9.6362 4.0838 9.48793 4.0838 9.33335C4.0838 9.17876 4.14516 9.0305 4.2544 8.92113L6.17553 7L4.25443 5.07891C4.15139 4.96832 4.09529 4.82207 4.09796 4.67094C4.10063 4.51982 4.16185 4.37563 4.26872 4.26876C4.3756 4.16188 4.51979 4.10066 4.67091 4.09799C4.82204 4.09532 4.96829 4.15142 5.07887 4.25446L6.99997 6.17556L8.92106 4.25446C9.03164 4.15142 9.1779 4.09532 9.32903 4.09799C9.48015 4.10066 9.62434 4.16188 9.73121 4.26876C9.83809 4.37563 9.89931 4.51982 9.90198 4.67094C9.90464 4.82207 9.84855 4.96832 9.74551 5.07891L7.82441 7L9.74554 8.92113C9.85478 9.0305 9.91614 9.17876 9.91614 9.33335C9.91614 9.48793 9.85478 9.6362 9.74554 9.74557C9.69168 9.8001 9.62748 9.84333 9.55669 9.87271C9.4859 9.90209 9.40996 9.91704 9.33332 9.91668C9.25668 9.91704 9.18073 9.90209 9.10995 9.87271C9.03916 9.84333 8.97495 9.8001 8.9211 9.74557L6.99997 7.82444L5.07884 9.74557C5.02499 9.8001 4.96078 9.84333 4.88999 9.87271C4.81921 9.90209 4.74326 9.91704 4.66662 9.91668Z",fill:"currentColor"})],-1),BA=f("defs",null,[f("clipPath",{id:"clip0_334_13179"},[f("rect",{width:"14",height:"14",fill:"white"})])],-1),$A=[VA,BA];function UA(e,t,n,i,r,s){return g(),S("svg",R({width:"14",height:"14",viewBox:"0 0 14 14",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e.pti()),$A,16)}ds.render=UA;var Ef={name:"Message",extends:Ve,emits:["close"],props:{severity:{type:String,default:"info"},closable:{type:Boolean,default:!0},sticky:{type:Boolean,default:!0},life:{type:Number,default:3e3},icon:{type:String,default:void 0},closeIcon:{type:String,default:void 0},closeButtonProps:{type:null,default:null}},timeout:null,data(){return{visible:!0}},mounted(){this.sticky||this.closeAfterDelay()},methods:{close(e){this.visible=!1,this.$emit("close",e)},closeAfterDelay(){setTimeout(()=>{this.visible=!1},this.life)}},computed:{containerClass(){return"p-message p-component p-message-"+this.severity},iconComponent(){return{info:vi,success:yn,warn:bi,error:ds}[this.severity]},closeAriaLabel(){return this.$primevue.config.locale.aria?this.$primevue.config.locale.aria.close:void 0}},directives:{ripple:gt},components:{TimesIcon:Qt,InfoCircleIcon:vi,CheckIcon:yn,ExclamationTriangleIcon:bi,TimesCircleIcon:ds}};const HA=["aria-label"];function zA(e,t,n,i,r,s){const a=le("TimesIcon"),o=Xe("ripple");return g(),Q($t,{name:"p-message",appear:""},{default:Ee(()=>[Ne(f("div",R({class:s.containerClass,role:"alert","aria-live":"assertive","aria-atomic":"true"},e.ptm("root")),[f("div",R({class:"p-message-wrapper"},e.ptm("wrapper")),[he(e.$slots,"messageicon",{class:"p-message-icon"},()=>[(g(),Q(_e(n.icon?"span":s.iconComponent),R({class:["p-message-icon",n.icon]},e.ptm("icon")),null,16,["class"]))]),f("div",R({class:"p-message-text"},e.ptm("text")),[he(e.$slots,"default")],16),n.closable?Ne((g(),S("button",R({key:0,class:"p-message-close p-link","aria-label":s.closeAriaLabel,type:"button",onClick:t[0]||(t[0]=l=>s.close(l))},{...n.closeButtonProps,...e.ptm("button")}),[he(e.$slots,"closeicon",{class:"p-message-close-icon"},()=>[n.closeIcon?(g(),S("i",R({key:0,class:["p-message-close-icon",n.closeIcon]},e.ptm("buttonIcon")),null,16)):(g(),Q(a,R({key:1,class:"p-message-close-icon"},e.ptm("buttonIcon")),null,16))])],16,HA)),[[o]]):M("",!0)],16)],16),[[mt,r.visible]])]),_:3})}function KA(e,t){t===void 0&&(t={});var n=t.insertAt;if(!(typeof document>"u")){var i=document.head||document.getElementsByTagName("head")[0],r=document.createElement("style");r.type="text/css",n==="top"&&i.firstChild?i.insertBefore(r,i.firstChild):i.appendChild(r),r.styleSheet?r.styleSheet.cssText=e:r.appendChild(document.createTextNode(e))}}var GA=`
258.p-message-wrapper {
259    display: flex;
260    align-items: center;
261}
262.p-message-close {
263    display: flex;
264    align-items: center;
265    justify-content: center;
266}
267.p-message-close.p-link {
268    margin-left: auto;
269    overflow: hidden;
270    position: relative;
271}
272.p-message-enter-from {
273    opacity: 0;
274}
275.p-message-enter-active {
276    transition: opacity 0.3s;
277}
278.p-message.p-message-leave-from {
279    max-height: 1000px;
280}
281.p-message.p-message-leave-to {
282    max-height: 0;
283    opacity: 0;
284    margin: 0 !important;
285}
286.p-message-leave-active {
287    overflow: hidden;
288    transition: max-height 0.3s cubic-bezier(0, 1, 0, 1), opacity 0.3s, margin 0.15s;
289}
290.p-message-leave-active .p-message-close {
291    display: none;
292}
293`;KA(GA);Ef.render=zA;var Ol={name:"ProgressBar",extends:Ve,props:{value:{type:Number,default:null},mode:{type:String,default:"determinate"},showValue:{type:Boolean,default:!0}},computed:{containerClass(){return["p-progressbar p-component",{"p-progressbar-determinate":this.determinate,"p-progressbar-indeterminate":this.indeterminate}]},progressStyle(){return{width:this.value+"%",display:"flex"}},indeterminate(){return this.mode==="indeterminate"},determinate(){return this.mode==="determinate"}}};const jA=["aria-valuenow"];function YA(e,t,n,i,r,s){return g(),S("div",R({role:"progressbar",class:s.containerClass,"aria-valuemin":"
2930","aria-valuenow":n.value,"aria-valuemax":"100"},e.ptm("root")),[s.determinate?(g(),S("div",R({key:0,class:"p-progressbar-value p-progressbar-value-animate",style:s.progressStyle},e.ptm("value")),[n.value!=null&&n.value!==0&&n.showValue?(g(),S("div",R({key:0,class:"p-progressbar-label"},e.ptm("label")),[he(e.$slots,"default",{},()=>[ke(N(n.value+"%"),1)])],16)):M("",!0)],16)):M("",!0),s.indeterminate?(g(),S("div",R({key:1,class:"p-progressbar-indeterminate-container"},e.ptm("root")),[f("div",R({class:"p-progressbar-value p-progressbar-value-animate"},e.ptm("value")),null,16)],16)):M("",!0)],16,jA)}function WA(e,t){t===void 0&&(t={});var n=t.insertAt;if(!(typeof document>"u")){var i=document.head||document.getElementsByTagName("head")[0],r=document.createElement("style");r.type="text/css",n==="top"&&i.firstChild?i.insertBefore(r,i.firstChild):i.appendChild(r),r.styleSheet?r.styleSheet.cssText=e:r.appendChild(document.createTextNode(e))}}var QA=`
294.p-progressbar {
295    position: relative;
296    overflow: hidden;
297}
298.p-progressbar-determinate .p-progressbar-value {
299    height: 100%;
300    width: 0%;
301    position: absolute;
302    display: none;
303    border: 0 none;
304    display: flex;
305    align-items: center;
306    justify-content: center;
307    overflow: hidden;
308}
309.p-progressbar-determinate .p-progressbar-label {
310    display: inline-flex;
311}
312.p-progressbar-determinate .p-progressbar-value-animate {
313    transition: width 1s ease-in-out;
314}
315.p-progressbar-indeterminate .p-progressbar-value::before {
316    content: '';
317    position: absolute;
318    background-color: inherit;
319    top: 0;
320    left: 0;
321    bottom: 0;
322    will-change: left, right;
323    -webkit-animation: p-progressbar-indeterminate-anim 2.1s cubic-bezier(0.65, 0.815, 0.735, 0.395) infinite;
324    animation: p-progressbar-indeterminate-anim 2.1s cubic-bezier(0.65, 0.815, 0.735, 0.395) infinite;
325}
326.p-progressbar-indeterminate .p-progressbar-value::after {
327    content: '';
328    position: absolute;
329    background-color: inherit;
330    top: 0;
331    left: 0;
332    bottom: 0;
333    will-change: left, right;
334    -webkit-animation: p-progressbar-indeterminate-anim-short 2.1s cubic-bezier(0.165, 0.84, 0.44, 1) infinite;
335    animation: p-progressbar-indeterminate-anim-short 2.1s cubic-bezier(0.165, 0.84, 0.44, 1) infinite;
336    -webkit-animation-delay: 1.15s;
337    animation-delay: 1.15s;
338}
339@-webkit-keyframes p-progressbar-indeterminate-anim {
3400% {
341        left: -35%;
342        right: 100%;
343}
34460% {
345        left: 100%;
346        right: -90%;
347}
348100% {
349        left: 100%;
350        right: -90%;
351}
352}
353@keyframes p-progressbar-indeterminate-anim {
3540% {
355        left: -35%;
356        right: 100%;
357}
35860% {
359        left: 100%;
360        right: -90%;
361}
362100% {
363        left: 100%;
364        right: -90%;
365}
366}
367@-webkit-keyframes p-progressbar-indeterminate-anim-short {
3680% {
369        left: -200%;
370        right: 100%;
371}
37260% {
373        left: 107%;
374        right: -8%;
375}
376100% {
377        left: 107%;
378        right: -8%;
379}
380}
381@keyframes p-progressbar-indeterminate-anim-short {
3820% {
383        left: -200%;
384        right: 100%;
385}
38660% {
387        left: 107%;
388        right: -8%;
389}
390100% {
391        left: 107%;
392        right: -8%;
393}
394}
395`;WA(QA);Ol.render=YA;var Al={name:"Badge",extends:Ve,props:{value:{type:[String,Number],default:null},severity:{type:String,default:null},size:{type:String,default:null}},computed:{containerClass(){return this.$slots.default?"p-overlay-badge":this.badgeClass},badgeClass(){return["p-badge p-component",{"p-badge-no-gutter":ve.isNotEmpty(this.value)&&String(this.value).length===1,"p-badge-dot":ve.isEmpty(this.value)&&!this.$slots.default,"p-badge-lg":this.size==="large","p-badge-xl":this.size==="xlarge","p-badge-info":this.severity==="info","p-badge-success":this.severity==="success","p-badge-warning":this.severity==="warning","p-badge-danger":this.severity==="danger"}]}}};function ZA(e,t,n,i,r,s){return g(),S("span",R({class:s.badgeClass},e.ptm("root")),[he(e.$slots,"default",{},()=>[ke(N(n.value),1)])],16)}Al.render=ZA;var Sf={extends:Ve,emits:["remove"],props:{files:{type:Array,default:()=>[]},badgeSeverity:{type:String,default:"warning"}
395,badgeValue:{type:String,default:null},previewWidth:{type:Number,default:50},templates:{type:null,default:null}},methods:{formatSize(e){if(e===0)return"0 B";let t=1e3,n=3,i=["B","KB","MB","GB","TB","PB","EB","ZB","YB"],r=Math.floor(Math.log(e)/Math.log(t));return parseFloat((e/Math.pow(t,r)).toFixed(n))+" "+i[r]}},components:{FileUploadButton:Qn,FileUploadBadge:Al,TimesIcon:Qt}};const qA=["alt","src","width"];function JA(e,t,n,i,r,s){const a=le("FileUploadBadge"),o=le("TimesIcon"),l=le("FileUploadButton");return g(!0),S(J,null,ye(n.files,(c,d)=>(g(),S("div",R({key:c.name+c.type+c.size,class:"p-fileupload-file"},e.ptm("file")),[f("img",R({role:"presentation",class:"p-fileupload-file-thumbnail",alt:c.name,src:c.objectURL,width:n.previewWidth},e.ptm("thumbnail")),null,16,qA),f("div",R({class:"p-fileupload-file-details"},e.ptm("details")),[f("div",R({class:"p-fileupload-file-name"},e.ptm("fileName")),N(c.name),17),f("span",R({class:"p-fileupload-file-size"},e.ptm("fileSize")),N(s.formatSize(c.size)),17),de(a,{value:n.badgeValue,class:"p-fileupload-file-badge",severity:n.badgeSeverity,pt:e.ptm("badge")},null,8,["value","severity","pt"])],16),f("div",R({class:"p-fileupload-file-actions"},e.ptm("actions")),[de(l,{onClick:u=>e.$emit("remove",d),text:"",rounded:"",severity:"danger",class:"p-fileupload-file-remove",pt:e.ptm("removeButton")},{icon:Ee(u=>[n.templates.fileremoveicon?(g(),Q(_e(n.templates.fileremoveicon),{key:0,class:Oe(u.class),file:c,index:d},null,8,["class","file","index"])):(g(),Q(o,R({key:1,class:u.class,"aria-hidden":"true"},e.ptm("removeButton").icon),null,16,["class"]))]),_:2},1032,["onClick","pt"])],16)],16))),128)}Sf.render=JA;var Cf={name:"FileUpload",extends:Ve,emits:["select","uploader","before-upload","progress","upload","error","before-send","clear","remove","remove-uploaded-file"],props:{name:{type:String,default:null},url:{type:String,default:null},mode:{type:String,default:"advanced"},multiple:{type:Boolean,default:!1},accept:{type:String,default:null},disabled:{type:Boolean,default:!1},auto:{type:Boolean,default:!1},maxFileSize:{type:Number,default:null},invalidFileSizeMessage:{type:String,default:"{0}: Invalid file size, file size should be smaller than {1}."},invalidFileTypeMessage:{type:String,default:"{0}: Invalid file type, allowed file types: {1}."},fileLimit:{type:Number,default:null},invalidFileLimitMessage:{type:String,default:"Maximum number of files exceeded, limit is {0} at most."},withCredentials:{type:Boolean,default:!1},previewWidth:{type:Number,default:50},chooseLabel:{type:String,default:null},uploadLabel:{type:String,default:null},cancelLabel:{type:String,default:null},customUpload:{type:Boolean,default:!1},showUploadButton:{type:Boolean,default:!0},showCancelButton:{type:Boolean,default:!0},chooseIcon:{type:String,default:void 0},uploadIcon:{type:String,default:void 0},cancelIcon:{type:String,default:void 0},style:null,class:null},duplicateIEEvent:!1,data(){return{uploadedFileCount:0,files:[],messages:[],focused:!1,progress:null,uploadedFiles:[]}},methods:{onFileSelect(e){if(e.type!=="drop"&&this.isIE11()&&this.duplicateIEEvent){this.duplicateIEEvent=!1;return}this.messages=[],this.files=this.files||[];let t=e.dataTransfer?e.dataTransfer.files:e.target.files;for(let n of t)this.isFileSelected(n)||this.validate(n)&&(this.isImage(n)&&(n.objectURL=window.URL.createObjectURL(n)),this.files.push(n));this.$emit("select",{originalEvent:e,files:this.files}),this.fileLimit&&this.checkFileLimit(),this.auto&&this.hasFiles&&!this.isFileLimitExceeded()&&this.upload(),e.type!=="drop"&&this.isIE11()?this.clearIEInput():this.clearInputElement()},choose(){this.$refs.fileInput.click()},upload(){if(this.customUpload)this.fileLimit&&(this.uploadedFileCount+=this.files.length),this.$emit("uploader",{files:this.files}),this.clear();else{let e=new XMLHttpRequest,t=new FormData;this.$emit("before-upload",{xhr:e,formData:t});for(let n of this.files)t.append(this.name,n,n.name);e.upload.addEventListener("progress",n=>{n.lengthComputable&&(this.progress=Math.round(n.loaded*100/n.total)),this.$emit("progress",{originalEvent:n,progress:this.progress})}),e.onreadystatechange=()=>{e.readyState===4&&(this.progress=0,e.status>=200&&e.status<300?(this.fileLimit&&(this.uploadedFileCount+=this.files.length),this.$emit("upload",{xhr:e,files:this.files})):this.$emit("error",{xhr:e,files:this.files}),this.uploadedFiles.push(...this.files),this.clear())},e.open("POST",this.url,!0),this.$emit("before-send",{xhr:e,formData:t}),e.withCredentials=this.withCredentials,e.send(t)}},clear(){this.files=[],this.messages=null,this.$emit("clear"),this.isAdvanced&&this.clearInputElement()},onFocus(){this.focused=!0},onBlur(){this.focused=!1},isFileSelected(e){if(this.files&&this.files.length){for(let t of this.files)if(t.name+t.type+t.size===e.name+e.type+e.size)return!0}return!1},isIE11(){return!!window.MSInputMethodContext&&!!document.documentMode},validate(e){return this.accept&&!this.isFileTypeValid(e)?(this.messages.push(this.invalidFileTypeMessage.replace("{0}",e.name).replace("{1}",this.accept)),!1):this.maxFileSize&&e.size>this.maxFileSize?(this.messages.push(this.invalidFileSizeMessage.replace("{0}",e.name).replace("{1}",this.formatSize(this.maxFileSize))),!1):!0},isFileTypeValid(e){let t=this.accept.split(",").map(n=>n.trim());for(let n of t)if(this.isWildcard(n)?this.getTypeClass(e.type)===this.getTypeClass(n):e.type==n||this.getFileExtension(e).toLowerCase()===n.toLowerCase())return!0;return!1},getTypeClass(e){return e.substring(0,e.indexOf("/"))},isWildcard(e){return e.indexOf("*")!==-1},getFileExtension(e){return"."+e.name.split(".").pop()},isImage(e){return/^image\//.test(e.type)},onDragEnter(e){this.disabled||(e.stopPropagation(),e.preventDefault())},onDragOver(e){this.disabled||(F.addClass(this.$refs.content,"p-fileupload-highlight"),e.stopPropagation(),e.preventDefault())},onDragLeave(){this.disabled||F.removeClass(this.$refs.content,"p-fileupload-highlight")},onDrop(e){if(!this.disabled){F.removeClass(this.$refs.content,"p-fileupload-highlight"),e.stopPropagation(),e.preventDefault();const t=e.dataTransfer?e.dataTransfer.files:e.target.files;(this.multiple||t&&t.length===1)&&this.onFileSelect(e)}},onBasicUploaderClick(){this.hasFiles?this.upload():this.$refs.fileInput.click()},remove(e){this.clearInputElement();let t=this.files.splice(e,1)[0];this.files=[...this.files],this.$emit("remove",{file:t,files:this.files})},removeUploadedFile(e){let t=this.uploadedFiles.splice(e,1)[0];this.uploadedFiles=[...this.uploadedFiles],this.$emit("remove-uploaded-file",{file:t,files:this.uploadedFiles})},clearInputElement(){this.$refs.fileInput.value=""},clearIEInput(){this.$refs.fileInput&&(this.duplicateIEEvent=!0,this.$refs.fileInput.value="")},formatSize(e){if(e===0)return"0 B";let t=1e3,n=3,i=["B","KB","MB","GB","TB","PB","EB","ZB","YB"],r=Math.floor(Math.log(e)/Math.log(t));return parseFloat((e/Math.pow(t,r)).toFixed(n))+" "+i[r]},isFileLimitExceeded(){return this.fileLimit&&this.fileLimit<=this.files.length+this.uploadedFileCount&&this.focused&&(this.focused=!1),this.fileLimit&&this.fileLimit<this.files.length+this.uploadedFileCount},checkFileLimit(){this.isFileLimitExceeded()&&this.messages.push(this.invalidFileLimitMessage.replace("{0}",this.fileLimit.toString()))},onMessageClose(){this.messages=null}},computed:{isAdvanced(){return this.mode==="advanced"},isBasic(){return this.mode==="basic"},advancedChooseButtonClass(){return["p-button p-component p-fileupload-choose",this.class,{"p-disabled":this.disabled,"p-focus":this.focused}]},basicChooseButtonClass(){return["p-button p-component p-fileupload-choose",this.class,{"p-fileupload-choose-selected":this.hasFiles,"p-disabled":this.disabled,"p-focus":this.focused}]},basicChooseButtonLabel(){return this.auto?this.chooseButtonLabel:this.hasFiles?this.files.map(e=>e.name).join(", "):this.chooseButtonLabel},hasFiles(){return this.files&&this.files.length>0},hasUploadedFiles(){return this.uploadedFiles&&this.uploadedFiles.length>0},chooseDisabled(){return this.disabled||this.fileLimit&&this.fileLimit<=this.files.length+this.uploadedFileCount},uploadDisabled(){return this.disabled||!this.hasFiles||this.fileLimit&&this.fileLimit<this.files.length},cancelDisabled(){return this.disabled||!this.hasFiles},chooseButtonLabel(){return this.chooseLabel||this.$primevue.config.locale.choose},uploadButtonLabel(){return this.uploadLabel||this.$primevue.config.locale.upload},cancelButtonLabel(){return this.cancelLabel||this.$primevue.config.locale.cancel},completedLabel(){return this.$primevue.config.locale.completed}
395,pendingLabel(){return this.$primevue.config.locale.pending}},components:{FileUploadButton:Qn,FileUploadProgressBar:Ol,FileUploadMessage:Ef,FileContent:Sf,PlusIcon:Pl,UploadIcon:wf,TimesIcon:Qt},directives:{ripple:gt}};const XA=["multiple","accept","disabled"],ek=["accept","disabled","multiple"];function tk(e,t,n,i,r,s){const a=le("FileUploadButton"),o=le("FileUploadProgressBar"),l=le("FileUploadMessage"),c=le("FileContent"),d=Xe("ripple");return s.isAdvanced?(g(),S("div",R({key:0,class:"p-fileupload p-fileupload-advanced p-component"},e.ptm("root")),[f("input",R({ref:"fileInput",type:"file",onChange:t[0]||(t[0]=(...u)=>s.onFileSelect&&s.onFileSelect(...u)),multiple:n.multiple,accept:n.accept,disabled:s.chooseDisabled},e.ptm("input")),null,16,XA),f("div",R({class:"p-fileupload-buttonbar"},e.ptm("buttonbar")),[he(e.$slots,"header",{files:r.files,uploadedFiles:r.uploadedFiles,chooseCallback:s.choose,uploadCallback:s.upload,clearCallback:s.clear},()=>[Ne((g(),S("span",R({class:s.advancedChooseButtonClass,style:n.style,onClick:t[1]||(t[1]=(...u)=>s.choose&&s.choose(...u)),onKeydown:t[2]||(t[2]=Je((...u)=>s.choose&&s.choose(...u),["enter"])),onFocus:t[3]||(t[3]=(...u)=>s.onFocus&&s.onFocus(...u)),onBlur:t[4]||(t[4]=(...u)=>s.onBlur&&s.onBlur(...u)),tabindex:"0"},e.ptm("chooseButton")),[he(e.$slots,"chooseicon",{},()=>[(g(),Q(_e(n.chooseIcon?"span":"PlusIcon"),R({class:["p-button-icon p-button-icon-left",n.chooseIcon],"aria-hidden":"true"},e.ptm("chooseIcon")),null,16,["class"]))]),f("span",R({class:"p-button-label"},e.ptm("chooseButtonLabel")),N(s.chooseButtonLabel),17)],16)),[[d]]),n.showUploadButton?(g(),Q(a,{key:0,label:s.uploadButtonLabel,onClick:s.upload,disabled:s.uploadDisabled,pt:e.ptm("uploadButton")},{icon:Ee(u=>[he(e.$slots,"uploadicon",{},()=>[(g(),Q(_e(n.uploadIcon?"span":"UploadIcon"),R({class:[u.class,n.uploadIcon],"aria-hidden":"true"},e.ptm("uploadButton").icon),null,16,["class"]))])]),_:3},8,["label","onClick","disabled","pt"])):M("",!0),n.showCancelButton?(g(),Q(a,{key:1,label:s.cancelButtonLabel,onClick:s.clear,disabled:s.cancelDisabled,pt:e.ptm("cancelButton")},{icon:Ee(u=>[he(e.$slots,"cancelicon",{},()=>[(g(),Q(_e(n.cancelIcon?"span":"TimesIcon"),R({class:[u.class,n.cancelIcon],"aria-hidden":"true"},e.ptm("cancelButton").icon),null,16,["class"]))])]),_:3},8,["label","onClick","disabled","pt"])):M("",!0)])],16),f("div",R({ref:"content",class:"p-fileupload-content",onDragenter:t[5]||(t[5]=(...u)=>s.onDragEnter&&s.onDragEnter(...u)),onDragover:t[6]||(t[6]=(...u)=>s.onDragOver&&s.onDragOver(...u)),onDragleave:t[7]||(t[7]=(...u)=>s.onDragLeave&&s.onDragLeave(...u)),onDrop:t[8]||(t[8]=(...u)=>s.onDrop&&s.onDrop(...u))},e.ptm("content")),[he(e.$slots,"content",{files:r.files,uploadedFiles:r.uploadedFiles,removeUploadedFileCallback:s.removeUploadedFile,removeFileCallback:s.remove,progress:r.progress,messages:r.messages},()=>[s.hasFiles?(g(),Q(o,{key:0,value:r.progress,showValue:!1,pt:e.ptm("progressbar")},null,8,["value","pt"])):M("",!0),(g(!0),S(J,null,ye(r.messages,u=>(g(),Q(l,{key:u,severity:"error",onClose:s.onMessageClose,pt:e.ptm("message")},{default:Ee(()=>[ke(N(u),1)]),_:2},1032,["onClose","pt"]))),128)),s.hasFiles?(g(),Q(c,{key:1,files:r.files,onRemove:s.remove,badgeValue:s.pendingLabel,previewWidth:n.previewWidth,templates:e.$slots,pt:e.pt},null,8,["files","onRemove","badgeValue","previewWidth","templates","pt"])):M("",!0),de(c,{files:r.uploadedFiles,onRemove:s.removeUploadedFile,badgeValue:s.completedLabel,badgeSeverity:"success",previewWidth:n.previewWidth,templates:e.$slots,pt:e.pt},null,8,["files","onRemove","badgeValue","previewWidth","templates","pt"])]),e.$slots.empty&&!s.hasFiles&&!s.hasUploadedFiles?(g(),S("div",R({key:0,class:"p-fileupload-empty"},e.ptm("empty")),[he(e.$slots,"empty")],16)):M("",!0)],16)],16)):s.isBasic?(g(),S("div",R({key:1,class:"p-fileupload p-fileupload-basic p-component"},e.ptm("root")),[(g(!0),S(J,null,ye(r.messages,u=>(g(),Q(l,{key:u,severity:"error",onClose:s.onMessageClose,pt:e.ptm("messages")},{default:Ee(()=>[ke(N(u),1)]),_:2},1032,["onClose","pt"]))),128)),Ne((g(),S("span",R({class:s.basicChooseButtonClass,style:n.style,onMouseup:t[12]||(t[12]=(...u)=>s.onBasicUploaderClick&&s.onBasicUploaderClick(...u)),onKeydown:t[13]||(t[13]=Je((...u)=>s.choose&&s.choose(...u),["enter"])),onFocus:t[14]||(t[14]=(...u)=>s.onFocus&&s.onFocus(...u)),onBlur:t[15]||(t[15]=(...u)=>s.onBlur&&s.onBlur(...u)),tabindex:"0"},e.ptm("basicButton")),[!s.hasFiles||n.auto?he(e.$slots,"uploadicon",{key:0}
395,()=>[(g(),Q(_e(n.uploadIcon?"span":"UploadIcon"),R({class:["p-button-icon p-button-icon-left",n.uploadIcon],"aria-hidden":"true"},e.ptm("uploadIcon")),null,16,["class"]))]):he(e.$slots,"chooseicon",{key:1},()=>[(g(),Q(_e(n.chooseIcon?"span":"PlusIcon"),R({class:["p-button-icon p-button-icon-left",n.chooseIcon],"aria-hidden":"true"},e.ptm("chooseIcon")),null,16,["class"]))]),f("span",R({class:"p-button-label"},e.ptm("label")),N(s.basicChooseButtonLabel),17),s.hasFiles?M("",!0):(g(),S("input",R({key:2,ref:"fileInput",type:"file",accept:n.accept,disabled:n.disabled,multiple:n.multiple,onChange:t[9]||(t[9]=(...u)=>s.onFileSelect&&s.onFileSelect(...u)),onFocus:t[10]||(t[10]=(...u)=>s.onFocus&&s.onFocus(...u)),onBlur:t[11]||(t[11]=(...u)=>s.onBlur&&s.onBlur(...u))},e.ptm("input")),null,16,ek))],16)),[[d]])],16)):M("",!0)}function nk(e,t){t===void 0&&(t={});var n=t.insertAt;if(!(typeof document>"u")){var i=document.head||document.getElementsByTagName("head")[0],r=document.createElement("style");r.type="text/css",n==="top"&&i.firstChild?i.insertBefore(r,i.firstChild):i.appendChild(r),r.styleSheet?r.styleSheet.cssText=e:r.appendChild(document.createTextNode(e))}}var sk=`
396.p-fileupload-content {
397    position: relative;
398}
399.p-fileupload-content .p-progressbar {
400    width: 100%;
401    position: absolute;
402    top: 0;
403    left: 0;
404}
405.p-button.p-fileupload-choose {
406    position: relative;
407    overflow: hidden;
408}
409.p-fileupload-buttonbar {
410    display: flex;
411    flex-wrap: wrap;
412}
413.p-fileupload > input[type='file'],
414.p-fileupload-basic input[type='file'] {
415    display: none;
416}
417.p-fluid .p-fileupload .p-button {
418    width: auto;
419}
420.p-fileupload-file {
421    display: flex;
422    flex-wrap: wrap;
423    align-items: center;
424}
425.p-fileupload-file-thumbnail {
426    flex-shrink: 0;
427}
428.p-fileupload-file-actions {
429    margin-left: auto;
430}
431`;nk(sk);Cf.render=tk;var If={name:"ArrowDownIcon",extends:ze};const ik=f("g",{"clip-path":"url(#clip0_326_12468)"},[f("path",{"fill-rule":"evenodd","clip-rule":"evenodd",d:"M6.99994 14C6.91097 14.0004 6.82281 13.983 6.74064 13.9489C6.65843 13.9148 6.58387 13.8646 6.52133 13.8013L1.10198 8.38193C0.982318 8.25351 0.917175 8.08367 0.920272 7.90817C0.923368 7.73267 0.994462 7.56523 1.11858 7.44111C1.24269 7.317 1.41014 7.2459 1.58563 7.2428C1.76113 7.23971 1.93098 7.30485 2.0594 7.42451L6.32263 11.6877V0.677419C6.32263 0.497756 6.394 0.325452 6.52104 0.198411C6.64808 0.0713706 6.82039 0 7.00005 0C7.17971 0 7.35202 0.0713706 7.47906 0.198411C7.6061 0.325452 7.67747 0.497756 7.67747 0.677419V11.6877L11.9407 7.42451C12.0691 7.30485 12.2389 7.23971 12.4144 7.2428C12.5899 7.2459 12.7574 7.317 12.8815 7.44111C13.0056 7.56523 13.0767 7.73267 13.0798 7.90817C13.0829 8.08367 13.0178 8.25351 12.8981 8.38193L7.47875 13.8013C7.41621 13.8646 7.34164 13.9148 7.25944 13.9489C7.17727 13.983 7.08912 14.0004 7.00015 14C7.00012 14 7.00009 14 7.00005 14C7.00001 14 6.99998 14 6.99994 14Z",fill:"currentColor"})],-1),rk=f("defs",null,[f("clipPath",{id:"clip0_326_12468"},[f("rect",{width:"14",height:"14",fill:"white"})])],-1),ak=[ik,rk];function ok(e,t,n,i,r,s){return g(),S("svg",R({width:"14",height:"14",viewBox:"0 0 14 14",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e.pti()),ak,16)}If.render=ok;var Tf={name:"ArrowUpIcon",extends:ze};const lk=f("g",{"clip-path":"url(#clip0_326_12509)"},[f("path",{"fill-rule":"evenodd","clip-rule":"evenodd",d:"M6.51551 13.799C6.64205 13.9255 6.813 13.9977 6.99193 14C7.17087 13.9977 7.34182 13.9255 7.46835 13.799C7.59489 13.6725 7.66701 13.5015 7.66935 13.3226V2.31233L11.9326 6.57554C11.9951 6.63887 12.0697 6.68907 12.1519 6.72319C12.2341 6.75731 12.3223 6.77467 12.4113 6.77425C12.5003 6.77467 12.5885 6.75731 12.6707 6.72319C12.7529 6.68907 12.8274 6.63887 12.89 6.57554C13.0168 6.44853 13.0881 6.27635 13.0881 6.09683C13.0881 5.91732 13.0168 5.74514 12.89 5.61812L7.48846 0.216594C7.48274 0.210436 7.4769 0.204374 7.47094 0.198411C7.3439 0.0713707 7.1716 0 6.99193 0C6.81227 0 6.63997 0.0713707 6.51293 0.198411C6.50704 0.204296 6.50128 0.210278 6.49563 0.216354L1.09386 5.61812C0.974201 5.74654 0.909057 5.91639 0.912154 6.09189C0.91525 6.26738 0.986345 6.43483 1.11046 6.55894C1.23457 6.68306 1.40202 6.75415 1.57752 6.75725C1.75302 6.76035 1.92286 6.6952 2.05128 6.57554L6.31451 2.31231V13.3226C6.31685 13.5015 6.38898 13.6725 6.51551 13.799Z",fill:"currentColor"})],-1),ck=f("defs",null,[f("clipPath",{id:"clip0_326_12509"},[f("rect",{width:"14",height:"14",fill:"white"})])],-1),dk=[lk,ck];function uk(e,t,n,i,r,s){return g(),S("svg",R({width:"14",height:"14",viewBox:"0 0 14 14",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e.pti()),dk,16)}Tf.render=uk;var Pf={name:"AngleDoubleLeftIcon",extends:ze};const hk=f("path",{"fill-rule":"evenodd","clip-rule":"evenodd",d:"M5.71602 11.164C5.80782 11.2021 5.9063 11.2215 6.00569 11.221C6.20216 11.2301 6.39427 11.1612 6.54025 11.0294C6.68191 10.8875 6.76148 10.6953 6.76148 10.4948C6.76148 10.2943 6.68191 10.1021 6.54025 9.96024L3.51441 6.9344L6.54025 3.90855C6.624 3.76126 6.65587 3.59011 6.63076 3.42254C6.60564 3.25498 6.525 3.10069 6.40175 2.98442C6.2785 2.86815 6.11978 2.79662 5.95104 2.7813C5.78229 2.76598 5.61329 2.80776 5.47112 2.89994L1.97123 6.39983C1.82957 6.54167 1.75 6.73393 1.75 6.9344C1.75 7.13486 1.82957 7.32712 1.97123 7.46896L5.47112 10.9991C5.54096 11.0698 5.62422 11.1259 5.71602 11.164ZM11.0488 10.9689C11.1775 11.
4311156 11.3585 11.2061 11.5531 11.221C11.7477 11.2061 11.9288 11.1156 12.0574 10.9689C12.1815 10.8302 12.25 10.6506 12.25 10.4645C12.25 10.2785 12.1815 10.0989 12.0574 9.96024L9.03158 6.93439L12.0574 3.90855C12.1248 3.76739 12.1468 3.60881 12.1204 3.45463C12.0939 3.30045 12.0203 3.15826 11.9097 3.04765C11.7991 2.93703 11.6569 2.86343 11.5027 2.83698C11.3486 2.81053 11.19 2.83252 11.0488 2.89994L7.51865 6.36957C7.37699 6.51141 7.29742 6.70367 7.29742 6.90414C7.29742 7.1046 7.37699 7.29686 7.51865 7.4387L11.0488 10.9689Z",fill:"currentColor"},null,-1),pk=[hk];function fk(e,t,n,i,r,s){return g(),S("svg",R({width:"14",height:"14",viewBox:"0 0 14 14",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e.pti()),pk,16)}Pf.render=fk;var kl={name:"FilterIcon",extends:ze};const mk=f("g",{"clip-path":"url(#clip0_390_17708)"},[f("path",{d:"M8.64708 14H5.35296C5.18981 13.9979 5.03395 13.9321 4.91858 13.8167C4.8032 13.7014 4.73745 13.5455 4.73531 13.3824V7L0.329431 0.98C0.259794 0.889466 0.217389 0.780968 0.20718 0.667208C0.19697 0.553448 0.219379 0.439133 0.271783 0.337647C0.324282 0.236453 0.403423 0.151519 0.500663 0.0920138C0.597903 0.0325088 0.709548 0.000692754 0.823548 0H13.1765C13.2905 0.000692754 13.4021 0.0325088 13.4994 0.0920138C13.5966 0.151519 13.6758 0.236453 13.7283 0.337647C13.7807 0.439133 13.8031 0.553448 13.7929 0.667208C13.7826 0.780968 13.7402 0.889466 13.6706 0.98L9.26472 7V13.3824C9.26259 13.5455 9.19683 13.7014 9.08146 13.8167C8.96609 13.9321 8.81022 13.9979 8.64708 14ZM5.97061 12.7647H8.02943V6.79412C8.02878 6.66289 8.07229 6.53527 8.15296 6.43177L11.9412 1.23529H2.05884L5.86355 6.43177C5.94422 6.53527 5.98773 6.66289 5.98708 6.79412L5.97061 12.7647Z",fill:"currentColor"})],-1),gk=f("defs",null,[f("clipPath",{id:"clip0_390_17708"},[f("rect",{width:"14",height:"14",fill:"white"})])],-1),yk=[mk,gk];function bk(e,t,n,i,r,s){return g(),S("svg",R({width:"14",height:"14",viewBox:"0 0 14 14",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e.pti()),yk,16)}kl.render=bk;var Mt=mf(),Kt={name:"Portal",props:{appendTo:{type:String,default:"body"},disabled:{type:Boolean,default:!1}},data(){return{mounted:!1}},mounted(){this.mounted=F.isClient()},computed:{inline(){return this.disabled||this.appendTo==="self"}}};function vk(e,t,n,i,r,s){return s.inline?he(e.$slots,"default",{key:0}):r.mounted?(g(),Q(jg,{key:1,to:n.appendTo},[he(e.$slots,"default")],8,["to"])):M("",!0)}Kt.render=vk;var Li={name:"VirtualScroller",extends:Ve,emits:["update:numToleratedItems","scroll","scroll-index-change","lazy-load"],props:{id:{type:String,default:null},style:null,class:null,items:{type:Array,default:null},itemSize:{type:[Number,Array],default:0},scrollHeight:null,scrollWidth:null,orientation:{type:String,default:"vertical"},numToleratedItems:{type:Number,default:null},delay:{type:Number,default:0},resizeDelay:{type:Number,default:10},lazy:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},loaderDisabled:{type:Boolean,default:!1},columns:{type:Array,default:null},loading:{type:Boolean,default:!1},showSpacer:{type:Boolean,default:!0},showLoader:{type:Boolean,default:!1},tabindex:{type:Number,default:0},inline:{type:Boolean,default:!1},step:{type:Number,default:0},appendOnly:{type:Boolean,default:!1},autoSize:{type:Boolean,default:!1}},data(){return{first:this.isBoth()?{rows:0,cols:0}:0,last:this.isBoth()?{rows:0,cols:0}:0,page:this.isBoth()?{rows:0,cols:0}:0,numItemsInViewport:this.isBoth()?{rows:0,cols:0}:0,lastScrollPos:this.isBoth()?{top:0,left:0}:0,d_numToleratedItems:this.numToleratedItems,d_loading:this.loading,loaderArr:[],spacerStyle:{},contentStyle:{}}},element:null,content:null,lastScrollPos:null,scrollTimeout:null,resizeTimeout:null,defaultWidth:0,defaultHeight:0,defaultContentWidth:0,defaultContentHeight:0,isRangeChanged:!1,lazyLoadState:{},resizeListener:null,initialized:!1,watch:{numToleratedItems(e){this.d_numToleratedItems=e},loading(e){this.d_loading=e},items(e,t){(!t||t.length!==(e||[]).length)&&(this.init(),this.calculateAutoSize())},itemSize(){this.init(),this.calculateAutoSize()},orientation(){this.lastScrollPos=this.isBoth()?{top:0,left:0}:0},scrollHeight(){this.init(),this.calculateAutoSize()},scrollWidth(){this.init(),this.calculateAutoSize()}},mounted(){this.viewInit(),this.lastScrollPos=this.isBoth()?{top:0,left:0}:0,this.lazyLoadState=this.lazyLoadState||{}},updated(){!this.initialized&&this.viewInit()},unmounted(){this.unbindResizeListener(),this.initialized=!1},methods:{viewInit(){F.isVisible(this.element)&&(this.setContentEl(this.content),this.init(),this.bindResizeListener(),this.defaultWidth=F.getWidth(this.element),this.defaultHeight=F.getHeight(this.element),this.defaultContentWidth=F.getWidth(this.content),this.defaultContentHeight=F.getHeight(this.content),this.initialized=!0)},init(){this.disabled||(this.setSize(),this.calculateOptions(),this.setSpacerSize())},isVertical(){return this.orientation==="vertical"},isHorizontal(){return this.orientation==="horizontal"},isBoth(){return this.orientation==="both"},scrollTo(e){this.lastScrollPos=this.both?{top:0,left:0}:0,this.element&&this.element.scrollTo(e)},scrollToIndex(e,t="auto"){const n=this.isBoth(),i=this.isHorizontal(),r=this.first,{numToleratedItems:s}=this.calculateNumItems(),a=this.getContentPosition(),o=this.itemSize,l=(h=0,m)=>h<=m?0:h,c=(h,m,v)=>h*m+v,d=(h=0,m=0)=>this.scrollTo({left:h,top:m,behavior:t});let u=n?{rows:0,cols:0}:0,p=!1;n?(u={rows:l(e[0],s[0]),cols:l(e[1],s[1])},d(c(u.cols,o[1],a.left),c(u.rows,o[0],a.top)),p=u.rows!==r.rows||u.cols!==r.cols
431):(u=l(e,s),i?d(c(u,o,a.left),0):d(0,c(u,o,a.top)),p=u!==r),this.isRangeChanged=p,this.first=u},scrollInView(e,t,n="auto"){if(t){const i=this.isBoth(),r=this.isHorizontal(),{first:s,viewport:a}=this.getRenderedRange(),o=(d=0,u=0)=>this.scrollTo({left:d,top:u,behavior:n}),l=t==="to-start",c=t==="to-end";if(l){if(i)a.first.rows-s.rows>e[0]?o(a.first.cols*this.itemSize[1],(a.first.rows-1)*this.itemSize[0]):a.first.cols-s.cols>e[1]&&o((a.first.cols-1)*this.itemSize[1],a.first.rows*this.itemSize[0]);else if(a.first-s>e){const d=(a.first-1)*this.itemSize;r?o(d,0):o(0,d)}}else if(c){if(i)a.last.rows-s.rows<=e[0]+1?o(a.first.cols*this.itemSize[1],(a.first.rows+1)*this.itemSize[0]):a.last.cols-s.cols<=e[1]+1&&o((a.first.cols+1)*this.itemSize[1],a.first.rows*this.itemSize[0]);else if(a.last-s<=e+1){const d=(a.first+1)*this.itemSize;r?o(d,0):o(0,d)}}}else this.scrollToIndex(e,n)},getRenderedRange(){const e=(i,r)=>Math.floor(i/(r||i));let t=this.first,n=0;if(this.element){const i=this.isBoth(),r=this.isHorizontal(),{scrollTop:s,scrollLeft:a}=this.element.scrollTop;i?(t={rows:e(s,this.itemSize[0]),cols:e(a,this.itemSize[1])},n={rows:t.rows+this.numItemsInViewport.rows,cols:t.cols+this.numItemsInViewport.cols}):(t=e(r?a:s,this.itemSize),n=t+this.numItemsInViewport)}return{first:this.first,last:this.last,viewport:{first:t,last:n}}},calculateNumItems(){const e=this.isBoth(),t=this.isHorizontal(),n=this.itemSize,i=this.getContentPosition(),r=this.element?this.element.offsetWidth-i.left:0,s=this.element?this.element.offsetHeight-i.top:0,a=(d,u)=>Math.ceil(d/(u||d)),o=d=>Math.ceil(d/2),l=e?{rows:a(s,n[0]),cols:a(r,n[1])}:a(t?r:s,n),c=this.d_numToleratedItems||(e?[o(l.rows),o(l.cols)]:o(l));return{numItemsInViewport:l,numToleratedItems:c}},calculateOptions(){const e=this.isBoth(),t=this.first,{numItemsInViewport:n,numToleratedItems:i}=this.calculateNumItems(),r=(a,o,l,c=!1)=>this.getLast(a+o+(a<l?2:3)*l,c),s=e?{rows:r(t.rows,n.rows,i[0]),cols:r(t.cols,n.cols,i[1],!0)}:r(t,n,i);this.last=s,this.numItemsInViewport=n,this.d_numToleratedItems=i,this.$emit("update:numToleratedItems",this.d_numToleratedItems),this.showLoader&&(this.loaderArr=e?Array.from({length:n.rows}).map(()=>Array.from({length:n.cols})):Array.from({length:n})),this.lazy&&Promise.resolve().then(()=>{this.lazyLoadState={first:this.step?e?{rows:0,cols:t.cols}:0:t,last:Math.min(this.step?this.step:s,this.items.length)},this.$emit("lazy-load",this.lazyLoadState)})},calculateAutoSize(){this.autoSize&&!this.d_loading&&Promise.resolve().then(()=>{if(this.content){const e=this.isBoth(),t=this.isHorizontal(),n=this.isVertical();this.content.style.minHeight=this.content.style.minWidth="auto",this.content.style.position="relative",this.element.style.contain="none";const[i,r]=[F.getWidth(this.content),F.getHeight(this.content)];i!==this.defaultContentWidth&&(this.element.style.width=""),r!==this.defaultContentHeight&&(this.element.style.height="");const[s,a]=[F.getWidth(this.element),F.getHeight(this.element)];(e||t)&&(this.element.style.width=s<this.defaultWidth?s+"px":this.scrollWidth||this.defaultWidth+"px"),(e||n)&&(this.element.style.height=a<this.defaultHeight?a+"px":this.scrollHeight||this.defaultHeight+"px"),this.content.style.minHeight=this.content.style.minWidth="",this.content.style.position="",this.element.style.contain=""}})},getLast(e=0,t){return this.items?Math.min(t?(this.columns||this.items[0]).length:this.items.length,e):0},getContentPosition(){if(this.content){const e=getComputedStyle(this.content),t=parseFloat(e.paddingLeft)+Math.max(parseFloat(e.left)||0,0),n=parseFloat(e.paddingRight)+Math.max(parseFloat(e.right)||0,0),i=parseFloat(e.paddingTop)+Math.max(parseFloat(e.top)||0,0),r=parseFloat(e.paddingBottom)+Math.max(parseFloat(e.bottom)||0,0);return{left:t,right:n,top:i,bottom:r,x:t+n,y:i+r}}return{left:0,right:0,top:0,bottom:0,x:0,y:0}},setSize(){if(this.element){const e=this.isBoth(),t=this.isHorizontal(),n=this.element.parentElement,i=this.scrollWidth||`${this.element.offsetWidth||n.offsetWidth}px`,r=this.scrollHeight||`${this.element.offsetHeight||n.offsetHeight}px`,s=(a,o)=>this.element.style[a]=o;e||t?(s("height",r),s("width",i)):s("height",r)}},setSpacerSize(){const e=this.items;if(e){const t=this.isBoth(),n=this.isHorizontal(),i=this.getContentPosition(),r=(s,a,o,l=0)=>this.spacerStyle={...this.spacerStyle,[`${s}`]:(a||[]).length*o+l+"px"};t?(r("height",e,this.itemSize[0],i.y),r("width",this.columns||e[1],this.itemSize[1],i.x)):n?r("width",this.columns||e,this.itemSize,i.x):r("height",e,this.itemSize,i.y)}},setContentPosition(e){if(this.content&&!this.appendOnly){const t=this.isBoth(),n=this.isHorizontal(),i=e?e.first:this.first,r=(a,o)=>a*o,s=(a=0,o=0)=>this.contentStyle={...this.contentStyle,transform:`translate3d(${a}px, ${o}
431px, 0)`};if(t)s(r(i.cols,this.itemSize[1]),r(i.rows,this.itemSize[0]));else{const a=r(i,this.itemSize);n?s(a,0):s(0,a)}}},onScrollPositionChange(e){const t=e.target,n=this.isBoth(),i=this.isHorizontal(),r=this.getContentPosition(),s=(_,b)=>_?_>b?_-b:_:0,a=(_,b)=>Math.floor(_/(b||_)),o=(_,b,w,C,O,T)=>_<=O?O:T?w-C-O:b+O-1,l=(_,b,w,C,O,T,E)=>_<=T?0:Math.max(0,E?_<b?w:_-T:_>b?w:_-2*T),c=(_,b,w,C,O,T)=>{let E=b+C+2*O;return _>=O&&(E+=O+1),this.getLast(E,T)},d=s(t.scrollTop,r.top),u=s(t.scrollLeft,r.left);let p=n?{rows:0,cols:0}:0,h=this.last,m=!1,v=this.lastScrollPos;if(n){const _=this.lastScrollPos.top<=d,b=this.lastScrollPos.left<=u;if(!this.appendOnly||this.appendOnly&&(_||b)){const w={rows:a(d,this.itemSize[0]),cols:a(u,this.itemSize[1])},C={rows:o(w.rows,this.first.rows,this.last.rows,this.numItemsInViewport.rows,this.d_numToleratedItems[0],_),cols:o(w.cols,this.first.cols,this.last.cols,this.numItemsInViewport.cols,this.d_numToleratedItems[1],b)};p={rows:l(w.rows,C.rows,this.first.rows,this.last.rows,this.numItemsInViewport.rows,this.d_numToleratedItems[0],_),cols:l(w.cols,C.cols,this.first.cols,this.last.cols,this.numItemsInViewport.cols,this.d_numToleratedItems[1],b)},h={rows:c(w.rows,p.rows,this.last.rows,this.numItemsInViewport.rows,this.d_numToleratedItems[0]),cols:c(w.cols,p.cols,this.last.cols,this.numItemsInViewport.cols,this.d_numToleratedItems[1],!0)},m=p.rows!==this.first.rows||h.rows!==this.last.rows||p.cols!==this.first.cols||h.cols!==this.last.cols||this.isRangeChanged,v={top:d,left:u}}}else{const _=i?u:d,b=this.lastScrollPos<=_;if(!this.appendOnly||this.appendOnly&&b){const w=a(_,this.itemSize),C=o(w,this.first,this.last,this.numItemsInViewport,this.d_numToleratedItems,b);p=l(w,C,this.first,this.last,this.numItemsInViewport,this.d_numToleratedItems,b),h=c(w,p,this.last,this.numItemsInViewport,this.d_numToleratedItems),m=p!==this.first||h!==this.last||this.isRangeChanged,v=_}}return{first:p,last:h,isRangeChanged:m,scrollPos:v}},onScrollChange(e){const{first:t,last:n,isRangeChanged:i,scrollPos:r}=this.onScrollPositionChange(e);if(i){const s={first:t,last:n};if(this.setContentPosition(s),this.first=t,this.last=n,this.lastScrollPos=r,this.$emit("scroll-index-change",s),this.lazy&&this.isPageChanged(t)){const a={first:this.step?Math.min(this.getPageByFirst(t)*this.step,this.items.length-this.step):t,last:Math.min(this.step?(this.getPageByFirst(t)+1)*this.step:n,this.items.length)};(this.lazyLoadState.first!==a.first||this.lazyLoadState.last!==a.last)&&this.$emit("lazy-load",a),this.lazyLoadState=a}}},onScroll(e){if(this.$emit("scroll",e),this.delay&&this.isPageChanged()){if(this.scrollTimeout&&clearTimeout(this.scrollTimeout),!this.d_loading&&this.showLoader){const{isRangeChanged:t}=this.onScrollPositionChange(e);(t||(this.step?this.isPageChanged():!1))&&(this.d_loading=!0)}this.scrollTimeout=setTimeout(()=>{this.onScrollChange(e),this.d_loading&&this.showLoader&&(!this.lazy||this.loading===void 0)&&(this.d_loading=!1,this.page=this.getPageByFirst())},this.delay)}else this.onScrollChange(e)},onResize(){this.resizeTimeout&&clearTimeout(this.resizeTimeout),this.resizeTimeout=setTimeout(()=>{if(F.isVisible(this.element)){const e=this.isBoth(),t=this.isVertical(),n=this.isHorizontal(),[i,r]=[F.getWidth(this.element),F.getHeight(this.element)],[s,a]=[i!==this.defaultWidth,r!==this.defaultHeight];(e?s||a:n?s:t?a:!1)&&(this.d_numToleratedItems=this.numToleratedItems,this.defaultWidth=i,this.defaultHeight=r,this.defaultContentWidth=F.getWidth(this.content),this.defaultContentHeight=F.getHeight(this.content),this.init())}},this.resizeDelay)},bindResizeListener(){this.resizeListener||(this.resizeListener=this.onResize.bind(this),window.addEventListener("resize",this.resizeListener),window.addEventListener("orientationchange",this.resizeListener))},unbindResizeListener(){this.resizeListener&&(window.removeEventListener("resize",this.resizeListener),window.removeEventListener("orientationchange",this.resizeListener),this.resizeListener=null)},getOptions(e){const t=(this.items||[]).length,n=this.isBoth()?this.first.rows+e:this.first+e;return{index:n,count:t,first:n===0,last:n===t-1,even:n%2===0,odd:n%2!==0}},getLoaderOptions(e,t){let n=this.loaderArr.length;return{index:e,count:n,first:e===0,last:e===n-1,even:e%2===0,odd:e%2!==0,...t}},getPageByFirst(e){return Math.floor(((e??this.first)+this.d_numToleratedItems*4)/(this.step||1))},isPageChanged(e){return this.step?this.page!==this.getPageByFirst(e??this.first):!0}
431,setContentEl(e){this.content=e||this.content||F.findSingle(this.element,".p-virtualscroller-content")},elementRef(e){this.element=e},contentRef(e){this.content=e}},computed:{containerClass(){return["p-virtualscroller",{"p-virtualscroller-inline":this.inline,"p-virtualscroller-both p-both-scroll":this.isBoth(),"p-virtualscroller-horizontal p-horizontal-scroll":this.isHorizontal()},this.class]},contentClass(){return["p-virtualscroller-content",{"p-virtualscroller-loading":this.d_loading}]},loaderClass(){return["p-virtualscroller-loader",{"p-component-overlay":!this.$slots.loader}]},loadedItems(){return this.items&&!this.d_loading?this.isBoth()?this.items.slice(this.appendOnly?0:this.first.rows,this.last.rows).map(e=>this.columns?e:e.slice(this.appendOnly?0:this.first.cols,this.last.cols)):this.isHorizontal()&&this.columns?this.items:this.items.slice(this.appendOnly?0:this.first,this.last):[]},loadedRows(){return this.d_loading?this.loaderDisabled?this.loaderArr:[]:this.loadedItems},loadedColumns(){if(this.columns){const e=this.isBoth(),t=this.isHorizontal();if(e||t)return this.d_loading&&this.loaderDisabled?e?this.loaderArr[0]:this.loaderArr:this.columns.slice(e?this.first.cols:this.first,e?this.last.cols:this.last)}return this.columns}},components:{SpinnerIcon:ps}};const _k=["tabindex"];function wk(e,t,n,i,r,s){const a=le("SpinnerIcon");return n.disabled?(g(),S(J,{key:1},[he(e.$slots,"default"),he(e.$slots,"content",{items:n.items,rows:n.items,columns:s.loadedColumns})],64)):(g(),S("div",R({key:0,ref:s.elementRef,class:s.containerClass,tabindex:n.tabindex,style:n.style,onScroll:t[0]||(t[0]=(...o)=>s.onScroll&&s.onScroll(...o))},e.ptm("root")),[he(e.$slots,"content",{styleClass:s.contentClass,items:s.loadedItems,getItemOptions:s.getOptions,loading:r.d_loading,getLoaderOptions:s.getLoaderOptions,itemSize:n.itemSize,rows:s.loadedRows,columns:s.loadedColumns,contentRef:s.contentRef,spacerStyle:r.spacerStyle,contentStyle:r.contentStyle,vertical:s.isVertical(),horizontal:s.isHorizontal(),both:s.isBoth()},()=>[f("div",R({ref:s.contentRef,class:s.contentClass,style:r.contentStyle},e.ptm("content")),[(g(!0),S(J,null,ye(s.loadedItems,(o,l)=>he(e.$slots,"item",{key:l,item:o,options:s.getOptions(l)})),128))],16)]),n.showSpacer?(g(),S("div",R({key:0,class:"p-virtualscroller-spacer",style:r.spacerStyle},e.ptm("spacer")),null,16)):M("",!0),!n.loaderDisabled&&n.showLoader&&r.d_loading?(g(),S("div",R({key:1,class:s.loaderClass},e.ptm("loader")),[e.$slots&&e.$slots.loader?(g(!0),S(J,{key:0},ye(r.loaderArr,(o,l)=>he(e.$slots,"loader",{key:l,options:s.getLoaderOptions(l,s.isBoth()&&{numCols:e.d_numItemsInViewport.cols})})),128)):M("",!0),he(e.$slots,"loadingicon",{},()=>[de(a,R({spin:"",class:"p-virtualscroller-loading-icon"},e.ptm("loadingIcon")),null,16)])],16)):M("",!0)],16,_k))}function Ek(e,t){t===void 0&&(t={});var n=t.insertAt;if(!(typeof document>"u")){var i=document.head||document.getElementsByTagName("head")[0],r=document.createElement("style");r.type="text/css",n==="top"&&i.firstChild?i.insertBefore(r,i.firstChild):i.appendChild(r),r.styleSheet?r.styleSheet.cssText=e:r.appendChild(document.createTextNode(e))}}var Sk=`
432.p-virtualscroller {
433    position: relative;
434    overflow: auto;
435    contain: strict;
436    transform: translateZ(0);
437    will-change: scroll-position;
438    outline: 0 none;
439}
440.p-virtualscroller-content {
441    position: absolute;
442    top: 0;
443    left: 0;
444    /* contain: content; */
445    min-height: 100%;
446    min-width: 100%;
447    will-change: transform;
448}
449.p-virtualscroller-spacer {
450    position: absolute;
451    top: 0;
452    left: 0;
453    height: 1px;
454    width: 1px;
455    transform-origin: 0 0;
456    pointer-events: none;
457}
458.p-virtualscroller .p-virtualscroller-loader {
459    position: sticky;
460    top: 0;
461    left: 0;
462    width: 100%;
463    height: 100%;
464}
465.p-virtualscroller-loader.p-component-overlay {
466    display: flex;
467    align-items: center;
468    justify-content: center;
469}
470.p-virtualscroller-loading-icon {
471    font-size: 2rem;
472}
473.p-virtualscroller-loading-icon.p-icon {
474    width: 2rem;
475    height: 2rem;
476}
477.p-virtualscroller-horizontal > .p-virtualscroller-content {
478    display: flex;
479}
480
481/* Inline */
482.p-virtualscroller-inline .p-virtualscroller-content {
483    position: static;
484}
485`;Ek(Sk);Li.render=wk;var Ni={name:"Dropdown",extends:Ve,emits:["update:modelValue","change","focus","blur","before-show","before-hide","show","hide","filter"],props:{modelValue:null,options:Array,optionLabel:null,optionValue:null,optionDisabled:null,optionGroupLabel:null,optionGroupChildren:null,scrollHeight:{type:String,default:"200px"},filter:Boolean,filterPlaceholder:String,filterLocale:String,filterMatchMode:{type:String,default:"contains"},filterFields:{type:Array,default:null},editable:Boolean,placeholder:{type:String,default:null},disabled:{type:Boolean,default:!1}
485,dataKey:null,showClear:{type:Boolean,default:!1},inputId:{type:String,default:null},inputClass:{type:[String,Object],default:null},inputStyle:{type:Object,default:null},inputProps:{type:null,default:null},panelClass:{type:[String,Object],default:null},panelStyle:{type:Object,default:null},panelProps:{type:null,default:null},filterInputProps:{type:null,default:null},clearIconProps:{type:null,default:null},appendTo:{type:String,default:"body"},loading:{type:Boolean,default:!1},clearIcon:{type:String,default:void 0},dropdownIcon:{type:String,default:void 0},filterIcon:{type:String,default:void 0},loadingIcon:{type:String,default:void 0},resetFilterOnHide:{type:Boolean,default:!1},virtualScrollerOptions:{type:Object,default:null},autoOptionFocus:{type:Boolean,default:!0},autoFilterFocus:{type:Boolean,default:!1},selectOnFocus:{type:Boolean,default:!1},filterMessage:{type:String,default:null},selectionMessage:{type:String,default:null},emptySelectionMessage:{type:String,default:null},emptyFilterMessage:{type:String,default:null},emptyMessage:{type:String,default:null},tabindex:{type:Number,default:0},"aria-label":{type:String,default:null},"aria-labelledby":{type:String,default:null}},outsideClickListener:null,scrollHandler:null,resizeListener:null,overlay:null,list:null,virtualScroller:null,searchTimeout:null,searchValue:null,isModelValueChanged:!1,focusOnHover:!1,data(){return{id:this.$attrs.id,focused:!1,focusedOptionIndex:-1,filterValue:null,overlayVisible:!1}},watch:{"$attrs.id":function(e){this.id=e||pt()},modelValue(){this.isModelValueChanged=!0},options(){this.autoUpdateModel()}},mounted(){this.id=this.id||pt(),this.autoUpdateModel()},updated(){this.overlayVisible&&this.isModelValueChanged&&this.scrollInView(this.findSelectedOptionIndex()),this.isModelValueChanged=!1},beforeUnmount(){this.unbindOutsideClickListener(),this.unbindResizeListener(),this.scrollHandler&&(this.scrollHandler.destroy(),this.scrollHandler=null),this.overlay&&(He.clear(this.overlay),this.overlay=null)},methods:{getOptionIndex(e,t){return this.virtualScrollerDisabled?e:t&&t(e).index},getOptionLabel(e){return this.optionLabel?ve.resolveFieldData(e,this.optionLabel):e},getOptionValue(e){return this.optionValue?ve.resolveFieldData(e,this.optionValue):e},getOptionRenderKey(e,t){return(this.dataKey?ve.resolveFieldData(e,this.dataKey):this.getOptionLabel(e))+"_"+t},getPTOptions(e,t,n,i){return this.ptm(i,{context:{selected:this.isSelected(e),focused:this.focusedOptionIndex===this.getOptionIndex(n,t),disabled:this.isOptionDisabled(e)}})},isOptionDisabled(e){return this.optionDisabled?ve.resolveFieldData(e,this.optionDisabled):!1},isOptionGroup(e){return this.optionGroupLabel&&e.optionGroup&&e.group},getOptionGroupLabel(e){return ve.resolveFieldData(e,this.optionGroupLabel)},getOptionGroupChildren(e){return ve.resolveFieldData(e,this.optionGroupChildren)},getAriaPosInset(e){return(this.optionGroupLabel?e-this.visibleOptions.slice(0,e).filter(t=>this.isOptionGroup(t)).length:e)+1},show(e){this.$emit("before-show"),this.overlayVisible=!0,this.focusedOptionIndex=this.focusedOptionIndex!==-1?this.focusedOptionIndex:this.autoOptionFocus?this.findFirstFocusedOptionIndex():-1,e&&F.focus(this.$refs.focusInput)},hide(e){const t=()=>{this.$emit("before-hide"),this.overlayVisible=!1,this.focusedOptionIndex=-1,this.searchValue="",this.resetFilterOnHide&&(this.filterValue=null),e&&F.focus(this.$refs.focusInput)};setTimeout(()=>{t()},0)},onFocus(e){this.disabled||(this.focused=!0,this.focusedOptionIndex=this.focusedOptionIndex!==-1?this.focusedOptionIndex:this.overlayVisible&&this.autoOptionFocus?this.findFirstFocusedOptionIndex():-1,this.overlayVisible&&this.scrollInView(this.focusedOptionIndex),this.$emit("focus",e))},onBlur(e){this.focused=!1,this.focusedOptionIndex=-1,this.searchValue="",this.$emit("blur",e)},onKeyDown(e){if(this.disabled){e.preventDefault();return}const t=e.metaKey||e.ctrlKey;switch(e.code){case"ArrowDown":this.onArrowDownKey(e);break;case"ArrowUp":this.onArrowUpKey(e,this.editable);break;case"ArrowLeft":case"ArrowRight":this.onArrowLeftKey(e,this.editable);break;case"Home":this.onHomeKey(e,this.editable);break;case"End":this.onEndKey(e,this.editable);break;case"PageDown":this.onPageDownKey(e);break;case"PageUp":this.onPageUpKey(e);break;case"Space":this.onSpaceKey(e,this.editable);break;case"Enter":case"NumpadEnter":this.onEnterKey(e);break;case"Escape":this.onEscapeKey(e);break;case"Tab":this.onTabKey(e);break;case"Backspace":this.onBackspaceKey(e,this.editable);break;case"ShiftLeft":case"ShiftRight":break;
485default:!t&&ve.isPrintableCharacter(e.key)&&(!this.overlayVisible&&this.show(),!this.editable&&this.searchOptions(e,e.key));break}},onEditableInput(e){const t=e.target.value;this.searchValue="",!this.searchOptions(e,t)&&(this.focusedOptionIndex=-1),this.updateModel(e,t)},onContainerClick(e){this.disabled||this.loading||F.hasClass(e.target,"p-dropdown-clear-icon")||e.target.tagName==="INPUT"||(!this.overlay||!this.overlay.contains(e.target))&&(this.overlayVisible?this.hide(!0):this.show(!0))},onClearClick(e){this.updateModel(e,null)},onFirstHiddenFocus(e){const t=e.relatedTarget===this.$refs.focusInput?F.getFirstFocusableElement(this.overlay,":not(.p-hidden-focusable)"):this.$refs.focusInput;F.focus(t)},onLastHiddenFocus(e){const t=e.relatedTarget===this.$refs.focusInput?F.getLastFocusableElement(this.overlay,":not(.p-hidden-focusable)"):this.$refs.focusInput;F.focus(t)},onOptionSelect(e,t,n=!0){const i=this.getOptionValue(t);this.updateModel(e,i),n&&this.hide(!0)},onOptionMouseMove(e,t){this.focusOnHover&&this.changeFocusedOptionIndex(e,t)},onFilterChange(e){const t=e.target.value;this.filterValue=t,this.focusedOptionIndex=-1,this.$emit("filter",{originalEvent:e,value:t}),!this.virtualScrollerDisabled&&this.virtualScroller.scrollToIndex(0)},onFilterKeyDown(e){switch(e.code){case"ArrowDown":this.onArrowDownKey(e);break;case"ArrowUp":this.onArrowUpKey(e,!0);break;case"ArrowLeft":case"ArrowRight":this.onArrowLeftKey(e,!0);break;case"Home":this.onHomeKey(e,!0);break;case"End":this.onEndKey(e,!0);break;case"Enter":this.onEnterKey(e);break;case"Escape":this.onEscapeKey(e);break;case"Tab":this.onTabKey(e,!0);break}},onFilterBlur(){this.focusedOptionIndex=-1},onFilterUpdated(){this.overlayVisible&&this.alignOverlay()},onOverlayClick(e){Mt.emit("overlay-click",{originalEvent:e,target:this.$el})},onOverlayKeyDown(e){switch(e.code){case"Escape":this.onEscapeKey(e);break}},onArrowDownKey(e){const t=this.focusedOptionIndex!==-1?this.findNextOptionIndex(this.focusedOptionIndex):this.findFirstFocusedOptionIndex();this.changeFocusedOptionIndex(e,t),!this.overlayVisible&&this.show(),e.preventDefault()},onArrowUpKey(e,t=!1){if(e.altKey&&!t)this.focusedOptionIndex!==-1&&this.onOptionSelect(e,this.visibleOptions[this.focusedOptionIndex]),this.overlayVisible&&this.hide(),e.preventDefault();else{const n=this.focusedOptionIndex!==-1?this.findPrevOptionIndex(this.focusedOptionIndex):this.findLastFocusedOptionIndex();this.changeFocusedOptionIndex(e,n),!this.overlayVisible&&this.show(),e.preventDefault()}},onArrowLeftKey(e,t=!1){t&&(this.focusedOptionIndex=-1)},onHomeKey(e,t=!1){t?(e.currentTarget.setSelectionRange(0,0),this.focusedOptionIndex=-1):(this.changeFocusedOptionIndex(e,this.findFirstOptionIndex()),!this.overlayVisible&&this.show()),e.preventDefault()},onEndKey(e,t=!1){if(t){const n=e.currentTarget,i=n.value.length;n.setSelectionRange(i,i),this.focusedOptionIndex=-1}else this.changeFocusedOptionIndex(e,this.findLastOptionIndex()),!this.overlayVisible&&this.show();e.preventDefault()},onPageUpKey(e){this.scrollInView(0),e.preventDefault()},onPageDownKey(e){this.scrollInView(this.visibleOptions.length-1),e.preventDefault()},onEnterKey(e){this.overlayVisible?(this.focusedOptionIndex!==-1&&this.onOptionSelect(e,this.visibleOptions[this.focusedOptionIndex]),this.hide()):this.onArrowDownKey(e),e.preventDefault()},onSpaceKey(e,t=!1){!t&&this.onEnterKey(e)},onEscapeKey(e){this.overlayVisible&&this.hide(!0),e.preventDefault()},onTabKey(e,t=!1){t||(this.overlayVisible&&this.hasFocusableElements()?(F.focus(this.$refs.firstHiddenFocusableElementOnOverlay),e.preventDefault()):(this.focusedOptionIndex!==-1&&this.onOptionSelect(e,this.visibleOptions[this.focusedOptionIndex]),this.overlayVisible&&this.hide(this.filter)))},onBackspaceKey(e,t=!1){t&&!this.overlayVisible&&this.show()},onOverlayEnter(e){He.set("overlay",e,this.$primevue.config.zIndex.overlay),this.alignOverlay(),this.scrollInView(),this.autoFilterFocus&&F.focus(this.$refs.filterInput)},onOverlayAfterEnter(){this.bindOutsideClickListener(),this.bindScrollListener(),this.bindResizeListener(),this.$emit("show")},onOverlayLeave(){this.unbindOutsideClickListener(),this.unbindScrollListener(),this.unbindResizeListener(),this.$emit("hide"),this.overlay=null},onOverlayAfterLeave(e){He.clear(e)},alignOverlay(){this.appendTo==="self"?F.relativePosition(this.overlay,this.$el):(this.overlay.style.minWidth=F.getOuterWidth(this.$el)+"px",F.absolutePosition(this.overlay,this.$el))},bindOutsideClickListener(){this.outsideClickListener||(this.outsideClickListener=e=>{this.overlayVisible&&this.overlay&&!this.$el.contains(e.target)&&!this.overlay.contains(e.target)&&this.hide()},document.addEventListener("click",this.outsideClickListener))},unbindOutsideClickListener(){this.outsideClickListener&&(document.removeEventListener("click",this.outsideClickListener),this.outsideClickListener=null)},bindScrollListener(){this.scrollHandler||(this.scrollHandler=new kn(this.$refs.container,()=>{this.overlayVisible&&this.hide()})),this.scrollHandler.bindScrollListener()},unbindScrollListener(){this.scrollHandler&&this.scrollHandler.unbindScrollListener()},bindResizeListener(){this.resizeListener||(this.resizeListener=()=>{this.overlayVisible&&!F.isTouchDevice()&&this.hide()},window.addEventListener("resize",this.resizeListener))},unbindResizeListener(){this.resizeListener&&(window.removeEventListener("resize",this.resizeListener),this.resizeListener=null)},hasFocusableElements(){return F.getFocusableElements(this.overlay,":not(.p-hidden-focusable)").length>0},isOptionMatched(e){return this.isValidOption(e)&&this.getOptionLabel(e).toLocaleLowerCase(this.filterLocale).startsWith(this.searchValue.toLocaleLowerCase(this.filterLocale))},isValidOption(e){return e&&!(this.isOptionDisabled(e)||this.isOptionGroup(e))},isValidSelectedOption(e){return this.isValidOption(e)&&this.isSelected(e)},isSelected(e){return this.isValidOption(e)&&ve.equals(this.modelValue,this.getOptionValue(e),this.equalityKey)},findFirstOptionIndex(){return this.visibleOptions.findIndex(e=>this.isValidOption(e))},findLastOptionIndex(){return ve.findLastIndex(this.visibleOptions,e=>this.isValidOption(e))},findNextOptionIndex(e){const t=e<this.visibleOptions.length-1?this.visibleOptions.slice(e+1).findIndex(n=>this.isValidOption(n)):-1;return t>-1?t+e+1:e},findPrevOptionIndex(e){const t=e>0?ve.findLastIndex(this.visibleOptions.slice(0,e),n=>this.isValidOption(n)):-1;return t>-1?t:e},findSelectedOptionIndex(){return this.hasSelectedOption?this.visibleOptions.findIndex(e=>this.isValidSelectedOption(e)):-1},findFirstFocusedOptionIndex(){const e=this.findSelectedOptionIndex();return e<0?this.findFirstOptionIndex():e},findLastFocusedOptionIndex(){const e=this.findSelectedOptionIndex();return e<0?this.findLastOptionIndex():e},searchOptions(e,t){this.searchValue=(this.searchValue||"")+t;let n=-1,i=!1;return this.focusedOptionIndex!==-1?(n=this.visibleOptions.slice(this.focusedOptionIndex).findIndex(r=>this.isOptionMatched(r)),n=n===-1?this.visibleOptions.slice(0,this.focusedOptionIndex).findIndex(r=>this.isOptionMatched(r)):n+this.focusedOptionIndex):n=this.visibleOptions.findIndex(r=>this.isOptionMatched(r)),n!==-1&&(i=!0),n===-1&&this.focusedOptionIndex===-1&&(n=this.findFirstFocusedOptionIndex()),n!==-1&&this.changeFocusedOptionIndex(e,n),this.searchTimeout&&clearTimeout(this.searchTimeout),this.searchTimeout=setTimeout(()=>{this.searchValue="",this.searchTimeout=null},500),i},changeFocusedOptionIndex(e,t){this.focusedOptionIndex!==t&&(this.focusedOptionIndex=t,this.scrollInView(),this.selectOnFocus&&this.onOptionSelect(e,this.visibleOptions[t],!1))},scrollInView(e=-1){const t=e!==-1?`${this.id}_${e}`:this.focusedOptionId,n=F.findSingle(this.list,`li[id="${t}"]`);n?n.scrollIntoView&&n.scrollIntoView({block:"nearest",inline:"start"}):this.virtualScrollerDisabled||setTimeout(()=>{this.virtualScroller&&this.virtualScroller.scrollToIndex(e!==-1?e:this.focusedOptionIndex)},0)},autoUpdateModel(){this.selectOnFocus&&this.autoOptionFocus&&!this.hasSelectedOption&&(this.focusedOptionIndex=this.findFirstFocusedOptionIndex(),this.onOptionSelect(null,this.visibleOptions[this.focusedOptionIndex],!1))},updateModel(e,t){this.$emit("update:modelValue",t),this.$emit("change",{originalEvent:e,value:t})},flatOptions(e){return(e||[]).reduce((t,n,i)=>{t.push({optionGroup:n,group:!0,index:i});const r=this.getOptionGroupChildren(n);return r&&r.forEach(s=>t.push(s)),t},[])},overlayRef(e){this.overlay=e},listRef(e,t){this.list=e,t&&t(e)},virtualScrollerRef(e){this.virtualScroller=e}},computed:{containerClass(){return["p-dropdown p-component p-inputwrapper",{"p-disabled":this.disabled,"p-dropdown-clearable":this.showClear&&!this.disabled,"p-focus":this.focused,"p-inputwrapper-filled":this.hasSelectedOption,"p-inputwrapper-focus":this.focused||this.overlayVisible,"p-overlay-open":this.overlayVisible}]}
485,inputStyleClass(){return["p-dropdown-label p-inputtext",this.inputClass,{"p-placeholder":!this.editable&&this.label===this.placeholder,"p-dropdown-label-empty":!this.editable&&!this.$slots.value&&(this.label==="p-emptylabel"||this.label.length===0)}]},panelStyleClass(){return["p-dropdown-panel p-component",this.panelClass,{"p-input-filled":this.$primevue.config.inputStyle==="filled","p-ripple-disabled":this.$primevue.config.ripple===!1}]},visibleOptions(){const e=this.optionGroupLabel?this.flatOptions(this.options):this.options||[];if(this.filterValue){const t=wr.filter(e,this.searchFields,this.filterValue,this.filterMatchMode,this.filterLocale);if(this.optionGroupLabel){const n=this.options||[],i=[];return n.forEach(r=>{const a=this.getOptionGroupChildren(r).filter(o=>t.includes(o));a.length>0&&i.push({...r,[typeof this.optionGroupChildren=="string"?this.optionGroupChildren:"items"]:[...a]})}),this.flatOptions(i)}return t}return e},hasSelectedOption(){return ve.isNotEmpty(this.modelValue)},label(){const e=this.findSelectedOptionIndex();return e!==-1?this.getOptionLabel(this.visibleOptions[e]):this.placeholder||"p-emptylabel"},editableInputValue(){const e=this.findSelectedOptionIndex();return e!==-1?this.getOptionLabel(this.visibleOptions[e]):this.modelValue||""},equalityKey(){return this.optionValue?null:this.dataKey},searchFields(){return this.filterFields||[this.optionLabel]},filterResultMessageText(){return ve.isNotEmpty(this.visibleOptions)?this.filterMessageText.replaceAll("{0}",this.visibleOptions.length):this.emptyFilterMessageText},filterMessageText(){return this.filterMessage||this.$primevue.config.locale.searchMessage||""},emptyFilterMessageText(){return this.emptyFilterMessage||this.$primevue.config.locale.emptySearchMessage||this.$primevue.config.locale.emptyFilterMessage||""},emptyMessageText(){return this.emptyMessage||this.$primevue.config.locale.emptyMessage||""},selectionMessageText(){return this.selectionMessage||this.$primevue.config.locale.selectionMessage||""},emptySelectionMessageText(){return this.emptySelectionMessage||this.$primevue.config.locale.emptySelectionMessage||""},selectedMessageText(){return this.hasSelectedOption?this.selectionMessageText.replaceAll("{0}","1"):this.emptySelectionMessageText},focusedOptionId(){return this.focusedOptionIndex!==-1?`${this.id}_${this.focusedOptionIndex}`:null},ariaSetSize(){return this.visibleOptions.filter(e=>!this.isOptionGroup(e)).length},virtualScrollerDisabled(){return!this.virtualScrollerOptions}},directives:{ripple:gt},components:{VirtualScroller:Li,Portal:Kt,TimesIcon:Qt,ChevronDownIcon:_n,SpinnerIcon:ps,FilterIcon:kl}};const Ck=["id"],Ik=["id","value","placeholder","tabindex","disabled","aria-label","aria-labelledby","aria-expanded","aria-controls","aria-activedescendant"],Tk=["id","tabindex","aria-label","aria-labelledby","aria-expanded","aria-controls","aria-activedescendant","aria-disabled"],Pk=["value","placeholder","aria-owns","aria-activedescendant"],Ok=["id"],Ak=["id"],kk=["id","aria-label","aria-selected","aria-disabled","aria-setsize","aria-posinset","onClick","onMousemove"];function Rk(e,t,n,i,r,s){const a=le("SpinnerIcon"),o=le("VirtualScroller"),l=le("Portal"),c=Xe("ripple");return g(),S("div",R({ref:"container",id:r.id,class:s.containerClass,onClick:t[15]||(t[15]=(...d)=>s.onContainerClick&&s.onContainerClick(...d))},e.ptm("root")),[n.editable?(g(),S("input",R({key:0,ref:"focusInput",id:n.inputId,type:"text",style:n.inputStyle,class:s.inputStyleClass,value:s.editableInputValue,placeholder:n.placeholder,tabindex:n.disabled?-1:n.tabindex,disabled:n.disabled,autocomplete:"off",role:"combobox","aria-label":e.ariaLabel,"aria-labelledby":e.ariaLabelledby,"aria-haspopup":"listbox","aria-expanded":r.overlayVisible,"aria-controls":r.id+"_list","aria-activedescendant":r.focused?s.focusedOptionId:void 0,onFocus:t[0]||(t[0]=(...d)=>s.onFocus&&s.onFocus(...d)),onBlur:t[1]||(t[1]=(...d)=>s.onBlur&&s.onBlur(...d)),onKeydown:t[2]||(t[2]=(...d)=>s.onKeyDown&&s.onKeyDown(...d)),onInput:t[3]||(t[3]=(...d)=>s.onEditableInput&&s.onEditableInput(...d))},{...n.inputProps,...e.ptm("input")}),null,16,Ik)):(g(),S("span",R({key:1,ref:"focusInput",id:n.inputId,style:n.inputStyle,class:s.inputStyleClass,tabindex:n.disabled?-1:n.tabindex,role:"combobox","aria-label":e.ariaLabel||(s.label==="p-emptylabel"?void 0:s.label),"aria-labelledby":e.ariaLabelledby,"aria-haspopup":"listbox","aria-expanded":r.overlayVisible,"aria-controls":r.id+"_list","aria-activedescendant":r.focused?s.focusedOptionId:void 0,"aria-disabled":n.disabled,onFocus:t[4]||(t[4]=(...d)=>s.onFocus&&s.onFocus(...d)),onBlur:t[5]||(t[5]=(...d)=>s.onBlur&&s.onBlur(...d)),onKeydown:t[6]||(t[6]=(...d)=>s.onKeyDown&&s.onKeyDown(...d))},{...n.inputProps,...e.ptm("input")}),[he(e.$slots,"value",{value:n.modelValue,placeholder:n.placeholder},()=>[ke(N(s.label==="p-emptylabel"?" ":s.label||"empty"),1)])],16,Tk)),n.showClear&&n.modelValue!=null?he(e.$slots,"clearicon",{key:2,onClick:s.onClearClick},()=>[(g(),Q(_e(n.clearIcon?"i":"TimesIcon"),R({class:["p-dropdown-clear-icon",n.clearIcon],onClick:s.onClearClick},{...n.clearIconProps,...e.ptm("clearIcon")}),null,16,["class","onClick"]))]):M("",!0),f("div",R({class:"p-dropdown-trigger"},e.ptm("trigger")),[n.loading?he(e.$slots,"loadingicon",{key:0,class:"p-dropdown-trigger-icon"},()=>[n.loadingIcon?(g(),S("span",R({key:0,class:["p-dropdown-trigger-icon pi-spin",n.loadingIcon],"aria-hidden":"true"},e.ptm("loadingIcon")),null,16)):(g(),Q(a,R({key:1,class:"p-dropdown-trigger-icon",spin:"","aria-hidden":"true"},e.ptm("loadingIcon")),null,16))]):he(e.$slots,"dropdownicon",{key:1,class:"p-dropdown-trigger-icon"},()=>[(g(),Q(_e(n.dropdownIcon?"span":"ChevronDownIcon"),R({class:["p-dropdown-trigger-icon",n.dropdownIcon],"aria-hidden":"true"},e.ptm("dropdownIcon")),null,16,["class"]))])],16),de(l,{appendTo:n.appendTo},{default:Ee(()=>[de($t,{name:"p-connected-overlay",onEnter:s.onOverlayEnter,onAfterEnter:s.onOverlayAfterEnter,onLeave:s.onOverlayLeave,onAfterLeave:s.onOverlayAfterLeave},{default:Ee(()=>[r.overlayVisible?(g(),S("div",R({key:0,ref:s.overlayRef,style:n.panelStyle,class:s.panelStyleClass,onClick:t[13]||(t[13]=(...d)=>s.onOverlayClick&&s.onOverlayClick(...d)),onKeydown:t[14]||(t[14]=(...d)=>s.onOverlayKeyDown&&s.onOverlayKeyDown(...d))},{...n.panelProps,...e.ptm("panel")}),[f("span",R({ref:"firstHiddenFocusableElementOnOverlay",role:"presentation","aria-hidden":"true",class:"p-hidden-accessible p-hidden-focusable",tabindex:0,onFocus:t[7]||(t[7]=(...d)=>s.onFirstHiddenFocus&&s.onFirstHiddenFocus(...d))},e.ptm("hiddenFirstFocusableEl")),null,16),he(e.$slots,"header",{value:n.modelValue,options:s.visibleOptions}),n.filter?(g(),S("div",R({key:0,class:"p-dropdown-header"},e.ptm("header")),[f("div",R({class:"p-dropdown-filter-container"},e.ptm("filterContainer")),[f("input",R({ref:"filterInput",type:"text",value:r.filterValue,onVnodeMounted:t[8]||(t[8]=(...d)=>s.onFilterUpdated&&s.onFilterUpdated(...d)),class:"p-dropdown-filter p-inputtext p-component",placeholder:n.filterPlaceholder,role:"searchbox",autocomplete:"off","aria-owns":r.id+"_list","aria-activedescendant":s.focusedOptionId,onKeydown:t[9]||(t[9]=(...d)=>s.onFilterKeyDown&&s.onFilterKeyDown(...d)),onBlur:t[10]||(t[10]=(...d)=>s.onFilterBlur&&s.onFilterBlur(...d)),onInput:t[11]||(t[11]=(...d)=>s.onFilterChange&&s.onFilterChange(...d))},{...n.filterInputProps,...e.ptm("filterInput")}),null,16,Pk),he(e.$slots,"filtericon",{},()=>[(g(),Q(_e(n.filterIcon?"span":"FilterIcon"),R({class:["p-dropdown-filter-icon",n.filterIcon]},e.ptm("filterIcon")),null,16,["class"]))])],16),f("span",R({role:"status","aria-live":"polite",class:"p-hidden-accessible"},e.ptm("hiddenFilterResult")),N(s.filterResultMessageText),17)],16)):M("",!0),f("div",R({class:"p-dropdown-items-wrapper",style:{"max-height":s.virtualScrollerDisabled?n.scrollHeight:""}},e.ptm("wrapper")),[de(o,R({ref:s.virtualScrollerRef},{...n.virtualScrollerOptions,...e.ptm("virtualScroller")},{items:s.visibleOptions,style:{height:n.scrollHeight},tabindex:-1,disabled:s.virtualScrollerDisabled}),ii({content:Ee(({styleClass:d,contentRef:u,items:p,getItemOptions:h,contentStyle:m,itemSize:v})=>[f("ul",R({ref:_=>s.listRef(_,u),id:r.id+"_list",class:["p-dropdown-items",d],style:m,role:"listbox"},e.ptm("list")),[(g(!0),S(J,null,ye(p,(_,b)=>(g(),S(J,{key:s.getOptionRenderKey(_,s.getOptionIndex(b,h))},[s.isOptionGroup(_)?(g(),S("li",R({key:0,id:r.id+"_"+s.getOptionIndex(b,h),style:{height:v?v+"px":void 0},class:"p-dropdown-item-group",role:"option"},e.ptm("itemGroup")),[he(e.$slots,"optiongroup",{option:_.optionGroup,index:s.getOptionIndex(b,h)},()=>[ke(N(s.getOptionGroupLabel(_.optionGroup)),1)])],16,Ak)):Ne((g(),S("li",R({key:1,id:r.id+"_"+s.getOptionIndex(b,h),style:{height:v?v+"px":void 0},class:["p-dropdown-item",{"p-highlight":s.isSelected(_),"p-focus":r.focusedOptionIndex===s.getOptionIndex(b,h),"p-disabled":s.isOptionDisabled(_)}],role:"option","aria-label":s.getOptionLabel(_),"aria-selected":s.isSelected(_),"aria-disabled":s.isOptionDisabled(_),"aria-setsize":s.ariaSetSize,"aria-posinset":s.getAriaPosInset(s.getOptionIndex(b,h)),onClick:w=>s.onOptionSelect(w,_),onMousemove:w=>s.onOptionMouseMove(w,s.getOptionIndex(b,h))}
485,s.getPTOptions(_,h,b,"item")),[he(e.$slots,"option",{option:_,index:s.getOptionIndex(b,h)},()=>[ke(N(s.getOptionLabel(_)),1)])],16,kk)),[[c]])],64))),128)),r.filterValue&&(!p||p&&p.length===0)?(g(),S("li",R({key:0,class:"p-dropdown-empty-message",role:"option"},e.ptm("emptyMessage")),[he(e.$slots,"emptyfilter",{},()=>[ke(N(s.emptyFilterMessageText),1)])],16)):!n.options||n.options&&n.options.length===0?(g(),S("li",R({key:1,class:"p-dropdown-empty-message",role:"option"},e.ptm("emptyMessage")),[he(e.$slots,"empty",{},()=>[ke(N(s.emptyMessageText),1)])],16)):M("",!0)],16,Ok)]),_:2},[e.$slots.loader?{name:"loader",fn:Ee(({options:d})=>[he(e.$slots,"loader",{options:d})]),key:"0"}:void 0]),1040,["items","style","disabled"])],16),he(e.$slots,"footer",{value:n.modelValue,options:s.visibleOptions}),!n.options||n.options&&n.options.length===0?(g(),S("span",R({key:1,role:"status","aria-live":"polite",class:"p-hidden-accessible"},e.ptm("emptyMessage")),N(s.emptyMessageText),17)):M("",!0),f("span",R({role:"status","aria-live":"polite",class:"p-hidden-accessible"},e.ptm("hiddenSelectedMessage")),N(s.selectedMessageText),17),f("span",R({ref:"lastHiddenFocusableElementOnOverlay",role:"presentation","aria-hidden":"true",class:"p-hidden-accessible p-hidden-focusable",tabindex:0,onFocus:t[12]||(t[12]=(...d)=>s.onLastHiddenFocus&&s.onLastHiddenFocus(...d))},e.ptm("hiddenLastFocusableEl")),null,16)],16)):M("",!0)]),_:3},8,["onEnter","onAfterEnter","onLeave","onAfterLeave"])]),_:3},8,["appendTo"])],16,Ck)}function Lk(e,t){t===void 0&&(t={});var n=t.insertAt;if(!(typeof document>"u")){var i=document.head||document.getElementsByTagName("head")[0],r=document.createElement("style");r.type="text/css",n==="top"&&i.firstChild?i.insertBefore(r,i.firstChild):i.appendChild(r),r.styleSheet?r.styleSheet.cssText=e:r.appendChild(document.createTextNode(e))}}var Nk=`
486.p-dropdown {
487    display: inline-flex;
488    cursor: pointer;
489    position: relative;
490    user-select: none;
491}
492.p-dropdown-clear-icon {
493    position: absolute;
494    top: 50%;
495    margin-top: -0.5rem;
496}
497.p-dropdown-trigger {
498    display: flex;
499    align-items: center;
500    justify-content: center;
501    flex-shrink: 0;
502}
503.p-dropdown-label {
504    display: block;
505    white-space: nowrap;
506    overflow: hidden;
507    flex: 1 1 auto;
508    width: 1%;
509    text-overflow: ellipsis;
510    cursor: pointer;
511}
512.p-dropdown-label-empty {
513    overflow: hidden;
514    opacity: 0;
515}
516input.p-dropdown-label {
517    cursor: default;
518}
519.p-dropdown .p-dropdown-panel {
520    min-width: 100%;
521}
522.p-dropdown-panel {
523    position: absolute;
524    top: 0;
525    left: 0;
526}
527.p-dropdown-items-wrapper {
528    overflow: auto;
529}
530.p-dropdown-item {
531    cursor: pointer;
532    font-weight: normal;
533    white-space: nowrap;
534    position: relative;
535    overflow: hidden;
536}
537.p-dropdown-item-group {
538    cursor: auto;
539}
540.p-dropdown-items {
541    margin: 0;
542    padding: 0;
543    list-style-type: none;
544}
545.p-dropdown-filter {
546    width: 100%;
547}
548.p-dropdown-filter-container {
549    position: relative;
550}
551.p-dropdown-filter-icon {
552    position: absolute;
553    top: 50%;
554    margin-top: -0.5rem;
555}
556.p-fluid .p-dropdown {
557    display: flex;
558}
559.p-fluid .p-dropdown .p-dropdown-label {
560    width: 1%;
561}
562`;Lk(Nk);Ni.render=Rk;var Of={name:"AngleDownIcon",extends:ze};const Dk=f("path",{d:"M3.58659 4.5007C3.68513 4.50023 3.78277 4.51945 3.87379 4.55723C3.9648 4.59501 4.04735 4.65058 4.11659 4.7207L7.11659 7.7207L10.1166 4.7207C10.2619 4.65055 10.4259 4.62911 10.5843 4.65956C10.7427 4.69002 10.8871 4.77074 10.996 4.88976C11.1049 5.00877 11.1726 5.15973 11.1889 5.32022C11.2052 5.48072 11.1693 5.6422 11.0866 5.7807L7.58659 9.2807C7.44597 9.42115 7.25534 9.50004 7.05659 9.50004C6.85784 9.50004 6.66722 9.42115 6.52659 9.2807L3.02659 5.7807C2.88614 5.64007 2.80725 5.44945 2.80725 5.2507C2.80725 5.05195 2.88614 4.86132 3.02659 4.7207C3.09932 4.64685 3.18675 4.58911 3.28322 4.55121C3.37969 4.51331 3.48305 4.4961 3.58659 4.5007Z",fill:"currentColor"},null,-1),xk=[Dk];function Mk(e,t,n,i,r,s){return g(),S("svg",R({width:"14",height:"14",viewBox:"0 0 14 14",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e.pti()),xk,16)}Of.render=Mk;var Af={name:"AngleUpIcon",extends:ze};const Fk=f("path",{d:"M10.4134 9.49931C10.3148 9.49977 10.2172 9.48055 10.1262 9.44278C10.0352 9.405 9.95263 9.34942 9.88338 9.27931L6.88338 6.27931L3.88338 9.27931C3.73811 9.34946 3.57409 9.3709 3.41567 9.34044C3.25724 9.30999 3.11286 9.22926 3.00395 9.11025C2.89504 8.99124 2.82741 8.84028 2.8111 8.67978C2.79478 8.51928 2.83065 8.35781 2.91338 8.21931L6.41338 4.71931C6.55401 4.57886 6.74463 4.49997 6.94338 4.49997C7.14213 4.49997 7.33276 4.57886 7.47338 4.71931L10.9734 8.21931C11.1138 8.35994 11.1927 8.55056 11.1927 8.74931C11.1927 8.94806 11.1138 9.13868 10.9734 9.27931C10.9007 9.35315 10.8132 9.41089 10.7168 9.44879C10.
5626203 9.48669 10.5169 9.5039 10.4134 9.49931Z",fill:"currentColor"},null,-1),Vk=[Fk];function Bk(e,t,n,i,r,s){return g(),S("svg",R({width:"14",height:"14",viewBox:"0 0 14 14",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e.pti()),Vk,16)}Af.render=Bk;var na={name:"InputText",extends:Ve,emits:["update:modelValue"],props:{modelValue:null},methods:{onInput(e){this.$emit("update:modelValue",e.target.value)}},computed:{filled(){return this.modelValue!=null&&this.modelValue.toString().length>0}}};const $k=["value"];function Uk(e,t,n,i,r,s){return g(),S("input",R({class:["p-inputtext p-component",{"p-filled":s.filled}],value:n.modelValue,onInput:t[0]||(t[0]=(...a)=>s.onInput&&s.onInput(...a))},e.ptm("root")),null,16,$k)}na.render=Uk;var Rl={name:"InputNumber",extends:Ve,emits:["update:modelValue","input","focus","blur"],props:{modelValue:{type:Number,default:null},format:{type:Boolean,default:!0},showButtons:{type:Boolean,default:!1},buttonLayout:{type:String,default:"stacked"},incrementButtonClass:{type:String,default:null},decrementButtonClass:{type:String,default:null},incrementButtonIcon:{type:String,default:void 0},decrementButtonIcon:{type:String,default:void 0},locale:{type:String,default:void 0},localeMatcher:{type:String,default:void 0},mode:{type:String,default:"decimal"},prefix:{type:String,default:null},suffix:{type:String,default:null},currency:{type:String,default:void 0},currencyDisplay:{type:String,default:void 0},useGrouping:{type:Boolean,default:!0},minFractionDigits:{type:Number,default:void 0},maxFractionDigits:{type:Number,default:void 0},min:{type:Number,default:null},max:{type:Number,default:null},step:{type:Number,default:1},allowEmpty:{type:Boolean,default:!0},highlightOnFocus:{type:Boolean,default:!1},readonly:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},placeholder:{type:String,default:null},inputId:{type:String,default:null},inputClass:{type:[String,Object],default:null},inputStyle:{type:Object,default:null},inputProps:{type:null,default:null},incrementButtonProps:{type:null,default:null},decrementButtonProps:{type:null,default:null},"aria-labelledby":{type:String,default:null},"aria-label":{type:String,default:null}},numberFormat:null,_numeral:null,_decimal:null,_group:null,_minusSign:null,_currency:null,_suffix:null,_prefix:null,_index:null,groupChar:"",isSpecialChar:null,prefixChar:null,suffixChar:null,timer:null,data(){return{d_modelValue:this.modelValue,focused:!1}},watch:{modelValue(e){this.d_modelValue=e},locale(e,t){this.updateConstructParser(e,t)},localeMatcher(e,t){this.updateConstructParser(e,t)},mode(e,t){this.updateConstructParser(e,t)},currency(e,t){this.updateConstructParser(e,t)},currencyDisplay(e,t){this.updateConstructParser(e,t)},useGrouping(e,t){this.updateConstructParser(e,t)},minFractionDigits(e,t){this.updateConstructParser(e,t)},maxFractionDigits(e,t){this.updateConstructParser(e,t)},suffix(e,t){this.updateConstructParser(e,t)},prefix(e,t){this.updateConstructParser(e,t)}},created(){this.constructParser()},methods:{getOptions(){return{localeMatcher:this.localeMatcher,style:this.mode,currency:this.currency,currencyDisplay:this.currencyDisplay,useGrouping:this.useGrouping,minimumFractionDigits:this.minFractionDigits,maximumFractionDigits:this.maxFractionDigits}},constructParser(){this.numberFormat=new Intl.NumberFormat(this.locale,this.getOptions());const e=[...new Intl.NumberFormat(this.locale,{useGrouping:!1}).format(9876543210)].reverse(),t=new Map(e.map((n,i)=>[n,i]));this._numeral=new RegExp(`[${e.join("")}]`,"g"),this._group=this.getGroupingExpression(),this._minusSign=this.getMinusSignExpression(),this._currency=this.getCurrencyExpression(),this._decimal=this.getDecimalExpression(),this._suffix=this.getSuffixExpression(),this._prefix=this.getPrefixExpression(),this._index=n=>t.get(n)},updateConstructParser(e,t){e!==t&&this.constructParser()},escapeRegExp(e){return e.replace(/[-[\]{}()*+?.,\\^$|#\s]/g,"\\$&")},getDecimalExpression(){const e=new Intl.NumberFormat(this.locale,{...this.getOptions(),useGrouping:!1});return new RegExp(`[${e.format(1.1).replace(this._currency,"").trim().replace(this._numeral,"")}]`,"g")},getGroupingExpression(){const e=new Intl.NumberFormat(this.locale,{useGrouping:!0});return this.groupChar=e.format(1e6).trim().replace(this._numeral,"").charAt(0),new RegExp(`[${this.groupChar}]`,"g")},getMinusSignExpression(){const e=new Intl.NumberFormat(this.locale,{useGrouping:!1});return new RegExp(`[${e.format(-1).trim().replace(this._numeral,"")}]`,"g")},getCurrencyExpression(){if(this.currency){const e=new Intl.NumberFormat(this.locale,{style:"currency",currency:this.currency,currencyDisplay:this.currencyDisplay,minimumFractionDigits:0,maximumFractionDigits:0});return new RegExp(`[${e.format(1).replace(/\s/g,"").replace(this._numeral,"").replace(this._group,"")}]`,"g")}return new RegExp("[]","g")},getPrefixExpression(){if(this.prefix)this.prefixChar=this.prefix;else{const e=new Intl.NumberFormat(this.locale,{style:this.mode,currency:this.currency,currencyDisplay:this.currencyDisplay});this.prefixChar=e.format(1).split("1")[0]}return new RegExp(`${this.escapeRegExp(this.prefixChar||"")}`,"g")}
562,getSuffixExpression(){if(this.suffix)this.suffixChar=this.suffix;else{const e=new Intl.NumberFormat(this.locale,{style:this.mode,currency:this.currency,currencyDisplay:this.currencyDisplay,minimumFractionDigits:0,maximumFractionDigits:0});this.suffixChar=e.format(1).split("1")[1]}return new RegExp(`${this.escapeRegExp(this.suffixChar||"")}`,"g")},formatValue(e){if(e!=null){if(e==="-")return e;if(this.format){let n=new Intl.NumberFormat(this.locale,this.getOptions()).format(e);return this.prefix&&(n=this.prefix+n),this.suffix&&(n=n+this.suffix),n}return e.toString()}return""},parseValue(e){let t=e.replace(this._suffix,"").replace(this._prefix,"").trim().replace(/\s/g,"").replace(this._currency,"").replace(this._group,"").replace(this._minusSign,"-").replace(this._decimal,".").replace(this._numeral,this._index);if(t){if(t==="-")return t;let n=+t;return isNaN(n)?null:n}return null},repeat(e,t,n){if(this.readonly)return;let i=t||500;this.clearTimer(),this.timer=setTimeout(()=>{this.repeat(e,40,n)},i),this.spin(e,n)},spin(e,t){if(this.$refs.input){let n=this.step*t,i=this.parseValue(this.$refs.input.$el.value)||0,r=this.validateValue(i+n);this.updateInput(r,null,"spin"),this.updateModel(e,r),this.handleOnInput(e,i,r)}},onUpButtonMouseDown(e){this.disabled||(this.$refs.input.$el.focus(),this.repeat(e,null,1),e.preventDefault())},onUpButtonMouseUp(){this.disabled||this.clearTimer()},onUpButtonMouseLeave(){this.disabled||this.clearTimer()},onUpButtonKeyUp(){this.disabled||this.clearTimer()},onUpButtonKeyDown(e){(e.keyCode===32||e.keyCode===13)&&this.repeat(e,null,1)},onDownButtonMouseDown(e){this.disabled||(this.$refs.input.$el.focus(),this.repeat(e,null,-1),e.preventDefault())},onDownButtonMouseUp(){this.disabled||this.clearTimer()},onDownButtonMouseLeave(){this.disabled||this.clearTimer()},onDownButtonKeyUp(){this.disabled||this.clearTimer()},onDownButtonKeyDown(e){(e.keyCode===32||e.keyCode===13)&&this.repeat(e,null,-1)},onUserInput(){this.isSpecialChar&&(this.$refs.input.$el.value=this.lastValue),this.isSpecialChar=!1},onInputKeyDown(e){if(this.readonly)return;if(this.lastValue=e.target.value,e.shiftKey||e.altKey){this.isSpecialChar=!0;return}let t=e.target.selectionStart,n=e.target.selectionEnd,i=e.target.value,r=null;switch(e.altKey&&e.preventDefault(),e.code){case"ArrowUp":this.spin(e,1),e.preventDefault();break;case"ArrowDown":this.spin(e,-1),e.preventDefault();break;case"ArrowLeft":this.isNumeralChar(i.charAt(t-1))||e.preventDefault();break;case"ArrowRight":this.isNumeralChar(i.charAt(t))||e.preventDefault();break;case"Tab":case"Enter":r=this.validateValue(this.parseValue(i)),this.$refs.input.$el.value=this.formatValue(r),this.$refs.input.$el.setAttribute("aria-valuenow",r),this.updateModel(e,r);break;case"Backspace":{if(e.preventDefault(),t===n){const s=i.charAt(t-1),{decimalCharIndex:a,decimalCharIndexWithoutPrefix:o}=this.getDecimalCharIndexes(i);if(this.isNumeralChar(s)){const l=this.getDecimalLength(i);if(this._group.test(s))this._group.lastIndex=0,r=i.slice(0,t-2)+i.slice(t-1);else if(this._decimal.test(s))this._decimal.lastIndex=0,l?this.$refs.input.$el.setSelectionRange(t-1,t-1):r=i.slice(0,t-1)+i.slice(t);else if(a>0&&t>a){const c=this.isDecimalMode()&&(this.minFractionDigits||0)<l?"":"0";r=i.slice(0,t-1)+c+i.slice(t)}else o===1?(r=i.slice(0,t-1)+"0"+i.slice(t),r=this.parseValue(r)>0?r:""):r=i.slice(0,t-1)+i.slice(t)}this.updateValue(e,r,null,"delete-single")}else r=this.deleteRange(i,t,n),this.updateValue(e,r,null,"delete-range");break}case"Delete":if(e.preventDefault(),t===n){const s=i.charAt(t),{decimalCharIndex:a,decimalCharIndexWithoutPrefix:o}=this.getDecimalCharIndexes(i);if(this.isNumeralChar(s)){const l=this.getDecimalLength(i);if(this._group.test(s))this._group.lastIndex=0,r=i.slice(0,t)+i.slice(t+2);else if(this._decimal.test(s))this._decimal.lastIndex=0,l?this.$refs.input.$el.setSelectionRange(t+1,t+1):r=i.slice(0,t)+i.slice(t+1);else if(a>0&&t>a){const c=this.isDecimalMode()&&(this.minFractionDigits||0)<l?"":"0";r=i.slice(0,t)+c+i.slice(t+1)}else o===1?(r=i.slice(0,t)+"0"+i.slice(t+1),r=this.parseValue(r)>0?r:""):r=i.slice(0,t)+i.slice(t+1)}
562this.updateValue(e,r,null,"delete-back-single")}else r=this.deleteRange(i,t,n),this.updateValue(e,r,null,"delete-range");break;case"Home":this.min&&(this.updateModel(e,this.min),e.preventDefault());break;case"End":this.max&&(this.updateModel(e,this.max),e.preventDefault());break}},onInputKeyPress(e){if(this.readonly)return;e.preventDefault();let t=e.which||e.keyCode,n=String.fromCharCode(t);const i=this.isDecimalSign(n),r=this.isMinusSign(n);(48<=t&&t<=57||r||i)&&this.insert(e,n,{isDecimalSign:i,isMinusSign:r})},onPaste(e){e.preventDefault();let t=(e.clipboardData||window.clipboardData).getData("Text");if(t){let n=this.parseValue(t);n!=null&&this.insert(e,n.toString())}},allowMinusSign(){return this.min===null||this.min<0},isMinusSign(e){return this._minusSign.test(e)||e==="-"?(this._minusSign.lastIndex=0,!0):!1},isDecimalSign(e){return this._decimal.test(e)?(this._decimal.lastIndex=0,!0):!1},isDecimalMode(){return this.mode==="decimal"},getDecimalCharIndexes(e){let t=e.search(this._decimal);this._decimal.lastIndex=0;const i=e.replace(this._prefix,"").trim().replace(/\s/g,"").replace(this._currency,"").search(this._decimal);return this._decimal.lastIndex=0,{decimalCharIndex:t,decimalCharIndexWithoutPrefix:i}},getCharIndexes(e){const t=e.search(this._decimal);this._decimal.lastIndex=0;const n=e.search(this._minusSign);this._minusSign.lastIndex=0;const i=e.search(this._suffix);this._suffix.lastIndex=0;const r=e.search(this._currency);return this._currency.lastIndex=0,{decimalCharIndex:t,minusCharIndex:n,suffixCharIndex:i,currencyCharIndex:r}},insert(e,t,n={isDecimalSign:!1,isMinusSign:!1}){const i=t.search(this._minusSign);if(this._minusSign.lastIndex=0,!this.allowMinusSign()&&i!==-1)return;const r=this.$refs.input.$el.selectionStart,s=this.$refs.input.$el.selectionEnd;let a=this.$refs.input.$el.value.trim();const{decimalCharIndex:o,minusCharIndex:l,suffixCharIndex:c,currencyCharIndex:d}=this.getCharIndexes(a);let u;if(n.isMinusSign)r===0&&(u=a,(l===-1||s!==0)&&(u=this.insertText(a,t,0,s)),this.updateValue(e,u,t,"insert"));else if(n.isDecimalSign)o>0&&r===o?this.updateValue(e,a,t,"insert"):o>r&&o<s?(u=this.insertText(a,t,r,s),this.updateValue(e,u,t,"insert")):o===-1&&this.maxFractionDigits&&(u=this.insertText(a,t,r,s),this.updateValue(e,u,t,"insert"));else{const p=this.numberFormat.resolvedOptions().maximumFractionDigits,h=r!==s?"range-insert":"insert";if(o>0&&r>o){if(r+t.length-(o+1)<=p){const m=d>=r?d-1:c>=r?c:a.length;u=a.slice(0,r)+t+a.slice(r+t.length,m)+a.slice(m),this.updateValue(e,u,t,h)}}else u=this.insertText(a,t,r,s),this.updateValue(e,u,t,h)}},insertText(e,t,n,i){if((t==="."?t:t.split(".")).length===2){const s=e.slice(n,i).search(this._decimal);return this._decimal.lastIndex=0,s>0?e.slice(0,n)+this.formatValue(t)+e.slice(i):e||this.formatValue(t)}else return i-n===e.length?this.formatValue(t):n===0?t+e.slice(i):i===e.length?e.slice(0,n)+t:e.slice(0,n)+t+e.slice(i)},deleteRange(e,t,n){let i;return n-t===e.length?i="":t===0?i=e.slice(n):n===e.length?i=e.slice(0,t):i=e.slice(0,t)+e.slice(n),i},initCursor(){let e=this.$refs.input.$el.selectionStart,t=this.$refs.input.$el.value,n=t.length,i=null,r=(this.prefixChar||"").length;t=t.replace(this._prefix,""),e=e-r;let s=t.charAt(e);if(this.isNumeralChar(s))return e+r;let a=e-1;for(;a>=0;)if(s=t.charAt(a),this.isNumeralChar(s)){i=a+r;break}else a--;if(i!==null)this.$refs.input.$el.setSelectionRange(i+1,i+1);else{for(a=e;a<n;)if(s=t.charAt(a),this.isNumeralChar(s)){i=a+r;break}else a++;i!==null&&this.$refs.input.$el.setSelectionRange(i,i)}return i||0},onInputClick(){const e=this.$refs.input.$el.value;!this.readonly&&e!==F.getSelection()&&this.initCursor()},isNumeralChar(e){return e.length===1&&(this._numeral.test(e)||this._decimal.test(e)||this._group.test(e)||this._minusSign.test(e))?(this.resetRegex(),!0):!1},resetRegex(){this._numeral.lastIndex=0,this._decimal.lastIndex=0,this._group.lastIndex=0,this._minusSign.lastIndex=0},updateValue(e,t,n,i){let r=this.$refs.input.$el.value,s=null;t!=null&&(s=this.parseValue(t),s=!s&&!this.allowEmpty?0:s,this.updateInput(s,n,i,t),this.handleOnInput(e,r,s))},handleOnInput(e,t,n){this.isValueChanged(t,n)&&this.$emit("input",{originalEvent:e,value:n,formattedValue:t})},isValueChanged(e,t){if(t===null&&e!==null)return!0;
562if(t!=null){let n=typeof e=="string"?this.parseValue(e):e;return t!==n}return!1},validateValue(e){return e==="-"||e==null?null:this.min!=null&&e<this.min?this.min:this.max!=null&&e>this.max?this.max:e},updateInput(e,t,n,i){t=t||"";let r=this.$refs.input.$el.value,s=this.formatValue(e),a=r.length;if(s!==i&&(s=this.concatValues(s,i)),a===0){this.$refs.input.$el.value=s,this.$refs.input.$el.setSelectionRange(0,0);const l=this.initCursor()+t.length;this.$refs.input.$el.setSelectionRange(l,l)}else{let o=this.$refs.input.$el.selectionStart,l=this.$refs.input.$el.selectionEnd;this.$refs.input.$el.value=s;let c=s.length;if(n==="range-insert"){const d=this.parseValue((r||"").slice(0,o)),p=(d!==null?d.toString():"").split("").join(`(${this.groupChar})?`),h=new RegExp(p,"g");h.test(s);const m=t.split("").join(`(${this.groupChar})?`),v=new RegExp(m,"g");v.test(s.slice(h.lastIndex)),l=h.lastIndex+v.lastIndex,this.$refs.input.$el.setSelectionRange(l,l)}else if(c===a)n==="insert"||n==="delete-back-single"?this.$refs.input.$el.setSelectionRange(l+1,l+1):n==="delete-single"?this.$refs.input.$el.setSelectionRange(l-1,l-1):(n==="delete-range"||n==="spin")&&this.$refs.input.$el.setSelectionRange(l,l);else if(n==="delete-back-single"){let d=r.charAt(l-1),u=r.charAt(l),p=a-c,h=this._group.test(u);h&&p===1?l+=1:!h&&this.isNumeralChar(d)&&(l+=-1*p+1),this._group.lastIndex=0,this.$refs.input.$el.setSelectionRange(l,l)}else if(r==="-"&&n==="insert"){this.$refs.input.$el.setSelectionRange(0,0);const u=this.initCursor()+t.length+1;this.$refs.input.$el.setSelectionRange(u,u)}else l=l+(c-a),this.$refs.input.$el.setSelectionRange(l,l)}this.$refs.input.$el.setAttribute("aria-valuenow",e)},concatValues(e,t){if(e&&t){let n=t.search(this._decimal);return this._decimal.lastIndex=0,this.suffixChar?e.replace(this.suffixChar,"").split(this._decimal)[0]+t.replace(this.suffixChar,"").slice(n)+this.suffixChar:n!==-1?e.split(this._decimal)[0]+t.slice(n):e}return e},getDecimalLength(e){if(e){const t=e.split(this._decimal);if(t.length===2)return t[1].replace(this._suffix,"").trim().replace(/\s/g,"").replace(this._currency,"").length}return 0},updateModel(e,t){this.d_modelValue=t,this.$emit("update:modelValue",t)},onInputFocus(e){this.focused=!0,!this.disabled&&!this.readonly&&this.$refs.input.$el.value!==F.getSelection()&&this.highlightOnFocus&&e.target.select(),this.$emit("focus",e)},onInputBlur(e){this.focused=!1;let t=e.target,n=this.validateValue(this.parseValue(t.value));this.$emit("blur",{originalEvent:e,value:t.value}),t.value=this.formatValue(n),t.setAttribute("aria-valuenow",n),this.updateModel(e,n)},clearTimer(){this.timer&&clearInterval(this.timer)},maxBoundry(){return this.d_modelValue>=this.max},minBoundry(){return this.d_modelValue<=this.min}},computed:{containerClass(){return["p-inputnumber p-component p-inputwrapper",{"p-inputwrapper-filled":this.filled,"p-inputwrapper-focus":this.focused,"p-inputnumber-buttons-stacked":this.showButtons&&this.buttonLayout==="stacked","p-inputnumber-buttons-horizontal":this.showButtons&&this.buttonLayout==="horizontal","p-inputnumber-buttons-vertical":this.showButtons&&this.buttonLayout==="vertical"}]},upButtonClass(){return["p-inputnumber-button p-inputnumber-button-up",this.incrementButtonClass,{"p-disabled":this.showButtons&&this.max!==null&&this.maxBoundry()}]},downButtonClass(){return["p-inputnumber-button p-inputnumber-button-down",this.decrementButtonClass,{"p-disabled":this.showButtons&&this.min!==null&&this.minBoundry()}]},filled(){return this.modelValue!=null&&this.modelValue.toString().length>0},upButtonListeners(){return{mousedown:e=>this.onUpButtonMouseDown(e),mouseup:e=>this.onUpButtonMouseUp(e),mouseleave:e=>this.onUpButtonMouseLeave(e),keydown:e=>this.onUpButtonKeyDown(e),keyup:e=>this.onUpButtonKeyUp(e)}},downButtonListeners(){return{mousedown:e=>this.onDownButtonMouseDown(e),mouseup:e=>this.onDownButtonMouseUp(e),mouseleave:e=>this.onDownButtonMouseLeave(e),keydown:e=>this.onDownButtonKeyDown(e),keyup:e=>this.onDownButtonKeyUp(e)}},formattedValue(){const e=!this.modelValue&&!this.allowEmpty?0:this.modelValue;return this.formatValue(e)},getFormatter(){return this.numberFormat}},components:{INInputText:na,INButton:Qn,AngleUpIcon:Af,AngleDownIcon:Of}};function Hk(e,t,n,i,r,s){const a=le("INInputText"),o=le("INButton");return g(),S("span",R({class:s.containerClass},e.ptm("root")),[de(a,R({ref:"input",id:n.inputId,class:["p-inputnumber-input",n.inputClass],role:"spinbutton",style:n.inputStyle,value:s.formattedValue,"aria-valuemin":n.min,"aria-valuemax":n.max,"aria-valuenow":n.modelValue,disabled:n.disabled,readonly:n.readonly,placeholder:n.placeholder,"aria-labelledby":e.ariaLabelledby,"aria-label":e.ariaLabel,onInput:s.onUserInput,onKeydown:s.onInputKeyDown,onKeypress:s.onInputKeyPress,onPaste:s.onPaste,onClick:s.onInputClick,onFocus:s.onInputFocus,onBlur:s.onInputBlur},{...n.inputProps,...e.ptm("input")}),null,16,["id","class","style","value","aria-valuemin","aria-valuemax","aria-valuenow","disabled","readonly","placeholder","aria-labelledby","aria-label","onInput","onKeydown","onKeypress","onPaste","onClick","onFocus","onBlur"]),n.showButtons&&n.buttonLayout==="stacked"?(g(),S("span",R({key:0,class:"p-in
562putnumber-button-group"},e.ptm("buttonGroup")),[de(o,R({class:s.upButtonClass},xi(s.upButtonListeners),{disabled:n.disabled,tabindex:-1,"aria-hidden":"true"},{...n.incrementButtonProps,...e.ptm("incrementButton")}),{icon:Ee(()=>[he(e.$slots,"incrementbuttonicon",{},()=>[(g(),Q(_e(n.incrementButtonIcon?"span":"AngleUpIcon"),R({class:n.incrementButtonIcon},e.ptm("incrementButton").icon),null,16,["class"]))])]),_:3},16,["class","disabled"]),de(o,R({class:s.downButtonClass},xi(s.downButtonListeners),{disabled:n.disabled,tabindex:-1,"aria-hidden":"true"},{...n.decrementButtonProps,...e.ptm("decrementButton")}),{icon:Ee(()=>[he(e.$slots,"decrementbuttonicon",{},()=>[(g(),Q(_e(n.decrementButtonIcon?"span":"AngleDownIcon"),R({class:n.decrementButtonIcon},e.ptm("decrementButton").icon),null,16,["class"]))])]),_:3},16,["class","disabled"])],16)):M("",!0),n.showButtons&&n.buttonLayout!=="stacked"?(g(),Q(o,R({key:1,class:s.upButtonClass},xi(s.upButtonListeners),{disabled:n.disabled,tabindex:-1,"aria-hidden":"true"},{...n.incrementButtonProps,...e.ptm("incrementButton")}),{icon:Ee(()=>[he(e.$slots,"incrementbuttonicon",{},()=>[(g(),Q(_e(n.incrementButtonIcon?"span":"AngleUpIcon"),R({class:n.incrementButtonIcon},e.ptm("incrementButton").icon),null,16,["class"]))])]),_:3},16,["class","disabled"])):M("",!0),n.showButtons&&n.buttonLayout!=="stacked"?(g(),Q(o,R({key:2,class:s.downButtonClass},xi(s.downButtonListeners),{disabled:n.disabled,tabindex:-1,"aria-hidden":"true"},{...n.decrementButtonProps,...e.ptm("decrementButton")}),{icon:Ee(()=>[he(e.$slots,"decrementbuttonicon",{},()=>[(g(),Q(_e(n.decrementButtonIcon?"span":"AngleDownIcon"),R({class:n.decrementButtonIcon},e.ptm("decrementButton").icon),null,16,["class"]))])]),_:3},16,["class","disabled"])):M("",!0)],16)}function zk(e,t){t===void 0&&(t={});var n=t.insertAt;if(!(typeof document>"u")){var i=document.head||document.getElementsByTagName("head")[0],r=document.createElement("style");r.type="text/css",n==="top"&&i.firstChild?i.insertBefore(r,i.firstChild):i.appendChild(r),r.styleSheet?r.styleSheet.cssText=e:r.appendChild(document.createTextNode(e))}}var Kk=`
563.p-inputnumber {
564    display: inline-flex;
565}
566.p-inputnumber-button {
567    display: flex;
568    align-items: center;
569    justify-content: center;
570    flex: 0 0 auto;
571}
572.p-inputnumber-buttons-stacked .p-button.p-inputnumber-button .p-button-label,
573.p-inputnumber-buttons-horizontal .p-button.p-inputnumber-button .p-button-label {
574    display: none;
575}
576.p-inputnumber-buttons-stacked .p-button.p-inputnumber-button-up {
577    border-top-left-radius: 0;
578    border-bottom-left-radius: 0;
579    border-bottom-right-radius: 0;
580    padding: 0;
581}
582.p-inputnumber-buttons-stacked .p-inputnumber-input {
583    border-top-right-radius: 0;
584    border-bottom-right-radius: 0;
585}
586.p-inputnumber-buttons-stacked .p-button.p-inputnumber-button-down {
587    border-top-left-radius: 0;
588    border-top-right-radius: 0;
589    border-bottom-left-radius: 0;
590    padding: 0;
591}
592.p-inputnumber-buttons-stacked .p-inputnumber-button-group {
593    display: flex;
594    flex-direction: column;
595}
596.p-inputnumber-buttons-stacked .p-inputnumber-button-group .p-button.p-inputnumber-button {
597    flex: 1 1 auto;
598}
599.p-inputnumber-buttons-horizontal .p-button.p-inputnumber-button-up {
600    order: 3;
601    border-top-left-radius: 0;
602    border-bottom-left-radius: 0;
603}
604.p-inputnumber-buttons-horizontal .p-inputnumber-input {
605    order: 2;
606    border-radius: 0;
607}
608.p-inputnumber-buttons-horizontal .p-button.p-inputnumber-button-down {
609    order: 1;
610    border-top-right-radius: 0;
611    border-bottom-right-radius: 0;
612}
613.p-inputnumber-buttons-vertical {
614    flex-direction: column;
615}
616.p-inputnumber-buttons-vertical .p-button.p-inputnumber-button-up {
617    order: 1;
618    border-bottom-left-radius: 0;
619    border-bottom-right-radius: 0;
620    width: 100%;
621}
622.p-inputnumber-buttons-vertical .p-inputnumber-input {
623    order: 2;
624    border-radius: 0;
625    text-align: center;
626}
627.p-inputnumber-buttons-vertical .p-button.p-inputnumber-button-down {
628    order: 3;
629    border-top-left-radius: 0;
630    border-top-right-radius: 0;
631    width: 100%;
632}
633.p-inputnumber-input {
634    flex: 1 1 auto;
635}
636.p-fluid .p-inputnumber {
637    width: 100%;
638}
639.p-fluid .p-inputnumber .p-inputnumber-input {
640    width: 1%;
641}
642.p-fluid .p-inputnumber-buttons-vertical .p-inputnumber-input {
643    width: 100%;
644}
645`;zk(Kk);Rl.render=Hk;var kf={name:"AngleDoubleRightIcon",extends:ze};const Gk=f("path",{"fill-rule":"evenodd","clip-rule":"evenodd",d:"M7.68757 11.
6451451C7.7791 11.1831 7.8773 11.2024 7.9764 11.2019C8.07769 11.1985 8.17721 11.1745 8.26886 11.1312C8.36052 11.088 8.44238 11.0265 8.50943 10.9505L12.0294 7.49085C12.1707 7.34942 12.25 7.15771 12.25 6.95782C12.25 6.75794 12.1707 6.56622 12.0294 6.42479L8.50943 2.90479C8.37014 2.82159 8.20774 2.78551 8.04633 2.80192C7.88491 2.81833 7.73309 2.88635 7.6134 2.99588C7.4937 3.10541 7.41252 3.25061 7.38189 3.40994C7.35126 3.56927 7.37282 3.73423 7.44337 3.88033L10.4605 6.89748L7.44337 9.91463C7.30212 10.0561 7.22278 10.2478 7.22278 10.4477C7.22278 10.6475 7.30212 10.8393 7.44337 10.9807C7.51301 11.0512 7.59603 11.1071 7.68757 11.1451ZM1.94207 10.9505C2.07037 11.0968 2.25089 11.1871 2.44493 11.2019C2.63898 11.1871 2.81949 11.0968 2.94779 10.9505L6.46779 7.49085C6.60905 7.34942 6.68839 7.15771 6.68839 6.95782C6.68839 6.75793 6.60905 6.56622 6.46779 6.42479L2.94779 2.90479C2.80704 2.83757 2.6489 2.81563 2.49517 2.84201C2.34143 2.86839 2.19965 2.94178 2.08936 3.05207C1.97906 3.16237 1.90567 3.30415 1.8793 3.45788C1.85292 3.61162 1.87485 3.76975 1.94207 3.9105L4.95922 6.92765L1.94207 9.9448C1.81838 10.0831 1.75 10.2621 1.75 10.4477C1.75 10.6332 1.81838 10.8122 1.94207 10.9505Z",fill:"currentColor"},null,-1),jk=[Gk];function Yk(e,t,n,i,r,s){return g(),S("svg",R({width:"14",height:"14",viewBox:"0 0 14 14",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e.pti()),jk,16)}kf.render=Yk;var Rf={name:"AngleRightIcon",extends:ze};const Wk=f("path",{d:"M5.25 11.1728C5.14929 11.1694 5.05033 11.1455 4.9592 11.1025C4.86806 11.0595 4.78666 10.9984 4.72 10.9228C4.57955 10.7822 4.50066 10.5916 4.50066 10.3928C4.50066 10.1941 4.57955 10.0035 4.72 9.86283L7.72 6.86283L4.72 3.86283C4.66067 3.71882 4.64765 3.55991 4.68275 3.40816C4.71785 3.25642 4.79932 3.11936 4.91585 3.01602C5.03238 2.91268 5.17819 2.84819 5.33305 2.83149C5.4879 2.81479 5.64411 2.84671 5.78 2.92283L9.28 6.42283C9.42045 6.56346 9.49934 6.75408 9.49934 6.95283C9.49934 7.15158 9.42045 7.34221 9.28 7.48283L5.78 10.9228C5.71333 10.9984 5.63193 11.0595 5.5408 11.1025C5.44966 11.1455 5.35071 11.1694 5.25 11.1728Z",fill:"currentColor"},null,-1),Qk=[Wk];function Zk(e,t,n,i,r,s){return g(),S("svg",R({width:"14",height:"14",viewBox:"0 0 14 14",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e.pti()),Qk,16)}Rf.render=Zk;var Lf={name:"AngleLeftIcon",extends:ze};const qk=f("path",{d:"M8.75 11.185C8.65146 11.1854 8.55381 11.1662 8.4628 11.1284C8.37179 11.0906 8.28924 11.0351 8.22 10.965L4.72 7.46496C4.57955 7.32433 4.50066 7.13371 4.50066 6.93496C4.50066 6.73621 4.57955 6.54558 4.72 6.40496L8.22 2.93496C8.36095 2.84357 8.52851 2.80215 8.69582 2.81733C8.86312 2.83252 9.02048 2.90344 9.14268 3.01872C9.26487 3.134 9.34483 3.28696 9.36973 3.4531C9.39463 3.61924 9.36303 3.78892 9.28 3.93496L6.28 6.93496L9.28 9.93496C9.42045 10.0756 9.49934 10.2662 9.49934 10.465C9.49934 10.6637 9.42045 10.8543 9.28 10.995C9.13526 11.1257 8.9448 11.1939 8.75 11.185Z",fill:"currentColor"},null,-1),Jk=[qk];function Xk(e,t,n,i,r,s){return g(),S("svg",R({width:"14",height:"14",viewBox:"0 0 14 14",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e.pti()),Jk,16)}Lf.render=Xk;var Nf={name:"CurrentPageReport",extends:Ve,props:{pageCount:{type:Number,default:0},currentPage:{type:Number,default:0},page:{type:Number,default:0},first:{type:Number,default:0},rows:{type:Number,default:0},totalRecords:{type:Number,default:0},template:{type:String,default:"({currentPage} of {totalPages})"}},computed:{text(){return this.template.replace("{currentPage}",this.currentPage).replace("{totalPages}",this.pageCount).replace("{first}",this.pageCount>0?this.first+1:0).replace("{last}",Math.min(this.first+this.rows,this.totalRecords)).replace("{rows}",this.rows).replace("{totalRecords}",this.totalRecords)}}};function eR(e,t,n,i,r,s){return g(),S("span",R({class:"p-paginator-current"},e.ptm("current")),N(s.text),17)}Nf.render=eR;var Df={name:"FirstPageLink",extends:Ve,props:{template:{type:Function,default:null}},methods:{getPTOptions(e){return this.ptm(e,{context:{disabled:this.$attrs.disabled}})}},computed:{containerClass(){return["p-paginator-first p-paginator-element p-link",{"p-disabled":this.$attrs.disabled}]}},components:{AngleDoubleLeftIcon:Pf},directives:{ripple:gt}};function tR(e,t,n,i,r,s){const a=Xe("ripple");return Ne((g(),S("button",R({class:s.containerClass,type:"button"},s.getPTOptions("firstPageButton")),[(g(),Q(_e(n.template||"AngleDoubleLeftIcon"),R({class:"p-paginator-icon"},s.getPTOptions("firstPageIcon")),null,16))],16)),[[a]])}Df.render=tR;var xf={name:"JumpToPageDropdown",extends:Ve,emits:["page-change"],props:{page:Number,pageCount:Number,disabled:Boolean}
645,methods:{onChange(e){this.$emit("page-change",e)}},computed:{pageOptions(){let e=[];for(let t=0;t<this.pageCount;t++)e.push({label:String(t+1),value:t});return e}},components:{JTPDropdown:Ni}};function nR(e,t,n,i,r,s){const a=le("JTPDropdown");return g(),Q(a,{modelValue:n.page,options:s.pageOptions,optionLabel:"label",optionValue:"value","onUpdate:modelValue":t[0]||(t[0]=o=>s.onChange(o)),class:"p-paginator-page-options",disabled:n.disabled,pt:e.ptm("JTPDropdown")},null,8,["modelValue","options","disabled","pt"])}xf.render=nR;var Mf={name:"JumpToPageInput",extends:Ve,inheritAttrs:!1,emits:["page-change"],props:{page:Number,pageCount:Number,disabled:Boolean},data(){return{d_page:this.page}},watch:{page(e){this.d_page=e}},methods:{onChange(e){e!==this.page&&(this.d_page=e,this.$emit("page-change",e-1))}},computed:{inputArialabel(){return this.$primevue.config.locale.aria?this.$primevue.config.locale.aria.jumpToPageInputLabel:void 0}},components:{JTPInput:Rl}};function sR(e,t,n,i,r,s){const a=le("JTPInput");return g(),Q(a,{ref:"jtpInput",modelValue:r.d_page,class:"p-paginator-page-input","aria-label":s.inputArialabel,disabled:n.disabled,"onUpdate:modelValue":s.onChange,pt:e.ptm("JTPInput")},null,8,["modelValue","aria-label","disabled","onUpdate:modelValue","pt"])}Mf.render=sR;var Ff={name:"LastPageLink",extends:Ve,props:{template:{type:Function,default:null}},methods:{getPTOptions(e){return this.ptm(e,{context:{disabled:this.$attrs.disabled}})}},computed:{containerClass(){return["p-paginator-last p-paginator-element p-link",{"p-disabled":this.$attrs.disabled}]}},components:{AngleDoubleRightIcon:kf},directives:{ripple:gt}};function iR(e,t,n,i,r,s){const a=Xe("ripple");return Ne((g(),S("button",R({class:s.containerClass,type:"button"},s.getPTOptions("lastPageButton")),[(g(),Q(_e(n.template||"AngleDoubleRightIcon"),R({class:"p-paginator-icon"},s.getPTOptions("lastPageIcon")),null,16))],16)),[[a]])}Ff.render=iR;var Vf={name:"NextPageLink",extends:Ve,props:{template:{type:Function,default:null}},methods:{getPTOptions(e){return this.ptm(e,{context:{disabled:this.$attrs.disabled}})}},computed:{containerClass(){return["p-paginator-next p-paginator-element p-link",{"p-disabled":this.$attrs.disabled}]}},components:{AngleRightIcon:Rf},directives:{ripple:gt}};function rR(e,t,n,i,r,s){const a=Xe("ripple");return Ne((g(),S("button",R({class:s.containerClass,type:"button"},s.getPTOptions("nextPageButton")),[(g(),Q(_e(n.template||"AngleRightIcon"),R({class:"p-paginator-icon"},s.getPTOptions("nextPageIcon")),null,16))],16)),[[a]])}Vf.render=rR;var Bf={name:"PageLinks",extends:Ve,inheritAttrs:!1,emits:["click"],props:{value:Array,page:Number},methods:{getPTOptions(e,t){return this.ptm(t,{context:{active:e===this.page}})},onPageLinkClick(e,t){this.$emit("click",{originalEvent:e,value:t})},ariaPageLabel(e){return this.$primevue.config.locale.aria?this.$primevue.config.locale.aria.pageLabel.replace(/{page}/g,e):void 0}},directives:{ripple:gt}};const aR=["aria-label","aria-current","onClick"];function oR(e,t,n,i,r,s){const a=Xe("ripple");return g(),S("span",R({class:"p-paginator-pages"},e.ptm("pages")),[(g(!0),S(J,null,ye(n.value,o=>Ne((g(),S("button",R({key:o,class:["p-paginator-page p-paginator-element p-link",{"p-highlight":o-1===n.page}],type:"button","aria-label":s.ariaPageLabel(o),"aria-current":o-1===n.page?"page":void 0,onClick:l=>s.onPageLinkClick(l,o)},s.getPTOptions(o-1,"pageButton")),[ke(N(o),1)],16,aR)),[[a]])),128))],16)}Bf.render=oR;var $f={name:"PrevPageLink",extends:Ve,props:{template:{type:Function,default:null}},methods:{getPTOptions(e){return this.ptm(e,{context:{disabled:this.$attrs.disabled}})}},computed:{containerClass(){return["p-paginator-prev p-paginator-element p-link",{"p-disabled":this.$attrs.disabled}]}},components:{AngleLeftIcon:Lf},directives:{ripple:gt}};function lR(e,t,n,i,r,s){const a=Xe("ripple");return Ne((g(),S("button",R({class:s.containerClass,type:"button"},s.getPTOptions("prevPageButton")),[(g(),Q(_e(n.template||"AngleLeftIcon"),R({class:"p-paginator-icon"},s.getPTOptions("prevPageIcon")),null,16))],16)),[[a]])}$f.render=lR;var Uf={name:"RowsPerPageDropdown",extends:Ve,emits:["rows-change"],props:{options:Array,rows:Number,disabled:Boolean}
645,methods:{onChange(e){this.$emit("rows-change",e)}},computed:{rowsOptions(){let e=[];if(this.options)for(let t=0;t<this.options.length;t++)e.push({label:String(this.options[t]),value:this.options[t]});return e}},components:{RPPDropdown:Ni}};function cR(e,t,n,i,r,s){const a=le("RPPDropdown");return g(),Q(a,{modelValue:n.rows,options:s.rowsOptions,optionLabel:"label",optionValue:"value","onUpdate:modelValue":t[0]||(t[0]=o=>s.onChange(o)),class:"p-paginator-rpp-options",disabled:n.disabled,pt:e.ptm("RPPDropdown")},null,8,["modelValue","options","disabled","pt"])}Uf.render=cR;var Hf={name:"Paginator",extends:Ve,emits:["update:first","update:rows","page"],props:{totalRecords:{type:Number,default:0},rows:{type:Number,default:0},first:{type:Number,default:0},pageLinkSize:{type:Number,default:5},rowsPerPageOptions:{type:Array,default:null},template:{type:[Object,String],default:"FirstPageLink PrevPageLink PageLinks NextPageLink LastPageLink RowsPerPageDropdown"},currentPageReportTemplate:{type:null,default:"({currentPage} of {totalPages})"},alwaysShow:{type:Boolean,default:!0}},data(){return{d_first:this.first,d_rows:this.rows}},watch:{first(e){this.d_first=e},rows(e){this.d_rows=e},totalRecords(e){this.page>0&&e&&this.d_first>=e&&this.changePage(this.pageCount-1)}},mounted(){this.setPaginatorAttribute(),this.createStyle()},methods:{changePage(e){const t=this.pageCount;if(e>=0&&e<t){this.d_first=this.d_rows*e;const n={page:e,first:this.d_first,rows:this.d_rows,pageCount:t};this.$emit("update:first",this.d_first),this.$emit("update:rows",this.d_rows),this.$emit("page",n)}},changePageToFirst(e){this.isFirstPage||this.changePage(0),e.preventDefault()},changePageToPrev(e){this.changePage(this.page-1),e.preventDefault()},changePageLink(e){this.changePage(e.value-1),e.originalEvent.preventDefault()},changePageToNext(e){this.changePage(this.page+1),e.preventDefault()},changePageToLast(e){this.isLastPage||this.changePage(this.pageCount-1),e.preventDefault()},onRowChange(e){this.d_rows=e,this.changePage(this.page)},createStyle(){if(this.hasBreakpoints()){this.styleElement=document.createElement("style"),this.styleElement.type="text/css",document.head.appendChild(this.styleElement);let e="";const t=Object.keys(this.template),n={};t.sort((i,r)=>parseInt(i)-parseInt(r)).forEach(i=>{n[i]=this.template[i]});for(const[i,[r]]of Object.entries(Object.entries(n))){const s=Object.entries(n)[i-1]?`and (min-width:${Object.keys(n)[i-1]})`:"";r==="default"?e+=`
646                            @media screen ${s} {
647                                .paginator[${this.attributeSelector}],
648                                .p-paginator-default{
649                                    display: flex !important;
650                                }
651                            }
652                        `:e+=`
653                        .paginator[${this.attributeSelector}], .p-paginator-${r} {
654                                display: none !important;
655                            }
656                        @media screen ${s} and (max-width: ${r}) {
657                            .paginator[${this.attributeSelector}], .p-paginator-${r} {
658                                display: flex !important;
659                            }
660                            .paginator[${this.attributeSelector}],
661                            .p-paginator-default{
662                                display: none !important;
663                            }
664                        }
665                    `}this.styleElement.innerHTML=e}},hasBreakpoints(){return typeof this.template=="object"},getPaginatorClasses(e){return[{"p-paginator-default":!this.hasBreakpoints(),[`p-paginator-${e}`]:this.hasBreakpoints()}]},setPaginatorAttribute(){this.$refs.paginator&&this.$refs.paginator.length>=0&&[...this.$refs.paginator].forEach(e=>{e.setAttribute(this.attributeSelector,"")})},getAriaLabel(e){return this.$primevue.config.locale.aria?this.$primevue.config.locale.aria[e]:void 0}},computed:{templateItems(){let e={};if(this.hasBreakpoints()){e=this.template,e.default||(e.default="FirstPageLink PrevPageLink PageLinks NextPageLink LastPageLink RowsPerPageDropdown");for(const t in e)e[t]=this.template[t].split(" ").map(n=>n.trim());return e}return e.default=this.template.split(" ").map(t=>t.trim()),e},page(){return Math.floor(this.d_first/this.d_rows)},pageCount(){return Math.ceil(this.totalRecords/this.d_rows)},isFirstPage(){return this.page===0},isLastPage(){return this.page===this.pageCount-1},calculatePageLinkBoundaries(){const e=this.pageCount,t=Math.min(this.pageLinkSize,e);let n=Math.max(0,Math.ceil(this.page-t/2)),i=Math.min(e-1,n+t-1);const r=this.pageLinkSize-(i-n+1);return n=Math.max(0,n-r),[n,i]},pageLinks(){let e=[],t=this.calculatePageLinkBoundaries,n=t[0],i=t[1];for(var r=n;r<=i;r++)e.push(r+1);return e},currentState(){return{page:this.page,first:this.d_first,rows:this.d_rows}},empty(){return this.pageCount===0},currentPage(){return this.pageCount>0?this.page+1:0},attributeSelector(){return pt()}},components:{CurrentPageReport:Nf,FirstPageLink:Df,LastPageLink:Ff,NextPageLink:Vf,PageLinks:Bf,PrevPageLink:$f,RowsPerPageDropdown:Uf,JumpToPageDropdown:xf,JumpToPageInput:Mf}};function dR(e,t,n,i,r,s){const a=le("FirstPageLink"),o=le("PrevPageLink"),l=le("NextPageLink"),c=le("LastPageLink"),d=le("PageLinks"),u=le("CurrentPageReport"),p=le("RowsPerPageDropdown"),h=le("JumpToPageDropdown"),m=le("JumpToPageInput");return n.alwaysShow||s.pageLinks&&s.pageLinks.length>1?(g(),S("nav",ft(R({key:0},e.ptm("root"))),[(g(!0),S(J,null,ye(s.templateItems,(v,_)=>(g(),S("div",R({key:_,ref_for:!0,ref:"paginator",class:["p-paginator p-component",s.getPaginatorClasses(_)]},e.ptm("paginator")),[e.$slots.start?(g(),S("div",R({key:0,class:"p-paginator-left-content"},e.ptm("left")),[he(e.$slots,"start",{state:s.currentState})],16)):M("",!0),(g(!0),S(J,null,ye(v,b=>(g(),S(J,{key:b},[b==="FirstPageLink"?(g(),Q(a,{key:0,"aria-label":s.getAriaLabel("firstPageLabel"),template:e.$slots.firstpagelinkicon,onClick:t[0]||(t[0]=w=>s.changePageToFirst(w)),disabled:s.isFirstPage||s.empty,pt:e.pt},null,8,["aria-label","template","disabled","pt"])):b==="PrevPageLink"?(g(),Q(o,{key:1,"aria-label":s.getAriaLabel("prevPageLabel"),template:e.$slots.prevpagelinkicon,onClick:t[1]||(t[1]=w=>s.changePageToPrev(w)),disabled:s.isFirstPage||s.empty,pt:e.pt},null,8,["aria-label","template","disabled","pt"])):b==="NextPageLink"?(g(),Q(l,{key:2,"aria-label":s.getAriaLabel("nextPageLabel"),template:e.$slots.nextpagelinkicon,onClick:t[2]||(t[2]=w=>s.changePageToNext(w)),disabled:s.isLastPage||s.empty,pt:e.pt},null,8,["aria-label","template","disabled","pt"])):b==="LastPageLink"?(g(),Q(c,{key:3,"aria-label":s.getAriaLabel("lastPageLabel"),template:e.$slots.lastpagelinkicon,onClick:t[3]||(t[3]=w=>s.changePageToLast(w)),disabled:s.isLastPage||s.empty,pt:e.pt},null,8,["aria-label","template","disabled","pt"])):b==="PageLinks"?(g(),Q(d,{key:4,"aria-label":s.getAriaLabel("pageLabel"),value:s.pageLinks,page:s.page,onClick:t[4]||(t[4]=w=>s.changePageLink(w)),pt:e.pt},null,8,["aria-label","value","page","pt"])):b==="CurrentPageReport"?(g(),Q(u,{key:5,"aria-live":"polite",template:n.currentPageReportTemplate,currentPage:s.currentPage,page:s.page,pageCount:s.pageCount,first:r.d_first,rows:r.d_rows,totalRecords:n.totalRecords,pt:e.pt},null,8,["template","currentPage","page","pageCount","first","rows","totalRecords","pt"])):b==="RowsPerPageDropdown"&&n.rowsPerPageOptions?(g(),Q(p,{key:6,"aria-label":s.getAriaLabel("rowsPerPageLabel"),rows:r.d_rows,options:n.rowsPerPageOptions,onRowsChange:t[5]||
665(t[5]=w=>s.onRowChange(w)),disabled:s.empty,pt:e.pt},null,8,["aria-label","rows","options","disabled","pt"])):b==="JumpToPageDropdown"?(g(),Q(h,{key:7,"aria-label":s.getAriaLabel("jumpToPageDropdownLabel"),page:s.page,pageCount:s.pageCount,onPageChange:t[6]||(t[6]=w=>s.changePage(w)),disabled:s.empty,pt:e.pt},null,8,["aria-label","page","pageCount","disabled","pt"])):b==="JumpToPageInput"?(g(),Q(m,{key:8,page:s.currentPage,onPageChange:t[7]||(t[7]=w=>s.changePage(w)),disabled:s.empty,pt:e.pt},null,8,["page","disabled","pt"])):M("",!0)],64))),128)),e.$slots.end?(g(),S("div",R({key:1,class:"p-paginator-right-content"},e.ptm("end")),[he(e.$slots,"end",{state:s.currentState})],16)):M("",!0)],16))),128))],16)):M("",!0)}function uR(e,t){t===void 0&&(t={});var n=t.insertAt;if(!(typeof document>"u")){var i=document.head||document.getElementsByTagName("head")[0],r=document.createElement("style");r.type="text/css",n==="top"&&i.firstChild?i.insertBefore(r,i.firstChild):i.appendChild(r),r.styleSheet?r.styleSheet.cssText=e:r.appendChild(document.createTextNode(e))}}var hR=`
666.p-paginator-default {
667    display: flex;
668}
669.p-paginator {
670    display: flex;
671    align-items: center;
672    justify-content: center;
673    flex-wrap: wrap;
674}
675.p-paginator-left-content {
676    margin-right: auto;
677}
678.p-paginator-right-content {
679    margin-left: auto;
680}
681.p-paginator-page,
682.p-paginator-next,
683.p-paginator-last,
684.p-paginator-first,
685.p-paginator-prev,
686.p-paginator-current {
687    cursor: pointer;
688    display: inline-flex;
689    align-items: center;
690    justify-content: center;
691    line-height: 1;
692    user-select: none;
693    overflow: hidden;
694    position: relative;
695}
696.p-paginator-element:focus {
697    z-index: 1;
698    position: relative;
699}
700`;uR(hR);Hf.render=dR;var zf={name:"BarsIcon",extends:ze};const pR=f("path",{"fill-rule":"evenodd","clip-rule":"evenodd",d:"M13.3226 3.6129H0.677419C0.497757 3.6129 0.325452 3.54152 0.198411 3.41448C0.0713707 3.28744 0 3.11514 0 2.93548C0 2.75581 0.0713707 2.58351 0.198411 2.45647C0.325452 2.32943 0.497757 2.25806 0.677419 2.25806H13.3226C13.5022 2.25806 13.6745 2.32943 13.8016 2.45647C13.9286 2.58351 14 2.75581 14 2.93548C14 3.11514 13.9286 3.28744 13.8016 3.41448C13.6745 3.54152 13.5022 3.6129 13.3226 3.6129ZM13.3226 7.67741H0.677419C0.497757 7.67741 0.325452 7.60604 0.198411 7.479C0.0713707 7.35196 0 7.17965 0 6.99999C0 6.82033 0.0713707 6.64802 0.198411 6.52098C0.325452 6.39394 0.497757 6.32257 0.677419 6.32257H13.3226C13.5022 6.32257 13.6745 6.39394 13.8016 6.52098C13.9286 6.64802 14 6.82033 14 6.99999C14 7.17965 13.9286 7.35196 13.8016 7.479C13.6745 7.60604 13.5022 7.67741 13.3226 7.67741ZM0.677419 11.7419H13.3226C13.5022 11.7419 13.6745 11.6706 13.8016 11.5435C13.9286 11.4165 14 11.2442 14 11.0645C14 10.8848 13.9286 10.7125 13.8016 10.5855C13.6745 10.4585 13.5022 10.3871 13.3226 10.3871H0.677419C0.497757 10.3871 0.325452 10.4585 0.198411 10.5855C0.0713707 10.7125 0 10.8848 0 11.0645C0 11.2442 0.0713707 11.4165 0.198411 11.5435C0.325452 11.6706 0.497757 11.7419 0.677419 11.7419Z",fill:"currentColor"},null,-1),fR=[pR];function mR(e,t,n,i,r,s){return g(),S("svg",R({width:"14",height:"14",viewBox:"0 0 14 14",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e.pti()),fR,16)}zf.render=mR;var Kf={name:"PencilIcon",extends:ze};const gR=f("g",{"clip-path":"url(#clip0_414_20836)"},[f("path",{d:"M0.609628 13.959C0.530658 13.9599 0.452305 13.9451 0.379077 13.9156C0.305849 13.8861 0.239191 13.8424 0.18294 13.787C0.118447 13.7234 0.0688234 13.6464 0.0376166 13.5614C0.00640987 13.4765 -0.00560954 13.3857 0.00241768 13.2956L0.25679 10.1501C0.267698 10.0041 0.331934 9.86709 0.437312 9.76516L9.51265 0.705715C10.0183 0.233014 10.6911 -0.0203041 11.3835 0.00127367C12.0714 0.00660201 12.7315 0.27311 13.2298 0.746671C13.7076 1.23651 13.9824 1.88848 13.9992 2.57201C14.0159 3.25554 13.7733 3.92015 13.32 4.4327L4.23648 13.5331C4.13482 13.6342 4.0017 13.6978 3.85903 13.7133L0.667067 14L0.609628 13.959ZM1.43018 10.4696L1.25787 12.714L3.50619 12.5092L12.4502 3.56444C12.6246 3.35841 12.7361 3.10674 12.7714 2.83933C12.8067 2.57193 12.7644 2.30002 12.6495 2.05591C12.5346 1.8118 12.3519 1.60575 12.1231 1.46224C11.8943 1.31873 11.6291 1.2438 11.3589 1.24633C11.1813 1.23508 11.0033 1.25975 10.8355 1.31887C10.6677 1.37798 10.5136 1.47033 10.3824 1.59036L1.43018 10.4696Z",fill:"currentColor"})],-1),yR=f("defs",null,[f("clipPath",{id:"clip0_414_20836"},[f("rect",{width:"14",height:"14",fill:"white"})])],-1),bR=[gR,yR];function vR(e,t,n,i,r,s){return g(),S("svg",R({width:"14",height:"14",viewBox:"0 0 14 14",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e.pti()),bR,16)}Kf.render=vR;function _R(e,t){const{onFocusIn:n,onFocusOut:i}=t.value||{};e.$_pfocustrap_mutationobserver=new MutationObserver(r=>{r.forEach(s=>{if(s.type==="childList"&&!e.contains(document.activeElement)){const a=o=>{const l=F.isFocusableElement(o)?o:F.getFirstFocusableElement(o);return ve.isNotEmpty(l)?l:a(o.nextSibling)};F.focus(a(s.nextSibling))}})}),e.$_pfocustrap_mutationobserver.disconnect(),e.$_pfocustrap_mutationobserver.observe(e,{childList:!0}),e.$_pfocustrap_focusinlistener=r=>n&&n(r),e.$_pfocustrap_focusoutlistener=r=>i&&i(r),e.addEventListener("focusin",e.$_pfocustrap_focusinlistener),e.addEventListener("focusout",e.$_pfocustrap_focusoutlistener)}function Zd(e){e.$_pfocustrap_mutationobserver&&e.$_pfocustrap_mutationobserver.disconnect(),e.$_pfocustrap_focusinlistener&&e.removeEventListener("focusin",e.$_pfocustrap_focusinlistener)&&(e.$_pfocustrap_focusinlistener=null),e.$_pfocustrap_focusoutlistener&&e.removeEventListener("focusout",e.$_pfocustrap_focusoutlistener)&&(e.$_pfocustrap_focusoutlistener=null)}function wR(e,t){const{autoFocusSelector:n="",firstFocusableSelector:i="",autoFocus:r=!1}=t.value||{};let s=F.getFirstFocusableElement(e,`[autofocus]:not(.p-hidden-focusable)${n}`);r&&!s&&(s=F.getFirstFocusableElement(e,`:not(.p-hidden-focusable)${i}`)),F.focus(s)}function ER(e){const{currentTarget:t,relatedTarget:n}=e,i=n===t.$_pfocustrap_lasthiddenfocusableelement?F.getFirstFocusableElement(t.parentElement,`:not(.p-hidden-focusable)${t.$_pfocustrap_focusableselector}`):t.$_pfocustrap_lasthiddenfocusableelement;F.focus(i)}function SR(e){const{currentTarget:t,relatedTarget:n}=e,i=n===t.$_pfocustrap_firsthiddenfocusableelement?F.getLastFocusableElement(t.parentElement,`:not(.p-hidden-focusable)${t.$_pfocustrap_focusableselector}`):t.$_pfocustrap_firsthiddenfocusableelement;F.focus(i)}function CR(e,t){const{tabIndex:n=0,firstFocusableSelector:i="",lastFocusableSelector:r=""}=t.value||{},s=l=>{const c=document.createElement("span");return c.classList="p-hidden-accessible p-hidden-focusable",c.tabIndex=n,c.setAttribute("aria-hidden","true"),c.setAttribute("role","presentation"),c.addEventListener("focus",l),c},a=s(ER),o=s(SR);a.$_pfocustrap_lasthiddenfocusableelement=o,a.$_pfocustrap_focusableselector=i,o.$_pfocustrap_firsthiddenfocusableelement=a,o.$_pfocustrap_focusableselector=r,e.prepe
700nd(a),e.append(o)}const Fs={mounted(e,t){const{disabled:n}=t.value||{};n||(CR(e,t),_R(e,t),wR(e,t))},updated(e,t){const{disabled:n}=t.value||{};n&&Zd(e)},unmounted(e){Zd(e)}};var Gf={name:"FilterSlashIcon",extends:ze};const IR=f("g",{"clip-path":"url(#clip0_408_20963)"},[f("path",{"fill-rule":"evenodd","clip-rule":"evenodd",d:"M13.4994 0.0920138C13.5967 0.151519 13.6758 0.236453 13.7283 0.337647C13.7807 0.439133 13.8031 0.553448 13.7929 0.667208C13.7827 0.780968 13.7403 0.889466 13.6707 0.98L11.406 4.06823C11.3099 4.19928 11.1656 4.28679 11.005 4.3115C10.8444 4.33621 10.6805 4.2961 10.5495 4.2C10.4184 4.1039 10.3309 3.95967 10.3062 3.79905C10.2815 3.63843 10.3216 3.47458 10.4177 3.34353L11.9412 1.23529H7.41184C7.24803 1.23529 7.09093 1.17022 6.97509 1.05439C6.85926 0.938558 6.79419 0.781457 6.79419 0.617647C6.79419 0.453837 6.85926 0.296736 6.97509 0.180905C7.09093 0.0650733 7.24803 0 7.41184 0H13.1765C13.2905 0.000692754 13.4022 0.0325088 13.4994 0.0920138ZM4.20008 0.181168H4.24126L13.2013 9.03411C13.3169 9.14992 13.3819 9.3069 13.3819 9.47058C13.3819 9.63426 13.3169 9.79124 13.2013 9.90705C13.1445 9.96517 13.0766 10.0112 13.0016 10.0423C12.9266 10.0735 12.846 10.0891 12.7648 10.0882C12.6836 10.0886 12.6032 10.0728 12.5283 10.0417C12.4533 10.0106 12.3853 9.96479 12.3283 9.90705L9.3142 6.92587L9.26479 6.99999V13.3823C9.26265 13.5455 9.19689 13.7014 9.08152 13.8167C8.96615 13.9321 8.81029 13.9979 8.64714 14H5.35302C5.18987 13.9979 5.03401 13.9321 4.91864 13.8167C4.80327 13.7014 4.73751 13.5455 4.73537 13.3823V6.99999L0.329492 1.02117C0.259855 0.930634 0.21745 0.822137 0.207241 0.708376C0.197031 0.594616 0.21944 0.480301 0.271844 0.378815C0.324343 0.277621 0.403484 0.192687 0.500724 0.133182C0.597964 0.073677 0.709609 0.041861 0.823609 0.0411682H3.86243C3.92448 0.0461551 3.9855 0.060022 4.04361 0.0823446C4.10037 0.10735 4.15311 0.140655 4.20008 0.181168ZM8.02949 6.79411C8.02884 6.66289 8.07235 6.53526 8.15302 6.43176L8.42478 6.05293L3.55773 1.23529H2.0589L5.84714 6.43176C5.92781 6.53526 5.97132 6.66289 5.97067 6.79411V12.7647H8.02949V6.79411Z",fill:"currentColor"})],-1),TR=f("defs",null,[f("clipPath",{id:"clip0_408_20963"},[f("rect",{width:"14",height:"14",fill:"white"})])],-1),PR=[IR,TR];function OR(e,t,n,i,r,s){return g(),S("svg",R({width:"14",height:"14",viewBox:"0 0 14 14",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e.pti()),PR,16)}Gf.render=OR;var jf={name:"TrashIcon",extends:ze};const AR=f("g",{"clip-path":"url(#clip0_417_21589)"},[f("path",{"fill-rule":"evenodd","clip-rule":"evenodd",d:"M3.44802 13.9955H10.552C10.8056 14.0129 11.06 13.9797 11.3006 13.898C11.5412 13.8163 11.7632 13.6877 11.9537 13.5196C12.1442 13.3515 12.2995 13.1473 12.4104 12.9188C12.5213 12.6903 12.5858 12.442 12.6 12.1884V4.36041H13.4C13.5591 4.36041 13.7117 4.29722 13.8243 4.18476C13.9368 4.07229 14 3.91976 14 3.76071C14 3.60166 13.9368 3.44912 13.8243 3.33666C13.7117 3.22419 13.5591 3.16101 13.4 3.16101H12.0537C12.0203 3.1557 11.9863 3.15299 11.952 3.15299C11.9178 3.15299 11.8838 3.1557 11.8503 3.16101H11.2285C11.2421 3.10893 11.2487 3.05513 11.248 3.00106V1.80966C11.2171 1.30262 10.9871 0.828306 10.608 0.48989C10.229 0.151475 9.73159 -0.0236625 9.22402 0.00257442H4.77602C4.27251 -0.0171866 3.78126 0.160868 3.40746 0.498617C3.03365 0.836366 2.807 1.30697 2.77602 1.80966V3.00106C2.77602 3.0556 2.78346 3.10936 2.79776 3.16101H0.6C0.521207 3.16101 0.443185 3.17652 0.37039 3.20666C0.297595 3.2368 0.231451 3.28097 0.175736 3.33666C0.120021 3.39235 0.0758251 3.45846 0.0456722 3.53121C0.0155194 3.60397 0 3.68196 0 3.76071C0 3.83946 0.0155194 3.91744 0.0456722 3.9902C0.0758251 4.06296 0.120021 4.12907 0.175736 4.18476C0.231451 4.24045 0.297595 4.28462 0.37039 4.31476C0.443185 4.3449 0.521207 4.36041 0.6 4.36041H1.40002V12.1884C1.41426 12.442 1.47871 12.6903 1.58965 12.9188C1.7006 13.1473 1.85582 13.3515 2.04633 13.5196C2.23683 13.6877 2.45882 13.8163 2.69944 13.898C2.94005 13.9797 3.1945 14.0129 3.44802 13.9955ZM2.60002 4.36041H11.304V12.1884C11.304 12.5163 10.952 12.7961 10.504 12.7961H3.40002C2.97602 12.7961 2.60002 12.5163 2.60002 12.1884V4.36041ZM3.95429 3.16101C3.96859 3.10936 3.97602 3.0556 3.97602 3.00106V1.80966C3.97602 1.48183 4.33602 1.20197 4.77602 1.20197H9.24802C9.66403 1.20197 10.048 1.48183 10.048 1.80966V3.00106C10.0473 3.05515 10.054 3.10896 10.0678 3.16101H3.95429ZM5.57571 10.997C5.41731 10.995 5.26597 10.9311 5.15395 10.8191C5.04193 10.7071 4.97808 
70010.5558 4.97601 10.3973V6.77517C4.97601 6.61612 5.0392 6.46359 5.15166 6.35112C5.26413 6.23866 5.41666 6.17548 5.57571 6.17548C5.73476 6.17548 5.8873 6.23866 5.99976 6.35112C6.11223 6.46359 6.17541 6.61612 6.17541 6.77517V10.3894C6.17647 10.4688 6.16174 10.5476 6.13208 10.6213C6.10241 10.695 6.05841 10.762 6.00261 10.8186C5.94682 10.8751 5.88035 10.92 5.80707 10.9506C5.73378 10.9813 5.65514 10.9971 5.57571 10.997ZM7.99968 10.8214C8.11215 10.9339 8.26468 10.997 8.42373 10.997C8.58351 10.9949 8.73604 10.93 8.84828 10.8163C8.96052 10.7025 9.02345 10.5491 9.02343 10.3894V6.77517C9.02343 6.61612 8.96025 6.46359 8.84778 6.35112C8.73532 6.23866 8.58278 6.17548 8.42373 6.17548C8.26468 6.17548 8.11215 6.23866 7.99968 6.35112C7.88722 6.46359 7.82404 6.61612 7.82404 6.77517V10.3973C7.82404 10.5564 7.88722 10.7089 7.99968 10.8214Z",fill:"currentColor"})],-1),kR=f("defs",null,[f("clipPath",{id:"clip0_417_21589"},[f("rect",{width:"14",height:"14",fill:"white"})])],-1),RR=[AR,kR];function LR(e,t,n,i,r,s){return g(),S("svg",R({width:"14",height:"14",viewBox:"0 0 14 14",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e.pti()),RR,16)}jf.render=LR;var Do={name:"SortAltIcon",extends:ze};const NR=Tr('<g clip-path="url(#clip0_378_15529)"><path d="M5.64515 3.61291C5.47353 3.61291 5.30192 3.54968 5.16644 3.4142L3.38708 1.63484L1.60773 3.4142C1.34579 3.67613 0.912244 3.67613 0.650309 3.4142C0.388374 3.15226 0.388374 2.71871 0.650309 2.45678L2.90837 0.198712C3.17031 -0.0632236 3.60386 -0.0632236 3.86579 0.198712L6.12386 2.45678C6.38579 2.71871 6.38579 3.15226 6.12386 3.4142C5.98837 3.54968 5.81676 3.61291 5.64515 3.61291Z" fill="currentColor"></path><path d="M3.38714 14C3.01681 14 2.70972 13.6929 2.70972 13.3226V0.677419C2.70972 0.307097 3.01681 0 3.38714 0C3.75746 0 4.06456 0.307097 4.06456 0.677419V13.3226C4.06456 13.6929 3.75746 14 3.38714 14Z" fill="currentColor"></path><path d="M10.6129 14C10.4413 14 10.2697 13.9368 10.1342 13.8013L7.87611 11.5432C7.61418 11.2813 7.61418 10.8477 7.87611 10.5858C8.13805 10.3239 8.5716 10.3239 8.83353 10.5858L10.6129 12.3652L12.3922 10.5858C12.6542 10.3239 13.0877 10.3239 13.3497 10.5858C13.6116 10.8477 13.6116 11.2813 13.3497 11.5432L11.0916 13.8013C10.9561 13.9368 10.7845 14 10.6129 14Z" fill="currentColor"></path><path d="M10.6129 14C10.2426 14 9.93552 13.6929 9.93552 13.3226V0.677419C9.93552 0.307097 10.2426 0 10.6129 0C10.9833 0 11.2904 0.307097 11.2904 0.677419V13.3226C11.2904 13.6929 10.9832 14 10.6129 14Z" fill="currentColor"></path></g><defs><clipPath id="clip0_378_15529"><rect width="14" height="14" fill="white"></rect></clipPath></defs>',2),DR=[NR];function xR(e,t,n,i,r,s){return g(),S("svg",R({width:"14",height:"14",viewBox:"0 0 14 14",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e.pti()),DR,16)}Do.render=xR;var xo={name:"SortAmountDownIcon",extends:ze};const MR=Tr('<g clip-path="url(#clip0_378_15544)"><path d="M2.59836 13.2009C2.44634 13.2009 2.29432 13.1449 2.1743 13.0248L0.174024 11.0246C-0.0580081 10.7925 -0.0580081 10.4085 0.174024 10.1764C0.406057 9.94441 0.79011 9.94441 1.02214 10.1764L2.59836 11.7527L4.17458 10.1764C4.40662 9.94441 4.79067 9.94441 5.0227 10.1764C5.25473 10.4085 5.25473 10.7925 5.0227 11.0246L3.02242 13.0248C2.90241 13.1449 2.75038 13.2009 2.59836 13.2009Z" fill="currentColor"></path><path d="M2.59836 13.2009C2.27032 13.2009 1.99833 12.9288 1.99833 12.6008V1.39922C1.99833 1.07117 2.27036 0.799133 2.59841 0.799133C2.92646 0.799133 3.19849 1.07117 3.19849 1.39922V12.6008C3.19849 12.9288 2.92641 13.2009 2.59836 13.2009Z" fill="currentColor"></path><path d="M13.3999 11.2006H6.99902C6.67098 11.2006 6.39894 10.9285 6.39894 10.6005C6.39894 10.2725 6.67098 10.0004 6.99902 10.0004H13.3999C13.728 10.0004 14 10.2725 14 10.6005C14 10.9285 13.728 11.2006 13.3999 11.2006Z" fill="currentColor"></path><path d="M10.1995 6.39991H6.99902C6.67098 6.39991 6.39894 6.12788 6.39894 5.79983C6.39894 5.47179 6.67098 5.19975 6.99902 5.19975H10.1995C10.5275 5.19975 10.7996 5.47179 10.7996 5.79983C10.7996 6.12788 10.5275 6.39991 10.1995 6.39991Z" fill="currentColor"></path><path d="M8.59925 3.99958H6.99902C6.67098 3.99958 6.39894 3.72754 6.39894 3.3995C6.39894 3.07145 6.67098 2.79941 6.99902 2.79941H8.59925C8.92729 2.79941 9.19933 3.07145 9.19933 3.3995C9.19933 3.72754 8.92729 3.99958 8.59925 3.99958Z" fill="currentColor"></path><path d="M11.7997 8.80025H6.99902C6.67098 8.80025 6.39894 8.52821 6.39894 8.20017C6.39894 7.87212 6.67098 7.60008 6.99902 7.60008H11.7997C12.1277 7.60008 12.3998 7.87212 12.3998 8.20017C12.3998 8.52821 12.1277 8.80025 11.7997 8.80025Z" fill="currentColor"></path></g><defs><clipPath id="clip0_378_15544"><rect width="14" height="14" fill="white"></rect></clipPath></defs>',2),FR=[MR];function VR(e,t,n,i,r,s){return g(),S("svg",R({width:"14",height:"14",viewBox:"0 0 14 14",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e.pti()),FR,16)}xo.render=VR;var Mo={name:"SortAmountUpAltIcon",extends:ze};const BR=Tr('<g clip-path="url(#clip0_378_15578)"><path d="M4.59864 3.99958C4.44662 3.99958 4.2946 3.94357 4.17458 3.82356L2.59836 2.24734L1.02214 3.82356C0.79011 4.05559 0.406057 4.05559 0.174024 3.82356C-0.0580081 3.59152 -0.0580081 3.20747 0.174024 2.97544L2.1743 0.97516C2.40634 0.743127 2.79039 0.743127 3.02242 0.97516L5.0227 2.97544C5.25473 3.20747 5.25473 3.59152 5.0227 3.82356C4.90268 3.94357 4.75066 3.99958 4.59864 3.99958Z" fill="currentColor"></path><path d="M2.59841 13.2009C2.27036 13.2009 1.99833 12.9288 1.99833 12.6008V1.39922C1.99833 1.07117 2.27036 0.799133 2.59841 0.799133C2.92646 0.799133 3.19849 1.07117 3.19849 1.39922V12.6008C3.19849 12.9288 2.92646 13.2009 2.59841 13.2009Z" fill="currentColor"></path><path d="M13.3999 11.2006H6.99902C6.67098 11.2006 6.39894 10.9285 6.39894 10.6005C6.39894 10.2725 6.67098 10.0004 6.99902 10.0004H13.3999C13.728 10.0004 14 10.2725 14 10.6005C14 10.9285 13.728 11.2006 13.3999 11.2006Z" fill="currentColor"></path><path d="M10.1995 6.39991H6.99902C6.67098 6.39991 6.39894 6.12788 6.39894 5.79983C6.39894 5.47179 
7006.67098 5.19975 6.99902 5.19975H10.1995C10.5275 5.19975 10.7996 5.47179 10.7996 5.79983C10.7996 6.12788 10.5275 6.39991 10.1995 6.39991Z" fill="currentColor"></path><path d="M8.59925 3.99958H6.99902C6.67098 3.99958 6.39894 3.72754 6.39894 3.3995C6.39894 3.07145 6.67098 2.79941 6.99902 2.79941H8.59925C8.92729 2.79941 9.19933 3.07145 9.19933 3.3995C9.19933 3.72754 8.92729 3.99958 8.59925 3.99958Z" fill="currentColor"></path><path d="M11.7997 8.80025H6.99902C6.67098 8.80025 6.39894 8.52821 6.39894 8.20017C6.39894 7.87212 6.67098 7.60008 6.99902 7.60008H11.7997C12.1277 7.60008 12.3998 7.87212 12.3998 8.20017C12.3998 8.52821 12.1277 8.80025 11.7997 8.80025Z" fill="currentColor"></path></g><defs><clipPath id="clip0_378_15578"><rect width="14" height="14" fill="white"></rect></clipPath></defs>',2),$R=[BR];function UR(e,t,n,i,r,s){return g(),S("svg",R({width:"14",height:"14",viewBox:"0 0 14 14",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e.pti()),$R,16)}Mo.render=UR;var Yf={name:"RowCheckbox",extends:Ve,emits:["change"],props:{value:null,checked:null,column:null,rowCheckboxIconTemplate:{type:Function,default:null}},data(){return{focused:!1}},methods:{getColumnPTOptions(e){return this.ptmo(this.getColumnProp(),e,{props:this.column.props,parent:{props:this.$props,state:this.$data},context:{checked:this.checked,focused:this.focused,disabled:this.$attrs.disabled}})},getColumnProp(){return this.column.props&&this.column.props.pt?this.column.props.pt:void 0},onClick(e){this.$attrs.disabled||(this.$emit("change",{originalEvent:e,data:this.value}),F.focus(this.$refs.input)),e.preventDefault()},onFocus(){this.focused=!0},onBlur(){this.focused=!1},onKeydown(e){switch(e.code){case"Space":{this.onClick(e);break}}}},computed:{checkboxAriaLabel(){return this.$primevue.config.locale.aria?this.checked?this.$primevue.config.locale.aria.selectRow:this.$primevue.config.locale.aria.unselectRow:void 0}},components:{CheckIcon:yn}};const HR=["checked","disabled","tabindex","aria-label"];function zR(e,t,n,i,r,s){const a=le("CheckIcon");return g(),S("div",R({class:["p-checkbox p-component",{"p-checkbox-focused":r.focused}],onClick:t[3]||(t[3]=(...o)=>s.onClick&&s.onClick(...o))},s.getColumnPTOptions("checkboxWrapper")),[f("div",R({class:"p-hidden-accessible"},s.getColumnPTOptions("hiddenInputWrapper")),[f("input",R({ref:"input",type:"checkbox",checked:n.checked,disabled:e.$attrs.disabled,tabindex:e.$attrs.disabled?null:"0","aria-label":s.checkboxAriaLabel,onFocus:t[0]||(t[0]=o=>s.onFocus(o)),onBlur:t[1]||(t[1]=o=>s.onBlur(o)),onKeydown:t[2]||(t[2]=(...o)=>s.onKeydown&&s.onKeydown(...o))},s.getColumnPTOptions("hiddenInput")),null,16,HR)],16),f("div",R({ref:"box",class:["p-checkbox-box p-component",{"p-highlight":n.checked,"p-disabled":e.$attrs.disabled,"p-focus":r.focused}]},s.getColumnPTOptions("checkbox")),[n.rowCheckboxIconTemplate?(g(),Q(_e(n.rowCheckboxIconTemplate),{key:0,checked:n.checked,class:"p-checkbox-icon"},null,8,["checked"])):!n.rowCheckboxIconTemplate&&n.checked?(g(),Q(a,R({key:1,class:"p-checkbox-icon"},s.getColumnPTOptions("checkboxIcon")),null,16)):M("",!0)],16)],16)}Yf.render=zR;var Wf={name:"RowRadioButton",extends:Ve,inheritAttrs:!1,emits:["change"],props:{value:null,checked:null,name:null,column:null},data(){return{focused:!1}},methods:{getColumnPTOptions(e){return this.ptmo(this.getColumnProp(),e,{props:this.column.props,parent:{props:this.$props,state:this.$data},context:{checked:this.checked,focused:this.focused,disabled:this.$attrs.disabled}})},getColumnProp(){return this.column.props&&this.column.props.pt?this.column.props.pt:void 0},onClick(e){this.disabled||this.checked||(this.$emit("change",{originalEvent:e,data:this.value}),F.focus(this.$refs.input))},onFocus(){this.focused=!0},onBlur(){this.focused=!1}}};const KR=["checked","disabled","name"];function GR(e,t,n,i,r,s){return g(),S("div",R({class:["p-radiobutton p-component",{"p-radiobutton-focused":r.focused}],onClick:t[3]||(t[3]=(...a)=>s.onClick&&s.onClick(...a))},s.getColumnPTOptions("radiobuttonWrapper")),[f("div",R({class:"p-hidden-accessible"},e.ptm("hiddenInputWrapper")),[f("input",R({ref:"input",type:"radio",checked:n.checked,disabled:e.$attrs.disabled,name:n.name,tabindex:"0",onFocus:t[0]||(t[0]=a=>s.onFocus(a)),onBlur:t[1]||(t[1]=a=>s.onBlur(a)),onKeydown:t[2]||(t[2]=Je(st((...a)=>s.onClick&&s.onClick(...a),["prevent"]),["space"]))},s.getColumnPTOptions("hiddenInput")),null,16,KR)],16),f("div",R({ref:"box",class:["p-radiobutton-box p-component",{"p-highlight":n.checked,"p-disabled":e.$attrs.disabled,"p-focus":r.focused}]},s.getColumnPTOptions("radiobutton")),[f("div",R({class:"p-radiobutton-icon"},s.getColumnPTOptions("radiobuttonIcon")),null,16)],16)],16)}Wf.render=GR;var Qf={name:"BodyCell",extends:Ve,emits:["cell-edit-init","cell-edit-complete","cell-edit-cancel","row-edit-init","row-edit-save","row-edit-cancel","row-toggle","radio-ch
700ange","checkbox-change","editing-meta-change"],props:{rowData:{type:Object,default:null},column:{type:Object,default:null},frozenRow:{type:Boolean,default:!1},rowIndex:{type:Number,default:null},index:{type:Number,default:null},isRowExpanded:{type:Boolean,default:!1},selected:{type:Boolean,default:!1},editing:{type:Boolean,default:!1},editingMeta:{type:Object,default:null},editMode:{type:String,default:null},responsiveLayout:{type:String,default:"stack"},virtualScrollerContentProps:{type:Object,default:null},ariaControls:{type:String,default:null},name:{type:String,default:null},expandedRowIcon:{type:String,default:null},collapsedRowIcon:{type:String,default:null}},documentEditListener:null,selfClick:!1,overlayEventListener:null,data(){return{d_editing:this.editing,styleObject:{}}},watch:{editing(e){this.d_editing=e},"$data.d_editing":function(e){this.$emit("editing-meta-change",{data:this.rowData,field:this.field||`field_${this.index}`,index:this.rowIndex,editing:e})}},mounted(){this.columnProp("frozen")&&this.updateStickyPosition()},updated(){this.columnProp("frozen")&&this.updateStickyPosition(),this.d_editing&&(this.editMode==="cell"||this.editMode==="row"&&this.columnProp("rowEditor"))&&setTimeout(()=>{const e=F.getFirstFocusableElement(this.$el);e&&e.focus()},1)},beforeUnmount(){this.overlayEventListener&&(Mt.off("overlay-click",this.overlayEventListener),this.overlayEventListener=null)},methods:{columnProp(e){return ve.getVNodeProp(this.column,e)},getColumnPTOptions(e,t){return this.ptmo(this.getColumnProp(e),t,{props:e.props,parent:{props:this.$props,state:this.$data}})},getColumnProp(e){return e.props&&e.props.pt?e.props.pt:void 0},resolveFieldData(){return ve.resolveFieldData(this.rowData,this.field)},toggleRow(e){this.$emit("row-toggle",{originalEvent:e,data:this.rowData})},toggleRowWithRadio(e,t){this.$emit("radio-change",{originalEvent:e.originalEvent,index:t,data:e.data})},toggleRowWithCheckbox(e,t){this.$emit("checkbox-change",{originalEvent:e.originalEvent,index:t,data:e.data})},isEditable(){return this.column.children&&this.column.children.editor!=null},bindDocumentEditListener(){this.documentEditListener||(this.documentEditListener=e=>{this.selfClick||this.completeEdit(e,"outside"),this.selfClick=!1},document.addEventListener("click",this.documentEditListener))},unbindDocumentEditListener(){this.documentEditListener&&(document.removeEventListener("click",this.documentEditListener),this.documentEditListener=null,this.selfClick=!1)},switchCellToViewMode(){this.d_editing=!1,this.unbindDocumentEditListener(),Mt.off("overlay-click",this.overlayEventListener),this.overlayEventListener=null},onClick(e){this.editMode==="cell"&&this.isEditable()&&(this.selfClick=!0,this.d_editing||(this.d_editing=!0,this.bindDocumentEditListener(),this.$emit("cell-edit-init",{originalEvent:e,data:this.rowData,field:this.field,index:this.rowIndex}),this.overlayEventListener=t=>{this.$el&&this.$el.contains(t.target)&&(this.selfClick=!0)},Mt.on("overlay-click",this.overlayEventListener)))},completeEdit(e,t){const n={originalEvent:e,data:this.rowData,newData:this.editingRowData,value:this.rowData[this.field],newValue:this.editingRowData[this.field],field:this.field,index:this.rowIndex,type:t,defaultPrevented:!1,preventDefault:function(){this.defaultPrevented=!0}};this.$emit("cell-edit-complete",n),n.defaultPrevented||this.switchCellToViewMode()},onKeyDown(e){if(this.editMode==="cell")switch(e.code){case"Enter":this.completeEdit(e,"enter");break;case"Escape":this.switchCellToViewMode(),this.$emit("cell-edit-cancel",{originalEvent:e,data:this.rowData,field:this.field,index:this.rowIndex});break;case"Tab":this.completeEdit(e,"tab"),e.shiftKey?this.moveToPreviousCell(e):this.moveToNextCell(e);break}},moveToPreviousCell(e){let t=this.findCell(e.target),n=this.findPreviousEditableColumn(t);n&&(F.invokeElementMethod(n,"click"),e.preventDefault())}
700,moveToNextCell(e){let t=this.findCell(e.target),n=this.findNextEditableColumn(t);n&&(F.invokeElementMethod(n,"click"),e.preventDefault())},findCell(e){if(e){let t=e;for(;t&&!F.hasClass(t,"p-cell-editing");)t=t.parentElement;return t}else return null},findPreviousEditableColumn(e){let t=e.previousElementSibling;if(!t){let n=e.parentElement.previousElementSibling;n&&(t=n.lastElementChild)}return t?F.hasClass(t,"p-editable-column")?t:this.findPreviousEditableColumn(t):null},findNextEditableColumn(e){let t=e.nextElementSibling;if(!t){let n=e.parentElement.nextElementSibling;n&&(t=n.firstElementChild)}return t?F.hasClass(t,"p-editable-column")?t:this.findNextEditableColumn(t):null},isEditingCellValid(){return F.find(this.$el,".p-invalid").length===0},onRowEditInit(e){this.$emit("row-edit-init",{originalEvent:e,data:this.rowData,newData:this.editingRowData,field:this.field,index:this.rowIndex})},onRowEditSave(e){this.$emit("row-edit-save",{originalEvent:e,data:this.rowData,newData:this.editingRowData,field:this.field,index:this.rowIndex})},onRowEditCancel(e){this.$emit("row-edit-cancel",{originalEvent:e,data:this.rowData,newData:this.editingRowData,field:this.field,index:this.rowIndex})},editorInitCallback(e){this.$emit("row-edit-init",{originalEvent:e,data:this.rowData,newData:this.editingRowData,field:this.field,index:this.rowIndex})},editorSaveCallback(e){this.editMode==="row"?this.$emit("row-edit-save",{originalEvent:e,data:this.rowData,newData:this.editingRowData,field:this.field,index:this.rowIndex}):this.completeEdit(e,"enter")},editorCancelCallback(e){this.editMode==="row"?this.$emit("row-edit-cancel",{originalEvent:e,data:this.rowData,newData:this.editingRowData,field:this.field,index:this.rowIndex}):(this.switchCellToViewMode(),this.$emit("cell-edit-cancel",{originalEvent:e,data:this.rowData,field:this.field,index:this.rowIndex}))},updateStickyPosition(){if(this.columnProp("frozen"))if(this.columnProp("alignFrozen")==="right"){let t=0,n=this.$el.nextElementSibling;n&&(t=F.getOuterWidth(n)+parseFloat(n.style.right||0)),this.styleObject.right=t+"px"}else{let t=0,n=this.$el.previousElementSibling;n&&(t=F.getOuterWidth(n)+parseFloat(n.style.left||0)),this.styleObject.left=t+"px"}},getVirtualScrollerProp(e){return this.virtualScrollerContentProps?this.virtualScrollerContentProps[e]:null}},computed:{editingRowData(){return this.editingMeta[this.rowIndex]?this.editingMeta[this.rowIndex].data:this.rowData},field(){return this.columnProp("field")},containerClass(){return[this.columnProp("bodyClass"),this.columnProp("class"),{"p-selection-column":this.columnProp("selectionMode")!=null,"p-editable-column":this.isEditable(),"p-cell-editing":this.d_editing,"p-frozen-column":this.columnProp("frozen")}]},containerStyle(){let e=this.columnProp("bodyStyle"),t=this.columnProp("style");return this.columnProp("frozen")?[t,e,this.styleObject]:[t,e]},loading(){return this.getVirtualScrollerProp("loading")},loadingOptions(){const e=this.getVirtualScrollerProp("getLoaderOptions");return e&&e(this.rowIndex,{cellIndex:this.index,cellFirst:this.index===0,cellLast:this.index===this.getVirtualScrollerProp("columns").length-1,cellEven:this.index%2===0,cellOdd:this.index%2!==0,column:this.column,field:this.field})},expandButtonAriaLabel(){return this.$primevue.config.locale.aria?this.isRowExpanded?this.$primevue.config.locale.aria.expandRow:this.$primevue.config.locale.aria.collapseRow:void 0},initButtonAriaLabel(){return this.$primevue.config.locale.aria?this.$primevue.config.locale.aria.editRow:void 0},saveButtonAriaLabel(){return this.$primevue.config.locale.aria?this.$primevue.config.locale.aria.saveEdit:void 0},cancelButtonAriaLabel(){return this.$primevue.config.locale.aria?this.$primevue.config.locale.aria.cancelEdit:void 0}},components:{DTRadioButton:Wf,DTCheckbox:Yf,ChevronDownIcon:_n,ChevronRightIcon:Rn,BarsIcon:zf,PencilIcon:Kf,CheckIcon:yn,TimesIcon:Qt},directives:{ripple:gt}};const jR=["aria-expanded","aria-controls","aria-label"],YR=["aria-label"],WR=["aria-label"],QR=["aria-label"];function ZR(e,t,n,i,r,s){const a=le("DTRadioButton"),o=le("DTCheckbox"),l=le("ChevronDownIcon"),c=le("ChevronRightIcon"),d=Xe("ripple");return s.loading?(g(),S("td",R({key:0,style:s.containerStyle,class:s.containerClass,role:"cell"},{...s.getColumnPTOptions(n.column,"root"),...s.getColumnPTOptions(n.column,"bodyCell")}),[(g(),Q(_e(n.column.children.loading),{data:n.rowData,column:n.column,field:s.field,index:n.rowIndex,frozenRow:n.frozenRow,loadingOptions:s.loadingOptions},null,8,["data","column","field","index","frozenRow","loadingOptions"]))],16)):(g(),S("td",R({key:1,style:s.containerStyle,class:s.containerClass,onClick:t[6]||(t[6]=(...u)=>s.onClick&&s.onClick(...u)),onKeydown:t[7]||(t[7]=(...u)=>s.onKeyDown&&s.onKeyDown(...u)),role:"cell"},{...s.getColumnPTOptions(n.column,"root"),...s.getColumnPTOptions(n.column,"bodyCell")}),[n.responsiveLayout==="stack"?(g(),S("span",R({key:0,class:"p-column-title"},s.getColumnPTOptions(n.column,"columnTitle")),N(s.columnProp("header")),17)):M("",!0),n.column.children&&n.column.children.body&&!r.d_editing?(g(),Q(_e(n.column.children.body),{key:1,data:n.rowData,column:n.column,field:s.field,index:n.rowIndex,frozenRow:n.frozenRow,editorInitCallback:s.editorInitCallback},null,8,["data","column","field","index","frozenRow","editorInitCallback"])):n.column.children&&n.column.children.editor&&r.d_editing?(g(),Q(_e(n.column.children.editor),{key:2,data:s.editingRowData,column:n.column,field:s.field,index:n.rowIndex,frozenRow:n.frozenRow,editorSaveCallback:s.editorSaveCallback,editorCancelCallback:s.editorCancelCallback},null,8,["data","column","field","index","frozenRow","editorSaveCallback","editorC
700ancelCallback"])):n.column.children&&n.column.children.body&&!n.column.children.editor&&r.d_editing?(g(),Q(_e(n.column.children.body),{key:3,data:s.editingRowData,column:n.column,field:s.field,index:n.rowIndex,frozenRow:n.frozenRow},null,8,["data","column","field","index","frozenRow"])):s.columnProp("selectionMode")?(g(),S(J,{key:4},[s.columnProp("selectionMode")==="single"?(g(),Q(a,{key:0,value:n.rowData,name:n.name,checked:n.selected,onChange:t[0]||(t[0]=u=>s.toggleRowWithRadio(u,n.rowIndex)),column:n.column,pt:e.pt},null,8,["value","name","checked","column","pt"])):s.columnProp("selectionMode")==="multiple"?(g(),Q(o,{key:1,value:n.rowData,checked:n.selected,rowCheckboxIconTemplate:n.column.children&&n.column.children.rowcheckboxicon,"aria-selected":n.selected?!0:void 0,onChange:t[1]||(t[1]=u=>s.toggleRowWithCheckbox(u,n.rowIndex)),column:n.column,pt:e.pt},null,8,["value","checked","rowCheckboxIconTemplate","aria-selected","column","pt"])):M("",!0)],64)):s.columnProp("rowReorder")?(g(),Q(_e(n.column.children&&n.column.children.rowreordericon?n.column.children.rowreordericon:s.columnProp("rowReorderIcon")?"i":"BarsIcon"),{key:5,class:Oe(["p-datatable-reorderablerow-handle",s.columnProp("rowReorderIcon")])},null,8,["class"])):s.columnProp("expander")?Ne((g(),S("button",R({key:6,class:"p-row-toggler p-link",type:"button","aria-expanded":n.isRowExpanded,"aria-controls":n.ariaControls,"aria-label":s.expandButtonAriaLabel,onClick:t[2]||(t[2]=(...u)=>s.toggleRow&&s.toggleRow(...u))},s.getColumnPTOptions(n.column,"rowToggler")),[n.column.children&&n.column.children.rowtogglericon?(g(),Q(_e(n.column.children.rowtogglericon),{key:0,rowExpanded:n.isRowExpanded},null,8,["rowExpanded"])):(g(),S(J,{key:1},[n.isRowExpanded&&n.expandedRowIcon?(g(),S("span",{key:0,class:Oe(["p-row-toggler-icon",n.expandedRowIcon])},null,2)):n.isRowExpanded&&!n.expandedRowIcon?(g(),Q(l,R({key:1,class:"p-row-toggler-icon"},s.getColumnPTOptions(n.column,"rowTogglerIcon")),null,16)):!n.isRowExpanded&&n.collapsedRowIcon?(g(),S("span",{key:2,class:Oe(["p-row-toggler-icon",n.collapsedRowIcon])},null,2)):!n.isRowExpanded&&!n.collapsedRowIcon?(g(),Q(c,R({key:3,class:"p-row-toggler-icon"},s.getColumnPTOptions(n.column,"rowTogglerIcon")),null,16)):M("",!0)],64))],16,jR)),[[d]]):n.editMode==="row"&&s.columnProp("rowEditor")?(g(),S(J,{key:7},[r.d_editing?M("",!0):Ne((g(),S("button",R({key:0,class:"p-row-editor-init p-link",type:"button","aria-label":s.initButtonAriaLabel,onClick:t[3]||(t[3]=(...u)=>s.onRowEditInit&&s.onRowEditInit(...u))},s.getColumnPTOptions(n.column,"rowEditorInitButton")),[(g(),Q(_e(n.column.children&&n.column.children.roweditoriniticon||"PencilIcon"),R({class:"p-row-editor-init-icon"},s.getColumnPTOptions(n.column,"rowEditorInitIcon")),null,16))],16,YR)),[[d]]),r.d_editing?Ne((g(),S("button",R({key:1,class:"p-row-editor-save p-link",type:"button","aria-label":s.saveButtonAriaLabel,onClick:t[4]||(t[4]=(...u)=>s.onRowEditSave&&s.onRowEditSave(...u))},s.getColumnPTOptions(n.column,"rowEditorEditButton")),[(g(),Q(_e(n.column.children&&n.column.children.roweditorsaveicon||"CheckIcon"),R({class:"p-row-editor-save-icon"},s.getColumnPTOptions(n.column,"rowEditorEditIcon")),null,16))],16,WR)),[[d]]):M("",!0),r.d_editing?Ne((g(),S("button",R({key:2,class:"p-row-editor-cancel p-link",type:"button","aria-label":s.cancelButtonAriaLabel,onClick:t[5]||(t[5]=(...u)=>s.onRowEditCancel&&s.onRowEditCancel(...u))},s.getColumnPTOptions(n.column,"rowEditorCancelButton")),[(g(),Q(_e(n.column.children&&n.column.children.roweditorcancelicon||"TimesIcon"),R({class:"p-row-editor-cancel-icon"},s.getColumnPTOptions(n.column,"rowEditorCancelIcon")),null,16))],16,QR)),[[d]]):M("",!0)],64)):(g(),S(J,{key:8},[ke(N(s.resolveFieldData()),1)],64))],16))}Qf.render=ZR;var Zf={name:"TableBody",extends:Ve,emits:["rowgroup-toggle","row-click","row-dblclick","row-rightclick","row-touchend","row-keydown","row-mousedown","row-dragstart","row-dragover","row-dragleave","row-dragend","row-drop","row-toggle","radio-ch
700ange","checkbox-change","cell-edit-init","cell-edit-complete","cell-edit-cancel","row-edit-init","row-edit-save","row-edit-cancel","editing-meta-change"],props:{value:{type:Array,default:null},columns:{type:null,default:null},frozenRow:{type:Boolean,default:!1},empty:{type:Boolean,default:!1},rowGroupMode:{type:String,default:null},groupRowsBy:{type:[Array,String,Function],default:null},expandableRowGroups:{type:Boolean,default:!1},expandedRowGroups:{type:Array,default:null},first:{type:Number,default:0},dataKey:{type:String,default:null},expandedRowIcon:{type:String,default:null},collapsedRowIcon:{type:String,default:null},expandedRows:{type:Array,default:null},expandedRowKeys:{type:null,default:null},selection:{type:[Array,Object],default:null},selectionKeys:{type:null,default:null},selectionMode:{type:String,default:null},contextMenu:{type:Boolean,default:!1},contextMenuSelection:{type:Object,default:null},rowClass:{type:null,default:null},rowStyle:{type:null,default:null},editMode:{type:String,default:null},compareSelectionBy:{type:String,default:"deepEquals"},editingRows:{type:Array,default:null},editingRowKeys:{type:null,default:null},editingMeta:{type:Object,default:null},templates:{type:null,default:null},scrollable:{type:Boolean,default:!1},responsiveLayout:{type:String,default:"stack"},virtualScrollerContentProps:{type:Object,default:null},isVirtualScrollerDisabled:{type:Boolean,default:!1}},data(){return{rowGroupHeaderStyleObject:{},tabindexArray:[],isARowSelected:!1}},mounted(){this.frozenRow&&this.updateFrozenRowStickyPosition(),this.scrollable&&this.rowGroupMode==="subheader"&&this.updateFrozenRowGroupHeaderStickyPosition()},updated(){this.frozenRow&&this.updateFrozenRowStickyPosition(),this.scrollable&&this.rowGroupMode==="subheader"&&this.updateFrozenRowGroupHeaderStickyPosition()},methods:{columnProp(e,t){return ve.getVNodeProp(e,t)},getColumnPTOptions(e,t){return this.ptmo(this.getColumnProp(e),t,{props:e.props,parent:{props:this.$props,state:this.$data}})},getColumnProp(e){return e.props&&e.props.pt?e.props.pt:void 0},shouldRenderRowGroupHeader(e,t,n){let i=ve.resolveFieldData(t,this.groupRowsBy),r=e[n-1];if(r){let s=ve.resolveFieldData(r,this.groupRowsBy);return i!==s}else return!0},getRowKey(e,t){return this.dataKey?ve.resolveFieldData(e,this.dataKey):this.getRowIndex(t)},getRowIndex(e){const t=this.getVirtualScrollerProp("getItemOptions");return t?t(e).index:this.first+e},getRowStyle(e){if(this.rowStyle)return this.rowStyle(e)},getRowClass(e){let t=[];if(this.selectionMode&&t.push("p-selectable-row"),this.selection&&t.push({"p-highlight":this.isSelected(e)}),this.contextMenuSelection&&t.push({"p-highlight-contextmenu":this.isSelectedWithContextMenu(e)}),this.rowClass){let n=this.rowClass(e);n&&t.push(n)}return t},shouldRenderRowGroupFooter(e,t,n){if(this.expandableRowGroups&&!this.isRowGroupExpanded(t))return!1;{let i=ve.resolveFieldData(t,this.groupRowsBy),r=e[n+1];if(r){let s=ve.resolveFieldData(r,this.groupRowsBy);return i!==s}else return!0}},shouldRenderBodyCell(e,t,n){if(this.rowGroupMode){if(this.rowGroupMode==="subheader")return this.groupRowsBy!==this.columnProp(t,"field");if(this.rowGroupMode==="rowspan")if(this.isGrouped(t)){let i=e[n-1];if(i){let r=ve.resolveFieldData(e[n],this.columnProp(t,"field")),s=ve.resolveFieldData(i,this.columnProp(t,"field"));return r!==s}else return!0}else return!0}else return!this.columnProp(t,"hidden")},calculateRowGroupSize(e,t,n){if(this.isGrouped(t)){let i=ve.resolveFieldData(e[n],this.columnProp(t,"field")),r=i,s=0;for(;i===r;){s++;let a=e[++n];if(a)r=ve.resolveFieldData(a,this.columnProp(t,"field"));else break}return s===1?null:s}else return null},isGrouped(e){return this.groupRowsBy&&this.columnProp(e,"field")?Array.isArray(this.groupRowsBy)?this.groupRowsBy.indexOf(e.props.field)>-1:this.groupRowsBy===e.props.field:!1},isRowEditing(e){return e&&this.editingRows?this.dataKey?this.editingRowKeys?this.editingRowKeys[ve.resolveFieldData(e,this.dataKey)]!==void 0:!1:this.findIndex(e,this.editingRows)>-1:!1},isRowExpanded(e){return e&&this.expandedRows?this.dataKey?this.expandedRowKeys?this.expandedRowKeys[ve.resolveFieldData(e,this.dataKey)]!==void 0:!1:this.findIndex(e,this.expandedRows)>-1:!1},isRowGroupExpanded(e){if(this.expandableRowGroups&&this.expandedRowGroups){let t=ve.resolveFieldData(e,this.groupRowsBy);return this.expandedRowGroups.indexOf(t)>-1}return!1},isSelected(e){return e&&this.selection?this.dataKey?this.selectionKeys?this.selectionKeys[ve.resolveFieldData(e,this.dataKey)]!==void 0:!1:this.selection instanceof Array?this.findIndexInSelection(e)>-1:this.equals(e,this.selection):!1},isSelectedWithContextMenu(e){return e&&this.contextMenuSelection?this.equals(e,this.contextMenuSelection,this.dataKey):!1},findIndexInSelection(e){return this.findIndex(e,this.selection)},findIndex(e,t){let n=-1;if(t&&t.length){for(let i=0;i<t.length;i++)if(this.equals(e,t[i])){n=i;break}}return n},equals(e,t){return this.compareSelectionBy==="equals"?e===t:ve.equals(e,t,this.dataKey)},onRowGroupToggle(e,t){this.$emit("rowgroup-toggle",{originalEvent:e,data:t})},onRowClick(e,t,n){this.$emit("row-click",{originalEvent:e,data:t,index:n})},onRowDblClick(e,t,n){this.$emit("row-dblclick",{originalEvent:e,data:t,index:n})},onRowRightClick(e,t,n){this.$emit("row-rightclick",{originalEvent:e,data:t,index:n})},onRowTouchEnd(e){this.$emit("row-touchend",e)},onRowKeyDown(e,t,n){this.$emit("row-keydown",{originalEvent:e,data:t,index:n})},onRowMouseDown(e){this.$emit("row-mousedown",e)},onRowDragStart(e,t){this.$emit("row-dragstart",{originalEvent:e,index:t})},onRowDragOver(e,t){this.$emit("row-dragover",{originalEvent:e,index:t})},onRowDragLeave(e){this.$emit("row-dragleave",e)},onRowDragEnd(e){this.$emit("row-dragend",e)},onRowDrop(e){this.$emit("row-drop",e)},onRowToggle(e){this.$emit("row-toggle",e)}
700,onRadioChange(e){this.$emit("radio-change",e)},onCheckboxChange(e){this.$emit("checkbox-change",e)},onCellEditInit(e){this.$emit("cell-edit-init",e)},onCellEditComplete(e){this.$emit("cell-edit-complete",e)},onCellEditCancel(e){this.$emit("cell-edit-cancel",e)},onRowEditInit(e){this.$emit("row-edit-init",e)},onRowEditSave(e){this.$emit("row-edit-save",e)},onRowEditCancel(e){this.$emit("row-edit-cancel",e)},onEditingMetaChange(e){this.$emit("editing-meta-change",e)},updateFrozenRowStickyPosition(){this.$el.style.top=F.getOuterHeight(this.$el.previousElementSibling)+"px"},updateFrozenRowGroupHeaderStickyPosition(){let e=F.getOuterHeight(this.$el.previousElementSibling);this.rowGroupHeaderStyleObject.top=e+"px"},getVirtualScrollerProp(e,t){return t=t||this.virtualScrollerContentProps,t?t[e]:null},bodyRef(e){const t=this.getVirtualScrollerProp("contentRef");t&&t(e)},setRowTabindex(e){return this.selection===null&&(this.selectionMode==="single"||this.selectionMode==="multiple")&&e===0?0:-1}},computed:{columnsLength(){let e=0;return this.columns.forEach(t=>{this.columnProp(t,"selectionMode")==="single"&&e--,this.columnProp(t,"hidden")&&e++}),this.columns?this.columns.length-e:0},rowGroupHeaderStyle(){return this.scrollable?{top:this.rowGroupHeaderStyleObject.top}:null},bodyStyle(){return this.getVirtualScrollerProp("contentStyle")},expandedRowId(){return pt()},nameAttributeSelector(){return pt()}},components:{DTBodyCell:Qf,ChevronDownIcon:_n,ChevronRightIcon:Rn}};const qR=["colspan"],JR=["onClick"],XR=["tabindex","aria-selected","onClick","onDblclick","onContextmenu","onKeydown","onDragstart","onDragover"],e3=["id"],t3=["colspan"],n3=["colspan"],s3=["colspan"];function i3(e,t,n,i,r,s){const a=le("ChevronDownIcon"),o=le("ChevronRightIcon"),l=le("DTBodyCell");return g(),S("tbody",R({ref:s.bodyRef,class:"p-datatable-tbody",role:"rowgroup",style:s.bodyStyle},e.ptm("tbody")),[n.empty?(g(),S("tr",R({key:1,class:"p-datatable-emptymessage",role:"row"},e.ptm("emptyMessage")),[f("td",R({colspan:s.columnsLength},{...s.getColumnPTOptions("root"),...s.getColumnPTOptions("bodyCell")}),[n.templates.empty?(g(),Q(_e(n.templates.empty),{key:0})):M("",!0)],16,s3)],16)):(g(!0),S(J,{key:0},ye(n.value,(c,d)=>(g(),S(J,null,[n.templates.groupheader&&n.rowGroupMode==="subheader"&&s.shouldRenderRowGroupHeader(n.value,c,s.getRowIndex(d))?(g(),S("tr",R({key:s.getRowKey(c,s.getRowIndex(d))+"_subheader",class:"p-rowgroup-header",style:s.rowGroupHeaderStyle,role:"row"},e.ptm("rowgroupHeader")),[f("td",R({colspan:s.columnsLength-1},{...s.getColumnPTOptions("root"),...s.getColumnPTOptions("bodyCell")}),[n.expandableRowGroups?(g(),S("button",R({key:0,class:"p-row-toggler p-link",onClick:u=>s.onRowGroupToggle(u,c),type:"button"},s.getColumnPTOptions("rowGroupToggler")),[n.templates.rowgrouptogglericon?(g(),Q(_e(n.templates.rowgrouptogglericon),{key:0,expanded:s.isRowGroupExpanded(c)},null,8,["expanded"])):(g(),S(J,{key:1},[s.isRowGroupExpanded(c)&&n.expandedRowIcon?(g(),S("span",{key:0,class:Oe(["p-row-toggler-icon",n.expandedRowIcon])},null,2)):s.isRowGroupExpanded(c)&&!n.expandedRowIcon?(g(),Q(a,R({key:1,class:"p-row-toggler-icon"},s.getColumnPTOptions("rowGroupTogglerIcon")),null,16)):!s.isRowGroupExpanded(c)&&n.collapsedRowIcon?(g(),S("span",{key:2,class:Oe(["p-row-toggler-icon",n.collapsedRowIcon])},null,2)):!s.isRowGroupExpanded(c)&&!n.collapsedRowIcon?(g(),Q(o,R({key:3,class:"p-row-toggler-icon"},s.getColumnPTOptions("rowGroupTogglerIcon")),null,16)):M("",!0)],64))],16,JR)):M("",!0),(g(),Q(_e(n.templates.groupheader),{data:c,index:s.getRowIndex(d)},null,8,["data","index"]))],16,qR)],16)):M("",!0),!n.expandableRowGroups||s.isRowGroupExpanded(c)?(g(),S("tr",R({key:s.getRowKey(c,s.getRowIndex(d)),class:s.getRowClass(c),style:s.getRowStyle(c),tabindex:s.setRowTabindex(d),role:"row","aria-selected":n.selectionMode?s.isSelected(c):null,onClick:u=>s.onRowClick(u,c,s.getRowIndex(d)),onDblclick:u=>s.onRowDblClick(u,c,s.getRowIndex(d)),onContextmenu:u=>s.onRowRightClick(u,c,s.getRowIndex(d)),onTouchend:t[9]||(t[9]=u=>s.onRowTouchEnd(u)),onKeydown:u=>s.onRowKeyDown(u,c,s.getRowIndex(d)),onMousedown:t[10]||(t[10]=u=>s.onRowMouseDown(u)),onDragstart:u=>s.onRowDragStart(u,s.getRowIndex(d)),onDragover:u=>s.onRowDragOver(u,s.getRowIndex(d)),onDragleave:t[11]||(t[11]=u=>s.onRowDragLeave(u)),onDragend:t[12]||(t[12]=u=>s.onRowDragEnd(u)),onDrop:t[13]||(t[13]=u=>s.onRowDrop(u))},e.ptm("row")),[(g(!0),S(J,null,ye(n.columns,(u,p)=>(g(),S(J,null,[s.shouldRenderBodyCell(n.value,u,s.getRowIndex(d))?(g(),Q(l,{key:s.columnProp(u,"columnKey")||s.c
700olumnProp(u,"field")||p,rowData:c,column:u,rowIndex:s.getRowIndex(d),index:p,selected:s.isSelected(c),frozenRow:n.frozenRow,rowspan:n.rowGroupMode==="rowspan"?s.calculateRowGroupSize(n.value,u,s.getRowIndex(d)):null,editMode:n.editMode,editing:n.editMode==="row"&&s.isRowEditing(c),editingMeta:n.editingMeta,responsiveLayout:n.responsiveLayout,virtualScrollerContentProps:n.virtualScrollerContentProps,ariaControls:s.expandedRowId+"_"+d+"_expansion",name:s.nameAttributeSelector,isRowExpanded:s.isRowExpanded(c),expandedRowIcon:n.expandedRowIcon,collapsedRowIcon:n.collapsedRowIcon,onRadioChange:t[0]||(t[0]=h=>s.onRadioChange(h)),onCheckboxChange:t[1]||(t[1]=h=>s.onCheckboxChange(h)),onRowToggle:t[2]||(t[2]=h=>s.onRowToggle(h)),onCellEditInit:t[3]||(t[3]=h=>s.onCellEditInit(h)),onCellEditComplete:t[4]||(t[4]=h=>s.onCellEditComplete(h)),onCellEditCancel:t[5]||(t[5]=h=>s.onCellEditCancel(h)),onRowEditInit:t[6]||(t[6]=h=>s.onRowEditInit(h)),onRowEditSave:t[7]||(t[7]=h=>s.onRowEditSave(h)),onRowEditCancel:t[8]||(t[8]=h=>s.onRowEditCancel(h)),onEditingMetaChange:s.onEditingMetaChange,pt:e.pt},null,8,["rowData","column","rowIndex","index","selected","frozenRow","rowspan","editMode","editing","editingMeta","responsiveLayout","virtualScrollerContentProps","ariaControls","name","isRowExpanded","expandedRowIcon","collapsedRowIcon","onEditingMetaChange","pt"])):M("",!0)],64))),256))],16,XR)):M("",!0),n.templates.expansion&&n.expandedRows&&s.isRowExpanded(c)?(g(),S("tr",R({key:s.getRowKey(c,s.getRowIndex(d))+"_expansion",id:s.expandedRowId+"_"+d+"_expansion",class:"p-datatable-row-expansion",role:"row"},e.ptm("rowExpansion")),[f("td",R({colspan:s.columnsLength},{...s.getColumnPTOptions("root"),...s.getColumnPTOptions("bodyCell")}),[(g(),Q(_e(n.templates.expansion),{data:c,index:s.getRowIndex(d)},null,8,["data","index"]))],16,t3)],16,e3)):M("",!0),n.templates.groupfooter&&n.rowGroupMode==="subheader"&&s.shouldRenderRowGroupFooter(n.value,c,s.getRowIndex(d))?(g(),S("tr",R({key:s.getRowKey(c,s.getRowIndex(d))+"_subfooter",class:"p-rowgroup-footer",role:"row"},e.ptm("rowgroupFooter")),[f("td",R({colspan:s.columnsLength-1},{...s.getColumnPTOptions("root"),...s.getColumnPTOptions("bodyCell")}),[(g(),Q(_e(n.templates.groupfooter),{data:c,index:s.getRowIndex(d)},null,8,["data","index"]))],16,n3)],16)):M("",!0)],64))),256))],16)}Zf.render=i3;var qf={name:"FooterCell",extends:Ve,props:{column:{type:Object,default:null}},data(){return{styleObject:{}}},mounted(){this.columnProp("frozen")&&this.updateStickyPosition()},updated(){this.columnProp("frozen")&&this.updateStickyPosition()},methods:{columnProp(e){return ve.getVNodeProp(this.column,e)},getColumnPTOptions(e){return this.ptmo(this.getColumnProp(),e,{props:this.column.props,parent:{props:this.$props,state:this.$data}})},getColumnProp(){return this.column.props&&this.column.props.pt?this.column.props.pt:void 0},updateStickyPosition(){if(this.columnProp("frozen"))if(this.columnProp("alignFrozen")==="right"){let t=0,n=this.$el.nextElementSibling;n&&(t=F.getOuterWidth(n)+parseFloat(n.style.right||0)),this.styleObject.right=t+"px"}else{let t=0,n=this.$el.previousElementSibling;n&&(t=F.getOuterWidth(n)+parseFloat(n.style.left||0)),this.styleObject.left=t+"px"}}},computed:{containerClass(){return[this.columnProp("footerClass"),this.columnProp("class"),{"p-frozen-column":this.columnProp("frozen")}]},containerStyle(){let e=this.columnProp("footerStyle"),t=this.columnProp("style");return this.columnProp("frozen")?[t,e,this.styleObject]:[t,e]}}};const r3=["colspan","rowspan"];function a3(e,t,n,i,r,s){return g(),S("td",R({style:s.containerStyle,class:s.containerClass,role:"cell",colspan:s.columnProp("colspan"),rowspan:s.columnProp("rowspan")},{...s.getColumnPTOptions("root"),...s.getColumnPTOptions("footerCell")}),[n.column.children&&n.column.children.footer?(g(),Q(_e(n.column.children.footer),{key:0,column:n.column},null,8,["column"])):M("",!0),ke(" "+N(s.columnProp("footer")),1)],16,r3)}qf.render=a3;var Jf={name:"TableFooter",extends:Ve,props:{columnGroup:{type:null,default:null},columns:{type:Object,default:null}},methods:{columnProp(e,t){return ve.getVNodeProp(e,t)},getColumnGroupPTOptions(e){return this.ptmo(this.getColumnGroupProps(),e,{props:this.getColumnGroupProps(),parent:{props:this.$props,state:this.$data}})},getColumnGroupProps(){return this.columnGroup&&this.columnGroup.props&&this.columnGroup.props.pt?this.columnGroup.props.pt:void 0},getRowPTOptions(e,t){return this.ptmo(this.getRowProp(e),t,{props:e.props,parent:{props:this.$props,state:this.$data}})},getRowProp(e){return e.props&&e.props.pt?e.props.pt:void 0},getFooterRows(){let e=[],t=this.columnGroup;if(t.children&&t.children.default){for(let n of t.children.default())n.type.name==="Row"?e.push(n):n.children&&n.children instanceof Array&&(e=n.children);return e}},getFooterColumns(e){let t=[];if(e.children&&e.children.default)return e.children.default().forEac
700h(n=>{n.children&&n.children instanceof Array?t=[...t,...n.children]:n.type.name==="Column"&&t.push(n)}),t}},computed:{hasFooter(){let e=!1;if(this.columnGroup)e=!0;else if(this.columns){for(let t of this.columns)if(this.columnProp(t,"footer")||t.children&&t.children.footer){e=!0;break}}return e}},components:{DTFooterCell:qf}};function o3(e,t,n,i,r,s){const a=le("DTFooterCell");return s.hasFooter?(g(),S("tfoot",R({key:0,class:"p-datatable-tfoot",role:"rowgroup"},{...e.ptm("tfoot"),...s.getColumnGroupPTOptions("root")}),[n.columnGroup?(g(!0),S(J,{key:1},ye(s.getFooterRows(),(o,l)=>(g(),S("tr",R({key:l,role:"row"},s.getRowPTOptions(o,"root")),[(g(!0),S(J,null,ye(s.getFooterColumns(o),(c,d)=>(g(),S(J,{key:s.columnProp(c,"columnKey")||s.columnProp(c,"field")||d},[s.columnProp(c,"hidden")?M("",!0):(g(),Q(a,{key:0,column:c,pt:e.pt},null,8,["column","pt"]))],64))),128))],16))),128)):(g(),S("tr",R({key:0,role:"row"},e.ptm("footerRow")),[(g(!0),S(J,null,ye(n.columns,(o,l)=>(g(),S(J,{key:s.columnProp(o,"columnKey")||s.columnProp(o,"field")||l},[s.columnProp(o,"hidden")?M("",!0):(g(),Q(a,{key:0,column:o,pt:e.pt},null,8,["column","pt"]))],64))),128))],16))],16)):M("",!0)}Jf.render=o3;var Ll={name:"ColumnFilter",extends:Ve,emits:["filter-change","filter-apply","operator-change","matchmode-change","constraint-add","constraint-remove","filter-clear","apply-click"],props:{field:{type:String,default:null},type:{type:String,default:"text"},display:{type:String,default:null},showMenu:{type:Boolean,default:!0},matchMode:{type:String,default:null},showOperator:{type:Boolean,default:!0},showClearButton:{type:Boolean,default:!0},showApplyButton:{type:Boolean,default:!0},showMatchModes:{type:Boolean,default:!0},showAddButton:{type:Boolean,default:!0},matchModeOptions:{type:Array,default:null},maxConstraints:{type:Number,default:2},filterElement:{type:Function,default:null},filterHeaderTemplate:{type:Function,default:null},filterFooterTemplate:{type:Function,default:null},filterClearTemplate:{type:Function,default:null},filterApplyTemplate:{type:Function,default:null},filterIconTemplate:{type:Function,default:null},filterAddIconTemplate:{type:Function,default:null},filterRemoveIconTemplate:{type:Function,default:null},filterClearIconTemplate:{type:Function,default:null},filters:{type:Object,default:null},filtersStore:{type:Object,default:null},filterMenuClass:{type:String,default:null},filterMenuStyle:{type:null,default:null},filterInputProps:{type:null,default:null},column:null},data(){return{overlayVisible:!1,defaultMatchMode:null,defaultOperator:null}},overlay:null,selfClick:!1,overlayEventListener:null,beforeUnmount(){this.overlayEventListener&&(Mt.off("overlay-click",this.overlayEventListener),this.overlayEventListener=null),this.overlay&&(He.clear(this.overlay),this.onOverlayHide())},mounted(){if(this.filters&&this.filters[this.field]){let e=this.filters[this.field];e.operator?(this.defaultMatchMode=e.constraints[0].matchMode,this.defaultOperator=e.operator):this.defaultMatchMode=this.filters[this.field].matchMode}},methods:{getColumnPTOptions(e){return this.ptmo(this.getColumnProp(),e,{props:this.column.props,parent:{props:this.$props,state:this.$data}})},getColumnProp(){return this.column.props&&this.column.props.pt?this.column.props.pt:void 0},clearFilter(){let e={...this.filters};e[this.field].operator?(e[this.field].constraints.splice(1),e[this.field].operator=this.defaultOperator,e[this.field].constraints[0]={value:null,matchMode:this.defaultMatchMode}):(e[this.field].value=null,e[this.field].matchMode=this.defaultMatchMode),this.$emit("filter-clear"),this.$emit("filter-change",e),this.$emit("filter-appl
700y"),this.hide()},applyFilter(){this.$emit("apply-click",{field:this.field,constraints:this.filters[this.field]}),this.$emit("filter-apply"),this.hide()},hasFilter(){if(this.filtersStore){let e=this.filtersStore[this.field];if(e)return e.operator?!this.isFilterBlank(e.constraints[0].value):!this.isFilterBlank(e.value)}return!1},hasRowFilter(){return this.filters[this.field]&&!this.isFilterBlank(this.filters[this.field].value)},isFilterBlank(e){return e!=null?typeof e=="string"&&e.trim().length==0||e instanceof Array&&e.length==0:!0},toggleMenu(){this.overlayVisible=!this.overlayVisible},onToggleButtonKeyDown(e){switch(e.code){case"Enter":case"Space":this.toggleMenu(),e.preventDefault();break;case"Escape":this.overlayVisible=!1;break}},onRowMatchModeChange(e){let t={...this.filters};t[this.field].matchMode=e,this.$emit("matchmode-change",{field:this.field,matchMode:e}),this.$emit("filter-change",t),this.$emit("filter-apply"),this.hide()},onRowMatchModeKeyDown(e){let t=e.target;switch(e.code){case"ArrowDown":var n=this.findNextItem(t);n&&(t.removeAttribute("tabindex"),n.tabIndex="0",n.focus()),e.preventDefault();break;case"ArrowUp":var i=this.findPrevItem(t);i&&(t.removeAttribute("tabindex"),i.tabIndex="0",i.focus()),e.preventDefault();break}},isRowMatchModeSelected(e){return this.filters[this.field].matchMode===e},onOperatorChange(e){let t={...this.filters};t[this.field].operator=e,this.$emit("filter-change",t),this.$emit("operator-change",{field:this.field,operator:e}
700),this.showApplyButton||this.$emit("filter-apply")},onMenuMatchModeChange(e,t){let n={...this.filters};n[this.field].constraints[t].matchMode=e,this.$emit("matchmode-change",{field:this.field,matchMode:e,index:t}),this.showApplyButton||this.$emit("filter-apply")},addConstraint(){let e={...this.filters},t={value:null,matchMode:this.defaultMatchMode};e[this.field].constraints.push(t),this.$emit("constraint-add",{field:this.field,constraing:t}),this.$emit("filter-change",e),this.showApplyButton||this.$emit("filter-apply")},removeConstraint(e){let t={...this.filters},n=t[this.field].constraints.splice(e,1);this.$emit("constraint-remove",{field:this.field,constraing:n}),this.$emit("filter-change",t),this.showApplyButton||this.$emit("filter-apply")},filterCallback(){this.$emit("filter-apply")},findNextItem(e){let t=e.nextElementSibling;return t?F.hasClass(t,"p-column-filter-separator")?this.findNextItem(t):t:e.parentElement.firstElementChild},findPrevItem(e){let t=e.previousElementSibling;return t?F.hasClass(t,"p-column-filter-separator")?this.findPrevItem(t):t:e.parentElement.lastElementChild},hide(){this.overlayVisible=!1,F.focus(this.$refs.icon)},onContentClick(e){this.selfClick=!0,Mt.emit("overlay-click",{originalEvent:e,target:this.overlay})},onContentMouseDown(){this.selfClick=!0},onOverlayEnter(e){this.filterMenuStyle&&F.applyStyle(this.overlay,this.filterMenuStyle),He.set("overlay",e,this.$primevue.config.zIndex.overlay),F.absolutePosition(this.overlay,this.$refs.icon),this.bindOutsideClickListener(),this.bindScrollListener(),this.bindResizeListener(),this.overlayEventListener=t=>{this.isOutsideClicked(t.target)||(this.selfClick=!0)},Mt.on("overlay-click",this.overlayEventListener)},onOverlayLeave(){this.onOverlayHide()},onOverlayAfterLeave(e){He.clear(e)},onOverlayHide(){this.unbindOutsideClickListener(),this.unbindResizeListener(),this.unbindScrollListener(),this.overlay=null,Mt.off("overlay-click",this.overlayEventListener),this.overlayEventListener=null},overlayRef(e){this.overlay=e},isOutsideClicked(e){return!this.isTargetClicked(e)&&this.overlay&&!(this.overlay.isSameNode(e)||this.overlay.contains(e))},isTargetClicked(e){return this.$refs.icon&&(this.$refs.icon.isSameNode(e)||this.$refs.icon.contains(e))},bindOutsideClickListener(){this.outsideClickListener||(this.outsideClickListener=e=>{this.overlayVisible&&!this.selfClick&&this.isOutsideClicked(e.target)&&(this.overlayVisible=!1),this.selfClick=!1},document.addEventListener("click",this.outsideClickListener))},unbindOutsideClickListener(){this.outsideClickListener&&(document.removeEventListener("click",this.outsideClickListener),this.outsideClickListener=null,this.selfClick=!1)},bindScrollListener(){this.scrollHandler||(this.scrollHandler=new kn(this.$refs.icon,()=>{this.overlayVisible&&this.hide()})),this.scrollHandler.bindScrollListener()},unbindScrollListener(){this.scrollHandler&&this.scrollHandler.unbindScrollListener()},bindResizeListener(){this.resizeListener||(this.resizeListener=()=>{this.overlayVisible&&!F.isTouchDevice()&&this.hide()},window.addEventListener("resize",this.resizeListener))},unbindResizeListener(){this.resizeListener&&(window.removeEventListener("resize",this.resizeListener),this.resizeListener=null)}},computed:{containerClass(){return["p-column-filter p-fluid",{"p-column-filter-row":this.display==="row","p-column-filter-menu":this.display==="menu"}]},overlayClass(){return[this.filterMenuClass,{"p-column-filter-overlay p-component p-fluid":!0,"p-column-filter-overlay-menu":this.display==="menu","p-input-filled":this.$primevue.config.inputStyle==="filled","p-ripple-disabled":this.$primevue.config.ripple===!1}]},showMenuButton(){return this.showMenu&&(this.display==="row"?this.type!=="boolean":!0)},overlayId(){return pt()},matchModes(){return this.matchModeOptions||this.$primevue.config.filterMatchModeOptions[this.type].map(e=>({label:this.$primevue.config.locale[e],value:e}))},isShowMatchModes(){return this.type!=="boolean"&&this.showMatchModes&&this.matchModes},operatorOptions(){return[{label:this.$primevue.config.locale.matchAll,value:_r.AND},{label:this.$primevue.config.locale.matchAny,value:_r.OR}]},noFilterLabel(){return this.$primevue.config.locale?this.$primevue.config.locale.noFilter:void 0},isShowOperator(){return this.showOperator&&this.filters[this.field].operator},operator(){return this.filters[this.field].operator},fieldConstraints(){return this.filters[this.field].constraints||[this.filters[this.field]]},showRemoveIcon(){return this.fieldConstraints.length>1},removeRuleButtonLabel(){return this.$primevue.config.locale?this.$primevue.config.locale.removeRule:void 0},addRuleButtonLabel(){return this.$primevue.config.locale?this.$primevue.config.locale.addRule:void 0},isShowAddConstraint(){return this.showAddButton&&this.filters[this.field].operator&&this.fieldConstraints&&this.fieldConstraints.length<this.maxConstraints},clearButtonLabel(){return this.$primevue.config.locale?this.$primevue.config.locale.clear:void 0},applyButtonLabel(){return this.$primevue.config.locale?this.$primevue.config.locale.apply:void 0},filterMenuButtonAriaLabel(){return this.$primevue.config.locale?this.overlayVisible?this.$primevue.config.locale.showFilterMenu:this.$primevue.config.locale.hideFilterMenu:void 0},filterOperatorAriaLabel(){return this.$primevue.config.locale?this.$primevue.config.locale.filterOperator:void 0},filterConstraintAriaLabel(){return this.$primevue.config.locale?this.$primevue.config.locale.filterConstraint:void 0}},components:{CFDropdown:Ni,CFButton:Qn,Portal:Kt,FilterSlashIcon:Gf,FilterIcon:kl,TrashIcon:jf,PlusIcon:Pl}
700,directives:{focustrap:Fs}};const l3=["aria-label","aria-expanded","aria-controls"],c3=["id","aria-modal"],d3=["onClick","onKeydown","tabindex"];function u3(e,t,n,i,r,s){const a=le("CFDropdown"),o=le("CFButton"),l=le("Portal"),c=Xe("focustrap");return g(),S("div",R({class:s.containerClass},s.getColumnPTOptions("columnFilter")),[n.display==="row"?(g(),S("div",R({key:0,class:"p-fluid p-column-filter-element"},{...n.filterInputProps,...s.getColumnPTOptions("filterInput")}),[(g(),Q(_e(n.filterElement),{field:n.field,filterModel:n.filters[n.field],filterCallback:s.filterCallback},null,8,["field","filterModel","filterCallback"]))],16)):M("",!0),s.showMenuButton?(g(),S("button",R({key:1,ref:"icon",type:"button",class:["p-column-filter-menu-button p-link",{"p-column-filter-menu-button-open":r.overlayVisible,"p-column-filter-menu-button-active":s.hasFilter()}],"aria-label":s.filterMenuButtonAriaLabel,"aria-haspopup":"true","aria-expanded":r.overlayVisible,"aria-controls":s.overlayId,onClick:t[0]||(t[0]=d=>s.toggleMenu()),onKeydown:t[1]||(t[1]=d=>s.onToggleButtonKeyDown(d))},s.getColumnPTOptions("filterMenuButton")),[(g(),Q(_e(n.filterIconTemplate||"FilterIcon")))],16,l3)):M("",!0),n.showClearButton&&n.display==="row"?(g(),S("button",R({key:2,class:[{"p-hidden-space":!s.hasRowFilter()},"p-column-filter-clear-button p-link"],type:"button",onClick:t[2]||(t[2]=d=>s.clearFilter())},s.getColumnPTOptions("headerFilterClearButton")),[(g(),Q(_e(n.filterClearIconTemplate||"FilterSlashIcon"),ft(Tt(s.getColumnPTOptions("filterClearIcon"))),null,16))],16)):M("",!0),de(l,null,{default:Ee(()=>[de($t,{name:"p-connected-overlay",onEnter:s.onOverlayEnter,onLeave:s.onOverlayLeave,onAfterLeave:s.onOverlayAfterLeave},{default:Ee(()=>[r.overlayVisible?Ne((g(),S("div",R({key:0,ref:s.overlayRef,id:s.overlayId,"aria-modal":r.overlayVisible,role:"dialog",class:s.overlayClass,onKeydown:t[10]||(t[10]=Je((...d)=>s.hide&&s.hide(...d),["escape"])),onClick:t[11]||(t[11]=(...d)=>s.onContentClick&&s.onContentClick(...d)),onMousedown:t[12]||(t[12]=(...d)=>s.onContentMouseDown&&s.onContentMouseDown(...d))},s.getColumnPTOptions("filterOverlay")),[(g(),Q(_e(n.filterHeaderTemplate),{field:n.field,filterModel:n.filters[n.field],filterCallback:s.filterCallback},null,8,["field","filterModel","filterCallback"])),n.display==="row"?(g(),S("ul",R({key:0,class:"p-column-filter-row-items"},s.getColumnPTOptions("filterRowItems")),[(g(!0),S(J,null,ye(s.matchModes,(d,u)=>(g(),S("li",R({key:d.label,class:["p-column-filter-row-item",{"p-highlight":s.isRowMatchModeSelected(d.value)}],onClick:p=>s.onRowMatchModeChange(d.value),onKeydown:[t[3]||(t[3]=p=>s.onRowMatchModeKeyDown(p)),Je(st(p=>s.onRowMatchModeChange(d.value),["prevent"]),["enter"])],tabindex:u===0?"0":null},s.getColumnPTOptions("filterRowItem")),N(d.label),17,d3))),128)),f("li",R({class:"p-column-filter-separator"},s.getColumnPTOptions("filterInput")),null,16),f("li",R({class:"p-column-filter-row-item",onClick:t[4]||(t[4]=d=>s.clearFilter()),onKeydown:[t[5]||(t[5]=d=>s.onRowMatchModeKeyDown(d)),t[6]||(t[6]=Je(d=>e.onRowClearItemClick(),["enter"]))]},s.getColumnPTOptions("filterRowItem")),N(s.noFilterLabel),17)],16)):(g(),S(J,{key:1},[s.isShowOperator?(g(),S("div",R({key:0,class:"p-column-filter-operator"},s.getColumnPTOptions("filterOperator")),[de(a,{options:s.operatorOptions,modelValue:s.operator,"aria-label":s.filterOperatorAriaLabel,class:"p-column-filter-operator-dropdown",optionLabel:"label",optionValue:"value","onUpdate:modelValue":t[7]||(t[7]=d=>s.onOperatorChange(d)),pt:s.getColumnPTOptions("filterOperatorDropdown")},null,8,["options","modelValue","aria-label","pt"])],16)):M("",!0),f("div",R({class:"p-column-filter-constraints"},s.getColumnPTOptions("filterConstraints")),[(g(!0),S(J,null,ye(s.fieldConstraints,(d,u)=>(g(),S("div",R({key:u,class:"p-column-filter-constraint"},s.getColumnPTOptions("filterConstraint")),[s.isShowMatchModes?(g(),Q(a,{key:0,options:s.matchModes,modelValue:d.matchMode,class:"p-column-filter-matchmode-dropdown",optionLabel:"label",optionValue:"value","aria-label":s.filterConstraintAriaLabel,"onUpdate:modelValue":p=>s.onMenuMatchModeChange(p,u),pt:s.getColumnPTOptions("filterMatchModeDropdown")},null,8,["options","modelValue","aria-label","onUpdate:modelValue","pt"])):M("",!0),n.display==="menu"?(g(),Q(_e(n.filterElement),{key:1,field:n.field,filterModel:d,filterCallback:s.filterCallback},null,8,["field","filterModel","filterCallback"])):M("",!0),f("div",ft(Tt(s.getColumnPTOptions("filterRemove"))),[s.showRemoveIcon?(g(),Q(o,{key:0,t
700ype:"button",class:"p-column-filter-remove-button p-button-text p-button-danger p-button-sm",onClick:p=>s.removeConstraint(u),label:s.removeRuleButtonLabel,pt:s.getColumnPTOptions("filterRemoveButton")},{icon:Ee(p=>[(g(),Q(_e(n.filterRemoveIconTemplate||"TrashIcon"),R({class:p.class},s.getColumnPTOptions("filterRemoveButton").icon),null,16,["class"]))]),_:2},1032,["onClick","label","pt"])):M("",!0)],16)],16))),128))],16),s.isShowAddConstraint?(g(),S("div",R({key:1,class:"p-column-filter-add-rule"},s.getColumnPTOptions("filterAddRule")),[de(o,{type:"button",label:s.addRuleButtonLabel,iconPos:"left",class:"p-column-filter-add-button p-button-text p-button-sm",onClick:t[8]||(t[8]=d=>s.addConstraint()),pt:s.getColumnPTOptions("filterAddRuleButton")},{icon:Ee(d=>[(g(),Q(_e(n.filterAddIconTemplate||"PlusIcon"),R({class:d.class},s.getColumnPTOptions("filterAddRuleButton").icon),null,16,["class"]))]),_:1},8,["label","pt"])],16)):M("",!0),f("div",R({class:"p-column-filter-buttonbar"},s.getColumnPTOptions("filterButtonbar")),[!n.filterClearTemplate&&n.showClearButton?(g(),Q(o,{key:0,type:"button",class:"p-button-outlined p-button-sm",label:s.clearButtonLabel,onClick:s.clearFilter,pt:s.getColumnPTOptions("filterClearButton")},null,8,["label","onClick","pt"])):(g(),Q(_e(n.filterClearTemplate),{key:1,field:n.field,filterModel:n.filters[n.field],filterCallback:s.clearFilter},null,8,["field","filterModel","filterCallback"])),n.showApplyButton?(g(),S(J,{key:2},[n.filterApplyTemplate?(g(),Q(_e(n.filterApplyTemplate),{key:1,field:n.field,filterModel:n.filters[n.field],filterCallback:s.applyFilter},null,8,["field","filterModel","filterCallback"])):(g(),Q(o,R({key:0,type:"button",class:"p-button-sm",label:s.applyButtonLabel,onClick:t[9]||(t[9]=d=>s.applyFilter())},s.getColumnPTOptions("filterApplyButton")),null,16,["label"]))],64)):M("",!0)],16)],64)),(g(),Q(_e(n.filterFooterTemplate),{field:n.field,filterModel:n.filters[n.field],filterCallback:s.filterCallback},null,8,["field","filterModel","filterCallback"]))],16,c3)),[[c,{autoFocus:!0}]]):M("",!0)]),_:1},8,["onEnter","onLeave","onAfterLeave"])]),_:1})],16)}Ll.render=u3;var Nl={name:"HeaderCheckbox",extends:Ve,emits:["change"],props:{checked:null,disabled:null,column:null,headerCheckboxIconTemplate:{type:Function,default:null}},data(){return{focused:!1}},methods:{getColumnPTOptions(e){return this.ptmo(this.getColumnProp(),e,{props:this.column.props,parent:{props:this.$props,state:this.$data},context:{checked:this.checked,focused:this.focused,disabled:this.disabled}})},getColumnProp(){return this.column.props&&this.column.props.pt?this.column.props.pt:void 0},onClick(e){this.disabled||(this.$emit("change",{originalEvent:e,checked:!this.checked}),F.focus(this.$refs.input))},onFocus(){this.focused=!0},onBlur(){this.focused=!1}},computed:{headerCheckboxAriaLabel(){return this.$primevue.config.locale.aria?this.checked?this.$primevue.config.locale.aria.selectAll:this.$primevue.config.locale.aria.unselectAll:void 0}},components:{CheckIcon:yn}};const h3=["checked","disabled","tabindex","aria-label"];function p3(e,t,n,i,r,s){const a=le("CheckIcon");return g(),S("div",R({class:["p-checkbox p-component",{"p-checkbox-focused":r.focused,"p-disabled":n.disabled}],onClick:t[2]||(t[2]=(...o)=>s.onClick&&s.onClick(...o)),onKeydown:t[3]||(t[3]=Je(st((...o)=>s.onClick&&s.onClick(...o),["prevent"]),["space"]))},s.getColumnPTOptions("headerCheckboxWrapper")),[f("div",R({class:"p-hidden-accessible"},s.getColumnPTOptions("hiddenHeaderInputWrapper")),[f("input",R({ref:"input",type:"checkbox",checked:n.checked,disabled:n.disabled,tabindex:n.disabled?null:"0","aria-label":s.headerCheckboxAriaLabel,onFocus:t[0]||(t[0]=o=>s.onFocus(o)),onBlur:t[1]||(t[1]=o=>s.onBlur(o))},s.getColumnPTOptions("hiddenHeaderInput")),null,16,h3)],16),f("div",R({ref:"box",class:["p-checkbox-box p-component",{"p-highlight":n.checked,"p-disabled":n.disabled,"p-focus":r.focused}]},s.getColumnPTOptions("headerCheckbox")),[n.headerCheckboxIconTemplate?(g(),Q(_e(n.headerCheckboxIconTemplate),{key:0,checked:n.checked,class:"p-checkbox-icon"},null,8,["checked"])):!n.headerCheckboxIconTemplate&&n.checked?(g(),Q(a,R({key:1,class:"p-checkbox-icon"},s.getColumnPTOptions("headerCheckboxIcon")),null,16)):M("",!0)],16)],16)}Nl.render=p3;var Xf={name:"HeaderCell",extends:Ve,emits:["column-click","column-mousedown","column-dragstart","column-dragover","column-dragleave","column-drop","column-resizestart","checkbox-change","filter-change","filter-appl
700y","operator-change","matchmode-change","constraint-add","constraint-remove","filter-clear","apply-click"],props:{column:{type:Object,default:null},resizableColumns:{type:Boolean,default:!1},groupRowsBy:{type:[Array,String,Function],default:null},sortMode:{type:String,default:"single"},groupRowSortField:{type:[String,Function],default:null},sortField:{type:[String,Function],default:null},sortOrder:{type:Number,default:null},multiSortMeta:{type:Array,default:null},allRowsSelected:{type:Boolean,default:!1},empty:{type:Boolean,default:!1},filterDisplay:{type:String,default:null},filters:{type:Object,default:null},filtersStore:{type:Object,default:null},filterColumn:{type:Boolean,default:!1},reorderableColumns:{type:Boolean,default:!1},filterInputProps:{type:null,default:null},headerCheckboxIconTemplate:{type:Function,default:null}},data(){return{styleObject:{}}},mounted(){this.columnProp("frozen")&&this.updateStickyPosition()},updated(){this.columnProp("frozen")&&this.updateStickyPosition()},methods:{columnProp(e){return ve.getVNodeProp(this.column,e)},getColumnPTOptions(e){return this.ptmo(this.getColumnProp(),e,{props:this.column.props,parent:{props:this.$props,state:this.$data}})},getColumnProp(){return this.column.props&&this.column.props.pt?this.column.props.pt:void 0},onClick(e){this.$emit("column-click",{originalEvent:e,column:this.column})},onKeyDown(e){(e.code==="Enter"||e.code==="Space")&&e.currentTarget.nodeName==="TH"&&F.hasClass(e.currentTarget,"p-sortable-column")&&(this.$emit("column-click",{originalEvent:e,column:this.column}),e.preventDefault())},onMouseDown(e){this.$emit("column-mousedown",{originalEvent:e,column:this.column})},onDragStart(e){this.$emit("column-dragstart",e)},onDragOver(e){this.$emit("column-dragover",e)},onDragLeave(e){this.$emit("column-dragleave",e)},onDrop(e){this.$emit("column-drop",e)},onResizeStart(e){this.$emit("column-resizestart",e)},getMultiSortMetaIndex(){return this.multiSortMeta.findIndex(e=>e.field===this.columnProp("field")||e.field===this.columnProp("sortField"))},getBadgeValue(){let e=this.getMultiSortMetaIndex();return this.groupRowsBy&&this.groupRowsBy===this.groupRowSortField&&e>-1?e:e+1},isMultiSorted(){return this.sortMode==="multiple"&&this.columnProp("sortable")&&this.getMultiSortMetaIndex()>-1},isColumnSorted(){return this.sortMode==="single"?this.sortField&&(this.sortField===this.columnProp("field")||this.sortField===this.columnProp("sortField")):this.isMultiSorted()},updateStickyPosition(){if(this.columnProp("frozen")){if(this.columnProp("alignFrozen")==="right"){let n=0,i=this.$el.nextElementSibling;i&&(n=F.getOuterWidth(i)+parseFloat(i.style.right||0)),this.styleObject.right=n+"px"}else{let n=0,i=this.$el.previousElementSibling;i&&(n=F.getOuterWidth(i)+parseFloat(i.style.left||0)),this.styleObject.left=n+"px"}let t=this.$el.parentElement.nextElementSibling;if(t){let n=F.index(this.$el);t.children[n].style.left=this.styleObject.left,t.children[n].style.right=this.styleObject.right}}},onHeaderCheckboxChange(e){this.$emit("checkbox-change",e)}},computed:{containerClass(){return[this.filterColumn?this.columnProp("filterHeaderClass"):this.columnProp("headerClass"),this.columnProp("class"),{"p-sortable-column":this.columnProp("sortable"),"p-resizable-column":this.resizableColumns,"p-highlight":this.isColumnSorted(),"p-filter-column":this.filterColumn,"p-frozen-column":this.columnProp("frozen"),"p-reorderable-column":this.reorderableColumns}]},containerStyle(){let e=this.filterColumn?this.columnProp("filterHeaderStyle"):this.columnProp("headerStyle"),t=this.columnProp("style");return this.columnProp("frozen")?[t,e,this.styleObject]:[t,e]},sortState(){let e=!1,t=null;if(this.sortMode==="single")e=this.sortField&&(this.sortField===this.columnProp("field")||this.sortField===this.columnProp("sortField")),t=e?this.sortOrder:0;else if(this.sortMode==="multiple"){let n=this.getMultiSortMetaIndex();n>-1&&(e=!0,t=this.multiSortMeta[n].order)}return{sorted:e,sortOrder:t}},sortableColumnIcon(){const{sorted:e,sortOrder:t}=this.sortState;if(e){if(e&&t>0)return Mo;if(e&&t<0)return xo}else return Do;return null},ariaSort(){if(this.columnProp("sortable")){const{sorted:e,sortOrder:t}=this.sortState;return e&&t<0?"descending":e&&t>0?"ascending":"none"}else return null}},components:{DTHeaderCheckbox:Nl,DTColumnFilter:Ll,SortAltIcon:Do,SortAmountUpAltIcon:Mo,SortAmountDownIcon:xo}};const f3=["tabindex","colspan","rowspan","aria-sort"];function m3(e,t,n,i,r,s){const a=le("DTHeaderCheckbox"),o=le("DTColumnFilter");return g(),S("th",R({style:s.containerStyle,class:s.containerClass,tabindex:s.columnProp("sortable")?"0":null,role:"columnheader",colspan:s.columnProp("colspan"),rowspan:s.columnProp("rowspan"),"aria-sort":s.ariaSort,onClick:t[8]||(t[8]=(...l)=>s.onClick&&s.onClick(...l)),onKeydown:t[9]||(t[9]=(...l)=>s.onKeyDown&&s.onKeyDown(...l)),onMousedown:t[10]||(t[10]=(...l)=>s.onMouseDown&&s.onMouseDown(...l)),onDragstart:t[11]||(t[11]=(...l)=>s.onDragStart&&s.onDragStart(...l)),onDragover:t[12]||(t[12]=(...l)=>s.onDragOver&&s.onDragOver(...l)),onDragleave:t[13]||(t[13]=(...l)=>s.onDragLeave&&s.onDragLeave(...l)),onDrop:t[14]||(t[14]=(...l)=>s.onDrop&&s.onDrop(...l))},{...s.getColumnPTOptions("root"),...s.getColumnPTOptions("headerCell")}),[n.resizableColumns&&!s.columnProp("frozen")?(g(),S("span",R({key:0,class:"p-column-resizer",onMousedown:t[0]||(t[0]=(...l)=>s.onResizeStart&&s.onResizeStart(...l))},s.getColumnPTOptions("columnResizer")),null,16)):M("",!0),f("div",R({class:"p-column-header-content"},s.getColumnPTOptions("headerContent")),[n.column.children&&n.column.children.header?(g(),Q(_e(n.column.children.header),{key:0,column:n.column},null,8,["column"])):M("",!0),s.columnProp("header")?(g(),S("span",R({key:1,class:"p-column-title"},s.getColumnPTOptions("headerTitle")),N(s.columnProp("header")),17)):M("",!0),s.columnProp("sortable")?(g(),S("span",ft(R({key:2},s.getColumnPTOptions("sort"))),[(g(),Q(_e(n.column.children&&n.column.children.sorticon||s.sortableColumnIcon),{sorted:s.sortState.sorted,sortOrder:s.sortState.sortOrder,class:"p-sortable-column-icon"},null,8,["sorted","sortOrder"]))],16)):M("",!0),s.isMultiSorted()?(g(),S("span",R({key:3,class:"p-sortable-column-badge"},s.getColumnPTOptions("sortBadge")),N(s.getBadgeValue()),17)):M("",!0),s.columnProp("selectionMode")==="multiple"&&n.filterDisplay!=="row"?(g(),Q(a,{key:4,checked:n.allRowsSelected,onChange:s.onHeaderCheckboxChange,disabled:n.empty,headerCheckboxIconTemplate:n.headerCheckboxIconTemplate,column:n.column,pt:e.pt},null,8,["checked","onChange","disabled","headerCheckboxIconTemplate","column","pt"])):M("",!0),n.filterDisplay==="menu"&&n.column.children&&n.column.children.filter?(g(),Q(o,{key:5,field:s.columnProp("filterField")||s.columnProp("field"),type:s.columnProp("dataType"),display:"menu",showMenu:s.columnProp("showFilterMenu"),filterElement:n.column.children&&n.column.children.filter,filterHeaderTemplate:n.column.children&&n.column.children.filterheader,filterFooterTemplate:n.column.children&&n.column.children.filterfooter,filterClearTemplate:n.column.children&&n.column.children.filterclear,filterApplyTemplate:n.column.children&&n.column.children.filterapply,filterIconTemplate:n.column.children&&n.column.children.filtericon,filterAddIconTemplate:n.column.children&&n.column.children.filteraddicon,filterRemoveIconTemplate:n.column.children&&n.column.children.filterremoveicon,filterClearIconTemplate:n.column.children&&n.column.children.filterclearicon,filters:n.filters,filtersStore:n.filtersStore,filterInputProps:n.filterInputProps,onFilterChange:t[1]||(t[1]=l=>e.$emit("filter-change",l)),onFilterApply:t[2]||(t[2]=l=>
700e.$emit("filter-apply")),filterMenuStyle:s.columnProp("filterMenuStyle"),filterMenuClass:s.columnProp("filterMenuClass"),showOperator:s.columnProp("showFilterOperator"),showClearButton:s.columnProp("showClearButton"),showApplyButton:s.columnProp("showApplyButton"),showMatchModes:s.columnProp("showFilterMatchModes"),showAddButton:s.columnProp("showAddButton"),matchModeOptions:s.columnProp("filterMatchModeOptions"),maxConstraints:s.columnProp("maxConstraints"),onOperatorChange:t[3]||(t[3]=l=>e.$emit("operator-change",l)),onMatchmodeChange:t[4]||(t[4]=l=>e.$emit("matchmode-change",l)),onConstraintAdd:t[5]||(t[5]=l=>e.$emit("constraint-add",l)),onConstraintRemove:t[6]||(t[6]=l=>e.$emit("constraint-remove",l)),onApplyClick:t[7]||(t[7]=l=>e.$emit("apply-click",l)),pt:e.pt,column:n.column},null,8,["field","type","showMenu","filterElement","filterHeaderTemplate","filterFooterTemplate","filterClearTemplate","filterApplyTemplate","filterIconTemplate","filterAddIconTemplate","filterRemoveIconTemplate","filterClearIconTemplate","filters","filtersStore","filterInputProps","filterMenuStyle","filterMenuClass","showOperator","showClearButton","showApplyButton","showMatchModes","showAddButton","matchModeOptions","maxConstraints","pt","column"])):M("",!0)],16)],16,f3)}Xf.render=m3;var em={name:"TableHeader",extends:Ve,emits:["column-click","column-mousedown","column-dragstart","column-dragover","column-dragleave","column-drop","column-resizestart","checkbox-change","filter-change","filter-apply","operator-change","matchmode-change","constraint-add","constraint-remove","filter-clear","apply-click"],props:{columnGroup:{type:null,default:null},columns:{type:null,default:null},rowGroupMode:{type:String,default:null},groupRowsBy:{type:[Array,String,Function],default:null},resizableColumns:{type:Boolean,default:!1},allRowsSelected:{type:Boolean,default:!1},empty:{type:Boolean,default:!1},sortMode:{type:String,default:"single"},groupRowSortField:{type:[String,Function],default:null},sortField:{type:[String,Function],default:null},sortOrder:{type:Number,default:null},multiSortMeta:{type:Array,default:null},filterDisplay:{type:String,default:null},filters:{type:Object,default:null},filtersStore:{type:Object,default:null},reorderableColumns:{type:Boolean,default:!1},filterInputProps:{type:null,default:null},headerCheckboxIconTemplate:{type:Function,default:null}},methods:{columnProp(e,t){return ve.getVNodeProp(e,t)},getColumnGroupPTOptions(e){return this.ptmo(this.getColumnGroupProps(),e,{props:this.getColumnGroupProps(),parent:{props:this.$props,state:this.$data}})},getColumnGroupProps(){return this.columnGroup&&this.columnGroup.props&&this.columnGroup.props.pt?this.columnGroup.props.pt:void 0},getRowPTOptions(e,t){return this.ptmo(this.getRowProp(e),t,{props:e.props,parent:{props:this.$props,state:this.$data}})},getRowProp(e){return e.props&&e.props.pt?e.props.pt:void 0},getColumnPTOptions(e,t){return this.ptmo(this.getColumnProp(e),t,{props:e.props,parent:{props:this.$props,state:this.$data}})},getColumnProp(e){return e.props&&e.props.pt?e.props.pt:void 0},getFilterColumnHeaderClass(e){return["p-filter-column",this.columnProp(e,"filterHeaderClass"),this.columnProp(e,"class"),{"p-frozen-column":this.columnProp(e,"frozen")}]},getFilterColumnHeaderStyle(e){return[this.columnProp(e,"filterHeaderStyle"),this.columnProp(e,"style")]},getHeaderRows(){let e=[],t=this.columnGroup;if(t.children&&t.children.default){for(let n of t.children.default())n.type.name==="Row"?e.push(n):n.children&&n.children instanceof Array&&(e=n.children);return e}},getHeaderColumns(e){let t=[];if(e.children&&e.children.default)return e.children.default().forEach(n=>{n.children&&n.children instanceof Array?t=[...t,...n.children]:n.type.name==="Column"&&t.push(n)}),t}},components:{DTHeaderCell:Xf,DTHeaderCheckbox:Nl,DTColumnFilter:Ll}};function g3(e,t,n,i,r,s){const a=le("DTHeaderCell"),o=le("DTHeaderCheckbox"),l=le("DTColumnFilter");return g(),S("thead",R({class:"p-datatable-thead",role:"rowgroup"},{...e.ptm("thead"),...s.getColumnGroupPTOptions("root")}),[n.columnGroup?(g(!0),S(J,{key:1},ye(s.getHeaderRows(),(c,d)=>(g(),S("tr",R({key:d,role:"row"},s.getRowPTOptions(c,"root")),[(g(!0),S(J,null,ye(s.getHeaderColumns(c),(u,p)=>
700(g(),S(J,{key:s.columnProp(u,"columnKey")||s.columnProp(u,"field")||p},[!s.columnProp(u,"hidden")&&(n.rowGroupMode!=="subheader"||n.groupRowsBy!==s.columnProp(u,"field"))&&typeof u.children!="string"?(g(),Q(a,{key:0,column:u,onColumnClick:t[23]||(t[23]=h=>e.$emit("column-click",h)),onColumnMousedown:t[24]||(t[24]=h=>e.$emit("column-mousedown",h)),groupRowsBy:n.groupRowsBy,groupRowSortField:n.groupRowSortField,sortMode:n.sortMode,sortField:n.sortField,sortOrder:n.sortOrder,multiSortMeta:n.multiSortMeta,allRowsSelected:n.allRowsSelected,empty:n.empty,onCheckboxChange:t[25]||(t[25]=h=>e.$emit("checkbox-change",h)),filters:n.filters,filterDisplay:n.filterDisplay,filtersStore:n.filtersStore,onFilterChange:t[26]||(t[26]=h=>e.$emit("filter-change",h)),onFilterApply:t[27]||(t[27]=h=>e.$emit("filter-apply")),onOperatorChange:t[28]||(t[28]=h=>e.$emit("operator-change",h)),onMatchmodeChange:t[29]||(t[29]=h=>e.$emit("matchmode-change",h)),onConstraintAdd:t[30]||(t[30]=h=>e.$emit("constraint-add",h)),onConstraintRemove:t[31]||(t[31]=h=>e.$emit("constraint-remove",h)),onApplyClick:t[32]||(t[32]=h=>e.$emit("apply-click",h)),headerCheckboxIconTemplate:n.headerCheckboxIconTemplate,pt:e.pt},null,8,["column","groupRowsBy","groupRowSortField","sortMode","sortField","sortOrder","multiSortMeta","allRowsSelected","empty","filters","filterDisplay","filtersStore","headerCheckboxIconTemplate","pt"])):M("",!0)],64))),128))],16))),128)):(g(),S(J,{key:0},[f("tr",R({role:"row"},e.ptm("headerRow")),[(g(!0),S(J,null,ye(n.columns,(c,d)=>(g(),S(J,{key:s.columnProp(c,"columnKey")||s.columnProp(c,"field")||d},[!s.columnProp(c,"hidden")&&(n.rowGroupMode!=="subheader"||n.groupRowsBy!==s.columnProp(c,"field"))?(g(),Q(a,{key:0,column:c,onColumnClick:t[0]||(t[0]=u=>e.$emit("column-click",u)),onColumnMousedown:t[1]||(t[1]=u=>e.$emit("column-mousedown",u)),onColumnDragstart:t[2]||(t[2]=u=>e.$emit("column-dragstart",u)),onColumnDragover:t[3]||(t[3]=u=>e.$emit("column-dragover",u)),onColumnDragleave:t[4]||(t[4]=u=>e.$emit("column-dragleave",u)),onColumnDrop:t[5]||(t[5]=u=>e.$emit("column-drop",u)),groupRowsBy:n.groupRowsBy,groupRowSortField:n.groupRowSortField,reorderableColumns:n.reorderableColumns,resizableColumns:n.resizableColumns,onColumnResizestart:t[6]||(t[6]=u=>e.$emit("column-resizestart",u)),sortMode:n.sortMode,sortField:n.sortField,sortOrder:n.sortOrder,multiSortMeta:n.multiSortMeta,allRowsSelected:n.allRowsSelected,empty:n.empty,onCheckboxChange:t[7]||(t[7]=u=>e.$emit("checkbox-change",u)),filters:n.filters,filterDisplay:n.filterDisplay,filtersStore:n.filtersStore,filterInputProps:n.filterInputProps,onFilterChange:t[8]||(t[8]=u=>e.$emit("filter-change",u)),onFilterApply:t[9]||(t[9]=u=>
700e.$emit("filter-apply")),onOperatorChange:t[10]||(t[10]=u=>e.$emit("operator-change",u)),onMatchmodeChange:t[11]||(t[11]=u=>e.$emit("matchmode-change",u)),onConstraintAdd:t[12]||(t[12]=u=>e.$emit("constraint-add",u)),onConstraintRemove:t[13]||(t[13]=u=>e.$emit("constraint-remove",u)),onApplyClick:t[14]||(t[14]=u=>e.$emit("apply-click",u)),headerCheckboxIconTemplate:n.headerCheckboxIconTemplate,pt:e.pt},null,8,["column","groupRowsBy","groupRowSortField","reorderableColumns","resizableColumns","sortMode","sortField","sortOrder","multiSortMeta","allRowsSelected","empty","filters","filterDisplay","filtersStore","filterInputProps","headerCheckboxIconTemplate","pt"])):M("",!0)],64))),128))],16),n.filterDisplay==="row"?(g(),S("tr",R({key:0,role:"row"},e.ptm("headerRow")),[(g(!0),S(J,null,ye(n.columns,(c,d)=>(g(),S(J,{key:s.columnProp(c,"columnKey")||s.columnProp(c,"field")||d},[!s.columnProp(c,"hidden")&&(n.rowGroupMode!=="subheader"||n.groupRowsBy!==s.columnProp(c,"field"))?(g(),S("th",R({key:0,style:s.getFilterColumnHeaderStyle(c),class:s.getFilterColumnHeaderClass(c)},{...s.getColumnPTOptions(c,"root"),...s.getColumnPTOptions(c,"headerCell")}),[s.columnProp(c,"selectionMode")==="multiple"?(g(),Q(o,{key:0,checked:n.allRowsSelected,disabled:n.empty,onChange:t[15]||(t[15]=u=>e.$emit("checkbox-change",u)),column:c,pt:e.pt},null,8,["checked","disabled","column","pt"])):M("",!0),c.children&&c.children.filter?(g(),Q(l,{key:1,field:s.columnProp(c,"filterField")||s.columnProp(c,"field"),type:s.columnProp(c,"dataType"),display:"row",showMenu:s.columnProp(c,"showFilterMenu"),filterElement:c.children&&c.children.filter,filterHeaderTemplate:c.children&&c.children.filterheader,filterFooterTemplate:c.children&&c.children.filterfooter,filterClearTemplate:c.children&&c.children.filterclear,filterApplyTemplate:c.children&&c.children.filterapply,filterIconTemplate:c.children&&c.children.filtericon,filterAddIconTemplate:c.children&&c.children.filteraddicon,filterRemoveIconTemplate:c.children&&c.children.filterremoveicon,filterClearIconTemplate:c.children&&c.children.filterclearicon,filters:n.filters,filtersStore:n.filtersStore,filterInputProps:n.filterInputProps,onFilterChange:t[16]||(t[16]=u=>e.$emit("filter-change",u)),onFilterApply:t[17]||(t[17]=u=>
700e.$emit("filter-apply")),filterMenuStyle:s.columnProp(c,"filterMenuStyle"),filterMenuClass:s.columnProp(c,"filterMenuClass"),showOperator:s.columnProp(c,"showFilterOperator"),showClearButton:s.columnProp(c,"showClearButton"),showApplyButton:s.columnProp(c,"showApplyButton"),showMatchModes:s.columnProp(c,"showFilterMatchModes"),showAddButton:s.columnProp(c,"showAddButton"),matchModeOptions:s.columnProp(c,"filterMatchModeOptions"),maxConstraints:s.columnProp(c,"maxConstraints"),onOperatorChange:t[18]||(t[18]=u=>e.$emit("operator-change",u)),onMatchmodeChange:t[19]||(t[19]=u=>e.$emit("matchmode-change",u)),onConstraintAdd:t[20]||(t[20]=u=>e.$emit("constraint-add",u)),onConstraintRemove:t[21]||(t[21]=u=>e.$emit("constraint-remove",u)),onApplyClick:t[22]||(t[22]=u=>e.$emit("apply-click",u)),pt:e.pt,column:c},null,8,["field","type","showMenu","filterElement","filterHeaderTemplate","filterFooterTemplate","filterClearTemplate","filterApplyTemplate","filterIconTemplate","filterAddIconTemplate","filterRemoveIconTemplate","filterClearIconTemplate","filters","filtersStore","filterInputProps","filterMenuStyle","filterMenuClass","showOperator","showClearButton","showApplyButton","showMatchModes","showAddButton","matchModeOptions","maxConstraints","pt","column"])):M("",!0)],16)):M("",!0)],64))),128))],16)):M("",!0)],64))],16)}em.render=g3;var tm={name:"DataTable",extends:Ve,emits:["value-change","update:first","update:rows","page","update:sortField","update:sortOrder","update:multiSortMeta","sort","filter","row-click","row-dblclick","update:selection","row-select","row-unselect","update:contextMenuSelection","row-contextmenu","row-unselect-all","row-select-all","select-all-change","column-resize-end","column-reorder","row-reorder","update:ex
700pandedRows","row-collapse","row-expand","update:expandedRowGroups","rowgroup-collapse","rowgroup-expand","update:filters","state-restore","state-save","cell-edit-init","cell-edit-complete","cell-edit-cancel","update:editingRows","row-edit-init","row-edit-save","row-edit-cancel"],props:{value:{type:Array,default:null},dataKey:{type:[String,Function],default:null},rows:{type:Number,default:0},first:{type:Number,default:0},totalRecords:{type:Number,default:0},paginator:{type:Boolean,default:!1},paginatorPosition:{type:String,default:"bottom"},alwaysShowPaginator:{type:Boolean,default:!0},paginatorTemplate:{type:[Object,String],default:"FirstPageLink PrevPageLink PageLinks NextPageLink LastPageLink RowsPerPageDropdown"},pageLinkSize:{type:Number,default:5},rowsPerPageOptions:{type:Array,default:null},currentPageReportTemplate:{type:String,default:"({currentPage} of {totalPages})"},lazy:{type:Boolean,default:!1},loading:{type:Boolean,default:!1},loadingIcon:{type:String,default:void 0},sortField:{type:[String,Function],default:null},sortOrder:{type:Number,default:null},defaultSortOrder:{type:Number,default:1},multiSortMeta:{type:Array,default:null},sortMode:{type:String,default:"single"},removableSort:{type:Boolean,default:!1},filters:{type:Object,default:null},filterDisplay:{type:String,default:null},globalFilterFields:{type:Array,default:null},filterLocale:{type:String,default:void 0},selection:{type:[Array,Object],default:null},selectionMode:{type:String,default:null},compareSelectionBy:{type:String,default:"deepEquals"},metaKeySelection:{type:Boolean,default:!0},contextMenu:{type:Boolean,default:!1},contextMenuSelection:{type:Object,default:null},selectAll:{type:Boolean,default:null},rowHover:{type:Boolean,default:!1},csvSeparator:{type:String,default:","},exportFilename:{type:String,default:"download"},exportFunction:{type:Function,default:null},resizableColumns:{type:Boolean,default:!1},columnResizeMode:{type:String,default:"fit"},reorderableColumns:{type:Boolean,default:!1},expandedRows:{type:Array,default:null},expandedRowIcon:{type:String,default:void 0},collapsedRowIcon:{type:String,default:void 0},rowGroupMode:{type:String,default:null},groupRowsBy:{type:[Array,String,Function],default:null},expandableRowGroups:{type:Boolean,default:!1},expandedRowGroups:{type:Array,default:null},stateStorage:{type:String,default:"session"},stateKey:{type:String,default:null},editMode:{type:String,default:null},editingRows:{type:Array,default:null},rowClass:{type:null,default:null},rowStyle:{type:null,default:null},scrollable:{type:Boolean,default:!1},virtualScrollerOptions:{type:Object,default:null},scrollHeight:{type:String,default:null},frozenValue:{type:Array,default:null},responsiveLayout:{type:String,default:"scroll"},breakpoint:{type:String,default:"960px"},showGridlines:{type:Boolean,default:!1},stripedRows:{type:Boolean,default:!1},tableStyle:{type:null,default:null},tableClass:{type:String,default:null},tableProps:{type:null,default:null},filterInputProps:{type:null,default:null}},data(){return{d_first:this.first,d_rows:this.rows,d_sortField:this.sortField,d_sortOrder:this.sortOrder,d_multiSortMeta:this.multiSortMeta?[...this.multiSortMeta]:[],d_groupRowsSortMeta:null,d_selectionKeys:null,d_expandedRowKeys:null,d_columnOrder:null,d_editingRowKeys:null,d_editingMeta:{},d_filters:this.cloneFilters(this.filters)}},rowTouched:!1,anchorRowIndex:null,rangeRowIndex:null,documentColumnResizeListener:null,documentColumnResizeEndListener:null,lastResizeHelperX:null,resizeColumnElement:null,columnResizing:!1,colReorderIconWidth:null,colReorderIconHeight:null,draggedColumn:null,draggedRowIndex:null,droppedRowIndex:null,rowDragging:null,columnWidthsState:null,tableWidthState:null,columnWidthsRestored:!1,watch:{first(e){this.d_first=e},rows(e){this.d_rows=e},sortField(e){this.d_sortField=e},sortOrder(e){this.d_sortOrder=e},multiSortMeta(e){this.d_multiSortMeta=e},selection:{immediate:!0,handler(e){this.dataKey&&this.updateSelectionKeys(e)}},expandedRows(e){this.dataKey&&this.updateExpandedRowKeys(e)},editingRows(e){this.dataKey&&this.updateEditingRowKeys(e)},filters:{deep:!0,handler:function(e){this.d_filters=this.cloneFilters(e)}}},beforeMount(){this.isStateful()&&this.restoreState()},mounted(){this.$el.setAttribute(this.attributeSelector,""),this.responsiveLayout==="stack"&&!this.scrollable&&this.createResponsiveStyle(),this.isStateful()&&this.resizableColumns&&this.restoreColumnWidths(),this.editMode==="row"&&this.dataKey&&!this.d_editingRowKeys&&this.updateEditingRowKeys(this.editingRows)},beforeUnmount(){this.unbindColumnResizeEvents(),this.destroyStyleElement(),this.destroyResponsiveStyle()},updated(){this.isStateful()&&this.saveState(),this.editMode==="row"&&this.dataKey&&!this.d_editingRowKeys&&this.updateEditingRowKeys(this.editingRows)},methods:{columnProp(e,t){return ve.getVNodeProp(e,t)},onPage(e){this.clearEditingMetaData(),this.d_first=e.first,this.d_rows=e.rows;let t=this.createLazyLoadEvent(e);
700t.pageCount=e.pageCount,t.page=e.page,this.$emit("update:first",this.d_first),this.$emit("update:rows",this.d_rows),this.$emit("page",t),this.$emit("value-change",this.processedData)},onColumnHeaderClick(e){const t=e.originalEvent,n=e.column;if(this.columnProp(n,"sortable")){const i=t.target,r=this.columnProp(n,"sortField")||this.columnProp(n,"field");(F.hasClass(i,"p-sortable-column")||F.hasClass(i,"p-column-title")||F.hasClass(i,"p-column-header-content")||F.hasClass(i,"p-sortable-column-icon")||F.hasClass(i.parentElement,"p-sortable-column-icon"))&&(F.clearSelection(),this.sortMode==="single"?(this.d_sortField===r?this.removableSort&&this.d_sortOrder*-1===this.defaultSortOrder?(this.d_sortOrder=null,this.d_sortField=null):this.d_sortOrder=this.d_sortOrder*-1:(this.d_sortOrder=this.defaultSortOrder,this.d_sortField=r),this.$emit("update:sortField",this.d_sortField),this.$emit("update:sortOrder",this.d_sortOrder),this.resetPage()):this.sortMode==="multiple"&&(t.metaKey||t.ctrlKey||(this.d_multiSortMeta=this.d_multiSortMeta.filter(a=>a.field===r)),this.addMultiSortField(r),this.$emit("update:multiSortMeta",this.d_multiSortMeta)),this.$emit("sort",this.createLazyLoadEvent(t)),this.$emit("value-change",this.processedData))}},sortSingle(e){if(this.clearEditingMetaData(),this.groupRowsBy&&this.groupRowsBy===this.sortField)return this.d_multiSortMeta=[{field:this.sortField,order:this.sortOrder||this.defaultSortOrder},{field:this.d_sortField,order:this.d_sortOrder}],this.sortMultiple(e);let t=[...e];return t.sort((n,i)=>{let r=ve.resolveFieldData(n,this.d_sortField),s=ve.resolveFieldData(i,this.d_sortField),a=null;return r==null&&s!=null?a=-1:r!=null&&s==null?a=1:r==null&&s==null?a=0:typeof r=="string"&&typeof s=="string"?a=r.localeCompare(s,void 0,{numeric:!0}):a=r<s?-1:r>s?1:0,this.d_sortOrder*a}),t},sortMultiple(e){if(this.clearEditingMetaData(),this.groupRowsBy&&(this.d_groupRowsSortMeta||this.d_multiSortMeta.length&&this.groupRowsBy===this.d_multiSortMeta[0].field)){const n=this.d_multiSortMeta[0];!this.d_groupRowsSortMeta&&(this.d_groupRowsSortMeta=n),n.field!==this.d_groupRowsSortMeta.field&&(this.d_multiSortMeta=[this.d_groupRowsSortMeta,...this.d_multiSortMeta])}let t=[...e];return t.sort((n,i)=>this.multisortField(n,i,0)),t},multisortField(e,t,n){const i=ve.resolveFieldData(e,this.d_multiSortMeta[n].field),r=ve.resolveFieldData(t,this.d_multiSortMeta[n].field);let s=null;if(typeof i=="string"||i instanceof String){if(i.localeCompare&&i!==r)return this.d_multiSortMeta[n].order*i.localeCompare(r,void 0,{numeric:!0})}else s=i<r?-1:1;return i===r?this.d_multiSortMeta.length-1>n?this.multisortField(e,t,n+1):0:this.d_multiSortMeta[n].order*s},addMultiSortField(e){let t=this.d_multiSortMeta.findIndex(n=>n.field===e);t>=0?this.removableSort&&this.d_multiSortMeta[t].order*-1===this.defaultSortOrder?this.d_multiSortMeta.splice(t,1):this.d_multiSortMeta[t]={field:e,order:this.d_multiSortMeta[t].order*-1}:this.d_multiSortMeta.push({field:e,order:this.defaultSortOrder}),this.d_multiSortMeta=[...this.d_multiSortMeta]},filter(e){if(!e)return;this.clearEditingMetaData();let t;this.filters.global&&(t=this.globalFilterFields||this.columns.map(r=>this.columnProp(r,"filterField")||this.columnProp(r,"field")));let n=[];for(let r=0;r<e.length;r++){let s=!0,a=!1,o=!1;for(let c in this.filters)if(Object.prototype.hasOwnProperty.call(this.filters,c)&&c!=="global"){o=!0;let d=c,u=this.filters[d];if(u.operator){for(let p of u.constraints)if(s=this.executeLocalFilter(d,e[r],p),u.operator===_r.OR&&s||u.operator===_r.AND&&!s)break}else s=this.executeLocalFilter(d,e[r],u);if(!s)break}if(this.filters.global&&!a&&t)for(let c=0;c<t.length;c++){let d=t[c];if(a=wr.filters[this.filters.global.matchMode||Lt.CONTAINS](ve.resolveFieldData(e[r],d),this.filters.global.value,this.filterLocale),a)break}let l;this.filters.global?l=o?o&&s&&a:a:l=o&&s,l&&n.push(e[r])}n.length===this.value.length&&(n=e);let i=this.createLazyLoadEvent();return i.filteredValue=n,this.$emit("filter",i),this.$emit("value-change",n),n},executeLocalFilter(e,t,n){let i=n.value,r=n.matchMode||Lt.STARTS_WITH,s=ve.resolveFieldData(t,e),a=wr.filters[r];return a(s,i,this.filterLocale)},onRowClick(e){const t=e.originalEvent,n=e.index,i=this.$refs.bodyRef&&this.$refs.bodyRef.$el,r=F.findSingle(i,'tr.p-selectable-row[tabindex="0"]');if(!F.isClickable(t.target)){if(this.$emit("row-click",e),this.selectionMode){const s=e.data,a=this.d_first+e.index;if(this.isMultipleSelectionMode()&&t.shiftKey&&this.anchorRowIndex!=null)F.clearSelection(),this.rangeRowIndex=a,this.selectRange(t);else{const o=this.isSelected(s),l=this.rowTouched?!1:this.metaKeySelection;if(this.anchorRowIndex=a,this.rangeRowIndex=a,l){let c=t.metaKey||t.ctrlKey;if(o&&c){if(this.isSingleSelectionMode())this.$emit("update:selection",null);else{const d=this.findIndexInSelection(s),u=this.selection.filter((p,h)=>h!=d);this.$emit("update:selection",u)}this.$emit("row-unselect",{originalEvent:t,data:s,index:a,type:"row"})}else{if(this.isSingleSelectionMode())this.$emit("update:selection",s);else if(this.isMultipleSelectionMode()){let d=c?this.selection||[]:[];d=[...d,s],this.$emit("update:selection",d)}this.$emit("row-select",{originalEvent:t,data:s,index:a,type:"row"})}}else if(this.selectionMode==="single")o?(this.$emit("update:selection",null),this.$emit("row-unselect",{originalEvent:t,data:s,index:a,type:"row"})):(this.$emit("update:selection",s),this.$emit("row-select",{originalEvent:t,data:s,index:a,type:"row"}));else if(this.selectionMode==="multiple")if(o){const c=this.findIndexInSelection(s),d=this.selection.filter((u,p)=>p!=c);this.$emit("update:selection",d),this.$emit("row-unselect",{originalEvent:t,data:s,index:a,type:"row"})}else{const c=this.selection?[...this.selection,s]:[s];this.$emit("update:selection",c),this.$emit("row-select",{originalEvent:t,data:s,index:a,type:"row"})}}}this.rowTouched=!1,r&&(r.tabIndex="-1",F.find(i,"tr.p-selectable-row")[n].tabIndex="0")}},onRowDblClick(e){const t=e.originalEvent;F.isClickable(t.target)||this.$emit("row-dblclick",e)},onRowRightClick(e){this.contextMenu&&(F.clearSelection(),e.originalEvent.target.focu
700s()),this.$emit("update:contextMenuSelection",e.data),this.$emit("row-contextmenu",e)},onRowTouchEnd(){this.rowTouched=!0},onRowKeyDown(e,t){const n=e.originalEvent,i=e.data,r=e.index,s=n.metaKey||n.ctrlKey;if(this.selectionMode){const a=n.target;switch(n.code){case"ArrowDown":this.onArrowDownKey(n,a,r,t);break;case"ArrowUp":this.onArrowUpKey(n,a,r,t);break;case"Home":this.onHomeKey(n,a,r,t);break;case"End":this.onEndKey(n,a,r,t);break;case"Enter":this.onEnterKey(n,i,r);break;case"Space":this.onSpaceKey(n,i,r,t);break;case"Tab":this.onTabKey(n,r);break;default:if(n.code==="KeyA"&&s){const o=this.dataToRender(t.rows);this.$emit("update:selection",o)}break}}},onArrowDownKey(e,t,n,i){const r=this.findNextSelectableRow(t);if(r&&this.focusRowChange(t,r),e.shiftKey){const s=this.dataToRender(i.rows),a=n+1>=s.length?s.length-1:n+1;this.onRowClick({originalEvent:e,data:s[a],index:a})}e.preventDefault()},onArrowUpKey(e,t,n,i){const r=this.findPrevSelectableRow(t);if(r&&this.focusRowChange(t,r),e.shiftKey){const s=this.dataToRender(i.rows),a=n-1<=0?0:n-1;this.onRowClick({originalEvent:e,data:s[a],index:a})}e.preventDefault()},onHomeKey(e,t,n,i){const r=this.findFirstSelectableRow();if(r&&this.focusRowChange(t,r),e.ctrlKey&&e.shiftKey){const s=this.dataToRender(i.rows);this.$emit("update:selection",s.slice(0,n+1))}e.preventDefault()},onEndKey(e,t,n,i){const r=this.findLastSelectableRow();if(r&&this.focusRowChange(t,r),e.ctrlKey&&e.shiftKey){const s=this.dataToRender(i.rows);this.$emit("update:selection",s.slice(n,s.length))}e.preventDefault()},onEnterKey(e,t,n){this.onRowClick({originalEvent:e,data:t,index:n}),e.preventDefault()},onSpaceKey(e,t,n,i){if(this.onEnterKey(e,t,n),e.shiftKey&&this.selection!==null){const r=this.dataToRender(i.rows);let s;if(this.selection.length>0){let o,l;o=ve.findIndexInList(this.selection[0],r),l=ve.findIndexInList(this.selection[this.selection.length-1],r),s=n<=o?l:o}else s=ve.findIndexInList(this.selection,r);const a=s!==n?r.slice(Math.min(s,n),Math.max(s,n)+1):t;this.$emit("update:selection",a)}},onTabKey(e,t){const n=this.$refs.bodyRef&&this.$refs.bodyRef.$el,i=F.find(n,"tr.p-selectable-row");if(e.code==="Tab"&&i&&i.length>0){const r=F.findSingle(n,"tr.p-highlight"),s=F.findSingle(n,'tr.p-selectable-row[tabindex="0"]');r?(r.tabIndex="0",s&&s!==r&&(s.tabIndex="-1")):(i[0].tabIndex="0",s!==i[0]&&(i[t].tabIndex="-1"))}},findNextSelectableRow(e){let t=e.nextElementSibling;return t?F.hasClass(t,"p-selectable-row")?t:this.findNextSelectableRow(t):null},findPrevSelectableRow(e){let t=e.previousElementSibling;return t?F.hasClass(t,"p-selectable-row")?t:this.findPrevSelectableRow(t):null},findFirstSelectableRow(){return F.findSingle(this.$refs.table,".p-selectable-row")},findLastSelectableRow(){const e=F.find(this.$refs.table,".p-selectable-row");return e?e[e.length-1]:null},focusRowChange(e,t){e.tabIndex="-1",t.tabIndex="0",F.focus(t)},toggleRowWithRadio(e){const t=e.data;this.isSelected(t)?(this.$emit("update:selection",null),this.$emit("row-unselect",{originalEvent:e.originalEvent,data:t,index:e.index,type:"radiobutton"})):(this.$emit("update:selection",t),this.$emit("row-select",{originalEvent:e.originalEvent,data:t,index:e.index,type:"radiobutton"}))},toggleRowWithCheckbox(e){const t=e.data;if(this.isSelected(t)){const n=this.findIndexInSelection(t),i=this.selection.filter((r,s)=>s!=n);this.$emit("update:selection",i),this.$emit("row-unselect",{originalEvent:e.originalEvent,data:t,index:e.index,type:"checkbox"})}else{let n=this.selection?[...this.selection]:[];n=[...n,t],this.$emit("update:selection",n),this.$emit("row-select",{originalEvent:e.originalEvent,data:t,index:e.index,type:"checkbox"})}},toggleRowsWithCheckbox(e){if(this.selectAll!==null)this.$emit("select-all-change",e);else{const{originalEvent:t,checked:n}=e;let i=[];n?(i=this.frozenValue?[...this.frozenValue,...this.processedData]:this.processedData,this.$emit("row-select-all",{originalEvent:t,data:i})):this.$emit("row-unselect-all",{originalEvent:t}),this.$emit("update:selection",i)}},isSingleSelectionMode(){return this.selectionMode==="single"},isMultipleSelectionMode(){return this.selectionMode==="multiple"},isSelected(e){return e&&this.selection?this.dataKey?this.d_selectionKeys?this.d_selectionKeys[ve.resolveFieldData(e,this.dataKey)]!==void 0:!1:this.selection instanceof Array?this.findIndexInSelection(e)>-1:this.equals(e,this.selection):!1},findIndexInSelection(e){return this.findIndex(e,this.selection)},findIndex(e,t){let n=-1;if(t&&t.length){for(let i=0;i<t.length;i++)if(this.equals(e,t[i])){n=i;break}}return n},updateSelectionKeys(e){if(this.d_selectionKeys={},Array.isArray(e))for(let t of e)this.d_selectionKeys[String(ve.resolveFieldData(t,this.dataKey))]=1;else this.d_selectionKeys[String(ve.resolveFieldData(e,this.dataKey))]=1},updateExpandedRowKeys(e){if(e&&e.length){this.d_expandedRowKeys={};for(let t of e)this.d_expandedRowKeys[String(ve.resolveFieldData(t,this.dataKey))]=1}else this.d_expandedRowKeys=null},updateEditingRowKeys(e){if(e&&e.length){this.d_editingRowKeys={};for(let t of e)this.d_editingRowKeys[String(ve.resolveFieldData(t,this.dataKey))]=1}else this.d_editingRowKeys=null},equals(e,t){return this.compareSelectionBy==="equals"?e===t:ve.equals(e,t,this.dataKey)},selectRange(e){let t,n;this.rangeRowIndex>this.anchorRowIndex?(t=this.anchorRowIndex,n=this.rangeRowIndex):this.rangeRowIndex<this.anchorRowIndex?(t=this.rangeRowIndex,n=this.anchorRowIndex):(t=this.rangeRowIndex,n=this.rangeRowIndex),this.lazy&&this.paginator&&(t-=this.first,n-=this.first);const i=this.processedData;let r=[];for(let s=t;s<=n;s++){let a=i[s];r.push(a),this.$emit("row-select",{originalEvent:e,data:a,type:"row"})}this.$emit("update:selection",r)},exportCSV(e,t){let n="\uFEFF";t||(t=this.processedData,e&&e.selectionOnly?t=this.selection||[]:this.frozenValue&&(t=t?[...this.frozenValue,...t]:this.frozenValue));let i=!1;for(let s=0;s<this.columns.length;s++){let a=this.columns[s];this.columnProp(a,"exportable")!==!1&&this.columnProp(a,"field")&&(i?n+=this.csvSeparator:i=!0,n+='"'+(this.columnProp(a,"exportHeader")||this.columnProp(a,"header")||this.columnProp(a,"field"))+'"')}t&&t.forEach(s=>
700{n+=`
701`;let a=!1;for(let o=0;o<this.columns.length;o++){let l=this.columns[o];if(this.columnProp(l,"exportable")!==!1&&this.columnProp(l,"field")){a?n+=this.csvSeparator:a=!0;let c=ve.resolveFieldData(s,this.columnProp(l,"field"));c!=null?this.exportFunction?c=this.exportFunction({data:c,field:this.columnProp(l,"field")}):c=String(c).replace(/"/g,'""'):c="",n+='"'+c+'"'}}});let r=!1;for(let s=0;s<this.columns.length;s++){let a=this.columns[s];s===0&&(n+=`
702`),this.columnProp(a,"exportable")!==!1&&this.columnProp(a,"exportFooter")&&(r?n+=this.csvSeparator:r=!0,n+='"'+(this.columnProp(a,"exportFooter")||this.columnProp(a,"footer")||this.columnProp(a,"field"))+'"')}F.exportCSV(n,this.exportFilename)},resetPage(){this.d_first=0,this.$emit("update:first",this.d_first)},onColumnResizeStart(e){let t=F.getOffset(this.$el).left;this.resizeColumnElement=e.target.parentElement,this.columnResizing=!0,this.lastResizeHelperX=e.pageX-t+this.$el.scrollLeft,this.bindColumnResizeEvents()},onColumnResize(e){let t=F.getOffset(this.$el).left;F.addClass(this.$el,"p-unselectable-text"),this.$refs.resizeHelper.style.height=this.$el.offsetHeight+"px",this.$refs.resizeHelper.style.top="0px",this.$refs.resizeHelper.style.left=e.pageX-t+this.$el.scrollLeft+"px",this.$refs.resizeHelper.style.display="block"},onColumnResizeEnd(){let e=this.$refs.resizeHelper.offsetLeft-this.lastResizeHelperX,t=this.resizeColumnElement.offsetWidth,n=t+e,i=this.resizeColumnElement.style.minWidth||15;if(t+e>parseInt(i,10)){if(this.columnResizeMode==="fit"){let s=this.resizeColumnElement.nextElementSibling.offsetWidth-e;n>15&&s>15&&this.resizeTableCells(n,s)}else if(this.columnResizeMode==="expand"){const r=this.$refs.table.offsetWidth+e+"px",s=a=>{a&&(a.style.width=a.style.minWidth=r)};if(s(this.$refs.table),!this.virtualScrollerDisabled){const a=this.$refs.bodyRef&&this.$refs.bodyRef.$el,o=this.$refs.frozenBodyRef&&this.$refs.frozenBodyRef.$el;s(a),s(o)}this.resizeTableCells(n)}this.$emit("column-resize-end",{element:this.resizeColumnElement,delta:e})}this.$refs.resizeHelper.style.display="none",this.resizeColumn=null,F.removeClass(this.$el,"p-unselectable-text"),this.unbindColumnResizeEvents(),this.isStateful()&&this.saveState()},resizeTableCells(e,t){let n=F.index(this.resizeColumnElement),i=[];F.find(this.$refs.table,".p-datatable-thead > tr > th").forEach(o=>i.push(F.getOuterWidth(o))),this.destroyStyleElement(),this.createStyleElement();let s="",a=`.p-datatable[${this.attributeSelector}] > .p-datatable-wrapper ${this.virtualScrollerDisabled?"":"> .p-virtualscroller"} > .p-datatable-table`;i.forEach((o,l)=>{let c=l===n?e:t&&l===n+1?t:o,d=`width: ${c}px !important; max-width: ${c}px !important`;s+=`
703                    ${a} > .p-datatable-thead > tr > th:nth-child(${l+1}),
704                    ${a} > .p-datatable-tbody > tr > td:nth-child(${l+1}),
705                    ${a} > .p-datatable-tfoot > tr > td:nth-child(${l+1}) {
706                        ${d}
707                    }
708                `}),this.styleElement.innerHTML=s},bindColumnResizeEvents(){this.documentColumnResizeListener||(this.documentColumnResizeListener=document.addEventListener("mousemove",()=>{this.columnResizing&&this.onColumnResize(event)})),this.documentColumnResizeEndListener||(this.documentColumnResizeEndListener=document.addEventListener("mouseup",()=>{this.columnResizing&&(this.columnResizing=!1,this.onColumnResizeEnd())}))},unbindColumnResizeEvents(){this.documentColumnResizeListener&&(document.removeEventListener("document",this.documentColumnResizeListener),this.documentColumnResizeListener=null),this.documentColumnResizeEndListener&&(document.removeEventListener("document",this.documentColumnResizeEndListener),this.documentColumnResizeEndListener=null)},onColumnHeaderMouseDown(e){const t=e.originalEvent,n=e.column;this.reorderableColumns&&this.columnProp(n,"reorderableColumn")!==!1&&(t.target.nodeName==="INPUT"||t.target.nodeName==="TEXTAREA"||F.hasClass(t.target,"p-column-resizer")?t.currentTarget.draggable=!1:t.currentTarget.draggable=!0)},onColumnHeaderDragStart(e){if(this.columnResizing){e.preventDefault();return}this.colReorderIconWidth=F.getHiddenElementOuterWidth(this.$refs.reorderIndicatorUp),this.colReorderIconHeight=F.getHiddenElementOuterHeight(this.$refs.reorderIndicatorUp),this.draggedColumn=this.findParentHeader(e.target),e.dataTransfer.setData("text","b")},onColumnHeaderDragOver(e){let t=this.findParentHeader(e.target);if(this.reorderableColumns&&this.draggedColumn&&t){e.preventDefault();let n=F.getOffset(this.$el),i=F.getOffset(t);if(this.draggedColumn!==t){let r=i.left-n.left,s=i.left+t.offsetWidth/2;this.$refs.reorderIndicatorUp.style.top=i.top-n.top-(this.colReorderIconHeight-1)+"px",this.$refs.reorderIndicatorDown.style.top=i.top-n.top+t.offsetHeight+"px",e.pageX>s?(this.$refs.reorderIndicatorUp.style.left=r+t.offsetWidth-Math.ceil(this.colReorderIconWidth/2)+"px",this.$refs.reorderIndicatorDown.style.left=r+t.offsetWidth-Math.ceil(this.colReorderIconWidth/2)+"px",this.dropPosition=1):(this.$refs.reorderIndicatorUp.style.left=r-Math.ceil(this.colReorderIconWidth/2)+"px",this.$refs.reorderIndicatorDown.style.left=r-Math.ceil(this.colReorderIconWidth/2)+"px",this.dropPosition=-1),this.$refs.reorderIndicatorUp.style.display="block",this.$refs.reorderIndicatorDown.style.display="block"}}},onColumnHeaderDragLeave(e){this.reorderableColumns&&this.draggedColumn&&(e.preventDefault(),this.$refs.reorderIndicatorUp.style.display="none",this.$refs.reorderIndicatorDown.style.display="none")},onColumnHeaderDrop(e){if(e.preventDefault(),this.draggedColumn){let t=F.index(this.draggedColumn),n=F.index(this.findParentHeader(e.target)),i=t!==n;i&&(n-t===1&&this.dropPosition===-1||n-t===-1&&this.dropPosition===1)&&(i=!1),i&&(ve.reorderArray(this.columns,t,n),this.updateReorderableColumns(),this.$emit("column-reorder",{originalEvent:e,dragIndex:t,dropIndex:n})),this.$refs.reorderIndicatorUp.style.display="none",this.$refs.reorderIndicatorDown.style.display="none",this.draggedColumn.draggable=!1,this.draggedColumn=null,this.dropPosition=null}},findParentHeader(e){if(e.nodeName==="TH")return e;{let t=e.parentElement;for(;t.nodeName!=="TH"&&(t=t.parentElement,!!t););return t}},findColumnByKey(e,t){if(e&&e.length)for(let n=0;n<e.length;n++){let i=e[n];if(this.columnProp(i,"columnKey")===t||this.columnProp(i,"field")===t)return i}return null},onRowMouseDown(e){F.hasClass(e.target,"p-datatable-reorderablerow-handle")?e.currentTarget.draggable=!0:e.currentTarget.draggable=!1},onRowDragStart(e){const t=e.originalEvent,n=e.index;this.rowDragging=!0,this.draggedRowIndex=n,t.dataTransfer.setData("text","b")},onRowDragOver(e){const t=e.originalEvent,n=e.index;if(this.rowDragging&&this.draggedRowIndex!==n){let i=t.currentTarget,r=F.getOffset(i).top+F.getWindowScrollTop(),s=t.pageY,a=r+F.getOuterHeight(i)/2,o=i.previousElementSibling;s<a?(F.removeClass(i,"p-datatable-dragpoint-bottom"),this.droppedRowIndex=n,o?F.addClass(o,"p-datatable-dragpoint-bottom"):F.addClass(i,"p-datatable-dragpoint-top")):(o?F.removeClass(o,"p-datatable-dragpoint-bottom"):F.addClass(i,"p-datatable-dragpoint-top"),this.droppedRowIndex=n+1,F.addClass(i,"p-datatable-dragpoint-bottom")),t.preventDefault()}},onRowDragLeave(e){let t=e.currentTarget,n=t.previousElementSibling;n&&F.removeClass(n,"p-datatable-dragpoint-bottom"),F.removeClass(t,"p-datatable-dragpoint-bottom"),F.removeClass(t,"p-datatable-dragpoint-top")},onRowDragEnd(e){this.rowDragging=!1,this.draggedRowIndex=null,this.droppedRowIndex=null,e.currentTarget.draggable=!1},onRowDrop(e){if(this.droppedRowIndex!=null){let t=this.draggedRowIndex>this.droppedRowIndex?this.droppedRowIndex:this.droppedRowIndex===0?0:this.droppedRowIndex-1,n=[...this.processedData];ve.reorderArray(n,this.draggedRowIndex+this.d_first,t+this.d_first),this.$emit("row-reorder",{originalEvent:e,dragIndex:this.draggedRowIndex,dropIndex:t,value:n})}this.onRowDragLeave(e),this.onRowDragEnd(e),e.preventDefault()},toggleRow(e){let t=e.data,n,i,r=this.expandedRows?[...this.expandedRows]:[];this.dataKey?n=this.d_expandedRowKeys?this.d_expandedRowKeys[ve.resolveFieldData(t,this.dataKey)]!==void 0:!1:(i=this.findIndex(t,this.expandedRows),n=i>-1),n?(i==null&&(i=this.findIndex(t,this.expandedRows)),r.splice(i,1),this.$emit("update:ex
708pandedRows",r),this.$emit("row-collapse",e)):(r.push(t),this.$emit("update:expandedRows",r),this.$emit("row-expand",e))},toggleRowGroup(e){const t=e.originalEvent,n=e.data,i=ve.resolveFieldData(n,this.groupRowsBy);let r=this.expandedRowGroups?[...this.expandedRowGroups]:[];this.isRowGroupExpanded(n)?(r=r.filter(s=>s!==i),this.$emit("update:expandedRowGroups",r),this.$emit("rowgroup-collapse",{originalEvent:t,data:i})):(r.push(i),this.$emit("update:expandedRowGroups",r),this.$emit("rowgroup-expand",{originalEvent:t,data:i}))},isRowGroupExpanded(e){if(this.expandableRowGroups&&this.expandedRowGroups){let t=ve.resolveFieldData(e,this.groupRowsBy);return this.expandedRowGroups.indexOf(t)>-1}return!1},isStateful(){return this.stateKey!=null},getStorage(){switch(this.stateStorage){case"local":return window.localStorage;case"session":return window.sessionStorage;default:throw new Error(this.stateStorage+' is not a valid value for the state storage, supported values are "local" and "session".')}},saveState(){const e=this.getStorage();let t={};this.paginator&&(t.first=this.d_first,t.rows=this.d_rows),this.d_sortField&&(t.sortField=this.d_sortField,t.sortOrder=this.d_sortOrder),this.d_multiSortMeta&&(t.multiSortMeta=this.d_multiSortMeta),this.hasFilters&&(t.filters=this.filters),this.resizableColumns&&this.saveColumnWidths(t),this.reorderableColumns&&(t.columnOrder=this.d_columnOrder),this.expandedRows&&(t.expandedRows=this.expandedRows,t.expandedRowKeys=this.d_expandedRowKeys),this.expandedRowGroups&&(t.expandedRowGroups=this.expandedRowGroups),this.selection&&(t.selection=this.selection,t.selectionKeys=this.d_selectionKeys),Object.keys(t).length&&e.setItem(this.stateKey,JSON.stringify(t)),this.$emit("state-save",t)},restoreState(){const t=this.getStorage().getItem(this.stateKey),n=/\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}.\d{3}Z/,i=function(r,s){return typeof s=="string"&&n.test(s)?new Date(s):s};if(t){let r=JSON.parse(t,i);this.paginator&&(this.d_first=r.first,this.d_rows=r.rows),r.sortField&&(this.d_sortField=r.sortField,this.d_sortOrder=r.sortOrder),r.multiSortMeta&&(this.d_multiSortMeta=r.multiSortMeta),r.filters&&this.$emit("update:filters",r.filters),this.resizableColumns&&(this.columnWidthsState=r.columnWidths,this.tableWidthState=r.tableWidth),this.reorderableColumns&&(this.d_columnOrder=r.columnOrder),r.expandedRows&&(this.d_expandedRowKeys=r.expandedRowKeys,this.$emit("update:expandedRows",r.expandedRows)),r.expandedRowGroups&&this.$emit("update:expandedRowGroups",r.expandedRowGroups),r.selection&&(this.d_selectionKeys=r.d_selectionKeys,this.$emit("update:selection",r.selection)),this.$emit("state-restore",r)}},saveColumnWidths(e){let t=[];F.find(this.$el,".p-datatable-thead > tr > th").forEach(i=>t.push(F.getOuterWidth(i))),e.columnWidths=t.join(","),this.columnResizeMode==="expand"&&(e.tableWidth=F.getOuterWidth(this.$refs.table)+"px")},restoreColumnWidths(){if(this.columnWidthsState){let e=this.columnWidthsState.split(",");if(this.columnResizeMode==="expand"&&this.tableWidthState&&(this.$refs.table.style.width=this.tableWidthState,this.$refs.table.style.minWidth=this.tableWidthState,this.$el.style.width=this.tableWidthState),ve.isNotEmpty(e)){this.createStyleElement();let t="",n=`.p-datatable[${this.attributeSelector}] > .p-datatable-wrapper ${this.virtualScrollerDisabled?"":"> .p-virtualscroller"} > .p-datatable-table`;e.forEach((i,r)=>{let s=`width: ${i}px !important; max-width: ${i}px !important`;t+=`
709                            ${n} > .p-datatable-thead > tr > th:nth-child(${r+1}),
710                            ${n} > .p-datatable-tbody > tr > td:nth-child(${r+1}),
711                            ${n} > .p-datatable-tfoot > tr > td:nth-child(${r+1}) {
712                                ${s}
713                            }
714                        `}),this.styleElement.innerHTML=t}}},onCellEditInit(e){this.$emit("cell-edit-init",e)},onCellEditComplete(e){this.$emit("cell-edit-complete",e)},onCellEditCancel(e){this.$emit("cell-edit-cancel",e)},onRowEditInit(e){let t=this.editingRows?[...this.editingRows]:[];t.push(e.data),this.$emit("update:editingRows",t),this.$emit("row-edit-init",e)},onRowEditSave(e){let t=[...this.editingRows];t.splice(this.findIndex(e.data,t),1),this.$emit("update:editingRows",t),this.$emit("row-edit-save",e)},onRowEditCancel(e){let t=[...this.editingRows];t.splice(this.findIndex(e.data,t),1),this.$emit("update:editingRows",t),this.$emit("row-edit-cancel",e)},onEditingMetaChange(e){let{data:t,field:n,index:i,editing:r}=e,s={...this.d_editingMeta},a=s[i];if(r)!a&&(a=s[i]={data:{...t},fields:[]}),a.fields.push(n);else if(a){const o=a.fields.filter(l=>l!==n);o.length?a.fields=o:delete s[i]}this.d_editingMeta=s},clearEditingMetaData(){this.editMode&&(this.d_editingMeta={})},createLazyLoadEvent(e){return{originalEvent:e,first:this.d_first,rows:this.d_rows,sortField:this.d_sortField,sortOrder:this.d_sortOrder,multiSortMeta:this.d_multiSortMeta,filters:this.d_filters}},hasGlobalFilter(){return this.filters&&Object.prototype.hasOwnProperty.call(this.filters,"global")},getChildren(){return this.$slots.default?this.$slots.default():null},onFilterChange(e){this.d_filters=e},onFilterApply(){this.d_first=0,this.$emit("update:first",this.d_first),this.$emit("update:filters",this.d_filters),this.lazy&&this.$emit("filter",this.createLazyLoadEvent())},cloneFilters(){let e={};
714return this.filters&&Object.entries(this.filters).forEach(([t,n])=>{e[t]=n.operator?{operator:n.operator,constraints:n.constraints.map(i=>({...i}))}:{...n}}),e},updateReorderableColumns(){let e=[];this.columns.forEach(t=>e.push(this.columnProp(t,"columnKey")||this.columnProp(t,"field"))),this.d_columnOrder=e},createStyleElement(){this.styleElement=document.createElement("style"),this.styleElement.type="text/css",document.head.appendChild(this.styleElement)},createResponsiveStyle(){if(!this.responsiveStyleElement){this.responsiveStyleElement=document.createElement("style"),this.responsiveStyleElement.type="text/css",document.head.appendChild(this.responsiveStyleElement);let e=`.p-datatable-wrapper ${this.virtualScrollerDisabled?"":"> .p-virtualscroller"} > .p-datatable-table`,t=`.p-datatable[${this.attributeSelector}] > ${e}`,n=`.p-datatable[${this.attributeSelector}].p-datatable-gridlines > ${e}`,i=`
715@media screen and (max-width: ${this.breakpoint}) {
716    ${t} > .p-datatable-thead > tr > th,
717    ${t} > .p-datatable-tfoot > tr > td {
718        display: none !important;
719    }
720
721    ${t} > .p-datatable-tbody > tr > td {
722        display: flex;
723        width: 100% !important;
724        align-items: center;
725        justify-content: space-between;
726    }
727
728    ${t} > .p-datatable-tbody > tr > td:not(:last-child) {
729        border: 0 none;
730    }
731
732    ${n} > .p-datatable-tbody > tr > td:last-child {
733        border-top: 0;
734        border-right: 0;
735        border-left: 0;
736    }
737
738    ${t} > .p-datatable-tbody > tr > td > .p-column-title {
739        display: block;
740    }
741}
742`;this.responsiveStyleElement.innerHTML=i}},destroyResponsiveStyle(){this.responsiveStyleElement&&(document.head.removeChild(this.responsiveStyleElement),this.responsiveStyleElement=null)},destroyStyleElement(){this.styleElement&&(document.head.removeChild(this.styleElement),this.styleElement=null)},recursiveGetChildren(e,t){return t||(t=[]),e&&e.length&&e.forEach(n=>{n.children instanceof Array?t.concat(this.recursiveGetChildren(n.children,t)):n.type.name=="Column"&&t.push(n)}),t},dataToRender(e){const t=e||this.processedData;if(t&&this.paginator){const n=this.lazy?0:this.d_first;return t.slice(n,n+this.d_rows)}return t},getVirtualScrollerRef(){return this.$refs.virtualScroller},hasSpacerStyle(e){return ve.isNotEmpty(e)}},computed:{containerClass(){return["p-datatable p-component",{"p-datatable-hoverable-rows":this.rowHover||this.selectionMode,"p-datatable-resizable":this.resizableColumns,"p-datatable-resizable-fit":this.resizableColumns&&this.columnResizeMode==="fit","p-datatable-scrollable":this.scrollable,"p-datatable-flex-scrollable":this.scrollable&&this.scrollHeight==="flex","p-datatable-responsive-stack":this.responsiveLayout==="stack","p-datatable-responsive-scroll":this.responsiveLayout==="scroll","p-datatable-striped":this.stripedRows,"p-datatable-gridlines":this.showGridlines,"p-datatable-grouped-header":this.headerColumnGroup!=null,"p-datatable-grouped-footer":this.footerColumnGroup!=null}]},tableStyleClass(){return["p-datatable-table",{"p-datatable-scrollable-table":this.scrollable,"p-datatable-resizable-table":this.resizableColumns,"p-datatable-resizable-table-fit":this.resizableColumns&&this.columnResizeMode==="fit"},this.tableClass]},columns(){let e=this.getChildren();if(!e)return;const t=this.recursiveGetChildren(e,[]);if(this.reorderableColumns&&this.d_columnOrder){let n=[];for(let i of this.d_columnOrder){let r=this.findColumnByKey(t,i);r&&!this.columnProp(r,"hidden")&&n.push(r)}return[...n,...t.filter(i=>n.indexOf(i)<0)]}return t},headerColumnGroup(){const e=this.getChildren();if(e){for(let t of e)if(t.type.name==="ColumnGroup"&&this.columnProp(t,"type")==="header")return t}return null},footerColumnGroup(){const e=this.getChildren();if(e){for(let t of e)if(t.type.name==="ColumnGroup"&&this.columnProp(t,"type")==="footer")return t}return null},hasFilters(){return this.filters&&Object.keys(this.filters).length>0&&this.filters.constructor===Object},processedData(){let e=this.value||[];return this.lazy||e&&e.length&&(this.hasFilters&&(e=this.filter(e)),this.sorted&&(this.sortMode==="single"?e=this.sortSingle(e):this.sortMode==="multiple"&&(e=this.sortMultiple(e)))),e},totalRecordsLength(){if(this.lazy)return this.totalRecords;{const e=this.processedData;return e?e.length:0}},empty(){const e=this.processedData;return!e||e.length===0},paginatorTop(){return this.paginator&&(this.paginatorPosition!=="bottom"||this.paginatorPosition==="both")},paginatorBottom(){return this.paginator&&(this.paginatorPosition!=="top"||this.paginatorPosition==="both")},sorted(){return this.d_sortField||this.d_multiSortMeta&&this.d_multiSortMeta.length>0},allRowsSelected(){if(this.selectAll!==null)return this.selectAll;{const e=this.frozenValue?[...this.frozenValue,...this.processedData]:this.processedData;return ve.isNotEmpty(e)&&this.selection&&Array.isArray(this.selection)&&e.every(t=>this.selection.some(n=>this.equals(n,t)))}},attributeSelector(){return pt()},groupRowSortField(){return this.sortMode==="single"?this.sortField:this.d_groupRowsSortMeta?this.d_groupRowsSortMeta.field:null},virtualScrollerDisabled(){return ve.isEmpty(this.virtualScrollerOptions)||!this.scrollable}},components:{DTPaginator:Hf,DTTableHeader:em,DTTableBody:Zf,DTTableFooter:Jf,DTVirtualScroller:Li,ArrowDownIcon:If,ArrowUpIcon:Tf,SpinnerIcon:ps}};function y3(e,t,n,i,r,s){const a=le("SpinnerIcon"),o=le("DTPaginator"),l=le("DTTableHeader"),c=le("DTTableBody"),d=le("DTTableFooter"),u=le("DTVirtualScroller");return g(),S("div",R({class:s.containerClass,"data-scrollselectors":".p-datatable-wrapper"},e.ptm("root")),[he(e.$slots,"default"),n.loading?(g(),S("div",R({key:0,class:"p-datatable-loading-overlay p-component-overlay"},e.ptm("loadingOverlay")),[e.$slots.loading?he(e.$slots,"loading",{key:0}):(g(),S(J,{key:1},[e.$slots.loadingicon?(g(),Q(_e(e.$slots.loadingicon),{key:0,class:"p-datatable-loading-icon"})):n.loadingIcon?(g(),S("i",R({key:1,class:["p-datatable-loading-icon pi-spin",n.loadingIcon]},e.ptm("loadingIcon")),null,16)):(g(),Q(a,R({key:2,spin:"",class:"p-datatable-loading-icon"},e.ptm("loadingIcon")),null,16))],64))],16)):M("",!0),e.$slots.header?(g(),S("div",R({key:1,class:"p-datatable-header"},e.ptm("header")),[he(e.$slots,"header")],16)):M("",!0),s.paginatorTop?(g(),Q(o,{key:2,rows:r.d_rows,first:r.d_first,totalRecords:s.totalRecordsLength,pageLinkSize:n.pageLinkSize,template:n.paginatorTemplate,rowsPerPageOptions:n.rowsPerPageOptions,currentPageReportTemplate:n.currentPageReportTemplate,class:"p-paginator-top",onPage:t[0]||(t[0]=p=>s.onPage(p)),alwaysShow:n.alwaysShowPaginator,pt:e.ptm("paginator")},ii({_:2},[e.$slots.paginatorstart?{name:"start",fn:Ee(()=>[he(e.$slots,"paginatorstart")]),key:"0"}:void 0,e.$slots.paginatorend?{name:"end",fn:Ee(()=>[he(e.$slots,"paginatorend")]),key:"1"}:void 0,e.$slots.paginatorfirstpagelinkicon?{name:"firstpagelinkicon",fn:Ee(()=>[he(e.$slots,"paginatorfirstpagelinkicon")]),key:"2"}:void 0,e.$slots.paginatorprevpagelinkicon?{name:"prevpagelinkicon",fn:Ee(()=>[he(e.$slots,"paginatorprevpagelinkicon")]),key:"3"}:void 0,e.$slots.paginatornextpagelinkicon?{name:"nextpagelinkicon",fn:Ee(()=>[he(e.$slots,"paginatornextpagelinkicon")]),key:"4"}:void 0,e.$slots.paginatorlastpagelinkicon?{name:"lastpagelinkicon",fn:Ee(()=>[he(e.$slots,"paginatorlastpagelinkicon")]),key:"5"}:void 0]),1032,["rows","first","totalRecords","pageLinkSize","template","rowsPerPageOptions","currentPageReportTemplate","alwaysShow","pt"])):M("",!0),f("div",R({class:"p-datatable-wrapper",style:{maxHeight:s.virtualScrollerDisabled?n.scrollHeight:""}},e.ptm("wrapper")),[de(u,R({ref:"virtualScroller"},{...n.virtualScrollerOptions,...e.ptm("virtualScroller")},{items:s.processedData,columns:s.columns,style:n.scrollHeight!=="flex"?{height:n.scrollHeight}:void 0,scrollHeight:n.scrollHeight!=="flex"?void 0:"100%",disabled:s.virtualScrollerDisabled,loaderDisabled:"",inline:"",autoSize:"",showSpacer:!1}),{content:Ee(p=>[f("table",R({ref:"table",role:"table",class:s.tableStyleClass,style:[n.tableStyle,p.spacerStyle]},{...n.tableProps,...e.ptm("table")}),[de(l,{columnGroup:s.headerColumnGroup,columns:p.columns,rowGroupMode:n.rowGroupMode,groupRowsBy:n.groupRowsBy,groupRowSortField:s.groupRowSortField,reorderableColumns:n.reorderableColumns,resizableColumns:n.resizableColumns,allRowsSelected:s.allRowsSelected,empty:s.empty,sortMode:n.sortMode,sortField:r.d_
742sortField,sortOrder:r.d_sortOrder,multiSortMeta:r.d_multiSortMeta,filters:r.d_filters,filtersStore:n.filters,filterDisplay:n.filterDisplay,filterInputProps:n.filterInputProps,headerCheckboxIconTemplate:e.$slots.headercheckboxicon,onColumnClick:t[1]||(t[1]=h=>s.onColumnHeaderClick(h)),onColumnMousedown:t[2]||(t[2]=h=>s.onColumnHeaderMouseDown(h)),onFilterChange:s.onFilterChange,onFilterApply:s.onFilterApply,onColumnDragstart:t[3]||(t[3]=h=>s.onColumnHeaderDragStart(h)),onColumnDragover:t[4]||(t[4]=h=>s.onColumnHeaderDragOver(h)),onColumnDragleave:t[5]||(t[5]=h=>s.onColumnHeaderDragLeave(h)),onColumnDrop:t[6]||(t[6]=h=>s.onColumnHeaderDrop(h)),onColumnResizestart:t[7]||(t[7]=h=>s.onColumnResizeStart(h)),onCheckboxChange:t[8]||(t[8]=h=>s.toggleRowsWithCheckbox(h)),pt:e.pt},null,8,["columnGroup","columns","rowGroupMode","groupRowsBy","groupRowSortField","reorderableColumns","resizableColumns","allRowsSelected","empty","sortMode","sortField","sortOrder","multiSortMeta","filters","filtersStore","filterDisplay","filterInputProps","headerCheckboxIconTemplate","onFilterChange","onFilterApply","pt"]),n.frozenValue?(g(),Q(c,{key:0,ref:"frozenBodyRef",value:n.frozenValue,frozenRow:!0,class:"p-datatable-frozen-tbody",columns:p.columns,first:r.d_first,dataKey:n.dataKey,selection:n.selection,selectionKeys:r.d_selectionKeys,selectionMode:n.selectionMode,contextMenu:n.contextMenu,contextMenuSelection:n.contextMenuSelection,rowGroupMode:n.rowGroupMode,groupRowsBy:n.groupRowsBy,expandableRowGroups:n.expandableRowGroups,rowClass:n.rowClass,rowStyle:n.rowStyle,editMode:n.editMode,compareSelectionBy:n.compareSelectionBy,scrollable:n.scrollable,expandedRowIcon:n.expandedRowIcon,collapsedRowIcon:n.collapsedRowIcon,expandedRows:n.expandedRows,expandedRowKeys:r.d_expandedRowKeys,expandedRowGroups:n.expandedRowGroups,editingRows:n.editingRows,editingRowKeys:r.d_editingRowKeys,templates:e.$slots,responsiveLayout:n.responsiveLayout,isVirtualScrollerDisabled:!0,onRowgroupToggle:s.toggleRowGroup,onRowClick:t[9]||(t[9]=h=>s.onRowClick(h)),onRowDblclick:t[10]||(t[10]=h=>s.onRowDblClick(h)),onRowRightclick:t[11]||(t[11]=h=>s.onRowRightClick(h)),onRowTouchend:s.onRowTouchEnd,onRowKeydown:s.onRowKeyDown,onRowMousedown:s.onRowMouseDown,onRowDragstart:t[12]||(t[12]=h=>s.onRowDragStart(h)),onRowDragover:t[13]||(t[13]=h=>s.onRowDragOver(h)),onRowDragleave:t[14]||(t[14]=h=>s.onRowDragLeave(h)),onRowDragend:t[15]||(t[15]=h=>s.onRowDragEnd(h)),onRowDrop:t[16]||(t[16]=h=>s.onRowDrop(h)),onRowToggle:t[17]||(t[17]=h=>s.toggleRow(h)),onRadioChange:t[18]||(t[18]=h=>s.toggleRowWithRadio(h)),onCheckboxChange:t[19]||(t[19]=h=>s.toggleRowWithCheckbox(h)),onCellEditInit:t[20]||(t[20]=h=>s.onCellEditInit(h)),onCellEditComplete:t[21]||(t[21]=h=>s.onCellEditComplete(h)),onCellEditCancel:t[22]||(t[22]=h=>s.onCellEditCancel(h)),onRowEditInit:t[23]||(t[23]=h=>s.onRowEditInit(h)),onRowEditSave:t[24]||(t[24]=h=>s.onRowEditSave(h)),onRowEditCancel:t[25]||(t[25]=h=>s.onRowEditCancel(h)),editingMeta:r.d_editingMeta,onEditingMetaChange:s.onEditingMetaChange},null,8,["value","columns","first","dataKey","selection","selectionKeys","selectionMode","contextMenu","contextMenuSelection","rowGroupMode","groupRowsBy","expandableRowGroups","rowClass","rowStyle","editMode","compareSelectionBy","scrollable","expandedRowIcon","collapsedRowIcon","expandedRows","expandedRowKeys","expandedRowGroups","editingRows","editingRowKeys","templates","responsiveLayout","onRowgroupToggle","onRowTouchend","onRowKeydown","onRowMousedown","editingMeta","onEditingMetaChange"])):M("",!0),de(c,{ref:"bodyRef",value:s.dataToRender(p.rows),class:Oe(p.styleClass),columns:p.columns,empty:s.empty,first:r.d_first,dataKey:n.dataKey,selection:n.selection,selectionKeys:r.d_selectionKeys,selectionMode:n.selectionMode,contextMenu:n.contextMenu,contextMenuSelection:n.contextMenuSelection,rowGroupMode:n.rowGroupMode,groupRowsBy:n.groupRowsBy,expandableRowGroups:n.expandableRowGroups,rowClass:n.rowClass,rowStyle:n.rowStyle,editMode:n.editMode,compareSelectionBy:n.compareSelectionBy,scrollable:n.scrollable,expandedRowIcon:n.expandedRowIcon,collapsedRowIcon:n.collapsedRowIcon,expandedRows:n.expandedRows,expandedRowKeys:r.d_expandedRowKeys,expandedRowGroups:n.expandedRowGroups,editingRows:n.editingRows,editingRowKeys:r.d_editingRowKeys,templates:e.$slots,responsiveLayout:n.responsiveLayout,virtualScrollerContentProps:p,isVirtualScrollerDisabled:s.virtualScrollerDisabled,onRowgroupToggle:s.toggleRowGroup,onRowClick:t[26]||(t[26]=h=>
742s.onRowClick(h)),onRowDblclick:t[27]||(t[27]=h=>s.onRowDblClick(h)),onRowRightclick:t[28]||(t[28]=h=>s.onRowRightClick(h)),onRowTouchend:s.onRowTouchEnd,onRowKeydown:h=>s.onRowKeyDown(h,p),onRowMousedown:s.onRowMouseDown,onRowDragstart:t[29]||(t[29]=h=>s.onRowDragStart(h)),onRowDragover:t[30]||(t[30]=h=>s.onRowDragOver(h)),onRowDragleave:t[31]||(t[31]=h=>s.onRowDragLeave(h)),onRowDragend:t[32]||(t[32]=h=>s.onRowDragEnd(h)),onRowDrop:t[33]||(t[33]=h=>s.onRowDrop(h)),onRowToggle:t[34]||(t[34]=h=>s.toggleRow(h)),onRadioChange:t[35]||(t[35]=h=>s.toggleRowWithRadio(h)),onCheckboxChange:t[36]||(t[36]=h=>s.toggleRowWithCheckbox(h)),onCellEditInit:t[37]||(t[37]=h=>s.onCellEditInit(h)),onCellEditComplete:t[38]||(t[38]=h=>s.onCellEditComplete(h)),onCellEditCancel:t[39]||(t[39]=h=>s.onCellEditCancel(h)),onRowEditInit:t[40]||(t[40]=h=>s.onRowEditInit(h)),onRowEditSave:t[41]||(t[41]=h=>s.onRowEditSave(h)),onRowEditCancel:t[42]||(t[42]=h=>s.onRowEditCancel(h)),editingMeta:r.d_editingMeta,onEditingMetaChange:s.onEditingMetaChange,pt:e.pt},null,8,["value","class","columns","empty","first","dataKey","selection","selectionKeys","selectionMode","contextMenu","contextMenuSelection","rowGroupMode","groupRowsBy","expandableRowGroups","rowClass","rowStyle","editMode","compareSelectionBy","scrollable","expandedRowIcon","collapsedRowIcon","expandedRows","expandedRowKeys","expandedRowGroups","editingRows","editingRowKeys","templates","responsiveLayout","virtualScrollerContentProps","isVirtualScrollerDisabled","onRowgroupToggle","onRowTouchend","onRowKeydown","onRowMousedown","editingMeta","onEditingMetaChange","pt"]),s.hasSpacerStyle(p.spacerStyle)?(g(),S("tbody",R({key:1,style:{height:`calc(${p.spacerStyle.height} - ${p.rows.length*p.itemSize}px)`},class:"p-datatable-virtualscroller-spacer"},e.ptm("virtualScrollerSpacer")),null,16)):M("",!0),de(d,{columnGroup:s.footerColumnGroup,columns:p.columns,pt:e.pt},null,8,["columnGroup","columns","pt"])],16)]),_:1},16,["items","columns","style","scrollHeight","disabled"])],16),e.$slots.footer?(g(),S("div",R({key:3,class:"p-datatable-footer"},e.ptm("footer")),[he(e.$slots,"footer")],16)):M("",!0),s.paginatorBottom?(g(),Q(o,{key:4,rows:r.d_rows,first:r.d_first,totalRecords:s.totalRecordsLength,pageLinkSize:n.pageLinkSize,template:n.paginatorTemplate,rowsPerPageOptions:n.rowsPerPageOptions,currentPageReportTemplate:n.currentPageReportTemplate,class:"p-paginator-bottom",onPage:t[43]||(t[43]=p=>s.onPage(p)),alwaysShow:n.alwaysShowPaginator,pt:e.ptm("paginator")},ii({_:2},[e.$slots.paginatorstart?{name:"start",fn:Ee(()=>[he(e.$slots,"paginatorstart")]),key:"0"}:void 0,e.$slots.paginatorend?{name:"end",fn:Ee(()=>[he(e.$slots,"paginatorend")]),key:"1"}:void 0,e.$slots.paginatorfirstpagelinkicon?{name:"firstpagelinkicon",fn:Ee(()=>[he(e.$slots,"paginatorfirstpagelinkicon")]),key:"2"}:void 0,e.$slots.paginatorprevpagelinkicon?{name:"prevpagelinkicon",fn:Ee(()=>[he(e.$slots,"paginatorprevpagelinkicon")]),key:"3"}:void 0,e.$slots.paginatornextpagelinkicon?{name:"nextpagelinkicon",fn:Ee(()=>[he(e.$slots,"paginatornextpagelinkicon")]),key:"4"}:void 0,e.$slots.paginatorlastpagelinkicon?{name:"lastpagelinkicon",fn:Ee(()=>[he(e.$slots,"paginatorlastpagelinkicon")]),key:"5"}:void 0]),1032,["rows","first","totalRecords","pageLinkSize","template","rowsPerPageOptions","currentPageReportTemplate","alwaysShow","pt"])):M("",!0),f("div",R({ref:"resizeHelper",class:"p-column-resizer-helper",style:{display:"none"}},e.ptm("resizeHelper")),null,16),n.reorderableColumns?(g(),S("span",R({key:5,ref:"reorderIndicatorUp",class:"p-datatable-reorder-indicator-up",style:{position:"absolute",display:"none"}},e.ptm("reorderIndicatorUp")),[(g(),Q(_e(e.$slots.reorderindicatorupicon||"ArrowDownIcon")))],16)):M("",!0),n.reorderableColumns?(g(),S("span",R({key:6,ref:"reorderIndicatorDown",class:"p-datatable-reorder-indicator-down",style:{position:"absolute",display:"none"}},e.ptm("reorderIndicatorDown")),[(g(),Q(_e(e.$slots.reorderindicatordownicon||"ArrowUpIcon")))],16)):M("",!0)],16)}function b3(e,t){t===void 0&&(t={});var n=t.insertAt;if(!(typeof document>"u")){var i=document.head||document.getElementsByTagName("head")[0],r=document.createElement("style");r.type="text/css",n==="top"&&i.firstChild?i.insertBefore(r,i.firstChild):i.appendChild(r),r.styleSheet?r.styleSheet.cssText=e:r.appendChild(document.createTextNode(e))}}var v3=`
743.p-datatable {
744    position: relative;
745}
746.p-datatable > .p-datatable-wrapper {
747    overflow: auto;
748}
749.p-datatable-table {
750    border-spacing: 0px;
751    width: 100%;
752}
753.p-datatable .p-sortable-column {
754    cursor: pointer;
755    user-select: none;
756}
757.p-datatable .p-sortable-column .p-column-title,
758.p-datatable .p-sortable-column .p-sortable-column-icon,
759.p-datatable .p-sortable-column .p-sortable-column-badge {
760    vertical-align: middle;
761}
762.p-datatable .p-sortable-column .p-sortable-column-badge {
763    display: inline-flex;
764    align-items: center;
765    justify-content: center;
766}
767.p-datatable-hoverable-rows .p-selectable-row {
768    cursor: pointer;
769}
770
771/* Scrollable */
772.p-datatable-scrollable > .p-datatable-wrapper {
773    position: relative;
774}
775.p-datatable-scrollable-table > .p-datatable-thead {
776    position: sticky;
777    top: 0;
778    z-index: 1;
779}
780.p-datatable-scrollable-table > .p-datatable-frozen-tbody {
781    position: sticky;
782    z-index: 1;
783}
784.p-datatable-scrollable-table > .p-datatable-tfoot {
785    position: sticky;
786    bottom: 0;
787    z-index: 1;
788}
789.p-datatable-scrollable .p-frozen-column {
790    position: sticky;
791    background: inherit;
792}
793.p-datatable-scrollable th.p-frozen-column {
794    z-index: 1;
795}
796.p-datatable-flex-scrollable {
797    display: flex;
798    flex-direction: column;
799    height: 100%;
800}
801.p-datatable-flex-scrollable > .p-datatable-wrapper {
802    display: flex;
803    flex-direction: column;
804    flex: 1;
805    height: 100%;
806}
807.p-datatable-scrollable-table > .p-datatable-tbody > .p-rowgroup-header {
808    position: sticky;
809    z-index: 1;
810}
811
812/* Resizable */
813.p-datatable-resizable-table > .p-datatable-thead > tr > th,
814.p-datatable-resizable-table > .p-datatable-tfoot > tr > td,
815.p-datatable-resizable-table > .p-datatable-tbody > tr > td {
816    overflow: hidden;
817    white-space: nowrap;
818}
819.p-datatable-resizable-table > .p-datatable-thead > tr > th.p-resizable-column:not(.p-frozen-column) {
820    background-clip: padding-box;
821    position: relative;
822}
823.p-datatable-resizable-table-fit > .p-datatable-thead > tr > th.p-resizable-column:last-child .p-column-resizer {
824    display: none;
825}
826.p-datatable .p-column-resizer {
827    display: block;
828    position: absolute !important;
829    top: 0;
830    right: 0;
831    margin: 0;
832    width: 0.5rem;
833    height: 100%;
834    padding: 0px;
835    cursor: col-resize;
836    border: 1px solid transparent;
837}
838.p-datatable .p-column-header-content {
839    display: flex;
840    align-items: center;
841}
842.p-datatable .p-column-resizer-helper {
843    width: 1px;
844    position: absolute;
845    z-index: 10;
846    display: none;
847}
848.p-datatable .p-row-editor-init,
849.p-datatable .p-row-editor-save,
850.p-datatable .p-row-editor-cancel {
851    display: inline-flex;
852    align-items: center;
853    justify-content: center;
854    overflow: hidden;
855    position: relative;
856}
857
858/* Expand */
859.p-datatable .p-row-toggler {
860    display: inline-flex;
861    align-items: center;
862    justify-content: center;
863    overflow: hidden;
864    position: relative;
865}
866
867/* Reorder */
868.p-datatable-reorder-indicator-up,
869.p-datatable-reorder-indicator-down {
870    position: absolute;
871    display: none;
872}
873.p-reorderable-column,
874.p-datatable-reorderablerow-handle {
875    cursor: move;
876}
877
878/* Loader */
879.p-datatable .p-datatable-loading-overlay {
880    position: absolute;
881    display: flex;
882    align-items: center;
883    justify-content: center;
884    z-index: 2;
885}
886
887/* Filter */
888.p-column-filter-row {
889    display: flex;
890    align-items: center;
891    width: 100%;
892}
893.p-column-filter-menu {
894    display: inline-flex;
895    margin-left: auto;
896}
897.p-column-filter-row .p-column-filter-element {
898    flex: 1 1 auto;
899    width: 1%;
900}
901.p-column-filter-menu-button,
902.p-column-filter-clear-button {
903    display: inline-flex;
904    justify-content: center;
905    align-items: center;
906    cursor: pointer;
907    text-decoration: none;
908    overflow: hidden;
909    position: relative;
910}
911.p-column-filter-overlay {
912    position: absolute;
913    top: 0;
914    left: 0;
915}
916.p-column-filter-row-items {
917    margin: 0;
918    padding: 0;
919    list-style: none;
920}
921.p-column-filter-row-item {
922    cursor: pointer;
923}
924.p-column-filter-add-button,
925.p-column-filter-remove-button {
926    justify-content: center;
927}
928.p-column-filter-add-button .p-button-label,
929.p-column-filter-remove-button .p-button-label {
930    flex-grow: 0;
931}
932.p-column-filter-buttonbar {
933    display: flex;
934    align-items: center;
935    justify-content: space-between;
936}
937.p-column-filter-buttonbar .p-button:not(.p-button-icon-only) {
938    width: auto;
939}
940
941/* Responsive */
942.p-datatable .p-datatable-tbody > tr > td > .p-column-title {
943    display: none;
944}
945
946/* VirtualScroller */
947.p-datatable-virtualscroller-spacer {
948    display: flex;
949}
950.p-datatable .p-virtualscroller .p-virtualscroller-loading {
951    transform: none !important;
952    min-height: 0;
953    position: sticky;
954    top: 0;
955    left: 0;
956}
957`;b3(v3);tm.render=y3;var _3={name:"Column",extends:Ve,props:{columnKey:{type:null,default:null},field:{type:[String,Function],default:null},sortField:{type:[String,Function],default:null},filterField:{type:[String,Function],default:null},dataType:{type:String,default:"text"},sortable:{type:Boolean,default:!1},header:{type:null,default:null},footer:{type:null,default:null},style:{type:null,default:null},class:{type:String,default:null},headerStyle:{type:null,default:null},headerClass:{type:String,default:null},bodyStyle:{type:null,default:null},bodyClass:{type:String,default:null},footerStyle:{type:null,default:null},footerClass:{type:String,default:null},showFilterMenu:{type:Boolean,default:!0},showFilterOperator:{type:Boolean,default:!0},showClearButton:{type:Boolean,default:!0},showApplyButton:{type:Boolean,default:!0},showFilterMatchModes:{type:Boolean,default:!0},showAddButton:{type:Boolean,default:!0},filterMatchModeOptions:{type:Array,default:null},maxConstraints:{type:Number,default:2},excludeGlobalFilter:{type:Boolean,default:!1},filterHeaderClass:{type:String,default:null},filterHeaderStyle:{type:null,default:null},filterMenuClass:{type:String,default:null},filterMenuStyle:{type:null,default:null},selectionMode:{type:String,default:null},expander:{type:Boolean,default:!1},colspan:{type:Number,default:null},rowspan:{type:Number,default:null},rowReorder:{type:Boolean,default:!1},rowReorderIcon:{type:String,default:void 0},reorderableColumn:{type:Boolean,default:!0},rowEditor:{type:Boolean,default:!1},frozen:{type:Boolean,default:!1},alignFrozen:{type:String,default:"left"},exportable:{type:Boolean,default:!0},exportHeader:{type:String,default:null},exportFooter:{type:String,default:null},filterMatchMode:{type:String,default:null},hidden:{type:Boolean,default:!1}},render(){return null}},Vs={name:"ChevronLeftIcon",extends:ze};const w3=f("path",{d:"M9.61296 13C9.50997 13.0005 9.40792 12.9804 9.3128 12.9409C9.21767 12.9014 9.13139 12.8433 9.05902 12.7701L3.83313 7.54416C3.68634 7.39718 3.60388 7.19795 3.60388 6.99022C3.60388 6.78249 3.68634 6.58325 3.83313 6.43
957628L9.05902 1.21039C9.20762 1.07192 9.40416 0.996539 9.60724 1.00012C9.81032 1.00371 10.0041 1.08597 10.1477 1.22959C10.2913 1.37322 10.3736 1.56698 10.3772 1.77005C10.3808 1.97313 10.3054 2.16968 10.1669 2.31827L5.49496 6.99022L10.1669 11.6622C10.3137 11.8091 10.3962 12.0084 10.3962 12.2161C10.3962 12.4238 10.3137 12.6231 10.1669 12.7701C10.0945 12.8433 10.0083 12.9014 9.91313 12.9409C9.81801 12.9804 9.71596 13.0005 9.61296 13Z",fill:"currentColor"},null,-1),E3=[w3];function S3(e,t,n,i,r,s){return g(),S("svg",R({width:"14",height:"14",viewBox:"0 0 14 14",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e.pti()),E3,16)}Vs.render=S3;var sa={name:"ChevronUpIcon",extends:ze};const C3=f("path",{d:"M12.2097 10.4113C12.1057 10.4118 12.0027 10.3915 11.9067 10.3516C11.8107 10.3118 11.7237 10.2532 11.6506 10.1792L6.93602 5.46461L2.22139 10.1476C2.07272 10.244 1.89599 10.2877 1.71953 10.2717C1.54307 10.2556 1.3771 10.1808 1.24822 10.0593C1.11933 9.93766 1.035 9.77633 1.00874 9.6011C0.982477 9.42587 1.0158 9.2469 1.10338 9.09287L6.37701 3.81923C6.52533 3.6711 6.72639 3.58789 6.93602 3.58789C7.14565 3.58789 7.3467 3.6711 7.49502 3.81923L12.7687 9.09287C12.9168 9.24119 13 9.44225 13 9.65187C13 9.8615 12.9168 10.0626 12.7687 10.2109C12.616 10.3487 12.4151 10.4207 12.2097 10.4113Z",fill:"currentColor"},null,-1),I3=[C3];function T3(e,t,n,i,r,s){return g(),S("svg",R({width:"14",height:"14",viewBox:"0 0 14 14",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e.pti()),I3,16)}sa.render=T3;var nm={name:"GalleriaItem",extends:Ve,emits:["start-slideshow","stop-slideshow","update:activeIndex"],props:{circular:{type:Boolean,default:!1},activeIndex:{type:Number,default:0},value:{type:Array,default:null},showItemNavigators:{type:Boolean,default:!0},showIndicators:{type:Boolean,default:!0},slideShowActive:{type:Boolean,default:!0},changeItemOnIndicatorHover:{type:Boolean,default:!0},autoPlay:{type:Boolean,default:!1},templates:{type:null,default:null},id:{type:String,default:null}},mounted(){this.autoPlay&&this.$emit("start-slideshow")},methods:{next(){let e=this.activeIndex+1,t=this.circular&&this.value.length-1===this.activeIndex?0:e;this.$emit("update:activeIndex",t)},prev(){let e=this.activeIndex!==0?this.activeIndex-1:0,t=this.circular&&this.activeIndex===0?this.value.length-1:e;this.$emit("update:activeIndex",t)},stopSlideShow(){this.slideShowActive&&this.stopSlideShow&&this.$emit("stop-slideshow")},navBackward(e){this.stopSlideShow(),this.prev(),e&&e.cancelable&&e.preventDefault()},navForward(e){this.stopSlideShow(),this.next(),e&&e.cancelable&&e.preventDefault()},onIndicatorClick(e){this.stopSlideShow(),this.$emit("update:activeIndex",e)},onIndicatorMouseEnter(e){this.changeItemOnIndicatorHover&&(this.stopSlideShow(),this.$emit("update:activeIndex",e))},onIndicatorKeyDown(e,t){switch(e.code){case"Enter":case"Space":this.stopSlideShow(),this.$emit("update:activeIndex",t),e.preventDefault();break;case"ArrowDown":case"ArrowUp":e.preventDefault();break}},isIndicatorItemActive(e){return this.activeIndex===e},isNavBackwardDisabled(){return!this.circular&&this.activeIndex===0},isNavForwardDisabled(){return!this.circular&&this.activeIndex===this.value.length-1},ariaSlideNumber(e){return this.$primevue.config.locale.aria?this.$primevue.config.locale.aria.slideNumber.replace(/{slideNumber}/g,e):void 0},ariaPageLabel(e){return this.$primevue.config.locale.aria?this.$primevue.config.locale.aria.pageLabel.replace(/{page}/g,e):void 0}},computed:{activeItem(){return this.value[this.activeIndex]},navBackwardClass(){return["p-galleria-item-prev p-galleria-item-nav p-link",{"p-disabled":this.isNavBackwardDisabled()}]},navForwardClass(){return["p-galleria-item-next p-galleria-item-nav p-link",{"p-disabled":this.isNavForwardDisabled()}]},ariaSlideLabel(){return this.$primevue.config.locale.aria?this.$primevue.config.locale.aria.slide:void 0}},components:{ChevronLeftIcon:Vs,ChevronRightIcon:Rn},directives:{ripple:gt}};const P3=["disabled"],O3=["id","aria-label","aria-roledescription"],A3=["disabled"],k3=["aria-label","aria-selected","aria-controls","onClick","onMouseenter","onKeydown"],R3={key:0,type:"button",tabindex:"-1",class:"p-link"};function L3(e,t,n,i,r,s){const a=Xe("ripple");return g(),S("div",R({class:"p-galleria-item-wrapper"},e.ptm("itemWrapper")),[f("div",R({class:"p-galleria-item-container"},e.ptm("itemContainer")),[n.showItemNavigators?Ne((g(),S("button",R({key:0,type:"button",class:s.navBackwardClass,onClick:t[0]||(t[0]=o=>s.navBackward(o)),disabled:s.isNavBackwardDisabled()},e.ptm("previousItemButton")),[(g(),Q(_e(n.templates.previousitemicon||"ChevronLeftIcon"),R({class:"p-galleria-item-prev-icon"},e.ptm("previousItemIcon")),null,16))],16,P3)),[[a]]):M("",!0),f("div",R({id:n.id+"_item_"+n.activeIndex,class:"p-galleria-item",role:"group","aria-label":s.ariaSlideNumber(n.activeIndex+1),"aria-roledescription":s.ariaSlideLabel},e.ptm("item")),[n.templates.item?(g(),Q(_e(n.templates.item),{key:0,item:s.activeItem},null,8,["item"])):M("",!0)],16,O3),n.showItemNavigators?Ne((g(),S("button",R({key:1,type:"button",class:s.navForwardClass,onClick:t[1]||(t[1]=o=>s.navForward(o)),disabled:s.isNavForwardDisabled()},e.ptm("nextItemButton")),[(g(),Q(_e(n.templates.nextitemicon||"ChevronRightIcon"),R({class:"p-galleria-item-next-icon"},e.ptm("nextItemIcon")),null,16))],16,A3)),[[a]]):M("",!0),n.templates.caption?(g(),S("div",R({key:2,class:"p-galleria-caption"},e.ptm("caption")),[n.templates.caption?(g(),Q(_e(n.templates.caption),{key:0,item:s.activeItem},null,8,["item"])):M("",!0)],16)):M("",!0)],16),n.showIndicators?(g(),S("ul",R({key:0,class:"p-galleria-indicators p-reset"},e.ptm("indicators")),[(g(!0),S(J,null,ye(n.value,(o,l)=>(g(),S("li",R({key:`p-galleria-indicator-${l}`,class:["p-galleria-indicator",{"p-highlight":s.isIndicatorItemActive(l)}],tabindex:"0","aria-label":s.ariaPageLabel(l+1),"aria-selected":n.activeIndex===l,"aria-controls":n.id+"_item_"+l,onClick:c=>s.onIndicatorClick(l),onMouseenter:c=>s.onIndicatorMouseEnter(l),onKeydown:c=>s.onIndicatorKeyDown(c,l)},e.ptm("indicator")),[n.templates.indicator?M("",!0):(g(),S("button",R3)),n.templates.indicator?(g(),Q(_e(n.templates.indicator),{key:1,index:l},null,8,["index"])):M("",!0)],16,k3))),128))],16)):M("",!0)],16)}nm.render=L3;var sm={name:"GalleriaThumbnails",extends:Ve,emits:["stop-slideshow","update:activeIndex"],props:{containerId:{type:String,default:null},value:{type:Array,default:null},numVisible:{type:Number,default:3},activeIndex:{type:Number,default:0},isVertical:{type:Boolean,default:!1},slideShowActive:{type:Boolean,default:!1},circular:{type:Boolean,default:!1},responsiveOptions:{type:Array,default:null},contentHeight:{type:String,default:"300px"},showThumbnailNavigators:{type:Boolean,default:!0},templates:{type:null,default:null},prevButtonProps:{type:null,default:null},nextButtonProps:{type:null,default:null}},startPos:null,thumbnailsStyle:null,sortedResponsiveOptions:null,data(){return{d_numVisible:this.numVisible,d_oldNumVisible:this.numVisible,d_activeIndex:this.activeIndex,d_oldActiveItemIndex:this.activeIndex,totalShiftedItems:0,page:0}},watch:{numVisible(e,t){this.d_numVisible=e,this.d_oldNumVisible=t},activeIndex(e,t){this.d_activeIndex=e,this.d_oldActiveItemIndex=t}},mounted(){this.createStyle(),this.calculatePosition(),this.responsiveOptions&&this.bindDocumentListeners()},updated(){let e=this.totalShiftedItems;(this.d_oldNumVisible!==this.d_numVisible||this.d_oldActiveItemIndex!==this.d_activeIndex)&&(this.d_activeIndex<=this.getMedianItemIndex()?e=0:this.value.length-this.d_numVisible+this.getMedianItemIndex()<this.d_activeIndex?e=this.d_numVisible-this.value.length:this.value.length-this.d_numVisible<this.d_activeIndex&&this.d_numVisible
957%2===0?e=this.d_activeIndex*-1+this.getMedianItemIndex()+1:e=this.d_activeIndex*-1+this.getMedianItemIndex(),e!==this.totalShiftedItems&&(this.totalShiftedItems=e),this.$refs.itemsContainer.style.transform=this.isVertical?`translate3d(0, ${e*(100/this.d_numVisible)}%, 0)`:`translate3d(${e*(100/this.d_numVisible)}%, 0, 0)`,this.d_oldActiveItemIndex!==this.d_activeIndex&&(F.removeClass(this.$refs.itemsContainer,"p-items-hidden"),this.$refs.itemsContainer.style.transition="transform 500ms ease 0s"),this.d_oldActiveItemIndex=this.d_activeIndex,this.d_oldNumVisible=this.d_numVisible)},beforeUnmount(){this.responsiveOptions&&this.unbindDocumentListeners(),this.thumbnailsStyle&&this.thumbnailsStyle.parentNode.removeChild(this.thumbnailsStyle)},methods:{step(e){let t=this.totalShiftedItems+e;e<0&&-1*t+this.d_numVisible>this.value.length-1?t=this.d_numVisible-this.value.length:e>0&&t>0&&(t=0),this.circular&&(e<0&&this.value.length-1===this.d_activeIndex?t=0:e>0&&this.d_activeIndex===0&&(t=this.d_numVisible-this.value.length)),this.$refs.itemsContainer&&(F.removeClass(this.$refs.itemsContainer,"p-items-hidden"),this.$refs.itemsContainer.style.transform=this.isVertical?`translate3d(0, ${t*(100/this.d_numVisible)}%, 0)`:`translate3d(${t*(100/this.d_numVisible)}%, 0, 0)`,this.$refs.itemsContainer.style.transition="transform 500ms ease 0s"),this.totalShiftedItems=t},stopSlideShow(){this.slideShowActive&&this.stopSlideShow&&this.$emit("stop-slideshow")},getMedianItemIndex(){let e=Math.floor(this.d_numVisible/2);return this.d_numVisible%2?e:e-1},navBackward(e){this.stopSlideShow();let t=this.d_activeIndex!==0?this.d_activeIndex-1:0,n=t+this.totalShiftedItems;this.d_numVisible-n-1>this.getMedianItemIndex()&&(-1*this.totalShiftedItems!==0||this.circular)&&this.step(1);let i=this.circular&&this.d_activeIndex===0?this.value.length-1:t;this.$emit("update:activeIndex",i),e.cancelable&&e.preventDefault()},navForward(e){this.stopSlideShow();let t=this.d_activeIndex===this.value.length-1?this.value.length-1:this.d_activeIndex+1;t+this.totalShiftedItems>this.getMedianItemIndex()&&(-1*this.totalShiftedItems<this.getTotalPageNumber()-1||this.circular)&&this.step(-1);let n=this.circular&&this.value.length-1===this.d_activeIndex?0:t;this.$emit("update:activeIndex",n),e.cancelable&&e.preventDefault()},onItemClick(e){this.stopSlideShow();let t=e;if(t!==this.d_activeIndex){const n=t+this.totalShiftedItems;let i=0;t<this.d_activeIndex?(i=this.d_numVisible-n-1-this.getMedianItemIndex(),i>0&&-1*this.totalShiftedItems!==0&&this.step(i)):(i=this.getMedianItemIndex()-n,i<0&&-1*this.totalShiftedItems<this.getTotalPageNumber()-1&&this.step(i)),this.$emit("update:activeIndex",t)}},onThumbnailKeydown(e,t){switch((e.code==="Enter"||e.code==="Space")&&(this.onItemClick(t),e.preventDefault()),e.code){case"ArrowRight":this.onRightKey();break;case"ArrowLeft":this.onLeftKey();break;case"Home":this.onHomeKey(),e.preventDefault();break;case"End":this.onEndKey(),e.preventDefault();break;case"ArrowUp":case"ArrowDown":e.preventDefault();break;case"Tab":this.onTabKey();break}},onRightKey(){const e=F.find(this.$refs.itemsContainer,".p-galleria-thumbnail-item"),t=this.findFocusedIndicatorIndex();this.changedFocusedIndicator(t,t+1===e.length?e.length-1:t+1)},onLeftKey(){const e=this.findFocusedIndicatorIndex();this.changedFocusedIndicator(e,e-1<=0?0:e-1)},onHomeKey(){const e=this.findFocusedIndicatorIndex();this.changedFocusedIndicator(e,0)},onEndKey(){const e=F.find(this.$refs.itemsContainer,".p-galleria-thumbnail-item"),t=this.findFocusedIndicatorIndex();this.changedFocusedIndicator(t,e.length-1)},onTabKey(){const e=[...F.find(this.$refs.itemsContainer,".p-galleria-thumbnail-item")],t=e.findIndex(r=>F.hasClass(r,"p-galleria-thumbnail-item-current")),n=F.findSingle(this.$refs.itemsContainer,'.p-galleria-thumbnail-item > [tabindex="0"'),i=e.findIndex(r=>r===n.parentElement);e[i].children[0].tabIndex="-1",e[t].children[0].tabIndex="0"},findFocusedIndicatorIndex(){const e=[...F.find(this.$refs.itemsContainer,".p-galleria-thumbnail-item")],t=F.findSingle(this.$refs.itemsContainer,'.p-galleria-thumbn
957ail-item > [tabindex="0"]');return e.findIndex(n=>n===t.parentElement)},changedFocusedIndicator(e,t){const n=F.find(this.$refs.itemsContainer,".p-galleria-thumbnail-item");n[e].children[0].tabIndex="-1",n[t].children[0].tabIndex="0",n[t].children[0].focus()},onTransitionEnd(){this.$refs.itemsContainer&&(F.addClass(this.$refs.itemsContainer,"p-items-hidden"),this.$refs.itemsContainer.style.transition="")},onTouchStart(e){let t=e.changedTouches[0];this.startPos={x:t.pageX,y:t.pageY}},onTouchMove(e){e.cancelable&&e.preventDefault()},onTouchEnd(e){let t=e.changedTouches[0];this.isVertical?this.changePageOnTouch(e,t.pageY-this.startPos.y):this.changePageOnTouch(e,t.pageX-this.startPos.x)},changePageOnTouch(e,t){t<0?this.navForward(e):this.navBackward(e)},getTotalPageNumber(){return this.value.length>this.d_numVisible?this.value.length-this.d_numVisible+1:0},createStyle(){this.thumbnailsStyle||(this.thumbnailsStyle=document.createElement("style"),this.thumbnailsStyle.type="text/css",document.body.appendChild(this.thumbnailsStyle));let e=`
958                #${this.containerId} .p-galleria-thumbnail-item {
959                    flex: 1 0 ${100/this.d_numVisible}%
960                }
961            `;if(this.responsiveOptions){this.sortedResponsiveOptions=[...this.responsiveOptions],this.sortedResponsiveOptions.sort((t,n)=>{const i=t.breakpoint,r=n.breakpoint;let s=null;return i==null&&r!=null?s=-1:i!=null&&r==null?s=1:i==null&&r==null?s=0:typeof i=="string"&&typeof r=="string"?s=i.localeCompare(r,void 0,{numeric:!0}):s=i<r?-1:i>r?1:0,-1*s});for(let t=0;t<this.sortedResponsiveOptions.length;t++){let n=this.sortedResponsiveOptions[t];e+=`
962                        @media screen and (max-width: ${n.breakpoint}) {
963                            #${this.containerId} .p-galleria-thumbnail-item {
964                                flex: 1 0 ${100/n.numVisible}%
965                            }
966                        }
967                    `}}this.thumbnailsStyle.innerHTML=e},calculatePosition(){if(this.$refs.itemsContainer&&this.sortedResponsiveOptions){let e=window.innerWidth,t={numVisible:this.numVisible};for(let n=0;n<this.sortedResponsiveOptions.length;n++){let i=this.sortedResponsiveOptions[n];parseInt(i.breakpoint,10)>=e&&(t=i)}this.d_numVisible!==t.numVisible&&(this.d_numVisible=t.numVisible)}},bindDocumentListeners(){this.documentResizeListener||(this.documentResizeListener=()=>{this.calculatePosition()},window.addEventListener("resize",this.documentResizeListener))},unbindDocumentListeners(){this.documentResizeListener&&(window.removeEventListener("resize",this.documentResizeListener),this.documentResizeListener=null)},isNavBackwardDisabled(){return!this.circular&&this.d_activeIndex===0||this.value.length<=this.d_numVisible},isNavForwardDisabled(){return!this.circular&&this.d_activeIndex===this.value.length-1||this.value.length<=this.d_numVisible},firstItemAciveIndex(){return this.totalShiftedItems*-1},lastItemActiveIndex(){return this.firstItemAciveIndex()+this.d_numVisible-1},isItemActive(e){return this.firstItemAciveIndex()<=e&&this.lastItemActiveIndex()>=e},ariaPageLabel(e){return this.$primevue.config.locale.aria?this.$primevue.config.locale.aria.pageLabel.replace(/{page}/g,e):void 0}},computed:{navBackwardClass(){return["p-galleria-thumbnail-prev p-link",{"p-disabled":this.isNavBackwardDisabled()}]},navForwardClass(){return["p-galleria-thumbnail-next p-link",{"p-disabled":this.isNavForwardDisabled()}]},ariaPrevButtonLabel(){return this.$primevue.config.locale.aria?this.$primevue.config.locale.aria.prevPageLabel:void 0},ariaNextButtonLabel(){return this.$primevue.config.locale.aria?this.$primevue.config.locale.aria.nextPageLabel:void 0}},components:{ChevronLeftIcon:Vs,ChevronRightIcon:Rn,ChevronUpIcon:sa,ChevronDownIcon:_n},directives:{ripple:gt}};const N3=["disabled","aria-label"],D3=["aria-selected","aria-controls","onKeydown"],x3=["tabindex","aria-label","aria-current","onClick"],M3=["disabled","aria-label"];function F3(e,t,n,i,r,s){const a=Xe("ripple");return g(),S("div",R({class:"p-galleria-thumbnail-wrapper"},e.ptm("thumbnailWrapper")),[f("div",R({class:"p-galleria-thumbn
967ail-container"},e.ptm("thumbnailContainer")),[n.showThumbnailNavigators?Ne((g(),S("button",R({key:0,class:s.navBackwardClass,disabled:s.isNavBackwardDisabled(),type:"button","aria-label":s.ariaPrevButtonLabel,onClick:t[0]||(t[0]=o=>s.navBackward(o))},{...n.prevButtonProps,...e.ptm("previousThumbnailButton")}),[(g(),Q(_e(n.templates.previousthumbnailicon||(n.isVertical?"ChevronUpIcon":"ChevronLeftIcon")),R({class:"p-galleria-thumbnail-prev-icon"},e.ptm("previousThumbnailIcon")),null,16))],16,N3)),[[a]]):M("",!0),f("div",R({class:"p-galleria-thumbnail-items-container",style:{height:n.isVertical?n.contentHeight:""}},e.ptm("thumbnailItemsContainer")),[f("div",R({ref:"itemsContainer",class:"p-galleria-thumbnail-items",role:"tablist",onTransitionend:t[1]||(t[1]=(...o)=>s.onTransitionEnd&&s.onTransitionEnd(...o)),onTouchstart:t[2]||(t[2]=o=>s.onTouchStart(o)),onTouchmove:t[3]||(t[3]=o=>s.onTouchMove(o)),onTouchend:t[4]||(t[4]=o=>s.onTouchEnd(o))},e.ptm("thumbnailItems")),[(g(!0),S(J,null,ye(n.value,(o,l)=>(g(),S("div",R({key:`p-galleria-thumbnail-item-${l}`,class:["p-galleria-thumbnail-item",{"p-galleria-thumbnail-item-current":n.activeIndex===l,"p-galleria-thumbnail-item-active":s.isItemActive(l),"p-galleria-thumbnail-item-start":s.firstItemAciveIndex()===l,"p-galleria-thumbnail-item-end":s.lastItemActiveIndex()===l}],role:"tab","aria-selected":n.activeIndex===l,"aria-controls":n.containerId+"_item_"+l,onKeydown:c=>s.onThumbnailKeydown(c,l)},e.ptm("thumbnailItem")),[f("div",R({class:"p-galleria-thumbnail-item-content",tabindex:n.activeIndex===l?"0":"-1","aria-label":s.ariaPageLabel(l+1),"aria-current":n.activeIndex===l?"page":void 0,onClick:c=>s.onItemClick(l)},e.ptm("thumbnailItemContent")),[n.templates.thumbnail?(g(),Q(_e(n.templates.thumbnail),{key:0,item:o},null,8,["item"])):M("",!0)],16,x3)],16,D3))),128))],16)],16),n.showThumbnailNavigators?Ne((g(),S("button",R({key:1,class:s.navForwardClass,disabled:s.isNavForwardDisabled(),type:"button","aria-label":s.ariaNextButtonLabel,onClick:t[5]||(t[5]=o=>s.navForward(o))},{...n.nextButtonProps,...e.ptm("nextThumbnailButton")}),[(g(),Q(_e(n.templates.nextthumbnailicon||(n.isVertical?"ChevronDownIcon":"ChevronRightIcon")),R({class:"p-galleria-thumbnail-next-icon"},e.ptm("nextThumbnailIcon")),null,16))],16,M3)),[[a]]):M("",!0)],16)],16)}sm.render=F3;var im={name:"GalleriaContent",extends:Ve,inheritAttrs:!1,interval:null,emits:["activeitem-change","mask-hide"],data(){return{id:this.$attrs.id||pt(),activeIndex:this.$attrs.activeIndex,numVisible:this.$attrs.numVisible,slideShowActive:!1}},watch:{"$attrs.value":function(e){e&&e.length<this.numVisible&&(this.numVisible=e.length)},"$attrs.activeIndex":function(e){this.activeIndex=e},"$attrs.numVisible":function(e){this.numVisible=e},"$attrs.autoPlay":function(e){e?this.startSlideShow():this.stopSlideShow()}},updated(){this.$emit("activeitem-change",this.activeIndex)},beforeUnmount(){this.slideShowActive&&this.stopSlideShow()},methods:{isAutoPlayActive(){return this.slideShowActive},startSlideShow(){this.interval=setInterval(()=>{let e=this.$attrs.circular&&this.$attrs.value.length-1===this.activeIndex?0:this.activeIndex+1;this.activeIndex=e},this.$attrs.transitionInterval),this.slideShowActive=!0},stopSlideShow(){this.interval&&clearInterval(this.interval),this.slideShowActive=!1},getPositionClass(e,t){const i=["top","left","bottom","right"].find(r=>r===t);return i?`${e}-${i}`:""},isVertical(){return this.$attrs.thumbnailsPosition==="left"||this.$attrs.thumbnailsPosition==="right"}},computed:{galleriaClass(){const e=this.$attrs.showThumbnails&&this.getPositionClass("p-galleria-thumbnails",this.$attrs.thumbnailsPosition),t=this.$attrs.showIndicators&&this.getPositionClass("p-galleria-indicators",this.$attrs.indicatorsPosition);return["p-galleria p-component",{"p-galleria-fullscreen":this.$attrs.fullScreen,"p-galleria-indicator-onitem":this.$attrs.showIndicatorsOnItem,"p-galleria-item-nav-onhover":this.$attrs.showItemNavigatorsOnHover&&!this.$attrs.fullScreen},e,t,this.$attrs.containerClass]},closeAriaLabel(){return this.$primevue.config.locale.aria?this.$primevue.config.locale.aria.close:void 0}},components:{GalleriaItem:nm,GalleriaThumbnails:sm,TimesIcon:Qt},directives:{ripple:gt}};const V3=["id"],B3=["aria-label"],$3=["aria-live"];function U3(e,t,n,i,r,s){const a=le("GalleriaItem"),o=le("GalleriaThumbnails"),l=Xe("ripple");return e.$attrs.value&&e.$attrs.value.length>0?(g(),S("div",R({key:0,id:r.id,class:s.galleriaClass,style:e.$attrs.containerStyle},{...e.$attrs.containerProps,...e.ptm("root")}),[e.$attrs.fullScreen?Ne((g(),S("button",R({key:0,autofocus:"",type:"button",class:"p-galleria-close p-link","aria-label":s.closeAriaLabel,onClick:t[0]||(t[0]=c=>e.$emit("mask-hide"))},e.ptm("closeButton")),[(g(),Q(_e(e.$attrs.templates.closeicon||"TimesIcon"),R({class:"p-galleria-close-icon"},e.ptm("closeIcon")),null,16))],16,B3)),[[l]]):M("",!0),e.$attrs.templates&&e.$attrs.templates.header?(g(),S("div",R({key:1,class:"p-galleria-header"},e.ptm("header")),[(g(),Q(_e(e.$attrs.templates.header)))],16)):M("",!0),f("div",R({class:"p-galleria-content","aria-live":e.$attrs.autoPlay?"polite":"off"},e.ptm("content")),[de(a,{id:r.id,activeIndex:r.activeIndex,"onUpdate:activeIndex":t[1]||(t[1]=c=>r.activeIndex=c),slideShowActive:r.slideShowActive,"onUpdate:slideShowActive":t[2]||(t[2]=c=>r.slideShowActive=c),value:e.$attrs.value,circular:e.$attrs.circular,templates:e.$attrs.templates,showIndicators:e.$attrs.showIndicators,changeItemOnIndicatorHover:e.$attrs.changeItemOnIndicatorHover,showItemNavigators:e.$attrs.showItemNavigators,autoPlay:e.$attrs.autoPlay,onStartSlideshow:s.startSlideShow,onStopSlideshow:s.stopSlideShow,pt:e.pt},null,8,["id","activeIndex","slideShowActive","value","circular","templates","showIndicators","changeItemOnIndicatorHover","showItemNavigators","autoPlay","onStart
967Slideshow","onStopSlideshow","pt"]),e.$attrs.showThumbnails?(g(),Q(o,{key:0,activeIndex:r.activeIndex,"onUpdate:activeIndex":t[3]||(t[3]=c=>r.activeIndex=c),slideShowActive:r.slideShowActive,"onUpdate:slideShowActive":t[4]||(t[4]=c=>r.slideShowActive=c),containerId:r.id,value:e.$attrs.value,templates:e.$attrs.templates,numVisible:r.numVisible,responsiveOptions:e.$attrs.responsiveOptions,circular:e.$attrs.circular,isVertical:s.isVertical(),contentHeight:e.$attrs.verticalThumbnailViewPortHeight,showThumbnailNavigators:e.$attrs.showThumbnailNavigators,prevButtonProps:e.$attrs.prevButtonProps,nextButtonProps:e.$attrs.nextButtonProps,onStopSlideshow:s.stopSlideShow,pt:e.pt},null,8,["activeIndex","slideShowActive","containerId","value","templates","numVisible","responsiveOptions","circular","isVertical","contentHeight","showThumbnailNavigators","prevButtonProps","nextButtonProps","onStopSlideshow","pt"])):M("",!0)],16,$3),e.$attrs.templates&&e.$attrs.templates.footer?(g(),S("div",R({key:2,class:"p-galleria-footer"},e.ptm("footer")),[(g(),Q(_e(e.$attrs.templates.footer)))],16)):M("",!0)],16,V3)):M("",!0)}im.render=U3;var rm={name:"Galleria",extends:Ve,inheritAttrs:!1,emits:["update:activeIndex","update:visible"],props:{id:{type:String,default:null},value:{type:Array,default:null},activeIndex:{type:Number,default:0},fullScreen:{type:Boolean,default:!1},visible:{type:Boolean,default:!1},numVisible:{type:Number,default:3},responsiveOptions:{type:Array,default:null},showItemNavigators:{type:Boolean,default:!1},showThumbnailNavigators:{type:Boolean,default:!0},showItemNavigatorsOnHover:{type:Boolean,default:!1},changeItemOnIndicatorHover:{type:Boolean,default:!1},circular:{type:Boolean,default:!1},autoPlay:{type:Boolean,default:!1},transitionInterval:{type:Number,default:4e3},showThumbnails:{type:Boolean,default:!0},thumbnailsPosition:{type:String,default:"bottom"},verticalThumbnailViewPortHeight:{type:String,default:"300px"},showIndicators:{type:Boolean,default:!1},showIndicatorsOnItem:{type:Boolean,default:!1},indicatorsPosition:{type:String,default:"bottom"},baseZIndex:{type:Number,default:0},maskClass:{type:String,default:null},containerStyle:{type:null,default:null},containerClass:{type:null,default:null},containerProps:{type:null,default:null},prevButtonProps:{type:null,default:null},nextButtonProps:{type:null,default:null}},container:null,mask:null,data(){return{containerVisible:this.visible}},updated(){this.fullScreen&&this.visible&&(this.containerVisible=this.visible)},beforeUnmount(){this.fullScreen&&F.removeClass(document.body,"p-overflow-hidden"),this.mask=null,this.container&&(He.clear(this.container),this.container=null)},methods:{onBeforeEnter(e){He.set("modal",e,this.baseZIndex||this.$primevue.config.zIndex.modal)},onEnter(e){this.mask.style.zIndex=String(parseInt(e.style.zIndex,10)-1),F.addClass(document.body,"p-overflow-hidden"),this.focus()},onBeforeLeave(){F.addClass(this.mask,"p-component-overlay-leave")},onAfterLeave(e){He.clear(e),this.containerVisible=!1,F.removeClass(document.body,"p-overflow-hidden")},onActiveItemChange(e){this.activeIndex!==e&&this.$emit("update:activeIndex",e)},maskHide(){this.$emit("update:visible",!1)},containerRef(e){this.container=e},maskRef(e){this.mask=e},focus(){let e=this.container.$el.querySelector("[autofocus]");e&&e.focus()}},computed:{maskContentClass(){return["p-galleria-mask p-component-overlay p-component-overlay-enter",this.maskClass,{"p-input-filled":this.$primevue.config.inputStyle==="filled","p-ripple-disabled":this.$primevue.config.ripple===!1}]}},components:{GalleriaContent:im,Portal:Kt},directives:{focustrap:Fs}};const H3=["role","aria-modal"];function z3(e,t,n,i,r,s){const a=le("GalleriaContent"),o=le("Portal"),l=Xe("focustrap");return n.fullScreen?(g(),Q(o,{key:0},{default:Ee(()=>[r.containerVisible?(g(),S("div",R({key:0,ref:s.maskRef,class:s.maskContentClass,role:n.fullScreen?"dialog":"region","aria-modal":n.fullScreen?"true":void 0},e.ptm("mask")),[de($t,{name:"p-galleria",onBeforeEnter:s.onBeforeEnter,onEnter:s.onEnter,onBeforeLeave:s.onBeforeLeave,onAfterLeave:s.onAfterLeave,appear:""},{default:Ee(()=>[n.visible?Ne((g(),Q(a,R({key:0,ref:s.containerRef,onMaskHide:s.maskHide,templates:e.$slots,onActiveitemChange:s.onActiveItem
967Change,pt:e.pt},e.$props),null,16,["onMaskHide","templates","onActiveitemChange","pt"])),[[l]]):M("",!0)]),_:1},8,["onBeforeEnter","onEnter","onBeforeLeave","onAfterLeave"])],16,H3)):M("",!0)]),_:1})):(g(),Q(a,R({key:1,templates:e.$slots,onActiveitemChange:s.onActiveItemChange,pt:e.pt},e.$props),null,16,["templates","onActiveitemChange","pt"]))}function K3(e,t){t===void 0&&(t={});var n=t.insertAt;if(!(typeof document>"u")){var i=document.head||document.getElementsByTagName("head")[0],r=document.createElement("style");r.type="text/css",n==="top"&&i.firstChild?i.insertBefore(r,i.firstChild):i.appendChild(r),r.styleSheet?r.styleSheet.cssText=e:r.appendChild(document.createTextNode(e))}}var G3=`
968.p-galleria-content {
969    display: flex;
970    flex-direction: column;
971}
972.p-galleria-item-wrapper {
973    display: flex;
974    flex-direction: column;
975    position: relative;
976}
977.p-galleria-item-container {
978    position: relative;
979    display: flex;
980    height: 100%;
981}
982.p-galleria-item-nav {
983    position: absolute;
984    top: 50%;
985    margin-top: -0.5rem;
986    display: inline-flex;
987    justify-content: center;
988    align-items: center;
989    overflow: hidden;
990}
991.p-galleria-item-prev {
992    left: 0;
993    border-top-left-radius: 0;
994    border-bottom-left-radius: 0;
995}
996.p-galleria-item-next {
997    right: 0;
998    border-top-right-radius: 0;
999    border-bottom-right-radius: 0;
1000}
1001.p-galleria-item {
1002    display: flex;
1003    justify-content: center;
1004    align-items: center;
1005    height: 100%;
1006    width: 100%;
1007}
1008.p-galleria-item-nav-onhover .p-galleria-item-nav {
1009    pointer-events: none;
1010    opacity: 0;
1011    transition: opacity 0.2s ease-in-out;
1012}
1013.p-galleria-item-nav-onhover .p-galleria-item-wrapper:hover .p-galleria-item-nav {
1014    pointer-events: all;
1015    opacity: 1;
1016}
1017.p-galleria-item-nav-onhover .p-galleria-item-wrapper:hover .p-galleria-item-nav.p-disabled {
1018    pointer-events: none;
1019}
1020.p-galleria-caption {
1021    position: absolute;
1022    bottom: 0;
1023    left: 0;
1024    width: 100%;
1025}
1026
1027/* Thumbnails */
1028.p-galleria-thumbnail-wrapper {
1029    display: flex;
1030    flex-direction: column;
1031    overflow: auto;
1032    flex-shrink: 0;
1033}
1034.p-galleria-thumbnail-prev,
1035.p-galleria-thumbnail-next {
1036    align-self: center;
1037    flex: 0 0 auto;
1038    display: flex;
1039    justify-content: center;
1040    align-items: center;
1041    overflow: hidden;
1042    position: relative;
1043}
1044.p-galleria-thumbnail-prev span,
1045.p-galleria-thumbnail-next span {
1046    display: flex;
1047    justify-content: center;
1048    align-items: center;
1049}
1050.p-galleria-thumbnail-container {
1051    display: flex;
1052    flex-direction: row;
1053}
1054.p-galleria-thumbnail-items-container {
1055    overflow: hidden;
1056    width: 100%;
1057}
1058.p-galleria-thumbnail-items {
1059    display: flex;
1060}
1061.p-galleria-thumbnail-item {
1062    overflow: auto;
1063    display: flex;
1064    align-items: center;
1065    justify-content: center;
1066    cursor: pointer;
1067    opacity: 0.5;
1068}
1069.p-galleria-thumbnail-item:hover {
1070    opacity: 1;
1071    transition: opacity 0.3s;
1072}
1073.p-galleria-thumbnail-item-current {
1074    opacity: 1;
1075}
1076
1077/* Positions */
1078/* Thumbnails */
1079.p-galleria-thumbnails-left .p-galleria-content,
1080.p-galleria-thumbnails-right .p-galleria-content {
1081    flex-direction: row;
1082}
1083.p-galleria-thumbnails-left .p-galleria-item-wrapper,
1084.p-galleria-thumbnails-right .p-galleria-item-wrapper {
1085    flex-direction: row;
1086}
1087.p-galleria-thumbnails-left .p-galleria-item-wrapper,
1088.p-galleria-thumbnails-top .p-galleria-item-wrapper {
1089    order: 2;
1090}
1091.p-galleria-thumbnails-left .p-galleria-thumbnail-wrapper,
1092.p-galleria-thumbnails-top .p-galleria-thumbnail-wrapper {
1093    order: 1;
1094}
1095.p-galleria-thumbnails-left .p-galleria-thumbnail-container,
1096.p-galleria-thumbnails-right .p-galleria-thumbnail-container {
1097    flex-direction: column;
1098    flex-grow: 1;
1099}
1100.p-galleria-thumbnails-left .p-galleria-thumbnail-items,
1101.p-galleria-thumbnails-right .p-galleria-thumbnail-items {
1102    flex-direction: column;
1103    height: 100%;
1104}
1105
1106/* Indicators */
1107.p-galleria-indicators {
1108    display: flex;
1109    align-items: center;
1110    justify-content: center;
1111}
1112.p-galleria-indicator > button {
1113    display: inline-flex;
1114    align-items: center;
1115}
1116.p-galleria-indicators-left .p-galleria-item-wrapper,
1117.p-galleria-indicators-right .p-galleria-item-wrapper {
1118    flex-direction: row;
1119    align-items: center;
1120}
1121.p-galleria-indicators-left .p-galleria-item-container,
1122.p-galleria-indicators-top .p-galleria-item-container {
1123    order: 2;
1124}
1125.p-galleria-indicators-left .p-galleria-indicators,
1126.p-galleria-indicators-top .p-galleria-indicators {
1127    order: 1;
1128}
1129.p-galleria-indicators-left .p-galleria-indicators,
1130.p-galleria-indicators-right .p-galleria-indicators {
1131    flex-direction: column;
1132}
1133.p-galleria-indicator-onitem .p-galleria-indicators {
1134    position: absolute;
1135    display: flex;
1136}
1137.p-galleria-indicator-onitem.p-galleria-indicators-top .p-galleria-indicators {
1138    top: 0;
1139    left: 0;
1140    width: 100%;
1141    align-items: flex-start;
1142}
1143.p-galleria-indicator-onitem.p-galleria-indicators-right .p-galleria-indicators {
1144    right: 0;
1145    top: 0;
1146    height: 100%;
1147    align-items: flex-end;
1148}
1149.p-galleria-indicator-onitem.p-galleria-indicators-bottom .p-galleria-indicators {
1150    bottom: 0;
1151    left: 0;
1152    width: 100%;
1153    align-items: flex-end;
1154}
1155.p-galleria-indicator-onitem.p-galleria-indicators-left .p-galleria-indicators {
1156    left: 0;
1157    top: 0;
1158    height: 100%;
1159    align-items: flex-start;
1160}
1161
1162/* FullScreen */
1163.p-galleria-mask {
1164    position: fixed;
1165    top: 0;
1166    left: 0;
1167    width: 100%;
1168    height: 100%;
1169    display: flex;
1170    align-items: center;
1171    justify-content: center;
1172}
1173.p-galleria-close {
1174    position: absolute;
1175    top: 0;
1176    right: 0;
1177    display: flex;
1178    justify-content: center;
1179    align-items: center;
1180    overflow: hidden;
1181}
1182.p-galleria-mask .p-galleria-item-nav {
1183    position: fixed;
1184    top: 50%;
1185    margin-top: -0.5rem;
1186}
1187
1188/* Animation */
1189.p-galleria-enter-active {
1190    transition: all 150ms cubic-bezier(0, 0, 0.2, 1);
1191}
1192.p-galleria-leave-active {
1193    transition: all 150ms cubic-bezier(0.4, 0, 0.2, 1);
1194}
1195.p-galleria-enter-from,
1196.p-galleria-leave-to {
1197    opacity: 0;
1198    transform: scale(0.7);
1199}
1200.p-galleria-enter-active .p-galleria-item-nav {
1201    opacity: 0;
1202}
1203
1204/* Keyboard Support */
1205.p-items-hidden .p-galleria-thumbnail-item {
1206    visibility: hidden;
1207}
1208.p-items-hidden .p-galleria-thumbnail-item.p-galleria-thumbnail-item-active {
1209    visibility: visible;
1210}
1211`;K3(G3);rm.render=z3;var am={name:"TabView",extends:Ve,emits:["update:activeIndex","tab-change","tab-click"],props:{activeIndex:{type:Number,default:0},lazy:{type:Boolean,default:!1},scrollable:{type:Boolean,default:!1},tabindex:{type:Number,default:0},selectOnFocus:{type:Boolean,default:!1},previousButtonProps:{type:null,default:null},nextButtonProps:{type:null,default:null},prevIcon:{type:String,default:void 0},nextIcon:{type:String,default:void 0}},data(){return{id:this.$attrs.id,d_activeIndex:this.activeIndex,isPrevButtonDisabled:!0,isNextButtonDisabled:!1}},watch:{"$attrs.id":function(e){this.id=e||pt()},activeIndex(e){this.d_activeIndex=e,this.scrollInView({index:e})}},mounted(){this.id=this.id||pt(),this.updateInkBar(),this.scrollable&&this.updateButtonState()},updated(){this.updateInkBar()},methods:{isTabPanel(e){return e.type.name==="TabPanel"},isTabActive(e){return this.d_activeIndex===e},getTabProp(e,t){return e.props?e.props[t]:void 0},getKey(e,t){return this.getTabProp(e,"header")||t},getTabHeaderActionId(e){return`${this.id}_${e}_header_action`},getTabContentId(e){return`${this.id}_${e}_content`},getTabPT(e,t){return this.ptmo(this.getTabProp(e,"pt"),t,{props:e.props,parent:{props:this.$props,state:this.$data}})},onScroll(e){this.scrollable&&this.updateButtonState(),e.preventDefault()},onPrevButtonClick(){const e=this.$refs.content,t=F.getWidth(e),n=e.scrollLeft-t;e.scrollLeft=n<=0?0:n},onNextButtonClick(){const e=this.$refs.content,t=F.getWidth(e)-this.getVisibleButtonWidths(),n=e.scrollLeft+t,i=e.scrollWidth-t;e.scrollLeft=n>=i?i:n},onTabClick(e,t,n){this.changeActiveIndex(e,t,n),this.$emit("tab-click",{originalEvent:e,index:n})},onTabKeyDown(e,t,n){switch(e.code){case"ArrowLeft":this.onTabArrowLeftKey(e);break;case"ArrowRight":this.onTabArrowRightKey(e);break;case"Home":this.onTabHomeKey(e);break;case"End":this.onTabEndKey(e);break;case"PageDown":this.onPageDownKey(e);break;case"PageUp":this.onPageUpKey(e);break;case"Enter":case"Space":this.onTabEnterKey(e,t,n);break}},onTabArrowRightKey(e){const t=this.findNextHeaderAction(e.target.parentElement);t?this.changeFocusedTab(e,t):this.onTabHomeKey(e),e.preventDefault()},onTabArrowLeftKey(e){const t=this.findPrevHeaderAction(e.target.parentElement);t?this.changeFocusedTab(e,t):this.onTabEndKey(e),e.preventDefault()},onTabHomeKey(e){const t=this.findFirstHeaderAction();this.changeFocusedTab(e,t),e.preventDefault()},onTabEndKey(e){const t=this.findLastHeaderAction();this.changeFocusedTab(e,t),e.preventDefault()},onPageDownKey(e){this.scrollInView({index:this.$refs.nav.children.length-2}),e.preventDefault()},onPageUpKey(e){this.scrollInView({index:0}),e.preventDefault()},onTabEnterKey(e,t,n){this.changeActiveIndex(e,t,n),e.preventDefault()},findNextHeaderAction(e,t=!1){const n=t?e:e.nextElementSibling;return n?F.hasClass(n,"p-disabled")||F.hasClass(n,"p-tabview-ink-bar")?this.findNextHeaderAction(n):F.findSingle(n,".p-tabview-header-action"):null},findPrevHeaderAction(e,t=!1){const n=t?e:e.previousElementSibling;return n?F.hasClass(n,"p-disabled")||F.hasClass(n,"p-tabview-ink-bar")?this.findPrevHeaderAction(n):F.findSingle(n,".p-tabview-header-action"):null},findFirstHeaderAction(){return this.findNextHeaderAction(this.$refs.nav.firstElementChild,!0)},findLastHeaderAction(){return this.findPrevHeaderAction(this.$refs.nav.lastElementChild,!0)},changeActiveIndex(e,t,n){!this.getTabProp(t,"disabled")&&this.d_activeIndex!==n&&(this.d_activeIndex=n,this.$emit("update:activeIndex",n),this.$emit("tab-change",{originalEvent:e,index:n}),this.scrollInView({index:n}))},changeFocusedTab(e,t){if(t&&(F.focus(t),this.scrollInView({element:t}),this.selectOnFocus)){const n=parseInt(t.parentElement.dataset.index,10),i=this.tabs[n];this.changeActiveIndex(e,i,n)}},scrollInView({element:e,index:t=-1}){const n=e||this.$refs.nav.children[t];n&&n.scrollIntoView&&n.scrollIntoView({block:"nearest"})},updateInkBar(){let e=this.$refs.nav.children[this.d_activeIndex];this.$refs.inkbar.style.width=F.getWidth(e)+"px",this.$refs.inkbar.style.left=F.getOffset(e).left-F.getOffset(this.$refs.nav).left+"px"},updateButtonState(){const e=this.$refs.content,{scrollLeft:t,scrollWidth:n}=e,i=F.getWidth(e);this.isPrevButtonDisabled=t===0,this.isNextButtonDisabled=parseInt(t)===n-i},getVisibleButtonWidths(){const{prevBtn:e,nextBtn:t}=this.$refs;return[e,t].reduce((n,i)=>i?n+F.getWidth(i):n,0)},getTabHeaderClass(e,t){return["p-tabview-header",this.getTabProp(e,"headerClass"),{"p-highlight":this.d_activeIndex===t,"p-disabled":this.getTabProp(e,"disabled")}]},getTabContentClass(e){return["p-tabview-panel",this.getTabProp(e,"contentClass")]}},computed:{contentClasses(){return["p-tabview p-component",{"p-tabview-scrollable":this.scrollable}]},tabs(){return this.$slots.default().reduce((e,t)=>
1211(this.isTabPanel(t)?e.push(t):t.children&&t.children instanceof Array&&t.children.forEach(n=>{this.isTabPanel(n)&&e.push(n)}),e),[])},prevButtonAriaLabel(){return this.$primevue.config.locale.aria?this.$primevue.config.locale.aria.previous:void 0},nextButtonAriaLabel(){return this.$primevue.config.locale.aria?this.$primevue.config.locale.aria.next:void 0}},directives:{ripple:gt},components:{ChevronLeftIcon:Vs,ChevronRightIcon:Rn}};const j3=["tabindex","aria-label"],Y3=["data-index"],W3=["id","tabindex","aria-disabled","aria-selected","aria-controls","onClick","onKeydown"],Q3=["tabindex","aria-label"],Z3=["aria-labelledby"];function q3(e,t,n,i,r,s){const a=Xe("ripple");return g(),S("div",R({class:s.contentClasses},e.ptm("root")),[f("div",R({class:"p-tabview-nav-container"},e.ptm("navcontainer")),[n.scrollable&&!r.isPrevButtonDisabled?Ne((g(),S("button",R({key:0,ref:"prevBtn",type:"button",class:"p-tabview-nav-prev p-tabview-nav-btn p-link",tabindex:n.tabindex,"aria-label":s.prevButtonAriaLabel,onClick:t[0]||(t[0]=(...o)=>s.onPrevButtonClick&&s.onPrevButtonClick(...o))},{...n.previousButtonProps,...e.ptm("prevbutton")}),[he(e.$slots,"previcon",{},()=>[(g(),Q(_e(n.prevIcon?"span":"ChevronLeftIcon"),R({"aria-hidden":"true",class:n.prevIcon},e.ptm("previcon")),null,16,["class"]))])],16,j3)),[[a]]):M("",!0),f("div",R({ref:"content",class:"p-tabview-nav-content",onScroll:t[1]||(t[1]=(...o)=>s.onScroll&&s.onScroll(...o))},e.ptm("navcontent")),[f("ul",R({ref:"nav",class:"p-tabview-nav",role:"tablist"},e.ptm("nav")),[(g(!0),S(J,null,ye(s.tabs,(o,l)=>(g(),S("li",R({key:s.getKey(o,l),style:s.getTabProp(o,"headerStyle"),class:s.getTabHeaderClass(o,l),role:"presentation","data-index":l},{...s.getTabProp(o,"headerProps"),...s.getTabPT(o,"root"),...s.getTabPT(o,"header")}),[Ne((g(),S("a",R({id:s.getTabHeaderActionId(l),class:"p-tabview-nav-link p-tabview-header-action",tabindex:s.getTabProp(o,"disabled")||!s.isTabActive(l)?-1:n.tabindex,role:"tab","aria-disabled":s.getTabProp(o,"disabled"),"aria-selected":s.isTabActive(l),"aria-controls":s.getTabContentId(l),onClick:c=>s.onTabClick(c,o,l),onKeydown:c=>s.onTabKeyDown(c,o,l)},{...s.getTabProp(o,"headerActionProps"),...s.getTabPT(o,"headeraction")}),[o.props&&o.props.header?(g(),S("span",R({key:0,class:"p-tabview-title"},s.getTabPT(o,"headertitle")),N(o.props.header),17)):M("",!0),o.children&&o.children.header?(g(),Q(_e(o.children.header),{key:1})):M("",!0)],16,W3)),[[a]])],16,Y3))),128)),f("li",R({ref:"inkbar",class:"p-tabview-ink-bar",role:"presentation","aria-hidden":"true"},e.ptm("inkbar")),null,16)],16)],16),n.scrollable&&!r.isNextButtonDisabled?Ne((g(),S("button",R({key:1,ref:"nextBtn",type:"button",class:"p-tabview-nav-next p-tabview-nav-btn p-link",tabindex:n.tabindex,"aria-label":s.nextButtonAriaLabel,onClick:t[2]||(t[2]=(...o)=>s.onNextButtonClick&&s.onNextButtonClick(...o))},{...n.nextButtonProps,...e.ptm("nextbutton")}),[he(e.$slots,"nexticon",{},()=>[(g(),Q(_e(n.nextIcon?"span":"ChevronRightIcon"),R({"aria-hidden":"true",class:n.nextIcon},e.ptm("nexticon")),null,16,["class"]))])],16,Q3)),[[a]]):M("",!0)],16),f("div",R({class:"p-tabview-panels"},e.ptm("panelcontainer")),[(g(!0),S(J,null,ye(s.tabs,(o,l)=>(g(),S(J,{key:s.getKey(o,l)},[!n.lazy||s.isTabActive(l)?Ne((g(),S("div",R({key:0,style:s.getTabProp(o,"contentStyle"),class:s.getTabContentClass(o),role:"tabpanel","aria-labelledby":s.getTabHeaderActionId(l)},{...s.getTabProp(o,"contentProps"),...s.getTabPT(o,"root"),...s.getTabPT(o,"content")}),[(g(),Q(_e(o)))],16,Z3)),[[mt,n.lazy?!0:s.isTabActive(l)]]):M("",!0)],64))),128))],16)],16)}function J3(e,t){t===void 0&&(t={});var n=t.insertAt;if(!(typeof document>"u")){var i=document.head||document.getElementsByTagName("head")[0],r=document.createElement("style");r.type="text/css",n==="top"&&i.firstChild?i.insertBefore(r,i.firstChild):i.appendChild(r),r.styleSheet?r.styleSheet.cssText=e:r.appendChild(document.createTextNode(e))}}var X3=`
1212.p-tabview-nav-container {
1213    position: relative;
1214}
1215.p-tabview-scrollable .p-tabview-nav-container {
1216    overflow: hidden;
1217}
1218.p-tabview-nav-content {
1219    overflow-x: auto;
1220    overflow-y: hidden;
1221    scroll-behavior: smooth;
1222    scrollbar-width: none;
1223    overscroll-behavior: contain auto;
1224}
1225.p-tabview-nav {
1226    display: flex;
1227    margin: 0;
1228    padding: 0;
1229    list-style-type: none;
1230    flex: 1 1 auto;
1231}
1232.p-tabview-header-action {
1233    cursor: pointer;
1234    user-select: none;
1235    display: flex;
1236    align-items: center;
1237    position: relative;
1238    text-decoration: none;
1239    overflow: hidden;
1240}
1241.p-tabview-ink-bar {
1242    display: none;
1243    z-index: 1;
1244}
1245.p-tabview-header-action:focus {
1246    z-index: 1;
1247}
1248.p-tabview-title {
1249    line-height: 1;
1250    white-space: nowrap;
1251}
1252.p-tabview-nav-btn {
1253    position: absolute;
1254    top: 0;
1255    z-index: 2;
1256    height: 100%;
1257    display: flex;
1258    align-items: center;
1259    justify-content: center;
1260}
1261.p-tabview-nav-prev {
1262    left: 0;
1263}
1264.p-tabview-nav-next {
1265    right: 0;
1266}
1267.p-tabview-nav-content::-webkit-scrollbar {
1268    display: none;
1269}
1270`;J3(X3);am.render=q3;var om={name:"TabPanel",extends:Ve,props:{header:null,headerStyle:null,headerClass:null,headerProps:null,headerActionProps:null,contentStyle:null,contentClass:null,contentProps:null,disabled:Boolean}};function eL(e,t,n,i,r,s){return he(e.$slots,"default")}om.render=eL;var lm={name:"Avatar",extends:Ve,emits:["error"],props:{label:{type:String,default:null},icon:{type:String,default:null},image:{type:String,default:null},size:{type:String,default:"normal"},shape:{type:String,default:"square"},"aria-labelledby":{type:String,default:null},"aria-label":{type:String,default:null}},methods:{onError(){this.$emit("error")}},computed:{containerClass(){return["p-avatar p-component",{"p-avatar-image":this.image!=null,"p-avatar-circle":this.shape==="circle","p-avatar-lg":this.size==="large","p-avatar-xl":this.size==="xlarge"}]}}};const tL=["aria-labelledby","aria-label"],nL=["src","alt"];function sL(e,t,n,i,r,s){return g(),S("div",R({class:s.containerClass,"aria-labelledby":e.ariaLabelledby,"aria-label":e.ariaLabel},e.ptm("root")),[he(e.$slots,"default",{},()=>[n.label?(g(),S("span",R({key:0,class:"p-avatar-text"},e.ptm("label")),N(n.label),17)):e.$slots.icon?(g(),Q(_e(e.$slots.icon),R({key:1,class:"p-avatar-icon"},e.ptm("icon")),null,16)):n.icon?(g(),S("span",R({key:2,class:["p-avatar-icon",n.icon]},e.ptm("icon")),null,16)):n.image?(g(),S("img",R({key:3,src:n.image,alt:e.ariaLabel,onError:t[0]||(t[0]=(...a)=>s.onError&&s.onError(...a))},e.ptm("image")),null,16,nL)):M("",!0)])],16,tL)}function iL(e,t){t===void 0&&(t={});var n=t.insertAt;if(!(typeof document>"u")){var i=document.head||document.getElementsByTagName("head")[0],r=document.createElement("style");r.type="text/css",n==="top"&&i.firstChild?i.insertBefore(r,i.firstChild):i.appendChild(r),r.styleSheet?r.styleSheet.cssText=e:r.appendChild(document.createTextNode(e))}}var rL=`
1271.p-avatar {
1272    display: inline-flex;
1273    align-items: center;
1274    justify-content: center;
1275    width: 2rem;
1276    height: 2rem;
1277    font-size: 1rem;
1278}
1279.p-avatar.p-avatar-image {
1280    background-color: transparent;
1281}
1282.p-avatar.p-avatar-circle {
1283    border-radius: 50%;
1284}
1285.p-avatar-circle img {
1286    border-radius: 50%;
1287}
1288.p-avatar .p-avatar-icon {
1289    font-size: 1rem;
1290}
1291.p-avatar img {
1292    width: 100%;
1293    height: 100%;
1294}
1295`;iL(rL);lm.render=sL;var cm={name:"WindowMaximizeIcon",extends:ze};const aL=f("g",{"clip-path":"url(#clip0_414_20927)"},[f("path",{"fill-rule":"evenodd","clip-rule":"evenodd",d:"M7 14H11.8C12.3835 14 12.9431 13.7682 13.3556 13.3556C13.7682 12.9431 14 12.3835 14 11.8V2.2C14 1.61652 13.7682 1.05694 13.3556 0.644365C12.9431 0.231785 12.3835 0 11.8 0H2.2C1.61652 0 1.05694 0.231785 0.644365 0.644365C0.231785 1.05694 0 1.61652 0 2.2V7C0 7.15913 0.063214 7.31174 0.175736 7.42426C0.288258 7.53679 0.44087 7.6 0.6 7.6C0.75913 7.6 0.911742 7.53679 1.02426 7.42426C1.13679 7.31174 1.2 7.15913 1.2 7V2.2C1.2 1.93478 1.30536 1.68043 1.49289 1.49289C1.68043 1.30536 1.93478 1.2 2.2 1.2H11.8C12.0652 1.2 12.3196 1.30536 12.5071 1.49289C12.6946 1.68043 12.8 1.93478 12.8 2.2V11.8C12.8 12.0652 12.6946 12.3196 12.5071 12.5071C12.3196 12.6946 12.0652 12.8 11.8 12.8H7C6.84087 12.8 6.68826 12.8632 6.57574 12.9757C6.46321 13.0883 6.4 13.2409 6.4 13.4C6.4 13.5591 6.46321 13.7117 6.57574 13.8243C6.68826 13.9368 6.84087 14 7 14ZM9.77805 7.42192C9.89013 7.534 10.0415 7.59788 10.2 7.59995C10.3585 7.59788 10.5099 7.534 10.622 7.42192C10.7341 7.30985 10.798 7.15844 10.8 6.99995V3.94242C10.8066 3.90505 10.8096 3.86689 10.8089 3.82843C10.8079 3.77159 10.7988 3.7157 10.7824 3.6623C10.756 3.55552 10.701 3.45698 10.622 3.37798C10.5099 3.2659 10.3585 3.20202 10.2 3.19995H7.00002C6.84089 3.19995 6.68828 3.26317 6.57576 3.37569C6.46324 3.48821 6.40002 3.64082 6.40002 3.79995C6.40002 3.95908 6.46324 4.11169 6.57576 4.22422C6.68828 4.33674 6.84089 4.39995 7.00002 4.39995H8.80006L6.19997 7.00005C6.10158 7.11005 6.04718 7.25246 6.04718 7.40005C6.04718 7.54763 6.10158 7.69004 6.19997 7.80005C6.30202 7.91645 6.44561 7.98824 6.59997 8.00005C6.75432 7.98824 6.89791 7.91645 6.99997 7.80005L9.60002 5.26841V6.99995C9.6021 7.15844 9.66598 7.30985 9.77805 7.42192ZM1.4 14H3.8C4.17066 13.9979 4.52553 13.8498 4.78763 13.5877C5.04973 13.3256 5.1979 12.9707 5.2 12.6V10.2C5.1979 9.82939 5.04973 9.47452 4.78763 9.21242C4.52553 8.95032 4.17066 8.80215 3.8 8.80005H1.4C1.02934 8.80215 0.674468 8.95032 0.412371 9.21242C0.150274 9.47452 0.00210008 9.82939 0 10.2V12.6C0.00210008 12.9707 0.150274 13.3256 0.412371 13.5877C0.
1295674468 13.8498 1.02934 13.9979 1.4 14ZM1.25858 10.0586C1.29609 10.0211 1.34696 10 1.4 10H3.8C3.85304 10 3.90391 10.0211 3.94142 10.0586C3.97893 10.0961 4 10.147 4 10.2V12.6C4 12.6531 3.97893 12.704 3.94142 12.7415C3.90391 12.779 3.85304 12.8 3.8 12.8H1.4C1.34696 12.8 1.29609 12.779 1.25858 12.7415C1.22107 12.704 1.2 12.6531 1.2 12.6V10.2C1.2 10.147 1.22107 10.0961 1.25858 10.0586Z",fill:"currentColor"})],-1),oL=f("defs",null,[f("clipPath",{id:"clip0_414_20927"},[f("rect",{width:"14",height:"14",fill:"white"})])],-1),lL=[aL,oL];function cL(e,t,n,i,r,s){return g(),S("svg",R({width:"14",height:"14",viewBox:"0 0 14 14",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e.pti()),lL,16)}cm.render=cL;var dm={name:"WindowMinimizeIcon",extends:ze};const dL=f("g",{"clip-path":"url(#clip0_414_20939)"},[f("path",{"fill-rule":"evenodd","clip-rule":"evenodd",d:"M11.8 0H2.2C1.61652 0 1.05694 0.231785 0.644365 0.644365C0.231785 1.05694 0 1.61652 0 2.2V7C0 7.15913 0.063214 7.31174 0.175736 7.42426C0.288258 7.53679 0.44087 7.6 0.6 7.6C0.75913 7.6 0.911742 7.53679 1.02426 7.42426C1.13679 7.31174 1.2 7.15913 1.2 7V2.2C1.2 1.93478 1.30536 1.68043 1.49289 1.49289C1.68043 1.30536 1.93478 1.2 2.2 1.2H11.8C12.0652 1.2 12.3196 1.30536 12.5071 1.49289C12.6946 1.68043 12.8 1.93478 12.8 2.2V11.8C12.8 12.0652 12.6946 12.3196 12.5071 12.5071C12.3196 12.6946 12.0652 12.8 11.8 12.8H7C6.84087 12.8 6.68826 12.8632 6.57574 12.9757C6.46321 13.0883 6.4 13.2409 6.4 13.4C6.4 13.5591 6.46321 13.7117 6.57574 13.8243C6.68826 13.9368 6.84087 14 7 14H11.8C12.3835 14 12.9431 13.7682 13.3556 13.3556C13.7682 12.9431 14 12.3835 14 11.8V2.2C14 1.61652 13.7682 1.05694 13.3556 0.644365C12.9431 0.231785 12.3835 0 11.8 0ZM6.368 7.952C6.44137 7.98326 6.52025 7.99958 6.6 8H9.8C9.95913 8 10.1117 7.93678 10.2243 7.82426C10.3368 7.71174 10.4 7.55913 10.4 7.4C10.4 7.24087 10.3368 7.08826 10.2243 6.97574C10.1117 6.86321 9.95913 6.8 9.8 6.8H8.048L10.624 4.224C10.73 4.11026 10.7877 3.95982 10.7849 3.80438C10.7822 3.64894 10.7192 3.50063 10.6093 3.3907C10.4994 3.28077 10.3511 3.2178 10.1956 3.21506C10.0402 3.21232 9.88974 3.27002 9.776 3.376L7.2 5.952V4.2C7.2 4.04087 7.13679 3.88826 7.02426 3.77574C6.91174 3.66321 6.75913 3.6 6.6 3.6C6.44087 3.6 6.28826 3.66321 6.17574 3.77574C6.06321 3.88826 6 4.04087 6 4.2V7.4C6.00042 7.47975 6.01674 7.55862 6.048 7.632C6.07656 7.70442 6.11971 7.7702 6.17475 7.82524C6.2298 7.88029 6.29558 7.92344 6.368 7.952ZM1.4 8.80005H3.8C4.17066 8.80215 4.52553 8.95032 4.78763 9.21242C5.04973 9.47452 5.1979 9.82939 5.2 10.2V12.6C5.1979 12.9707 5.04973 13.3256 4.78763 13.5877C4.52553 13.8498 4.17066 13.9979 3.8 14H1.4C1.02934 13.9979 0.674468 13.8498 0.412371 13.5877C0.150274 13.3256 0.00210008 12.9707 0 12.6V10.2C0.00210008 9.82939 0.150274 9.47452 0.412371 9.21242C0.674468 8.95032 1.02934 8.80215 1.4 8.80005ZM3.94142 12.7415C3.97893 12.704 4 12.6531 4 12.6V10.2C4 10.147 3.97893 10.0961 3.94142 10.0586C3.90391 10.0211 3.85304 10 3.8 10H1.4C1.34696 10 1.29609 10.0211 1.25858 10.0586C1.22107 10.0961 1.2 10.147 1.2 10.2V12.6C1.2 12.6531 1.22107 12.704 1.25858 12.7415C1.29609 12.779 1.34696 12.8 1.4 12.8H3.8C3.85304 12.8 3.90391 12.779 3.94142 12.7415Z",fill:"currentColor"})],-1),uL=f("defs",null,[f("clipPath",{id:"clip0_414_20939"},[f("rect",{width:"14",height:"14",fill:"white"})])],-1),hL=[dL,uL];function pL(e,t,n,i,r,s){return g(),S("svg",R({width:"14",height:"14",viewBox:"0 0 14 14",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e.pti()),hL,16)}dm.render=pL;var um={name:"Dialog",extends:Ve,inheritAttrs:!1,emits:["update:visible","show","hide","after-hide","maximize","unmaximize","dragend"],props:{header:{type:null,default:null},footer:{type:null,default:null},visible:{type:Boolean,default:!1},modal:{type:Boolean,default:null},contentStyle:{type:null,default:null},contentClass:{type:String,default:null},contentProps:{type:null,default:null},rtl:{type:Boolean,default:null},maximizable:{type:Boolean,default:!1},dismissableMask:{type:Boolean,default:!1},closable:{type:Boolean,default:!0},closeOnEscape:{type:Boolean,default:!0},showHeader:{type:Boolean,default:!0},baseZIndex:{type:Number,default:0},autoZIndex:{type:Boolean,default:!0},position:{type:String,default:"center"},breakpoints:{type:Object,default:null},draggable:{type:Boolean,default:!0},keepInViewport:{type:Boolean,default:!0},minX:{type:Number,default:0},minY:{type:Number,default:0},appendTo:{type:String,default:"body"},closeIcon:{type:String,default:void 0},maximizeIcon:{type:String,default:void 0},minimizeIcon:{type:String,default:void 0},closeButtonProps:{type:null,default:null},_instance:null},provide(){return{dialogRef:ee(()=>this._instance)}},data(){return{containerVisible:this.visible,maximized:!1,focusableMax:null,focusableClose:null}},documentKeydownListener:null,container:null,mask:null,content:null,headerContainer:null,footerContainer:null,maximizableButton:null,closeButton:null,styleElement:null,dragging:null,documentDragListener:null,documentDragEndListener:null,lastPageX:null,lastPageY:null,updated(){this.visible&&(this.containerVisible=this.visible)},beforeUnmount(){this.unbindDocumentState(),this.unbindGlobalListeners(),this.destroyStyle(),this.mask&&this.autoZIndex&&He.clear(this.mask),this.container=null,this.mask=null},mounted(){this.breakpoints&&this.createStyle()},methods:{close(){this.$emit("update:visible",!1)},onBeforeEnter(e){e.setAttribute(this.attributeSelector,"")},onEnter(){this.$emit("show"),this.focus(),this.enableDocumentSettings(),this.bindGlobalListeners(),this.autoZIndex&&He.set("modal",this.mask,this.baseZIndex+this.$primevue.config.zIndex.modal)},onBeforeLeave(){this.modal&&F.addClass(this.mask,"p-component-overlay-leave")},onLeave(){this.$emit("hide"),this.focusableClose=null,this.focusableMax=null},onAfterLeave(){this.autoZIndex&&He.clear(this.mask),this.containerVisible=!1,this.unbindDocumentState(),this.unbindGlobalListeners(),this.$emit("after-hide")},onMaskClick(e){this.dismissableMask&&this.modal&&this.mask===e.target&&this.close()},focus(){const e=n=>n.querySelector("[autofocus]");let t=this.$slots.footer&&e(this.footerContainer);t||(t=this.$slots.header&&e(this.headerContainer),t||(t=this.$slots.default&&e(this.content),t||(this.maximizable?(this.focusableMax=!0,t=this.maximizableButton):(this.focusableClose=!0,t=this.closeButton)))),t&&F.focus(t)},maximize(e){this.maximized?(this.maximized=!1,this.$emit("unmaximize",e)):(this.maximized=!0,this.$emit("maximize",e)),this.modal||(this.maximized?F.addClass(document.body,"p-overflow-hidden"):F.removeClass(document.body,"p-overflow-hidden"))},enableDocumentSettings(){(this.modal||this.maximizable&&this.maximized)&&F.addClass(document.body,"p-overflow-hidden")},unbindDocumentState(){(this.modal||this.maximizable&&this.maximized)&&F.removeClass(document.body,"p-overflow-hidden")},onKeyDown(e){e.code==="Escape"&&this.closeOnEscape&&this.close()},bindDocumentKeyDownListener(){this.documentKeydownListener||(this.documentKeydownListener=this.onKeyDown.bind(this),window.document.addEventListener("keydown",this.documentKeydownListener))},unbindDocumentKeyDownListener(){this.documentKeydownListener&&(window.document.removeEventListener("keydown",this.documentKeydownListener),this.documentKeydownListener=null)},getPositionClass(){const t=["left","right","top","topleft","topright","bottom","bottomleft","bottomright"].find(n=>n===this.position);return t?`p-dialog-${t}`:""},containerRef(e){this.container=e},maskRef(e){this.mask=e},contentRef(e){this.content=e},headerContainerRef(e){this.headerContainer=e},footerContainerRef(e){this.footerContainer=e},maximizableRef(e){this.maximizableButton=e},closeButtonRef(e){this.closeButton=e},createStyle(){if(!this.styleElement){this.styleElement=document.createElement("style"),this.styleElement.type="text/css",document.head.appendChild(this.styleElement);let e="";for(let t in this.breakpoints)e+=`
1296                        @media screen and (max-width: ${t}) {
1297                            .p-dialog[${this.attributeSelector}] {
1298                                width: ${this.breakpoints[t]} !important;
1299                            }
1300                        }
1301                    `;this.styleElement.innerHTML=e}},destroyStyle(){this.styleElement&&(document.head.removeChild(this.styleElement),this.styleElement=null)},initDrag(e){F.hasClass(e.target,"p-dialog-header-icon")||F.hasClass(e.target.parentElement,"p-dialog-header-icon")||this.draggable&&(this.dragging=!0,this.lastPageX=e.pageX,this.lastPageY=e.pageY,this.container.style.margin="0",F.addClass(document.body,"p-unselectable-text"))},bindGlobalListeners(){this.draggable&&(this.bindDocumentDragListener(),this.bindDocumentDragEndListener()),this.closeOnEscape&&this.closable&&this.bindDocumentKeyDownListener()},unbindGlobalListeners(){this.unbindDocumentDragListener(),this.unbindDocumentDragEndListener(),this.unbindDocumentKeyDownListener()},bindDocumentDragListener(){this.documentDragListener=e=>{if(this.dragging){let t=F.getOuterWidth(this.container),n=F.getOuterHeight(this.container),i=e.pageX-this.lastPageX,r=e.pageY-this.lastPageY,s=this.container.getBoundingClientRect(),a=s.left+i,o=s.top+r,l=F.getViewport();this.container.style.position="fixed",this.keepInViewport?(a>=this.minX&&a+t<l.width&&(this.lastPageX=e.pageX,this.container.style.left=a+"px"),o>
1301=this.minY&&o+n<l.height&&(this.lastPageY=e.pageY,this.container.style.top=o+"px")):(this.lastPageX=e.pageX,this.container.style.left=a+"px",this.lastPageY=e.pageY,this.container.style.top=o+"px")}},window.document.addEventListener("mousemove",this.documentDragListener)},unbindDocumentDragListener(){this.documentDragListener&&(window.document.removeEventListener("mousemove",this.documentDragListener),this.documentDragListener=null)},bindDocumentDragEndListener(){this.documentDragEndListener=e=>{this.dragging&&(this.dragging=!1,F.removeClass(document.body,"p-unselectable-text"),this.$emit("dragend",e))},window.document.addEventListener("mouseup",this.documentDragEndListener)},unbindDocumentDragEndListener(){this.documentDragEndListener&&(window.document.removeEventListener("mouseup",this.documentDragEndListener),this.documentDragEndListener=null)}},computed:{maskClass(){return["p-dialog-mask",{"p-component-overlay p-component-overlay-enter":this.modal},this.getPositionClass()]},dialogClass(){return["p-dialog p-component",{"p-dialog-rtl":this.rtl,"p-dialog-maximized":this.maximizable&&this.maximized,"p-input-filled":this.$primevue.config.inputStyle==="filled","p-ripple-disabled":this.$primevue.config.ripple===!1}]},maximizeIconComponent(){return this.maximized?this.minimizeIcon?"span":"WindowMinimizeIcon":this.maximizeIcon?"span":"WindowMaximizeIcon"},maximizeIconClass(){return`p-dialog-header-maximize-icon ${this.maximized?this.minimizeIcon:this.maximizeIcon}`},ariaId(){return pt()},ariaLabelledById(){return this.header!=null||this.$attrs["aria-labelledby"]!==null?this.ariaId+"_header":null},closeAriaLabel(){return this.$primevue.config.locale.aria?this.$primevue.config.locale.aria.close:void 0},attributeSelector(){return pt()},contentStyleClass(){return["p-dialog-content",this.contentClass]}},directives:{ripple:gt,focustrap:Fs},components:{Portal:Kt,WindowMinimizeIcon:dm,WindowMaximizeIcon:cm,TimesIcon:Qt}};const fL=["aria-labelledby","aria-modal"],mL=["id"],gL=["autofocus","tabindex"],yL=["autofocus","aria-label"];function bL(e,t,n,i,r,s){const a=le("Portal"),o=Xe("ripple"),l=Xe("focustrap");return g(),Q(a,{appendTo:n.appendTo},{default:Ee(()=>[r.containerVisible?(g(),S("div",R({key:0,ref:s.maskRef,class:s.maskClass,onClick:t[3]||(t[3]=(...c)=>s.onMaskClick&&s.onMaskClick(...c))},e.ptm("mask")),[de($t,{name:"p-dialog",onBeforeEnter:s.onBeforeEnter,onEnter:s.onEnter,onBeforeLeave:s.onBeforeLeave,onLeave:s.onLeave,onAfterLeave:s.onAfterLeave,appear:""},{default:Ee(()=>[n.visible?Ne((g(),S("div",R({key:0,ref:s.containerRef,class:s.dialogClass,role:"dialog","aria-labelledby":s.ariaLabelledById,"aria-modal":n.modal},{...e.$attrs,...e.ptm("root")}),[n.showHeader?(g(),S("div",R({key:0,ref:s.headerContainerRef,class:"p-dialog-header",onMousedown:t[2]||(t[2]=(...c)=>s.initDrag&&s.initDrag(...c))},e.ptm("header")),[he(e.$slots,"header",{},()=>[n.header?(g(),S("span",R({key:0,id:s.ariaLabelledById,class:"p-dialog-title"},e.ptm("headerTitle")),N(n.header),17,mL)):M("",!0)]),f("div",R({class:"p-dialog-header-icons"},e.ptm("headerIcons")),[n.maximizable?Ne((g(),S("button",R({key:0,ref:s.maximizableRef,autofocus:r.focusableMax,class:"p-dialog-header-icon p-dialog-header-maximize p-link",onClick:t[0]||(t[0]=(...c)=>s.maximize&&s.maximize(...c)),type:"button",tabindex:n.maximizable?"0":"-1"},e.ptm("maximizableButton")),[he(e.$slots,"maximizeicon",{maximized:r.maximized},()=>[(g(),Q(_e(s.maximizeIconComponent),R({class:s.maximizeIconClass},e.ptm("maximizableIcon")),null,16,["class"]))])],16,gL)),[[o]]):M("",!0),n.closable?Ne((g(),S("button",R({key:1,ref:s.closeButtonRef,autofocus:r.focusableClose,class:"p-dialog-header-icon p-dialog-header-close p-link",onClick:t[1]||(t[1]=(...c)=>s.close&&s.close(...c)),"aria-label":s.closeAriaLabel,type:"button"},{...n.closeButtonProps,...e.ptm("closeButton")}),[he(e.$slots,"closeicon",{},()=>[(g(),Q(_e(n.closeIcon?"span":"TimesIcon"),R({class:["p-dialog-header-close-icon",n.closeIcon]},e.ptm("closeButtonIcon")),null,16,["class"]))])],16,yL)),[[o]]):M("",!0)],16)],16)):M("",!0),f("div",R({ref:s.contentRef,class:s.contentStyleClass,style:n.contentStyle},{...n.contentProps,...e.ptm("content")}),[he(e.$slots,"default")],16),n.footer||e.$slots.footer?(g(),S("div",R({key:1,ref:s.footerContainerRef,class:"p-dialog-footer"},e.ptm("footer")),[he(e.$slots,"footer",{},()=>[ke(N(n.footer),1)])],16)):M("",!0)],16,fL)),[[l,{disabled:!n.modal}]]):M("",!0)]),_:3},8,["onBeforeEnter","onEnter","onBeforeLeave","onLeave","onAfterLeave"])],16)):M("",!0)]),_:3},8,["appendTo"])}
1301function vL(e,t){t===void 0&&(t={});var n=t.insertAt;if(!(typeof document>"u")){var i=document.head||document.getElementsByTagName("head")[0],r=document.createElement("style");r.type="text/css",n==="top"&&i.firstChild?i.insertBefore(r,i.firstChild):i.appendChild(r),r.styleSheet?r.styleSheet.cssText=e:r.appendChild(document.createTextNode(e))}}var _L=`
1302.p-dialog-mask {
1303    position: fixed;
1304    top: 0;
1305    left: 0;
1306    width: 100%;
1307    height: 100%;
1308    display: flex;
1309    justify-content: center;
1310    align-items: center;
1311    pointer-events: none;
1312}
1313.p-dialog-mask.p-component-overlay {
1314    pointer-events: auto;
1315}
1316.p-dialog {
1317    display: flex;
1318    flex-direction: column;
1319    pointer-events: auto;
1320    max-height: 90%;
1321    transform: scale(1);
1322}
1323.p-dialog-content {
1324    overflow-y: auto;
1325}
1326.p-dialog-header {
1327    display: flex;
1328    align-items: center;
1329    justify-content: space-between;
1330    flex-shrink: 0;
1331}
1332.p-dialog-footer {
1333    flex-shrink: 0;
1334}
1335.p-dialog .p-dialog-header-icons {
1336    display: flex;
1337    align-items: center;
1338}
1339.p-dialog .p-dialog-header-icon {
1340    display: flex;
1341    align-items: center;
1342    justify-content: center;
1343    overflow: hidden;
1344    position: relative;
1345}
1346
1347/* Fluid */
1348.p-fluid .p-dialog-footer .p-button {
1349    width: auto;
1350}
1351
1352/* Animation */
1353/* Center */
1354.p-dialog-enter-active {
1355    transition: all 150ms cubic-bezier(0, 0, 0.2, 1);
1356}
1357.p-dialog-leave-active {
1358    transition: all 150ms cubic-bezier(0.4, 0, 0.2, 1);
1359}
1360.p-dialog-enter-from,
1361.p-dialog-leave-to {
1362    opacity: 0;
1363    transform: scale(0.7);
1364}
1365
1366/* Top, Bottom, Left, Right, Top* and Bottom* */
1367.p-dialog-top .p-dialog,
1368.p-dialog-bottom .p-dialog,
1369.p-dialog-left .p-dialog,
1370.p-dialog-right .p-dialog,
1371.p-dialog-topleft .p-dialog,
1372.p-dialog-topright .p-dialog,
1373.p-dialog-bottomleft .p-dialog,
1374.p-dialog-bottomright .p-dialog {
1375    margin: 0.75rem;
1376    transform: translate3d(0px, 0px, 0px);
1377}
1378.p-dialog-top .p-dialog-enter-active,
1379.p-dialog-top .p-dialog-leave-active,
1380.p-dialog-bottom .p-dialog-enter-active,
1381.p-dialog-bottom .p-dialog-leave-active,
1382.p-dialog-left .p-dialog-enter-active,
1383.p-dialog-left .p-dialog-leave-active,
1384.p-dialog-right .p-dialog-enter-active,
1385.p-dialog-right .p-dialog-leave-active,
1386.p-dialog-topleft .p-dialog-enter-active,
1387.p-dialog-topleft .p-dialog-leave-active,
1388.p-dialog-topright .p-dialog-enter-active,
1389.p-dialog-topright .p-dialog-leave-active,
1390.p-dialog-bottomleft .p-dialog-enter-active,
1391.p-dialog-bottomleft .p-dialog-leave-active,
1392.p-dialog-bottomright .p-dialog-enter-active,
1393.p-dialog-bottomright .p-dialog-leave-active {
1394    transition: all 0.3s ease-out;
1395}
1396.p-dialog-top .p-dialog-enter-from,
1397.p-dialog-top .p-dialog-leave-to {
1398    transform: translate3d(0px, -100%, 0px);
1399}
1400.p-dialog-bottom .p-dialog-enter-from,
1401.p-dialog-bottom .p-dialog-leave-to {
1402    transform: translate3d(0px, 100%, 0px);
1403}
1404.p-dialog-left .p-dialog-enter-from,
1405.p-dialog-left .p-dialog-leave-to,
1406.p-dialog-topleft .p-dialog-enter-from,
1407.p-dialog-topleft .p-dialog-leave-to,
1408.p-dialog-bottomleft .p-dialog-enter-from,
1409.p-dialog-bottomleft .p-dialog-leave-to {
1410    transform: translate3d(-100%, 0px, 0px);
1411}
1412.p-dialog-right .p-dialog-enter-from,
1413.p-dialog-right .p-dialog-leave-to,
1414.p-dialog-topright .p-dialog-enter-from,
1415.p-dialog-topright .p-dialog-leave-to,
1416.p-dialog-bottomright .p-dialog-enter-from,
1417.p-dialog-bottomright .p-dialog-leave-to {
1418    transform: translate3d(100%, 0px, 0px);
1419}
1420
1421/* Maximize */
1422.p-dialog-maximized {
1423    -webkit-transition: none;
1424    transition: none;
1425    transform: none;
1426    width: 100vw !important;
1427    height: 100vh !important;
1428    top: 0px !important;
1429    left: 0px !important;
1430    max-height: 100%;
1431    height: 100%;
1432}
1433.p-dialog-maximized .p-dialog-content {
1434    flex-grow: 1;
1435}
1436
1437/* Position */
1438.p-dialog-left {
1439    justify-content: flex-start;
1440}
1441.p-dialog-right {
1442    justify-content: flex-end;
1443}
1444.p-dialog-top {
1445    align-items: flex-start;
1446}
1447.p-dialog-topleft {
1448    justify-content: flex-start;
1449    align-items: flex-start;
1450}
1451.p-dialog-topright {
1452    justify-content: flex-end;
1453    align-items: flex-start;
1454}
1455.p-dialog-bottom {
1456    align-items: flex-end;
1457}
1458.p-dialog-bottomleft {
1459    justify-content: flex-start;
1460    align-items: flex-end;
1461}
1462.p-dialog-bottomright {
1463    justify-content: flex-end;
1464    align-items: flex-end;
1465}
1466.p-confirm-dialog .p-dialog-content {
1467    display: flex;
1468    align-items: center;
1469}
1470`;vL(_L);um.render=bL;var hm={name:"Divider",extends:Ve,props:{align:{type:String,default:null},layout:{type:String,default:"horizontal"},type:{type:String,default:"solid"}},computed:{containerClass(){return["p-divider p-component","p-divider-"+this.layout,"p-divider-"+this.type,{"p-divider-left":this.layout==="horizontal"&&(!this.align||this.align==="left")},{"p-divider-center":this.layout==="horizontal"&&this.align==="center"},{"p-divider-right":this.layout==="horizontal"&&this.align==="right"},{"p-divider-top":this.layout==="vertical"&&this.align==="top"},{"p-divider-center":this.layout==="vertical"&&(!this.align||this.align==="center")},{"p-divider-bottom":this.layout==="vertical"&&this.align==="bottom"}]}}};const wL=["aria-orientation"];function EL(e,t,n,i,r,s){return g(),S("div",R({class:s.containerClass,role:"separator","aria-orientation":n.layout},e.ptm("root")),[e.$slots.default?(g(),S("div",R({key:0,class:"p-divider-content"},e.ptm("content")),[he(e.$slots,"default")],16)):M("",!0)],16,wL)}function SL(e,t){t===void 0&&(t={});var n=t.insertAt;if(!(typeof document>"u")){var i=document.head||document.getElementsByTagName("head")[0],r=document.createElement("style");r.type="text/css",n==="top"&&i.firstChild?i.insertBefore(r,i.firstChild):i.appendChild(r),r.styleSheet?r.styleSheet.cssText=e:r.appendChild(document.createTextNode(e))}}var CL=`
1471.p-divider-horizontal {
1472    display: flex;
1473    width: 100%;
1474    position: relative;
1475    align-items: center;
1476}
1477.p-divider-horizontal:before {
1478    position: absolute;
1479    display: block;
1480    top: 50%;
1481    left: 0;
1482    width: 100%;
1483    content: '';
1484}
1485.p-divider-horizontal.p-divider-left {
1486    justify-content: flex-start;
1487}
1488.p-divider-horizontal.p-divider-right {
1489    justify-content: flex-end;
1490}
1491.p-divider-horizontal.p-divider-center {
1492    justify-content: center;
1493}
1494.p-divider-content {
1495    z-index: 1;
1496}
1497.p-divider-vertical {
1498    min-height: 100%;
1499    margin: 0 1rem;
1500    display: flex;
1501    position: relative;
1502    justify-content: center;
1503}
1504.p-divider-vertical:before {
1505    position: absolute;
1506    display: block;
1507    top: 0;
1508    left: 50%;
1509    height: 100%;
1510    content: '';
1511}
1512.p-divider-vertical.p-divider-top {
1513    align-items: flex-start;
1514}
1515.p-divider-vertical.p-divider-center {
1516    align-items: center;
1517}
1518.p-divider-vertical.p-divider-bottom {
1519    align-items: flex-end;
1520}
1521.p-divider-solid.p-divider-horizontal:before {
1522    border-top-style: solid;
1523}
1524.p-divider-solid.p-divider-vertical:before {
1525    border-left-style: solid;
1526}
1527.p-divider-dashed.p-divider-horizontal:before {
1528    border-top-style: dashed;
1529}
1530.p-divider-dashed.p-divider-vertical:before {
1531    border-left-style: dashed;
1532}
1533.p-divider-dotted.p-divider-horizontal:before {
1534    border-top-style: dotted;
1535}
1536.p-divider-dotted.p-divider-vertical:before {
1537    border-left-style: dotted;
1538}
1539`;SL(CL);hm.render=EL;var pm={name:"RadioButton",extends:Ve,emits:["click","update:modelValue","change","focus","blur"],props:{value:null,modelValue:null,name:{type:String,default:null},disabled:{type:Boolean,default:!1},inputId:{type:String,default:null},inputClass:{type:[String,Object],default:null},inputStyle:{type:Object,default:null},inputProps:{type:null,default:null},"aria-labelledby":{type:String,default:null},"aria-label":{type:String,default:null}},data(){return{focused:!1}},methods:{onClick(e){this.disabled||(this.$emit("click",e),this.$emit("update:modelValue",this.value),this.$refs.input.focus(),this.checked||this.$emit("change",e))},onFocus(e){this.focused=!0,this.$emit("focus",e)},onBlur(e){this.focused=!1,this.$emit("blur",e)}},computed:{checked(){return this.modelValue!=null&&ve.equals(this.modelValue,this.value)},containerClass(){return["p-radiobutton p-component",{"p-radiobutton-checked":this.checked,"p-radiobutton-disabled":this.disabled,"p-radiobutton-focused":this.focused}]}}};const IL=["id","name","checked","disabled","value","aria-labelledby","aria-label"];function TL(e,t,n,i,r,s){return g(),S("div",R({class:s.containerClass,onClick:t[2]||(t[2]=a=>s.onClick(a))},e.ptm("root")),[f("div",R({class:"p-hidden-accessible"},e.ptm("hiddenInputWrapper")),[f("input",R({ref:"input",id:n.inputId,type:"radio",class:n.inputClass,style:n.inputStyle,name:n.name,checked:s.checked,disabled:n.disabled,value:n.value,"aria-labelledby":e.ariaLabelledby,"aria-label":e.ariaLabel,onFocus:t[0]||(t[0]=(...a)=>s.onFocus&&s.onFocus(...a)),onBlur:t[1]||(t[1]=(...a)=>s.onBlur&&s.onBlur(...a))},e.ptm("hiddenInput")),null,16,IL)],16),f("div",R({ref:"box",class:["p-radiobutton-box",{"p-highlight":s.checked,"p-disabled":n.disabled,"p-focus":r.focused}]},{...n.inputProps,...e.ptm("input")}),[f("div",R({class:"p-radiobutton-icon"},e.ptm("icon")),null,16)],16)],16)}pm.render=TL;var fm={name:"CalendarIcon",extends:ze};const PL=f("path",{d:"M10.7838 1.51351H9.83783V0.567568C9.83783 0.417039 9.77804 0.272676 9.6716 0.166237C9.56516 0.0597971 9.42079 0 9.27027 0C9.11974 0 8.97538 0.0597971 8.86894 0.166237C8.7625 0.272676 8.7027 0.417039 8.7027 0.567568V1.51351H5.29729V0.567568C5.29729 0.417039 5.2375 0.272676 5.13106 0.166237C5.02462 0.0597971 4.88025 0 4.72973 0C4.5792 0 4.43484 0.0597971 4.3284 0.166237C4.22196 0.272676 4.16216 0.417039 4.16216 0.567568V1.51351H3.21621C2.66428 1.51351 2.13494 1.73277 1.74467 2.12305C1.35439 2.51333 1.13513 3.04266 1.13513 3.59459V11.9189C1.13513 12.4709 1.35439 13.0002 1.74467 13.3905C2.13494 13.7807 2.66428 14 3.21621 14H10.7838C11.3357 14 11.865 13.7807 12.2553 13.3905C12.6456 13.0002 12.8649 12.4709 12.8649 11.9189V3.59459C12.8649 3.04266 12.6456 2.51333 12.2553 2.12305C11.865 1.73277 11.3357 1.51351 10.7838 1.51351ZM3.21621 2.64865H4.16216V3.59459C4.16216 3.74512 4.22196 3.88949 4.3284 3.99593C4.43484 4.10237 4.5792 4.16216 4.72973 4.16216C4.88025 4.16216 5.02462 4.10237 5.13106 3.99593C5.2375 3.88949 5.29729 3.74512 5.29729 3.59459V2.64865H8.7027V3.59459C8.7027 3.74512 8.7625 3.88949 8.86894 3.99593C8.97538 4.10237 9.11974 4.16216 9.27027 4.16216C9.42079 4.16216 9.56516 4.10237 9.6716 3.99593C9.77804 3.88949 9.83783 3.74512 9.83783 3.59459V2.64865H10.7838C11.0347 2.64865 11.2753 2.74831 11.4527 2.92571C11.6301 3.10311 11.7297 3.34371 11.7297 3.59459V5.67568H2.27027V3.59459C2.27027 3.34371 2.36993 3.10311 2.54733 2.92571C2.72473 2.74831 2.96533 2.64865 3.21621 2.64865ZM10.7838 12.8649H3.21621C2.96533 12.8649 2.72473 12.7652 2.54733 12.5878C2.36993 12.4104 2.27027 12.1698 2.27027 11.9189V6.81081H11.7297V11.9189C11.7297 12.1698 11.6301 12.4104 11.4527 12.5878C11.2753 12.7652 11.
15390347 12.8649 10.7838 12.8649Z",fill:"currentColor"},null,-1),OL=[PL];function AL(e,t,n,i,r,s){return g(),S("svg",R({width:"14",height:"14",viewBox:"0 0 14 14",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e.pti()),OL,16)}fm.render=AL;var mm={name:"Calendar",extends:Ve,emits:["show","hide","input","month-change","year-change","date-select","update:modelValue","today-click","clear-click","focus","blur","keydown"],props:{modelValue:null,selectionMode:{type:String,default:"single"},dateFormat:{type:String,default:null},inline:{type:Boolean,default:!1},showOtherMonths:{type:Boolean,default:!0},selectOtherMonths:{type:Boolean,default:!1},showIcon:{type:Boolean,default:!1},icon:{type:String,default:void 0},previousIcon:{type:String,default:void 0},nextIcon:{type:String,default:void 0},incrementIcon:{type:String,default:void 0},decrementIcon:{type:String,default:void 0},numberOfMonths:{type:Number,default:1},responsiveOptions:Array,view:{type:String,default:"date"},touchUI:{type:Boolean,default:!1},monthNavigator:{type:Boolean,default:!1},yearNavigator:{type:Boolean,default:!1},yearRange:{type:String,default:null},minDate:{type:Date,value:null},maxDate:{type:Date,value:null},disabledDates:{type:Array,value:null},disabledDays:{type:Array,value:null},maxDateCount:{type:Number,value:null},showOnFocus:{type:Boolean,default:!0},autoZIndex:{type:Boolean,default:!0},baseZIndex:{type:Number,default:0},showButtonBar:{type:Boolean,default:!1},shortYearCutoff:{type:String,default:"+10"},showTime:{type:Boolean,default:!1},timeOnly:{type:Boolean,default:!1},hourFormat:{type:String,default:"24"},stepHour:{type:Number,default:1},stepMinute:{type:Number,default:1},stepSecond:{type:Number,default:1},showSeconds:{type:Boolean,default:!1},hideOnDateTimeSelect:{type:Boolean,default:!1},hideOnRangeSelection:{type:Boolean,default:!1},timeSeparator:{type:String,default:":"},showWeek:{type:Boolean,default:!1},manualInput:{type:Boolean,default:!0},appendTo:{type:String,default:"body"},disabled:{type:Boolean,default:!1},readonly:{type:Boolean,default:!1},placeholder:{type:String,default:null},id:{type:String,default:null},inputId:{type:String,default:null},inputClass:{type:[String,Object],default:null},inputStyle:{type:Object,default:null},inputProps:{type:null,default:null},panelClass:{type:[String,Object],default:null},panelStyle:{type:Object,default:null},panelProps:{type:null,default:null},"aria-labelledby":{type:String,default:null},"aria-label":{type:String,default:null}},navigationState:null,timePickerChange:!1,scrollHandler:null,outsideClickListener:null,maskClickListener:null,resizeListener:null,overlay:null,input:null,mask:null,timePickerTimer:null,preventFocus:!1,typeUpdate:!1,data(){return{currentMonth:null,currentYear:null,currentHour:null,currentMinute:null,currentSecond:null,pm:null,focused:!1,overlayVisible:!1,currentView:this.view}}
1539,watch:{modelValue(e){this.updateCurrentMetaData(),!this.typeUpdate&&!this.inline&&this.input&&(this.input.value=this.formatValue(e)),this.typeUpdate=!1},showTime(){this.updateCurrentMetaData()},months(){this.overlay&&(this.focused||(this.inline&&(this.preventFocus=!0),setTimeout(this.updateFocus,0)))},numberOfMonths(){this.destroyResponsiveStyleElement(),this.createResponsiveStyle()},responsiveOptions(){this.destroyResponsiveStyleElement(),this.createResponsiveStyle()},currentView(){Promise.resolve(null).then(()=>this.alignOverlay())}},created(){this.updateCurrentMetaData()},mounted(){this.createResponsiveStyle(),this.inline?(this.overlay&&this.overlay.setAttribute(this.attributeSelector,""),this.disabled||(this.preventFocus=!0,this.initFocusableCell(),this.numberOfMonths===1&&(this.overlay.style.width=F.getOuterWidth(this.$el)+"px"))):this.input.value=this.formatValue(this.modelValue)},updated(){this.overlay&&(this.preventFocus=!0,setTimeout(this.updateFocus,0)),this.input&&this.selectionStart!=null&&this.selectionEnd!=null&&(this.input.selectionStart=this.selectionStart,this.input.selectionEnd=this.selectionEnd,this.selectionStart=null,this.selectionEnd=null)},beforeUnmount(){this.timePickerTimer&&clearTimeout(this.timePickerTimer),this.mask&&this.destroyMask(),this.destroyResponsiveStyleElement(),this.unbindOutsideClickListener(),this.unbindResizeListener(),this.scrollHandler&&(this.scrollHandler.destroy(),this.scrollHandler=null),this.overlay&&this.autoZIndex&&He.clear(this.overlay),this.overlay=null},methods:{isComparable(){return this.modelValue!=null&&typeof this.modelValue!="string"},isSelected(e){if(!this.isComparable())return!1;if(this.modelValue){if(this.isSingleSelection())return this.isDateEquals(this.modelValue,e);if(this.isMultipleSelection()){let t=!1;for(let n of this.modelValue)if(t=this.isDateEquals(n,e),t)break;return t}else if(this.isRangeSelection())return this.modelValue[1]?this.isDateEquals(this.modelValue[0],e)||this.isDateEquals(this.modelValue[1],e)||this.isDateBetween(this.modelValue[0],this.modelValue[1],e):this.isDateEquals(this.modelValue[0],e)}return!1},isMonthSelected(e){if(this.isComparable()){let t=this.isRangeSelection()?this.modelValue[0]:this.modelValue;return this.isMultipleSelection()?!1:t.getMonth()===e&&t.getFullYear()===this.currentYear}return!1},isYearSelected(e){if(this.isComparable()){let t=this.isRangeSelection()?this.modelValue[0]:this.modelValue;return!this.isMultipleSelection()&&this.isComparable()?t.getFullYear()===e:!1}return!1},isDateEquals(e,t){return e?e.getDate()===t.day&&e.getMonth()===t.month&&e.getFullYear()===t.year:!1},isDateBetween(e,t,n){let i=!1;if(e&&t){let r=new Date(n.year,n.month,n.day);return e.getTime()<=r.getTime()&&t.getTime()>=r.getTime()}return i},getFirstDayOfMonthIndex(e,t){let n=new Date;n.setDate(1),n.setMonth(e),n.setFullYear(t);let i=n.getDay()+this.sundayIndex;return i>=7?i-7:i},getDaysCountInMonth(e,t){return 32-this.daylightSavingAdjust(new Date(t,e,32)).getDate()},getDaysCountInPrevMonth(e,t){let n=this.getPreviousMonthAndYear(e,t);return this.getDaysCountInMonth(n.month,n.year)},getPreviousMonthAndYear(e,t){let n,i;return e===0?(n=11,i=t-1):(n=e-1,i=t),{month:n,year:i}},getNextMonthAndYear(e,t){let n,i;return e===11?(n=0,i=t+1):(n=e+1,i=t),{month:n,year:i}},daylightSavingAdjust(e){return e?(e.setHours(e.getHours()>12?e.getHours()+2:0),e):null},isToday(e,t,n,i){return e.getDate()===t&&e.getMonth()===n&&e.getFullYear()===i},isSelectable(e,t,n,i){let r=!0,s=!0,a=!0,o=!0;return i&&!this.selectOtherMonths?!1:(this.minDate&&(this.minDate.getFullYear()>n||this.minDate.getFullYear()===n&&(this.minDate.getMonth()>t||this.minDate.getMonth()===t&&this.minDate.getDate()>e))&&(r=!1),this.maxDate&&(this.maxDate.getFullYear()<n||this.maxDate.getFullYear()===n&&(this.maxDate.getMonth()<t||this.maxDate.getMonth()===t&&this.maxDate.getDate()<e))&&(s=!1),this.disabledDates&&(a=!this.isDateDisabled(e,t,n)),this.disabledDays&&(o=!this.isDayDisabled(e,t,n)),r&&s&&a&&o)},onOverlayEnter(e){e.setAttribute(this.attributeSelector,""),this.autoZIndex&&(this.touchUI?He.set("modal",e,this.baseZIndex||this.$primevue.config.zIndex.modal):He.set("overlay",e,this.baseZIndex||this.$primevue.config.zIndex.overlay)),this.alignOverlay(),this.$emit("show")},onOverlayEnterComplete(){this.bindOutsideClickListener(),this.bindScrollListener(),this.bindResizeListener()},onOverlayAfterLeave(e){this.autoZIndex&&He.clear(e)},onOverlayLeave(){this.currentView=this.view,this.unbindOutsideClickListener(),this.unbindScrollListener(),this.unbindResizeListener(),this.$emit("hide"),this.mask&&this.disableModality(),this.overlay=null},onPrevButtonClick(e){this.showOtherMonths&&(this.navigationState={backward:!0,button:!0},this.navBackward(e))},onNextButtonClick(e){this.showOtherMonths&&(this.navigationState={backward:!1,button:!0},this.navForward(e))},navBackward(e){e.preventDefault(),this.isEnabled()&&(this.currentView==="month"?(this.decrementYear(),this.$emit("year-change",{month:this.currentMonth,year:this.currentYear})):this.currentView==="year"?this.decrementDecade():e.shiftKey?this.decrementYear():(this.currentMonth===0?(this.currentMonth=11,this.decrementYear()):this.currentMonth--,this.$emit("month-change",{month:this.currentMonth+1,year:this.currentYear})))},navForward(e){e.preventDefault(),this.isEnabled()&&(this.currentView==="month"?(this.incrementYear(),this.$emit("year-change",{month:this.currentMonth,year:this.currentYear})):this.currentView==="year"?this.incrementDecade():e.shiftKey?this.incrementYear():(this.currentMonth===11?(this.currentMonth=0,this.incrementYear()):this.currentMonth++,this.$emit("month-change",{month:this.currentMonth+1,year:this.currentYear})))},decrementYear(){this.currentYear--},decrementDecade(){this.currentYear=this.currentYear-10},incrementYear(){this.currentYear++},incrementDecade(){this.currentYear=this.currentYear+10},switchToMonthView(e){this.currentView="month",setTimeout(this.updateFocus,0),e.preventDefault()},switchToYearView(e){this.currentView="year",setTimeout(this.updateFocus,0),e.preventDefault()},isEnabled(){return!this.disabled&&!this.readonly},updateCurrentTimeMeta(e){let t=e.getHours();this.hourFormat==="12"&&(this.pm=t>11,t>=12?t=t==12?12:t-12:t=t==0?12:t),this.currentHour=Math.floor(t/this.stepHour)*this.stepHour,this.currentMinute=Math.floor(e.getMinutes()/this.stepMinute)*this.stepMinute,this.currentSecond=Math.floor(e.getSeconds()/this.stepSecond)*this.stepSecond},bindOutsideClickListener(){this.outsideClickListener||(this.outsideClickListener=e=>{this.overlayVisible&&this.isOutsideClicked(e)&&(this.overlayVisible=!1)},document.addEventListener("mousedown",this.outsideClickListener))},unbindOutsideClickListener(){this.outsideClickListener&&(document.removeEventListener("mousedown",this.outsideClickListener),this.outsideClickListener=null)},bindScrollListener(){this.scrollHandler||(this.scrollHandler=new kn(this.$refs.container,()=>{this.overlayVisible&&(this.overlayVisible=!1)})),this.scrollHandler.bindScrollListener()},unbindScrollListener(){this.scrollHandler&&this.scrollHandler.unbindScrollListener()},bindResizeListener(){this.resizeListener||(this.resizeListener=()=>{this.overlayVisible&&!F.isTouchDevice()&&(this.overlayVisible=!1)},window.addEventListener("resize",this.resizeListener))},unbindResizeListener(){this.resizeListener&&(window.removeEventListener("resize",this.resizeListener),this.resizeListener=null)},isOutsideClicked(e){return!(this.$el.isSameNode(e.target)||this.isNavIconClicked(e)||this.$el.contains(e.target)||this.overlay&&this.overlay.contains(e.target))},isNavIconClicked(e){return F.hasClass(e.target,"p-datepicker-prev")||F.hasClass(e.target,"p-datepicker-prev-icon")||F.hasClass(e.target,"p-datepicker-next")||F.hasClass(e.target,"p-datepicker-next-icon")},alignOverlay(){this.touchUI?this.enableModality():this.overlay&&(this.appendTo==="self"||this.inline?F.relativePosition(this.overlay,this.$el):(this.view==="date"?(this.overlay.style.width=F.getOuterWidth(this.overlay)+"px",this.overlay.style.minWidth=F.getOuterWidth(this.$el)+"px"):this.overlay.style.width=F.getOuterWidth(this.$el)+"px",F.absolutePosition(this.overlay,this.$el)))},onButtonClick(){this.isEnabled()&&(this.overlayVisible?this.overlayVisible=!1:(this.input.focus(),this.overlayVisible=!0))},isDateDisabled(e,t,n){if(this.disabledDates){for(let i of this.disabledDates)if(i.getFullYear()===n&&i.getMonth()===t&&i.getDate()===e)return!0}return!1},isDayDisabled(e,t,n){if(this.disabledDays){let r=new Date(n,t,e).getDay();return this.disabledDays.indexOf(r)!==-1}return!1},onMonthDropdownChange(e){this.currentMonth=parseInt(e),this.$emit("month-change",{month:this.currentMonth+1,year:this.currentYear})},onYearDropdownChange(e){this.currentYear=parseInt(e),this.$emit("year-change",{month:this.currentMonth+1,year:this.currentYear})},onDateSelect(e,t){if(!(this.disabled||!t.selectable)){if(F.find(this.overlay,".p-datepicker-calendar td span:not(.p-disabled)").forEach(n=>
1539n.tabIndex=-1),e&&e.currentTarget.focus(),this.isMultipleSelection()&&this.isSelected(t)){let n=this.modelValue.filter(i=>!this.isDateEquals(i,t));this.updateModel(n)}else this.shouldSelectDate(t)&&(t.otherMonth?(this.currentMonth=t.month,this.currentYear=t.year,this.selectDate(t)):this.selectDate(t));this.isSingleSelection()&&(!this.showTime||this.hideOnDateTimeSelect)&&setTimeout(()=>{this.input&&this.input.focus(),this.overlayVisible=!1},150)}},selectDate(e){let t=new Date(e.year,e.month,e.day);this.showTime&&(this.hourFormat==="12"&&this.pm&&this.currentHour!=12?t.setHours(this.currentHour+12):t.setHours(this.currentHour),t.setMinutes(this.currentMinute),t.setSeconds(this.currentSecond)),this.minDate&&this.minDate>t&&(t=this.minDate,this.currentHour=t.getHours(),this.currentMinute=t.getMinutes(),this.currentSecond=t.getSeconds()),this.maxDate&&this.maxDate<t&&(t=this.maxDate,this.currentHour=t.getHours(),this.currentMinute=t.getMinutes(),this.currentSecond=t.getSeconds());let n=null;if(this.isSingleSelection())n=t;else if(this.isMultipleSelection())n=this.modelValue?[...this.modelValue,t]:[t];else if(this.isRangeSelection())if(this.modelValue&&this.modelValue.length){let i=this.modelValue[0],r=this.modelValue[1];!r&&t.getTime()>=i.getTime()?r=t:(i=t,r=null),n=[i,r]}else n=[t,null];n!==null&&this.updateModel(n),this.isRangeSelection()&&this.hideOnRangeSelection&&n[1]!==null&&setTimeout(()=>{this.overlayVisible=!1},150),this.$emit("date-select",t)},updateModel(e){this.$emit("update:modelValue",e)},shouldSelectDate(){return this.isMultipleSelection()&&this.maxDateCount!=null?this.maxDateCount>(this.modelValue?this.modelValue.length:0):!0},isSingleSelection(){return this.selectionMode==="single"},isRangeSelection(){return this.selectionMode==="range"},isMultipleSelection(){return this.selectionMode==="multiple"},formatValue(e){if(typeof e=="string")return e;let t="";if(e)try{if(this.isSingleSelection())t=this.formatDateTime(e);else if(this.isMultipleSelection())for(let n=0;n<e.length;n++){let i=this.formatDateTime(e[n]);t+=i,n!==e.length-1&&(t+=", ")}else if(this.isRangeSelection()&&e&&e.length){let n=e[0],i=e[1];t=this.formatDateTime(n),i&&(t+=" - "+this.formatDateTime(i))}}catch{t=e}return t},formatDateTime(e){let t=null;return e&&(this.timeOnly?t=this.formatTime(e):(t=this.formatDate(e,this.datePattern),this.showTime&&(t+=" "+this.formatTime(e)))),t},formatDate(e,t){if(!e)return"";let n;const i=l=>{const c=n+1<t.length&&t.charAt(n+1)===l;return c&&n++,c},r=(l,c,d)=>{let u=""+c;if(i(l))for(;u.length<d;)u="0"+u;return u},s=(l,c,d,u)=>i(l)?u[c]:d[c];let a="",o=!1;if(e)for(n=0;n<t.length;n++)if(o)t.charAt(n)==="'"&&!i("'")?o=!1:a+=t.charAt(n);else switch(t.charAt(n)){case"d":a+=r("d",e.getDate(),2);break;case"D":a+=s("D",e.getDay(),this.$primevue.config.locale.dayNamesShort,this.$primevue.config.locale.dayNames);break;case"o":a+=r("o",Math.round((new Date(e.getFullYear(),e.getMonth(),e.getDate()).getTime()-new Date(e.getFullYear(),0,0).getTime())/864e5),3);break;case"m":a+=r("m",e.getMonth()+1,2);break;case"M":a+=s("M",e.getMonth(),this.$primevue.config.locale.monthNamesShort,this.$primevue.config.locale.monthNames);break;case"y":a+=i("y")?e.getFullYear():(e.getFullYear()%100<10?"0":"")+e.getFullYear()%100;break;case"@":a+=e.getTime();break;case"!":a+=e.getTime()*1e4+this.ticksTo1970;break;case"'":i("'")?a+="'":o=!0;break;default:a+=t.charAt(n)}return a},formatTime(e){if(!e)return"";let t="",n=e.getHours(),i=e.getMinutes(),r=e.getSeconds();return this.hourFormat==="12"&&n>11&&n!==12&&(n-=12),this.hourFormat==="12"?t+=n===0?12:n<10?"0"+n:n:t+=n<10?"0"+n:n,t+=":",t+=i<10?"0"+i:i,this.showSeconds&&(t+=":",t+=r<10?"0"+r:r),this.hourFormat==="12"&&(t+=e.getHours()>11?` ${this.$primevue.config.locale.pm}`:` ${this.$primevue.config.locale.am}`),t},onTodayButtonClick(e){let t=new Date,n={day:t.getDate(),month:t.getMonth(),year:t.getFullYear(),otherMonth:t.getMonth()!==this.currentMonth||t.getFullYear()!==this.currentYear,today:!0,selectable:!0};this.onDateSelect(null,n),this.$emit("today-click",t),e.preventDefault()},onClearButtonClick(e){this.updateModel(null),this.overlayVisible=!1,this.$emit("clear-click",e),e.preventDefault()},onTimePickerElementMouseDown(e,t,n){this.isEnabled()&&(this.repeat(e,null,t,n),e.preventDefault())},onTimePickerElementMouseUp(e){this.isEnabled()&&(this.clearTimePickerTimer(),this.updateModelTime(),e.preventDefault())},onTimePickerElementMouseLeave(){this.clearTimePickerTimer()},repeat(e,t,n,i){let r=t||500;switch(this.clearTimePickerTimer(),this.timePickerTimer=setTimeout(()=>{this.repeat(e,100,n,i)},r),n){case 0:i===1?this.incrementHour(e):this.decrementHour(e);break;case 1:i===1?this.incrementMinute(e):this.decrementMinute(e);break;case 2:i===1?this.incrementSecond(e):this.decrementSecond(e);break}},convertTo24Hour(e,t){return this.hourFormat=="12"?e===12?t?12:0:t?e+12:e:e},validateTime(e,t,n,i){let r=this.isComparable()?this.modelValue:this.viewDate;const s=this.convertTo24Hour(e,i);this.isRangeSelection()&&(r=this.modelValue[1]||this.modelValue[0]),this.isMultipleSelection()&&(r=this.modelValue[this.modelValue.length-1]);const a=r?r.toDateString():null;return!(this.minDate&&a&&this.minDate.toDateString()===a&&(this.minDate.getHours()>s||this.minDate.getHours()===s&&(this.minDate.getMinutes()>t||this.minDate.getMinutes()===t&&this.minDate.getSeconds()>n))||this.maxDate&&a&&this.maxDate.toDateString()===a&&(this.maxDate.getHours()<s||this.maxDate.getHours()===s&&(this.maxDate.getMinutes()<t||this.maxDate.getMinutes()===t&&this.maxDate.getSeconds()<n)))},incrementHour(e){let t=this.currentHour,n=this.currentHour+this.stepHour,i=this.pm;this.hourFormat=="24"?n=n>=24?n-24:n:this.hourFormat=="12"&&(t<12&&n>11&&(i=!this.pm),n=n>=13?n-12:n),this.validateTime(n,this.currentMinute,this.currentSecond,i)&&(this.currentHour=n,this.pm=i),e.preventDefault()},decrementHour(e){let t=this.currentHour-this.stepHour,n=this.pm;this.hourFormat=="24"?t=t<0?24+t:t:this.hourFormat=="12"&&(this.currentHour===12&&(n=!this.pm),t=t<=0?12+t:t),this.validateTime(t,this.currentMinute,this.currentSecond,n)&&(this.currentHour=t,this.pm=n),e.preventDefault()},incrementMinute(e){let t=this.currentMinute+this.stepMinute;this.validateTime(this.currentHour,t,this.currentSecond,this.pm)&&(this.currentMinute=t>59?t-60:t),e.preventDefault()},decrementMinute(e){let t=this.currentMinute-this.stepMinute;t=t<0?60+t:t,this.validateTime(this.currentHour,t,this.currentSecond,this.pm)&&(this.currentMinute=t),e.preventDefault()},incrementSecond(e){let t=this.currentSecond+this.stepSecond;this.validateTime(this.currentHour,this.currentMinute,t,this.pm)&&(this.currentSecond=t>59?t-60:t),e.preventDefault()},decrementSecond(e){let t=this.currentSecond-this.stepSecond;t=t<0?60+t:t,this.validateTime(this.currentHour,this.currentMinute,t,this.pm)&&(this.currentSecond=t),e.preventDefault()},updateModelTime(){this.timePickerChange=!0;let e=this.isComparable()?this.modelValue:this.viewDate;this.isRangeSelection()&&(e=this.modelValue[1]||this.modelValue[0]),this.isMultipleSelection()&&(e=this.modelValue[this.modelValue.length-1]),e=e?new Date(e.getTime()):new Date,this.hourFormat=="12"?this.currentHour===12?e.setHours(this.pm?12:0):e.setHours(this.pm?this.currentHour+12:this.currentHour):e.setHours(this.currentHour),e.setMinutes(this.currentMinute),e.setSeconds(this.currentSecond),this.isRangeSelection()&&(this.modelValue[1]?e=[this.modelValue[0],e]:e=[e,null]),this.isMultipleSelection()&&(e=[...this.modelValue.slice(0,-1),e]),this.updateModel(e),this.$emit("date-select",e),setTimeout(()=>this.timePickerChange=!1,0)},toggleAMPM(e){!this.validateTime(this.currentHour,this.currentMinute,this.currentSecond,!this.pm)&&(this.maxDate||this.minDate)||(this.pm=!this.pm,this.updateModelTime(),e.preventDefault())},clearTimePickerTimer(){this.timePickerTimer&&clearInterval(this.timePickerTimer)},onMonthSelect(e,{month:t,index:n}){this.view==="month"?this.onDateSelect(e,{year:this.currentYear,month:n,day:1,selectable:!0}):(this.currentMonth=n,this.currentView="date",this.$emit("month-change",{month:this.currentMonth+1,year:this.currentYear})),setTimeout(this.updateFocus,0)},onYearSelect(e,t){this.view==="year"?this.onDateSelect(e,{year:t.value,month:0,day:1,selectable:!0}):(this.currentYear=t.value,this.currentView="month",this.$emit("year-change",{month:this.currentMonth+1,year:this.currentYear})),setTimeout(this.updateFocus,0)},enableModality(){this.mask||(this.mask=document.createElement("div"),this.mask.style.zIndex=String(parseInt(this.overlay.style.zIndex,10)-1),F.addMultipleClasses(this.mask,"p-datepicker-mask p-datepicker-mask-scrollblocker p-component-overlay p-component-overlay-enter"),this.maskClickListener=()=>{this.overlayVisible=!1},this.mask.addEventListener("click",this.maskClickListener),document.body.appendChild(this.mask),F.addClass(document.body,"p-overflow-hidden"))},disableModality(){this.mask&&(F.addClass(this.mask,"p-component-overlay-leave"),this.mask.addEventListener("animationend",()=>{this.destroyMask()}))},destroyMask(){this.mask.removeEventListener("click",this.maskClickListener),this.maskClickListener=null,document.body.removeChild(this.mask),this.mask=null;let e=document.body.children,t;for(let n=0;n<e.length;n++){let i=e[n];if(F.hasClass(i,"p-datepicker-mask-scrollblocker")){t=!0;break}}t||F.removeClass(document.body,"p-overflow-hidden")},updateCurrentMetaData(){const e=this.viewDate;this.currentMonth=e.getMonth(),this.currentYear=e.getFullYear(),(this.showTime||this.timeOnly)&&this.updateCurrentTimeMeta(e)},isValidSelection(e){if(e==null)return!0;let t=!0;return this.isSingleSelection()?this.isSelectable(e.getDate(),e.getMonth(),e.getFullYear(),!1)||(t=!1):e.every(n=>this.isSelectable(n.getDate(),n.getMonth(),n.getFullYear(),!1))&&this.isRangeSelection()&&(t=e.length>1&&e[1]>e[0]),t},parseValue(e){if(!e||e.trim().length===0)return null;let t;if(this.isSingleSelection())t=this.parseDateTime(e);else if(this.isMultipleSelection()){let n=e.split(",");t=[];for(let i of n)t.push(this.parseDateTime(i.trim()))}else if(this.isRangeSelection()){let n=e.split(" - ");t=[];for(let i=0;i<n.length;i++)t[i]=this.parseDateTime(n[i].trim())}return t},parseDateTime(e){let t,n=e.split(" ");if(this.timeOnly)t=new Date,this.populateTime(t,n[0],n[1]);else{const i=this.datePattern;this.showTime?(t=this.parseDate(n[0],i),this.populateTime(t,n[1],n[2])):t=this.parseDate(e,i)}return t},populateTime(e,t,n){if(this.hourFormat=="12"&&!n)throw"Invalid Time";this.pm=n===this.$primevue.config.locale.pm||n===this.$primevue.config.locale.pm.toLowerCase();let i=this.parseTime(t);e.setHours(i.hour),e.setMinutes(i.minute),e.setSeconds(i.second)},parseTime(e){let t=e.split(":"),n=this.showSeconds?3:2,i=/^[0-9][0-9]$/;if(t.length!==n||!t[0].match(i)||!t[1].match(i)||this.showSeconds&&!t[2].match(i))throw"Invalid time";let r=parseInt(t[0]),s=parseInt(t[1]),a=this.showSeconds?parseInt(t[2]):null;if(isNaN(r)||isNaN(s)||r>23||s>59||this.hourFormat=="12"&&r>12||this.showSeconds&&(isNaN(a)||a>59))throw"Invalid time";return this.hourFormat=="12"&&r!==12&&this.pm&&(r+=12),{hour:r,minute:s,second:a}},parseDate(e,t){if(t==null||e==null)throw"Invalid arguments";if(e=typeof e=="object"?e.toString():e+"",e==="")return null;let n,i,r,s=0,a=typeof this.shortYearCutoff!="string"?this.shortYearCutoff:new Date().getFullYear()%100+parseInt(this.shortYearCutoff,10),o=-1,l=-1,c=-1,d=-1,u=!1,p,h=b=>{let w=n+1<t.length&&t.charAt(n+1)===b;return w&&n++,w},m=b=>{let w=h(b),C=b==="@"?14:b==="!"?20:b==="y"&&w?4:b==="o"?3:2,O=b==="y"?C:1,T=new RegExp("^\\d{"+O+","+C+"}"),E=e.substring(s).match(T);if(!E)throw"Missing number at position "+s;return s+=E[0].length,parseInt(E[0],10)},v=(b,w,C)=>{let O=-1,T=h(b)?C:w,E=[];for(let y=0;y<T.length;y++)E.push([y,T[y]]);E.sort((y,P)=>-(y[1].length-P[1].length));for(let y=0;y<E.length;y++){let P=E[y][1];if(e.substr(s,P.length).toLowerCase()===P.toLowerCase()){O=E[y][0],s+=P.length;break}}if(O!==-1)return O+1;throw"Unknown name at position "+s},_=()=>{if(e.charAt(s)!==t.charAt(n))throw"Unexpected literal at position "+s;s++};for(this.currentView==="month"&&(c=1),n=0;n<t.length;n++)if(u)t.charAt(n)==="'"&&!h("'")?u=!1:_();else switch(t.charAt(n)){case"d":c=m("d");break;case"D":v("D",this.$primevue.config.locale.dayNamesShort,this.$primevue.config.locale.dayNames);break;case"o":d=m("o");break;case"m":l=m("m");break;case"M":l=v("M",this.$primevue.config.locale.monthNamesShort,this.$primevue.config.locale.monthNames);break;case"y":o=m("y");break;case"@":p=new Date(m("@")),o=p.getFullYear(),l=p.getMonth()+1,c=p.getDate();break;case"!":p=new Date((m("!")-this.ticksTo1970)/1e4),o=p.getFullYear(),l=p.getMonth()+1,c=p.getDate();break;
1539case"'":h("'")?_():u=!0;break;default:_()}if(s<e.length&&(r=e.substr(s),!/^\s+/.test(r)))throw"Extra/unparsed characters found in date: "+r;if(o===-1?o=new Date().getFullYear():o<100&&(o+=new Date().getFullYear()-new Date().getFullYear()%100+(o<=a?0:-100)),d>-1){l=1,c=d;do{if(i=this.getDaysCountInMonth(o,l-1),c<=i)break;l++,c-=i}while(!0)}if(p=this.daylightSavingAdjust(new Date(o,l-1,c)),p.getFullYear()!==o||p.getMonth()+1!==l||p.getDate()!==c)throw"Invalid date";return p},getWeekNumber(e){let t=new Date(e.getTime());t.setDate(t.getDate()+4-(t.getDay()||7));let n=t.getTime();return t.setMonth(0),t.setDate(1),Math.floor(Math.round((n-t.getTime())/864e5)/7)+1},onDateCellKeydown(e,t,n){const i=e.currentTarget,r=i.parentElement,s=F.index(r);switch(e.code){case"ArrowDown":{if(i.tabIndex="-1",r.parentElement.nextElementSibling){let o=F.index(r.parentElement),d=Array.from(r.parentElement.parentElement.children).slice(o+1).find(u=>{let p=u.children[s].children[0];return!F.hasClass(p,"p-disabled")});if(d){let u=d.children[s].children[0];u.tabIndex="0",u.focus()}else this.navigationState={backward:!1},this.navForward(e)}else this.navigationState={backward:!1},this.navForward(e);e.preventDefault();break}case"ArrowUp":{if(i.tabIndex="-1",r.parentElement.previousElementSibling){let o=F.index(r.parentElement),d=Array.from(r.parentElement.parentElement.children).slice(0,o).reverse().find(u=>{let p=u.children[s].children[0];return!F.hasClass(p,"p-disabled")});if(d){let u=d.children[s].children[0];u.tabIndex="0",u.focus()}else this.navigationState={backward:!0},this.navBackward(e)}else this.navigationState={backward:!0},this.navBackward(e);e.preventDefault();break}case"ArrowLeft":{if(i.tabIndex="-1",r.previousElementSibling){let c=Array.from(r.parentElement.children).slice(0,s).reverse().find(d=>{let u=d.children[0];return!F.hasClass(u,"p-disabled")});if(c){let d=c.children[0];d.tabIndex="0",d.focus()}else this.navigateToMonth(e,!0,n)}else this.navigateToMonth(e,!0,n);e.preventDefault();break}case"ArrowRight":{if(i.tabIndex="-1",r.nextElementSibling){let c=Array.from(r.parentElement.children).slice(s+1).find(d=>{let u=d.children[0];return!F.hasClass(u,"p-disabled")});if(c){let d=c.children[0];d.tabIndex="0",d.focus()}else this.navigateToMonth(e,!1,n)}else this.navigateToMonth(e,!1,n);e.preventDefault();break}case"Enter":case"Space":{this.onDateSelect(e,t),e.preventDefault();break}case"Escape":{this.overlayVisible=!1,e.preventDefault();break}case"Tab":{this.inline||this.trapFocus(e);break}case"Home":{i.tabIndex="-1";let o=r.parentElement.children[0].children[0];F.hasClass(o,"p-disabled")?this.navigateToMonth(e,!0,n):(o.tabIndex="0",o.focus()),e.preventDefault();break}case"End":{i.tabIndex="-1";let a=r.parentElement,o=a.children[a.children.length-1].children[0];F.hasClass(o,"p-disabled")?this.navigateToMonth(e,!1,n):(o.tabIndex="0",o.focus()),e.preventDefault();break}case"PageUp":{i.tabIndex="-1",e.shiftKey?(this.navigationState={backward:!0},this.navBackward(e)):this.navigateToMonth(e,!0,n),e.preventDefault();break}case"PageDown":{i.tabIndex="-1",e.shiftKey?(this.navigationState={backward:!1},this.navForward(e)):this.navigateToMonth(e,!1,n),e.preventDefault();break}}},navigateToMonth(e,t,n){if(t)if(this.numberOfMonths===1||n===0)this.navigationState={backward:!0},this.navBackward(e);else{let i=this.overlay.children[n-1],r=F.find(i,".p-datepicker-calendar td span:not(.p-disabled):not(.p-ink)"),s=r[r.length-1];s.tabIndex="0",s.focus()}else if(this.numberOfMonths===1||n===this.numberOfMonths-1)this.navigationState={backward:!1},this.navForward(e);else{let i=this.overlay.children[n+1],r=F.findSingle(i,".p-datepicker-calendar td span:not(.p-disabled):not(.p-ink)");r.tabIndex="0",r.focus()}},onMonthCellKeydown(e,t){const n=e.currentTarget;switch(e.code){case"ArrowUp":case"ArrowDown":{n.tabIndex="-1";var i=n.parentElement.children,r=F.index(n);let s=i[e.code==="ArrowDown"?r+3:r-3];s&&(s.tabIndex="0",s.focus()),e.preventDefault();break}case"ArrowLeft":{n.tabIndex="-1";let s=n.previousElementSibling;s?(s.tabIndex="0",s.focus()):(this.navigationState={backward:!0},this.navBackward(e)),e.preventDefault();break}case"ArrowRight":{n.tabIndex="-1";let s=n.nextElementSibling;s?(s.tabIndex="0",s.focus()):(this.navigationState={backward:!1},this.navForward(e)),e.preventDefault();break}case"PageUp":{if(e.shiftKey)return;this.navigationState={backward:!0},this.navBackward(e);break}case"PageDown":{if(e.shiftKey)return;this.navigationState={backward:!1},this.navForward(e);break}case"Enter":case"Space":{this.onMonthSelect(e,t),e.preventDefault();break}case"Escape":{this.overlayVisible=!1,e.preventDefault();break}case"Tab":{this.trapFocus(e);break}}},onYearCellKeydown(e,t){const n=e.currentTarget;switch(e.code){case"ArrowUp":case"ArrowDown":{n.tabIndex="-1";var i=n.parentElement.children,r=F.index(n);let s=i[e.code==="ArrowDown"?r+2:r-2];s&&(s.tabIndex="0",s.focus()),e.preventDefault();break}case"ArrowLeft":{n.tabIndex="-1";let s=n.previousElementSibling;s?(s.tabIndex="0",s.focus()):(this.navigationState={backward:!0},this.navBackward(e)),e.preventDefault();break}case"ArrowRight":{n.tabIndex="-1";let s=n.nextElementSibling;s?(s.tabIndex="0",s.focus()):(this.navigationState={backward:!1},this.navForward(e)),e.preventDefault();break}case"PageUp":{if(e.shiftKey)return;this.navigationState={backward:!0},this.navBackward(e);break}case"PageDown":{if(e.shiftKey)return;this.navigationState={backward:!1},this.navForward(e);break}case"Enter":case"Space":{this.onYearSelect(e,t),e.preventDefault();break}case"Escape":{this.overlayVisible=!1,e.preventDefault();break}case"Tab":{this.trapFocus(e);break}}},updateFocus(){let e;if(this.navigationState){if(this.navigationState.button)this.initFocusableCell(),this.navigationState.backward?F.findSingle(this.overlay,".p-datepicker-prev").focus():F.findSingle(this.overlay,".p-datepicker-next").focus();else{if(this.navigationState.backward){let t;this.currentView==="month"?t=F.find(this.overlay,".p-monthpicker .p-monthpicker-month:not(.p-disabled)"):this.currentView==="year"?t=F.find(this.overlay,".p-yearpicker .p-yearpicker-year:not(.p-disabled)"):t=F.find(this.overlay,".p-datepicker-calendar td span:not(.p-disabled):not(.p-ink)"),t&&t.length>0&&(e=t[t.length-1])}else this.currentView==="month"?e=F.findSingle(this.overlay,".p-monthpicker .p-monthpicker-month:not(.p-disabled)"):this.currentView==="year"?e=F.findSingle(this.overlay,".p-yearpicker .p-yearpicker-year:not(.p-disabled)"):e=F.findSingle(this.overlay,".p-datepicker-calendar td span:not(.p-disabled):not(.p-ink)");e&&(e.tabIndex="0",e.focus())}this.navigationState=null}else this.initFocusableCell()},initFocusableCell(){let e;if(this.currentView==="month"){let t=F.find(this.overlay,".p-monthpicker .p-monthpicker-month"),n=F.findSingle(this.overlay,".p-monthpicker .p-monthpicker-month.p-highlight");t.forEach(i=>
1539i.tabIndex=-1),e=n||t[0]}else if(this.currentView==="year"){let t=F.find(this.overlay,".p-yearpicker .p-yearpicker-year"),n=F.findSingle(this.overlay,".p-yearpicker .p-yearpicker-year.p-highlight");t.forEach(i=>i.tabIndex=-1),e=n||t[0]}else if(e=F.findSingle(this.overlay,"span.p-highlight"),!e){let t=F.findSingle(this.overlay,"td.p-datepicker-today span:not(.p-disabled):not(.p-ink)");t?e=t:e=F.findSingle(this.overlay,".p-datepicker-calendar td span:not(.p-disabled):not(.p-ink)")}e&&(e.tabIndex="0",!this.inline&&(!this.navigationState||!this.navigationState.button)&&!this.timePickerChange&&e.focus(),this.preventFocus=!1)},trapFocus(e){e.preventDefault();let t=F.getFocusableElements(this.overlay);if(t&&t.length>0)if(!document.activeElement)t[0].focus();else{let n=t.indexOf(document.activeElement);if(e.shiftKey)n===-1||n===0?t[t.length-1].focus():t[n-1].focus();else if(n===-1)if(this.timeOnly)t[0].focus();else{let i=null;for(let r=0;r<t.length;r++)t[r].tagName==="SPAN"&&(i=r);t[i].focus()}else n===t.length-1?t[0].focus():t[n+1].focus()}},onContainerButtonKeydown(e){switch(e.code){case"Tab":this.trapFocus(e);break;case"Escape":this.overlayVisible=!1,e.preventDefault();break}this.$emit("keydown",e)},onInput(e){try{this.selectionStart=this.input.selectionStart,this.selectionEnd=this.input.selectionEnd;let t=this.parseValue(e.target.value);this.isValidSelection(t)&&(this.typeUpdate=!0,this.updateModel(t))}catch{}this.$emit("input",e)},onInputClick(){this.showOnFocus&&this.isEnabled()&&!this.overlayVisible&&(this.overlayVisible=!0)},onFocus(e){this.showOnFocus&&this.isEnabled()&&(this.overlayVisible=!0),this.focused=!0,this.$emit("focus",e)},onBlur(e){this.$emit("blur",{originalEvent:e,value:e.target.value}),this.focused=!1,e.target.value=this.formatValue(this.modelValue)},onKeyDown(e){e.code==="ArrowDown"&&this.overlay?this.trapFocus(e):e.code==="ArrowDown"&&!this.overlay?this.overlayVisible=!0:e.code==="Escape"?this.overlayVisible&&(this.overlayVisible=!1,e.preventDefault()):e.code==="Tab"&&(this.overlay&&F.getFocusableElements(this.overlay).forEach(t=>t.tabIndex="-1"),this.overlayVisible&&(this.overlayVisible=!1))},overlayRef(e){this.overlay=e},inputRef(e){this.input=e},getMonthName(e){return this.$primevue.config.locale.monthNames[e]},getYear(e){return this.currentView==="month"?this.currentYear:e.year},onOverlayClick(e){this.inline||Mt.emit("overlay-click",{originalEvent:e,target:this.$el})},onOverlayKeyDown(e){switch(e.code){case"Escape":this.input.focus(),this.overlayVisible=!1;break}},onOverlayMouseUp(e){this.onOverlayClick(e)},createResponsiveStyle(){if(this.numberOfMonths>1&&this.responsiveOptions){this.responsiveStyleElement||(this.responsiveStyleElement=document.createElement("style"),this.responsiveStyleElement.type="text/css",document.body.appendChild(this.responsiveStyleElement));let e="";if(this.responsiveOptions){let t=[...this.responsiveOptions].filter(n=>!!(n.breakpoint&&n.numMonths)).sort((n,i)=>-1*n.breakpoint.localeCompare(i.breakpoint,void 0,{numeric:!0}));for(let n=0;n<t.length;n++){let{breakpoint:i,numMonths:r}=t[n],s=`
1540                            .p-datepicker[${this.attributeSelector}] .p-datepicker-group:nth-child(${r}) .p-datepicker-next {
1541                                display: inline-flex !important;
1542                            }
1543                        `;for(let a=r;a<this.numberOfMonths;a++)s+=`
1544                                .p-datepicker[${this.attributeSelector}] .p-datepicker-group:nth-child(${a+1}) {
1545                                    display: none !important;
1546                                }
1547                            `;e+=`
1548                            @media screen and (max-width: ${i}) {
1549                                ${s}
1550                            }
1551                        `}}this.responsiveStyleElement.innerHTML=e}},destroyResponsiveStyleElement(){this.responsiveStyleElement&&(this.responsiveStyleElement.remove(),this.responsiveStyleElement=null)}},computed:{viewDate(){let e=this.modelValue;if(e&&Array.isArray(e)&&(this.isRangeSelection()?e=this.inline?e[0]:e[1]||e[0]:this.isMultipleSelection()&&(e=e[e.length-1])),e&&typeof e!="string")return e;{let t=new Date;return this.maxDate&&this.maxDate<t?this.maxDate:this.minDate&&this.minDate>t?this.minDate:t}},inputFieldValue(){return this.formatValue(this.modelValue)},containerClass(){return["p-calendar p-component p-inputwrapper",{"p-calendar-w-btn":this.showIcon,"p-calendar-timeonly":this.timeOnly,"p-calendar-disabled":this.disabled,"p-inputwrapper-filled":this.modelValue,"p-inputwrapper-focus":this.focused}]},panelStyleClass(){return["p-datepicker p-component",this.panelClass,{"p-datepicker-inline":this.inl
1551ine,"p-disabled":this.disabled,"p-datepicker-timeonly":this.timeOnly,"p-datepicker-multiple-month":this.numberOfMonths>1,"p-datepicker-monthpicker":this.currentView==="month","p-datepicker-yearpicker":this.currentView==="year","p-datepicker-touch-ui":this.touchUI,"p-input-filled":this.$primevue.config.inputStyle==="filled","p-ripple-disabled":this.$primevue.config.ripple===!1}]},months(){let e=[];for(let t=0;t<this.numberOfMonths;t++){let n=this.currentMonth+t,i=this.currentYear;n>11&&(n=n%11-1,i=i+1);let r=[],s=this.getFirstDayOfMonthIndex(n,i),a=this.getDaysCountInMonth(n,i),o=this.getDaysCountInPrevMonth(n,i),l=1,c=new Date,d=[],u=Math.ceil((a+s)/7);for(let p=0;p<u;p++){let h=[];if(p==0){for(let v=o-s+1;v<=o;v++){let _=this.getPreviousMonthAndYear(n,i);h.push({day:v,month:_.month,year:_.year,otherMonth:!0,today:this.isToday(c,v,_.month,_.year),selectable:this.isSelectable(v,_.month,_.year,!0)})}let m=7-h.length;for(let v=0;v<m;v++)h.push({day:l,month:n,year:i,today:this.isToday(c,l,n,i),selectable:this.isSelectable(l,n,i,!1)}),l++}else for(let m=0;m<7;m++){if(l>a){let v=this.getNextMonthAndYear(n,i);h.push({day:l-a,month:v.month,year:v.year,otherMonth:!0,today:this.isToday(c,l-a,v.month,v.year),selectable:this.isSelectable(l-a,v.month,v.year,!0)})}else h.push({day:l,month:n,year:i,today:this.isToday(c,l,n,i),selectable:this.isSelectable(l,n,i,!1)});l++}this.showWeek&&d.push(this.getWeekNumber(new Date(h[0].year,h[0].month,h[0].day))),r.push(h)}e.push({month:n,year:i,dates:r,weekNumbers:d})}return e},weekDays(){let e=[],t=this.$primevue.config.locale.firstDayOfWeek;for(let n=0;n<7;n++)e.push(this.$primevue.config.locale.dayNamesMin[t]),t=t==6?0:++t;return e},ticksTo1970(){return(1969*365+Math.floor(1970/4)-Math.floor(1970/100)+Math.floor(1970/400))*24*60*60*1e7},sundayIndex(){return this.$primevue.config.locale.firstDayOfWeek>0?7-this.$primevue.config.locale.firstDayOfWeek:0},datePattern(){return this.dateFormat||this.$primevue.config.locale.dateFormat},yearOptions(){if(this.yearRange){let e=this;const t=this.yearRange.split(":");let n=parseInt(t[0]),i=parseInt(t[1]),r=[];this.currentYear<n?e.currentYear=i:this.currentYear>i&&(e.currentYear=n);for(let s=n;s<=i;s++)r.push(s);return r}else return null},monthPickerValues(){let e=[];const t=n=>{if(this.minDate){const i=this.minDate.getMonth(),r=this.minDate.getFullYear();if(this.currentYear<r||this.currentYear===r&&n<i)return!1}if(this.maxDate){const i=this.maxDate.getMonth(),r=this.maxDate.getFullYear();if(this.currentYear>r||this.currentYear===r&&n>i)return!1}return!0};for(let n=0;n<=11;n++)e.push({value:this.$primevue.config.locale.monthNamesShort[n],selectable:t(n)});return e},yearPickerValues(){let e=[],t=this.currentYear-this.currentYear%10;const n=i=>!(this.minDate&&this.minDate.getFullYear()>i||this.maxDate&&this.maxDate.getFullYear()<i);for(let i=0;i<10;i++)e.push({value:t+i,selectable:n(t+i)});return e},formattedCurrentHour(){return this.currentHour<10?"0"+this.currentHour:this.currentHour},formattedCurrentMinute(){return this.currentMinute<10?"0"+this.currentMinute:this.currentMinute},formattedCurrentSecond(){return this.currentSecond<10?"0"+this.currentSecond:this.currentSecond},todayLabel(){return this.$primevue.config.locale.today},clearLabel(){return this.$primevue.config.locale.clear},weekHeaderLabel(){return this.$primevue.config.locale.weekHeader},monthNames(){return this.$primevue.config.locale.monthNames},attributeSelector(){return pt()},switchViewButtonDisabled(){return this.numberOfMonths>1||this.disabled},panelId(){return pt()+"_panel"}},components:{CalendarButton:Qn,Portal:Kt,CalendarIcon:fm,ChevronLeftIcon:Vs,ChevronRightIcon:Rn,ChevronUpIcon:sa,ChevronDownIcon:_n},directives:{ripple:gt}};const kL=["id"],RL=["id","placeholder","aria-expanded","aria-controls","aria-labelledby","aria-label","disabled","readonly"],LL=["id","role","aria-modal","aria-label"],NL=["disabled","aria-label"],DL=["disabled","aria-label"],xL=["disabled","aria-label"],ML=["disabled","aria-label"],FL=["abbr"],VL=["aria-label"],BL=["onClick","onKeydown","aria-selected"],$L=["onClick","onKeydown"],UL=["onClick","onKeydown"],HL=["aria-label"],zL=["aria-label"],KL=["aria-label","disabled"],GL=["aria-label","disabled"],jL=["aria-label","disabled"],YL=["aria-label","disabled"],WL=["aria-label","disabled"],QL=["aria-label","disabled"];function ZL(e,t,n,i,r,s){const a=le("CalendarButton"),o=le("Portal"),l=Xe("ripple");return g(),S("span",R({ref:"container",id:n.id,class:s.containerClass},e.ptm("root")),[n.inline?M("",!0):(g(),S("input",R({key:0,ref:s.inputRef,id:n.inputId,type:"text",role:"combobox",class:["p-inputtext p-component",n.inputClass],style:n.inputStyle,placeholder:n.placeholder,autocomplete:"off","aria-autocomplete":"none","aria-haspopup":"dialog","aria-expanded":r.overlayVisible,"aria-controls":s.panelId,"aria-labelledby":e.ariaLabelledby,"aria-label":e.ariaLabel,inputmode:"none",disabled:n.disabled,readonly:!n.manualInput||n.readonly,tabindex:0,onInput:t[0]||(t[0]=(...c)=>s.onInput&&s.onInput(...c)),onClick:t[1]||(t[1]=(...c)=>s.onInputClick&&s.onInputClick(...c)),onFocus:t[2]||(t[2]=(...c)=>s.onFocus&&s.onFocus(...c)),onBlur:t[3]||(t[3]=(...c)=>s.onBlur&&s.onBlur(...c)),onKeydown:t[4]||(t[4]=(...c)=>s.onKeyDown&&s.onKeyDown(...c))},{...n.inputProps,...e.ptm("input")}),null,16,RL)),n.showIcon?(g(),Q(a,{key:1,class:"p-datepicker-trigger",disabled:n.disabled,onClick:s.onButtonClick,type:"button","aria-label":e.$primevue.config.locale.chooseDate,"aria-haspopup":"dialog","aria-expanded":r.overlayVisible,"aria-controls":s.panelId,pt:e.ptm("dropdownButton")},{icon:Ee(()=>[he(e.$slots,"dropdownicon",{},()=>[(g(),Q(_e(n.icon?"span":"CalendarIcon"),R({class:n.icon},e.ptm("dropdownButton").icon),null,16,["class"]))])]),_:3},8,["disabled","onClick","aria-label","aria-expanded","aria-controls","pt"])):M("",!0),de(o,{appendTo:n.appendTo,disabled:n.inline},{default:Ee(()=>[de($t,{name:"p-connected-overlay",onEnter:t[68]||(t[68]=c=>s.onOverlayEnter(c)),onAfterEnter:s.onOverlayEnterComplete,onAfterLeave:s.onOverlayAfterLeave,onLeave:s.onOverlayLeave},{default:Ee(()=>[n.inline||r.overlayVisible?(g(),S("div",R({key:0,ref:s.overlayRef,id:s.panelId,class:s.panelStyleClass,style:n.panelStyle,role:n.inline?null:"dialog","aria-modal":n.inline?null:"true","aria-label":e.$primevue.config.locale.chooseDate,onClick:t[65]||(t[65]=(...c)=>s.onOverlayClick&&s.onOverlayClick(...c)),onKeydown:t[66]||(t[66]=(...c)=>s.onOverlayKeyDown&&s.onOverlayKeyDown(...c)),onMouseup:t[67]||(t[67]=(...c)=>s.onOverlayMouseUp&&s.onOverlayMouseUp(...c))},{...n.panelProps,...e.ptm("panel")}),[n.timeOnly?M("",!0):(g(),S(J,{key:0},[f("div",R({class:"p-datepicker-group-container"},e.ptm("groupContainer")),[(g(!0),S(J,null,ye(s.months,(c,d)=>(g(),S("div",R({key:c.month+c.year,class:"p-datepicker-group"},e.ptm("group")),[f("div",R({class:"p-datepicker-header"},e.ptm("header")),[he(e.$slots,"header"),Ne((g(),S("button",R({class:"p-datepicker-prev p-link",onClick:t[5]||(t[5]=(...u)=>s.onPrevButtonClick&&s.onPrevButtonClick(...u)),type:"button",onKeydown:t[6]||(t[6]=(...u)=>s.onContainerButtonKeydown&&s.onContainerButtonKeydown(...u)),disabled:n.disabled,"aria-label":r.currentView==="year"?e.$primevue.config.locale.prevDecade:r.currentView==="month"?e.$primevue.config.locale.prevYear:e.$primevue.config.locale.prevMonth},e.ptm("previousButton")),[he(e.$slots,"previousicon",{},()=>[(g(),Q(_e(n.previousIcon?"span":"ChevronLeftIcon"),R({class:["p-datepicker-prev-icon",n.previousIcon]},e.ptm("previousIcon")),null,16,["class"]))])],16,NL)),[[mt,n.showOtherMonths?d===0:!1],[l]]),f("div",R({class:"p-datepicker-title"},e.ptm("title")),[r.currentView==="date"?(g(),S("button",R({key:0,type:"button",onClick:t[7]||(t[7]=(...u)=>s.switchToMonthView&&s.switchToMonthView(...u)),onKeydown:t[8]||(t[8]=(...u)=>s.onContainerButtonKeydown&&s.onContainerButtonKeydown(...u)),class:"p-datepicker-month p-link",disabled:s.switchViewButtonDisabled,"aria-label":e.$primevue.config.locale.chooseMonth},e.ptm("monthTitle")),N(s.getMonthName(c.month)),17,DL)):M("",!0),r.currentView!=="year"?(g(),S("button",R({key:1,type:"button",onClick:t[9]||(t[9]=(...u)=>s.switchToYearView&&s.switchToYearView(...u)),onKeydown:t[10]||(t[10]=(...u)=>s.onContainerButtonKeydown&&s.onContainerButtonKeydown(...u)),class:"p-datepicker-year p-link",disabled:s.switchViewButtonDisabled,"aria-label":e.$primevue.config.locale.chooseYear},e.ptm("yearTitle")),N(s.getYear(c)),17,xL)):M("",!0),r.currentView==="year"?(g(),S("span",R({key:2,class:"p-datepicker-decade"},e.ptm("decadeTitle")),[he(e.$slots,"decade",{years:s.yearPickerValues},()=>[ke(N(s.yearPickerValues[0].value)+" - "+N(s.yearPickerValues[s.yearPickerValues.length-1].value),1)])],16)):M("",!0)],16),Ne((g(),S("button",R({class:"p-datepicker-next p-link",onClick:t[11]||(t[11]=(...u)=>s.onNextButtonClick&&s.onNextButtonClick(...u)),type:"button",onKeydown:t[12]||(t[12]=(...u)=>s.onContainerButtonKeydown&&s.onContainerButtonKeydown(...u)),disabled:n.disabled,"aria-label":r.currentView==="year"?e.$primevue.config.locale.nextDecade:r.currentView==="month"?e.$primevue.config.locale.nextYear:e.$primevue.config.locale.nextMonth},e.ptm("nextButton")),[he(e.$slots,"nexticon",{},()=>[(g(),Q(_e(n.nextIcon?"span":"ChevronRightIcon"),R({class:["p-datepicker-next-icon",n.nextIcon]},e.ptm("nextIcon")),null,16,["class"]))])],16,ML)),[[mt,n.showOtherMonths?n.numberOfMonths===1?!0:d===n.numberOfMonths-1:!1],[l]])],16),r.currentView==="date"?(g(),S("div",R({key:0,class:"p-datepicker-calendar-container"},e.ptm("container")),[f("table",R({class:"p-datepicker-calendar",role:"grid"},e.ptm("table")),[f("thead",ft(Tt(e.ptm("tableHeader"))),[f("tr",ft(Tt(e.ptm("tableHeaderRow"))),[n.showWeek?(g(),S("th",R({key:0,scope:"col",class:"p-datepicker-weekheader p-disabled"},e.ptm("weekHeader")),[f("span",ft(Tt(e.ptm("weekLabel"))),N(s.weekHeaderLabel),17)],16)):M("",!0),(g(!0),S(J,null,ye(s.weekDays,u=>(g(),S("th",R({key:u,scope:"col",abbr:u},e.ptm("tableHeaderCell")),[f("span",ft(Tt(e.ptm("weekDay"))),N(u),17)],16,FL))),128))],16)],16),f("tbody",ft(Tt(e.ptm("tableBody"))),[(g(!0),S(J,null,ye(c.dates,(u,p)=>(g(),S("tr",R({key:u[0].day+""+u[0].month},e.ptm("tableBodyRow")),[n.showWeek?(g(),S("td",R({key:0,class:"p-datepicker-weeknumber"},e.ptm("weekNumber")),[f("span",R({class:"p-disabled"},e.ptm("weekLabelContainer")),[c.weekNumbers[p]<10?(g(),S("span",R({key:0,style:{visibility:"hidden"}},e.ptm("weekLabel")),"0",16)):M("",!0),ke(" "+N(c.weekNumbers[p]),1)],16)],16)):M("",!0),(g(!0),S(J,null,ye(u,h=>(g(),S("td",R({key:h.day+""+h.month,"aria-label":h.day,class:{"p-datepicker-other-month":h.otherMonth,"p-datepicker-today":h.today}},e.ptm("day")),[Ne((g(),S("span",R({class:{"p-highlight":s.isSelected(h),"p-disabled":!h.selectable},onClick:m=>s.onDateSelect(m,h),draggable:"false",onKeydown:m=>s.onDateCellKeydown(m,h,d),"aria-selected":s.isSelected(h)},e.ptm("dayLabel")),[he(e.$slots,"date",{date:h},()=>[ke(N(h.day),1)])],16,BL)),[[l]]),s.isSelected(h)?(g(),S("div",R({key:0,class:"p-hidden-accessible","aria-live":"polite"},e.ptm("ariaSelectedDay")),N(h.day),17)):M("",!0)],16,VL))),128))],16))),128))],16)],16)],16)):M("",!0)],16))),128))],16),r.currentView==="month"?(g(),S("div",R({key:0,class:"p-monthpicker"},e.ptm("monthPicker")),[(g(!0),S(J,null,ye(s.monthPickerValues,(c,d)=>Ne((g(),S("span",R({key:c,onClick:u=>s.onMonthSelect(u,{month:c,index:d}),onKeydown:u=>s.onMonthCellKeydown(u,{month:c,index:d}),class:["p-monthpicker-month",{"p-highlight":s.isMonthSelected(d),"p-disabled":!c.selectable}]},e.ptm("month")),[ke(N(c.value)+" ",1),s.isMonthSelected(d)?(g(),S("div",R({key:0,class:"p-hidden-accessible","aria-live":"polite"},e.ptm("ariaMonth")),N(c.value),17)):M("",!0)],16,$L)),[[l]])),128))],16)):M("",!0),r.currentView==="year"?(g(),S("div",R({key:1,class:"p-yearpicker"},e.ptm("yearPicker")),[(g(!0),S(J,null,ye(s.yearPickerValues,c=>Ne((g(),S("span",R({key:c.value,onClick:d=>s.onYearSelect(d,c),onKeydown:d=>s.onYearCellKeydown(d,c),class:["p-yearpicker-year",{"p-highlight":s.isYearSelected(c.value),"p-disabled":!c.selectable}]},e.ptm("year")),[ke(N(c.value)+" ",1),s.isYearSelected(c.value)?(g(),S("div",R({key:0,class:"p-hidden-accessible","aria-live":"polite"},e.ptm("ariaYear")),N(c.value),17)):M("",!0)],16,UL)),[[l]])),128))],16)):M("",!0)],64)),(n.showTime||n.timeOnly)&&r.currentView==="date"?(g(),S("div",R({key:1,class:"p-timepicker"},e.ptm("timePicker")),[f("div",R({class:"p-hour-picker"},e.ptm("hourPicker")),[Ne((g(),S("button",R({class:"p-link","aria-label":e.$primevue.config.locale.nextHour,onMousedown:t[13]||(t[13]=c=>s.onTimePickerElementMouseDown(c,0,1)),onMouseup:t[14]||(t[14]=c=>s.onTimePickerElementMouseUp(c)),onKeydown:[t[15]||(t[15]=(...c)=>s.onContainerButtonKeydown&&s.onContainerButtonKeydown(...c)),t[17]||(t[17]=Je(c=>s.onTimePickerElementMouseDown(c,0,1),["enter"])),t[18]||(t[18]=Je(c=>s.onTimePickerElementMouseDown(c,0,1),["space"]))],onMouseleave:t[16]||(t[16]=c=>s.onTimePickerElementMouseLeave()),onKeyup:[t[19]||(t[19]=Je(c=>s.onTimePickerElementMouseUp(c),["enter"])),t[20]||(t[20]=Je(c=>s.onTimePickerElementMouseUp(c),["space"]))],type:"button"},e.ptm("incrementButton")),[he(e.$slots,"incrementicon",{},()=>[(g(),Q(_e(n.incrementIcon?"span":"ChevronUpIcon"),R({class:n.incrementIcon},e.ptm("incrementIcon")),null,16,["class"]))])],16,HL)),[[l]]),f("span",ft(Tt(e.ptm("hour"))),N(s.formattedCurrentHour),17),Ne((g(),S("button",R({class:"p-link","aria-label":e.$primevue.config.locale.prevHour,onMousedown:t[21]||(t[21]=c=>s.onTimePickerElementMouseDown(c,0,-1)),onMouseup:t[22]||(t[22]=c=>s.onTimePickerElementMouseUp(c)),onKeydown:[t[23]||(t[23]=(...c)=>s.onContainerButtonKeydown&&s.onContainerButtonKeydown(...c)),t[25]||(t[25]=Je(c=>s.onTimePickerElementMouseDown(c,0,-1),["enter"])),t[26]||(t[26]=Je(c=>s.onTimePickerElementMouseDown(c,0,-1),["space"]))],onMouseleave:t[24]||(t[24]=c=>s.onTimePickerElementMouseLeave()),onKeyup:[t[27]||(t[27]=Je(c=>s.onTimePickerElementMouseUp(c),["enter"])),t[28]||(t[28]=Je(c=>s.onTimePickerElementMouseUp(c),["space"]))],type:"button"},e.ptm("decrementButton")),[he(e.$slots,"decrementicon",{},()=>[(g(),Q(_e(n.decrementIcon?"span":"ChevronDownIcon"),R({class:n.decrementIcon},e.ptm("decrementIcon")),null,16,["class"]))])],16,zL)),[[l]])],16),f("div",R({class:"p-separator"},e.ptm("separatorContainer")),[f("span",ft(Tt(e.ptm("separator"))),N(n.timeSeparator),17)],16),f("div",R({class:"p-minute-picker"},e.ptm("minutePicker")),[Ne((g(),S("button",R({class:"p-link","aria-label":e.$primevue.config.locale.nextMinute,onMousedown:t[29]||(t[29]=c=>s.onTimePickerElementMouseDown(c,1,1)),onMouseup:t[30]||(t[30]=c=>s.onTimePickerElementMouseUp(c)),onKeydown:[t[31]||(t[31]=(...c)=>s.onContainerButtonKeydown&&s.onContainerButtonKeydown(...c)),t[33]||(t[33]=Je(c=>s.onTimePickerElementMouseDown(c,1,1),["enter"])),t[34]||(t[34]=Je(c=>s.onTimePickerElementMouseDown(c,1,1),["space"]))],disabled:n.disabled,onMouseleave:t[32]||(t[32]=c=>s.onTimePickerElementMouseLeave()),onKeyup:[t[35]||(t[35]=Je(c=>s.onTimePickerElementMouseUp(c),["enter"])),t[36]||(t[36]=Je(c=>s.onTimePickerElementMouseUp(c),["space"]))],type:"button"},e.ptm("incrementButton")),[he(e.$slots,"incrementicon",{},()=>[(g(),Q(_e(n.incrementIcon?"span":"ChevronUpIcon"),R({class:n.incrementIcon},e.ptm("incrementIcon")),null,16,["class"]))])],16,KL)),[[l]]),f("span",ft(Tt(e.ptm("minute"))),N(s.formattedCurrentMinute),17),Ne((g(),S("button",R({class:"p-link","aria-label":e.$primevue.config.locale.prevMinute,onMousedown:t[37]||(t[37]=c=>s.onTimePickerElementMouseDown(c,1,-1)),onMouseup:t[38]||(t[38]=c=>s.onTimePickerElementMouseUp(c)),onKeydown:[t[39]||(t[39]=(...c)=>s.onContainerButtonKeydown&&s.onContainerButtonKeydown(...c)),t[41]||(t[41]=Je(c=>s.onTimePickerElementMouseDown(c,1,-1),["enter"])),t[42]||(t[42]=Je(c=>s.onTimePickerElementMouseDown(c,1,-1),["space"]))],disabled:n.disabled,onMouseleave:t[40]||(t[40]=c=>s.onTimePickerElementMouseLeave()),onKeyup:[t[43]||(t[43]=Je(c=>s.onTimePickerElementMouseUp(c),["enter"])),t[44]||(t[44]=Je(c=>s.onTimePickerElementMouseUp(c),["space"]))],type:"button"},e.ptm("decrementButton")),[he(e.$slots,"decrementicon",{},()=>[(g(),Q(_e(n.decrementIcon?"span":"ChevronDownIcon"),R({class:n.decrementIcon},e.ptm("decrementIcon")),null,16,["class"]))])],16,GL)),[[l]])],16),n.showSeconds?(g(),S("div",R(
1551{key:0,class:"p-separator"},e.ptm("separatorContainer")),[f("span",ft(Tt(e.ptm("separator"))),N(n.timeSeparator),17)],16)):M("",!0),n.showSeconds?(g(),S("div",R({key:1,class:"p-second-picker"},e.ptm("secondPicker")),[Ne((g(),S("button",R({class:"p-link","aria-label":e.$primevue.config.locale.nextSecond,onMousedown:t[45]||(t[45]=c=>s.onTimePickerElementMouseDown(c,2,1)),onMouseup:t[46]||(t[46]=c=>s.onTimePickerElementMouseUp(c)),onKeydown:[t[47]||(t[47]=(...c)=>s.onContainerButtonKeydown&&s.onContainerButtonKeydown(...c)),t[49]||(t[49]=Je(c=>s.onTimePickerElementMouseDown(c,2,1),["enter"])),t[50]||(t[50]=Je(c=>s.onTimePickerElementMouseDown(c,2,1),["space"]))],disabled:n.disabled,onMouseleave:t[48]||(t[48]=c=>s.onTimePickerElementMouseLeave()),onKeyup:[t[51]||(t[51]=Je(c=>s.onTimePickerElementMouseUp(c),["enter"])),t[52]||(t[52]=Je(c=>s.onTimePickerElementMouseUp(c),["space"]))],type:"button"},e.ptm("incrementButton")),[he(e.$slots,"incrementicon",{},()=>[(g(),Q(_e(n.incrementIcon?"span":"ChevronUpIcon"),R({class:n.incrementIcon},e.ptm("incrementIcon")),null,16,["class"]))])],16,jL)),[[l]]),f("span",ft(Tt(e.ptm("second"))),N(s.formattedCurrentSecond),17),Ne((g(),S("button",R({class:"p-link","aria-label":e.$primevue.config.locale.prevSecond,onMousedown:t[53]||(t[53]=c=>s.onTimePickerElementMouseDown(c,2,-1)),onMouseup:t[54]||(t[54]=c=>s.onTimePickerElementMouseUp(c)),onKeydown:[t[55]||(t[55]=(...c)=>s.onContainerButtonKeydown&&s.onContainerButtonKeydown(...c)),t[57]||(t[57]=Je(c=>s.onTimePickerElementMouseDown(c,2,-1),["enter"])),t[58]||(t[58]=Je(c=>s.onTimePickerElementMouseDown(c,2,-1),["space"]))],disabled:n.disabled,onMouseleave:t[56]||(t[56]=c=>s.onTimePickerElementMouseLeave()),onKeyup:[t[59]||(t[59]=Je(c=>s.onTimePickerElementMouseUp(c),["enter"])),t[60]||(t[60]=Je(c=>s.onTimePickerElementMouseUp(c),["space"]))],type:"button"},e.ptm("decrementButton")),[he(e.$slots,"decrementicon",{},()=>[(g(),Q(_e(n.decrementIcon?"span":"ChevronDownIcon"),R({class:n.decrementIcon},e.ptm("decrementIcon")),null,16,["class"]))])],16,YL)),[[l]])],16)):M("",!0),n.hourFormat=="12"?(g(),S("div",R({key:2,class:"p-separator"},e.ptm("separatorContainer")),[f("span",ft(Tt(e.ptm("separator"))),N(n.timeSeparator),17)],16)):M("",!0),n.hourFormat=="12"?(g(),S("div",R({key:3,class:"p-ampm-picker"},e.ptm("ampmPicker")),[Ne((g(),S("button",R({class:"p-link","aria-label":e.$primevue.config.locale.am,onClick:t[61]||(t[61]=c=>s.toggleAMPM(c)),type:"button",disabled:n.disabled},e.ptm("incrementButton")),[he(e.$slots,"incrementicon",{},()=>[(g(),Q(_e(n.incrementIcon?"span":"ChevronUpIcon"),R({class:n.incrementIcon},e.ptm("incrementIcon")),null,16,["class"]))])],16,WL)),[[l]]),f("span",ft(Tt(e.ptm("ampm"))),N(r.pm?e.$primevue.config.locale.pm:e.$primevue.config.locale.am),17),Ne((g(),S("button",R({class:"p-link","aria-label":e.$primevue.config.locale.pm,onClick:t[62]||(t[62]=c=>s.toggleAMPM(c)),type:"button",disabled:n.disabled},e.ptm("decrementButton")),[he(e.$slots,"decrementicon",{},()=>[(g(),Q(_e(n.decrementIcon?"span":"ChevronDownIcon"),R({class:n.decrementIcon},e.ptm("decrementIcon")),null,16,["class"]))])],16,QL)),[[l]])],16)):M("",!0)],16)):M("",!0),n.showButtonBar?(g(),S("div",R({key:2,class:"p-datepicker-buttonbar"},e.ptm("buttonbar")),[de(a,{type:"button",label:s.todayLabel,onClick:t[63]||(t[63]=c=>s.onTodayButtonClick(c)),class:"p-button-text",onKeydown:s.onContainerButtonKeydown,pt:e.ptm("todayButton")},null,8,["label","onKeydown","pt"]),de(a,{type:"button",label:s.clearLabel,onClick:t[64]||(t[64]=c=>s.onClearButtonClick(c)),class:"p-button-text",onKeydown:s.onContainerButtonKeydown,pt:e.ptm("clearButton")},null,8,["label","onKeydown","pt"])],16)):M("",!0),he(e.$slots,"footer")],16,LL)):M("",!0)]),_:3},8,["onAfterEnter","onAfterLeave","onLeave"])]),_:3},8,["appendTo","disabled"])],16,kL)}function qL(e,t){t===void 0&&(t={});var n=t.insertAt;if(!(typeof document>"u")){var i=document.head||document.getElementsByTagName("head")[0],r=document.createElement("style");r.type="text/css",n==="top"&&i.firstChild?i.insertBefore(r,i.firstChild):i.appendChild(r),r.styleSheet?r.styleSheet.cssText=e:r.appendChild(document.createTextNode(e))}}var JL=`
1552.p-calendar {
1553    position: relative;
1554    display: inline-flex;
1555    max-width: 100%;
1556}
1557.p-calendar .p-inputtext {
1558    flex: 1 1 auto;
1559    width: 1%;
1560}
1561.p-calendar-w-btn .p-inputtext {
1562    border-top-right-radius: 0;
1563    border-bottom-right-radius: 0;
1564}
1565.p-calendar-w-btn .p-datepicker-trigger {
1566    border-top-left-radius: 0;
1567    border-bottom-left-radius: 0;
1568}
1569
1570/* Fluid */
1571.p-fluid .p-calendar {
1572    display: flex;
1573}
1574.p-fluid .p-calendar .p-inputtext {
1575    width: 1%;
1576}
1577
1578/* Datepicker */
1579.p-calendar .p-datepicker {
1580    min-width: 100%;
1581}
1582.p-datepicker {
1583    width: auto;
1584    position: absolute;
1585    top: 0;
1586    left: 0;
1587}
1588.p-datepicker-inline {
1589    display: inline-block;
1590    position: static;
1591    overflow-x: auto;
1592}
1593
1594/* Header */
1595.p-datepicker-header {
1596    display: flex;
1597    align-items: center;
1598    justify-content: space-between;
1599}
1600.p-datepicker-header .p-datepicker-title {
1601    margin: 0 auto;
1602}
1603.p-datepicker-prev,
1604.p-datepicker-next {
1605    cursor: pointer;
1606    display: inline-flex;
1607    justify-content: center;
1608    align-items: center;
1609    overflow: hidden;
1610    position: relative;
1611}
1612
1613/* Multiple Month DatePicker */
1614.p-datepicker-multiple-month .p-datepicker-group-container {
1615    display: flex;
1616}
1617.p-datepicker-multiple-month .p-datepicker-group-container .p-datepicker-group {
1618    flex: 1 1 auto;
1619}
1620
1621/* DatePicker Table */
1622.p-datepicker table {
1623    width: 100%;
1624    border-collapse: collapse;
1625}
1626.p-datepicker td > span {
1627    display: flex;
1628    justify-content: center;
1629    align-items: center;
1630    cursor: pointer;
1631    margin: 0 auto;
1632    overflow: hidden;
1633    position: relative;
1634}
1635
1636/* Month Picker */
1637.p-monthpicker-month {
1638    width: 33.3%;
1639    display: inline-flex;
1640    align-items: center;
1641    justify-content: center;
1642    cursor: pointer;
1643    overflow: hidden;
1644    position: relative;
1645}
1646
1647/* Year Picker */
1648.p-yearpicker-year {
1649    width: 50%;
1650    display: inline-flex;
1651    align-items: center;
1652    justify-content: center;
1653    cursor: pointer;
1654    overflow: hidden;
1655    position: relative;
1656}
1657
1658/*  Button Bar */
1659.p-datepicker-buttonbar {
1660    display: flex;
1661    justify-content: space-between;
1662    align-items: center;
1663}
1664
1665/* Time Picker */
1666.p-timepicker {
1667    display: flex;
1668    justify-content: center;
1669    align-items: center;
1670}
1671.p-timepicker button {
1672    display: flex;
1673    align-items: center;
1674    justify-content: center;
1675    cursor: pointer;
1676    overflow: hidden;
1677    position: relative;
1678}
1679.p-timepicker > div {
1680    display: flex;
1681    align-items: center;
1682    flex-direction: column;
1683}
1684
1685/* Touch UI */
1686.p-datepicker-touch-ui,
1687.p-calendar .p-datepicker-touch-ui {
1688    position: fixed;
1689    top: 50%;
1690    left: 50%;
1691    min-width: 80vw;
1692    transform: translate(-50%, -50%);
1693}
1694`;qL(JL);mm.render=ZL;var Dl={name:"EyeIcon",extends:ze};const XL=f("path",{"fill-rule":"evenodd","clip-rule":"evenodd",d:"M0.0535499 7.25213C0.208567 7.59162 2.40413 12.4 7 12.4C11.5959 12.4 13.7914 7.59162 13.9465 7.25213C13.9487 7.2471 13.9506 7.24304 13.952 7.24001C13.9837 7.16396 14 7.08239 14 7.00001C14 6.91762 13.9837 6.83605 13.952 6.76001C13.9506 6.75697 13.9487 6.75292 13.9465 6.74788C13.7914 6.4084 11.5959 1.60001 7 1.60001C2.40413 1.60001 0.208567 6.40839 0.0535499 6.74788C0.0512519 6.75292 0.0494023 6.75697 0.048 6.76001C0.0163137 6.83605 0 6.91762 0 7.00001C0 7.08239 0.0163137 7.16396 0.048 7.24001C0.0494023 7.24304 0.0512519 7.2471 0.0535499 7.25213ZM7 11.2C3.664 11.2 1.736 7.92001 1.264 7.00001C1.736 6.08001 3.664 2.80001 7 2.80001C10.336 2.80001 12.264 6.08001 12.736 7.00001C12.264 7.92001 10.336 11.2 7 11.2ZM5.55551 9.16182C5.98308 9.44751 6.48576 9.6 7 9.6C7.68891 9.59789 8.349 9.32328 8.83614 8.83614C9.32328 8.349 9.59789 7.68891 9.59999 7C9.59999 6.48576 9.44751 5.98308 9.16182 5.55551C8.87612 5.12794 8.47006 4.7947 7.99497 4.59791C7.51988 4.40112 6.99711 4.34963 6.49276 4.44995C5.98841 4.55027 5.52513 4.7979 5.16152 5.16152C4.7979 5.52513 4.55027 5.98841 4.44995 6.49276C4.34963 6.99711 4.40112 7.51988 4.59791 7.99497C4.7947 8.47006 5.12794 8.87612 5.55551 9.16182ZM6.2222 5.83594C6.45243 5.6821 6.7231 5.6 7 5.6C7.37065 5.6021 7.72553 5.75027 7.98762 6.01237C8.24972 6.27446 8.39789 6.62934 8.4 7C8.4 7.27689 8.31789 7.54756 8.16405 7.77779C8.01022 8.00802 7.79157 8.18746 7.53575 8.29343C7.27994 8.39939 6.99844 8.42711 6.72687 8.37309C6.4553 8.31908 6.20584 8.18574 6.01005 7.98994C5.81425 7.79415 5.68091 7.54469 5.6269 7.27312C5.57288 7.00155 5.6006 6.72006 5.70656 6.46424C5.81253 6.20842 5.99197 5.98977 6.2222 5.83594Z",fill:"currentColor"},null,-1),e6=[XL];function t6(e,t,n,i,r,s){return g(),S("svg",R({width:"14",height:"14",viewBox:"0 0 14 14",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e.pti()),e6,16)}Dl.render=t6;var gm={name:"EyeSlashIcon",extends:ze};const n6=f("g",{"clip-path":"url(#clip0_287_10550)"},[f("path",{"fill-rule":"evenodd","clip-rule":"evenodd",d:"M13.9414 6.74792C13.9437 6.75295 13.9455 6.757 13.9469 6.76003C13.982 6.8394 14.0001 6.9252 14.0001 7.01195C14.0001 7.0987 13.982 7.1845 13.9469 7.26386C13.6004 8.00059 13.1711 8.69549 12.6674 9.33515C12.6115 9.4071 12.54 9.46538 12.4582 9.50556C12.3765 9.54574 12.2866 9.56678 12.1955 9.56707C12.0834 9.56671 11.9737 9.53496 11.8788 9.47541C11.7838 9.41586 11.7074 9.3309 11.6583 9.23015C11.6092 9.12941 11.5893 9.01691 11.6008 8.90543C11.6124 8.79394 11.6549 8.68793 11.7237 8.5994C12.1065 8.09726 12.4437 7.56199 12.7313 6.99995C12.2595 6.08027 10.3402 2.8014 6.99732 2.8014C6.63723 2.80218 6.27816 2.83969 5.92569 2.91336C5.77666 2.93304 5.62568 2.89606 5.50263 2.80972C5.37958 2.72337 5.29344 2.59398 5.26125 2.44714C5.22907 2.30031 5.2532 2.14674 5.32885 2.01685C5.40451 1.88696 5.52618 1.79021 5.66978 1.74576C6.10574 1.64961 6.55089 1.60134 6.99732 1.60181C11.5916 1.60181 13.7864 6.40856 13.9414 6.74792ZM2.20333 1.61685C2.35871 1.61411 2.5091 1.67179 2.6228 1.77774L12.2195 11.3744C12.3318 11.4869 12.3949 11.6393 12.3949 11.7983C12.3949 11.9572 12.3318 12.1097 12.2195 12.2221C12.107 12.3345 11.9546 12.3976 11.7956 12.3976C11.6367 12.3976 11.4842 12.3345 11.3718 12.2221L10.5081 11.3584C9.46549 12.0426 8.24432 12.4042 6.99729 12.3981C2.403 12.3981 0.208197 7.59135 0.0532336 7.25198C0.0509364 7.24694 0.0490875 7.2429 0.0476856 7.23986C0.0162332 7.16518 3.05176e-05 7.08497 3.05176e-05 7.00394C3.05176e-05 6.92291 0.0162332 6.8427 0.0476856 6.76802C0.631261 5.47831 1.46902 4.31959 2.51084 3.36119L1.77509 2.62545C1.66914 2.51175 1.61146 2.36136 1.61421 2.20597C1.61695 2.05059 1.6799 1.90233 1.78979 1.79244C1.89968 1.68254 2.04794 1.6196 2.20333 1.61685ZM7.45314 8.35147L5.68574 6.57609V6.5361C5.5872 6.78938 5.56498 7.06597 5.
169462183 7.33173C5.67868 7.59749 5.8121 7.84078 6.00563 8.03158C6.19567 8.21043 6.43052 8.33458 6.68533 8.39089C6.94014 8.44721 7.20543 8.43359 7.45314 8.35147ZM1.26327 6.99994C1.7351 7.91163 3.64645 11.1985 6.99729 11.1985C7.9267 11.2048 8.8408 10.9618 9.64438 10.4947L8.35682 9.20718C7.86027 9.51441 7.27449 9.64491 6.69448 9.57752C6.11446 9.51014 5.57421 9.24881 5.16131 8.83592C4.74842 8.42303 4.4871 7.88277 4.41971 7.30276C4.35232 6.72274 4.48282 6.13697 4.79005 5.64041L3.35855 4.2089C2.4954 5.00336 1.78523 5.94935 1.26327 6.99994Z",fill:"currentColor"})],-1),s6=f("defs",null,[f("clipPath",{id:"clip0_287_10550"},[f("rect",{width:"14",height:"14",fill:"white"})])],-1),i6=[n6,s6];function r6(e,t,n,i,r,s){return g(),S("svg",R({width:"14",height:"14",viewBox:"0 0 14 14",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e.pti()),i6,16)}gm.render=r6;var ym={name:"Password",extends:Ve,emits:["update:modelValue","change","focus","blur","invalid"],props:{modelValue:String,promptLabel:{type:String,default:null},mediumRegex:{type:String,default:"^(((?=.*[a-z])(?=.*[A-Z]))|((?=.*[a-z])(?=.*[0-9]))|((?=.*[A-Z])(?=.*[0-9])))(?=.{6,})"},strongRegex:{type:String,default:"^(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.{8,})"},weakLabel:{type:String,default:null},mediumLabel:{type:String,default:null},strongLabel:{type:String,default:null},feedback:{type:Boolean,default:!0},appendTo:{type:String,default:"body"},toggleMask:{type:Boolean,default:!1},hideIcon:{type:String,default:void 0},showIcon:{type:String,default:void 0},disabled:{type:Boolean,default:!1},placeholder:{type:String,default:null},required:{type:Boolean,default:!1},inputId:{type:String,default:null},inputClass:{type:[String,Object],default:null},inputStyle:{type:Object,default:null},inputProps:{type:null,default:null},panelId:{type:String,default:null},panelClass:{type:[String,Object],default:null},panelStyle:{type:Object,default:null},panelProps:{type:null,default:null},"aria-labelledby":{type:String,default:null},"aria-label":{type:String,default:null}},data(){return{overlayVisible:!1,meter:null,infoText:null,focused:!1,unmasked:!1}},mediumCheckRegExp:null,strongCheckRegExp:null,resizeListener:null,scrollHandler:null,overlay:null,mounted(){this.infoText=this.promptText,this.mediumCheckRegExp=new RegExp(this.mediumRegex),this.strongCheckRegExp=new RegExp(this.strongRegex)},beforeUnmount(){this.unbindResizeListener(),this.scrollHandler&&(this.scrollHandler.destroy(),this.scrollHandler=null),this.overlay&&(He.clear(this.overlay),this.overlay=null)},methods:{onOverlayEnter(e){He.set("overlay",e,this.$primevue.config.zIndex.overlay),this.alignOverlay(),this.bindScrollListener(),this.bindResizeListener()},onOverlayLeave(){this.unbindScrollListener(),this.unbindResizeListener(),this.overlay=null},onOverlayAfterLeave(e){He.clear(e)},alignOverlay(){this.appendTo==="self"?F.relativePosition(this.overlay,this.$refs.input.$el):(this.overlay.style.minWidth=F.getOuterWidth(this.$refs.input.$el)+"px",F.absolutePosition(this.overlay,this.$refs.input.$el))},testStrength(e){let t=0;return this.strongCheckRegExp.test(e)?t=3:this.mediumCheckRegExp.test(e)?t=2:e.length&&(t=1),t},onInput(e){this.$emit("update:modelValue",e.target.value)},onFocus(e){this.focused=!0,this.feedback&&(this.setPasswordMeter(this.modelValue),this.overlayVisible=!0),this.$emit("focus",e)},onBlur(e){this.focused=!1,this.feedback&&(this.overlayVisible=!1),this.$emit("blur",e)},onKeyUp(e){if(this.feedback){const t=e.target.value,{meter:n,label:i}=this.checkPasswordStrength(t);if(this.meter=n,this.infoText=i,e.code==="Escape"){this.overlayVisible&&(this.overlayVisible=!1);return}this.overlayVisible||(this.overlayVisible=!0)}},setPasswordMeter(){if(!this.modelValue)return;const{meter:e,label:t}=this.checkPasswordStrength(this.modelValue);this.meter=e,this.infoText=t,this.overlayVisible||(this.overlayVisible=!0)},checkPasswordStrength(e){let t=null,n=null;switch(this.testStrength(e)){case 1:t=this.weakText,n={strength:"weak",width:"33.33%"};break;case 2:t=this.mediumText,n={strength:"medium",width:"66.66%"};break;case 3:t=this.strongText,n={strength:"strong",width:"100%"};break;default:t=this.promptText,n=null;break}return{label:t,meter:n}},onInvalid(e){this.$emit("invalid",e)},bindScrollListener(){this.scrollHandler||(this.scrollHandler=new kn(this.$refs.input.$el,()=>{this.overlayVisible&&(this.overlayVisible=!1)})),this.scrollHandler.bindScrollListener()},unbindScrollListener(){this.scrollHandler&&this.scrollHandler.unbindScrollListener()},bindResizeListener(){this.resizeListener||(this.resizeListener=()=>{this.overlayVisible&&!F.isTouchDevice()&&(this.overlayVisible=!1)},window.addEventListener("resize",this.resizeListener))},unbindResizeListener(){this.resizeListener&&(window.removeEventListener("resize",this.resizeListener),this.resizeListener=null)},overlayRef(e){this.overlay=e}
1694,onMaskToggle(){this.unmasked=!this.unmasked},onOverlayClick(e){Mt.emit("overlay-click",{originalEvent:e,target:this.$el})}},computed:{containerClass(){return["p-password p-component p-inputwrapper",{"p-inputwrapper-filled":this.filled,"p-inputwrapper-focus":this.focused,"p-input-icon-right":this.toggleMask}]},inputFieldClass(){return["p-password-input",this.inputClass,{"p-disabled":this.disabled}]},panelStyleClass(){return["p-password-panel p-component",this.panelClass,{"p-input-filled":this.$primevue.config.inputStyle==="filled","p-ripple-disabled":this.$primevue.config.ripple===!1}]},strengthClass(){return`p-password-strength ${this.meter?this.meter.strength:""}`},inputType(){return this.unmasked?"text":"password"},filled(){return this.modelValue!=null&&this.modelValue.toString().length>0},weakText(){return this.weakLabel||this.$primevue.config.locale.weak},mediumText(){return this.mediumLabel||this.$primevue.config.locale.medium},strongText(){return this.strongLabel||this.$primevue.config.locale.strong},promptText(){return this.promptLabel||this.$primevue.config.locale.passwordPrompt},panelUniqueId(){return pt()+"_panel"}},components:{PInputText:na,Portal:Kt,EyeSlashIcon:gm,EyeIcon:Dl}};const a6=["id"];function o6(e,t,n,i,r,s){const a=le("PInputText"),o=le("Portal");return g(),S("div",R({class:s.containerClass},e.ptm("root")),[de(a,R({ref:"input",id:n.inputId,type:s.inputType,class:s.inputFieldClass,style:n.inputStyle,value:n.modelValue,"aria-labelledby":e.ariaLabelledby,"aria-label":e.ariaLabel,"aria-controls":n.panelProps&&n.panelProps.id||n.panelId||s.panelUniqueId,"aria-expanded":r.overlayVisible,"aria-haspopup":!0,placeholder:n.placeholder,required:n.required,onInput:s.onInput,onFocus:s.onFocus,onBlur:s.onBlur,onKeyup:s.onKeyUp,onInvalid:s.onInvalid},{...n.inputProps,...e.ptm("input")}),null,16,["id","type","class","style","value","aria-labelledby","aria-label","aria-controls","aria-expanded","placeholder","required","onInput","onFocus","onBlur","onKeyup","onInvalid"]),n.toggleMask&&r.unmasked?he(e.$slots,"hideicon",{key:0,onClick:s.onMaskToggle},()=>[(g(),Q(_e(n.hideIcon?"i":"EyeSlashIcon"),R({class:n.hideIcon,onClick:s.onMaskToggle},e.ptm("hideIcon")),null,16,["class","onClick"]))]):M("",!0),n.toggleMask&&!r.unmasked?he(e.$slots,"showicon",{key:1,onClick:s.onMaskToggle},()=>[(g(),Q(_e(n.showIcon?"i":"EyeIcon"),R({class:n.showIcon,onClick:s.onMaskToggle},e.ptm("showIcon")),null,16,["class","onClick"]))]):M("",!0),f("span",R({class:"p-hidden-accessible","aria-live":"polite"},e.ptm("hiddenAccesible")),N(r.infoText),17),de(o,{appendTo:n.appendTo},{default:Ee(()=>[de($t,{name:"p-connected-overlay",onEnter:s.onOverlayEnter,onLeave:s.onOverlayLeave,onAfterLeave:s.onOverlayAfterLeave},{default:Ee(()=>[r.overlayVisible?(g(),S("div",R({key:0,ref:s.overlayRef,id:n.panelId||s.panelUniqueId,class:s.panelStyleClass,style:n.panelStyle,onClick:t[0]||(t[0]=(...l)=>s.onOverlayClick&&s.onOverlayClick(...l))},{...n.panelProps,...e.ptm("panel")}),[he(e.$slots,"header"),he(e.$slots,"content",{},()=>[f("div",R({class:"p-password-meter"},e.ptm("meter")),[f("div",R({class:s.strengthClass,style:{width:r.meter?r.meter.width:""}},e.ptm("meterLabel")),null,16)],16),f("div",R({class:"p-password-info"},e.ptm("info")),N(r.infoText),17)]),he(e.$slots,"footer")],16,a6)):M("",!0)]),_:3},8,["onEnter","onLeave","onAfterLeave"])]),_:3},8,["appendTo"])],16)}function l6(e,t){t===void 0&&(t={});var n=t.insertAt;if(!(typeof document>"u")){var i=document.head||document.getElementsByTagName("head")[0],r=document.createElement("style");r.type="text/css",n==="top"&&i.firstChild?i.insertBefore(r,i.firstChild):i.appendChild(r),r.styleSheet?r.styleSheet.cssText=e:r.appendChild(document.createTextNode(e))}}var c6=`
1695.p-password {
1696    position: relative;
1697    display: inline-flex;
1698}
1699.p-password-panel {
1700    position: absolute;
1701    top: 0;
1702    left: 0;
1703}
1704.p-password .p-password-panel {
1705    min-width: 100%;
1706}
1707.p-password-meter {
1708    height: 10px;
1709}
1710.p-password-strength {
1711    height: 100%;
1712    width: 0;
1713    transition: width 1s ease-in-out;
1714}
1715.p-fluid .p-password {
1716    display: flex;
1717}
1718.p-password-input::-ms-reveal,
1719.p-password-input::-ms-clear {
1720    display: none;
1721}
1722`;l6(c6);ym.render=o6;var bm={name:"Sidebar",extends:Ve,inheritAttrs:!1,emits:["update:visible","show","hide","after-hide"],props:{visible:{type:Boolean,default:!1},position:{type:String,default:"left"},baseZIndex:{type:Number,default:0},autoZIndex:{type:Boolean,default:!0},dismissable:{type:Boolean,default:!0},showCloseIcon:{type:Boolean,default:!0},closeIcon:{type:String,default:void 0},modal:{type:Boolean,default:!0},blockScroll:{type:Boolean,default:!1}},data(){return{containerVisible:this.visible}},container:null,mask:null,content:null,headerContainer:null,closeButton:null,outsideClickListener:null,updated(){this.visible&&(this.containerVisible=this.visible)},beforeUnmount(){this.disableDocumentSettings(),this.mask&&this.autoZIndex&&He.clear(this.mask),this.container=null,this.mask=null},methods:{hide(){this.$emit("update:visible",!1)},onEnter(){this.$emit("show"),this.focus(),this.autoZIndex&&He.set("modal",this.mask,this.baseZIndex||this.$primevue.config.zIndex.modal)},onAfterEnter(){this.enableDocumentSettings()},onBeforeLeave(){this.modal&&F.addClass(this.mask,"p-component-overlay-leave")},onLeave(){this.$emit("hide")},onAfterLeave(){this.autoZIndex&&He.clear(this.mask),this.containerVisible=!1,this.disableDocumentSettings(),this.$emit("after-hide")},onMaskClick(e){this.dismissable&&this.modal&&this.mask===e.target&&this.hide()},focus(){const e=n=>n.querySelector("[autofocus]");let t=this.$slots.default&&e(this.content);t||(t=this.$slots.header&&e(this.headerContainer),t||(t=e(this.container))),t&&t.focus()},enableDocumentSettings(){this.dismissable&&!this.modal&&this.bindOutsideClickListener(),this.blockScroll&&F.addClass(document.body,"p-overflow-hidden")},disableDocumentSettings(){this.unbindOutsideClickListener(),this.blockScroll&&F.removeClass(document.body,"p-overflow-hidden")},onKeydown(e){e.code==="Escape"&&this.hide()},containerRef(e){this.container=e},maskRef(e){this.mask=e},contentRef(e){this.content=e},headerContainerRef(e){this.headerContainer=e},closeButtonRef(e){this.closeButton=e},getPositionClass(){const t=["left","right","top","bottom"].find(n=>n===this.position);return t?`p-sidebar-${t}`:""},bindOutsideClickListener(){this.outsideClickListener||(this.outsideClickListener=e=>{this.isOutsideClicked(e)&&this.hide()},document.addEventListener("click",this.outsideClickListener))},unbindOutsideClickListener(){this.outsideClickListener&&(document.removeEventListener("click",this.outsideClickListener),this.outsideClickListener=null)},isOutsideClicked(e){return this.container&&!this.container.contains(e.target)}},computed:{containerClass(){return["p-sidebar p-component",{"p-input-filled":this.$primevue.config.inputStyle==="filled","p-ripple-disabled":this.$primevue.config.ripple===!1,"p-sidebar-full":this.fullScreen}]},fullScreen(){return this.position==="full"},closeAriaLabel(){return this.$primevue.config.locale.aria?this.$primevue.config.locale.aria.close:void 0},maskClass(){return["p-sidebar-mask",this.getPositionClass(),{"p-component-overlay p-component-overlay-enter":this.modal,"p-sidebar-mask-scrollblocker":this.blockScroll,"p-sidebar-visible":this.containerVisible,"p-sidebar-full":this.fullScreen}]}}
1722,directives:{focustrap:Fs,ripple:gt},components:{Portal:Kt,TimesIcon:Qt}};const d6=["aria-modal"],u6=["aria-label"];function h6(e,t,n,i,r,s){const a=le("Portal"),o=Xe("ripple"),l=Xe("focustrap");return g(),Q(a,null,{default:Ee(()=>[r.containerVisible?(g(),S("div",R({key:0,ref:s.maskRef,class:s.maskClass,onMousedown:t[2]||(t[2]=(...c)=>s.onMaskClick&&s.onMaskClick(...c))},e.ptm("mask")),[de($t,{name:"p-sidebar",onEnter:s.onEnter,onAfterEnter:s.onAfterEnter,onBeforeLeave:s.onBeforeLeave,onLeave:s.onLeave,onAfterLeave:s.onAfterLeave,appear:""},{default:Ee(()=>[n.visible?Ne((g(),S("div",R({key:0,ref:s.containerRef,class:s.containerClass,role:"complementary","aria-modal":n.modal,onKeydown:t[1]||(t[1]=(...c)=>s.onKeydown&&s.onKeydown(...c))},{...e.$attrs,...e.ptm("root")}),[f("div",R({ref:s.headerContainerRef,class:"p-sidebar-header"},e.ptm("header")),[e.$slots.header?(g(),S("div",R({key:0,class:"p-sidebar-header-content"},e.ptm("headerContent")),[he(e.$slots,"header")],16)):M("",!0),n.showCloseIcon?Ne((g(),S("button",R({key:1,ref:s.closeButtonRef,autofocus:"",type:"button",class:"p-sidebar-close p-sidebar-icon p-link","aria-label":s.closeAriaLabel,onClick:t[0]||(t[0]=(...c)=>s.hide&&s.hide(...c))},e.ptm("closeButton")),[he(e.$slots,"closeicon",{},()=>[(g(),Q(_e(n.closeIcon?"span":"TimesIcon"),R({class:["p-sidebar-close-icon ",n.closeIcon]},e.ptm("closeIcon")),null,16,["class"]))])],16,u6)),[[o]]):M("",!0)],16),f("div",R({ref:s.contentRef,class:"p-sidebar-content"},e.ptm("content")),[he(e.$slots,"default")],16)],16,d6)),[[l]]):M("",!0)]),_:3},8,["onEnter","onAfterEnter","onBeforeLeave","onLeave","onAfterLeave"])],16)):M("",!0)]),_:3})}function p6(e,t){t===void 0&&(t={});var n=t.insertAt;if(!(typeof document>"u")){var i=document.head||document.getElementsByTagName("head")[0],r=document.createElement("style");r.type="text/css",n==="top"&&i.firstChild?i.insertBefore(r,i.firstChild):i.appendChild(r),r.styleSheet?r.styleSheet.cssText=e:r.appendChild(document.createTextNode(e))}}var f6=`
1723.p-sidebar-mask {
1724    position: fixed;
1725    top: 0;
1726    left: 0;
1727    width: 100%;
1728    height: 100%;
1729    display: none;
1730    justify-content: center;
1731    align-items: center;
1732    pointer-events: none;
1733    background-color: transparent;
1734    transition-property: background-color;
1735}
1736.p-sidebar-mask.p-component-overlay {
1737    pointer-events: auto;
1738}
1739.p-sidebar-visible {
1740    display: flex;
1741}
1742.p-sidebar {
1743    display: flex;
1744    flex-direction: column;
1745    pointer-events: auto;
1746    transform: translate3d(0px, 0px, 0px);
1747    position: relative;
1748    transition: transform 0.3s;
1749}
1750.p-sidebar-content {
1751    overflow-y: auto;
1752    flex-grow: 1;
1753}
1754.p-sidebar-header {
1755    display: flex;
1756    align-items: center;
1757    justify-content: flex-end;
1758    flex-shrink: 0;
1759}
1760.p-sidebar-icon {
1761    display: flex;
1762    align-items: center;
1763    justify-content: center;
1764    overflow: hidden;
1765    position: relative;
1766}
1767.p-sidebar-full .p-sidebar {
1768    transition: none;
1769    transform: none;
1770    width: 100vw !important;
1771    height: 100vh !important;
1772    max-height: 100%;
1773    top: 0px !important;
1774    left: 0px !important;
1775}
1776
1777/* Animation */
1778/* Center */
1779.p-sidebar-left .p-sidebar-enter-from,
1780.p-sidebar-left .p-sidebar-leave-to {
1781    transform: translateX(-100%);
1782}
1783.p-sidebar-right .p-sidebar-enter-from,
1784.p-sidebar-right .p-sidebar-leave-to {
1785    transform: translateX(100%);
1786}
1787.p-sidebar-top .p-sidebar-enter-from,
1788.p-sidebar-top .p-sidebar-leave-to {
1789    transform: translateY(-100%);
1790}
1791.p-sidebar-bottom .p-sidebar-enter-from,
1792.p-sidebar-bottom .p-sidebar-leave-to {
1793    transform: translateY(100%);
1794}
1795.p-sidebar-full .p-sidebar-enter-from,
1796.p-sidebar-full .p-sidebar-leave-to {
1797    opacity: 0;
1798}
1799.p-sidebar-full .p-sidebar-enter-active,
1800.p-sidebar-full .p-sidebar-leave-active {
1801    transition: opacity 400ms cubic-bezier(0.25, 0.8, 0.25, 1);
1802}
1803
1804/* Position */
1805.p-sidebar-left {
1806    justify-content: flex-start;
1807}
1808.p-sidebar-right {
1809    justify-content: flex-end;
1810}
1811.p-sidebar-top {
1812    align-items: flex-start;
1813}
1814.p-sidebar-bottom {
1815    align-items: flex-end;
1816}
1817
1818/* Size */
1819.p-sidebar-left .p-sidebar {
1820    width: 20rem;
1821    height: 100%;
1822}
1823.p-sidebar-right .p-sidebar {
1824    width: 20rem;
1825    height: 100%;
1826}
1827.p-sidebar-top .p-sidebar {
1828    height: 10rem;
1829    width: 100%;
1830}
1831.p-sidebar-bottom .p-sidebar {
1832    height: 10rem;
1833    width: 100%;
1834}
1835.p-sidebar-left .p-sidebar-sm,
1836.p-sidebar-right .p-sidebar-sm {
1837    width: 20rem;
1838}
1839.p-sidebar-left .p-sidebar-md,
1840.p-sidebar-right .p-sidebar-md {
1841    width: 40rem;
1842}
1843.p-sidebar-left .p-sidebar-lg,
1844.p-sidebar-right .p-sidebar-lg {
1845    width: 60rem;
1846}
1847.p-sidebar-top .p-sidebar-sm,
1848.p-sidebar-bottom .p-sidebar-sm {
1849    height: 10rem;
1850}
1851.p-sidebar-top .p-sidebar-md,
1852.p-sidebar-bottom .p-sidebar-md {
1853    height: 20rem;
1854}
1855.p-sidebar-top .p-sidebar-lg,
1856.p-sidebar-bottom .p-sidebar-lg {
1857    height: 30rem;
1858}
1859.p-sidebar-left .p-sidebar-content,
1860.p-sidebar-right .p-sidebar-content,
1861.p-sidebar-top .p-sidebar-content,
1862.p-sidebar-bottom .p-sidebar-content {
1863    width: 100%;
1864    height: 100%;
1865}
1866@media screen and (max-width: 64em) {
1867.p-sidebar-left .p-sidebar-lg,
1868    .p-sidebar-left .p-sidebar-md,
1869    .p-sidebar-right .p-sidebar-lg,
1870    .p-sidebar-right .p-sidebar-md {
1871        width: 20rem;
1872}
1873}
1874`;p6(f6);bm.render=h6;var vm={name:"Carousel",extends:Ve,emits:["update:page"],props:{value:null,page:{type:Number,default:0},numVisible:{type:Number,default:1},numScroll:{type:Number,default:1},responsiveOptions:Array,orientation:{type:String,default:"horizontal"},verticalViewPortHeight:{type:String,default:"300px"},contentClass:String,containerClass:String,indicatorsContentClass:String,circular:{type:Boolean,default:!1},autoplayInterval:{type:Number,default:0},showNavigators:{type:Boolean,default:!0},showIndicators:{type:Boolean,default:!0},prevButtonProps:{type:null,default:null},nextButtonProps:{type:null,default:null}},isRemainingItemsAdded:!1,data(){return{remainingItems:0,d_numVisible:this.numVisible,d_numScroll:this.numScroll,d_oldNumScroll:0,d_oldNumVisible:0,d_oldValue:null,d_page:this.page,totalShiftedItems:this.page*this.numScroll*-1,allowAutoplay:!!this.autoplayInterval,d_circular:this.circular||this.allowAutoplay,swipeThreshold:20}},watch:{page(e){this.d_page=e},circular(e){this.d_circular=e},numVisible(e,t){this.d_numVisible=e,this.d_oldNumVisible=t},numScroll(e,t){this.d_oldNumScroll=t,this.d_numScroll=e},value(e){this.d_oldValue=e}},mounted(){let e=!1;if(this.$el.setAttribute(this.attributeSelector,""),this.createStyle(),this.calculatePosition(),this.responsiveOptions&&this.bindDocumentListeners(),this.isCircular()){let t=this.totalShiftedItems;this.d_page===0?t=-1*this.d_numVisible:t===0&&(t=-1*this.value.length,this.remainingItems>0&&(this.isRemainingItemsAdded=!0)),t!==this.totalShiftedItems&&(this.totalShiftedItems=t,e=!0)}!e&&this.isAutoplay()&&this.startAutoplay()},updated(){const e=this.isCircular();let t=!1,n=this.totalShiftedItems;if(this.autoplayInterval&&this.stopAutoplay(),this.d_oldNumScroll!==this.d_numScroll||this.d_oldNumVisible!==this.d_numVisible||this.d_oldValue.length!==this.value.length){this.remainingItems=(this.value.length-this.d_numVisible)%this.d_numScroll;let i=this.d_page;this.totalIndicators!==0&&i>=this.totalIndicators&&(i=this.totalIndicators-1,this.$emit("update:page",i),this.d_page=i,t=!0),n=i*this.d_numScroll*-1,e&&(n-=this.d_numVisible),i===this.totalIndicators-1&&this.remainingItems>0?(n+=-1*this.remainingItems+this.d_numScroll,this.isRemainingItemsAdded=!0):this.isRemainingItemsAdded=!1,n!==this.totalShiftedItems&&(this.totalShiftedItems=n,t=!0),this.d_oldNumScroll=this.d_numScroll,this.d_oldNumVisible=this.d_numVisible,this.d_oldValue=this.value,this.$refs.itemsContainer.style.transform=this.isVertical()?`translate3d(0, ${n*(100/this.d_numVisible)}%, 0)`:`translate3d(${n*(100/this.d_numVisible)}%, 0, 0)`}e&&(this.d_page===0?n=-1*this.d_numVisible:n===0&&(n=-1*this.value.length,this.remainingItems>0&&(this.isRemainingItemsAdded=!0)),n!==this.totalShiftedItems&&(this.totalShiftedItems=n,t=!0)),!t&&this.isAutoplay()&&this.startAutoplay()},beforeUnmount(){this.responsiveOptions&&this.unbindDocumentListeners(),this.autoplayInterval&&this.stopAutoplay()},methods:{step(e,t){let n=this.totalShiftedItems;const i=this.isCircular();if(t!=null)n=this.d_numScroll*t*-1,i&&(n-=this.d_numVisible),this.isRemainingItemsAdded=!1;else{n+=this.d_numScroll*e,this.isRemainingItemsAdded&&(n+=this.remainingItems-this.d_numScroll*e,this.isRemainingItemsAdded=!1);let r=i?n+this.d_numVisible:n;t=Math.abs(Math.floor(r/this.d_numScroll))}i&&this.d_page===this.totalIndicators-1&&e===-1?(n=-1*(this.value.length+this.d_numVisible),t=0):i&&this.d_page===0&&e===1?(n=0,t=this.totalIndicators-1):t===this.totalIndicators-1&&this.remainingItems>0&&(n+=this.remainingItems*-1-this.d_numScroll*e,this.isRemainingItemsAdded=!0),this.$refs.itemsContainer&&(F.removeClass(this.$refs.itemsContainer,"p-items-hidden"),this.$refs.itemsContainer.style.transform=this.isVertical()?`translate3d(0, ${n*(100/this.d_numVisible)}%, 0)`:`translate3d(${n*(100/this.d_numVisible)}%, 0, 0)`,this.$refs.itemsContainer.style.transition="transform 500ms ease 0s"),this.totalShiftedItems=n,this.$emit("update:page",t),this.d_page=t},calculatePosition(){if(this.$refs.itemsContainer&&this.responsiveOptions){let e=window.innerWidth,t={numVisible:this.numVisible,numScroll:this.numScroll};for(let n=0;n<this.responsiveOptions.length;n++){let i=this.responsiveOptions[n];parseInt(i.breakpoint,10)>=e&&(t=i)}if(this.d_numScroll!==t.numScroll){let n=this.d_page;n=parseInt(n*this.d_numScroll/t.numScroll),this.totalShiftedItems=t.numScroll*n*-1,this.isCircular()&&(this.totalShiftedItems-=t.numVisible),this.d_numScroll=t.numScroll,this.$emit("update:page",n),this.d_page=n}this.d_numVisible!==t.numVisible&&(this.d_numVisible=t.numVisible)}},navBackward(e,t){(this.d_circular||this.d_page!==0)&&this.step(1,t),this.allowAutoplay=!1,e.cancelable&&e.preventDefault()},navForward(e,t){(this.d_circular||this.d_page<this.totalIndicators-1)&&this.step(-1,t),this.allowAutoplay=!1,e.cancelable&&e.preventDefault()},onIndicatorClick(e,t){let n=this.d_page;t>n?this.navForward(e,t):t<n&&this.navBackward(e,t)},onTransitionEnd(){this.$refs.itemsContainer&&(F.addClass(this.$refs.itemsContainer,"p-items-hidden"),this.$refs.itemsContainer.style.transition="",(this.d_page===0||this.d_page===this.totalIndicators-1)&&this.isCircular()&&(this.$refs.itemsContainer.style.transform=this.isVertical()?`translate3d(0, ${this.totalShiftedItems*(100/this.d_numVisible)}%, 0)`:`translate3d(${this.totalShiftedItems*(100/this.d_numVisible)}%, 0, 0)`))},onTouchStart(e){let t=e.changedTouches[0];this.startPos={x:t.pageX,y:t.pageY}},onTouchMove(e){e.cancelable&&e.preventDefault()},onTouchEnd(e){let t=e.changedTouches[0];this.isVertical()?this.changePageOnTouch(e,t.pageY-this.startPos.y):this.changePageOnTouch(e,t.pageX-this.startPos.x)},changePageOnTouch(e,t){Math.abs(t)>this.swipeThreshold&&(t<0?this.navForward(e):this.navBackward(e))},onIndicatorKeydown(e){switch(e.code){case"ArrowRight":this.onRightKey();break;case"ArrowLeft":this.onLeftKey();break;case"Home":this.onHomeKey(),e.preventDefault();break;case"End":this.onEndKey(),e.preventDefault();break;case"ArrowUp":case"ArrowDown":e.preventDefault();break;case"Tab":this.onTabKey();break}},onRightKey(){const e=[...F.find(this.$refs.indicatorContent,".p-carousel-indicator")],t=this.findFocusedIndicatorIndex();this.changedFocusedIndicator(t,t+1===e.length?e.length-1:t+1)},onLeftKey(){const e=this.findFocusedIndicatorIndex();this.changedFocusedIndicator(e,e-1<=0?0:e-1)},onHomeKey(){const e=this.findFocusedIndicatorIndex();this.changedFocusedIndicator(e,0)},onEndKey(){const e=[...F.find(this.$refs.indicatorContent,".p-carousel-indicator")],t=this.findFocusedIndicatorIndex();this.changedFocusedIndicator(t,e.length-1)},onTabKey(){const e=[...F.find(this.$refs.indicatorContent,".p-carousel-indicator")],t=e.findIndex(r=>F.hasClass(r,"p-highlight")),n=F.findSingle(this.$refs.indicatorContent,'.p-carousel-indicator > button[tabindex="0"]'),i=e.findIndex(r=>r===n.parentElement);e[i].children[0].tabIndex="-1",e[t].children[0].tabIndex="0"},findFocusedIndicatorIndex(){const e=[...F.find(this.$refs.indicatorContent,".p-carousel-indicator")],t=F.findSingle(this.$refs.indicatorContent,'.p-carousel-indicator > button[tabindex="0"]');return e.findIndex(n=>n===t.parentElement)},changedFocusedIndicator(e,t){const n=[...F.find(this.$refs.indicatorContent,".p-carousel-indicator")];n[e].children[0].tabIndex="-1",n[t].children[0].tabIndex="0",n[t].children[0].focus()},bindDocumentListeners(){this.documentResizeListener||(this.documentResizeListener=e=>{this.calculatePosition(e)},window.addEventListener("resize",this.documentResizeListener))},unbindDocumentListeners(){this.documentResizeListener&&(window.removeEventListener("resize",this.documentResizeListener),this.documentResizeListener=null)},startAutoplay(){this.interval=setInterval(()=>{this.d_page===this.totalIndicators-1?this.step(-1,0):this.step(-1,this.d_page+1)},this.autoplayInterval)},stopAutoplay(){this.interval&&clearInterval(this.interval)},createStyle(){this.carouselStyle||(this.carouselStyle=document.createElement("style"),this.carouselStyle.type="text/css",document.body.appendChild(this.carouselStyle));let e=`
1875                .p-carousel[${this.attributeSelector}] .p-carousel-item {
1876                    flex: 1 0 ${100/this.d_numVisible}%
1877                }
1878            `;if(this.responsiveOptions){let t=[...this.responsiveOptions];t.sort((n,i)=>{const r=n.breakpoint,s=i.breakpoint;let a=null;return r==null&&s!=null?a=-1:r!=null&&s==null?a=1:r==null&&s==null?a=0:typeof r=="string"&&typeof s=="string"?a=r.localeCompare(s,void 0,{numeric:!0}):a=r<s?-1:r>s?1:0,-1*a});for(let n=0;n<t.length;n++){let i=t[n];e+=`
1879                        @media screen and (max-width: ${i.breakpoint}) {
1880                            .p-carousel[${this.attributeSelector}] .p-carousel-item {
1881                                flex: 1 0 ${100/i.numVisible}%
1882                            }
1883                        }
1884                    `}}this.carouselStyle.innerHTML=e},isVertical(){return this.orientation==="vertical"},isCircular(){return this.value&&this.d_circular&&this.value.length>=this.d_numVisible},isAutoplay(){return this.autoplayInterval&&this.allowAutoplay},firstIndex(){return this.isCircular()?-1*(this.totalShiftedItems+this.d_numVisible):this.totalShiftedItems*-1},lastIndex(){return this.firstIndex()+this.d_numVisible-1},ariaSlideNumber(e){return this.$primevue.config.locale.aria?this.$primevue.config.locale.aria.slideNumber.replace(/{slideNumber}/g,e):void 0},ariaPageLabel(e){return this.$primevue.config.locale.aria?this.$primevue.config.locale.aria.pageLabel.replace(/{page}/g,e):void 0}},computed:{totalIndicators(){return this.value?Math.max(Math.ceil((this.value.length-this.d_numVisible)/this.d_numScroll)+1,0):0},backwardIsDisabled(){return this.value&&(!this.circular||this.value.length<this.d_numVisible)&&this.d_page===0},forwardIsDisabled(){return this.value&&(!this.circular||this.value.length<this.d_numVisible)&&(this.d_page===this.totalIndicators-1||this.totalIndicators===0)},containerClasses(){return["p-carousel-container",this.containerClass]},contentClasses(){return["p-carousel-content ",this.contentClass]},indicatorsContentClasses(){return["p-carousel-indicators p-reset",this.indicatorsContentClass]},ariaSlideLabel(){return this.$primevue.config.locale.aria?this.$primevue.config.locale.aria.slide:void 0},ariaPrevButtonLabel(){return this.$primevue.config.locale.aria?this.$primevue.config.locale.aria.prevPageLabel:void 0},ariaNextButtonLabel(){return this.$primevue.config.locale.aria?this.$primevue.config.locale.aria.nextPageLabel:void 0},attributeSelector(){return pt()}},components:{ChevronRightIcon:Rn,ChevronDownIcon:_n,ChevronLeftIcon:Vs,ChevronUpIcon:sa},directives:{ripple:gt}};const m6=["aria-live"],g6=["disabled","aria-label"],y6=["aria-hidden","aria-label","aria-roledescription"],b6=["disabled","aria-label"],v6=["tabindex","aria-label","aria-current","onClick"];function _6(e,t,n,i,r,s){const a=Xe("ripple");return g(),S("div",R({class:["p-carousel p-component",{"p-carousel-vertical":s.isVertical(),"p-carousel-horizontal":!s.isVertical()}],role:"region"},e.ptm("root")),[e.$slots.header?(g(),S("div",R({key:0,class:"p-carousel-header"},e.ptm("header")),[he(e.$slots,"header")],16)):M("",!0),f("div",R({class:s.contentClasses},e.ptm("content")),[f("div",R({class:s.containerClasses,"aria-live":r.allowAutoplay?"polite":"off"},e.ptm("container")),[n.showNavigators?Ne((g(),S("button",R({key:0,type:"button",class:["p-carousel-prev p-link",{"p-disabled":s.backwardIsDisabled}],disabled:s.backwardIsDisabled,"aria-label":s.ariaPrevButtonLabel,onClick:t[0]||(t[0]=(...o)=>s.navBackward&&s.navBackward(...o))},{...n.prevButtonProps,...e.ptm("previousButton")}),[he(e.$slots,"previousicon",{},()=>[(g(),Q(_e(s.isVertical()?"ChevronUpIcon":"ChevronLeftIcon"),R({class:"p-carousel-next-icon"},e.ptm("previousButtonIcon")),null,16))])],16,g6)),[[a]]):M("",!0),f("div",R({class:"p-carousel-items-content",style:[{height:s.isVertical()?n.verticalViewPortHeight:"auto"}],onTouchend:t[2]||(t[2]=(...o)=>s.onTouchEnd&&s.onTouchEnd(...o)),onTouchstart:t[3]||(t[3]=(...o)=>s.onTouchStart&&s.onTouchStart(...o)),onTouchmove:t[4]||(t[4]=(...o)=>s.onTouchMove&&s.onTouchMove(...o))},e.ptm("itemsContent")),[f("div",R({ref:"itemsContainer",class:"p-carousel-items-container",onTransitionend:t[1]||(t[1]=(...o)=>s.onTransitionEnd&&s.onTransitionEnd(...o))},e.ptm("itemsContainer")),[s.isCircular()?(g(!0),S(J,{key:0},ye(n.value.slice(-1*r.d_numVisible),(o,l)=>(g(),S("div",R({key:l+"_scloned",class:["p-carousel-item p-carousel-item-cloned",{"p-carousel-item-active":r.totalShiftedItems*-1===n.value.length+r.d_numVisible,"p-carousel-item-start":l===0,"p-carousel-item-end":n.value.slice(-1*r.d_numVisible).length-1===l}]},e.ptm("itemCloned")),[he(e.$slots,"item",{data:o,index:l})],16))),128)):M("",!0),(g(!0),S(J,null,ye(n.value,(o,l)=>(g(),S("div",R({key:l,class:["p-carousel-item",{"p-carousel-item-active":s.firstIndex()<=l&&s.lastIndex()>=l,"p-carousel-item-start":s.firstIndex()===l,"p-carousel-item-end":s.lastIndex()===l}],role:"group","aria-hidden":s.firstIndex()>l||s.lastIndex()<l?!0:void 0,"aria-label":s.ariaSlideNumber(l),"aria-roledescription":s.ariaSlideLabel},e.ptm("item")),[he(e.$slots,"item",{data:o,index:l})],16,y6))),128)),s.isCircular()?(g(!0),S(J,{key:1},ye(n.value.slice(0,r.d_numVisible),(o,l)=>(g(),S("div",R({key:l+"_fcloned",class:["p-carousel-item p-carousel-item-cloned",{"p-carousel-item-active":r.totalShiftedItems===0,"p-carousel-item-start":l===0,"p-carousel-item-end":n.value.slice(0,r.d_numVisible).length-1===l}]},e.ptm("itemCloned")),[he(e.$slots,"item",{data:o,index:l})],16))),128)):M("",!0)],16)],16),n.showNavigators?Ne((g(),S("button",R({key:1,type:"button",class:["p-carousel-next p-link",{"p-disabled":s.forwardIsDisabled}],disabled:s.forwardIsDisabled,"aria-label":s.ariaNextButtonLabel,onClick:t[5]||(t[5]=(...o)=>s.navForward&&s.navForward(...o))},{...n.nextButtonProps,...e.ptm("nextButton")}),[he(e.$slots,"nexticon",{},()=>[(g(),Q(_e(s.isVertical()?"ChevronDownIcon":"ChevronRightIcon"),R({class:"p-carousel-prev-icon"},e.ptm("nextButtonIcon")),null,16))])],16,b6)),[[a]]):M("",!0)],16,m6),s.totalIndicators>=0&&n.showIndicators?(g(),S("ul",R({key:0,ref:"indicatorContent",class:s.indicatorsContentClasses,onKeydown:t[6]||(t[6]=(...o)=>s.onIndicatorKeydown&&s.onIndicatorKeydown(...o))}
1884,e.ptm("indicators")),[(g(!0),S(J,null,ye(s.totalIndicators,(o,l)=>(g(),S("li",R({key:"p-carousel-indicator-"+l.toString(),class:["p-carousel-indicator",{"p-highlight":r.d_page===l}]},e.ptm("indicator")),[f("button",R({class:"p-link",type:"button",tabindex:r.d_page===l?"0":"-1","aria-label":s.ariaPageLabel(l+1),"aria-current":r.d_page===l?"page":void 0,onClick:c=>s.onIndicatorClick(c,l)},e.ptm("indicatorButton")),null,16,v6)],16))),128))],16)):M("",!0)],16),e.$slots.footer?(g(),S("div",R({key:1,class:"p-carousel-footer"},e.ptm("footer")),[he(e.$slots,"footer")],16)):M("",!0)],16)}function w6(e,t){t===void 0&&(t={});var n=t.insertAt;if(!(typeof document>"u")){var i=document.head||document.getElementsByTagName("head")[0],r=document.createElement("style");r.type="text/css",n==="top"&&i.firstChild?i.insertBefore(r,i.firstChild):i.appendChild(r),r.styleSheet?r.styleSheet.cssText=e:r.appendChild(document.createTextNode(e))}}var E6=`
1885.p-carousel {
1886    display: flex;
1887    flex-direction: column;
1888}
1889.p-carousel-content {
1890    display: flex;
1891    flex-direction: column;
1892    overflow: auto;
1893}
1894.p-carousel-prev,
1895.p-carousel-next {
1896    align-self: center;
1897    flex-grow: 0;
1898    flex-shrink: 0;
1899    display: flex;
1900    justify-content: center;
1901    align-items: center;
1902    overflow: hidden;
1903    position: relative;
1904}
1905.p-carousel-container {
1906    display: flex;
1907    flex-direction: row;
1908}
1909.p-carousel-items-content {
1910    overflow: hidden;
1911    width: 100%;
1912}
1913.p-carousel-items-container {
1914    display: flex;
1915    flex-direction: row;
1916}
1917.p-carousel-indicators {
1918    display: flex;
1919    flex-direction: row;
1920    justify-content: center;
1921    flex-wrap: wrap;
1922}
1923.p-carousel-indicator > button {
1924    display: flex;
1925    align-items: center;
1926    justify-content: center;
1927}
1928
1929/* Vertical */
1930.p-carousel-vertical .p-carousel-container {
1931    flex-direction: column;
1932}
1933.p-carousel-vertical .p-carousel-items-container {
1934    flex-direction: column;
1935    height: 100%;
1936}
1937
1938/* Keyboard Support */
1939.p-items-hidden .p-carousel-item {
1940    visibility: hidden;
1941}
1942.p-items-hidden .p-carousel-item.p-carousel-item-active {
1943    visibility: visible;
1944}
1945`;w6(E6);vm.render=_6;let _m;function xa(e){e.$_ptooltipModifiers.focus?(e.addEventListener("focus",Sm),e.addEventListener("blur",Cm)):(e.addEventListener("mouseenter",wm),e.addEventListener("mouseleave",Em),e.addEventListener("click",Im)),e.addEventListener("keydown",Tm)}function Ma(e){e.$_ptooltipModifiers.focus?(e.removeEventListener("focus",Sm),e.removeEventListener("blur",Cm)):(e.removeEventListener("mouseenter",wm),e.removeEventListener("mouseleave",Em),e.removeEventListener("click",Im)),e.removeEventListener("keydown",Tm)}function S6(e){e.$_ptooltipScrollHandler||(e.$_ptooltipScrollHandler=new kn(e,function(){Bs(e)})),e.$_ptooltipScrollHandler.bindScrollListener()}function C6(e){e.$_ptooltipScrollHandler&&e.$_ptooltipScrollHandler.unbindScrollListener()}function wm(e){const t=e.currentTarget,n=t.$_ptooltipShowDelay;Pm(t,n)}function Em(e){const t=e.currentTarget,n=t.$_ptooltipHideDelay;Bs(t,n)}function Sm(e){const t=e.currentTarget,n=t.$_ptooltipShowDelay;Pm(t,n)}function Cm(e){const t=e.currentTarget,n=t.$_ptooltipHideDelay;Bs(t,n)}function Im(e){const t=e.currentTarget,n=t.$_ptooltipHideDelay;Bs(t,n)}function Tm(e){e.code==="Escape"&&Bs(e.currentTarget,hideDelay)}function qd(e){if(e.$_ptooltipDisabled)return;let t=I6(e);T6(e),F.fadeIn(t,250),window.addEventListener("resize",function n(){F.isTouchDevice()||Bs(e),this.removeEventListener("resize",n)}),S6(e),He.set("tooltip",t,e.$_ptooltipZIndex)}function Pm(e,t){t!==void 0?_m=setTimeout(()=>qd(e),t):qd(e)}function Jd(e){Om(e),C6(e)}function Bs(e,t){clearTimeout(_m),t!==void 0?setTimeout(()=>Jd(e),t):Jd(e)}function fs(e){return document.getElementById(e.$_ptooltipId)}function I6(e){const t=e.$_ptooltipIdAttr!==""?e.$_ptooltipIdAttr:pt()+"_tooltip";e.$_ptooltipId=t;let n=document.createElement("div");n.id=t;let i=document.createElement("div");i.className="p-tooltip-arrow",n.appendChild(i);let r=document.createElement("div");return r.className="p-tooltip-text",e.$_ptooltipEscape?r.innerHTML=e.$_ptooltipValue:(r.innerHTML="",r.appendChild(document.createTextNode(e.$_ptooltipValue))),n.setAttribute("role","tooltip"),n.appendChild(r),document.body.appendChild(n),n.style.display="inline-block",e.$_ptooltipFitContent&&(n.style.width="fit-content"),n}
1945function Om(e){if(e){let t=fs(e);t&&t.parentElement&&(He.clear(t),document.body.removeChild(t)),e.$_ptooltipId=null}}function T6(e){const t=e.$_ptooltipModifiers;t.top?(js(e),Zt(e)&&(Ys(e),Zt(e)&&js(e))):t.left?(Va(e),Zt(e)&&(Fa(e),Zt(e)&&(js(e),Zt(e)&&(Ys(e),Zt(e)&&Va(e))))):t.bottom?(Ys(e),Zt(e)&&(js(e),Zt(e)&&Ys(e))):(Fa(e),Zt(e)&&(Va(e),Zt(e)&&(js(e),Zt(e)&&(Ys(e),Zt(e)&&Fa(e)))))}function ia(e){let t=e.getBoundingClientRect(),n=t.left+F.getWindowScrollLeft(),i=t.top+F.getWindowScrollTop();return{left:n,top:i}}function Fa(e){ra(e,"right");let t=fs(e),n=ia(e),i=n.left+F.getOuterWidth(e),r=n.top+(F.getOuterHeight(e)-F.getOuterHeight(t))/2;t.style.left=i+"px",t.style.top=r+"px"}function Va(e){ra(e,"left");let t=fs(e),n=ia(e),i=n.left-F.getOuterWidth(t),r=n.top+(F.getOuterHeight(e)-F.getOuterHeight(t))/2;t.style.left=i+"px",t.style.top=r+"px"}function js(e){ra(e,"top");let t=fs(e),n=ia(e),i=n.left+(F.getOuterWidth(e)-F.getOuterWidth(t))/2,r=n.top-F.getOuterHeight(t);t.style.left=i+"px",t.style.top=r+"px"}function Ys(e){ra(e,"bottom");let t=fs(e),n=ia(e),i=n.left+(F.getOuterWidth(e)-F.getOuterWidth(t))/2,r=n.top+F.getOuterHeight(e);t.style.left=i+"px",t.style.top=r+"px"}function ra(e,t){let n=fs(e);n.style.left="-999px",n.style.top="-999px",n.className=`p-tooltip p-component p-tooltip-${t} ${e.$_ptooltipClass||""}`}function Zt(e){let t=fs(e),n=t.getBoundingClientRect(),i=n.top,r=n.left,s=F.getOuterWidth(t),a=F.getOuterHeight(t),o=F.getViewport();return r+s>o.width||r<0||i<0||i+a>o.height}function Ba(e){return F.hasClass(e,"p-inputwrapper")?F.findSingle(e,"input"):e}function Xd(e){return e.modifiers&&Object.keys(e.modifiers).length?e.modifiers:e.arg&&typeof e.arg=="object"?Object.entries(e.arg).reduce((t,[n,i])=>((n==="event"||n==="position")&&(t[i]=!0),t),{}):{}}const P6={beforeMount(e,t){let n=Ba(e);if(n.$_ptooltipModifiers=Xd(t),t.value){if(typeof t.value=="string")n.$_ptooltipValue=t.value,n.$_ptooltipDisabled=!1,n.$_ptooltipEscape=!1,n.$_ptooltipClass=null,n.$_ptooltipFitContent=!0,n.$_ptooltipShowDelay=0,n.$_ptooltipHideDelay=0;else if(typeof t.value=="object"&&t.value){if(ve.isEmpty(t.value.value)||t.value.value.trim()==="")return;n.$_ptooltipValue=t.value.value,n.$_ptooltipDisabled=!!t.value.disabled===t.value.disabled?t.value.disabled:!1,n.$_ptooltipEscape=!!t.value.escape===t.value.escape?t.value.escape:!1,n.$_ptooltipClass=t.value.class,n.$_ptooltipFitContent=!!t.value.fitContent===t.value.fitContent?t.value.fitContent:!0,n.$_ptooltipIdAttr=t.value.id||"",n.$_ptooltipShowDelay=t.value.showDelay||0,n.$_ptooltipHideDelay=t.value.hideDelay||0}}else return;n.$_ptooltipZIndex=t.instance.$primevue&&t.instance.$primevue.config&&t.instance.$primevue.config.zIndex.tooltip,xa(n)},unmounted(e){let t=Ba(e);Om(t),Ma(t),t.$_ptooltipScrollHandler&&(t.$_ptooltipScrollHandler.destroy(),t.$_ptooltipScrollHandler=null)},updated(e,t){let n=Ba(e);if(n.$_ptooltipModifiers=Xd(t),!t.value){Ma(n);return}if(typeof t.value=="string")n.$_ptooltipValue=t.value,n.$_ptooltipDisabled=!1,n.$_ptooltipEscape=!1,n.$_ptooltipClass=null,n.$_ptooltipIdAttr="",n.$_ptooltipShowDelay=0,n.$_ptooltipHideDelay=0,xa(n);else if(typeof t.value=="object"&&t.value)if(ve.isEmpty(t.value.value)||t.value.value.trim()===""){Ma(n);return}else n.$_ptooltipValue=t.value.value,n.$_ptooltipDisabled=!!t.value.disabled===t.value.disabled?t.value.disabled:!1,n.$_ptooltipEscape=!!t.value.escape===t.value.escape?t.value.escape:!1,n.$_ptooltipClass=t.value.class,n.$_ptooltipFitContent=!!t.value.fitContent===t.value.fitContent?t.value.fitContent:!0,n.$_ptooltipIdAttr=t.value.id||"",n.$_ptooltipShowDelay=t.value.showDelay||0,n.$_ptooltipHideDelay=t.value.hideDelay||0,xa(n)}};var Sn=mf(),Am={name:"ToastMessage",extends:Ve,emits:["close"],props:{message:{type:null,default:null},templates:{type:Object,default:null},closeIcon:{type:String,default:null},infoIcon:{type:String,default:null},warnIcon:{type:String,default:null},errorIcon:{type:String,default:null},successIcon:{type:String,default:null},closeButtonProps:{type:null,default:null}},closeTimeout:null,mounted(){this.message.life&&(this.closeTimeout=setTimeout(()=>{this.close({message:this.message,type:"life-end"})},this.message.life))},beforeUnmount(){this.clearCloseTimeout()},methods:{close(e){this.$emit("close",e)},onCloseClick(){this.clearCloseTimeout(),this.close({message:this.message,type:"close"})},clearCloseTimeout(){this.closeTimeout&&(clearTimeout(this.closeTimeout),this.closeTimeout=null)}},computed:{containerClass(){return["p-toast-message",this.message.styleClass,{"p-toast-message-info":this.message.severity==="info","p-toast-message-warn":this.message.severity==="warn","p-toast-message-error":this.message.severity==="error","p-toast-message-success":this.message.severity==="success"}]},iconComponent(){return{info:!this.infoIcon&&vi,success:!this.successIcon&&yn,warn:!this.warnIcon&&bi,error:!this.errorIcon&&ds}[this.message.severity]},iconClass(){return[{[this.infoIcon]:this.message.severity==="info",[this.warnIcon]:this.message.severity==="warn",[this.errorIcon]:this.message.severity==="error",[this.successIcon]:this.message.severity==="success"}]},closeAriaLabel(){return this.$primevue.config.locale.aria?this.$primevue.config.locale.aria.close:void 0}},components:{TimesIcon:Qt,InfoCircleIcon:vi,CheckIcon:yn,ExclamationTriangleIcon:bi,TimesCircleIcon:ds},directives:{ripple:gt}};const O6=["aria-label"];function A6(e,t,n,i,r,s){const a=Xe("ripple");return g(),S("div",R({class:s.containerClass,role:"alert","aria-live":"assertive","aria-atomic":"true"},e.ptm("container")),[f("div",R({class:["p-toast-message-content",n.message.contentStyleClass]},e.ptm("content")),[n.templates.message?(g(),Q(_e(n.templates.message),{key:1,message:n.message},null,8,["message"])):(g(),S(J,{key:0},[(g(),Q(_e(n.templates.icon?n.templates.icon:s.iconComponent.name?s.iconComponent:"span"),R({class:[s.iconClass,"p-toast-message-icon"]},e.ptm("icon")),null,16,["class"])),f("div",R({class:"p-toast-message-text"},e.ptm("text")),[f("span",R({class:"p-toast-summary"},e.ptm("summary")),N(n.message.summary),17),f("div",R({class:"p-toast-detail"},e.ptm("detail")),N(n.message.detail),17)],16)],64)),n.message.closable!==!1?(g(),S("div",ft(R({key:2},e.ptm("buttonContainer"))),[Ne((g(),S("button",R({class:"p-toast-icon-close p-link",type:"button","aria-label":s.closeAriaLabel,onClick:t[0]||(t[0]=(...o)=>s.onCloseClick&&s.onCloseClick(...o)),autofocus:""},{...n.closeButtonProps,...e.ptm("button")}),[(g(),Q(_e(n.templates.closeicon||"TimesIcon"),R({class:["p-toast-icon-close-icon",n.closeIcon]},e.ptm("buttonIcon")),null,16,["class"]))],16,O6)),[[a]])],16)):M("",!0)],16)],16)}Am.render=A6;var k6=0,km={name:"Toast",extends:Ve,inheritAttrs:!1,emits:["close","life-end"],props:{group:{type:String,default:null},position:{type:String,default:"top-right"},autoZIndex:{type:Boolean,default:!0},baseZIndex:{type:Number,default:0},breakpoints:{type:Object,default:null},closeIcon:{type:String,default:void 0},infoIcon:{type:String,default:void 0},warnIcon:{type:String,default:void 0},errorIcon:{type:String,default:void 0},successIcon:{type:String,default:void 0},closeButtonProps:{type:null,default:null}},data(){return{messages:[]}},styleElement:null,mounted(){Sn.on("add",this.onAdd),Sn.on("remove-group",this.onRemoveGroup),Sn.on("remove-all-groups",this.onRemoveAllGroups),this.breakpoints&&this.createStyle()},beforeUnmount(){this.destroyStyle(),this.$refs.container&&this.autoZIndex&&He.clear(this.$refs.container),Sn.off("add",this.onAdd),Sn.off("remove-group",this.onRemoveGroup),Sn.off("remove-all-groups",this.onRemoveAllGroups)},methods:{add(e){e.id==null&&(e.id=k6++),this.messages=[...this.messages,e]},remove(e){let t=-1;for(let n=0;n<this.messages.length;n++)if(this.messages[n]===e.message){t=n;break}this.messages.splice(t,1),this.$emit(e.type,{message:e.message})},onAdd(e){this.group==e.group&&this.add(e)},onRemoveGroup(e){this.group===e&&(this.messages=[])},onRemoveAllGroups(){this.messages=[]},onEnter(){this.$refs.container.setAttribute(this.attributeSelector,""),this.autoZIndex&&He.set("modal",this.$refs.container,this.baseZIndex||this.$primevue.config.zIndex.modal)},onLeave(){this.$refs.container&&this.autoZIndex&&ve.isEmpty(this.messages)&&setTimeout(()=>{He.clear(this.$refs.container)},200)},createStyle(){if(!this.styleElement){this.styleElement=document.createElement("style"),this.styleElement.type="text/css",document.head.appendChild(this.styleElement);let e="";for(let t in this.breakpoints){let n="";for(let i in this.breakpoints[t])n+=i+":"+this.breakpoints[t][i]+"!important;";e+=`
1946                        @media screen and (max-width: ${t}) {
1947                            .p-toast[${this.attributeSelector}] {
1948                                ${n}
1949                            }
1950                        }
1951                    `}this.styleElement.innerHTML=e}},destroyStyle(){this.styleElement&&(document.head.removeChild(this.styleElement),this.styleElement=null)}},computed:{containerClass(){return["p-toast p-component p-toast-"+this.position,{"p-input-filled":this.$primevue.config.inputStyle==="filled","p-ripple-disabled":this.$primevue.config.ripple===!1}]},attributeSelector(){return pt()}},components:{ToastMessage:Am,Portal:Kt}};function R6(e,t,n,i,r,s){const a=le("ToastMessage"),o=le("Portal");return g(),Q(o,null,{default:Ee(()=>[f("div",R({ref:"container",class:s.containerClass},{...e.$attrs,...e.ptm("root")}),[de(Yg,R({name:"p-toast-message",tag:"div",onEnter:s.onEnter,onLeave:s.onLeave},e.ptm("message")),{default:Ee(()=>[(g(!0),S(J,null,ye(r.messages,l=>(g(),Q(a,{key:l.id,message:l,templates:e.$slots,closeIcon:n.closeIcon,infoIcon:n.infoIcon,warnIcon:n.warnIcon,errorIcon:n.errorIcon,successIcon:n.successIcon,closeButtonProps:n.closeButtonProps,onClose:t[0]||(t[0]=c=>s.remove(c)),pt:e.pt}
1951,null,8,["message","templates","closeIcon","infoIcon","warnIcon","errorIcon","successIcon","closeButtonProps","pt"]))),128))]),_:1},16,["onEnter","onLeave"])],16)]),_:1})}function L6(e,t){t===void 0&&(t={});var n=t.insertAt;if(!(typeof document>"u")){var i=document.head||document.getElementsByTagName("head")[0],r=document.createElement("style");r.type="text/css",n==="top"&&i.firstChild?i.insertBefore(r,i.firstChild):i.appendChild(r),r.styleSheet?r.styleSheet.cssText=e:r.appendChild(document.createTextNode(e))}}var N6=`
1952.p-toast {
1953    position: fixed;
1954    width: 25rem;
1955}
1956.p-toast-message-content {
1957    display: flex;
1958    align-items: flex-start;
1959}
1960.p-toast-message-text {
1961    flex: 1 1 auto;
1962}
1963.p-toast-top-right {
1964    top: 20px;
1965    right: 20px;
1966}
1967.p-toast-top-left {
1968    top: 20px;
1969    left: 20px;
1970}
1971.p-toast-bottom-left {
1972    bottom: 20px;
1973    left: 20px;
1974}
1975.p-toast-bottom-right {
1976    bottom: 20px;
1977    right: 20px;
1978}
1979.p-toast-top-center {
1980    top: 20px;
1981    left: 50%;
1982    transform: translateX(-50%);
1983}
1984.p-toast-bottom-center {
1985    bottom: 20px;
1986    left: 50%;
1987    transform: translateX(-50%);
1988}
1989.p-toast-center {
1990    left: 50%;
1991    top: 50%;
1992    min-width: 20vw;
1993    transform: translate(-50%, -50%);
1994}
1995.p-toast-icon-close {
1996    display: flex;
1997    align-items: center;
1998    justify-content: center;
1999    overflow: hidden;
2000    position: relative;
2001}
2002.p-toast-icon-close.p-link {
2003    cursor: pointer;
2004}
2005
2006/* Animations */
2007.p-toast-message-enter-from {
2008    opacity: 0;
2009    -webkit-transform: translateY(50%);
2010    -ms-transform: translateY(50%);
2011    transform: translateY(50%);
2012}
2013.p-toast-message-leave-from {
2014    max-height: 1000px;
2015}
2016.p-toast .p-toast-message.p-toast-message-leave-to {
2017    max-height: 0;
2018    opacity: 0;
2019    margin-bottom: 0;
2020    overflow: hidden;
2021}
2022.p-toast-message-enter-active {
2023    -webkit-transition: transform 0.3s, opacity 0.3s;
2024    transition: transform 0.3s, opacity 0.3s;
2025}
2026.p-toast-message-leave-active {
2027    -webkit-transition: max-height 0.45s cubic-bezier(0, 1, 0, 1), opacity 0.3s, margin-bottom 0.3s;
2028    transition: max-height 0.45s cubic-bezier(0, 1, 0, 1), opacity 0.3s, margin-bottom 0.3s;
2029}
2030`;L6(N6);km.render=R6;const Rm=Symbol();function D6(){const e=Ft(Rm);if(!e)throw new Error("No PrimeVue Toast provided!");return e}var x6={install:e=>{const t={add:n=>{Sn.emit("add",n)},removeGroup:n=>{Sn.emit("remove-group",n)},removeAllGroups:()=>{Sn.emit("remove-all-groups")}};e.config.globalProperties.$toast=t,e.provide(Rm,t)}},Lm={name:"Checkbox",extends:Ve,emits:["click","update:modelValue","change","input","focus","blur"],props:{value:null,modelValue:null,binary:Boolean,name:{type:String,default:null},trueValue:{type:null,default:!0},falseValue:{type:null,default:!1},disabled:{type:Boolean,default:!1},readonly:{type:Boolean,default:!1},required:{type:Boolean,default:!1},tabindex:{type:Number,default:null},inputId:{type:String,default:null},inputClass:{type:[String,Object],default:null},inputStyle:{type:Object,default:null},inputProps:{type:null,default:null},"aria-labelledby":{type:String,default:null},"aria-label":{type:String,default:null}},data(){return{focused:!1}},methods:{onClick(e){if(!this.disabled&&!this.readonly){let t;this.binary?t=this.checked?this.falseValue:this.trueValue:this.checked?t=this.modelValue.filter(n=>!ve.equals(n,this.value)):t=this.modelValue?[...this.modelValue,this.value]:[this.value],this.$emit("click",e),this.$emit("update:modelValue",t),this.$emit("change",e),this.$emit("input",t),this.$refs.input.focus()}},onFocus(e){this.focused=!0,this.$emit("focus",e)},onBlur(e){this.focused=!1,this.$emit("blur",e)}},computed:{checked(){return this.binary?this.modelValue===this.trueValue:ve.contains(this.value,this.modelValue)},containerClass(){return["p-checkbox p-component",{"p-checkbox-checked":this.checked,"p-checkbox-disabled":this.disabled,"p-checkbox-focused":this.focused}]}},components:{CheckIcon:yn}};const M6=["id","value","name","checked","tabindex","disabled","readonly","required","aria-labelledby","aria-label"];function F6(e,t,n,i,r,s){return g(),S("div",R({class:s.containerClass,onClick:t[2]||(t[2]=a=>s.onClick(a))},e.ptm("root")),[f("div",R({class:"p-hidden-accessible"},e.ptm("hiddenInputWrapper")),[f("input",R({ref:"input",id:n.inputId,type:"checkbox",value:n.value,
2030name:n.name,checked:s.checked,tabindex:n.tabindex,disabled:n.disabled,readonly:n.readonly,required:n.required,"aria-labelledby":e.ariaLabelledby,"aria-label":e.ariaLabel,onFocus:t[0]||(t[0]=a=>s.onFocus(a)),onBlur:t[1]||(t[1]=a=>s.onBlur(a))},e.ptm("hiddenInput")),null,16,M6)],16),f("div",R({ref:"box",class:["p-checkbox-box",n.inputClass,{"p-highlight":s.checked,"p-disabled":n.disabled,"p-focus":r.focused}],style:n.inputStyle},{...n.inputProps,...e.ptm("input")}),[he(e.$slots,"icon",{checked:s.checked},()=>[(g(),Q(_e(s.checked?"CheckIcon":null),R({class:"p-checkbox-icon"},e.ptm("icon")),null,16))])],16)],16)}Lm.render=F6;var Nm={name:"OverlayPanel",extends:Ve,inheritAttrs:!1,emits:["show","hide"],props:{dismissable:{type:Boolean,default:!0},showCloseIcon:{type:Boolean,default:!1},appendTo:{type:String,default:"body"},baseZIndex:{type:Number,default:0},autoZIndex:{type:Boolean,default:!0},breakpoints:{type:Object,default:null},closeIcon:{type:String,default:void 0}},data(){return{visible:!1}},watch:{dismissable:{immediate:!0,handler(e){e?this.bindOutsideClickListener():this.unbindOutsideClickListener()}}},selfClick:!1,target:null,eventTarget:null,outsideClickListener:null,scrollHandler:null,resizeListener:null,container:null,styleElement:null,overlayEventListener:null,beforeUnmount(){this.dismissable&&this.unbindOutsideClickListener(),this.scrollHandler&&(this.scrollHandler.destroy(),this.scrollHandler=null),this.destroyStyle(),this.unbindResizeListener(),this.target=null,this.container&&this.autoZIndex&&He.clear(this.container),this.overlayEventListener&&(Mt.off("overlay-click",this.overlayEventListener),this.overlayEventListener=null),this.container=null},mounted(){this.breakpoints&&this.createStyle()},methods:{toggle(e,t){this.visible?this.hide():this.show(e,t)},show(e,t){this.visible=!0,this.eventTarget=e.currentTarget,this.target=t||e.currentTarget},hide(){this.visible=!1,F.focus(this.target)},onContentClick(){this.selfClick=!0},onEnter(e){this.container.setAttribute(this.attributeSelector,""),this.alignOverlay(),this.dismissable&&this.bindOutsideClickListener(),this.bindScrollListener(),this.bindResizeListener(),this.autoZIndex&&He.set("overlay",e,this.baseZIndex+this.$primevue.config.zIndex.overlay),this.overlayEventListener=t=>{this.container.contains(t.target)&&(this.selfClick=!0)},this.focus(),Mt.on("overlay-click",this.overlayEventListener),this.$emit("show")},onLeave(){this.unbindOutsideClickListener(),this.unbindScrollListener(),this.unbindResizeListener(),Mt.off("overlay-click",this.overlayEventListener),this.overlayEventListener=null,this.$emit("hide")},onAfterLeave(e){this.autoZIndex&&He.clear(e)},alignOverlay(){F.absolutePosition(this.container,this.target);const e=F.getOffset(this.container),t=F.getOffset(this.target);let n=0;e.left<t.left&&(n=t.left-e.left),this.container.style.setProperty("--overlayArrowLeft",`${n}px`),e.top<t.top&&F.addClass(this.container,"p-overlaypanel-flipped")},onContentKeydown(e){e.code==="Escape"&&this.hide()},onButtonKeydown(e){switch(e.code){case"ArrowDown":case"ArrowUp":case"ArrowLeft":case"ArrowRight":e.preventDefault()}},focus(){let e=this.container.querySelector("[autofocus]");e&&e.focus()},bindOutsideClickListener(){!this.outsideClickListener&&F.isClient()&&(this.outsideClickListener=e=>{this.visible&&!this.selfClick&&!this.isTargetClicked(e)&&(this.visible=!1),this.selfClick=!1},document.addEventListener("click",this.outsideClickListener))},unbindOutsideClickListener(){this.outsideClickListener&&(document.removeEventListener("click",this.outsideClickListener),this.outsideClickListener=null,this.selfClick=!1)},bindScrollListener(){this.scrollHandler||(this.scrollHandler=new kn(this.target,()=>{this.visible&&(this.visible=!1)})),this.scrollHandler.bindScrollListener()},unbindScrollListener(){this.scrollHandler&&this.scrollHandler.unbindScrollListener()},bindResizeListener(){this.resizeListener||(this.resizeListener=()=>{this.visible&&!F.isTouchDevice()&&(this.visible=!1)},window.addEventListener("resize",this.resizeListener))},unbindResizeListener(){this.resizeListener&&(window.removeEventListener("resize",this.resizeListener),this.resizeListener=null)},isTargetClicked(e){return this.eventTarget&&(this.eventTarget===e.target||this.eventTarget.contains(e.target))},containerRef(e){this.container=e},createStyle(){if(!this.styleElement){this.styleElement=document.createElement("style"),this.styleElement.type="text/css",document.head.appendChild(this.styleElement);let e="";for(let t in this.breakpoints)e+=`
2031                        @media screen and (max-width: ${t}) {
2032                            .p-overlaypanel[${this.attributeSelector}] {
2033                                width: ${this.breakpoints[t]} !important;
2034                            }
2035                        }
2036                    `;this.styleElement.innerHTML=e}},destroyStyle(){this.styleElement&&(document.head.removeChild(this.styleElement),this.styleElement=null)},onOverlayClick(e){Mt.emit("overlay-click",{originalEvent:e,target:this.target})}},computed:{containerClass(){return["p-overlaypanel p-component",{"p-input-filled":this.$primevue.config.inputStyle==="filled","p-ripple-disabled":this.$primevue.config.ripple===!1}]},attributeSelector(){return pt()},closeAriaLabel(){return this.$primevue.config.locale.aria?this.$primevue.config.locale.aria.close:void 0}}
2036,directives:{focustrap:Fs,ripple:gt},components:{Portal:Kt,TimesIcon:Qt}};const V6=["aria-modal"],B6=["aria-label"];function $6(e,t,n,i,r,s){const a=le("Portal"),o=Xe("ripple"),l=Xe("focustrap");return g(),Q(a,{appendTo:n.appendTo},{default:Ee(()=>[de($t,{name:"p-overlaypanel",onEnter:s.onEnter,onLeave:s.onLeave,onAfterLeave:s.onAfterLeave},{default:Ee(()=>[r.visible?Ne((g(),S("div",R({key:0,ref:s.containerRef,role:"dialog",class:s.containerClass,"aria-modal":r.visible,onClick:t[5]||(t[5]=(...c)=>s.onOverlayClick&&s.onOverlayClick(...c))},{...e.$attrs,...e.ptm("root")}),[f("div",R({class:"p-overlaypanel-content",onClick:t[0]||(t[0]=(...c)=>s.onContentClick&&s.onContentClick(...c)),onMousedown:t[1]||(t[1]=(...c)=>s.onContentClick&&s.onContentClick(...c)),onKeydown:t[2]||(t[2]=(...c)=>s.onContentKeydown&&s.onContentKeydown(...c))},e.ptm("content")),[he(e.$slots,"default")],16),n.showCloseIcon?Ne((g(),S("button",R({key:0,class:"p-overlaypanel-close p-link","aria-label":s.closeAriaLabel,type:"button",autofocus:"",onClick:t[3]||(t[3]=(...c)=>s.hide&&s.hide(...c)),onKeydown:t[4]||(t[4]=(...c)=>s.onButtonKeydown&&s.onButtonKeydown(...c))},e.ptm("closeButton")),[he(e.$slots,"closeicon",{},()=>[(g(),Q(_e(n.closeIcon?"span":"TimesIcon"),R({class:["p-overlaypanel-close-icon ",n.closeIcon]},e.ptm("closeIcon")),null,16,["class"]))])],16,B6)),[[o]]):M("",!0)],16,V6)),[[l]]):M("",!0)]),_:3},8,["onEnter","onLeave","onAfterLeave"])]),_:3},8,["appendTo"])}function U6(e,t){t===void 0&&(t={});var n=t.insertAt;if(!(typeof document>"u")){var i=document.head||document.getElementsByTagName("head")[0],r=document.createElement("style");r.type="text/css",n==="top"&&i.firstChild?i.insertBefore(r,i.firstChild):i.appendChild(r),r.styleSheet?r.styleSheet.cssText=e:r.appendChild(document.createTextNode(e))}}var H6=`
2037.p-overlaypanel {
2038    position: absolute;
2039    margin-top: 10px;
2040    top: 0;
2041    left: 0;
2042}
2043.p-overlaypanel-flipped {
2044    margin-top: 0;
2045    margin-bottom: 10px;
2046}
2047.p-overlaypanel-close {
2048    display: flex;
2049    justify-content: center;
2050    align-items: center;
2051    overflow: hidden;
2052    position: relative;
2053}
2054
2055/* Animation */
2056.p-overlaypanel-enter-from {
2057    opacity: 0;
2058    transform: scaleY(0.8);
2059}
2060.p-overlaypanel-leave-to {
2061    opacity: 0;
2062}
2063.p-overlaypanel-enter-active {
2064    transition: transform 0.12s cubic-bezier(0, 0, 0.2, 1), opacity 0.12s cubic-bezier(0, 0, 0.2, 1);
2065}
2066.p-overlaypanel-leave-active {
2067    transition: opacity 0.1s linear;
2068}
2069.p-overlaypanel:after,
2070.p-overlaypanel:before {
2071    bottom: 100%;
2072    left: calc(var(--overlayArrowLeft, 0) + 1.25rem);
2073    content: ' ';
2074    height: 0;
2075    width: 0;
2076    position: absolute;
2077    pointer-events: none;
2078}
2079.p-overlaypanel:after {
2080    border-width: 8px;
2081    margin-left: -8px;
2082}
2083.p-overlaypanel:before {
2084    border-width: 10px;
2085    margin-left: -10px;
2086}
2087.p-overlaypanel-flipped:after,
2088.p-overlaypanel-flipped:before {
2089    bottom: auto;
2090    top: 100%;
2091}
2092.p-overlaypanel.p-overlaypanel-flipped:after {
2093    border-bottom-color: transparent;
2094}
2095.p-overlaypanel.p-overlaypanel-flipped:before {
2096    border-bottom-color: transparent;
2097}
2098`;U6(H6);Nm.render=$6;var Dm={name:"Menuitem",extends:Ve,inheritAttrs:!1,emits:["item-click"],props:{item:null,templates:null,exact:null,id:null,focusedOptionId:null},methods:{getItemProp(e,t){return e&&e.item?ve.getItemValue(e.item[t]):void 0},getPTOptions(e){return this.ptm(e,{context:{focused:this.isItemFocused()}})},isItemFocused(){return this.focusedOptionId===this.id},onItemActionClick(e,t){t&&t(e)},onItemClick(e){const t=this.getItemProp(this.item,"command");t&&t({originalEvent:e,item:this.item.item}),this.$emit("item-click",{originalEvent:e,item:this.item,id:this.id})},containerClass(){return["p-menuitem",this.item.class,{"p-focus":this.id===this.focusedOptionId,"p-disabled":this.disabled()}]},linkClass(e){return["p-menuitem-link",{"router-link-active":e&&e.isActive,"router-link-active-exact":this.exact&&e&&e.isExactActive}]},visible(){return typeof this.item.visible=="function"?this.item.visible():this.item.visible!==!1},disabled(){return typeof this.item.disabled=="function"?this.item.disabled():this.item.disabled},label(){return typeof this.item.label=="function"?this.item.label():this.item.label}},computed:{iconClass(){return["p-menuitem-icon",this.item.icon]}},directives:{ripple:gt}};const z6=["id","aria-label","aria-disabled"],K6=["href","onClick"],G6=["href","target"];function j6(e,t,n,i,r,s){const a=le("router-link"),o=Xe("ripple");return s.visible()?(g(),S("li",R({key:0,id:n.id,class:s.containerClass(),role:"menuitem",style:n.item.style,"aria-label":s.label(),"aria-disabled":s.disabled()},s.getPTOptions("menuitem")),[f("div",R({class:"p-menuitem-content",onClick:t[0]||(t[0]=l=>s.onItemClick(l))},s.getPTOptions("content")),[n.templates.item?(g(),Q(_e(n.templates.item),{key:1,item:n.item},null,8,["item"])):(g(),S(J,{key:0},[n.item.to&&!s.disabled()?(g(),Q(a,{key:0,to:n.item.to,custom:""},{default:Ee(({navigate:l,href:c,isActive:d,isExactActive:u})=>[Ne((g(),S("a",R({href:c,class:s.linkClass({isActive:d,isExactActive:u}),tabindex:"-1","aria-hidden":"true",onClick:p=>s.onItemActionClick(p,l)},s.getPTOptions("action")),[n.templates.itemicon?(g(),Q(_e(n.templates.itemicon),{key:0,item:n.item,class:Oe(s.iconClass)},null,8,["item","class"])):n.item.icon?(g(),S("span",R({key:1,class:s.iconClass},s.getPTOptions("icon")),null,16)):M("",!0),f("span",R({class:"p-menuitem-text"},s.getPTOptions("label")),N(s.label()),17)],16,K6)),[[o]])]),_:1},8,["to"])):Ne((g(),S("a",R({key:1,href:n.item.url,class:s.linkClass(),target:n.item.target,tabindex:"-1","aria-hidden":"true"},s.getPTOptions("action")),[n.templates.itemicon?(g(),Q(_e(n.templates.itemicon),{key:0,item:n.item,class:Oe(s.iconClass)},null,8,["item","class"])):n.item.icon?(g(),S("span",R({key:1,class:s.iconClass},s.getPTOptions("icon")),null,16)):M("",!0),f("span",R({class:"p-menuitem-text"},s.getPTOptions("label")),N(s.label()),17)],16,G6)),[[o]])],64))],16)],16,z6)):M("",!0)}Dm.render=j6;var xm={name:"Menu",extends:Ve,inheritAttrs:!1,emits:["show","hide","focus","blur"],props:{popup:{type:Boolean,default:!1},model:{type:Array,default:null},appendTo:{type:String,default:"body"},autoZIndex:{type:Boolean,default:!0},baseZIndex:{type:Number,default:0},exact:{type:Boolean,default:!0},tabindex:{type:Number,default:0},"aria-label":{type:String,default:null},"aria-labelledby":{type:String,default:null}},data(){return{id:this.$attrs.id,overlayVisible:!1,focused:!1,focusedOptionIndex:-1,selectedOptionIndex:-1}},watch:{"$attrs.id":function(e){this.id=e||pt()}},target:null,outsideClickListener:null,scrollHandler:null,resizeListener:null,container:null,list:null,mounted(){this.id=this.id||pt(),this.popup||(this.bindResizeListener(),this.bindOutsideClickListener())},beforeUnmount(){this.unbindResizeListener(),this.unbindOutsideClickListener(),this.scrollHandler&&(this.scrollHandler.destroy(),this.scrollHandler=null),this.target=null,this.container&&this.autoZIndex&&He.clear(this.container),this.container=null},methods:{itemClick(e){const t=e.item;this.disabled(t)||(t.command&&t.command(e),t.to&&e.navigate&&e.navigate(e.originalEvent),this.overlayVisible&&this.hide(),!this.popup&&this.focusedOptionIndex!==e.id&&(this.focusedOptionIndex=e.id))},onListFocus(e){this.focused=!0,this.popup||(this.selectedOptionIndex!==-1?(this.changeFocusedOptionIndex(this.selectedOptionIndex),this.selectedOptionIndex=-1):this.changeFocusedOptionIndex(0)),this.$emit("focus",e)},onListBlur(e){this.focused=!1,this.focusedOptionIndex=-1,this.$emit("blur",e)},onListKeyDown(e){switch(e.code){case"ArrowDown":this.onArrowDownKey(e);break;case"ArrowUp":this.onArrowUpKey(e);break;case"Home":this.onHomeKey(e);break;case"End":this.onEndKey(e);break;case"Enter":this.onEnterKey(e);break;case"Space":this.onSpaceKey(e);break;case"Escape":this.popup&&(F.focus(this.target),this.hide());case"Tab":this.overlayVisible&&this.hide();break}},onArrowDownKey(e){const t=this.findNextOptionIndex(this.focusedOptionIndex);this.changeFocusedOptionIndex(t),e.preventDefault()},onArrowUpKey(e){if(e.altKey&&this.popup)F.focus(this.target),this.hide(),e.preventDefault();else{const t=this.findPrevOptionIndex(this.focusedOptionIndex);this.changeFocusedOptionIndex(t),e.preventDefault()}},onHomeKey(e){this.changeFocusedOptionIndex(0),e.preventDefault()},onEndKey(e){this.changeFocusedOptionIndex(F.find(this.container,"li.p-menuitem:not(.p-disabled)").length-1),e.preventDefault()},onEnterKey(e){const t=F.findSingle(this.list,`li[id="${`${this.focusedOptionIndex}`}"]`),n=t&&F.findSingle(t,".p-menuitem-link");this.popup&&F.focus(this.target),n?n.click():t&&t.click(),e.preventDefault()},onSpaceKey(e){this.onEnterKey(e)},findNextOptionIndex(e){const n=[...F.find(this.container,"li.p-menuitem:not(.p-disabled)")].findIndex(i=>i.id===e);return n>-1?n+1:0},findPrevOptionIndex(e){const n=[...F.find(this.container,"li.p-menuitem:not(.p-disabled)")].findIndex(i=>i.id===e);return n>-1?n-1:0},changeFocusedOptionIndex(e){const t=F.find(this.container,"li.p-menuitem:not(.p-disabled)");let n=e>=t.length?t.length-1:e<0?0:e;n>-1&&(this.focusedOptionIndex=t[n].getAttribute("id"))},toggle(e){this.overlayVisible?this.hide():this.show(e)},show(e){this.overlayVisible=!0,this.target=e.currentTarget},hide(){this.overlayVisible=!1,this.target=null},onEnter(e){this.alignOverlay(),this.bindOutsideClickListener(),this.bindResizeListener(),this.bindScrollListener(),this.autoZIndex&&He.set("menu",e,this.baseZIndex+this.$primevue.config.zIndex.menu),this.popup&&(F.focus(this.list),this.changeFocusedOptionIndex(0)),this.$emit("show")},onLeave(){this.unbindOutsideClickListener(),this.unbindResizeListener(),this.unbindScrollListener(),this.$emit("hide")},onAfterLeave(e){this.autoZIndex&&He.clear(e)},alignOverlay(){F.absolutePosition(this.container,this.target),this.container.style.minWidth=F.getOuterWidth(this.target)+"px"},bindOutsideClickListener(){this.outsideClickListener||(this.outsideClickListener=e=>{const t=this.container&&!this.container.contains(e.target),n=!(this.target&&(this.target===e.target||this.target.contains(e.target)));this.overlayVisible&&t&&n?this.hide():!this.popup&&t&&n&&(this.focusedOptionIndex=-1)},document.addEventListener("click",this.outsideClickListener))},unbindOutsideClickListener(){this.outsideClickListener&&(document.removeEventListener("click",this.outsideClickListener),this.outsideClickListener=null)},bindScrollListener(){this.scrollHandler||(this.scrollHandler=new kn(this.target,()=>{this.overlayVisible&&this.hide()})),this.scrollHandler.bindScrollListener()},unbindScrollListener(){this.scrollHandler&&this.scrollHandler.unbindScrollListener()},bindResizeListener(){this.resizeListener||(this.resizeListener=()=>{this.overlayVisible&&!F.isTouchDevice()&&this.hide()},window.addEventListener("resize",this.resizeListener))},unbindResizeListener(){this.resizeListener&&(window.removeEventListener("resize",this.resizeListener),this.resizeListener=null)},visible(e){return typeof e.visible=="function"?e.visible():e.visible!==!1},disabled(e){return typeof e.disabled=="function"?e.disabled():e.disabled},label(e){return typeof e.label=="function"?e.label():e.label},separatorClass(e){return["p-menuitem-separator",e.class]},onOverlayClick(e){Mt.emit("overlay-click",{originalEvent:e,target:this.target})},containerRef(e){this.container=e},listRef(e){this.list=e}},computed:{containerClass(){return["p-menu p-component",{"p-menu-overlay":this.popup,"p-input-filled":this.$primevue.config.inputStyle==="filled","p-ripple-disabled":this.$primevue.config.ripple===!1}]},focusedOptionId(){return this.focusedOptionIndex!==-1?this.focusedOptionIndex:null}},components:{PVMenuitem:Dm,Portal:Kt}};const Y6=["id"],W6=["id","tabindex","aria-activedescendant","aria-label","aria-labelledby"],Q6=["id"];function Z6(e,t,n,i,r,s){const a=le("PVMenuitem"),o=le("Portal");return g(),Q(o,{appendTo:n.appendTo,disabled:!n.popup},{default:Ee(()=>[de($t,{name:"p-connected-overlay",onEnter:s.onEnter,onLeave:s.onLeave,onAfterLeave:s.onAfterLeave},{default:Ee(()=>[!n.popup||r.overlayVisible?(g(),S("div",R({key:0,ref:s.containerRef,id:r.id,class:s.containerClass,onClick:t[3]||(t[3]=(...l)=>s.onOverlayClick&&s.onOverlayClick(...l))},{...e.$attrs,...e.ptm("root")}),[e.$slots.start?(g(),S("div",R({key:0,class:"p-menu-start"},e.ptm("start")),[he(e.$slots,"start")],16)):M("",!0),f("ul",R({ref:s.listRef,id:r.id+"_list",class:"p-menu-list p-reset",role:"menu",tabindex:n.tabindex,"aria-activedescendant":r.focused?s.focusedOptionId:void 0,"aria-label":e.ariaLabel,"aria-labelledby":e.ariaLabelledby,onFocus:t[0]||(t[0]=(...l)=>s.onListFocus&&s.onListFocus(...l)),onBlur:t[1]||(t[1]=(...l)=>s.onListBlur&&s.onListBlur(...l)),onKeydown:t[2]||(t[2]=(...l)=>s.onListKeyDown&&s.onListKeyDown(...l))},e.ptm("menu")),[(g(!0),S(J,null,ye(n.model,(l,c)=>(g(),S(J,{key:s.label(l)+c.toString()},[l.items&&s.visible(l)&&!l.separator?(g(),S(J,{key:0},[l.items?(g(),S("li",R({key:0,id:r.id+"_"+c,class:"p-submenu-header",role:"none"},e.ptm("submenuHeader")),[he(e.$slots,"item",{item:l},()=>[ke(N(s.label(l)),1)])],16,Q6)):M("",!0),(g(!0),S(J,null,ye(l.items,(d,u)=>(g(),S(J,{key:d.label+c+"_"+u},[s.visible(d)&&!d.separator?(g(),Q(a,{key:0,id:r.id+"_"+c+"_"+u,item:d,templates:e.$slots,exact:n.exact,focusedOptionId:s.focusedOptionId,onItemClick:s.itemClick,pt:e.pt},null,8,["id","item","templates","exact","focusedOptionId","onItemClick","pt"])):s.visible(d)&&d.separator?(g(),S("li",R({key:"separator"+c+u,class:s.separatorClass(l),style:d.style,role:"separator"},e.ptm("separator")),null,16)):M("",!0)],64))),128))],64)):s.visible(l)&&l.separator?(g(),S("li",R({key:"separator"+c.toString(),class:s.separatorClass(l),style:l.style,role:"separator"},e.ptm("separator")),null,16)):(g(),Q(a,{key:s.label(l)+c.toString(),id:r.id+"_"+c,item:l,templates:e.$slots,exact:n.exact,focusedOptionId:s.focusedOptionId,onItemClick:s.itemClick,pt:e.pt},null,8,["id","item","templates","exact","focusedOptionId","onItemClick","pt"]))],64))),128))],16,W6),e.$slots.end?(g(),S("div",R({key:1,class:"p-menu-end"},e.ptm("end")),[he(e.$slots,"end")],16)):M("",!0)],16,Y6)):M("",!0)]),_:3},8,["onEnter","onLeave","onAfterLeave"])]),_:3},8,["appendTo","disabled"])}
2098function q6(e,t){t===void 0&&(t={});var n=t.insertAt;if(!(typeof document>"u")){var i=document.head||document.getElementsByTagName("head")[0],r=document.createElement("style");r.type="text/css",n==="top"&&i.firstChild?i.insertBefore(r,i.firstChild):i.appendChild(r),r.styleSheet?r.styleSheet.cssText=e:r.appendChild(document.createTextNode(e))}}var J6=`
2099.p-menu-overlay {
2100    position: absolute;
2101    top: 0;
2102    left: 0;
2103}
2104.p-menu ul {
2105    margin: 0;
2106    padding: 0;
2107    list-style: none;
2108}
2109.p-menu .p-menuitem-link {
2110    cursor: pointer;
2111    display: flex;
2112    align-items: center;
2113    text-decoration: none;
2114    overflow: hidden;
2115    position: relative;
2116}
2117.p-menu .p-menuitem-text {
2118    line-height: 1;
2119}
2120`;q6(J6);xm.render=Z6;var Mm={name:"SearchIcon",extends:ze};const X6=f("g",{"clip-path":"url(#clip0_238_9909)"},[f("path",{"fill-rule":"evenodd","clip-rule":"evenodd",d:"M2.67602 11.0265C3.6661 11.688 4.83011 12.0411 6.02086 12.0411C6.81149 12.0411 7.59438 11.8854 8.32483 11.5828C8.87005 11.357 9.37808 11.0526 9.83317 10.6803L12.9769 13.8241C13.0323 13.8801 13.0983 13.9245 13.171 13.9548C13.2438 13.985 13.3219 14.0003 13.4007 14C13.4795 14.0003 13.5575 13.985 13.6303 13.9548C13.7031 13.9245 13.7691 13.8801 13.8244 13.8241C13.9367 13.7116 13.9998 13.5592 13.9998 13.4003C13.9998 13.2414 13.9367 13.089 13.8244 12.9765L10.6807 9.8328C11.053 9.37773 11.3573 8.86972 11.5831 8.32452C11.8857 7.59408 12.0414 6.81119 12.0414 6.02056C12.0414 4.8298 11.6883 3.66579 11.0268 2.67572C10.3652 1.68564 9.42494 0.913972 8.32483 0.45829C7.22472 0.00260857 6.01418 -0.116618 4.84631 0.115686C3.67844 0.34799 2.60568 0.921393 1.76369 1.76338C0.921698 2.60537 0.348296 3.67813 0.115991 4.84601C-0.116313 6.01388 0.00291375 7.22441 0.458595 8.32452C0.914277 9.42464 1.68595 10.3649 2.67602 11.0265ZM3.35565 2.0158C4.14456 1.48867 5.07206 1.20731 6.02086 1.20731C7.29317 1.20731 8.51338 1.71274 9.41304 2.6124C10.3127 3.51206 10.8181 4.73226 10.8181 6.00457C10.8181 6.95337 10.5368 7.88088 10.0096 8.66978C9.48251 9.45868 8.73328 10.0736 7.85669 10.4367C6.98011 10.7997 6.01554 10.8947 5.08496 10.7096C4.15439 10.5245 3.2996 10.0676 2.62869 9.39674C1.95778 8.72583 1.50089 7.87104 1.31579 6.94046C1.13068 6.00989 1.22568 5.04532 1.58878 4.16874C1.95187 3.29215 2.56675 2.54292 3.35565 2.0158Z",fill:"currentColor"})],-1),eN=f("defs",null,[f("clipPath",{id:"clip0_238_9909"},[f("rect",{width:"14",height:"14",fill:"white"})])],-1),tN=[X6,eN];function nN(e,t,n,i,r,s){return g(),S("svg",R({width:"14",height:"14",viewBox:"0 0 14 14",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e.pti()),tN,16)}Mm.render=nN;var Fm={name:"MultiSelect",extends:Ve,emits:["update:modelValue","change","focus","blur","before-show","before-hide","show","hide","filter","selectall-change"],props:{modelValue:null,options:Array,optionLabel:null,optionValue:null,optionDisabled:null,optionGroupLabel:null,optionGroupChildren:null,scrollHeight:{type:String,default:"200px"},placeholder:String,disabled:Boolean,inputId:{type:String,default:null},inputProps:{type:null,default:null},panelClass:{type:String,default:null},panelStyle:{type:null,default:null},panelProps:{type:null,default:null},filterInputProps:{type:null,default:null},closeButtonProps:{type:null,default:null},dataKey:null,filter:Boolean,filterPlaceholder:String,filterLocale:String,filterMatchMode:{type:String,default:"contains"},filterFields:{type:Array,default:null},appendTo:{type:String,default:"body"},display:{type:String,default:"comma"},selectedItemsLabel:{type:String,default:"{0} items selected"},maxSelectedLabels:{type:Number,default:null},selectionLimit:{type:Number,default:null},showToggleAll:{type:Boolean,default:!0},loading:{type:Boolean,default:!1},checkboxIcon:{type:String,default:void 0},closeIcon:{type:String,default:void 0},dropdownIcon:{type:String,default:void 0},filterIcon:{type:String,default:void 0},loadingIcon:{type:String,default:void 0},removeTokenIcon:{type:String,default:void 0},selectAll:{type:Boolean,default:null},resetFilterOnHide:{type:Boolean,default:!1},virtualScrollerOptions:{type:Object,default:null},autoOptionFocus:{type:Boolean,default:!0},autoFilterFocus:{type:Boolean,default:!1},filterMessage:{type:String,default:null},selectionMessage:{type:String,default:null},emptySelectionMessage:{type:String,default:null},emptyFilterMessage:{type:String,default:null},emptyMessage:{type:String,default:null},tabindex:{type:Number,default:0},"aria-label":{type:String,default:null},"aria-labelledby":{type:String,default:null}},outsideClickListener:null,scrollHandler:null,resizeListener:null,overlay:null,list:null,virtualScroller:null,startRangeIndex:-1,searchTimeout:null,searchValue:"",selectOnFocus:!1,focusOnHover:!1,data(){return{id:this.$attrs.id,focused:!1,focusedOptionIndex:-1,headerCheckboxFocused:!1,filterValue:null,overlayVisible:!1}},watch:{"$attrs.id":function(e){this.id=e||pt()},options(){this.autoUpdateModel()}},mounted(){this.id=this.id||pt(),this.autoUpdateModel()},beforeUnmount(){this.unbindOutsideClickListener(),this.unbindResizeListener(),this.scrollHandler&&(this.scrollHandler.destroy(),this.scrollHandler=null),this.overlay&&(He.clear(this.overlay),this.overlay=null)},methods:{getOptionIndex(e,t){return this.virtualScrollerDisabled?e:t&&t(e).index},getOptionLabel(e){return this.optionLabel?ve.resolveFieldData(e,this.optionLabel):e},getOptionValue(e){return this.optionValue?ve.resolveFieldData(e,this.optionValue):e},getOptionRenderKey(e){return this.dataKey?ve.resolveFieldData(e,this.dataKey):this.getOptionLabel(e)},getHeaderCheckboxPTOptions(e){return this.ptm(e,{context:{selected:this.allSelected,focused:this.headerCheckboxFocused}})},getCheckboxPTOptions(e,t,n,i){return this.ptm(i,{context:{selected:this.isSelected(e),focused:this.focusedOptionIndex===this.getOptionIndex(n,t),disabled:this.isOptionDisabled(e)}})},isOptionDisabled(e){return this.maxSelectionLimitReached&&!this.isSelected(e)?!0:this.optionDisabled?ve.resolveFieldData(e,this.optionDisabled):!1},isOptionGroup(e){return this.optionGroupLabel&&e.optionGroup&&e.group},getOptionGroupLabel(e){return ve.resolveFieldData(e,this.optionGroupLabel)},getOptionGroupChildren(e){return ve.resolveFieldData(e,this.optionGroupChildren)},getAriaPosInset(e){return(this.optionGroupLabel?e-this.visibleOptions.slice(0,e).filter(t=>this.isOptionGroup(t)).length:e)+1},show(e){this.$emit("before-show"),this.overlayVisible=!0,this.focusedOptionIndex=this.focusedOptionIndex!==-1?this.focusedOptionIndex:this.autoOptionFocus?this.findFirstFocusedOptionIndex():-1,e&&F.focus(this.$refs.focusInput)},hide(e){const t=()=>{this.$emit("before-hide"),this.overlayVisible=!1,this.focusedOptionIndex=-1,this.searchValue="",this.resetFilterOnHide&&(this.filterValue=null),e&&F.focus(this.$refs.focusInput)};setTimeout(()=>{t()},0)},onFocus(e){this.disabled||(this.focused=!0,this.focusedOptionIndex=this.focusedOptionIndex!==-1?this.focusedOptionIndex:this.overlayVisible&&this.autoOptionFocus?this.findFirstFocusedOptionIndex():-1,this.overlayVisible&&this.scrollInView(this.focusedOptionIndex),this.$emit("focus",e))},onBlur(e){this.focused=!1,this.focusedOptionIndex=-1,this.searchValue="",this.$emit("blur",e)},onKeyDown(e){if(this.disabled){e.preventDefault();return}const t=e.metaKey||e.ctrlKey;switch(e.code){case"ArrowDown":this.onArrowDownKey(e);break;case"ArrowUp":this.onArrowUpKey(e);break;case"Home":this.onHomeKey(e);break;case"End":this.onEndKey(e);break;case"PageDown":this.onPageDownKey(e);break;case"PageUp":this.onPageUpKey(e);break;case"Enter":case"Space":this.onEnterKey(e);break;case"Escape":this.onEscapeKey(e);break;case"Tab":this.onTabKey(e);break;case"ShiftLeft":case"ShiftRight":this.onShiftKey(e);break;default:if(e.code==="KeyA"&&t){const n=this.visibleOptions.filter(i=>this.isValidOption(i)).map(i=>this.getOptionValue(i));this.updateModel(e,n),e.preventDefault();break}
2120!t&&ve.isPrintableCharacter(e.key)&&(!this.overlayVisible&&this.show(),this.searchOptions(e),e.preventDefault());break}},onContainerClick(e){this.disabled||this.loading||(!this.overlay||!this.overlay.contains(e.target))&&(this.overlayVisible?this.hide(!0):this.show(!0))},onFirstHiddenFocus(e){const t=e.relatedTarget===this.$refs.focusInput?F.getFirstFocusableElement(this.overlay,":not(.p-hidden-focusable)"):this.$refs.focusInput;F.focus(t)},onLastHiddenFocus(e){const t=e.relatedTarget===this.$refs.focusInput?F.getLastFocusableElement(this.overlay,":not(.p-hidden-focusable)"):this.$refs.focusInput;F.focus(t)},onCloseClick(){this.hide(!0)},onHeaderCheckboxFocus(){this.headerCheckboxFocused=!0},onHeaderCheckboxBlur(){this.headerCheckboxFocused=!1},onOptionSelect(e,t,n=-1,i=!1){if(this.disabled||this.isOptionDisabled(t))return;let r=this.isSelected(t),s=null;r?s=this.modelValue.filter(a=>!ve.equals(a,this.getOptionValue(t),this.equalityKey)):s=[...this.modelValue||[],this.getOptionValue(t)],this.updateModel(e,s),n!==-1&&(this.focusedOptionIndex=n),i&&F.focus(this.$refs.focusInput)},onOptionMouseMove(e,t){this.focusOnHover&&this.changeFocusedOptionIndex(e,t)},onOptionSelectRange(e,t=-1,n=-1){if(t===-1&&(t=this.findNearestSelectedOptionIndex(n,!0)),n===-1&&(n=this.findNearestSelectedOptionIndex(t)),t!==-1&&n!==-1){const i=Math.min(t,n),r=Math.max(t,n),s=this.visibleOptions.slice(i,r+1).filter(a=>this.isValidOption(a)).map(a=>this.getOptionValue(a));this.updateModel(e,s)}},onFilterChange(e){const t=e.target.value;this.filterValue=t,this.focusedOptionIndex=-1,this.$emit("filter",{originalEvent:e,value:t}),!this.virtualScrollerDisabled&&this.virtualScroller.scrollToIndex(0)},onFilterKeyDown(e){switch(e.code){case"ArrowDown":this.onArrowDownKey(e);break;case"ArrowUp":this.onArrowUpKey(e,!0);break;case"ArrowLeft":case"ArrowRight":this.onArrowLeftKey(e,!0);break;case"Home":this.onHomeKey(e,!0);break;case"End":this.onEndKey(e,!0);break;case"Enter":this.onEnterKey(e);break;case"Escape":this.onEscapeKey(e);break;case"Tab":this.onTabKey(e,!0);break}},onFilterBlur(){this.focusedOptionIndex=-1},onFilterUpdated(){this.overlayVisible&&this.alignOverlay()},onOverlayClick(e){Mt.emit("overlay-click",{originalEvent:e,target:this.$el})},onOverlayKeyDown(e){switch(e.code){case"Escape":this.onEscapeKey(e);break}},onArrowDownKey(e){const t=this.focusedOptionIndex!==-1?this.findNextOptionIndex(this.focusedOptionIndex):this.findFirstFocusedOptionIndex();e.shiftKey&&this.onOptionSelectRange(e,this.startRangeIndex,t),this.changeFocusedOptionIndex(e,t),!this.overlayVisible&&this.show(),e.preventDefault()},onArrowUpKey(e,t=!1){if(e.altKey&&!t)this.focusedOptionIndex!==-1&&this.onOptionSelect(e,this.visibleOptions[this.focusedOptionIndex]),this.overlayVisible&&this.hide(),e.preventDefault();else{const n=this.focusedOptionIndex!==-1?this.findPrevOptionIndex(this.focusedOptionIndex):this.findLastFocusedOptionIndex();e.shiftKey&&this.onOptionSelectRange(e,n,this.startRangeIndex),this.changeFocusedOptionIndex(e,n),!this.overlayVisible&&this.show(),e.preventDefault()}},onArrowLeftKey(e,t=!1){t&&(this.focusedOptionIndex=-1)},onHomeKey(e,t=!1){const{currentTarget:n}=e;if(t){const i=n.value.length;n.setSelectionRange(0,e.shiftKey?i:0),this.focusedOptionIndex=-1}else{let i=e.metaKey||e.ctrlKey,r=this.findFirstOptionIndex();e.shiftKey&&i&&this.onOptionSelectRange(e,r,this.startRangeIndex),this.changeFocusedOptionIndex(e,r),!this.overlayVisible&&this.show()}e.preventDefault()},onEndKey(e,t=!1){const{currentTarget:n}=e;if(t){const i=n.value.length;n.setSelectionRange(e.shiftKey?0:i,i),this.focusedOptionIndex=-1}else{let i=e.metaKey||e.ctrlKey,r=this.findLastOptionIndex();e.shiftKey&&i&&this.onOptionSelectRange(e,this.startRangeIndex,r),this.changeFocusedOptionIndex(e,r),!this.overlayVisible&&this.show()}e.preventDefault()},onPageUpKey(e){this.scrollInView(0),e.preventDefault()},onPageDownKey(e){this.scrollInView(this.visibleOptions.length-1),e.preventDefault()},onEnterKey(e){this.overlayVisible?this.focusedOptionIndex!==-1&&(e.shiftKey?this.onOptionSelectRange(e,this.focusedOptionIndex):this.onOptionSelect(e,this.visibleOptions[this.focusedOptionIndex])):this.onArrowDownKey(e),e.preventDefault()},onEscapeKey(e){this.overlayVisible&&this.hide(!0),e.preventDefault()},onTabKey(e,t=!1){t||(this.overlayVisible&&this.hasFocusableElements()?(F.focus(e.shiftKey?this.$refs.lastHiddenFocusableElementOnOverlay:this.$refs.firstHiddenFocusableElementOnOverlay),e.preventDefault()):(this.focusedOptionIndex!==-1&&this.onOptionSelect(e,this.visibleOptions[this.focusedOptionIndex]),this.overlayVisible&&this.hide(this.filter)))},onShiftKey(){this.startRangeIndex=this.focusedOptionIndex},onOverlayEnter(e){He.set("overlay",e,this.$primevue.config.zIndex.overlay),this.alignOverlay(),this.scrollInView(),this.autoFilterFocus&&F.focus(this.$refs.filterInput)},onOverlayAfterEnter(){this.bindOutsideClickListener(),this.bindScrollListener(),this.bindResizeListener(),this.$emit("show")},onOverlayLeave(){this.unbindOutsideClickListener(),this.unbindScrollListener(),this.unbindResizeListener(),this.$emit("hide"),this.overlay=null},onOverlayAfterLeave(e){He.clear(e)},alignOverlay(){this.appendTo==="self"?F.relativePosition(this.overlay,this.$el):(this.overlay.style.minWidth=F.getOuterWidth(this.$el)+"px",F.absolutePosition(this.overlay,this.$el))},bindOutsideClickListener(){this.outsideClickListener||(this.outsideClickListener=e=>{this.overlayVisible&&this.isOutsideClicked(e)&&this.hide()},document.addEventListener("click",this.outsideClickListener))},unbindOutsideClickListener(){this.outsideClickListener&&(document.removeEventListener("click",this.outsideClickListener),this.outsideClickListener=null)},bindScrollListener(){this.scrollHandler||(this.scrollHandler=new kn(this.$refs.container,()=>{this.overlayVisible&&this.hide()})),this.scrollHandler.bindScrollListener()},unbindScrollListener(){this.scrollHandler&&this.scrollHandler.unbindScrollListener()},bindResizeListener(){this.resizeListener||(this.resizeListener=()=>{this.overlayVisible&&!F.isTouchDevice()&&this.hide()},window.addEventListener("resize",this.resizeListener))},unbindResizeListener(){this.resizeListener&&(window.removeEventListener("resize",this.resizeListener),this.resizeListener=null)},isOutsideClicked(e){return!(this.$el.isSameNode(e.target)||this.$el.contains(e.target)||this.overlay&&this.overlay.contains(e.target))},getLabelByValue(e){const n=(this.optionGroupLabel?this.flatOptions(this.options):this.options||[]).find(i=>!this.isOptionGroup(i)&&ve.equals(this.getOptionValue(i),e,this.equalityKey));return n?this.getOptionLabel(n):null},getSelectedItemsLabel(){let e=/{(.*?)}/;return e.test(this.selectedItemsLabel)?this.selectedItemsLabel.replace(this.selectedItemsLabel.match(e)[0],this.modelValue.length+""):this.selectedItemsLabel},onToggleAll(e){if(this.selectAll!==null)this.$emit("selectall-change",{originalEvent:e,checked:!this.allSelected});else{const t=this.allSelected?[]:this.visibleOptions.filter(n=>this.isValidOption(n)).map(n=>this.getOptionValue(n));this.updateModel(e,t)}this.headerCheckboxFocused=!0},removeOption(e,t){let n=this.modelValue.filter(i=>!ve.equals(i,t,this.equalityKey));this.updateModel(e,n)},clearFilter(){this.filterValue=null},hasFocusableElements(){return F.getFocusableElements(this.overlay,":not(.p-hidden-focusable)").length>0},isOptionMatched(e){return this.isValidOption(e)&&this.getOptionLabel(e).toLocaleLowerCase(this.filterLocale).startsWith(this.searchValue.toLocaleLowerCase(this.filterLocale))},isValidOption(e){return e&&!(this.isOptionDisabled(e)||this.isOptionGroup(e))},isValidSelectedOption(e){return this.isValidOption(e)&&this.isSelected(e)},isSelected(e){const t=this.getOptionValue(e);return(this.modelValue||[]).some(n=>ve.equals(n,t,this.equalityKey))},findFirstOptionIndex(){return this.visibleOptions.findIndex(e=>this.isValidOption(e))},findLastOptionIndex(){return ve.findLastIndex(this.visibleOptions,e=>this.isValidOption(e))},findNextOptionIndex(e){const t=e<this.visibleOptions.length-1?this.visibleOptions.slice(e+1).findIndex(n=>this.isValidOption(n)):-1;return t>-1?t+e+1:e},findPrevOptionIndex(e){const t=e>0?ve.findLastIndex(this.visibleOptions.slice(0,e),n=>this.isValidOption(n)):-1;return t>-1?t:e},findFirstSelectedOptionIndex(){return this.hasSelectedOption?this.visibleOptions.findIndex(e=>this.isValidSelectedOption(e)):-1},findLastSelectedOptionIndex(){return this.hasSelectedOption?ve.findLastIndex(this.visibleOptions,e=>this.isValidSelectedOption(e)):-1},findNextSelectedOptionIndex(e){const t=this.hasSelectedOption&&e<this.visibleOptions.length-1?this.visibleOptions.slice(e+1).findIndex(n=>this.isValidSelectedOption(n)):-1;return t>-1?t+e+1:-1},findPrevSelectedOptionIndex(e){const t=this.hasSelectedOption&&e>0?ve.findLastIndex(this.visibleOptions.slice(0,e),n=>this.isValidSelectedOption(n)):-1;return t>-1?t:-1},findNearestSelectedOptionIndex(e,t=!1){let n=-1;return this.hasSelectedOption&&(t?(n=this.findPrevSelectedOptionIndex(e),n=n===-1?this.findNextSelectedOptionIndex(e):n):(n=this.findNextSelectedOptionIndex(e),n=n===-1?this.findPrevSelectedOptionIndex(e):n)),n>-1?n:e},findFirstFocusedOptionIndex(){const e=this.findFirstSelectedOptionIndex();return e<0?this.findFirstOptionIndex():e},findLastFocusedOptionIndex(){const e=this.findLastSelectedOptionIndex();return e<0?this.findLastOptionIndex():e},searchOptions(e){this.searchValue=(this.searchValue||"")+e.key;let t=-1;this.focusedOptionIndex!==-1?(t=this.visibleOptions.slice(this.focusedOptionIndex).findIndex(n=>this.isOptionMatched(n)),t=t===-1?this.visibleOptions.slice(0,this.focusedOptionIndex).findIndex(n=>this.isOptionMatched(n)):t+this.focusedOptionIndex):t=this.visibleOptions.findIndex(n=>this.isOptionMatched(n)),t===-1&&this.focusedOptionIndex===-1&&(t=this.findFirstFocusedOptionIndex()),t!==-1&&this.changeFocusedOptionIndex(e,t),this.searchTimeout&&clearTimeout(this.searchTimeout),this.searchTimeout=setTimeout(()=>{this.searchValue="",this.searchTimeout=null},500)},changeFocusedOptionIndex(e,t){this.focusedOptionIndex!==t&&(this.focusedOptionIndex=t,this.scrollInView())},scrollInView(e=-1){const t=e!==-1?`${this.id}_${e}`:this.focusedOptionId,n=F.findSingle(this.list,`li[id="${t}"]`);n?n.scrollIntoView&&n.scrollIntoView({block:"nearest",inline:"nearest"}):this.virtualScrollerDisabled||this.virtualScroller&&this.virtualScroller.scrollToIndex(e!==-1?e:this.focusedOptionIndex)},autoUpdateModel(){if(this.selectOnFocus&&this.autoOptionFocus&&!this.hasSelectedOption){this.focusedOptionIndex=this.findFirstFocusedOptionIndex();const e=this.getOptionValue(this.visibleOptions[this.focusedOptionIndex]);this.updateModel(null,[e])}},updateModel(e,t){this.$emit("update:modelValue",t),this.$emit("change",{originalEvent:e,value:t})},flatOptions(e){return(e||[]).reduce((t,n,i)=>{t.push({optionGroup:n,group:!0,index:i});const r=this.getOptionGroupChildren(n);return r&&r.forEach(s=>t.push(s)),t},[])},overlayRef(e){this.overlay=e},listRef(e,t){this.list=e,t&&t(e)},virtualScrollerRef(e){this.virtualScroller=e}},computed:{containerClass(){return["p-multiselect p-component p-inputwrapper",{"p-multiselect-chip":this.display==="chip","p-disabled":this.disabled,"p-focus":this.focused,"p-inputwrapper-filled":this.modelValue&&this.modelValue.length,"p-inputwrapper-focus":this.focused||this.overlayVisible,"p-overlay-open":this.overlayVisible}]},labelClass(){return["p-multiselect-label",{"p-placeholder":this.label===this.placeholder,"p-multiselect-label-empty":!this.placeholder&&(!this.modelValue||this.modelValue.length===0)}]},panelStyleClass(){return["p-multiselect-panel p-component",this.panelClass,{"p-input-filled":this.$primevue.config.inputStyle==="filled","p-ripple-disabled":this.$primevue.config.ripple===!1}]},headerCheckboxClass(){return["p-checkbox p-component",{"p-checkbox-checked":this.allSelected,"p-checkbox-focused":this.headerCheckboxFocused}]},visibleOptions(){const e=this.optionGroupLabel?this.flatOptions(this.options):this.options||[];if(this.filterValue){const t=wr.filter(e,this.searchFields,this.filterValue,this.filterMatchMode,this.filterLocale);if(this.optionGroupLabel){const n=this.options||[],i=[];
2120return n.forEach(r=>{const a=this.getOptionGroupChildren(r).filter(o=>t.includes(o));a.length>0&&i.push({...r,[typeof this.optionGroupChildren=="string"?this.optionGroupChildren:"items"]:[...a]})}),this.flatOptions(i)}return t}return e},label(){let e;if(this.modelValue&&this.modelValue.length){if(ve.isNotEmpty(this.maxSelectedLabels)&&this.modelValue.length>this.maxSelectedLabels)return this.getSelectedItemsLabel();e="";for(let t=0;t<this.modelValue.length;t++)t!==0&&(e+=", "),e+=this.getLabelByValue(this.modelValue[t])}else e=this.placeholder;return e},chipSelectedItems(){return ve.isNotEmpty(this.maxSelectedLabels)&&this.modelValue&&this.modelValue.length>this.maxSelectedLabels?this.modelValue.slice(0,this.maxSelectedLabels):this.modelValue},allSelected(){return this.selectAll!==null?this.selectAll:ve.isNotEmpty(this.visibleOptions)&&this.visibleOptions.every(e=>this.isOptionGroup(e)||this.isOptionDisabled(e)||this.isSelected(e))},hasSelectedOption(){return ve.isNotEmpty(this.modelValue)},equalityKey(){return this.optionValue?null:this.dataKey},searchFields(){return this.filterFields||[this.optionLabel]},maxSelectionLimitReached(){return this.selectionLimit&&this.modelValue&&this.modelValue.length===this.selectionLimit},filterResultMessageText(){return ve.isNotEmpty(this.visibleOptions)?this.filterMessageText.replaceAll("{0}",this.visibleOptions.length):this.emptyFilterMessageText},filterMessageText(){return this.filterMessage||this.$primevue.config.locale.searchMessage||""},emptyFilterMessageText(){return this.emptyFilterMessage||this.$primevue.config.locale.emptySearchMessage||this.$primevue.config.locale.emptyFilterMessage||""},emptyMessageText(){return this.emptyMessage||this.$primevue.config.locale.emptyMessage||""},selectionMessageText(){return this.selectionMessage||this.$primevue.config.locale.selectionMessage||""},emptySelectionMessageText(){return this.emptySelectionMessage||this.$primevue.config.locale.emptySelectionMessage||""},selectedMessageText(){return this.hasSelectedOption?this.selectionMessageText.replaceAll("{0}",this.modelValue.length):this.emptySelectionMessageText},focusedOptionId(){return this.focusedOptionIndex!==-1?`${this.id}_${this.focusedOptionIndex}`:null},ariaSetSize(){return this.visibleOptions.filter(e=>!this.isOptionGroup(e)).length},toggleAllAriaLabel(){return this.$primevue.config.locale.aria?this.$primevue.config.locale.aria[this.allSelected?"selectAll":"unselectAll"]:void 0},closeAriaLabel(){return this.$primevue.config.locale.aria?this.$primevue.config.locale.aria.close:void 0},virtualScrollerDisabled(){return!this.virtualScrollerOptions}},directives:{ripple:gt},components:{VirtualScroller:Li,Portal:Kt,TimesIcon:Qt,SearchIcon:Mm,TimesCircleIcon:ds,ChevronDownIcon:_n,SpinnerIcon:ps,CheckIcon:yn}};const sN=["id","disabled","placeholder","tabindex","aria-label","aria-labelledby","aria-expanded","aria-controls","aria-activedescendant"],iN=["onClick"],rN=["checked","aria-label"],aN=["value","placeholder","aria-owns","aria-activedescendant"],oN=["aria-label"],lN=["id"],cN=["id"],dN=["id","aria-label","aria-selected","aria-disabled","aria-setsize","aria-posinset","onClick","onMousemove"];function uN(e,t,n,i,r,s){const a=le("TimesCircleIcon"),o=le("SpinnerIcon"),l=le("VirtualScroller"),c=le("Portal"),d=Xe("ripple");return g(),S("div",R({ref:"container",class:s.containerClass,onClick:t[15]||(t[15]=(...u)=>s.onContainerClick&&s.onContainerClick(...u))},e.ptm("root")),[f("div",R({class:"p-hidden-accessible"},e.ptm("hiddenInputWrapper")),[f("input",R({ref:"focusInput",id:n.inputId,type:"text",readonly:"",disabled:n.disabled,placeholder:n.placeholder,tabindex:n.disabled?-1:n.tabindex,role:"combobox","aria-label":e.ariaLabel,"aria-labelledby":e.ariaLabelledby,"aria-haspopup":"listbox","aria-expanded":r.overlayVisible,"aria-controls":r.id+"_list","aria-activedescendant":r.focused?s.focusedOptionId:void 0,onFocus:t[0]||(t[0]=(...u)=>s.onFocus&&s.onFocus(...u)),onBlur:t[1]||(t[1]=(...u)=>s.onBlur&&s.onBlur(...u)),onKeydown:t[2]||(t[2]=(...u)=>s.onKeyDown&&s.onKeyDown(...u))},{...n.inputProps,...e.ptm("input")}),null,16,sN)],16),f("div",R({class:"p-multiselect-label-container"},e.ptm("labelContainer")),[f("div",R({class:s.labelClass},e.ptm("label")),[he(e.$slots,"value",{value:n.modelValue,placeholder:n.placeholder},()=>[n.display==="comma"?(g(),S(J,{key:0},[ke(N(s.label||"empty"),1)],64)):n.display==="chip"?(g(),S(J,{key:1},[(g(!0),S(J,null,ye(s.chipSelectedItems,u=>(g(),S("div",R({key:s.getLabelByValue(u),class:"p-multiselect-token"},e.ptm("token")),[he(e.$slots,"chip",{value:u},()=>[f("span",R({class:"p-multiselect-token-label"},e.ptm("tokenLabel")),N(s.getLabelByValue(u)),17)]),n.disabled?M("",!0):he(e.$slots,"removetokenicon",{key:0,class:"p-multiselect-token-icon",onClick:p=>s.removeOption(p,u)},()=>[n.removeTokenIcon?(g(),S("span",R({key:0,class:["p-multiselect-token-icon",n.removeTokenIcon],onClick:st(p=>s.removeOption(p,u),["stop"])},e.ptm("removeTokenIcon")),null,16,iN)):(g(),Q(a,R({key:1,class:"p-multiselect-token-icon",onClick:st(p=>s.removeOption(p,u),["stop"])},e.ptm("removeTokenIcon")),null,16,["onClick"]))])],16))),128)),!n.modelValue||n.modelValue.length===0?(g(),S(J,{key:0},[ke(N(n.placeholder||"empty"),1)],64)):M("",!0)],64)):M("",!0)])],16)],16),f("div",R({class:"p-multiselect-trigger"},e.ptm("trigger")),[n.loading?he(e.$slots,"loadingicon",{key:0,class:"p-multiselect-trigger-icon"},()=>[n.loadingIcon?(g(),S("span",R({key:0,class:["p-multiselect-trigger-icon pi-spin",n.loadingIcon],"aria-hidden":"true"},e.ptm("triggerIcon")),null,16)):(g(),Q(o,R({key:1,class:"p-multiselect-trigger-icon",spin:"","aria-hidden":"true"},e.ptm("triggerIcon")),null,16))]):he(e.$slots,"dropdownicon",{key:1,class:"p-multiselect-trigger-icon"},()=>[(g(),Q(_e(n.dropdownIcon?"span":"ChevronDownIcon"),R({class:["p-multiselect-trigger-icon",n.dropdownIcon],"aria-hidden":"true"},e.ptm("dropdownIcon")),null,16,["class"]))])],16),de(c,{appendTo:n.appendTo},{default:Ee(()=>[de($t,{name:"p-connected-overlay",onEnter:s.onOverlayEnter,onAfterEnter:s.onOverlayAfterEnter,onLeave:s.onOverlayLeave,onAfterLeave:s.onOverlayAfterLeave},{default:Ee(()=>[r.overlayVisible?(g(),S("div",R({key:0,ref:s.overlayRef,style:n.panelStyle,class:s.panelStyleClass,onClick:t[13]||(t[13]=(...u)=>s.onOverlayClick&&s.onOverlayClick(...u)),onKeydown:t[14]||(t[14]=(...u)=>s.onOverlayKeyDown&&s.onOverlayKeyDown(...u))},{...n.panelProps,...e.ptm("panel")}),[f("span",R({ref:"firstHiddenFocusableElementOnOverlay",role:"presentation","aria-hidden":"true",class:"p-hidden-accessible p-hidden-focusable",tabindex:0,onFocus:t[3]||(t[3]=(...u)=>s.onFirstHiddenFocus&&s.onFirstHiddenFocus(...u))},e.ptm("hiddenFirstFocusableEl")),null,16),he(e.$slots,"header",{value:n.modelValue,options:s.visibleOptions}),n.showToggleAll&&n.selectionLimit==null||n.filter?(g(),S("div",R({key:0,class:"p-multiselect-header"},e.ptm("header")),[n.showToggleAll&&n.selectionLimit==null?(g(),S("div",R({key:0,class:s.headerCheckboxClass,onClick:t[6]||(t[6]=(...u)=>s.onToggleAll&&s.onToggleAll(...u))},e.ptm("headerCheckboxContainer")),[f("div",R({class:"p-hidden-accessible"},e.ptm("hiddenInputWrapper")),[f("input",R({type:"checkbox",readonly:"",checked:s.allSelected,"aria-label":s.toggleAllAriaLabel,onFocus:t[4]||(t[4]=(...u)=>s.onHeaderCheckboxFocus&&s.onHeaderCheckboxFocus(...u)),onBlur:t[5]||(t[5]=(...u)=>s.onHeaderCheckboxBlur&&s.onHeaderCheckboxBlur(...u))},e.ptm("headerCheckbox")),null,16,rN)],16),f("div",R({class:["p-checkbox-box",{"p-highlight":s.allSelected,"p-focus":r.headerCheckboxFocused}]},s.getHeaderCheckboxPTOptions("headerCheckbox")),[he(e.$slots,"headercheckboxicon",{allSelected:s.allSelected,class:"p-checkbox-icon"}
2120,()=>[(g(),Q(_e(n.checkboxIcon?"span":"CheckIcon"),R({class:["p-checkbox-icon",{[n.checkboxIcon]:s.allSelected}]},s.getHeaderCheckboxPTOptions("headerCheckboxIcon")),null,16,["class"]))])],16)],16)):M("",!0),n.filter?(g(),S("div",R({key:1,class:"p-multiselect-filter-container"},e.ptm("filterContainer")),[f("input",R({ref:"filterInput",type:"text",value:r.filterValue,onVnodeMounted:t[7]||(t[7]=(...u)=>s.onFilterUpdated&&s.onFilterUpdated(...u)),class:"p-multiselect-filter p-inputtext p-component",placeholder:n.filterPlaceholder,role:"searchbox",autocomplete:"off","aria-owns":r.id+"_list","aria-activedescendant":s.focusedOptionId,onKeydown:t[8]||(t[8]=(...u)=>s.onFilterKeyDown&&s.onFilterKeyDown(...u)),onBlur:t[9]||(t[9]=(...u)=>s.onFilterBlur&&s.onFilterBlur(...u)),onInput:t[10]||(t[10]=(...u)=>s.onFilterChange&&s.onFilterChange(...u))},{...n.filterInputProps,...e.ptm("filterInput")}),null,16,aN),he(e.$slots,"filtericon",{class:"p-multiselect-filter-icon"},()=>[(g(),Q(_e(n.filterIcon?"span":"SearchIcon"),R({class:["p-multiselect-filter-icon",n.filterIcon]},e.ptm("filterIcon")),null,16,["class"]))])],16)):M("",!0),n.filter?(g(),S("span",R({key:2,role:"status","aria-live":"polite",class:"p-hidden-accessible"},e.ptm("hiddenFilterResult")),N(s.filterResultMessageText),17)):M("",!0),Ne((g(),S("button",R({class:"p-multiselect-close p-link","aria-label":s.closeAriaLabel,onClick:t[11]||(t[11]=(...u)=>s.onCloseClick&&s.onCloseClick(...u)),type:"button"},{...n.closeButtonProps,...e.ptm("closeButton")}),[he(e.$slots,"closeicon",{class:"p-multiselect-close-icon"},()=>[(g(),Q(_e(n.closeIcon?"span":"TimesIcon"),R({class:["p-multiselect-close-icon",n.closeIcon]},e.ptm("closeIcon")),null,16,["class"]))])],16,oN)),[[d]])],16)):M("",!0),f("div",R({class:"p-multiselect-items-wrapper",style:{"max-height":s.virtualScrollerDisabled?n.scrollHeight:""}},e.ptm("wrapper")),[de(l,R({ref:s.virtualScrollerRef},{...n.virtualScrollerOptions,...e.ptm("virtualScroller")},{items:s.visibleOptions,style:{height:n.scrollHeight},tabindex:-1,disabled:s.virtualScrollerDisabled}),ii({content:Ee(({styleClass:u,contentRef:p,items:h,getItemOptions:m,contentStyle:v,itemSize:_})=>[f("ul",R({ref:b=>s.listRef(b,p),id:r.id+"_list",class:["p-multiselect-items p-component",u],style:v,role:"listbox","aria-multiselectable":"true"},e.ptm("list")),[(g(!0),S(J,null,ye(h,(b,w)=>(g(),S(J,{key:s.getOptionRenderKey(b,s.getOptionIndex(w,m))},[s.isOptionGroup(b)?(g(),S("li",R({key:0,id:r.id+"_"+s.getOptionIndex(w,m),style:{height:_?_+"px":void 0},class:"p-multiselect-item-group",role:"option"},e.ptm("itemGroup")),[he(e.$slots,"optiongroup",{option:b.optionGroup,index:s.getOptionIndex(w,m)},()=>[ke(N(s.getOptionGroupLabel(b.optionGroup)),1)])],16,cN)):Ne((g(),S("li",R({key:1,id:r.id+"_"+s.getOptionIndex(w,m),style:{height:_?_+"px":void 0},class:["p-multiselect-item",{"p-highlight":s.isSelected(b),"p-focus":r.focusedOptionIndex===s.getOptionIndex(w,m),"p-disabled":s.isOptionDisabled(b)}],role:"option","aria-label":s.getOptionLabel(b),"aria-selected":s.isSelected(b),"aria-disabled":s.isOptionDisabled(b),"aria-setsize":s.ariaSetSize,"aria-posinset":s.getAriaPosInset(s.getOptionIndex(w,m)),onClick:C=>s.onOptionSelect(C,b,s.getOptionIndex(w,m),!0),onMousemove:C=>s.onOptionMouseMove(C,s.getOptionIndex(w,m))},s.getCheckboxPTOptions(b,m,w,"item")),[f("div",R({class:"p-checkbox p-component"},e.ptm("checkboxContainer")),[f("div",R({class:["p-checkbox-box",{"p-highlight":s.isSelected(b)}]},s.getCheckboxPTOptions(b,m,w,"checkbox")),[he(e.$slots,"itemcheckboxicon",{selected:s.isSelected(b),class:"p-checkbox-icon"},()=>[(g(),Q(_e(n.checkboxIcon?"span":"CheckIcon"),R({class:["p-checkbox-icon",{[n.checkboxIcon]:s.isSelected(b)}]},s.getCheckboxPTOptions(b,m,w,"checkboxIcon")),null,16,["class"]))])],16)],16),he(e.$slots,"option",{option:b,index:s.getOptionIndex(w,m)},()=>[f("span",ft(Tt(e.ptm("option"))),N(s.getOptionLabel(b)),17)])],16,dN)),[[d]])],64))),128)),r.filterValue&&(!h||h&&h.length===0)?(g(),S("li",R({key:0,class:"p-multiselect-empty-message",role:"option"},e.ptm("emptyMessage")),[he(e.$slots,"emptyfilter",{},()=>[ke(N(s.emptyFilterMessageText),1)])],16)):!n.options||n.options&&n.options.length===0?(g(),S("li",R({key:1,class:"p-multiselect-empty-message",role:"option"},e.ptm("emptyMessage")),[he(e.$slots,"empty",{},()=>[ke(N(s.emptyMessageText),1)])],16)):M("",!0)],16,lN)]),_:2},[e.$slots.loader?{name:"loader",fn:Ee(({options:u})=>[he(e.$slots,"loader",{options:u})]),key:"0"}:void 0]),1040,["items","style","disabled"])],16),he(e.$slots,"footer",{value:n.modelValue,options:s.visibleOptions}),!n.options||n.options&&n.options.length===0?(g(),S("span",R({key:1,role:"status","aria-live":"polite",class:"p-hidden-accessible"},e.ptm("emptyMessage")),N(s.emptyMessageText),17)):M("",!0),f("span",R({role:"status","aria-live":"polite",class:"p-hidden-accessible"},e.ptm("hiddenSelectedMessage")),N(s.selectedMessageText),17),f("span",R({ref:"lastHiddenFocusableElementOnOverlay",role:"presentation","aria-hidden":"true",class:"p-hidden-accessible p-hidden-focusable",tabindex:0,onFocus:t[12]||(t[12]=(...u)=>s.onLastHiddenFocus&&s.onLastHiddenFocus(...u))},e.ptm("hiddenLastFocusableEl")),null,16)],16)):M("",!0)]),_:3},8,["onEnter","onAfterEnter","onLeave","onAfterLeave"])]),_:3},8,["appendTo"])],16)}function hN(e,t){t===void 0&&(t={});var n=t.insertAt;if(!(typeof document>"u")){var i=document.head||document.getElementsByTagName("head")[0],r=document.createElement("style");r.type="text/css",n==="top"&&i.firstChild?i.insertBefore(r,i.firstChild):i.appendChild(r),r.styleSheet?r.styleSheet.cssText=e:r.appendChild(document.createTextNode(e))}}var pN=`
2121.p-multiselect {
2122    display: inline-flex;
2123    cursor: pointer;
2124    position: relative;
2125    user-select: none;
2126}
2127.p-multiselect-trigger {
2128    display: flex;
2129    align-items: center;
2130    justify-content: center;
2131    flex-shrink: 0;
2132}
2133.p-multiselect-label-container {
2134    overflow: hidden;
2135    flex: 1 1 auto;
2136    cursor: pointer;
2137}
2138.p-multiselect-label {
2139    display: block;
2140    white-space: nowrap;
2141    cursor: pointer;
2142    overflow: hidden;
2143    text-overflow: ellipsis;
2144}
2145.p-multiselect-label-empty {
2146    overflow: hidden;
2147    visibility: hidden;
2148}
2149.p-multiselect-token {
2150    cursor: default;
2151    display: inline-flex;
2152    align-items: center;
2153    flex: 0 0 auto;
2154}
2155.p-multiselect-token-icon {
2156    cursor: pointer;
2157}
2158.p-multiselect .p-multiselect-panel {
2159    min-width: 100%;
2160}
2161.p-multiselect-panel {
2162    position: absolute;
2163    top: 0;
2164    left: 0;
2165}
2166.p-multiselect-items-wrapper {
2167    overflow: auto;
2168}
2169.p-multiselect-items {
2170    margin: 0;
2171    padding: 0;
2172    list-style-type: none;
2173}
2174.p-multiselect-item {
2175    cursor: pointer;
2176    display: flex;
2177    align-items: center;
2178    font-weight: normal;
2179    white-space: nowrap;
2180    position: relative;
2181    overflow: hidden;
2182}
2183.p-multiselect-item-group {
2184    cursor: auto;
2185}
2186.p-multiselect-header {
2187    display: flex;
2188    align-items: center;
2189    justify-content: space-between;
2190}
2191.p-multiselect-filter-container {
2192    position: relative;
2193    flex: 1 1 auto;
2194}
2195.p-multiselect-filter-icon {
2196    position: absolute;
2197    top: 50%;
2198    margin-top: -0.5rem;
2199}
2200.p-multiselect-filter-container .p-inputtext {
2201    width: 100%;
2202}
2203.p-multiselect-close {
2204    display: flex;
2205    align-items: center;
2206    justify-content: center;
2207    flex-shrink: 0;
2208    overflow: hidden;
2209    position: relative;
2210    margin-left: auto;
2211}
2212.p-fluid .p-multiselect {
2213    display: flex;
2214}
2215`;hN(pN);Fm.render=uN;var Vm={name:"Slider",extends:Ve,emits:["update:modelValue","change","slideend"],props:{modelValue:[Number,Array],min:{type:Number,default:0},max:{type:Number,default:100},orientation:{type:String,default:"horizontal"},step:{type:Number,default:null},range:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},tabindex:{type:Number,default:0},"aria-labelledby":{type:String,default:null},"aria-label":{type:String,default:null}},dragging:!1,handleIndex:null,initX:null,initY:null,barWidth:null,barHeight:null,dragListener:null,dragEndListener:null,beforeUnmount(){this.unbindDragListeners()},methods:{updateDomData(){let e=this.$el.getBoundingClientRect();this.initX=e.left+F.getWindowScrollLeft(),this.initY=e.top+F.getWindowScrollTop(),this.barWidth=this.$el.offsetWidth,this.barHeight=this.$el.offsetHeight},setValue(e){let t,n=e.touches?e.touches[0].pageX:e.pageX,i=e.touches?e.touches[0].pageY:e.pageY;this.orientation==="horizontal"?t=(n-this.initX)*100/this.barWidth:t=(this.initY+this.barHeight-i)*100/this.barHeight;let r=(this.max-this.min)*(t/100)+this.min;if(this.step){const s=this.range?this.modelValue[this.handleIndex]:this.modelValue,a=r-s;a<0?r=s+Math.ceil(r/this.step-s/this.step)*this.step:a>0&&(r=s+Math.floor(r/this.step-s/this.step)*this.step)}else r=Math.floor(r);this.updateModel(e,r)},updateModel(e,t){let n=parseFloat(t.toFixed(10)),i;this.range?(i=this.modelValue?[...this.modelValue]:[],this.handleIndex==0?(n<this.min?n=this.min:n>=this.max&&(n=this.max),i[0]=n):(n>this.max?n=this.max:n<=this.min&&(n=this.min),i[1]=n)):(n<this.min?n=this.min:n>this.max&&(n=this.max),i=n),this.$emit("update:modelValue",i),this.$emit("change",i
2215)},onDragStart(e,t){this.disabled||(F.addClass(this.$el,"p-slider-sliding"),this.dragging=!0,this.updateDomData(),this.range&&this.modelValue[0]===this.max?this.handleIndex=0:this.handleIndex=t,e.currentTarget.focus(),e.preventDefault())},onDrag(e){this.dragging&&(this.setValue(e),e.preventDefault())},onDragEnd(e){this.dragging&&(this.dragging=!1,F.removeClass(this.$el,"p-slider-sliding"),this.$emit("slideend",{originalEvent:e,value:this.modelValue}))},onBarClick(e){this.disabled||F.hasClass(e.target,"p-slider-handle")||(this.updateDomData(),this.setValue(e))},onMouseDown(e,t){this.bindDragListeners(),this.onDragStart(e,t)},onKeyDown(e,t){switch(this.handleIndex=t,e.code){case"ArrowDown":case"ArrowLeft":this.decrementValue(e,t),e.preventDefault();break;case"ArrowUp":case"ArrowRight":this.incrementValue(e,t),e.preventDefault();break;case"PageDown":this.decrementValue(e,t,!0),e.preventDefault();break;case"PageUp":this.incrementValue(e,t,!0),e.preventDefault();break;case"Home":this.updateModel(e,this.min),e.preventDefault();break;case"End":this.updateModel(e,this.max),e.preventDefault();break}},decrementValue(e,t,n=!1){let i;this.range?this.step?i=this.modelValue[t]-this.step:i=this.modelValue[t]-1:this.step?i=this.modelValue-this.step:!this.step&&n?i=this.modelValue-10:i=this.modelValue-1,this.updateModel(e,i),e.preventDefault()},incrementValue(e,t,n=!1){let i;this.range?this.step?i=this.modelValue[t]+this.step:i=this.modelValue[t]+1:this.step?i=this.modelValue+this.step:!this.step&&n?i=this.modelValue+10:i=this.modelValue+1,this.updateModel(e,i),e.preventDefault()},bindDragListeners(){this.dragListener||(this.dragListener=this.onDrag.bind(this),document.addEventListener("mousemove",this.dragListener)),this.dragEndListener||(this.dragEndListener=this.onDragEnd.bind(this),document.addEventListener("mouseup",this.dragEndListener))},unbindDragListeners(){this.dragListener&&(document.removeEventListener("mousemove",this.dragListener),this.dragListener=null),this.dragEndListener&&(document.removeEventListener("mouseup",this.dragEndListener),this.dragEndListener=null)}},computed:{containerClass(){return["p-slider p-component",{"p-disabled":this.disabled,"p-slider-horizontal":this.orientation==="horizontal","p-slider-vertical":this.orientation==="vertical"}]},horizontal(){return this.orientation==="horizontal"},vertical(){return this.orientation==="vertical"},rangeStyle(){if(this.range){const e=this.rangeEndPosition>this.rangeStartPosition?this.rangeEndPosition-this.rangeStartPosition:this.rangeStartPosition-this.rangeEndPosition,t=this.rangeEndPosition>this.rangeStartPosition?this.rangeStartPosition:this.rangeEndPosition;return this.horizontal?{left:t+"%",width:e+"%"}:{bottom:t+"%",height:e+"%"}}else return this.horizontal?{width:this.handlePosition+"%"}:{height:this.handlePosition+"%"}},handleStyle(){return this.horizontal?{left:this.handlePosition+"%"}:{bottom:this.handlePosition+"%"}},handlePosition(){return this.modelValue<this.min?0:this.modelValue>this.max?100:(this.modelValue-this.min)*100/(this.max-this.min)},rangeStartPosition(){return this.modelValue&&this.modelValue[0]?(this.modelValue[0]<this.min?0:this.modelValue[0]-this.min)*100/(this.max-this.min):0},rangeEndPosition(){return this.modelValue&&this.modelValue.length===2?(this.modelValue[1]>this.max?100:this.modelValue[1]-this.min)*100/(this.max-this.min):100},rangeStartHandleStyle(){return this.horizontal?{left:this.rangeStartPosition+"%"}:{bottom:this.rangeStartPosition+"%"}},rangeEndHandleStyle(){return this.horizontal?{left:this.rangeEndPosition+"%"}:{bottom:this.rangeEndPosition+"%"}}}};const fN=["tabindex","aria-valuemin","aria-valuenow","aria-valuemax","aria-labelledby","aria-label","aria-orientation"],mN=["tabindex","aria-valuemin","aria-valuenow","aria-valuemax","aria-labelledby","aria-label","aria-orientation"],gN=["tabindex","aria-valuemin","aria-valuenow","aria-valuemax","aria-labelledby","aria-label","aria-orientation"];function yN(e,t,n,i,r,s){return g(),S("div",R({class:s.containerClass,onClick:t[15]||(t[15]=(...a)=>s.onBarClick&&s.onBarClick(...a))},e.ptm("root")),[f("span",R({class:"p-slider-range",style:s.rangeStyle},e.ptm("range")),null,16),n.range?M("",!0):(g(),S("span",R({key:0,class:"p-slider-handle",style:s.handleStyle,onTouchstart:t[0]||(t[0]=a=>s.onDragStart(a)),onTouchmove:t[1]||(t[1]=a=>s.onDrag(a)),onTouchend:t[2]||(t[2]=a=>s.onDragEnd(a)),onMousedown:t[3]||(t[3]=a=>s.onMouseDown(a)),onKeydown:t[4]||(t[4]=a=>s.onKeyDown(a)),tabindex:n.tabindex,role:"slider","aria-valuemin":n.min,"aria-valuenow":n.modelValue,"aria-valuemax":n.max,"aria-labelledby":e.ariaLabelledby,"aria-label":e.ariaLabel,"aria-orientation":n.orientation},e.ptm("handle")),null,16,fN)),n.range?(g(),S("span",R({key:1,class:"p-slider-handle",style:s.rangeStartHandleStyle,onTouchstart:t[5]||(t[5]=a=>s.onDragStart(a,0)),onTouchmove:t[6]||(t[6]=a=>s.onDrag(a)),onTouchend:t[7]||(t[7]=a=>s.onDragEnd(a)),onMousedown:t[8]||(t[8]=a=>s.onMouseDown(a,0)),onKeydown:t[9]||(t[9]=a=>s.onKeyDown(a,0)),tabindex:n.tabindex,role:"slider","aria-valuemin":n.min,"aria-valuenow":n.modelValue?n.modelValue[0]:null,"aria-valuemax":n.max,"aria-labelledby":e.ariaLabelledby,"aria-label":e.ariaLabel,"aria-orientation":n.orientation},e.ptm("startHandler")),null,16,mN)):M("",!0),n.range?(g(),S("span",R({key:2,class:"p-slider-handle",style:s.rangeEndHandleStyle,onTouchstart:t[10]||(t[10]=a=>s.onDragStart(a,1)),onTouchmove:t[11]||(t[11]=a=>s.onDrag(a)),onTouchend:t[12]||(t[12]=a=>s.onDragEnd(a)),onMousedown:t[13]||(t[13]=a=>
2215s.onMouseDown(a,1)),onKeydown:t[14]||(t[14]=a=>s.onKeyDown(a,1)),tabindex:n.tabindex,role:"slider","aria-valuemin":n.min,"aria-valuenow":n.modelValue?n.modelValue[1]:null,"aria-valuemax":n.max,"aria-labelledby":e.ariaLabelledby,"aria-label":e.ariaLabel,"aria-orientation":n.orientation},e.ptm("endHandler")),null,16,gN)):M("",!0)],16)}function bN(e,t){t===void 0&&(t={});var n=t.insertAt;if(!(typeof document>"u")){var i=document.head||document.getElementsByTagName("head")[0],r=document.createElement("style");r.type="text/css",n==="top"&&i.firstChild?i.insertBefore(r,i.firstChild):i.appendChild(r),r.styleSheet?r.styleSheet.cssText=e:r.appendChild(document.createTextNode(e))}}var vN=`
2216.p-slider {
2217    position: relative;
2218}
2219.p-slider .p-slider-handle {
2220    position: absolute;
2221    cursor: grab;
2222    touch-action: none;
2223    display: block;
2224}
2225.p-slider-range {
2226    position: absolute;
2227    display: block;
2228}
2229.p-slider-horizontal .p-slider-range {
2230    top: 0;
2231    left: 0;
2232    height: 100%;
2233}
2234.p-slider-horizontal .p-slider-handle {
2235    top: 50%;
2236}
2237.p-slider-vertical {
2238    height: 100px;
2239}
2240.p-slider-vertical .p-slider-handle {
2241    left: 50%;
2242}
2243.p-slider-vertical .p-slider-range {
2244    bottom: 0;
2245    left: 0;
2246    width: 100%;
2247}
2248`;bN(vN);Vm.render=yN;var Bm={name:"Skeleton",extends:Ve,props:{shape:{type:String,default:"rectangle"},size:{type:String,default:null},width:{type:String,default:"100%"},height:{type:String,default:"1rem"},borderRadius:{type:String,default:null},animation:{type:String,default:"wave"}},computed:{containerClass(){return["p-skeleton p-component",{"p-skeleton-circle":this.shape==="circle","p-skeleton-none":this.animation==="none"}]},containerStyle(){return this.size?{width:this.size,height:this.size,borderRadius:this.borderRadius}:{width:this.width,height:this.height,borderRadius:this.borderRadius}}}};function _N(e,t,n,i,r,s){return g(),S("div",R({style:s.containerStyle,class:s.containerClass,"aria-hidden":"true"},e.ptm("root")),null,16)}function wN(e,t){t===void 0&&(t={});var n=t.insertAt;if(!(typeof document>"u")){var i=document.head||document.getElementsByTagName("head")[0],r=document.createElement("style");r.type="text/css",n==="top"&&i.firstChild?i.insertBefore(r,i.firstChild):i.appendChild(r),r.styleSheet?r.styleSheet.cssText=e:r.appendChild(document.createTextNode(e))}}var EN=`
2249.p-skeleton {
2250    position: relative;
2251    overflow: hidden;
2252}
2253.p-skeleton::after {
2254    content: '';
2255    animation: p-skeleton-animation 1.2s infinite;
2256    height: 100%;
2257    left: 0;
2258    position: absolute;
2259    right: 0;
2260    top: 0;
2261    transform: translateX(-100%);
2262    z-index: 1;
2263}
2264.p-skeleton.p-skeleton-circle {
2265    border-radius: 50%;
2266}
2267.p-skeleton-none::after {
2268    animation: none;
2269}
2270@keyframes p-skeleton-animation {
2271from {
2272        transform: translateX(-100%);
2273}
2274to {
2275        transform: translateX(100%);
2276}
2277}
2278`;wN(EN);Bm.render=_N;var $m={name:"Textarea",extends:Ve,emits:["update:modelValue"],props:{modelValue:null,autoResize:Boolean},mounted(){this.$el.offsetParent&&this.autoResize&&this.resize()},updated(){this.$el.offsetParent&&this.autoResize&&this.resize()},methods:{resize(){const e=window.getComputedStyle(this.$el);this.$el.style.height="auto",this.$el.style.height=`calc(${e.borderTopWidth} + ${e.borderBottomWidth} + ${this.$el.scrollHeight}px)`,parseFloat(this.$el.style.height)>=parseFloat(this.$el.style.maxHeight)?(this.$el.style.overflowY="scroll",this.$el.style.height=this.$el.style.maxHeight):this.$el.style.overflow="hidden"},onInput(e){this.autoResize&&this.resize(),this.$emit("update:modelValue",e.target.value)}},computed:{filled(){return this.modelValue!=null&&this.modelValue.toString().length>0}}};const SN=["value"];function CN(e,t,n,i,r,s){return g(),S("textarea",R({class:["p-inputtextarea p-inputtext p-component",{"p-filled":s.filled,"p-inputtextarea-resizable ":n.autoResize}],value:n.modelValue,onInput:t[0]||(t[0]=(...a)=>s.onInput&&s.onInput(...a))},e.ptm("root")),null,16,SN)}function IN(e,t){t===void 0&&(t={});var n=t.insertAt;if(!(typeof document>"u")){var i=document.head||document.getElementsByTagName("head")[0],r=document.createElement("style");r.type="text/css",n==="top"&&i.firstChild?i.insertBefore(r,i.firstChild):i.appendChild(r),r.styleSheet?r.styleSheet.cssText=e:r.appendChild(document.createTextNode(e))}}var TN=`
2279.p-inputtextarea-resizable {
2280    overflow: hidden;
2281    resize: none;
2282}
2283.p-fluid .p-inputtextarea {
2284    width: 100%;
2285}
2286`;IN(TN);$m.render=CN;var Um={name:"InputSwitch",extends:Ve,emits:["click","update:modelValue","change","input","focus","blur"],props:{modelValue:{type:null,default:!1},trueValue:{type:null,default:!0},falseValue:{type:null,default:!1},disabled:{type:Boolean,default:!1},inputId:{type:String,default:null},inputClass:{type:[String,Object],default:null},inputStyle:{type:Object,default:null},inputProps:{type:null,default:null},"aria-labelledby":{type:String,default:null},"aria-label":{type:String,default:null}},data(){return{focused:!1}},methods:{onClick(e){if(!this.disabled){const t=this.checked?this.falseValue:this.trueValue;this.$emit("click",e),this.$emit("update:modelValue",t),this.$emit("change",e),this.$emit("input",t),this.$refs.input.focus()}e.preventDefault()},onFocus(e){this.focused=!0,this.$emit("focus",e)},onBlur(e){this.focused=!1,this.$emit("blur",e)}},computed:{containerClass(){return["p-inputswitch p-component",{"p-inputswitch-checked":this.checked,"p-disabled":this.disabled,"p-focus":this.focused}]},checked(){return this.modelValue===this.trueValue}}};const PN=["id","checked","disabled","aria-checked","aria-labelledby","aria-label"];function ON(e,t,n,i,r,s){return g(),S("div",R({class:s.containerClass,onClick:t[2]||(t[2]=a=>s.onClick(a))},e.ptm("root")),[f("div",R({class:"p-hidden-accessible"},e.ptm("hiddenInputWrapper")),[f("input",R({ref:"input",id:n.inputId,type:"checkbox",role:"switch",class:n.inputClass,style:n.inputStyle,checked:s.checked,disabled:n.disabled,"aria-checked":s.checked,"aria-labelledby":e.ariaLabelledby,"aria-label":e.ariaLabel,onFocus:t[0]||(t[0]=a=>s.onFocus(a)),onBlur:t[1]||(t[1]=a=>s.onBlur(a))}
2286,e.ptm("hiddenInput")),null,16,PN)],16),f("span",R({class:"p-inputswitch-slider"},{...n.inputProps,...e.ptm("slider")}),null,16)],16)}function AN(e,t){t===void 0&&(t={});var n=t.insertAt;if(!(typeof document>"u")){var i=document.head||document.getElementsByTagName("head")[0],r=document.createElement("style");r.type="text/css",n==="top"&&i.firstChild?i.insertBefore(r,i.firstChild):i.appendChild(r),r.styleSheet?r.styleSheet.cssText=e:r.appendChild(document.createTextNode(e))}}var kN=`
2287.p-inputswitch {
2288    position: relative;
2289    display: inline-block;
2290}
2291.p-inputswitch-slider {
2292    position: absolute;
2293    cursor: pointer;
2294    top: 0;
2295    left: 0;
2296    right: 0;
2297    bottom: 0;
2298    border: 1px solid transparent;
2299}
2300.p-inputswitch-slider:before {
2301    position: absolute;
2302    content: '';
2303    top: 50%;
2304}
2305`;AN(kN);Um.render=ON;var Hm={name:"AutoComplete",extends:Ve,emits:["update:modelValue","change","focus","blur","item-select","item-unselect","dropdown-click","clear","complete","before-show","before-hide","show","hide"],props:{modelValue:null,suggestions:{type:Array,default:null},field:{type:[String,Function],default:null},optionLabel:null,optionDisabled:null,optionGroupLabel:null,optionGroupChildren:null,scrollHeight:{type:String,default:"200px"},dropdown:{type:Boolean,default:!1},dropdownMode:{type:String,default:"blank"},autoHighlight:{type:Boolean,default:!1},multiple:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},placeholder:{type:String,default:null},dataKey:{type:String,default:null},minLength:{type:Number,default:1},delay:{type:Number,default:300},appendTo:{type:String,default:"body"},forceSelection:{type:Boolean,default:!1},completeOnFocus:{type:Boolean,default:!1},inputId:{type:String,default:null},inputStyle:{type:Object,default:null},inputClass:{type:[String,Object],default:null},inputProps:{type:null,default:null},panelStyle:{type:Object,default:null},panelClass:{type:[String,Object],default:null},panelProps:{type:null,default:null},dropdownIcon:{type:String,default:void 0},dropdownClass:{type:[String,Object],default:null},loadingIcon:{type:String,default:void 0},removeTokenIcon:{type:String,default:void 0},virtualScrollerOptions:{type:Object,default:null},autoOptionFocus:{type:Boolean,default:!0},selectOnFocus:{type:Boolean,default:!1},searchLocale:{type:String,default:void 0},searchMessage:{type:String,default:null},selectionMessage:{type:String,default:null},emptySelectionMessage:{type:String,default:null},emptySearchMessage:{type:String,default:null},tabindex:{type:Number,default:0},"aria-label":{type:String,default:null},"aria-labelledby":{type:String,default:null}},outsideClickListener:null,resizeListener:null,scrollHandler:null,overlay:null,virtualScroller:null,searchTimeout:null,focusOnHover:!1,dirty:!1,data(){return{id:this.$attrs.id,focused:!1,focusedOptionIndex:-1,focusedMultipleOptionIndex:-1,overlayVisible:!1,searching:!1}},watch:{"$attrs.id":function(e){this.id=e||pt()},suggestions(){this.searching&&(ve.isNotEmpty(this.suggestions)?this.show():this.$slots.empty?this.show():this.hide(),this.focusedOptionIndex=this.overlayVisible&&this.autoOptionFocus?this.findFirstFocusedOptionIndex():-1,this.searching=!1),this.autoUpdateModel()}},mounted(){this.id=this.id||pt(),this.autoUpdateModel()},updated(){this.overlayVisible&&this.alignOverlay()},beforeUnmount(){this.unbindOutsideClickListener(),this.unbindResizeListener(),this.scrollHandler&&(this.scrollHandler.destroy(),this.scrollHandler=null),this.overlay&&(He.clear(this.overlay),this.overlay=null)},methods:{getOptionIndex(e,t){return this.virtualScrollerDisabled?e:t&&t(e).index},getOptionLabel(e){return this.field||this.optionLabel?ve.resolveFieldData(e,this.field||this.optionLabel):e},getOptionValue(e){return e},getOptionRenderKey(e,t){return(this.dataKey?ve.resolveFieldData(e,this.dataKey):this.getOptionLabel(e))+"_"+t},getPTOptions(e,t,n,i){return this.ptm(i,{context:{selected:this.isSelected(e),focused:this.focusedOptionIndex===this.getOptionIndex(n,t),disabled:this.isOptionDisabled(e)}})},isOptionDisabled(e){return this.optionDisabled?ve.resolveFieldData(e,this.optionDisabled):!1},isOptionGroup(e){return this.optionGroupLabel&&e.optionGroup&&e.group},getOptionGroupLabel(e){return ve.resolveFieldData(e,this.optionGroupLabel)},getOptionGroupChildren(e){return ve.resolveFieldData(e,this.optionGroupChildren)},getAriaPosInset(e){return(this.optionGroupLabel?e-this.visibleOptions.slice(0,e).filter(t=>this.isOptionGroup(t)).length:e)+1},show(e){this.$emit("before-show"),this.dirty=!0,this.overlayVisible=!0,this.focusedOptionIndex=this.focusedOptionIndex!==-1?this.focusedOptionIndex:this.autoOptionFocus?this.findFirstFocusedOptionIndex():-1,e&&F.focus(this.$refs.focusInput)},hide(e){const t=()=>{this.$emit("before-hide"),this.dirty=e,this.overlayVisible=!1,this.focusedOptionIndex=-1,e&&F.focus(this.$refs.focusInput)};setTimeout(()=>{t()},0)},onFocus(e){this.disabled||(!this.dirty&&this.completeOnFocus&&this.search(e,e.target.value,"focus"),this.dirty=!0,this.focused=!0,this.focusedOptionIndex=this.focusedOptionIndex!==-1?this.focusedOptionIndex:this.overlayVisible&&this.autoOptionFocus?this.findFirstFocusedOptionIndex():-1,this.overlayVisible&&this.scrollInView(this.focusedOptionIndex),this.$emit("focus",e))},onBlur(e){this.dirty=!1,this.focused=!1,this.focusedOptionIndex=-1,this.$emit("blur",e)},onKeyDown(e){if(this.disabled){e.preventDefault();return}switch(e.code){case"ArrowDown":this.onArrowDownKey(e);break;case"ArrowUp":this.onArrowUpKey(e);break;case"ArrowLeft":this.onArrowLeftKey(e);break;case"ArrowRight":this.onArrowRightKey(e);break;case"Home":this.onHomeKey(e);break;case"End":this.onEndKey(e);break;case"PageDown":this.onPageDownKey(e);break;case"PageUp":this.onPageUpKey(e);break;case"Enter":case"NumpadEnter":this.onEnterKey(e);break;case"Escape":this.onEscapeKey(e);break;case"Tab":this.onTabKey(e);break;case"Backspace":this.onBackspaceKey(e);break}},onInput(e){this.searchTimeout&&clearTimeout(this.searchTimeout);let t=e.target.value;this.multiple||this.updateModel(e,t),t.length===0?(this.hide(),this.$emit("clear")):t.length>=this.minLength?(this.focusedOptionIndex=-1,this.searchTimeout=setTimeout(()=>{this.search(e,t,"input")},this.delay)):this.hide()},onChange(e){if(this.forceSelection){let t=!1;if(this.visibleOptions){const n=this.visibleOptions.find(i=>this.isOptionMatched(i,this.$refs.focusInput.value||""));n!==void 0&&(t=!0,!this.isSelected(n)&&this.onOptionSelect(e,n))}t||(this.$refs.focusInput.value="",this.$emit("clear"),!this.multiple&&this.updateModel(e,null))}},onMultipleContainerFocus(){this.disabled||(this.focused=!0)},onMultipleContainerBlur(){this.focusedMultipleOptionIndex=-1,this.focused=!1},onMultipleContainerKeyDown(e){if(this.disabled){e.preventDefault();return}switch(e.code){case"ArrowLeft":this.onArrowLeftKeyOnMultiple(e);break;case"ArrowRight":this.onArrowRightKeyOnMultiple(e);break;case"Backspace":this.onBackspaceKeyOnMultiple(e);break}},onContainerClick(e){this.disabled||this.searching||this.isInputClicked(e)||this.isDropdownClicked(e)||(!this.overlay||!this.overlay.contains(e.target))&&F.focus(this.$refs.focusInput)},onDropdownClick(e){let t;this.overlayVisible?this.hide(!0):(F.focus(this.$refs.focusInput),t=this.$refs.focusInput.value,this.dropdownMode==="blank"?this.search(e,"","dropdown"):this.dropdownMode==="current"&&this.search(e,t,"dropdown")),this.$emit("dropdown-click",{originalEvent:e,query:t})},onOptionSelect(e,t,n=!0){const i=this.getOptionValue(t);this.multiple?(this.$refs.focusInput.value="",this.isSelected(t)||this.updateModel(e,[...this.modelValue||[],i])):this.updateModel(e,i),this.$emit("item-select",{originalEvent:e,value:t}),n&&this.hide(!0)},onOptionMouseMove(e,t){this.focusOnHover&&this.changeFocusedOptionIndex(e,t)},onOverlayClick(e){Mt.emit("overlay-click",{originalEvent:e,target:this.$el})},onOverlayKeyDown(e){switch(e.code){case"Escape":this.onEscapeKey(e);break}},onArrowDownKey(e){if(!this.overlayVisible)return;const t=this.focusedOptionIndex!==-1?this.findNextOptionIndex(this.focusedOptionIndex):this.findFirstFocusedOptionIndex();this.changeFocusedOptionIndex(e,t),e.preventDefault()},onArrowUpKey(e){if(this.overlayVisible)if(e.altKey)this.focusedOptionIndex!==-1&&this.onOptionSelect(e,this.visibleOptions[this.focusedOptionIndex]),this.overlayVisible&&this.hide(),e.preventDefault();else{const t=this.focusedOptionIndex!==-1?this.findPrevOptionIndex(this.focusedOptionIndex):this.findLastFocusedOptionIndex();this.changeFocusedOptionIndex(e,t),e.preventDefault()}},onArrowLeftKey(e){const t=e.currentTarget;this.focusedOptionIndex=-1,this.multiple&&(ve.isEmpty(t.value)&&this.hasSelectedOption?(F.focus(this.$refs.multiContainer),this.focusedMultipleOptionIndex=this.modelValue.length):e.stopPropagation())},onArrowRightKey(e){this.focusedOptionIndex=-1,this.multiple&&e.stopPropagation()},onHomeKey(e){const{currentTarget:t}=e,n=t.value.length;t.setSelectionRange(0,e.shiftKey?n:0),this.focusedOptionIndex=-1,e.preventDefault()},onEndKey(e){const{currentTarget:t}=e,n=t.value.length;t.setSelectionRange(e.shiftKey?0:n,n),this.focusedOptionIndex=-1,e.preventDefault()},onPageUpKey(e){this.scrollInView(0),e.preventDefault()},onPageDownKey(e){this.scrollInView(this.visibleOptions.length-1),e.preventDefault()},onEnterKey(e){this.overlayVisible?(this.focusedOptionIndex!==-1&&this.onOptionSelect(e,this.visibleOptions[this.focusedOptionIndex]),this.hide()):this.onArrowDownKey(e),e.preventDefault()},onEscapeKey(e){this.overlayVisible&&this.hide(!0),e.preventDefault()},onTabKey(e){this.focusedOptionIndex!==-1&&this.onOptionSelect(e,this.visibleOptions[this.focusedOptionIndex]),this.overlayVisible&&this.hide()},onBackspaceKey(e){if(this.multiple){if(ve.isNotEmpty(this.modelValue)&&!this.$refs.focusInput.value){const t=this.modelValue[this.modelValue.length-1],n=this.modelValue.slice(0,-1);this.$emit("update:modelValue",n),this.$emit("item-unselect",{originalEvent:e,value:t})}e.stopPropagation()}},onArrowLeftKeyOnMultiple(){this.focusedMultipleOptionIndex=this.focusedMultipleOptionIndex<1?0:this.focusedMultipleOptionIndex-1},onArrowRightKeyOnMultiple(){this.focusedMultipleOptionIndex++,this.focusedMultipleOptionIndex>this.modelValue.length-1&&(this.focusedMultipleOptionIndex=-1,F.focus(this.$refs.focusInput))},onBackspaceKeyOnMultiple(e){this.focusedMultipleOptionIndex!==-1&&this.removeOption(e,this.focusedMultipleOptionIndex)},onOverlayEnter(e){He.set("overlay",e,this.$primevue.config.zIndex.overlay),this.alignOverlay()},onOverlayAfterEnter(){this.bindOutsideClickListener(),this.bindScrollListener(),this.bindResizeListener(),this.$emit("show")},onOverlayLeave(){this.unbindOutsideClickListener(),this.unbindScrollListener(),this.unbindResizeListener(),this.$emit("hide"),this.overlay=null},onOverlayAfterLeave(e){He.clear(e)},alignOverlay(){let e=this.multiple?this.$refs.multiContainer:this.$refs.focusInput;this.appendTo==="self"?F.relativePosition(this.overlay,e):(this.overlay.style.minWidth=F.getOuterWidth(e)+"px",F.absolutePosition(this.overlay,e))},bindOutsideClickListener(){this.outsideClickListener||(this.outsideClickListener=e=>{this.overlayVisible&&this.overlay&&this.isOutsideClicked(e)&&this.hide()},document.addEventListener("click",this.outsideClickListener))},unbindOutsideClickListener(){this.outsideClickListener&&(document.removeEventListener("click",this.outsideClickListener),this.outsideClickListener=null)},bindScrollListener(){this.scrollHandler||(this.scrollHandler=new kn(this.$refs.container,()=>{this.overlayVisible&&this.hide()})),this.scrollHandler.bindScrollListener()},unbindScrollListener(){this.scrollHandler&&this.scrollHandler.unbindScrollListener()},bindResizeListener(){this.resizeListener||(this.resizeListener=()=>{this.overlayVisible&&!F.isTouchDevice()&&this.hide()},window.addEventListener("resize",this.resizeListener))},unbindResizeListener(){this.resizeListener&&(window.removeEventListener("resize",this.resizeListener),this.resizeListener=null)},isOutsideClicked(e){return!this.overlay.contains(e.target)&&!this.isInputClicked(e)&&!this.isDropdownClicked(e)},isInputClicked(e){return this.multiple?e.target===this.$refs.multiContainer||this.$refs.multiContainer.contains(e.target):e.target===this.$refs.focusInput},isDropdownClicked(e){return this.$refs.dropdownButton?e.target===this.$refs.dropdownButton||this.$refs.dropdownButton.$el.contains(e.target):!1},isOptionMatched(e,t){return this.isValidOption(e)&&this.getOptionLabel(e).toLocaleLowerCase(this.searchLocale)===t.toLocaleLowerCase(this.searchLocale)},isValidOption(e){return e&&!(this.isOptionDisabled(e)||this.isOptionGroup(e))},isValidSelectedOption(e){return this.isValidOption(e)&&this.isSelected(e)},isSelected(e){return ve.equals(this.modelValue,this.getOptionValue(e),this.equalityKey)},findFirstOptionIndex(){return this.visibleOptions.findIndex(e=>this.isValidOption(e))},findLastOptionIndex(){return ve.findLastIndex(this.visibleOptions,e=>this.isValidOption(e))},findNextOptionIndex(e){const t=e<this.visibleOptions.length-1?this.visibleOptions.slice(e+1).findIndex(n=>this.isValidOption(n)):-1;return t>-1?t+e+1:e},findPrevOptionIndex(e){const t=e>0?ve.findLastIndex(this.visibleOptions.slice(0,e),n=>this.isValidOption(n)):-1;return t>-1?t:e},findSelectedOptionIndex(){return this.hasSelectedOption?this.visibleOptions.findIndex(e=>this.isValidSelectedOption(e)):-1},findFirstFocusedOptionIndex(){const e=this.findSelectedOptionIndex();return e<0?this.findFirstOptionIndex():e},findLastFocusedOptionIndex(){const e=this.findSelectedOptionIndex();return e<0?this.findLastOptionIndex():e}
2305,search(e,t,n){t!=null&&(n==="input"&&t.trim().length===0||(this.searching=!0,this.$emit("complete",{originalEvent:e,query:t})))},removeOption(e,t){const n=this.modelValue[t],i=this.modelValue.filter((r,s)=>s!==t).map(r=>this.getOptionValue(r));this.updateModel(e,i),this.$emit("item-unselect",{originalEvent:e,value:n}),this.dirty=!0,F.focus(this.$refs.focusInput)},changeFocusedOptionIndex(e,t){this.focusedOptionIndex!==t&&(this.focusedOptionIndex=t,this.scrollInView(),(this.selectOnFocus||this.autoHighlight)&&this.onOptionSelect(e,this.visibleOptions[t],!1))},scrollInView(e=-1){const t=e!==-1?`${this.id}_${e}`:this.focusedOptionId,n=F.findSingle(this.list,`li[id="${t}"]`);n?n.scrollIntoView&&n.scrollIntoView({block:"nearest",inline:"start"}):this.virtualScrollerDisabled||setTimeout(()=>{this.virtualScroller&&this.virtualScroller.scrollToIndex(e!==-1?e:this.focusedOptionIndex)},0)},autoUpdateModel(){(this.selectOnFocus||this.autoHighlight)&&this.autoOptionFocus&&!this.hasSelectedOption&&(this.focusedOptionIndex=this.findFirstFocusedOptionIndex(),this.onOptionSelect(null,this.visibleOptions[this.focusedOptionIndex],!1))},updateModel(e,t){this.$emit("update:modelValue",t),this.$emit("change",{originalEvent:e,value:t})},flatOptions(e){return(e||[]).reduce((t,n,i)=>{t.push({optionGroup:n,group:!0,index:i});const r=this.getOptionGroupChildren(n);return r&&r.forEach(s=>t.push(s)),t},[])},overlayRef(e){this.overlay=e},listRef(e,t){this.list=e,t&&t(e)},virtualScrollerRef(e){this.virtualScroller=e}},computed:{containerClass(){return["p-autocomplete p-component p-inputwrapper",{"p-disabled":this.disabled,"p-focus":this.focused,"p-autocomplete-dd":this.dropdown,"p-autocomplete-multiple":this.multiple,"p-inputwrapper-filled":this.modelValue||ve.isNotEmpty(this.inputValue),"p-inputwrapper-focus":this.focused,"p-overlay-open":this.overlayVisible}]},inputStyleClass(){return["p-autocomplete-input p-inputtext p-component",this.inputClass,{"p-autocomplete-dd-input":this.dropdown}]},multiContainerClass(){return["p-autocomplete-multiple-container p-component p-inputtext"]},panelStyleClass(){return["p-autocomplete-panel p-component",this.panelClass,{"p-input-filled":this.$primevue.config.inputStyle==="filled","p-ripple-disabled":this.$primevue.config.ripple===!1}]},visibleOptions(){return this.optionGroupLabel?this.flatOptions(this.suggestions):this.suggestions||[]},inputValue(){if(this.modelValue)if(typeof this.modelValue=="object"){const e=this.getOptionLabel(this.modelValue);return e??this.modelValue}else return this.modelValue;else return""},hasSelectedOption(){return ve.isNotEmpty(this.modelValue)},equalityKey(){return this.dataKey},searchResultMessageText(){return ve.isNotEmpty(this.visibleOptions)&&this.overlayVisible?this.searchMessageText.replaceAll("{0}",this.visibleOptions.length):this.emptySearchMessageText},searchMessageText(){return this.searchMessage||this.$primevue.config.locale.searchMessage||""},emptySearchMessageText(){return this.emptySearchMessage||this.$primevue.config.locale.emptySearchMessage||""},selectionMessageText(){return this.selectionMessage||this.$primevue.config.locale.selectionMessage||""},emptySelectionMessageText(){return this.emptySelectionMessage||this.$primevue.config.locale.emptySelectionMessage||""},selectedMessageText(){return this.hasSelectedOption?this.selectionMessageText.replaceAll("{0}",this.multiple?this.modelValue.length:"1"):this.emptySelectionMessageText},focusedOptionId(){return this.focusedOptionIndex!==-1?`${this.id}_${this.focusedOptionIndex}`:null},focusedMultipleOptionId(){return this.focusedMultipleOptionIndex!==-1?`${this.id}_multiple_option_${this.focusedMultipleOptionIndex}`:null},ariaSetSize(){return this.visibleOptions.filter(e=>!this.isOptionGroup(e)).length},virtualScrollerDisabled(){return!this.virtualScrollerOptions}},components:{Button:Qn,VirtualScroller:Li,Portal:Kt,ChevronDownIcon:_n,SpinnerIcon:ps,TimesCircleIcon:ds},directives:{ripple:gt}};const RN=["id","value","placeholder","tabindex","disabled","aria-label","aria-labelledby","aria-expanded","aria-controls","aria-activedescendant"],LN=["aria-activedescendant"],NN=["id","aria-label","aria-setsize","aria-posinset"],DN=["id","placeholder","tabindex","disabled","aria-label","aria-labelledby","aria-expanded","aria-controls","aria-activedescendant"],xN=["id"],MN=["id"],FN=["id","aria-label","aria-selected","aria-disabled","aria-setsize","aria-posinset","onClick","onMousemove"];function VN(e,t,n,i,r,s){const a=le("SpinnerIcon"),o=le("Button"),l=le("VirtualScroller"),c=le("Portal"),d=Xe("ripple");return g(),S("div",R({ref:"container",class:s.containerClass,onClick:t[15]||(t[15]=(...u)=>s.onContainerClick&&s.onContainerClick(...u))},e.ptm("root")),[n.multiple?M("",!0):(g(),S("input",R({key:0,ref:"focusInput",id:n.inputId,type:"text",style:n.inputStyle,class:s.inputStyleClass,value:s.inputValue,placeholder:n.placeholder,tabindex:n.disabled?-1:n.tabindex,disabled:n.disabled,autocomplete:"off",role:"combobox","aria-label":e.ariaLabel,"aria-labelledby":e.ariaLabelledby,"aria-haspopup":"listbox","aria-autocomplete":"list","aria-expanded":r.overlayVisible,"aria-controls":r.id+"_list","aria-activedescendant":r.focused?s.focusedOptionId:void 0,onFocus:t[0]||(t[0]=(...u)=>s.onFocus&&s.onFocus(...u)),onBlur:t[1]||(t[1]=(...u)=>s.onBlur&&s.onBlur(...u)),onKeydown:t[2]||(t[2]=(...u)=>s.onKeyDown&&s.onKeyDown(...u)),onInput:t[3]||(t[3]=(...u)=>s.onInput&&s.onInput(...u)),onChange:t[4]||(t[4]=(...u)=>s.onChange&&s.onChange(...u))},{...n.inputProps,...e.ptm("input")}),null,16,RN)),n.multiple?(g(),S("ul",R({key:1,ref:"multiContainer",class:s.multiContainerClass,tabindex:"-1",role:"listbox","aria-orientation":"horizontal","aria-activedescendant":r.focused?s.focusedMultipleOptionId:void 0,onFocus:t[10]||(t[10]=(...u)=>s.onMultipleContainerFocus&&s.onMultipleContainerFocus(...u)),onBlur:t[11]||(t[11]=(...u)=>s.onMultipleContainerBlur&&s.onMultipleContainerBlur(...u)),onKeydown:t[12]||(t[12]=(...u)=>s.onMultipleContainerKeyDown&&s.onMultipleContainerKeyDown(...u))},e.ptm("container")),[(g(!0),S(J,null,ye(n.modelValue,(u,p)=>(g(),S("li",R({key:p,id:r.id+"_multiple_option_"+p,class:["p-autocomplete-token",{"p-focus":r.focusedMultipleOptionIndex===p}],role:"option","aria-label":s.getOptionLabel(u),"aria-selected":!0,"aria-setsize":n.modelValue.length,"aria-posinset":p+1},e.ptm("token")),[he(e.$slots,"chip",{value:u},()=>[f("span",R({class:"p-autocomplete-token-label"},e.ptm("tokenLabel")),N(s.getOptionLabel(u)),17)]),he(e.$slots,"removetokenicon",{class:"p-autocomplete-token-icon",onClick:h=>s.removeOption(h,p)},()=>[(g(),Q(_e(n.removeTokenIcon?"span":"TimesCircleIcon"),R({class:["p-autocomplete-token-icon",n.removeTokenIcon],onClick:h=>s.removeOption(h,p),"aria-hidden":"true"},e.ptm("removeTokenIcon")),null,16,["class","onClick"]))])],16,NN))),128)),f("li",R({class:"p-autocomplete-input-token",role:"option"},e.ptm("token")),[f("input",R({ref:"focusInput",id:n.inputId,type:"text",style:n.inputStyle,class:n.inputClass,placeholder:n.placeholder,tabindex:n.disabled?-1:n.tabindex,disabled:n.disabled,autocomplete:"off",role:"combobox","aria-label":e.ariaLabel,"aria-labelledby":e.ariaLabelledby,"aria-haspopup":"listbox","aria-autocomplete":"list","aria-expanded":r.overlayVisible,"aria-controls":r.id+"_list","aria-activedescendant":r.focused?s.focusedOptionId:void 0,onFocus:t[5]||(t[5]=(...u)=>s.onFocus&&s.onFocus(...u)),onBlur:t[6]||(t[6]=(...u)=>s.onBlur&&s.onBlur(...u)),onKeydown:t[7]||(t[7]=(...u)=>s.onKeyDown&&s.onKeyDown(...u)),onInput:t[8]||(t[8]=(...u)=>s.onInput&&s.onInput(...u)),onChange:t[9]||(t[9]=(...u)=>s.onChange&&s.onChange(...u))},{...n.inputProps,...e.ptm("input")}),null,16,DN)],16)],16,LN)):M("",!0),r.searching?he(e.$slots,"loadingicon",{key:2},()=>[n.loadingIcon?(g(),S("i",R({key:0,class:["p-autocomplete-loader pi-spin",n.loadingIcon],"aria-hidden":"true"},e.ptm("loadingIcon")),null,16)):(g(),Q(a,R({key:1,class:"p-autocomplete-loader",spin:"","aria-hidden":"true"},e.ptm("loadingIcon")),null,16))]):M("",!0),n.dropdown?(g(),Q(o,{key:3,ref:"dropdownButton",type:"button",tabindex:"-1",class:Oe(["p-autocomplete-dropdown",n.dropdownClass]),disabled:n.disabled,"aria-hidden":"true",onClick:s.onDropdownClick,pt:e.ptm("dropdownButton")},{icon:Ee(()=>[he(e.$slots,"dropdownicon",{},()=>[(g(),Q(_e(n.dropdownIcon?"span":"ChevronDownIcon"),R({class:n.dropdownIcon},e.ptm("dropdownButton").icon),null,16,["class"]))])]),_:3},8,["class","disabled","onClick","pt"])):M("",!0),f("span",R({role:"status","aria-live":"polite",class:"p-hidden-accessible"},e.ptm("hiddenSearchResult")),N(s.searchResultMessageText),17),de(c,{appendTo:n.appendTo},{default:Ee(()=>[de($t,{name:"p-connected-overlay",onEnter:s.onOverlayEnter,onAfterEnter:s.onOverlayAfterEnter,onLeave:s.onOverlayLeave,onAfterLeave:s.onOverlayAfterLeave},{default:Ee(()=>[r.overlayVisible?(g(),S("div",R({key:0,ref:s.overlayRef,class:s.panelStyleClass,style:{...n.panelStyle,"max-height":s.virtualScrollerDisabled?n.scrollHeight:""},onClick:t[13]||(t[13]=(...u)=>s.onOverlayClick&&s.onOverlayClick(...u)),onKeydown:t[14]||(t[14]=(...u)=>s.onOverlayKeyDown&&s.onOverlayKeyDown(...u))},{...n.panelProps,...e.ptm("panel")}),[he(e.$slots,"header",{value:n.modelValue,suggestions:s.visibleOptions}),de(l,R({ref:s.virtualScrollerRef},{...n.virtualScrollerOptions,...e.ptm("virtualScroller")},{style:{height:n.scrollHeight},items:s.visibleOptions,tabindex:-1,disabled:s.virtualScrollerDisabled}),ii({content:Ee(({styleClass:u,contentRef:p,items:h,getItemOptions:m,contentStyle:v,itemSize:_})=>[f("ul",R({ref:b=>s.listRef(b,p),id:r.id+"_list",class:["p-autocomplete-items",u],style:v,role:"listbox"}
2305,e.ptm("list")),[(g(!0),S(J,null,ye(h,(b,w)=>(g(),S(J,{key:s.getOptionRenderKey(b,s.getOptionIndex(w,m))},[s.isOptionGroup(b)?(g(),S("li",R({key:0,id:r.id+"_"+s.getOptionIndex(w,m),style:{height:_?_+"px":void 0},class:"p-autocomplete-item-group",role:"option"},e.ptm("itemGroup")),[he(e.$slots,"optiongroup",{option:b.optionGroup,item:b.optionGroup,index:s.getOptionIndex(w,m)},()=>[ke(N(s.getOptionGroupLabel(b.optionGroup)),1)])],16,MN)):Ne((g(),S("li",R({key:1,id:r.id+"_"+s.getOptionIndex(w,m),style:{height:_?_+"px":void 0},class:["p-autocomplete-item",{"p-highlight":s.isSelected(b),"p-focus":r.focusedOptionIndex===s.getOptionIndex(w,m),"p-disabled":s.isOptionDisabled(b)}],role:"option","aria-label":s.getOptionLabel(b),"aria-selected":s.isSelected(b),"aria-disabled":s.isOptionDisabled(b),"aria-setsize":s.ariaSetSize,"aria-posinset":s.getAriaPosInset(s.getOptionIndex(w,m)),onClick:C=>s.onOptionSelect(C,b),onMousemove:C=>s.onOptionMouseMove(C,s.getOptionIndex(w,m))},s.getPTOptions(b,m,w,"item")),[e.$slots.option?he(e.$slots,"option",{key:0,option:b,index:s.getOptionIndex(w,m)},()=>[ke(N(s.getOptionLabel(b)),1)]):he(e.$slots,"item",{key:1,item:b,index:s.getOptionIndex(w,m)},()=>[ke(N(s.getOptionLabel(b)),1)])],16,FN)),[[d]])],64))),128)),!h||h&&h.length===0?(g(),S("li",R({key:0,class:"p-autocomplete-empty-message",role:"option"},e.ptm("emptyMessage")),[he(e.$slots,"empty",{},()=>[ke(N(s.searchResultMessageText),1)])],16)):M("",!0)],16,xN)]),_:2},[e.$slots.loader?{name:"loader",fn:Ee(({options:u})=>[he(e.$slots,"loader",{options:u})]),key:"0"}:void 0]),1040,["style","items","disabled"]),he(e.$slots,"footer",{value:n.modelValue,suggestions:s.visibleOptions}),f("span",R({role:"status","aria-live":"polite",class:"p-hidden-accessible"},e.ptm("hiddenSelectedMessage")),N(s.selectedMessageText),17)],16)):M("",!0)]),_:3},8,["onEnter","onAfterEnter","onLeave","onAfterLeave"])]),_:3},8,["appendTo"])],16)}function BN(e,t){t===void 0&&(t={});var n=t.insertAt;if(!(typeof document>"u")){var i=document.head||document.getElementsByTagName("head")[0],r=document.createElement("style");r.type="text/css",n==="top"&&i.firstChild?i.insertBefore(r,i.firstChild):i.appendChild(r),r.styleSheet?r.styleSheet.cssText=e:r.appendChild(document.createTextNode(e))}}var $N=`
2306.p-autocomplete {
2307    display: inline-flex;
2308    position: relative;
2309}
2310.p-autocomplete-loader {
2311    position: absolute;
2312    top: 50%;
2313    margin-top: -0.5rem;
2314}
2315.p-autocomplete-dd .p-autocomplete-input {
2316    flex: 1 1 auto;
2317    width: 1%;
2318}
2319.p-autocomplete-dd .p-autocomplete-input,
2320.p-autocomplete-dd .p-autocomplete-multiple-container {
2321    border-top-right-radius: 0;
2322    border-bottom-right-radius: 0;
2323}
2324.p-autocomplete-dd .p-autocomplete-dropdown {
2325    border-top-left-radius: 0;
2326    border-bottom-left-radius: 0px;
2327}
2328.p-autocomplete .p-autocomplete-panel {
2329    min-width: 100%;
2330}
2331.p-autocomplete-panel {
2332    position: absolute;
2333    overflow: auto;
2334    top: 0;
2335    left: 0;
2336}
2337.p-autocomplete-items {
2338    margin: 0;
2339    padding: 0;
2340    list-style-type: none;
2341}
2342.p-autocomplete-item {
2343    cursor: pointer;
2344    white-space: nowrap;
2345    position: relative;
2346    overflow: hidden;
2347}
2348.p-autocomplete-multiple-container {
2349    margin: 0;
2350    padding: 0;
2351    list-style-type: none;
2352    cursor: text;
2353    overflow: hidden;
2354    display: flex;
2355    align-items: center;
2356    flex-wrap: wrap;
2357}
2358.p-autocomplete-token {
2359    cursor: default;
2360    display: inline-flex;
2361    align-items: center;
2362    flex: 0 0 auto;
2363}
2364.p-autocomplete-token-icon {
2365    cursor: pointer;
2366}
2367.p-autocomplete-input-token {
2368    flex: 1 1 auto;
2369    display: inline-flex;
2370}
2371.p-autocomplete-input-token input {
2372    border: 0 none;
2373    outline: 0 none;
2374    background-color: transparent;
2375    margin: 0;
2376    padding: 0;
2377    box-shadow: none;
2378    border-radius: 0;
2379    width: 100%;
2380}
2381.p-fluid .p-autocomplete {
2382    display: flex;
2383}
2384.p-fluid .p-autocomplete-dd .p-autocomplete-input {
2385    width: 1%;
2386}
2387`;BN($N);Hm.render=VN;var zm={name:"RefreshIcon",extends:ze};const UN=f("g",{"clip-path":"url(#clip0_414_20758)"},[f("path",{"fill-rule":"evenodd","clip-rule":"evenodd",d:"M6.77051 5.96336C6.84324 5.99355 6.92127 6.00891 7.00002 6.00854C7.07877 6.00891 7.1568 5.99355 7.22953 5.96336C7.30226 5.93317 7.36823 5.88876 7.42357 5.83273L9.82101 3.43529C9.93325 3.32291 9.99629 3.17058 9.99629 3.01175C9.99629 2.85292 9.93325 2.70058 9.82101 2.5882L7.42357 0.190763C7.3687 0.131876 7.30253 0.0846451 7.22901 0.0518865C7.15549 0.019128 7.07612 0.00151319 6.99564 9.32772e-05C6.91517 -0.00132663 6.83523 0.0134773 6.7606 0.0436218C6.68597 0.0737664 6.61817 0.118634 6.56126 0.175548C6.50435 0.232462 6.45948 0.300257 6.42933 0.374888C6.39919 0.449519 6.38439 0.529456 6.38581 0.609933C6.38722 0.690409 6.40484 0.769775 6.4376 0.843296C6.47036 0.916817 6.51759 0.982986 6.57647 1.03786L7.95103 2.41241H6.99998C5.46337 2.41241 3.989
238769 3.02283 2.90314 4.10938C1.81659 5.19593 1.20618 6.66961 1.20618 8.20622C1.20618 9.74283 1.81659 11.2165 2.90314 12.3031C3.98969 13.3896 5.46337 14 6.99998 14C8.53595 13.9979 10.0084 13.3868 11.0945 12.3007C12.1806 11.2146 12.7917 9.74218 12.7938 8.20622C12.7938 8.04726 12.7306 7.89481 12.6182 7.78241C12.5058 7.67001 12.3534 7.60686 12.1944 7.60686C12.0355 7.60686 11.883 7.67001 11.7706 7.78241C11.6582 7.89481 11.5951 8.04726 11.5951 8.20622C11.5951 9.11504 11.3256 10.0035 10.8207 10.7591C10.3157 11.5148 9.59809 12.1037 8.75845 12.4515C7.9188 12.7993 6.99489 12.8903 6.10353 12.713C5.21217 12.5357 4.3934 12.0981 3.75077 11.4554C3.10813 10.8128 2.67049 9.99404 2.49319 9.10268C2.31589 8.21132 2.40688 7.2874 2.75468 6.44776C3.10247 5.60811 3.69143 4.89046 4.44709 4.38554C5.20275 3.88063 6.09116 3.61113 6.99998 3.61113H7.95098L6.57647 4.98564C6.46423 5.09802 6.40119 5.25035 6.40119 5.40918C6.40119 5.56801 6.46423 5.72035 6.57647 5.83273C6.63181 5.88876 6.69778 5.93317 6.77051 5.96336Z",fill:"currentColor"})],-1),HN=f("defs",null,[f("clipPath",{id:"clip0_414_20758"},[f("rect",{width:"14",height:"14",fill:"white"})])],-1),zN=[UN,HN];function KN(e,t,n,i,r,s){return g(),S("svg",R({width:"14",height:"14",viewBox:"0 0 14 14",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e.pti()),zN,16)}zm.render=KN;var Km={name:"SearchMinusIcon",extends:ze};const GN=f("g",{"clip-path":"url(#clip0_417_21152)"},[f("path",{"fill-rule":"evenodd","clip-rule":"evenodd",d:"M6.0208 12.0411C4.83005 12.0411 3.66604 11.688 2.67596 11.0265C1.68589 10.3649 0.914216 9.42464 0.458534 8.32452C0.00285271 7.22441 -0.116374 6.01388 0.11593 4.84601C0.348235 3.67813 0.921637 2.60537 1.76363 1.76338C2.60562 0.921393 3.67838 0.34799 4.84625 0.115686C6.01412 -0.116618 7.22466 0.00260857 8.32477 0.45829C9.42488 0.913972 10.3652 1.68564 11.0267 2.67572C11.6883 3.66579 12.0414 4.8298 12.0414 6.02056C12.0395 7.41563 11.5542 8.76029 10.6783 9.8305L13.8244 12.9765C13.9367 13.089 13.9997 13.2414 13.9997 13.4003C13.9997 13.5592 13.9367 13.7116 13.8244 13.8241C13.769 13.8801 13.703 13.9245 13.6302 13.9548C13.5575 13.985 13.4794 14.0003 13.4006 14C13.3218 14.0003 13.2437 13.985 13.171 13.9548C13.0982 13.9245 13.0322 13.8801 12.9768 13.8241L9.83082 10.678C8.76059 11.5539 7.4159 12.0393 6.0208 12.0411ZM6.0208 1.20731C5.07199 1.20731 4.14449 1.48867 3.35559 2.0158C2.56669 2.54292 1.95181 3.29215 1.58872 4.16874C1.22562 5.04532 1.13062 6.00989 1.31572 6.94046C1.50083 7.87104 1.95772 8.72583 2.62863 9.39674C3.29954 10.0676 4.15433 10.5245 5.0849 10.7096C6.01548 10.8947 6.98005 10.7997 7.85663 10.4367C8.73322 10.0736 9.48244 9.45868 10.0096 8.66978C10.5367 7.88088 10.8181 6.95337 10.8181 6.00457C10.8181 4.73226 10.3126 3.51206 9.41297 2.6124C8.51331 1.71274 7.29311 1.20731 6.0208 1.20731ZM4.00591 6.60422H8.00362C8.16266 6.60422 8.31518 6.54104 8.42764 6.42859C8.5401 6.31613 8.60328 6.1636 8.60328 6.00456C8.60328 5.84553 8.5401 5.693 8.42764 5.58054C8.31518 5.46809 8.16266 5.40491 8.00362 5.40491H4.00591C3.84687 5.40491 3.69434 5.46809 3.58189 5.58054C3.46943 5.693 3.40625 5.84553 3.40625 6.00456C3.40625 6.1636 3.46943 6.31613 3.58189 6.42859C3.69434 6.54104 3.84687 6.60422 4.00591 6.60422Z",fill:"currentColor"})],-1),jN=f("defs",null,[f("clipPath",{id:"clip0_417_21152"},[f("rect",{width:"14",height:"14",fill:"white"})])],-1),YN=[GN,jN];function WN(e,t,n,i,r,s){return g(),S("svg",R({width:"14",height:"14",viewBox:"0 0 14 14",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e.pti()),YN,16)}Km.render=WN;var Gm={name:"SearchPlusIcon",extends:ze};const QN=f("g",{"clip-path":"url(#clip0_417_21164)"},[f("path",{"fill-rule":"evenodd","clip-rule":"evenodd",d:"M2.67596 11.0265C3.66604 11.688 4.83005 12.0411 6.0208 12.0411C6.81143 12.0411 7.59432 11.8854 8.32477 11.5828C8.86999 11.357 9.37802 11.0526 9.83311 10.6803L12.9768 13.8241C13.0322 13.8801 13.0982 13.9245 13.171 13.9548C13.2437 13.985 13.3218 14.0003 13.4006 14C13.4794 14.0003 13.5575 13.985 13.6302 13.9548C13.703 13.9245 13.769 13.8801 13.8244 13.8241C13.9367 13.7116 13.9997 13.5592 13.9997 13.4003C13.9997 13.2414 13.9367 13.089 13.8244 
238712.9765L10.6806 9.8328C11.0529 9.37773 11.3572 8.86972 11.5831 8.32452C11.8856 7.59408 12.0414 6.81119 12.0414 6.02056C12.0414 4.8298 11.6883 3.66579 11.0267 2.67572C10.3652 1.68564 9.42488 0.913972 8.32477 0.45829C7.22466 0.00260857 6.01412 -0.116618 4.84625 0.115686C3.67838 0.34799 2.60562 0.921393 1.76363 1.76338C0.921637 2.60537 0.348235 3.67813 0.11593 4.84601C-0.116374 6.01388 0.00285271 7.22441 0.458534 8.32452C0.914216 9.42464 1.68589 10.3649 2.67596 11.0265ZM3.35559 2.0158C4.14449 1.48867 5.07199 1.20731 6.0208 1.20731C7.29311 1.20731 8.51331 1.71274 9.41297 2.6124C10.3126 3.51206 10.8181 4.73226 10.8181 6.00457C10.8181 6.95337 10.5367 7.88088 10.0096 8.66978C9.48244 9.45868 8.73322 10.0736 7.85663 10.4367C6.98005 10.7997 6.01548 10.8947 5.0849 10.7096C4.15433 10.5245 3.29954 10.0676 2.62863 9.39674C1.95772 8.72583 1.50083 7.87104 1.31572 6.94046C1.13062 6.00989 1.22562 5.04532 1.58872 4.16874C1.95181 3.29215 2.56669 2.54292 3.35559 2.0158ZM6.00481 8.60309C5.84641 8.60102 5.69509 8.53718 5.58308 8.42517C5.47107 8.31316 5.40722 8.16183 5.40515 8.00344V6.60422H4.00591C3.84687 6.60422 3.69434 6.54104 3.58189 6.42859C3.46943 6.31613 3.40625 6.1636 3.40625 6.00456C3.40625 5.84553 3.46943 5.693 3.58189 5.58054C3.69434 5.46809 3.84687 5.40491 4.00591 5.40491H5.40515V4.00572C5.40515 3.84668 5.46833 3.69416 5.58079 3.5817C5.69324 3.46924 5.84577 3.40607 6.00481 3.40607C6.16385 3.40607 6.31637 3.46924 6.42883 3.5817C6.54129 3.69416 6.60447 3.84668 6.60447 4.00572V5.40491H8.00362C8.16266 5.40491 8.31518 5.46809 8.42764 5.58054C8.5401 5.693 8.60328 5.84553 8.60328 6.00456C8.60328 6.1636 8.5401 6.31613 8.42764 6.42859C8.31518 6.54104 8.16266 6.60422 8.00362 6.60422H6.60447V8.00344C6.60239 8.16183 6.53855 8.31316 6.42654 8.42517C6.31453 8.53718 6.1632 8.60102 6.00481 8.60309Z",fill:"currentColor"})],-1),ZN=f("defs",null,[f("clipPath",{id:"clip0_417_21164"},[f("rect",{width:"14",height:"14",fill:"white"})])],-1),qN=[QN,ZN];function JN(e,t,n,i,r,s){return g(),S("svg",R({width:"14",height:"14",viewBox:"0 0 14 14",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e.pti()),qN,16)}Gm.render=JN;var jm={name:"UndoIcon",extends:ze};const XN=f("g",{"clip-path":"url(#clip0_417_21625)"},[f("path",{"fill-rule":"evenodd","clip-rule":"evenodd",d:"M6.77042 5.96336C6.84315 5.99355 6.92118 6.00891 6.99993 6.00854C7.07868 6.00891 7.15671 5.99355 7.22944 5.96336C7.30217 5.93317 7.36814 5.88876 7.42348 5.83273C7.53572 5.72035 7.59876 5.56801 7.59876 5.40918C7.59876 5.25035 7.53572 5.09802 7.42348 4.98564L6.04897 3.61113H6.99998C7.9088 3.61113 8.79722 3.88063 9.55288 4.38554C10.3085 4.89046 10.8975 5.60811 11.2453 6.44776C11.5931 7.2874 11.6841 8.21132 11.5068 9.10268C11.3295 9.99404 10.8918 10.8128 10.2492 11.4554C9.60657 12.0981 8.7878 12.5357 7.89644 12.713C7.00508 12.8903 6.08116 12.7993 5.24152 12.4515C4.40188 12.1037 3.68422 11.5148 3.17931 10.7591C2.67439 10.0035 2.4049 9.11504 2.4049 8.20622C2.4049 8.04726 2.34175 7.89481 2.22935 7.78241C2.11695 7.67001 1.9645 7.60686 1.80554 7.60686C1.64658 7.60686 1.49413 7.67001 1.38172 7.78241C1.26932 7.89481 1.20618 8.04726 1.20618 8.20622C1.20829 9.74218 1.81939 11.2146 2.90548 12.3007C3.99157 13.3868 5.46402 13.9979 6.99998 14C8.5366 14 10.0103 13.3896 11.0968 12.3031C12.1834 11.2165 12.7938 9.74283 12.7938 8.20622C12.7938 6.66961 12.1834 5.19593 11.0968 4.10938C10.0103 3.02283 8.5366 2.41241 6.99998 2.41241H6.04892L7.42348 1.03786C7.48236 0.982986 7.5296 0.916817 7.56235 0.843296C7.59511 0.769775 7.61273 0.690409 7.61415 0.609933C7.61557 0.529456 7.60076 0.449519 7.57062 0.374888C7.54047 0.300257 7.49561 0.232462 7.43869 0.175548C7.38178 0.118634 7.31398 0.0737664 7.23935 0.0436218C7.16472 0.0134773 7.08478 -0.00132663 7.00431 9.32772e-05C6.92383 0.00151319 6.84447 0.019128 6.77095 0.0518865C6.69742 0.0846451 6.63126 0.131876 6.57638 0.190763L4.17895 2.5882C4.06671 2.70058 4.00366 2.85292 4.00366 3.01175C4.00366 3.17058 4.06671 3.32291 4.17895 3.43529L6.57638 5.83273C6.63172 5.88876 6.69769 5.93317 6.77042 5.96336Z",fill:"currentColor"})],-1),e4=f("defs",null,[f("clipPath",{id:"clip0_417_21625"},[f("rect",{width:"14",height:"14",fill:"white"})])],-1),t4=[XN,e4];function n4(e,t,n,i,r,s){return g(),S("svg",R({width:"14",height:"14",viewBox:"0 0 14 14",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e.pti()),t4,16)}jm.render=n4;var Ym={name:"Image",extends:Ve,inheritAttrs:!1,emits:["show","hide","error"],props:{preview:{type:Boolean,default:!1},class:{type:null,default:null},style:{type:null,default:null},imageStyle:{type:null,default:null},imageClass:{type:null,default:null},previewButtonProps:{type:null,default:null},indicatorIcon:{type:String,default:void 0},zoomInDisabled:{type:Boolean,default:!1},zoomOutDisabled:{type:Boolean,default:!1}},mask:null,data(){return{maskVisible:!1,previewVisible:!1,rotate:0,scale:1}},beforeUnmount(){this.mask&&He.clear(this.container)},methods:{maskRef(e){this.mask=e},toolbarRef(e){this.toolbarRef=e},onImageClick(){this.preview&&(this.maskVisible=!0,setTimeout(()=>{this.previewVisible=!0},25))},onPreviewImageClick(){this.previewClick=!0},onMaskClick(e){[e.target.classList].includes("p-image-action")||e.target.closest(".p-image-action")||(this.previewClick||(this.previewVisible=!1,this.rotate=0,this.scale=1),this.previewClick=!1)},onMaskKeydown(e){switch(e.code){case"Escape":this.onMaskClick(),setTimeout(()=>{F.focus(this.$refs.previewButton)},25),e.preventDefault();break}},onError(){this.$emit("error")},rotateRight(){this.rotate+=90,this.previewClick=!0},rotateLeft(){this.rotate-=90,this.previewClick=!0},zoomIn(){this.scale=this.scale+.1,this.previewClick=!0},zoomOut(){this.scale=this.scale-.1,this.previewClick=!0},onBeforeEnter(){He.set("modal",this.mask,this.$primevue.config.zIndex.modal)},onEnter(){this.focus(),this.$emit("show")},onBeforeLeave(){F.addClass(this.mask,"p-component-overlay-leave")},onLeave(){this.$emit("hide")},onAfterLeave(e){He.clear(e),this.maskVisible=!1},focus(){let e=this.mask.querySelector("[autofocus]");e&&e.focus()},hidePreview(){this.previewVisible=!1,this.rotate=0,this.scale=1}},computed:{containerClass(){return["p-image p-component",this.class,{"p-image-preview-container":this.preview}]},maskClass(){return["p-image-mask p-component-overlay p-component-overlay-enter"]},rotateClass(){return"p-image-preview-rotate-"+this.rotate},imagePreviewStyle(){return{transform:"rotate("+this.rotate+"deg) scale("+this.scale+")"}},isZoomInDisabled(){return this.zoomInDisabled||this.scale>=1.5},isZoomOutDisabled(){return this.zoomOutDisabled||this.scale<=.5},rightAriaLabel(){return this.$primevue.config.locale.aria?this.$primevue.config.locale.aria.rotateRight:void 0},leftAriaLabel(){return this.$primevue.config.locale.aria?this.$primevue.config.locale.aria.rotateLeft:void 0},zoomInAriaLabel(){return this.$primevue.config.locale.aria?this.$primevue.config.locale.aria.zoomIn:void 0},zoomOutAriaLabel(){return this.$primevue.config.locale.aria?this.$primevue.config.locale.aria.zoomOut:void 0},closeAriaLabel(){return this.$primevue.config.locale.aria?this.$primevue.config.locale.aria.close:void 0}},components:{Portal:Kt,EyeIcon:Dl,RefreshIcon:zm,UndoIcon:jm,SearchMinusIcon:Km,SearchPlusIcon:Gm,TimesIcon:Qt}
2387,directives:{focustrap:Fs}};const s4=["aria-modal"],i4=["aria-label"],r4=["aria-label"],a4=["disabled","aria-label"],o4=["disabled","aria-label"],l4=["aria-label"],c4=["src"];function d4(e,t,n,i,r,s){const a=le("RefreshIcon"),o=le("UndoIcon"),l=le("SearchMinusIcon"),c=le("SearchPlusIcon"),d=le("TimesIcon"),u=le("Portal"),p=Xe("focustrap");return g(),S("span",R({class:s.containerClass,style:n.style},e.ptm("root")),[he(e.$slots,"image",{class:Oe(n.imageClass),style:cs(n.imageStyle),onError:s.onError},()=>[f("img",R({style:n.imageStyle,class:n.imageClass,onError:t[0]||(t[0]=(...h)=>s.onError&&s.onError(...h))},{...e.$attrs,...e.ptm("image")}),null,16)]),n.preview?(g(),S("button",R({key:0,ref:"previewButton",class:"p-image-preview-indicator",onClick:t[1]||(t[1]=(...h)=>s.onImageClick&&s.onImageClick(...h))},{...n.previewButtonProps,...e.ptm("button")}),[he(e.$slots,"indicatoricon",{},()=>[(g(),Q(_e(n.indicatorIcon?"i":"EyeIcon"),R({class:"p-image-preview-icon"},e.ptm("icon")),null,16))])],16)):M("",!0),de(u,null,{default:Ee(()=>[r.maskVisible?Ne((g(),S("div",R({key:0,ref:s.maskRef,role:"dialog",class:s.maskClass,"aria-modal":r.maskVisible,onClick:t[8]||(t[8]=(...h)=>s.onMaskClick&&s.onMaskClick(...h)),onKeydown:t[9]||(t[9]=(...h)=>s.onMaskKeydown&&s.onMaskKeydown(...h))},e.ptm("mask")),[f("div",R({class:"p-image-toolbar"},e.ptm("toolbar")),[f("button",R({class:"p-image-action p-link",onClick:t[2]||(t[2]=(...h)=>s.rotateRight&&s.rotateRight(...h)),type:"button","aria-label":s.rightAriaLabel},e.ptm("rotateRightButton")),[he(e.$slots,"refresh",{},()=>[de(a,ft(Tt(e.ptm("rotateRightIcon"))),null,16)])],16,i4),f("button",R({class:"p-image-action p-link",onClick:t[3]||(t[3]=(...h)=>s.rotateLeft&&s.rotateLeft(...h)),type:"button","aria-label":s.leftAriaLabel},e.ptm("rotateLeftButton")),[he(e.$slots,"undo",{},()=>[de(o,ft(Tt(e.ptm("rotateLeftIcon"))),null,16)])],16,r4),f("button",R({class:["p-image-action p-link",{"p-disabled":s.isZoomOutDisabled}],onClick:t[4]||(t[4]=(...h)=>s.zoomOut&&s.zoomOut(...h)),type:"button",disabled:s.isZoomOutDisabled,"aria-label":s.zoomOutAriaLabel},e.ptm("zoomOutButton")),[he(e.$slots,"zoomout",{},()=>[de(l,ft(Tt(e.ptm("zoomOutIcon"))),null,16)])],16,a4),f("button",R({class:["p-image-action p-link",{"p-disabled":s.isZoomInDisabled}],onClick:t[5]||(t[5]=(...h)=>s.zoomIn&&s.zoomIn(...h)),type:"button",disabled:s.isZoomInDisabled,"aria-label":s.zoomInAriaLabel},e.ptm("zoomInButton")),[he(e.$slots,"zoomin",{},()=>[de(c,ft(Tt(e.ptm("zoomInIcon"))),null,16)])],16,o4),f("button",R({class:"p-image-action p-link",type:"button",onClick:t[6]||(t[6]=(...h)=>s.hidePreview&&s.hidePreview(...h)),"aria-label":s.closeAriaLabel,autofocus:""},e.ptm("closeButton")),[he(e.$slots,"close",{},()=>[de(d,ft(Tt(e.ptm("closeIcon"))),null,16)])],16,l4)],16),de($t,{name:"p-image-preview",onBeforeEnter:s.onBeforeEnter,onEnter:s.onEnter,onLeave:s.onLeave,onBeforeLeave:s.onBeforeLeave,onAfterLeave:s.onAfterLeave},{default:Ee(()=>[r.previewVisible?(g(),S("div",ft(R({key:0},e.ptm("previewContainer"))),[he(e.$slots,"preview",{class:"p-image-preview",style:cs(s.imagePreviewStyle),onClick:s.onPreviewImageClick},()=>[f("img",R({src:e.$attrs.src,class:"p-image-preview",style:s.imagePreviewStyle,onClick:t[7]||(t[7]=(...h)=>s.onPreviewImageClick&&s.onPreviewImageClick(...h))},e.ptm("preview")),null,16,c4)])],16)):M("",!0)]),_:3},8,["onBeforeEnter","onEnter","onLeave","onBeforeLeave","onAfterLeave"])],16,s4)),[[p]]):M("",!0)]),_:3})],16)}function u4(e,t){t===void 0&&(t={});var n=t.insertAt;if(!(typeof document>"u")){var i=document.head||document.getElementsByTagName("head")[0],r=document.createElement("style");r.type="text/css",n==="top"&&i.firstChild?i.insertBefore(r,i.firstChild):i.appendChild(r),r.styleSheet?r.styleSheet.cssText=e:r.appendChild(document.createTextNode(e))}}var h4=`
2388.p-image-mask {
2389    display: flex;
2390    align-items: center;
2391    justify-content: center;
2392}
2393.p-image-preview-container {
2394    position: relative;
2395    display: inline-block;
2396}
2397.p-image-preview-indicator {
2398    position: absolute;
2399    left: 0;
2400    top: 0;
2401    width: 100%;
2402    height: 100%;
2403    display: flex;
2404    align-items: center;
2405    justify-content: center;
2406    opacity: 0;
2407    transition: opacity 0.3s;
2408}
2409.p-image-preview-container:hover > .p-image-preview-indicator {
2410    opacity: 1;
2411    cursor: pointer;
2412}
2413.p-image-preview-container > img {
2414    cursor: pointer;
2415}
2416.p-image-toolbar {
2417    position: absolute;
2418    top: 0;
2419    right: 0;
2420    display: flex;
2421}
2422.p-image-action.p-link {
2423    display: flex;
2424    justify-content: center;
2425    align-items: center;
2426}
2427.p-image-preview {
2428    transition: transform 0.15s;
2429    max-width: 100vw;
2430    max-height: 100vh;
2431}
2432.p-image-preview-enter-active {
2433    transition: all 150ms cubic-bezier(0, 0, 0.2, 1);
2434}
2435.p-image-preview-leave-active {
2436    transition: all 150ms cubic-bezier(0.4, 0, 0.2, 1);
2437}
2438.p-image-preview-enter-from,
2439.p-image-preview-leave-to {
2440    opacity: 0;
2441    transform: scale(0.7);
2442}
2443`;u4(h4);Ym.render=d4;const p4=_t(e=>{e.vueApp.use(dA,{ripple:!1}),e.vueApp.component("Accordion",vf),e.vueApp.component("AccordionTab",_f),e.vueApp.component("Button",Qn),e.vueApp.component("FileUpload",Cf),e.vueApp.component("DataTable",tm),e.vueApp.component("Column",_3),e.vueApp.component("Galleria",rm),e.vueApp.component("Dropdown",Ni),e.vueApp.component("TabView",am),e.vueApp.component("TabPanel",om),e.vueApp.component("Avatar",lm),e.vueApp.component("Badge",Al),e.vueApp.component("Dialog",um),e.vueApp.component("Divider",hm),e.vueApp.component("RadioButton",pm),e.vueApp.component("InputText",na),e.vueApp.component("Calendar",mm),e.vueApp.component("Password",ym),e.vueApp.component("Sidebar",bm),e.vueApp.component("Carousel",vm),e.vueApp.directive("tooltip",P6),e.vueApp.component("Toast",km),e.vueApp.component("Checkbox",Lm),e.vueApp.component("OverlayPanel",Nm),e.vueApp.component("ProgressBar",Ol),e.vueApp.component("InputNumber",Rl),e.vueApp.component("Menu",xm),e.vueApp.component("MultiSelect",Fm),e.vueApp.component("Slider",Vm),e.vueApp.component("Skeleton",Bm),e.vueApp.component("Textarea",$m),e.vueApp.component("InputSwitch",Um),e.vueApp.component("AutoComplete",Hm),e.vueApp.component("Image",Ym),e.vueApp.use(x6)}),f4=_t(()=>{const{clientEnv:e}=Be().public,n=e==="dev"?"http://localhost:8080":`https://${se()}/js/shared/vue/vto`,i=a=>{const o=document.createElement("link");o.rel="stylesheet",o.href=`${n}${a}`,document.head.appendChild(o)},r=(a,o)=>{const l=document.createElement("script");return l.src=`${n}${a}`,l.defer=!0,document.body.appendChild(l),l};i("/css/chunk-vendors.css"),i("/css/app.css"),r("/js/chunk-vendors.js"),r("/js/app.js");const s=document.createElement("script");s.id="fitmixScriptAdvanced",s.src="https://vto-advanced-integration-api.fittingbox.com/index.js",s.defer=!0,document.body.appendChild(s),s.addEventListener("load",()=>{window.FitMixAdvanced=window.FitMix})}),m4=_t(()=>{const e=It();(e.href.includes("contactsexpress.ca")||e.href.includes("opticontacts.com")||e.href.includes("postalcontacts.com"))&&(document.body.classList.add("raleway-font"),document.documentElement.classList.add("raleway-font"))});var eu=/^(GTM|G)-[0-9A-Z]+$/;function $a(e){if(typeof e!="string"||!eu.test(e)){let t=String(e).toUpperCase().replace(/.*-|[^0-9A-Z]/g,""),n=t.length===0?"":` Did you mean 'GTM-${t}' or 'G-${t}'?`;throw new Error(`'${e}' is not a valid GTM-ID (${eu}).${n}`)}}function Qs(e,t="dataLayer"){return e[t]||(e[t]=[]),e[t]}function Cs(e,t){let n=document,i=n.createElement("script"),r=c=>{var d;(d=t.onReady)==null||d.call(t,{id:e,script:i}),i.removeEventListener("load",r)};i.addEventListener("load",r);let s=t.dataLayerName??"dataLayer";if(Qs(window,s).push({event:"gtm.js","gtm.start":new Date().getTime()}),!e)return i;i.async=!t.defer,i.defer=!!(t.defer||t.compatibility),t.nonce&&i.setAttribute("nonce",t.nonce),t.scriptType&&(i.type=t.scriptType);let a=new URLSearchParams({id:e,...t.dataLayerName?{l:t.dataLayerName}:{},...t.queryParams??{}}),o=t.source??"https://www.googletagmanager.com/gtm.js";i.src=`${o}?${a}`;let l=t.parentElement??n.body;if(typeof(l==null?void 0:l.appendChild)!="function")throw new Error("parentElement must be a DOM element");return l.appendChild(i),i}function g4(e="https://www.googletagmanager.com/gtm.js"){return Array.from(document.getElementsByTagName("script")).some(t=>t.src.includes(e))}var y4=class{constructor(e){en(this,"id");en(this,"options");en(this,"scriptElements",[]);en(this,"isInBrowserContext",()=>typeof window<"u");if(Array.isArray(e.id))for(let t of e.id)$a(typeof t=="string"?t:t.id);else $a(e.id);this.id=e.id,this.options={enabled:!0,debug:!1,loadScript:!0,defer:!1,compatibility:!1,dataLayerName:"dataLayer",...e},delete this.options.id}enabled(){return this.options.enabled??!0}enable(e=!0,t){if(this.options.enabled=e,this.isInBrowserContext()&&e&&!g4(t)&&this.options.loadScript)if(Array.isArray(this.id))this.id.forEac
2443h(n=>{let i;typeof n=="string"?i=Cs(n,{...this.options}):i=Cs(n.id,{...this.options,queryParams:n.queryParams}),this.scriptElements.push(i)});else{let n=Cs(this.id,{...this.options});this.scriptElements.push(n)}}debugEnabled(){return this.options.debug??!1}debug(e){this.options.debug=e}dataLayer(){return this.isInBrowserContext()&&this.options.enabled?Qs(window,this.options.dataLayerName):!1}trackView(e,t,n={}){let i=this.isInBrowserContext()&&(this.options.enabled??!1);this.options.debug&&console.log(`[GTM-Support${i?"":"(disabled)"}]: Dispatching TrackView`,{screenName:e,path:t}),i&&Qs(window,this.options.dataLayerName).push({...n,event:this.options.trackViewEventProperty??"content-view","content-name":t,"content-view-name":e})}trackEvent({event:e,category:t=null,action:n=null,label:i=null,value:r=null,noninteraction:s=!1,...a}={}){let o=this.isInBrowserContext()&&(this.options.enabled??!1);this.options.debug&&console.log(`[GTM-Support${o?"":"(disabled)"}]: Dispatching event`,{event:e,category:t,action:n,label:i,value:r,...a}),o&&Qs(window,this.options.dataLayerName).push({event:e??"interaction",target:t,action:n,"target-properties":i,value:r,"interaction-type":s,...a})}push(e){let t=this.isInBrowserContext()&&(this.options.enabled??!1);this.options.debug&&console.log(`[GTM-Support${t?"":"(disabled)"}]: Dispatching event`,e),t&&Qs(window,this.options.dataLayerName).push(e)}},xt;function b4(e,t={id:""}){t={trackOnNextTick:!1,...t},xt=new y4(t),e.config.globalProperties.$gtm=xt,xt.isInBrowserContext()&&(t.vueRouter&&v4(e,t.vueRouter,t.ignoredViews,t.trackOnNextTick,t.vueRouterAdditionalEventData),xt.options.enabled&&xt.options.loadScript&&(Array.isArray(t.id)?t.id.forEach(n=>{if(typeof n=="string")Cs(n,t);else{let i={...t};n.queryParams!=null&&(i.queryParams={...i.queryParams,...n.queryParams}),Cs(n.id,i)}}):Cs(t.id,t))),e.provide("gtm",t)}function v4(e,t,n=[],i,r=()=>({})){function s(a,o){return a instanceof Error?!!(a.type&o):!1}t.afterEach(async(a,o,l)=>{var p,h,m;if(typeof a.name!="string"||Array.isArray(n)&&n.includes(a.name)||typeof n=="function"&&n(a,o))return;let c=a.meta&&typeof a.meta.gtm=="string"&&a.meta.gtm?a.meta.gtm:a.name;s(l,4)?xt!=null&&xt.debugEnabled()&&console.log(`[VueGtm]: '${c}' not tracked due to navigation aborted`):s(l,8)&&(xt!=null&&xt.debugEnabled())&&console.log(`[VueGtm]: '${c}' not tracked due to navigation cancelled`);let d={...await r(a,o),...(p=a.meta)==null?void 0:p.gtmAdditionalEventData},u=((m=(h=t.options)==null?void 0:h.history)==null?void 0:m.base)??"";u.endsWith("/")||(u+="/"),u+=a.fullPath.startsWith("/")?a.fullPath.substring(1):a.fullPath,i?kt(()=>{xt==null||xt.trackView(c,u,d)}):xt==null||xt.trackView(c,u,d)})}function _4(e){return{install:t=>b4(t,e)}}const w4=_t(e=>{let t="",n=se();const r=On().path;
2443if(!(r==="/optician-vto"||r.startsWith("/plugins/"))){if(n.includes("kits.ca")&&(t="GTM-WGVQHHK"),n.includes("kits.com")&&(t="GTM-59T77DM"),n.includes("opticontacts.com")&&(t="GTM-WRHGPFW"),n.includes("contactsexpress.ca")&&(t="GTM-PVMFLV6"),n.includes("postalcontacts.com")&&(t="GTM-KQ3Q9X9"),!t){console.warn("[GTM] No matching GTM container for domain:",n);return}n.includes(".camp.")||e.vueApp.use(_4({id:t}))}}),E4=_t(e=>{e.$pinia.use(({store:t})=>{t.$i18n=e.$i18n})}),S4=_t({hooks:{"app:mounted"(){Me({link:[{rel:"stylesheet",href:"https://fonts.googleapis.com/css2?family=Outfit:wght@100;200;300;400;500;600;700;800;900&display=swap"}]})}}}),C4=Ge({__name:"vueRecaptcha",props:{sitekey:{type:String,required:!0},size:{type:String,required:!1,default:"normal"},theme:{type:String,required:!1,default:"light"},hl:{type:String,required:!1},loadingTimeout:{type:Number,required:!1,default:0}},emits:{verify:e=>e!=null&&e!="",error:e=>e,expire:null,fail:null},setup(e,{expose:t,emit:n}){const i=e,r=Re(null);let s=null;t({execute:function(){window.grecaptcha.execute(s)},reset:function(){window.grecaptcha.reset(s)}});function a(){s=window.grecaptcha.render(r.value,{sitekey:i.sitekey,theme:i.theme,size:i.size,callback:o=>n("verify",o),"expired-callback":()=>n("expire"),"error-callback":()=>n("fail")})}return vt(()=>{window.grecaptcha==null?new Promise((o,l)=>{let c,d=!1;window.recaptchaReady=function(){d||(d=!0,clearTimeout(c),o())};const u="recaptcha-script",p=v=>()=>{var _;d||(d=!0,clearTimeout(c),(_=document.getElementById(u))==null||_.remove(),l(v))};i.loadingTimeout>0&&(c=setTimeout(p("timeout"),i.loadingTimeout));const h=window.document,m=h.createElement("script");m.id=u,m.onerror=p("error"),m.onabort=p("aborted"),m.setAttribute("src",`https://www.google.com/recaptcha/api.js?onload=recaptchaReady&render=explicit&hl=${i.hl}&_=${+new Date}`),h.head.appendChild(m)}).then(()=>{a()}).catch(o=>{n("error",o)}):a()}),(o,l)=>(g(),S("div",{ref_key:"recaptchaDiv",ref:r},null,512))}}),I4=_t(e=>{e.vueApp.component("vue-recaptcha",C4)}),T4=_t(e=>{}),P4=_t({hooks:{"app:mounted"(){Me({script:[]})}}}),O4=[U1,z1,o_,l_,c_,R_,L_,N_,$E,HE,nS,hS,pS,UO,p4,f4,m4,w4,E4,S4,I4,T4,P4],A4=Ge({props:{vnode:{type:Object,required:!0},route:{type:Object,required:!0},vnodeRef:Object,renderKey:String,trackRootNodes:Boolean},setup(e){const t=e.renderKey,n=e.route,i={};for(const r in e.route)Object.defineProperty(i,r,{get:()=>t===e.renderKey?e.route[r]:n[r]});return Hn(Ar,Ir(i)),()=>gn(e.vnode,{ref:e.vnodeRef})}}),k4=Ge({name:"NuxtPage",inheritAttrs:!1,props:{name:{type:String},transition:{type:[Boolean,Object],default:void 0},keepalive:{type:[Boolean,Object],default:void 0},route:{type:Object},pageKey:{type:[Function,String],default:null}},setup(e,{attrs:t,expose:n}){const i=ct(),r=Re(),s=Ft(Ar,null);let a;n({pageRef:r});const o=Ft(Lb,null);let l;const c=i.deferHydration();if(i.isHydrating){const d=i.hooks.hookOnce("app:error",c);dn().beforeEach(d)}return e.pageKey&&We(()=>e.pageKey,(d,u)=>{d!==u&&i.callHook("page:loading:start")}),()=>gn(Bh,{name:e.name,route:e.route,...t},{default:d=>{const u=L4(s,d.route,d.Component),p=s&&s.matched.length===d.route.matched.length;if(!d.Component){if(l&&!p)return l;c();return}if(l&&o&&!o.isCurrent(d.route))return l;if(u&&s&&(!o||o!=null&&o.isCurrent(s)))return p?l:null;const h=ao(d,e.pageKey);!i.isHydrating&&!N4(s,d.route,d.Component)&&a===h&&i.callHook("page:loading:end"),a=h;const m=!!(e.transition??d.route.meta.pageTransition??no),v=m&&R4([e.transition,d.route.meta.pageTransition,no,{onAfterLeave:()=>{i.callHook("page:transition:finish",d.Component)}}].filter(Boolean)),_=e.keepalive??d.route.meta.keepalive??R1;return l=Xv($t,m&&v,Qv(_,gn(Ku,{suspensible:!0,onPending:()=>i.callHook("page:start",d.Component),onResolve:()=>{kt(()=>i.callHook("page:finish",d.Component).then(()=>i.callHook("page:loading:end")).finally(c))}},{default:()=>{const b=gn(A4,{key:h||void 0,vnode:d.Component,route:d.route,renderKey:h||void 0,trackRootNodes:m,vnodeRef:r});return _&&(b.type.name=d.Component.type.name||d.Component.type.__name||"RouteProvider"),b}}))).default(),l}}
2443)}});function R4(e){const t=e.map(n=>({...n,onAfterLeave:n.onAfterLeave?qo(n.onAfterLeave):void 0}));return ch(...t)}function L4(e,t,n){if(!e)return!1;const i=t.matched.findIndex(r=>{var s;return((s=r.components)==null?void 0:s.default)===(n==null?void 0:n.type)});return!i||i===-1?!1:t.matched.slice(0,i).some((r,s)=>{var a,o,l;return((a=r.components)==null?void 0:a.default)!==((l=(o=e.matched[s])==null?void 0:o.components)==null?void 0:l.default)})||n&&ao({route:t,Component:n})!==ao({route:e,Component:n})}function N4(e,t,n){return e?t.matched.findIndex(r=>{var s;return((s=r.components)==null?void 0:s.default)===(n==null?void 0:n.type)})<t.matched.length-1:!1}const xl=e=>String(e??"").replace(/<(br|\/p|\/div|\/li|\/tr|\/h[1-6])\s*\/?>/gi," ").replace(/<[^>]*>/g,"").replace(/\s+/g," ").trim(),bn=e=>Array.isArray(e)?e.map(bn).filter(t=>t!==void 0):e===null||typeof e!="object"?e:Object.entries(e).reduce((t,[n,i])=>{if(i==null||i==="")return t;const r=bn(i);return Array.isArray(r)&&r.length===0||(t[n]=r),t},{}),D4=e=>bn({"@type":"Organization","@id":`${e.origin}/#organization`,name:e.siteName,legalName:e.legalName,url:e.origin,logo:{"@type":"ImageObject",url:rn(e,e.logo)},sameAs:e.sameAs}),x4=e=>bn({"@type":"WebSite","@id":`${e.origin}/#website`,name:e.siteName,url:e.origin,inLanguage:e.locale,publisher:{"@id":`${e.origin}/#organization`}}),M4=(e,t)=>{const{name:n,description:i,brand:r,sku:s,mpn:a,url:o,path:l,images:c=[],price:d,discountedPrice:u=null,currency:p=e.currency,availability:h="https://schema.org/InStock",rating:m=null,extra:v={}}=t,_=u!=null,b=(_?u:d)!==null&&(_?u:d)!==void 0;return bn({"@type":"Product",name:n,description:xl(i),sku:s,mpn:a,brand:r?{"@type":"Brand",name:r}:void 0,url:rn(e,o??l),image:c.map(w=>rn(e,w)),offers:b?{"@type":"Offer",url:rn(e,o??l),availability:h,price:_?u:d,priceCurrency:p,seller:{"@id":`${e.origin}/#organization`},priceSpecification:_?{"@type":"UnitPriceSpecification",priceType:"https://schema.org/StrikethroughPrice",price:d,priceCurrency:p}:void 0}:void 0,aggregateRating:m&&m.count?{"@type":"AggregateRating",ratingValue:m.value,reviewCount:m.count}:void 0,...v})},FX=(e,t)=>{const{name:n,description:i,brand:r,sku:s,url:a,path:o,images:l=[],price:c,discountedPrice:d=null,currency:u=e.currency,rating:p=null,variants:h=[],variantUrl:m}=t,v=rn(e,a??o),_=v.split("?")[0],b=m??(C=>`${_}?config=${tu(C)}`),w=h.map(C=>{const O=tu(C);if(!O)return null;const T=C.price??null,E=C.discounted_price??C.discount_price??null,y=T??c??null,P=E??(T===null?d:null);return M4(e,{name:F4(n,C),description:i,brand:r,sku:s,url:b(C),images:C.image_url?[C.image_url]:[],price:y,discountedPrice:P,currency:u,availability:C.soldout||C.greydout?"https://schema.org/OutOfStock":"https://schema.org/InStock",extra:{inProductGroupWithID:s,productID:O,color:C.color,additionalProperty:V4(C)}})}).filter(Boolean);return bn({"@type":"ProductGroup",name:n,description:xl(i),brand:r?{"@type":"Brand",name:r}:void 0,url:v,image:l.map(C=>rn(e,C)),productGroupID:s,variesBy:B4(h),aggregateRating:p&&p.count?{"@type":"AggregateRating",ratingValue:p.value,reviewCount:p.count}:void 0,hasVariant:w})},tu=e=>e.configuration_id??e.config_id??null,F4=(e,t)=>{const n=[t.lens_color,t.lens_type].filter(Boolean).join(" "),i=[t.color,n&&`${n} Lenses`].filter(Boolean).join(" with ");return i?`${e} - ${i}`:e},V4=e=>[e.lens_color&&{"@type":"PropertyValue",name:"Lens colour",value:e.lens_color},e.lens_type&&{"@type":"PropertyValue",name:"Lens type",value:e.lens_type}].filter(Boolean),B4=e=>{const t=i=>new Set(e.map(r=>r[i]).filter(Boolean)).size,n=[];return t("color")>1&&n.push("https://schema.org/color"),n},VX=(e,t=[])=>bn({"@type":"BreadcrumbList",itemListElement:t.map((n,i)=>({"@type":"ListItem",position:i+1,name:n.name,item:n.path||n.url?rn(e,n.url??n.path):void 0}))}),BX=(e,{name:t,description:n,url:i,path:r}={})=>bn({"@type":"WebPage",name:t,url:i||r?rn(e,i??r):void 0,description:n}),$X=({name:e,description:t,steps:n=[]}={})=>bn({"@type":"HowTo",name:e,description:t,step:n.map(i=>({"@type":"HowToStep",name:i.name,text:i.text}))}),UX=(e={})=>{const t=Number(e.aggregate_review),n=Number(e.reviews_count);return!Number.isFinite(n)||n<1||!Number.isFinite(t)||t<=0||t>5?null:{value:Math.round(t*10)/10,count:n}},HX=(e=[])=>bn({"@type":"FAQPage",mainEntity:e.map(t=>
2443({"@type":"Question",name:t.question,acceptedAnswer:{"@type":"Answer",text:xl(t.answer)}}))}),$4=(e={})=>{const{pageId:t="default",title:n,description:i,path:r,canonical:s,alternates:a=!0,noindex:o=!1,ogType:l="website",ogTitle:c,ogDescription:d,images:u=[],schemas:p=[],key:h="seo"}=e,m=Jr(),v=It(),_=ef(m),b=VI(r??v.pathname,m),w=s===!1?null:s??rn(m,`${_}${b}`),C=n===!1?null:n??Dd(m,t,"title"),O=i===!1?null:i??Dd(m,t,"description"),T=o||!m.isProduction,E=w?[{rel:"canonical",href:w}]:[];w&&a&&!s&&(m.alternates??[]).forEach(D=>{const z=rn(m,`${D.prefix}${b}`);E.push({rel:"alternate",hreflang:D.hreflang,href:z,key:`hreflang-${D.hreflang}`}),D.xDefault&&E.push({rel:"alternate",hreflang:"x-default",href:z,key:"hreflang-x-default"})});const y={htmlAttrs:{lang:m.locale}};E.length&&(y.link=E),C&&(y.title=C),T&&(y.meta=[{name:"robots",content:"noindex, nofollow"}]),Me(y);const P=(Array.isArray(u)?u:[u]).map(D=>typeof D=="string"?D:D==null?void 0:D.image).filter(Boolean).map(D=>rn(m,D)),A={ogType:l,ogSiteName:m.siteName,twitterCard:"summary_large_image"};w&&(A.ogUrl=w),m.locale&&(A.ogLocale=m.locale.replace("-","_")),m.twitterHandle&&(A.twitterSite=m.twitterHandle);const I=c??C,L=d??O;return I&&(A.ogTitle=I,A.twitterTitle=I),O&&(A.description=O),L&&(A.ogDescription=L,A.twitterDescription=L),P.length&&(A.ogImage=P,A.twitterImage=P[0]),O1(A),Wm(p,{key:h,site:m,canonical:w}),{site:m,canonical:w}},Wm=(e=[],t={})=>{const n=t.site??Jr(),i=t.key??"seo",r=o=>{const l=(Array.isArray(o)?o:[o]).map(c=>typeof c=="function"?c(n,t.canonical):c).filter(c=>c&&Object.keys(c).length);return l.length?JSON.stringify({"@context":"https://schema.org","@graph":l}).replace(/</g,"\\u003C"):""},s=typeof e=="function",a=s?ee(()=>r(e())):r(e);!s&&!a||Me({script:[{key:`ld-json-${i}`,type:"application/ld+json",innerHTML:a}]})},U4=()=>{const e=Jr();return Wm([D4(e),x4(e)],{key:"site",site:e}),$4({pageId:"default",canonical:!1,key:"site-default"})},H4=()=>{const e=D6();ie().systemStore.$subscribe((t,n)=>{if(t.payload)switch(t.payload.toastMessage.type){case"ERROR":e.add({severity:"error",summary:"Error",detail:`${t.payload.toastMessage.payload}`,life:t.payload.toastMessage.life});break;case"SUCCESS":e.add({severity:"success",summary:"Success",detail:`${t.payload.toastMessage.payload}`,life:t.payload.toastMessage.life});break;case"WARNING":e.add({severity:"warn",summary:"Warning",detail:`${t.payload.toastMessage.payload}`,life:t.payload.toastMessage.life});break;case"INFO":e.add({severity:"info",summary:"Info",detail:`${t.payload.toastMessage.payload}`,life:t.payload.toastMessage.life});break}})};function nu(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);t&&(i=i.filter(function(r){return Object.getOwnPropertyDescriptor(e,r).enumerable})),n.push.apply(n,i)}return n}function _i(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?nu(Object(n),!0).forEach(function(i){z4(e,i,n[i])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):nu(Object(n)).forEach(function(i){Object.defineProperty(e,i,Object.getOwnPropertyDescriptor(n,i))})}return e}function z4(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Er(e){return typeof e=="function"}function Fo(e){return e!==null&&typeof e=="object"&&!Array.isArray(e)}function aa(e){return Er(e.$validator)?_i({},e):{$validator:e}}function Qm(e){return typeof e=="object"?e.$valid:e}function Zm(e){return e.$validator||e}function K4(e,t){if(!Fo(e))throw new Error(`[@vuelidate/validators]: First parameter to "withParams" should be an object, provided ${typeof e}`);if(!Fo(t)&&!Er(t))throw new Error("[@vuelidate/validators]: Validator must be a function or object with $validator parameter");const n=aa(t);return n.$params=_i(_i({},n.$params||{}),e),n}function G4(e,t){if(!Er(e)&&typeof k(e)!="string")throw new Error(`[@vuelidate/validators]: First parameter to "withMessage" should be string or a function returning a string, provided ${typeof e}`);if(!Fo(t)&&!Er(t))throw new Error("[@vuelidate/validators]: Validator must be a function or object with $validator parameter");const n=aa(t);return n.$message=e,n}function j4(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:[];const n=aa(e);return _i(_i({},n),{},{$async:!0,$watchTargets:t})}function Y4(e){return{$validator(t){for(var n=arguments.length,i=new Array(n>1?n-1:0),r=1;r<n;r++)i[r-1]=arguments[r];return k(t).reduce((s,a,o)=>{const l=Object.entries(a).reduce((c,d)=>{let[u,p]=d;const h=e[u]||{},m=Object.entries(h).reduce((v,_)=>{let[b,w]=_;const O=Zm(w).call(this,p,a,o,...i),T=Qm(O);
2443if(v.$data[b]=O,v.$data.$invalid=!T||!!v.$data.$invalid,v.$data.$error=v.$data.$invalid,!T){let E=w.$message||"";const y=w.$params||{};typeof E=="function"&&(E=E({$pending:!1,$invalid:!T,$params:y,$model:p,$response:O})),v.$errors.push({$property:u,$message:E,$params:y,$response:O,$model:p,$pending:!1,$validator:b})}return{$valid:v.$valid&&T,$data:v.$data,$errors:v.$errors}},{$valid:!0,$data:{},$errors:[]});return c.$data[u]=m.$data,c.$errors[u]=m.$errors,{$valid:c.$valid&&m.$valid,$data:c.$data,$errors:c.$errors}},{$valid:!0,$data:{},$errors:{}});return{$valid:s.$valid&&l.$valid,$data:s.$data.concat(l.$data),$errors:s.$errors.concat(l.$errors)}},{$valid:!0,$data:[],$errors:[]})},$message:t=>{let{$response:n}=t;return n?n.$errors.map(i=>Object.values(i).map(r=>r.map(s=>s.$message)).reduce((r,s)=>r.concat(s),[])):[]}}}const ms=e=>{if(e=k(e),Array.isArray(e))return!!e.length;if(e==null)return!1;if(e===!1)return!0;if(e instanceof Date)return!isNaN(e.getTime());if(typeof e=="object"){for(let t in e)return!0;return!1}return!!String(e).length},Ml=e=>(e=k(e),Array.isArray(e)?e.length:typeof e=="object"?Object.keys(e).length:String(e).length);function Zn(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return i=>(i=k(i),!ms(i)||t.every(r=>(r.lastIndex=0,r.test(i))))}var wi=Object.freeze({__proto__:null,forEach:Y4,len:Ml,normalizeValidatorObject:aa,regex:Zn,req:ms,unwrap:k,unwrapNormalizedValidator:Zm,unwrapValidatorResponse:Qm,withAsync:j4,withMessage:G4,withParams:K4});Zn(/^[a-zA-Z]*$/);Zn(/^[a-zA-Z0-9]*$/);Zn(/^\d*(\.\d+)?$/);const W4=/^(?:[A-z0-9!#$%&'*+/=?^_`{|}~-]+(?:\.[A-z0-9!#$%&'*+/=?^_`{|}~-]+)*|"(?:[\x01-\x08\x0b\x0c\x0e-\x1f\x21\x23-\x5b\x5d-\x7f]|[\x01-\x09\x0b\x0c\x0e-\x7f])*")@(?:(?:[a-z0-9](?:[a-z0-9-]*[a-z0-9])?\.)+[a-z0-9]{2,}(?:[a-z0-9-]*[a-z0-9])?|\[(?:(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\.){3}(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?|[a-z0-9-]*[a-z0-9]:(?:[\x01-\x08\x0b\x0c\x0e-\x1f\x21-\x5a\x53-\x7f]|\\[\x01-\x09\x0b\x0c\x0e-\x7f])+)\])$/i;var Q4=Zn(W4),Fl={$validator:Q4,$message:"Value is not a valid email address",$params:{type:"email"}};function Z4(e){return t=>!ms(t)||Ml(t)<=k(e)}function zX(e){return{$validator:Z4(e),$message:t=>{let{$params:n}=t;return`The maximum length allowed is ${n.max}`},$params:{max:e,type:"maxLength"}}}function q4(e){return t=>!ms(t)||Ml(t)>=k(e)}function KX(e){return{$validator:q4(e),$message:t=>{let{$params:n}=t;return`This field should be at least ${n.min} characters long`},$params:{min:e,type:"minLength"}}}function J4(e){return typeof e=="string"&&(e=e.trim()),ms(e)}var Ei={$validator:J4,$message:"Value is required",$params:{type:"required"}};const X4=/^(?:(?:(?:https?|ftp):)?\/\/)(?:\S+(?::\S*)?@)?(?:(?!(?:10|127)(?:\.\d{1,3}){3})(?!(?:169\.254|192\.168)(?:\.\d{1,3}){2})(?!172\.(?:1[6-9]|2\d|3[0-1])(?:\.\d{1,3}){2})(?:[1-9]\d?|1\d\d|2[01]\d|22[0-3])(?:\.(?:1?\d{1,2}|2[0-4]\d|25[0-5])){2}(?:\.(?:[1-9]\d?|1\d\d|2[0-4]\d|25[0-4]))|(?:(?:[a-z0-9\u00a1-\uffff][a-z0-9\u00a1-\uffff_-]{0,62})?[a-z0-9\u00a1-\uffff]\.)+(?:[a-z\u00a1-\uffff]{2,}\.?))(?::\d{2,5})?(?:[/?#]\S*)?$/i;Zn(X4);function eD(e){return t=>!ms(t)||(!/\s/.test(t)||t instanceof Date)&&+t>=+k(e)}function GX(e){return{$validator:eD(e),$message:t=>{let{$params:n}=t;return`The minimum value allowed is ${n.min}`},$params:{min:e,type:"minValue"}}}function tD(e){return t=>!ms(t)||(!/\s/.test(t)||t instanceof Date)&&+t<=+k(e)}var jX=e=>({$validator:tD(e),$message:t=>{let{$params:n}=t;return`The maximum value allowed is ${n.max}`},$params:{max:e,type:"maxValue"}});Zn(/(^[0-9]*$)|(^-[0-9]+$)/);Zn(/^[-]?\d*(\.\d+)?$/);function su(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);t&&(i=i.filter(function(r){return Object.getOwnPropertyDescriptor(e,r).enumerable})),n.push.apply(n,i)}return n}function Fn(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?su(Object(n),!0).forEach(function(i){nD(e,i,n[i])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):su(Object(n)).forEach(function(i){Object.defineProperty(e,i,Object.getOwnPropertyDescriptor(n,i))})}return e}function nD(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function iu(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:[];return Object.keys(e).reduce((n,i)=>(t.includes(i)||(n[i]=k(e[i])),n),{})}function Sr(e){return typeof e=="function"}function sD(e){return Uo(e)||Uu(e)}function qm(e,t,n){let i=e;const r=t.split(".");for(let s=0;s<r.length;s++){if(!i[r[s]])return n;i=i[r[s]]}return i}function Ua(e,t,n){return ee(()=>e.some(i=>qm(t,i,{[n]:!1})[n]))}function ru(e,t,n){return ee(()=>e.reduce((i,r)=>{const s=qm(t,r,{[n]:!1})[n]||[];return i.concat(s)},[]))}function Jm(e,t,n,i){return e.call(i,k(t),k(n),i)}function Xm(e){return e.$valid!==void 0?!e.$valid:!e}function iD(e,t,n,i,r,s,a){let{$lazy:o,$rewardEarly:l}=r,c=arguments.length>7&&arguments[7]!==void 0?arguments[7]:[],d=arguments.length>8?arguments[8]:void 0,u=arguments.length>9?arguments[9]:void 0,p=arguments.length>10?arguments[10]:void 0;const h=Re(!!i.value),m=Re(0);n.value=!1;const v=We([t,i].concat(c,p),()=>{if(o&&!i.value||l&&!u.value&&!n.value)return;let _;try{_=Jm(e,t,d,a)}catch(b){_=Promise.reject(b)}m.value++,n.value=!!m.value,h.value=!1,Promise.resolve(_).then(b=>{m.value--,n.value=!!m.value,s.value=b,h.value=Xm(b)}).catch(b=>{m.value--,n.value=!!m.value,s.value=b,h.value=!0})},{immediate:!0,deep:typeof t=="object"});
vendor: 4,095 bytes, line 2443
2443return{$invalid:h,$unwatch:v}}function rD(e,t,n,i,r,s,a,o){let{$lazy:l,$rewardEarly:c}=i;const d=()=>({}),u=ee(()=>{if(l&&!n.value||c&&!o.value)return!1;let p=!0;try{const h=Jm(e,t,a,s);r.value=h,p=Xm(h)}catch(h){r.value=h}return p});return{$unwatch:d,$invalid:u}}function aD(e,t,n,i,r,s,a,o,l,c,d){const u=Re(!1),p=e.$params||{},h=Re(null);let m,v;e.$async?{$invalid:m,$unwatch:v}=iD(e.$validator,t,u,n,i,h,r,e.$watchTargets,l,c,d):{$invalid:m,$unwatch:v}=rD(e.$validator,t,n,i,h,r,l,c);const _=e.$message;return{$message:Sr(_)?ee(()=>_(iu({$pending:u,$invalid:m,$params:iu(p),$model:t,$response:h,$validator:s,$propertyPath:o,$property:a}))):_||"",$params:p,$pending:u,$invalid:m,$response:h,$unwatch:v}}function oD(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};const t=k(e),n=Object.keys(t),i={},r={},s={};let a=null;return n.forEach(o=>{const l=t[o];switch(!0){case Sr(l.$validator):i[o]=l;break;case Sr(l):i[o]={$validator:l};break;case o==="$validationGroups":a=l;break;case o.startsWith("$"):s[o]=l;break;default:r[o]=l}}),{rules:i,nestedValidators:r,config:s,validationGroups:a}}const lD="__root";function cD(e,t,n,i,r,s,a,o,l){const c=Object.keys(e),d=i.get(r,e),u=Re(!1),p=Re(!1),h=Re(0);if(d){if(!d.$partial)return d;d.$unwatch(),u.value=d.$dirty.value}const m={$dirty:u,$path:r,$touch:()=>{u.value||(u.value=!0)},$reset:()=>{u.value&&(u.value=!1)},$commit:()=>{}};return c.length?(c.forEach(v=>{m[v]=aD(e[v],t,m.$dirty,s,a,v,n,r,l,p,h)}),m.$externalResults=ee(()=>o.value?[].concat(o.value).map((v,_)=>({$propertyPath:r,$property:n,$validator:"$externalResults",$uid:`${r}-externalResult-${_}`,$message:v,$params:{},$response:null,$pending:!1})):[]),m.$invalid=ee(()=>{const v=c.some(_=>k(m[_].$invalid));return p.value=v,!!m.$externalResults.value.length||v}),m.$pending=ee(()=>c.some(v=>k(m[v].$pending))),m.$error=ee(()=>m.$dirty.value?m.$pending.value||m.$invalid.value:!1),m.$silentErrors=ee(()=>c.filter(v=>k(m[v].$invalid)).map(v=>{const _=m[v];return Wt({$propertyPath:r,$property:n,$validator:v,$uid:`${r}-${v}`,$message:_.$message,$params:_.$params,$response:_.$response,$pending:_.$pending})}).concat(m.$externalResults.value)),m.$errors=ee(()=>m.$dirty.value?m.$silentErrors.value:[]),m.$unwatch=()=>c.forEach(v=>{m[v].$unwatch()}),m.$commit=()=>{p.value=!0,h.value=Date.now()},i.set(r,e,m),m):(d&&i.set(r,e,m),m)}function dD(e,t,n,i,r,s,a){const o=Object.keys(e);return o.length?o.reduce((l,c)=>(l[c]=Vo({validations:e[c],state:t,key:c,parentKey:n,resultsCache:i,globalConfig:r,instance:s,externalResults:a}),l),{}):{}}function uD(e,t,n){const i=ee(()=>[t,n].filter(m=>m).reduce((m,v)=>m.concat(Object.values(k(v))),[])),r=ee({get(){return e.$dirty.value||(i.value.length?i.value.every(m=>m.$dirty):!1)},set(m){e.$dirty.value=m}}),s=ee(()=>{const m=k(e.$silentErrors)||[],v=i.value.filter(_=>(k(_).$silentErrors||[]).length).reduce((_,b)=>_.concat(...b.$silentErrors),[]);return m.concat(v)}),a=ee(()=>{const m=k(e.$errors)||[],v=i.value.filter(_=>(k(_).$errors||[]).length).reduce((_,b)=>_.concat(...b.$errors),[]);return m.concat(v)}),o=ee(()=>i.value.some(m=>m.$invalid)||k(e.$invalid)||!1),l=ee(()=>i.value.some(m=>k(m.$pending))||k(e.$pending)||!1),c=ee(()=>i.value.some(m=>m.$dirty)||i.value.some(m=>m.$anyDirty)||r.value),d=ee(()=>r.value?l.value||o.value:!1),u=()=>{e.$touch(),i.value.forEach(m=>{m.$touch()})},p=()=>{e.$commit(),i.value.forEach(m=>{m.$commit()})},h=()=>{e.$reset(),i.value.forEach(m=>{m.$reset()})};return i.value.length&&i.value.every(m=>m.$dirty)&&u(),{$dirty:r,$errors:a,$invalid:o,$anyDirty:c,$error:d,$pending:l,$touch:u,$reset:h,$silentErrors:s,$commit:p}}function Vo(e){let{validations:t,state:n,key:i,parentKey:r,childResults:s,resultsCache:a,globalConfig:o={},instance:l,externalResults:c}=e;const d=r?`${r}.${i}`:i,{rules:u,nestedValidators:p,config:h,validationGroups:m}=oD(t),v=Fn(Fn({},o),h),_=i?ee(()=>{const V=k(n);return V?k(V[i]):void 0}):n,b=Fn({},k(c)||{}),w=ee(()=>{const V=k(c);return i?V?k(V[i]):void 0:V}),C=cD(u,_,i,a,d,v,l,w,n),O=dD(p,_,d,a,v,l,w),T={};m&&Object.entries(m).forEach(V=>{let[te,fe]=V;
2443T[te]={$invalid:Ua(fe,O,"$invalid"),$error:Ua(fe,O,"$error"),$pending:Ua(fe,O,"$pending"),$errors:ru(fe,O,"$errors"),$silentErrors:ru(fe,O,"$silentErrors")}});const{$dirty:E,$errors:y,$invalid:P,$anyDirty:A,$error:I,$pending:L,$touch:D,$reset:z,$silentErrors:G,$commit:ne}=uD(C,O,s),W=i?ee({get:()=>k(_),set:V=>{E.value=!0;const te=k(n),fe=k(c);fe&&(fe[i]=b[i]),Jt(te[i])?te[i].value=V:te[i]=V}}):null;i&&v.$autoDirty&&We(_,()=>{E.value||D();const V=k(c);V&&(V[i]=b[i])},{flush:"sync"});async function ue(){return D(),v.$rewardEarly&&(ne(),await kt()),await kt(),new Promise(V=>{if(!L.value)return V(!P.value);const te=We(L,()=>{V(!P.value),te()})})}function H(V){return(s.value||{})[V]}function x(){Jt(c)?c.value=b:Object.keys(b).length===0?Object.keys(c).forEach(V=>{delete c[V]}):Object.assign(c,b)}return Wt(Fn(Fn(Fn({},C),{},{$model:W,$dirty:E,$error:I,$errors:y,$invalid:P,$anyDirty:A,$pending:L,$touch:D,$reset:z,$path:d||lD,$silentErrors:G,$validate:ue,$commit:ne},s&&{$getResultsForChild:H,$clearExternalResults:x,$validationGroups:T}),O))}class hD{constructor(){this.storage=new Map}set(t,n,i){this.storage.set(t,{rules:n,result:i})}checkRulesValidity(t,n,i){const r=Object.keys(i),s=Object.keys(n);return s.length!==r.length||!s.every(o=>r.includes(o))?!1:s.every(o=>n[o].$params?Object.keys(n[o].$params).every(l=>k(i[o].$params[l])===k(n[o].$params[l])):!0)}get(t,n){const i=this.storage.get(t);if(!i)return;const{rules:r,result:s}=i,a=this.checkRulesValidity(t,n,r),o=s.$unwatch?s.$unwatch:()=>({});return a?s:{$dirty:s.$dirty,$partial:!0,$unwatch:o}}}const nr={COLLECT_ALL:!0,COLLECT_NONE:!1},au=Symbol("vuelidate#injectChildResults"),ou=Symbol("vuelidate#removeChildResults");function pD(e){let{$scope:t,instance:n}=e;const i={},r=Re([]),s=ee(()=>r.value.reduce((d,u)=>(d[u]=k(i[u]),d),{}));function a(d,u){let{$registerAs:p,$scope:h,$stopPropagation:m}=u;m||t===nr.COLLECT_NONE||h===nr.COLLECT_NONE||t!==nr.COLLECT_ALL&&t!==h||(i[p]=d,r.value.push(p))}n.__vuelidateInjectInstances=[].concat(n.__vuelidateInjectInstances||[],a);function o(d){r.value=r.value.filter(u=>u!==d),delete i[d]}n.__vuelidateRemoveInstances=[].concat(n.__vuelidateRemoveInstances||[],o);const l=Ft(au,[]);Hn(au,n.__vuelidateInjectInstances);const c=Ft(ou,[]);return Hn(ou,n.__vuelidateRemoveInstances),{childResults:s,sendValidationResultsToParent:l,removeValidationResultsFromParent:c}}function eg(e){return new Proxy(e,{get(t,n){return typeof t[n]=="object"?eg(t[n]):ee(()=>t[n])}})}let lu=0;function oa(e,t){var n;let i=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};arguments.length===1&&(i=e,e=void 0,t=void 0);let{$registerAs:r,$scope:s=nr.COLLECT_ALL,$stopPropagation:a,$externalResults:o,currentVueInstance:l}=i;const c=l||((n=ln())===null||n===void 0?void 0:n.proxy),d=c?c.$options:{};r||(lu+=1,r=`_vuelidate_${lu}`);const u=Re({}),p=new hD,{childResults:h,sendValidationResultsToParent:m,removeValidationResultsFromParent:v}=c?pD({$scope:s,instance:c}):{childResults:Re({})};if(!e&&d.validations){const _=d.validations;t=Re({}),zu(()=>{t.value=c,We(()=>Sr(_)?_.call(t.value,new eg(t.value)):_,b=>{u.value=Vo({validations:b,state:t,childResults:h,resultsCache:p,globalConfig:i,instance:c,externalResults:o||c.vuelidateExternalResults})},{immediate:!0})}),i=d.validationsConfig||i}else{const _=Jt(e)||sD(e)?e:Wt(e||{});We(_,b=>{u.value=Vo({validations:b,state:t,childResults:h,resultsCache:p,globalConfig:i,instance:c??{},externalResults:o})},{immediate:!0})}return c&&(m.forEach(_=>_(u,{$registerAs:r,$scope:s,$stopPropagation:a})),Cr(()=>v.forEach(_=>_(r)))),ee(()=>Fn(Fn({},k(u.value)),h.value))}function cu(e){const t=e;t.__i18n=t.__i18n||[],t.__i18n.push({locale:"",resource:{en:{"lens-flow-login":{"login-button":{t:0,b:{t:2,i:[{t:3}],s:"Returning Customer? Login for express options"}},form:{"login-title":{t:0,b:{t:2,i:[{t:3}],s:"Login"}},"login-description":{t:0,b:{t:2,i:[{t:3}],s:"Log into your account for a faster checkout process"}},email:{t:0,b:{t:2,i:[{t:3}],s:"Email"}},password:{t:0,b:{t:2,i:[{t:3}],s:"Password"}},"invalid-email":{t:0,b:{t:2,i:[{t:3}],s:"*Valid email is required:"}},"required-email":{t:0,b:{t:2,i:[{t:3}],s:"*Email is required"}},"required-password":{t:0,b:{t:2,i:[{t:3}],s:"*Password field is required"}},"forgot-password":{t:0,b:{t:2,i:[{t:3}],s:"Forgot Your Password?"}}}}}}})}const Ke=(e,t)=>{const n=e.__vccOpts||e;for(const[i,r]of t)n[i]=r;return n},tg=Ge({setup(e,{expose:t}){const{t:n}=rt({useScope:"local"}),i=ie(),r=Re(!1),s=Re(!1),a=Re(!1),o=Re({loginEmail:"",loginPassword:""}),l={loginEmail:{required:wi.withMessage("*Email is required",Ei),email:Fl},loginPassword:{required:wi.withMessage("*Password field is required",Ei)}},c=oa(l,o),d=async h=>{if(s.value=!0,!h)return;a.value=!0;const m=await i.glassesStore.loginLensFlow({username:o.value.loginEmail,password:o.value.loginPassword});a.value=!1,m&&p()},u=()=>{r.value=!0},p=()=>{r.value=!1};
2443return t({openLoginDialog:u,closeLoginDialog:p}),{t:n,v$:c,loginVisible:r,submitted:s,formFields:o,formRules:l,onSubmitLogIn:d,isLoginLoading:a}}}),fD={class:"flex flex-column w-full mb-3 login-lens-flow"},mD={class:"m-0 pb-2 pt-4 relative"},gD={class:"text-center"},yD={class:"mb-2 h-font-size-24 h-font-weight-600"},bD={class:"grid px-3 mx-0"},vD={class:"col-12 sm:col-6 mt-3"},_D={class:"p-float-label h-font-size-14"},wD={class:"p-float-label"},ED={for:"loginEmail",class:"h-font-size-14"},SD={key:0,class:"p-error h-font-size-12"},CD={key:1,class:"p-error h-font-size-12"},ID={class:"col-12 sm:col-6 mt-3"},TD={class:"p-float-label h-font-size-14"},PD={class:"p-float-label"},OD={for:"loginPassword",class:"h-font-size-14"},AD={key:0,class:"p-error h-font-size-12"},kD={class:"col-12 mt-2 text-center h-font-size-14"},RD={href:"/lost_password",target:"_blank",class:"h-color-link h-font-weight-600"},LD={class:"col-12 text-center"};function ND(e,t,n,i,r,s){const a=le("InputText"),o=le("Password"),l=le("Button"),c=le("Dialog");return g(),S("div",fD,[de(c,{visible:e.loginVisible,"onUpdate:visible":t[4]||(t[4]=d=>e.loginVisible=d),modal:"",draggable:!1,style:{width:"50rem"},breakpoints:{"1199px":"75vw",575:"90vw"},appendTo:".login-lens-flow"},{default:Ee(()=>[f("div",mD,[f("i",{onClick:t[0]||(t[0]=d=>e.loginVisible=!1),class:"pi pi-times h-font-size-18 absolute right-0 top-0 cursor-pointer mr-2 mt-2"}),f("div",gD,[f("div",yD,N(e.t("lens-flow-login.form.login-title")),1),f("div",null,N(e.t("lens-flow-login.form.login-description")),1)]),f("form",{onSubmit:t[3]||(t[3]=st(d=>e.onSubmitLogIn(!e.v$.$invalid),["prevent"]))},[f("div",bD,[f("div",vD,[f("span",_D,[f("span",wD,[de(a,{id:"loginEmail",class:Oe(["w-full h-color-primary",{"p-invalid":e.v$.loginEmail.$invalid&&e.submitted,"p-valid":e.v$.loginEmail.$dirty&&!e.v$.loginEmail.$invalid}]),modelValue:e.v$.loginEmail.$model,"onUpdate:modelValue":t[1]||(t[1]=d=>e.v$.loginEmail.$model=d)},null,8,["modelValue","class"]),f("label",ED,N(e.t("lens-flow-login.form.email")),1)]),e.v$.loginEmail.required.$invalid&&e.submitted||e.v$.loginEmail.$pending.$response?(g(),S("div",SD,N(e.v$.loginEmail.required.$message),1)):M("",!0),e.v$.loginEmail.email.$invalid&&e.submitted||e.v$.loginEmail.$pending.$response?(g(),S("div",CD,N(e.t("lens-flow-login.form.invalid-email"))+" [email protected] ",1)):M("",!0)])]),f("div",ID,[f("span",TD,[f("span",PD,[de(o,{modelValue:e.v$.loginPassword.$model,"onUpdate:modelValue":t[2]||(t[2]=d=>e.v$.loginPassword.$model=d),inputId:"loginPassword",feedback:!1,toggleMask:"",class:Oe(["login-lens-flow__password",{"p-invalid":e.v$.loginPassword.$invalid&&e.submitted}])},null,8,["modelValue","class"]),f("label",OD,N(e.t("lens-flow-login.form.password")),1)]),e.v$.loginPassword.$invalid&&e.submitted||e.v$.loginPassword.$pending.$response?(g(),S("div",AD,N(e.v$.loginPassword.required.$message),1)):M("",!0)])]),f("div",kD,[f("a",RD,N(e.t("lens-flow-login.form.forgot-password")),1)]),f("div",LD,[de(l,{type:"submit",disabled:e.isLoginLoading,class:"button__primary-kits w-full py-3 uppercase",label:e.t("lens-flow-login.form.login-title")},null,8,["disabled","label"])])])],32)])]),_:1},8,["visible"])])}typeof cu=="function"&&cu(tg);const DD=Ke(tg,[["render",ND]]),xD={key:0},MD={class:"flex justify-content-between"},FD={class:"flex flex-row gap-1 lg:gap-2 align-items-center"},VD=["src"],BD=f("span",{class:"lens-flow-optician__gradient-text h-font-size-14 lg:h-font-size-16 h-font-weight-600 text-left"}," Get lens recommendation ",-1),$D=f("span",{class:"hidden lg:block h-color-white h-font-size-12 h-font-weight-500 h-bg-ribbon-blue px-2 py-1 border-round-3xl",style:{"max-height":"24px"}}," New ",-1),UD=f("div",{class:"lens-flow-optician__description h-color-trout h-font-size-14 text-left mt-1"}," Based on your prescription with KITS OpticianAI™ ",-1),HD={key:1},zD={class:"flex flex-row gap-2 align-items-start"},KD={class:"flex justify-content-center align-items-center h-bg-ribbon-blue border-circle",style:{"min-width":"28px",height:"28px"}},GD=["src"],jD={class:"ml-2"},YD=f("span",{class:"lens-flow-optician__gradient-text h-font-size-14 lg:h-font-size-16 h-font-weight-600"}," KITS OpticianAI™ ",-1),WD={class:"h-color-trout h-font-size-14 text-left mt-1"},QD={key:0,class:"mt-1"},ZD=f("span",{class:"h-color-mako-dark h-font-size-14 h-font-weight-700 mt-1"},"Tel:",-1),qD={class:"h-color-mako-dark h-font-size-14 h-font-weight-400 mt-1 ml-1"},JD={key:1},XD=f("span",{class:"h-color-mako-dark h-font-size-14 h-font-weight-700 mt-1"},"Email:",-1),ex={class:"h-color-mako-dark h-font-size-14 h-font-weight-400 mt-1 ml-1 underline"},tx={__name:"LensFlowOpticianCard",props:{description:{type:String,required:!1},isFromFirstStep:{type:Boolean,required:!1}},setup(e){const t=ie(),{imagePath:n}=Be().public,i=ee(()=>t.systemStore.getGenericSiteMetadata),r=ee(()=>t.glassesStore.getRxHasPrism);return(s,a)=>(g(),S("div",{class:Oe(["lens-flow-optician",{"square-left":!e.isFromFirstStep}])},[f("div",{class:Oe(["lens-flow-optician__gradient px-2 lg:px-3 py-2 lg:py-3",{"square-left":!e.isFromFirstStep}])},[e.isFromFirstStep?(g(),S("div",xD,[f("div",MD,[f("div",FD,[f("img",{src:k(n)+"images/pdp/glasses/glassesFlow/stars-optician-gradient.svg",class:"optician-icon 
2443img-responsive"},null,8,VD),BD]),$D]),UD])):(g(),S("div",HD,[f("div",zD,[f("span",KD,[f("img",{src:k(n)+"images/pdp/glasses/glassesFlow/stars-white.svg",class:"img-responsive"},null,8,GD)]),f("div",jD,[YD,f("div",WD,N(e.description),1),k(r)?(g(),S("div",QD,[ZD,f("span",qD,N(k(i).phone_support),1)])):M("",!0),k(r)?(g(),S("div",JD,[XD,f("span",ex,N(k(i).email_support),1)])):M("",!0)])])]))],2)],2))}},nx=e=>(us("data-v-1909868c"),e=e(),hs(),e),sx={class:"w-full bg-white"},ix={class:"lensflow-cta mx-auto p-3 pb-4 flex flex-row justify-content-between gap-2"},rx={class:"mb-2 w-full h-font-weight-600 h-color-mirage-dark h-font-weight-600"},ax={key:0,class:"my-2"},ox=nx(()=>f("span",{class:"h-color-mako-dark"},"Subtotal:",-1)),lx={key:1,class:"h-font-weight-600 h-color-danger mr-2"},cx={key:0,class:"flex align-items-center w-9rem sm:w-13rem gap-3 mt-3"},dx={__name:"LensFlowMobileCTA",props:{isContinueDisabled:{required:!0},isGreyedOut:{required:!1}},emits:["onSubmit"],setup(e,{emit:t}){const n=t,i=ie(),r=ee(()=>i.glassesStore.getFrameDetails),s=ee(()=>i.glassesStore.getLensFlowOptician),a=ee(()=>i.glassesStore.getCurrentLensStep),o=ee(()=>i.glassesStore.getLensFlowSelectedOptions.lensType),l=ee(()=>!Yt(r.value.product_sku)||i.glassesStore.getLensTechnologyPrice>0?0:i.glassesStore.getPreselectedLensTintPrice||0),c=ee(()=>i.glassesStore.getLensOptionPrice),d=ee(()=>i.glassesStore.getLensTechnologyPrice),u=ee(()=>i.glassesStore.getGlassesTypePrice),p=ee(()=>!!Yt(r.value.product_sku)&&i.glassesStore.getPangolinGlassesTypePricesLoading),h=()=>a.value==="lensTechnologies"&&!s.value?"Select and review":a.value!=="lensTechnologies"||!s.value?"Continue":"Add to cart",m=()=>{n("onSubmit")};return(v,_)=>{const b=le("Skeleton"),w=le("Button");return g(),S("div",sx,[f("div",ix,[f("div",{class:Oe(["flex align-items-center w-full",k(a)==="lensTechnologies"?"flex-row justify-content-between gap-2":"flex-column justify-content-center"])},[f("div",{class:Oe(["",k(s)?"p-0":""])},[f("div",{class:Oe(k(a)==="lensTechnologies"?"":"text-center")},[f("div",rx,N(k(r).brand_name)+" "+N(k(r).name.replaceAll(k(r).brand_name,"")),1),k(a)==="lensTechnologies"?(g(),S("div",ax,N(k(o).displayName),1)):M("",!0),ox,k(r).discounted_price?(g(),S("span",lx,[k(p)?(g(),Q(b,{key:0,width:"3.5rem",height:"1.25rem",borderRadius:"4px",class:"inline-block",style:{"vertical-align":"middle"}})):(g(),S(J,{key:1},[ke(" $"+N((k(xd)(k(r).discounted_price,k(c),k(d),k(u))+k(l)).toFixed(2)),1)],64))])):M("",!0),f("span",{class:Oe(["h-color-mirage-dark h-font-weight-600",k(r).discounted_price?"line-through":""])},[k(p)?(g(),Q(b,{key:0,width:"3rem",height:"1.1rem",borderRadius:"4px",class:"inline-block",style:{"vertical-align":"middle"}})):(g(),S(J,{key:1},[ke(" $"+N((k(xd)(k(r).price,k(c),k(d),k(u))+k(l)).toFixed(2)),1)],64))],2)],2)],2),e.isContinueDisabled?M("",!0):(g(),S("div",cx,[de(w,{label:h(),class:"button__primary-kits-v3 w-full max-h-3rem border-1 border-900 px-4 h-bg-primary hover:text-900 hover:bg-white white-space-nowrap",type:"submit",disabled:e.isGreyedOut,onClick:_[0]||(_[0]=C=>m())},null,8,["label","disabled"])]))],2)])])}}},ux=Ke(dx,[["__scopeId","data-v-1909868c"]]);function ng(e){return Ii()?(Is(e),!0):!1}function la(e){return typeof e=="function"?e():k(e)}const sg=typeof window<"u"&&typeof document<"u";typeof WorkerGlobalScope<"u"&&globalThis instanceof WorkerGlobalScope;const hx=Object.prototype.toString,px=e=>hx.call(e)==="[object Object]",sr=()=>{},fx=mx();function mx(){var e,t;return sg&&((e=window==null?void 0:window.navigator)==null?void 0:e.userAgent)&&(/iP(?:ad|hone|od)/.test(window.navigator.userAgent)||((t=window==null?void 0:window.navigator)==null?void 0:t.maxTouchPoints)>2&&/iPad|Macintosh/.test(window==null?void 0:window.navigator.userAgent))}function gx(e,t){function n(...i){return new Promise((r,s)=>{Promise.resolve(e(()=>t.apply(this,i),{fn:t,thisArg:this,args:i})).then(r).catch(s)})}return n}const ig=e=>e();function yx(e=ig){const t=Re(!0);function n(){t.value=!1}function i(){t.value=!0}const r=(...s)=>{t.value&&e(...s)};return{isActive:Gu(t),pause:n,resume:i,eventFilter:r}}function bx(e){return ln()}function vx(e,t,n={}){const{eventFilter:i=ig,...r}=n;return We(e,gx(i,t),r)}function _x(e,t,n={}){const{eventFilter:i,...r}=n,{eventFilter:s,pause:a,resume:o,isActive:l}=yx(i);return{stop:vx(e,t,{...r,eventFilter:s}),pause:a,resume:o,isActive:l}}function wx(e,t=!0,n){bx()?vt(e,n):t?e():kt(e)}function Zs(e){var t;const n=la(e);return(t=n==null?void 0:n.$el)!=null?t:n}const xs=sg?window:void 0;function si(...e){let t,n,i,r;if(typeof e[0]=="string"||Array.isArray(e[0])?([n,i,r]=e,t=xs):[t,n,i,r]=e,!t)return sr;Array.isArray(n)||(n=[n]),Array.isArray(i)||(i=[i]);const s=[],a=()=>
2443{s.forEach(d=>d()),s.length=0},o=(d,u,p,h)=>(d.addEventListener(u,p,h),()=>d.removeEventListener(u,p,h)),l=We(()=>[Zs(t),la(r)],([d,u])=>{if(a(),!d)return;const p=px(u)?{...u}:u;s.push(...n.flatMap(h=>i.map(m=>o(d,h,m,p))))},{immediate:!0,flush:"post"}),c=()=>{l(),a()};return ng(c),c}let du=!1;function YX(e,t,n={}){const{window:i=xs,ignore:r=[],capture:s=!0,detectIframe:a=!1}=n;if(!i)return sr;fx&&!du&&(du=!0,Array.from(i.document.body.children).forEach(p=>p.addEventListener("click",sr)),i.document.documentElement.addEventListener("click",sr));let o=!0;const l=p=>r.some(h=>{if(typeof h=="string")return Array.from(i.document.querySelectorAll(h)).some(m=>m===p.target||p.composedPath().includes(m));{const m=Zs(h);return m&&(p.target===m||p.composedPath().includes(m))}}),d=[si(i,"click",p=>{const h=Zs(e);if(!(!h||h===p.target||p.composedPath().includes(h))){if(p.detail===0&&(o=!l(p)),!o){o=!0;return}t(p)}},{passive:!0,capture:s}),si(i,"pointerdown",p=>{const h=Zs(e);o=!l(p)&&!!(h&&!p.composedPath().includes(h))},{passive:!0}),a&&si(i,"blur",p=>{setTimeout(()=>{var h;const m=Zs(e);((h=i.document.activeElement)==null?void 0:h.tagName)==="IFRAME"&&!(m!=null&&m.contains(i.document.activeElement))&&t(p)},0)})].filter(Boolean);return()=>d.forEach(p=>p())}function Ex(){const e=Re(!1),t=ln();return t&&vt(()=>{e.value=!0},t),e}function Sx(e){const t=Ex();return ee(()=>(t.value,!!e()))}function Cx(e,t={}){const{window:n=xs}=t,i=Sx(()=>n&&"matchMedia"in n&&typeof n.matchMedia=="function");let r;const s=Re(!1),a=c=>{s.value=c.matches},o=()=>{r&&("removeEventListener"in r?r.removeEventListener("change",a):r.removeListener(a))},l=Ci(()=>{i.value&&(o(),r=n.matchMedia(la(e)),"addEventListener"in r?r.addEventListener("change",a):r.addListener(a),s.value=r.matches)});return ng(()=>{l(),o(),r=void 0}),s}const Wi=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{},Qi="__vueuse_ssr_handlers__",Ix=Tx();function Tx(){return Qi in Wi||(Wi[Qi]=Wi[Qi]||{}),Wi[Qi]}function Px(e,t){return Ix[e]||t}function Ox(e){return e==null?"any":e instanceof Set?"set":e instanceof Map?"map":e instanceof Date?"date":typeof e=="boolean"?"boolean":typeof e=="string"?"string":typeof e=="object"?"object":Number.isNaN(e)?"any":"number"}const Ax={boolean:{read:e=>e==="true",write:e=>String(e)},object:{read:e=>JSON.parse(e),write:e=>JSON.stringify(e)},number:{read:e=>Number.parseFloat(e),write:e=>String(e)},any:{read:e=>e,write:e=>String(e)},string:{read:e=>e,write:e=>String(e)},map:{read:e=>new Map(JSON.parse(e)),write:e=>JSON.stringify(Array.from(e.entries()))},set:{read:e=>new Set(JSON.parse(e)),write:e=>JSON.stringify(Array.from(e))},date:{read:e=>new Date(e),write:e=>e.toISOString()}},uu="vueuse-storage";function kx(e,t,n,i={}){var r;const{flush:s="pre",deep:a=!0,listenToStorageChanges:o=!0,writeDefaults:l=!0,mergeDefaults:c=!1,shallow:d,window:u=xs,eventFilter:p,onError:h=I=>{console.error(I)},initOnMounted:m}=i,v=(d?Kn:Re)(typeof t=="function"?t():t);if(!n)try{n=Px("getDefaultStorage",()=>{var I;return(I=xs)==null?void 0:I.localStorage})()}catch(I){h(I)}if(!n)return v;const _=la(t),b=Ox(_),w=(r=i.serializer)!=null?r:Ax[b],{pause:C,resume:O}=_x(v,()=>E(v.value),{flush:s,deep:a,eventFilter:p});u&&o&&wx(()=>{si(u,"storage",P),si(u,uu,A),m&&P()}),m||P();function T(I,L){u&&u.dispatchEvent(new CustomEvent(uu,{detail:{key:e,oldValue:I,newValue:L,storageArea:n}}))}function E(I){try{const L=n.getItem(e);if(I==null)T(L,null),n.removeItem(e);else{const D=w.write(I);L!==D&&(n.setItem(e,D),T(L,D))}}catch(L){h(L)}}function y(I){const L=I?I.newValue:n.getItem(e);if(L==null)return l&&_!=null&&n.setItem(e,w.write(_)),_;if(!I&&c){const D=w.read(L);return typeof c=="function"?c(D,_):b==="object"&&!Array.isArray(D)?{..._,...D}:D}else return typeof L!="string"?L:w.read(L)}function P(I){if(!(I&&I.storageArea!==n)){if(I&&I.key==null){v.value=_;return}if(!(I&&I.key!==e)){C();try{(I==null?void 0:I.newValue)!==w.write(v.value)&&(v.value=y(I))}catch(L){h(L)}finally{I?kt(O):O()}}}}function A(I){P(I.detail)}return v}function rg(e,t,n={}){const{window:i=xs}=n;return kx(e,t,i==null?void 0:i.localStorage,n)}function hu(e){const t=e;t.__i18n=t.__i18n||[],t.__i18n.push({locale:"",resource:{en:{"lens-flow-glasses":{"express-checkout":{title:{t:0,b:{t:2,i:[{t:3}],s:"Welcome back!"}},description:{t:0,b:{t:2,i:[{t:3}],s:"Welcome back! Use this option to checkout with your saved prescription & add-ons."}},button:{t:0,b:{t:2,i:[{t:3}],s:"Express"}},tip:{title:{t:0,b:{t:2,i:[{t:3}],s:"Did you know? "}},description:{t:0,b:{t:2,i:[{t:3}],s:"Any frame is available with sun, or light adaptive lenses. Your preferred option can be chosen after your prescription input."}},"description-us":{t:0,b:{t:2,i:[{t:3}],s:"Any frame is available with light adaptive lenses. Your preferred option can be chosen after your prescription input."}}}},"free-rx-note":{label:{t:0,b:{t:2,i:[{t:3}],s:"Free for prescriptions up to ±2.75"}},title:{t:0,b:{t:2,i:[{t:3}],s:"What if my prescription is stronger than ±2.75?"}},body:{t:0,b:{t:2,i:[{t:3}],s:"You'll need a thinner, higher-index lens, which costs more. We'll show your exact price after you enter your prescription."}},"got-it":{t:0,b:{t:2,i:[{t:3}],s:"Got it"}}},"glasses-type":{tags:{reading:{t:0,b:{t:2,i:[{t:3}],s:"Reading"}},readers:{t:0,b:{t:2,i:[{t:3}],s:"Readers"}}},"learn-more":{t:0,b:{t:2,i:[{t:3}],s:"Learn more"}},"single-vision":{"display-name":{t:0,b:{t:2,i:[{t:3}],s:"Single vision"}},description:{t:0,b:{t:2,i:[{t:3}],s:"Corrects a single field of vision for distance."}},children:{"standard-sv":{"display-name":{t:0,b:{t:2,i:[{t:3}],s:"Standard"}},description:{t:0,b:{static:"",t:2,i:[]}},"pos-list":[{t:0,b:{t:2,i:[{t:3}],s:"Focused clarity for a single viewing distance"}},{t:0,b:{t:2,i:[{t:3}],s:"Designed for all-day comfort"}},{t:0,b:{t:2,i:[{t:3,v:"Lenses starting from $"},{t:4,k:"price"}]}}]},"anti-fatigue":{"display-name":{t:0,b:{t:2,i:[{t:3}],s:"Single Vision with Anti-Fatigue"}},"description-bold":{t:0,b:{static:"",t:2,i:[]}},description:{t:0,b:{t:2,i:[{t:3}],s:"Reduces eye strain during screen time and close-up work. A gentle boost in the lower lens helps your eyes focu
2443s with less effort."}},"pos-list":[{t:0,b:{t:2,i:[{t:3}],s:"Reduces digital eye strain and fatigue"}},{t:0,b:{t:2,i:[{t:3}],s:"Optimized for screen-heavy lifestyles"}},{t:0,b:{t:2,i:[{t:3}],s:"Easier on the eyes during extended near-vision tasks"}}],tags:[]}}},progressives:{"display-name":{t:0,b:{t:2,i:[{t:3}],s:"Progressives"}},description:{t:0,b:{t:2,i:[{t:3}],s:"Corrects near, middle, and far distances, all in one lens."}},children:{"standard-progressive":{"display-name":{t:0,b:{t:2,i:[{t:3}],s:"Standard Progressives"}},tags:[],description:{t:0,b:{t:2,i:[{t:3}],s:"Balanced viewing for everyday clarity and comfort."}},"pos-list":[{t:0,b:{t:2,i:[{t:3}],s:"Seamless focus from near to far"}},{t:0,b:{t:2,i:[{t:3}],s:"Designed for all-day clarity and comfort"}},{t:0,b:{t:2,i:[{t:3,v:"Lenses starting from $"},{t:4,k:"price"}]}}],"learn-more":{title:{t:0,b:{t:2,i:[{t:3}],s:"Standard Progressives"}},text:{t:0,b:{t:2,i:[{t:3}],s:"Progressive glasses, also known as multifocal or varifocal glasses, are a type of eyewear designed to address multiple vision problems in a single pair of glasses. They provide a seamless and convenient solution for individuals who have difficulty seeing objects clearly at different distances. Unlike traditional bifocal or trifocal glasses that have visible lines separating different lens powers, progressive glasses feature a gradual transition of lens powers. This means that wearers can smoothly shift their gaze from near to intermediate to distant objects without the need for multiple pairs of glasses."}},image:{t:0,b:{t:2,i:[{t:3}],s:"simple_progressives.jpg"}}}},"enhanced-progressive":{"display-name":{t:0,b:{t:2,i:[{t:3}],s:"Enhanced Progressives"}},tags:[{t:0,b:{t:2,i:[{t:3}],s:"Popular"}}],"description-bold":{t:0,b:{t:2,i:[{t:3}],s:"Up to 40% wider field of view"}},description:{t:0,b:{t:2,i:[{t:3}],s:" for more comfortable vision and easier adjustment."}},"pos-list":[{t:0,b:{t:2,i:[{t:3}],s:"Up to 40% wider viewing area with less edge distortion"}},{t:0,b:{t:2,i:[{t:3}],s:"Smoother transitions across distances for more comfortable all-day vision"}},{t:0,b:{t:2,i:[{t:3}],s:"Easier adjustment, especially for first-time wearers"}},{t:0,b:{t:2,i:[{t:3,v:"Lenses starting from $"},{t:4,k:"price"}]}}],"learn-more":{title:{t:0,b:{t:2,i:[{t:3}],s:"Enhanced Progressives"}},text:{t:0,b:{t:2,i:[{t:3}],s:"Enhanced progressives, also known as high-definition or wide-view progressives, are an advanced type of progressive glasses that offer a wider field of view compared to traditional progressive lenses. These lenses are specially designed using advanced optical technology to minimize distortions and expand the usable area of vision. With enhanced progressives, wearers can experience improved peripheral vision, allowing for a more natural and comfortable visual experience. Whether it's reading, using digital devices, or engaging in various activities, enhanced progressives provide wearers with a broader and more immersive visual experience."}},image:{t:0,b:{t:2,i:[{t:3}],s:"enhanced_progressives.jpg"}}}}}},readers:{"display-name":{t:0,b:{t:2,i:[{t:3}],s:"Reading"}},description:{t:0,b:{t:2,i:[{t:3}],s:"Magnification for close-up tasks. No prescription needed."}},children:{"simple-readers":{"display-name":{t:0,b:{t:2,i:[{t:3}],s:"Simple readers"}},description:{t:0,b:{t:2,i:[{t:3}],s:"Single magnification for close-up tasks."}},image:{t:0,b:{t:2,i:[{t:3}],s:"reading_lenses.svg"}}},"progressive-readers":{"display-name":{t:0,b:{t:2,i:[{t:3}],s:"Progressive readers"}},description:{t:0,b:{t:2,i:[{t:3}],s:"Clear at the top with reading strength at the bottom. See near and far."}},image:{t:0,b:{t:2,i:[{t:3}],s:"reading_lenses.svg"}}}}},"non-prescription":{"display-name":{t:0,b:{t:2,i:[{t:3}],s:"Non-prescription"}},description:{t:0,b:{t:2,i:[{t:3}],s:"Just for style. Lenses with no vision correction."}},children:{}}}}}}})}const ag=e=>(us("data-v-b317a4e3"),e=e(),hs(),e),Rx={class:"lg:hidden fixed bottom-0 left-0 w-full z-1"},Lx={class:"mb-8 pb-8 lg:mb-0"},Nx={class:"h-color-mirage-dark h-font-size-20 lg:h-font-size-24 h-font-weight-600 lens-flow__title"},Dx={key:0,class:"col-12 p-0"},xx={class:"optician-ai-lens-flow flex flex-column sm:flex-row h-border-color-iron-dark mb-4 gap-3"},Mx={class:"flex align-items-start gap-1 lg:gap-2"},Fx=["src"],Vx={class:"flex flex-column text-left"},Bx={style:{"font-weight":"600",color:"#4e5ba6"},class:"h-font-size-14 lg:h-font-size-16"},$x=ag(()=>f("span",{class:"mt-1 h-font-size-14 h-color-trout"}," Save time by purchasing the same lenses again",-1)),Ux=["onClick"],Hx={class:"pr-3"},zx=["src"],Kx={class:"flex flex-column"},Gx={class:"flex flex-column lg:flex-row h-color-mirage-dark h-font-size-16 h-font-weight-600"},jx={class:"mt-0 lg:mt-0"},Yx={key:0,class:"h-color-trout h-font-size-14 lg:h-font-size-16 mt-2"}
2443,Wx={key:1,class:"h-font-size-14 lg:h-font-size-16"},Qx={class:"pl-4 mt-3 text-gray-400 h-font-size-12 lg:h-font-size-16"},Zx={key:2,class:"mt-1 lg:mt-3 underline h-font-weight-600 w-7rem"},qx=["onClick"],Jx={class:"hidden lg:flex justify-content-center align-items-start pr-3"},Xx=["src"],e8={class:"flex flex-column w-full"},t8={class:"flex flex-row gap-3"},n8=["src"],s8={class:"flex h-color-mirage-dark h-font-size-16 h-font-weight-600 align-items-center"},i8={key:0,class:"h-color-trout h-font-size-14 lg:h-font-size-16 mt-2"},r8={key:0,class:"flex flex-column align-items-center"},a8={class:"w-full py-1 flex flex-column"},o8=["for"],l8={class:"flex align-items-start"},c8={class:"flex flex-column ml-2 cursor-pointer align-items-start"},d8={class:"flex align-items-center gap-2 flex-wrap"},u8={class:"h-color-mako-dark h-font-size-16 h-font-weight-500"},h8=["onClick"],p8={key:1,class:"h-bg-ribbon-blue text-white h-font-size-12 px-2 py-1 h-border-radius-20"},f8={key:2,class:"h-bg-ribbon-blue text-white h-font-size-12 px-2 py-1 h-border-radius-20"},m8={key:0,class:"h-color-trout h-font-size-14 h-font-weight-600"},g8={class:"h-color-trout h-font-size-14"},y8={key:1,class:"rx-label-b-test"},b8={class:"h-color-trout h-font-size-14"},v8={class:"free-rx-note__help"},_8=["aria-label"],w8=ag(()=>f("i",{class:"pi pi-question-circle"},null,-1)),E8=[w8],S8={key:0,class:"h-font-size-14 lg:h-font-size-16 h-color-trout white-space-nowrap"},C8={style:{width:"200px","margin-left":"auto","margin-top":"24px"}},I8={class:"h-font-size-16 h-font-weight-600 h-color-mirage-dark mb-3"},T8={class:"h-font-size-14 h-font-weight-400 h-color-trout line-height-3 mb-5"},P8={class:"flex justify-content-end"},og={__name:"LensFlowGlassesType",setup(e){vt(async()=>{A.value&&D(),Cl(p.value)&&(n.glassesStore.restoreDefaultLensesPrices()||await n.glassesStore.fetchLensesPrices(p.value.product_sku),P.value||be())}),vt(()=>{ne.value&&n.glassesStore.setGlassTypeParentValue("progressives"),b.value.lensType.cookieValue==="progressive"?n.glassesStore.setExpandedType("progressives"):b.value.lensType.type==="readers"?n.glassesStore.setExpandedType(b.value.lensType.type):["distance","anti-fatigue"].includes(b.value.lensType.value)&&n.glassesStore.setExpandedType("single-vision")});const{t}=rt({useScope:"local"}),n=ie(),{imagePath:i}=Be().public,r=se(),s=ht(r),a=Re(null),o=Re(!1),l=Cx("(max-width: 991px)"),c=Re("What do you use your glasses for?"),d=ee(()=>n.glassesStore.getExpandedType),u=ee(()=>{const B=t("lens-flow-glasses.free-rx-note.title"),Se=t("lens-flow-glasses.free-rx-note.body");return{value:`<span class="free-rx-note__tooltip-title">${B}</span>${Se}`,class:"free-rx-note__tooltip",escape:!0,disabled:l.value}}),p=ee(()=>n.glassesStore.getFrameDetails),h=ee(()=>nT(p.value)),m=ee(()=>!!ta(p.value)),v=ee(()=>n.glassesStore.getLensesPrices.lenses),_=ee(()=>n.systemStore.getGenericSiteMetadata.is_logged_in),b=ee(()=>n.glassesStore.getLensFlowSelectedOptions),w=ee(()=>n.systemStore.getCustomerExpressCheckoutLoading),C={distance:"Single Vision","anti-fatigue":"Anti-Fatigue","simple-readers":"Single Vision",progressive:"Progressive",progressive2:"Progressive2"},O=ee(()=>!!Yt(p.value.product_sku)),T=Re({}),E=Re({}),y=Re(!1),P=ee(()=>!!Yt(p.value.product_sku)&&n.glassesStore.getPangolinGlassesTypePricesLoading),A=ee(()=>r2(p.value)),I=ee(()=>P.value||y.value),L=async B=>{n.glassesStore.setPangolinGlassesTypePricesLoading(!0);try{const Se=n.glassesStore.getSelectedRxOptions,Ce=[...new Set(Object.values(C))],U=await Promise.all(Ce.map(ce=>Ws(ce,B.lensOption.backendValue,Se,p.value.product_sku,!1))),j={};Ce.forEach((ce,Ie)=>{var Te;const De=U[Ie];j[ce]=De!=null&&De.success?((Te=De.data.find(pe=>{var Pe,et;return wl((et=(Pe=pe.pos_list)==null?void 0:Pe.good_points)==null?void 0:et[0])==="1.59"}))==null?void 0:Te.price)??null:null}),T.value=j}finally{n.glassesStore.setPangolinGlassesTypePricesLoading(!1)}},D=async()=>{y.value=!0;try{const Se=[...new Set(Object.values(C))].map(Ce=>({key:Ce,prod_group:Ce,lens_color:a2(p.value,Ce)}));E.value=await n.glassesStore.fetchCheapestSellableLensPrices(p.value.product_sku,Se)}finally{y.value=!1}},z=ee(()=>{var j;const B=p.value.is_rimless?v.value.rimless:v.value.normal,Se=ce=>{if(!ce)return null;if(p.value.product_group==="Sunglasses")return ce!=null&&ce.cheapest_tinted_lens_price?ce.cheapest_tinted_lens_price:ce.cheapest_sun_lens_price;const Ie=Object.values(ce).filter(De=>typeof De=="number");return Ie.length?Math.min(...Ie):null};let Ce=[{displayName:t("lens-flow-glasses.glasses-type.single-vision.display-name"),value:"single-vision",backendValue:"Single Vision",cookieValue:"distance",description:t("lens-flow-glasses.glasses-type.single-vision.description"),posList:[],tags:[],learnMore:null,inlineChildren:!0,image:"clear_lenses-new.svg",children:[{displayName:t("lens-flow-glasses.glasses-type.single-vision.children.standard-sv.display-name"),value:"distance",backendValue:"Single Vision",cookieValue:"distance",description:t("lens-flow-glasses.glasses-type.single-vision.children.standard-sv.description"),posList:[t("lens-flow-glasses.glasses-type.single-vision.children.standard-sv.pos-list[0]"),t("lens-flow-glasses.glasses-type.single-vision.children.standard-sv.pos-list[1]"),t("lens-flow-glasses.glasses-type.single-vision.children.standard-sv.pos-list[2]",{price:Se(B.single_vision)?((j=B.single_vision.cheapest_clear_lens_price)==null?void 0:j.toFixed(2))??"0.00":"0.00"})],tags:[],learnMore:null,image:"clear_lenses-new.svg",price:Se(B.single_vision),priceLabel:Se(B.single_vision)===0?"Included":null},{displayName:t("lens-flow-glasses.glasses-type.single-vision.children.anti-fatigue.display-name"),value:"anti-fatigue",backendValue:"Anti-Fatigue",cookieValue:"distance",descriptionBold:t("lens-flow-glasses.glasses-type.single-vision.children.anti-fatigue.description-bold"),description:t("lens-flow-glasses.glasses-type.single-vision.children.anti-fatigue.description"),posList:[t("lens-flow-glasses.glasses-type.single-vision.children.anti-fatigue.pos-list[0]"),t("lens-flow-glasses.glasses-type.single-vision.children.anti-fatigue.pos-list[1]"),t("lens-flow-glasses.glasses-type.single-vision.children.anti-fatigue.pos-list[2]")],tags:[],learnMore:{title:"Anti-fatigue lenses",texts:["Anti-fatigue lenses reduce the effort your eyes exert when focu
2443sing from near to far. They feature a subtle boost of magnification in the lower portion of the lens, giving your eyes extra support during screen time and close-up work.","A great option if your eyes feel tired after a long day on screens. Pair them with blue light-blocking lenses for added comfort on heavy screen days.","Our standard anti-fatigue boost is +0.75. If you require a different strength, please reach out to our Customer Care team."],image:"anti_fatigue.png"},image:"clear_lenses-new.svg",price:Se(B==null?void 0:B.anti_fatigue)}]},{displayName:t("lens-flow-glasses.glasses-type.progressives.display-name"),value:"progressives",backendValue:"Progressive",cookieValue:"progressive",description:t("lens-flow-glasses.glasses-type.progressives.description"),posList:[],tags:[],learnMore:null,inlineChildren:!0,image:"progressives_lenses.svg",children:[{displayName:t("lens-flow-glasses.glasses-type.progressives.children.standard-progressive.display-name"),value:"progressive",backendValue:"Progressive",cookieValue:"progressive",description:t("lens-flow-glasses.glasses-type.progressives.children.standard-progressive.description"),posList:[t("lens-flow-glasses.glasses-type.progressives.children.standard-progressive.pos-list[0]"),t("lens-flow-glasses.glasses-type.progressives.children.standard-progressive.pos-list[1]"),t("lens-flow-glasses.glasses-type.progressives.children.standard-progressive.pos-list[2]",{price:Se(B.progressives)?p.value.product_group==="Sunglasses"?B.progressives.cheapest_sun_lens_price.toFixed(2):B.progressives.cheapest_clear_lens_price.toFixed(2):0})],tags:[],learnMore:{title:t("lens-flow-glasses.glasses-type.progressives.children.standard-progressive.learn-more.title"),text:t("lens-flow-glasses.glasses-type.progressives.children.standard-progressive.learn-more.text"),image:"simple_progressives.jpg"},image:"progressives_lenses_standard.svg",price:Se(B.progressives)},{displayName:t("lens-flow-glasses.glasses-type.progressives.children.enhanced-progressive.display-name"),value:"progressive2",backendValue:"Progressive2",cookieValue:"progressive",descriptionBold:t("lens-flow-glasses.glasses-type.progressives.children.enhanced-progressive.description-bold"),description:t("lens-flow-glasses.glasses-type.progressives.children.enhanced-progressive.description"),posList:[t("lens-flow-glasses.glasses-type.progressives.children.enhanced-progressive.pos-list[0]"),t("lens-flow-glasses.glasses-type.progressives.children.enhanced-progressive.pos-list[1]"),t("lens-flow-glasses.glasses-type.progressives.children.enhanced-progressive.pos-list[2]"),t("lens-flow-glasses.glasses-type.progressives.children.enhanced-progressive.pos-list[3]",{price:Se(B.progressives2)?p.value.product_group==="Sunglasses"?B.progressives2.cheapest_sun_lens_price.toFixed(2):B.progressives2.cheapest_clear_lens_price.toFixed(2):0})],tags:[t("lens-flow-glasses.glasses-type.progressives.children.enhanced-progressive.tags[0]")],learnMore:{title:t("lens-flow-glasses.glasses-type.progressives.children.enhanced-progressive.learn-more.title"),text:t("lens-flow-glasses.glasses-type.progressives.children.enhanced-progressive.learn-more.text"),image:"enhanced_progressives.jpg"},image:"progressives_lenses_premium.svg",price:Se(B.progressives2)}]},{displayName:t("lens-flow-glasses.glasses-type.readers.display-name"),value:"readers",backendValue:"Single Vision",cookieValue:"reading",description:t("lens-flow-glasses.glasses-type.readers.description"),posList:[],tags:[],learnMore:null,inlineChildren:!0,image:"reading_lenses-new.svg",children:[{displayName:t("lens-flow-glasses.glasses-type.readers.children.simple-readers.display-name"),value:"simple-readers",backendValue:"Single Vision",cookieValue:"reading",description:t("lens-flow-glasses.glasses-type.readers.children.simple-readers.description"),posList:[],tags:[],learnMore:null,image:"reading_lenses.svg",price:Se(B.single_vision)},{displayName:t("lens-flow-glasses.glasses-type.readers.children.progressive-readers.display-name"),value:"progressive-readers",backendValue:"Single Vision",cookieValue:"reading",description:t("lens-flow-glasses.glasses-type.readers.children.progressive-readers.description"),posList:[],tags:[],learnMore:null,image:"reading_lenses.svg",price:50}]},{displayName:t("lens-flow-glasses.glasses-type.non-prescription.display-name"),value:"non-prescription",backendValue:"Single Vision",cookieValue:"non-prescription",description:t("lens-flow-glasses.glasses-type.non-prescription.description"),posList:[],tags:[],learnMore:null,inlineChildren:!1,image:"classic-new.svg",children:[]}];if(r.includes(".com")&&!p.value.collections.some(ce=>ce.collection_name==="kits")){const ce=["non-prescription"];Ce.splice(0,Ce.length,...Ce.filter(Ie=>!ce.includes(Ie.value)))}if(A.value)for(const ce of Ce.flatMap(Ie=>Ie.children)){const Ie=E.value[C[ce.value]];typeof Ie=="number"&&(ce.price=Ie,ce.priceLabel=Ie===0?"Included":null)}const U=n.glassesStore.getPreselectedLensTint;
2443if(Yt(p.value.product_sku)){if(!KT(U)){const ce=Ce.find(Ie=>Ie.value==="readers");ce&&(ce.children=ce.children.filter(Ie=>Ie.value!=="progressive-readers"))}if(Ud(U)){Ce=Ce.filter(Ie=>Ie.value!=="progressives");const ce=Ce.find(Ie=>Ie.value==="single-vision");ce&&(ce.children=ce.children.filter(Ie=>Ie.value!=="anti-fatigue"))}if(U&&U.id!=="clear"){const ce=Ud(U),Ie=n.glassesStore.getPreselectedLensTintPrice||0;Ce.flatMap(Te=>Te.children??[]).filter(Te=>!(ce&&Te.value==="progressive-readers")).forEach(Te=>{const pe=C[Te.value],Pe=T.value[pe];ce?Te.price=0:typeof Pe=="number"&&(Te.price=Math.max(0,Pe-Ie)),Te.priceLabel=Te.price===0?"Included":null})}}return Ce}),G=ee(()=>n.glassesStore.getLensFlowSelectedOptions.lensType),ne=ee(()=>n.glassesStore.getProgressiveChoice),W=ee(()=>{var B;return(B=p.value.collections)==null?void 0:B.some(Se=>Se.collection_name==="rimless")}),ue=ee(()=>{var B;return(B=p==null?void 0:p.value.collections)==null?void 0:B.some(Se=>Se.collection_id===55)}),H=()=>{n.glassesStore.resetSelectedGlassesType(),Un("optician_lensflow","glassesFlowWithEccomerceData"),n.glassesStore.setFlowStep("glassesRx"),n.glassesStore.setLensFlowOptician(!0),window.scrollTo({top:0,left:0,behavior:"auto"})},x=(B,Se,Ce,U,j,ce)=>{n.glassesStore.setGlassesTypePrice(0),j==="Single Vision"&&n.glassesStore.setExpandedType(null);let Ie=U;if(U==="simple-readers"&&(Ie="readers"),U==="progressive-readers"&&(Ie="readers"),U==="non-prescription"&&n.glassesStore.saveRxOptions("62.0","SINGLE_PD"),n.glassesStore.setSelectedGlassesType(Se,Ce,Ie,j,ce),!(Se===U&&U=="readers")&&!(Se===U&&U=="progressives")){if(window.scrollTo({top:0,left:0,behavior:"auto"}),Se===U&&U=="non-prescription"){n.glassesStore.setFlowStep("lensOptions"),Un("rx_type_selected","glassesFlowWithEccomerceData");return}Se&&n.glassesStore.setFlowStep("glassesRx"),n.glassesStore.fetchGlassesRxOptionsFromCookie(U),Un("rx_type_selected","glassesFlowWithEccomerceData")}},V=()=>{const{value:B,type:Se}=G.value;B&&n.glassesStore.setFlowStep("glassesRx"),n.glassesStore.fetchGlassesRxOptionsFromCookie(Se),Un("rx_type_selected","glassesFlowWithEccomerceData"),window.scrollTo({top:0,left:0,behavior:"auto"})},te=B=>{n.glassesStore.setSelectedGlassesType(B.value,B.displayName,B.value,B.backendValue,B.cookieValue),n.glassesStore.setExpandedType(d.value===B.value?null:B.value)},fe=Re(null),re=B=>{if(n.glassesStore.setSelectedGlassesType(B.value,B.displayName,B.value,B.backendValue,B.cookieValue),I.value){fe.value=B.value;return}fe.value=null,n.glassesStore.setGlassesTypePrice(B.price)};We(()=>[P.value,n.glassesStore.getPreselectedLensTintPrice],([B])=>{B||!Yt(p.value.product_sku)||(be(),fe.value=null)}),We(y,B=>{B||(be(),fe.value=null)});const be=()=>{var Ce;const B=fe.value||((Ce=G.value)==null?void 0:Ce.value);if(!B)return;const Se=z.value.flatMap(U=>[U,...U.children??[]]).find(U=>U.value===B);(Se==null?void 0:Se.price)!=null&&n.glassesStore.setGlassesTypePrice(Se.price)};let Y=!1;const oe=B=>{const Se=B.currentTarget.parentElement;Y=B.target.matches(":focus-visible")&&Se.offsetParent!==null,Y&&Se.dispatchEvent(new Event("mouseenter"))},K=B=>{Y&&(Y=!1,B.currentTarget.parentElement.dispatchEvent(new Event("mouseleave")))},Z=()=>{l.value&&(o.value=!0)},me=()=>{o.value=!1};We(o,B=>{var Se;if(B){history.pushState({...history.state,freeRxNote:!0},""),window.addEventListener("popstate",me);return}window.removeEventListener("popstate",me),(Se=history.state)!=null&&Se.freeRxNote&&history.back()}),Cr(()=>{window.removeEventListener("popstate",me)});const q=(B,Se)=>{B.stopPropagation(),n.glassesStore.setProductShowcaseLearnMoreInfo(Se)},ae=async()=>{w.value||await n.glassesStore.fetchProductCustomerExpressCheckout(p.value)},ge=async()=>{var B;_.value?await ae():(B=a.value)==null||B.openLoginDialog()},we=B=>{if(B.value==="readers"&&(ue.value||W.value)){re(B.children[0]),V(),n.glassesStore.setExpandedType("");return}te(B)},X=B=>{var Ce;const Se=G.value.value;return!!(B.value===Se||B.value===d.value||(Ce=B.children)!=null&&Ce.some(U=>U.value===Se))};return We(()=>{var B;return(B=n.glassesStore.getPreselectedLensTint)==null?void 0:B.id},()=>{!n.glassesStore.getPreselectedLensTint||n.glassesStore.getPreselectedLensTint.id==="clear"||!Yt(p.value.product_sku)||L(n.glassesStore.getPreselectedLensTint)},{immediate:!0}),(B,Se)=>{const Ce=le("RadioButton"),U=le("Skeleton"),j=le("Button"),ce=le("Dialog"),Ie=Xe("tooltip");return g(),S(J,null,[f("div",Rx,[de(ux,{isContinueDisabled:!0})]),f("div",Lx,[f("div",Nx,N(k(c)),1),k(G).parentValueName===""?(g(),S("div",Dx,[f("div",xx,[!k(O)&&k(p).product_group!=="Sunglasses"&&(k(s)==="kits.com"||k(s)==="kits.ca")&&!k(p).collections.some(De=>De.collection_id===55)&&!k(m)&&!k(KI)()?(g(),S("button",{key:0,id:"optician-ai-lens-flow",onClick:H,class:"w-full"},[de(tx,{isFromFirstStep:!0})])):M("",!0),f("button",{class:"w-full border-1 p-2 lg:p-3 h-border-radius-12 bg-white",style:{"border-color":"#b3b8db"},onClick:Se[0]||(Se[0]=De=>ge())},[f("div",Mx,[f("img",{src:k(i)+"images/pdp/glasses/glassesFlow/clock-rewind.svg",class:"optician-icon mt-0 lg:mt-0"},null,8,Fx),f("div",Vx,[f("span",Bx,N(k(_)?"Reorder":"Login to reorder")+" your last lenses",1),$x])])])]),(g(!0),S(J,null,ye(k(z),De=>(g(),S("div",{key:De,class:Oe([{"h-border-color-iron-dark":!X(De),"border-900":X(De)},"col-12 product-cards h-border-radius-8 product-lens-flow-card py-0 px-3 lg:px-4 mb-2 sm:mb-3 selected-card-option align-items-center cursor-pointer"])},[!De.inlineChildren&&De.children.length===0?(g(),S("div",{key:0,class:"flex",onClick:st(Te=>x(B.event,De.value,De.displayName,De.value,De.backendValue,De.cookieValue),["stop"]),style:{"margin-top":"12px","margin-bottom":"12px"}},[f("div",Hx,[f("img",{class:"glasses-type__icon",src:`${k(i)}images/pdp/glasses/glassesFlow/${De.image}`,alt:"image frame"},null,8,zx)]),f("div",Kx,[f("div",Gx,[f("span",null,N(De.displayName),1),f("div",jx,[(g(!0),S(J,null,ye(De.tags,Te=>(g(),S("span",{key:Te,class:"ml-2 px-4 py-1 border-round-3xl capitalize"},N(Te),1))),128))])]),De.description?(g(),S("div",Yx,N(De.description),1)):M("",!0),De.posList.length>0?(g(),S("div",Wx,[f("ul",Qx,[(g(!0),S(J,null,ye(De.posList,Te=>(g(),S("li",{key:Te,class:"mb-2"},N(Te),1))),128))])])):M("",!0),De.learnMore?(g(),S("div",Zx,N(k(t)("lens-flow-glasses.glasses-type.learn-more")),1)):M("",!0)])],8,Ux)):M("",!0),De.inlineChildren&&De.children.length>0?(g(),S("div",{key:1,class:"flex w-full",style:{"margin-top":"12px","margin-bottom":"12px"},onClick:Te=>we(De)},[f("div",Jx,[f("img",{class:"glasses-type__icon",src:`${k(i)}images/pdp/glasses/glassesFlow/${De.image}`,alt:"image frame"},null,8,Xx)]),f("div",e8,[f("div",t8,[f("img",{class:"glasses-type__icon lg:hidden",src:`${k(i)}images/pdp/glasses/glassesFlow/${De.image}`,alt:"image frame"},null,8,n8),f("div",null,[f("div",s8,N(De.displayName),1),De.description?(g(),S("div",i8,N(De.description),1)):M("",!0)])]),de($t,{name:"slide-open"},{default:Ee(()=>[De.value===k(d)?(g(),S("div",r8,[f("div",a8,[(g(!0),S(J,null,ye(De.children,Te=>(g(),S("label",{for:Te.value,key:Te.value,class:Oe(["glasses-rx-prescription product-cards flex justify-content-between border-1 h-border-radius-12 p-2 w-full cursor-pointer",{"border-900":Te.value===k(G).value,"h-border-color-iron-dark":Te.value!==k(G).value,"min-h-0":Te.value==="distance"}]),style:{"box-shadow":"none !important","margin-top":"12px"},onClick:Se[2]||(Se[2]=st(()=>{},["stop"]))},[f("div",l8,[de(Ce,{inputId:Te.value,name:De.value,value:Te.value,modelValue:k(G).value,"onUpdate:modelValue":Se[1]||(Se[1]=pe=>k(G).value=pe),onClick:st(pe=>re(Te),["stop","prevent"])},null,8,["inputId","name","value","modelValue","onClick"]),f("div",c8,[f("div",d8,[f("span",u8,N(Te.displayName),1),Te.learnMore?(g(),S("i",{key:0,onClick:st(pe=>q(pe,Te.learnMore),["stop","prevent"]),class:"pi pi-question-circle h-color-aluminium"},null,8,h8)):M("",!0),Te.value==="progressive2"||Te.value==="progressive-readers"?(g(),S("span",p8," Recommended ")):M("",!0),Te.value==="anti-fatigue"?(g(),S("span",f8," Popular ")):M("",!0)]),f("div",null,[Te.descriptionBold?(g(),S("span",m8,N(Te.descriptionBold),1)):M("",!0),f("span",g8,N(Te.description),1),Te.value==="distance"&&k(h)?(g(),S("span",y8,[f("span",b8,[ke(N(k(t)("lens-flow-glasses.free-rx-note.label"))+" ",1),Ne((g(),S("span",v8,[f("button",{type:"button",class:"free-rx-note__help-button h-color-aluminium","aria-label":k(t)("lens-flow-glasses.free-rx-note.title"),onClick:st(Z,["stop","prevent"]),onFocus:oe,onBlur:K},E8,40,_8)])),[[Ie,k(u),void 0,{bottom:!0}]])])])):M("",!0)])])]),Te.priceLabel||Te.price!=null?(g(),S("div",S8,[k(I)&&Te.value!=="progressive-readers"?(g(),Q(U,{key:0,width:"3rem",height:"1rem",borderRadius:"4px",class:"inline-block"})):(g(),S(J,{key:1},[ke(N(Te.priceLabel?Te.priceLabel:k(p).product_group==="Sunglasses"&&Te.value==="progressive-readers"?"+$50":`+$${Te.price}`),1)],64))])):M("",!0)],10,o8))),128)),f("div",C8,[de(j,{onClick:st(V,["stop","prevent"]),type:"submit",label:"Continue",disabled:!De.children.some(Te=>
2443Te.value===k(G).value),class:"button__primary-kits-v3 capitalize w-full button__continue"},null,8,["disabled"])])])])):M("",!0)]),_:2},1024)])],8,qx)):M("",!0)],2))),128))])):M("",!0),de(DD,{ref_key:"lensFlowLoginRef",ref:a},null,512),de(ce,{visible:k(o),"onUpdate:visible":Se[4]||(Se[4]=De=>Jt(o)?o.value=De:null),modal:"",draggable:!1,showHeader:!1,dismissableMask:!0,pt:{mask:{class:"free-rx-note__mask"}},class:"free-rx-note__modal"},{default:Ee(()=>[f("div",I8,N(k(t)("lens-flow-glasses.free-rx-note.title")),1),f("div",T8,N(k(t)("lens-flow-glasses.free-rx-note.body")),1),f("div",P8,[de(j,{label:k(t)("lens-flow-glasses.free-rx-note.got-it"),onClick:Se[3]||(Se[3]=De=>o.value=!1),class:"button__primary-kits-v3 h-font-size-16 px-3 py-2"},null,8,["label"])])]),_:1},8,["visible"])])],64)}}};typeof hu=="function"&&hu(og);const ca=Ke(og,[["__scopeId","data-v-b317a4e3"]]),O8=Ge({props:{headerType:{type:String,required:!0}},components:{LensFlowGlassesType:ca},setup(e){vt(()=>{u()});const t=ie(),n=se(),i=ht(n),{imagePath:r}=Be().public,s=Re(null),a=ee(()=>t.systemStore.getIsAccordionVisible),o=()=>{t.systemStore.setDisplayHeaderSearch(!0)},l=p=>{t.systemStore.setHeaderNavType(p)},c=p=>{t.systemStore.setHeaderNavMenuType(p)},d=()=>{t.systemStore.setIsAccordionVisible(!a.value)},u=()=>{const p=it.get("basket_cookie");if(!p){s.value=null;return}const h=JSON.parse(p),m={items:[]},v=parseInt(h.number_total_items);for(let _=1;_<=v;_++)m.items.push({price:h[`price${_}`],description:h[`descrip${_}`],href:h[`href${_}`],src:h[`src${_}`],quantity:h[`qty${_}`]});m.subtotal=h.subtot,m.totalQuantity=h.totqty,m.locale=h.mv_locale,s.value=m};return{imagePath:r,isAccordionVisible:a,openSearchBar:o,handleHeaderNavType:l,handleHeaderNavMenuType:c,handleAccordionVisibility:d,setDynamicLink:Ae,getActiveDomain:se,baseDomain:i,cartProducts:s}}}),A8={class:"header-menu flex align-items-center justify-content-end w-full mr-2"},k8={class:"px-2 header-menu-links cursor-pointer"},R8=["src"],L8=["href"],N8=["src"],D8=["src"],x8=["href"],M8=["src"],F8={key:0,class:"absolute top-0 flex align-items-center h-font-size-10 h-font-weight-300 justify-content-center bg-gray-900 text-white border-circle",style:{width:"22px",height:"22px","margin-top":"19px","margin-left":"3px"}},V8=["src"],B8=["href"],$8=["src"],U8={class:"px-2 lg:hidden cursor-pointer"},H8=["src"];function z8(e,t,n,i,r,s){return g(),S("div",A8,[f("div",k8,[f("img",{class:"vertical-align-middle",src:`${e.imagePath}images/header/search_new.svg`,alt:"Search Icon",onClick:t[0]||(t[0]=st((...a)=>e.openSearchBar&&e.openSearchBar(...a),["stop"]))},null,8,R8)]),e.headerType==="normal"?(g(),S("a",{key:0,href:e.setDynamicLink()+"/customerservice",class:"px-2 hidden lg:block header-menu-links cursor-pointer",onMouseover:t[1]||(t[1]=st(a=>e.handleHeaderNavMenuType("profile"),["stop"]))},[f("img",{class:"vertical-align-middle",src:`${e.imagePath}images/header/profile.svg`,alt:"Profile Icon"},null,8,N8)],40,L8)):M("",!0),f("div",{class:"header-menu-links px-2 hidden lg:block cursor-pointer",onMouseover:t[2]||(t[2]=st(a=>e.handleHeaderNavMenuType("help"),["stop"]))},[f("img",{class:"vertical-align-middle",width:"20px",src:`${e.imagePath}images/header/helpme.svg`,alt:"Help Icon"},null,8,D8)],32),f("a",{href:e.setDynamicLink()+"/favorites",class:"px-2 hidden lg:block header-menu-links cursor-pointer"},[f("img",{class:"vertical-align-middle",src:`${e.imagePath}images/header/favorite.svg`,alt:"Favorite Icon"},null,8,M8)],8,x8),e.cartProducts&&e.cartProducts.totalQuantity>0?(g(),S("div",{key:1,class:"relative px-2 header-menu-links cursor-pointer flex flex-column",onMouseover:t[3]||(t[3]=st(a=>e.handleHeaderNavMenuType("cart"),["stop"]))},[e.cartProducts&&e.cartProducts.totalQuantity>0?(g(),S("div",F8,N(e.cartProducts.totalQuantity),1)):M("",!0),f("img",{class:"vertical-align-middle",src:`${e.imagePath}images/header/cart_new.svg`,alt:"Cart Icon"},null,8,V8)],32)):(g(),S("a",{key:2,href:e.setDynamicLink()+"/ord/checkout",class:"px-2 header-menu-links cursor-pointer"},[f("img",{class:"vertical-align-middle",src:`${e.imagePath}images/header/cart_new.svg`,alt:"Cart Icon"},null,8,$8)],8,B8)),f("div",U8,[f("img",{class:"vertical-align-middle",src:`${e.imagePath}images/header/hamburger.svg`,alt:"Hamburger Icon",onClick:t[4]||(t[4]=(...a)=>e.handleAccordionVisibility&&e.handleAccordionVisibility(...a))},null,8,H8)])])}const K8=Ke(O8,[["render",z8]]),G8=Ge({components:{LensFlowGlassesType:ca},setup(){const e=ie(),t=se(),n=ht(t),i=Re("");return{closeSearchBar:()=>{e.systemStore.setDisplayHeaderSearch(!1)},handleSearch:async a=>{a.target.value?(e.systemStore.setDisplayHeaderSearchMenu(!0),await e.systemStore.fetchSearchProduct(a.target.value,n)):e.systemStore.setDisplayHeaderSearchMenu(!1)},searchValue:i}}}),j8={class:"header-search",id:"search-wrapper"},Y8=f("i",{class:"magnify-search-bar-icon pi pi-search h-font-size-18 h-font-weight-600 absolute top-50"},null,-1);function W8(e,t,n,i,r,s){const a=le("InputText");return g(),S("div",j8,[de(a,{type:"text",modelValue:e.searchValue,"onUpdate:modelValue":t[0]||(t[0]=o=>e.searchValue=o),placeholder:"Type & Hit Enter...",class:"border-round-3xl w-full pl-5 py-2",onInput:e.handleSearch},null,8,["modelValue","onInput"]),Y8,f("i",{class:"close-search-bar-icon pi pi-times h-font-size-14 border-1 border-circle p-1 h-font-weight-600 cursor-pointer absolute top-50",onClick:t[1]||(t[1]=(...o)=>e.closeSearchBar&&e.closeSearchBar(...o))})])}const Q8=Ke(G8,[["render",W8]]);function pu(e){const t=e;t.__i18n=t.__i18n||[],t.__i18n.push({locale:"",resource:{en:{"header-links":{"image-alt":{t:0,b:{t:2,i:[{t:3}],s:"Kits Logo"}},eyeglasses:{t:0,b:{t:2,i:[{t:3}],s:"EYEGLASSES"}},progressives:{t:0,b:{t:2,i:[{t:3}],s:"PROGRESSIVES"}},sunglasses:{t:0,b:{t:2,i:[{t:3}],s:"SUNGLASSES"}}
2443,contacts:{t:0,b:{t:2,i:[{t:3}],s:"CONTACTS"}},insurance:{t:0,b:{t:2,i:[{t:3}],s:"INSURANCE"}}}}}})}const lg=Ge({components:{HeaderMenu:K8,HeaderSearch:Q8},props:{logo:{type:String,required:!0}},setup(){const{t:e}=rt({useScope:"local"}),t=ie(),{imagePath:n}=Be().public,i=ee(()=>t.systemStore.getHeaderNavType),r=ee(()=>t.systemStore.getDisplayHeaderSearch);return{t:e,imagePath:n,headerNavType:i,displaySearch:r,handleHeaderNavType:o=>{t.systemStore.setHeaderNavType(o)},handleHeaderNavMenuType:o=>{t.systemStore.setHeaderNavMenuType(o)},setDynamicLink:Ae}}}),Z8=["src","alt"],q8={key:0,class:"hidden lg:flex"},J8=["href"],X8=["href"],e9=["href"],t9=["href"],n9=["href"],s9={key:1,class:"hidden md:block ml-2 relative w-full",style:{"max-width":"500px"}},i9={key:0,class:"header-search header-search__bar block md:hidden w-full absolute left-50 px-2 mt-8",style:{transform:"translateX(-50%)"}};function r9(e,t,n,i,r,s){const a=le("HeaderSearch"),o=le("HeaderMenu");return g(),S("div",{class:Oe(["pdp-header border-bottom-1 h-border-color-grey flex",e.displaySearch?"h-9rem md:h-6rem align-items-start md:align-items-center":"h-6rem align-items-center"])},[f("a",{href:"/index",onMouseover:t[0]||(t[0]=l=>(e.handleHeaderNavType(""),e.handleHeaderNavMenuType(""))),class:"logo-image"},[f("img",{style:{height:"25px"},src:`${e.imagePath}images/header/${e.logo}`,alt:e.t("header-links.image-alt"),class:"header-img"},null,8,Z8)],32),f("div",{class:Oe(["w-full ml-4 flex align-items-center justify-content-between",e.displaySearch?"ml-3":"ml-4"])},[e.displaySearch?(g(),S("div",s9,[de(a)])):(g(),S("div",q8,[f("a",{href:e.setDynamicLink()+"/glasses",class:"normal-links cursor-pointer",onMouseover:t[1]||(t[1]=l=>e.handleHeaderNavType("eyeglasses"))},N(e.t("header-links.eyeglasses")),41,J8),f("a",{href:e.setDynamicLink()+"/glasses?filters=filter=features_uFilter:+Progressive+Eligible",id:"nav-progressives-category",class:"normal-links cursor-pointer",onMouseover:t[2]||(t[2]=l=>e.handleHeaderNavType("progressives"))},N(e.t("header-links.progressives")),41,X8),f("a",{href:e.setDynamicLink()+"/sunglasses",class:"normal-links cursor-pointer",onMouseover:t[3]||(t[3]=l=>e.handleHeaderNavType("sunglasses"))},N(e.t("header-links.sunglasses")),41,e9),f("a",{href:e.setDynamicLink()+"/contacts",class:"normal-links cursor-pointer",onMouseover:t[4]||(t[4]=l=>e.handleHeaderNavType("contacts"))},N(e.t("header-links.contacts")),41,t9),f("a",{href:e.setDynamicLink()+"/insurance",class:"normal-links cursor-pointer",onMouseover:t[5]||(t[5]=l=>e.handleHeaderNavType(""))},N(e.t("header-links.insurance")),41,n9)])),de(o,{headerType:"normal"})],2),e.displaySearch?(g(),S("div",i9,[de(a)])):M("",!0)],2)}typeof pu=="function"&&pu(lg);const a9=Ke(lg,[["render",r9]]);function fu(e){const t=e;t.__i18n=t.__i18n||[],t.__i18n.push({locale:"",resource:{en:{"header-menu":{"sign-in":{t:0,b:{t:2,i:[{t:3}],s:"Sign in"}}}}}})}const cg=Ge({components:{LensFlowGlassesType:ca},setup(){const e=y=>{var P,A,I,L;if(((P=y.data)==null?void 0:P.type)==="close-scanner"){c.value=!1,t.systemStore.setIsScannerOpened(!1);return}if(((A=y.data)==null?void 0:A.type)==="barcode-scan-result"&&(c.value=!1,t.systemStore.setIsScannerOpened(!1),(I=y.data.response)!=null&&I.data)){const D=(L=y.data.response)==null?void 0:L.data.sku;window.location.href=Ae()+"/contact_lenses/"+D}};vt(()=>{a.value=window.innerWidth,window.addEventListener("message",e)}),cn(()=>{window.removeEventListener("message",e)});const t=ie(),n=se(),i=ht(n),{imagePath:r}=Be().public,{t:s}=rt({useScope:"local"}),a=Re(""),o=Re(null),l=Re(""),c=Re(!1);We(()=>t.systemStore.getIsScannerOpened,y=>{c.value=y});const d=rg("favItemsNew",[]),u=ee(()=>t.systemStore.getIsAccordionVisible),p=ee(()=>t.systemStore.getHeaderNavMenuType),h=ee(()=>t.systemStore.getMobileMenuType),m=ee(()=>t.systemStore.getGenericSiteMetadata),v=ee(()=>d.value.length),_=()=>{t.systemStore.setDisplayHeaderSearch(!0),t.systemStore.setDisplayHeaderSearchMenu(!0),t.systemStore.setIsAccordionVisible(!1),w(""),b("")},b=y=>{t.systemStore.setHeaderNavType(y)},w=y=>{y===p.value?t.systemStore.setHeaderNavMenuType(""):t.systemStore.setHeaderNavMenuType(y)},C=y=>{y===h.value?t.systemStore.setMobileMenuType(""):t.systemStore.setMobileMenuType(y)},O=()=>{t.systemStore.setIsAccordionVisible(!u.value)},T=async()=>{document.body.style.marginTop=0,t.systemStore.setIsAccordionVisible(!1),t.systemStore.setHeaderNavMenuType(""),t.systemStore.setHeaderNavType(""),t.systemStore.setDisplayHeaderSearch(!0),t.systemStore.setDisplayHeaderSearchMenu(!0)},E=()=>{xn("Optician_AI_Clicked")};return We(p,y=>{y!==""&&a.value<768&&window.scrollTo(0,0)}),{t:s,imagePath:r,isAccordionVisible:u,openSearchBar:_,handleHeaderNavType:b,handleHeaderNavMenuType:w,headerNavMenuType:p,handleMobileMenuType:C,handleAccordionVisibility:O,setDynamicLink:Ae,getActiveDomain:se,genericSiteMetadata:m,baseDomain:i,cartProducts:o,handleClickOnSearchInput:T,handleOpticianAiClick:E,itemCount:v,windowWidth:a,searchValue:l,isScannerDialogOpen:c}}}),o9={class:"header-menu flex align-items-center",style:{height:"70px"}},l9={key:0,class:"optician-wrapper",href:"/optician"},c9=["src"],d9={class:"h-color-white h-font-size-12 lg:h-font-size-14 h-font-weight-600"},u9={class:"block"},h9=["src"],p9=["data-count"],f9=["src"],m9=["data-count"],g9=["src"],y9=["data-count"],b9=["src"],v9=["src"],_9={key:3,src:"/plugins/barco
2443de-scanner",allow:"camera",style:{position:"fixed",inset:"0",width:"100vw",height:"100vh",border:"none","z-index":"9999",background:"transparent"}};function w9(e,t,n,i,r,s){var a,o,l,c;return g(),S("div",o9,[e.baseDomain.includes("kits")?(g(),S("a",l9,[f("img",{class:"vertical-align-middle hidden sm:block",src:`${e.imagePath}images/header/ai-stars-white.svg`,alt:"KITS OpticianAI™ Icon"},null,8,c9),f("span",d9,N(e.windowWidth>767?"Ask":"")+" Optician AI™",1)])):M("",!0),f("div",{class:Oe(["menu-item h-color-primary cursor-pointer h-full flex align-items-center border-bottom-2 border-transparent white-space-nowrap",e.headerNavMenuType==="profile"?"h-border-color-primary":""]),onClick:t[0]||(t[0]=d=>e.handleHeaderNavMenuType("profile"))},[f("div",u9,[f("img",{class:"vertical-align-middle",src:`${e.imagePath}images/header/account-grey.svg`,alt:"Profile Icon"},null,8,h9)])],2),f("div",{class:Oe(["menu-item favorite-link hidden lg:flex header-menu-links-new cursor-pointer h-full align-items-center border-bottom-2 border-transparent",{"h-border-color-primary":e.headerNavMenuType==="favorite","header-menu-links-label":e.itemCount>0}]),onClick:t[1]||(t[1]=d=>e.handleHeaderNavMenuType("favorite")),"data-count":e.itemCount},[f("img",{class:"vertical-align-middle",src:`${e.imagePath}images/header/heart-grey.svg`,alt:"Favorite Icon"},null,8,f9)],10,p9),e.windowWidth>=991?(g(),S("button",{key:1,class:Oe(["menu-item flex header-menu-links-new cursor-pointer h-full align-items-center border-bottom-2 border-transparent",{"h-border-color-primary":e.headerNavMenuType==="cart","header-menu-links-label":((a=e.genericSiteMetadata.side_cart.items)==null?void 0:a.length)>0}]),onClick:t[2]||(t[2]=d=>e.handleHeaderNavMenuType("cart")),"data-count":(o=e.genericSiteMetadata.side_cart.items)==null?void 0:o.length},[f("img",{class:"vertical-align-middle",src:`${e.imagePath}images/header/bag-grey.svg`,alt:"Cart Icon"},null,8,g9)],10,m9)):(g(),S("a",{key:2,class:Oe(["menu-item flex header-menu-links-new cursor-pointer h-full align-items-center border-bottom-2 border-transparent",{"h-border-color-primary":e.headerNavMenuType==="cart","header-menu-links-label":((l=e.genericSiteMetadata.side_cart.items)==null?void 0:l.length)>0}]),"data-count":(c=e.genericSiteMetadata.side_cart.items)==null?void 0:c.length,href:"/ord/checkout"},[f("img",{class:"vertical-align-middle",src:`${e.imagePath}images/header/bag-grey.svg`,alt:"Cart Icon"},null,8,b9)],10,y9)),f("div",{class:Oe(["menu-item flex lg:hidden cursor-pointer h-full align-items-center border-bottom-2 border-transparent",e.headerNavMenuType==="hamburger"?"h-border-color-primary":""])},[f("img",{onClick:t[3]||(t[3]=d=>e.handleHeaderNavMenuType("hamburger")),class:"vertical-align-middle",src:`${e.imagePath}images/header/hamburger-grey.svg`,alt:"Hamburger Icon"},null,8,v9)],2),e.isScannerDialogOpen?(g(),S("iframe",_9)):M("",!0)])}typeof fu=="function"&&fu(cg);const E9=Ke(cg,[["render",w9],["__scopeId","data-v-c3dd3fc1"]]),S9={},C9={class:"loading-dots h-color-denim"},I9=f("span",{class:"loading-dots__dot"},null,-1),T9=f("span",{class:"loading-dots__dot"},null,-1),P9=f("span",{class:"loading-dots__dot"},null,-1),O9=[I9,T9,P9];function A9(e,t){return g(),S("span",C9,O9)}const dg=Ke(S9,[["render",A9]]);function mu(e){const t=e;t.__i18n=t.__i18n||[],t.__i18n.push({locale:"",resource:{en:{search:{clear:{t:0,b:{t:2,i:[{t:3}],s:"Clear"}}}}}})}const ug=Ge({components:{LensFlowGlassesType:ca,LoadingDotsOptician:dg},setup(){vt(()=>{window.addEventListener("keydown",h),window.addEventListener("keydown",m)}),cn(()=>{window.removeEventListener("keydown",h),window.removeEventListener("keydown",m)});const{t:e}=rt({useScope:"local"}),t=ie(),n=se(),i=ht(n),{imagePath:r}=Be().public,s=ee({get:()=>t.systemStore.getSearchValue,set:w=>t.systemStore.setSearchValue(w)}),a=Re(null),o=ee(()=>t.systemStore.getDisplayHeaderSearch),l=ee(()=>t.systemStore.getIsOpticianSearch),c=ee(()=>t.systemStore.getSearchResultsLoading),d=ee(()=>bl(async w=>{const O=w.target.value.trim().replace(/`+/g,"");O?(t.systemStore.setSelectedProductType("popular"),t.systemStore.setDisplayHeaderSearchMenu(!0),await t.systemStore.fetchSearchProduct(O,i,l.value)):(t.systemStore.setSelectedProductType("trending"),t.systemStore.setSearchResultLoading(!1),v())},500)),u=w=>(t.systemStore.setSearchResultLoading(!0),d.value(w)),p=()=>{t.systemStore.closeSearchBar()},h=w=>{w.key==="Escape"&&p()},m=w=>{l.value||w.key==="Enter"&&s.value!==""&&(ea("predictive_search",{query:s.value,source:l.value?"Optician AI":"Regular"}),window.location.href=Ae()+`/glasses?q=${s.value.replace(" ","+").replaceAll("&","%26")}`)},v=()=>{c.value||(a.value.$el.focus(),t.systemStore.setSearchValue(""),t.systemStore.setSearchResults({numberOfProducts:0,products:[],start:0}))},_=async()=>{t.systemStore.setIsAccordionVisible(!1),t.systemStore.setHeaderNavMenuType(""),t.systemStore.setHeaderNavType(""),t.systemStore.setDisplayHeaderSearch(!0),t.systemStore.setDisplayHeaderSearchMenu(!0)};return Ci(()=>{o.value&&a.value&&a.value.$el.focus()}),We(l,async w=>{w||(t.systemStore.abortOpticianSearch(),t.systemStore.setSearchResultLoading(!1));const C=s.value.trim();C?(t.systemStore.setSearchResultLoading(!0),t.systemStore.setSelectedProductType("popular"),t.systemStore.setDisplayHeaderSearchMenu(!0),await t.systemStore.fetchSearchProduct(C,i,w)):t.systemStore.setSearchResults({numberOfProducts:0,products:[],start:0}),a.value&&a.value.$el.focus()}),{t:e,imagePath:r,handleSearch:u,handleCloseSearchBar:p,handleClickOnSearchInput:_,searchValue:s,displaySearch:o,searchInputRef:a,clearSearchBar:v,setDynamicLink:Ae,isOpticianSearch:l,resultsLoading:c,baseDomain:i,openScanner:async()=>{t.systemStore.closeSearchBar(),await kt(),t.systemStore.setIsScannerOpened(!0)}}}}),k9={class:"search-wrapper relative",id:"search-wrapper"},R9={class:"flex mobile-search align-items-center gap-2 relative"},L9={class:"relative w-full"},N9=["href"],D9=["src"],x9=["src"],M9={class:"cursor-pointer p-1"},F9=["src"];function V9(e,t,n,i,r,s){const a=le("LoadingDotsOptician"),o=le("InputText");return g(),S("div",k9,[f("div",R9,[f("div",L9,[e.searchValue!==""?(g(),S("div",{key:0,onClick:t[0]||(t[0]=(...l)=>e.clearSearchBar&&e.clearSearchBar(...l)),class:"absolute clear-search h-color-oslo-gray h-font-weight-300 h-font-size-14 underline z-1 h-full align-content-center",style:{}},[Ne(f("span",{class:"cursor-pointer"},N(e.t("search.clear")),513),[[mt,!e.resultsLoading]]),Ne(de(a,null,null,512),[[mt,e.resultsLoading]])])):M("",!0),de(o,{type:"text",id:"search-input",ref:"searchInputRef",modelValue:e.searchValue,"onUpdate:modelValue":t[1]||(t[1]=l=>e.searchValue=l),placeholder:e.isOpticianSearch?"'glasses for cycling'...":"Search",class:Oe(["border-round-lg relative w-full pl-6",e.baseDomain==="opticontacts.com"||e.baseDomain==="contactsexpress.ca"?"pr-10":"pr-7"]),style:{"padding-top":"12px","padding-bottom":"12px"},onInput:e.handleSearch,onClick:e.handleClickOnSearchInput},null,8,["modelValue","placeholder","class","onInput","onClick"])]),f("a",{href:e.isOpticianSearch?null:e.setDynamicLink()+`/glasses?q=${e.searchValue.replace(" ","+").replaceAll("&","%26")}`,class:Oe(["h-color-primary magnify-search-bar-icon h-font-size-18 h-font-weight-600 absolute",e.isOpticianSearch?"":"cursor-pointer"]),style:{to
2443p:"21px",left:"15px"}},[e.isOpticianSearch?(g(),S("img",{key:0,class:"vertical-align-middle",src:e.imagePath+"images/header/ai-stars-blue.svg",alt:"search"},null,8,D9)):(g(),S("img",{key:1,class:"vertical-align-middle",src:e.imagePath+"images/header/search_new.svg",alt:"search"},null,8,x9))],10,N9),f("div",M9,[f("img",{class:"vertical-align-middle",src:e.imagePath+"images/header/close-grey.svg",onClick:t[2]||(t[2]=(...l)=>e.handleCloseSearchBar&&e.handleCloseSearchBar(...l)),alt:"Close Icon"},null,8,F9)])])])}typeof mu=="function"&&mu(ug);const B9=Ke(ug,[["render",V9],["__scopeId","data-v-33919090"]]);function gu(e){const t=e;t.__i18n=t.__i18n||[],t.__i18n.push({locale:"",resource:{en:{header:{"image-alt":{t:0,b:{t:2,i:[{t:3}],s:"Logo"}},links:{eyeglasses:{t:0,b:{t:2,i:[{t:3}],s:"Eyeglasses"}},sunglasses:{t:0,b:{t:2,i:[{t:3}],s:"Sunglasses"}},"smart-glasses":{t:0,b:{t:2,i:[{t:3}],s:"AI Smart Glasses"}},designer:{t:0,b:{t:2,i:[{t:3}],s:"Brands"}},readers:{t:0,b:{t:2,i:[{t:3}],s:"Readers"}},contacts:{t:0,b:{t:2,i:[{t:3}],s:"Contacts"}},insurance:{t:0,b:{t:2,i:[{t:3}],s:"Insurance"}},sale:{t:0,b:{t:2,i:[{t:3}],s:"Sale"}}}}}}})}const da=e=>(us("data-v-630af692"),e=e(),hs(),e),$9={class:"normal-header-new"},U9=["href"],H9=["src","alt"],z9=["href"],K9=["src","alt"],G9={class:"flex align-items-center gap-2 py-2"},j9=["src"],Y9=da(()=>f("span",{class:"h-color-pale-sky h-font-weight-400 h-font-size-14"},"Search Products",-1)),W9=["src"],Q9={key:3,class:"flex flex-column md:flex-row md:align-items-center align-items-start justify-content-center gap-2 w-full px-2 py-0 my-3"},Z9={class:"flex-row align-items-center justify-content-between w-full md:w-auto",id:"optician-ai-wrapper"},q9={key:0,class:"toggler-wrapper border-1 h-border-color-iron-dark h-bg-alabaster h-border-radius-8 p-1"},J9=["src"],X9=da(()=>f("span",{class:"h-font-size-14 h-color-mirage-dark h-font-weight-500 ml-1"},"Search",-1)),e5=["src"],t5={key:1,class:"cursor-pointer p-1 md:hidden"},n5=["src"],s5={class:"relative header__search-container"},i5={key:4,class:"flex align-items-center justify-content-end py-0 gap-2"},r5={key:0,class:"m-3 flex md:hidden justify-content-center"},a5={class:"flex align-items-center gap-2 py-2"},o5=["src"],l5=da(()=>f("span",{class:"h-color-pale-sky h-font-weight-400 h-font-size-14"},"Search Products",-1)),c5=["src"],d5={key:1,class:"hidden lg:flex align-items-center h-font-weight-500 justify-content-center gap-2 h-font-size-16 h-bg-alabaster border-bottom-1 h-border-color-cultured-grey"},u5=["href"],h5=["href"],p5=["href"],f5=["href"],m5=da(()=>f("span",{class:"h-bg-ribbon-blue h-color-white h-font-size-14 h-font-weight-500 border-round-3xl py-1 px-2"},"New",-1)),g5=["href"],y5=["href"],b5=["href"],v5=["href"],_5=["href"],hg={__name:"NormalHeaderNew",setup(e){const{t}=rt({useScope:"local"}),n=ie(),i=ht(se()),{imagePath:r}=Be().public,s=ee(()=>n.systemStore.getHeaderNavType),a=ee(()=>n.systemStore.getHeaderInformation),o=ee(()=>n.systemStore.getDisplayHeaderSearch),l=ee(()=>n.systemStore.getIsOpticianSearch),c=_=>{n.systemStore.setHeaderNavType(_)},d=()=>{n.systemStore.setIsOpticianSearch(!0)},u=()=>{n.systemStore.setIsOpticianSearch(!1)},p=()=>{n.systemStore.closeSearchBar()},h=async()=>{document.body.style.marginTop=0,n.systemStore.setIsAccordionVisible(!1),n.systemStore.setHeaderNavMenuType(""),n.systemStore.setHeaderNavType(""),n.systemStore.setDisplayHeaderSearch(!0),n.systemStore.setDisplayHeaderSearchMenu(!0)},m=async()=>{n.systemStore.closeSearchBar(),await kt(),n.systemStore.setIsScannerOpened(!0)};Re(!1);const v=()=>{try{dataLayer.push({event:"navbar_insurance_click"})}catch{console.log("Datalayer not found navbar_insurance_click")}};return(_,b)=>(g(),S("div",$9,[f("div",{class:Oe(["flex align-items-center justify-content-between px-3 sm:px-4 border-bottom-1 h-border-color-cultured-grey transition-colors transition-duration-300",k(l)?"h-bg-cloud-blue":"h-bg-white"])},[k(i)==="opticontacts.com"?(g(),S("a",{key:0,href:k(Ae)()+"/index",class:Oe(["py-0",k(o)?"hidden md:block":"block"])},[f("img",{src:`${k(r)}images/header/${k(a).logo}`,alt:k(t)("header.image-alt"),class:"header-img-opti"},null,8,H9)],10,U9)):(g(),S("a",{key:1,href:k(Ae)()+"/index",class:Oe(["py-0",k(o)?"hidden md:block":"block"])}
2443,[f("img",{src:`${k(r)}images/header/${k(a).logo}`,alt:k(t)("header.image-alt"),class:Oe(["header-img",{"header-img-cxp":k(i)==="contactsexpress.ca","header-img-kits":k(i).includes("kits")}])},null,10,K9)],10,z9)),k(o)?M("",!0):(g(),S("div",{key:2,class:"hidden md:flex justify-content-between align-items-center w-full border-1 border-round-3xl h-border-color-iron-dark px-2 py-1 md:mx-4 cursor-pointer",style:{"max-width":"500px"},onClick:h},[f("div",G9,[f("img",{src:k(r)+"images/header/search.svg",alt:"search"},null,8,j9),Y9]),k(i).includes("contacts")?(g(),S("img",{key:0,class:"barcode-scanner",id:"barcode-scanner",src:k(r)+"images/header/scan-barcode.svg",alt:"scan",onClick:st(m,["stop"])},null,8,W9)):M("",!0)])),k(o)?(g(),S("div",Q9,[f("div",Z9,[k(i)==="kits.ca"||k(i)==="kits.com"?(g(),S("div",q9,[f("div",{class:Oe(["toggler-slider h-border-radius-6",k(l)?"toggler-slider__ai":"toggler-slider__search"])},null,2),f("button",{class:"toggler-btn flex flex-row align-items-center justify-content-center h-border-radius-6 px-3",onClick:u},[f("img",{src:`${k(r)}images/header/search-md.svg`,alt:"search icon"},null,8,J9),X9]),f("button",{class:"toggler-btn flex flex-row align-items-center justify-content-center h-border-radius-6 py-2 px-3",onClick:d},[f("img",{src:k(l)?`${k(r)}images/header/ai-stars-white.svg`:`${k(r)}images/header/ai-stars-blue.svg`,alt:"search icon"},null,8,e5),f("span",{class:Oe(["h-font-size-14 h-font-weight-500 ml-1",k(l)?"h-color-white":"h-color-denim"])},"AI search",2)])])):M("",!0),k(i)==="kits.ca"||k(i)==="kits.com"?(g(),S("div",t5,[f("img",{class:"vertical-align-middle",src:k(r)+"images/header/close-grey.svg",onClick:p,alt:"Close Icon"},null,8,n5)])):M("",!0)]),f("div",s5,[de(B9)])])):M("",!0),k(o)?M("",!0):(g(),S("div",i5,[de(E9,{headerType:"normal"})]))],2),k(o)?M("",!0):(g(),S("div",r5,[f("div",{class:"flex justify-content-between align-items-center w-full border-1 border-round-3xl h-border-color-iron-dark px-2 py-1 cursor-pointer",style:{"max-width":"500px"},onClick:h},[f("div",a5,[f("img",{src:k(r)+"images/header/search.svg",alt:"search"},null,8,o5),l5]),k(i).includes("contacts")?(g(),S("img",{key:0,class:"barcode-scanner",id:"barcode-scanner",src:k(r)+"images/header/scan-barcode.svg",alt:"scan",onClick:st(m,["stop"])},null,8,c5)):M("",!0)])])),k(o)?M("",!0):(g(),S("div",d5,[k(a).type==="legacy"?(g(),S("a",{key:0,href:k(Ae)()+"/contacts",class:Oe(["h-color-primary py-3 px-3 border-bottom-2",k(s)==="contacts"?"h-border-primary":" h-border-color-transparent"]),onMouseover:b[0]||(b[0]=w=>c("contacts"))},N(k(t)("header.links.contacts")),43,u5)):M("",!0),f("a",{href:k(Ae)()+"/glasses",class:Oe(["h-color-primary py-3 px-3 border-bottom-2",k(s)==="eyeglasses"?"h-border-color-primary":"border-transparent"]),onMouseover:b[1]||(b[1]=w=>c("eyeglasses"))},N(k(t)("header.links.eyeglasses")),43,h5),f("a",{href:k(Ae)()+"/sunglasses",class:Oe(["h-color-primary py-3 px-3 border-bottom-2",k(s)==="sunglasses"?"h-border-primary":" h-border-color-transparent"]),onMouseover:b[2]||(b[2]=w=>c("sunglasses"))},N(k(t)("header.links.sunglasses")),43,p5),f("a",{href:`${k(Ae)()}/ai-smart-glasses`,class:Oe(["h-color-primary py-3 px-3 border-bottom-2 white-space-nowrap",k(s)==="smart-glasses"?"h-border-primary":" h-border-color-transparent"]),onMouseover:b[3]||(b[3]=w=>c("smart-glasses"))},[ke(N(k(t)("header.links.smart-glasses"))+" ",1),m5],42,f5),f("a",{href:`${k(Ae)()}/glasses?product_type=Glasses,Sunglasses&page=1&filters=%26filter=collections_name_uFilter:+${encodeURIComponent("Designer")}`,class:Oe(["h-color-primary py-3 px-3 border-bottom-2",k(s)==="designer"?"h-border-primary":" h-border-color-transparent"]),onMouseover:b[4]||(b[4]=w=>c("designer"))},N(k(t)("header.links.designer")),43,g5),k(i)!=="opticontacts.com"&&k(i)!=="contactsexpress.ca"?(g(),S("a",{key:1,href:k(Ae)()+"/glasses/readers",class:Oe(["h-color-primary py-3 px-3 border-bottom-2",k(s)==="readers"?"h-border-primary":" h-border-color-transparent"]),onMouseover:b[5]||(b[5]=w=>c("readers"))},N(k(t)("header.links.readers")),43,y5)):M("",!0),k(a).type==="normal"?(g(),S("a",{key:2,href:k(Ae)()+"/contacts",class:Oe(["h-color-primary py-3 px-3 border-bottom-2",k(s)==="contacts"?"h-border-primary":"h-border-color-transparent"]),onMouseover:b[6]||(b[6]=w=>c("contacts"))},N(k(t)("header.links.contacts")),43,b5)):M("",!0),f("a",{href:k(Ae)()+"/insurance",class:"insurance-link h-color-primary py-3 px-3 border-bottom-2 cursor-pointer",onMouseover:b[7]||(b[7]=w=>c("")),onClick:v},N(k(t)("header.links.insurance")),41,v5),k(i)==="kits.ca"||k(i)==="kits.com"?(g(),S("a",{key:3,href:`${k(Ae)()}/collection-kits-glasses-sale`,class:"sale-link h-color-alizarin-crimson py-3 px-3 border-bottom-2 cursor-pointer",onMouseover:b[8]||(b[8]=w=>c("sale"))},N(k(t)("header.links.sale")),41,_5)):M("",!0)]))]))}};typeof gu=="function"&&gu(hg);const w5=Ke(hg,[["__scopeId","data-v-630af692"]]);function yu(e){const t=e;t.__i18n=t.__i18n||[],t.__i18n.push({locale:"",resource:{en:{search:{suggestions:{t:0,b:{t:2,i:[{t:3}],s:"Suggestions"}},popular:{t:0,b:{t:2,i:[{t:3}],s:"Popular search"}},trending:{t:0,b:{t:2,i:[{t:3}],s:"Trending products"}},products:{t:0,b:{t:2,i:[{t:3}],s:"Products"}},contacts:{t:0,b:{t:2,i:[{t:3}],s:"Contacts"}},"no-results":{t:0,b:{t:2,i:[{t:3}],s:"Sorry, we couldn't find any matching results for this search."}},"see-trending":{t:0,b:{t:2,i:[{t:3}],s:"These trending products might interest you."}},glasses:{t:0,b:{t:2,i:[{t:3}],s:"Glasses"}},or:{t:0,b:{t:2,i:[{t:3}],s:"or"}},"image-alt":{t:0,b:{t:2,i:[{t:3}],s:"Product Image"}},price:{t:0,b:{t:2,i:[{t:3}],s:"$69"}},results:{t:0,b:{t:2,i:[{t:3}],s:"Results"}},"ai-results":{t:0,b:{t:2,i:[{t:3}],s:"AI-powered results"}}},static:{"popular-search":{eyeglasses:{t:0,b:{t:2,i:[{t:3}],s:"All eyeglasses"}},readers:{t:0,b:{t:2,i:[{t:3}],s:"Readers"}},accessories:{t:0,b:{t:2,i:[{t:3}],s:"Accessories"}},women:{t:0,b:{t:2,i:[{t:3}],s:"Women"}},men:{t:0,b:{t:2,i:[{t:3}],s:"Men"}},prescription:{t:0,b:{t:2,i:[{t:3}],s:"Strong prescription"}},designer:{t:0,b:{t:2,i:[{t:3}],s:"Designer"}},"best-sellers":{t:0,b:{t:2,i:[{t:3}],s:"Best Sellers"}},sunglasses:{t:0,b:{t:2,i:[{t:3}],s:"Sunglasses"}},"new-arrivals":{t:0,b:{t:2,i:[{t:3}],s:"New arrivals"}},rayban:{t:0,b:{t:2,i:[{t:3}],s:"Ray-Ban"}},soren:{t:0,b:{t:2,i:[{t:3}],s:"Soren SE"}}},"ai-search":{trending:{t:0,b:{t:2,i:[{t:3}],s:"Trending glasses"}},lightweight:{t:0,b:{t:2,i:[{t:3}],s:"Lightweight glasses"}},"round-face":{t:0,b:{t:2,i:[{t:3}
2443],s:"Glasses for round face"}},red:{t:0,b:{t:2,i:[{t:3}],s:"Red glasses"}},fancy:{t:0,b:{t:2,i:[{t:3}],s:"Designer frames"}},budget:{t:0,b:{t:2,i:[{t:3}],s:"Budget frames under $38"}},expensive:{t:0,b:{t:2,i:[{t:3}],s:"Premium frames"}}}},faq:{label:{t:0,b:{t:2,i:[{t:3}],s:"FAQ"}},"how-to-insurance":{t:0,b:{t:2,i:[{t:3}],s:"How do I use my insurance?"}},"how-to-buy-glasses":{t:0,b:{t:2,i:[{t:3}],s:"How do I buy glasses online?"}},"receive-order":{t:0,b:{t:2,i:[{t:3}],s:"When will I receive my order?"}}}}}})}const ua=e=>(us("data-v-489d4729"),e=e(),hs(),e),E5={class:"absolute left-0 right-0 header-search-results-container"},S5={id:"search-results-wrapper",class:"search-results-wrapper bg-white"},C5={class:"header-search-results-menu flex flex-column lg:flex-row p-2"},I5={key:0,class:"col-12 lg:col-3 flex flex-column gap-3 mt-2 px-3"},T5={key:0},P5={class:"h-color-pale-sky h-font-size-16 h-font-weight-600"},O5={class:"popular-search__container flex flex-nowrap lg:flex-wrap overflow-x-scroll gap-2 py-4"},A5=["href"],k5=["href"],R5=["src","alt"],L5={class:"h-color-mirage-dark h-font-size-18 h-font-weight-600 pt-3"},N5={class:"h-color-mako-dark h-font-size-14 h-font-weight-500 flex align-items-center gap-1"},D5=["src"],x5={key:1},M5={class:"flex flex-column gap-3 align-items-start h-font-size-14"},F5={class:"h-color-pale-sky h-font-size-16 h-font-weight-600 lg:mt-2 line-height-3 pl-0"},V5={class:"flex flex-wrap flex-column w-full"},B5=["href","innerHTML"],$5={key:2,class:"flex flex-column gap-3 align-items-start h-font-size-14 w-full pl-0"},U5={class:"h-color-pale-sky h-font-size-16 h-font-weight-600 sm:mt-2 line-height-3"},H5={class:"h-font-size-16 h-color-shuttle-gray h-font-weight-400 sm:mx-0"},z5=ua(()=>f("br",null,null,-1)),K5={key:0,class:"flex justify-content-start h-color-denim mb-2"},G5=["src"],j5={key:1},Y5={class:"popular-search__container flex flex-wrap gap-2 py-4 cursor-pointer"},W5=["onClick"],Q5={class:"flex flex-wrap gap-2 py-4"},Z5={key:2,class:"mb-1 mt-3 px-0"},q5={class:"h-color-pale-sky h-font-size-16 h-font-weight-600 line-height-3"},J5={key:3,class:"grid mt-2 px-0"},X5={class:"flex flex-column w-full align-items-start gap-2 pt-2"},eM={class:"mt-3",id:"trending-results",style:{height:"65vh"}},tM={class:"flex flex-column md:flex-row lg:gap-8"},nM={class:"grid mx-1 mt-1 lg:mx-0 lg:mt-0"},sM={class:"col-12 mb-1 p-0"},iM={class:"h-color-pale-sky h-font-size-16 h-font-weight-600"},rM=["href","onMouseover"],aM=["src","alt"],oM=["src","alt"],lM={class:"flex flex-column w-full align-items-start gap-1 py-2 mx-auto"},cM={class:"flex flex-row flex-wrap w-full align-items-center gap-1"},dM={class:"h-font-weight-600 h-color-ebony-clay-dark"},uM={class:"h-color-ebony-clay-dark h-font-size-14"},hM={key:0,class:"h-color-ebony-clay-dark h-font-size-14 my-1"},pM={class:"h-font-weight-500 m-0 h-font-size-16 h-color-mako-dark"},fM=["href","onMouseover"],mM=["src","alt"],gM={class:"flex flex-column w-full align-items-start gap-1 py-2 mx-auto"},yM={class:"flex flex-row flex-wrap w-full align-items-center gap-1"},bM={class:"h-font-weight-600 h-color-primary"},vM={class:"brand-name"},_M={key:0,class:"h-font-weight-500 m-0 sm:mt-3 flex gap-2 h-font-size-16 h-color-mako-dark"},wM={class:"line-through"},EM={class:"h-color-danger"},SM={key:1},CM={class:""},IM={key:1,class:"flex"},TM={class:"line-through"},PM={class:"h-color-danger ml-2"},OM=["href"],AM=["src","alt"],kM={class:"h-color-mirage-dark h-font-size-18 h-font-weight-600 pt-3"},RM={class:"h-color-mako-dark h-font-size-14 h-font-weight-500 flex align-items-center gap-1"},LM=["src"],NM=ua(()=>f("div",{class:"w-full h-8rem sm:h-5rem"},null,-1)),DM={class:"grid mt-2 px-0",id:"search-results",style:{height:"50vh"}},xM=["href","onMouseover"],MM=["src","alt"],FM=["src","alt"],VM={class:"flex flex-column w-full align-items-start gap-1 py-2",style:{"max-width":"320px"}},BM={class:"flex flex-row flex-wrap w-full align-items-center gap-1"},$M={class:"h-color-primary h-font-weight-600 h-font-size-16"},UM={class:"brand-name h-color-mako h-font-weight-400 h-font-size-16"},HM={key:0,class:"h-font-size-14 my-1"}
2443,zM={key:1,class:"h-font-size-16 h-font-weight-500 m-0 h-color-mako-dark"},KM={key:0},GM={class:"line-through"},jM={class:"h-color-danger"},YM={key:2,class:"h-font-weight-500 m-0 flex gap-2 h-font-size-16 h-color-mako-dark"},WM={key:0},QM={class:"line-through"},ZM={class:"h-color-danger"},qM={key:1,class:"flex"},JM={class:"line-through"},XM={class:"h-color-danger ml-2"},e7={key:0,class:"w-full flex align-items-center justify-content-center mb-8"},t7=ua(()=>f("div",{class:"w-full h-8rem sm:h-5rem"},null,-1)),n7=ua(()=>f("div",{class:"header-search-results-freespace"},null,-1)),pg={__name:"HeaderSearchResults",setup(e){vt(async()=>{o=Sp(()=>{const q=Math.floor(Math.random()*l.length);d.value=l[q]},3e3),(r==="kits.com"||r==="kits.ca")&&await n.systemStore.fetchTrendingProducts(),await n.systemStore.fetchTrendingContacts(r)}),cn(()=>{clearInterval(o)});const{t}=rt({useScope:"local"}),n=ie(),{imagePath:i}=Be().public,r=ht(se()),s=It(),a=_l();let o;const l=["thinking","considering","analyzing","processing","reflecting","reasoning","evaluating","pondering","calculating"],c=Re(""),d=Re(l[0]),u=Re(),p=Re(8),h={normal:{src:"images/header/panel/Jan19-2026-Navbar-Search-1.jpg",srcFR:"images/header/panel/Jan19-2026-Navbar-Search-1.jpg",heading:"Popular for a reason",subheading:"Shop KITS best sellers",url:"/glasses?filters=%26filter=collections_name_uFilter:+Popular&product_type=Glasses"},legacy:{src:"images/header/panel/Jan19-2026-Navbar-Search-1.jpg",srcFR:"images/header/panel/Jan19-2026-Navbar-Search-1.jpg",heading:"Popular for a reason",subheading:"Shop KITS best sellers",url:"/glasses?filters=%26filter=collections_name_uFilter:+Popular&product_type=Glasses"}},m=ee(()=>n.systemStore.getSearchResultsLoading),v=ee(()=>n.systemStore.getSearchSuggestionsLoading),_=ee(()=>n.systemStore.getSelectedProductType),b=ee(()=>n.systemStore.getHeaderInformation),w=ee(()=>n.contactsStore.getDiscounts),C=ee(()=>n.systemStore.getIsOpticianSearch),O=ee(()=>n.systemStore.getSearchResults.searchMetaData.queryParams.q),T=ee(()=>n.systemStore.getSearchResults.response.products.filter(q=>q.doctype==="KEYWORD_SUGGESTION"||q.doctype==="TOP_SEARCH_QUERIES")),E=ee(()=>n.systemStore.getSearchValue),y=ee(()=>{const q=c.value||a,ae=[];if(T.value.forEach(ge=>{const we=new RegExp(`(${be(O.value)})`,"gi"),X=ge.autosuggest.replace(/ü/g,"ü").replace(/™/g,"™"),B=X.replace(we,"<strong>$1</strong>");ae.push({raw:X,formatted:B,key:X,readersType:""})}),q&&T.value.length>0){const ge=T.value[0],we=new RegExp(`(${be(O.value)})`,"gi"),X=ge.autosuggest.replace(/ü/g,"ü").replace(/™/g,"™"),B=X.replace(we,"<strong>$1</strong>");q==="progressive-readers"?(ae.push({raw:X,formatted:`${B} Progressive Readers`,key:`${X}-progressive-readers`,readersType:"progressive-readers"}),ae.push({raw:X,formatted:`${B} Readers`,key:`${X}-readers`,readersType:"readers"})):ae.push({raw:X,formatted:`${B} Readers`,key:`${X}-readers`,readersType:"readers"})}return ae}),P=ee(()=>n.systemStore.getTrendingResults.items),A=ee(()=>n.systemStore.getTrendingContacts.products),I=ee(()=>n.systemStore.getSearchResults.response.products.filter(q=>q.doctype==="POPULAR_PRODUCTS").map(q=>({...q,name:Td(q.name),autosuggest:Td(q.autosuggest)}))),L=ee(()=>C.value?I.value.slice(0,p.value):I.value),D=ee(()=>C.value&&p.value<I.value.length),z=ee(()=>{let q=[];return q=_.value==="trending"?A.value:I.value,q.length===0&&(q=A.value),q}),G=ee(()=>z.value.map(q=>{const ge=kC(w.value,q.products_sku,q.brand_name)/100,we=PC([{price:q.price,quantity:4}],4),X=we-we*ge;return{discountedPrice:ss(X),price:ss(we),price_1r:q.price_1r}})),ne=ee(()=>n.glassesStore.getReaders.progressive),W=ee(()=>[{text:r.includes("kits")?t("static.popular-search.soren"):t("static.popular-search.eyeglasses"),url:r.includes("kits")?"/glasses/GL22133/soren-se":"/glasses"},{text:t("static.popular-search.readers"),url:"/glasses/readers"},{text:t("static.popular-search.women"),url:'/glasses?product_type=Glasses&filters=%26filter=gender_uFilter:+"Unisex"+OR+gender_uFilter:+"Female"&page=1'},{text:t("static.popular-search.men"),url:'/glasses?product_type=Glasses&filters=%26filter=gender_uFilter:+"Unisex"+OR+gender_uFilter:+"Male"&page=1'},{text:t("static.popular-search.prescription"),url:'/glasses?product_type=Glasses&filters=%26filter=material_uFilter:+"Acetate"+OR+material_uFilter:+"Plastic"+OR+material_uFilter:+"Eco-Friendly"&page=1'}]),ue=ee(()=>{const q=n.systemStore.getAiSearchSuggestions;return(q==null?void 0:q.length)!==0?q:[{text:t("static.ai-search.trending")},{text:t("static.ai-search.lightweight")}
2443,{text:t("static.ai-search.round-face")},{text:t("static.ai-search.red")}]}),H=q=>{const ae=Ae(),ge=q.readersType?`/glasses/${q.readersType}`:"/glasses",we=new URLSearchParams({q:q.raw});return`${ae}${ge}?${we.toString()}`},x=()=>{p.value=I.value.length},V=q=>a==="sun-readers"||a==="sun-progressive-readers"?`${q.includes("Sun")?"":"Sun"} ${ne.value?"Progressive Readers":"Readers"} `:a==="readers"||a==="progressive-readers"?`${ne.value?"Progressive":""} Readers`:"",te=q=>{const ae=q.url.replace(".html",""),ge=!a&&(q==null?void 0:q.type)==="glasses"?c.value:"",we=a||ge,X=we?`${we.replace(/^\/|\/$/g,"")}/`:"";return ae.replace(/^\/glasses\//,`/glasses/${X}`)},fe=q=>{var we;if(!q)return"#";const ae=q.product_group.toLowerCase();q.autosuggest.split(" ").join("");const ge=Array.isArray(q.category)&&q.category.some(X=>(X==null?void 0:X.toLowerCase())==="eyeglasses")&&!((we=q.category)!=null&&we.some(X=>(X==null?void 0:X.toLowerCase())==="sunglasses"));if(ae.includes("contact"))return`/contact_lenses/${q.products_sku}/${$n(q.autosuggest)}`;if(ae==="glasses"||ae==="sunglasses")if(ge){const X=!a&&q.accepts_lenses&&q.accepts_lenses!==!1?c.value:"",B=a||X;return`/glasses/${B?`${B.replace(/^\/|\/$/g,"")}/`:""}${q.products_sku}/${$n(q.autosuggest,q==null?void 0:q.brand_name)}?config=${q.configuration_id}`}else return`/glasses/${q.products_sku}/${$n(q.autosuggest,q==null?void 0:q.brand_name)}?config=${q.configuration_id}`;if(ae==="accessories")return`/accessories/${q.products_sku}`},re=(q,ae)=>q.includes(ae)?q.replace(ae,""):q,be=q=>q.replace(/[.*+?^${}()|[\]\\]/g,"\\$&"),Y=()=>{ea("predictive_search",{query:n.systemStore.getSearchValue,source:C.value?"Optician AI":"Regular"})},oe=async q=>{const ae=n.systemStore.getSearchValue,ge=ae?`${ae} ${q.text}`:q.text;n.systemStore.setSearchValue(ge),await n.systemStore.fetchSearchProduct(ge,r,C.value)},K=q=>{const ae=q==null?void 0:q.category;return"accepts_lenses"in(q||{})&&!(q.accepts_lenses=="1"||q.accepts_lenses===!0)?!1:Array.isArray(ae)?ae.some(ge=>(ge==null?void 0:ge.toLowerCase())==="eyeglasses")&&!ae.some(ge=>(ge==null?void 0:ge.toLowerCase())==="sunglasses"):typeof ae=="string"?ae.toLowerCase()==="glasses":!1},Z=q=>{if(!K(q))return 0;const ae=re(q.autosuggest||q.name||"",q.brand_name);return(V(ae)||me(q)).toLowerCase().includes("progressive readers")?50:0},me=q=>!c.value||c.value==="progressive-readers"&&!K(q)?"":c.value==="progressive-readers"?"Progressive Readers":c.value==="readers"?"Readers":"";return We(I,()=>{p.value=8}),We(()=>n.systemStore.getSearchInputText,q=>{const ae=(q||"").toLowerCase();vr(ae,"progressive")?c.value="progressive-readers":vr(ae,"readers")?c.value="readers":c.value=""},{immediate:!0}),We(E,(q,ae)=>{q.trim()===""&&(c.value="")},{immediate:!0}),(q,ae)=>{const ge=le("Skeleton"),we=le("Button");return g(),S("div",E5,[f("div",S5,[f("div",C5,[k(C)?M("",!0):(g(),S("div",I5,[k(O)===""&&k(T).length===0?(g(),S("div",T5,[f("span",P5,N(k(t)("search.popular")),1),f("div",O5,[(g(!0),S(J,null,ye(k(W),X=>(g(),S("a",{key:X,href:k(Ae)()+`${X.url}`,class:"popular-search__item h-color-chinese-black h-font-size-14 h-font-weight-400 h-bg-alice-white border-round-3xl py-2 px-3 white-space-nowrap"},N(X.text),9,A5))),128))]),f("a",{class:"promo-wrapper desktop",href:k(Ae)()+h[k(b).type].url},[f("img",{src:k(i)+(k(s).href.toLowerCase().includes("fr_ca")?h[k(b).type].srcFR:h[k(b).type].src),alt:h[k(b).type].heading,style:{"max-height":"70%",width:"100%"}},null,8,R5),f("div",L5,N(h[k(b).type].heading),1),f("div",N5,[ke(N(h[k(b).type].subheading)+" ",1),f("img",{src:k(i)+"images/header/arrow-right-smaller-414651.svg",height:"20",width:"20",alt:"Small Right Arrow"},null,8,D5)])],8,k5)])):k(O)!==""&&k(T).length>0?(g(),S("div",x5,[f("div",M5,[f("span",F5,N(k(t)("search.suggestions")),1),f("div",V5,[(g(!0),S(J,null,ye(k(y),X=>(g(),S("a",{key:X.key,href:H(X),class:"suggestions__container h-color-primary h-font-size-14 sm:h-font-size-16 line-height-3 py-1",innerHTML:X.formatted},null,8,B5))),128))])])])):k(O)!==""&&k(T).length===0?(g(),S("div",$5,[f("span",U5,N(k(t)("search.suggestions"))+":",1),f("div",H5,[ke(N(k(t)("search.no-results")),1),z5,ke(N(k(t)("search.see-trending")),1)])])):M("",!0)])),f("div",{class:Oe(k(C)?"col-12 flex justify-content-center":"col-12 lg:col-9")},[f("div",{class:Oe([k(C)?"col-12 lg:col-9":"col-12","px-3"])},[k(C)?(g(),S("div",K5,[f("span",{class:Oe([k(m)?"flex":"hidden","align-items-center gap-2"])},[de(dg),ke(" Optician AI is "+N(k(d)),1)],2),f("span",{class:Oe([k(m)?"hidden":"flex","align-items-center gap-1"])},[f("img",{class:"vertical-align-middle",src:k(i)+"images/header/ai-stars-blue.svg",alt:"search"},null,8,G5),ke(" "+N(k(I).length===0?"Describe what you're looking for":"Here are the best matches. Use the smart filter to refine further"),1)],2)])):M("",!0),k(C)?(g(),S("div",j5,[
2443Ne(f("div",null,[f("div",Y5,[(g(!0),S(J,null,ye(k(ue),X=>(g(),S("button",{onClick:B=>oe(X),key:X,class:"popular-search__item h-color-chinese-black h-font-size-14 h-font-weight-400 h-bg-cloud-blue border-round-3xl py-2 px-3 white-space-nowrap"},N(X.text),9,W5))),128))])],512),[[mt,!k(v)]]),Ne(f("div",null,[f("div",Q5,[(g(),S(J,null,ye(["130px","150px","175px","110px","160px"],X=>de(ge,{key:X,width:X,height:"33px",borderRadius:"16px"},null,8,["width"])),64))])],512),[[mt,k(v)]])])):M("",!0),k(I).length>0&&!k(m)?(g(),S("div",Z5,[f("span",q5,N(k(C)?k(t)("search.ai-results"):k(t)("search.results"))+" ("+N(k(I).length)+") ",1)])):M("",!0),k(m)?(g(),S("div",J5,[(g(),S(J,null,ye(8,X=>f("div",{key:X,class:"col-6 lg:col-3 flex flex-column align-items-center justify-content-center mb-3"},[de(ge,{width:"100%",height:"150px",borderRadius:"8px"}),f("div",X5,[de(ge,{width:"70%",height:"0.75rem",borderRadius:"4px"}),de(ge,{width:"40%",height:"0.75rem",borderRadius:"4px"})])])),64))])):M("",!0),Ne(f("div",eM,[f("div",tM,[f("div",nM,[f("div",sM,[f("span",iM,N(k(t)("search.trending")),1)]),k(r)==="kits.ca"||k(r)==="kits.com"?(g(!0),S(J,{key:0},ye(k(P),(X,B)=>(g(),S("a",{key:X.config_id,href:k(Ae)()+te(X),onMouseover:Se=>u.value=B,onMouseout:ae[0]||(ae[0]=Se=>u.value=null),class:"col-6 sm:col-4 lg:col-3 flex flex-column align-items-center justify-content-center"},[Ne(f("img",{src:X.image,alt:k(t)("search.image-alt"),class:"w-full"},null,8,aM),[[mt,B!==k(u)||!X.image_alt1]]),Ne(f("img",{src:X.image_alt1,alt:k(t)("search.image-alt"),class:"w-full"},null,8,oM),[[mt,B===k(u)&&X.image_alt1]]),f("div",lM,[f("div",cM,[f("span",dM,N(X.brand_name),1),f("span",uM,N(X.name),1)]),V(X.name)||me(X)?(g(),S("span",hM,N(V(X.name)||me(X)),1)):M("",!0),f("p",pM," $"+N(k(ss)(X.price+Z(X))),1)])],40,rM))),128)):(g(!0),S(J,{key:1},ye(k(A),(X,B)=>{var Se,Ce,U,j,ce,Ie,De;return g(),S("a",{key:X.uniqueId,href:k(Ae)()+`/contact_lenses/${X.products_sku}/${k($n)(X.name)}`,onMouseover:Te=>u.value=B,onMouseout:ae[1]||(ae[1]=Te=>u.value=null),class:"col-6 sm:col-4 lg:col-3 flex flex-column align-items-center justify-content-center"},[f("img",{src:X.imageUrl[0],alt:k(t)("search.image-alt"),class:"w-full"},null,8,mM),f("div",gM,[f("div",yM,[f("span",bM,N(X.brand_name),1),f("span",vM,N(X.name),1)]),k(gi)===!1?(g(),S(J,{key:0},[((Se=k(G)[B])==null?void 0:Se.price)!==((Ce=k(G)[B])==null?void 0:Ce.discountedPrice)?(g(),S("div",_M,[f("span",wM," $"+N((U=k(G)[B])==null?void 0:U.price),1),f("span",EM," $"+N((j=k(G)[B])==null?void 0:j.discountedPrice),1)])):(g(),S("div",SM,[f("span",CM," $"+N((ce=k(G)[B])==null?void 0:ce.price),1)]))],64)):(g(),S("div",IM,[f("span",TM," $"+N((Ie=k(G)[B])==null?void 0:Ie.price),1),f("span",PM," $"+N((De=k(G)[B])==null?void 0:De.price_1r),1)]))])],40,fM)}),128))])]),f("a",{class:"promo-wrapper mobile",href:k(Ae)()+h[k(b).type].url},[f("img",{src:k(i)+(k(s).href.toLowerCase().includes("fr_ca")?h[k(b).type].srcFR:h[k(b).type].src),alt:h[k(b).type].heading,style:{"max-height":"70%",width:"100%"}},null,8,AM),f("div",kM,N(h[k(b).type].heading),1),f("div",RM,[ke(N(h[k(b).type].subheading)+" ",1),f("img",{src:k(i)+"images/header/arrow-right-smaller-414651.svg",height:"20",width:"20",alt:"Small Right Arrow"},null,8,LM)])],8,OM),NM],512),[[mt,k(I).length===0&&!k(m)&&!k(C)]]),Ne(f("div",DM,[(g(!0),S(J,null,ye(k(L),(X,B)=>{var Se,Ce,U,j,ce,Ie,De;return g(),S("a",{key:X,href:k(Ae)()+fe(X),onClick:Y,onMouseover:Te=>u.value=B,onMouseout:ae[2]||(ae[2]=Te=>u.value=null),class:"col-6 sm:col-4 lg:col-3 flex flex-column align-items-center justify-content-center"},[Ne(f("img",{src:X.imageUrl[0],alt:k(t)("search.image-alt"),style:{"max-width":"320px"},class:"w-full"},null,8,MM),[[mt,B!==k(u)||!X.angle_image]]),Ne(f("img",{src:X.angle_image,alt:k(t)("search.image-alt"),style:{"max-width":"320px"},class:"w-full"},null,8,FM),[[mt,B===k(u)&&X.angle_image]]),f("div",VM,[f("div",BM,[f("span",$M,N(X.brand_name),1),f("span",UM,N(re(X.autosuggest,X.brand_name)),1)]),Array.isArray(X.category)&&X.category[0]==="Eyeglasses"&&(V(re(X.autosuggest,X.brand_name))||me(X))?(g(),S("span",HM,N(V(re(X.autosuggest,X.brand_name))||me(X)),1)):M("",!0),X.product_group!=="Contact Lenses"?(g(),S("div",zM,[!X.promo_price||X.promo_price<=X.price?(g(),S("span",KM,"$"+N(k(ss)(X.price+Z(X))),1)):(g(),S(J,{key:1},[f("span",GM," $"+N(k(ss)(X.promo_price+Z(X))),1),f("span",jM," $"+N(k(ss)(X.price+Z(X))),1)],64))])):M("",!0),X.product_group==="Contact Lenses"?(g(),S("div",YM,[k(gi)===!1?(g(),S(J,{key:0},[((Se=k(G)[B])==null?void 0:Se.discountedPrice)>=((Ce=k(G)[B])==null?void 0:Ce.price)?(g(),S("span",WM," $"+N((U=k(G)[B])==null?void 0:U.price),1)):(g(),S(J,{key:1},[f("span",QM," $"+N((j=k(G)[B])==null?void 0:j.price),1),f("span",ZM," $"+N((ce=k(G)[B])==null?void 0:ce.discountedPrice),1)],64))],64)):(g(),S("div",qM,[f("span",JM," $"+N((Ie=k(G)[B])==null?void 0:Ie.price),1),f("span",X
2443M," $"+N((De=k(G)[B])==null?void 0:De.price_1r),1)]))])):M("",!0)])],40,xM)}),128)),k(D)?(g(),S("div",e7,[de(we,{class:"mt-4 button__primary-kits-v3 px-3 flex flex-row align-items-center",type:"button",label:"See all",onClick:st(x,["prevent"])})])):M("",!0),t7],512),[[mt,k(I).length!==0&&!k(m)]])],2)],2)])]),n7])}}};typeof yu=="function"&&yu(pg);const s7=Ke(pg,[["__scopeId","data-v-489d4729"]]);function bu(e){const t=e;t.__i18n=t.__i18n||[],t.__i18n.push({locale:"",resource:{en:{shop:{title:{t:0,b:{t:2,i:[{t:3}],s:"Shop"}},all:{t:0,b:{t:2,i:[{t:3}],s:"All contacts"}},daily:{t:0,b:{t:2,i:[{t:3}],s:"Daily"}},weekly:{t:0,b:{t:2,i:[{t:3}],s:"Weekly"}},monthly:{t:0,b:{t:2,i:[{t:3}],s:"Monthly"}},single:{t:0,b:{t:2,i:[{t:3}],s:"Toric"}},multifocal:{t:0,b:{t:2,i:[{t:3}],s:"Multifocal"}},color:{t:0,b:{t:2,i:[{t:3}],s:"Color"}},colour:{t:0,b:{t:2,i:[{t:3}],s:"Colour"}}},"featured-brands":{title:{t:0,b:{t:2,i:[{t:3}],s:"Featured"}},all:{t:0,b:{t:2,i:[{t:3}],s:"See all"}}}}}})}const fg=Ge({components:{},setup(){const{t:e}=rt({useScope:"local"}),{imagePath:t}=Be().public,n=ie(),i=ht(se());let r=It();const s=ee(()=>n.systemStore.getHeaderInformation),a=[{text:"shop.all",url:"/contacts"},{text:"shop.daily",url:'/contacts?filters=%26filter=category_uFilter:+"Daily+Disposables"'},{text:"shop.weekly",url:'/contacts?filters=%26filter=category_uFilter:+"1-2+Week+Disposables"'},{text:"shop.monthly",url:'/contacts?filters=%26filter=category_uFilter:+"Monthly+Disposables"'},{text:"shop.single",url:'/contacts?filters=%26filter=category_uFilter:+"Toric+Lenses"'},{text:"shop.multifocal",url:'/contacts?filters=%26filter=category_uFilter:+"Bifocals+and+Progressives"'},{text:i.includes(".ca")?"shop.colour":"shop.color",url:"/contacts?filters=%26filter=category_uFilter:+Color+Disposables"}];return{t:e,path:r,imagePath:t,headerInformation:s,shopItems:a,featuredBrands:[{img:"images/header/panel/brands/contacts/logo-kits-daily.svg",alt:"Kits Daily",url:'/contacts?filters=%26filter=brand_name_uFilter:+"KITS"'},{img:"images/header/panel/brands/contacts/logo-acuvue.svg",alt:"Acuvue",url:'/contacts?filters=%26filter=brand_name_uFilter:+"Johnson+and+Johnson"'},{img:"images/header/panel/brands/contacts/logo-biofinity.svg",alt:"Biofinity",url:'/contacts?filters=%26filter=brand_name_uFilter:+"CooperVision"'},{img:"images/header/panel/brands/contacts/logo-dailies.svg",alt:"Dailies",url:'/contacts?filters=%26filter=brand_name_uFilter:+"Alcon"'},{img:"images/header/panel/brands/contacts/logo-air-optix.svg",alt:"Air Optix",url:'/contacts?filters=%26filter=brand_name_uFilter:+"Alcon"'},{img:"images/header/panel/brands/contacts/logo-clariti.svg",alt:"Clariti",url:'/contacts?filters=%26filter=brand_name_uFilter:+"CooperVision"'},{img:"images/header/panel/brands/contacts/logo-precision1.svg",alt:"Precision 1",url:'/contacts?filters=%26filter=brand_name_uFilter:+"Alcon"'},{img:"images/header/panel/brands/contacts/logo-biotrue.svg",alt:"Biotrue",url:'/contacts?filters=%26filter=brand_name_uFilter:+"Bausch+and+Lomb"'},{img:"images/header/panel/brands/contacts/logo-ultra.svg",alt:"Bausch & Lomb ULTRA",url:'/contacts?filters=%26filter=brand_name_uFilter:+"Bausch+and+Lomb"'}],images:[{src:"images/header/panel/Apr30-2026-Navbar-Contacts-1.jpg",srcFR:"images/header/panel/Apr30-2026-Navbar-Contacts-1.jpg",heading:"Contacts starting at $1 a day",subheading:"Shop KITS Daily",url:"/kits-daily-contacts"}],setDynamicLink:Ae}}}),i7={class:"flex"},r7={style:{width:"200px"}},a7={class:"py-2 h-color-pale-sky h-font-size-16 h-font-weight-600"},o7={class:"pt-2 h-color-mirage-dark h-font-size-18 h-font-weight-500"},l7=["href"],c7={style:{"max-width":"425px"}},d7={class:"py-2 h-color-pale-sky h-font-size-16 h-font-weight-600"},u7={class:"brands-grid"},h7=["href"],p7=["src","alt"],f7={class:"flex gap-5"},m7=["href"],g7=["src","alt"],y7={class:"h-color-mirage-dark h-font-size-18 h-font-weight-600"},b7={class:"w-fit h-color-mako-dark h-font-size-14 h-font-weight-500 flex align-items-center gap-1 subheading"},v7=["src"];function _7(e,t,n,i,r,s){return g(),S("div",{class:Oe(["flex w-full gap-5",e.images.length===2?"justify-content-center":"justify-content-between"]),style:{"max-width":"1440px",margin:"0 auto"}},[f("div",i7,[f("div",r7,[f("div",a7,N(e.t("shop.title")),1),(g(!0),S(J,null,ye(e.shopItems,a=>(g(),S("div",o7,[f("a",{href:e.setDynamicLink()+a.url,class:"block item-title"},N(e.t(a.text)),9,l7)]))),256))]),f("div",c7,[f("div",d7,N(e.t("featured-brands.title")),1),f("div",u7,[(g(!0),S(J,null,ye(e.featuredBrands,a=>(g(),S("a",{key:a.text,href:e.setDynamicLink()+a.url,class:"brand-wrapper cursor-pointer"},[f("img",{src:e.imagePath+a.img,alt:a.alt},null,8,p7)],8,h7))),128))])])]),f("div",f7,[(g(!0),S(J,null,ye(e.images,(a,o)=>(g(),S("a",{key:o,class:"promo-wrapper",href:e.setDynamicLink()+a.url},[f("img",{src:e.imagePath+(e.path.href.toLowerCase().includes("fr_ca")?a.srcFR:a.src),alt:a.heading,style:{"max-height":"70%",width:"100%"}}
2443,null,8,g7),f("div",y7,N(a.heading),1),f("div",b7,[ke(N(a.subheading)+" ",1),f("img",{src:e.imagePath+"images/header/arrow-right-smaller-414651.svg",height:"20",width:"20",alt:"Small Right Arrow"},null,8,v7)])],8,m7))),128))])],2)}typeof bu=="function"&&bu(fg);const w7=Ke(fg,[["render",_7],["__scopeId","data-v-6e87fd60"]]);function vu(e){const t=e;t.__i18n=t.__i18n||[],t.__i18n.push({locale:"",resource:{en:{shop:{title:{t:0,b:{t:2,i:[{t:3}],s:"Shop"}},all:{t:0,b:{t:2,i:[{t:3}],s:"All eyeglasses"}},women:{t:0,b:{t:2,i:[{t:3}],s:"Women"}},men:{t:0,b:{t:2,i:[{t:3}],s:"Men"}},kids:{t:0,b:{t:2,i:[{t:3}],s:"Kids"}},accessories:{t:0,b:{t:2,i:[{t:3}],s:"Accessories"}}},featured:{title:{t:0,b:{t:2,i:[{t:3}],s:"Featured"}},"fit-and-style":{t:0,b:{t:2,i:[{t:3}],s:"Fit & Style Quiz"}},"best-sellers":{t:0,b:{t:2,i:[{t:3}],s:"Best sellers"}},"progressive-eligible":{t:0,b:{t:2,i:[{t:3}],s:"Progressives"}},new:{t:0,b:{t:2,i:[{t:3}],s:"KITS new arrivals"}},eyeglasses:{t:0,b:{t:2,i:[{t:3}],s:"KITS eyeglasses"}},designer:{t:0,b:{t:2,i:[{t:3}],s:"Designer eyeglasses"}}},curated:{title:{t:0,b:{t:2,i:[{t:3}],s:"Curated"}},"campus-edit":{t:0,b:{t:2,i:[{t:3}],s:"The Campus Edit"}},"office-ready":{t:0,b:{t:2,i:[{t:3}],s:"Office Ready"}}}}}})}const mg=Ge({components:{},setup(){const{t:e}=rt({useScope:"local"}),{imagePath:t}=Be().public,n=ie(),i=ht(se());let r=It();const s=ee(()=>n.systemStore.getGenericSiteMetadata),a=ee(()=>{let d=[{text:"shop.all",url:"/glasses"},{text:"shop.women",url:"/glasses?filters=%26filter=gender_uFilter:+Unisex+OR+gender_uFilter:+Women&product_type=Glasses"},{text:"shop.men",url:"/glasses?filters=%26filter=gender_uFilter:+Unisex+OR+gender_uFilter:+Men&product_type=Glasses"},{text:"shop.kids",url:"/glasses?filters=%26filter=gender_uFilter:+Kids&product_type=Glasses"}];return i==="kits.ca"&&d.push({text:"shop.accessories",url:"/accessories"}),d}),o=[{text:"featured.best-sellers",url:"/glasses?filters=%26filter=collections_name_uFilter:+Popular&product_type=Glasses"},{text:"featured.progressive-eligible",url:"/glasses?filters=%26filter=features_uFilter:+Progressive+Eligible&product_type=Glasses"},{text:"featured.new",url:"/glasses?filters=%26filter=collections_name_uFilter:+New&product_type=Glasses"},{text:"featured.eyeglasses",url:"/glasses?filters=%26filter=brand_name_uFilter:+KITS&product_type=Glasses"},{text:"featured.designer",url:"/glasses?filters=%26filter=collections_name_uFilter:+Designer&product_type=Glasses"}],l=[{text:"curated.campus-edit",url:"/glasses?filters=%26filter=collections_name_uFilter:+The+Campus+Edit&product_type=Glasses"},{text:"curated.office-ready",url:"/glasses?filters=%26filter=collections_name_uFilter:+Office+Ready&product_type=Glasses"}];return i.includes("kits")&&o.unshift({text:"featured.fit-and-style",url:"/quiz/glasses",label:"fit"}),{t:e,imagePath:t,genericSiteMetadata:s,shopItems:a,featuredItems:o,curatedItems:l,images:[{src:"images/header/panel/Jul20-2026-Navbar-Eyeglasses-1.jpg",srcFR:"images/header/panel/Jul20-2026-Navbar-Eyeglasses-1.jpg",heading:"Up to 50% off Kids frames",subheading:"Shop kids glasses",url:"/glasses?filters=%26filter=gender_uFilter:+Kids&product_type=Glasses"},{src:"images/header/panel/Jul14-2026-Navbar-Smart-Glasses-1.jpg",srcFR:"images/header/panel/Jul14-2026-Navbar-Smart-Glasses-1.jpg",heading:"Meet Your Everyday AI Glasses",subheading:"Shop KITS Pangolin 3",url:"/glasses?filters=%26filter=brand_name_uFilter:+KITS%26filter=collections_name_uFilter:+Smart+Glasses&product_type=Glasses,Sunglasses"}],setDynamicLink:Ae,path:r}}}),E7={class:"navigation-expand h-full flex justify-content-between gap-4",style:{"max-width":"1440px",margin:"0 auto"}},S7={class:"flex gap-8"},C7={style:{width:"200px"}},I7={class:"py-2 h-color-pale-sky h-font-size-16 h-font-weight-600"},T7=["href"],P7={style:{width:"200px"}},O7={class:"py-2 h-color-pale-sky h-font-size-16 h-font-weight-600"},A7=["id"],k7=["href"],R7={key:0,class:"pill pill--new"},L7={style:{width:"200px"}},N7={class:"py-2 h-color-pale-sky h-font-size-16 h-font-weight-600"},D7={class:"pt-2 h-color-mirage-dark h-font-size-18 h-font-weight-500 align-items-center"},x7=["href"],M7={class:"flex gap-5"},F7=["href"],V7=["src","alt"],B7={class:"h-color-mirage-dark h-font-size-18 h-font-weight-600"},$7={class:"w-fit h-color-mako-dark h-font-size-14 h-font-weight-500 flex align-items-center gap-1 subheading"},U7=["src"];function H7(e,t,n,i,r,s){return g(),S("div",E7,[f("div",S7,[f("div",C7,[f("div",I7,N(e.t("shop.title")),1),(g(!0),S(J,null,ye(e.shopItems,a=>(g(),S("div",{key:a.text,class:"pt-2 h-color-mirage-dark h-font-size-18 h-font-weight-500"},[f("a",{href:e.setDynamicLink()+a.url,class:"block item-title"},N(e.t(a.text)),9,T7)]))),128))]),f("div",P7,[f("div",O7,N(e.t("featured.title")),1),(g(!0),S(J,null,ye(e.featuredItems,(a,o)=>(g(),S("div",{key:a.text,class:"pt-2 h-color-mirage-dark h-font-size-18 h-font-weight-500 align-items-center",id:a.label==="fit"?"monetate-pdp-eyeglasses-quiz":"",style:cs(a.label==="fit"?{display:"none"}:"")}
2443,[f("a",{class:Oe(["block item-title",{"h-color-denim":a.label==="fit"}]),href:e.setDynamicLink()+a.url},N(e.t(a.text)),11,k7),a.label==="fit"?(g(),S("div",R7,"New")):M("",!0)],12,A7))),128))]),f("div",L7,[f("div",N7,N(e.t("curated.title")),1),(g(!0),S(J,null,ye(e.curatedItems,a=>(g(),S("div",D7,[f("a",{class:"block item-title",href:e.setDynamicLink()+a.url},N(e.t(a.text)),9,x7)]))),256))])]),f("div",M7,[(g(!0),S(J,null,ye(e.images,(a,o)=>(g(),S("a",{key:o,class:"promo-wrapper",href:e.setDynamicLink()+a.url},[f("img",{src:e.imagePath+(e.path.href.toLowerCase().includes("fr_ca")?a.srcFR:a.src),alt:a.heading,style:{"max-height":"70%",width:"100%"}},null,8,V7),f("div",B7,N(a.heading),1),f("div",$7,[ke(N(a.subheading)+" ",1),f("img",{src:e.imagePath+"images/header/arrow-right-smaller-414651.svg",height:"20",width:"20",alt:"Small Right Arrow"},null,8,U7)])],8,F7))),128))])])}typeof vu=="function"&&vu(mg);const z7=Ke(mg,[["render",H7],["__scopeId","data-v-3c772f00"]]);function _u(e){const t=e;t.__i18n=t.__i18n||[],t.__i18n.push({locale:"",resource:{en:{shop:{all:{t:0,b:{t:2,i:[{t:3}],s:"All progressives"}},"shop-title":{t:0,b:{t:2,i:[{t:3}],s:"Shop"}},women:{t:0,b:{t:2,i:[{t:3}],s:"Women"}},men:{t:0,b:{t:2,i:[{t:3}],s:"Men"}},kids:{t:0,b:{t:2,i:[{t:3}],s:"Kids"}},sale:{t:0,b:{t:2,i:[{t:3}],s:"Designer sale from $50"}}},faq:{title:{t:0,b:{t:2,i:[{t:3}],s:"FAQ"}},"progressive-easy":{t:0,b:{t:2,i:[{t:3}],s:"Progressive made easy"}},"how-to-buy-glasses":{t:0,b:{t:2,i:[{t:3}],s:"How do I buy glasses online?"}}},"frame-size":{title:{t:0,b:{t:2,i:[{t:3}],s:"Frame size"}},"extra-small":{t:0,b:{t:2,i:[{t:3}],s:"Extra Small"}},small:{t:0,b:{t:2,i:[{t:3}],s:"Small"}},medium:{t:0,b:{t:2,i:[{t:3}],s:"Medium"}},large:{t:0,b:{t:2,i:[{t:3}],s:"Large"}},"find-size":{t:0,b:{t:2,i:[{t:3}],s:"Find my frame size"}},"last-purchased":{t:0,b:{t:2,i:[{t:3}],s:"Last purchased"}}}}}})}const gg=Ge({components:{},setup(){const{t:e}=rt({useScope:"local"}),{imagePath:t}=Be().public,n=ie(),i=ee(()=>n.systemStore.genericSiteMetadata);let r=It();const s=[{text:"shop.all",url:'/glasses?filters=%26filter=features_uFilter:+"Progressive+Eligible"&product_type=Glasses&page=1'},{text:"shop.women",url:'/glasses?filters=%26filter=features_uFilter:+"Progressive+Eligible"%26filter=gender_uFilter:+"Female"+OR+gender_uFilter:+"Unisex"&product_type=Glasses&page=1'},{text:"shop.men",url:'/glasses?filters=%26filter=features_uFilter:+"Progressive+Eligible"%26filter=gender_uFilter:+"Unisex"+OR+gender_uFilter:+"Male"&product_type=Glasses&page=1'},{text:"shop.kids",url:'/glasses?filters=%26filter=features_uFilter:+"Progressive+Eligible"%26filter=gender_uFilter:+"Kids"&product_type=Glasses&page=1'},{text:"shop.sale",url:"/glasses?product_type=Glasses,Sunglasses&filters=%26filter=collections_name_uFilter:+Designer+Promo%26filter=features_uFilter:+Progressive+Eligible"}],a=[{text:"faq.progressive-easy",url:"/progressive-lenses"},{text:"faq.how-to-buy-glasses",url:"/how_to_buy_glasses_online"}],o=[{text:"frame-size.small",url:'/glasses?product_type=Glasses&filters=%26filter=features_uFilter:+"Progressive+Eligible"%26filter=v_tshirt_size_uFilter:+"S"&page=1 ',label:"S"},{text:"frame-size.medium",url:'/glasses?product_type=Glasses&filters=%26filter=features_uFilter:+"Progressive+Eligible"%26filter=v_tshirt_size_uFilter:+"M"&page=1',label:"M"},{text:"frame-size.large",url:'/glasses?product_type=Glasses&filters=%26filter=features_uFilter:+"Progressive+Eligible"%26filter=v_tshirt_size_uFilter:+"L"&page=1 ',label:"L"}],l=ee(()=>{let c=[];return c.push({src:"images/header/panel/Jan12-2026-Navbar-Progressives-1.jpg",srcFR:"images/header/panel/Jan12-2026-Navbar-Progressives-1.jpg",alt:"KITS Progressives",url:"/glasses?filters=%26filter=features_uFilter:+Progressive+Eligible%26filter=brand_name_uFilter:+KITS&product_type=Glasses"}),c});return{t:e,images:l,imagePath:t,genericSiteMetadata:i,path:r,shopItems:s,faqItems:a,frameItems:o,setDynamicLink:Ae}}}),K7={class:"navigation-expand flex justify-content-between gap-4 pb-2",style:{"max-width":"800px",margin:"0 auto"}},G7={class:""},j7={class:"py-2 h-font-weight-700"},Y7={class:"h-color-primary h-font-weight-600"},W7=["href"],Q7={class:""},Z7={class:"py-2 h-font-weight-700"},q7={class:"h-color-primary h-font-weight-600"},J7=["href"],X7={key:0,class:"h-bg-selago inline border-round-lg py-1 px-2 h-font-size-12 mx-1"},eF={class:"h-color-royal-blue"},tF={class:""},nF={class:"py-2 h-font-weight-700"},sF={class:"h-color-primary h-font-weight-600"},iF=["href"],rF={class:"flex gap-3"},aF=["href"],oF=["src","alt"],lF={class:"col-11 px-0 py-2 h-color-mako h-font-size-16 h-font-weight-400"};function cF(e,t,n,i,r,s){return g(),S("div",K7,[f("div",G7,[f("div",j7,[f("span",Y7,N(e.t("shop.shop-title")),1)]),(g(!0),S(J,null,ye(e.shopItems,a=>(g(),S("div",{key:a.text,class:"pt-2"},[f("a",{class:Oe(["h-color-mako h-font-weight-400 block",a.text==="shop.sale"?"sale__label h-color-alizarin-crimson":""]),href:e.setDynamicLink()+a.url},N(e.t(a.text)),11,W7)]))),128))]),f("div",Q7,[f("div",Z7,[f("span",q7,N(e.t("frame-size.title")),1)]),(g(!0),S(J,null,ye(e.frameItems,a=>(g(),S("div",{key:a.text,class:"pt-2 h-color-mako h-font-weight-400"},[f("a",{class:Oe(["h-color-mako h-font-weight-400 block",a.text==="frame-size.find-size"?"gradient-text":""]),href:e.setDynamicLink()+a.url},N(e.t(a.text)),11,J7),a.label===e.genericSiteMetadata.user.last_purchase?(g(),S("div",X7,[f("span",eF,N(e.t("frame-size.last-purchased")),1
2443)])):M("",!0)]))),128))]),f("div",tF,[f("div",nF,[f("span",sF,N(e.t("faq.title")),1)]),(g(!0),S(J,null,ye(e.faqItems,a=>(g(),S("div",{key:a.text,class:"pt-2 h-color-mako h-font-weight-400"},[f("a",{class:Oe(["h-color-mako h-font-weight-400 block",a.text==="featured.sale"?"sale__label h-color-alizarin-crimson":""]),href:e.setDynamicLink()+a.url},N(e.t(a.text)),11,iF)]))),128))]),f("div",rF,[(g(!0),S(J,null,ye(e.images,a=>(g(),S("a",{key:a.alt,class:"flex flex-column",href:e.setDynamicLink()+a.url,style:{"max-width":"168px"}},[f("img",{class:"img-responsive image-opacity cursor-pointer",src:e.imagePath+(e.path.href.toLowerCase().includes("fr_ca")?a.srcFR:a.src),alt:a.alt,style:{"max-height":"232px","object-fit":"cover"}},null,8,oF),f("span",lF,N(a.alt),1)],8,aF))),128))])])}typeof _u=="function"&&_u(gg);const dF=Ke(gg,[["render",cF]]);function wu(e){const t=e;t.__i18n=t.__i18n||[],t.__i18n.push({locale:"",resource:{en:{shop:{title:{t:0,b:{t:2,i:[{t:3}],s:"Shop"}},all:{t:0,b:{t:2,i:[{t:3}],s:"All sunglasses"}},women:{t:0,b:{t:2,i:[{t:3}],s:"Women"}},men:{t:0,b:{t:2,i:[{t:3}],s:"Men"}},kids:{t:0,b:{t:2,i:[{t:3}],s:"Kids"}}},featured:{title:{t:0,b:{t:2,i:[{t:3}],s:"Featured"}},"best-sellers":{t:0,b:{t:2,i:[{t:3}],s:"Best sellers"}},polarized:{t:0,b:{t:2,i:[{t:3}],s:"Polarized"}},sunglasses:{t:0,b:{t:2,i:[{t:3}],s:"KITS sunglasses"}},designer:{t:0,b:{t:2,i:[{t:3}],s:"Designer sunglasses"}}}}}})}const yg=Ge({components:{},setup(){const{t:e}=rt({useScope:"local"}),{imagePath:t}=Be().public,n=ie();ht(se());let i=It();const r=ee(()=>n.systemStore.getGenericSiteMetadata),s=ee(()=>[{text:"shop.all",url:"/sunglasses"},{text:"shop.women",url:"/glasses?filters=%26filter=gender_uFilter:+Unisex+OR+gender_uFilter:+Women&product_type=Sunglasses"},{text:"shop.men",url:"/glasses?filters=%26filter=gender_uFilter:+Unisex+OR+gender_uFilter:+Men&product_type=Sunglasses"},{text:"shop.kids",url:"/glasses?filters=%26filter=gender_uFilter:+Kids&product_type=Sunglasses"}]);return{t:e,imagePath:t,genericSiteMetadata:r,shopItems:s,featuredItems:[{text:"featured.best-sellers",url:"/glasses?filters=%26filter=collections_name_uFilter:+Popular&product_type=Sunglasses"},{text:"featured.polarized",url:"/includes-polarized-lenses"},{text:"featured.sunglasses",url:"/glasses?filters=%26filter=brand_name_uFilter:+KITS&product_type=Sunglasses"},{text:"featured.designer",url:"/glasses?filters=%26filter=collections_name_uFilter:+Designer&product_type=Sunglasses"}],images:[{src:"images/header/panel/Aug06-2026-Navbar-Sunglasses-1.jpg",srcFR:"images/header/panel/Aug06-2026-Navbar-Sunglasses-1.jpg",heading:"Up to 50% off Kids frames",subheading:"Shop kids sunglasses",url:"/glasses?filters=%26filter=gender_uFilter:+Kids&product_type=Sunglasses"},{src:"images/header/panel/Apr13-2026-Navbar-Sunglasses-2.jpg",srcFR:"images/header/panel/Apr13-2026-Navbar-Sunglasses-2.jpg",heading:"Vacation-ready",subheading:"Shop sun styles",url:"/glasses?filters=%26filter=collections_name_uFilter:+The+Slim+Edit&product_type=Sunglasses"}],setDynamicLink:Ae,path:i}}}),uF={class:"navigation-expand h-full flex justify-content-between gap-4",style:{"max-width":"1440px",margin:"0 auto"}},hF={class:"flex gap-8"},pF={style:{width:"200px"}},fF={class:"py-2 h-color-pale-sky h-font-size-16 h-font-weight-600"},mF=["href"],gF={style:{width:"200px"}},yF={class:"py-2 h-color-pale-sky h-font-size-16 h-font-weight-600"},bF=["href"],vF={class:"flex gap-5"},_F=["href"],wF=["src","alt"],EF={class:"h-color-mirage-dark h-font-size-18 h-font-weight-600"},SF={class:"w-fit h-color-mako-dark h-font-size-14 h-font-weight-500 flex align-items-center gap-1 subheading"},CF=["src"];function IF(e,t,n,i,r,s){return g(),S("div",uF,[f("div",hF,[f("div",pF,[f("div",fF,N(e.t("shop.title")),1),(g(!0),S(J,null,ye(e.shopItems,a=>(g(),S("div",{key:a.text,class:"pt-2 h-color-mirage-dark h-font-size-18 h-font-weight-500"},[f("a",{href:e.setDynamicLink()+a.url,class:"block item-title"},N(e.t(a.text)),9,mF)]))),128))]),f("div",gF,[f("div",yF,N(e.t("featured.title")),1),(g(!0),S(J,null,ye(e.featuredItems,(a,o)=>(g(),S("div",{key:a.text,class:"pt-2 h-color-mirage-dark h-font-size-18 h-font-weight-500"},[f("a",{class:"block item-title",href:e.setDynamicLink()+a.url},N(e.t(a.text)),9,bF)]))),128))])]),f("div",vF,[(g(!0),S(J,null,ye(e.images,(a,o)=>(g(),S("a",{key:o,class:"promo-wrapper",href:e.setDynamicLink()+a.url},[f("img",{src:e.imagePath+(e.path.href.toLowerCase().includes("fr_ca")?a.srcFR:a.src),alt:a.heading,style:{"max-height":"70%",width:"100%"}}
2443,null,8,wF),f("div",EF,N(a.heading),1),f("div",SF,[ke(N(a.subheading)+" ",1),f("img",{src:e.imagePath+"images/header/arrow-right-smaller-414651.svg",height:"20",width:"20",alt:"Small Right Arrow"},null,8,CF)])],8,_F))),128))])])}typeof wu=="function"&&wu(yg);const TF=Ke(yg,[["render",IF],["__scopeId","data-v-d53577dc"]]);function Eu(e){const t=e;t.__i18n=t.__i18n||[],t.__i18n.push({locale:"",resource:{en:{shop:{title:{t:0,b:{t:2,i:[{t:3}],s:"Shop"}}},"featured-brands":{title:{t:0,b:{t:2,i:[{t:3}],s:"Featured"}}}}}})}const PF={class:"flex justify-content-between gap-5 navigation-expand",style:{"max-width":"1440px",margin:"0 auto"}},OF={class:"flex gap-5"},AF={class:"white-space-nowrap",style:{width:"200px"}},kF={class:"py-2 h-color-pale-sky h-font-size-16 h-font-weight-600"},RF={class:"pt-2 h-color-mirage-dark h-font-size-18 h-font-weight-500"},LF=["href"],NF={class:"flex flex-column gap-3",style:{"max-width":"350px"}},DF={class:"py-2 h-color-pale-sky h-font-size-14 h-font-weight-600"},xF=["href"],MF={key:0,class:"h-bg-ribbon-blue h-color-white h-font-size-14 h-font-weight-500 border-round-lg py-1 px-2 absolute z-1",style:{to
2443p:"4px",left:"4px"}},FF={class:"flex flex-row"},VF={class:"col-6"},BF=["src","alt"],$F={class:"flex flex-column justify-content-center"},UF={class:"h-color-ebony-clay-dark h-font-size-16 h-font-weight-600"},HF={key:0,class:"flex flex-row gap-2 h-font-size-16 h-font-weight-400 h-color-mako-dark"},zF={class:"h-color-danger h-font-weight-500"},KF={class:"line-through"},GF={key:1,class:"h-font-size-16 h-font-weight-400 h-color-mako-dark"},jF={class:"flex gap-5"},YF=["href"],WF=["src","alt"],QF={class:"h-color-mirage-dark h-font-size-18 h-font-weight-600"},ZF={class:"w-fit h-color-mako-dark h-font-size-14 h-font-weight-500 flex align-items-center gap-1 subheading"},qF=["src"],bg={__name:"NormalSmartGlassesExpand",setup(e){vt(async()=>{await l()});const{t}=rt({useScope:"local"}),{imagePath:n}=Be().public,i=ht(se());let r=It();const s=ie(),a=[{text:"All AI Smart Glasses",url:"/ai-smart-glasses"},{text:"KITS",url:"/glasses?filters=%26filter=brand_name_uFilter:+KITS%26filter=collections_name_uFilter:+Smart+Glasses&product_type=Glasses,Sunglasses"},{text:"Ray-Ban Meta",url:"/glasses?filters=%26filter=brand_name_uFilter:+Ray-Ban%26filter=collections_name_uFilter:+Smart+Glasses&product_type=Glasses,Sunglasses"},{text:"Oakley Meta",url:"/glasses?filters=%26filter=brand_name_uFilter:+Oakley%26filter=collections_name_uFilter:+Smart+Glasses&product_type=Glasses,Sunglasses"},{text:"Nuance Audio",url:"/glasses?filters=%26filter=brand_name_uFilter:+NUANCE+AUDIO%26filter=collections_name_uFilter:+Smart+Glasses&product_type=Glasses,Sunglasses"},{text:"Lucyd Armor",url:"/glasses?filters=%26filter=brand_name_uFilter:+Lucyd%26filter=collections_name_uFilter:+Smart+Glasses&product_type=Glasses,Sunglasses"},{text:"Reebok",url:"/glasses?filters=%26filter=brand_name_uFilter:+Reebok%26filter=collections_name_uFilter:+Smart+Glasses&product_type=Glasses,Sunglasses"}],o=Re([{src:"",sku:"GL28472",name:"",alt:"",fullPrice:""},{src:"",sku:i.includes(".ca")?"GL25778":"GL25629",name:"",alt:"",fullPrice:"",discountedPrice:""}]),l=async()=>{const d=o.value.map(p=>({sku:p.sku,config:""})),u=await s.glassesStore.fetchGlassesBulk(d);u==null||u.forEach(p=>{var m,v;const h=o.value.find(_=>_.sku===p.product_sku);h&&(h.src=(v=(m=p==null?void 0:p.product_images)==null?void 0:m[0])==null?void 0:v.image,h.name=p.name,h.fullPrice=p.price,h.discountedPrice=p.discounted_price)})},c=[{src:"images/header/panel/Jul14-2026-Navbar-Smart-Glasses-1.jpg",srcFR:"images/header/panel/Jul14-2026-Navbar-Smart-Glasses-1.jpg",heading:"KITS Pangolin 3",subheading:"Discover now",url:"/glasses?filters=%26filter=brand_name_uFilter:+KITS%26filter=collections_name_uFilter:+Smart+Glasses&product_type=Glasses,Sunglasses"},{src:"images/header/panel/Jul14-2026-Navbar-Smart-Glasses-2.jpg",srcFR:"images/header/panel/Jul14-2026-Navbar-Smart-Glasses-2_fr.jpg",heading:"Designer frames. Smart technology.",subheading:"Shop the collection",url:"/ai-smart-glasses"}];return(d,u)=>(g(),S("div",PF,[f("div",OF,[f("div",AF,[f("div",kF,N(k(t)("shop.title")),1),(g(),S(J,null,ye(a,p=>f("div",RF,[p.text==="Nuance Audio"&&k(i).includes(".ca")?(g(),S(J,{key:0},[],64)):(g(),S("a",{key:1,href:k(Ae)()+p.url,class:"block item-title"},N(p.text),9,LF))])),64))]),f("div",NF,[f("div",DF,N(k(t)("featured-brands.title")),1),(g(!0),S(J,null,ye(k(o),(p,h)=>(g(),S("a",{class:Oe(["h-bg-white-smoke border-round-lg py-2 px-3",{relative:h===0}]),href:`/glasses/${p.sku}/${k($n)(p.name)}`},[h===0?(g(),S("span",MF,"New")):M("",!0),f("div",FF,[f("div",VF,[f("img",{src:p.src,alt:p.alt,style:{"mix-blend-mode":"multiply"},class:"img-responsive"},null,8,BF)]),f("div",$F,[f("div",UF,N(p.name),1),p.discountedPrice?(g(),S("div",HF,[f("span",zF,"$"+N(p.discountedPrice),1),f("span",KF,"$"+N(p.fullPrice),1)])):(g(),S("div",GF," $"+N(p.fullPrice),1))])])],10,xF))),256))])]),f("div",jF,[(g(),S(J,null,ye(c,(p,h)=>f("a",{key:h,class:"promo-wrapper",href:k(Ae)()+p.url},[f("img",{src:k(n)+(k(r).href.toLowerCase().includes("fr_ca")?p.srcFR:p.src),alt:p.heading,style:{"max-height":"70%",width:"100%"}},null,8,WF),f("div",QF,N(p.heading),1),f("div",ZF,[ke(N(p.subheading)+" ",1),f("img",{src:k(n)+"images/header/arrow-right-smaller-414651.svg",height:"20",width:"20",alt:"Small Right Arrow"},null,8,qF)])],8,YF)),64))])]))}};typeof Eu=="function"&&Eu(bg);const JF=Ke(bg,[["__scopeId","data-v-a791b1ee"]]);function Su(e){const t=e;t.__i18n=t.__i18n||[],t.__i18n.push({locale:"",resource:{en:{shop:{title:{t:0,b:{t:2,i:[{t:3}],s:"Shop"}}},"featured-brands":{title:{t:0,b:{t:2,i:[{t:3}],s:"Top brands"}}}}}})}const vg=Ge({components:{},setup(){const{t:e}=rt({useScope:"local"}),{imagePath:t}=Be().public,n=ht(se());let i=It();
2443return{t:e,imagePath:t,baseDomain:n,shopDesigners:[{title:"Brand A-Z",url:"/brands",sale:!1},{title:"Designer eyeglasses",url:"/glasses?filters=%26filter=collections_name_uFilter:+Designer&product_type=Glasses",sale:!1},{title:"Designer sunglasses",url:"/glasses?filters=%26filter=collections_name_uFilter:+Designer&product_type=Sunglasses",sale:!1},{title:"Designer kids",url:"/glasses?filters=%26filter=gender_uFilter:+Kids%26filter=collections_name_uFilter:+Designer+Kids&product_type=Glasses,Sunglasses",sale:!1},{title:"Smart glasses",url:"/ai-smart-glasses",sale:!1},{title:"Safety glasses",url:"/glasses?filters=%26filter=collections_name_uFilter:+Safety+Glasses&product_type=Glasses,Sunglasses",sale:!1},{title:"Designer sale up to 70% off",url:"/glasses?product_type=Glasses,Sunglasses&filters=%26filter=collections_name_uFilter:+Designer+Promo",sale:!0}],featuredBrands:[{img:"images/header/panel/brands/logo-kits-grey.svg",alt:"Kits",url:"/glasses?filters=%26filter=brand_name_uFilter:+KITS&product_type=Glasses,Sunglasses"},{img:"images/header/panel/brands/logo-ray-ban-grey.svg",alt:"Ray Ban",url:"/brand-ray-ban"},{img:"images/header/panel/brands/logo-oakley-grey.svg",alt:"Oakley",url:"/brand-oakley"},{img:"images/header/panel/brands/logo-tom-ford-grey.svg",alt:"Tom Ford",url:"/brand-tom-ford"},{img:"images/header/panel/brands/logo-marc-jacobs-grey.svg",alt:"Marc Jacobs",url:"/brand-marc-jacobs"},{img:"images/header/panel/brands/logo-gucci-grey.svg",alt:"Gucci",url:"/brand-gucci"},{img:"images/header/panel/brands/logo-michael-kors-grey.svg",alt:"Michael Kors",url:"/glasses?filters=%26filter=brand_name_uFilter:+Michael+Kors&product_type=Glasses,Sunglasses"},{img:"images/header/panel/brands/logo-carrera-grey.svg",alt:"Carrera",url:"/brand-carrera"},{img:"images/header/panel/brands/logo-kate-spade-grey.svg",alt:"Kate Spade",url:"/brand-kate-spade"}],images:[{src:"images/header/panel/Aug06-2026-Navbar-Designer-1.jpg",srcFR:"images/header/panel/Aug06-2026-Navbar-Designer-1.jpg",heading:"NEW designer kids collection",subheading:"Shop up to 50% off",url:"/glasses?filters=%26filter=collections_name_uFilter:+Designer+Kids&product_type=Glasses,Sunglasses"},{src:"images/header/panel/Sep08-2026-Navbar-Designer-2.jpg",srcFR:"images/header/panel/Sep08-2026-Navbar-Designer-2_fr.jpg",heading:"Shop NEW Ray-Ban Meta",subheading:"With 30% off lenses",url:"/glasses?filters=%26filter=brand_name_uFilter:+Ray-Ban%26filter=collections_name_uFilter:+Smart+Glasses&product_type=Glasses&product_type=Sunglasses"}],setDynamicLink:Ae,path:i}}}),XF={class:"flex justify-content-center gap-5 navigation-expand",style:{"max-width":"1440px",margin:"0 auto"}},eV={class:"flex gap-5"},tV={style:{width:"200px"}},nV={class:"py-2 h-color-pale-sky h-font-size-16 h-font-weight-600"},sV={class:"pt-2 h-color-mirage-dark h-font-size-18 h-font-weight-500"},iV=["href"],rV={style:{"max-width":"425px"}},aV={class:"py-2 h-color-pale-sky h-font-size-16 h-font-weight-600"},oV={class:"brands-grid"},lV=["href"],cV=["src","alt"],dV={class:"flex gap-5"},uV=["href"],hV=["src","alt"],pV={class:"h-color-mirage-dark h-font-size-18 h-font-weight-600"},fV={class:"w-fit h-color-mako-dark h-font-size-14 h-font-weight-500 flex align-items-center gap-1 subheading"},mV=["src"];function gV(e,t,n,i,r,s){return g(),S("div",XF,[f("div",eV,[f("div",tV,[f("div",nV,N(e.t("shop.title")),1),(g(!0),S(J,null,ye(e.shopDesigners,a=>(g(),S("div",sV,[f("a",{href:e.setDynamicLink()+a.url,class:Oe(["block item-title",{"h-color-alizarin-crimson item-title-alizarin-crimson":a.sale}])},N(a.title),11,iV)]))),256))]),f("div",rV,[f("div",aV,N(e.t("featured-brands.title")),1),f("div",oV,[(g(!0),S(J,null,ye(e.featuredBrands,a=>(g(),S("a",{key:a.text,href:e.setDynamicLink()+a.url,class:"brand-wrapper cursor-pointer"},[f("img",{src:e.imagePath+a.img,alt:a.alt},null,8,cV)],8,lV))),128))])])]),f("div",dV,[(g(!0),S(J,null,ye(e.images,(a,o)=>(g(),S("a",{key:o,class:"promo-wrapper",href:e.setDynamicLink()+a.url},[f("img",{src:e.imagePath+(e.path.href.toLowerCase().includes("fr_ca")?a.srcFR:a.src),alt:a.heading,style:{"max-height":"70%",width:"100%"}}
2443,null,8,hV),f("div",pV,N(a.heading),1),f("div",fV,[ke(N(a.subheading)+" ",1),f("img",{src:e.imagePath+"images/header/arrow-right-smaller-414651.svg",height:"20",width:"20",alt:"Small Right Arrow"},null,8,mV)])],8,uV))),128))])])}typeof Su=="function"&&Su(vg);const yV=Ke(vg,[["render",gV],["__scopeId","data-v-31009c12"]]);function Cu(e){const t=e;t.__i18n=t.__i18n||[],t.__i18n.push({locale:"",resource:{en:{"normal-readers":{title:{t:0,b:{t:2,i:[{t:3}],s:"Close-up vision"}},readers:{t:0,b:{t:2,i:[{t:3}],s:"Readers"}},"sun-readers":{t:0,b:{t:2,i:[{t:3}],s:"Sun readers"}},shop:{t:0,b:{t:2,i:[{t:3}],s:"Shop"}}},"progressive-readers":{title:{t:0,b:{t:2,i:[{t:3}],s:"Near + far vision"}},progressive:{t:0,b:{t:2,i:[{t:3}],s:"Progressive readers"}},"pill-progressives":{t:0,b:{t:2,i:[{t:3}],s:"New"}},"sun-progressive":{t:0,b:{t:2,i:[{t:3}],s:"Sun progressive readers"}}},"progressive-readers-cta":{title:{t:0,b:{t:2,i:[{t:3}],s:"See near and far with one pair"}},description:{t:0,b:{t:2,i:[{t:3}],s:"Progressive readers seamlessly transition from no magnification at the top to your reading strength at the bottom, so you can move naturally throughout your day without ever taking your glasses off. One pair, no visible lines, no prescription needed."}},shop:{t:0,b:{t:2,i:[{t:3}],s:"Shop Progressive Readers"}}}}}})}const _g=Ge({components:{},setup(){const{t:e}=rt({useScope:"local"}),{imagePath:t}=Be().public,n=ht(se());let i=It();const r=[{title:e("normal-readers.readers"),url:"/glasses/readers?product_type=Glasses"}],s=[{title:e("progressive-readers.progressive"),url:"/glasses/progressive-readers?product_type=Glasses",pill:e("progressive-readers.pill-progressives")}];return{t:e,imagePath:t,baseDomain:n,normalReaders:r,progressiveReaders:s,images:[{src:"images/header/panel/kits-progressive-readers.png",srcFR:"images/header/panel/kits-progressive-readers.png",alt:"",url:"/glasses/progressive-readers?product_type=Glasses&filters="}],setDynamicLink:Ae,path:i}}}),bV={class:"flex justify-content-between gap-5 navigation-expand",style:{"max-width":"1300px",margin:"0 auto"}},vV={class:"flex gap-8"},_V={class:"white-space-nowrap"},wV={class:"h-color-pale-sky my-2 h-font-weight-600 h-font-size-16"},EV={class:"pt-2 h-color-mako h-font-weight-400"},SV=["href"],CV={class:"pt-2 h-color-mako h-font-weight-400"},IV=["href"],TV={class:"pill"},PV={class:"navigation-expand flex align-items-center gap-6"},OV={class:"flex gap-3 pt-3"},AV=["href"],kV=["src","alt"],RV={class:"flex flex-column",style:{"max-width":"300px"}},LV={class:"h-color-mirage-dark h-font-weight-600 h-font-size-20 my-2 h-font-weight-600"},NV={class:"h-font-size-16 line-height-3 h-color-mako-dark"},DV=["href"],xV={class:"h-font-size-14 h-font-weight-400 h-color-mako-dark"},MV=["src"];function FV(e,t,n,i,r,s){return g(),S("div",bV,[f("div",vV,[f("div",_V,[f("p",wV,N(e.t("normal-readers.shop")),1),(g(!0),S(J,null,ye(e.normalReaders,a=>(g(),S("div",EV,[f("a",{href:e.setDynamicLink()+a.url,class:"h-color-mirage-dark h-font-weight-500 h-font-size-18"},N(a.title),9,SV)]))),256)),(g(!0),S(J,null,ye(e.progressiveReaders,a=>(g(),S("div",CV,[f("a",{href:e.setDynamicLink()+a.url,class:"h-color-mirage-dark h-font-weight-500 h-font-size-18 flex"},[ke(N(a.title)+" ",1),f("span",TV,N(a.pill),1)],8,IV)]))),256))])]),f("div",PV,[f("div",OV,[(g(!0),S(J,null,ye(e.images,a=>(g(),S("a",{key:a.alt,class:"flex flex-column",href:e.setDynamicLink()+a.url},[f("img",{class:"img-responsive image-opacity cursor-pointer",src:e.imagePath+(e.path.href.toLowerCase().includes("fr_ca")?a.srcFR:a.src),alt:a.alt,style:{"object-fit":"cover"}},null,8,kV)],8,AV))),128))]),f("div",RV,[f("p",LV,N(e.t("progressive-readers-cta.title")),1),f("span",NV,N(e.t("progressive-readers-cta.description")),1),f("a",{href:e.setDynamicLink()+e.images[0].url,class:"flex flex-row align-items-center mt-3"},[f("span",xV,N(e.t("progressive-readers-cta.shop")),1),f("img",{src:e.imagePath+"images/header/arrow-right.svg",class:"ml-2"},null,8,MV)],8,DV)])])])}typeof Cu=="function"&&Cu(_g);const VV=Ke(_g,[["render",FV],["__scopeId","data-v-38826148"]]),BV=Ge({components:{},setup(){const{t:e}=rt({useScope:"local"}),{imagePath:t}=Be().public,n=ie();let i=It();const r=ee(()=>n.systemStore.getGenericSiteMetadata);return{t:e,imagePath:t,genericSiteMetadata:r,images:[{src:"images/header/panel/Jul27-2026-Navbar-Sale-1.jpg",srcFR:"images/header/panel/Jul27-2026-Navbar-Sale-1_fr.jpg",heading:"Up to 65% off selected KITS Frames",subheading:"Shop KITS sale",url:"/collection-kits-glasses-sale"},{src:"images/header/panel/Jan19-2026-Navbar-Sale-2.jpg",srcFR:"images/header/panel/Jan19-2026-Navbar-Sale-2.jpg",heading:"Designer sale up to 70% off",subheading:"Shop Designer sale",url:"/glasses?product_type=Glasses,Sunglasses&filters=%26filter=collections_name_uFilter:+Designer+Promo",url:"/glasses?product_type=Glasses,Sunglasses&filters=%26filter=collections_name_uFilter:+Designer+Promo"}
2443],setDynamicLink:Ae,path:i}}}),$V={class:"navigation-expand h-full flex justify-content-center gap-4",style:{"max-width":"1440px",margin:"0 auto"}},UV={class:"flex gap-6"},HV=["href"],zV=["src","alt"],KV={class:"h-color-alizarin-crimson h-font-size-18 h-font-weight-600"},GV={class:"w-fit h-color-mako-dark h-font-size-14 h-font-weight-500 flex align-items-center gap-1 subheading"},jV=["src"];function YV(e,t,n,i,r,s){return g(),S("div",$V,[f("div",UV,[(g(!0),S(J,null,ye(e.images,(a,o)=>(g(),S("a",{key:o,class:"promo-wrapper",href:e.setDynamicLink()+a.url},[f("img",{src:e.imagePath+(e.path.href.toLowerCase().includes("fr_ca")?a.srcFR:a.src),alt:a.heading,style:{"max-height":"70%",width:"100%"}},null,8,zV),f("div",KV,N(a.heading),1),f("div",GV,[ke(N(a.subheading)+" ",1),f("img",{src:e.imagePath+"images/header/arrow-right-smaller-414651.svg",height:"20",width:"20",alt:"Small Right Arrow"},null,8,jV)])],8,HV))),128))])])}const WV=Ke(BV,[["render",YV],["__scopeId","data-v-a2ea92fd"]]),QV=Ge({components:{NormalContactsExpand:w7,NormalEyeglassesExpand:z7,NormalProgressivesExpand:dF,NormalSunglassesExpand:TF,NormalSmartGlassesExpand:JF,NormalDesignerExpand:yV,NormalReadersExpand:VV,NormalSaleExpand:WV},setup(){const e=ie();return{headerNavType:ee(()=>e.systemStore.getHeaderNavType),handleHeaderNavType:i=>{e.systemStore.setHeaderNavType(i)}}}});function ZV(e,t,n,i,r,s){const a=le("NormalEyeglassesExpand"),o=le("NormalSunglassesExpand"),l=le("NormalSmartGlassesExpand"),c=le("NormalDesignerExpand"),d=le("NormalReadersExpand"),u=le("NormalContactsExpand"),p=le("NormalSaleExpand");return g(),S(J,null,[Ne(f("div",{class:"dropdown",onMouseenter:t[0]||(t[0]=h=>e.handleHeaderNavType("eyeglasses"))},[de(a)],544),[[mt,e.headerNavType==="eyeglasses"]]),Ne(f("div",{class:"dropdown",onMouseenter:t[1]||(t[1]=h=>e.handleHeaderNavType("sunglasses"))},[de(o)],544),[[mt,e.headerNavType==="sunglasses"]]),Ne(f("div",{class:"dropdown",onMouseenter:t[2]||(t[2]=h=>e.handleHeaderNavType("smart-glasses"))},[de(l)],544),[[mt,e.headerNavType==="smart-glasses"]]),Ne(f("div",{class:"dropdown",onMouseenter:t[3]||(t[3]=h=>e.handleHeaderNavType("designer"))},[de(c)],544),[[mt,e.headerNavType==="designer"]]),Ne(f("div",{class:"h-full w-full pt-4 pb-8 px-3 xl:px-6",onMouseenter:t[4]||(t[4]=h=>e.handleHeaderNavType("readers"))},[de(d)],544),[[mt,e.headerNavType==="readers"]]),Ne(f("div",{class:"dropdown",onMouseenter:t[5]||(t[5]=h=>e.handleHeaderNavType("contacts"))},[de(u)],544),[[mt,e.headerNavType==="contacts"]]),Ne(f("div",{class:"dropdown",onMouseenter:t[6]||(t[6]=h=>e.handleHeaderNavType("sale"))},[de(p)],544),[[mt,e.headerNavType==="sale"]])],64)}const qV=Ke(QV,[["render",ZV],["__scopeId","data-v-0beb8fdb"]]),JV=["src"],XV={__name:"ProductGift",props:{variant:{type:String,default:"default"}},setup(e){const t=ie(),{imagePath:n}=Be().public;ee(()=>t.contactsStore.getContactsData);const i=ee(()=>!1);return(r,s)=>k(i)?(g(),S("div",{key:0,class:Oe(["product-gift h-bg-foam h-border-radius-8 flex flex-row align-items-center",e.variant==="header"?"md:py-1 py-3":"md:py-0 py-1 gap-1 px-3"])},[f("img",{src:`${k(n)}images/pdp/contacts/travel_mirror.png`,alt:"mirror",class:Oe(["product-gift__img",{"product-gift__img--header":e.variant==="header"}])},null,10,JV),f("p",{class:Oe(["m-0",e.variant==="header"?"md:h-font-size-18 h-font-size-14 h-font-weight-500 h-color-mirage-dark":"h-font-size-14 h-font-weight-600 h-color-mirage-dark"])}," Free travel mirror with your first order ",2)],2)):M("",!0)}},eB=Ke(XV,[["__scopeId","data-v-7da5781b"]]);function Iu(e){const t=e;t.__i18n=t.__i18n||[],t.__i18n.push({locale:"",resource:{en:{"carousel-header":{help:{t:0,b:{t:2,i:[{t:3}],s:"Help"}},"kits-plus":{t:0,b:{t:2,i:[{t:3}],s:"Join KITS+"}}},"autoship-modal":{"content-1":{t:0,b:{t:2,i:[{t:3}],s:"Despite potential Canada Post service disruptions, we want to assure our valued customers that KITS shipping remains minimally affected. Our team has proactively secured alternative shipping solutions to ensure quick delivery of your orders."}},"content-2":{t:0,b:{t:2,i:[{t:3}],s:"However, we can no longer deliver to PO Box addresses due to the ongoing situation."}},"content-3":{t:0,b:{t:2,i:[{t:3}],s:"If you have any questions or concerns, please don't hesitate to contact our customer care team at"}},"last-updated":{t:0,b:{t:2,i:[{t:3}],s:"Last updated: November 26, 2024"}},or:{t:0,b:{t:2,i:[{t:3}],s:"or"}}}}}})}const yt=e=>(us("data-v-b96dd689"),e=e(),hs(),e),tB={key:0,class:"flex align-items-center justify-content-center w-full py-3 overflow-hidden"},nB=["href"],sB=["innerHTML"],iB={key:0,class:"stripe__cta"},rB=["onClick"],aB=["href"],oB={key:1,class:"stripe__wrapper"},lB=["innerHTML"],cB=["href"],dB={key:1,class:"stripe__cta"},uB=["onClick"],hB=["href"],pB={key:1,class:"flex align-items-center justify-content-center w-full overflow-hidden"}
2443,fB={key:2,class:"hidden lg:flex align-items-center justify-content-end hidden pb-2 pt-1 lg:py-0",style:{"min-width":"245px"}},mB={key:0,class:"flex align-items-center"},gB=["href"],yB=yt(()=>f("span",{class:"h-font-weight-600 mx-3"},"|",-1)),bB={key:1,class:"flex"},vB=yt(()=>f("span",{class:"h-font-weight-600 mx-3"},"|",-1)),_B=yt(()=>f("span",{class:"pi pi-times"},null,-1)),wB=[_B],EB=yt(()=>f("div",{class:"h-color-mirage-dark h-font-size-24 h-font-weight-600 mb-3"}," Bonus sunglasses included ",-1)),SB={class:"py-4"},CB={class:"flex flex-wrap"},IB={class:"px-3"},TB=["src"],PB=yt(()=>f("div",{class:"h-color-trout h-font-size-16 h-font-weight-400"},[f("div",null,"We're adding a complimentary pair of sunglasses to your order."),f("div",null," To redeem, simply use code BOGO at checkout, your free sunglasses will be automatically added to your order. ")],-1)),OB=yt(()=>f("div",{class:"pb-0 pt-5 flex justify-content-center gap-2"},[f("a",{href:"/glasses",class:"modal__cta"},"Shop glasses"),f("a",{href:"/sunglasses",class:"modal__cta"},"Shop sunglasses")],-1)),AB=yt(()=>f("span",{class:"pi pi-times"},null,-1)),kB=[AB],RB={class:"p-5"},LB=yt(()=>f("div",{class:"h-font-size-32 h-font-weight-700 text-center mb-3"}," $10K Canadian Getaway Giveaway ",-1)),NB={class:"h-font-size-14 h-font-weight-400"},DB=yt(()=>f("div",{class:"h-font-size-14 h-font-weight-400 my-1"}," To show Canadians there's so much more to see, we're giving away a $10,000 getaway anywhere in Canada. One lucky winner will plan their dream vacation with flights, 5-star stays, unforgettable experiences, and a KITS shopping spree. ",-1)),xB={class:"h-font-size-14 h-font-weight-400 my-1"},MB=yt(()=>f("div",{class:"h-font-size-14 h-font-weight-400 my-1"}," Giveaway ends October 31, 2025 at 11:59 PM PT. Open to Canadian residents 18+. Prize details and inclusions are set by KITS and may be changed, substituted, or cancelled at any time. No cash value. No purchase necessary. Free entr
2443ies available on Instagram. ",-1)),FB=yt(()=>f("span",{class:"pi pi-times"},null,-1)),VB=[FB],BB={class:"p-5 text-center"},$B=yt(()=>f("div",{class:"h-font-size-16 h-font-weight-700 h-color-tundora mb-3"},[f("div",null,"10% OFF* YOUR FIRST CONTACTS ORDER!"),f("div",null,"Use code: SAVE10")],-1)),UB=yt(()=>f("div",{class:"h-font-size-14 h-font-weight-400 h-color-dusty-gray"}," Discount applied on the current website price at the time of order. Offer only valid for new customer first contacts order over $10. Maximum discount of $100. Cannot be combined with any other offers. Promotions are subject to change without notice. We reserve the right to cancel orders that are in breach of the terms and conditions of this offer ",-1)),HB={class:"flex flex-row justify-content-center mt-5"},zB=yt(()=>f("span",{class:"pi pi-times"},null,-1)),KB=[zB],GB={class:"p-5"},jB={class:"grid"},YB={class:"col-12 mb-3"},WB={class:"text-center align-items-center"},QB=yt(()=>f("div",{class:"relative line-height-3 h-font-size-36 h-font-weight-700 uppercase h-color-cornflower-blue"}," Subscribe and save* with ",-1)),ZB=["src"],qB={class:"col-6 md:col-3"},JB={class:"flex flex-column align-items-center justify-content-center"},XB=["src"],e$=yt(()=>f("div",{class:"h-font-size-16 h-font-weight-700 text-center mt-2"},"Save 15%",-1)),t$=yt(()=>f("div",{class:"h-font-size-14 text-gray-400 text-center mt-1"}," Increased savings on future orders ",-1)),n$={class:"col-6 md:col-3"},s$={class:"flex flex-column align-items-center justify-content-center"},i$=["src"],r$=yt(()=>f("div",{class:"h-font-size-16 h-font-weight-700 text-center mt-2"}," Price-Match Guarantee ",-1)),a$=yt(()=>f("div",{class:"h-font-size-14 text-gray-400 text-center mt-1"},"On every order",-1)),o$={class:"col-6 md:col-3"},l$={class:"flex flex-column align-items-center justify-content-center"},c$=["src"],d$=yt(()=>f("div",{class:"h-font-size-16 h-font-weight-700 text-center mt-2"},"Free Shipping",-1)),u$=yt(()=>f("div",{class:"h-font-size-14 text-gray-400 text-center mt-1"},"on all future orders*",-1)),h$={class:"col-6 md:col-3"},p$={class:"flex flex-column align-items-center justify-content-center"},f$=["src"],m$=yt(()=>f("div",{class:"h-font-size-16 h-font-weight-700 text-center mt-2"},"Loyalty Rewards",-1)),g$=yt(()=>f("div",{class:"h-font-size-14 text-gray-400 text-center mt-1"}," Top tier savings & perks with each reorder ",-1)),y$={class:"col-12"},b$={class:"flex flex-column sm:flex-row align-items-center justify-content-center"},v$=["href"],_$={class:"col-12 text-center mb-2"},w$=["href"],E$={key:0,class:"col-12"},S$=yt(()=>f("div",{class:"flex flex-column h-font-size-14 h-font-weight-300"},[f("div",{class:"mb-3 line-height-3"}," Unfortunately, we can't offer direct billing on Autoship orders just yet, but we're actively working on it! In the meantime, here's what you can do: "),f("li",{class:"mb-2 line-height-3"},[f("span",{class:"h-font-weight-700"},"To keep Autoship:"),ke(" Place your order as usual and submit a claim to your insurance provider afterward ")]),f("li",{class:"line-height-3"},[f("span",{class:"h-font-weight-700"},"For direct billing now:"),ke(" Unselect the Autoship option at checkout and we'll process your insurance claim directly. ")])],-1)),C$=[S$],wg={__name:"NormalCarouselHeader",setup(e){vt(async()=>{await n.systemStore.fetchOffersSiteStripe(),yl()}),cn(()=>{p&&p.stop()});const{t}=rt({useScope:"local"}),n=ie(),i=se(),r=ht(se()),{imagePath:s}=Be().public,a=async _=>{await kt(),_.update(),_.slideTo(0,0)};ee(()=>n.contactsStore.getContactsData);const o=ee(()=>!1),l=ee(()=>n.systemStore.getHeaderNavMenuType);ee(()=>n.systemStore.getGenericSiteMetadata);const c=ee(()=>n.systemStore.getOffersSiteStripe.filter(_=>Number(_.enabled)&&(_.offer_type==="contacts"&&_.environment===gl()||_.offer_type==="glasses"&&_.environment===RC()))),d={slidesPerView:1,slidesPerGroup:1,loop:!0,autoplay:{delay:8e3,disableOnInteraction:!1}},u=Re({canadian_getaway:!1,autoship_modal:!1,postal_save10:!1,free_sunglasses_disclaimer:!1});Re(""),Re({days:"00",hours:"00",minutes:"00",seconds:"00"}),Re(!1);let p=null;const h=()=>window.location.pathname.toLowerCase().includes("fr_ca"),m=_=>{const b=window.location.pathname;if(_==="en"&&h()){const w=b.replace("/fr_CA","");window.location.href=`${window.location.origin}${w}${window.location.search}${window.location.hash}`}if(_==="fr"&&!h()){const w=`/fr_CA${b}`;window.location.href=`${window.location.origin}${w}${window.location.search}${window.location.hash}`}},v=_=>{_===l.value?n.systemStore.setHeaderNavMenuType(""):n.systemStore.setHeaderNavMenuType(_)};return(_,b)=>{const w=ju,C=Yu,O=le("Dialog"),T=le("Button");return g(),S(J,null,[f("div",{class:Oe(["flex m-0 px-3 h-color-white",[k(r)==="opticontacts.com"?"h-bg-matisse":"h-bg-primary",{"site-stripe--gift":k(o)}]]),style:cs({backgroundColor:k(o)?"#DCFAE6":k(r)==="contactsexpress.ca"?"#181D27":k(r)==="kits.ca"||k(r)==="kits.com"?"#0E0F11":""})},[k(c)&&!k(o)?(g(),S("div",tB,[de(C,R(d,{class:"w-full",modules:_.modules,onSwiper:a}),{default:Ee(()=>[(g(!0),S(J,null,ye(k(c),E=>(g(),Q(w,{key:E.sort_order,class:"stripe__slide"},{default:Ee(()=>[E.content_href?(g(),S("a",{key:0,href:`/${E.content_href}`,class:"stripe__wrapper"},[f("span",{class:"stripe__content",innerHTML:E.content},null,8,sB),E.shop_cta?(g(),S("span",iB,N(E.shop_cta),1)):M("",!0),E.terms_cta&&E.terms_target?(g(),S("span",{key:1,onClick:st(y=>k(u)[E.terms_target]=!0,["prevent"]),class:"stripe__terms"},N(E.terms_cta),9,rB)):E.terms_cta&&E.terms_href?(g(),S("a",{key:2,href:`/${E.terms_href}`,class:"stripe__terms"},N(E.terms_cta),9,aB)):M("",!0)],8,nB)):(g(),S("div",oB,[f("span",{class:"stripe__content",innerHTML:E.content},null,8,lB),E.shop_cta&&E.shop_href?(g(),S("a",{key:0,class:"stripe__cta",href:`/${E.shop_href}`},N(E.shop_cta),9,cB)):E.shop_cta?(g(),S("span",dB,N(E.shop_cta),1)):M("",!0),E.terms_cta&&E.terms_target?(g(),S("span",{key:2,onClick:st(y=>k(u)[E.terms_target]=!0,["prevent"]),class:"stripe__terms"},N(E.terms_cta),9,uB)):E.terms_cta&&E.terms_href?(g(),S("a",{key:3,href:`/${E.terms_href}`,class:"stripe__terms"},N(E.terms_cta),9,hB)):M("",!0)]))]),_:2},1024))),128))]),_:1},16,["modules"])])):M("",!0),k(o)?(g(),S("div",pB,[de(eB,{variant:"header"})])):M("",!0),k(o)?M("",!0):(g(),S("div",fB,[k(r)==="kits.ca"||k(r)==="kits.com"?(g(),S("span",mB,[f("a",{href:k(Ae)()+"/kits-plus",class:"h-color-white h-font-size-14 no-underline hover:underline"},N(k(t)("carousel-header.kits-plus")),9,gB),yB])):M("",!0),f("span",{onClick:b[0]||(b[0]=E=>v("help")),class:"header-menu-links-new flex align-items-center h-color-white hover:underline cursor-pointer h-font-size-14"},N(k(t)("carousel-header.help")),1),k(r)==="kits.ca"?(g(),S("span",bB,[vB,f("span",{class:Oe(["cursor-pointer mx-1 h-color-gray-cloud h-font-size-14",{"h-color-white":!h()}]),onClick:b[1]||(b[1]=E=>m("en"))},"EN ",2),f("span",{class:Oe(["cursor-pointer mr-2 mx-1 h-color-gray-cloud h-font-size-14",{"h-color-white":h()}]),onClick:b[2]||(b[2]=E=>m("fr"))}," FR ",2)])):M("",!0)]))],6),de(O,{visible:k(u).free_sunglasses_disclaimer,"onUpdate:visible":b[4]||(b[4]=E=>k(u).free_sunglasses_disclaimer=E),modal:"",closable:!1,dismissableMask:!0,style:{maxWidth:"400px"}},{default:Ee(()=>[f("div",{onClick:b[3]||(b[3]=E=>k(u).free_sunglasses_disclaimer=!1),class:"cursor-pointer absolute right-0 top-0 mt-3 mr-3"},wB),EB,f("div",SB,[f("div",CB,[f("div",IB,[f("img",{src:`https://${k(i)}
2443/cart/images/shared/nav/May11-2026-Free-Sunglasses-Stripe.jpg`,alt:"KITS Pace Image",class:"img-responsive"},null,8,TB)])])]),PB,OB]),_:1},8,["visible"]),de(O,{visible:k(u).canadian_getaway,"onUpdate:visible":b[6]||(b[6]=E=>k(u).canadian_getaway=E),modal:"",closable:!1,dismissableMask:!0,style:{maxWidth:"800px"}},{default:Ee(()=>[f("div",{onClick:b[5]||(b[5]=E=>k(u).canadian_getaway=!1),class:"cursor-pointer absolute right-0 top-0 mt-3 mr-3"},kB),f("div",RB,[LB,f("div",NB,[DB,f("div",xB," Every purchase made on "+N(k(LC)(k(r)))+" by October 31 will automatically receive 100 entries. For more ways to win, be sure to check us out on Instagram @kitseyecare. ",1),MB])])]),_:1},8,["visible"]),de(O,{visible:k(u).postal_save10,"onUpdate:visible":b[9]||(b[9]=E=>k(u).postal_save10=E),modal:"",closable:!1,dismissableMask:!0,style:{maxWidth:"800px"}},{default:Ee(()=>[f("div",{onClick:b[7]||(b[7]=E=>k(u).postal_save10=!1),class:"cursor-pointer absolute right-0 top-0 mt-3 mr-3"},VB),f("div",BB,[$B,UB,f("div",HB,[f("div",{onClick:b[8]||(b[8]=E=>k(u).postal_save10=!1),class:"h-font-size-14 h-font-weight-700 h-color-white h-bg-tundora px-4 py-2 cursor-pointer"}," CLOSE ")])])]),_:1},8,["visible"]),de(O,{visible:k(u).autoship_modal,"onUpdate:visible":b[12]||(b[12]=E=>k(u).autoship_modal=E),modal:"",closable:!1,dismissableMask:!0,style:{maxWidth:"800px"}},{default:Ee(()=>[f("div",{onClick:b[10]||(b[10]=E=>k(u).autoship_modal=!1),class:"cursor-pointer absolute right-0 top-0 mt-3 mr-3"},KB),f("div",GB,[f("div",jB,[f("div",YB,[f("div",WB,[QB,f("img",{src:`${k(s)}images/header/autoship_blue.webp`,class:"w-full",style:{"max-width":"270px"}},null,8,ZB)])]),f("div",qB,[f("div",JB,[f("img",{alt:"Subscribe Icon",src:`${k(s)}images/header/Piggy_Bank.svg`},null,8,XB),e$,t$])]),f("div",n$,[f("div",s$,[f("img",{alt:"Subscribe Icon",src:`${k(s)}images/header/Price_Match.svg`},null,8,i$),r$,a$])]),f("div",o$,[f("div",l$,[f("img",{alt:"Subscribe Icon",src:`${k(s)}images/header/Shipping.svg`},null,8,c$),d$,u$])]),f("div",h$,[f("div",p$,[f("img",{alt:"Subscribe Icon",src:`${k(s)}images/header/loyalty_rewards.svg`},null,8,f$),m$,g$])]),f("div",y$,[f("div",b$,[f("a",{href:k(Ae)()+"/autoship"},[de(T,{class:"button__legacy-autoship-learn m-1 w-10rem",label:"LEARN MORE"})],8,v$),de(T,{class:"button__legacy-autoship-close m-1 w-10rem",label:"CLOSE",onClick:b[11]||(b[11]=E=>k(u).autoship_modal=!1)})])]),f("div",_$,[f("a",{href:k(Ae)()+"/autoship",class:"text-blue-400 hover:text-blue-800 h-font-weight-300"},"*See autoship page for details, restrictions may apply!",8,w$)]),k(r)==="contactsexpress.ca"?(g(),S("div",E$,C$)):M("",!0)])])]),_:1},8,["visible"])],64)}}};typeof Iu=="function"&&Iu(wg);const I$=Ke(wg,[["__scopeId","data-v-b96dd689"]]);function T$(e=768){const t=Re(!1);let n=null;const i=()=>{t.value=n.matches};return vt(()=>{var r;n=window.matchMedia(`(max-width: ${e-1}
2443px)`),i(),(r=n.addEventListener)==null||r.call(n,"change",i)}),cn(()=>{var r;(r=n==null?void 0:n.removeEventListener)==null||r.call(n,"change",i)}),Gu(t)}const P$=Ge({props:{titleName:{type:String,required:!0},customClass:{type:String,required:!1}},setup(){vt(()=>{o(),window.addEventListener("message",a)}),cn(()=>{window.removeEventListener("message",a)});const{imagePath:e}=Be().public,t=ie(),n=ee(()=>t.glassesStore.getSelectedRxOptions),i=ee(()=>t.glassesStore.getFrameDetails),r=ee(()=>t.glassesStore.getLensFlowSelectedOptions),s=T$(),a=d=>{d.data.type==="startMeasurePd"&&c()},o=()=>{let d=document.createElement("script");d.setAttribute("defer",""),d.setAttribute("id","veero-location"),d.setAttribute("src","https://app.veero.ai/js/veero.main.js?b=NKzVP6wZO"),document.head.appendChild(d)},l={eyeSizeCallback:d=>{try{dataLayer.push({event:"find_my_size_received_measurements"})}catch{console.log("Datalayer not found: find_my_size_received_measurements",{event:"find_my_size_received_measurements"})}t.glassesStore.setMeasuredPdResults(d);const u=Math.round((d.mono_pd*1e3).toFixed(2)).toFixed(1);t.glassesStore.saveRxOptions(u,"SINGLE_PD"),t.glassesStore.setDoublePdActive(!1),saveGlassesRxOptionsToCookies(i.value,r.value,n.value,"singlePD"),EyeSize.closeModal()},eyeSizeExitCallback:()=>{},vendorID:"NKzVP6wZO",initialMeasurementIdx:!1,customLoadingImageURL:`${e}images/loading-rotating-blue.svg`,ctaIndex:0},c=()=>{try{dataLayer.push({event:"find_my_size_pdp"})}catch{console.log("Datalayer not found: find_my_size_pdp",{event:"find_my_size_pdp"})}EyeSize.launch(l)};return{openMeasureMyPDScript:c,isMobile:s}}}),O$={class:"product-gallery"};function A$(e,t,n,i,r,s){return g(),S("div",O$,[f("span",{class:Oe(["m-0 p-0 underline h-font-weight-400 h-color-ebony-clay cursor-pointer",e.customClass]),onClick:t[0]||(t[0]=a=>e.openMeasureMyPDScript())},N(e.titleName),3)])}const Eg=Ke(P$,[["render",A$]]);function Tu(e){const t=e;t.__i18n=t.__i18n||[],t.__i18n.push({locale:"",resource:{en:{"gallery-find-my-size":{"pupillary-distance":{title:{t:0,b:{t:2,i:[{t:3}],s:"Pupillary Distance"}},"what-is-pd":{t:0,b:{t:2,i:[{t:3}],s:"WHAT IS PUPILLARY DISTANCE?"}},"two-distance-numbers":{t:0,b:{t:2,i:[{t:3}],s:"TWO PUPILLARY DISTANCE NUMBERS"}},"what-is-pd-description":{t:0,b:{t:2,i:[{t:3}],s:"Pupillary Distance (PD) is the distance between your left and right pupil, expressed in mm. This value normally ranges from 54mm to 68mm for most adults and between 42mm and 54mm for children. If your prescription has a different PD measurement for each eye, click 'I have more than one PD' to enter in both values"}},"two-distance-numbers-description":{t:0,b:{t:2,i:[{t:3}],s:"If your Pupillary Distance consists of two numbers, it is measured as the distance between the centers of each pupil to the bridge of the nose. Dual Pupillary distances are usually written in this format: #/#. The first number is the right eye, and second number refers to the left eye. Both numbers should be less than 40. If your prescription has a different PD measurement for each eye, click 'I have more than one PD' to enter in both values."}},"click-here":{t:0,b:{t:2,i:[{t:3}],s:"Click here to measure your PD using our tool."}}},"glasses-prescription":{"how-to-read":{t:0,b:{t:2,i:[{t:3}],s:"How to read your glasses prescription"}},"how-to-enter":{t:0,b:{t:2,i:[{t:3}],s:"How to enter your glasses prescription"}}},"contacts-prescription":{"how-to-read":{t:0,b:{t:2,i:[{t:3}],s:"How to read your contacts prescription"}},"how-to-enter":{t:0,b:{t:2,i:[{t:3}],s:"How to enter your contacts prescription"}}},od:{t:0,b:{t:2,i:[{t:3}],s:"OD is an abbreviation for the Latin term oculus dexter which means right eye. Notice that the right eye information is asked for first even though we typically read from left to right."}},os:{t:0,b:{t:2,i:[{t:3}],s:"OS is an abbreviation of the Latin oculus sinister which means left eye. That will be referenced on the far right column of the prescription."}},bc:{t:0,b:{t:2,i:[{t:3}],s:"B.C. is short for base curve measurement indicates the back curvature of your contact lens, in millimetres. This is important for comfort, as the BC of your contact lenses should match your eye's natural curve as closely as possible to ensure a better fit when you are wearing your contact lenses."}},dia:{t:0,b:{t:2,i:[{t:3}],s:"DIA is short for 'diameter', or the distance from one edge of the contact lens to the other. This is measured in millimeters."}},sph:{t:0,b:{t:2,i:[{t:3}],s:"SPH is short for sphere. The sphere of your prescription indicates the power on the lenses that is needed to see clearly. A plus (+) symbol indicates the eyeglass wearer is farsighted. A minus (-) symbol indicates that the eyeglass wearer is nearsighted."}},cyl:{t:0,b:{t:2,i:[{t:3}],s:"CYL is short for cylinder. The cylinder indicates the lens power necessary to correct astigmatism. If the column has no value (is blank), it indicates that the eyeglass wearer does not have astigmatism. If this is the case on your prescription, you can leave it blank when entering it in."}},axis:{t:0,b:{t:2,i:[{t:3}],s:"AXIS is a prescription will include an axis value for those with astigmatism. This 
2443number represents the angle of the lens that shouldn't feature a cylinder power to help correct your astigmatism."}},add:{t:0,b:{t:2,i:[{t:3}],s:"ADD is short for 'additional correction'. This is where details about bifocals, multifocal lenses or progressive lenses would appear."}}}}}})}const Sg=Ge({components:{MeasureMyPD:Eg},props:{titleName:{type:String,required:!1},galleryList:{type:Array,required:!0},color:{type:String,required:!1},underline:{required:!1}},setup(e){const{t}=rt({useScope:"local"}),{imagePath:n}=Be().public,i=Re(!1),r=Re(0),s=4;function a(){r.value=(r.value+1)%s}function o(){r.value=(r.value-1+s)%s}function l(d){i.value&&(d.key==="ArrowRight"?a():d.key==="ArrowLeft"?o():d.key==="Escape"&&(i.value=!1))}function c(){i.value=!0}return vt(()=>{window.addEventListener("keydown",l)}),cn(()=>{window.removeEventListener("keydown",l)}),{imagePath:n,isGalleryVisible:i,openGallery:c,currentSlideIndex:r,t}}}),k$={key:0},R$=["src"],L$={key:1},N$={class:"h-bg-white p-2 md:p-6"},D$={class:"h-font-size-26 mb-0 h-color-elephant"},x$={class:"text-center"},M$=["src"],F$={class:"m-0 text-left"},V$={href:"/pd-tool",class:"underline h-color-klein-blue"},B$={class:"text-center"},$$=["src"],U$={class:"m-0 text-left"},H$={href:"/pd-tool",class:"underline h-color-klein-blue"},z$={key:2,style:{height:"100vh"},class:"h-bg-white p-2 md:p-6 overflow-scroll"},K$={class:"h-font-size-16 lg:h-font-size-28 h-font-weight-200 h-color-black"},G$=["src"],j$={class:"h-font-size-16 lg:h-font-size-28 h-font-weight-200 h-color-black"},Y$=["src"],W$={class:"h-font-size-16 h-color-dusty-gray"},Q$={class:"mt-2 h-color-dusty-gray"},Z$={class:"mt-2 h-color-dusty-gray"},q$={class:"mt-2 h-color-dusty-gray"},J$={class:"mt-2 h-color-dusty-gray"},X$={class:"mt-2 h-color-dusty-gray"},eU={class:"mt-2 h-color-dusty-gray"},tU={key:3,style:{height:"100vh"},class:"h-bg-white p-2 md:p-6 overflow-scroll"},nU={class:"h-font-size-24 lg:h-font-size-28 h-font-weight-200 h-color-black"},sU=["src"],iU={class:"h-font-size-24 lg:h-font-size-28 h-font-weight-200 h-color-black"},rU=["src"],aU={class:"h-font-size-16"},oU={class:"mt-2 h-color-dusty-gray"},lU={class:"mt-2 h-color-dusty-gray"},cU={class:"mt-2 h-color-dusty-gray"},dU={class:"mt-2 h-color-dusty-gray"},uU={class:"mt-2 h-color-dusty-gray"},hU={class:"mt-2 h-color-dusty-gray"},pU={class:"mt-2 h-color-dusty-gray"},fU={class:"mt-2 h-color-dusty-gray"},mU=["innerHTML"];function gU(e,t,n,i,r,s){const a=le("MeasureMyPD"),o=le("TabPanel"),l=le("TabView"),c=le("Galleria");return g(),S("div",null,[de(c,{visible:e.isGalleryVisible,"onUpdate:visible":t[0]||(t[0]=d=>e.isGalleryVisible=d),value:e.galleryList,numVisible:e.galleryList.length,containerStyle:"max-width: 50%",circular:!0,fullScreen:!0,showItemNavigators:e.galleryList.length>1,showThumbnails:!1,activeIndex:e.currentSlideIndex,"onUpdate:activeIndex":t[1]||(t[1]=d=>e.currentSlideIndex=d),containerClass:"prescription__gallery",maskClass:"prescription__gallery"},{item:Ee(d=>[d.item.section_name==="FrameMeasurment"&&d.item.active?(g(),S("div",k$,[f("img",{class:"img-responsive max-h-screen",src:`${e.imagePath}images/pdp/glasses/find_my_size_measurements.png`,alt:"side glasses 1",style:{width:"100%","min-width":"320px"}},null,8,R$)])):M("",!0),d.item.section_name==="PDMeasurment"&&d.item.active?(g(),S("div",L$,[f("div",N$,[f("p",D$,N(e.t("gallery-find-my-size.pupillary-distance.title")),1),de(a,{titleName:"Measure my PD"}),de(l,{class:"mt-5"},{default:Ee(()=>[de(o,{header:e.t("gallery-find-my-size.pupillary-distance.what-is-pd")},{default:Ee(()=>[f("div",x$,[f("img",{class:"img-responsive mb-2",src:`${e.imagePath}images/pdp/glasses/pd_01.webp`,alt:""},null,8,M$),f("p",F$,[ke(N(e.t("gallery-find-my-size.pupillary-distance.what-is-pd-description"))+" ",1),f("a",V$,N(e.t("gallery-find-my-size.pupillary-distance.click-here")),1)])])]),_:1},8,["header"]),de(o,{header:e.t("gallery-find-my-size.pupillary-distance.two-distance-numbers")},{default:Ee(()=>[f("div",B$,[f("img",{class:"img-responsive mb-2",src:`${e.imagePath}images/pdp/glasses/pd.webp`,alt:""},null,8,$$),f("p",U$,[ke(N(e.t("gallery-find-my-size.pupillary-distance.two-distance-numbers-description"))+" ",1),f("a",H$,N(e.t("gallery-find-my-size.pupillary-distance.click-here")),1)])])]),_:1},8,["header"])]),_:1})])])):M("",!0),d.item.section_name==="GlassesPrescription"&&d.item.active?(g(),S("div",z$,[f("p",K$,N(e.t("gallery-find-my-size.glasses-prescription.how-to-read")),1),f("img",{class:"img-responsive",src:`${e.imagePath}images/pdp/glasses/glasses_RX-01.webp`,alt:""},null,8,G$),f("div",j$,N(e.t("gallery-find-my-size.glasses-prescription.how-to-enter")),1),f("img",{class:"img-responsive",src:`${e.imagePath}images/pdp/glasses/glasses_RX-02.webp`,alt:""},null,8,Y$),f("div",W$,[f("p",Q$,N(e.t("gallery-find-my-size.od")),1),f("p",Z$,N(e.t("gallery-find-my-size.os")),1
2443),f("p",q$,N(e.t("gallery-find-my-size.sph")),1),f("p",J$,N(e.t("gallery-find-my-size.cyl")),1),f("p",X$,N(e.t("gallery-find-my-size.axis")),1),f("p",eU,N(e.t("gallery-find-my-size.add")),1)])])):M("",!0),d.item.section_name==="ContactsPrescription"&&d.item.active?(g(),S("div",tU,[f("div",nU,N(e.t("gallery-find-my-size.contacts-prescription.how-to-read")),1),f("img",{class:"img-responsive",src:`${e.imagePath}images/pdp/glasses/contacts_RX-01.png`,alt:""},null,8,sU),f("div",iU,N(e.t("gallery-find-my-size.contacts-prescription.how-to-enter")),1),f("img",{class:"img-responsive",src:`${e.imagePath}images/pdp/glasses/contacts_RX-02.webp`,alt:""},null,8,rU),f("div",aU,[f("p",oU,N(e.t("gallery-find-my-size.od")),1),f("p",lU,N(e.t("gallery-find-my-size.os")),1),f("p",cU,N(e.t("gallery-find-my-size.bc")),1),f("p",dU,N(e.t("gallery-find-my-size.dia")),1),f("p",uU,N(e.t("gallery-find-my-size.sph")),1),f("p",hU,N(e.t("gallery-find-my-size.cyl")),1),f("p",pU,N(e.t("gallery-find-my-size.axis")),1),f("p",fU,N(e.t("gallery-find-my-size.add")),1)])])):M("",!0)]),_:1},8,["visible","value","numVisible","showItemNavigators","activeIndex"]),e.titleName?(g(),S("span",{key:0,class:Oe(["m-0 p-0 cursor-pointer",e.underline===!0?"underline":""]),onClick:t[2]||(t[2]=d=>e.openGallery())},[f("span",{class:"h-font-weight-300 h-font-size-16",innerHTML:e.titleName},null,8,mU)],2)):M("",!0),f("span",{onClick:t[3]||(t[3]=d=>e.isGalleryVisible=!0)},[he(e.$slots,"default")])])}typeof Tu=="function"&&Tu(Sg);const yU=Ke(Sg,[["render",gU]]);function Pu(e){const t=e;t.__i18n=t.__i18n||[],t.__i18n.push({locale:"",resource:{en:{"order-info":{"order-status":{t:0,b:{t:2,i:[{t:3}],s:"Check order status"}},"place-reorder":{t:0,b:{t:2,i:[{t:3}],s:"Place reorder"}}},help:{label:{t:0,b:{t:2,i:[{t:3}],s:"Get help"}},"resource-hub":{t:0,b:{t:2,i:[{t:3}],s:"Resource hub"}},"sign-out":{t:0,b:{t:2,i:[{t:3}],s:"Sign out"}},"measure-pd":{t:0,b:{t:2,i:[{t:3}],s:"How to Measure Your PD at home"}},"how-to-prescription-glasses":{t:0,b:{t:2,i:[{t:3}],s:"Glasses - How to read your prescription"}},"how-to-prescription-contacts":{t:0,b:{t:2,i:[{t:3}],s:"Contacts - How to read your prescription"}},"shipping-returns":{t:0,b:{t:2,i:[{t:3}],s:"Shipping & Returns"}},"contact-us":{t:0,b:{t:2,i:[{t:3}],s:"Contact us"}},"get-in-touch":{t:0,b:{t:2,i:[{t:3}],s:"Get In Touch"}},welcome:{t:0,b:{t:2,i:[{t:3}],s:"Welcome"}},greeting:{t:0,b:{t:2,i:[{t:3,v:"Nice to see you, "},{t:4,k:"fname"},{t:3,v:" "},{t:4,k:"lname"}]}}},contact:{"live-chat":{t:0,b:{t:2,i:[{t:3}],s:"Chat with us"}},"phone-hours":{t:0,b:{t:2,i:[{t:3}],s:"(Monday to Friday: 10am-6pm EST)"}},"leave-message":{t:0,b:{t:2,i:[{t:3}],s:"Leave a video or voice message"}},"fastest-connect":{t:0,b:{t:2,i:[{t:3}],s:"The fastest way to connect with our team"}}}}}})}const Cg=Ge({components:{GalleryFindMySize:yU,MeasureMyPD:Eg},setup(){vt(()=>{});const{t:e}=rt({useScope:"local"}),t=ie(),{imagePath:n}=Be().public,i=ee(()=>t.systemStore.getHeaderNavMenuType),r=ee(()=>t.systemStore.getHamburgerMenuType),s=ee(()=>t.systemStore.getGenericSiteMetadata),a=p=>{t.systemStore.setHeaderNavMenuType(p),t.systemStore.setHamburgerMenuType("")},o=ee(()=>OC()),l=()=>{t.systemStore.setHamburgerMenuType("")},c=[{key:"orderStatus",label:e("order-info.order-status"),icon:"images/header/package-search.svg",url:"/query/check_orders?pagename=check_status",alt:"order Icon"},{key:"placeReorder",label:e("order-info.place-reorder"),icon:"images/header/clock-rewind.svg",url:"/saved_carts_changes?pagename=saved_carts",alt:"reorder Icon"}],d=[{key:"liveChat",label:e("contact.live-chat"),icon:"images/header/panel/kits_chat-new.svg",url:"/contactus",alt:"Chat Icon"},{key:"phoneSupport",label:s.value.phone_support,description:e("contact.phone-hours"),icon:"images/header/panel/phone.svg",url:"/contactus",alt:"Phone Icon"},{key:"emailSupport",icon:"images/header/panel/kits_email-new.svg",label:s.value.email_support,url:"/contactus",alt:"Email Icon"},{key:"leaveMessage",icon:"images/header/panel/Group.svg",label:e("contact.leave-message"),description:e("contact.fastest-connect"),url:"/contactus",alt:"Email Icon"}],u=[{key:"measurePD",label:e("help.measure-pd"),url:"/pd-tool"},{key:"howToPrescriptionGlasses",label:e("help.how-to-prescription-glasses"),url:"intern"},{key:"howToPrescriptionContacts",label:e("help.how-to-prescription-contacts"),url:"intern"},{key:"shippingReturns",label:e("help.shipping-returns"),url:"/shipping"},{key:"contactUs",label:e("help.contact-us"),url:"/contactus"}];return{t:e,imagePath:n,headerNavMenuType:i,hamburgerMenuType:r,orderItems:c,setDynamicLink:Ae,triggerChat:AC,genericSiteMetadata:s,contactOptions:d,helpMenuItems:u,handleHeaderNavMenuType:a,backToMainHamburgerMenu:l,isLiveChatAvailable:o}}}),bU={class:"help-expand"},vU={key:0,class:"help-hamburger-header"},_U={class:"md:hidden border-bottom-1 h-border-color-iron"},wU={class:"help-header flex justify-content-between align-items-center p-4"},EU=["src"],SU={class:"flex align-items-center gap-2 h-color-primary m-0 h-font-size-18 h-font-weight-500"},CU=f("i",{class:"pi pi-times"},null,-1),IU=[CU],TU={style:{}},PU={class:"flex flex-column p-4 gap-3 border-bottom-1 h-border-color-iron"},OU=["href"],AU=["src","alt"],kU={class:"navigation-expand resource-hub px-5 mt-4"},RU={key:0},LU=["href"],NU={key:0,class:"px-5 py-2 mt-5 border-round-bottom h-bg-alice-white"},DU={class:"h-font-weight-500 h-font-size-16 h-color-primary"},xU={class:"flex flex-column align-items-start justify-content-center cursor-pointer"},MU=["src","alt"],FU=["href"],VU={class:"flex align-items-center gap-1 h-color-primary"},BU=["src","alt"],$U={class:"flex flex-column h-color-primary"},UU={class:"h-font-size-14 h-color-shuttle-gray h-font-weight-400 align-self-end"},HU=["href"],zU={class:"flex align-items-center gap-1 h-color-primary"},KU=["src","alt"],GU=["href"],jU={class:"flex align-items-center flex-row gap-1 h-color-primary pb-5"},YU=["src","alt"],WU={class:"flex flex-column pt-3"},QU={class:"h-font-size-14 h-color-shuttle-gray h-font-weight-400"};function ZU(e,t,n,i,r,s){const a=le("Button"),o=le("GalleryFindMySize"),l=le("MeasureMyPD");return g(),S("div",bU,[e.hamburgerMenuType==="help"?(g(),S("div",vU,[f("div",_U,[f("div",wU,[f("div",{onClick:t[0]||(t[0]=(...c)=>e.backToMainHamburgerMenu&&e.backToMainHamburgerMenu(...c)),class:"flex align-items-center gap-2 cursor-pointer"},[f("img",{src:e.imagePath+"images/header/arrow-left.svg",alt:"Left pointing arrow"},null,8,EU),f("div",SU,N(e.t("help.label")),1)]),f("div",{onClick:t[1]||(t[1]=c=>e.handleHeaderNavMenuType("")),class:"cursor-pointer"},IU)])])])):M("",!0),f("div",TU,[f("div",PU,[(g(!0),S(J,null,ye(e.orderItems,c=>(g(),S("a",{key:c.key,href:e.setDynamicLink()+c.url},[de(a,{label:"Sign in",class:"button__secondary-kits-v2-nav w-full"},{default:Ee(()=>[f("img",{class:"mr-1",width:"20px",height:"20px",src:`${e.imagePath}${c.icon}`,alt:c.alt},null,8,AU),ke(" "+N(c.label),1)]),_:2},1024)],8,OU))),128))]),f("div",kU,[(g(!0),S(J,null,ye(e.helpMenuItems,c=>(g(),S("div",{key:c.key,class:"cursor-pointer py-2"},[c.url==="intern"?(g(),S("div",RU,[c.key==="howToPrescriptionGlasses"?(g(),Q(o,{key:0,underline:!1,titleName:`
2444              <div class='h-font-size-14 h-color-mako-dark h-font-weight-500'>${c.label}</div>
2445              `,galleryList:[{section_name:"GlassesPrescription",active:!0}]},null,8,["titleName"])):M("",!0),c.key==="howToPrescriptionContacts"?(g(),Q(o,{key:1,underline:!1,titleName:`<div class='h-font-size-14 h-color-mako-dark h-font-weight-500'>${c.label}</div>`,galleryList:[{section_name:"ContactsPrescription",active:!0}]},null,8,["titleName"])):M("",!0)])):c.key==="measurePD"?(g(),Q(l,{key:1,titleName:c.label,customClass:"h-font-size-14 h-color-mako-dark h-font-weight-500 no-underline block w-full"},null,8,["titleName"])):(g(),S("a",{key:2,href:e.setDynamicLink()+c.url,class:"h-font-size-14 h-color-mako-dark h-font-weight-500 block w-full"},N(c.label),9,LU))]))),128))]),e.hamburgerMenuType!=="help"?(g(),S("div",NU,[f("h2",DU,N(e.t("help.get-in-touch")),1),f("div",xU,[e.isLiveChatAvailable?(g(),S("button",{key:0,onClick:t[2]||(t[2]=(...c)=>e.triggerChat&&e.triggerChat(...c)),class:"flex align-items-center gap-1 py-2 h-color-primary"},[f("img",{class:"mr-1 h-color-primary",width:"24px",height:"24px",src:`${e.imagePath}${e.contactOptions[0].icon}`,alt:e.contactOptions[0].alt},null,8,MU),ke(" "+N(e.contactOptions[0].label),1)])):M("",!0),f("a",{href:e.setDynamicLink()+e.contactOptions[1].url,class:"py-2 block w-full"},[f("div",VU,[f("img",{class:"mr-1",width:"24px",height:"24px",src:`${e.imagePath}${e.contactOptions[1].icon}`,alt:e.contactOptions[1].alt},null,8,BU),f("div",$U,[ke(N(e.contactOptions[1].label)+" ",1),f("span",UU,N(e.contactOptions[1].description),1)])])],8,FU),f("a",{href:e.setDynamicLink()+e.contactOptions[2].url,class:"pt-2 block w-full"},[f("div",zU,[f("img",{class:"mr-1 h-color-primary",width:"24px",height:"24px",src:`${e.imagePath}${e.contactOptions[2].icon}`,alt:e.contactOptions[2].alt},null,8,KU),ke(" "+N(e.contactOptions[2].label),1)])],8,HU),f("a",{href:e.setDynamicLink()+e.contactOptions[3].url,class:"block w-full"},[f("div",jU,[f("img",{class:"mr-1 h-color-primary",width:"24px",height:"24px",src:`${e.imagePath}${e.contactOptions[3].icon}`,alt:e.contactOptions[3].alt},null,8,YU),f("div",WU,[ke(N(e.contactOptions[3].label)+" ",1),f("span",QU,N(e.contactOptions[3].description),1)])])],8,GU)])])):M("",!0)])])}typeof Pu=="function"&&Pu(Cg);const Ig=Ke(Cg,[["render",ZU]]),qU={},JU={class:"loading-animation-dark"},XU=f("div",null,null,-1),eH=f("div",null,null,-1),tH=f("div",null,null,-1),nH=f("div",null,null,-1),sH=[XU,eH,tH,nH];function iH(e,t){return g(),S("div",JU,sH)}const rH=Ke(qU,[["render",iH]]);function Ou(e){const t=e;t.__i18n=t.__i18n||[],t.__i18n.push({locale:"",resource:{en:{hamburger:{welcome:{t:0,b:{t:2,i:[{t:3}],s:"Welcome"}},greeting:{t:0,b:{t:2,i:[{t:3,v:"Nice to see you, "},{t:4,k:"fname"},{t:3,v:" "},{t:4,k:"lname"}]}},"shop-by-brands":{t:0,b:{t:2,i:[{t:3}],s:"Shop by brands"}},"featured-brands":{t:0,b:{t:2,i:[{t:3}],s:"Featured"}},"top-brands":{t:0,b:{t:2,i:[{t:3}],s:"Top brands"}},"all-brands":{t:0,b:{t:2,i:[{t:3}],s:"All brands"}},all:{t:0,b:{t:2,i:[{t:3}],s:"A-Z brand list"}},shop:{t:0,b:{t:2,i:[{t:3}],s:"Shop"}}},accordion:{eyeglasses:{t:0,b:{t:2,i:[{t:3}],s:"Eyeglasses"}},sunglasses:{t:0,b:{t:2,i:[{t:3}],s:"Sunglasses"}},"smart-glasses":{t:0,b:{t:2,i:[{t:3}],s:"AI Smart Glasses"}},designer:{t:0,b:{t:2,i:[{t:3}],s:"Brands"}},readers:{t:0,b:{t:2,i:[{t:3}],s:"Readers"}},contacts:{t:0,b:{t:2,i:[{t:3}],s:"Contacts"}},insurance:{t:0,b:{t:2,i:[{t:3}],s:"Insurance"}},sale:{t:0,b:{t:2,i:[{t:3}],s:"Sale"}}},"hamburger-footer":{"account-logged-in":{t:0,b:{t:2,i:[{t:3}],s:"My account"}},"account-logged-out":{t:0,b:{t:2,i:[{t:3}],s:"Sign in"}},favorites:{t:0,b:{t:2,i:[{t:3}],s:"Favorites"}},favourites:{t:0,b:{t:2,i:[{t:3}],s:"Favourites"}},"use-insurance":{t:0,b:{t:2,i:[{t:3}],s:"Use your insurance"}},help:{t:0,b:{t:2,i:[{t:3}],s:"Get help"}},en:{t:0,b:{t:2,i:[{t:3}],s:"EN"}},fr:{t:0,b:{t:2,i:[{t:3}],s:"FR"}}},eyeglasses:{shop:{title:{t:0,b:{t:2,i:[{t:3}],s:"Shop"}},all:{t:0,b:{t:2,i:[{t:3}],s:"All eyeglasses"}},women:{t:0,b:{t:2,i:[{t:3}],s:"Women"}},men:{t:0,b:{t:2,i:[{t:3}],s:"Men"}},kids:{t:0,b:{t:2,i:[{t:3}],s:"Kids"}},accessories:{t:0,b:{t:2,i:[{t:3}],s:"Accessories"}}},featured:{title:{t:0,b:{t:2,i:[{t:3}],s:"Featured"}},"fit-and-style":{t:0,b:{t:2,i:[{t:3}],s:"Fit & Style Quiz"}},"best-sellers":{t:0,b:{t:2,i:[{t:3}],s:"Best sellers"}},new:{t:0,b:{t:2,i:[{t:3}],s:"KITS new arrivals"}},eyeglasses:{t:0,b:{t:2,i:[{t:3}],s:"KITS eyeglasses"}},"progressive-eligible":{t:0,b:{t:2,i:[{t:3}],s:"Progressives"}},designer:{t:0,b:{t:2,i:[{t:3}],s:"Designer eyeglasses"}},"designer-sale":{t:0,b:{t:2,i:[{t:3}],s:"Designer sale"}},sale:{t:0,b:{t:2,i:[{t:3}],s:"Sale"}}},curated:{title:{t:0,b:{t:2,i:[{t:3}],s:"Curated"}},"campus-edit":{t:0,b:{t:2,i:[{t:3}],s:"The Campus Edit"}},"office-ready":{t:0,b:{t:2,i:[{t:3}],s:"Office Ready"}}}},sunglasses:{shop:{title:{t:0,b:{t:2,i:[{t:3}],s:"Shop"}},all:{t:0,b:{t:2,i:[{t:3}],s:"All sunglasses"}},women:{t:0,b:{t:2,i:[{t:3}],s:"Women"}},men:{t:0,b:{t:2,i:[{t:3}],s:"Men"}},kids:{t:0,b:{t:2,i:[{t:3}],s:"Kids"}}},featured:{title:{t:0,b:{t:2,i:[{t:3}],s:"Featured"}},"best-sellers":{t:0,b:{t:2,i:[{t:3}],s:"Best sellers"}},"polarized-lenses":{t:0,b:{t:2,i:[{t:3}],s:"Polarized"}},sunglasses:{t:0,b:{t:2,i:[{t:3}],s:"KITS sunglasses"}},designer:{t:0,b:{t:2,i:[{t:3}],s:"Designer sunglasses"}}}},"smart-glasses":[{text:{t:0,b:{t:2,i:[{t:3}],s:"All AI Smart Glasses"}},url:{t:0,b:{t:2,i:[{t:3}],s:"/ai-smart-glasses"}}},{text:{t:0,b:{t:2,i:[{t:3}],s:"KITS"}},url:{t:0,b:{t:2,i:[{t:3}],s:"/glasses?filters=%26filter=brand_name_uFilter:+KITS%26filter=collections_name_uFilter:+Smart+Glasses&product_type=Glasses,Sunglasses"}}},{text:{t:0,b:{t:2,i:[{t:3}],s:"Ray-Ban Meta"}},url:{t:0,b:{t:2,i:[{t:3}],s:"/glasses?filters=%26filter=brand_name_uFilter:+Ray-Ban%26filter=collections_name_uFilter:+Smart+Glasses&product_type=Glasses,Sunglasses"}}},{text:{t:0,b:{t:2,i:[{t:3}],s:"Oakley Meta"}},url:{t:0,b:{t:2,i:[{t:3}],s:"/glasses?filters=%26filter=brand_name_uFilter:+Oakley%26filter=collections_name_uFilter:+Smart+Glasses&product_type=Glasses,Sunglasses"}}},{text:{t:0,b:{t:2,i:[{t:3}],s:"Nuance Audio"}},url:{t:0,b:{t:2,i:[{t:3}],s:"/glasses?filters=%26filter=brand_name_uFilter:+NUANCE+AUDIO%26filter=collections_name_uFilter:+Smart+Glasses&product_type=Glasses,Sunglasses"}}},{text:{t:0,b:{t:2,i:[{t:3}],s:"Lucyd Armor"}}
2445,url:{t:0,b:{t:2,i:[{t:3}],s:"/glasses?filters=%26filter=brand_name_uFilter:+Lucyd%26filter=collections_name_uFilter:+Smart+Glasses&product_type=Glasses,Sunglasses"}}},{text:{t:0,b:{t:2,i:[{t:3}],s:"Reebok"}},url:{t:0,b:{t:2,i:[{t:3}],s:"/glasses?filters=%26filter=brand_name_uFilter:+Reebok%26filter=collections_name_uFilter:+Smart+Glasses&product_type=Glasses,Sunglasses"}}}],designer:[{text:{t:0,b:{t:2,i:[{t:3}],s:"Brand A-Z"}},url:{t:0,b:{t:2,i:[{t:3}],s:"/brands"}}},{text:{t:0,b:{t:2,i:[{t:3}],s:"Designer eyeglasses"}},url:{t:0,b:{t:2,i:[{t:3}],s:"/glasses?filters=%26filter=collections_name_uFilter:+Designer&product_type=Glasses"}}},{text:{t:0,b:{t:2,i:[{t:3}],s:"Designer sunglasses"}},url:{t:0,b:{t:2,i:[{t:3}],s:"/glasses?filters=%26filter=collections_name_uFilter:+Designer&product_type=Sunglasses"}}},{text:{t:0,b:{t:2,i:[{t:3}],s:"Designer kids"}},url:{t:0,b:{t:2,i:[{t:3}],s:"/glasses?filters=%26filter=gender_uFilter:+Kids%26filter=collections_name_uFilter:+Designer+Kids&product_type=Glasses,Sunglasses"}}},{text:{t:0,b:{t:2,i:[{t:3}],s:"Smart glasses"}},url:{t:0,b:{t:2,i:[{t:3}],s:"/ai-smart-glasses"}}},{text:{t:0,b:{t:2,i:[{t:3}],s:"Safety glasses"}},url:{t:0,b:{t:2,i:[{t:3}],s:"/glasses?filters=%26filter=collections_name_uFilter:+Safety+Glasses&product_type=Glasses,Sunglasses"}}},{text:{t:0,b:{t:2,i:[{t:3}],s:"Designer sale up to 70% off"}},url:{t:0,b:{t:2,i:[{t:3}],s:"/glasses?product_type=Glasses,Sunglasses&filters=%26filter=collections_name_uFilter:+Designer+Promo"}}}],readers:{"normal-readers":{title:{t:0,b:{t:2,i:[{t:3}],s:"Close-up vision"}},readers:{t:0,b:{t:2,i:[{t:3}],s:"Readers"}},"sun-readers":{t:0,b:{t:2,i:[{t:3}],s:"Sun readers"}},shop:{t:0,b:{t:2,i:[{t:3}],s:"Shop"}}},"progressive-readers":{title:{t:0,b:{t:2,i:[{t:3}],s:"Near + far vision"}},progressive:{t:0,b:{t:2,i:[{t:3}],s:"Progressive readers"}},"pill-progressives":{t:0,b:{t:2,i:[{t:3}],s:"New"}},"sun-progressive":{t:0,b:{t:2,i:[{t:3}],s:"Sun progressive readers"}}},"progressive-readers-cta":{title:{t:0,b:{t:2,i:[{t:3}],s:"See near and far with one pair"}},description:{t:0,b:{t:2,i:[{t:3}],s:"Progressive readers seamlessly transition from no magnification at the top to your reading strength at the bottom, so you can move naturally throughout your day without ever taking your glasses off. One pair, no visible lines, no prescription needed."}},shop:{t:0,b:{t:2,i:[{t:3}],s:"Shop Progressive Readers"}}}},progressives:{all:{t:0,b:{t:2,i:[{t:3}],s:"All progressives"}},sale:{t:0,b:{t:2,i:[{t:3}],s:"Designer sale from $50"}},"resource-hub":{title:{t:0,b:{t:2,i:[{t:3}],s:"Resource hub"}},"made-easy":{t:0,b:{t:2,i:[{t:3}],s:"Progressive made easy"}},"how-to-buy-glasses":{t:0,b:{t:2,i:[{t:3}],s:"How do I buy glasses online?"}}}},contacts:{"all-contacts":{t:0,b:{t:2,i:[{t:3}],s:"All contacts"}},daily:{t:0,b:{t:2,i:[{t:3}],s:"Daily"}},weekly:{t:0,b:{t:2,i:[{t:3}],s:"Weekly"}},monthly:{t:0,b:{t:2,i:[{t:3}],s:"Monthly"}},"single-vision":{t:0,b:{t:2,i:[{t:3}],s:"Toric"}},multifocal:{t:0,b:{t:2,i:[{t:3}],s:"Multifocal"}},color:{t:0,b:{t:2,i:[{t:3}],s:"Color"}},colour:{t:0,b:{t:2,i:[{t:3}],s:"Colour"}}}}}})}const $s=e=>(us("data-v-024db075"),e=e(),hs(),e),aH={id:"hamburger",class:"hamburger"},oH={class:"flex flex-row align-items-center justify-content-between w-full md:w-auto"},lH={key:0,class:"toggler-wrapper border-1 h-border-color-iron-dark h-bg-alabaster h-border-radius-8 p-1",id:"optician-ai-wrapper"},cH=["src"],dH=$s(()=>f("span",{class:"h-font-size-14 h-color-mirage-dark h-font-weight-500 ml-1"},"Search",-1)),uH=["src"],hH={key:1,class:"cursor-pointer p-1 md:hidden"},pH=["src"],fH={class:"flex mobile-search align-items-center gap-2 relative w-full"},mH={class:"relative w-full"},gH={class:"h-color-primary magnify-search-bar-icon h-font-size-18 h-font-weight-600 absolute",style:{top:"21px",left:"15px"}},yH=["src"],bH=["src"],vH=["src"],_H=["src"],wH={class:"hamburger-items"},EH=["onClick"],SH={class:"h-color-alizarin-crimson"},CH=$s(()=>f("i",{class:"pi pi-angle-right"},null,-1)),IH=["href"],TH=["onClick"],PH={key:0,class:"h-bg-ribbon-blue h-color-white h-font-size-14 h-font-weight-500 border-round-3xl py-1 px-2"},OH=$s(()=>f("i",{class:"pi pi-angle-right"},null,-1)),AH={class:"hamburger-footer border-top-1 h-border-color-soltitude-darker h-full py-3"},kH={class:"hamburger-footer-items"},RH=["onClick"],LH={class:"flex align-items-center gap-2"},NH=["href"],DH={class:"flex align-items-center gap-2"},xH={key:0,class:"flex justify-content-between domain-item py-2 px-4 cursor-pointer"},MH={class:"h-color-pale-sky h-font-weight-500 h-font-size-16 flex align-items-center gap-2"},FH=$s(()=>f("span",{class:"h-color-pale-sky h-font-weight-600 my-1"},"|",-1)),VH={key:0,class:"eyeglasses-hamburger"},BH={class:"eyeglasses-header cursor-pointer flex justify-content-between align-items-center p-4 border-bottom-1 h-border-color-iron"},$H=["src"],UH={class:"h-color-primary m-0 h-font-size-18 h-font-weight-500"},HH=["src"],zH={class:"hamburger-items__container eyeglasses-items pb-4"},KH={class:"pt-4 px-4"},GH={class:"h-color-pale-sky h-font-size-14 h-font-weight-600"},jH={class:"pt-2 flex flex-column"},YH=["href"],WH={class:"h-color-mirage-dark h-font-weight-500 h-font-size-20"},QH=["href"],ZH={class:"h-color-mirage-dark h-font-weight-500 h-font-size-20"},qH={class:"pt-3"},JH={class:"py-2 px-4"},XH={class:"h-color-pale-sky h-font-size-14 h-font-weight-600"},ez={class:"flex flex-column"},tz=["href","id"],nz={key:0,class:"pill pill--new"},sz={class:"pt-3"},iz={class:"py-2 px-4"},rz={class:"h-color-pale-sky h-font-size-14 h-font-weight-600"},az={class:"flex flex-column"},oz=["href"],lz={class:"h-color-mirage-dark h-font-weight-500 h-font-size-20"},cz={class:"flex flex-column px-4 pt-2 pb-4 gap-4"},dz=["href"],uz=["src","alt"],hz={class:"h-color-mirage-dark h-font-size-18 h-font-weight-600"},pz={class:"h-color-mako-dark h-font-size-14 h-font-weight-500 flex align-items-center gap-1"},fz=["src"],mz={key:1},gz={class:"eyeglasses-header cursor-pointer flex justify-content-between align-items-center p-4 border-bottom-1 h-border-color-iron"},yz=["src"],bz={class:"h-color-primary m-0 h-font-size-18 h-font-weight-500"},vz=["src"],_z={class:"hamburger-items__container eyeglasses-items pb-4"},wz={class:"pt-4 flex flex-column"},Ez={class:"py-2 px-4"},Sz={class:"h-color-pale-sky h-font-size-14 h-font-weight-600"},Cz=["href"],Iz={class:"h-color-mirage-dark h-font-weight-500 h-font-size-20"},Tz={class:"pt-3"},Pz={class:"py-2 px-4"},Oz={class:"h-color-pale-sky h-font-size-14 h-font-weight-600"},Az={class:"flex flex-column"},kz=["href"],Rz={class:"flex flex-column px-4 pt-2 pb-4 gap-4"},Lz=["href"],Nz=["src","alt"],Dz={class:"h-color-mirage-dark h-font-size-18 h-font-weight-600"},xz={class:"h-color-mako-dark h-font-size-14 h-font-weight-500 flex align-items-center gap-1"},Mz=["src"],Fz={key:2},Vz={class:"smart-glasses-header flex justify-content-between align-items-center p-4 border-bottom-1 h-border-color-iron"},Bz=["src"],$z={class:"h-color-primary m-0 h-font-size-18 h-font-weight-500"},Uz=["src"],Hz={class:"hamburger-items__container pb-4"},zz={class:"flex flex-column py-3"},Kz={class:"py-2 px-4"},Gz={class:"h-color-pale-sky h-font-size-14 h-font-weight-600"},jz=["href"],Yz={class:"h-color-mirage-dark h-font-weight-500 h-font-size-20"},Wz={class:"flex flex-column gap-3 py-3 px-4"},Qz={class:"h-color-pale-sky h-font-size-14 h-font-weight-600"},Zz=["href"],qz={key:0,class:"h-bg-ribbon-blue h-color-white h-font-size-14 h-font-weight-500 border-round-lg py-1 px-2 absolute z-1",style:{to
2445p:"4px",left:"4px"}},Jz={class:"flex flex-row"},Xz={class:"col-6"},eK=["src","alt"],tK={class:"flex flex-column justify-content-center"},nK={class:"h-color-ebony-clay-dark h-font-size-16 h-font-weight-600"},sK={key:0,class:"flex flex-row gap-2 h-font-size-16 h-font-weight-400 h-color-mako-dark"},iK={class:"h-color-danger h-font-weight-500"},rK={class:"line-through"},aK={key:1,class:"h-font-size-16 h-font-weight-400 h-color-mako-dark"},oK={class:"flex flex-column px-4 pt-2 pb-4 gap-4"},lK=["href"],cK=["src","alt"],dK={class:"h-color-mirage-dark h-font-size-18 h-font-weight-600"},uK={class:"h-color-mako-dark h-font-size-14 h-font-weight-500 flex align-items-center gap-1"},hK=["src"],pK={key:3},fK={class:"designer-header flex justify-content-between align-items-center p-4 border-bottom-1 h-border-color-iron"},mK=["src"],gK={class:"h-color-primary m-0 h-font-size-18 h-font-weight-500"},yK=["src"],bK={class:"hamburger-items__container pb-4"},vK={class:"mt-4 mx-4"},_K={class:"flex justify-content-between align-items-center h-color-pale-sky h-font-size-14 h-font-weight-600"},wK={class:"brands-grid mx-4 py-4"},EK=["href"],SK=["src","alt"],CK={class:"flex flex-column py-3"},IK={class:"py-2 px-4"},TK={class:"h-color-pale-sky h-font-size-14 h-font-weight-600"},PK=["href"],OK={class:"flex flex-column px-4 pt-2 pb-4 gap-4"},AK=["href"],kK=["src","alt"],RK={class:"h-color-mirage-dark h-font-size-18 h-font-weight-600"},LK={class:"h-color-mako-dark h-font-size-14 h-font-weight-500 flex align-items-center gap-1"},NK=["src"],DK={key:4},xK={class:"readers-header flex justify-content-between align-items-center p-4 border-bottom-1 h-border-color-iron"},MK=$s(()=>f("div",null,[f("i",{class:"pi pi-chevron-left h-color-primary h-font-size-12"})],-1)),FK={class:"h-color-primary m-0 h-font-size-18 h-font-weight-500"},VK=$s(()=>f("i",{class:"pi pi-times h-color-primary"},null,-1)),BK=[VK],$K={class:"hamburger-items__container pb-4"},UK={class:"flex flex-column"},HK={class:"flex flex-column py-3 h-border-color-soltitude-darker"},zK={class:"h-color-pale-sky my-2 px-3 h-font-weight-600 h-font-size-14"},KK=["href"],GK={class:"h-color-mirage-dark h-font-weight-500 h-font-size-20"},jK=["href"],YK={class:"h-color-mirage-dark h-font-weight-500 h-font-size-20 flex"},WK={class:"pill"},QK={class:"flex flex-column px-2 pt-2 pb-8"},ZK={class:"w-full"},qK=["href"],JK=["src","alt"],XK={class:"flex flex-column p-2"},eG={class:"h-color-mirage-dark h-font-weight-600 my-2 h-font-size-20"},tG={class:"h-font-size-14 h-color-trout line-height-3"},nG=["href"],sG={class:"h-font-size-14 h-font-weight-500 h-color-mako-dark"},iG=["src"],rG={key:5},aG={class:"contacts-header flex justify-content-between align-items-center p-4 border-bottom-1 h-border-color-iron"},oG=["src"],lG={class:"h-color-primary m-0 h-font-size-18 h-font-weight-500"},cG=["src"],dG={class:"hamburger-items__container pb-4"},uG={class:"mt-4 mx-5"},hG={class:"h-color-pale-sky h-font-size-14 h-font-weight-600"},pG={class:"brands-grid mx-4 py-4"},fG=["href"],mG=["src","alt"],gG={class:"flex flex-column py-3"},yG={class:"py-2 px-4"},bG={class:"h-color-pale-sky h-font-size-14 h-font-weight-600"},vG=["href"],_G={class:"h-color-mirage-dark h-font-weight-500 h-font-size-20"},wG={class:"flex flex-column px-4 pt-2 pb-4 gap-4"},EG=["href"],SG=["src","alt"],CG={class:"h-color-mirage-dark h-font-size-18 h-font-weight-600"},IG={class:"h-color-mako-dark h-font-size-14 h-font-weight-500 flex align-items-center gap-1"},TG=["src"],PG={key:6},OG={class:"contacts-header flex justify-content-between align-items-center p-4 border-bottom-1 h-border-color-iron"},AG=["src"],kG={class:"h-color-primary m-0 h-font-size-18 h-font-weight-500"},RG=["src"],LG={class:"hamburger-items__container py-4"},NG={class:"flex flex-column px-4 pt-2 pb-4 gap-4"},DG=["href"],xG=["src","alt"],MG={class:"h-color-alizarin-crimson h-font-size-18 h-font-weight-600"},FG={class:"h-color-mako-dark h-font-size-14 h-font-weight-500 flex align-items-center gap-1"},VG=["src"],BG={key:7,style:{height:"100%",overflow:"scroll"}},Tg={__name:"HamburgerMenu",setup(e){vt(()=>{W()});const{t}=rt({useScope:"local"}),n=ie(),{imagePath:i}=Be().public;let r=It();const a=ee(()=>n.systemStore.getGenericSiteMetadata).value.is_logged_in,o=ee(()=>n.systemStore.getHeaderNavMenuType),l=ee(()=>n.systemStore.getHamburgerMenuType),c=ee(()=>n.systemStore.getIsOpticianSearch);ee(()=>n.systemStore.getHeaderInformation);const d=se(),u=ht(d),p=()=>{n.systemStore.setHeaderNavMenuType(""),n.systemStore.setIsScannerOpened(!0)};Re({brands:[]}),Re({brands:[]}),Re([]);const h=ge=>{ge==="help"?(n.systemStore.setHamburgerMenuType(ge),window.width<=768&&n.systemStore.setHeaderNavMenuType("hamburger")):n.systemStore.setHeaderNavMenuType(ge)},m=ge=>{n.systemStore.setHamburgerMenuType(ge)},v=()=>{n.systemStore.setHamburgerMenuType(""),n.systemStore.setHeaderNavMenuType("")},_=()=>{n.systemStore.setHamburgerMenuType("")},b=()=>window.location.pathname.toLowerCase().includes("fr_ca"),w=ge=>{const we=window.location.pathname;if(ge==="en"&&b()){const X=we.replace("/fr_CA","");window.location.href=`${window.location.origin}${X}${window.location.search}${window.location.hash}`}if(ge==="fr"&&!b()){const X=`/fr_CA${we}`;window.location.href=`${window.location.origin}${X}${window.location.search}${window.location.hash}`}},C=()=>{const ge=document.getElementById("header-new"),we=document.querySelector(".hamburger");if(!ge||!we){console.error(`Element ${ge?"cart-items":"header-new"} not found`);return}const{clientHeight:X}=ge,B=`calc(100vh - ${X}
2445px + 75px)`;we.style.setProperty("height",B,"important")},O=async()=>{document.body.style.marginTop=0,n.systemStore.setIsAccordionVisible(!1),n.systemStore.setHeaderNavMenuType(""),n.systemStore.setHeaderNavType(""),n.systemStore.setDisplayHeaderSearch(!0),n.systemStore.setDisplayHeaderSearchMenu(!0)},T=[{title:t("accordion.eyeglasses"),label:"eyeglasses"},{title:t("accordion.sunglasses"),label:"sunglasses"},{title:t("accordion.smart-glasses"),label:"smart-glasses"},{title:t("accordion.designer"),label:"designer"},{title:t("accordion.readers"),label:"readers"},{title:t("accordion.contacts"),label:"contacts"},{title:t("accordion.insurance"),label:"insurance"},{title:t("accordion.sale"),label:"sale"}],E=[{label:"account",title:t(a?"hamburger-footer.account-logged-in":"hamburger-footer.account-logged-out"),icon:`${i}images/header/loggedUser.svg`,navigateTo:"profile"},{label:"favorites",title:u.includes(".ca")?t("hamburger-footer.favourites"):t("hamburger-footer.favorites"),icon:`${i}images/header/favorite.svg`,navigateTo:"favorite",url:"/favorites"},{label:"insurance",title:t("hamburger-footer.use-insurance"),icon:`${i}images/header/verified_user.svg`,navigateTo:"",url:"/insurance"},{label:"help",title:t("hamburger-footer.help"),icon:`${i}images/header/help.svg`,navigateTo:"help"}],y=[{text:t("eyeglasses.shop.all"),url:"/glasses"},{text:t("eyeglasses.shop.women"),url:"/glasses?filters=%26filter=gender_uFilter:+Unisex+OR+gender_uFilter:+Women&product_type=Glasses"},{text:t("eyeglasses.shop.men"),url:"/glasses?filters=%26filter=gender_uFilter:+Unisex+OR+gender_uFilter:+Men&product_type=Glasses"},{text:t("eyeglasses.shop.kids"),url:"/glasses?filters=%26filter=gender_uFilter:+Kids&product_type=Glasses"}],P=[{text:t("eyeglasses.featured.best-sellers"),url:"/glasses?filters=%26filter=collections_name_uFilter:+Popular&product_type=Glasses"},{text:t("eyeglasses.featured.progressive-eligible"),url:"/glasses?filters=%26filter=features_uFilter:+Progressive+Eligible&product_type=Glasses"},{text:t("eyeglasses.featured.new"),url:"/glasses?filters=%26filter=collections_name_uFilter:+New&product_type=Glasses"},{text:t("eyeglasses.featured.eyeglasses"),url:"/glasses?filters=%26filter=brand_name_uFilter:+KITS&product_type=Glasses"},{text:t("eyeglasses.featured.designer"),url:"/glasses?filters=%26filter=collections_name_uFilter:+Designer&product_type=Glasses"}],A=[{text:t("eyeglasses.curated.campus-edit"),url:"/glasses?filters=%26filter=collections_name_uFilter:+The+Campus+Edit&product_type=Glasses"},{text:t("eyeglasses.curated.office-ready"),url:"/glasses?filters=%26filter=collections_name_uFilter:+Office+Ready&product_type=Glasses"}];u.includes("kits")&&P.unshift({text:t("eyeglasses.featured.fit-and-style"),url:"/quiz/glasses",label:"fit"});const I=[{src:"images/header/panel/Jul20-2026-Navbar-Eyeglasses-1.jpg",srcFR:"images/header/panel/Jul20-2026-Navbar-Eyeglasses-1.jpg",heading:"Up to 50% off Kids frames",subheading:"Shop kids glasses",url:"/glasses?filters=%26filter=gender_uFilter:+Kids&product_type=Glasses"},{src:"images/header/panel/Jul14-2026-Navbar-Smart-Glasses-1.jpg",srcFR:"images/header/panel/Jul14-2026-Navbar-Smart-Glasses-1.jpg",heading:"Meet Your Everyday AI Glasses",subheading:"Shop KITS Pangolin 3",url:"/glasses?filters=%26filter=brand_name_uFilter:+KITS%26filter=collections_name_uFilter:+Smart+Glasses&product_type=Glasses,Sunglasses"}],L=[{text:t("sunglasses.shop.all"),url:"/sunglasses"},{text:t("sunglasses.shop.women"),url:'/glasses?filters=%26filter=gender_uFilter:+"Unisex"+OR+gender_uFilter:+"Women"&product_type=Sunglasses&page=1'},{text:t("sunglasses.shop.men"),url:'/glasses?filters=%26filter=gender_uFilter:+"Unisex"+OR+gender_uFilter:+"Men"&product_type=Sunglasses&page=1'},{text:t("sunglasses.shop.kids"),url:'/glasses?filters=%26filter=gender_uFilter:+"Kids"&product_type=Sunglasses&page=1'}],D=[{text:t("sunglasses.featured.best-sellers"),url:"/glasses?filters=%26filter=collections_name_uFilter:+Popular&product_type=Sunglasses"},{text:t("sunglasses.featured.polarized-lenses"),url:"/includes-polarized-lenses"},{text:t("sunglasses.featured.sunglasses"),url:"/glasses?filters=%26filter=brand_name_uFilter:+KITS&product_type=Sunglasses"},{text:t("sunglasses.featured.designer"),url:"/glasses?filters=%26filter=collections_name_uFilter:+Designer&product_type=Sunglasses"}],z=[{src:"images/header/panel/Aug06-2026-Navbar-Sunglasses-1.jpg",srcFR:"images/header/panel/Aug06-2026-Navbar-Sunglasses-1.jpg",heading:"Up to 50% off Kids frames",subheading:"Shop kids sunglasses",url:"/glasses?filters=%26filter=gender_uFilter:+Kids&product_type=Sunglasses"},{src:"images/header/panel/Apr13-2026-Navbar-Sunglasses-2.jpg",srcFR:"images/header/panel/Apr13-2026-Navbar-Sunglasses-2.jpg",heading:"Vacation-ready",subheading:"Shop sun styles",url:"/glasses?filters=%26filter=collections_name_uFilter:+The+Slim+Edit&product_type=Sunglasses"}],G=[{text:t("smart-glasses[0].text"),url:t("smart-glasses[0].url")},{text:t("smart-glasses[1].text"),url:t("smart-glasses[1].url")},{text:t("smart-glasses[2].text"),url:t("smart-glasses[2].url")},{text:t("smart-glasses[3].text"),url:t("smart-glasses[3].url")},{text:t("smart-glasses[4].text"),url:t("smart-glasses[4].url")},{text:t("smart-glasses[5].text"),url:t("smart-glasses[5].url")},{text:t("smart-glasses[6].text"),url:t("smart-glasses[6].url")}],ne=Re([{src:"",sku:"GL28472",name:"",alt:"",fullPrice:""},{src:"",sku:u.includes(".ca")?"GL25778":"GL25629",name:"",alt:"",fullPrice:"",discountedPrice:""}]),W=async()=>{const ge=ne.value.map(X=>({sku:X.sku,config:""})),we=await n.glassesStore.fetchGlassesBulk(ge);we==null||we.forEach(X=>{var Se,Ce;const B=ne.value.find(U=>U.sku===X.product_sku);B&&(B.src=(Ce=(Se=X==null?void 0:X.product_images)==null?void 0:Se[0])==null?void 0:Ce.image,B.name=X.name,B.fullPrice=X.price,B.discountedPrice=X.discounted_price)})},ue=[{src:"images/header/panel/Jul14-2026-Navbar-Smart-Glasses-1.jpg",srcFR:"images/header/panel/Jul14-2026-Navbar-Smart-Glasses-1.jpg",heading:"KITS Pangolin 3",subheading:"Discover now",url:"/glasses?filters=%26filter=brand_name_uFilter:+KITS%26filter=collections_name_uFilter:+Smart+Glasses&product_type=Glasses,Sunglasses"},{src:"images/header/panel/Jul14-2026-Navbar-Smart-Glasses-2.jpg",srcFR:"images/header/panel/Jul14-2026-Navbar-Smart-Glasses-2_fr.jpg",heading:"Designer frames. Smart technology.",subheading:"Shop the collection",url:"/ai-smart-glasses"}],H=[{img:"images/header/panel/brands/logo-kits-grey.svg",alt:"Kits",url:"/glasses?filters=%26filter=brand_name_uFilter:+KITS&product_type=Glasses,Sunglasses"},{img:"images/header/panel/brands/logo-ray-ban-grey.svg",alt:"Ray Ban",url:"/brand-ray-ban"},{img:"images/header/panel/brands/logo-oakley-grey.svg",alt:"Oakley",url:"/brand-oakley"},{img:"images/header/panel/brands/logo-tom-ford-grey.svg",alt:"Tom Ford",url:"/brand-tom-ford"},{img:"images/header/panel/brands/logo-marc-jacobs-grey.svg",alt:"Marc Jacobs",url:"/brand-marc-jacobs"},{img:"images/header/panel/brands/logo-gucci-grey.svg",alt:"Gucci",url:"/brand-gucci"},{img:"images/header/panel/brands/logo-michael-kors-grey.svg",alt:"Michael Kors",url:"/glasses?filters=%26filter=brand_name_uFilter:+Michael+Kors&product_type=Glasses,Sunglasses"},{img:"images/header/panel/brands/logo-carrera-grey.svg",alt:"Carrera",url:"/brand-carrera"},{img:"images/header/panel/brands/logo-kate-spade-grey.svg",alt:"Kate Spade",url:"/brand-kate-spade"}],x=[{text:t("designer[0].text"),url:t("designer[0].url"),sale:!1},{text:t("designer[1].text"),url:t("designer[1].url"),sale:!1},{text:t("designer[2].text"),url:t("designer[2].url"),sale:!1},{text:t("designer[3].text"),url:t("designer[3].url"),sale:!1},{text:t("designer[4].text"),url:t("designer[4].url"),sale:!1},{text:t("designer[5].text"),url:t("designer[5].url"),sale:!1},{text:t("designer[6].text"),url:t("designer[6].url"),sale:!0}],V=[{src:"images/header/panel/Aug06-2026-Navbar-Designer-1.jpg",srcFR:"images/header/panel/Aug06-2026-Navbar-Designer-1.jpg",heading:"NEW designer kids collection",subheading:"Shop up to 50% off",url:"/glasses?filters=%26filter=collections_name_uFilter:+Designer+Kids&product_type=Glasses,Sunglasses"},{src:"images/header/panel/Sep08-2026-Navbar-Designer-2.jpg",srcFR:"images/header/panel/Sep08-2026-Navbar-Designer-2_fr.jpg",heading:"Shop NEW Ray-Ban Meta",subheading:"With 30% off lenses",url:"/glasses?filters=%26filter=brand_name_uFilter:+Ray-Ban%26filter=collections_name_uFilter:+Smart+Glasses&product_type=Glasses&product_type=Sunglasses"}],te=[{img:"images/header/panel/brands/contacts/logo-kits-daily.svg",alt:"Kits Daily",url:'/contacts?filters=%26filter=brand_name_uFilter:+"KITS"'},{img:"images/header/panel/brands/contacts/logo-acuvue.svg",alt:"Acuvue",url:'/contacts?filters=%26filter=brand_name_uFilter:+"Johnson+and+Johnson"'},{img:"images/header/panel/brands/contacts/logo-biofinity.svg",alt:"Biofinity",url:'/contacts?filters=%26filter=brand_name_uFilter:+"CooperVision"'},{img:"images/header/panel/brands/contacts/logo-dailies.svg",alt:"Dailies",url:'/contacts?filters=%26filter=brand_name_uFilter:+"Alcon"'},{img:"images/header/panel/brands/contacts/logo-air-optix.svg",alt:"Air Optix",url:'/contacts?filters=%26filter=brand_name_uFilter:+"Alcon"'},{img:"images/header/panel/brands/contacts/logo-clariti.svg",alt:"Clariti",url:'/contacts?filters=%26filter=brand_name_uFilter:+"CooperVision"'},{img:"images/header/panel/brands/contacts/logo-precision1.svg",alt:"Precision 1",url:'/contacts?filters=%26filter=brand_name_uFilter:+"Alcon"'},{img:"images/header/panel/brands/contacts/logo-biotrue.svg",alt:"Biotrue",url:'/contacts?filters=%26filter=brand_name_uFilter:+"Bausch+and+Lomb"'},{img:"images/header/panel/brands/contacts/logo-ultra.svg",alt:"Bausch & Lomb ULTRA",url:'/contacts?filters=%26filter=brand_name_uFilter:+"Bausch+and+Lomb"'}],fe=[{title:t("contacts.all-contacts"),url:"/contacts"},{title:t("contacts.daily"),url:'/contacts?filters=%26filter=category_uFilter:+"Daily+Disposables"'},{title:t("contacts.weekly"),url:'/contacts?filters=%26filter=category_uFilter:+"1-2+Week+Disposables"'},{title:t("contacts.monthly"),url:'/contacts?filters=%26filter=category_uFilter:+"Monthly+Disposables"'},{title:t("contacts.single-vision"),url:'/contacts?filters=%26filter=category_uFilter:+"Toric+Lenses"'},{title:t("contacts.multifocal"),url:'/contacts?filters=%26filter=category_uFilter:+"Bifocals+and+Progressives"'},{title:u.includes(".ca")?t("contacts.colour"):t("contacts.color"),url:"/contacts?filters=%26filter=category_uFilter:+Color+Disposables"}],re=[{src:"images/header/panel/Apr30-2026-Navbar-Contacts-1.jpg",srcFR:"images/header/panel/Apr30-2026-Navbar-Contacts-1.jpg",heading:"Contacts starting at $1 a day",subheading:"Shop KITS Daily",url:"/kits-daily-contacts"}],be=[{src:"images/header/panel/Jul27-2026-Navbar-Sale-1.jpg",srcFR:"images/header/panel/Jul27-2026-Navbar-Sale-1_fr.jpg",heading:"Up to 65% off selected KITS Frames",subheading:"Shop KITS sale",url:"/collection-kits-glasses-sale"},{src:"images/header/panel/Jan19-2026-Navbar-Sale-2.jpg",srcFR:"images/header/panel/Jan19-2026-Navbar-Sale-2.jpg",heading:"Designer sale up to 70% off",subheading:"Shop Designer sale",url:"/glasses?product_type=Glasses,Sunglasses&filters=%26filter=collections_name_uFilter:+Designer+Promo",url:"/glasses?product_type=Glasses,Sunglasses&filters=%26filter=collections_name_uFilter:+Designer+Promo"}
2445],Y=[{src:"images/pdp/glasses/readers/ProgressiveReaders.png",srcFR:"images/pdp/glasses/readers/ProgressiveReaders.png",alt:"",url:"/glasses/progressive-readers?product_type=Glasses&filters="}],oe=[{title:t("readers.normal-readers.readers"),url:"/glasses/readers?product_type=Glasses"}],K=[{title:t("readers.progressive-readers.progressive"),url:"/glasses/progressive-readers?product_type=Glasses",pill:t("readers.progressive-readers.pill-progressives")}],Z=()=>{n.systemStore.setIsOpticianSearch(!1)},me=()=>{n.systemStore.setIsOpticianSearch(!0),O()},q=()=>{Z(),h("")},ae=()=>{try{dataLayer.push({event:"navbar_insurance_click"})}catch{console.log("Datalayer not found navbar_insurance_click")}};return We([o],(ge,we)=>{ge[0]==="hamburger"&&kt(()=>{C()})},{immediate:!0}),(ge,we)=>{const X=le("InputText");return g(),S("div",aH,[k(l)===""?(g(),S(J,{key:0},[f("div",{class:Oe(["hamburger-header flex flex-column justify-content-between align-items-start p-4 border-bottom-1 h-border-color-soltitude-darker gap-2 transition-colors transition-duration-300",k(c)?"h-bg-cloud-blue":"h-bg-white"])},[f("div",oH,[k(u)==="kits.ca"||k(u)==="kits.com"?(g(),S("div",lH,[f("div",{class:Oe(["toggler-slider h-border-radius-6",k(c)?"toggler-slider--ai":"toggler-slider--search"])},null,2),f("button",{class:"toggler-btn flex flex-row align-items-center justify-content-center h-border-radius-6 px-3",onClick:Z},[f("img",{src:`${k(i)}images/header/search-md.svg`,alt:"search icon"},null,8,cH),dH]),f("button",{class:"toggler-btn flex flex-row align-items-center justify-content-center h-border-radius-6 py-2 px-3",onClick:me},[f("img",{src:k(c)?`${k(i)}images/header/ai-stars-white.svg`:`${k(i)}images/header/ai-stars-blue.svg`,alt:"search icon"},null,8,uH),f("span",{class:Oe(["h-font-size-14 h-font-weight-500 ml-1",k(c)?"h-color-white":"h-color-denim"])},"AI search",2)])])):M("",!0),k(u)==="kits.ca"||k(u)==="kits.com"?(g(),S("div",hH,[f("img",{class:"vertical-align-middle",src:k(i)+"images/header/close-grey.svg",onClick:q,alt:"Close Icon"},null,8,pH)])):M("",!0)]),f("div",fH,[f("div",mH,[de(X,{type:"text",placeholder:k(c)?"'glasses for cycling'...":"Search",id:"search-input",class:"border-round-lg relative w-full pl-6 pr-7",onClick:O},null,8,["placeholder"]),f("div",gH,[k(c)?(g(),S("img",{key:0,class:"vertical-align-middle",src:k(i)+"images/header/ai-stars-blue.svg",alt:"search"},null,8,yH)):(g(),S("img",{key:1,class:"vertical-align-middle",src:k(i)+"images/header/search_new.svg",alt:"search"},null,8,bH))]),k(u)==="opticontacts.com"||k(u)==="contactsexpress.ca"?(g(),S("img",{key:0,class:"vertical-align-middle absolute cursor-pointer barcode-scanner",id:"barcode-scanner",style:{right:"12px",to
2445p:"50%",transform:"translateY(-50%)"},src:k(i)+"images/header/scan-barcode.svg",alt:"scan",onClick:p},null,8,vH)):M("",!0)]),k(u)!=="kits.ca"&&k(u)!=="kits.com"?(g(),S("img",{key:0,class:"cursor-pointer",onClick:we[0]||(we[0]=B=>h("")),src:k(i)+"images/header/close-grey.svg",alt:"Close Icon"},null,8,_H)):M("",!0)])],2),f("div",wH,[(g(),S(J,null,ye(T,(B,Se)=>(g(),S(J,{key:Se},[B.label==="sale"&&!k(u).includes("kits")?(g(),S(J,{key:0},[],64)):B.label==="sale"&&k(u).includes("kits")?(g(),S("div",{key:1,class:"flex justify-content-between domain-item h-color-mirage-dark h-font-size-20 h-font-weight-500 py-3 px-4 cursor-pointer",onClick:Ce=>m(B.label)},[f("span",SH,N(B.title),1),CH],8,EH)):B.label==="insurance"?(g(),S("a",{key:2,class:"flex justify-content-between domain-item h-color-mirage-dark h-font-size-20 h-font-weight-500 py-3 px-4 cursor-pointer",href:k(Ae)()+"/insurance",onClick:ae},N(B.title),9,IH)):(g(),S("div",{key:3,class:"flex justify-content-between domain-item h-color-mirage-dark h-font-size-20 h-font-weight-500 py-3 px-4 cursor-pointer",onClick:Ce=>m(B.label)},[f("span",{class:Oe({"h-color-alizarin-crimson":B.label==="sale"})},[ke(N(B.title)+" ",1),B.label==="smart-glasses"?(g(),S("span",PH,"New")):M("",!0)],2),OH],8,TH))],64))),64))]),f("div",AH,[f("div",kH,[(g(),S(J,null,ye(E,(B,Se)=>f("div",{class:"flex justify-content-between domain-item py-2 px-4 cursor-pointer",key:Se},[B.label!=="favorites"&&B.label!=="insurance"?(g(),S("button",{key:0,onClick:Ce=>h(B.navigateTo),class:"h-color-mako-dark h-font-weight-500 h-font-size-14 flex align-items-center justify-content-between w-full"},[f("div",LH,[f("span",null,N(B.title),1)])],8,RH)):(g(),S("a",{key:1,href:k(Ae)()+B.url,class:"h-color-mako-dark w-full h-font-weight-500 h-font-size-14 flex align-items-center gap-2"},[f("div",DH,[f("span",null,N(B.title),1)])],8,NH))])),64)),k(u)==="kits.ca"?(g(),S("div",xH,[f("div",MH,[f("div",null,[f("span",{class:Oe({"h-color-mako-dark":!b()}),onClick:we[1]||(we[1]=B=>w("en"))},"EN ",2),FH,f("span",{class:Oe({"h-color-mako-dark":b()}),onClick:we[2]||(we[2]=B=>w("fr"))}," FR ",2)])])])):M("",!0)])])],64)):M("",!0),k(l)!==""?(g(),S(J,{key:1},[k(l)==="eyeglasses"?(g(),S("div",VH,[f("div",BH,[f("button",{onClick:_,class:"flex align-items-center gap-2"},[f("img",{src:k(i)+"images/header/arrow-left.svg",alt:"Left pointing arrow"},null,8,$H),f("p",UH,N(k(t)("accordion.eyeglasses")),1)]),f("button",{onClick:v,class:"cursor-pointer"},[f("img",{src:k(i)+"images/header/close-grey.svg",alt:"Close Icon"},null,8,HH)])]),f("div",zH,[f("div",KH,[f("div",GH,N(k(t)("eyeglasses.shop.title")),1)]),f("div",jH,[(g(),S(J,null,ye(y,B=>f("a",{key:B.text,href:k(Ae)()+B.url,class:"hamburger-menu-item__container cursor-pointer w-full px-4 py-2"},[f("span",WH,N(B.text),1)],8,YH)),64)),k(u).includes(".ca")?(g(),S("a",{key:0,href:k(Ae)()+"/accessories",class:"hamburger-menu-item__container cursor-pointer w-full px-4 py-2"},[f("span",ZH,N(k(t)("eyeglasses.shop.accessories")),1)],8,QH)):M("",!0)]),f("div",qH,[f("div",JH,[f("div",XH,N(k(t)("eyeglasses.featured.title")),1)]),f("div",ez,[(g(),S(J,null,ye(P,B=>f("a",{href:k(Ae)()+B.url,key:B.text,class:"hamburger-menu-item__container cursor-pointer w-full px-4 py-2 align-items-center",id:B.label==="fit"?"monetate-pdp-hamburger-quiz":"",style:cs(B.label==="fit"?{display:"none"}:"")},[f("span",{class:Oe(["h-color-mirage-dark h-font-weight-500 h-font-size-20",{"h-color-denim":B.label==="fit"}])},N(B.text),3),B.label==="fit"?(g(),S("div",nz,"New")):M("",!0)],12,tz)),64))])]),f("div",sz,[f("div",iz,[f("div",rz,N(k(t)("eyeglasses.curated.title")),1)]),f("div",az,[(g(),S(J,null,ye(A,B=>f("a",{href:k(Ae)()+B.url,class:"hamburger-menu-item__container cursor-pointer w-full px-4 py-2 align-items-center"},[f("span",lz,N(B.text),1)],8,oz)),64))])]),f("div",cz,[(g(),S(J,null,ye(I,(B,Se)=>f("a",{key:Se,class:"promo-wrapper",href:k(Ae)()+B.url},[f("img",{src:k(i)+(k(r).href.toLowerCase().includes("fr_ca")?B.srcFR:B.src),alt:B.heading,class:"img-responsive"},null,8,uz),f("div",hz,N(B.heading),1),f("div",pz,[ke(N(B.subheading)+" ",1),f("img",{src:k(i)+"images/header/arrow-right-smaller-414651.svg",height:"20",width:"20",alt:"Small Right Arrow"},null,8,fz)])],8,dz)),64))])])])):M("",!0),k(l)==="sunglasses"?(g(),S("div",mz,[f("div",gz,[f("div",{onClick:_,class:"flex align-items-center gap-2"},[f("img",{src:k(i)+"images/header/arrow-left.svg",alt:"Left pointing arrow"},null,8,yz),f("p",bz,N(k(t)("accordion.sunglasses")),1)]),f("div",{onClick:v,class:"cursor-pointer"},[f("img",{src:k(i)+"images/header/close-grey.svg",alt:"Close Icon"}
2445,null,8,vz)])]),f("div",_z,[f("div",wz,[f("div",Ez,[f("div",Sz,N(k(t)("sunglasses.shop.title")),1)]),(g(),S(J,null,ye(L,B=>f("a",{key:B.text,href:k(Ae)()+B.url,class:"hamburger-menu-item__container cursor-pointer w-full px-4 py-2"},[f("span",Iz,N(B.text),1)],8,Cz)),64))]),f("div",Tz,[f("div",Pz,[f("div",Oz,N(k(t)("sunglasses.featured.title")),1)]),f("div",Az,[(g(),S(J,null,ye(D,(B,Se)=>f("a",{href:k(Ae)()+B.url,key:B.text,class:"hamburger-menu-item__container cursor-pointer w-full px-4 py-2"},[f("span",{class:Oe(["h-color-mirage-dark h-font-weight-500 h-font-size-20",B.text===k(t)("eyeglasses.featured.sale")||B.text===k(t)("eyeglasses.featured.designer-sale")?"h-color-alizarin-crimson":""])},N(B.text),3)],8,kz)),64))])]),f("div",Rz,[(g(),S(J,null,ye(z,(B,Se)=>f("a",{key:Se,class:"promo-wrapper",href:k(Ae)()+B.url},[f("img",{src:k(i)+(k(r).href.toLowerCase().includes("fr_ca")?B.srcFR:B.src),alt:B.heading,class:"img-responsive"},null,8,Nz),f("div",Dz,N(B.heading),1),f("div",xz,[ke(N(B.subheading)+" ",1),f("img",{src:k(i)+"images/header/arrow-right-smaller-414651.svg",height:"20",width:"20",alt:"Small Right Arrow"},null,8,Mz)])],8,Lz)),64))])])])):M("",!0),k(l)==="smart-glasses"?(g(),S("div",Fz,[f("div",Vz,[f("div",{onClick:_,class:"flex align-items-center gap-2 cursor-pointer"},[f("img",{src:k(i)+"images/header/arrow-left.svg",alt:"Left pointing arrow"},null,8,Bz),f("p",$z,N(k(t)("accordion.smart-glasses")),1)]),f("div",{onClick:v,class:"cursor-pointer"},[f("img",{src:k(i)+"images/header/close-grey.svg",alt:"Close Icon"},null,8,Uz)])]),f("div",Hz,[f("div",zz,[f("div",Kz,[f("div",Gz,N(k(t)("hamburger.shop")),1)]),(g(),S(J,null,ye(G,B=>(g(),S(J,null,[B.text==="Nuance Audio"&&k(u).includes(".ca")?(g(),S(J,{key:0},[],64)):(g(),S("a",{key:1,href:k(Ae)()+B.url,class:"hamburger-menu-item__container cursor-pointer w-full px-4 py-2"},[f("span",Yz,N(B.text),1)],8,jz))],64))),64))]),f("div",Wz,[f("div",Qz,N(k(t)("hamburger.featured-brands")),1),(g(!0),S(J,null,ye(k(ne),(B,Se)=>(g(),S("a",{class:Oe(["h-bg-white-smoke border-round-lg p-3",{relative:Se===0}]),href:`/glasses/${B.sku}/${k($n)(B.name)}`},[Se===0?(g(),S("span",qz,"New")):M("",!0),f("div",Jz,[f("div",Xz,[f("img",{src:B.src,alt:B.alt,style:{"mix-blend-mode":"multiply"},class:"img-responsive"},null,8,eK)]),f("div",tK,[f("div",nK,N(B.name),1),B.discountedPrice?(g(),S("div",sK,[f("span",iK,"$"+N(B.discountedPrice),1),f("span",rK,"$"+N(B.fullPrice),1)])):(g(),S("div",aK," $"+N(B.fullPrice),1))])])],10,Zz))),256))]),f("div",oK,[(g(),S(J,null,ye(ue,(B,Se)=>f("a",{key:Se,href:k(Ae)()+B.url,class:"promo-wrapper"},[f("img",{src:k(i)+(k(r).href.toLowerCase().includes("fr_ca")?B.srcFR:B.src),alt:B.heading,class:"img-responsive"},null,8,cK),f("div",dK,N(B.heading),1),f("div",uK,[ke(N(B.subheading)+" ",1),f("img",{src:k(i)+"images/header/arrow-right-smaller-414651.svg",height:"20",width:"20",alt:"Small Right Arrow"},null,8,hK)])],8,lK)),64))])])])):M("",!0),k(l)==="designer"?(g(),S("div",pK,[f("div",fK,[f("div",{onClick:_,class:"flex align-items-center gap-2 cursor-pointer"},[f("img",{src:k(i)+"images/header/arrow-left.svg",alt:"Left pointing arrow"},null,8,mK),f("p",gK,N(k(t)("accordion.designer")),1)]),f("div",{onClick:v,class:"cursor-pointer"},[f("img",{src:k(i)+"images/header/close-grey.svg",alt:"Close Icon"},null,8,yK)])]),f("div",bK,[f("div",vK,[f("div",_K,[f("span",null,N(k(t)("hamburger.top-brands")),1)])]),f("div",wK,[(g(),S(J,null,ye(H,B=>f("a",{key:B.text,href:k(Ae)()+B.url,class:"brand-wrapper cursor-pointer"},[f("img",{src:k(i)+B.img,alt:B.alt},null,8,SK)],8,EK)),64))]),f("div",CK,[f("div",IK,[f("div",TK,N(k(t)("hamburger.shop")),1)]),(g(),S(J,null,ye(x,B=>f("a",{href:k(Ae)()+B.url,class:"hamburger-menu-item__container cursor-pointer w-full px-4 py-2"},[f("span",{class:Oe(["h-color-mirage-dark h-font-weight-500 h-font-size-20",B.sale?"h-color-alizarin-crimson":""])},N(B.text),3)],8,PK)),64))]),f("div",OK,[(g(),S(J,null,ye(V,(B,Se)=>f("a",{key:Se,href:k(Ae)()+B.url,class:"promo-wrapper"},[f("img",{src:k(i)+(k(r).href.toLowerCase().includes("fr_ca")?B.srcFR:B.src),alt:B.heading,class:"img-responsive"}
2445,null,8,kK),f("div",RK,N(B.heading),1),f("div",LK,[ke(N(B.subheading)+" ",1),f("img",{src:k(i)+"images/header/arrow-right-smaller-414651.svg",height:"20",width:"20",alt:"Small Right Arrow"},null,8,NK)])],8,AK)),64))])])])):M("",!0),k(l)==="readers"?(g(),S("div",DK,[f("div",xK,[f("div",{onClick:_,class:"flex align-items-center gap-2 cursor-pointer"},[MK,f("p",FK,N(k(t)("accordion.readers")),1)]),f("div",{onClick:v,class:"cursor-pointer"},BK)]),f("div",$K,[f("div",UK,[f("div",HK,[f("p",zK,N(k(t)("readers.normal-readers.shop")),1),(g(),S(J,null,ye(oe,B=>f("a",{href:k(Ae)()+B.url,class:"hamburger-menu-item__container cursor-pointer w-full py-2 px-3"},[f("span",GK,N(B.title),1)],8,KK)),64)),(g(),S(J,null,ye(K,B=>f("a",{href:k(Ae)()+B.url,class:"hamburger-menu-item__container cursor-pointer w-full py-2 px-3"},[f("span",YK,[ke(N(B.title)+" ",1),f("span",WK,N(B.pill),1)])],8,jK)),64))])]),f("div",QK,[f("div",ZK,[(g(),S(J,null,ye(Y,B=>f("a",{href:k(Ae)()+B.url,class:"w-full"},[f("img",{src:k(i)+(k(r).href.toLowerCase().includes("fr_ca")?B.srcFR:B.src),alt:B.alt,class:"img-responsive w-full px-1 border-round-lg"},null,8,JK)],8,qK)),64))]),f("div",XK,[f("p",eG,N(k(t)("readers.progressive-readers-cta.title")),1),f("span",tG,N(k(t)("readers.progressive-readers-cta.description")),1)]),f("a",{href:k(Ae)()+Y[0].url,class:"flex flex-row align-items-center mt-3 px-2"},[f("span",sG,N(k(t)("readers.progressive-readers-cta.shop")),1),f("img",{src:k(i)+"images/header/arrow-right.svg",class:"ml-2"},null,8,iG)],8,nG)])])])):M("",!0),k(l)==="contacts"?(g(),S("div",rG,[f("div",aG,[f("div",{class:"flex align-items-center gap-2 cursor-pointer",onClick:_},[f("img",{src:k(i)+"images/header/arrow-left.svg",alt:"Left pointing arrow"},null,8,oG),f("p",lG,N(k(t)("accordion.contacts")),1)]),f("div",{onClick:v,class:"cursor-pointer"},[f("img",{src:k(i)+"images/header/close-grey.svg",alt:"Close Icon"},null,8,cG)])]),f("div",dG,[f("div",uG,[f("div",hG,N(k(t)("hamburger.featured-brands")),1)]),f("div",pG,[(g(),S(J,null,ye(te,B=>f("a",{key:B.text,href:k(Ae)()+B.url,class:"brand-wrapper cursor-pointer"},[f("img",{src:k(i)+B.img,alt:B.alt},null,8,mG)],8,fG)),64))]),f("div",gG,[f("div",yG,[f("div",bG,N(k(t)("hamburger.shop")),1)]),(g(),S(J,null,ye(fe,B=>f("a",{href:k(Ae)()+B.url,class:"hamburger-menu-item__container cursor-pointer w-full px-4 py-2 flex flex-column"},[f("span",_G,N(B.title),1)],8,vG)),64))]),f("div",wG,[(g(),S(J,null,ye(re,(B,Se)=>f("a",{key:Se,class:"promo-wrapper",href:k(Ae)()+B.url},[f("img",{src:k(i)+(k(r).href.toLowerCase().includes("fr_ca")?B.srcFR:B.src),alt:B.heading,class:"img-responsive"},null,8,SG),f("div",CG,N(B.heading),1),f("div",IG,[ke(N(B.subheading)+" ",1),f("img",{src:k(i)+"images/header/arrow-right-smaller-414651.svg",height:"20",width:"20",alt:"Small Right Arrow"},null,8,TG)])],8,EG)),64))])])])):M("",!0),k(l)==="sale"?(g(),S("div",PG,[f("div",OG,[f("div",{class:"flex align-items-center gap-2 cursor-pointer",onClick:_},[f("img",{src:k(i)+"images/header/arrow-left.svg",alt:"Left pointing arrow"},null,8,AG),f("p",kG,N(k(t)("accordion.sale")),1)]),f("div",{onClick:v,class:"cursor-pointer"},[f("img",{src:k(i)+"images/header/close-grey.svg",alt:"Close Icon"},null,8,RG)])]),f("div",LG,[f("div",NG,[(g(),S(J,null,ye(be,(B,Se)=>f("a",{key:Se,class:"promo-wrapper",href:k(Ae)()+B.url},[f("img",{src:k(i)+(k(r).href.toLowerCase().includes("fr_ca")?B.srcFR:B.src),alt:B.heading,class:"img-responsive"},null,8,xG),f("div",MG,N(B.heading),1),f("div",FG,[ke(N(B.subheading)+" ",1),f("img",{src:k(i)+"images/header/arrow-right-smaller-414651.svg",height:"20",width:"20",alt:"Small Right Arrow"},null,8,VG)])],8,DG)),64))])])])):M("",!0),k(l)==="help"?(g(),S("div",BG,[de(Ig)])):M("",!0)],64)):M("",!0)])}}};typeof Ou=="function"&&Ou(Tg);const $G=Ke(Tg,[["__scopeId","data-v-024db075"]]);function Au(e){const t=e;t.__i18n=t.__i18n||[],t.__i18n.push({locale:"",resource:{en:{profile:{"my-account":{t:0,b:{t:2,i:[{t:3}],s:"My Account"}},"create-account":{t:0,b:{t:2,i:[{t:3}],s:"Create an account"}},"forgot-password":{t:0,b:{t:2,i:[{t:3}],s:"Forgot password"}},"order-tracking":{t:0,b:{t:2,i:[{t:3}],s:"Order Tracking"}},"place-reorder":{t:0,b:{t:2,i:[{t:3}],s:"Place Re-Order"}}
2445,"my-autoship":{t:0,b:{t:2,i:[{t:3}],s:"My Autoship"}},"my-prescription":{t:0,b:{t:2,i:[{t:3}],s:"My Prescription"}},"online-vision-test":{t:0,b:{t:2,i:[{t:3}],s:"Online Vision Test"}},"sign-out":{t:0,b:{t:2,i:[{t:3}],s:"Sign out"}},register:{t:0,b:{t:2,i:[{t:3}],s:"Register"}},"sign-in":{t:0,b:{t:2,i:[{t:3}],s:"Sign in"}},"account-details":{t:0,b:{t:2,i:[{t:3}],s:"Account details"}},"my-profile":{t:0,b:{t:2,i:[{t:3}],s:"My profile"}},"order-history":{t:0,b:{t:2,i:[{t:3}],s:"Order history"}},"trending-products":{t:0,b:{t:2,i:[{t:3}],s:"Trending products"}},"join-autoship":{t:0,b:{t:2,i:[{t:3}],s:"Autoship"}},"kits-plus":{t:0,b:{t:2,i:[{t:3}],s:"KITS+"}},enrolled:{t:0,b:{t:2,i:[{t:3}],s:"Enrolled"}},welcome:{t:0,b:{t:2,i:[{t:3}],s:"Welcome,"}},greeting:{t:0,b:{t:2,i:[{t:3,v:"Nice to see you, "},{t:4,k:"fname"},{t:3,v:" "},{t:4,k:"lname"}]}},account:{t:0,b:{t:2,i:[{t:3}],s:"Account"}}},favorite:{"title-us":{t:0,b:{t:2,i:[{t:3}],s:"Favorites"}},"title-ca":{t:0,b:{t:2,i:[{t:3}],s:"Favourites"}},"view-us":{t:0,b:{t:2,i:[{t:3}],s:"View my favorites"}},"view-ca":{t:0,b:{t:2,i:[{t:3}],s:"View my favourites"}},items:{t:0,b:{t:2,i:[{t:3}],s:"Items"}},"shop-bestsellers":{t:0,b:{t:2,i:[{t:3}],s:"Shop bestsellers"}},register:{t:0,b:{t:2,i:[{t:3}],s:"Register"}},"sign-in":{t:0,b:{t:2,i:[{t:3}],s:"Sign in"}},"list-empty-us":{t:0,b:{t:2,i:[{t:3}],s:"Your favorites list is empty."}},"list-empty-ca":{t:0,b:{t:2,i:[{t:3}],s:"Your favourites list is empty."}},"add-items-us":{t:0,b:{t:2,i:[{t:3}],s:"Start adding items to your Favorites list and keep them all in one place."}},"add-items-ca":{t:0,b:{t:2,i:[{t:3}],s:"Start adding items to your Favourites list and keep them all in one place."}}},"order-info":{"order-status":{t:0,b:{t:2,i:[{t:3}],s:"Check order status"}},"place-reorder":{t:0,b:{t:2,i:[{t:3}],s:"Place reorder"}}},"card-text":{program:{t:0,b:{t:2,i:[{t:3}],s:"Trending products"}},subscribe:{t:0,b:{t:2,i:[{t:3}],s:"Subscribe & Save"}},"join-plus":{t:0,b:{t:2,i:[{t:3}],s:"Join KITS+"}}},cart:{"view-cart":{t:0,b:{t:2,i:[{t:3}],s:"View cart & checkout"}},subtotal:{t:0,b:{t:2,i:[{t:3}],s:"Subtotal"}},"sign-in":{t:0,b:{t:2,i:[{t:3}],s:"Sign in to see items you may have previously added."}},"apply-promo":{t:0,b:{t:2,i:[{t:3}],s:"Apply"}},"remove-promo":{t:0,b:{t:2,i:[{t:3}],s:"Remove"}},"enter-promo":{t:0,b:{t:2,i:[{t:3}],s:"Enter coupon code"}},items:{t:0,b:{t:2,i:[{t:3}],s:"Items"}},"my-bag":{t:0,b:{t:2,i:[{t:3}],s:"My bag"}},"bag-empty":{t:0,b:{t:2,i:[{t:3}],s:"Your bag is empty."}},"coupon-required":{t:0,b:{t:2,i:[{t:3}],s:"*Coupon code is required"}}}}}})}const Pg=Ge({components:{LoadingDots:rH,HamburgerMenu:$G},setup(){var L,D,z,G;const{t:e}=rt({useScope:"local"}),t=ie(),{imagePath:n}=Be().public,i=ht(se()),r=rg("favItemsNew",[]),s=Re(!1),a=window.location.origin,o=ee(()=>t.systemStore.getHeaderNavMenuType),l=ee(()=>t.systemStore.getLoadingFetchData),c=ee(()=>t.systemStore.getGenericSiteMetadata),d=ee(()=>t.systemStore.getInvalidCoupon),u=ee(()=>t.glassesStore.getReaders.progressive),p=ee(()=>{const ne=_l();if(ne==="progressive-readers"||ne==="sun-progressive-readers"||u.value)return"Progressive Readers";switch(ne){case"readers":case"sun-readers":return"Readers";default:return""}}),h=ne=>{if(ne==="progressive-readers"||ne==="sun-progressive-readers")return"Progressive Readers";switch(ne){case"readers":case"sun-readers":return"Readers";default:return""}},m=ne=>{const W=r.value.findIndex(ue=>ue.product_sku===ne);if(W!==-1){const ue=r.value.splice(W,1)[0],H={product_sku:ue.product_sku,brand_name:ue.brand_name,product_price:ue.product_price,product_promo_price:ue.product_promo_price,product_group:ue.product_group,product_name:ue.product_name,product_config_id:ue.product_config_id,product_image_url:ue.product_image_url,product_color:ue.product_color,product_generic_color:ue.product_generic_color,product_a_size:ue.product_a_size,product_b_size:ue.product_b_size,product_bridge:ue.product_bridge,product_temple:ue.product_temple,product_vto_alt_full:ue.product_vto_alt_full,readersType:ue.readersType};try{dataLayer.push({event:"remove_fav",data:H})}catch(x){console.log(x,{event:"remove_fav",data:H})}}r.value=r.value},v=async ne=>{await t.systemStore.removeCartItem(ne)},_=ne=>{t.systemStore.setHeaderNavMenuType(ne)},b=()=>{t.systemStore.setHeaderNavMenuType("hamburger")},w=()=>{const ne=document.getElementById("header-new"),W=document.querySelector(".cart-items");if(!ne||!W){console.error(`Element ${ne?"cart-items":"header-new"} not found`);return}const{clientHeight:ue}=ne,H=`calc(100vh - ${ue}px + 75px)`;W.style.setProperty("height",H,"important")},C=ne=>{console.log("fav",ne);const W=Ae(),{product_sku:ue,product_config_id:H,readersType:x,brand_name:V,product_name:te}=ne,fe=x?`${x.replace(/^\/|\/$/g,"")}/`:"";return`${W}/glasses/${fe}${ue}/${$n(te,V)}?config=${H}`},O=(ne,W,ue)=>{try{let H=new URL(ne);return W&&ue!=="Sunglasses"&&(H.pathname=H.pathname.replace("/glasses",`/glasses
2445/${W}`)),H.pathname+H.search}catch(H){return console.error("Invalid URL:",H),null}},T=[{key:"myAccount",label:"profile.my-account",url:"/customerservice"},{key:"newAccount",label:"profile.create-account",url:"/new_account"},{key:"orderTracking",label:"profile.order-tracking",url:"/query/check_orders?pagename=check_status"},{key:"placeReorder",label:"profile.place-reorder",url:"/saved_carts_changes?pagename=saved_carts"},{key:"my-autoship",label:"profile.my-autoship",url:"/manage_autoship?manage_autoship=1"},{key:"myPrescription",label:"profile.my-prescription",url:"/upload_rx?pagename=upload_prescrip"},{key:"onlineVisionTest",label:"profile.online-vision-test",url:"/onlinevisiontest"}],E=[{key:"orderStatus",label:"order-info.order-status",icon:"images/header/package-search.svg",url:"/query/check_orders?pagename=check_status",alt:"clock rewind Icon"},{key:"placeReorder",label:"order-info.place-reorder",icon:"images/header/clock-rewind.svg",url:"/saved_carts_changes?pagename=saved_carts",alt:"package search Icon"}],y=Re({coupon:c.value&&((G=(z=(D=(L=c.value)==null?void 0:L.side_cart)==null?void 0:D.discounts)==null?void 0:z.coupon)!=null&&G.added)?c.value.side_cart.discounts.coupon.coupon_code:""}),P={coupon:{required:wi.withMessage("",Ei)}}
2445,A=oa(P,y),I=async ne=>{if(s.value=!0,!ne){y.value.coupon==""&&t.systemStore.addToastMessage("ERROR",e("cart.coupon-required"));return}const W=y.value.coupon.trim();c.value.side_cart.discounts.coupon.added&&await t.systemStore.removeCoupon(W),await t.systemStore.addCoupon(W)&&(s.value=!1,y.value={coupon:""})};return We([()=>o.value,()=>c.value.side_cart.items],async([ne,W])=>{ne==="cart"&&(W!=null&&W.length)&&(await kt(),w())},{immediate:!0}),{v$:A,t:e,imagePath:n,headerNavMenuType:o,currentOrigin:a,handleHeaderNavMenuType:_,backToMainHamburgerMenu:b,setDynamicLink:Ae,favItems:r,genericSiteMetadata:c,profileMenuItems:T,orderItems:E,returnPriceWithDecimals:ss,deleteFavoriteItem:m,deleteCartItem:v,isLoadingFetchData:l,createUrlLink:O,formFields:y,onSubmit:I,invalidCoupon:d,baseDomain:i,createItemLink:C,getReadersTypeLabel:h,readersTypeLabel:p}}}),Us=e=>(us("data-v-56ab1b40"),e=e(),hs(),e),UG={key:0,class:"header-menu-expanded border-round-bottom-md bg-white header-panel-overflow box-shadow",style:{"min-width":"280px"}},HG={key:0,class:"profile"},zG={class:"profile-container"},KG={key:0},GG={class:"profile-header flex md:hidden justify-content-between align-items-center p-4 border-bottom-1 h-border-color-iron"},jG={class:"flex align-items-center gap-2"},YG=["src"],WG={class:"h-color-primary m-0 h-font-size-18 h-font-weight-500"},QG=Us(()=>f("i",{class:"pi pi-times"},null,-1)),ZG=[QG],qG={class:"profile-login flex flex-column p-4 mb-3"},JG={class:"h-color-mirage-dark h-font-size-18 h-font-weight-600 pb-3"},XG={class:"flex flex-row gap-4 pb-4 border-bottom-1 h-border-color-iron"},ej=["href"],tj=["href"],nj={class:"program flex flex-column gap-1 mt-4"},sj={class:"h-color-pale-sky h-font-size-14 h-font-weight-600 m-0 pb-2"},ij=["href"],rj={key:0,class:"h-bg-alice-blue inline border-round-lg py-1 px-2 h-font-size-12"},aj={class:"gradient-text"},oj=["href"],lj={key:0,class:"h-bg-alice-blue inline border-round-lg py-1 px-2 h-font-size-12"},cj={class:"gradient-text"},dj={key:1},uj={class:"profile-header flex md:hidden justify-content-between align-items-center p-4 border-bottom-1 h-border-color-iron"},hj={class:"flex align-items-center gap-2"},pj=["src"],fj={class:"h-color-primary m-0 h-font-size-18 h-font-weight-500"},mj=Us(()=>f("i",{class:"pi pi-times"},null,-1)),gj=[mj],yj={class:"profile-header flex flex-column p-4 gap-2"},bj={class:"flex justify-content-between gap-2"},vj={class:"h-color-primary m-0 h-font-size-18 h-font-weight-500"},_j=["href"],wj={class:"profile-login flex flex-column p-4 pt-0 gap-3"},Ej=["href"],Sj=["src","alt"],Cj={class:"navigation-expand account details flex flex-column gap-1 py-3 border-y-1 h-border-color-iron"},Ij={class:"h-color-pale-sky h-font-size-16 h-font-weight-600 m-0 pb-2"},Tj=["href"],Pj=["href"],Oj=["href"],Aj={class:"account details flex flex-column gap-1"},kj={class:"h-color-pale-sky h-font-size-16 h-font-weight-600 m-0 pb-2"},Rj={class:"navigation-expand flex align-items-center gap-2"},Lj=["href"],Nj={key:0,class:"h-bg-alice-blue inline border-round-lg py-1 px-2 h-font-size-12"},Dj={class:"gradient-text"},xj={key:0,class:"navigation-expand flex align-items-center gap-2"},Mj=["href"],Fj={key:0,class:"h-bg-alice-blue inline border-round-lg py-1 px-2 h-font-size-12"},Vj={class:"gradient-text"},Bj={key:1,class:"favorite h-full"},$j={class:"favorite-container h-full"},Uj={class:"favorite-header flex justify-content-between align-items-center border-bottom-1 p-4 h-border-color-iron mb-4 md:border-none md:mb-0"},Hj={class:"flex align-items-center gap-2"},zj={key:0,class:"h-color-primary m-0 h-font-size-18 h-font-weight-500"},Kj={key:1,class:"h-color-primary m-0 h-font-size-18 h-font-weight-500"},Gj={class:"h-color-shuttle-gray h-font-weight-300"},jj=Us(()=>f("i",{class:"pi pi-times"},null,-1)),Yj=[jj],Wj={key:0,class:"favorite-login flex flex-column pb-4 pr-4 pl-4 pt-0"},Qj={key:0,class:"h-color-shuttle-gray h-font-weight-300"},Zj={key:1,class:"h-color-shuttle-gray h-font-weight-300"},qj={class:"flex flex-column gap-2 mt-3"},Jj=["href"],Xj=["href"],eY={class:"flex flex-column gap-1 mt-4"},tY={class:"h-color-primary h-font-size-16 h-font-weight-600 m-0"},nY=["href"],sY={key:0,class:"h-bg-alice-blue inline border-round-lg py-1 px-2 h-font-size-12"},iY={class:"gradient-text"},rY=["href"],aY={key:0,class:"h-bg-alice-blue inline border-round-lg py-1 px-2 h-font-size-12"},oY={class:"gradient-text"},lY={key:1,class:"favorite-empty flex flex-column px-4 pb-6 pt-0"}
2445,cY={key:0,class:"h-color-shuttle-gray mb-2 h-font-weight-300"},dY={key:1,class:"h-color-shuttle-gray mb-2 h-font-weight-300"},uY=["href"],hY={class:"favorite-block"},pY={key:0,class:"favorite-items flex flex-column pb-0 pr-4 pl-4 pt-0"},fY=["href"],mY=["src"],gY={class:"flex flex-column"},yY={class:"m-0 h-color-primary h-font-weight-600 h-font-size-16"},bY=["innerHTML"],vY={class:"m-0 h-color-gray-tundora h-font-size-16 h-font-weight-400"},_Y={key:0,class:"flex price gap-2"},wY={class:"mt-1 h-color-danger h-font-weight-500 h-font-size-16"},EY={key:1,class:"flex price gap-2"},SY={class:"mt-1 h-color-primary h-font-weight-500 h-font-size-16"},CY=["onClick"],IY=["src"],TY={key:1,class:"pb-6 px-4 pt-6 md:pt-0"},PY=["href"],OY={key:2,class:"cart bg-white border-round-bottom-md"},AY={class:"cart-container h-full"},kY={class:"cart-header flex justify-content-between align-items-center p-4 border-bottom-1 h-border-color-iron md:border-none md:mb-0"},RY={class:"flex align-items-start gap-1"},LY={class:"md:hidden"},NY=["src"],DY={class:"flex align-items-center gap-2 flex-column md:flex-row"},xY={class:"h-color-primary m-0 h-font-size-18 h-font-weight-500"},MY={class:"h-color-shuttle-gray h-font-weight-300"},FY=Us(()=>f("i",{class:"pi pi-times"},null,-1)),VY=[FY],BY={key:0,class:"cart-login flex flex-column p-4 pt-0"},$Y={class:"h-color-shuttle-gray h-font-weight-300 mt-4 md:mt-0"},UY={class:"flex flex-column gap-2 mt-3"},HY=["href"],zY=["href"],KY={class:"flex flex-column gap-1 mt-4"},GY={class:"h-color-primary h-font-size-16 h-font-weight-600 m-0"},jY=["href"],YY={key:0,class:"h-bg-alice-blue inline border-round-lg py-1 px-2 h-font-size-12"},WY={class:"gradient-text"},QY=["href"],ZY={key:0,class:"h-bg-alice-blue inline border-round-lg py-1 px-2 h-font-size-12"},qY={class:"gradient-text"},JY={key:1,class:"cart-empty flex flex-column px-4 pb-6 pt-0"},XY={class:"h-color-shuttle-gray mb-2 h-font-weight-300"},eW=["href"],tW={key:2,id:"cart-items",class:"cart-items flex flex-column"},nW={class:"shipping-status-label flex align-items-center gap-2 h-bg-alice-blue h-color-ucla-blue p-2 pl-4"},sW=["src"],iW={class:"items-list p-4 pt-0 overflow-auto"},rW=["href"],aW=["src"],oW={class:"flex flex-column"},lW={class:"m-0 h-color-primary h-font-weight-600 h-font-size-16"},cW=["innerHTML"],dW={class:"m-0 h-color-gray-tundora h-font-size-16 h-font-weight-400"},uW={class:"flex align-items-center gap-2"},hW={key:0,class:"mt-1 h-color-danger h-font-weight-500"},pW=["onClick"],fW=["src"],mW={class:"cart-subtotal"},gW={class:"p-4 pb-6 pt-2"},yW={class:"flex justify-content-between align-items-center"},bW={class:"h-font-size-16 h-color-primary mt-2 mb-3 h-font-weight-600"},vW={class:"flex align-items-center gap-2"},_W={key:0,class:"h-font-size-16 h-color-danger h-font-weight-500 mt-2 mb-3"},wW=["href"],EW={class:"relative mb-2"},SW={class:"absolute underline",type:"submit",style:{right:"12px",to
2445p:"12px","text-underline-offset":"4px"}},CW={key:0,class:"text-center mt-2"},IW={key:0,class:"flex align-items-center gap-2 h-font-size-14 h-color-danger"},TW=Us(()=>f("i",{class:"pi pi-exclamation-circle h-font-size-20"},null,-1)),PW={key:1,class:"flex align-items-center gap-2 h-font-size-14 flex align-items-center h-color-success"},OW=Us(()=>f("i",{class:"pi pi-check h-font-size-20"},null,-1)),AW={key:3,class:"hamburger-wrapper bg-white border-round-bottom-md"};function kW(e,t,n,i,r,s){const a=le("Button"),o=le("InputText"),l=le("LoadingDots"),c=le("HamburgerMenu");return e.headerNavMenuType!==""?(g(),S("div",UG,[e.headerNavMenuType==="profile"?(g(),S("div",HG,[f("div",zG,[e.genericSiteMetadata.is_logged_in?(g(),S("div",dj,[f("div",uj,[f("div",hj,[f("div",{onClick:t[2]||(t[2]=(...d)=>e.backToMainHamburgerMenu&&e.backToMainHamburgerMenu(...d)),class:"inline-flex cursor-pointer align-items-center gap-2 w-auto"},[f("img",{src:e.imagePath+"images/header/arrow-left.svg",alt:"Left pointing arrow"},null,8,pj),f("p",fj,N(e.t("profile.account")),1)])]),f("div",{onClick:t[3]||(t[3]=d=>e.handleHeaderNavMenuType("")),class:"cursor-pointer"},gj)]),f("div",yj,[f("div",bj,[f("p",vj,N(e.t("profile.greeting",{fname:e.genericSiteMetadata.user.fname,lname:e.genericSiteMetadata.user.lname})),1)]),f("a",{href:e.setDynamicLink()+"/logout",class:"h-color-mako-dark h-font-size-14 h-font-weight-500 border-bottom-1 h-border-color-trout w-fit"},N(e.t("profile.sign-out")),9,_j)]),f("div",wj,[(g(!0),S(J,null,ye(e.orderItems,d=>(g(),S("a",{key:d.key,href:e.setDynamicLink()+d.url},[de(a,{label:e.t("profile.sign-in"),class:"button__secondary-kits-v2-nav w-full"},{default:Ee(()=>[f("img",{class:"mr-1",width:"20px",height:"20px",src:`${e.imagePath}${d.icon}`,alt:d.alt},null,8,Sj),ke(" "+N(e.t(d.label)),1)]),_:2},1032,["label"])],8,Ej))),128)),f("div",Cj,[f("p",Ij,N(e.t("profile.account-details")),1),f("a",{href:e.setDynamicLink()+"/customerservice",class:"py-2 h-color-mirage-dark h-font-size-18 h-font-weight-500"},N(e.t("profile.my-profile")),9,Tj),f("a",{href:e.setDynamicLink()+"/query/check_orders?pagename=check_status",class:"py-2 h-color-mirage-dark h-font-size-18 h-font-weight-500"},N(e.t("profile.order-history")),9,Pj),f("a",{href:e.setDynamicLink()+"/upload_rx?pagename=upload_prescrip",class:"py-2 h-color-mirage-dark h-font-size-18 h-font-weight-500"},N(e.t("profile.my-prescription")),9,Oj)]),f("div",Aj,[f("p",kj,N(e.t("profile.trending-products")),1),f("div",Rj,[f("a",{href:e.setDynamicLink()+"/autoship",class:"py-2 h-color-mirage-dark h-font-size-18 h-font-weight-500"},N(e.t("profile.join-autoship")),9,Lj),e.genericSiteMetadata.autoship_status?(g(),S("div",Nj,[f("span",Dj,N(e.t("profile.enrolled")),1)])):M("",!0)]),e.baseDomain==="kits.ca"||e.baseDomain==="kits.com"?(g(),S("div",xj,[f("a",{href:e.setDynamicLink()+"/kits-plus",class:"py-2 h-color-mirage-dark h-font-size-18 h-font-weight-500"},N(e.t("profile.kits-plus")),9,Mj),e.genericSiteMetadata.kits_membership.has_membership?(g(),S("div",Fj,[f("span",Vj,N(e.t("profile.enrolled")),1)])):M("",!0)])):M("",!0)])])])):(g(),S("div",KG,[f("div",GG,[f("div",jG,[f("div",{onClick:t[0]||(t[0]=(...d)=>e.backToMainHamburgerMenu&&e.backToMainHamburgerMenu(...d)),class:"inline-flex cursor-pointer align-items-center gap-2 w-auto"},[f("img",{src:e.imagePath+"images/header/arrow-left.svg",alt:"Left pointing arrow"},null,8,YG),f("p",WG,N(e.t("profile.account")),1)])]),f("div",{onClick:t[1]||(t[1]=d=>e.handleHeaderNavMenuType("")),class:"cursor-pointer"},ZG)]),f("div",qG,[f("div",JG,N(e.t("profile.welcome")),1),f("div",XG,[f("a",{href:e.setDynamicLink()+"/login",class:"w-full"},[de(a,{label:e.t("profile.sign-in"),class:"button__primary-kits-v2-nav w-full"},null,8,["label"])],8,ej),f("a",{href:e.setDynamicLink()+"/new_account",class:"w-full"},[de(a,{label:e.t("profile.register"),class:"button__secondary-kits-v2-nav w-full"},null,8,["label"])],8,tj)]),f("div",nj,[f("p",sj,N(e.t("card-text.program")),1),f("a",{href:e.setDynamicLink()+"/autoship",class:"py-2 h-color-mirage-dark h-font-size-18 h-font-weight-500"},[ke(N(e.t("card-text.subscribe"))+" ",1),e.genericSiteMetadata.autoship_status?(g(),S("div",rj,[f("span",aj,N(e.t("profile.enrolled")),1)])):M("",!0)],8,ij),e.baseDomain==="kits.ca"||e.baseDomain==="kits.com"?(g(),S("a",{key:0,href:e.setDynamicLink()+"/kits-plus",class:"py-2 h-color-mirage-dark h-font-size-18 h-font-weight-500"},[ke(N(e.t("card-text.join-plus"))+" ",1),e.genericSiteMetadata.kits_membership.has_membership?(g(),S("div",lj,[f("span",cj,N(e.t("profile.enrolled")),1)])):M("",!0)],8,oj)):M("",!0)])])]))])])):M("",!0),e.headerNavMenuType==="favorite"?(g(),S("div",Bj,[f("div",$j,[f("div",Uj,[f("div",Hj,[e.baseDomain.includes(".ca")?(g(),S("p",zj,N(e.t("favorite.title-ca")),1)):(g(),S("p",Kj,N(e.t("favorite.title-us")),1)),f("span",Gj," ("+N(e.favItems.length)+" "+N(e.t("favorite.items"))+") ",1)]),f("div",{onClick:t[4]||(t[4]=d=>e.handleHeaderNavMenuType("")),class:"cursor-pointer"},Yj)]),e.favItems.length===0&&e.genericSiteMetadata&&!e.genericSiteMetadata.is_logged_in?(g(),S("div",Wj,[e.baseDomain.includes(".ca")?(g(),S("span",Qj,N(e.t("favorite.add-items-ca")),1)):(g(),S("span",Zj,N(e.t("favorite.add-items-us")),1)),f("div",qj,[f("a",{href:e.setDynamicLink()+"/login"},[de(a,{label:e.t("favorite.sign-in"),class:"button__primary-kits-v2 w-full"},null,8,["label"])],8,Jj),f("a",{href:e.setDynamicLink()+"/new_account"},[de(a,{label:e.t("favorite.register"),class:"button__secondary-kits-v2 w-full"},null,8,["label"])],8,Xj)]),f("div",eY,[f("p",tY,N(e.t("card-text.program")),1),f("a",{href:e.setDynamicLink()+"/autoship",class:"mt-1 h-font-weight-300 h-font-size-16"},[ke(N(e.t("card-text.subscribe"))+" ",1),e.genericSiteMetadata.autoship_status?(g(),S("div",sY,[f("span",iY,N(e.t("profile.enrolled")),1)])):M("",!0)],8,nY),e.baseDomain==="kits.ca"||e.baseDomain==="kits.com"?(g(),S("a",{key:0,href:e.setDynamicLink()+"/kits-plus",class:"mt-1 h-font-weight-300 h-font-size-16"},[ke(N(e.t("card-text.join-plus"))+" ",1),e.genericSiteMetadata.kits_membership.has_membership?(g(),S("div",aY,[f("span",oY,N(e.t("profile.enrolled")),1)])):M("",!0)],8,rY)):M("",!0)])])):M("",!0),e.favItems.length===0&&e.genericSiteMetadata.is_logged_in?(g(),S("div",lY,[e.baseDomain.includes(".ca")?(g(),S("span",cY,N(e.t("favorite.list-empty-ca")),1)):(g(),S("span",dY,N(e.t("favorite.list-empty-us")),1)),f("a",{href:e.setDynamicLink()+"/glasses?filters=%26filter=collections_name_uFilter:+Popular&product_type=Glasses&page=1",class:"gap-2 mt-3"},[de(a,{label:e.t("favorite.shop-bestsellers"),class:"button__primary-kits-v2 w-full"},null,8,["label"])],8,uY)])):M("",!0),f("div",hY,[e.favItems.length>0?(g(),S("div",pY,[(g(!0),S(J,null,ye(e.favItems,(d,u)=>(g(),S("div",{class:"favorite-item my-3 flex align-items-start justify-content-between",key:u},[f("a",{href:e.createItemLink(d),class:"flex align-items-center gap-3"},[f("img",{src:d.product_image_url,alt:"Product Image",class:"w-full",style:{"max-width":"140px"}},null,8,mY),f("div",gY,[f("p",yY,N(`${d.brand_name}`),1),f("p",{class:"m-0 h-color-gray-tundora h-font-size-16 h-font-weight-400",innerHTML:d.product_name},null,8,bY),f("span",vY,N(e.getReadersTypeLabel(d.readersType)),1),d.product_promo_price?(g(),S("div",_Y,[f("p",wY," $"+N(e.returnPriceWithDecimals(d.product_price+(d.readersType==="progressive-readers"?50:0))),1),f("p",{class:Oe(["mt-1 h-color-primary h-font-weight-500 h-font-size-16",d.product_promo_price?"line-through":""])}," $"+N(e.returnPriceWithDecimals(d.product_promo_price+(d.readersType==="progressive-readers"?50:0))),3)])):(g(),S("div",EY,[f("p",SY," $"+N(e.returnPriceWithDecimals(d.product_price+(d.readersType==="progressive-readers"?50:0))),1)]))])],8,fY),f("button",{class:"cursor-pointer",onClick:p=>e.deleteFavoriteItem(d.product_sku)},[f("img",{class:"vertical-align-middle",src:`${e.imagePath}images/header/delete.svg`,alt:"delete Icon"},null,8,IY)],8,CY)]))),128))])):M("",!0),e.favItems.length>0?(g(),S("div",TY,[f("a",{href:e.setDynamicLink()+"/favorites"},[e.baseDomain.includes(".ca")?(g(),Q(a,{key:0,class:"button__primary-kits-v2 w-full",label:e.t("favorite.view-ca")},null,8,["label"])):(g(),Q(a,{key:1,class:"button__primary-kits-v2 w-full",label:e.t("favorite.view-us")},null,8,["label"]))],8,PY)])):M("",!0)])])])):M("",!0),e.headerNavMenuType==="cart"?(g(),S("div",OY,[f("div",AY,[f("div",kY,[f("div",RY,[f("div",LY,[f("img",{class:"vertical-align-middle",src:`${e.imagePath}images/header/cart_new.svg`,alt:"Cart Icon"},null,8,NY)]),f("div",DY,[f("p",xY,N(e.t("cart.my-bag")),1),f("span",MY," ("+N(e.genericSiteMetadata.side_cart.items.length)+" "+N(e.t("cart.items"))+") ",1)])]),f("div",{onClick:t[5]||(t[5]=d=>e.handleHeaderNavMenuType("")),class:"cursor-pointer"},VY)]),e.genericSiteMetadata.side_cart.items.length===0&&!e.genericSiteMetadata.is_logged_in?(g(),S("div",BY,[f("span",$Y,N(e.t("cart.sign-in")),1
2445),f("div",UY,[f("a",{class:"w-full",href:e.setDynamicLink()+"/login"},[de(a,{label:"Sign in",class:"button__primary-kits-v2 w-full"})],8,HY),f("a",{class:"w-full",href:e.setDynamicLink()+"/new_account"},[de(a,{label:"Register",class:"button__secondary-kits-v2 w-full"})],8,zY)]),f("div",KY,[f("p",GY,N(e.t("card-text.program")),1),f("a",{href:e.setDynamicLink()+"/autoship",class:"mt-1 h-font-weight-300 h-font-size-16"},[ke(N(e.t("card-text.subscribe"))+" ",1),e.genericSiteMetadata.autoship_status?(g(),S("div",YY,[f("span",WY,N(e.t("profile.enrolled")),1)])):M("",!0)],8,jY),e.baseDomain==="kits.ca"||e.baseDomain==="kits.com"?(g(),S("a",{key:0,href:e.setDynamicLink()+"/kits-plus",class:"mt-1 h-font-weight-300 h-font-size-16"},[ke(N(e.t("card-text.join-plus"))+" ",1),e.genericSiteMetadata.kits_membership.has_membership?(g(),S("div",ZY,[f("span",qY,N(e.t("profile.enrolled")),1)])):M("",!0)],8,QY)):M("",!0)])])):M("",!0),e.genericSiteMetadata.side_cart.items.length===0&&e.genericSiteMetadata.is_logged_in?(g(),S("div",JY,[f("span",XY,N(e.t("cart.bag-empty")),1),f("a",{href:e.setDynamicLink()+"/glasses?filters=%26filter=collections_name_uFilter:+Popular&product_type=Glasses&page=1",class:"flex flex-column gap-2 mt-3"},[de(a,{label:e.t("favorite.shop-bestsellers"),class:"button__primary-kits-v2 h-font-weight-300"},null,8,["label"])],8,eW)])):M("",!0),e.genericSiteMetadata.side_cart.items.length>0?(g(),S("div",tW,[f("div",nW,[f("img",{src:`${e.imagePath}images/header/free_shipping.svg`,alt:"Product Image",class:"vertical-align-middle"},null,8,sW),ke(" "+N(e.genericSiteMetadata.shipping_status),1)]),f("div",iW,[(g(!0),S(J,null,ye(e.genericSiteMetadata.side_cart.items,(d,u)=>(g(),S("div",{class:Oe(["list-item mb-5 flex align-items-start justify-content-between",u==0?"mt-4":""]),key:u},[f("a",{href:e.setDynamicLink()+e.createUrlLink(d.link,d==null?void 0:d.glasses_type,d==null?void 0:d.product_group),class:"flex align-items-center gap-3"},[f("img",{src:d.image,alt:"Product Image",class:"w-full",style:{"max-width":"140px"}},null,8,aW),f("div",oW,[f("p",lW,N(d.brand),1),f("p",{class:"m-0 h-color-gray-tundora h-font-size-16 h-font-weight-400",innerHTML:d.name},null,8,cW),f("div",dW,N(e.getReadersTypeLabel(d.glasses_type)),1),f("div",uW,[f("p",{class:Oe(["mt-1 h-color-primary h-font-weight-500 h-font-size-16",d.discount_price?"line-through":""])}," $"+N(e.returnPriceWithDecimals(d.product_price)+" x "+d.quantity),3),d.discount_price?(g(),S("p",hW," $"+N(e.returnPriceWithDecimals(d.discount_price)+" x "+d.quantity),1)):M("",!0)])])],8,rW),f("button",{class:"cursor-pointer",onClick:p=>e.deleteCartItem(d.mv_ip)},[f("img",{class:"vertical-align-middle",src:`${e.imagePath}images/header/delete.svg`,alt:"delete Icon"},null,8,fW)],8,pW)],2))),128))]),f("div",mW,[f("div",gW,[f("div",yW,[f("p",bW,N(e.t("cart.subtotal")),1),f("div",vW,[e.genericSiteMetadata.side_cart.totals.discount?(g(),S("p",_W," $"+N(e.returnPriceWithDecimals(e.genericSiteMetadata.side_cart.totals.subtotal-e.genericSiteMetadata.side_cart.totals.discount)),1)):M("",!0),f("p",{class:Oe(["h-font-size-16 mt-2 mb-3",e.genericSiteMetadata.side_cart.totals.discount?"line-through":""])}," $"+N(e.returnPriceWithDecimals(e.genericSiteMetadata.side_cart.totals.subtotal)),3)])]),f("a",{href:e.setDynamicLink()+"/ord/checkout"},[de(a,{label:e.t("cart.view-cart"),class:"button__primary-kits-v2 mb-3 w-full"},null,8,["label"])],8,wW),f("div",EW,[f("form",{onSubmit:t[7]||(t[7]=st(d=>e.onSubmit(!e.v$.$invalid),["prevent"]))},[de(o,{modelValue:e.v$.coupon.$model,"onUpdate:modelValue":t[6]||(t[6]=d=>e.v$.coupon.$model=d),placeholder:e.t("cart.enter-promo"),class:"w-full inputtext-placeholder uppercase pr-7"},null,8,["modelValue","placeholder"]),f("button",SW,N(e.t("cart.apply-promo")),1)],32),e.isLoadingFetchData?(g(),S("div",CW,[de(l)])):M("",!0)]),!e.genericSiteMetadata.side_cart.discounts.coupon.added&&e.invalidCoupon&&!e.isLoadingFetchData?(g(),S("small",IW,[TW,ke(" "+N(e.invalidCoupon),1)])):M("",!0),e.genericSiteMetadata.side_cart.discounts.coupon.added&&!e.isLoadingFetchData?(g(),S("small",PW,[OW,ke(" "+N(e.genericSiteMetadata.side_cart.discounts.coupon.coupon_description),1)])):M("",!0)])])])):M("",!0)])])):M("",!0),e.headerNavMenuType==="hamburger"?(g(),S("div",AW,[de(c)])):M("",!0)])):M("",!0)}typeof Au=="function"&&Au(Pg);const RW=Ke(Pg,[["render",kW],["__scopeId","data-v-56ab1b40"]]),LW=Ge({components:{NormalHeader:a9,NormalHeaderNew:w5,NormalCarouselHeader:I$,NormalCarouselExpanded:Ig,HeaderSearchResults:s7,NormalHeaderPanelExpand:qV,HeaderMenuExpanded:RW},setup(){vt(()=>{u(),document.body.addEventListener("click",m),document.body.addEventListener("click",v),yl()}),cn(()=>{document.body.removeEventListener("click",m),document.body.removeEventListener("click",v)});const e=ie(),t=se(),n=ht(t),i=On(),{imagePath:r}=Be().public,s=ee(()=>e.systemStore.getHeaderNavType),a=ee(()=>e.systemStore.getHeaderNavMenuType),o=ee(()=>e.systemStore.getHeaderInformation),l=ee(()=>e.systemStore.getGenericSiteMetadata),c=ee(()=>e.systemStore.getDisplayHeaderSearch),d=ee(()=>e.systemStore.getDisplayHeaderSearchMenu),u=()=>{e.systemStore.setHeaderInformation(n)},p=_=>{e.systemStore.setHeaderNavType(_)},h=_=>{e.systemStore.setHeaderNavMenuType(_)},m=()=>{event.target.classList.contains("body-backdrop")&&(e.systemStore.setHeaderNavMenuType(""),e.systemStore.setHamburgerMenuType(""))},v=_=>{_.target.classList.contains("header-search-results-freespace")&&e.systemStore.closeSearchBar()};return We([a,s],(_,b)=>{_[0]!==""||_[1]!==""?document.body.classList.add("body-backdrop"):document.body.classList.remove("body-backdrop")},{immediate:!0}),{headerInformation:o,headerNavType:s,headerNavMenuType:a,handleHeaderNavType:p,handleHeaderNavMenuType:h,setDynamicLink:Ae,displaySearch:c,genericSiteMetadata:l,imagePath:r,displaySearchMenu:d,cleanSearch:v,route:i}}}),NW={id:"header-new",class:"header absolute md:fixed w-full h-bg-white top-0"},DW={class:"absolute right-0 bg-white header-panel-overflow md:box-sha
2445dow w-full md:w-23rem md:mr-3 border-round-bottom",style:{"z-index":"400"}};function xW(e,t,n,i,r,s){const a=le("NormalCarouselHeader"),o=le("NormalCarouselExpanded"),l=le("NormalHeaderNew"),c=le("NormalHeaderPanelExpand"),d=le("HeaderMenuExpanded"),u=le("HeaderSearchResults");return g(),S("div",NW,[e.route.path!=="/optician-ai"?(g(),S("div",{key:0,onMouseover:t[0]||(t[0]=p=>e.handleHeaderNavType("")),class:"header-promotion site-stripe"},[(e.headerInformation.type,g(),Q(a,{key:0})),f("div",DW,[e.headerNavMenuType==="help"?(g(),Q(o,{key:0})):M("",!0)])],32)):M("",!0),f("div",null,[(e.headerInformation.type,g(),Q(l,{key:0}))]),f("div",{onMouseleave:t[1]||(t[1]=p=>e.handleHeaderNavType("")),class:"absolute right-0 left-0 bg-white header-panel-overflow"},[(e.headerInformation.type,g(),Q(c,{key:0}))],32),e.headerNavMenuType!==""?(g(),Q(d,{key:1,class:"absolute top-0 w-screen h-screen md:h-auto md:w-auto md:right-0 md:top-auto"})):M("",!0),e.displaySearchMenu?(g(),Q(u,{key:2})):M("",!0)])}const Og=Ke(LW,[["render",xW],["__scopeId","data-v-80058f32"]]);function ku(e){const t=e;t.__i18n=t.__i18n||[],t.__i18n.push({locale:"",resource:{en:{footer:{"stay-in-know":{t:0,b:{t:2,i:[{t:3}],s:"Stay in the know"}},"new-arrivals":{t:0,b:{t:2,i:[{t:3}],s:"New arrivals, exclusive offers, and more"}},"email-placeholder":{t:0,b:{t:2,i:[{t:3}],s:"Email"}},"invalid-email":{t:0,b:{t:2,i:[{t:3}],s:"*Valid email is required:"}},products:{t:0,b:{t:2,i:[{t:3}],s:"Products"}},eyeglasses:{t:0,b:{t:2,i:[{t:3}],s:"Eyeglasses"}},sunglasses:{t:0,b:{t:2,i:[{t:3}],s:"Sunglasses"}},readers:{t:0,b:{t:2,i:[{t:3}],s:"Readers"}},progressives:{t:0,b:{t:2,i:[{t:3}],s:"Progressives"}},designer:{t:0,b:{t:2,i:[{t:3}],s:"Designer"}},contacts:{t:0,b:{t:2,i:[{t:3}],s:"Contacts"}},accessories:{t:0,b:{t:2,i:[{t:3}],s:"Accessories"}},"gift-cards":{t:0,b:{t:2,i:[{t:3}],s:"Gift Cards"}},"blue-light":{t:0,b:{t:2,i:[{t:3}],s:"Blue Light Glasses"}},"kids-glasses":{t:0,b:{t:2,i:[{t:3}],s:"Kids Glasses"}},"polarized-lenses":{t:0,b:{t:2,i:[{t:3}],s:"Polarized Lenses"}},help:{t:0,b:{t:2,i:[{t:3}],s:"Help"}},"customer-care":{t:0,b:{t:2,i:[{t:3}],s:"Customer Care"}},shipping:{t:0,b:{t:2,i:[{t:3}],s:"Shipping"}},returns:{t:0,b:{t:2,i:[{t:3}],s:"Return Policy"}},faqs:{t:0,b:{t:2,i:[{t:3}],s:"FAQs"}},guides:{t:0,b:{t:2,i:[{t:3}],s:"Guides"}},"sales-and-deals":{t:0,b:{t:2,i:[{t:3}],s:"Sales & Deals"}},insurance:{t:0,b:{t:2,i:[{t:3}],s:"Using Insurance"}},"how-to-buy-glasses":{t:0,b:{t:2,i:[{t:3}],s:"How to Buy Glasses Online"}},"face-shape":{t:0,b:{t:2,i:[{t:3}],s:"Shop by Face Shape"}},"eye-care":{t:0,b:{t:2,i:[{t:3}],s:"Care for Your Eyes"}},"pd-tool":{t:0,b:{t:2,i:[{t:3}],s:"Pupillary Distance (PD)"}},"black-friday-summer-sale":{t:0,b:{t:2,i:[{t:3}],s:"Black Friday Summer Sale"}},"about-us":{t:0,b:{t:2,i:[{t:3}],s:"About Us"}},"our-story":{t:0,b:{t:2,i:[{t:3}],s:"Our Story"}},flagship:{t:0,b:{t:2,i:[{t:3}],s:"Find a store"}},"our-programs":{t:0,b:{t:2,i:[{t:3}],s:"Our Programs"}},"kits-plus":{t:0,b:{t:2,i:[{t:3}],s:"KITS+ Membership"}},"share-a-pair":{t:0,b:{t:2,i:[{t:3}],s:"Share a Pair"}},"first-pair-free":{t:0,b:{t:2,i:[{t:3}],s:"First Pair Free"}},"contact-us":{t:0,b:{t:2,i:[{t:3}],s:"Contact Us"}},"kits-eyecare":{t:0,b:{t:2,i:[{t:3}],s:"KITS Eyecare"}},"order-status":{t:0,b:{t:2,i:[{t:3}],s:"Order Status"}},"investor-relations":{t:0,b:{t:2,i:[{t:3}],s:"Investor Relations"}}},form:{"email-required":{t:0,b:{t:2,i:[{t:3}],s:"Email is required"}},"email-invalid":{t:0,b:{t:2,i:[{t:3}],s:"Email is invalid"}}}}}})}const Ag=Ge({setup(){vt(()=>{});const e=se(),t=ht(e),{t:n}=rt({useScope:"local"}),i=ie(),{imagePath:r}=Be().public,s=ee(()=>i.systemStore.getGenericSiteMetadata),a=[{title:"products",mobile:!0,links:[{content:"eyeglasses",url:"/glasses"},{content:"sunglasses",url:"/sunglasses"},{content:"readers",url:"/glasses/readers"},{content:"progressives",url:"/glasses?filters=%26filter=features_uFilter:+Progressive+Eligible&product_type=Glasses"},{content:"designer",url:"/glasses?filters=%26filter=collections_name_uFilter:+Designer&product_type=Glasses"},{content:"contacts",url:"/contacts"},{content:"accessories",url:"/accessories",domain:"kits.ca"},{content:"accessories",url:"/accessories",domain:"contactsexpress.ca"},{content:"gift-cards",url:t==="kits.ca"?"/deals/VCGCKCA250":"/deals/VCGCK250"},{content:"blue-light",url:"/blue_light_lenses"},{content:"kids-glasses",url:"/glasses?filters=%26filter=gender_uFilter:+Kids&product_type=Glasses"},{content:"polarized-lenses",url:"/includes-polarized-lenses"}]},{title:"guides",links:[{content:"insurance",url:"/insurance"},{content:"how-to-buy-glasses",url:"/how_to_buy_glasses_online"},{content:"face-shape",url:"/face_shape_guide"},{content:"eye-care",url:"/eye-care"},{content:"pd-tool",url:"/pd-tool"},{content:"sales-and-deals",url:"/sales-and-deals"},{content:"black-friday-summer-sale",url:"/black-friday-summer-sale"}]},{title:"help",links:[{content:"customer-care",url:"/contactus"},{content:"shipping",url:"/shipping"},{content:"returns",url:"/returnpolicy"},{content:"faqs",url:"/faq"},{content:"order-status",url:"/order-status"}]},{title:"about-us",links:[{content:"our-story",url:"/aboutus"},{content:"flagship",url:"/stores"},{content:"investor-relations",url:"https://ir.kits.com"},{content:"our-programs",url:"/our-programs"},{content:"kits-plus",url:"/kits-plus"},{content:"share-a-pair",url:"/share-a-pair"},{content:"first-pair-free",url:"/collection-first-pair-free",domain:"kits.ca"}]}],o=[{icon:"pi-facebook",url:"https://www.facebook.com/kitseyecare/"},{icon:"pi-instagram",url:"https://www.instagram.com/kitseyecare/?hl=en"},{icon:"pi-pinterest",url:"https://ca.pinterest.com/kitseyecare/"},{icon:"pi-twitter",url:"https://x.com/kitseyecare"},{icon:"pi-tiktok",url:"https://www.tiktok.com/@kitseyecare?lang=en"}],l=Re(!1),c=Re({email:""}),d={email:{required:wi.withMessage("*Email is required",Ei),email:Fl}},u=oa(d,c);return{t:n,imagePath:r,setDynamicLink:Ae,linkList:a,socialLinks:o,genericSiteMetadata:s,submitted:l,formFields:c,v$:u,onSubmitSubscribe:async h=>{if(l.value=!0,!h){c.value.email==""?i.systemStore.addToastMessage("ERROR",n("form.email-required")):i.systemStore.addToastMessage("ERROR",n("form.email-invalid"));return}try{await i.systemStore.subscribeUserToNewsletter({email:c.value.email})&&(l.value=!1,c.value={email:""})}catch(m){console.error(m)}},baseDomain:t}}}),MW={class:"h-bg-primary pb-6 px-3 lg:px-0 flex flex-column align-items-center justify-content-center h-color-white"},FW={class:"px-5 md:p-0 w-full footer-wrapper footer-wrapper__normal"},VW={class:"h-font-size-24 sm:h-font-size-32 lg:h-font-size-40 h-font-weight-400 w-full lg:px-0 line-height-3"},BW=f("br",null,null,-1),$W=f("br",null,null,-1),UW={class:"relative w-full sm:w-25rem"},HW=f("i",{class:"pi pi-arrow-right cursor-pointer h-font-size-12 absolute top-50 right-0 mr-3 md:mr-2",style:{transform:"translateY(-50%)"}},null,-1),zW=[HW],KW={key:0,class:"p-error mt-2 w-22rem"},GW={class:"hidden lg:flex footer-wrapper footer-wrapper__normal m-0 w-full grid flex-nowrap border-top-1"},jW={class:"h-font-weight-700 h-font-size-14 normal-link-subtitle-desktop"},YW={class:"flex flex-column"},WW={key:0,class:"h-font-weight-700 h-font-size-14 mt-2 normal-link-subtitle-desktop"},QW=["href"],ZW={class:"col normal-col-desktop ml-3"},qW={class:"h-font-weight-500 h-font-size-14 normal-link-subtitle-desktop"},JW={class:"flex flex-column"},XW=["href"],eQ=["href"],tQ=["href"],nQ={class:"flex mt-3"},sQ=["href"],iQ={class:"mt-6 block lg:hidden w-full h-bg-primary footer-accordion"},rQ={class:"flex flex-column -mt-3"},aQ=["href"],oQ={class:"flex flex-column mt-3"},lQ=["href"],cQ=["href"],dQ=["href"],uQ=["href"],hQ=["href"],pQ={class:"flex flex-column mt-3"},fQ=["href"],mQ={class:"flex flex-column mt-3"},gQ=["href"],yQ={class:"flex flex-column mt-3"},bQ=["href"],vQ=["href"],_Q={class:"flex flex-column"},wQ=["href"],EQ={class:"flex flex-column mt-3"},SQ=["href"],CQ=["href"],IQ=["href"],TQ={class:"flex mt-3"},PQ=["href"],OQ={class:"px-4 footer-wrapper mt-4"},AQ=["src"];function kQ(e,t,n,i,r,s){const a=le("InputText"),o=le("AccordionTab"),l=le("Accordion");return g(),S("div",MW,[f("div",FW,[f("div",VW,[ke(N(e.t("footer.stay-in-know"))+" ",1),BW,ke(" "+N(e.t("footer.new-arrivals"))+" ",1),$W]),f("form",{class:"mt-4 flex flex-column sm:align-items-start align-items-center",onSubmit:t[2]||(t[2]=st(c=>
2445e.onSubmitSubscribe(!e.v$.$invalid),["prevent"]))},[f("div",UW,[de(a,{id:"yourEmail",class:"w-full sm:w-25rem h-color-white pr-5 h-border-color-white h-font-weight-300 border-round footer-email-input",style:{"background-color":"#ffffff0d","box-shadow":"none !important"},placeholder:e.t("footer.email-placeholder"),maxlength:60,modelValue:e.v$.email.$model,"onUpdate:modelValue":t[0]||(t[0]=c=>e.v$.email.$model=c)},null,8,["placeholder","modelValue"]),f("div",{onClick:t[1]||(t[1]=st(c=>e.onSubmitSubscribe(!e.v$.$invalid),["prevent"]))},zW)]),e.v$.email.email.$invalid&&e.submitted||e.v$.email.$pending.$response?(g(),S("small",KW,N(e.t("footer.invalid-email"))+" [email protected] ",1)):M("",!0)],32)]),f("div",GW,[(g(!0),S(J,null,ye(e.linkList,(c,d)=>(g(),S("div",{key:d,class:Oe(["col normal-col-desktop",{"ml-3":d>0}])},[f("div",jW,N(e.t(`footer.${c.title}`)),1),f("div",YW,[(g(!0),S(J,null,ye(c.links,u=>(g(),S(J,{key:u.content},[u.content==="our-programs"||u.content==="sales-and-deals"?(g(),S("div",WW,N(e.t(`footer.${u.content}`)),1)):!u.domain||e.baseDomain===u.domain?(g(),S("a",{key:1,href:e.setDynamicLink()+u.url,class:"normal-link-desktop h-color-white hover:text-white h-font-weight-400 h-font-size-14"},N(e.t(`footer.${u.content}`)),9,QW)):M("",!0)],64))),128))])],2))),128)),f("div",ZW,[f("div",qW,N(e.t("footer.contact-us")),1),f("div",JW,[f("a",{href:e.setDynamicLink()+"/contactus",class:"normal-link-desktop h-color-white h-font-weight-400 h-font-size-14"},N(e.t("footer.kits-eyecare")),9,XW),f("a",{href:e.setDynamicLink()+"/contactus",class:"normal-link-desktop h-color-white h-font-weight-400 h-font-size-14"},N(e.genericSiteMetadata.phone_support),9,eQ),f("a",{href:e.setDynamicLink()+"/contactus",class:"normal-link-desktop h-color-white h-font-weight-400 h-font-size-14"},N(e.genericSiteMetadata.email_support),9,tQ)]),f("div",nQ,[(g(!0),S(J,null,ye(e.socialLinks,c=>(g(),S("a",{key:c.icon,href:c.url,target:"_blank",class:"text-100 hover:text-white mr-2"},[f("i",{class:Oe(`pi ${c.icon}`)},null,2)],8,sQ))),128))])])]),f("div",iQ,[de(l,{multiple:!0,"expand-icon":"pi pi-chevron-down","collapse-icon":"pi pi-chevron-up"},{default:Ee(()=>[(g(!0),S(J,null,ye(e.linkList.filter(c=>c.mobile),c=>(g(),Q(o,{key:c.title,header:e.t(`footer.${c.title}`)},{default:Ee(()=>[f("div",rQ,[(g(!0),S(J,null,ye(c.links,d=>(g(),S(J,{key:d.content},[!d.domain||e.baseDomain===d.domain?(g(),S("a",{key:0,href:e.setDynamicLink()+d.url,class:"mt-3 text-300 h-font-weight-400 h-font-size-14"},N(e.t(`footer.${d.content}`)),9,aQ)):M("",!0)],64))),128))])]),_:2},1032,["header"]))),128)),de(o,{header:e.t("footer.guides")},{default:Ee(()=>[f("div",oQ,[f("a",{href:e.setDynamicLink()+e.linkList[1].links[0].url,class:"normal-link-desktop h-color-white hover:text-white h-font-weight-400 h-font-size-14"},N(e.t(`footer.${e.linkList[1].links[0].content}`)),9,lQ),f("a",{href:e.setDynamicLink()+e.linkList[1].links[1].url,class:"normal-link-desktop h-color-white hover:text-white h-font-weight-400 h-font-size-14"},N(e.t(`footer.${e.linkList[1].links[1].content}`)),9,cQ),f("a",{href:e.setDynamicLink()+e.linkList[1].links[2].url,class:"normal-link-desktop h-color-white hover:text-white h-font-weight-400 h-font-size-14"},N(e.t(`footer.${e.linkList[1].links[2].content}`)),9,dQ),f("a",{href:e.setDynamicLink()+e.linkList[1].links[3].url,class:"normal-link-desktop h-color-white hover:text-white h-font-weight-400 h-font-size-14"},N(e.t(`footer.${e.linkList[1].links[3].content}`)),9,uQ),f("a",{href:e.setDynamicLink()+e.linkList[1].links[4].url,class:"normal-link-desktop h-color-white hover:text-white h-font-weight-400 h-font-size-14"},N(e.t(`footer.${e.linkList[1].links[4].content}`)),9,hQ)])]),_:1},8,["header"]),de(o,{header:e.t("footer.sales-and-deals")},{default:Ee(()=>[f("div",pQ,[f("a",{href:e.setDynamicLink()+e.linkList[1].links[6].url,class:"normal-link-desktop h-color-white hover:text-white h-font-weight-400 h-font-size-14"},N(e.t(`footer.${e.linkList[1].links[6].content}`)),9,fQ)])]),_:1},8,["header"]),de(o,{header:e.t("footer.help")},{default:Ee(()=>[f("div",mQ,[(g(!0),S(J,null,ye(e.linkList[2].links,c=>(g(),S("a",{key:c.content,href:e.setDynamicLink()+c.url,class:"normal-link-desktop h-color-white hover:text-white h-font-weight-400 h-font-size-14"},N(e.t(`footer.${c.content}`)),9,gQ))),128))])]),_:1},8,["header"]),de(o,{header:e.t("footer.about-us")},{default:Ee(()=>[f("div",yQ,[f("a",{href:e.setDynamicLink()+e.linkList[3].links[0].url,class:"normal-link-desktop h-color-white hover:text-white h-font-weight-400 h-font-size-14"},N(e.t(`footer.${e.linkList[3].links[0].content}`)),9,bQ)]),f("a",{href:e.setDynamicLink()+e.linkList[3].links[1].url,class:"normal-link-desktop h-color-white hover:text-white h-font-weight-400 h-font-size-14 block"},N(e.t(`footer.${e.linkList[3].links[1].content}`)),9,vQ),f("div",_Q,[f("a",{href:e.setDynamicLink()+e.linkList[3].links[2].url,class:"normal-link-desktop h-color-white hover:text-white h-font-weight-400 h-font-size-14"},N(e.t(`footer.${e.linkList[3].links[2].content}`)),9,wQ)])]),_:1},8,["header"]),de(o,{header:e.t("footer.our-programs")},{default:Ee(()=>[f("div",EQ,[f("a",{href:e.setDynamicLink()+e.linkList[3].links[3].url,class:"normal-link-desktop h-color-white hover:text-white h-font-weight-400 h-font-size-14"},N(e.t(`footer.${e.linkList[3].links[3].content}`)),9,SQ),f("a",{href:e.setDynamicLink()+e.linkList[3].links[4].url,class:"normal-link-desktop h-color-white hover:text-white h-font-weight-400 h-font-size-14"},N(e.t(`footer.${e.linkList[3].links[4].content}`)),9,CQ),e.baseDomain==="kits.ca"?(g(),S("a",{key:0,href:e.setDynamicLink()+e.linkList[3].links[5].url,class:"normal-link-desktop h-color-white hover:text-white h-font-weight-400 h-font-size-14"},N(e.t(`footer.${e.linkList[3].links[5].content}`)),9,IQ)):M("",!0)])]),_:1},8,["header"]),de(o,{header:e.t("footer.contact-us")},{default:Ee(()=>[f("div",TQ,[(g(!0),S(J,null,ye(e.socialLinks,c=>(g(),S("a",{key:c.icon,href:c.url,target:"_blank"},[f("i",{class:Oe(["text-100 hover:text-white mr-2 h-bg-shark p-3 border-circle",`pi ${c.icon}`])},null,2)],8,PQ))),128))])]),_:1},8,["header"])]),_:1})]),f("div",OQ,[f("img",{src:`${e.imagePath}images/footer/VectorKITS.png`,alt:"Brand Image",class:"img-responsive"},null,8,AQ)])])}typeof ku=="function"&&ku(Ag);const RQ=Ke(Ag,[["render",kQ]]);function Ru(e){const t=e;t.__i18n=t.__i18n||[],t.__i18n.push({locale:"",resource:{en:{"nav-legacy-footer":{terms:{t:0,b:{t:2,i:[{t:3}],s:"Term of Use"}},accessibility:{t:0,b:{t:2,i:[{t:3}],s:"Accessibility"}},privacy:{t:0,b:{t:2,i:[{t:3}],s:"Privacy Policy"}},investor:{t:0,b:{t:2,i:[{t:3}],s:"Investor Relations"}},"canada-en":{t:0,b:{t:2,i:[{t:3}],s:"Canada EN"}},"canada-fr":{t:0,b:{t:2,i:[{t:3}],s:"Canada FR"}},us:{t:0,b:{t:2,i:[{t:3}],s:"US"}}}}}})}const kg=Ge({setup(){const{t:e}=rt();return{termsLinks:[{label:"nav-legacy-footer.terms",url:"/TAC"},{label:"nav-legacy-footer.accessibility",url:"/accessibility"},{label:"nav-legacy-footer.privacy",url:"/privacypolicy"},{label:"nav-legacy-footer.investor",url:"https://ir.kits.com/"}],localeLinks:[{label:"nav-legacy-footer.canada-en",url:"https://www.kits.ca/"},{label:"nav-legacy-footer.canada-fr",url:"https://www.kits.ca/fr_CA"},{label:"nav-legacy-footer.us",url:"https://www.kits.com/"}],t:e,setDynamicLink:Ae}}}),LQ={class:"footer-copyright__wrapper h-bg-ucla-blue h-color-white pt-5 flex justify-content-center"},NQ={class:"footer-wrapper flex flex-column lg:flex-row justify-content-between w-full px-2 px-8"},DQ={class:"flex flex-wrap flex-row align-items-center justify-content-center"},xQ=["href"],MQ=["href"],FQ={key:2,style:{width:"2px",height:"2px"},class:"hidden md:block m-2 border-circle h-bg-white"},VQ={class:"mt-2 lg:mt-0 flex align-items-center mx-auto lg:mx-0"},BQ=["href"],$Q={key:0,class:"mx-3 border-right-1 h-1rem"};function UQ(e,t,n,i,r,s){return g(),S("div",LQ,[f("div",NQ,[f("div",DQ,[(g(!0),S(J,null,ye(e.termsLinks,(a,o)=>(g(),S(J,{key:o},[a.url.includes("https")?(g(),S("a",{key:0,class:"m-2 h-font-size-14 md:h-font-size-16 text-200 h-font-weight-300 border-bottom-1 pb-1 hover:h-color-black",href:a.url},N(e.t(a.label)),9,xQ)):(g(),S("a",{key:1,class:"m-2 h-font-size-14 md:h-font-size-16 text-200 h-font-weight-300 border-bottom-1 pb-1",href:e.setDynamicLink()+a.url},N(e.t(a.label)),9,MQ)),o!==e.termsLinks.length-1?(g(),S("div",FQ)):M("",!0)],64))),128))]),f("div",VQ,[(g(!0),S(J,null,ye(e.localeLinks,(a,o)=>(g(),S(J,{key:o},[f("a",{class:"my-2 h-font-size-14 md:h-font-size-16 text-200 h-font-weight-300 border-bottom-1 pb-1",href:a.url},N(e.t(a.label)),9,BQ),o!==e.localeLinks.length-1?(g(),S("div",$Q)):M("",!0)],64))),128))])])])}typeof Ru=="function"&&Ru(kg);const HQ=Ke(kg,[["render",UQ]]);function Lu(e){const t=e;t.__i18n=t.__i18n||[],t.__i18n.push({locale:"",resource:{en:{footer:{"customer-care":{title:{t:0,b:{t:2,i:[{t:3}],s:"CUSTOMER CARE"}},"privacy-policy":{t:0,b:{t:2,i:[{t:3}],s:"Privacy Policy"}},accessibility:{t:0,b:{t:2,i:[{t:3}],s:"Accessibility"}},"security-policy":{t:0,b:{t:2,i:[{t:3}],s:"Security Policy"}},"care-eyes":{t:0,b:{t:2,i:[{t:3}],s:"Care for your eyes"}},feedback:{t:0,b:{t:2,i:[{t:3}],s:"Feedback"}},shipping:{t:0,b:{t:2,i:[{t:3}],s:"Shipping"}},"return-policy":{t:0,b:{t:2,i:[{t:3}],s:"Return Policy"}},"terms-conditions":{t:0,b:{t:2,i:[{t:3}],s:"Terms and Conditions"}},"order-status":{t:0,b:{t:2,i:[{t:3}],s:"Order Status"}}},"quick-links":{title:{t:0,b:{t:2,i:[{t:3}],s:"QUICK LINKS"}},"how-to-buy":{t:0,b:{t:2,i:[{t:3}],s:"How to Buy Glasses Online"}},"blue-light":{t:0,b:{t:2,i:[{t:3}],s:"Blue Light Lenses"}},"face-guide":{t:0,b:{t:2,i:[{t:3}],s:"Face Shape Guide"}},eyeglasses:{t:0,b:{t:2,i:[{t:3}],s:"Eyeglasses"}},sunglasses:{t:0,b:{t:2,i:[{t:3}],s:"Sunglasses"}},readers:{t:0,b:{t:2,i:[{t:3}],s:"Readers"}},"polarized-lenses":{t:0,b:{t:2,i:[{t:3}],s:"Polarized Lenses"}},"contacts-lenses":{t:0,b:{t:2,i:[{t:3}],s:"Contact Lenses"}},deals:{t:0,b:{t:2,i:[{t:3}],s:"Gift Cards"}},"complete-saved-order":{t:0,b:{t:2,i:[{t:3}],s:"Complete Saved Order"}},"about-us":{t:0,b:{t:2,i:[{t:3}],s:"About Us"}},"contact-us":{t:0,b:{t:2,i:[{t:3}],s:"Contact Us"}},faq:{t:0,b:{t:2,i:[{t:3}],s:"FAQ"}},"vision-test":{t:0,b:{t:2,i:[{t:3}],s:"Online Vision Test"}},"place-reorder":{t:0,b:{t:2,i:[{t:3}],s:"Place a Reorder"}}},"shop-with-confidence":{title:{t:0,b:{t:2,i:[{t:3}],s:"SHOP WITH CONFIDENCE"}},description:{t:0,b:{t:2,i:[{t:3}],s:" guarantees the lowest possible price on your contact lenses. On top of low prices, you will receive world class customer service and super fast shipping."}}}}}}})}const zQ={class:"pt-4 pb-6 flex align-items-center justify-content-center"},KQ={class:"col-12 md:col mt-3"},GQ={key:0}
2445,jQ=["src"],YQ={key:0,class:"mt-4"},WQ={href:"/contactus",class:"h-font-weight-400 footer-legacy-link hover:text-gray-900"},QQ=["innerHTML"],ZQ={key:1,class:"mt-4"},qQ=["href"],JQ={class:"col-12 md:col mt-3"},XQ={class:"h-font-weight-600 footer-legacy-link-subtitle"},eZ={class:"flex flex-column"},tZ=["href"],nZ=["src"],sZ={class:"ml-2"},iZ={class:"col-12 md:col mt-4 sm:mt-3"},rZ={class:"h-font-weight-600 footer-legacy-link-subtitle"},aZ={class:"flex flex-column"},oZ=["href"],lZ=["src"],cZ={class:"ml-2"},dZ={class:"col-12 md:col-4 mt-3 h-font-weight-400 footer-legacy-link"},uZ={class:"h-font-weight-600 footer-legacy-link-subtitle"},hZ={class:"line-height-3 mb-3"},pZ={class:"capitalize"},fZ={key:0},mZ={class:"flex align-items-center mt-5"},gZ=["src"],yZ={class:"grid mt-5"},bZ={class:"col-6"},vZ=["src"],_Z={class:"col-6"},wZ=["src"],EZ={key:1},SZ={class:"flex align-items-center mt-5"},CZ=["src"],IZ={class:"relative z-1 text-left mt-4"},TZ={key:2},PZ={class:"flex align-items-center mt-5"},OZ=["src"],AZ={class:"grid mt-4"},kZ={class:"col-6"},RZ={class:"flex flex-column"},LZ=f("a",{href:"https://www.resellerratings.com/store/Contactsexpress_ca",target:"_blank"},[f("img",{class:"w-full",style:{"max-width":"140px"},src:"//seals.resellerratings.com/seal.php?seller=28192",alt:"reseller ratings"})],-1),NZ=["src"],DZ={class:"col-6"},xZ=["src"],Rg={__name:"LegacyFooter",setup(e){const{t}=rt({useScope:"local"}),{imagePath:n}=Be().public,i=ht(se()),r=ee(()=>{const u=c.filter(v=>!v.isPostalContacts||i!=="postalcontacts.com"),p=u.find(v=>v.url==="/accessibility"),h=u.filter(v=>v.url!=="/accessibility"),m=[h[0]];return p&&m.push(p),m.push(...h.slice(1)),m}),s=ee(()=>d.filter(u=>!u.domain||u.domain===i)),a=()=>{window.open("https://seals.resellerratings.com/landing.php?seller=28192","name","height=760,width=780,scrollbars=1")},o=()=>{alert("Copying Prohibited by Law")},l=[{name:"postalcontacts.com",logo:"images/header/postal_contacts_logo.svg",logoWidth:"200px",address:"1120 Yew Ave <br /> Blaine, WA 98320",contact:[{type:"phone",value:"1-833-487-5487",icon:"pi-phone",link:"/contactus"},{type:"email",value:"[email protected]",icon:"pi-envelope",link:"/contactus"}]},{name:"opticontacts.com",logo:"images/header/opti-logo-2.svg",logoWidth:"140px",contact:[{type:"phone",value:"1866-982-5367",icon:"pi-phone",link:"/contactus"},{type:"email",value:"[email protected]",icon:"pi-envelope",link:"/contactus"}]},{name:"contactsexpress.ca",logo:"images/header/contacts-express-logo.svg",logoWidth:"220px",address:"510 Seymour St <br /> Vancouver, BC V6B 3J5",contact:[{type:"phone",value:"1-833-487-5487",icon:"pi-phone",link:"/contactus"},{type:"email",value:"[email protected]",icon:"pi-envelope",link:"/contactus"}]}],c=[{url:"/privacypolicy",content:"footer.customer-care.privacy-policy"},{url:"/accessibility",content:"footer.customer-care.accessibility",isPostalContacts:!0},{url:"/securitypolicy",content:"footer.customer-care.security-policy"},{url:"/eye-care",content:"footer.customer-care.care-eyes"},{url:"/contactus",content:"footer.customer-care.feedback"},{url:"/shipping",content:"footer.customer-care.shipping"},{url:"/returnpolicy",content:"footer.customer-care.return-policy"},{url:"/TAC",content:"footer.customer-care.terms-conditions"},{url:"/order-status",content:"footer.customer-care.order-status"}],d=[{url:"/how_to_buy_glasses_online",content:"footer.quick-links.how-to-buy"},{url:"/blue_light_lenses",content:"footer.quick-links.blue-light",domain:"postalcontacts.com"},{url:"/face_shape_guide",content:"footer.quick-links.face-guide"},{url:"/glasses",content:"footer.quick-links.eyeglasses"},{url:"/sunglasses",content:"footer.quick-links.sunglasses"},{url:"/glasses/readers",content:"footer.quick-links.readers"},{url:"/includes-polarized-lenses",content:"footer.quick-links.polarized-lenses"},{url:"/product_listing",content:"footer.quick-links.contacts-lenses"},{url:"/deals/VCGCPC250",content:"footer.quick-links.deals",domain:"postalcontacts.com"},{url:"/complete_quote",content:"footer.quick-links.complete-saved-order",domain:"postalcontacts.com"},{url:"/saved_carts",content:"footer.quick-links.place-reorder"},{url:"/aboutus",content:"footer.quick-links.about-us"},{url:"/contactus",content:"footer.quick-links.contact-us"},{url:"/faq",content:"footer.quick-links.faq"},{url:"/onlinevisiontest",content:"footer.quick-links.vision-test",domain:"opticontacts.com"}];return(u,p)=>(g(),S("div",zQ,[f("div",{class:Oe(["p-3 footer-wrapper w-full grid h-font-size-14",k(i)==="contactsexpress.ca"?"footer-wrapper__legacy-contactsexpress px-5 sm:px-8 lg:px-1":"footer-wrapper__legacy px-1 sm:px-2 lg:px-1"])},[f("div",KQ,[(g(),S(J,null,ye(l,(h,m)=>f("div",{key:m}
2445,[k(i)===h.name?(g(),S("div",GQ,[f("img",{src:`${k(n)}${h.logo}`,alt:"logo",style:cs({width:h.logoWidth})},null,12,jQ),h.address?(g(),S("div",YQ,[f("a",WQ,[f("span",{innerHTML:h.address},null,8,QQ)])])):M("",!0),h.contact?(g(),S("div",ZQ,[(g(!0),S(J,null,ye(h.contact,v=>(g(),S("div",{key:v.type},[f("a",{class:"h-font-weight-400 footer-legacy-link hover:text-gray-900 line-height-3",href:k(Ae)()+v.link},[f("i",{class:Oe(`pi ${v.icon} mr-1`)},null,2),ke(N(v.value),1)],8,qQ)]))),128))])):M("",!0)])):M("",!0)])),64))]),f("div",JQ,[f("div",XQ,N(k(t)("footer.customer-care.title")),1),f("div",eZ,[(g(!0),S(J,null,ye(k(r),h=>(g(),S("a",{key:h.content,href:k(Ae)()+h.url,class:"flex align-items-center mb-2 h-font-weight-400 footer-legacy-link hover:text-gray-900"},[f("img",{src:`${k(n)}images/widget-link.webp`,alt:"widget link"},null,8,nZ),f("span",sZ,N(k(t)(h.content)),1)],8,tZ))),128))])]),f("div",iZ,[f("div",rZ,N(k(t)("footer.quick-links.title")),1),f("div",aZ,[(g(!0),S(J,null,ye(k(s),h=>(g(),S("a",{key:h.content,href:k(Ae)()+h.url,class:"flex align-items-center mb-2 h-font-weight-400 footer-legacy-link hover:text-gray-900"},[f("img",{src:`${k(n)}images/widget-link.webp`,alt:"widget link"},null,8,lZ),f("span",cZ,N(k(t)(h.content)),1)],8,oZ))),128))])]),f("div",dZ,[f("div",uZ,N(k(t)("footer.shop-with-confidence.title")),1),f("div",hZ,[f("span",pZ,N(k(i)),1),ke(" "+N(k(t)("footer.shop-with-confidence.description")),1)]),k(i)==="postalcontacts.com"?(g(),S("div",fZ,[f("div",mZ,[f("img",{width:"24px",src:`${k(n)}images/flag_USD.png`,alt:"country flag",class:"mr-3"},null,8,gZ),ke(" All prices are in USD ")]),f("div",yZ,[f("div",bZ,[f("img",{class:"w-full",style:{"max-width":"140px"},src:`${k(n)}images/credit_cards_logo.webp`,alt:"credit cards logo"},null,8,vZ)]),f("div",_Z,[f("img",{class:"w-full",style:{"max-width":"140px"},src:`${k(n)}images/secure_check.webp`,alt:"secure check"},null,8,wZ)])])])):M("",!0),k(i)==="opticontacts.com"?(g(),S("div",EZ,[f("div",SZ,[f("img",{width:"24px",src:`${k(n)}images/flag_USD.png`,alt:"country flag",class:"mr-3"},null,8,CZ),ke(" All prices are in USD ")]),f("div",IZ,[f("a",{href:"https://www.resellerratings.com",onClick:st(a,["prevent"])},[f("img",{src:"//seals.resellerratings.com/seal.php?seller=28192",onContextmenu:st(o,["prevent"])},null,32)])])])):M("",!0),k(i)==="contactsexpress.ca"?(g(),S("div",TZ,[f("div",PZ,[f("img",{width:"24px",src:`${k(n)}images/flag_CAD.webp`,alt:"country flag",class:"mr-3"},null,8,OZ),ke(" All prices are in CAD ")]),f("div",AZ,[f("div",kZ,[f("div",RZ,[LZ,f("img",{class:"w-full",style:{"max-width":"140px"},src:`${k(n)}images/secure_check.webp`,alt:"secure check"},null,8,NZ)])]),f("div",DZ,[f("img",{class:"w-full",style:{"max-width":"140px"},src:`${k(n)}images/credit_cards_logo.webp`,alt:"credit cards logo"},null,8,xZ)])])])):M("",!0)])],2)]))}};typeof Lu=="function"&&Lu(Rg);function Nu(e){const t=e;t.__i18n=t.__i18n||[],t.__i18n.push({locale:"",resource:{en:{footer:{copyright:{t:0,b:{t:2,i:[{t:3,v:"Copyright © "},{t:4,k:"year"},{t:3,v:" All Rights Reserved"}]}},links:{"terms-of-use":{t:0,b:{t:2,i:[{t:3}],s:"Term of Use"}},accessibility:{t:0,b:{t:2,i:[{t:3}],s:"Accessibility"}},"privacy-policy":{t:0,b:{t:2,i:[{t:3}],s:"Privacy Policy"}},"investor-relations":{t:0,b:{t:2,i:[{t:3}],s:"Investor Relations"}}}}}}})}const Lg=Ge({setup(){const{t:e}=rt({useScope:"local"}),t=se(),n=ht(t);return{t:e,getActiveDomain:se,baseDomain:n}}}),MZ={class:"legacy-copyright__wrapper h-bg-gainsboro flex align-items-center flex-column h-font-size-14 text-gray-700 h-font-weight-100"},FZ={class:"mb-2 text-left footer-legacy-link h-font-weight-300"},VZ={class:"flex flex-wrap flex-row align-items-center footer-legacy-link"},BZ={class:"hover:text-gray-900 footer-legacy-link-border border-bottom-1 pb-1 mb-0 mt-2 h-font-weight-300",href:"/TAC"},$Z={key:0,style:{width:"2px",height:"2px"},class:"block mx-3 border-circle h-bg-black"},UZ={key:1,class:"hover:text-gray-900 footer-legacy-link-border border-bottom-1 pb-1 mb-0 mt-2 h-font-weight-300",href:"/accessibility"},HZ=f("div",{style:{width:"2px",height:"2px"},class:"block mx-3 border-circle h-bg-black"},null,-1),zZ={class:"hover:text-gray-900 footer-legacy-link-border border-bottom-1 pb-1 mb-0 mt-2 h-font-weight-300",href:"/privacypolicy"},KZ={key:2,style:{width:"2px",height:"2px"},class:"block mx-3 border-circle h-bg-black"},GZ={key:3,class:"hover:text-gray-900 footer-legacy-link-border border-bottom-1 pb-1 mb-0 mt-2 h-font-weight-300",href:"https://ir.kits.com/"};function jZ(e,t,n,i,r,s){return g(),S("div",MZ,[f("div",{class:Oe(["footer-wrapper w-full",e.baseDomain==="contactsexpress.ca"?"footer-wrapper__legacy-contactsexpress px-2 sm:px-6 lg:px-1 pt-5 lg:pt-4 pb-8 lg:pb-6":"footer-wrapper__legacy px-3 lg:px-1 pt-5 lg:pt-4 pb-8 lg:pb-7"])},[f("div",FZ,N(e.t("footer.copyright",{year:new Date().getFullYear()})),1),f("div",VZ,[f("a",BZ,N(e.t("footer.links.terms-of-use")),1),e.baseDomain!=="postalcontacts.com"?(g(),S("div",$Z)):M("",!0),e.baseDomain!=="postalcontacts.com"?(g(),S("a",UZ,N(e.t("footer.links.accessibility")),1)):M("",!0),HZ,f("a",zZ,N(e.t("footer.links.privacy-policy")),1),e.baseDomain!=="postalcontacts.com"?(g(),S("div",KZ)):M("",!0),e.baseDomain!=="postalcontacts.com"?(g(),S("a",GZ,N(e.t("footer.links.investor-relations")),1)):M("",!0)])],2)])}typeof Nu=="function"&&Nu(Lg);const YZ=Ke(Lg,[["render",jZ]]);function Du(e){const t=e;t.__i18n=t.__i18n||[],t.__i18n.push({locale:"",resource:{en:{subscribe:{postalcontacts:{title:{t:0,b:{t:2,i:[{t:3}],s:"THE BEST DEALS ARE ON EMAIL."}}},default:{title:{t:0,b:{t:2,i:[{t:3}],s:"Subscribe to our mailing list for insider news, product launches, and more!"}}},"email-placeholder":{t:0,b:{t:2,i:[{t:3}],s:"Enter your email"}},submit:{t:0,b:{t:2,i:[{t:3}],s:"SUBMIT"}},subscribe:{t:0,b:{t:2,i:[{t:3}],s:"Subscribe"}},error:{required:{t:0,b:{t:2,i:[{t:3}],s:"Email is required."}},invalid:{t:0,b:{t:2,i:[{t:3}
2445],s:"Email is not valid."}}}}}}})}const Ng=Ge({setup(){const{t:e}=rt({useScope:"local"}),t=ie(),n=se(),i=ht(n),r=Re(!1),s=Re({email:""}),a={email:{required:wi.withMessage("*Email is required",Ei),email:Fl}},o=oa(a,s);return{t:e,getActiveDomain:se,baseDomain:i,formFields:s,v$:o,onSubmitSubscribe:async c=>{if(r.value=!0,!c){s.value.email==""?t.systemStore.addToastMessage("ERROR",e("subscribe.error.required")):t.systemStore.addToastMessage("ERROR",e("subscribe.error.invalid"));return}try{await t.systemStore.subscribeUserToNewsletter({email:s.value.email})&&(r.value=!1,s.value={email:""})}catch(d){console.error(d)}}}}}),WZ={class:"mr-0 lg:mr-3 mb-3 lg:mb-0 footer-subscribe-postalcontacts h-font-weight-600"},QZ={class:"mt-3 mb-5 px-2 h-font-size-20 h-font-weight-400 text-center text-white"};function ZZ(e,t,n,i,r,s){const a=le("InputText"),o=le("Button");return g(),S("div",{class:Oe(["flex flex-column align-items-center justify-content-center",e.baseDomain==="postalcontacts.com"?"h-bg-anti-flash-white":"h-bg-cornflower-blue"]),style:cs(e.baseDomain==="postalcontacts.com"?"padding: 15px 0;":"padding: 20px 0;")},[e.baseDomain==="postalcontacts.com"?(g(),S("form",{key:0,class:"flex flex-column lg:flex-row align-items-center",onSubmit:t[2]||(t[2]=st(l=>e.onSubmitSubscribe(!e.v$.$invalid),["prevent"]))},[f("div",WZ,N(e.t("subscribe.postalcontacts.title")),1),f("div",null,[de(a,{id:"yourEmail",class:"w-11rem py-2 h-border-color-scarpa-flow border-noround mr-2",placeholder:e.t("subscribe.email-placeholder"),maxlength:60,modelValue:e.v$.email.$model,"onUpdate:modelValue":t[0]||(t[0]=l=>e.v$.email.$model=l)},null,8,["placeholder","modelValue"]),de(o,{class:"w-7rem py-2 cursor-pointer h-bg-cornflower-blue hover:bg-gray-700 border-round-sm h-font-weight-600",onClick:t[1]||(t[1]=st(l=>e.onSubmitSubscribe(!e.v$.$invalid),["prevent"]))},{default:Ee(()=>[ke(N(e.t("subscribe.submit")),1)]),_:1})])],32)):(g(),S("form",{key:1,class:"flex flex-column align-items-center",onSubmit:t[5]||(t[5]=st(l=>e.onSubmitSubscribe(!e.v$.$invalid),["prevent"]))},[f("div",QZ,N(e.t("subscribe.default.title")),1),f("div",null,[de(a,{id:"yourEmail",class:"w-12rem sm:w-18rem h-font-size-14 py-2 border-transparent mr-2",placeholder:e.t("subscribe.email-placeholder"),maxlength:60,modelValue:e.v$.email.$model,"onUpdate:modelValue":t[3]||(t[3]=l=>e.v$.email.$model=l)},null,8,["placeholder","modelValue"]),de(o,{class:"w-7rem sm:w-7rem h-font-size-14 border-round-md h-font-weight-700 py-2 cursor-pointer border-noround h-bg-white h-bg-cornflower-blue-hover text-gray-700 hover:text-white hover:border-white",onClick:t[4]||(t[4]=st(l=>e.onSubmitSubscribe(!e.v$.$invalid),["prevent"]))},{default:Ee(()=>[ke(N(e.t("subscribe.subscribe")),1)]),_:1})])],32))],6)}typeof Du=="function"&&Du(Ng);const qZ=Ke(Ng,[["render",ZZ]]),JZ=Ge({components:{NormalFooter:RQ,LegacyFooter:Rg,NormalFooterCopyright:HQ,LegacyFooterCopyright:YZ,LegacyFooterSubscribe:qZ},setup(){vt(()=>{r()}),ie();const e=se(),t=ht(e),n=Re({logo:"",type:""}),i={"kits.ca":{logo:"kits_logo.svg",type:"normal"},"kits.com":{logo:"kits_logo.svg",type:"normal"},"opticontacts.com":{logo:"opti-logo-2.svg",type:"legacy"},"contactsexpress.ca":{logo:"contacts-express-logo.svg",type:"legacy"},"postalcontacts.com":{logo:"postal_contacts_logo.svg",type:"legacy"}},r=()=>{n.value=i[t]||{logo:"kits_logo.svg",type:"normal"}};return{footerInformation:n}}}),XZ={class:"w-full pdp-footer relative",style:{"z-index":"10"}};function eq(e,t,n,i,r,s){const a=le("NormalFooter"),o=le("NormalFooterCopyright"),l=le("LegacyFooterSubscribe"),c=le("LegacyFooter"),d=le("LegacyFooterCopyright");return g(),S("div",XZ,[e.footerInformation.type==="normal"?(g(),Q(a,{key:0})):M("",!0),e.footerInformation.type==="normal"?(g(),Q(o,{key:1})):M("",!0),e.footerInformation.type==="legacy"?(g(),Q(l,{key:2})):M("",!0),e.footerInformation.type==="legacy"?(g(),Q(c,{key:3})):M("",!0),e.footerInformation.type==="legacy"?(g(),Q(d,{key:4})):M("",!0)])}const Dg=Ke(JZ,[["render",eq]]),tq={class:"p-3"},nq={class:"flex flex-column align-items-center gap-3 text-center"},sq=f("i",{class:"pi pi-exclamation-triangle h-color-warning h-font-size-32"},null,-1),iq={class:"h-font-size-20 h-font-weight-600 h-color-mirage-dark"},rq={class:"h-font-size-16 h-font-weight-400 h-color-trout"},aq={class:"flex flex-row gap-2 mt-4"},oq={__name:"SimpleDialog",setup(e){const t=ie(),n=ee(()=>t.systemStore.getConfirmDialog),i=()=>
2445t.systemStore.resolveConfirm(!0),r=()=>t.systemStore.resolveConfirm(!1);return(s,a)=>{const o=le("Button");return g(),S("div",tq,[f("div",nq,[sq,f("div",iq,N(k(n).title),1),f("div",rq,N(k(n).message),1)]),f("div",aq,[de(o,{label:"No",onClick:r,class:"button__secondary-kits w-full"}),de(o,{label:"Yes",onClick:i,class:"button__secondary-kits w-full"})])])}}},lq={class:"flex flex-column align-items-start gap-2"},cq={class:"flex flex-row justify-content-between w-full px-4 mt-4"},dq=["src"],uq=["src"],hq={class:"h-font-size-20 h-font-weight-600 h-color-mirage-dark mx-4 mt-2"},pq={class:"h-font-size-16 h-font-weight-400 h-color-trout mx-4"},fq={class:"flex flex-column gap-2 pt-4 border-top-1 h-border-color-iron-dark p-4 pt-5 mt-4"},mq={__name:"LensFlowDialog",setup(e){const t=ie(),{imagePath:n}=Be().public,i=ee(()=>t.systemStore.getConfirmDialog),r=()=>{i.value.onBottomButtonClick&&i.value.onBottomButtonClick(),t.systemStore.resolveConfirm(!0)},s=()=>{i.value.onTopButtonClick&&i.value.onTopButtonClick(),t.systemStore.resolveConfirm(!1)},a=()=>{i.value.onSkipButtonClick&&i.value.onSkipButtonClick(),t.systemStore.resolveConfirm(!1)};return(o,l)=>{const c=le("Button");return g(),S(J,null,[f("div",lq,[f("div",cq,[k(i).iconType?(g(),S("div",{key:0,class:Oe(["flex align-items-center justify-content-center border-circle mt-2",k(i).iconType==="warning"?"h-bg-beeswax-dark":"h-bg-provincial-pink-dark"]),style:{width:"48px",height:"48px"}},[f("img",{src:k(i).iconType==="warning"?k(n)+"icons/alert-circle-orange.svg":k(n)+"icons/alert-circle-red.svg",alt:"alert-circle"},null,8,dq)],2)):M("",!0),f("button",{onClick:s,class:"align-self-start"},[f("img",{src:k(n)+"icons/x-close.svg",alt:"alert-circle"},null,8,uq)])]),f("div",hq,N(k(i).title),1),f("div",pq,N(k(i).message),1)]),f("div",fq,[de(c,{label:k(i).topButtonText,onClick:s,class:"button__primary-kits w-full"},null,8,["label"]),k(i).bottomButtonText?(g(),Q(c,{key:0,label:k(i).bottomButtonText,onClick:r,class:"button__secondary-kits w-full"},null,8,["label"])):M("",!0)]),k(i).showSkip?(g(),S("button",{key:0,onClick:a,class:"h-font-size-14 w-full text-center h-font-weight-500 h-color-mako-dark mb-4 text-center underline"}," Skip and send later ")):M("",!0)],64)}}},gq={__name:"ConfirmDialog",setup(e){const t=ie(),n=ee(()=>t.systemStore.getConfirmDialog),i=ee(()=>t.glassesStore.getLensFlowActive),r=ee(()=>i.value&&n.value.topButtonText?mq:oq),s=a=>{a||t.systemStore.resolveConfirm(!1)};return(a,o)=>{const l=le("Dialog");return g(),Q(l,{visible:k(n).isVisible,"onUpdate:visible":[o[0]||(o[0]=c=>k(n).isVisible=c),s],modal:"",position:"center",class:"confirm-dialog__container h-bg-white border-round-2xl",pt:{mask:{style:"backdrop-filter: blur(3px); "},content:{style:"max-width: 500px"}},showHeader:!1,dismissableMask:!0},{default:Ee(()=>[(g(),Q(_e(k(r))))]),_:1},8,["visible"])}}},yq=Ge({components:{Header:Og,Footer:Dg,ConfirmDialog:gq},setup(){vt(async()=>{it.set("glasses-flow-progressive-calculation","true",{expires:1}),t.systemStore.setShouldShowAnagram(!0),t.contactsStore.fetchDiscounts(),H4(),await t.systemStore.fetchGenericSiteMetadata(),qp({app_id:"r60ufm3m"}),i=new MutationObserver(()=>{if(document.querySelector(".intercom-lightweight-app")||document.querySelector(".intercom-app")){i.disconnect();const c=document.getElementById("vtoApp");c&&(r=new MutationObserver(()=>o()),r.observe(c,{childList:!0,subtree:!0})),o()}}),i.observe(document.body,{childList:!0,subtree:!0});try{dataLayer.push({internalSessionID:it.get("ga_internal_session")})}catch{console.log("Datalayer not found: Setting InternalSessionID",{internalSessionID:it.get("ga_internal_session")})}BC(),e.query.link_coupon&&sessionStorage.setItem("link_coupon",e.query.link_coupon),e.query.autoship_action&&sessionStorage.setItem("autoship_action",e.query.autoship_action)}),cn(()=>{i.disconnect(),r==null||r.disconnect()});const e=On(),t=ie(),{imagePath:n}=Be().public;let i=null,r=null;const s=ee(()=>t.glassesStore.getLensFlowActive),a=ee(()=>t.opticianStore.getIsOpticianWidgetOpen);FI(It().pathname)?Me({meta:[{name:"robots",content:"noindex, nofollow"}]}):U4(),Me({script:[{src:"https://cdn.shopify.com/shopifycloud/shop-js/shop-pay-payment-request.js",async:!0}]}
2445),Me({script:[{src:"https://maps.googleapis.com/maps/api/js?key=AIzaSyCRXeR7xYLXoiZ9_brOBwhZ7f-u84-TKto&libraries=places",async:!0}]}),Me({script:[{src:"https://pay.google.com/gp/p/js/pay.js"}]}),se().includes("kits.ca")&&(Me({link:[{rel:"icon",href:`${n}kits.png`}],style:[{children:".anti-flicker, .anti-flicker * {visibility: hidden !important; opacity: 0 !important;}",type:"text/css"}],script:[{children:"var monetateT = new Date().getTime();",type:"text/javascript"},{src:se().includes(".camp.")?"//se.monetate.net/js/2/a-507d68b4/d/camp.kits.ca/entry.js":"//se.monetate.net/js/2/a-507d68b4/p/kits.ca/entry.js",type:"text/javascript"},{id:"aimerce-trackjs",src:"https://cdn.aimerce.ai/a.browser.shopify.umd.js?domain=kits.ca"},{src:"https://cdn.kustomerapp.com/chat-web/widget.js",body:!0,"data-kustomer-api-key":"eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpZCI6IjYyMWY2MGYxMTFjYjQ2ZWNhMzI2NGFmZSIsInVzZXIiOiI2MjFmNjBmMGNlZDk5NmUxNzAyMjRkODUiLCJvcmciOiI2MWQ0NmU2OTE0NmZmMTBkMmZkOTA3NGQiLCJvcmdOYW1lIjoia2l0cyIsInVzZXJUeXBlIjoibWFjaGluZSIsInBvZCI6InByb2QxIiwicm9sZXMiOlsib3JnLnRyYWNraW5nIl0sImF1ZCI6InVybjpjb25zdW1lciIsImlzcyI6InVybjphcGkiLCJzdWIiOiI2MjFmNjBmMGNlZDk5NmUxNzAyMjRkODUifQ.zW2nTO6lHIEg36qpfV-J3TZFE3uHn_Hi8JKj0udMnSw"},{src:"https://libraries.unbxdapi.com/sdk-clients/ss-unbxd-gcp-kits-ca-prod16621689373059/ua/ua.js"},{src:"https://cdn.kustomerapp.com/chat-web/release-v0.1.388/widget-api.4d7cc3374fe1c283f6b6.js"}]}),It().href.includes("fr_CA")&&Me({script:[{src:"https://www.onelink-edge.com/moxie/3.1.1/moxie.min.js","data-oljs":"P91C9-A27F-29D5-0E90",integrity:"sha256-jdIJmrfCTc68JlOWPTmIxasTw6cZ2CMq9F3Kdc0jM6s=",crossorigin:"anonymous"}]})),se().includes("kits.com")&&Me({link:[{rel:"icon",href:`${n}kits.png`}],style:[{children:".anti-flicker, .anti-flicker * {visibility: hidden !important; opacity: 0 !important;}",type:"text/css"}],script:[{children:"var monetateT = new Date().getTime();",type:"text/javascript"},{src:se().includes(".camp.")?"//se.monetate.net/js/2/a-507d68b4/d/camp.kits.com/entry.js":"//se.monetate.net/js/2/a-507d68b4/p/kits.com/entry.js",type:"text/javascript"},{src:"https://cdn.kustomerapp.com/chat-web/widget.js",body:!0,"data-kustomer-api-key":"eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpZCI6IjYyMWY2MGYxMTFjYjQ2ZWNhMzI2NGFmZSIsInVzZXIiOiI2MjFmNjBmMGNlZDk5NmUxNzAyMjRkODUiLCJvcmciOiI2MWQ0NmU2OTE0NmZmMTBkMmZkOTA3NGQiLCJvcmdOYW1lIjoia2l0cyIsInVzZXJUeXBlIjoibWFjaGluZSIsInBvZCI6InByb2QxIiwicm9sZXMiOlsib3JnLnRyYWNraW5nIl0sImF1ZCI6InVybjpjb25zdW1lciIsImlzcyI6InVybjphcGkiLCJzdWIiOiI2MjFmNjBmMGNlZDk5NmUxNzAyMjRkODUifQ.zW2nTO6lHIEg36qpfV-J3TZFE3uHn_Hi8JKj0udMnSw"},{src:"https://libraries.unbxdapi.com/sdk-clients/ss-unbxd-gcp-kits-com-prod16621689373955/ua/ua.js"}]}),se().includes("opticontacts")&&Me({link:[{rel:"icon",href:`${n}opticontacts.png`}],style:[{children:".anti-flicker, .anti-flicker * {visibility: hidden !important; opacity: 0 !important;}",type:"text/css"}],script:[{children:"var monetateT = new Date().getTime();",type:"text/javascript"},{src:se().includes(".camp.")?"//se.monetate.net/js/2/a-507d68b4/d/camp.opticontacts.com/entry.js":"//se.monetate.net/js/2/a-507d68b4/p/opticontacts.com/entry.js",type:"text/javascript"},{src:"https://cdn.kustomerapp.com/chat-web/widget.js",body:!0,"data-kustomer-api-key":"eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpZCI6IjYyMWY2MTU4OWIxMzg5ZWExZmJkZWUyZSIsInVzZXIiOiI2MjFmNjE1N2VkMmVjODAwMDQwNmJjNmMiLCJvcmciOiI2MWQ0NmU2OTE0NmZmMTBkMmZkOTA3NGQiLCJvcmdOYW1lIjoia2l0cyIsInVzZXJUeXBlIjoibWFjaGluZSIsInBvZCI6InByb2QxIiwicm9sZXMiOlsib3JnLnRyYWNraW5nIl0sImF1ZCI6InVybjpjb25zdW1lciIsImlzcyI6InVybjphcGkiLCJzdWIiOiI2MjFmNjE1N2VkMmVjODAwMDQwNmJjNmMifQ.IElwh4wDveNDwzEMHVwiLOZOTv006EaJE-XoTyzkKE0"},{src:"https://libraries.unbxdapi.com/sdk-clients/ss-unbxd-gcp-opticontacts-prod16621689373264/ua/ua.js"},{src:"https://cdn.kustomerapp.com/chat-web/release-v0.1.388/widget-api.4d7cc3374fe1c283f6b6.js"}]}),se().includes("postalcontacts")&&Me({link:[{rel:"icon",href:`${n}postalcontacts.png`}],script:[{src:"https://cdn.kustomerapp.com/chat-web/widget.js",body:!0,"data-kustomer-api-key":"eyJhbGciOiJub25lIn0.eyJvcmciOiI2MWQ0NmU2OTE0NmZmMTBkMmZkOTA3NGQiLCJvcmdOYW1lIjoia2l0cyIsInBvZCI6InByb2QxIiwicm9sZXMiOlsib3JnLnRyYWNraW5nIl19."}]}),se().includes("contactsexpress")&&Me({link:[{rel:"icon",href:`${n}contactsexpress.png`}],style:[{children:".anti-flicker, .anti-flicker * {visibility: hidden !important; opacity: 0 !important;}",type:"text/css"}],script:[{children:"var monetateT = new Date().getTime();",type:"text/javascript"},{src:se().includes(".camp.")?"//se.monetate.net/js/2/a-507d68b4/d/camp.contactsexpress.ca/entry.js":"//se.monetate.net/js/2/a-507d68b4/p/contactsexpress.ca/entry.js",type:"text/javascript"},{src:"https://cdn.kustomerapp.com/chat-web/widget.js",body:!0,"data-kustomer-api-key":"eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpZCI6IjYyMWY2MTNkZWQ2NjFkNDU1ZmE5MDc2NSIsInVzZXIiOiI2MjFmNjEzYzhmY2Q3YTlhNzQ3ZWVkMTYiLCJvcmciOiI2MWQ0NmU2OTE0NmZmMTBkMmZkOTA3NGQiLCJvcmdOYW1lIjoia2l0cyIsInVzZXJUeXBlIjoibWFjaGluZSIsInBvZCI6InByb2QxIiwicm9sZXMiOlsib3JnLnRyYWNraW5nIl0sImF1ZCI6InVybjpjb25zdW1lciIsImlzcyI6InVybjphcGkiLCJzdWIiOiI2MjFmNjEzYzhmY2Q3YTlhNzQ3ZWVkMTYifQ.vBFnhYead_B40aS7_Dl5kvddn0qIQhBhpbAd_1mXnQk"},{src:"https://libraries.unbxdapi.com/sdk-clients/ss-unbxd-gcp-contactsexpress-ca-prod16621689373366/ua/ua.js"},{src:"https://cdn.kustomerapp.com/chat-web/release-v0.1.388/widget-api.4d7cc3374fe1c283f6b6.js"}]});const o=()=>{const l=document.querySelector(".intercom-lightweight-app")||document.querySelector(".intercom-app"),c=window.innerWidth<=520&&a.value||s.value||!!document.getElementById("vto-type-product");l==null||l.classList.toggle("hide-intercom",c)};return We(a,()=>{o()}),We(s,()=>{o()}),{isLensFlowActive:s,route:e}}}),bq={key:0},vq={class:"p-toast-message-text"},_q={class:"p-toast-summary"},wq=["innerHTML"],Eq={key:1},Sq={class:"p-toast-message-text"},Cq={class:"p-toast-summary"},Iq=["innerHTML"];function Tq(e,t,n,i,r,s){const a=le("Header"),o=Yh,l=k4,c=le("Toast"),d=le("ConfirmDialog"),u=le("Footer");return g(),S("div",null,[e.route.path.includes("widget")?(g(),S("div",Eq,[de(l),de(o,null,{default:Ee(()=>[de(c,null,{message:Ee(({message:p})=>[f("span",{class:Oe(["p-toast-message-icon pi",{"pi-times-circle":p.severity==="error","pi-check":p.severity==="success","pi-exclamation-triangle":p.severity==="warn","pi-info-circle":p.severity==="info"}])},null,2),f("div",Sq,[f("span",Cq,N(p.summary),1),f("div",{class:"p-toast-detail",innerHTML:p.detail},null,8,Iq)])]),_:1}),de(d)]),_:1})])):(g(),S("div",bq,[de(o,null,{default:Ee(()=>[!e.isLensFlowActive&&!["/optician","/optician/,  `/plugins/barco
2445de-scanner`]"].includes(e.route.path)&&!["/optician-vto","/optician-vto/","/plugins/barcode-scanner"].includes(e.route.path)?(g(),Q(a,{key:0})):M("",!0)]),_:1}),de(l),de(o,null,{default:Ee(()=>[de(c,null,{message:Ee(({message:p})=>[f("span",{class:Oe(["p-toast-message-icon pi",{"pi-times-circle":p.severity==="error","pi-check":p.severity==="success","pi-exclamation-triangle":p.severity==="warn","pi-info-circle":p.severity==="info"}])},null,2),f("div",vq,[f("span",_q,N(p.summary),1),f("div",{class:"p-toast-detail",innerHTML:p.detail},null,8,wq)])]),_:1})]),_:1}),de(o,null,{default:Ee(()=>[de(d)]),_:1}),de(o,null,{default:Ee(()=>[!e.isLensFlowActive&&!["/optician","/optician/","/plugins/barcode-scanner"].includes(e.route.path)&&!["/optician-vto","/optician-vto/","/plugins/barcode-scanner"].includes(e.route.path)?(g(),Q(u,{key:0})):M("",!0)]),_:1})]))])}const Pq=Ke(yq,[["render",Tq]]);function xu(e){const t=e;t.__i18n=t.__i18n||[],t.__i18n.push({locale:"",resource:{en:{heading:{t:0,b:{t:2,i:[{t:3}],s:"Explore our best sellers"}},"view-more":{t:0,b:{t:2,i:[{t:3}],s:"View more"}},categories:[{t:0,b:{t:2,i:[{t:3}],s:"Eyeglasses"}},{t:0,b:{t:2,i:[{t:3}],s:"Sunglasses"}},{t:0,b:{t:2,i:[{t:3}],s:"Designer"}},{t:0,b:{t:2,i:[{t:3}],s:"Contacts"}}]}}})}const xg=Ge({setup(){const{t:e}=rt({useScope:"local"}),t=ie(),{imagePath:n}=Be().public,i=Re("/glasses"),r=Re("glasses");t.systemStore.fetchNewGlassesBestSellers(),t.systemStore.fetchNewSunglassesBestSellers(),t.systemStore.fetchNewDesignerBestSellers(),t.systemStore.fetchContactsBestSellers();const s=ee(()=>t.systemStore.getNewGlassesBestSellers),a=ee(()=>t.systemStore.getNewSunglassesBestSellers),o=ee(()=>t.systemStore.getNewDesignerBestSellers),l=ee(()=>t.systemStore.getNewContactsBestSellers),c=[{type:"glasses",label:e("categories[0]")},{type:"sunglasses",label:e("categories[1]")},{type:"designer",label:e("categories[2]")},{type:"contacts",label:e("categories[3]")}],d=ee(()=>[{type:"glasses",items:s.value},{type:"sunglasses",items:a.value},{type:"designer",items:o.value}]),u=C=>`label_generic_color_${(C.generic_color||"").replace(/\s/g,"")}`,p=C=>C==null||C===""?null:Number(C),h=C=>{const O=p(C.price),T=p(C.promo_price),E=p(C.price_1r);return O===null?null:T!==null&&T>O?{sale:O,original:T}:gi.value&&E!==null&&E<O?{sale:E,original:O}:null},m=(C,O)=>{C.currentConfig=O.configuration_id,C.currentImage=O.image,C.currentAlt=O.image_url},v=C=>{switch(r.value=C,kt(()=>{var O;return(O=b.value[C])==null?void 0:O.update()}),C){case"glasses":i.value="/glasses";break;case"sunglasses":i.value="/sunglasses";break;case"designer":i.value="/glasses?filters=%26filter=collections_name_uFilter:+Designer&product_type=Glasses,Sunglasses";break;case"contacts":i.value="/contacts";break}},_=Re({slidesPerGroup:1,slidesPerView:1.75,spaceBetween:20,grabCursor:!0,observer:!0,observeParents:!0,mousewheel:{forceToAxis:!0},breakpoints:{1440:{slidesPerView:4.5},768:{slidesPerView:3.5}}}),b=Re([]);return{t:e,imagePath:n,handleBestSellersType:v,bestSellersType:r,categories:c,glassesGroups:d,setMainSwipers:(C,O)=>{b.value[O]=C},swiperConfig:_,modules:[Wg],setDynamicLink:Ae,bestSellersUrl:i,newGlassesBestSellers:s,newSunglassesBestSellers:a,newDesignerBestSellers:o,newContactsBestSellers:l,handleColorChange:m,swatchColorId:u,saleInfo:h,slugify:$n}}}),Oq={class:"best-sellers h-bg-grey-soltitude py-6 pl-3 md:pl-5"},Aq={class:"mx-auto",style:{"max-width":"1440px"}},kq={class:"h-color-mirage-dark h-font-size-24 md:h-font-size-30 h-font-weight-600 mb-6"},Rq={class:"flex flex-row justify-content-between align-items-center mb-3 gap-3 md:pr-4 pr-3"},Lq={class:"flex flex-row align-items-center gap-4 overflow-x-auto best-sellers__tabs"},Nq=["onClick"],Dq=["href"],xq=["src"],Mq={class:"flex flex-column h-bg-white px-3 pb-2 h-full"},Fq=["href"],Vq=["src","alt"],Bq=["src","alt"],$q={class:"h-color-chinese-black h-font-size-14 h-font-weight-600 best-sellers__name mt-2"},Uq={class:"flex flex-row gap-1 h-font-size-14 mb-2"},Hq={class:"h-color-red h-font-weight-400"},zq={class:"line-through font-light h-color-chinese-black"},Kq={key:1,class:"h-color-ebony-clay-dark h-font-weight-400"},Gq={class:"flex flex-row flex-nowrap overflow-hidden gap-2 mt-auto"},jq=["onClick"],Yq=["id"],Wq=["href"],Qq=["src","alt"],Zq={class:"h-color-chinese-black h-font-size-14 h-font-weight-600 best-sellers__name"},qq={class:"flex flex-row gap-1 h-font-size-14 mt-auto"},Jq={class:"h-color-red h-font-weight-400"},Xq={class:"line-through font-light h-color-chinese-black"},eJ={key:1,class:"h-color-ebony-clay-dark h-font-weight-400"},tJ={class:"flex lg:hidden justify-content-end mt-3 pr-3"},nJ=["href"],sJ=["src"];function iJ(e,t,n,i,r,s){const a=ju,o=Yu,l=Xe("tooltip");return g(),S("section",Oq,[f("div",Aq,[f("div",kq,N(e.t("heading")),1),f("div",Rq,[f("div",Lq,[(g(!0),S(J,null,ye(e.categories,c=>(g(),S("div",{key:c.type,onClick:d=>e.handleBestSellersType(c.type),class:Oe(["h-font-size-16 md:h-font-size-18 cursor-pointer white-space-nowrap pb-2 best-sellers__tab",e.bestSellersType===c.type?"h-color-mirage-dark best-sellers__tab--selected":"h-color-pale-sky"])},N(c.label),11,Nq))),128))]),f("a",{href:e.setDynamicLink()+e.bestSellersUrl,class:"hidden lg:flex align-items-center gap-2 h-font-size-16 h-font-weight-600 h-color-pale-sky no-underline white-space-nowrap"},[ke(N(e.t("view-more"))+" ",1),f("img",{src:e.imagePath+"images/header/arrow-right.svg",width:"15",alt:"","aria-hidden":"true"},null,8,xq)],8,Dq)]),(g(!0),S(J,null,ye(e.glassesGroups,c=>Ne((g(),S("div",{key:c.type},[de(o,R({class:"pb-4 pt-1",ref_for:!0},e.swiperConfig,{modules:e.modules,onSwiper:d=>e.setMainSwipers(d,c.type)}),{default:Ee(()=>[(g(!0),S(J,null,ye(c.items,d=>(g(),Q(a,{key:d.sku,class:"h-auto"},{default:Ee(()=>[f("div",Mq,[f("a",{href:`${e.setDynamicLink()}/glasses/${d.sku}/${e.slugify(d.name)}?config=${d.currentConfig||d.configuration_id}`,class:"block relative best-sellers__frame"},[f("img",{src:d.currentImage||d.image,alt:d.name,class:"img-responsive mt-7 md:mb-0 mb-7 best-sellers__frame-img"},null,8,Vq),d.currentAlt||d.altImage?(g(),S("img",{key:0,src:d.currentAlt||d.altImage,alt:d.name,"aria-hidden":"true",class:"img-responsive mt-7 md:mb-0 mb-7 best-sellers__frame-img best-sellers__frame-img--alt"},null,8,Bq)):M("",!0)],8,Fq),f("div",$q,N(d.displayName||d.name),1),f("div",Uq,[e.saleInfo(d)?(g(),S(J,{key:0},[f("span",Hq,"$"+N(e.saleInfo(d).sale),1),f("span",zq,"$"+N(e.saleInfo(d).original),1)],64)):(g(),S("span",Kq,"$"+N(d.price),1))]),f("div",Gq,[(g(!0),S(J,null,ye(d.variations,u=>Ne((g(),S("div",{key:u.configuration_id,class:Oe(["flex flex-none align-items-center justify-content-center border-circle cursor-pointer best-sellers__swatch",{"best-sellers__swatch--active":(d.currentConfig||d.configuration_id)===u.configuration_id}]),onClick:p=>e.handleColorChange(d,u)},[f("span",{id:e.swatchColorId(u),class:"border-circle best-sellers__swatch-color"},null,8,Yq)],10,jq)),[[l,u.color,void 0,{top:!0}]])),128))])])]),_:2},1024))),128))]),_:2},1040,["modules","onSwiper"])])),[[mt,e.bestSellersType===c.type]]
2445)),128)),Ne(f("div",null,[de(o,R({class:"py-4"},e.swiperConfig,{modules:e.modules,onSwiper:t[0]||(t[0]=c=>e.setMainSwipers(c,"contacts"))}),{default:Ee(()=>[(g(!0),S(J,null,ye(e.newContactsBestSellers,c=>(g(),Q(a,{key:c.sku,class:"h-auto"},{default:Ee(()=>[f("a",{href:`${e.setDynamicLink()}/contact_lenses/${c.sku}/${e.slugify(c.name)}`,class:"flex flex-column h-bg-white h-full p-3 gap-2 no-underline"},[f("img",{src:c.image,alt:c.name,class:"img-responsive py-4"},null,8,Qq),f("div",Zq,N(c.displayName||c.name),1),f("div",qq,[e.saleInfo(c)?(g(),S(J,{key:0},[f("span",Jq,"$"+N(e.saleInfo(c).sale),1),f("span",Xq,"$"+N(e.saleInfo(c).original),1)],64)):(g(),S("span",eJ,"$"+N(c.price),1))])],8,Wq)]),_:2},1024))),128))]),_:1},16,["modules"])],512),[[mt,e.bestSellersType==="contacts"]]),f("div",tJ,[f("a",{href:e.setDynamicLink()+e.bestSellersUrl,class:"flex align-items-center gap-2 h-font-size-14 h-font-weight-600 h-color-pale-sky no-underline"},[ke(N(e.t("view-more"))+" ",1),f("img",{src:e.imagePath+"images/header/arrow-right.svg",width:"15",alt:"","aria-hidden":"true"},null,8,sJ)],8,nJ)])])])}typeof xu=="function"&&xu(xg);const rJ=Ke(xg,[["render",iJ],["__scopeId","data-v-f8e24761"]]);function Mu(e){const t=e;t.__i18n=t.__i18n||[],t.__i18n.push({locale:"",resource:{en:{"error-code":{t:0,b:{t:2,i:[{t:3}],s:"404 ERROR"}},"not-found":{t:0,b:{t:2,i:[{t:3}],s:"Page not found"}},heading:{t:0,b:{t:2,i:[{t:3}],s:"This page doesn't exist."}},subheading:{t:0,b:{t:2,i:[{t:3}],s:"Good news? Everything else you need to see clearly is right this way."}},buttons:[{text:{t:0,b:{t:2,i:[{t:3}],s:"Shop glasses"}},url:{t:0,b:{t:2,i:[{t:3}],s:"/glasses"}}},{text:{t:0,b:{t:2,i:[{t:3}],s:"Shop contacts"}},url:{t:0,b:{t:2,i:[{t:3}],s:"/contacts"}}}],image:{path:{t:0,b:{t:2,i:[{t:4,k:"path"},{t:3,v:"images/404-Oops.jpg"}]}},alt:{t:0,b:{t:2,i:[{t:3}],s:"Not Found Image"}}}}}})}const Mg=Ge({components:{BestSellers:rJ},setup(){const{t:e}=rt({useScope:"local"});ie();const{imagePath:t}=Be().public;return{t:e,imagePath:t,setDynamicLink:Ae}}}),aJ={class:"flex flex-column lg:flex-row justify-content-between mx-auto lg:px-3 px-5 md:pt-0 pt-6",style:{"max-width":"1440px","padding-bottom":"70px"}},oJ={class:"flex flex-column justify-content-center"},lJ={class:"h-color-midnight-cobalt h-font-size-18 lg:h-font-size-20 h-font-weight-500 md:mt-0 mt-4"},cJ={class:"h-color-mirage-dark h-font-size-36 lg:h-font-size-60 h-font-weight-600 md:mb-0 m-0"},dJ={class:"h-color-trout h-font-size-18 lg:h-font-size-20 h-font-weight-400 lg:pr-8 pt-4"},uJ={class:"flex flex-column lg:flex-row gap-3 lg:pb-0 lg:pt-5 pt-5 pb-7"},hJ=["href"],pJ=["href"],fJ=["src","alt"];function mJ(e,t,n,i,r,s){const a=le("BestSellers");return g(),S(J,null,[f("div",aJ,[f("div",oJ,[f("div",lJ,N(e.t("error-code")),1),f("h1",cJ,N(e.t("not-found")),1),f("div",dJ,[f("div",null,N(e.t("heading")),1),f("div",null,N(e.t("subheading")),1)]),f("div",uJ,[f("a",{href:e.setDynamicLink()+e.t("buttons[0].url"),class:"error-button"},N(e.t("buttons[0].text")),9,hJ),f("a",{href:e.setDynamicLink()+e.t("buttons[1].url"),class:"error-button"},N(e.t("buttons[1].text")),9,pJ)])]),f("div",null,[f("img",{src:e.t("image.path",{path:e.imagePath}),alt:e.t("image.alt"),class:"img-responsive desktop-pt-50 pb-6 lg:pb-0"},null,8,fJ)])]),de(a)],64)}typeof Mu=="function"&&Mu(Mg);const gJ=Ke(Mg,[["render",mJ],["__scopeId","data-v-9888d9f7"]]),yJ=Ge({components:{Header:Og,Footer:Dg,NotFound404:gJ},setup(){vt(async()=>{await e.systemStore.fetchGenericSiteMetadata()});const e=ie(),{imagePath:t}=Be().public;return Me({title:"Sorry, the requested page was not found",meta:[{name:"description",content:"Kits Eyewear. Canada's #1 Eyewear Store. High-quality eyewear at affordable prices. All KITS glasses and sunglasses are now available starting at $28."}]}),se().includes("kits.ca")&&Me({link:[{rel:"icon",href:`${t}kits.png`}],style:[{children:".anti-flicker, .anti-flicker * {visibility: hidden !important; opacity: 0 !important;}",type:"text/css"}],script:[{src:"https://cdn.kustomerapp.com/chat-web/widget.js","data-kustomer-api-key":"eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpZCI6IjYyMWY2MGYxMTFjYjQ2ZWNhMzI2NGFmZSIsInVzZXIiOiI2MjFmNjBmMGNlZDk5NmUxNzAyMjRkODUiLCJvcmciOiI2MWQ0NmU2OTE0NmZmMTBkMmZkOTA3NGQiLCJvcmdOYW1lIjoia2l0cyIsInVzZXJUeXBlIjoibWFjaGluZSIsInBvZCI6InByb2QxIiwicm9sZXMiOlsib3JnLnRyYWNraW5nIl0sImF1ZCI6InVybjpjb25zdW1lciIsImlzcyI6InVybjphcGkiLCJzdWIiOiI2MjFmNjBmMGNlZDk5NmUxNzAyMjRkODUifQ.zW2nTO6lHIEg36qpfV-J3TZFE3uHn_Hi8JKj0udMnSw"},{src:"https://libraries.unbxdapi.com/sdk-clients/ss-unbxd-gcp-kits-ca-prod16621689373059/ua/ua.js"}]}),se().includes("kits.com")&&Me({link:[{rel:"icon",href:`${t}kits.png`}],script:[{src:"https://cdn.kustomerapp.com/chat-web/widget.js","data-kustomer-api-key":"eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpZCI6IjYyMWY2MGYxMTFjYjQ2ZWNhMzI2NGFmZSIsInVzZXIiOiI2MjFmNjBmMGNlZDk5NmUxNzAyMjRkODUiLCJvcmciOiI2MWQ0NmU2OTE0NmZmMTBkMmZkOTA3NGQiLCJvcmdOYW1lIjoia2l0cyIsInVzZXJUeXBlIjoibWFjaGluZSIsInBvZCI6InByb2QxIiwicm9sZXMiOlsib3JnLnRyYWNraW5nIl0sImF1ZCI6InVybjpjb25zdW1lciIsImlzcyI6InVybjphcGkiLCJzdWIiOiI2MjFmNjBmMGNlZDk5NmUxNzAyMjRkODUifQ.zW2nTO6lHIEg36qpfV-J3TZFE3uHn_Hi8JKj0udMnSw"},{src:"https://libraries.unbxdapi.com/sdk-clients/ss-unbxd-gcp-kits-com-prod16621689373955/ua/ua.js"}]}),se().includes("opticontacts")&&Me({link:[{rel:"icon",href:`${t}opticontacts.png`}],script:[{src:"https://cdn.kustomerapp.com/chat-web/widget.js","data-kustomer-api-key":"eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpZCI6IjYyMWY2MTU4OWIxMzg5ZWExZmJkZWUyZSIsInVzZXIiOiI2MjFmNjE1N2VkMmVjODAwMDQwNmJjNmMiLCJvcmciOiI2MWQ0NmU2OTE0NmZmMTBkMmZkOTA3NGQiLCJvcmdOYW1lIjoia2l0cyIsInVzZXJUeXBlIjoibWFjaGluZSIsInBvZCI6InByb2QxIiwicm9sZXMiOlsib3JnLnRyYWNraW5nIl0sImF1ZCI6InVybjpjb25zdW1lciIsImlzcyI6InVybjphcGkiLCJzdWIiOiI2MjFmNjE1N2VkMmVjODAwMDQwNmJjNmMifQ.IElwh4wDveNDwzEMHVwiLOZOTv006EaJE-XoTyzkKE0"},{src:"https://libraries.unbxdapi.com/sdk-clients/ss-unbxd-gcp-opticontacts-prod16621689373264/ua/ua.js"}]}),se().includes("postalcontacts")&&Me({link:[{rel:"icon",href:`${t}postalcontacts.png`}],script:[{src:"https://cdn.kustomerapp.com/chat-web/widget.js","data-kustomer-api-key":"eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpZCI6IjYyMWY2MTEzNTFmMjg0OWEzNmU5NGMxMiIsInVzZXIiOiI2MjFmNjExMmZiODQ3MjY2ZDY5YTIwNjgiLCJvcmciOiI2MWQ0NmU2OTE0NmZmMTBkMmZkOTA3NGQiLCJvcmdOYW1lIjoia2l0cyIsInVzZXJUeXBlIjoibWFjaGluZSIsInBvZCI6InByb2QxIiwicm9sZXMiOlsib3JnLnRyYWNraW5nIl0sImF1ZCI6InVybjpjb25zdW1lciIsImlzcyI6InVybjphcGkiLCJzdWIiOiI2MjFmNjExMmZiODQ3MjY2ZDY5YTIwNjgifQ.AJ3nPK8jYU70dTT2A24fDl3o9TjNgfIOSvfDD88LlAo"},{src:"https://libraries.unbxdapi.com/sdk-clients/ss-unbxd-gcp-postalcontacts-prod16621689373314/ua/ua.js"}]}),se().includes("contactsexpress")&&Me({link:[{rel:"icon",href:`${t}contactsexpress.png`}],style:[{children:".anti-flicker, .anti-flicker * {visibility: hidden !important; opacity: 0 !important;}",type:"text/css"}],script:[{src:"https://cdn.kustomerapp.com/chat-web/widget.js","data-kustomer-api-key":"eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpZCI6IjYyMWY2MTNkZWQ2NjFkNDU1ZmE5MDc2NSIsInVzZXIiOiI2MjFmNjEzYzhmY2Q3YTlhNzQ3ZWVkMTYiLCJvcmciOiI2MWQ0NmU2OTE0NmZmMTBkMmZkOTA3NGQiLCJvcmdOYW1lIjoia2l0cyIsInVzZXJUeXBlIjoibWFjaGluZSIsInBvZCI6InByb2QxIiwicm9sZXMiOlsib3JnLnRyYWNraW5nIl0sImF1ZCI6InVybjpjb25zdW1lciIsImlzcyI6InVybjphcGkiLCJzdWIiOiI2MjFmNjEzYzhmY2Q3YTlhNzQ3ZWVkMTYifQ.vBFnhYead_B40aS7_Dl5kvddn0qIQhBhpbAd_1mXnQk"},{src:"https://libraries.unbxdapi.com/sdk-clients/ss-unbxd-gcp-contactsexpress-ca-prod16621689373366/ua/ua.js"}]}),{}}}),bJ={class:"p-toast-message-text"},vJ={class:"p-toast-summary"},_J=["innerHTML"];function wJ(e,t,n,i,r,s){const a=le("Header"),o=le("NotFound404"),l=le("Footer"),c=Yh,d=le("Toast");return g(),S("div",null,[de(c,null,{default:Ee(()=>[de(a),de(o),de(l)]),_:1}),de(c,null,{default:Ee(()=>[de(d,null,{message:Ee(({message:u})=>[f("span",{class:Oe(["p-toast-message-icon pi",{"pi-times-circle":u.severity==="error","pi-check":u.severity==="success","pi-exclamation-triangle":u.severity==="warn","pi-info-circle":u.severity==="info"}])},null,2),f("div",bJ,[f("span",vJ,N(u.summary),1),f("div",{class:"p-toast-detail",innerHTML:u.detail}
2445,null,8,_J)])]),_:1})]),_:1})])}const EJ=Ke(yJ,[["render",wJ]]),Fu={__name:"nuxt-root",setup(e){const t=()=>null,n=ct(),i=n.deferHydration();if(n.isHydrating){const o=n.hooks.hookOnce("app:error",i);dn().beforeEach(o)}const r=!1;Hn(Ar,On()),n.hooks.callHookWith(o=>o.map(l=>l()),"vue:setup");const s=Rr();Qg((o,l,c)=>{if(n.hooks.callHook("vue:error",o,l,c).catch(d=>console.error("[nuxt] Error in `vue:error` hook",d)),Mb(o)&&(o.fatal||o.unhandled))return n.runWithContext(()=>Es(o)),!1});const a=!1;return(o,l)=>(g(),Q(Ku,{onResolve:k(i)},{default:Ee(()=>[k(s)?(g(),Q(k(EJ),{key:0,error:k(s)},null,8,["error"])):k(a)?(g(),Q(k(t),{key:1,context:k(a)},null,8,["context"])):k(r)?(g(),Q(_e(k(r)),{key:2})):(g(),Q(k(Pq),{key:3}))]),_:1},8,["onResolve"]))}};let Vu;{let e;Vu=async function(){var a,o;if(e)return e;const i=!!((a=window.__NUXT__)!=null&&a.serverRendered||((o=document.getElementById("__NUXT_DATA__"))==null?void 0:o.dataset.ssr)==="true")?Zg(Fu):qg(Fu),r=tb({vueApp:i});async function s(l){await r.callHook("app:error",l),r.payload.error=r.payload.error||Ti(l)}i.config.errorHandler=s;try{await sb(r,O4)}catch(l){s(l)}try{await r.hooks.callHook("app:created",i),await r.hooks.callHook("app:beforeMount",i),i.mount(D1),await r.hooks.callHook("app:mounted",i),await kt()}catch(l){s(l)}return i.config.errorHandler===s&&(i.config.errorHandler=void 0),i},e=Vu().catch(t=>{throw console.error("Error while mounting app:",t),t})}export{MC as $,oa as A,Me as B,Jp as C,Zr as D,qr as E,Yv as F,kJ as G,PC as H,eB as I,kC as J,bl as K,rH as L,dn as M,gJ as N,OP as O,fi as P,$n as Q,RJ as R,sX as S,UX as T,OJ as U,xJ as V,TJ as W,PJ as X,AJ as Y,rX as Z,Ke as _,It as a,wX as a$,cX as a0,g2 as a1,_l as a2,_X as a3,Cx as a4,xn as a5,SX as a6,Yt as a7,vX as a8,oX as a9,qT as aA,bX as aB,Na as aC,T$ as aD,PX as aE,OX as aF,AX as aG,WT as aH,YI as aI,Cl as aJ,r2 as aK,LX as aL,ux as aM,tx as aN,JI as aO,yX as aP,mX as aQ,yU as aR,a2 as aS,nT as aT,EX as aU,TX as aV,lf as aW,wl as aX,hX as aY,NX as aZ,ta as a_,it as aa,Eg as ab,aX as ac,CX as ad,jT as ae,RC as af,D6 as ag,DJ as ah,dX as ai,Un as aj,rg as ak,lX as al,zI as am,xl as an,TC as ao,VT as ap,FX as aq,KI as ar,LC as as,Id as at,YX as au,xd as av,$J as aw,gX as ax,kX as ay,RX as az,se as b,XI as b0,eT as b1,pX as b2,jI as b3,ca as b4,fX as b5,IX as b6,GT as b7,Ws as b8,VJ as b9,XJ as bA,qJ as bB,UJ as bC,DX as bD,xX as bE,SI as bF,Pd as bG,HJ as bH,zJ as bI,tX as bJ,ZJ as bK,Yd as bL,MX as bM,nX as bN,JJ as bO,eX as bP,FJ as ba,uX as bb,jX as bc,GX as bd,yl as be,MJ as bf,AC as bg,NJ as bh,Sp as bi,YJ as bj,WJ as bk,kd as bl,BX as bm,$X as bn,jJ as bo,ko as bp,CI as bq,RI as br,QP as bs,ka as bt,AI as bu,Aa as bv,KJ as bw,GJ as bx,QJ as by,Bt as bz,$4 as c,VX as d,ie as e,BJ as f,ht as g,rt as h,LJ as i,Yh as j,On as k,Jr as l,iX as m,Wm as n,HX as o,M4 as p,gi as q,ss as r,Ae as s,gl as t,Be as u,wi as v,Ei as w,zX as x,KX as y,Fl as z};

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.