1import{a as hh}from"./chunk-3XE5HNPJ.js";import{a as Cs,b as gh,c as ys,d as vs}from"./chunk-2CT6XGUG.js";import{a as Kf}from"./chunk-T7GQKILI.js";import{a as rm}from"./chunk-H5J4OWBQ.js";import{a as fh}from"./chunk-5KRFWC2G.js";import{a as Qf}from"./chunk-FBSK2SV2.js";import{a as gs,b as dh,c as Jn,d as mh,e as _s}from"./chunk-7AYE2LUL.js";import{a as uh}from"./chunk-OVX25T2I.js";import{a as Sf}from"./chunk-AOY6ESIO.js";import{a as lh}from"./chunk-PUOBMACD.js";import"./chunk-2R5A6FL5.js";import"./chunk-AJTEUFXG.js";import"./chunk-7TNZTNIS.js";import"./chunk-JQCUBXV6.js";import"./chunk-JBWBJ2B4.js";import"./chunk-D6RHPPC7.js";import{a as Xf,b as Jf}from"./chunk-75I7P5I5.js";import{a as hf,b as vf,c as Za,d as ih}from"./chunk-KK3UJBG6.js";import{b as th}from"./chunk-WWLWJUUC.js";import{a as Yf,i as Zf,j as Ja}from"./chunk-TPJJWLLM.js";import"./chunk-XPCC2AEC.js";import{a as eh}from"./chunk-ATB4UYP4.js";import{a as Mi,b as Dr,c as ec,d as oh,e as tc}from"./chunk-NH76BMX5.js";import{b as sh}from"./chunk-X6BU2E3B.js";import{a as gf,b as xf,c as ah,d as ch,e as ph}from"./chunk-3DUILYZ2.js";import{a as nh,c as rh}from"./chunk-DIUJYOVV.js";import{a as gi,b as _m}from"./chunk-ARHWKCUX.js";import{a as hs,b as Zn,c as Xn}from"./chunk-WEJHOC5S.js";import{j as Au,k as Lu}from"./chunk-EYYH3V35.js";import{a as bf}from"./chunk-ILT2J4ED.js";import"./chunk-3U3RUHF6.js";import{a as qn}from"./chunk-YWNKC6Z2.js";import{a as Wf}from"./chunk-BBY7Z4XN.js";import{b as jf,d as qf}from"./chunk-BFGUQT63.js";import"./chunk-LCJSQW3Y.js";import{M as Lf,h as Pf,i as Mf,j as Ef,l as Df,u as Ff}from"./chunk-DN53PZSF.js";import"./chunk-EKEZHEKC.js";import"./chunk-QNIXKBD3.js";import"./chunk-THHYQEQJ.js";import"./chunk-OFPNA4II.js";import"./chunk-3G34URYB.js";import{a as Vf}from"./chunk-YUZECZ4F.js";import"./chunk-34Q4RQFS.js";import{a as vi,e as $f,g as Bf,h as Uf,i as zf,j as Gf,l as Hf}from"./chunk-IMDXOVWQ.js";import"./chunk-WIBSPPCM.js";import{e as ju,f as Bu,g as tf,h as nf,j as rf,k as of,l as sf,m as af,n as df,o as uf,p as ff}from"./chunk-3MOT2TTE.js";import{a as Hu,b as Ya}from"./chunk-KDSHL5UQ.js";import{b as qi}from"./chunk-Z5IFGQHE.js";import"./chunk-YYA4U5CJ.js";import"./chunk-77JUQVHD.js";import{b as Qu,d as Yu,f as lf}from"./chunk-73KO2E3G.js";import{A as Qa,o as Ka,p as as}from"./chunk-VPNEUWRW.js";import{a as pf}from"./chunk-HZQXAPUI.js";import"./chunk-OM32733U.js";import"./chunk-BCGX2S3W.js";import{a as Ua,b as Ln}from"./chunk-FB3RXB7D.js";import"./chunk-QOIXCD7Y.js";import"./chunk-4PMMTYZN.js";import"./chunk-BNLYJMBU.js";import"./chunk-HV7CAB5F.js";import{d as Nr,e as ss,f as Wu}from"./chunk-ELWJXKH4.js";import{a as Yn}from"./chunk-C66YHVQ5.js";import{j as cf}from"./chunk-IRFZQOWH.js";import"./chunk-X5ZC6EMR.js";import{a as $i}from"./chunk-6QHHSURX.js";import{a as Fn}from"./chunk-PKCDE3Z4.js";import{b as Pt}from"./chunk-CQWWMJD5.js";import"./chunk-UV2ZCROI.js";import"./chunk-BDVA2GPB.js";import{a as gt}from"./chunk-MWWXCM3J.js";import{a as _f}from"./chunk-IMREOZMI.js";import"./chunk-LRWV4YLO.js";import{a as Cf}from"./chunk-LLP4GHEC.js";import{a as rs,b as Kn,c as Qn,e as ds}from"./chunk-YNCXXF72.js";import{a as yf}from"./chunk-XRQEWQB5.js";import"./chunk-KSP3JTWR.js";import"./chunk-CBKCLXCN.js";import{a as Vi}from"./chunk-RJUS6BOZ.js";import"./chunk-SBGOI54C.js";import{b as ls}from"./chunk-FRRZBO73.js";import{a as ef,b as Me}from"./chunk-OA5GKU5O.js";import{a as ht}from"./chunk-MJ4Y67YW.js";import{a as Qe}from"./chunk-LT2NQL6J.js";import{a as Dt}from"./chunk-LGSDJCGQ.js";import{c as us,f as If,j as wf,k as Tf,n as kf,o as Rf,p as Af,q as Xa,r as fs,x as Nf}from"./chunk-KGZUXKHN.js";import"./chunk-PA6VGBJ7.js";import"./chunk-YYPLYDEM.js";import"./chunk-X4SO7FXM.js";import"./chunk-3L62N2GX.js";import"./chunk-37MHNOLO.js";import{b as ft}from"./chunk-MJDNH7QI.js";import{a as Ku}from"./chunk-WIIZ5XVT.js";import"./chunk-ON7NRTQG.js";import{a as Kt,e as At,j as Of}from"./chunk-PX2CFBUF.js";import{a as Nu,b as Du,c as Fu,g as Vn}from"./chunk-TX64DUOP.js";import"./chunk-Y25CNICT.js";import{a as Tu,b as ku,c as Ru,d as es,e as it,f as ts,g as is}from"./chunk-5ETMJ6VZ.js";import{a as Bi,b as Bn,c as _i,e as Vu,h as qu}from"./chunk-HTADUWDO.js";import"./chunk-7BPK4QOM.js";import{b as ja}from"./chunk-2BJPNG3N.js";import{a as Ba,b as Dn}from"./chunk-SCB6RBNV.js";import{a as yi}from"./chunk-XUFA6U7R.js";import{c as ot,d as um,e as fm,f as $a}from"./chunk-23OYWDAP.js";import"./chunk-7NFGL5VA.js";import"./chunk-EWHIIGU2.js";import{a as nt}from"./chunk-5BYY3CUG.js";import{b as hm,d as Bo,e as gm}from"./chunk-L7T3VYHM.js";import{d as Xm,l as za,n as wu}from"./chunk-RXO5FOGF.js";import"./chunk-MKRPQEP7.js";import"./chunk-MXAVAYRT.js";import{a as Jm}from"./chunk-TDUHGQVS.js";import{e as Ym,f as Wo,g as Zm}from"./chunk-I57Q5XCC.js";import{a as xe}from"./chunk-SHD7ZT4O.js";import"./chunk-MNDIYD7B.js";import{Q as Hm,a as de,b as li,c as bl,d as Oa,f as xl,g as cn,h as wa,j as Ta,m as Pn,n as ka,o as fo}from"./chunk-NBYIECIO.js";import{a as bm}from"./chunk-HF6NAPYW.js";import"./chunk-3PGHLUKK.js";import{a as om,b as sm,c as tt,d as am,e as dt,f as Lo,g as jo,h as cm,i as pm,j as lm,k as dm,m as mm,n as $o}from"./chunk-BZRY3WX3.js";import{A as mu,B as uu,C as Hn,D as fu,F as hu,G as gu,H as _u,I as Cu,K as yu,L as vu,M as Su,N as bu,ba as xu,eb as Pu,g as kr,gb as Mu,hb as Eu,ib as Hi,jb as Iu,k as Cm,kb as Ou,l as Uo,m as ym,mb as Qt,n as vm,q as Sm,r as ei,s as eu,w as cu,x as pu,y as Jo,z as Wa}from"./chunk-NGFOYMLE.js";import{k as Zo,l as qa,n as Xo}from"./chunk-BXLI5HAL.js";import{a as lt,c as jn}from"./chunk-FCZ6MCLW.js";import"./chunk-RJOOTOZF.js";import"./chunk-PMDY5XFA.js";import{e as Vo,h as Am}from"./chunk-QMQ54HP6.js";import{E as qo,W as Wm}from"./chunk-44NWIEBJ.js";import{H as au,I as lu,J as du,a as xm,e as Mm,f as Ke,g as Go,h as Tm,i as km,j as Rm,k as Ui,m as Ar}from"./chunk-ABACGHJ4.js";import{b as Fo,c as Wt,d as Tr,e as nm,f as La,g as et}from"./chunk-GDB2PFOH.js";import{a as zm}from"./chunk-IXGEFSMQ.js";import{b as Uu,c as os,d as zu,e as Gu,f as Zu,g as Xu,h as Ju,i as ps}from"./chunk-7XSOZUTK.js";import"./chunk-T2C72SUQ.js";import"./chunk-EMG7GVNH.js";import{d as Wi,f as Ki}from"./chunk-6QDM7Q5V.js";import{a as mf}from"./chunk-XPXABRQ4.js";import{b as $u}from"./chunk-OGG4A2QW.js";import"./chunk-KMH4CD5X.js";import"./chunk-LIWSNI2U.js";
1import{a as Wn}from"./chunk-DAAXSM72.js";import"./chunk-3D57UA43.js";import"./chunk-7FE7YXZN.js";import"./chunk-OMXPTFCM.js";import{a as se}from"./chunk-TPDW35KC.js";import{a as Bm,b as Um}from"./chunk-NZJ33BRL.js";import{a as $n,b as Pm}from"./chunk-TWWRSAAI.js";import"./chunk-PF2HCEW7.js";import"./chunk-MUPHABQG.js";import{a as Vm}from"./chunk-SVYMASPC.js";import{a as qm}from"./chunk-2TZM34WV.js";import{a as Nt,d as Ci}from"./chunk-OQ4Y2D57.js";import{a as Gn}from"./chunk-QSJABKNM.js";import{a as Rr}from"./chunk-6YOKE3XR.js";import{q as Sl,t as Nm,u as $m}from"./chunk-QBKLDZGY.js";import{U as zi,V as Gi}from"./chunk-XI4FVBZT.js";import{b as zn}from"./chunk-IDGFXIUB.js";import{a as Dm,b as Fm}from"./chunk-BEHWAJ2I.js";import"./chunk-2EGFIPKB.js";import"./chunk-DZFR5FMO.js";import{L as ou,M as su,d as Ha,f as nu,u as ru,x as Qo}from"./chunk-XKQLI5KL.js";import{a as Km,c as Qm}from"./chunk-R4ARHUW6.js";import{B as Ko,a as tu,v as ln,w as Ga,y as iu}from"./chunk-BNJC75RQ.js";import{$a as Zd,Ba as Nn,Ea as Kd,Fa as Qd,La as ji,P as jd,V
1a as Yd,W as $d,Z as Fa,_ as Bd,a as Fd,aa as Ud,ab as Xd,b as Ld,ba as zd,bb as Jd,db as wr,eb as em,fb as tm,ga as No,ja as ee,ka as Do,na as Gd,oa as Li,qa as Hd,ra as Vd,sb as im,ta as qd,ua as Wd,wa as An}from"./chunk-BTU2RJ7F.js";import"./chunk-QSKVK5UT.js";import{b as cs,c as ms}from"./chunk-OXWXMYUY.js";import{a as ns,u as Ae}from"./chunk-7NUAVIFX.js";import"./chunk-4MVYGVQH.js";import"./chunk-5USKAXQR.js";import{a as ut}from"./chunk-HTGKFTJD.js";import{a as Un}from"./chunk-WXHOXPNQ.js";import"./chunk-OLA7DPU5.js";import{c as mt,j as Va,l as Yo}from"./chunk-UVPO54ZG.js";import"./chunk-WRVDYOEU.js";import{a as Lm,b as jm}from"./chunk-W4LQNO54.js";import{b as Gm}from"./chunk-GUVLWF6N.js";import{a as je}from"./chunk-YGD5LXH5.js";import{a as Ho}from"./chunk-2L2ZYCSH.js";import{a as zo,b as Em,c as Im,d as Om,e as wm,f as be}from"./chunk-QUDZR5CE.js";import{$a as ye,$b as br,$c as al,A as Tp,Ab as Pi,Ac as T,Ad as _l,Ag as nd,B as kp,Ba as io,Bc as ai,Bd as Cl,Be as Jt,Bg as rd,Bh as bd,Ca as F,Cd as yl,Cg as fi,D as Rp,Da as h,Dd as uo,De as _o,Df as zl,Dg as od,Dh as hi,E as Ap,Ec as ne,Ed as vl,Ee as Er,Eg as sd,F as Jr,Fe as Co,Fg as ad,Fh as xd,Gc as Xe,Gh as Pd,H as j,Ha as no,Hf as Gl,Hg as cd,Hh as Md,Ia as Hp,Ib as S,Ic as nl,Ie as kl,If as Eo,Ig as pd,Ih as Ed,J as Np,Ja as ke,Jb as b,Jc as rl,Je as Rl,Jf as Hl,Jg as ld,K as Ge,Ka as Re,Kb as P,Kc as lo,Kd as Mn,Ke as Al,Kf as ui,Kh as Ro,Lb as B,Lc as Ai,Ld as Pl,Lf as Vl,Lg as dd,Mb as U,Me as K,Mg as wo,Mh as Ao,Na as Le,Nb as He,Ng as To,Ob as Ve,Od as En,Og as md,Oh as Id,P as Dp,Pb as Zp,Ph as Od,Qa as si,Qh as wd,R as z,Ra as ro,Rb as Ce,Rc as bt,Rd as jt,Re as Nl,Rf as ql,Rg as kn,Rh as Td,S as Fp,Sc as ol,Sd as Ni,Sf as Fi,Sg as ud,Sh as kd,T as Lp,Ta as wt,Tb as C,Tc as mo,Td as $t,Te as mi,Tf as Wl,Tg as Rn,Th as Rd,U as X,Ua as oo,Ub as Xp,Ud as di,Uf as Kl,V as jp,Vb as Jp,Vd as kt,Vf as Na,Wa as Vp,Wb as co,Wg as fd,Wh as Ad,X as $p,Xa as Ne,Xc as Ie,Xd as Ml,Xe as Ra,Xh as Nd,Ya as Ea,Yc as qe,Yd as pn,Ye as yo,Yf as Se,Zc as W,Ze as Dl,Zg as hd,_ as Ma,_a as qp,_c as sl,_d as El,_e as Fl,_f as Io,_g as gd,_h as Dd,a as Ee,ac as xr,ad as cl,ag as Ql,ah as _d,b as Pp,ba as rt,bb as Ct,bc as Pr,bd as Vt,bf as vo,c as Zr,cc as Y,cd as ci,ce as In,cf as So,ch as Cd,d as Xr,dc as H,dd as q,de as Il,e as Mp,ea as Bp,eb as Wp,ec as Be,ee as re,ef as Di,eg as Rt,fb as d,fc as le,fe as On,ga as _t,gb as O,gc as el,gd as pl,gf as Ir,gh as yd,ha as eo,he as G,hh as vd,i as Sn,if as Or,ja as Sr,jb as Kp,je as Ol,jf as bo,ka as A,kd as $,kf as Ll,kg as Yl,la as Up,ld as ct,lg as Zl,ma as zp,md as pi,mg as Bt,na as Ot,nb as so,nc as Ia,nf as Je,ng as Xl,o as Ep,ob as bn,od as an,of as xo,og as Oo,p as D,pa as to,pb as Zt,pc as tl,pd as Mr,pe as M,pf as jl,q as sn,qa as fe,qb as Qp,qc as ve,qd as ll,qe as ho,qf as Aa,qg as Da,qh as ko,rc as xn,re as wl,rf as wn,rg as Jl,sa as I,sb as ao,sc as il,sd as dl,sf as Po,t as pe,ta as f,tc as po,td as We,te as Ue,tf as $l,u as Ip,ua as St,ub as v,ud as Et,uf as Bl,uh as xt,v as x,va as u,vb as yt,vd as ml,ve as go,vf as Mo,vh as pt,w as ae,wa as L,wb as l,wd as ul,wf as Tn,x as Op,xb as Tt,xd as fl,xf as qt,xg as ed,xh as Sd,y as wp,ya as Gp,yb as Xt,yd as hl,yf as Ul,yg as td,zb as Yp,zc as w,zd as gl,ze as Tl,zg as id}from"./chunk-ZIECK5QA.js";import{a as R,b as ie,e as xp,k as Fe,l as vr,m as J}from"./chunk-3JMZ37NM.js";function _h(i){return new fe(3e3,!1)}function pv(){return new fe(3100,!1)}function lv(){return new fe(3101,!1)}function dv(i){return new fe(3001,!1)}function mv(i){return new fe(3003,!1)}function uv(i){return new fe(3004,!1)}function fv(i,e){return new fe(3005,!1)}function hv(){return new fe(3006,!1)}function gv(){return new fe(3007,!1)}function _v(i,e){return new fe(3008,!1)}function Cv(i){return new fe(3002,!1)}function yv(i,e,r,t,n){return new fe(3010,!1)}function vv(){return new fe(3011,!1)}function Sv(){return new fe(3012,!1)}function bv(){return new fe(3200,!1)}function xv(){return new fe(3202,!1)}function Pv(){return new fe(3013,!1)}function Mv(i){return new fe(3014,!1)}function Ev(i){return new fe(3015,!1)}function Iv(i){return new fe(3016,!1)}function Ov(i,e){return new fe(3404,!1)}function wv(i){return new fe(3502,!1)}function Tv(i){return new fe(3503,!1)}function kv(){return new fe(3300,!1)}function Rv(i){return new fe(3504,!1)}function Av(i){return new fe(3301,!1)}function Nv(i,e){return new fe(3302,!1)}function Dv(i){return new fe(3303,!1)}function Fv(i,e){return new fe(3400,!1)}function Lv(i){return new fe(3401,!1)}function jv(i){return new fe(3402,!1)}function $v(i,e){return new fe(3505,!1)}function Qi(i){switch(i.length){case 0:return new Pn;case 1:return i[0];default:return new ka(i)}}function kh(i,e,r=new Map,t=new Map){let n=[],o=[],s=-1,a=null;if(e.forEach(c=>{let p=c.get("offset"),m=p==s,_=m&&a||new Map;
vendor: 47,145 bytes, line 1
1c.forEach((y,E)=>{let k=E,N=y;if(E!=="offset")switch(k=i.normalizePropertyName(k,n),N){case fo:N=r.get(E);break;case li:N=t.get(E);break;default:N=i.normalizeStyleValue(E,k,N,n);break}_.set(k,N)}),m||o.push(_),a=_,s=p}),n.length)throw wv(n);return o}function Pc(i,e,r,t){switch(e){case"start":i.onStart(()=>t(r&&ic(r,"start",i)));break;case"done":i.onDone(()=>t(r&&ic(r,"done",i)));break;case"destroy":i.onDestroy(()=>t(r&&ic(r,"destroy",i)));break}}function ic(i,e,r){let t=r.totalTime,n=!!r.disabled,o=Mc(i.element,i.triggerName,i.fromState,i.toState,e||i.phaseName,t??i.totalTime,n),s=i._data;return s!=null&&(o._data=s),o}function Mc(i,e,r,t,n="",o=0,s){return{element:i,triggerName:e,fromState:r,toState:t,phaseName:n,totalTime:o,disabled:!!s}}function zt(i,e,r){let t=i.get(e);return t||i.set(e,t=r),t}function Ch(i){let e=i.indexOf(":"),r=i.substring(1,e),t=i.slice(e+1);return[r,t]}var Bv=typeof document>"u"?null:document.documentElement;function Ec(i){let e=i.parentNode||i.host||null;return e===Bv?null:e}function Uv(i){return i.substring(1,6)=="ebkit"}var dn=null,yh=!1;function zv(i){dn||(dn=Gv()||{},yh=dn.style?"WebkitAppearance"in dn.style:!1);let e=!0;return dn.style&&!Uv(i)&&(e=i in dn.style,!e&&yh&&(e="Webkit"+i.charAt(0).toUpperCase()+i.slice(1)in dn.style)),e}function Gv(){return typeof document<"u"?document.body:null}function Rh(i,e){for(;e;){if(e===i)return!0;e=Ec(e)}return!1}function Ah(i,e,r){if(r)return Array.from(i.querySelectorAll(e));let t=i.querySelector(e);return t?[t]:[]}var Ic=(()=>{let e=class e{validateStyleProperty(t){return zv(t)}matchesElement(t,n){return!1}containsElement(t,n){return Rh(t,n)}getParentElement(t){return Ec(t)}query(t,n,o){return Ah(t,n,o)}computeStyle(t,n,o){return o||""}animate(t,n,o,s,a,c=[],p){return new Pn(o,s)}};e.\u0275fac=function(n){return new(n||e)},e.\u0275prov=I({token:e,factory:e.\u0275fac});let i=e;return i})(),kc=class kc{};kc.NOOP=new Ic;var fn=kc,hn=class{};var Hv=1e3,Nh="{{",Vv="}}",Dh="ng-enter",cc="ng-leave",Ss="ng-trigger",Es=".ng-trigger",vh="ng-animating",pc=".ng-animating";function Ei(i){if(typeof i=="number")return i;let e=i.match(/^(-?[\.\d]+)(m?s)/);return!e||e.length<2?0:lc(parseFloat(e[1]),e[2])}function lc(i,e){switch(e){case"s":return i*Hv;default:return i}}function Is(i,e,r){return i.hasOwnProperty("duration")?i:qv(i,e,r)}function qv(i,e,r){let t=/^(-?[\.\d]+)(m?s)(?:\s+(-?[\.\d]+)(m?s))?(?:\s+([-a-z]+(?:\(.+?\))?))?$/i,n,o=0,s="";if(typeof i=="string"){let a=i.match(t);if(a===null)return e.push(_h(i)),{duration:0,delay:0,easing:""};n=lc(parseFloat(a[1]),a[2]);let c=a[3];c!=null&&(o=lc(parseFloat(c),a[4]));let p=a[5];p&&(s=p)}else n=i;if(!r){let a=!1,c=e.length;n<0&&(e.push(pv()),a=!0),o<0&&(e.push(lv()),a=!0),a&&e.splice(c,0,_h(i))}return{duration:n,delay:o,easing:s}}function Wv(i){return i.length?i[0]instanceof Map?i:i.map(e=>new Map(Object.entries(e))):[]}function Si(i,e,r){e.forEach((t,n)=>{let o=Oc(n);r&&!r.has(n)&&r.set(n,i.style[o]),i.style[o]=t})}function un(i,e){e.forEach((r,t)=>{let n=Oc(t);i.style[n]=""})}function Fr(i){return Array.isArray(i)?i.length==1?i[0]:xl(i):i}function Kv(i,e,r){let t=e.params||{},n=Fh(i);n.length&&n.forEach(o=>{t.hasOwnProperty(o)||r.push(dv(o))})}var dc=new RegExp(`${Nh}\\s*(.+?)\\s*${Vv}`,"g");function Fh(i){let e=[];if(typeof i=="string"){let r;for(;r=dc.exec(i);)e.push(r[1]);dc.lastIndex=0}return e}function jr(i,e,r){let t=`${i}`,n=t.replace(dc,(o,s)=>{let a=e[s];return a==null&&(r.push(mv(s)),a=""),a.toString()});return n==t?i:n}var Qv=/-+([a-z0-9])/g;function Oc(i){return i.replace(Qv,(...e)=>e[1].toUpperCase())}function Yv(i,e){return i===0||e===0}function Zv(i,e,r){if(r.size&&e.length){let t=e[0],n=[];if(r.forEach((o,s)=>{t.has(s)||n.push(s),t.set(s,o)}),n.length)for(let o=1;o<e.length;o++){let s=e[o];n.forEach(a=>s.set(a,wc(i,a)))}}return e}function Ut(i,e,r){switch(e.type){case de.Trigger:return i.visitTrigger(e,r);case de.State:return i.visitState(e,r);case de.Transition:return i.visitTransition(e,r);case de.Sequence:return i.visitSequence(e,r);case de.Group:return i.visitGroup(e,r);case de.Animate:return i.visitAnimate(e,r);case de.Keyframes:return i.visitKeyframes(e,r);case de.Style:return i.visitStyle(e,r);case de.Reference:return i.visitReference(e,r);case de.AnimateChild:return i.visitAnimateChild(e,r);case de.AnimateRef:return i.visitAnimateRef(e,r);case de.Query:return i.visitQuery(e,r);case de.Stagger:return i.visitStagger(e,r);default:throw uv(e.type)}}function wc(i,e){return window.getComputedStyle(i)[e]}var Xv=new Set(["width","height","minWidth","minHeight","maxWidth","maxHeight","left","top","bottom","right","fontSize","outlineWidth","outlineOffset","paddingTop","paddingLeft","paddingBottom","paddingRight","marginTop","marginLeft","marginBottom","marginRight","borderRadius","borderWidth","borderTopWidth","borderLeftWidth","borderRightWidth","borderBottomWidth","textIndent","perspective"]),Os=class extends hn{normalizePropertyName(e,r){return Oc(e)}normalizeStyleValue(e,r,t,n){let o="",s=t.toString().trim();if(Xv.has(r)&&t!==0&&t!=="0")if(typeof t=="number")o="px";else{let a=t.match(/^[+-]?[\d\.]+([a-z]*)$/);a&&a[1].length==0&&n.push(fv(e,t))}return s+o}};var ws="*";function Jv(i,e){let r=[];return typeof i=="string"?i.split(/\s*,\s*/).forEach(t=>eS(t,r,e)):r.push(i),r}function eS(i,e,r){if(i[0]==":"){let c=tS(i,r);if(typeof c=="function"){e.push(c);return}i=c}let t=i.match(/^(\*|[-\w]+)\s*(<?[=-]>)\s*(\*|[-\w]+)$/);if(t==null||t.length<4)return r.push(Ev(i)),e;let n=t[1],o=t[2],s=t[3];e.push(Sh(n,s));let a=n==ws&&s==ws;o[0]=="<"&&!a&&e.push(Sh(s,n))}function tS(i,e){switch(i){case":enter":return"void => *";case":leave":return"* => void";case":increment":return(r,t)=>parseFloat(t)>parseFloat(r);case":decrement":return(r,t)=>parseFloat(t)<parseFloat(r);default:return e.push(Iv(i)),"* => *"}}var bs=new Set(["true","1"]),xs=new Set(["false","0"]);function Sh(i,e){let r=bs.has(i)||xs.has(i),t=bs.has(e)||xs.has(e);return(n,o)=>{let s=i==ws||i==n,a=e==ws||e==o;return!s&&r&&typeof n=="boolean"&&(s=n?bs.has(i):xs.has(i)),!a&&t&&typeof o=="boolean"&&(a=o?bs.has(e):xs.has(e)),s&&a}}var Lh=":self",iS=new RegExp(`s*${Lh}s*,?`,"g");function jh(i,e,r,t){return new mc(i).build(e,r,t)}var bh="",mc=class{constructor(e){this._driver=e}build(e,r,t){let n=new uc(r);return this._resetContextStyleTimingState(n),Ut(this,Fr(e),n)}_resetContextStyleTimingState(e){e.currentQuerySelector=bh,e.collectedStyles=new Map,e.collectedStyles.set(bh,new Map),e.currentTime=0}visitTrigger(e,r){let t=r.queryCount=0,n=r.depCount=0,o=[],s=[];return e.name.charAt(0)=="@"&&r.errors.push(hv()),e.definitions.forEach(a=>{if(this._resetContextStyleTimingState(r),a.type==de.State){let c=a,p=c.name;p.toString().split(/\s*,\s*/).forEach(m=>{c.name=m,o.push(this.visitState(c,r))}),c.name=p}else if(a.type==de.Transition){let c=this.visitTransition(a,r);t+=c.queryCount,n+=c.depCount,s.push(c)}else r.errors.push(gv())}),{type:de.Trigger,name:e.name,states:o,transitions:s,queryCount:t,depCount:n,options:null}}visitState(e,r){let t=this.visitStyle(e.styles,r),n=e.options&&e.options.params||null;if(t.containsDynamicStyles){let o=new Set,s=n||{};t.styles.forEach(a=>{a instanceof Map&&a.forEach(c=>{Fh(c).forEach(p=>{s.hasOwnProperty(p)||o.add(p)})})}),o.size&&r.errors.push(_v(e.name,[...o.values()]))}return{type:de.State,name:e.name,style:t,options:n?{params:n}:null}}visitTransition(e,r){r.queryCount=0,r.depCount=0;let t=Ut(this,Fr(e.animation),r),n=Jv(e.expr,r.errors);return{type:de.Transition,matchers:n,animation:t,queryCount:r.queryCount,depCount:r.depCount,options:mn(e.options)}}visitSequence(e,r){return{type:de.Sequence,steps:e.steps.map(t=>Ut(this,t,r)),options:mn(e.options)}}visitGroup(e,r){let t=r.currentTime,n=0,o=e.steps.map(s=>{r.currentTime=t;let a=Ut(this,s,r);return n=Math.max(n,r.currentTime),a});return r.currentTime=n,{type:de.Group,steps:o,options:mn(e.options)}}visitAnimate(e,r){let t=sS(e.timings,r.errors);r.currentAnimateTimings=t;let n,o=e.styles?e.styles:cn({});if(o.type==de.Keyframes)n=this.visitKeyframes(o,r);else{let s=e.styles,a=!1;if(!s){a=!0;let p={};t.easing&&(p.easing=t.easing),s=cn(p)}r.currentTime+=t.duration+t.delay;let c=this.visitStyle(s,r);c.isEmptyStep=a,n=c}return r.currentAnimateTimings=null,{type:de.Animate,timings:t,style:n,options:null}}visitStyle(e,r){let t=this._makeStyleAst(e,r);return this._validateStyleAst(t,r),t}_makeStyleAst(e,r){let t=[],n=Array.isArray(e.styles)?e.styles:[e.styles];for(let a of n)typeof a=="string"?a===li?t.push(a):r.errors.push(Cv(a)):t.push(new Map(Object.entries(a)));let o=!1,s=null;return t.forEach(a=>{if(a instanceof Map&&(a.has("easing")&&(s=a.get("easing"),a.delete("easing")),!o)){for(let c of a.values())if(c.toString().indexOf(Nh)>=0){o=!0;break}}}),{type:de.Style,styles:t,easing:s,offset:e.offset,containsDynamicStyles:o,options:null}}_validateStyleAst(e,r){let t=r.currentAnimateTimings,n=r.currentTime,o=r.currentTime;t&&o>0&&(o-=t.duration+t.delay),e.styles.forEach(s=>{typeof s!="string"&&s.forEach((a,c)=>{let p=r.collectedStyles.get(r.currentQuerySelector),m=p.get(c),_=!0;m&&(o!=n&&o>=m.startTime&&n<=m.endTime&&(r.errors.push(yv(c,m.startTime,m.endTime,o,n)),_=!1),o=m.startTime),_&&p.set(c,{startTime:o,endTime:n}),r.options&&Kv(a,r.options,r.errors)})})}visitKeyframes(e,r){let t={type:de.Keyframes,styles:[],options:null};if(!r.currentAnimateTimings)return r.errors.push(vv()),t;let n=1,o=0,s=[],a=!1,c=!1,p=0,m=e.steps.map(_e=>{let ze=this._makeStyleAst(_e,r),st=ze.offset!=null?ze.offset:oS(ze.styles),Ze=0;return st!=null&&(o++,Ze=ze.offset=st),c=c||Ze<0||Ze>1,a=a||Ze<p,p=Ze,s.push(Ze),ze});c&&r.errors.push(Sv()),a&&r.errors.push(bv());let _=e.steps.length,y=0;o>0&&o<_?r.errors.push(xv()):o==0&&(y=n/(_-1));let E=_-1,k=r.currentTime,N=r.currentAnimateTimings,Q=N.duration;return m.forEach((_e,ze)=>{let st=y>0?ze==E?1:y*ze:s[ze],Ze=st*Q;r.currentTime=k+N.delay+Ze,N.duration=Ze,this._validateStyleAst(_e,r),_e.offset=st,t.styles.push(_e)}),t}visitReference(e,r){return{type:de.Reference,animation:Ut(this,Fr(e.animation),r),options:mn(e.options)}}visitAnimateChild(e,r){return r.depCount++,{type:de.AnimateChild,options:mn(e.options)}}visitAnimateRef(e,r){return{type:de.AnimateRef,animation:this.visitReference(e.animation,r),options:mn(e.options)}}visitQuery(e,r){let t=r.currentQuerySelector,n=e.options||{};r.queryCount++,r.currentQuery=e;let[o,s]=nS(e.selector);r.currentQuerySelector=t.length?t+" "+o:o,zt(r.collectedStyles,r.currentQuerySelector,new Map);let a=Ut(this,Fr(e.animation),r);return r.currentQuery=null,r.currentQuerySelector=t,{type:de.Query,selector:o,limit:n.limit||0,optional:!!n.optional,includeSelf:s,animation:a,originalSelector:e.selector,options:mn(e.options)}}visitStagger(e,r){r.currentQuery||r.errors.push(Pv());let t=e.timings==="full"?{duration:0,delay:0,easing:"full"}:Is(e.timings,r.errors,!0);return{type:de.Stagger,animation:Ut(this,Fr(e.animation),r),timings:t,options:null}}};function nS(i){let e=!!i.split(/\s*,\s*/).find(r=>r==Lh);return e&&(i=i.replace(iS,"")),i=i.replace(/@\*/g,Es).replace(/@\w+/g,r=>Es+"-"+r.slice(1)).replace(/:animating/g,pc),[i,e]}function rS(i){return i?R({},i):null}var uc=class{constructor(e){this.errors=e,this.queryCount=0,this.depCount=0,this.currentTransition=null,this.currentQuery=null,this.currentQuerySelector=null,this.currentAnimateTimings=null,this.currentTime=0,this.collectedStyles=new Map,this.options=null,this.unsupportedCSSPropertiesFound=new Set}};function oS(i){if(typeof i=="string")return null;let e=null;if(Array.isArray(i))i.forEach(r=>{if(r instanceof Map&&r.has("offset")){let t=r;e=parseFloat(t.get("offset")),t.delete("offset")}});else if(i instanceof Map&&i.has("offset")){let r=i;e=parseFloat(r.get("offset")),r.delete("offset")}return e}function sS(i,e){if(i.hasOwnProperty("duration"))return i;if(typeof i=="number"){let o=Is(i,e).duration;return nc(o,0,"")}let r=i;if(r.split(/\s+/).some(o=>o.charAt(0)=="{"&&o.charAt(1)=="{")){let o=nc(0,0,"");return o.dynamic=!0,o.strValue=r,o}let n=Is(r,e);return nc(n.duration,n.delay,n.easing)}function mn(i){return i?(i=R({},i),i.params&&(i.params=rS(i.params))):i={},i}function nc(i,e,r){return{duration:i,delay:e,easing:r}}function Tc(i,e,r,t,n,o,s=null,a=!1){return{type:1,element:i,keyframes:e,preStyleProps:r,postStyleProps:t,duration:n,delay:o,totalTime:n+o,easing:s,subTimeline:a}}var $r=class{constructor(){this._map=new Map}get(e){return this._map.get(e)||[]}append(e,r){let t=this._map.get(e);t||this._map.set(e,t=[]),t.push(...r)}has(e){return this._map.has(e)}clear(){this._map.clear()}},aS=1,cS=":enter",pS=new RegExp(cS,"g"),lS=":leave",dS=new RegExp(lS,"g");function $h(i,e,r,t,n,o=new Map,s=new Map,a,c,p=[]){return new fc().buildKeyframes(i,e,r,t,n,o,s,a,c,p)}var fc=class{buildKeyframes(e,r,t,n,o,s,a,c,p,m=[]){p=p||new $r;let _=new hc(e,r,p,n,o,m,[]);_.options=c;let y=c.delay?Ei(c.delay):0;_.currentTimeline.delayNextStep(y),_.currentTimeline.setStyles([s],null,_.errors,c),Ut(this,t,_);let E=_.timelines.filter(k=>k.containsAnimation());if(E.length&&a.size){let k;for(let N=E.length-1;N>=0;N--){let Q=E[N];if(Q.element===r){k=Q;break}}k&&!k.allowOnlyTimelineStyles()&&k.setStyles([a],null,_.errors,c)}return E.length?E.map(k=>k.buildKeyframes()):[Tc(r,[],[],[],0,y,"",!1)]}visitTrigger(e,r){}visitState(e,r){}visitTransition(e,r){}visitAnimateChild(e,r){let t=r.subInstructions.get(r.element);if(t){let n=r.createSubContext(e.options),o=r.currentTimeline.currentTime,s=this._visitSubInstructions(t,n,n.options);o!=s&&r.transformIntoNewTimeline(s)}r.previousNode=e}visitAnimateRef(e,r){let t=r.createSubContext(e.options);t.transformIntoNewTimeline(),this._applyAnimationRefDelays([e.options,e.animation.options],r,t),this.visitReference(e.animation,t),r.transformIntoNewTimeline(t.currentTimeline.currentTime),r.previousNode=e}_applyAnimationRefDelays(e,r,t){for(let n of e){let o=n?.delay;if(o){let s=typeof o=="number"?o:Ei(jr(o,n?.params??{},r.errors));t.delayNextStep(s)}}}_visitSubInstructions(e,r,t){let o=r.currentTimeline.currentTime,s=t.duration!=null?Ei(t.duration):null,a=t.delay!=null?Ei(t.delay):null;return s!==0&&e.forEach(c=>{let p=r.appendInstructionToTimeline(c,s,a);o=Math.max(o,p.duration+p.delay)}),o}visitReference(e,r){r.updateOptions(e.options,!0),Ut(this,e.animation,r),r.previousNode=e}visitSequence(e,r){let t=r.subContextCount,n=r,o=e.options;if(o&&(o.params||o.delay)&&(n=r.createSubContext(o),n.transformIntoNewTimeline(),o.delay!=null)){n.previousNode.type==de.Style&&(n.currentTimeline.snapshotCurrentStyles(),n.previousNode=Ts);let s=Ei(o.delay);n.delayNextStep(s)}e.steps.length&&(e.steps.forEach(s=>Ut(this,s,n)),n.currentTimeline.applyStylesToKeyframe(),n.subContextCount>t&&n.transformIntoNewTimeline()),r.previousNode=e}visitGroup(e,r){let t=[],n=r.currentTimeline.currentTime,o=e.options&&e.options.delay?Ei(e.options.delay):0;e.steps.forEach(s=>{let a=r.createSubContext(e.options);o&&a.delayNextStep(o),Ut(this,s,a),n=Math.max(n,a.currentTimeline.currentTime),t.push(a.currentTimeline)}),t.forEach(s=>r.currentTimeline.mergeTimelineCollectedStyles(s)),r.transformIntoNewTimeline(n),r.previousNode=e}_visitTiming(e,r){if(e.dynamic){let t=e.strValue,n=r.params?jr(t,r.params,r.errors):t;return Is(n,r.errors)}else return{duration:e.duration,delay:e.delay,easing:e.easing}}visitAnimate(e,r){let t=r.currentAnimateTimings=this._visitTiming(e.timings,r),n=r.currentTimeline;t.delay&&(r.incrementTime(t.delay),n.snapshotCurrentStyles());let o=e.style;o.type==de.Keyframes?this.visitKeyframes(o,r):(r.incrementTime(t.duration),this.visitStyle(o,r),n.applyStylesToKeyframe()),r.currentAnimateTimings=null,r.previousNode=e}visitStyle(e,r){let t=r.currentTimeline,n=r.currentAnimateTimings;!n&&t.hasCurrentStyleProperties()&&t.forwardFrame();let o=n&&n.easing||e.easing;e.isEmptyStep?t.applyEmptyStep(o):t.setStyles(e.styles,o,r.errors,r.options),r.previousNode=e}visitKeyframes(e,r){let t=r.currentAnimateTimings,n=r.currentTimeline.duration,o=t.duration,a=r.createSubContext().currentTimeline;a.easing=t.easing,e.styles.forEach(c=>{let p=c.offset||0;a.forwardTime(p*o),a.setStyles(c.styles,c.easing,r.errors,r.options),a.applyStylesToKeyframe()}),r.currentTimeline.mergeTimelineCollectedStyles(a),r.transformIntoNewTimeline(n+o),r.previousNode=e}visitQuery(e,r){let t=r.currentTimeline.currentTime,n=e.options||{},o=n.delay?Ei(n.delay):0;o&&(r.previousNode.type===de.Style||t==0&&r.currentTimeline.hasCurrentStyleProperties())&&(r.currentTimeline.snapshotCurrentStyles(),r.previousNode=Ts);let s=t,a=r.invokeQuery(e.selector,e.originalSelector,e.limit,e.includeSelf,!!n.optional,r.errors);r.currentQueryTotal=a.length;let c=null;a.forEach((p,m)=>{r.currentQueryIndex=m;let _=r.createSubContext(e.options,p);o&&_.delayNextStep(o),p===r.element&&(c=_.currentTimeline),Ut(this,e.animation,_),_.currentTimeline.applyStylesToKeyframe();let y=_.currentTimeline.currentTime;s=Math.max(s,y)}),r.currentQueryIndex=0,r.currentQueryTotal=0,r.transformIntoNewTimeline(s),c&&(r.currentTimeline.mergeTimelineCollectedStyles(c),r.currentTimeline.snapshotCurrentStyles()),r.previousNode=e}visitStagger(e,r){let t=r.parentContext,n=r.currentTimeline,o=e.timings,s=Math.abs(o.duration),a=s*(r.currentQueryTotal-1),c=s*r.currentQueryIndex;switch(o.duration<0?"reverse":o.easing){case"reverse":c=a-c;break;case"full":c=t.currentStaggerTime;break}let m=r.currentTimeline;c&&m.delayNextStep(c);let _=m.currentTime;Ut(this,e.animation,r),r.previousNode=e,t.currentStaggerTime=n.currentTime-_+(n.startTime-t.currentTimeline.startTime)}},Ts={},hc=class i{constructor(e,r,t,n,o,s,a,c){this._driver=e,this.element=r,this.subInstructions=t,this._enterClassName=n,this._leaveClassName=o,this.errors=s,this.timelines=a,this.parentContext=null,this.currentAnimateTimings=null,this.previousNode=Ts,this.subContextCount=0,this.options={},this.currentQueryIndex=0,this.currentQueryTotal=0,this.currentStaggerTime=0,this.currentTimeline=c||new ks(this._driver,r,0),a.push(this.currentTimeline)}get params(){return this.options.params}updateOptions(e,r){if(!e)return;let t=e,n=this.options;t.duration!=null&&(n.duration=Ei(t.duration)),t.delay!=null&&(n.delay=Ei(t.delay));let o=t.params;if(o){let s=n.params;s||(s=this.options.params={}),Object.keys(o).forEach(a=>{(!r||!s.hasOwnProperty(a))&&(s[a]=jr(o[a],s,this.errors))})}}_copyOptions(){let e={};if(this.options){let r=this.options.params;if(r){let t=e.params={};Object.keys(r).forEach(n=>{t[n]=r[n]})}}return e}createSubContext(e=null,r,t){let n=r||this.element,o=new i(this._driver,n,this.subInstructions,this._enterClassName,this._leaveClassName,this.errors,this.timelines,this.currentTimeline.fork(n,t||0));return o.previousNode=this.previousNode,o.currentAnimateTimings=this.currentAnimateTimings,o.options=this._copyOptions(),o.updateOptions(e),o.currentQueryIndex=this.currentQueryIndex,o.currentQueryTotal=this.currentQueryTotal,o.parentContext=this,this.subContextCount++,o}transformIntoNewTimeline(e){return this.previousNode=Ts,this.currentTimeline=this.currentTimeline.fork(this.element,e),this.timelines.push(this.currentTimeline),this.currentTimeline}appendInstructionToTimeline(e,r,t){let n={duration:r??e.duration,delay:this.currentTimeline.currentTime+(t??0)+e.delay,easing:""},o=new gc(this._driver,e.element,e.keyframes,e.preStyleProps,e.postStyleProps,n,e.stretchStartingKeyframe);return this.timelines.push(o),n}incrementTime(e){this.currentTimeline.forwardTime(this.currentTimeline.duration+e)}delayNextStep(e){e>0&&this.currentTimeline.delayNextStep(e)}invokeQuery(e,r,t,n,o,s){let a=[];if(n&&a.push(this.element),e.length>0){e=e.replace(pS,"."+this._enterClassName),e=e.replace(dS,"."+this._leaveClassName);let c=t!=1,p=this._driver.query(this.element,e,c);t!==0&&(p=t<0?p.slice(p.length+t,p.length):p.slice(0,t)),a.push(...p)}return!o&&a.length==0&&s.push(Mv(r)),a}},ks=class i{constructor(e,r,t,n){this._driver=e,this.element=r,this.startTime=t,this._elementTimelineStylesLookup=n,this.duration=0,this.easing=null,this._previousKeyframe=new Map,this._currentKeyframe=new Map,this._keyframes=new Map,this._styleSummary=new Map,this._localTimelineStyles=new Map,this._pendingStyles=new Map,this._backFill=new Map,this._currentEmptyStepKeyframe=null,this._elementTimelineStylesLookup||(this._elementTimelineStylesLookup=new Map),this._globalTimelineStyles=this._elementTimelineStylesLookup.get(r),this._globalTimelineStyles||(this._globalTimelineStyles=this._localTimelineStyles,this._elementTimelineStylesLookup.set(r,this._localTimelineStyles)),this._loadKeyframe()}containsAnimation(){switch(this._keyframes.size){case 0:return!1;case 1:return this.hasCurrentStyleProperties();default:return!0}}hasCurrentStyleProperties(){return this._currentKeyframe.size>0}get currentTime(){return this.startTime+this.duration}delayNextStep(e){let r=this._keyframes.size===1&&this._pendingStyles.size;this.duration||r?(this.forwardTime(this.currentTime+e),r&&this.snapshotCurrentStyles()):this.startTime+=e}fork(e,r){return this.applyStylesToKeyframe(),new i(this._driver,e,r||this.currentTime,this._elementTimelineStylesLookup)}_loadKeyframe(){this._currentKeyframe&&(this._previousKeyframe=this._currentKeyframe),this._currentKeyframe=this._keyframes.get(this.duration),this._currentKeyframe||(this._currentKeyframe=new Map,this._keyframes.set(this.duration,this._currentKeyframe))}forwardFrame(){this.duration+=aS,this._loadKeyframe()}forwardTime(e){this.applyStylesToKeyframe(),this.duration=e,this._loadKeyframe()}_updateStyle(e,r){this._localTimelineStyles.set(e,r),this._globalTimelineStyles.set(e,r),this._styleSummary.set(e,{time:this.currentTime,value:r})}allowOnlyTimelineStyles(){return this._currentEmptyStepKeyframe!==this._currentKeyframe}applyEmptyStep(e){e&&this._previousKeyframe.set("easing",e);for(let[r,t]of this._globalTimelineStyles)this._backFill.set(r,t||li),this._currentKeyframe.set(r,li);this._currentEmptyStepKeyframe=this._currentKeyframe}setStyles(e,r,t,n){r&&this._previousKeyframe.set("easing",r);let o=n&&n.params||{},s=mS(e,this._globalTimelineStyles);for(let[a,c]of s){let p=jr(c,o,t);this._pendingStyles.set(a,p),this._localTimelineStyles.has(a)||this._backFill.set(a,this._globalTimelineStyles.get(a)??li),this._updateStyle(a,p)}}applyStylesToKeyframe(){this._pendingStyles.size!=0&&(this._pendingStyles.forEach((e,r)=>{this._currentKeyframe.set(r,e)}),this._pendingStyles.clear(),this._localTimelineStyles.forEach((e,r)=>{this._currentKeyframe.has(r)||this._currentKeyframe.set(r,e)}))}snapshotCurrentStyles(){for(let[e,r]of this._localTimelineStyles)this._pendingStyles.set(e,r),this._updateStyle(e,r)}getFinalKeyframe(){return this._keyframes.get(this.duration)}get properties(){let e=[];for(let r in this._currentKeyframe)e.push(r);return e}mergeTimelineCollectedStyles(e){e._styleSummary.forEach((r,t)=>{let n=this._styleSummary.get(t);(!n||r.time>n.time)&&this._updateStyle(t,r.value)})}buildKeyframes(){this.applyStylesToKeyframe();let e=new Set,r=new Set,t=this._keyframes.size===1&&this.duration===0,n=[];this._keyframes.forEach((a,c)=>{let p=new Map([...this._backFill,...a]);p.forEach((m,_)=>{m===fo?e.add(_):m===li&&r.add(_)}),t||p.set("offset",c/this.duration),n.push(p)});let o=[...e.values()],s=[...r.values()];if(t){let a=n[0],c=new Map(a);a.set("offset",0),c.set("offset",1),n=[a,c]}return Tc(this.element,n,o,s,this.duration,this.startTime,this.easing,!1)}},gc=class extends ks{constructor(e,r,t,n,o,s,a=!1){super(e,r,s.delay),this.keyframes=t,this.preStyleProps=n,this.postStyleProps=o,this._stretchStartingKeyframe=a,this.timings={duration:s.duration,delay:s.delay,easing:s.easing}}containsAnimation(){return this.keyframes.length>1}buildKeyframes(){let e=this.keyframes,{delay:r,duration:t,easing:n}=this.timings;if(this._stretchStartingKeyframe&&r){let o=[],s=t+r,a=r/s,c=new Map(e[0]);c.set("offset",0),o.push(c);let p=new Map(e[0]);p.set("offset",xh(a)),o.push(p);let m=e.length-1;for(let _=1;_<=m;_++){let y=new Map(e[_]),E=y.get("offset"),k=r+E*t;y.set("offset",xh(k/s)),o.push(y)}t=s,r=0,n="",e=o}return Tc(this.element,e,this.preStyleProps,this.postStyleProps,t,r,n,!0)}};function xh(i,e=3){let r=Math.pow(10,e-1);return Math.round(i*r)/r}function mS(i,e){let r=new Map,t;return i.forEach(n=>{if(n==="*"){t??=e.keys();for(let o of t)r.set(o,li)}else for(let[o,s]of n)r.set(o,s)}),r}function Ph(i,e,r,t,n,o,s,a,c,p,m,_,y){return{type:0,element:i,triggerName:e,isRemovalTransition:n,fromState:r,fromStyles:o,toState:t,toStyles:s,timelines:a,queriedElements:c,preStyleProps:p,postStyleProps:m,totalTime:_,errors:y}}var rc={},Rs=class{constructor(e,r,t){this._triggerName=e,this.ast=r,this._stateStyles=t}match(e,r,t,n){return uS(this.ast.matchers,e,r,t,n)}buildStyles(e,r,t){let n=this._stateStyles.get("*");return e!==void 0&&(n=this._stateStyles.get(e?.toString())||n),n?n.buildStyles(r,t):new Map}build(e,r,t,n,o,s,a,c,p,m){let _=[],y=this.ast.options&&this.ast.options.params||rc,E=a&&a.params||rc,k=this.buildStyles(t,E,_),N=c&&c.params||rc,Q=this.buildStyles(n,N,_),_e=new Set,ze=new Map,st=new Map,Ze=n==="void",ni={params:Bh(N,y),delay:this.ast.options?.delay},ri=m?[]:$h(e,r,this.ast.animation,o,s,k,Q,ni,p,_),Mt=0;return ri.forEach(It=>{Mt=Math.max(It.duration+It.delay,Mt)}),_.length?Ph(r,this._triggerName,t,n,Ze,k,Q,[],[],ze,st,Mt,_):(ri.forEach(It=>{let nn=It.element,vn=zt(ze,nn,new Set);It.preStyleProps.forEach(rn=>vn.add(rn));let yp=zt(st,nn,new Set);It.postStyleProps.forEach(rn=>yp.add(rn)),nn!==r&&_e.add(nn)}),Ph(r,this._triggerName,t,n,Ze,k,Q,ri,[..._e.values()],ze,st,Mt))}};function uS(i,e,r,t,n){return i.some(o=>o(e,r,t,n))}function Bh(i,e){let r=R({},e);return Object.entries(i).forEach(([t,n])=>{n!=null&&(r[t]=n)}),r}var _c=class{constructor(e,r,t){this.styles=e,this.defaultParams=r,this.normalizer=t}buildStyles(e,r){let t=new Map,n=Bh(e,this.defaultParams);return this.styles.styles.forEach(o=>{typeof o!="string"&&o.forEach((s,a)=>{s&&(s=jr(s,n,r));let c=this.normalizer.normalizePropertyName(a,r);s=this.normalizer.normalizeStyleValue(a,c,s,r),t.set(a,s)})}),t}};function fS(i,e,r){return new Cc(i,e,r)}var Cc=class{constructor(e,r,t){this.name=e,this.ast=r,this._normalizer=t,this.transitionFactories=[],this.states=new Map,r.states.forEach(n=>{let o=n.options&&n.options.params||{};this.states.set(n.name,new _c(n.style,o,t))}),Mh(this.states,"true","1"),Mh(this.states,"false","0"),r.transitions.forEach(n=>{this.transitionFactories.push(new Rs(e,n,this.states))}),this.fallbackTransition=hS(e,this.states,this._normalizer)}get containsQueries(){return this.ast.queryCount>0}matchTransition(e,r,t,n){return this.transitionFactories.find(s=>s.match(e,r,t,n))||null}matchStyles(e,r,t){return this.fallbackTransition.buildStyles(e,r,t)}};function hS(i,e,r){let t=[(s,a)=>!0],n={type:de.Sequence,steps:[],options:null},o={type:de.Transition,animation:n,matchers:t,options:null,queryCount:0,depCount:0};return new Rs(i,o,e)}function Mh(i,e,r){i.has(e)?i.has(r)||i.set(r,i.get(e)):i.has(r)&&i.set(e,i.get(r))}var gS=new $r,yc=class{constructor(e,r,t){this.bodyNode=e,this._driver=r,this._normalizer=t,this._animations=new Map,this._playersById=new Map,this.players=[]}register(e,r){let t=[],n=[],o=jh(this._driver,r,t,n);if(t.length)throw Tv(t);n.length&&void 0,this._animations.set(e,o)}_buildPlayer(e,r,t){let n=e.element,o=kh(this._normalizer,e.keyframes,r,t);return this._driver.animate(n,o,e.duration,e.delay,e.easing,[],!0)}create(e,r,t={}){let n=[],o=this._animations.get(e),s,a=new Map;if(o?(s=$h(this._driver,r,o,Dh,cc,new Map,new Map,t,gS,n),s.forEach(m=>{let _=zt(a,m.element,new Map);m.postStyleProps.forEach(y=>_.set(y,null))})):(n.push(kv()),s=[]),n.length)throw Rv(n);a.forEach((m,_)=>{m.forEach((y,E)=>{m.set(E,this._driver.computeStyle(_,E,li))})});let c=s.map(m=>{let _=a.get(m.element);return this._buildPlayer(m,new Map,_)}),p=Qi(c);return this._playersById.set(e,p),p.onDestroy(()=>this.destroy(e)),this.players.push(p),p}destroy(e){let r=this._getPlayer(e);r.destroy(),this._playersById.delete(e);let t=this.players.indexOf(r);t>=0&&this.players.splice(t,1)}_getPlayer(e){let r=this._playersById.get(e);if(!r)throw Av(e);return r}listen(e,r,t,n){let o=Mc(r,"","","");return Pc(this._getPlayer(e),t,o,n),()=>{}}command(e,r,t,n){if(t=="register"){this.register(e,n[0]);return}if(t=="create"){let s=n[0]||{};this.create(e,r,s);return}let o=this._getPlayer(e);switch(t){case"play":o.play();break;case"pause":o.pause();break;case"reset":o.reset();break;case"restart":o.restart();break;case"finish":o.finish();break;case"init":o.init();break;case"setPosition":o.setPosition(parseFloat(n[0]));break;case"destroy":this.destroy(e);break}}},Eh="ng-animate-queued",_S=".ng-animate-queued",oc="ng-animate-disabled",CS=".ng-animate-disabled",yS="ng-star-inserted",vS=".ng-star-inserted",SS=[],Uh={namespaceId:"",setForRemoval:!1,setForMove:!1,hasAnimation:!1,removedBeforeQueried:!1},bS={namespaceId:"",setForMove:!1,setForRemoval:!1,hasAnimation:!1,removedBeforeQueried:!0},ti="__ng_removed",Br=class{get params(){return this.options.params}constructor(e,r=""){this.namespaceId=r;let t=e&&e.hasOwnProperty("value"),n=t?e.value:e;if(this.value=PS(n),t){let o=e,{value:s}=o,a=xp(o,["value"]);this.options=a}else this.options={};this.options.params||(this.options.params={})}absorbOptions(e){let r=e.params;if(r){let t=this.options.params;Object.keys(r).forEach(n=>{t[n]==null&&(t[n]=r[n])})}}},Lr="void",sc=new Br(Lr),vc=class{constructor(e,r,t){this.id=e,this.hostElement=r,this._engine=t,this.players=[],this._triggers=new Map,this._queue=[],this._elementListeners=new Map,this._hostClassName="ng-tns-"+e,Yt(r,this._hostClassName)}listen(e,r,t,n){if(!this._triggers.has(r))throw Nv(t,r);if(t==null||t.length==0)throw Dv(r);if(!MS(t))throw Fv(t,r);let o=zt(this._elementListeners,e,[]),s={name:r,phase:t,callback:n};o.push(s);let a=zt(this._engine.statesByElement,e,new Map);return a.has(r)||(Yt(e,Ss),Yt(e,Ss+"-"+r),a.set(r,sc)),()=>{this._engine.afterFlush(()=>{let c=o.indexOf(s);c>=0&&o.splice(c,1),this._triggers.has(r)||a.delete(r)})}}register(e,r){return this._triggers.has(e)?!1:(this._triggers.set(e,r),!0)}_getTrigger(e){let r=this._triggers.get(e);if(!r)throw Lv(e);return r}trigger(e,r,t,n=!0){let o=this._getTrigger(r),s=new Ur(this.id,r,e),a=this._engine.statesByElement.get(e);a||(Yt(e,Ss),Yt(e,Ss+"-"+r),this._engine.statesByElement.set(e,a=new Map));let c=a.get(r),p=new Br(t,this.id);if(!(t&&t.hasOwnProperty("value"))&&c&&p.absorbOptions(c.options),a.set(r,p),c||(c=sc),!(p.value===Lr)&&c.value===p.value){if(!OS(c.params,p.params)){let N=[],Q=o.matchStyles(c.value,c.params,N),_e=o.matchStyles(p.value,p.params,N);N.length?this._engine.reportError(N):this._engine.afterFlush(()=>{un(e,Q),Si(e,_e)})}return}let y=zt(this._engine.playersByElement,e,[]);y.forEach(N=>{N.namespaceId==this.id&&N.triggerName==r&&N.queued&&N.destroy()});let E=o.matchTransition(c.value,p.value,e,p.params),k=!1;if(!E){if(!n)return;E=o.fallbackTransition,k=!0}return this._engine.totalQueuedPlayers++,this._queue.push({element:e,triggerName:r,transition:E,fromState:c,toState:p,player:s,isFallbackTransition:k}),k||(Yt(e,Eh),s.onStart(()=>{er(e,Eh)})),s.onDone(()=>{let N=this.players.indexOf(s);N>=0&&this.players.splice(N,1);let Q=this._engine.playersByElement.get(e);if(Q){let _e=Q.indexOf(s);_e>=0&&Q.splice(_e,1)}}),this.players.push(s),y.push(s),s}deregister(e){this._triggers.delete(e),this._engine.statesByElement.forEach(r=>r.delete(e)),this._elementListeners.forEach((r,t)=>{this._elementListeners.set(t,r.filter(n=>n.name!=e))})}clearElementCache(e){this._engine.statesByElement.delete(e),this._elementListeners.delete(e);let r=this._engine.playersByElement.get(e);r&&(r.forEach(t=>t.destroy()),this._engine.playersByElement.delete(e))}_signalRemovalForInnerTriggers(e,r){let t=this._engine.driver.query(e,Es,!0);t.forEach(n=>{if(n[ti])return;let o=this._engine.fetchNamespacesByElement(n);o.size?o.forEach(s=>s.triggerLeaveAnimation(n,r,!1,!0)):this.clearElementCache(n)}),this._engine.afterFlushAnimationsDone(()=>t.forEach(n=>this.clearElementCache(n)))}triggerLeaveAnimation(e,r,t,n){let o=this._engine.statesByElement.get(e),s=new Map;if(o){let a=[];if(o.forEach((c,p)=>{if(s.set(p,c.value),this._triggers.has(p)){let m=this.trigger(e,p,Lr,n);m&&a.push(m)}}),a.length)return this._engine.markElementAsRemoved(this.id,e,!0,r,s),t&&Qi(a).onDone(()=>this._engine.processLeaveNode(e)),!0}return!1}prepareLeaveAnimationListeners(e){let r=this._elementListeners.get(e),t=this._engine.statesByElement.get(e);if(r&&t){let n=new Set;r.forEach(o=>{let s=o.name;if(n.has(s))return;n.add(s);let c=this._triggers.get(s).fallbackTransition,p=t.get(s)||sc,m=new Br(Lr),_=new Ur(this.id,s,e);this._engine.totalQueuedPlayers++,this._queue.push({element:e,triggerName:s,transition:c,fromState:p,toState:m,player:_,isFallbackTransition:!0})})}}removeNode(e,r){let t=this._engine;if(e.childElementCount&&this._signalRemovalForInnerTriggers(e,r),this.triggerLeaveAnimation(e,r,!0))return;let n=!1;if(t.totalAnimations){let o=t.players.length?t.playersByQueriedElement.get(e):[];if(o&&o.length)n=!0;else{let s=e;for(;s=s.parentNode;)if(t.statesByElement.get(s)){n=!0;break}}}if(this.prepareLeaveAnimationListeners(e),n)t.markElementAsRemoved(this.id,e,!1,r);else{let o=e[ti];(!o||o===Uh)&&(t.afterFlush(()=>this.clearElementCache(e)),t.destroyInnerAnimations(e),t._onRemovalComplete(e,r))}}insertNode(e,r){Yt(e,this._hostClassName)}drainQueuedTransitions(e){let r=[];return this._queue.forEach(t=>{let n=t.player;if(n.destroyed)return;let o=t.element,s=this._elementListeners.get(o);s&&s.forEach(a=>{if(a.name==t.triggerName){let c=Mc(o,t.triggerName,t.fromState.value,t.toState.value);c._data=e,Pc(t.player,a.phase,c,a.callback)}}),n.markedForDestroy?this._engine.afterFlush(()=>{n.destroy()}):r.push(t)}),this._queue=[],r.sort((t,n)=>{let o=t.transition.ast.depCount,s=n.transition.ast.depCount;return o==0||s==0?o-s:this._engine.driver.containsElement(t.element,n.element)?1:-1})}destroy(e){this.players.forEach(r=>r.destroy()),this._signalRemovalForInnerTriggers(this.hostElement,e)}},Sc=class{_onRemovalComplete(e,r){this.onRemovalComplete(e,r)}constructor(e,r,t,n){this.bodyNode=e,this.driver=r,this._normalizer=t,this.scheduler=n,this.players=[],this.newHostElements=new Map,this.playersByElement=new Map,this.playersByQueriedElement=new Map,this.statesByElement=new Map,this.disabledNodes=new Set,this.totalAnimations=0,this.totalQueuedPlayers=0,this._namespaceLookup={},this._namespaceList=[],this._flushFns=[],this._whenQuietFns=[],this.namespacesByHostElement=new Map,this.collectedEnterElements=[],this.collectedLeaveElements=[],this.onRemovalComplete=(o,s)=>{}}get queuedPlayers(){let e=[];return this._namespaceList.forEach(r=>{r.players.forEach(t=>{t.queued&&e.push(t)})}),e}createNamespace(e,r){let t=new vc(e,r,this);return this.bodyNode&&this.driver.containsElement(this.bodyNode,r)?this._balanceNamespaceList(t,r):(this.newHostElements.set(r,t),this.collectEnterElement(r)),this._namespaceLookup[e]=t}_balanceNamespaceList(e,r){let t=this._namespaceList,n=this.namespacesByHostElement;if(t.length-1>=0){let s=!1,a=this.driver.getParentElement(r);for(;a;){let c=n.get(a);if(c){let p=t.indexOf(c);t.splice(p+1,0,e),s=!0;break}a=this.driver.getParentElement(a)}s||t.unshift(e)}else t.push(e);return n.set(r,e),e}register(e,r){let t=this._namespaceLookup[e];return t||(t=this.createNamespace(e,r)),t}registerTrigger(e,r,t){let n=this._namespaceLookup[e];n&&n.register(r,t)&&this.totalAnimations++}destroy(e,r){e&&(this.afterFlush(()=>{}),this.afterFlushAnimationsDone(()=>{let t=this._fetchNamespace(e);this.namespacesByHostElement.delete(t.hostElement);let n=this._namespaceList.indexOf(t);n>=0&&this._namespaceList.splice(n,1),t.destroy(r),delete this._namespaceLookup[e]}))}_fetchNamespace(e){return this._namespaceLookup[e]}fetchNamespacesByElement(e){let r=new Set,t=this.statesByElement.get(e);if(t){for(let n of t.values())if(n.namespaceId){let o=this._fetchNamespace(n.namespaceId);o&&r.add(o)}}return r}trigger(e,r,t,n){if(Ps(r)){let o=this._fetchNamespace(e);if(o)return o.trigger(r,t,n),!0}return!1}insertNode(e,r,t,n){if(!Ps(r))return;let o=r[ti];if(o&&o.setForRemoval){o.setForRemoval=!1,o.setForMove=!0;let s=this.collectedLeaveElements.indexOf(r);s>=0&&this.collectedLeaveElements.splice(s,1)}if(e){let s=this._fetchNamespace(e);s&&s.insertNode(r,t)}n&&this.collectEnterElement(r)}collectEnterElement(e){this.collectedEnterElements.push(e)}markElementAsDisabled(e,r){r?this.disabledNodes.has(e)||(this.disabledNodes.add(e),Yt(e,oc)):this.disabledNodes.has(e)&&(this.disabledNodes.delete(e),er(e,oc))}removeNode(e,r,t){if(Ps(r)){this.scheduler?.notify();let n=e?this._fetchNamespace(e):null;n?n.removeNode(r,t):this.markElementAsRemoved(e,r,!1,t);let o=this.namespacesByHostElement.get(r);o&&o.id!==e&&o.removeNode(r,t)}else this._onRemovalComplete(r,t)}markElementAsRemoved(e,r,t,n,o){this.collectedLeaveElements.push(r),r[ti]={namespaceId:e,setForRemoval:n,hasAnimation:t,removedBeforeQueried:!1,previousTriggersValues:o}}listen(e,r,t,n,o){return Ps(r)?this._fetchNamespace(e).listen(r,t,n,o):()=>{}}_buildInstruction(e,r,t,n,o){return e.transition.build(this.driver,e.element,e.fromState.value,e.toState.value,t,n,e.fromState.options,e.toState.options,r,o)}destroyInnerAnimations(e){let r=this.driver.query(e,Es,!0);r.forEach(t=>this.destroyActiveAnimationsForElement(t)),this.playersByQueriedElement.size!=0&&(r=this.driver.query(e,pc,!0),r.forEach(t=>this.finishActiveQueriedAnimationOnElement(t)))}destroyActiveAnimationsForElement(e){let r=this.playersByElement.get(e);r&&r.forEach(t=>{t.queued?t.markedForDestroy=!0:t.destroy()})}finishActiveQueriedAnimationOnElement(e){let r=this.playersByQueriedElement.get(e);r&&r.forEach(t=>t.finish())}whenRenderingDone(){return new Promise(e=>{if(this.players.length)return Qi(this.players).onDone(()=>e());e()})}processLeaveNode(e){let r=e[ti];if(r&&r.setForRemoval){if(e[ti]=Uh,r.namespaceId){this.destroyInnerAnimations(e);let t=this._fetchNamespace(r.namespaceId);t&&t.clearElementCache(e)}this._onRemovalComplete(e,r.setForRemoval)}e.classList?.contains(oc)&&this.markElementAsDisabled(e,!1),this.driver.query(e,CS,!0).forEach(t=>{this.markElementAsDisabled(t,!1)})}flush(e=-1){let r=[];if(this.newHostElements.size&&(this.newHostElements.forEach((t,n)=>this._balanceNamespaceList(t,n)),this.newHostElements.clear()),this.totalAnimations&&this.collectedEnterElements.length)for(let t=0;t<this.collectedEnterElements.length;t++){let n=this.collectedEnterElements[t];Yt(n,yS)}if(this._namespaceList.length&&(this.totalQueuedPlayers||this.collectedLeaveElements.length)){let t=[];try{r=this._flushAnimations(t,e)}finally{for(let n=0;n<t.length;n++)t[n]()}}else for(let t=0;t<this.collectedLeaveElements.length;t++){let n=this.collectedLeaveElements[t];this.processLeaveNode(n)}if(this.totalQueuedPlayers=0,this.collectedEnterElements.length=0,this.collectedLeaveElements.length=0,this._flushFns.forEach(t=>t()),this._flushFns=[],this._whenQuietFns.length){let t=this._whenQuietFns;this._whenQuietFns=[],r.length?Qi(r).onDone(()=>{t.forEach(n=>n())}):t.forEach(n=>n())}}reportError(e){throw jv(e)}_flushAnimations(e,r){let t=new $r,n=[],o=new Map,s=[],a=new Map,c=new Map,p=new Map,m=new Set;this.disabledNodes.forEach(V=>{m.add(V);let Z=this.driver.query(V,_S,!0);for(let te=0;te<Z.length;te++)m.add(Z[te])});let _=this.bodyNode,y=Array.from(this.statesByElement.keys()),E=wh(y,this.collectedEnterElements),k=new Map,N=0;E.forEach((V,Z)=>{let te=Dh+N++;k.set(Z,te),V.forEach(ue=>Yt(ue,te))});let Q=[],_e=new Set,ze=new Set;for(let V=0;V<this.collectedLeaveElements.length;V++){let Z=this.collectedLeaveElements[V],te=Z[ti];te&&te.setForRemoval&&(Q.push(Z),_e.add(Z),te.hasAnimation?this.driver.query(Z,vS,!0).forEach(ue=>_e.add(ue)):ze.add(Z))}let st=new Map,Ze=wh(y,Array.from(_e));Ze.forEach((V,Z)=>{let te=cc+N++;st.set(Z,te),V.forEach(ue=>Yt(ue,te))}),e.push(()=>{E.forEach((V,Z)=>{let te=k.get(Z);V.forEach(ue=>er(ue,te))}),Ze.forEach((V,Z)=>{let te=st.get(Z);V.forEach(ue=>er(ue,te))}),Q.forEach(V=>{this.processLeaveNode(V)})});let ni=[],ri=[];for(let V=this._namespaceList.length-1;V>=0;V--)this._namespaceList[V].drainQueuedTransitions(r).forEach(te=>{let ue=te.player,at=te.element;if(ni.push(ue),this.collectedEnterElements.length){let vt=at[ti];if(vt&&vt.setForMove){if(vt.previousTriggersValues&&vt.previousTriggersValues.has(te.triggerName)){let on=vt.previousTriggersValues.get(te.triggerName),Ht=this.statesByElement.get(te.element);if(Ht&&Ht.has(te.triggerName)){let Yr=Ht.get(te.triggerName);Yr.value=on,Ht.set(te.triggerName,Yr)}}ue.destroy();return}}let oi=!_||!this.driver.containsElement(_,at),Lt=st.get(at),Ri=k.get(at),$e=this._buildInstruction(te,t,Ri,Lt,oi);if($e.errors&&$e.errors.length){ri.push($e);return}if(oi){ue.onStart(()=>un(at,$e.fromStyles)),ue.onDestroy(()=>Si(at,$e.toStyles)),n.push(ue);return}if(te.isFallbackTransition){ue.onStart(()=>un(at,$e.fromStyles)),ue.onDestroy(()=>Si(at,$e.toStyles)),n.push(ue);return}let bp=[];$e.timelines.forEach(vt=>{vt.stretchStartingKeyframe=!0,this.disabledNodes.has(vt.element)||bp.push(vt)}),$e.timelines=bp,t.append(at,$e.timelines);let cv={instruction:$e,player:ue,element:at};s.push(cv),$e.queriedElements.forEach(vt=>zt(a,vt,[]).push(ue)),$e.preStyleProps.forEach((vt,on)=>{if(vt.size){let Ht=c.get(on);Ht||c.set(on,Ht=new Set),vt.forEach((Yr,Pa)=>Ht.add(Pa))}}),$e.postStyleProps.forEach((vt,on)=>{let Ht=p.get(on);Ht||p.set(on,Ht=new Set),vt.forEach((Yr,Pa)=>Ht.add(Pa))})});if(ri.length){let V=[];ri.forEach(Z=>{V.push($v(Z.triggerName,Z.errors))}),ni.forEach(Z=>Z.destroy()),this.reportError(V)}let Mt=new Map,It=new Map;s.forEach(V=>{let Z=V.element;t.has(Z)&&(It.set(Z,Z),this._beforeAnimationBuild(V.player.namespaceId,V.instruction,Mt))}),n.forEach(V=>{let Z=V.element;this._getPreviousPlayers(Z,!1,V.namespaceId,V.triggerName,null).forEach(ue=>{zt(Mt,Z,[]).push(ue),ue.destroy()})});let nn=Q.filter(V=>Th(V,c,p)),vn=new Map;Oh(vn,this.driver,ze,p,li).forEach(V=>{Th(V,c,p)&&nn.push(V)});let rn=new Map;E.forEach((V,Z)=>{Oh(rn,this.driver,new Set(V),c,fo)}),nn.forEach(V=>{let Z=vn.get(V),te=rn.get(V);vn.set(V,new Map([...Z?.entries()??[],...te?.entries()??[]]))});let xa=[],vp=[],Sp={};s.forEach(V=>{let{element:Z,player:te,instruction:ue}=V;if(t.has(Z)){if(m.has(Z)){te.onDestroy(()=>Si(Z,ue.toStyles)),te.disabled=!0,te.overrideTotalTime(ue.totalTime),n.push(te);return}let at=Sp;if(It.size>1){let Lt=Z,Ri=[];for(;Lt=Lt.parentNode;){let $e=It.get(Lt);if($e){at=$e;break}Ri.push(Lt)}Ri.forEach($e=>It.set($e,at))}let oi=this._buildAnimation(te.namespaceId,ue,Mt,o,rn,vn);if(te.setRealPlayer(oi),at===Sp)xa.push(te);else{let Lt=this.playersByElement.get(at);Lt&&Lt.length&&(te.parentPlayer=Qi(Lt)),n.push(te)}}else un(Z,ue.fromStyles),te.onDestroy(()=>Si(Z,ue.toStyles)),vp.push(te),m.has(Z)&&n.push(te)}),vp.forEach(V=>{let Z=o.get(V.element);if(Z&&Z.length){let te=Qi(Z);V.setRealPlayer(te)}}),n.forEach(V=>{V.parentPlayer?V.syncPlayerEvents(V.parentPlayer):V.destroy()});for(let V=0;V<Q.length;V++){let Z=Q[V],te=Z[ti];if(er(Z,cc),te&&te.hasAnimation)continue;let ue=[];if(a.size){let oi=a.get(Z);oi&&oi.length&&ue.push(...oi);let Lt=this.driver.query(Z,pc,!0);for(let Ri=0;Ri<Lt.length;Ri++){let $e=a.get(Lt[Ri]);$e&&$e.length&&ue.push(...$e)}}let at=ue.filter(oi=>!oi.destroyed);at.length?ES(this,Z,at):this.processLeaveNode(Z)}return Q.length=0,xa.forEach(V=>{this.players.push(V),V.onDone(()=>{V.destroy();let Z=this.players.indexOf(V);this.players.splice(Z,1)}),V.play()}),xa}afterFlush(e){this._flushFns.push(e)}afterFlushAnimationsDone(e){this._whenQuietFns.push(e)}_getPreviousPlayers(e,r,t,n,o){let s=[];if(r){let a=this.playersByQueriedElement.get(e);a&&(s=a)}else{let a=this.playersByElement.get(e);if(a){let c=!o||o==Lr;a.forEach(p=>{p.queued||!c&&p.triggerName!=n||s.push(p)})}}return(t||n)&&(s=s.filter(a=>!(t&&t!=a.namespaceId||n&&n!=a.triggerName))),s}_beforeAnimationBuild(e,r,t){let n=r.triggerName,o=r.element,s=r.isRemovalTransition?void 0:e,a=r.isRemovalTransition?void 0:n;for(let c of r.timelines){let p=c.element,m=p!==o,_=zt(t,p,[]);this._getPreviousPlayers(p,m,s,a,r.toState).forEach(E=>{let k=E.getRealPlayer();k.beforeDestroy&&k.beforeDestroy(),E.destroy(),_.push(E)})}un(o,r.fromStyles)}_buildAnimation(e,r,t,n,o,s){let a=r.triggerName,c=r.element,p=[],m=new Set,_=new Set,y=r.timelines.map(k=>{let N=k.element;m.add(N);let Q=N[ti];if(Q&&Q.removedBeforeQueried)return new Pn(k.duration,k.delay);let _e=N!==c,ze=IS((t.get(N)||SS).map(Mt=>Mt.getRealPlayer())).filter(Mt=>{let It=Mt;return It.element?It.element===N:!1}),st=o.get(N),Ze=s.get(N),ni=kh(this._normalizer,k.keyframes,st,Ze),ri=this._buildPlayer(k,ni,ze);if(k.subTimeline&&n&&_.add(N),_e){let Mt=new Ur(e,a,N);Mt.setRealPlayer(ri),p.push(Mt)}return ri});p.forEach(k=>{zt(this.playersByQueriedElement,k.element,[]).push(k),k.onDone(()=>xS(this.playersByQueriedElement,k.element,k))}),m.forEach(k=>Yt(k,vh));let E=Qi(y);return E.onDestroy(()=>{m.forEach(k=>er(k,vh)),Si(c,r.toStyles)}),_.forEach(k=>{zt(n,k,[]).push(E)}),E}_buildPlayer(e,r,t){return r.length>0?this.driver.animate(e.element,r,e.duration,e.delay,e.easing,t):new Pn(e.duration,e.delay)}},Ur=class{constructor(e,r,t){this.namespaceId=e,this.triggerName=r,this.element=t,this._player=new Pn,this._containsRealPlayer=!1,this._queuedCallbacks=new Map,this.destroyed=!1,this.parentPlayer=null,this.markedForDestroy=!1,this.disabled=!1,this.queued=!0,this.totalTime=0}setRealPlayer(e){this._containsRealPlayer||(this._player=e,this._queuedCallbacks.forEach((r,t)=>{r.forEach(n=>Pc(e,t,void 0,n))}),this._queuedCallbacks.clear(),this._containsRealPlayer=!0,this.overrideTotalTime(e.totalTime),this.queued=!1)}getRealPlayer(){return this._player}overrideTotalTime(e){this.totalTime=e}syncPlayerEvents(e){let r=this._player;r.triggerCallback&&e.onStart(()=>r.triggerCallback("start")),e.onDone(()=>this.finish()),e.onDestroy(()=>this.destroy())}_queueEvent(e,r){zt(this._queuedCallbacks,e,[]).push(r)}onDone(e){this.queued&&this._queueEvent("done",e),this._player.onDone(e)}onStart(e){this.queued&&this._queueEvent("start",e),this._player.onStart(e)}onDestroy(e){this.queued&&this._queueEvent("destroy",e),this._player.onDestroy(e)}init(){this._player.init()}hasStarted(){return this.queued?!1:this._player.hasStarted()}play(){!this.queued&&this._player.play()}pause(){!this.queued&&this._player.pause()}restart(){!this.queued&&this._player.restart()}finish(){this._player.finish()}destroy(){this.destroyed=!0,this._player.destroy()}reset(){!this.queued&&this._player.reset()}setPosition(e){this.queued||this._player.setPosition(e)}getPosition(){return this.queued?0:this._player.getPosition()}triggerCallback(e){let r=this._player;r.triggerCallback&&r.triggerCallback(e)}};function xS(i,e,r){let t=i.get(e);if(t){if(t.length){let n=t.indexOf(r);t.splice(n,1)}t.length==0&&i.delete(e)}return t}function PS(i){return i??null}function Ps(i){return i&&i.nodeType===1}function MS(i){return i=="start"||i=="done"}function Ih(i,e){let r=i.style.display;return i.style.display=e??"none",r}function Oh(i,e,r,t,n){let o=[];r.forEach(c=>o.push(Ih(c)));let s=[];t.forEach((c,p)=>{let m=new Map;
1c.forEach(_=>{let y=e.computeStyle(p,_,n);m.set(_,y),(!y||y.length==0)&&(p[ti]=bS,s.push(p))}),i.set(p,m)});let a=0;return r.forEach(c=>Ih(c,o[a++])),s}function wh(i,e){let r=new Map;if(i.forEach(a=>r.set(a,[])),e.length==0)return r;let t=1,n=new Set(e),o=new Map;function s(a){if(!a)return t;let c=o.get(a);if(c)return c;let p=a.parentNode;return r.has(p)?c=p:n.has(p)?c=t:c=s(p),o.set(a,c),c}return e.forEach(a=>{let c=s(a);c!==t&&r.get(c).push(a)}),r}function Yt(i,e){i.classList?.add(e)}function er(i,e){i.classList?.remove(e)}function ES(i,e,r){Qi(r).onDone(()=>i.processLeaveNode(e))}function IS(i){let e=[];return zh(i,e),e}function zh(i,e){for(let r=0;r<i.length;r++){let t=i[r];t instanceof ka?zh(t.players,e):e.push(t)}}function OS(i,e){let r=Object.keys(i),t=Object.keys(e);if(r.length!=t.length)return!1;for(let n=0;n<r.length;n++){let o=r[n];if(!e.hasOwnProperty(o)||i[o]!==e[o])return!1}return!0}function Th(i,e,r){let t=r.get(i);if(!t)return!1;let n=e.get(i);return n?t.forEach(o=>n.add(o)):e.set(i,t),r.delete(i),!0}var ir=class{constructor(e,r,t,n){this._driver=r,this._normalizer=t,this._triggerCache={},this.onRemovalComplete=(o,s)=>{},this._transitionEngine=new Sc(e.body,r,t,n),this._timelineEngine=new yc(e.body,r,t),this._transitionEngine.onRemovalComplete=(o,s)=>this.onRemovalComplete(o,s)}registerTrigger(e,r,t,n,o){let s=e+"-"+n,a=this._triggerCache[s];if(!a){let c=[],p=[],m=jh(this._driver,o,c,p);if(c.length)throw Ov(n,c);p.length&&void 0,a=fS(n,m,this._normalizer),this._triggerCache[s]=a}this._transitionEngine.registerTrigger(r,n,a)}register(e,r){this._transitionEngine.register(e,r)}destroy(e,r){this._transitionEngine.destroy(e,r)}onInsert(e,r,t,n){this._transitionEngine.insertNode(e,r,t,n)}onRemove(e,r,t){this._transitionEngine.removeNode(e,r,t)}disableAnimations(e,r){this._transitionEngine.markElementAsDisabled(e,r)}process(e,r,t,n){if(t.charAt(0)=="@"){let[o,s]=Ch(t),a=n;this._timelineEngine.command(o,r,s,a)}else this._transitionEngine.trigger(e,r,t,n)}listen(e,r,t,n,o){if(t.charAt(0)=="@"){let[s,a]=Ch(t);return this._timelineEngine.listen(s,r,a,o)}return this._transitionEngine.listen(e,r,t,n,o)}flush(e=-1){this._transitionEngine.flush(e)}get players(){return[...this._transitionEngine.players,...this._timelineEngine.players]}whenRenderingDone(){return this._transitionEngine.whenRenderingDone()}afterFlushAnimationsDone(e){this._transitionEngine.afterFlushAnimationsDone(e)}};function wS(i,e){let r=null,t=null;return Array.isArray(e)&&e.length?(r=ac(e[0]),e.length>1&&(t=ac(e[e.length-1]))):e instanceof Map&&(r=ac(e)),r||t?new bc(i,r,t):null}var tr=class tr{constructor(e,r,t){this._element=e,this._startStyles=r,this._endStyles=t,this._state=0;let n=tr.initialStylesByElement.get(e);n||tr.initialStylesByElement.set(e,n=new Map),this._initialStyles=n}start(){this._state<1&&(this._startStyles&&Si(this._element,this._startStyles,this._initialStyles),this._state=1)}finish(){this.start(),this._state<2&&(Si(this._element,this._initialStyles),this._endStyles&&(Si(this._element,this._endStyles),this._endStyles=null),this._state=1)}destroy(){this.finish(),this._state<3&&(tr.initialStylesByElement.delete(this._element),this._startStyles&&(un(this._element,this._startStyles),this._endStyles=null),this._endStyles&&(un(this._element,this._endStyles),this._endStyles=null),Si(this._element,this._initialStyles),this._state=3)}};tr.initialStylesByElement=new WeakMap;var bc=tr;function ac(i){let e=null;return i.forEach((r,t)=>{TS(t)&&(e=e||new Map,e.set(t,r))}),e}function TS(i){return i==="display"||i==="position"}var As=class{constructor(e,r,t,n){this.element=e,this.keyframes=r,this.options=t,this._specialStyles=n,this._onDoneFns=[],this._onStartFns=[],this._onDestroyFns=[],this._initialized=!1,this._finished=!1,this._started=!1,this._destroyed=!1,this._originalOnDoneFns=[],this._originalOnStartFns=[],this.time=0,this.parentPlayer=null,this.currentSnapshot=new Map,this._duration=t.duration,this._delay=t.delay||0,this.time=this._duration+this._delay}_onFinish(){this._finished||(this._finished=!0,this._onDoneFns.forEach(e=>e()),this._onDoneFns=[])}init(){this._buildPlayer(),this._preparePlayerBeforeStart()}_buildPlayer(){if(this._initialized)return;this._initialized=!0;let e=this.keyframes;this.domPlayer=this._triggerWebAnimation(this.element,e,this.options),this._finalKeyframe=e.length?e[e.length-1]:new Map;let r=()=>this._onFinish();this.domPlayer.addEventListener("finish",r),this.onDestroy(()=>{this.domPlayer.removeEventListener("finish",r)})}_preparePlayerBeforeStart(){this._delay?this._resetDomPlayerState():this.domPlayer.pause()}_convertKeyframesToObject(e){let r=[];return e.forEach(t=>{r.push(Object.fromEntries(t))}),r}_triggerWebAnimation(e,r,t){return e.animate(this._convertKeyframesToObject(r),t)}onStart(e){this._originalOnStartFns.push(e),this._onStartFns.push(e)}onDone(e){this._originalOnDoneFns.push(e),this._onDoneFns.push(e)}onDestroy(e){this._onDestroyFns.push(e)}play(){this._buildPlayer(),this.hasStarted()||(this._onStartFns.forEach(e
1=>e()),this._onStartFns=[],this._started=!0,this._specialStyles&&this._specialStyles.start()),this.domPlayer.play()}pause(){this.init(),this.domPlayer.pause()}finish(){this.init(),this._specialStyles&&this._specialStyles.finish(),this._onFinish(),this.domPlayer.finish()}reset(){this._resetDomPlayerState(),this._destroyed=!1,this._finished=!1,this._started=!1,this._onStartFns=this._originalOnStartFns,this._onDoneFns=this._originalOnDoneFns}_resetDomPlayerState(){this.domPlayer&&this.domPlayer.cancel()}restart(){this.reset(),this.play()}hasStarted(){return this._started}destroy(){this._destroyed||(this._destroyed=!0,this._resetDomPlayerState(),this._onFinish(),this._specialStyles&&this._specialStyles.destroy(),this._onDestroyFns.forEach(e=>e()),this._onDestroyFns=[])}setPosition(e){this.domPlayer===void 0&&this.init(),this.domPlayer.currentTime=e*this.time}getPosition(){return+(this.domPlayer.currentTime??0)/this.time}get totalTime(){return this._delay+this._duration}beforeDestroy(){let e=new Map;this.hasStarted()&&this._finalKeyframe.forEach((t,n)=>{n!=="offset"&&e.set(n,this._finished?t:wc(this.element,n))}),this.currentSnapshot=e}triggerCallback(e){let r=e==="start"?this._onStartFns:this._onDoneFns;r.forEach(t=>t()),r.length=0}},Ns=class{validateStyleProperty(e){return!0}validateAnimatableStyleProperty(e){return!0}matchesElement(e,r){return!1}containsElement(e,r){return Rh(e,r)}getParentElement(e){return Ec(e)}query(e,r,t){return Ah(e,r,t)}computeStyle(e,r,t){return wc(e,r)}animate(e,r,t,n,o,s=[]){let a=n==0?"both":"forwards",c={duration:t,delay:n,fill:a};o&&(c.easing=o);let p=new Map,m=s.filter(E=>E instanceof As);Yv(t,n)&&m.forEach(E=>{E.currentSnapshot.forEach((k,N)=>p.set(N,k))});let _=Wv(r).map(E=>new Map(E));_=Zv(e,_,p);let y=wS(e,_);return new As(e,_,c,y)}};var Ms="@",Gh="@.disabled",Ds=class{constructor(e,r,t,n){this.namespaceId=e,this.delegate=r,this.engine=t,this._onDestroy=n,this.\u0275type=0}get data(){return this.delegate.data}destroyNode(e){this.delegate.destroyNode?.(e)}destroy(){this.engine.destroy(this.namespaceId,this.delegate),this.engine.afterFlushAnimationsDone(()=>{queueMicrotask(()=>{this.delegate.destroy()})}),this._onDestroy?.()}createElement(e,r){return this.delegate.createElement(e,r)}createComment(e){return this.delegate.createComment(e)}createText(e){return this.delegate.createText(e)}appendChild(e,r){this.delegate.appendChild(e,r),this.engine.onInsert(this.namespaceId,r,e,!1)}insertBefore(e,r,t,n=!0){this.delegate.insertBefore(e,r,t),this.engine.onInsert(this.namespaceId,r,e,n)}removeChild(e,r,t){this.engine.onRemove(this.namespaceId,r,this.delegate)}selectRootElement(e,r){return this.delegate.selectRootElement(e,r)}parentNode(e){return this.delegate.parentNode(e)}nextSibling(e){return this.delegate.nextSibling(e)}setAttribute(e,r,t,n){this.delegate.setAttribute(e,r,t,n)}removeAttribute(e,r,t){this.delegate.removeAttribute(e,r,t)}addClass(e,r){this.delegate.addClass(e,r)}removeClass(e,r){this.delegate.removeClass(e,r)}setStyle(e,r,t,n){this.delegate.setStyle(e,r,t,n)}removeStyle(e,r,t){this.delegate.removeStyle(e,r,t)}setProperty(e,r,t){r.charAt(0)==Ms&&r==Gh?this.disableAnimations(e,!!t):this.delegate.setProperty(e,r,t)}setValue(e,r){this.delegate.setValue(e,r)}listen(e,r,t){return this.delegate.listen(e,r,t)}disableAnimations(e,r){this.engine.disableAnimations(e,r)}},xc=class extends Ds{constructor(e,r,t,n,o){super(r,t,n,o),this.factory=e,this.namespaceId=r}setProperty(e,r,t){r.charAt(0)==Ms?r.charAt(1)=="."&&r==Gh?(t=t===void 0?!0:!!t,this.disableAnimations(e,t)):this.engine.process(this.namespaceId,e,r.slice(1),t):this.delegate.setProperty(e,r,t)}listen(e,r,t){if(r.charAt(0)==Ms){let n=kS(e),o=r.slice(1),s="";return o.charAt(0)!=Ms&&([o,s]=RS(o)),this.engine.listen(this.namespaceId,n,o,s,a=>{let c=a._data||-1;this.factory.scheduleListenerCallback(c,t,a)})}return this.delegate.listen(e,r,t)}};function kS(i){switch(i){case"body":return document.body;case"document":return document;case"window":return window;default:return i}}function RS(i){let e=i.indexOf("."),r=i.substring(0,e),t=i.slice(e+1);return[r,t]}var Fs=class{constructor(e,r,t){this.delegate=e,this.engine=r,this._zone=t,this._currentId=0,this._microtaskId=1,this._animationCallbacksBuffer=[],this._rendererCache=new Map,this._cdRecurDepth=0,r.onRemovalComplete=(n,o)=>{let s=o?.parentNode(n);s&&o.removeChild(s,n)}}createRenderer(e,r){let t="",n=this.delegate.createRenderer(e,r);if(!e||!r?.data?.animation){let p=this._rendererCache,m=p.get(n);if(!m){let _=()=>p.delete(n);
1m=new Ds(t,n,this.engine,_),p.set(n,m)}return m}let o=r.id,s=r.id+"-"+this._currentId;this._currentId++,this.engine.register(s,e);let a=p=>{Array.isArray(p)?p.forEach(a):this.engine.registerTrigger(o,s,e,p.name,p)};return r.data.animation.forEach(a),new xc(this,s,n,this.engine)}begin(){this._cdRecurDepth++,this.delegate.begin&&this.delegate.begin()}_scheduleCountTask(){queueMicrotask(()=>{this._microtaskId++})}scheduleListenerCallback(e,r,t){if(e>=0&&e<this._microtaskId){this._zone.run(()=>r(t));return}let n=this._animationCallbacksBuffer;n.length==0&&queueMicrotask(()=>{this._zone.run(()=>{n.forEach(o=>{let[s,a]=o;s(a)}),this._animationCallbacksBuffer=[]})}),n.push([r,t])}end(){this._cdRecurDepth--,this._cdRecurDepth==0&&this._zone.runOutsideAngular(()=>{this._scheduleCountTask(),this.engine.flush(this._microtaskId)}),this.delegate.end&&this.delegate.end()}whenRenderingDone(){return this.engine.whenRenderingDone()}};var NS=(()=>{let e=class e extends ir{constructor(t,n,o){super(t,n,o,L(Kp,{optional:!0}))}ngOnDestroy(){this.flush()}};e.\u0275fac=function(n){return new(n||e)(u(bt),u(fn),u(hn))},e.\u0275prov=I({token:e,factory:e.\u0275fac});let i=e;return i})();function DS(){return new Os}function FS(i,e,r){return new Fs(i,e,r)}var Vh=[{provide:hn,useFactory:DS},{provide:ir,useClass:NS},{provide:so,useFactory:FS,deps:[gl,ir,Zt]}],Hh=[{provide:fn,useFactory:()=>new Ns},{provide:Ea,useValue:"BrowserAnimations"},...Vh],LS=[{provide:fn,useClass:Ic},{provide:Ea,useValue:"NoopAnimations"},...Vh],qh=(()=>{let e=class e{static withConfig(t){return{ngModule:e,providers:t.disableAnimations?LS:Hh}}};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({providers:Hh,imports:[Cl]});let i=e;return i})();var Wh=(()=>{let e=class e{constructor(t,n){this.sipSiteConfigService=t,this.sipSiteService=n,this.CONFIG_ENABLE_STATIC_REDIRECT="static.url.redirect",this.CONFIG_ENABLE_EXTENDED_STATIC_REDIRECT="static.url.ext.redirect",this.CONFIG_URL_PRODUCT="url.product",this.CONFIG_URL_CATEGORY="url.category"}isExtendedStaticRedirectEnabled(){return this.sipSiteConfigService.getBooleanConfig(this.CONFIG_ENABLE_EXTENDED_STATIC_REDIRECT)}isStaticRedirectEnabled(){return this.sipSiteConfigService.getBooleanConfig(this.CONFIG_ENABLE_STATIC_REDIRECT)}getRedirectStaticMappingUri(t,n){return n.staticPageUrlMapping?.entry?.find(o=>o.key===t)?.value}getCurrentUri(t){return this.isExtendedStaticRedirectEnabled().pipe(A(n=>n?ae([this.sipSiteConfigService.getConfig(this.CONFIG_URL_PRODUCT),this.sipSiteConfigService.getConfig(this.CONFIG_URL_CATEGORY)]).pipe(x(([o,s])=>t.includes(o)?t.substring(t.lastIndexOf(o)):t.includes(s)?t.substring(t.lastIndexOf(s)):t)):D(t)))}getRedirectUri(t){return ae([this.isStaticRedirectEnabled().pipe(A(n=>n?this.getCurrentUri(t):D(null))),this.sipSiteService.getSite()]).pipe(x(([n,o])=>n?this.getRedirectStaticMappingUri(n,o):null))}};e.\u0275fac=function(n){return new(n||e)(u(Ke),u(be))},e.\u0275prov=I({token:e,factory:e.\u0275fac,providedIn:"root"});let i=e;return i})();var or=(()=>{let e=class e{constructor(t,n){this.uriRedirectFilterService=t,this.redirectService=n}canActivate(t,n){let o=t.pathFromRoot.map(c=>c.url.map(p=>p.toString()).join("/")).join("/").replace(/\/{2,}/g,"/"),s=new URLSearchParams(t.queryParams).toString(),a=`${o}${s?"?":""}${s}`;return this.uriRedirectFilterService.getRedirectUri(a).pipe(x(c=>c?this.redirectService.handleRedirect(c,{},301):!0))}};e.\u0275fac=function(n){return new(n||e)(u(Wh),u(it))},e.\u0275prov=I({token:e,factory:e.\u0275fac,providedIn:"root"});let i=e;return i})();var oe=(()=>{let e=class e{constructor(t,n){this.cmsPageGuard=t,this.uriRedirectFilterGuard=n}canActivate(t,n){return this.uriRedirectFilterGuard.canActivate(t,n).pipe(A(o=>{if(o){if(o instanceof kt)return D(o)}else return D(!1);return this.cmsPageGuard.canActivate(t,n)}),z(1))}};e.\u0275fac=function(n){return new(n||e)(u(Li),u(or))},e.\u0275prov=I({token:e,factory:e.\u0275fac,providedIn:"root"});let i=e;return i})();var Ls=(()=>{let e=class e extends qt{constructor(){super(...arguments),this._isReady=new Mp(1)}initialize(t){return J(this,null,function*(){return this.configInitializedPromise||(this.configInitializedPromise=vr(e.prototype,this,"initialize").call(this,t),this.configInitializedPromise.then(()=>{this._isReady.next(!0)},()=>{this._isReady.next(!0)})),this.isReady()})}isReady(){return this._isReady.pipe(z(1)).toPromise()}};e.\u0275fac=(()=>{let t;return function(o){return(t||(t=Le(e)))(o||e)}})(),e.\u0275prov=I({token:e,factory:e.\u0275fac,providedIn:"root"});let i=e;return i})();var De=(()=>{let e=class e{constructor(){this.configInitializerService=L(Ls),this.checkoutService=L(Vn),this._logger=L(et).getLogger("SipAppInitGuard")}canActivate(t,n){return J(this,null,function*(){if(am.every(o=>!n.url?.includes(o)))try{yield this.checkoutService.restoreOriginalCartIfPresent()}catch(o){this._logger.error("Caught an error restoring the original cart: ",o)}return yield this.configInitializerService.isReady()})}};e.\u0275fac=function(n){return new(n||e)},e.\u0275prov=I({token:e,factory:e.\u0275fac,providedIn:"root"});let i=e;return i})();function Ac(i,e,r){return i.length>0&&r.data?.pattern.some(t=>t.test(`/${i.map(n=>n.path).join("/")}`))?{consumed:i}:null}var Nc=(()=>{let e=class e{constructor(){this.redirectService=L(it),this.windowRef=L(K)}canActivate(t,n){if(t.data?.proxy){if(this.windowRef.isBrowser())throw new Error("InvalidUrlGuard");return!1}return this.redirectService.handleRedirect("/pageNotFound",{},301)}};e.\u0275fac=function(n){return new(n||e)},e.\u0275prov=I({token:e,factory:e.\u0275fac,providedIn:"root"});let i=e;return i})();var Kh=i=>({hidden:i}),js=(()=>{let e=class e{constructor(t,n,o,s,a,c,p,m){this.activatedRoute=t,this.router=n,this.globalMessageService=o,this.scrollRestorationService=s,this.ngZone=a,this.sipGtmService=c,this.cmsService=p,this.contentStackConfigService=m,this.subscription=new Ee,this.logoutQueryParam="logout",this.page$=new Xr("")}
1ngAfterViewInit(){this.scrollRestorationService.restore(),this.sipGtmService.pushHomePageEvent()}ngOnInit(){let t=this.contentStackConfigService.getContentStackPage().subscribe(o=>{this.isContentStackPage=o}),n=this.activatedRoute.queryParams.pipe(j(o=>o[this.logoutQueryParam]==="true"),Ot(o=>{this.globalMessageService.addMessage({key:"account.confirmation.signout.title"},je.MSG_TYPE_INFO),this.ngZone.runOutsideAngular(()=>{let s=R({},o);delete s[this.logoutQueryParam],this.router.navigate([],{relativeTo:this.activatedRoute,queryParams:s,replaceUrl:!0})})}),z(1)).subscribe();this.subscription.add(n),this.subscription.add(t),this.filterContentStack()}filterContentStack(){let t=this.cmsService.getContentSlot("contentStack").pipe(z(1)).subscribe(n=>{this.page$.next(n)});this.subscription.add(t)}ngOnDestroy(){this.subscription.unsubscribe()}};e.\u0275fac=function(n){return new(n||e)(O(In),O(re),O(Nt),O(Lu),O(Zt),O(qn),O(kn),O(Pt))},e.\u0275cmp=F({type:e,selectors:[["sip-home-page"]],decls:25,vars:22,consts:[[1,"page","homepage"],[1,"no-space",3,"ngClass"],[1,"row","no-space-mobile-banner"],[1,"col-sm-12","no-space","slider-component-wrapper","homepage-hero"],["position","Section1A",3,"forceRender"],["position","SectionPromotions",3,"forceRender"],["position","Section4",3,"forceRender"],["position","Section5",3,"forceRender"],["position","Section6",3,"forceRender"],["position","Section7",3,"forceRender"],[1,"row","no-space-mobile-banner","layout-no-gutter","is-4-col","homepage-banners",3,"ngClass"],[1,"col-xs-12","col-sm-6","col-md-3","no-space-mobile","col-tablet-margin-bottom","homepage-banner-item"],["position","Section2A",3,"forceRender"],["position","Section2B",3,"forceRender"],[1,"col-xs-12","col-sm-6","col-md-3","no-space-mobile","clear-left-tablet","homepage-banner-item"],["position","Section2C",3,"forceRender"],[1,"col-xs-12","col-sm-6","col-md-3","no-space-mobile","homepage-banner-item"],["position","Section2D",3,"forceRender"],[1,"row",3,"ngClass"],[1,"col-xs-12","stack-up-savings-component"],["position","Section3",3,"forceRender"],["position","WhyCostco",3,"forceRender"],[3,"page"]],template:function(n,o){n&1&&(S(0,"div",0)(1,"div",1)(2,"div",2)(3,"div",3),P(4,"sip-page-slot",4),b()(),P(5,"sip-page-slot",5)(6,"sip-page-slot",6)(7,"sip-page-slot",7)(8,"sip-page-slot",8)(9,"sip-page-slot",9),S(10,"div",10)(11,"div",11),P(12,"sip-page-slot",12),b(),S(13,"div",11),P(14,"sip-page-slot",13),b(),S(15,"div",14),P(16,"sip-page-slot",15),b(),S(17,"div",16),P(18,"sip-page-slot",17),b()()(),S(19,"div",18)(20,"div",19),P(21,"sip-page-slot",20),b()(),P(22,"sip-page-slot",21)(23,"sip-generic-content-page",22),w(24,"async"),b()),n&2&&(d(),l("ngClass",ve(18,Kh,o.isContentStackPage)),d(3),l("forceRender",!0),d(),l("forceRender",!0),d(),l("forceRender",!0),d(),l("forceRender",!0),d(),l("forceRender",!0),d(),l("forceRender",!0),d(),l("ngClass",o.isContentStackPage?"":"homepage-banners-border-bottom"),d(2),l("forceRender",!0),d(2),l("forceRender",!0),d(2),l("forceRender",!0),d(2),l("forceRender",!0),d(),l("ngClass",ve(20,Kh,o.isContentStackPage)),d(2),l("forceRender",!0),d(),l("forceRender",!0),d(),l("page",T(24,16,o.page$)))},dependencies:[Ie,ja,Ua,q],styles:['[_nghost-%COMP%] owl-carousel-o .owl-carousel{display:flex!important;flex-direction:column}@media screen and (max-width: 767px){[_nghost-%COMP%] owl-carousel-o .owl-carousel{min-height:220px}}[_nghost-%COMP%] owl-carousel-o .owl-dots{margin-top:auto}[_nghost-%COMP%] .featured-content-component img{min-height:120px}@media screen and (max-width: 767px){[_nghost-%COMP%] .featured-content-component img{min-height:60px}}[_nghost-%COMP%] sip-product-carousel{min-height:480px}[_nghost-%COMP%] sip-product-carousel.has-title{min-height:520px}@media screen and (max-width: 767px){[_nghost-%COMP%] sip-product-carousel{min-height:400px}}[_nghost-%COMP%] sip-product-carousel .owl-stage{display:flex}@media screen and (min-width: 1024px){[_nghost-%COMP%] sip-product-carousel .owl-stage .owl-item{flex:1 1 auto}}@media screen and (min-width: 1024px){[_nghost-%COMP%] .no-space{padding:0!important}[_nghost-%COMP%] .padd-right{padding-right:8px}[_nghost-%COMP%] .padd-left{padding-left:8px}[_nghost-%COMP%] .slider-component-wrapper{width:100%}[_nghost-%COMP%] .slider_component{width:100%}[_nghost-%COMP%] .row2{margin-left:12px;margin-right:12px}[_nghost-%COMP%] .triple-banner{padding:16px!important}[_nghost-%COMP%] .triple-banner:after{content:"";position:absolute;right:0;top:15%;height:70%;width:1px;border-right:solid 1px #9c9c9c}[_nghost-%COMP%] .triple-banner:last-child:after{border:none}}@media screen and (max-width: 767px){[_nghost-%COMP%] .no-space-mobile{padding:0}[_nghost-%COMP%] .no-space-mobile-banner{margin-left:-8px!important;margin-right:-8px!important}[_nghost-%COMP%] .page-homepage .top.banner-component{margin-top:0}}[_nghost-%COMP%] .homepage-hero .banner-component{margin-top:0}[_nghost-%COMP%] .homepage-hero .banner-component__content-align-wrapper{text-align:right}[_nghost-%COMP%] .banner-component.right .banner-component__content{width:100%!important}[_nghost-%COMP%] .banner-component.top .banner-component__content{position:absolute;top:0}@media screen and (max-width: 767px){[_nghost-%COMP%] .stack-up-savings-component .banner-component__title{display:block!important}[_nghost-%COMP%] .stack-up-savings-component .banner-component__title span{padding-right:0!important}[_nghost-%COMP%] .stack-up-savings-component .banner-component__content{position:inherit!important;transform:inherit!important}[_nghost-%COMP%] .stack-up-savings-component .banner-component__img{display:none}[_nghost-%COMP%] .stack-up-savings-component .banner-component__paragraph{text-align:center}}@media screen and (min-width: 768px) and (max-width: 1024px) and (orientation: portrait){[_nghost-%COMP%] .stack-up-savings-component{padding:0 2em}}[_nghost-%COMP%] .homepage-banners-border-bottom{border-bottom:solid 1px #9c9c9c}@media screen and (max-width: 767px){[_nghost-%COMP%] .homepage-banners{padding:0;margin-top:0}}[_nghost-%COMP%] h1.banner-component__title{font-size:21px}[_nghost-%COMP%] p.banner-component__title{font-size:21px}@media screen and (min-width: 1400px){[_nghost-%COMP%] .homepage-banner-item .banner-component__content{padding:1em 1.1em}}@media screen and (min-width: 1024px){[_nghost-%COMP%] .homepage-banner-item .banner-component__content{padding:.6em .7em}}[_nghost-%COMP%] .page.homepage .costco-carousel-component+.homepage-banners, [_nghost-%COMP%] .page.homepage .featured-content-collection+.homepage-banners{border-top:1px solid #cccccc;margin-top:12px;padding-top:12px}[_nghost-%COMP%] .page.homepage .featured-content-collection+.featured-content-collection{margin-top:0}[_nghost-%COMP%] .page.homepage .costco-carousel-component{margin:16px 0 0}[_nghost-%COMP%] .page.homepage .costco-carousel-component .headline+div.carousel{margin-bottom:24px}[_nghost-%COMP%] .banner-component .banner-component__content .costco-hero-title{color:#333;font-size:31px;font-weight:400;padding-top:.4em;margin-top:.75em;padding-right:.7em;display:inline-block}@media screen and (min-width: 768px) and (max-width: 1023px){[_nghost-%COMP%] .banner-component .banner-component__content .costco-hero-title{font-size:26px}}@media screen and (max-width: 767px){[_nghost-%COMP%] .banner-component .banner-component__content .costco-hero-title{font-size:20px}}@media screen and (max-width: 320px){[_nghost-%COMP%] .banner-component .banner-component__content .costco-hero-title{font-size:15px}}[_nghost-%COMP%] .banner-component .banner-component__content .costco-hero-paragraph{color:#333;font-size:18px;display:inline-block;margin-left:0;padding-right:1em}@media screen and (min-width: 768px) and (max-width: 1023px){[_nghost-%COMP%] .banner-component .banner-component__content .costco-hero-paragraph{font-size:19px}}@media screen and (max-width: 767px){[_nghost-%COMP%] .banner-component .banner-component__content .costco-hero-paragraph{font-size:14px}}@media screen and (max-width: 320px){[_nghost-%COMP%] .banner-component .banner-component__content .costco-hero-paragraph{font-size:11px}}[_nghost-%COMP%] .banner-component .banner-component__content .costco-hero-call-to-action{dis
1play:inline-block;background-color:#325c82;color:#fff;font-size:16px;padding:.4em 1em;margin:.8em 1em 0 0;transition:background-color .2s}@media screen and (max-width: 767px){[_nghost-%COMP%] .banner-component .banner-component__content .costco-hero-call-to-action{font-size:13px}}@media screen and (max-width: 320px){[_nghost-%COMP%] .banner-component .banner-component__content .costco-hero-call-to-action{font-size:11px}}[_nghost-%COMP%] .banner-component .banner-component__content .costco-banner-title{color:#333;font-size:18px;font-weight:400;margin:.1em 0 0 .1em;display:inline-block}[_nghost-%COMP%] .banner-component .banner-component__content .costco-banner-title.larger-banner-title{font-size:26px}@media screen and (min-width: 1400px){[_nghost-%COMP%] .banner-component .banner-component__content .costco-banner-title{font-size:20px}}@media screen and (min-width: 768px) and (max-width: 1023px){[_nghost-%COMP%] .banner-component .banner-component__content .costco-banner-title{font-size:24px;margin:.2em 0 0 .2em}}@media screen and (max-width: 767px){[_nghost-%COMP%] .banner-component .banner-component__content .costco-banner-title{font-size:22px}[_nghost-%COMP%] .banner-component .banner-component__content .costco-banner-title.larger-banner-title{font-size:18px}}[_nghost-%COMP%] .banner-component .banner-component__content .costco-banner-paragraph{margin-left:0;padding-right:1.6em;font-size:16px;margin-top:.5em;color:#565656;display:block}@media screen and (min-width: 1400px){[_nghost-%COMP%] .banner-component .banner-component__content .costco-banner-paragraph{font-size:16px}}@media screen and (min-width: 768px) and (max-width: 1023px){[_nghost-%COMP%] .banner-component .banner-component__content .costco-banner-paragraph{font-size:18px;margin-left:.3em}}@media screen and (max-width: 767px){[_nghost-%COMP%] .banner-component .banner-component__content .costco-banner-paragraph{font-size:15px}}[_nghost-%COMP%] .banner-component .banner-component__content .costco-banner-call-to-action{color:#0060a9;margin:0 0 .25em .1em;padding-bottom:0;font-size:12px;display:inline-block;border-bottom:1px solid transparent;transition:border-bottom .2s ease-out}[_nghost-%COMP%] .banner-component .banner-component__content .costco-banner-call-to-action:after{content:" >"}@media screen and (min-width: 1400px){[_nghost-%COMP%] .banner-component .banner-component__content .costco-banner-call-to-action{font-size:13px}}@media screen and (min-width: 768px) and (max-width: 1023px){[_nghost-%COMP%] .banner-component .banner-component__content .costco-banner-call-to-action{font-size:18px;margin-left:.25em}}@media screen and (max-width: 767px){[_nghost-%COMP%] .banner-component .banner-component__content .costco-banner-call-to-action{font-size:15px}}[_nghost-%COMP%] .banner-component:hover .costco-banner-call-to-action{border-bottom:1px solid #0060a9;transition:border-bottom .2s ease-in}[_nghost-%COMP%] .banner-component:hover .costco-hero-call-to-action{background-color:#4175a4;transition:background-color .2s}'],changeDetection:0});let i=e;return i})();var Qh=(i,e)=>{let r=L(Pt),t=L(re),n=e.url,o=ju.join("|");if(!new RegExp(`^/live-preview/[^/]+/[^/]+/(${o})/[a-zA-Z0-9]+$`).test(n))return t.navigate([Tu]),!1;let a=i.params.environment;return r.getStackFromBFF(a)};var Fc=[{matcher:Ac,data:{pattern:[/^\/logout/,/^\/maintenance$/,/^\/mediapermalink/,/^\/checkout\/(?!confirmation(\/|$)|single(\/|$)|splitAddress(\/|$))/,/^\/cart\/pre-checkout/,/^\/cart\/checkout/,/^\/renew$/,/^\/paypal\//,/^\/customer-care-search$/,/^\/login\/checkout\/membership-guest/],proxy:!0},canActivate:[Nc],component:gi},{path:"",pathMatch:"full",canActivate:[oe],component:js},{matcher:Ac,data:{pattern:[/.*\/[cp]$/]},canActivate:[Nc],component:gi},{path:"content/:contentPageId",canActivate:[oe],component:gi},{path:"cx-preview",canActivate:[oe],component:gi},{path:"productNotFound",canActivate:[oe],component:gi},{path:dt.NO_RESULT_PAGE,canActivate:[oe],component:Au},{path:Lo.NOT_FOUND_PAGE,canActivate:[oe],component:gi},{path:"live-preview/:environment/:locale/:contentType/:entryId",canActivate:[Qh,oe],loadChildren:()=>import("./chunk-NBGYPJYV.js").then(i=>i.SipLivePreviewPageModule)},{path:"",redirectTo:"/invalid-page",pathMatch:"full"}];Fc=[{path:"",canActivate:[De],children:Fc}];var Yh=(()=>{let e=class e{static forRoot(){return{ngModule:e}}};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({imports:[_m,G.forRoot(Fc,{useHash:!1,initialNavigation:"enabledBlocking",anchorScrolling:"enabled",scrollPositionRestoration:"enabled"}),rm,G]});let i=e;return i})();var Zh=(()=>{let e=class e{constructor(t,n,o,s){this.router=t,this.cmsService=n,this.sipCmsService=o,this.contentStackConfigService=s,this.componentInfo$=this.getBreadcrumbVisibility()}getBreadcrumbVisibility(){return this.router.events.pipe(j(t=>t instanceof pn),A(()=>this.contentStackConfigService.getContentStackPage().pipe(A(t=>t?this.cmsService.getContentStackPageData().pipe(A(n=>{let o=n?.siteSettings?.[0],s=n?.type;return!o?.breadcrumb&&s!==Ue.CONTENT_PAGE?D(null):this.sipCmsService.getCurrentPage().pipe(x(a=>{if(s===Ue.CONTENT_PAGE&&a?.pageId==="categoryLandingPage")s=Ue.CATEGORY_PAGE;else if(s===Ue.CONTENT_PAGE)switch(n?.breadcrumb?.breadcrumb_options){case $a.DEFAULT:return{breadcrumb:!0};case $a.CUSTOM:return n?.breadcrumb?.html_render_component_block?{html_render_component_block:n?.breadcrumb?.html_render_component_block}:null;default:return null}let c=o.breadcrumb[s];return c?{breadcrumb:c}:null}))})):D(null)))))}};e.\u0275fac=function(n){return new(n||e)(u(re),u(is),u(xe),u(Pt))},e.\u0275prov=I({token:e,factory:e.\u0275fac,providedIn:"root"});let i=e;return i})();function GS(i,e){i&1&&P(0,"div",1)}var Xh=(()=>{let e=class e{constructor(t,n,o){this.siteService=t,this.languageService=n,this.document=o,this.scriptElementName="script",this.langIsoPipe=new ns}ngOnInit(){this.injectGoogleTranslateScripts()}createScriptElement(t){return this.document.createElement(t)}injectGoogleTranslateScripts(){this.siteService.getSite().pipe(to(this.languageService.getActive())).subscribe(([t,n])=>{if(n||(n=t.defaultLanguage.isocode),t.autoTranslate&&t.defaultLanguage.isocode&&t.stores[0].translateLanguages&&n!==t.defaultLanguage.isocode){this.googleTranslateEnabled=!0;let o=this.createScriptElement(this.scriptElementName);o.id="google-translate",o.src="//translate.google.com/translate_a/element.js?cb=googleTranslateElementInit",o.defer="defer";let s=this.createScriptElement(this.scriptElementName);this.defaultSiteLanguage=this.langIsoPipe.transform(t.defaultLanguage.isocode),s.text=` 2 function googleTranslateElementInit() { 3 new google.translate.TranslateElement( 4 { 5 pageLanguage: '${this.defaultSiteLanguage}', 6 includedLanguages: '${this.langIsoPipe.transform(t.stores[0].translateLanguages)},${this.defaultSiteLanguage}', 7 layout: google.translate.TranslateElement.FloatPosition.TOP_LEFT, 8 autoDisplay: false 9 }, 10 'google_translate_element');}`,this.document.getElementById(o.id)||(this.document.head.appendChild(o),this.document.head.appendChild(s))}}).unsubscribe()}};e.\u0275fac=function(n){return new(n||e)(O(be),O(fi),O(bt))},e.\u0275cmp=F({type:e,selectors:[["sip-google-translate"]],decls:1,vars:1,consts:[["id","google_translate_element","class","hidden",4,"ngIf"],["id","google_translate_element",1,"hidden"]],template:function(n,o){n&1&&v(0,GS,1,0,"div",0),n&2&&l("ngIf",o.googleTranslateEnabled)},dependencies:[W],encapsulation:2,changeDetection:0});let i=e;return i})();var Jh=(()=>{let e=class e{constructor(t){this.loggerFactory=t,this.imageVersion=Fo.IMAGE_VERSION,this.uid=this.loggerFactory.uuid,this.troubleshootingString=D((this.imageVersion?`i.${this.imageVersion}`:"")+` s.${this.uid}`)}};e.\u0275fac=function(n){return new(n||e)(O(et))},e.\u0275cmp=F({type:e,selectors:[["sip-troubleshooting-information"]],decls:3,vars:3,consts:[[1,"troubleshooting-information"]],template:function(n,o){n&1&&(S(0,"p",0),H(1),w(2,"async"),b()),n&2&&(d(),le(" ",T(2,1,o.troubleshootingString),` 11`))},dependencies:[q],styles:[".troubleshooting-information[_ngcontent-%COMP%]{position:fixed;bottom:0;right:0;background:#ffffff7a;z-index:99999999;pointer-events:none;border:1px solid black;border-width:1px 0 0 1px;padding:0 5px}.troubleshooting-information[_ngcontent-%COMP%]:hover{opacity:0}
11"],changeDetection:0});let i=e;return i})();var eg=(()=>{let e=class e{constructor(t){this.winRef=t,this.SCROLL_EVENT_THROTTLE_TIME=200,this.fadeAnimation$=D("")}ngOnInit(){this.winRef.nativeWindow&&(this.fadeAnimation$=kp(this.winRef.nativeWindow,"scroll").pipe(Np(this.SCROLL_EVENT_THROTTLE_TIME),Dp(300),x(t=>this.winRef.nativeWindow.pageYOffset>100?"in":"out")))}scrollToTop(t){t.preventDefault(),this.winRef.nativeWindow.scrollTo({top:0,left:0,behavior:"smooth"})}};e.\u0275fac=function(n){return new(n||e)(O(K))},e.\u0275cmp=F({type:e,selectors:[["sip-back-to-top-button"]],decls:7,vars:6,consts:[["id","back2Top",1,"btn_backtotop",3,"click"],["aria-hidden","true",1,"glyphicon","glyphicon-chevron-up"]],template:function(n,o){n&1&&(S(0,"div",0),w(1,"async"),Ce("click",function(a){return o.scrollToTop(a)}),P(2,"span",1)(3,"br"),S(4,"span"),H(5),w(6,"cxTranslate"),b()()),n&2&&(l("@fade",T(1,2,o.fadeAnimation$)),d(5),Be(T(6,4,"text.back2Top")||"TOP"))},dependencies:[q,xt],data:{animation:[bl("fade",[wa("in",cn({opacity:1,display:"block"})),wa("out",cn({opacity:0})),Ta("out => in",[cn({display:"block"}),Oa("0.5s")]),Ta("in => out",Oa("0.5s"))])]},changeDetection:0});let i=e;return i})();var WS=["app-root",""];function KS(i,e){i&1&&P(0,"sip-checkout-header")}function QS(i,e){i&1&&P(0,"sip-header")}function YS(i,e){if(i&1&&(B(0),v(1,KS,1,0,"sip-checkout-header",11),w(2,"async"),v(3,QS,1,0,"ng-template",null,0,ne),U()),i&2){let r=Y(4),t=C();d(),l("ngIf",T(2,2,t.useCheckoutHeader$))("ngIfElse",r)}}function ZS(i,e){if(i&1&&(S(0,"div",12),P(1,"sip-cs-dynamic-component",13),b()),i&2){let r=e.ngIf;d(),l("componentInfo",r)}}function XS(i,e){i&1&&P(0,"sip-troubleshooting-information")}var ig=(()=>{let e=class e{constructor(t,n,o,s,a,c,p,m){this.router=t,this.titleService=n,this.cmsService=o,this.breadcrumbService=s,this.document=c,this.platformId=p,this._i18next=m,this.checkoutHeaderPaths=["/costcocheckout",tt.CHECKOUT,tt.SPLIT_ADDRESS],this.isProd=Fo.IS_PROD,this.subscription=new Ee,this.i18next=this._i18next||Ol,ct(p)&&a.runOutsideAngular(()=>{this.subscription.add(ae([this.router.events.pipe(j(_=>_ instanceof pn),eo(1)),this.cmsService.getCurrentPage()]).subscribe(([_,y])=>{this.titleService.setTitle(y.title)}))})}ngOnInit(){this.useCheckoutHeader$=this.router.events.pipe(j(t=>t instanceof pn),x(t=>{for(let n of this.checkoutHeaderPaths)if(t.url.includes(n))return!0;return!1})),this.isLivePreviewPage=this.document.URL.includes(fm),this.componentInfo$=this.breadcrumbService.componentInfo$}ngOnDestroy(){this.subscription.unsubscribe(),this.i18next.off("languageChanged",void 0)}};e.\u0275fac=function(n){return new(n||e)(O(re),O(uo),O(Pu),O(Zh),O(Zt),O(bt),O(Ne),O(Bm))},e.\u0275cmp=F({type:e,selectors:[["","app-root",""]],hostAttrs:["tabIndex","-1"],attrs:WS,decls:16,vars:6,consts:[["regularHeader",""],[4,"ngIf"],[1,"container","bottom-header",3,"sip-page-slot"],["class","container bottom-header",4,"ngIf"],["id","globalMessages",1,"container","main-wrapper"],["id","skip-to-content","tabindex","-1"],[1,"page-content","container","main-wrapper"],["sip-footer","",1,"main-footer"],["name","accessiblityForm"],["type","hidden","id","accesibility_refreshScreenReaderBufferField","name","accesibility_refreshScreenReaderBufferField","value",""],["id","ariaStatusMsg","role","status","aria-relevant","text","aria-live","polite",1,"skip"],[4,"ngIf","ngIfElse"],[1,"container","bottom-header"],[3,"componentInfo"]],template:function(n,o){n&1&&(v(0,YS,5,4,"ng-container",1),P(1,"div",2),v(2,ZS,2,1,"div",3),w(3,"async"),S(4,"div",4),P(5,"sip-global-message"),b(),P(6,"div",5)(7,"sip-back-to-top-button"),S(8,"div",6),P(9,"router-outlet"),b(),P(10,"footer",7),S(11,"form",8),P(12,"input",9),b(),P(13,"div",10)(14,"sip-google-translate"),v(15,XS,1,0,"sip-troubleshooting-information",1)),n&2&&(l("ngIf",!o.isLivePreviewPage),d(),l("sip-page-slot","BottomHeader"),d(),l("ngIf",T(3,4,o.componentInfo$)),d(13),l("ngIf",!o.isProd))},dependencies:[Il,W,rf,hf,of,Hu,Xh,Jh,gf,eg,Dn,q],styles:["[_nghost-%COMP%]{outline:none;overflow-x:hidden}.main-wrapper[_ngcontent-%COMP%]{position:relative}.container[_ngcontent-%COMP%]{padding-bottom:0}"],changeDetection:0});let i=e;return i})();function Bs(i){let e=[];
11if(e.push({label:i.category.name,link:i.category.url}),i.category.supercategories)for(let r of i.category.supercategories)e.unshift({label:r.name,link:r.url});return e}var cr=function(i){return i.GOOGLE_SITE_VERIFICATION_KEY="searchengine.meta.google.verification.key",i.NAVER_SITE_VERIFICATION_KEY="searchengine.meta.naver.verification.key",i.OPEN_GRAPH_TYPE_WEBSITE="website",i.OPEN_GRAPH_TYPE_PRODUCT="og:product",i}(cr||{});var bi=(()=>{let e=class e extends Wd{constructor(t,n,o,s){super(t,n,s),this.ngTitle=t,this.ngMeta=n,this.document=o,this.pageMetaService=s,this._subscription=new Ee,this.previousSchemaOrg=[]}set title(t){this.ngTitle.setTitle(t||""),this.addTag({name:"title",content:t}),this.openGraphTitle=t}set metaTitle(t){this.addTag({name:"title",content:t}),this.openGraphTitle=t}set keywords(t){this.addTag({name:"keywords",content:t})}set description(t){super.description=t,this.openGraphDescription=t}set robots(t){this.addTag({name:"robots",content:t.toString()})}set googleSiteVerification(t){this.addTag({name:"google-site-verification",content:t})}set naverSiteVerification(t){this.addTag({name:"naver-site-verification",content:t})}set openGraph(t){this.addTag({property:"og:type",content:t})}set openGraphURL(t){this.addTag({property:"og:url",content:t})}set openGraphTitle(t){this.addTag({property:"og:title",content:t})}set openGraphDescription(t){this.addTag({property:"og:description",content:t})}set openGraphImage(t){this.addTag({property:"og:image",content:t})}set image(t){this.openGraphImage=t}set thumbnail(t){this.addTag({name:"thumbnail",content:t})}set schemaOrg(t){this.insertSchemaOrg(t)}set bvUserAuth(t){this.addTag({name:"bv:userToken",content:t})}set amount(t){this.addTag({property:"product:price:amount",content:t})}set currency(t){this.addTag({property:"product:price:currency",content:t})}insertSchemaOrg(t){this.previousSchemaOrg&&this.previousSchemaOrg.forEach(n=>{this.removeHeadElementIfExists(this.document.getElementById(`${n}`))}),this.document.getElementById(e.organizationSchemaOrgId)&&this.removeHeadElementIfExists(this.document.getElementById(e.organizationSchemaOrgId)),this.document.getElementById(e.websiteSchemaOrgId)&&this.removeHeadElementIfExists(this.document.getElementById(e.websiteSchemaOrgId)),this.previousSchemaOrg=Object.keys(t);for(let n in t)this.removeHeadElementIfExists(this.document.getElementById(n)),this.insertSchemaOrgElement(n,t[n])}insertSchemaOrgElement(t,n){let o=JSON.parse(n),s=this.document.createElement("script");s.id=t,s.type="application/ld+json",s.text=Wt(o),this.document.head.appendChild(s)}set canonicalLink(t){this.setLink("canonical",t),this.openGraphURL=t}set nextLink(t){this.setLink("next",t)}set prevLink(t){this.setLink("prev",t)}setLink(t,n){if(this.removeHeadElementIfExists(this.document.head.querySelectorAll(`[rel=${t}]`)[0]),typeof n<"u"&&n!=null){let o=this.document.createElement("link");o.setAttribute("rel",t),o.setAttribute("href",n),this.document.head.appendChild(o)}}set alternateLinks(t){this.document.head.querySelectorAll("[rel=alternate]").forEach(n=>this.removeHeadElementIfExists(n)),t&&t.forEach(n=>{let o=this.document.createElement("link");o.setAttribute("rel","alternate"),o.setAttribute("hreflang",n.hreflang),o.setAttribute("href",n.href),this.document.head.appendChild(o)})}removeHeadElementIfExists(t){t&&this.document.head.removeChild(t)}init(){this.metadata$=this.pageMetaService.getMeta().pipe(j(t=>!!t)),this.handleAttribute("title"),this.handleAttribute("keywords"),this.handleAttribute("description"),this.handleAttribute("image"),this.handleAttribute("robots"),this.handleAttribute("googleSiteVerification"),this.handleAttribute("naverSiteVerification"),this.handleAttribute("openGraph"),this.handleAttribute("thumbnail"),this.handleAttribute("canonicalLink"),this.handleAttribute("nextLink"),this.handleAttribute("prevLink"),this.handleAttribute("alternateLinks"),this.handleAttribute("schemaOrg"),this.handleAttribute("amount"),this.handleAttribute("currency"),this.handleAttribute("bvUserAuth")}ngOnDestroy(){this._subscription.unsubscribe()}handleAttribute(t){this._subscription.add(this.metadata$.pipe(j(Boolean),rt(t),X()).subscribe(n=>{try{this[t]=n}catch{}}))}};e.websiteSchemaOrgId="schemaorg_website",e.organizationSchemaOrgId="schemaorg_organization",e.\u0275fac=function(n){return new(n||e)(u(uo),u(yl),u(bt),u(Vi))},e.\u0275prov=I({token:e,factory:e.\u0275fac,providedIn:"root"});let i=e;return i})();var Zi=(()=>{let e=class e extends ud{constructor(t,n,o,s,a){super(),this.sipSiteConfigService=t,this.occEndpointsService=n,this.http=o,this.windowRef=s,this.bffEndpointsService=a,this.request=L(Un,{optional:!0})}resolveNaverSiteVerification(){return this.sipSiteConfigService.getConfig(cr.NAVER_SITE_VERIFICATION_KEY).pipe(x(t=>({naverSiteVerification:t})))}resolveGoogleSiteVerification(){return this.sipSiteConfigService.getConfig(cr.GOOGLE_SITE_VERIFICATION_KEY).pipe(x(t=>({googleSiteVerification:t})))}resolveOpenGraph(){return D({openGraph:cr.OPEN_GRAPH_TYPE_WEBSITE})}resolveOpenGraphProduct(){return D({openGraph:cr.OPEN_GRAPH_TYPE_PRODUCT})}resolveRobots(){return D({robots:[Se.INDEX.toLowerCase(),Se.FOLLOW.toLowerCase()]})}resolveCanonicalLink(){let t;this.request?t=this.request.fullUrl:t=new URL(this.windowRef.document.URL);let n=decodeURIComponent(t.href.replace(t.protocol,"https:"));return D({canonicalLink:n})}setSchemaUrl(t){let n;try{n=JSON.parse(t.schemaOrg)}catch{n={}}let o;try{o=JSON.parse(t.schemaOrgOrganization)}catch{o={}}let s=this.request?this.request.fullUrl.toString():this.windowRef.document.URL;return n.url=s?.split("?")[0],this.currentPageUid==="homepage"||s?.split("?")[0]?.endsWith("/")?t.schemaOrg={[bi.organizationSchemaOrgId]:Wt(o)}:t.schemaOrg={[bi.websiteSchemaOrgId]:Wt(n)},R({},t)}pipeMerge(t){return t.pipe(Bp((n,o)=>{let s=o.filter(p=>p&&p.schemaOrg).map(p=>p.schemaOrg),a=Object.assign({},...s),c=Object.assign({},n,...o);return c.schemaOrg=a,c},{schemaOrg:[]}))}fetchMetadata(t,n){this.currentPageUid=t,t.includes("/")&&(n=R({code:t},n),t=sm);let o=this.bffEndpointsService.resolveEndpointUrl("metadata",{urlParam
11s:{pageId:t},queryParams:n?.code?n:{queryParams:n}});return this.http.get(o).pipe(_t(1))}};e.\u0275fac=function(n){return new(n||e)(u(Ke),u(Je),u(We),u(K),u(yi))},e.\u0275prov=I({token:e,factory:e.\u0275fac,providedIn:"root"});let i=e;return i})();var zs=(()=>{let e=class e{constructor(t,n){this.cms=t,this.contentStackConfigService=n,this.cms$=this.cms.getCurrentPage().pipe(j(o=>!!o))}resolveRobots(){return this.cms$.pipe(x(({robots:t})=>({robots:this.normalizeMetaRobots(t)})))}resolveKeywords(){return this.cms$.pipe(x(({keywords:t})=>t?{keywords:t}:{}))}resolveDescription(t){return this.cms$.pipe(x(({description:n})=>({description:n})))}normalizeMetaRobots(t){if(typeof t=="string"&&t)switch(t){case"index_follow":return[Se.INDEX.toLowerCase(),Se.FOLLOW.toLowerCase()];case"noindex_nofollow":return[Se.NOINDEX.toLowerCase(),Se.NOFOLLOW.toLowerCase()];case"index_nofollow":return[Se.INDEX.toLowerCase(),Se.NOFOLLOW.toLowerCase()];case"noindex_follow":return[Se.NOINDEX.toLowerCase(),Se.FOLLOW.toLowerCase()];default:return[Se.INDEX.toLowerCase(),Se.FOLLOW.toLowerCase()]}return[Se.INDEX.toLowerCase(),Se.FOLLOW.toLowerCase()]}updateSchema(t){return this.contentStackConfigService.getContentStackPage().pipe(A(n=>n?this.cms$.pipe(x(o=>{let s=o.schemaOrgOrganization,a=R({},t.schemaOrg);return a&&a?.[bi.websiteSchemaOrgId]&&s?a=ie(R({},a),{[bi.websiteSchemaOrgId]:Wt(s)}):a&&a?.[bi.organizationSchemaOrgId]&&s&&(a=ie(R({},a),{[bi.organizationSchemaOrgId]:Wt(s)})),{schemaOrg:a}})):D(t)))}};e.\u0275fac=function(n){return new(n||e)(u(xe),u(Pt))},e.\u0275prov=I({token:e,factory:e.\u0275fac,providedIn:"root"});let i=e;return i})();var rg=(()=>{let e=class e extends Zi{constructor(t,n,o,s,a,c,p,m,_,y,E,k,N){super(o,c,p,m,y),this.siteService=t,this.productSearchService=n,this.sipSiteConfigService=o,this.router=s,this.cms=a,this.occEndpointsService=c,this.http=p,this.windowRef=m,this.translationService=_,this.bffEndpointsService=y,this.sipRoutingService=E,this.contentStackConfigService=k,this.csPageResolver=N,this.BREADCRUMB_TIRE_SEARCH="tires.tire.breadcrumb.search",this.BREADCRUMB_TIRE_CHOOSESIZE="tires.tire.breadcrumb.search.choosesize",this.BREADCRUM_AUTOMOTIVE_SEARCH="automotive.breadcrumb.search.chooseservice",this.TIRE_SEARCH=Uo,this.cms$=this.cms.getCurrentPage().pipe(j(Q=>!!Q)),this.pageType=Ue.CONTENT_PAGE}resolveMetaData(){return this.pipeMerge(ae([this.resolveTitle(),this.resolveBreadcrumbs(),this.resolveNaverSiteVerification(),this.resolveGoogleSiteVerification(),this.resolveCanonicalLink(),this.resolveOpenGraph(),this.resolveMetaDataFromOcc().pipe(A(t=>ae([this.resolveDescription(t),this.csPageResolver.updateSchema(t),this.resolveRobots(),this.resolveKeywords()]).pipe(x(([n,o,s,a])=>R(R(R(R(R({},t),n),o),s),a))))),this.resolveBvUserAuth()]))}resolveBreadcrumbs(){return this.cms.getCurrentPage().pipe(j(Boolean),A(t=>t.pageId===dt.NO_RESULT_PAGE?this.productSearchService.getResults().pipe(j(Boolean),x(n=>n.category?{breadcrumbs:Bs(n)}:{breadcrumbs:[{label:t.title||t.name}]})):t.pageId===jo.CART_PAGE?this.translationService.translate("breadcrumb.cart",{},!0).pipe(x(n=>({breadcrumbs:[{label:n}]}))):t.pageId===mm.TIRE_SEARCH_PAGE?ae([this.translationService.translate(this.BREADCRUMB_TIRE_SEARCH),this.translationService.translate(this.BREADCRUMB_TIRE_CHOOSESIZE),this.translationService.translate(this.BREADCRUM_AUTOMOTIVE_SEARCH),this.sipSiteConfigService.getConfig(this.TIRE_SEARCH),this.sipSiteConfigService.getConfig(vm),this.sipRoutingService.currentUrl$]).pipe(x(([n,o,s,a,c,p])=>{let m=[];return p.indexOf("/selectsize")>-1?(m.push({label:n,link:a}),m.push({label:o,link:null})):p.includes(c)?m.push({label:s,link:c}):m.push({label:n,link:null}),{breadcrumbs:m}})):D({breadcrumbs:[{label:t.title||t.name,link:this.router.url}]})))}resolveMetaDataFromOcc(){return ae([this.cms.getUntamperedCurrentPage(),this.sipRoutingService.currentUrl$]).pipe(X(([t,n],[o,s])=>Vi.compareRoutes(n,s)),x(([t,n])=>t),j(t=>!!t&&t.pageId!=="search"&&t?.type===this.pageType),x(t=>t.pageId),X(),A(t=>this.fetchMetadata(t)),x(t=>this.setSchemaUrl(t)))}resolveDescription(t){return this.contentStackConfigService.getContentStackPage().pipe(A(n=>n?this.csPageResolver.resolveDescription(t):t.description&&t.description?.trim()?D(t):this.cms$.pipe(x(({description:o})=>ie(R({},t),{description:o})))))}resolveKeywords(){return this.contentStackConfigService.getContentStackPage().pipe(A(t=>t?this.csPageResolver.resolveKeywords():D({})))}resolveTitle(){return this.cms$.pipe(x(t=>({title:t.title})))}resolveRobots(){return this.contentStackConfigService.getContentStackPage().pipe(A(t=>t?this.csPageResolver.resolveRobots():D({})))}resolveBvUserAuth(){return this.siteService.getSite().pipe(rt("bvUserAuth"))}};e.\u0275fac=function(n){return new(n||e)(u(be),u(Ro),u(Ke),u(re),u(xe),u(Je),u(We),u(K),u(Um),u(yi),u(lt),u(Pt),u(zs))},e.\u0275prov=I({token:e,factory:e.\u0275fac});let i=e;return i})();var og={provide:Xe,multi:!0,useFactory:JS,deps:[K,fi,ns]};function JS(i,e,r){return()=>{e.getActive().subscribe(t=>
11{i.document.documentElement.lang=r.transform(t)})}}var sg=(()=>{let e=class e extends Zi{constructor(t,n,o,s,a,c,p,m,_,y,E,k){super(p,a,c,_,y),this.cms=t,this.routingService=n,this.productService=o,this.translation=s,this.occEndpointsService=a,this.http=c,this.sipSiteConfigService=p,this.sipSiteService=m,this.windowRef=_,this.bffEndpointsService=y,this.contentStackConfigService=E,this.csPageResolver=k,this.TITLE_WORD_SEPARATOR=" | ",this.productSchemaOrgId="schemaorg_product",this.product$=this.routingService.getRouterState().pipe(x(N=>N.state.params.productCode),j(N=>!!N),A(N=>this.productService.get(N,"details")),j(N=>!!N&&!N.error),_t(1)),this.pageType=Ue.PRODUCT_PAGE}resolveMetaData(){return this.pipeMerge(ae([this.resolveBreadcrumbs(),this.resolveImage(),this.resolveNaverSiteVerification(),this.resolveGoogleSiteVerification(),this.resolveCanonicalLink(),this.resolveOpenGraphProduct(),this.resolveAmount(),this.resolveCurrency(),this.resolveHeading(),this.resolveMetaDataFromOcc().pipe(A(this.resolveTitle.bind(this))),this.resolveRobots()]))}resolveMetaDataFromOcc(){return ae([this.cms.getUntamperedCurrentPage().pipe(j(t=>!!t?.pageId&&t?.type===this.pageType),x(t=>t.pageId),X()),this.product$.pipe(x(t=>t.code),X())]).pipe(X(([t,n],[o,s])=>s===n),A(([t,n])=>this.fetchMetadata(t,{code:n})),z(1),x(t=>{let n=this.windowRef.location.href?.lastIndexOf("?");return this.windowRef.location.href?.indexOf("bvstate=")>n&&(t.robots=[Se.NOINDEX,Se.NOFOLLOW]),this.setSchemaUrl(t)}))}resolveHeading(){return this.product$.pipe(A(t=>D({heading:t.name})))}resolveTitle(t){let n=_i.DEFAULT_TITLE_MAX_LENGTH;return t.metaTitle.length+3>=n?this.sipSiteService.getSite().pipe(A(o=>D(t.metaTitle.length>n?ie(R({},t),{title:t.metaTitle.substr(0,n-3)+"..."}):ie(R({},t),{title:t.metaTitle})))):this.sipSiteService.getSite().pipe(A(o=>D((t.metaTitle+this.TITLE_WORD_SEPARATOR+o.name).length>n?ie(R({},t),{title:(t.metaTitle+this.TITLE_WORD_SEPARATOR+o.name).substr(0,n-3)+"..."}):ie(R({},t),{title:t.metaTitle+this.TITLE_WORD_SEPARATOR+o.name}))))}resolveAmount(){return this.product$.pipe(A(t=>D({amount:String(t.price?.value||"")})))}resolveCurrency(){return this.product$.pipe(A(t=>D({currency:t.price?.currencyIso||""})))}resolveImage(){return this.product$.pipe(x(t=>t.images?.PRIMARY?.zoom?.url?t.images.PRIMARY.zoom.url:null))}resolveRobots(){return this.contentStackConfigService.getContentStackPage()?this.csPageResolver.resolveRobots():this.routingService.getRouterState().pipe(A(t=>Object.prototype.hasOwnProperty.call(t?.state?.queryParams??{},"bvstate")?D({robots:[Se.NOINDEX,Se.NOFOLLOW]}):D({robots:[Se.FOLLOW,Se.INDEX]})))}resolveBreadcrumbs(){return this.product$.pipe(x(t=>({breadcrumbs:t.supercategories&&t.supercategories.length>0?this.resolveBreadcrumbData(t):[{label:t.name}]})))}resolveCanonicalLink(){let t;this.request?t=this.request.fullUrl:t=new URL(this.windowRef.document.URL),t.search="";let n=decodeURIComponent(t.href.replace(t.protocol,"https:"));return D({canonicalLink:n})}resolveFirstCategory(t){let n;return t.categories?.length>0&&(n=t.categories[0]),n?` | ${n.name||n.code}`:""}resolveManufacturer(t){return t.manufacturer?` | ${t.manufacturer}`:""}resolveBreadcrumbData(t){let n=[];for(let o of t.supercategories)n.unshift({label:o.name,link:o.url});return n}setSchemaUrl(t){let n=super.setSchemaUrl(t);if(t.schemaOrgProduct){let o=JSON.parse(t.schemaOrgProduct);n.schemaOrg[this.productSchemaOrgId]=Wt(o)}return n}};e.\u0275fac=function(n){return new(n||e)(u(xe),u(mi),u(Ao),u(Rn),u(Je),u(We),u(Ke),u(be),u(K),u(yi),u(Pt),u(zs))},e.\u0275prov=I({token:e,factory:e.\u0275fac,providedIn:"root"});let i=e;return i})();var cg=(()=>{let e=class e extends Zi{constructor(t,n,o,s,a,c,p,m,_,y,E){super(o,p,m,_,y),this.cms=t,this.cmsComponentService=n,this.sipSiteConfigService=o,this.productListingService=s,this.sipSiteService=a,this.productSearchService=c,this.occEndpointsService=p,this.http=m,this.windowRef=_,this.bffEndpointsService=y,this.req=E,this._subscription=this.productSearchService.getResults().subscribe(k=>this.isCategoryPage=!!k.categoryCode),this.pageType=Ue.CATEGORY_PAGE}resolveMetaData(){return this.pipeMerge(ae([this.resolveTitle(),this.resolveBreadcrumbs(),this.resolveNaverSiteVerification(),this.resolveGoogleSiteVerification(),this.resolveCanonicalLink(),this.resolveOpenGraph(),this.resolveMetaDataFromOcc().pipe(A(this.resolveDescription.bind(this))),this.resolveRobots(),this.resolveNextLink(),this.resolvePrevLink()]))}resolveMetaDataFromOcc(){return ae([this.cms.getUntamperedCurrentPage().pipe(j(t=>!!t?.pageId),x(t=>t.pageId),X()),this.productSearchService.getCurrentCategory().pipe(j(t=>!!t?.code),x(t=>t.code),X())]).pipe(X(([t,n],[o,s])=>s===n),A(([t,n])=>this.fetchMetadata(t,{code:n})),z(1),x(t=>this.setSchemaUrl(t)))}resolveRobots(){return this.productSearchService.getResults().pipe(j(Boolean),x(t=>t.indexSelection?{robots:[Se.INDEX,Se.FOLLOW]}:{robots:[Se.NOINDEX,Se.NOFOLLOW]}))}resolveDescription(t){return t.description&&t.description.trim()?D(t):this.productSearchService.getResults().pipe(j(n=>!!n&&!!n.categoryCode),x(n=>ie(R({},t),{description:n.category.name})))}resolveTitle(){return ae([this.productListingService.model$.pipe(j(t=>!!(t?.category||t?.categoryLandingPage))),this.sipSiteConfigService.getConfig(_i.TITLE_LIMIT_PROPERTY_ID,_i.DEFAULT_TITLE_MAX_LENGTH).pipe(x(t=>+t)),this.sipSiteService.getSite().pipe(rt("name"))]).pipe(x(([t,n,o])=>{let s=[].concat(t.breadcrumbs||[]).sort(this.productListingService.facetComparator).map(m=>m.facetValueName).join(" "),a=new URL(this.req?this.req.protocol+"://"+this.req.host+this.req.originalUrl:window.location.href),c=a.searchParams.has("page")?" p."+a.searchParams.get("page"):"",p=`${s?s+" ":""}${(t.category?.metaTitle?t.category?.metaTitle+c:t.category?.metaTitle)||t.category?.name+c+_i.TITLE_WORD_SEPARATOR+o}`;return{title:p.length<=n?p:p.substr(0,n-3)+"..."}}))}resolveBreadcrumbs(){return this.productSearchService.getResults().pipe(j(Boolean),x(t=>t.category?{breadcrumbs:Bs(t)}:null))}resolveNextLink(){return this.productSearchService.getResults().pipe(x(t=>{let n=null;return t.pagination?.totalPages>t.pagination?.currentPage+1&&(n=new URL(this.req?this.req.protocol+"://"+this.req.host+this.req.originalUrl:window.location.href),n.searchParams.set("page",String(t.pagination.currentPage+1)),this.handleParamsForLink(n)),{nextLink:n==null?null:n.toString()}}))}resolvePrevLink(){return this.productSearchService.getResults().pipe(x(t=>{let n=null;if(t.pagination?.currentPage>0){n=new URL(this.req?this.req.protocol+"://"+this.req.host+this.req.originalUrl:window.location.href);let o=t.pagination.currentPage-1;o===0?n.searchParams.delete("page"):n.searchParams.set("page",String(o)),this.handleParamsForLink(n)}return{prevLink:n==null?null:n.toString()}}))}resolveCanonicalLink(){return this.productSearchService.getResults().pipe(x(t=>{let n=new URL(this.req?this.req.protocol+"://"+this.req.host+this.req.originalUrl:window.location.href);return this.handleParamsForLink(n),{canonicalLink:n.toString()}}))}handleParamsForLink(t){if(t.searchParams.has("q")){let n=t.searchParams.get("q"),o=/([^:]*:?)/g,s=n.match(o);if(s&&s.length>1){let a=s;a[1]=":",t.searchParams.set("q",`${a.join("")}`)}}
11t.searchParams.forEach((n,o)=>{o==="query"&&!t.searchParams.has("q")&&t.searchParams.set("q",t.searchParams.get("query")),["q","page"].includes(o)?o==="page"&&+t.searchParams.get(o)==0&&t.searchParams.delete(o):t.searchParams.delete(o)})}getScore(t){return this.pageType&&t.type===this.pageType||t.type===Ue.CONTENT_PAGE&&t.pageId==="categoryLandingPage"||t.pageId===dt.NO_RESULT_PAGE?2:0}getPriority(t){return t.pageId===dt.NO_RESULT_PAGE&&this.isCategoryPage?10:super.getPriority(t)}ngOnDestroy(){this._subscription.unsubscribe()}};e.\u0275fac=function(n){return new(n||e)(u(xe),u(jn),u(Ke),u(_i),u(be),u(Bi),u(Je),u(We),u(K),u(yi),u(Un,8))},e.\u0275prov=I({token:e,factory:e.\u0275fac,providedIn:"root"});let i=e;return i})();var pg=(()=>{let e=class e extends Zi{constructor(t,n,o,s,a,c,p,m,_,y,E){super(a,p,m,_,y),this.cms=t,this.routingService=n,this.productSearchService=o,this.translation=s,this.sipSiteConfigService=a,this.sipSiteService=c,this.occEndpointsService=p,this.http=m,this.windowRef=_,this.bffEndpointsService=y,this.tireService=E,this.SEARCH_META_TITLE="search.meta.title",this.TITLE_WORD_SEPARATOR=" | ",this.SEARCH_META_DESCRIPTION_RESULTS="search.meta.description.results",this.SEARCH_META_DESCRIPTION_ON="search.meta.description.on",this.searchText$=this.routingService.getRouterState().pipe(x(k=>k.state.queryParams.text||k.state.queryParams.query?.split(":")[0])),this.searchPageWithSearchText$=this.productSearchService.getResults().pipe(j(k=>!!k&&(!!k.freeTextSearch||!!k.tireSearch||Array.isArray(k.products)&&k.products.length>0&&k.products.every(N=>N.groupId&&N.groupId===this.tireService.batteryCartgroupId)))),this._subscription=this.productSearchService.getResults().subscribe(k=>{this.isSearchPage=!!k.freeTextSearch,this.isTireSearchPage=!!k.tireSearch,this.isBatterySearchPage=!!Array.isArray(k.products)&&k.products.length>0&&k.products.every(N=>N.groupId&&N.groupId===this.tireService.batteryCartgroupId)}),this.pageType=Ue.CONTENT_PAGE,this.pageTemplate="CostcoSipSearchResultsGridPageTemplate"}resolveMetaData(){return this.pipeMerge(ae([this.resolveTitle(),this.resolveBreadcrumbs(),this.resolveNaverSiteVerification(),this.resolveGoogleSiteVerification(),this.resolveCanonicalLink(),this.resolveOpenGraph(),this.resolveRobots(),this.resolveMetaDataFromOcc(),this.resolveKeywords(),this.resolveDescription()]))}resolveMetaDataFromOcc(){return this.cms.getUntamperedCurrentPage().pipe(j(t=>!!t?.pageId&&t?.type===this.pageType),x(t=>t.pageId),X(),A(t=>this.fetchMetadata(t)),x(t=>this.setSchemaUrl(t)))}resolveTitle(){return this.searchText$.pipe(A(t=>ae([this.translation.translate(this.SEARCH_META_TITLE),this.translation.translate("tires.tire.search.result"),this.sipSiteService.getSite().pipe(x(n=>n.name))]).pipe(x(([n,o,s])=>({title:(this.isTireSearchPage||this.isBatterySearchPage?o:n+" "+t)+this.TITLE_WORD_SEPARATOR+s})))))}resolveBreadcrumbs(){return this.translation.translate("breadcrumb.search.result.suffix").pipe(x(t=>({breadcrumbs:[{label:t,link:this.isTireSearchPage||this.isBatterySearchPage?this.request?this.request.fullUrl.toString():this.windowRef.document.URL:null}]})))}resolveKeywords(){return this.searchPageWithSearchText$.pipe(x(t=>({keywords:t.freeTextSearch})))}resolveDescription(){return this.searchPageWithSearchText$.pipe(x(t=>t.freeTextSearch),A(t=>ae([this.translation.translate(this.SEARCH_META_DESCRIPTION_RESULTS),this.translation.translate(this.SEARCH_META_DESCRIPTION_ON),this.sipSiteService.getSite()]).pipe(x(([n,o,s])=>({description:n+" "+t+" "+o+" "+s.name})))))}resolveRobots(){return D({robots:[Se.NOINDEX,Se.FOLLOW]})}hasMatch(t){return t.pageId===dt.NO_RESULT_PAGE?!0:super.hasMatch(t)}getScore(t){return t.type===Ue.CONTENT_PAGE&&t.pageId==="search"?2:0}getPriority(t){return t.pageId===dt.NO_RESULT_PAGE&&this.isSearchPage?10:super.getPriority(t)}ngOnDestroy(){this._subscription.unsubscribe()}};e.\u0275fac=function(n){return new(n||e)(u(xe),u(mi),u(Bi),u(Rn),u(Ke),u(be),u(Je),u(We),u(K),u(yi),u(Hi))},e.\u0275prov=I({token:e,factory:e.\u0275fac,providedIn:"root"});let i=e;return i})();function ib(i){return()=>{i.get(bi).init()}}var nb=[{provide:Od,useExisting:sg},{provide:Id,useExisting:cg},{provide:wd,useExisting:pg},{provide:fd,useClass:rg}],lg=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({providers:[og,...nb,{provide:bd,useExisting:Vi},Vi,{provide:Xe,useFactory:ib,deps:[si,Je],multi:!0}]});let i=e;return i})();var rb={entities:{},details:{},activeSite:""};function dg(i=rb,e){switch(e.type){case Im:{let r=e.payload;return ie(R({},i),{details:r})}}return i}function Gs(i){let e={};if(i){let r;"entry"in i?r=i.entry:r=i,Array.isArray(r)&&r.forEach(t=>
11{e[t.key]=t.value})}return e}function mg(i){let e=new Map;if(i){let r;"entry"in i?r=i.entry:r=i,Array.isArray(r)&&r.forEach(t=>{e.set(t.key,t.value)})}return e}var Bc=(()=>{let e=class e{constructor(t,n,o,s){this.actions$=t,this.occEndpointsService=n,this.http=o,this.baseSiteService=s,this.loadSipSite$=jt(()=>this.actions$.pipe($t(Em),Lp(1),$p((...a)=>{let c;if(se.basesites){let p=this.occEndpointsService.buildUrl("currentsite");c=this.http.get(p)}else c=ae([this.baseSiteService.getActive(),this.baseSiteService.getAll()]).pipe(A(([p,m])=>{let _=m.find(y=>y.uid===p);if(!_.configs){let y=this.occEndpointsService.buildUrl("baseSites",{},{baseSite:!1});return this.http.get(y).pipe(x(E=>E.baseSites.find(k=>k.uid===p)))}return D(_)}));return c.pipe(x(p=>{let m=R({},p);return m.configs&&m.configs.entry&&(m.configs=Gs(m.configs)),(!m.stores||m.stores.length<1)&&m.baseStore&&(m.stores=[m.baseStore]),m}),x(p=>new wm(p)),Ge(p=>D(new Om(Tr(p)))))})))}};e.\u0275fac=function(n){return new(n||e)(u(Ni),u(Je),u(We),u(So))},e.\u0275prov=I({token:e,factory:e.\u0275fac});let i=e;return i})();var ug=(()=>{let e=class e{static forRoot(){return{ngModule:e,providers:[{provide:Tn,multi:!0,useFactory:ob,deps:[Bc,be,qt,vd]}]}}};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({imports:[$,En.forFeature(zo,dg),di.forFeature([Bc])]});let i=e;return i})();function ob(i,e,r){return{scopes:["currentsite"],configFactory:()=>J(this,null,function*(){let t=r.getStable("context").pipe(z(1)).toPromise();return e.bindSipSite(),yield e.loadSite(),t})}}var fg=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({imports:[$,ug.forRoot(),pf]});let i=e;return i})();var sb=()=>({cxRoute:"cart"}),hg=i=>({count:i}),ab=i=>({total:i}),cb=(()=>{let e=class e{constructor(t,n,o,s,a){this.activeCartFacade=t,this.authService=n,this.statePersistenceService=o,this.siteContextParamsService=s,this.eventService=a}getQuantity(){return this.activeCartRequired().pipe(A(t=>t?this.activeCartFacade.getActive().pipe(Sr({totalUnitCount:0}),x(n=>n.totalUnitCount||0)):D(0)))}getTotalPrice(){return this.activeCartRequired().pipe(A(t=>t?this.activeCartFacade.getActive().pipe(x(n=>n.totalPrice?.formattedValue??"")):D("")))}activeCartRequired(){return ae([this.hasActiveCartInStorage(),this.authService.isUserLoggedIn(),this.isCartCreated()]).pipe(x(([t,n,o])=>t||n||o),X(),zp(t=>!t,!0))}hasActiveCartInStorage(){return this.getCartStateFromBrowserStorage().pipe(x(t=>!!t?.active))}isCartCreated(){return this.eventService.get(tu).pipe(x(t=>!0),Sr(!1))}getCartStateFromBrowserStorage(){return this.siteContextParamsService.getValues([Fl]).pipe(x(t=>this.statePersistenceService.readStateFromStorage({key:"cart",context:t,storageType:jl.LOCAL_STORAGE})))}};e.\u0275fac=function(n){return new(n||e)(u(Ko),u(Di),u(wn),u(wo),u(zl))},e.\u0275prov=I({token:e,factory:e.\u0275fac,providedIn:"root"});let i=e;return i})(),pb=(()=>{let e=class e{constructor(t){this.miniCartComponentService=t,this.iconTypes=Bd,this.quantity$=this.miniCartComponentService.getQuantity(),this.total$=this.miniCartComponentService.getTotalPrice()}};e.\u0275fac=function(n){return new(n||e)(O(cb))},e.\u0275cmp=F({type:e,selectors:[["cx-mini-cart"]],decls:13,vars:29,consts:[[3,"routerLink"],[3,"type"],[1,"total"],[1,"count"]],template:function(n,o){n&1&&(S(0,"a",0),w(1,"cxUrl"),w(2,"async"),w(3,"cxTranslate"),P(4,"cx-icon",1),S(5,"span",2),H(6),w(7,"async"),w(8,"cxTranslate"),b(),S(9,"span",3),H(10),w(11,"async"),w(12,"cxTranslate"),b()()),n&2&&(l("routerLink",T(1,5,tl(22,sb))),yt("aria-label",ai(3,9,"miniCart.item",ve(23,hg,T(2,7,o.quantity$)))),d(4),l("type",o.iconTypes.CART),d(2),le(" ",ai(8,14,"miniCart.total",ve(25,ab,T(7,12,o.total$)))," "),d(4),le(" ",ai(12,19,"miniCart.count",ve(27,hg,T(11,17,o.quantity$)))," "))},dependencies:[On,Ud,q,hd,xt],encapsulation:2,changeDetection:0});let i=e;return i})(),gg=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({providers:[wl({cmsComponents:{MiniCartComponent:{component:pb}}})],imports:[$,G,gd,zd,pt]});let i=e;return i})();var lb=["sip-link-with-image",""];function db(i,e){if(i&1&&P(0,"img",4),i&2){let r=C().ngIf;l("src",r.media.url,Ct)("alt",r.media.altText)}}function mb(i,e){if(i&1&&(B(0),S(1,"a",1),v(2,db,1,2,"img",2),P(3,"span",3),b(),U()),i&2){let r=e.ngIf;d(),l("sipRouterLink",r.url)("target",r.target),d(),l("ngIf",r.media),d(),l("innerHTML",r.linkName,ye)}}var _g=(()=>{let e=class e{constructor(t){this.component=t,this.componentData$=this.component.data$.pipe(x(({media:n,url:o,linkName:s,target:a})=>({media:n,url:o,linkName:s,target:a==="true"||a===!0?"_blank":null})))}};e.\u0275fac=function(n){return new(n||e)(O(ee))},e.\u0275cmp=F({type:e,selectors:[["div","sip-link-with-image",""]],hostAttrs:[1,"link-with-media"],attrs:lb,decls:2,vars:3,consts:[[4,"ngIf"],[3,"sipRouterLink","target"],["class","menu-item-icon",3,"src","alt",4,"ngIf"],[1,"link-with-media-name",3,"innerHTML"],[1,"menu-item-icon",3,"src","alt"]],template:function(n,o){n&1&&(v(0,mb,4,4,"ng-container",0),w(1,"async")),n&2&&l("ngIf",T
11(1,1,o.componentData$))},dependencies:[W,nt,q],changeDetection:0});let i=e;return i})();var ub=["sip-link-with-image-skeleton",""],Cg=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275cmp=F({type:e,selectors:[["div","sip-link-with-image-skeleton",""]],attrs:ub,decls:1,vars:0,consts:[[1,"sip-link-with-image-skeleton"]],template:function(n,o){n&1&&P(0,"sip-skeleton",0)},dependencies:[Dt],styles:[".sip-link-with-image-skeleton[_ngcontent-%COMP%]{width:100%;height:50px}"],changeDetection:0});let i=e;return i})();var yg=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({providers:[M({cmsComponents:{CMSLinkWithImageComponent:{component:_g,skeletonComponent:Cg}}})],imports:[$,G,Qe,ht]});let i=e;return i})();var fb=i=>({disabled:i});function hb(i,e){if(i&1&&P(0,"sip-media",8),i&2){let r=C().ngIf;l("container",r.media)("alt",r.media.altText)}}function gb(i,e){i&1&&(S(0,"div"),P(1,"span",9),w(2,"cxTranslate"),w(3,"safeHtml"),b()),i&2&&(d(),l("innerHTML",T(3,3,T(2,1,"automotive.search.vehiclesearch.validate.automotivepartsnotfound.message.text")),ye))}function _b(i,e){if(i&1){let r=Ve();S(0,"div",1)(1,"div",2)(2,"a",3),Ce("click",function(){let n=ke(r).ngIf,o=C();return Re(o.navigateBasedOnUrl(n.url,n.name))}),P(3,"span",4),v(4,hb,1,2,"sip-media",5),S(5,"span",6),H(6,">"),b()(),v(7,gb,4,5,"div",7),b()()}if(i&2){let r=e.ngIf,t=C();d(2),l("ngClass",ve(4,fb,t.disabled(r.name))),d(),l("innerHTML",r.linkName,ye),d(),l("ngIf",r.media),d(3),l("ngIf",t.disabled(r.name))}}var Sg=(()=>{let e=class e{constructor(t,n,o,s){this.tireService=t,this.router=n,this.component=o,this.store=s,this.sub=new Ee}disabled(t){return t===kr.TIRES?this.vehicledataResponse.data.tireSize?.every(n=>n.tyre.every(o=>o.tireCount===0&&o.higherSpeedRatingTireCount===0)):t===kr.BATTERIES?this.vehicledataResponse.data.batteries?.every(n=>n.batteryProductCount===0):!1}navigateBasedOnUrl(t,n){n===kr.TIRES?this.tireService.proceedToTiresSizeSelect():n===kr.BATTERIES?(this.vehicleDeatils="",this.sub.add(this.store.select(xu).pipe(z(1)).subscribe(o=>{o[0]&&(this.vehicleDeatils="vehicle_"+o[0]),o[1]&&(this.vehicleDeatils+=":"+o[1]),o[2]&&(this.vehicleDeatils+=":"+o[2]),o[3]&&(this.vehicleDeatils+=":"+o[3])})),this.tireService.proceedToBatteriesSearch(this.vehicleDeatils)):this.router.navigateByUrl(t)}ngOnInit(){this.sub.add(this.tireService.getVehicleSearchResponseData().subscribe(t=>this.vehicledataResponse=t))}ngOnDestroy(){this.sub.unsubscribe()}};e.\u0275fac=function(n){return new(n||e)(O(Hi),O(re),O(ee),O(Mn))},e.\u0275cmp=F({type:e,selectors:[["sip-choose-your-automotive-parts"]],decls:3,vars:3,consts:[["class","category-listing-container",4,"ngIf"],[1,"category-listing-container"],[1,"category-list-item"],[3,"click","ngClass"],[1,"category-link",3,"innerHTML"],["class","category-image",3,"container","alt",4,"ngIf"],[1,"arrow"],[4,"ngIf"],[1,"category-image",3,"container","alt"],[1,"vehicle-error-message",3,"innerHTML"]],template:function(n,o){n&1&&(B(0),v(1,_b,8,6,"div",0),w(2,"async"),U()),n&2&&(d(),l("ngIf",T(2,1,o.component.data$)))},dependencies:[Ie,W,ft,q,xt,ut],styles:["[_nghost-%COMP%] .category-listing-container{padding-left:10px;display:inline-block;margin-bottom:10px}@media screen and (max-width: 767px){[_nghost-%COMP%] .category-listing-container{width:calc(100% - 16px);height:auto}}[_nghost-%COMP%] .category-list-item{border:1px solid #00000017;margin:0 10px;box-shadow:0 10px 10px #ccc;position:relative;padding:36px}[_nghost-%COMP%] .category-image img{border-radius:50%;margin:16px 0;width:250px;height:250px;background-color:#f3f3f3;cursor:pointer}[_nghost-%COMP%] .category-link{position:absolute;top:10px;left:10px;font-size:31px;margin-bottom:5px;color:#005dab;font-weight:700;cursor:pointer}[_nghost-%COMP%] .arrow{position:absolute;right:16px;top:10px;font-size:31px;color:#005dab;cursor:pointer}[_nghost-%COMP%] .disabled{pointer-events:none;opacity:.5}[_nghost-%COMP%] .vehicle-error-message{color:green;background:#fdd6d6;border:1px solid #D32029;font-size:16px;padding:15px;position:absolute;width:100%;bottom:0;left:0}"],changeDetection:0});let i=e;return i})();var bg=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({providers:[M({cmsComponents:{AutomotiveSearchCategoryComponent:{component:Sg}}})],imports:[$,pt,gt,Ae,$i,Qe,Yn,Ae,G]});let i=e;return i})();var xg=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({imports:[$i,Qd,yg,gg,bg]});let i=e;return i})();var Pg=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({imports:[G.forChild([{path:"",children:[{path:"",canActivate:[],loadChildren:()=>import("./chunk-TK45MKY2.js").then(t=>
11t.SipOricoPayLaterPageModule),data:{cxRoute:"payLaterReturn"}}]}])]});let i=e;return i})();function Cb(i,e){if(i&1&&(S(0,"li")(1,"a",5),H(2),b()()),i&2){let r=e.$implicit;d(),l("sipRouterLink",r.url)("title",r.linkName),d(),Be(r.linkName)}}function yb(i,e){if(i&1&&(S(0,"ul",3),v(1,Cb,3,3,"li",4),w(2,"async"),b()),i&2){let r=C();d(),l("ngForOf",T(2,1,r.$links))}}function vb(i,e){if(i&1&&P(0,"sip-link-list",7),i&2){let r,t=e.$implicit;l("ngClass",(r=t==null||t.device_type==null?null:t.device_type.toLowerCase())!==null&&r!==void 0?r:"")("linkData",t==null?null:t.menu_list_reference[0])}}function Sb(i,e){if(i&1&&(v(0,vb,1,2,"sip-link-list",6),w(1,"async")),i&2){let r=C();l("ngForOf",T(1,1,r.component.data$))}}var Mg=(()=>{let e=class e{constructor(t){this.component=t,this.$links=this.component.data$.pipe(jp("linksList"),x(n=>{let o=n.linksList||{};return Array.from(Object.values(o))})),this.$IsContentStackMenuItems=this.component.data$.pipe(x((n,o)=>{if(n&&n[o]&&"device_type"in n[o])return!0}),z(1))}};e.\u0275fac=function(n){return new(n||e)(O(ee))},e.\u0275cmp=F({type:e,selectors:[["sip-responsive-header"]],hostAttrs:[1,"top-header-wrapper-item"],decls:5,vars:7,consts:[["showUtilityMenu",""],["class","d-flex",4,"ngIf","ngIfElse"],[3,"ngIf"],[1,"d-flex"],[4,"ngFor","ngForOf"],[3,"sipRouterLink","title"],["variant","NavSimpleList","class","utility-menu",3,"ngClass","linkData",4,"ngFor","ngForOf"],["variant","NavSimpleList",1,"utility-menu",3,"ngClass","linkData"]],template:function(n,o){if(n&1&&(v(0,yb,3,3,"ul",1),w(1,"async"),v(2,Sb,2,3,"ng-template",2,0,ne),w(4,"async")),n&2){let s=Y(3);l("ngIf",T(1,3,o.$links))("ngIfElse",s),d(2),l("ngIf",T(4,5,o.$IsContentStackMenuItems))}},dependencies:[Ie,qe,W,nt,Bu,q],styles:[".utility-menu.tablet[_ngcontent-%COMP%], .utility-menu.desktop[_ngcontent-%COMP%], .utility-menu.default[_ngcontent-%COMP%]{display:none}@media screen and (min-width: 768px) and (max-width: 1023px){.utility-menu.tablet[_ngcontent-%COMP%]{display:block}.utility-menu.desktop[_ngcontent-%COMP%]{display:none}.utility-menu.default[_ngcontent-%COMP%]{display:block}}@media screen and (min-width: 1024px){.utility-menu.tablet[_ngcontent-%COMP%]{display:none}.utility-menu.desktop[_ngcontent-%COMP%], .utility-menu.default[_ngcontent-%COMP%]{display:block}}"],changeDetection:0});let i=e;return i})();var Hs=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({providers:[M({cmsComponents:{ResponsiveHeaderComponent:{component:Mg}}})],imports:[$,ji,G,Qe,af]});let i=e;return i})();var bb=["sip-cms-image",""];function xb(i,e){if(i&1&&(B(0),S(1,"div",2),P(2,"sip-media",3),b(),U()),i&2){let r=e.ngIf;d(2),l("container",r.media)}}function Pb(i,e){if(i&1&&(S(0,"div",2),P(1,"sip-media",3),b()),i&2){let r=e.ngIf;d(),l("container",r.media)}}function Mb(i,e){if(i&1&&(v(0,Pb,2,1,"div",4),w(1,"async")),i&2){let r=C();l("ngIf",T(1,1,r.componentData$))}}var lr=(()=>{let e=class e{constructor(t){this.component=t,this.componentData$=this.component.data$}};e.\u0275fac=function(n){return new(n||e)(O(ee))},e.\u0275cmp=F({type:e,selectors:[["","sip-cms-image",""]],inputs:{data:[io.None,"sip-cms-image","data"]},attrs:bb,decls:3,vars:2,consts:[["componentMedia",""],[4,"ngIf","ngIfElse"],[1,"cmsimage"],[3,"container"],["class","cmsimage",4,"ngIf"]],template:function(n,o){if(n&1&&v(0,xb,3,1,"ng-container",1)(1,Mb,2,3,"ng-template",null,0,ne),n&2){let s=Y(2);l("ngIf",o.data)("ngIfElse",s)}},dependencies:[W,ft,q],encapsulation:2,changeDetection:0});let i=e;return i})();var Ob=["sip-category-menu-nav",""],wb=i=>({selector:i,defaultValue:!0,keepOpen:!0});function Tb(i,e){i&1&&P(0,"span",7)}function kb(i,e){i&1&&P(0,"span",10)}function Rb(i,e){if(i&1&&(B(0),S(1,"a",8),H(2),v(3,kb,1,0,"span",9),b(),U()),i&2){let r=C(2);d(),l("routerLink",r.categoryUrl),yt("tabIndex",r.catLevel===1?0:null)("aria-haspopup",r.catLevel===1?"true":""),d(),le(" ",r.name," "),d(),l("ngIf",r.catLevel===1)}}function Ab(i,e){i&1&&P(0,"span",10)}function Nb(i,e){if(i&1&&(S(0,"a",11),H(1),v(2,Ab,1,0,"span",9),b()),i&2){let r=C(2);l("routerLink",r.categoryUrl)("sip-aria-controls",r.catLevel===1?r.ariaControl
11sId:void 0),yt("tabIndex",r.catLevel===1?0:null)("aria-haspopup",r.catLevel===1?"true":null),d(),le(" ",r.name," "),d(),l("ngIf",r.catLevel===1)}}function Db(i,e){if(i&1&&(B(0),S(1,"a",4),w(2,"async"),S(3,"label",5),H(4),b(),v(5,Tb,1,0,"span",6),b(),v(6,Rb,4,5,"ng-container",2)(7,Nb,3,6,"ng-template",null,1,ne),U()),i&2){let r=Y(8),t=C();d(),l("ngClass",T(2,7,t.activeClass$)?"":"active-cat")("sip-aria-controls",ve(9,wb,t.ariaControlsId)),yt("tabIndex",t.catLevel===1?0:null),d(3),Be(t.name),d(),l("ngIf",t.catLevel===1||t.catLevel===2),d(),l("ngIf",t.catLevel!==1)("ngIfElse",r)}}function Fb(i,e){i&1&&P(0,"span",14)}function Lb(i,e){if(i&1&&(S(0,"a",12),H(1),v(2,Fb,1,0,"span",13),b()),i&2){let r=C();l("routerLink",r.categoryUrl),yt("title",r.name)("aria-label",r.name),d(),le(" ",r.name," "),d(),l("ngIf",r.catLevel===1||r.catLevel===2)}}function jb(i,e){if(i&1&&(B(0),P(1,"li",19),U()),i&2){let r=e.$implicit,t=C(2);d(),l("categoryUrl",r.url)("name",r.name)("subcategories",r.subcategories)("uid",r.uid)("catLevel",t.catLevel+1)("parentUid",t.parentUid)}}function $b(i,e){if(i&1&&(S(0,"ul",15)(1,"li",16)(2,"a",17),H(3),w(4,"cxTranslate"),b()(),v(5,jb,2,6,"ng-container",18),b()),i&2){let r=C();l("id",r.ariaControlsId)("sip-aria-hidden",r.ariaControlsId),d(2),l("routerLink",r.categoryUrl),yt("aria-label",r.name),d(),el(" ",T(4,8,"menu.categories.all"),"\xA0 ",r.name," "),d(2),l("ngForOf",r.subcategories)("ngForTrackBy",r.trackCategory)}}var Og=(()=>{let e=class e{constructor(t){this.ariaService=t,this.subcategories=[]}trackCategory(t,n){return n.uid}ngOnInit(){let t=this.parentUid?`${this.parentUid}--`:"";this.ariaControlsId=`${t}${this.uid}`,this.subcategories&&this.subcategories.length&&(this.activeClass$=this.ariaService.getState(this.uid))}};e.\u0275fac=function(n){return new(n||e)(O(Wn))},e.\u0275cmp=F({type:e,selectors:[["","sip-category-menu-nav",""]],inputs:{uid:"uid",catLevel:"catLevel",categoryUrl:"categoryUrl",name:"name",subcategories:"subcategories",parentUid:"parentUid"},attrs:Ob,decls:5,vars:3,consts:[["leafCategory",""],["firstLevelCategory",""],[4,"ngIf","ngIfElse"],["role","none",3,"id","sip-aria-hidden",4,"ngIf"],["href","javascript:void(0)","aria-haspopup","true","data-category","${safeCategoryCode}",1,"visible-xs","visible-sm","cat-trigger",3,"ngClass","sip-aria-controls"],[1,"show-sub-menu"],["class","costco-icons costco-icon-right-chevron",4,"ngIf"],[1,"costco-icons","costco-icon-right-chevron"],["role","menuitem",1,"show-sub-menu","hidden-xs","hidden-sm",3,"routerLink"],["class","costco-icons costco-icon-right-chevron hidden-xs hidden-sm",4,"ngIf"],[1,"costco-icons","costco-icon-right-chevron","hidden-xs","hidden-sm"],["role","menuitem",1,"show-sub-menu","hidden-xs","hidden-sm",3,"routerLink","sip-aria-controls"],[3,"routerLink"],["class","costco-icons costco-icon-right-chevron hidden-md hidden-lg",4,"ngIf"],[1,"costco-icons","costco-icon-right-chevron","hidden-md","hidden-lg"],["role","none",3,"id","sip-aria-hidden"],["role","none"],["role","menuitem",1,"hidden-md","hidden-lg",3,"routerLink"],[4,"ngFor","ngForOf","ngForTrackBy"],["sip-category-menu-nav","",3,"categoryUrl","name","subcategories","uid","catLevel","parentUid"]],template:function(n,o){if(n&1&&(v(0,Db,9,11,"ng-container",2)(1,Lb,3,5,"ng-template",null,0,ne),B(3),v(4,$b,6,10,"ul",3),U()),n&2){let s=Y(2);l("ngIf",o.subcategories.length)("ngIfElse",s),d(4),l("ngIf",o.subcategories.length)}},dependencies:[Ie,qe,W,On,rs,Kn,e,q,xt],styles:["[aria-hidden=false][_ngcontent-%COMP%]{display:block!important}.topmenu[_nghost-%COMP%] ul[_ngcontent-%COMP%], .topmenu [_nghost-%COMP%] ul[_ngcontent-%COMP%]{min-height:100%}"],changeDetection:0});let i=e;return i})();var zb=["sip-navigation-bar-collection",""];function Gb(i,e){if(i&1&&P(0,"li",4),i&2){let r=e.$implicit;l("sip-aria-mouse-events",r.uid)("categoryUrl",r.url)("name",r.name)("subcategories",r.subcategories)("uid",r.uid)("catLevel",1)}}function Hb(i,e){if(i&1&&P(0,"div",8),i&2){let r=C().$implicit;l("sip-cms-image",r.featureIcon)}}function Vb(i,e){if(i&1&&(P(0,"a",9),w(1,"safeHtml")),i&2){let r=C().$implicit;l("sipRouterLink",r.link.url)("innerHTML",T(1,2,r.link.linkName),ye)}}function qb(i,e){if(i&1&&(S(0,"li",5),v(1,Hb,1,1,"div",6)(2,Vb,2,4,"a",7),b()),i&2){let r=e.$implicit;l("ngClass",r.styleClass),d(),l("ngIf",r.featureIcon),d(),l("ngIf",r.link)}}function Wb(i,e){if(i&1&&(B(0),P(1,"li",1),v(2,Gb,1,6,"li",2),w(3,"async"),v(4,qb,3,3,"li",3),w(5,"async"),U()),i&2){let r=C();d(2),l("ngForOf",T(3,4,r.categories$))("ngForTrackBy",r.trackByUid),d(2),l("ngForOf",T(5,6,r.components$))("ngForTrackBy",r.trackByUid)}}var wg=(()=>{let e=class e{constructor(t,n,o,s,a,c,p,m){this.component=t,this.ariaService=n,this.el=o,this.router=s,this.renderer=a,this.layoutService=c,this.sipCmsComponentService=p,this.winRef=m,this.sub=new Ee,this.id=om,this.role="menu",this.labelledBy="theMenuButton",this.class="topmenu menu-container",this.categories$=this.component.data$.pipe(rt("firstLevelCategories"),Ot(_=>this.ariaService.setState(this.id,!0)),X(),x(this.convertCategoryMap.bind(this)),_t(1)),this.components$=this.component.data$.pipe(rt("components"),j(_=>typeof _=="object"&&!!_),x(_=>Array.from(Object.values(_)))),this.lazyLoaded$=Jr(D(!this.sipCmsComponentService.shouldRenderSkeleton()),this.ariaService.getState(this.id
11).pipe(x(_=>!_),j(_=>_))),this.shouldRender$=this.sipCmsComponentService.shouldRenderSkeleton()?D(!1):this.lazyLoaded$,this.ariaHiddenDirective=new Kn(this.ariaService,this.el,this.renderer,this.layoutService,this.winRef),this.ariaHiddenDirective.selectorObject=this.id,this.ariaMouseEventsDirective=new Qn(this.ariaService,this.el,this.renderer,this.layoutService),this.ariaMouseEventsDirective.selectorObject=this.id}ariaHiddenCheckFocus(){this.ariaHiddenDirective.checkFocus()}ariaHiddenClose(t){this.ariaHiddenDirective.close(t)}ariaMouseClose(){this.ariaMouseEventsDirective.close()}ariaMouseOpen(){this.ariaMouseEventsDirective.open()}ariaNextFocus(t){this.ariaHiddenDirective.nextFocus(t)}ariaPrevFocus(t){this.ariaHiddenDirective.prevFocus(t)}convertCategoryMap(t,n=0){let o=Array.from(Object.values(t));return o=o.map((s,a)=>{let c=R({},s);return c.uid=`${s.id}-${n}-${a}`,c.subcategoryMap&&(c.subcategories=this.convertCategoryMap(s.subcategoryMap,n+1)),c}),o}closeMenuOnNavigate(){this.sub.add(this.router.events.pipe(j(t=>t instanceof Ml)).subscribe(t=>{this.ariaService.setState(this.id,!0)}))}trackByUid(t,n){return n.uid}ngOnInit(){this.closeMenuOnNavigate(),this.ariaMouseEventsDirective.ngOnInit(),this.ariaHiddenDirective.ngOnInit()}ngOnDestroy(){this.sub.unsubscribe(),this.ariaMouseEventsDirective.ngOnDestroy(),this.ariaHiddenDirective.ngOnDestroy()}};e.\u0275fac=function(n){return new(n||e)(O(ee),O(Wn),O(wt),O(re),O(bn),O($u),O(jn),O(K))},e.\u0275cmp=F({type:e,selectors:[["ul","sip-navigation-bar-collection",""]],hostVars:7,hostBindings:function(n,o){n&1&&Ce("focusout",function(){return o.ariaHiddenCheckFocus()})("keydown.escape",function(a){return o.ariaHiddenClose(a)},!1,Wp)("mouseenter",function(){return o.ariaMouseClose()})("mouseleave",function(){return o.ariaMouseOpen()})("keydown.arrowdown",function(a){return o.ariaNextFocus(a)})("keydown.arrowup",function(a){return o.ariaPrevFocus(a)}),n&2&&(Zp("id",o.id),yt("role",o.role)("aria-labelledby",o.labelledBy)("sip-aria-hidden",o.ariaHiddenDirective)("sip-aria-mouse-events",o.ariaMouseEventsDirective),Pi(o.class))},attrs:zb,decls:3,vars:5,consts:[[4,"ngIf"],[1,"menu-arrow"],["class","topmenu","role","none","sip-category-menu-nav","",3,"sip-aria-mouse-events","categoryUrl","name","subcategories","uid","catLevel",4,"ngFor","ngForOf","ngForTrackBy"],["role","none","class","topmenu",3,"ngClass",4,"ngFor","ngForOf","ngForTrackBy"],["role","none","sip-category-menu-nav","",1,"topmenu",3,"sip-aria-mouse-events","categoryUrl","name","subcategories","uid","catLevel"],["role","none",1,"topmenu",3,"ngClass"],["class","yCmsComponent",3,"sip-cms-image",4,"ngIf"],["role","menuitem",3,"sipRouterLink","innerHTML",4,"ngIf"],[1,"yCmsComponent",3,"sip-cms-image"],["role","menuitem",3,"sipRouterLink","innerHTML"]],template:function(n,o){n&1&&(v(0,Wb,6,8,"ng-container",0),w(1,"async"),w(2,"async")),n&2&&l("ngIf",T(1,1,o.categories$)&&T(2,3,o.shouldRender$))},dependencies:[Ie,qe,W,Qn,lr,nt,Og,q,ut],changeDetection:0});let i=e;return i})();function Kb(i,e){if(i&1&&(B(0),S(1,"a",1),w(2,"async"),H(3),b(),U()),i&2){let r=e.ngIf,t=C();d(),Yp(r.styleAttributes),l("sipRouterLink",r.url)("title",r.linkName)("ngClass",r.styleClasses)("target",T(2,7,t.target$)),d(2),le(" ",r.linkName,"")}}var Vs=(()=>{let e=class e{constructor(t,n){this.component=t,this.el=n}set componentData(t){this.data$=D(t)}ngOnInit(){this.data$||(this.data$=this.component.data$),this.target$=this.data$.pipe(x(t=>t.target==="true"||t.target===!0?"_blank":null))}};e.\u0275fac=function(n){return new(n||e)(O(ee),O(wt))},e.\u0275cmp=F({type:e,selectors:[["span"],["","sip-link",""]],inputs:{componentData:[io.None,"sip-link","componentData"]},decls:2,vars:3,consts:[[4,"ngIf"],[3,"sipRouterLink","title","ngClass","target"]],template:function(n,o){n&1&&(v(0,Kb,4,9,"ng-container",0),w(1,"async")),n&2&&l("ngIf",T(1,1,o.data$))},dependencies:[Ie,W,nt,q],encapsulation:2,changeDetection:0});let i=e;return i})();var Yb=["navigationRef"],Zb=["sip-navigation",""];function Xb(i,e){if(i&1&&P(0,"div",7),i&2){let r=e.ngIf;l("sip-cms-image",r)}}function Jb(i,e){if(i&1&&(P(0,"span",8),w(1,"async")),i&2){let r=C(3);l("ngClass",T(1,1,r.isOpen$)?"arrow-down":"arrow-up")}}function ex(i,e){if(i&1&&P(0,"div",21),i&2){let r=C().$implicit;l("sip-link",r.links[0])}}function tx(i,e){if(i&1&&P(0,"div",21),i&2){let r=e.$implicit;l("sip-link",r)}}function ix(i,e){if(i&1&&(S(0,"li",24),v(1,tx,1,1,"div",25),b()),i&2){let r=e.$implicit;d(),l("ngForOf",r.links)}}function nx(i,e){if(i&1&&(S(0,"ul",22),v(1,ix,2,1,"li",23),b()),i&2){let r=C(),t=r.$implicit,n=r.index,o=C(4).ngIf;l("id",o.link.uid+"-"+n),d(),l("ngForOf",t.children)}}function rx(i,e){if(i&1&&(B(0),S(1,"li",18),v(2,ex,1,1,"div",19)(3,nx,2,2,"ul",20),b(),U()),i&2){let r=e.$implicit;d(),Tt("max-width",r.maxWidth),Xt("has-children",r.hasChildren)("no-children",!r.hasChildren),d(),l("ngIf",r.hasLinks),d(),l("ngIf",r.hasChildren)}}function ox(i,e){if(i&1&&(S(0,"ul",16),v(1,rx,4,8,"ng-container",17),b()),i&2){let r=e.$implicit;d(),l("ngForOf",r)}}function sx(i,e){if(i&1&&(B(0),S(1,"div",26)(2,"div",27),P(3,"img",28),b()(),U()),i&2){let r=e.ngIf;d(3),l("title",r.mime)("alt",r.altText)("src",r.url,Ct)}}function ax(i,e){if(i&1&&(B(0),S(1,"div",9),P(2,"div",10),b(),S(3,"ul",11,0),w(5,"async"),P(6,"li",12),S(7,"li",13),v(8,ox,2,1,"ul",14),b(),S(9,"li",15),v(10,sx,4,3,"ng-container",1),b()(),U()),i&2){let r=e.ngIf,t=C(2).ngIf,n=C();d(3),l("id",t.link.uid+"-sub")("sip-aria-hidden",t.link.uid+"-sub")("ngStyle",T(5,5,n.position$)),d(5),l("ngForOf",r),d(2),l("ngIf",t.featureComponent==null?null:t.featureComponent.media)}}function cx(i,e){if(i&1&&(S(0,"li",3),v(1,Xb,1,1,"div",4),P(2,"a",5),w(3,"safeHtml"),v(4,Jb,2,3,"span",6)(5,ax,11,7,"ng-container",1),w(6,"async"),b()),i&2){let r=C().ngIf,t=C();Pi((r.styleClass||"")+" "+(r.dropDownLayout||"")),Xt("has-sub",r.navigationNode==null?null:r.navigationNode.children)("js-enquire-has-sub",r.navigationNode==null?null:r.navigationNode.children),l("sip-aria-mouse-events",r.link.uid+"-sub"),d(),l("ngIf",r.featureIcon),d(),l("sipRouterLink",r.link.url)("sip-aria-controls",!(r.navigationNode==null||r.navigationNode.children==null)&&r.navigationNode.children.length?r.link.uid+"-sub"
11:void 0)("title",r.link.linkName)("target",r.link.target==="NEWWINDOW"?"_blank":"_self")("innerHTML",T(3,15,r.link.linkName),ye),d(2),l("ngIf",r.arrow==="true"),d(),l("ngIf",T(6,17,(r.navigationNode==null||r.navigationNode.children==null?null:r.navigationNode.children.length)&&t.links$))}}function px(i,e){if(i&1&&(B(0),v(1,cx,7,19,"li",2),U()),i&2){let r=e.ngIf;d(),l("ngIf",r)}}var Tg=(()=>{let e=class e{constructor(t,n,o,s){this.componentData=t,this.service=n,this.windowRef=o,this.ariaService=s,this.subscription=new Ee,this.isOpen$=this.componentData.data$.pipe(A(a=>this.ariaService.getState(a.link.uid+"-sub").pipe(x(c=>!c)))),this.position$=this.isOpen$.pipe(x(this.handlePositionStyle.bind(this))),this.data$=this.componentData.data$,this.links$=this.data$.pipe(j(a=>!!a.navigationNode),x(a=>{let c=ie(R({},a),{navigationNode:R({},a.navigationNode)});return c.navigationNode.hasChildren=c.navigationNode.children.length>0,c.navigationNode.children.reduce((p,m,_)=>{let y=R({},m);if(Array.isArray(y.links)){y.hasChildren=y.children?.length>0,y.hasLinks=y.links?.length>0;let E=c.navigationNode.children?.length||1,k=y.children?.length||1;return y.maxWidth=`${100/(y.hasChildren?E:k)}%`,(_%(+c.wrapAfter+1)===0?p.push([y]):p[p.length-1].push(y))&&p}else return p.push(y)&&p},[])}))}handlePositionStyle(t){if(!t)return{left:"auto",right:"auto",transform:"none"};let{left:n,width:o}=this.ref.nativeElement.getBoundingClientRect(),a=(this.windowRef.nativeWindow?.innerWidth||0)-(n+this.ref.nativeElement.clientWidth),m=this.windowRef.document.querySelectorAll(".navigation-wrapper")[0].getBoundingClientRect().right-(n+o);return n<0?{left:"11px",transform:"none"}:a<11?{right:"11px",transform:"none"}:m<5?{right:"5px",transform:"none"}:{transform:"translate(-7%, 0)"}}ngOnDestroy(){this.subscription.unsubscribe()}};e.\u0275fac=function(n){return new(n||e)(O(ee),O(em),O(K),O(Wn))},e.\u0275cmp=F({type:e,selectors:[["ul","sip-navigation",""]],viewQuery:function(n,o){if(n&1&&br(Yb,5),n&2){let s;xr(s=Pr())&&(o.ref=s.first)}},hostAttrs:["role","none",1,"nbc-container"],attrs:Zb,decls:2,vars:3,consts:[["navigationRef",""],[4,"ngIf"],["role","none",3,"sip-aria-mouse-events","class","has-sub","js-enquire-has-sub",4,"ngIf"],["role","none",3,"sip-aria-mouse-events"],["class","yCmsComponent",3,"sip-cms-image",4,"ngIf"],["aria-haspopup","true","role","menuitem","tabindex","0",3,"sipRouterLink","sip-aria-controls","title","target","innerHTML"],["class","chevron costco-white-icons costco-icon-down-chevron",3,"ngClass",4,"ngIf"],[1,"yCmsComponent",3,"sip-cms-image"],[1,"chevron","costco-white-icons","costco-icon-down-chevron",3,"ngClass"],[1,"sub-menu-arrow-container"],[1,"sub-menu-arrow"],["role","menu","aria-labelledby","sub-navigation",1,"sub-navigation",3,"id","sip-aria-hidden","ngStyle"],["role","presentation",1,"sub-nav-edge"],["role","none"],["class","sub-nav-menu-container","role","none",4,"ngFor","ngForOf"],[1,"navbar-simple-cms-component"],["role","none",1,"sub-nav-menu-container"],[4,"ngFor","ngForOf"],["role","none",1,"sub-nav-item"],["class","yCmsComponent",3,"sip-link",4,"ngIf"],["class","second-sub-navigation","role","none",3,"id",4,"ngIf"],[1,"yCmsComponent",3,"sip-link"],["role","none",1,"second-sub-navigation",3,"id"],["class","second-sub-nav-item","role","none",4,"ngFor","ngForOf"],["role","none",1,"second-sub-nav-item"],["class","yCmsComponent",3,"sip-link",4,"ngFor","ngForOf"],[1,"yCmsComponent"],[1,"simple-banner-component"],["loading","lazy",3,"title","alt","src"]],template:function(n,o){n&1&&(v(0,px,2,1,"ng-container",1),w(1,"async")),n&2&&l("ngIf",T(1,1,o.data$))},dependencies:[Ie,qe,W,Vt,rs,Kn,Qn,Vs,lr,nt,q,ut],changeDetection:0});let i=e;return i})();var dr=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({providers:[M({cmsComponents:{CMSImageComponent:{component:lr}}})],imports:[$,gt]});let i=e;return i})();var kg=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({providers:[M({cmsComponents:{NavigationBarComponent:{component:Tg},NavigationBarCollectionComponent:{component:wg}}})],imports:[$,pt,qi,G,ds,dr,Qe,Ae]});let i=e;return i})();function lx(i,e){if(i&1){let r=Ve();S(0,"div",1),w(1,"safeHtml"),Ce("click",function(){let n=ke(r).ngIf,o=C();return Re(o.onClick(n))}),b()}if(i&2){let r=e.ngIf,t=C();l("sipObserve",t.handleComponentVisible.bind(t))("innerHTML",T(1,2,r.content),ye)}}var zc=(()=>{let e=class e{constructor(t,n,o,s){this.component=t,this.element=n,this.routeService=o,this.sipGtmService=s,this.subscriptions=new Ee}get links(){let t='a:not([href^="javascript:"]):not([href^="mailto:"])';return Array.from(this.element.nativeElement.querySelectorAll(`${t}[target="_self"], ${t}[target=""], ${t}:not([target])`))}ngAfterViewInit(){this.routeService.routeParagraphLinks(this.links)}handleComponentVisible(){this.subscriptions.add(this.component.data$.pipe(j(t=>!!t?.promotionId),X()).subscribe(t=>{this.saveGtmEvent(t,Kt.PROMOTION_IMPRESSIONS_VIEW)}))}saveGtmEvent(t,n){if(t.promotionId){let o={id:t.promotionId,name:t.promotionName,creative:t.promotionCreative,position:t.promotionPosition};this.sipGtmService.pushPromotionImpressionEvent(o,n),this.sipGtmService.pushGA4ViewPromotionEvent(o)}}onClick(t){if(t.promotionId){let n={id:t.promotionId,name:t.promotionName,creative:t.promotionCreative,position:t.promotionPosition,urlTarget:""};this.sipGtmService.pushGA4SelectPromotionEvent(n)}}ngOnDestroy(){this.subscriptions.unsubscribe()}};e.\u0275fac=function(n){return new(n||e)(O(ee),O(wt),O(lt),O(At))},e.\u0275cmp=F({type:e,selectors:[["sip-paragraph"]],hostAttrs:["ngSkipHydration","true"],decls:2,vars:3,consts:[[3,"sipObserve","innerHTML","click",4,"ngIf"],[3,"click","
11sipObserve","innerHTML"]],template:function(n,o){n&1&&(v(0,lx,2,4,"div",0),w(1,"async")),n&2&&l("ngIf",T(1,1,o.component.data$))},dependencies:[W,Wi,q,ut],styles:["[_nghost-%COMP%]{display:block}[_nghost-%COMP%] h1.section-header, [_nghost-%COMP%] h2.section-header{margin:10px 0 5px;padding:20px;text-align:center;font-size:24px}"],changeDetection:0});let i=e;return i})();var Gc=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275cmp=F({type:e,selectors:[["sip-paragraph-skeleton"]],decls:1,vars:0,consts:[[1,"sip-paragraph-skeleton"]],template:function(n,o){n&1&&P(0,"sip-skeleton",0)},dependencies:[Dt],styles:[".sip-paragraph-skeleton[_ngcontent-%COMP%]{width:100%}@media screen and (min-width: 1024px){.sip-paragraph-skeleton[_ngcontent-%COMP%]{height:300px}}@media screen and (max-width: 767px){.sip-paragraph-skeleton[_ngcontent-%COMP%]{height:150px}}.BottomHeader[_nghost-%COMP%] .sip-paragraph-skeleton[_ngcontent-%COMP%], .BottomHeader [_nghost-%COMP%] .sip-paragraph-skeleton[_ngcontent-%COMP%]{display:none}"],changeDetection:0});let i=e;return i})();var Rg=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({providers:[M({cmsComponents:{CMSParagraphComponent:{component:zc,skeletonComponent:Gc},CMSTabParagraphComponent:{component:zc,skeletonComponent:Gc}}})],imports:[$,Ae,ht,Ki]});let i=e;return i})();function dx(i,e){if(i&1&&(S(0,"a",4),He(1,5),b()),i&2){let r=e.ngIf;C();let t=Y(3);l("sipRouterLink",r),d(),l("ngTemplateOutlet",t)}}function mx(i,e){if(i&1&&P(0,"sip-media",10),i&2){let r=e.ngIf;l("container",r)}}function ux(i,e){if(i&1&&(S(0,"div")(1,"div",6)(2,"div"),P(3,"p",7),w(4,"safeHtml"),P(5,"p",8),w(6,"safeHtml"),b()(),v(7,mx,1,1,"sip-media",9),b()),i&2){let r=C().ngIf;Pi(r.valign+" banner-component "+r.align),d(2),Pi(r.contentWidth+" banner-component__content-align-wrapper "+r.mobileContentWidth),d(),l("innerHTML",T(4,7,r.bannerTitle),ye),d(2),l("innerHTML",T(6,9,r.bannerParagraph),ye),d(2),l("ngIf",r.media)}}function fx(i,e){if(i&1&&(S(0,"div",2),v(1,dx,2,2,"a",3)(2,ux,8,11,"ng-template",null,0,ne),b()),i&2){let r=e.ngIf,t=Y(3);d(),l("ngIf",r.locUrlLink)("ngIfElse",t)}}var Ag=(()=>{let e=class e{constructor(t){this.component=t}};e.\u0275fac=function(n){return new(n||e)(O(ee))},e.\u0275cmp=F({type:e,selectors:[["sip-responsive-text-overlay"]],decls:2,vars:3,consts:[["bannerContent",""],["class","simple-responsive-banner-component",4,"ngIf"],[1,"simple-responsive-banner-component"],[3,"sipRouterLink",4,"ngIf","ngIfElse"],[3,"sipRouterLink"],[3,"ngTemplateOutlet"],[1,"banner-component__content"],[1,"banner-component__title",3,"innerHTML"],[1,"banner-component__paragraph",3,"innerHTML"],["format","desktop",3,"container",4,"ngIf"],["format","desktop",3,"container"]],template:function(n,o){n&1&&(v(0,fx,4,2,"div",1),w(1,"async")),n&2&&l("ngIf",T(1,1,o.component.data$))},dependencies:[W,ci,nt,ft,q,ut],styles:["[_nghost-%COMP%]{display:block}[_nghost-%COMP%] .simple-responsive-banner-component[_ngcontent-%COMP%]{margin-top:8px}"],changeDetection:0});let i=e;return i})();var Ng=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275cmp=F({type:e,selectors:[["sip-responsive-text-overlay-skeleton"]],decls:2,vars:0,consts:[[1,"sip-responsive-text-overlay-skeleton_container"],[1,"sip-responsive-text-overlay-skeleton"]],template:function(n,o){n&1&&(S(0,"div",0),P(1,"sip-skeleton",1),b())},dependencies:[Dt],styles:[".sip-responsive-text-overlay-skeleton_container[_ngcontent-%COMP%]{width:100%;height:auto}@media screen and (min-width: 1024px){.sip-responsive-text-overlay-skeleton[_ngcontent-%COMP%]{height:400px}}@media screen and (max-width: 767px){.sip-responsive-text-overlay-skeleton[_ngcontent-%COMP%]{height:200px}}"],changeDetection:0});let i=e;return i})();var Dg=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({providers:[M({cmsComponents:{ResponsiveTextOverlayBannerComponent:{component:Ag,skeletonComponent:Ng}}})],imports:[$,Qe,ht,gt,Ae]});let i=e;return i})();var Ws=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({providers:[M({cmsComponents:{CMSLinkComponent:{component:Vs}}})],imports:[$,G,Qe]});let i=e;return i})();var Fg=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({imports:[$,G,ds,Ws,qi,dr,Qe,Ae]});let i=e;return i})();var hx=["sip-simple-banner",""];function gx(i,e){if(i&1&&(S(0,"a",4),He(1,5),b()),i&2){let r=C().ngIf,t=Y(4);l("sipRouterLink",r.urlLink)("target",r.external==="true"?"_blank":"_self")("title",r.media==null?null:r.media.altText),d(),l("ngTemplateOutlet",t)}}function _x(i,e){if(i&1&&P(0,"p",8),i&2){let r=C(2).ngIf;l("innerHTML",r.headline,ye)}}function Cx(i,e){if(i&1&&P(0,"p",8),i&2){let r=C(2).ngIf;l("innerHTML",r.content,ye)}}function yx(i,e){if(i&1&&(v(0,_x,1,1,"p",6),P(1,"sip-media",7),v(2,Cx,1,1,"p",6)),i&2){let r=C().ngIf;l("ngIf",r.headline),d(),l("container",r.media),d(),l("ngIf",r.content)}}function vx(i,e){if(i&1&&(S(0,"div",2),w(1,"async"),v(2,gx,2,4,"a",3)(3,yx,3,3,"ng-template",null,0,ne),b()),i&2){let r=e.ngIf,t=Y(4),n=C();l("ngClass",T(1,3,n.bannerClass$)),d(2),l("ngIf",r.urlLink)("ngIfElse",t)}}var Ks=(()=>{let e=class e{constructor(t){this.component=t,this.bannerClass$=this.component.data$.pipe(x(n=>n.typeCode==="BannerComponent"?"simple-banner--auto-width":""))}};e.\u0275fac=function(n){return new(n||e)(O(ee))},e.\u0275cmp=F({type:e,selectors:[["div","sip-simple-banner",""]],hostAttrs:[1,"simple-banner-component"],attrs:hx,decls:2,vars:3,consts:[["bannerContent",""],["class","simple-banner",3,"ngClass",4,"ngIf"],[1,"simple-banner",3,"ngClass"],[3,"sipRouterLink","target","title",4,"ngIf","ngIfElse"],[3,"sipRouterLink","target","title"],[3,"ngTemplateOutlet"],[3,"innerHTML",4,"ngIf"],[3,"container"],[3,"innerHTML"]],template:function(n,o){n&1&&(v(0,vx,5,5,"div",1),w(1,"async")),n&2&&l("ngIf",T
11(1,1,o.component.data$))},dependencies:[Ie,W,ci,nt,ft,q],styles:["[_nghost-%COMP%]{display:block}[_nghost-%COMP%] cx-media[_ngcontent-%COMP%], [_nghost-%COMP%] a[_ngcontent-%COMP%]{display:block}[_nghost-%COMP%] .simple-banner--auto-width[_ngcontent-%COMP%] img{width:auto}"],changeDetection:0});let i=e;return i})();var Qs=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275cmp=F({type:e,selectors:[["sip-simple-banner-skeleton"]],decls:1,vars:0,consts:[[1,"sip-simple-banner-skeleton"]],template:function(n,o){n&1&&P(0,"sip-skeleton",0)},dependencies:[Dt],styles:["@media screen and (min-width: 1024px){.sip-simple-banner-skeleton[_ngcontent-%COMP%]{height:100px}}@media screen and (max-width: 767px){.sip-simple-banner-skeleton[_ngcontent-%COMP%]{height:50px}}"],changeDetection:0});let i=e;return i})();var Lg=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({providers:[M({cmsComponents:{SimpleBannerComponent:{component:Ks,skeletonComponent:Qs}}})],imports:[$,G,ji,Qe,ht,gt]});let i=e;return i})();function Sx(i,e){if(i&1&&P(0,"sip-media",8),i&2){let r=C(2).ngIf;l("container",r.image)("alt",r.image.altText)}}function bx(i,e){if(i&1&&(P(0,"span",4),w(1,"safeHtml")),i&2){let r=C(2).ngIf;l("innerHTML",T(1,1,r.title),ye)}}function xx(i,e){if(i&1){let r=Ve();S(0,"a",5),Ce("click",function(){ke(r);let n=C().ngIf,o=C();return Re(o.onClick(n))}),v(1,Sx,1,2,"sip-media",6)(2,bx,2,3,"span",7),b()}if(i&2){let r=C().ngIf;l("sipRouterLink",r.link)("skipNavigation",!0),d(),l("ngIf",r.image),d(),l("ngIf",r.title)}}function Px(i,e){if(i&1&&(B(0),S(1,"div",1)(2,"div",2),v(3,xx,3,4,"a",3),P(4,"p",4),w(5,"safeHtml"),b()(),U()),i&2){let r=e.ngIf;d(3),l("ngIf",r.image||r.title),d(),l("innerHTML",T(5,2,r.paragraph),ye)}}var Ys=(()=>{let e=class e{constructor(t,n,o,s){this.component=t,this.sipGtmService=n,this.router=o,this.platformId=s,this.subscriptions=new Ee}ngOnInit(){pi(this.platformId)||(this.content?this.saveGtmEvent(this.content,Kt.PROMOTION_IMPRESSIONS_VIEW):this.subscriptions.add(this.component.data$.pipe(X()).subscribe(t=>{this.saveGtmEvent(t,Kt.PROMOTION_IMPRESSIONS_VIEW)})))}ngOnDestroy(){this.subscriptions.unsubscribe()}onClick(t){this.saveGtmEvent(t,Kt.PROMOTION_IMPRESSIONS),this.triggerSelectPromotionEvent(t),t.link&&this.router.navigateByUrl(t.link)}saveGtmEvent(t,n){if(t.promotionId){let o={id:t.promotionId,name:t.promotionName,creative:t.promotionCreative,position:t.promotionPosition,urlTarget:t.link};this.sipGtmService.pushPromotionImpressionEvent(o,n),this.sipGtmService.pushGA4ViewPromotionEvent(o)}}triggerSelectPromotionEvent(t){if(t.promotionId){let n={id:t.promotionId,name:t.promotionName,creative:t.promotionCreative,position:t.promotionPosition,urlTarget:t.link};this.sipGtmService.pushGA4SelectPromotionEvent(n)}}};e.\u0275fac=function(n){return new(n||e)(O(ee),O(At),O(re),O(Ne))},e.\u0275cmp=F({type:e,selectors:[["sip-featured-content"]],inputs:{content:"content"},decls:2,vars:3,consts:[[4,"ngIf"],[1,"col-xs-6","col-sm-3","col-md-3"],[1,"featured-content-component"],[3,"sipRouterLink","skipNavigation","click",4,"ngIf"],[3,"innerHTML"],[3,"click","sipRouterLink","skipNavigation"],["class","img-responsive",3,"container","alt",4,"ngIf"],[3,"innerHTML",4,"ngIf"],[1,"img-responsive",3,"container","alt"]],template:function(n,o){n&1&&(v(0,Px,6,4,"ng-container",0),w(1,"async")),n&2&&l("ngIf",o.content||T(1,1,o.component.data$))},dependencies:[W,nt,ft,q,ut],styles:["@media screen and (max-width: 767px){.featured-content-component[_ngcontent-%COMP%]{margin-bottom:15px}}.featured-content-component[_ngcontent-%COMP%] h4[_ngcontent-%COMP%]{font-size:18px;margin-top:10px;line-height:24px}@media screen and (min-width: 1024px){.featured-content-component[_ngcontent-%COMP%] h4[_ngcontent-%COMP%]{font-size:24px}}.featured-content-component[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{color:#707070;line-height:20px}[_nghost-%COMP%]{display:block}"],changeDetection:0});let i=e;return i})();function Ex(i,e){if(i&1&&(B(0),P(1,"sip-featured-content",3),U()),i&2){let r=e.$implicit;d(),l("content",r.value)}}function Ix(i,e){if(i&1&&(B(0),S(1,"div",1),v(2,Ex,2,1,"ng-container",2),w(3,"keyvalue"),b(),U()),i&2){let r=e.ngIf,t=C();d(2),l("ngForOf",ai(3,1,r.components,t.preserveOrderFn))}}var jg=(()=>{let e=class e{constructor(t){this.component=t}preserveOrderFn(){return 0}};e.\u0275fac=function(n){return new(n||e)(O(ee))},e.\u0275cmp=F({type:e,selectors:[["sip-featured-content-collection"]],decls:2,vars:3,consts:[[4,"ngIf"],[1,"row","featured-content-collection"],[4,"ngFor","ngForOf"],[3,"content"]],template:function(n,o){n&1&&(v(0,Ix,4,4,"ng-container",0),w(1,"async")),n&2&&l("ngIf",T
11(1,1,o.component.data$))},dependencies:[qe,W,Ys,q,pl],styles:[".featured-content-collection[_ngcontent-%COMP%]{margin:15px 0}@media screen and (max-width: 767px){.featured-content-collection.row[_ngcontent-%COMP%]{margin-left:-10px;margin-right:-10px}}@media screen and (min-width: 1024px){.featured-content-collection.row[_ngcontent-%COMP%]{margin-left:-15px;margin-right:-15px}.featured-content-collection[_ngcontent-%COMP%] > .col-md-3[_ngcontent-%COMP%]{padding-left:15px;padding-right:15px}}[_nghost-%COMP%]{display:block}"]});let i=e;return i})();var Zs=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275cmp=F({type:e,selectors:[["sip-featured-content-skeleton"]],decls:1,vars:0,consts:[[1,"sip-banner-skeleton"]],template:function(n,o){n&1&&P(0,"sip-skeleton",0)},dependencies:[Dt],styles:[".sip-banner-skeleton[_ngcontent-%COMP%]{width:60%;height:220px;margin-bottom:16px}@media screen and (min-width: 768px) and (max-width: 1024px),screen and (max-width: 767px){.sip-banner-skeleton[_ngcontent-%COMP%]{height:110px}}"],changeDetection:0});let i=e;return i})();var Xs=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({providers:[M({cmsComponents:{FeaturedContentComponent:{component:Ys,skeletonComponent:Zs}}})],imports:[$,G,Ae,Qe,ht,gt]});let i=e;return i})();var $g=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275cmp=F({type:e,selectors:[["sip-featured-content-collection-skeleton"]],decls:5,vars:0,consts:[[1,"featured-content-collection-skeleton"],[1,"sip-banner-skeleton"]],template:function(n,o){n&1&&(S(0,"div",0),P(1,"sip-featured-content-skeleton",1)(2,"sip-featured-content-skeleton",1)(3,"sip-featured-content-skeleton",1)(4,"sip-featured-content-skeleton",1),b())},dependencies:[Zs],styles:[".featured-content-collection-skeleton[_ngcontent-%COMP%]{column-count:4;column-gap:16px}@media screen and (max-width: 767px){.featured-content-collection-skeleton[_ngcontent-%COMP%]{column-count:2}}"],changeDetection:0});let i=e;return i})();var Bg=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({providers:[M({cmsComponents:{FeaturedContentCollectionComponent:{component:jg,skeletonComponent:$g}}})],imports:[$,qi,Xs]});let i=e;return i})();var wx=["container"],Tx=["cookieConsentModal"];function kx(i,e){if(i&1){let r=Ve();S(0,"div",3,1),w(2,"async"),S(3,"div",4),P(4,"div",5),w(5,"cxTranslate"),w(6,"safeHtml"),S(7,"div",6)(8,"button",7),Ce("click",function(){ke(r);let n=C();return Re(n.acceptAction())}),H(9),w(10,"cxTranslate"),b(),S(11,"button",8),Ce("click",function(){ke(r);let n=C(),o=Y(3);return Re(n.reviewAction(o))}),H(12),w(13,"cxTranslate"),b(),S(14,"button",9),Ce("click",function(){ke(r);let n=C();return Re(n.rejectAction())}),H(15),w(16,"cxTranslate"),b()()()()}if(i&2){let r=e.ngIf,t=C();Xt("invisible",!T(2,6,t.display$)),d(4),l("innerHTML",T(6,10,r.isContentStack?r.messageContent.footerContent:T(5,8,"text.gdpr.footer.content")),ye),d(5),le(" ",r.isContentStack?r.messageContent.buttonAccept:T(10,12,"text.gdpr.button.accept")," "),d(3),le(" ",r.isContentStack?r.messageContent.buttonReview:T(13,14,"text.gdpr.button.review")," "),d(3),le(" ",r.isContentStack?r.messageContent.buttonReject:T(16,16,"text.gdpr.button.reject")," ")}}function Rx(i,e){if(i&1&&(S(0,"div",24)(1,"div",14)(2,"div",25),H(3),w(4,"cxTranslate"),b()(),P(5,"hr"),b()),i&2){let r=C().ngIf;d(3),le(" ",r.isContentStack?r.messageContent.modalMainCookieDeletion:T(4,1,"text.gdpr.modal.main.cookie.deletion")," ")}}function Ax(i,e){if(i&1){let r=Ve();S(0,"sip-modal-dialog",11),w(1,"cxTranslate"),S(2,"div",12),P(3,"div",13),w(4,"cxTranslate"),P(5,"hr"),S(6,"div",14)(7,"div",15),P(8,"sip-checkbox",16),w(9,"cxTranslate"),b(),S(10,"div",17),H(11),w(12,"cxTranslate"),b()(),P(13,"hr"),S(14,"div",14)(15,"div",15)(16,"sip-checkbox",18),w(17,"cxTranslate"),Ce("handleChange",function(n){ke(r);let o=C(2);return Re(o.analyticsCookieCheckboxChange(n))}),b()(),S(18,"div",17),H(19),w(20,"cxTranslate"),b()(),P(21,"hr"),S(22,"div",14)(23,"div",15)(24,"sip-checkbox",19),w(25,"cxTranslate"),Ce("handleChange",function(n){ke(r);let o=C(2);return Re(o.preferencesCookieCheckboxChange(n))}),b()(),S(26,"div",17)(27,"span"),H(28),w(29,"cxTranslate"),b(),H(30,"\xA0 "),S(31,"span",20),H(32),w(33,"cxTranslate"),b()()(),P(34,"hr"),v(35,Rx,6,3,"div",21),b(),B(36,22),S(37,"sip-modal-actions",23),w(38,"cxTranslate"),w(39,"cxTranslate"),Ce("cancelled",function(){ke(r);let n=C(2);return Re(n.modal.dismiss("review"))})("confirmed",function(){ke(r);let n=C(2);return Re(n.modal.close({analyticsEnabled:n.preferences.analyticsEnabled,preferencesEnabled:n.preferences.preferencesEnabled}))}),b(),U(),b()}if(i&2){let r=e.ngIf,t=C(2);l("modalTitle",r.isContentStack?r.messageContent.modalHeader:T(1,15,"text.gdpr.modal.header"))("hideDismiss",!0),d(3),l("innerHTML",r.isContentStack?r.messageContent.modalMainContent:T(4,17,"text.gdpr.modal.main.content"),ye),d(5),l("label",r.isContentStack?r.messageContent.modalRequiredCookiesName:T(9,19,"text.gdpr.modal.required.cookies.name")),d(3),le(" ",r.isContentStack?r.messageContent.modalRequiredCookiesContent:T(12,21,"text.gdpr.modal.required.cookies.content")," "),d(5),l("checked",t.preferences.analyticsEnabled)("label",r.isContentStack?r.messageContent.modalAnalyticsCookiesName:T(17,23,"text.gdpr.modal.analytics.cookies.name")),d(3),le(" ",r.isContentStack?r.messageContent.modalAnalyticsCookiesContent:T(20,25,"text.gdpr.modal.analytics.cookies.content")," "),d(5),l("checked",t.preferences.preferencesEnabled)("label",r.isContentStack?r.messageContent.modalPreferencesCookiesName:T(25,27,"text.gdpr.modal.preferences.cookies.name")),d(4),Be(r.
11isContentStack?r.messageContent.modalPreferencesCookiesContent:T(29,29,"text.gdpr.modal.preferences.cookies.content")),d(4),Be(r.isContentStack?r.messageContent.modalPreferencesCookiesBoldContent:T(33,31,"text.gdpr.modal.preferences.cookies.boldcontent")),d(3),l("ngIf",t.consentWithdrawn),d(2),l("cancelText",r.isContentStack?r.messageContent.modalReviewCookiePolicyButton:T(38,33,"text.gdpr.modal.review.cookie.policy.button"))("confirmText",r.isContentStack?r.messageContent.modalSaveButton:T(39,35,"text.gdpr.modal.save.button"))}}function Nx(i,e){if(i&1&&(v(0,Ax,40,37,"sip-modal-dialog",10),w(1,"async")),i&2){let r=C();l("ngIf",T(1,1,r.component.data$))}}var zg=(()=>{let e=class e{constructor(t,n,o,s,a,c,p,m,_,y){this.component=t,this.cookieService=n,this.windowRef=o,this.cdr=s,this.document=a,this.sipSiteService=c,this.modalService=p,this.ngZone=m,this.platformId=_,this.sipRememberMeService=y,this.display$=new Xr(!1),this.cookieName="UserPreferences",this.preferences={},this.subscriptions=new Ee,this.ANGULAR_COMPONENT_REFERNCE="angularComponentReference",this.PREFERENCES="preferences",this.scriptElementName="script",this.consentWithdrawn=!1}ngOnInit(){if(ct(this.platformId))window[this.ANGULAR_COMPONENT_REFERNCE]={component:this,zone:this.ngZone,loadAngularFunction:()=>this.reviewAction(this.cookieConsentModal)};else return;this.readPreferencesFromCookie(),this.sipSiteService.getSite().subscribe(t=>{this.cookieConsentEnforcement=t.stores[0].cookieConsentEnforcement,this.cookieExpiredDays=t.stores[0].cookieExpiredDays,this.cookiePolicyUrl=t.stores[0].cookiePolicyUrl,this.cookieConsentEnforcement?this.applyPreferences():(this.preferences.visited=!0,this.preferences.analyticsEnabled=!0,this.preferences.preferencesEnabled=!0,this.saveCookie())}).unsubscribe(),this.injectCookieModalClickScript()}ngOnDestroy(){this.subscriptions.unsubscribe()}createScriptElement(t){return this.document.createElement(t)}injectCookieModalClickScript(){if(this.cookieConsentEnforcement){let t=this.createScriptElement(this.scriptElementName);t.text=` 12 function docReady(fn) { 13 // see if DOM is already available 14 if (document.readyState === "complete" || document.readyState === "interactive") { 15 // call on next available tick 16 setTimeout(fn, 1); 17 } else { 18 document.addEventListener("DOMContentLoaded", fn); 19 } 20 } 21 22 docReady(function() { 23 let cookieSettingsLink = document.getElementById('cookieSettingsLink'); 24 let loginCookieSettingsLink = document.getElementById('loginCookieSettingsLink'); 25 if (cookieSettingsLink || loginCookieSettingsLink) { 26 cookieSettingsLink.onclick = callAngularFunction; 27 loginCookieSettingsLink.onclick = callAngularFunction; 28 } 29 }) 30 31 function callAngularFunction() { 32 if (window.angularComponentReference !== undefined) { 33 window.angularComponentReference.zone.run(() => { 34 window.angularComponentReference.loadAngularFunction(); 35 }); 36 } 37 } 38 `,this.document.head.appendChild(t)}}acceptAction(){this.preferences.analyticsEnabled=!0,this.preferences.visited=!0,this.preferences.preferencesEnabled=!0,this.saveCookie()}reviewAction(t){this.closeComponent(),this.modal=this.modalService.open(t,{panelClass:"gdpr-modal-override"}),this.modal.result.then(n=>{this.preferences.preferencesEnabled&&!n.preferencesEnabled&&this.sipRememberMeService.expireRememberMeCookie(),this.preferences.analyticsEnabled=n.analyticsEnabled,this.preferences.preferencesEnabled=n.preferencesEnabled,this.preferences.visited=!0,this.saveCookie()},n=>{this.windowRef.document.location.href=this.cookiePolicyUrl})}rejectAction(){this.preferences.analyticsEnabled=!1,this.preferences.visited=!0,this.saveCookie()}closeComponent(){this.display$.next(!1),this.cdr.detectChanges()}openComponent(){this.display$.next(!0),this.cdr.detectChanges()}readPreferencesFromCookie(){this.cookieService.check(this.cookieName)&&(this.preferences=this.getGDPRCookie()),this.windowRef.nativeWindow&&(this.windowRef.nativeWindow[this.PREFERENCES]=this.preferences)}getGDPRCookie(){try{let t=this.cookieService.get(this.cookieName);return{visited:t.indexOf("visited")>=0,analyticsEnabled:t.indexOf("analyticsEnabled")>=0,preferencesEnabled:t.indexOf("preferencesEnabled")>=0}}catch{return{}}}applyPreferences(){let t=this.cookieService.get(this.cookieName);this.preferences.visited===void 0||this.preferences.visited===!1||t.split("-").length===2?this.openComponent():this.closeComponent()}saveCookie(){let t=(this.preferences.visited?"visited":"")+"-"+(this.preferences.analyticsEnabled?"analyticsEnabled":"")+"-"+(this.preferences.preferencesEnabled?"preferencesEnabled":"");this.cookieService.set(this.cookieName,t,Number(this.cookieExpiredDays),"/",void 0,!0,"Strict"),this.closeComponent(),this.sipRememberMeService.showRememberMeValue(!0)}analyticsCookieCheckboxChange(t){this.preferences.analyticsEnabled=t,this.consentWithdrawn=!t&&this.preferences.visited}preferencesCookieCheckboxChange(t){this.preferences.preferencesEnabled=t,this.consentWithdrawn=!t&&this.preferences.visited}};e.\u0275fac=function(n){return new(n||e)(O(ee),O(ei),O(K),O(Ai),O(bt),O(be),O(Nm),O(Zt),O(Ne),O(Sf))},e.\u0275cmp=F({type:e,selectors:[["sip-sip-gdpr-options-component"]],viewQuery:function(n,o){if(n&1&&(br(wx,5),br(Tx,5)),n&2){let s;xr(s=Pr())&&(o.containerElement=s.first),xr(s=Pr())&&(o.cookieConsentModal=s.first)}},decls:4,vars:3,consts:[["cookieConsentModal",""],["container",""],["id","gdprMessage","class","gdpr-message-item",3,"invisible",4,"ngIf"],["id","gdprMessage",1,"gdpr-message-item"],[1,"container","gdpr-message-container"],[1,"col-md-10","col-sm-8","col-xs-12","gdpr-message-item_content",3,"innerHTML"],["role","group",1,"col-md-2","col-sm-4","col-xs-12","gdpr-buttons"],["type","button",1,"btn","btn-primary","gdpr-accept",3,"click"],["type","button",1,"btn","btn-secondary","gdpr-review",3,"click"],["type","button",1,"btn","btn-secondary","gdpr-reject",3,"click"],[3,"modalTitle","hideDismiss",4,"ngIf"],[3,"modalTitle","hideDismiss"],[1,"gdpr-modal"],[1,"gdpr-modal-content",3,"innerHTML"],[1,"gdpr-modal-container"],[1,"gdpr-modal-left","gdpr-modal-left-text"],["idKey","requiredCookieCheckbox","disabled","","checked","",3,"label"],[1,"gdpr-modal-right"],["idKey","essentialCookieCheckbox",3,"handleChange","checked","label"],["idKey","preferencesCookieCheckbox",3,"handleChange","checked","label"],[1,"gdpr-modal-right-emphasized"],["id","withdrawConsentContainer",4,"ngIf"],["footer",""],[3,"cancelled","confirmed","cancelText","confirmText"],["id","withdrawConsentContainer"],[1,"gdpr-modal-content","cookie-consent-withdrawn-message"]],template:function(n,o){n&1&&(v(0,kx,17,18,"div",2),w(1,"async"),v(2,Nx,2,3,"ng-template",null,0,ne)),n&2&&l("ngIf",T
38(1,1,o.component.data$))},dependencies:[W,Hm,$m,zm,q,ut,xt],styles:["#gdprMessage[_ngcontent-%COMP%]{display:block}.gdpr-message-item[_ngcontent-%COMP%]{background-color:#eff7fb;width:100vw;margin-bottom:-126px;padding:12px 12px 12px 0;text-align:center;box-shadow:0 8px 12px -11px #9c9c9c,0 -10px 10px -14px #9c9c9c;border:1px solid #2a6293;display:none;position:fixed;bottom:126px;left:0;z-index:2000}.gdpr-message-item[_ngcontent-%COMP%] .gdpr-message-container[_ngcontent-%COMP%]{display:flex;flex-direction:row}@media screen and (max-width: 767px){.gdpr-message-item[_ngcontent-%COMP%] .gdpr-message-container[_ngcontent-%COMP%]{flex-direction:column}}.gdpr-message-item[_ngcontent-%COMP%] .gdpr-message-item_content[_ngcontent-%COMP%]{font-size:14px;margin:0 auto;flex:1}.gdpr-message-item[_ngcontent-%COMP%] .gdpr-message-item_content[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{font-weight:700}@media screen and (max-width: 767px){.gdpr-message-item[_ngcontent-%COMP%] .gdpr-message-item_content[_ngcontent-%COMP%]{max-width:100%;font-size:1em;padding-bottom:10px}}@media screen and (min-width: 768px) and (max-width: 1024px){.gdpr-message-item[_ngcontent-%COMP%] .gdpr-message-item_content[_ngcontent-%COMP%]{font-size:1.2em}}.gdpr-message-item[_ngcontent-%COMP%] .gdpr-buttons[_ngcontent-%COMP%]{display:flex;padding-right:0;gap:12px;min-width:40%}@media screen and (min-width: 768px) and (max-width: 1024px){.gdpr-message-item[_ngcontent-%COMP%] .gdpr-buttons[_ngcontent-%COMP%]{display:inline-block}}@media screen and (max-width: 767px){.gdpr-message-item[_ngcontent-%COMP%] .gdpr-buttons[_ngcontent-%COMP%]{width:100%}}.gdpr-message-item[_ngcontent-%COMP%] .gdpr-reject[_ngcontent-%COMP%]{display:inline-block}@media screen and (max-width: 767px){.gdpr-message-item[_ngcontent-%COMP%] .gdpr-accept[_ngcontent-%COMP%]{margin-bottom:8px}}@media screen and (max-width: 767px){.gdpr-message-item[_ngcontent-%COMP%] .gdpr-review[_ngcontent-%COMP%]{margin-bottom:0}}.gdpr-modal[_ngcontent-%COMP%] div.modal-header[_ngcontent-%COMP%]{display:none;text-align:center}.gdpr-modal-override[_ngcontent-%COMP%]{opacity:1!important}.gdpr-modal-override[_ngcontent-%COMP%] input[type=checkbox][_ngcontent-%COMP%], .gdpr-input[_ngcontent-%COMP%]{-webkit-appearance:checkbox}@media screen and (max-width: 767px){.gdpr-modal-save[_ngcontent-%COMP%] .gdpr-modal-review[_ngcontent-%COMP%]{margin-bottom:5px}}.gdpr-modal-container[_ngcontent-%COMP%]{display:flex}@media screen and (min-width: 768px) and (max-width: 1024px),screen and (max-width: 767px){.gdpr-modal-container[_ngcontent-%COMP%]{flex-direction:column}}.gdpr-modal-left[_ngcontent-%COMP%]{order:1;margin-right:10px}.gdpr-modal-left-text[_ngcontent-%COMP%]{min-width:190px;font-weight:700}.gdpr-modal-right[_ngcontent-%COMP%]{order:2}.gdpr-modal-right-emphasized[_ngcontent-%COMP%]{font-weight:700}.gdpr-modal-header[_ngcontent-%COMP%]{text-align:center;font-weight:700;font-size:20px;margin:15px;color:#0060a9}.cookie-consent-withdrawn-message[_ngcontent-%COMP%]{font-weight:700}"],changeDetection:0});let i=e;return i})();var Js=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({providers:[M({cmsComponents:{CostcoSipGdprOptionsComponent:{component:zg,skeletonComponent:!1}}})],imports:[$,Ae,pt,cf,Yn]});let i=e;return i})();var Gg=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275cmp=F({type:e,selectors:[["sip-banner-skeleton"]],decls:1,vars:0,consts:[[1,"sip-banner-skeleton"]],template:function(n,o){n&1&&P(0,"sip-skeleton",0)},dependencies:[Dt],styles:[".sip-banner-skeleton[_ngcontent-%COMP%]{display:block;min-height:200px}"],changeDetection:0});let i=e;return i})();function Dx(i,e){if(i&1&&P(0,"p",5),i&2){let r=C().ngIf;l("innerHTML",r.headline,ye)}}function Fx(i,e){if(i&1&&(P(0,"sip-media",6),w(1,"async")),i&2){let r=e.ngIf,t=C(2);l("container",r)("showTitle",T(1,2,t.showSlideTitle$))}}function Lx(i,e){if(i&1&&P(0,"p",5),i&2){let r=C().ngIf;l("innerHTML",r.content,ye)}}function jx(i,e){if(i&1){let r=Ve();S(0,"div",1)(1,"a",2),Ce("click",function(){let n=ke(r).ngIf,o=C();return Re(o.onClick(n))}),v(2,Dx,1,1,"p",3)(3,Fx,2,4,"sip-media",4),w(4,"async"),v(5,Lx,1,1,"p",3),b()()}if(i&2){let r=e.ngIf,t=C();l("sipObserve",t.handleComponentVisible.bind(t)),d(),l("sipRouterLink",r.urlLink)("target",r.external==="true"?"_blank":"_self"),d(),l("ngIf",r.headline),d(),l("ngIf",T
38(4,6,t.banner$)),d(2),l("ngIf",r.content)}}var Hg=(()=>{let e=class e{constructor(t,n,o,s){this.component=t,this.sipGtmService=n,this.router=o,this.platformId=s,this.subscriptions=new Ee,this.showSlideTitle$=this.component.data$.pipe(j(a=>!!a),x(a=>a.showSlideTitle===void 0||String(a.showSlideTitle)==="true")),this.banner$=this.component.data$.pipe(rt("media"),x(a=>a),j((a={})=>Object.entries(a).length>0))}handleComponentVisible(){this.subscriptions.add(this.component.data$.pipe(j(t=>!!t?.promotionId),X()).subscribe(t=>{this.saveGtmEvent(t,Kt.PROMOTION_IMPRESSIONS_VIEW)}))}saveGtmEvent(t,n){if(t.promotionId){let o={id:t.promotionId,name:t.promotionName,creative:t.promotionCreative,position:t.promotionPosition,urlTarget:t.urlLink};this.sipGtmService.pushPromotionImpressionEvent(o,n),this.sipGtmService.pushGA4ViewPromotionEvent(o)}}onClick(t){if(t.promotionId){let n={id:t.promotionId,name:t.promotionName,creative:t.promotionCreative,position:t.promotionPosition,urlTarget:t.urlLink};this.sipGtmService.pushGA4SelectPromotionEvent(n)}t.urlLink&&this.router.navigateByUrl(t.urlLink)}ngOnDestroy(){this.subscriptions.unsubscribe()}};e.\u0275fac=function(n){return new(n||e)(O(ee),O(At),O(re),O(Ne))},e.\u0275cmp=F({type:e,selectors:[["sip-banner"]],decls:2,vars:3,consts:[["class","simple-responsive-banner-component",3,"sipObserve",4,"ngIf"],[1,"simple-responsive-banner-component",3,"sipObserve"],[3,"click","sipRouterLink","target","title"],[3,"innerHTML",4,"ngIf"],["format","desktop",3,"container","showTitle",4,"ngIf"],[3,"innerHTML"],["format","desktop",3,"container","showTitle"]],template:function(n,o){n&1&&(v(0,jx,6,8,"div",0),w(1,"async")),n&2&&l("ngIf",T(1,1,o.component.data$))},dependencies:[W,ft,nt,Wi,q],styles:["[_nghost-%COMP%]{display:block}[_nghost-%COMP%] .simple-responsive-banner-component[_ngcontent-%COMP%]{margin-top:8px}"],changeDetection:0});let i=e;return i})();var Vg=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({providers:[M({cmsComponents:{BannerComponent:{component:Ks,skeletonComponent:Qs},SimpleResponsiveBannerComponent:{component:Hg,skeletonComponent:Gg}}})],imports:[$,G,ji,gt,Qe,ht,pt,Ki]});let i=e;return i})();function Hc(i){return i&&typeof i=="object"&&!Array.isArray(i)}function ea(i={},...e){if(!e.length)return i;let r=e.shift()||{};if(Hc(i)&&Hc(r))for(let t in r)r[t]instanceof Date?Object.assign(i,{[t]:r[t]}):Hc(r[t])?(i[t]||Object.assign(i,{[t]:{}}),ea(i[t],r[t])):Object.assign(i,{[t]:r[t]});return ea(i,...e)}function $x(i,e){if(i&1&&(S(0,"a",6),He(1,7),b()),i&2){C();let r=Y(5);d(),l("ngTemplateOutlet",r)}}function Bx(i,e){if(i&1&&(S(0,"a",8),He(1,7),b()),i&2){let r=C().ngIf,t=Y(5);l("href",r.bannerLink.url,Ct),d(),l("ngTemplateOutlet",t)}}function Ux(i,e){if(i&1&&(S(0,"a",9),He(1,7),b()),i&2){let r=C().ngIf,t=Y(5);l("sipRouterLink",r.bannerLink.url),d(),l("ngTemplateOutlet",t)}}function zx(i,e){if(i&1&&P(0,"sip-media",12),i&2){let r=e.ngIf,t=C(4);l("container",r)("loading",t.imageLoadingStrategy)}}function Gx(i,e){if(i&1&&(B(0),v(1,zx,1,2,"sip-media",11),w(2,"async"),U()),i&2){let r=C(3);d(),l("ngIf",T(2,1,r.medias$))}}function Hx(i,e){if(i&1&&(v(0,Gx,3,3,"ng-container",10),w(1,"async")),i&2){let r=C(2);l("ngIf",T(1,1,r.hasMedias$))}}function Vx(i,e){if(i&1&&(S(0,"div",2),v(1,$x,2,1,"a",3)(2,Bx,2,2,"a",4)(3,Ux,2,2,"a",5)(4,Hx,2,3,"ng-template",null,0,ne),b()),i&2){let r=e.ngIf;l("ngSwitch",r.bannerLink!=null&&r.bannerLink.url?r.external||r.bannerLink.external?"external":"":"none"),d(),l("ngSwitchCase","none"),d(),l("ngSwitchCase","external")}}var qg=(()=>{let e=class e{constructor(t){this.component=t,this.data$=this.component.data$.pipe(j(n=>!!n),x(n=>{try{let o=ea({},n);return typeof n.external=="string"&&(o.external=n.external==="true"),n.bannerLink&&typeof n.bannerLink.external=="string"&&(o.bannerLink.external=n.bannerLink.external==="true"),o}catch(o){throw new Error(`SIP - ${o.message}`)}})),this.medias$=this.data$.pipe(rt("medias")),this.hasMedias$=this.medias$.pipe(x((n={})=>Object.entries(n).length>0)),this.imageLoadingStrategy=Nn.EAGER}};e.\u0275fac=function(n){return new(n||e)(O(ee))},e.\u0275cmp=F({type:e,selectors:[["sip-dynamic-banner"]],decls:2,vars:3,consts:[["banner",""],["class","banner",3,"ngSwitch",4,"ngIf"],[1,"banner",3,"ngSwitch"],["class","block",4,"ngSwitchCase"],["class","block",3,"href",4,"ngSwitchCase"],["class","block",3,"sipRouterLink",4,"ngSwitchDefault"],[1,"block"],[3,"ngTemplateOutlet"],[1,"block",3,"href"],[1,"block",3,"sipRouterLink"],[4,"ngIf"],["format","desktop","class","d-block",3,"container","loading",4,"ngIf"],["format","desktop",1,"d-block",3,"container","loading"]],template:function(n,o){n&1&&(v(0,Vx,6,3,"div",1),w(1,"async")),n&2&&l("ngIf",T
38(1,1,o.data$))},dependencies:[W,ci,sl,al,cl,nt,ft,q],encapsulation:2,changeDetection:0});let i=e;return i})();var Wg=(()=>{let e=class e{constructor(t){this.skeletonService=t,this.LOADING_STRATEGY=Nn,this.placeholderImage$=this.skeletonService.getBannerImagePlaceholder()}};e.\u0275fac=function(n){return new(n||e)(O(xf))},e.\u0275cmp=F({type:e,selectors:[["sip-dynamic-banner-placeholder"]],decls:3,vars:8,consts:[["format","desktop",1,"sip-dynamic-banner-placeholder",3,"container","alt","forceOnErrorHandler","loading"]],template:function(n,o){n&1&&(P(0,"sip-media",0),w(1,"async"),w(2,"cxTranslate")),n&2&&l("container",T(1,4,o.placeholderImage$))("alt",T(2,6,"text.loadingMessage"))("forceOnErrorHandler",!0)("loading",o.LOADING_STRATEGY.EAGER)},dependencies:[ft,q,xt],styles:[".sip-dynamic-banner-placeholder[_ngcontent-%COMP%]{display:block;min-height:200px}.sip-dynamic-banner-placeholder.has-error[_ngcontent-%COMP%]{display:none}"],changeDetection:0});let i=e;return i})();var Kg=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({providers:[M({cmsComponents:{CostcoDynamicBannerComponent:{component:qg,skeletonComponent:Wg}}})],imports:[$,Qe,gt,ht,pt]});let i=e;return i})();var Qg=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({providers:[M({featureModules:{compareProduct:{cmsComponents:["CompareProductWidgetComponent"]}}})]});let i=e;return i})();var Yg=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({providers:[M({featureModules:{compareProduct:{module:()=>import("./chunk-3GLFX77K.js").then(t=>t.SipCompareProductWidgetModule)}}})],imports:[Qg]});let i=e;return i})();var Zg=(()=>{let e=class e extends Do{constructor(t,n){super(t,n)}getInjector(t,n,o,s){let a=this.cmsComponentsService.getMapping(t,s)?.providers;return a=a||[],si.create({providers:[{provide:Ba,useValue:this.getCustomizedCmsData(n,o,s)},{provide:ee,useExisting:Ba},...a],parent:o||this.injector})}getCustomizedCmsData(t,n,o){return{uid:t,position:o,data$:(n||this.injector).get(xe).getComponentData(t)}}};e.\u0275fac=function(n){return new(n||e)(u(No),u(si))},e.\u0275prov=I({token:e,factory:e.\u0275fac,providedIn:"root"});let i=e;return i})();var Xg=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({imports:[G.forChild([{path:"",canActivate:[De],children:[{path:null,canActivate:[oe],runGuardsAndResolvers:"paramsOrQueryParamsChange",loadChildren:()=>import("./chunk-FGL2PKHY.js").then(t=>t.SipCartPageModule),data:{pageLabel:"cart",cxRoute:"cart"}}]}])]});let i=e;return i})();var Jg=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({imports:[G.forChild([{path:"",canActivate:[De],children:[{path:null,canActivate:[oe],runGuardsAndResolvers:"paramsOrQueryParamsChange",loadChildren:()=>import("./chunk-T5WMU7RK.js").then(t=>t.SipTireSearchPageModule),data:{pageLabel:"tiresearch",cxRoute:"tireSearch"}},{path:null,canActivate:[oe],runGuardsAndResolvers:"paramsOrQueryParamsChange",loadChildren:()=>import("./chunk-T5WMU7RK.js").then(t=>t.SipTireSearchPageModule),data:{pageLabel:"tiresearch",cxRoute:"tireSearchSelectSize"}},{path:null,canActivate:[oe],runGuardsAndResolvers:"paramsOrQueryParamsChange",loadChildren:()=>import("./chunk-T5WMU7RK.js").then(t=>t.SipTireSearchPageModule),data:{pageLabel:"tiresearch",cxRoute:"tireSearchSkipPos"}},{path:null,canActivate:[oe],runGuardsAndResolvers:"paramsOrQueryParamsChange",loadChildren:()=>import("./chunk-T5WMU7RK.js").then(t=>t.SipTireSearchPageModule),data:{pageLabel:"tiresearch",cxRoute:"automotiveSearchService"}}]}])]});let i=e;return i})();var Pe=(()=>{let e=class e{constructor(t,n,o,s,a,c,p,m){this.authGuard=t,this.myAccountService=n,this.redirectService=o,this.cmsPageGuard=s,this.cmsService=a,this.winRef=c,this.routingService=p,this.abstractLoggerFactory=m,this.logger=this.abstractLoggerFactory.getLogger("SipMyAccountPageGuard")}canActivate(t,n){if(!this.winRef.isBrowser())return this.cmsPageGuard.canActivate(t,n);let o=this.redirectService.handleRedirect("/");return this.authGuard.canActivate().pipe(A(s=>!s||s instanceof kt?(this.routingService.go({cxRoute:"login"},{queryParams:{redirect:n.url}}),D(!1)):this.cmsPageGuard.canActivate(t,n)),Ge(s=>(this.logger.error("Caught error: ",s),D(o))))}};e.\u0275fac=function(n){return new(n||e)(u(ui),u(ls),u(it),u(oe),u(xe),u(K),u(lt),u(et))},e.\u0275prov=I({token:e,factory:e.\u0275fac,providedIn:"root"});let i=e;return i})();var t0=(()=>{let e=class e{constructor(t,n,o,s){this.myAccountPageGuard=t,this.membershipService=n,this.globalMessageService=o,this.router=s}canActivate(t,n){return this.myAccountPageGuard.canActivate(t,n).pipe(A(o=>o===!0?this.membershipService.canCancelMembership().pipe(x(s=>s?(s!=="CANCELLATION_DISABLED"&&this.globalMessageService.addMessage({key:"text.account.cancel.membership.in.warehouse.message"},je.MSG_TYPE_CONFIRMATION),this.router.createUrlTree(["/my-account/update-profile"])):o)):D(o)))}};e.\u0275fac=function(n){return new(n||e)(u(Pe),u(_f),u(Nt),u(re))},e.\u0275prov=I({token:e,factory:e.\u0275fac,providedIn:"root"});let i=e;return i})();var i0=(()=>{let e=class e{constructor(t,n,o,s){this.myAccountPageGuard=t,this.router=n,this.baseStoreService=o,this.routingService=s}canActivate(t,n){let o=t.params.addressType,s=Object.values(Vo).includes(o),a=n.url.split("?")[0],c=t.queryParams;return this.baseStoreService.getCurrentBaseStore().pipe(A(p=>{if(p.availableForAddressSplitting){if(!s)return this.routingService.redirectSafely([a,Vo.SHIPPING],c),D(!1)}else if(!s)return this.routingService.redirectSafely([a,Vo.ALL_ADDRESSES],c),D(!1);return this.myAccountPageGuard.canActivate(t,n)}),z(1))}};e.\u0275fac=function(n){return new(n||e)(u(Pe),u(re),u(Ho),u(lt))},e.\u0275prov=I({token:e,factory:e.\u0275fac,providedIn:"root"});let i=e;return i})();var n0=(()=>{let e=class e extends Pe{constructor(t,n,o,s,a,c,p,m,_,y,E){super(t,n,o,s,a,c,p,E),this.authGuard=t,this.myAccountService=n,this.redirectService=o,this.cmsPageGuard=s,this.cmsService=a,this.winRef=c,this.routingService=p,this.bulkOrderService=m,this.semanticPathService=_,this.router=y,this.abstractLoggerFactory=E}canActivate(t,n){return this.bulkOrderService.bulkOrderValidationResults$.pipe(A(o=>o?super.canActivate(t,n):D(this.router.createUrlTree(this.semanticPathService.transform({cxRoute:"bulkOrders"})))))}};e.\u0275fac=function(n){return new(n||e)(u(ui),u(ls),u(it),u(oe),u(xe),u(K),u(lt),u(Kf),u(Nl),u(re),u(et))},e.\u0275prov=I({token:e,factory:e.\u0275fac,providedIn:"root"});let i=e;return i})();var zr=(()=>{let e=class e{constructor(){this.myAccountPageGuard=L(Pe),this.featureModuleService=L(hi),this.router=L(re)}canActivate(t,n){return this.myAccountPageGuard.canActivate(t,n).pipe(A(o=>
38o?this.featureModuleService.resolveFeature("orderReturns").pipe(x(()=>!0)):D(o)))}};e.\u0275fac=function(n){return new(n||e)},e.\u0275prov=I({token:e,factory:e.\u0275fac,providedIn:"root"});let i=e;return i})();var ta=(()=>{let e=class e{constructor(){this.myAccountPageGuard=L(Pe),this.featureModuleService=L(hi)}canActivate(t,n){return this.myAccountPageGuard.canActivate(t,n).pipe(A(o=>o?this.featureModuleService.resolveFeature("orderCancel").pipe(x(()=>!0)):D(o)))}};e.\u0275fac=function(n){return new(n||e)},e.\u0275prov=I({token:e,factory:e.\u0275fac,providedIn:"root"});let i=e;return i})();var Kx=["edit","return-select-items","cancel-select-items"],r0=(()=>{let e=class e{constructor(){this.myAccountPageGuard=L(Pe),this.redirectService=L(it),this.globalMessageService=L(Nt),this.orderDetailsService=L(Vf),this.router=L(re),this.loggerFactory=L(et),this.logger=this.loggerFactory.getLogger("SipOrderDetailModeGuard")}canActivate(t,n){return this.myAccountPageGuard.canActivate(t,n).pipe(A(o=>{if(!o)return D(o);let s=t.params.mode;return s&&!Kx.includes(s)?(this.logger.warn(`Invalid mode "${s}" for order detail`),D(this.redirectService.handleRedirect("my-account/orders"))):(s==="cancel-select-items"&&setTimeout(()=>J(this,null,function*(){let a=yield pe(this.orderDetailsService.getOrderDetails());if(!a.entries.some(c=>c.cancelDecision?.eligible))return this.router.navigate([tt.ORDER_DETAILS,a.code],{replaceUrl:!0}).then(()=>{this.globalMessageService.addMessage({key:"text.account.order.cancel.confirmation.fail"},je.MSG_TYPE_ERROR)})})),D(!0))}))}};e.\u0275fac=function(n){return new(n||e)},e.\u0275prov=I({token:e,factory:e.\u0275fac,providedIn:"root"});let i=e;return i})();var ia=(()=>{let e=class e{constructor(){this.trackingDetailsService=L(Qf),this.siteService=L(be),this.redirectService=L(it)}canActivate(t,n){return this.trackingDetailsService.setTrackingDetails(null),this.trackingDetailsService.loadTrackingDetails({trackingToken:t.queryParamMap.get("trk"),orderCode:t.paramMap.get("orderCode"),consignmentCode:t.paramMap.get("consignmentCode")}).pipe(to(this.siteService.getSite()),x(([o,s])=>{let a=o?.parcelItem?.externalTrackingLink,c=/^https?:\/\//i.test(a??"");return s.forceExternalTrackingPage&&c?(this.redirectService.handleRedirect(a),!1):(this.trackingDetailsService.setTrackingDetails(o),!0)}),Ge(({error:o})=>{if(o?.errors?.[0]?.type==="NotFoundError"){let s=o?.errors?.[0]?.message??"";if(/^https?:\/\//i.test(s))return this.redirectService.handleRedirect(s),D(!1)}return D(!0)}))}};e.\u0275fac=function(n){return new(n||e)},e.\u0275prov=I({token:e,factory:e.\u0275fac,providedIn:"root"});let i=e;return i})();var o0=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({imports:[G.forChild([{path:"",canActivate:[De],children:[{path:null,canActivate:[Pe],loadChildren:()=>import("./chunk-B5MXAPGA.js").then(t=>t.SipMyAccountPageModule),data:{pageLabel:Me.REWARDS.pageId,cxRoute:"myRewards"}},{path:null,canActivate:[Pe],loadChildren:()=>import("./chunk-B5MXAPGA.js").then(t=>t.SipMyAccountPageModule),data:{pageLabel:Me.RECEIPTS.pageId,cxRoute:"myReceipts"}},{path:null,canActivate:[Pe],loadChildren:()=>import("./chunk-B5MXAPGA.js").then(t=>t.SipMyAccountPageModule),data:{pageLabel:Me.REORDER.pageId,cxRoute:"reorderDetails"}},{path:null,canActivate:[zr],loadChildren:()=>import("./chunk-B5MXAPGA.js").then(t=>t.SipMyAccountPageModule),data:{pageLabel:Me.ORDER_RETURN_COMPLETED.pageId,cxRoute:"orderReturnsCompleted"}},{path:null,canActivate:[zr],loadChildren:()=>import("./chunk-B5MXAPGA.js").then(t=>t.SipMyAccountPageModule),data:{pageLabel:Me.ORDER_RETURN_REVIEW.pageId,cxRoute:"orderReturnsReview"}},{path:null,canActivate:[zr],loadChildren:()=>import("./chunk-B5MXAPGA.js").then(t=>t.SipMyAccountPageModule),data:{pageLabel:Me.ORDER_RETURN_METHOD.pageId,cxRoute:"orderReturnsEditItems"}},{path:null,canActivate:[zr],loadChildren:()=>import("./chunk-B5MXAPGA.js").then(t=>t.SipMyAccountPageModule),data:{pageLabel:Me.ORDER_RETURNS.pageId,cxRoute:"orderReturnsSelect"}},{path:null,canActivate:[ta],loadChildren:()=>import("./chunk-B5MXAPGA.js").then(t=>t.SipMyAccountPageModule),data:{pageLabel:Me.ORDER_CANCEL_REVIEW.pageId,cxRoute:"orderCancelReview"}},{path:null,canActivate:[ta],loadChildren:()=>import("./chunk-B5MXAPGA.js").then(t=>t.SipMyAccountPageModule),data:{pageLabel:Me.ORDER_CANCEL_CONFIRMATION.pageId,cxRoute:"orderCancelConfirmation"}},{path:null,canActivate:[ta],loadChildren:()=>import("./chunk-B5MXAPGA.js").then(t=>t.SipMyAccountPageModule),data:{pageLabel:Me.ORDER_CANCEL.pageId,cxRoute:"orderCancelSelect"}},{path:null,canActivate:[r0],loadChildren:()=>import("./chunk-B5MXAPGA.js").then(t=>t.SipMyAccountPageModule),data:{pageLabel:Me.ORDERDETAILS.pageId,cxRoute:"order"}},{path:null,canActivate:[Pe],loadChildren:()=>import("./chunk-B5MXAPGA.js").then(t=>t.SipMyAccountPageModule),data:{pageLabel:Me.ORDERS.pageId,cxRoute:"orders"}},{path:null,canActivate:[Pe],loadChildren:()=>import("./chunk-B5MXAPGA.js").then(t=>t.SipMyAccountPageModule),data:{pageLabel:Me.UPGRADE_MEMBERSHIP.pageId,cxRoute:"upgradeMembership"}},{path:null,canActivate:[Pe],loadChildren:()=>import("./chunk-B5MXAPGA.js").then(t=>t.SipMyAccountPageModule),data:{pageLabel:Me.SUBSCRIPTIONS.pageId,cxRoute:"subscriptions"}},{path:null,canActivate:[Pe],loadChildren:()=>import("./chunk-B5MXAPGA.js").then(t=>t.SipMyAccountPageModule),data:{pageLabel:Me.WISH_LIST.pageId,cxRoute:"wishlist"}},{path:null,canActivate:[Pe],loadChildren:()=>import("./chunk-B5MXAPGA.js").then(t=>t.SipMyAccountPageModule),data:{pageLabel:Me.UPDATE_PROFILE.pageId,cxRoute:"updateProfile"}}
38,{path:null,canActivate:[t0],loadChildren:()=>import("./chunk-B5MXAPGA.js").then(t=>t.SipMyAccountPageModule),data:{pageLabel:Me.CANCEL_MEMBERSHIP.pageId,cxRoute:"cancelMembership"}},{path:null,canActivate:[Pe],loadChildren:()=>import("./chunk-B5MXAPGA.js").then(t=>t.SipMyAccountPageModule),data:{pageLabel:Me.UNREGISTER_ACCOUNT.pageId,cxRoute:"unregisterAccount"}},{path:null,canActivate:[Pe],loadChildren:()=>import("./chunk-B5MXAPGA.js").then(t=>t.SipMyAccountPageModule),data:{pageLabel:Me.UPDATE_PASSWORD.pageId,cxRoute:"updatePassword"}},{path:null,canActivate:[Pe],loadChildren:()=>import("./chunk-B5MXAPGA.js").then(t=>t.SipMyAccountPageModule),data:{pageLabel:Me.CONTACT_US.pageId,cxRoute:"contactUs"}},{path:null,canActivate:[Pe],loadChildren:()=>import("./chunk-B5MXAPGA.js").then(t=>t.SipMyAccountPageModule),data:{pageLabel:Me.PREFERENCES.pageId,cxRoute:"marketingPreferences"}},{path:null,canActivate:[i0],loadChildren:()=>import("./chunk-B5MXAPGA.js").then(t=>t.SipMyAccountPageModule),data:{pageLabel:Me.ADDRESS_BOOK.pageId,cxRoute:"addressBook"}},{path:null,canActivate:[Pe],loadChildren:()=>import("./chunk-B5MXAPGA.js").then(t=>t.SipMyAccountPageModule),data:{pageLabel:Me.ADD_EDIT_ADDRESS.pageId,cxRoute:"addEditAddress"}},{path:null,canActivate:[Pe],loadChildren:()=>import("./chunk-B5MXAPGA.js").then(t=>t.SipMyAccountPageModule),data:{pageLabel:Me.BULK_ORDERS.pageId,cxRoute:"bulkOrders"}},{path:null,canActivate:[n0],loadChildren:()=>import("./chunk-B5MXAPGA.js").then(t=>t.SipMyAccountPageModule),data:{pageLabel:Me.BULK_ORDERS_VALIDATION_RESULTS.pageId,cxRoute:"bulkOrdersValidationResults"}},{path:null,canActivate:[Pe],loadChildren:()=>import("./chunk-B5MXAPGA.js").then(t=>t.SipMyAccountPageModule),data:{pageLabel:Me.PAYMENT_METHODS.pageId,cxRoute:"paymentMethods"}},{path:null,canActivate:[Pe],loadChildren:()=>import("./chunk-B5MXAPGA.js").then(t=>t.SipMyAccountPageModule),data:{pageLabel:Me.INVOICE_PROFILE.pageId,cxRoute:"carrier"}},{path:null,runGuardsAndResolvers:"paramsOrQueryParamsChange",canActivate:[Pe,ia],loadChildren:()=>import("./chunk-B5MXAPGA.js").then(t=>t.SipMyAccountPageModule),data:{pageLabel:Me.ACCOUNT_CONSIGNMENT_TRACKING.pageId,cxRoute:"accountTrackingDetails"}}]}])]});let i=e;return i})();var s0=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({imports:[$,$i,Ln,G.forChild([{path:"",pathMatch:"full",canActivate:[De],children:[{path:null,canActivate:[oe],component:js,data:{cxRoute:"home"}}]}])]});let i=e;return i})();var Gr=(()=>{let e=class e{constructor(t,n,o,s,a,c){this.cmsPageGuard=t,this.activeCartService=n,this.siteConfigService=o,this.router=s,this.redirectService=a,this.tireService=c}isTiresCartEntry(t=[],n){return t.some(o=>o.entries.some(s=>s.entryNumber===n&&s.product?.tire))}canActivate(t,n){let o=t.params.cartEntryNumber,s=t.queryParams,a=this.tireService.storeIdFromCookie;return o?ae([this.activeCartService.getActive(),this.activeCartService.getLoading(),this.siteConfigService.getConfig("tires.page.prefix.tirestorefinder.warehouseselect")]).pipe(j(([c,p])=>!p),z(1),A(([c,p,m])=>this.isTiresCartEntry(c.cartGroupEntries,+o)?D(this.redirectService.handleRedirect(m,{},301)):this.cmsPageGuard.canActivate(t,n))):s?.sizeSearch&&s?.skipPos!=="false"?a?this.siteConfigService.getConfig(Uo).pipe(z(1),x(c=>this.router.createUrlTree([c+Cm],{queryParams:s}))):this.siteConfigService.getConfig(ym).pipe(z(1),x(c=>this.router.createUrlTree([c+"/results"],{queryParams:{frontfilters:this.tireService.frontFilters,rearfilters:this.tireService.rearFilters,sizeSearch:"true",skipPos:"false"}}))).toPromise():this.cmsPageGuard.canActivate(t,n)}};e.\u0275fac=function(n){return new(n||e)(u(oe),u(Qt),u(Ke),u(re),u(it),u(Hi))},e.\u0275prov=I({token:e,factory:e.\u0275fac,providedIn:"root"});let i=e;return i})();var a0=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({imports:[G.forChild([{path:"",children:[{path:null,canActivate:[Gr],loadChildren:()=>import("./chunk-7RAJ75VS.js").then(t=>t.SipStoreFinderPageModule),data:{pageLabel:cm,cxRoute:"storeFinder"}},{path:null,canActivate:[Gr],loadChildren:()=>import("./chunk-7RAJ75VS.js").then(t=>t.SipStoreFinderPageModule),data:{pageLabel:lm,cxRoute:"bopisStoreFinder",storeFinder:"bopis"}},{path:null,canActivate:[Gr],loadChildren:()=>import("./chunk-7RAJ75VS.js").then(t=>t.SipStoreFinderPageModule),data:{pageLabel:pm,cxRoute:"tireStoreFinder",storeFinder:"tires"}},{path:null,canActivate:[Gr],loadChildren:()=>import("./chunk-7RAJ75VS.js").then(t=>t.SipStoreFinderPageModule),data:{pageLabel:dm,cxRoute:"batteriesStoreFinder",storeFinder:"battery"}}]}])]});let i=e;return i})();var na=(()=>{let e=class e{constructor(){this.checkoutService=L(Vn),this.router=L(re),this.windowRef=L(K)}canActivate(t,n){return J(this,null,function*(){return this.checkCheckoutEnabled(t,n)})}checkCheckoutEnabled(t,n){return J(this,null,function*(){let o=yield pe(this.checkoutService.isSPACheckoutEnabled()),[s]=n.url.split("?"),a=tt.LEGACY_CHECKOUT===s,c=tt.CHECKOUT===s,p=s.startsWith(tt.LEGACY_CHECKOUT_ORDER_CONFIRMATION),m=s.startsWith(tt.CHECKOUT_ORDER_CONFIRMATION);if(o){if(c||m)return!0;
38if(a)return this.router.createUrlTree([`${tt.CHECKOUT}`],{queryParams:t.queryParams});if(p)return this.router.createUrlTree([`${tt.CHECKOUT_ORDER_CONFIRMATION}`],{queryParams:t.queryParams})}else if(a||p)return this.windowRef.location.href=n.url,!1;return!0})}};e.\u0275fac=function(n){return new(n||e)},e.\u0275prov=I({token:e,factory:e.\u0275fac,providedIn:"root"});let i=e;return i})();var c0="individualCheckoutCartGroup",ra=(()=>{let e=class e{constructor(){this.cmsPageGuard=L(Li),this.checkoutVersionGuard=L(na),this.windowRef=L(K),this.checkoutService=L(Vn),this.activeCartService=L(Qt),this.router=L(re),this.userService=L(Ci),this.userIdService=L(Gn),this.siteConfigService=L(Ke),this.globalMessageService=L(Nt),this.siteService=L(be),this.maskingService=L(jm),this.cartMessagesService=L(Xo),this.addToCartService=L(Of),this._logger=L(et).getLogger("SipCheckoutPageGuard")}canActivate(t,n){return J(this,null,function*(){try{return yield this.canActivateInternal(t,n)}catch(o){throw this.addToCartService.closeBuyNowLoadingOverlayIfOpen(),o}})}canActivateInternal(t,n){return J(this,null,function*(){if(!this.windowRef.isBrowser())return!1;let o=yield this.checkoutVersionGuard.canActivate(t,n);if(o!==!0)return o;yield this.waitForStableCart();let s=yield pe(this.activeCartService.getActive()),a=yield pe(this.userService.isAnonymousUser()),c=yield this.processQueryParameters(t,n);if(c!==null)return c;yield this.waitForStableCart();let p=yield pe(this.activeCartService.getActive());if(!p?.cartGroupEntries?.length)return this.router.createUrlTree([tt.CART]);let m=yield pe(this.activeCartService.getActiveCartId()),_=yield this.validateAnonymousAccess(p,n);if(_!==null){let k=yield pe(this.userIdService.takeUserId());return yield this.loadNewCart(k,s.guid),_}!a&&(p.buyNow||p.individualCheckout)&&this.checkoutService.setOriginalCartId(s?.code??_o);let y=yield pe(this.activeCartService.validateCartPreCheckout({validateCartBasics:!0})),E=yield this.performAllCartValidations(m,y);return E&&!p.buyNow&&y?.modifications?.length?(this.cartMessagesService.setCartModificationsAtNavigationEnd(y.modifications),E):(yield this.validateIdentity(),this.addToCartService.closeBuyNowLoadingOverlayIfOpen(),yield this.waitForStableCart(),yield pe(this.cmsPageGuard.canActivate(t,n)))})}loadNewCart(t,n){return J(this,null,function*(){yield this.waitForStableCart(),yield this.activeCartService.loadNewCart(t,n),yield this.waitForStableCart()})}waitForStableCart(){return J(this,null,function*(){yield pe(this.activeCartService.isStable().pipe(j(Boolean)))})}processQueryParameters(t,n){return J(this,null,function*(){let o=t.queryParams.cartId??t.queryParams.paramCartId;if(o){let c=yield pe(this.userIdService.takeUserId());yield this.loadNewCart(c,o)}let s=t.queryParams[c0],a=yield pe(this.userIdService.takeUserId());if(s&&a!==Jt)try{let c=yield pe(this.activeCartService.takeActiveCartId()),p=yield pe(this.activeCartService.createIndividualCheckoutCartForCartGroup(s,c));return this.router.createUrlTree([tt.CHECKOUT],{queryParams:{cartId:p.code}})}catch{this._logger.error(`Something went wrong when attempting to create an individual checkout for cart group: ${s}`)}return null})}performAllCartValidations(t,n){return J(this,null,function*(){let o=yield pe(this.userIdService.takeUserId()),s=yield pe(this.siteConfigService.getConfig("batteries.cartgroup.cartgroupname"));if(o!==Jt)if(n.deliveryAddress){if(n.deliveryAddress.visibleInAddressBook&&!Zf(n,s)){let c=n.cartGroupEntries.some(m=>!m.deliveryAddress&&m.cartGroup.groupId!==s&&!m.cartGroup.tire),p=n.cartGroupEntries.some(m=>m.cartGroup.groupId!==s&&m.entries.some(_=>!_.deliveryAddress&&!_.product?.tire));(c||p)&&(yield this.activeCartService.replaceCartDeliveryAddress(n.deliveryAddress))}}else{let p=(yield pe(this.activeCartService.loadDefaultShippingAddress())).code??n.code;p&&(yield this.loadNewCart(o,p))}let a=yield this.primaryCartValidation(n);return a!==null?a:(yield this.inlineCartValidation(n),Yo.isCartIdGuid(t)?t!==n.guid&&(yield this.loadNewCart(o,n.guid)):t!==n.code&&(yield this.loadNewCart(o,n.code)),null)})}validateAnonymousAccess(t,n){return J(this,null,function*(){if(!(yield pe(this.userService.isAnonymousUser()))||Yf(t,[Ar.MEMBERSHIP]))return null;let s=n.url.split("?")[0];if(t.individualCheckout){let a=t.cartGroupEntries?.[0]?.cartGroup,c=a?.individualCheckout?a.groupId:null;(c||c===null)&&(s+=`?${c0}=${c}`)}return this.router.createUrlTree([tt.LOGIN],{queryParams:{redirect:s}})})}primaryCartValidation(t){return J(this,null,function*(){let n=(yield pe(this.userIdService.takeUserId()))!==Jt;if(!t.deliveryAddress&&n&&(yield pe(this.activeCartService.loadDefaultShippingAddress())),t.modifications?.length){let{modifications:s}=t,a=(...Q)=>s.some(_e=>_e.statusCode&&Q.includes(_e.statusCode)),c=s.filter(Q=>!!Q.statusCode).every(Q=>Q.statusCode===mt.SUCCESS),p=s.find(Q=>Q.statusCode===mt.BD_PRICE_CHANGED)??null,m=a(mt.CHECKOUT_PRODUCT_NOT_DELIVERABLE,mt.BUYNOW_PRODUCT_RESTRICTED),_=a(mt.NO_STOCK,mt.NO_PRICE,mt.BD_NO_PRICE,mt.BD_NO_STOCK),y=a(mt.NO_STOCK);!m&&_&&t.cartGroupEntries?.length&&this.globalMessageService.addMessage({key:"basket.validation.ineligible"},je.MSG_TYPE_CONFIRMATION);let k=(yield pe(this.siteService.getSite())).baseStore.inputDeliveryByAddress;if(p){let Q=p.postalCode;k&&p.address?.shortFormattedAddress&&(Q=yield pe(this.maskingService.mask(p.address.shortFormattedAddress,Lm.ADDRESS))),this.globalMessageService.addMessage({key:"single.checkout.text.business.delivery.validation.price.changed.error",params:{0:Q}},je.MSG_TYPE_WARNING)}let N=t.modifications.filter(Q=>(!Q.entry||!Q.entry?.eligible)&&Q.statusCode!==mt.BD_PRICE_CHANGED&&!y&&Q.statusCode);if(this.cartMessagesService.setCartModificationsAtNavigationEnd(N),!c&&(yield this._shouldRedirectToCart()))return this._logger.info("Redirecting due to invali
38d cart at checkout",JSON.stringify(t.modifications)),this.router.parseUrl("/cart")}return Ja(t)&&this.showRestrictionMessageAtNavigationEnd(),null})}showRestrictionMessageAtNavigationEnd(){pe(this.router.events.pipe(j(t=>t instanceof pn||t instanceof El),z(1))).then(()=>{this.globalMessageService.addMessage({key:"basket.validation.checkout.product.not.deliverable.global.error"},je.MSG_TYPE_ERROR_RESTRICTED_DELIVERY)})}inlineCartValidation(t){return J(this,null,function*(){let n=new Map,o=t.modifications??[];if(o.length){let a=[Ar.SERVICE_ADDON,Ar.SHIPPABLE_ADDON,Ar.DELIVERY_SURCHARGE];for(let{cartGroup:c,entries:p}of t.cartGroupEntries??[]){let m=c?.groupId,_={itemCountInGroup:0,itemsPriceAdjusted:0,itemOutOfStock:0,itemNoPrice:0,itemExvatPriceError:0,itemMaxOrderQuantityExceeded:0,outOfStockFound:!1,noPriceFound:!1,exvatPriceErrorFound:!1,bdPriceChangedFound:!1,maxOrderQuantityExceededFound:!1,typesOfStatusFound:0};for(let y of p??[])if(!(!y.product?.groupId||y.hide||y.product.groupId!==m||y.product.productType&&a.includes(y.product.productType))){_.itemCountInGroup+=1;for(let E of o)if(E.entry?.entryNumber===y.entryNumber)switch(E.statusCode){case mt.NO_STOCK:case mt.BD_NO_STOCK:_.typesOfStatusFound+=_.outOfStockFound?0:1,_.outOfStockFound=!0,_.itemOutOfStock+=1;break;case mt.NO_PRICE:case mt.BD_NO_PRICE:_.typesOfStatusFound+=_.noPriceFound?0:1,_.noPriceFound=!0,_.itemNoPrice+=1;break;case mt.TAX_PRICE_ERROR:_.typesOfStatusFound+=_.exvatPriceErrorFound?0:1,_.exvatPriceErrorFound=!0,_.itemExvatPriceError+=1;break;case mt.BD_PRICE_CHANGED:_.typesOfStatusFound+=_.bdPriceChangedFound?0:1,_.bdPriceChangedFound=!0,_.postalCode=E.postalCode??"",_.address=E.address,_.itemsPriceAdjusted+=1;break;case mt.MAX_ORDER_QUANTITY_NOT_RESPECTED:_.typesOfStatusFound+=_.maxOrderQuantityExceededFound?0:1,_.maxOrderQuantityExceededFound=!0,_.itemMaxOrderQuantityExceeded+=1;break}}n.set(m,_)}}let s=Ja(t);this.checkoutService.setValidationData({modifications:o,cartGroupValidationErrors:n,hasRestrictedForDelivery:s})})}validateIdentity(){return J(this,null,function*(){try{yield pe(this.activeCartService.verifyIdentity())}catch{this.globalMessageService.addMessage({key:"checkout.identity.verification.expired"},je.MSG_TYPE_ERROR)}})}_shouldRedirectToCart(){return J(this,null,function*(){return(yield pe(this.siteConfigService.getBooleanConfig(Wm)))||this.router.getCurrentNavigation()?.previousNavigation?.initialUrl.toString().includes("login")})}};e.\u0275fac=function(n){return new(n||e)},e.\u0275prov=I({token:e,factory:e.\u0275fac,providedIn:"root"});let i=e;return i})();var p0=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({imports:[G.forChild([{path:"",canActivate:[De],children:[{path:"",canActivate:[oe,ui,ra],loadChildren:()=>import("./chunk-F43MOR77.js").then(t=>t.SipSplitAddressPageModule),data:{cxRoute:"splitAddress"}}]}])]});let i=e;return i})();var l0=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275cmp=F({type:e,selectors:[["sip-cart-empty"]],decls:3,vars:3,consts:[[1,"empty-cart"]],template:function(n,o){n&1&&(S(0,"div",0),H(1),w(2,"cxTranslate"),b()),n&2&&(d(),le(" ",T(2,1,"cart.page.empty"),` 39`))},dependencies:[xt],encapsulation:2,changeDetection:0});let i=e;return i})();var d0=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({providers:[M({cmsComponents:{EmptyCartParagraphComponent:{component:l0,skeletonComponent:Wf}}})],imports:[$,ht,pt]});let i=e;return i})();var mr=(()=>{let e=class e{constructor(t,n,o,s,a,c,p,m){this.productListingService=t,this.productSearchService=n,this.routingService=o,this.cmsService=s,this.cmsPageGuard=a,this.tireService=c,this.uriRedirectFilterGuard=p,this.redirectService=m}getCorrectPath(t,n){return this.redirectService.getCorrectPath(t.category,n)}canActivate(t,n){return J(this,null,function*(){let o=yield this.uriRedirectFilterGuard.canActivate(t,n).pipe(z(1)).toPromise();if(o){if(o instanceof kt)return o}else return!1;this.tireService.setTireCategoryOrTextSearchUrlInCookie();let a=this.productListingService.searchByRoute(t)?this.productSearchService.getResults().pipe(eo(1),z(1)).toPromise():Promise.resolve({});if(yield this.cmsPageGuard.canActivate(t,n).pipe(z(1)).toPromise(),(yield this.cmsService.getNextPage().pipe(z(1)).toPromise()).pageId===Lo.NOT_FOUND_PAGE)return this.routingService.pushContinueShoppingUrl("/"),!0;let p=yield a,m=p.keywordRedirectUrl;if(m)return this.productSearchService.clearResults(),this.redirectService.handleRedirect(m,{},301);if(p.categoryLandingPage){let y=this.getCorrectPath(p,t);return y?this.redirectService.handleRedirect(y.toString(),{},301):!0}if(p.parentCategoryRedirectUrl)return this.productSearchService.clearResults(),this.redirectService.handleRedirect(p.parentCategoryRedirectUrl,{},301);let _=t.queryParams.text||t.queryParams.query||t.queryParams.q;if(t.data.cxRoute==="search"&&!_||!p.pagination?.totalResults&&!p.tireSearch)this.routingService.pushContinueShoppingUrl("/"),setTimeout(()=>J(this,null,function*(){yield this.routingService.pushNewPageContext({id:dt.NO_RESULT_PAGE,type:Ue.CONTENT_PAGE,code:p.category?.code})}));else{let y=this.getCorrectPath(p,t);if(y)return this.redirectService.handleRedirect(y.toString(),{},301)}return this.routingService.pushContinueShoppingUrl(n.url),!0})}};e.\u0275fac=function(n){return new(n||e)(u(_i),u(Bi),u(lt),u(xe),u(Li),u(Hi),u(or),u(it))},e.\u0275prov=I({token:e,factory:e.\u0275fac,providedIn:"root"});let i=e;return i})();function oa(i,e,r){let t=r.data.cxSuffixUrlMatcher,{marker:n,paramName:o}=t,s=t.precedingParamName||"param",a=Yx(i,({path:_})=>_===n),c=a===i.length-1;if(a===-1||c)return null;let p=a+1,m={[o]:i[p]};for(let _=0;_<a;_++)m[`${s}${_}`]=i[_];return{consumed:i.slice(0,p+1),posParams:m}}function Yx(i,e){for(let r=i.length-1;r>=0;r--)if(e(i[r]))return r;return-1}var m0=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({imports:[G.forChild([{path:"",children:[{path:null,canActivate:[mr],runGuardsAndResolvers:"always",loadChildren:()=>import("./chunk-QHZ2TUU3.js").then(t=>
39t.SipProductListingPageModule),data:{cxRoute:"category"}},{path:null,canActivate:[mr],runGuardsAndResolvers:"always",loadChildren:()=>import("./chunk-QHZ2TUU3.js").then(t=>t.SipProductListingPageModule),data:{pageLabel:"search",cxRoute:"search"}},{path:null,canActivate:[mr],runGuardsAndResolvers:"always",loadChildren:()=>import("./chunk-QHZ2TUU3.js").then(t=>t.SipProductListingPageModule),data:{pageLabel:"search",cxRoute:"tireSearchResults"}},{path:null,canActivate:[mr],runGuardsAndResolvers:"always",loadChildren:()=>import("./chunk-QHZ2TUU3.js").then(t=>t.SipProductListingPageModule),data:{pageLabel:"search",cxRoute:"batteriesSearchResults"}},{matcher:oa,canActivate:[mr],runGuardsAndResolvers:"always",loadChildren:()=>import("./chunk-QHZ2TUU3.js").then(t=>t.SipProductListingPageModule),data:{cxSuffixUrlMatcher:{marker:"c",paramName:"categoryCode"}}}]}])]});let i=e;return i})();var qc=(()=>{let e=class e{constructor(t,n,o,s,a,c,p,m,_){this.productService=t,this.routingService=n,this.router=o,this.cmsService=s,this.cmsPageGuard=a,this.uriRedirectFilterGuard=c,this.redirectService=p,this.evTransactionService=m,this.req=_}canActivate(t,n){return J(this,null,function*(){let o=yield this.uriRedirectFilterGuard.canActivate(t,n).pipe(z(1)).toPromise();if(o){if(o instanceof kt)return o}else return!1;let s=t.queryParams[e.EV_TX_ID_PARAM];s&&this.evTransactionService.setCurrentTransactionId(s);let a=t.params[e.PRODUCT_CODE_PARAM],c=this.productService.get(a,"details").pipe(j(_=>!!_),z(1)).toPromise();yield this.cmsPageGuard.canActivate(t,n).pipe(z(1)).toPromise();let p=yield this.cmsService.getNextPage().pipe(z(1)).toPromise(),m=yield c;if(m?.error)return this.handleProductResolutionError(a,"Cannot fetch from API");if(p.pageId===dt.NOT_FOUND_PAGE&&!m?.categories)return!0;if(!m?.code)return this.handleProductResolutionError(a,"No product code");try{return this.doValidation(m,t)}catch(_){return this.handleProductResolutionError(a,_.message)}})}doValidation(t,n){if(t.url)return this.doValidationUrl(t,n);let o=t.categories;if(!t.membership){if(Yu(o))return this.handleProductResolutionError(t.code,"No parent category");let s=o[0];return s.url?this.redirectService.handleRedirect(s.url,{},301):this.handleProductResolutionError(t.code,"First category does not have URL")}return!0}doValidationUrl(t,n){let o=this.redirectService.getCorrectPath(t,n);if(o)return this.redirectService.handleRedirect(o.toString(),{},301);if(t.isExternalVendorVariantProduct)if(t.externalVendorTransactionId){if(n.queryParams.evTxId===t.externalVendorTransactionId){n.queryParams.evTxId&&this.evTransactionService.setCurrentTransactionId(n.queryParams.evTxId);let s=this.router.parseUrl(t.url);return s.queryParams=R({},n.queryParams),delete s.queryParams[e.EV_TX_ID_PARAM],s.fragment=n.fragment,s}}else return this.router.parseUrl(`/p/${t.baseProduct}`);return!0}handleProductResolutionError(t,n="Unknown"){return setTimeout(()=>J(this,null,function*(){if(this.req)throw new Error(`Product unresolved. Code: ${t}, Reason: ${n}.`);yield this.routingService.pushNewPageContext({id:dt.NOT_FOUND_PAGE,type:Ue.CONTENT_PAGE})})),!0}};e.PRODUCT_CODE_PARAM="productCode",e.EV_TX_ID_PARAM="evTxId",e.\u0275fac=function(n){return new(n||e)(u(Ui),u(lt),u(re),u(xe),u(Li),u(or),u(it),u(Mm),u(Un,8))},e.\u0275prov=I({token:e,factory:e.\u0275fac,providedIn:"root"});let i=e;return i})();var f0=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({imports:[G.forChild([{path:"",canActivate:[De],children:[{path:null,canActivate:[qc],runGuardsAndResolvers:"paramsOrQueryParamsChange",loadChildren:()=>import("./chunk-EB366XLX.js").then(t=>t.SipProductDetailsPageModule),data:{cxRoute:"product"}},{matcher:oa,canActivate:[qc],runGuardsAndResolvers:"paramsOrQueryParamsChange",loadChildren:()=>import("./chunk-EB366XLX.js").then(t=>t.SipProductDetailsPageModule),data:{cxSuffixUrlMatcher:{marker:"p",paramName:"productCode"}}}]}])]});let i=e;return i})();var h0=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({providers:[no([hs]),M({featureModules:{productCarousel:{cmsComponents:["ProductCarouselComponent","CostcoTopSellerCarouselComponent","ProductReferencesComponent","RecentlyViewedCarouselComponent"]}}})]});let i=e;return i})();var g0=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({imports:[h0]});let i=e;return i})();var _0=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({providers:[no([hs]),M({featureModules:{responsiveCarousel:{cmsComponents:["ResponsiveCarouselComponent"]}}})]});let i=e;return i})();
39var C0=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({providers:[M({featureModules:{responsiveCarousel:{module:()=>import("./chunk-BFTZQ4PK.js").then(t=>t.ResponsiveCarouselModule)}}})],imports:[_0]});let i=e;return i})();var y0=(()=>{let e=class e{constructor(t,n,o,s){this.component=t,this.renderer=n,this.elementRef=o,this.http=s}ngOnInit(){this.component.data$.pipe(A(t=>t.page?.endsWith(".jsp")?Sn:this.http.get(t.page,{responseType:"text"}).pipe(Ot(n=>{let o=this.renderer.createElement("div");o.innerHTML=n,o.querySelectorAll("script").forEach(a=>{let c=this.renderer.createElement("script");a.src?c.src=a.src:a.innerHTML&&c.append(a.innerHTML),this.renderer.appendChild(this.elementRef.nativeElement,c)})}))),z(1)).subscribe()}};e.\u0275fac=function(n){return new(n||e)(O(ee),O(bn),O(wt),O(We))},e.\u0275cmp=F({type:e,selectors:[["sip-jsp-include"]],decls:0,vars:0,template:function(n,o){},encapsulation:2,changeDetection:0});let i=e;return i})();var v0=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({providers:[M({cmsComponents:{JspIncludeComponent:{component:y0,disableSSR:!0}}})],imports:[$,Ae]});let i=e;return i})();var S0=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({providers:[M({featureModules:{consentSection:{cmsComponents:["CostcoSipConsentSectionComponent"]}}})]});let i=e;return i})();var b0=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({providers:[M({featureModules:{consentSection:{module:()=>import("./chunk-CIR37WOW.js").then(t=>t.SipConsentSectionModule)}}})],imports:[S0]});let i=e;return i})();var x0=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({providers:[M({featureModules:{consentParagraph:{cmsComponents:["CostcoSipConsentParagraphComponent"]}}})]});let i=e;return i})();var P0=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({providers:[M({featureModules:{consentParagraph:{module:()=>import("./chunk-SE4A437O.js").then(t=>t.SipConsentParagraphModule)}}})],imports:[x0]});let i=e;return i})();var sa=(()=>{let e=class e{constructor(){this.notAuthGuard=L(Vl),this.routingService=L(lt),this.siteService=L(be),this.cmsService=L(xe),this.cmsPageGuardService=L(Gd),this.windowRef=L(K),this.router=L(re)}registrationCanActivate(t,n,o){return this.windowRef.isBrowser()?this.notAuthGuard.canActivate().pipe(A(s=>!s||s instanceof kt?D(this.router.parseUrl(ef)):this.siteService.getSiteUid().pipe(A(a=>{let c={id:`${a}${o}`,type:Ue.CONTENT_PAGE};return this.routingService.changeNextPageContext(c),this.cmsService.getPage(c).pipe(A(p=>this.cmsPageGuardService.canActivatePage(c,p,t,n)))})))):!1}};e.\u0275fac=function(n){return new(n||e)},e.\u0275prov=I({token:e,factory:e.\u0275fac});let i=e;return i})();var M0=(()=>{let e=class e extends sa{canActivate(t,n){return super.registrationCanActivate(t,n,$o.PAGE_ID_SUFFIX_ONLINE)}};e.\u0275fac=(()=>{let t;return function(o){return(t||(t=Le(e)))(o||e)}})(),e.\u0275prov=I({token:e,factory:e.\u0275fac,providedIn:"root"});let i=e;return i})();var E0=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({imports:[G.forChild([{path:"",canActivate:[De],children:[{path:null,canActivate:[M0],runGuardsAndResolvers:"paramsOrQueryParamsChange",loadChildren:()=>import("./chunk-CMFYTLWK.js").then(t=>t.SipOnlineRegisterPageModule),data:{cxRoute:"onlineRegistration"}},{path:null,canActivate:[oe],loadChildren:()=>import("./chunk-2HO4MW3H.js").then(t=>t.SipOnlineRegisterConfirmationPageModule),data:{pageLabel:"registrationconfirmation",cxRoute:"onlineRegistrationConfirmation"}}]}])]});let i=e;return i})();var I0=(()=>{let e=class e extends sa{constructor(t,n){super(),this.activeCartFacade=t,this.globalMessageService=n}canActivate(t,n){let o=super.registrationCanActivate(t,n,$o.PAGE_ID_SUFFIX);return(o instanceof Pp?o:D(o)).pipe(A(s=>!s||s instanceof kt?D(s):ae([this.activeCartFacade.getActiveCartId(),this.activeCartFacade.getActive()]).pipe(j(([a,c])=>a===c.guid||!a),A(()=>this.activeCartFacade.hasMembershipProductInCart().pipe(A(a=>a?Ep(this.router.navigateByUrl(tt.CART).finally(()=>{this.globalMessageService.addMessage({key:"basket.information.quantity.noItemsAdded.membershipMaxOrderQuantityExceeded"},je.MSG_TYPE_ERROR)})):D(!0)))))))}};e.\u0275fac=function(n){return new(n||e)(u(Qt),u(Nt))},e.\u0275prov=I({token:e,factory:e.\u0275fac,providedIn:"root"});let i=e;return i})();var O0=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({imports:[G.forChild([{path:"",canActivate:[De],children:[{path:null,canActivate:[I0],runGuardsAndResolvers:"paramsOrQueryParamsChange",loadChildren:()=>import("./chunk-6JON5IT4.js").then(t=>
39t.SipRegistrationPageModule),data:{cxRoute:"membershipRegistration"}}]}])]});let i=e;return i})();var w0=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({imports:[G.forChild([{path:"",canActivate:[De],children:[{path:null,loadChildren:()=>import("./chunk-X6UGRUD3.js").then(t=>t.SipExternalReturnPageModule),data:{cxRoute:"externalReturn"}}]}])]});let i=e;return i})();var T0=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({imports:[G.forChild([{path:"",canActivate:[De],children:[{path:null,canActivate:[oe],loadChildren:()=>import("./chunk-G63V4PE6.js").then(t=>t.SipCompareProductsPageModule),data:{cxRoute:"compareProducts",pageLabel:"compare-products"}}]}])]});let i=e;return i})();var k0=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({imports:[G.forChild([{path:"",children:[{path:null,canActivate:[oe],loadChildren:()=>import("./chunk-PTNIY4TP.js").then(t=>t.SipShopCardPageModule),data:{pageLabel:"cashcard",cxRoute:"shopCard"}}]}])]});let i=e;return i})();var R0=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({imports:[G.forChild([{path:"",canActivate:[ra],children:[{path:null,loadChildren:()=>import("./chunk-LFK6D6JW.js").then(t=>t.SipCheckoutPageModule),data:{pageLabel:"checkout",cxRoute:"checkout"}}]}])]});let i=e;return i})();var A0=(()=>{let e=class e{constructor(t,n,o,s,a){this.authGuard=t,this.redirectService=n,this.cmsPageGuard=o,this.winRef=s,this.abstractLoggerFactory=a,this.logger=this.abstractLoggerFactory.getLogger("SipLoginPageGuard")}canActivate(t,n){let o=this.redirectService.handleRedirect("/");return this.authGuard.canActivate().pipe(A(s=>!s||s instanceof kt?this.cmsPageGuard.canActivate(t,n):D(o)),Ge(s=>(this.logger.error("Caught error: ",s),D(o))))}};e.\u0275fac=function(n){return new(n||e)(u(ui),u(it),u(oe),u(K),u(et))},e.\u0275prov=I({token:e,factory:e.\u0275fac,providedIn:"root"});let i=e;return i})();var N0=(()=>{let e=class e{constructor(t,n){this.cmsPageGuard=t,this.router=n}canActivate(t,n){let o=t.queryParamMap.get("token");return!o||o.trim()===""?(this.router.navigateByUrl("/"),D(!1)):this.cmsPageGuard.canActivate(t,n)}};e.\u0275fac=function(n){return new(n||e)(u(oe),u(re))},e.\u0275prov=I({token:e,factory:e.\u0275fac,providedIn:"root"});let i=e;return i})();var D0=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({imports:[G.forChild([{path:"",canActivate:[De],children:[{path:null,canActivate:[A0],loadChildren:()=>import("./chunk-GHJSSFIJ.js").then(t=>t.SipLoginPageModule),data:{pageLabel:"login",cxRoute:"login"}},{path:null,canActivate:[oe],loadChildren:()=>import("./chunk-AFZ4GUL7.js").then(t=>t.SipForgotPasswordPageModule),data:{pageLabel:"forgot-pwd",cxRoute:"forgotPassword"}},{path:null,canActivate:[oe],loadChildren:()=>import("./chunk-TL23MZMI.js").then(t=>t.SipFindLoginIdPageModule),data:{pageLabel:"find-login-id",cxRoute:"findLoginId"}},{path:null,canActivate:[N0],loadChildren:()=>import("./chunk-2WIWH4D5.js").then(t=>t.SipResetPasswordPageModule),data:{pageLabel:"updatePassword",cxRoute:"resetPassword"}}]}])]});let i=e;return i})();var F0=(()=>{let e=class e{constructor(t,n,o,s,a,c,p){this.authGuard=t,this.cmsPageGuard=n,this.featureModules=o,this.router=s,this.windowRef=a,this.userService=c,this.checkoutVersionGuard=p}canActivate(t,n){return J(this,null,function*(){let o=this.router.getCurrentNavigation()?.extras?.state;if(!this.windowRef.isBrowser())return!1;let s=yield this.checkoutVersionGuard.canActivate(t,n);if(s!==!0)return s;yield pe(this.featureModules.resolveFeature(vi));let a=yield pe(this.userService.isAnonymousUser());if(o?.order&&a)return pe(this.cmsPageGuard.canActivate(t,n));let c=yield pe(this.authGuard.canActivate());return c===!0?pe(this.cmsPageGuard.canActivate(t,n)):c})}};e.\u0275fac=function(n){return new(n||e)(u(ui),u(oe),u(hi),u(re),u(K),u(Ci),u(na))},e.\u0275prov=I({token:e,factory:e.\u0275fac,providedIn:"root"});let i=e;return i})();var L0=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({imports:[G.forChild([{path:"",children:[{path:"",canActivate:[F0],loadChildren:()=>import("./chunk-S4TVX2YI.js").then(t=>t.SipCheckoutOrderConfirmationPageModule),data:{pageLabel:"orderConfirmation",cxRoute:"orderConfirmation"}}]}])]});let i=e;return i})();var j0=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({imports:[G.forChild([{path:"",children:[{path:"",canActivate:[oe],loadChildren:()=>import("./chunk-TMQ3V2XY.js").then(t=>t.SipCreditCardConfirmationPageModule),data:{pageLabel:"creditCardApprovalConfirmation",cxRoute:"creditCardApprovalConfirmation"}}]}])]});let i=e;return i})();var $0=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({imports:[G.forChild([{path:"",canActivate:[De],children:[{path:null,runGuardsAndResolvers:"paramsOrQueryParamsChange",canActivate:[oe,ia],loadChildren:()=>import("./chunk-TYC2ZP3A.js").then(t=>t.SipTrackingDetailsPageModule),data:{pageLabel:"trackingdetails",cxRoute:"trackingDetails"}}]}])]});let i=e;return i})();var B0=(()=>{let e=class e{static forRoot(){return{ngModule:e,providers:[{provide:Do,useExisting:Zg},{provide:kn,useExisting:xe}]}}};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({providers:[{provide:No,useExisting:jn}],imports:[Lg,Vg,Kg,qi,Ya,Hs,df,Cf,kg,Dg,C0,Rg,v0,Fg,sf,Ws,yf,Js,dr,Bg,Xs,Za,g0,Yg,Xg,o0,s0,a0,p0,D0,d0,qf,m0,Jg,f0,b0,P0,E0,O0,w0,T0,k0,R0,L0,j0,$0,Pg,G.forChild([{path:"**",canActivate:[oe],component:gi}]),uf,ih,ff,Ya,bf,Za]});let i=e;return i})();var U0=(()=>{let e=class e{constructor(t){this.docRef=t}injectStyle(t,n){let o=this.docRef.querySelector(`link[href="${t}"]`);if(!o){let s=this.docRef.createElement("link");s.rel="preload",s.setAttribute("as","style"),s.href=t,this.docRef.getElementsByTagName("head")[0].appendChild(s);let a=this.docRef.createElement("link");return a.rel="stylesheet",a.type="text/css",a.href=t,n?.element?n.element.insertAdjacentElement(n.insert,a):this.docRef.getElementsByTagName("head")[0].appendChild(a),a}return o}injectSharedStyles(){let t=this.injectStyle("/mediapermalink/costco.css"),n=se.production||se.useRemoteSharedStyles?`/wro/costco_responsive_spa.css?v=${se.appVersion}`:`/_ui/responsive/theme-costco/css/spa-style.css?v=${se.appVersion}`;this.injectStyle(n,{insert:"beforebegin",element:t})}};e.\u0275fac=function(n){return new(n||e)(u(bt))},e.\u0275prov=I({token:e,factory:e.\u0275fac,providedIn:"root"});let i=e;return i})();function z0(i){return()=>{i.injectSharedStyles()}}var G0=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({providers:[{provide:Xe,useFactory:z0,deps:[U0],multi:!0}],imports:[$]});let i=e;return i})();var H0=(()=>{let e=class e extends Po{initSync(){}};e.\u0275fac=(()=>{let t;return function(o){return(t||(t=Le(e)))(o||e)}})(),e.\u0275prov=I({token:e,factory:e.\u0275fac,providedIn:"root"});let i=e;return i})();var V0=(()=>{let e=class e extends Mo{constructor(){super(...arguments),this.siteService=L(be)}loadClientAuthenticationToken(){return this.siteService.getSiteUid().pipe(A(t=>{let n=this.authConfigService.getTokenEndpoint(),o=new Mr().set("client_id",encodeURIComponent(this.authConfigService.getClientId())).set("client_secret",encodeURIComponent(this.authConfigService.getClientSecret())).set("grant_type","client_credentials").set("siteUid",t),s=new an({"Content-Type":"application/x-www-form-urlencoded"});return this.http.post(n,o,{headers:s})}))}};e.\u0275fac=(()=>{let t;return function(o){return(t||(t=Le(e)))(o||e)}})(),e.\u0275prov=I({token:e,factory:e.\u0275fac,providedIn:"root"});let i=e;return i})();var aa=(()=>{let e=class e extends zu{constructor(){super(...arguments),this.searchServiceUtils=L(Hn)}isOccUrl(t){let n=this.occEndpoints.getBaseUrl(),o=this.searchServiceUtils.getSearchServiceBaseUrl();if(!n)return!1;let s=n,a=n.replace("/v2","/v3");return t.includes(s)||t.includes(a)||t.includes(o)}};e.\u0275fac=(()=>{let t;return function(o){return(t||(t=Le(e)))(o||e)}})(),e.\u0275prov=I({token:e,factory:e.\u0275fac,providedIn:"root"});let i=e;return i})();var q0=(()=>
39{let e=class e extends Eo{constructor(t,n){super(t,n),this.authHttpHeaderService=t,this.authConfigService=n}intercept(t,n){return super.intercept(t,n)}};e.\u0275fac=function(n){return new(n||e)(u(aa),u(Al))},e.\u0275prov=I({token:e,factory:e.\u0275fac,providedIn:"root"});let i=e;return i})();function Xx(i,e,r,t){return{scopes:["jsession"],configFactory:()=>J(this,null,function*(){return pi(t)?{}:(yield Promise.all([i.getStable("currentsite").toPromise(),e.init(),e.authUsingJSESSION()]),(yield e.isUserLoggedIn().pipe(z(1)).toPromise())&&r.loadPreferences(),{})})}}var W0=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({providers:[{provide:Gl,useExisting:aa},{provide:Eo,useExisting:q0},{provide:Co,useExisting:Gn},{provide:Po,useExisting:H0},{provide:Di,useExisting:za},{provide:Mo,useExisting:V0},{provide:Tn,useFactory:Xx,multi:!0,deps:[qt,za,Nd,Ne]}],imports:[$,lh]});let i=e;return i})();var K0=(()=>{let e=class e{constructor(t,n,o){this.actions$=t,this.cartConnector=n,this.globalMessageService=o,this.reloadCartInStorefront$=jt(()=>this.actions$.pipe($t(Ha.CREATE_CART_SUCCESS),x(s=>s.payload),Ot(()=>{this.cartConnector.reloadCartInStorefront().toPromise()})),{dispatch:!1}),this.removeItemGlobalMessage$=jt(()=>this.actions$.pipe($t(Ha.CART_REMOVE_ENTRY_SUCCESS),x(s=>s.payload),Ot(()=>{this.globalMessageService.addMessage({key:"basket.page.message.remove"},je.MSG_TYPE_CONFIRMATION)})),{dispatch:!1})}};e.\u0275fac=function(n){return new(n||e)(u(Ni),u(Jo),u(Nt))},e.\u0275prov=I({token:e,factory:e.\u0275fac});let i=e;return i})();var Y0=(()=>{let e=class e{constructor(t,n,o,s){this.cookiesService=t,this.winRef=n,this.siteService=o,this.userService=s,this.CART="cart"}persistCartGuidFromCookie(){return ae([this.siteService.getSiteUid().pipe(j(Boolean)),this.userService.isAnonymousUser()]).pipe(x(([t,n])=>{let o=this.winRef.localStorage;if(!o)return;let s=`spartacus\u26BF${[].concat(t)}\u26BF${this.CART}`,a=`${t}-${this.CART}`,c=n?this.cookiesService.get(a):null;c?.length?o.setItem(s,Wt({active:c})):o.removeItem(s)}),z(1)).toPromise()}};e.\u0275fac=function(n){return new(n||e)(u($n),u(K),u(be),u(Ci))},e.\u0275prov=I({token:e,factory:e.\u0275fac,providedIn:"root"});let i=e;return i})();var Z0=(()=>{let e=class e{constructor(t,n,o,s,a,c,p){this.windowRef=t,this.userIdService=n,this.sessionStorageService=o,this.saveForLaterAdapter=s,this.cartMessagesService=a,this.featureModules=c,this.location=p}processSaveForLater(){return J(this,null,function*(){if(this.windowRef.isBrowser()&&Yo.isCartPage(this.location.path())){yield this.featureModules.resolveFeature("saveForLater").pipe(z(1)).toPromise();let t=this.sessionStorageService.retrieve(Va);if(t!=null){let n=yield this.userIdService.getUserId().pipe(z(1)).toPromise();if(n!==Jt){let o=yield this.saveForLaterAdapter.addSaveForLaterEntry(n,_o,t.toString()).toPromise();this.cartMessagesService.dispatchSaveForLaterMessage(o)}this.sessionStorageService.clear(Va)}}})}};e.\u0275fac=function(n){return new(n||e)(u(K),u(Co),u(Mu),u(wf),u(Xo),u(hi),u(mo))},e.\u0275prov=I({token:e,factory:e.\u0275fac,providedIn:"root"});let i=e;return i})();var X0=(()=>{let e=class e extends Qo{constructor(t,n,o,s,a){super(t,n,o),this.cartCookieService=s,this.cartPreparationService=a}initSync(){this.cartCookieService.persistCartGuidFromCookie().then(()=>this.cartPreparationService.processSaveForLater()).then(()=>{super.initSync()})}};e.\u0275fac=function(n){return new(n||e)(u(wn),u(Mn),u(wo),u(Y0),u(Z0))},e.\u0275prov=I({token:e,factory:e.\u0275fac,providedIn:"root"});let i=e;return i})();var J0=(()=>{let e=class e{static forRoot(){return{ngModule:e,providers:[M({featureModules:{[ln]:{module:()=>import("./chunk-S2BQWOXN.js").then(t=>t.CartBaseCoreModule)}}}),{provide:Qo,useExisting:X0},{provide:Ko,useExisting:Qt},{provide:ou,useExisting:cu},{provide:ru,useExisting:Jo},{provide:nu,useExisting:pu},{provide:su,useExisting:Tf}]}}};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({imports:[di.forFeature([K0])]});let i=e;return i})();var e_=(()=>{let e=class e extends To{parse(t){let n=t.replace(/\(/g,"%28").replace(/\)/g,"%29");return super.parse(n)}};e.\u0275fac=(()=>{let t;return function(o){return(t||(t=Le(e)))(o||e)}})(),e.\u0275prov=I({token:e,factory:e.\u0275fac,providedIn:"root"});let i=e;return i})();var t_=(()=>{let e=class e{constructor(t){this.cookiesService=t}
39getContextSegment(){let t=this.cookiesService.get("context_segment");if(t&&t.length){if(!t.includes("|"))try{t=Sm(t)}catch{}return t.split("|")}return null}getLang(){let t=this.getContextSegment();return t?.length?t[0]:null}};e.\u0275fac=function(n){return new(n||e)(u($n))},e.\u0275prov=I({token:e,factory:e.\u0275fac,providedIn:"root"});let i=e;return i})();var i_=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({providers:[{provide:Xe,useFactory:t1,deps:[t_,fi,qt,K],multi:!0},{provide:To,useExisting:e_}]});let i=e;return i})();function t1(i,e,r,t){return()=>J(this,null,function*(){if(!t.isBrowser())return;yield r.getStable("context");let n=i.getLang(),o=`spartacus\u26BF\u26BF${yo}`;n&&n!=="en"?(t.localStorage.setItem(o,`"${n}"`),e.setActive(n)):t.localStorage.removeItem(o)})}var n_=new St("AuthReducers");function i1(){return{clientToken:Tl.loaderReducer(Ll)}}var n1={provide:n_,useFactory:i1};function r1(i){return(e,r)=>(r.type===Er.LOGOUT&&(e=ie(R({},e),{clientToken:void 0})),i(e,r))}var o1=[r1],r_=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({providers:[n1],imports:[En.forFeature(bo,n_,{metaReducers:o1})]});let i=e;return i})();var o_=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({imports:[$]});let i=e;return i})();var ur=class{constructor(e){this.urlRegEx=RegExp(e)}matches(e){return this.urlMatches(e)}urlMatches(e){return this.urlRegEx.test(e.url)}};var Qc=class{add(e,r,t){if(typeof arguments[0]!="string")for(let n in arguments[0])this.add(n,arguments[0][n],arguments[1]);else(Array.isArray(e)?e:[e]).forEach(function(n){this[n]=this[n]||[],r&&this[n][t?"unshift":"push"](r)},this)}run(e,r){this[e]=this[e]||[],this[e].forEach(function(t){t.call(r&&r.context?r.context:r,r)})}},Yc=class{constructor(e){this.jsep=e,this.registered={}}register(){for(var e=arguments.length,r=new Array(e),t=0;t<e;t++)r[t]=arguments[t];r.forEach(n=>{if(typeof n!="object"||!n.name||!n.init)throw new Error("Invalid JSEP plugin format");this.registered[n.name]||(n.init(this.jsep),this.registered[n.name]=n)})}},Ft=class i{static get version(){return"1.4.0"}static toString(){return"JavaScript Expression Parser (JSEP) v"+i.version}static addUnaryOp(e){return i.max_unop_len=Math.max(e.length,i.max_unop_len),i.unary_ops[e]=1,i}static addBinaryOp(e,r,t){return i.max_binop_len=Math.max(e.length,i.max_binop_len),i.binary_ops[e]=r,t?i.right_associative.add(e):i.right_associative.delete(e),i}static addIdentifierChar(e){return i.additional_identifier_chars.add(e),i}static addLiteral(e,r){return i.literals[e]=r,i}static removeUnaryOp(e){return delete i.unary_ops[e],e.length===i.max_unop_len&&(i.max_unop_len=i.getMaxKeyLen(i.unary_ops)),i}static removeAllUnaryOps(){return i.unary_ops={},i.max_unop_len=0,i}static removeIdentifierChar(e){return i.additional_identifier_chars.delete(e),i}static removeBinaryOp(e){return delete i.binary_ops[e],e.length===i.max_binop_len&&(i.max_binop_len=i.getMaxKeyLen(i.binary_ops)),i.right_associative.delete(e),i}static removeAllBinaryOps(){return i.binary_ops={},i.max_binop_len=0,i}static removeLiteral(e){return delete i.literals[e],i}static removeAllLiterals(){return i.literals={},i}get char(){return this.expr.charAt(this.index)}get code(){return this.expr.charCodeAt(this.index)}constructor(e){this.expr=e,this.index=0}static parse(e){return new i(e).parse()}static getMaxKeyLen(e){return Math.max(0,...Object.keys(e).map(r=>r.length))}static isDecimalDigit(e){return e>=48&&e<=57}static binaryPrecedence(e){return i.binary_ops[e]||0}static isIdentifierStart(e){return e>=65&&e<=90||e>=97&&e<=122||e>=128&&!i.binary_ops[String.fromCharCode(e)]||i.additional_identifier_chars.has(String.fromCharCode(e))}static isIdentifierPart(e){return i.isIdentifierStart(e)||i.isDecimalDigit(e)}throwError(e){let r=new Error(e+" at character "+this.index);throw r.index=this.index,r.description=e,r}runHook(e,r){if(i.hooks[e]){let t={context:this,node:r};return i.hooks.run(e,t),t.node}return r}searchHook(e){if(i.hooks[e]){let r={context:this};return i.hooks[e].find(function(t){return t.call(r.context,r),r.node}
vendor: 7,438 bytes, lines 39-40
39),r.node}}gobbleSpaces(){let e=this.code;for(;e===i.SPACE_CODE||e===i.TAB_CODE||e===i.LF_CODE||e===i.CR_CODE;)e=this.expr.charCodeAt(++this.index);this.runHook("gobble-spaces")}parse(){this.runHook("before-all");let e=this.gobbleExpressions(),r=e.length===1?e[0]:{type:i.COMPOUND,body:e};return this.runHook("after-all",r)}gobbleExpressions(e){let r=[],t,n;for(;this.index<this.expr.length;)if(t=this.code,t===i.SEMCOL_CODE||t===i.COMMA_CODE)this.index++;else if(n=this.gobbleExpression())r.push(n);else if(this.index<this.expr.length){if(t===e)break;this.throwError('Unexpected "'+this.char+'"')}return r}gobbleExpression(){let e=this.searchHook("gobble-expression")||this.gobbleBinaryExpression();return this.gobbleSpaces(),this.runHook("after-expression",e)}gobbleBinaryOp(){this.gobbleSpaces();let e=this.expr.substr(this.index,i.max_binop_len),r=e.length;for(;r>0;){if(i.binary_ops.hasOwnProperty(e)&&(!i.isIdentifierStart(this.code)||this.index+e.length<this.expr.length&&!i.isIdentifierPart(this.expr.charCodeAt(this.index+e.length))))return this.index+=r,e;e=e.substr(0,--r)}return!1}gobbleBinaryExpression(){let e,r,t,n,o,s,a,c,p;if(s=this.gobbleToken(),!s||(r=this.gobbleBinaryOp(),!r))return s;for(o={value:r,prec:i.binaryPrecedence(r),right_a:i.right_associative.has(r)},a=this.gobbleToken(),a||this.throwError("Expected expression after "+r),n=[s,o,a];r=this.gobbleBinaryOp();){if(t=i.binaryPrecedence(r),t===0){this.index-=r.length;break}o={value:r,prec:t,right_a:i.right_associative.has(r)},p=r;let m=_=>o.right_a&&_.right_a?t>_.prec:t<=_.prec;for(;n.length>2&&m(n[n.length-2]);)a=n.pop(),r=n.pop().value,s=n.pop(),e={type:i.BINARY_EXP,operator:r,left:s,right:a},n.push(e);e=this.gobbleToken(),e||this.throwError("Expected expression after "+p),n.push(o,e)}for(c=n.length-1,e=n[c];c>1;)e={type:i.BINARY_EXP,operator:n[c-1].value,left:n[c-2],right:e},c-=2;return e}gobbleToken(){let e,r,t,n;if(this.gobbleSpaces(),n=this.searchHook("gobble-token"),n)return this.runHook("after-token",n);if(e=this.code,i.isDecimalDigit(e)||e===i.PERIOD_CODE)return this.gobbleNumericLiteral();if(e===i.SQUOTE_CODE||e===i.DQUOTE_CODE)n=this.gobbleStringLiteral();else if(e===i.OBRACK_CODE)n=this.gobbleArray();else{for(r=this.expr.substr(this.index,i.max_unop_len),t=r.length;t>0;){if(i.unary_ops.hasOwnProperty(r)&&(!i.isIdentifierStart(this.code)||this.index+r.length<this.expr.length&&!i.isIdentifierPart(this.expr.charCodeAt(this.index+r.length)))){this.index+=t;let o=this.gobbleToken();return o||this.throwError("missing unaryOp argument"),this.runHook("after-token",{type:i.UNARY_EXP,operator:r,argument:o,prefix:!0})}r=r.substr(0,--t)}i.isIdentifierStart(e)?(n=this.gobbleIdentifier(),i.literals.hasOwnProperty(n.name)?n={type:i.LITERAL,value:i.literals[n.name],raw:n.name}:n.name===i.this_str&&(n={type:i.THIS_EXP})):e===i.OPAREN_CODE&&(n=this.gobbleGroup())}return n?(n=this.gobbleTokenProperty(n),this.runHook("after-token",n)):this.runHook("after-token",!1)}gobbleTokenProperty(e){this.gobbleSpaces();let r=this.code;for(;r===i.PERIOD_CODE||r===i.OBRACK_CODE||r===i.OPAREN_CODE||r===i.QUMARK_CODE;){let t;if(r===i.QUMARK_CODE){if(this.expr.charCodeAt(this.index+1)!==i.PERIOD_CODE)break;t=!0,this.index+=2,this.gobbleSpaces(),r=this.code}this.index++,r===i.OBRACK_CODE?(e={type:i.MEMBER_EXP,computed:!0,object:e,property:this.gobbleExpression()},e.property||this.throwError('Unexpected "'+this.char+'"'),this.gobbleSpaces(),r=this.code,r!==i.CBRACK_CODE&&this.throwError("Unclosed ["),this.index++):r===i.OPAREN_CODE?e={type:i.CALL_EXP,arguments:this.gobbleArguments(i.CPAREN_CODE),callee:e}:(r===i.PERIOD_CODE||t)&&(t&&this.index--,this.gobbleSpaces(),e={type:i.MEMBER_EXP,computed:!1,object:e,property:this.gobbleIdentifier()}),t&&(e.optional=!0),this.gobbleSpaces(),r=this.code}return e}gobbleNumericLiteral(){let e="",r,t;for(;i.isDecimalDigit(this.code);)e+=this.expr.charAt(this.index++);if(this.code===i.PERIOD_CODE)for(e+=this.expr.charAt(this.index++);i.isDecimalDigit(this.code);)e+=this.expr.charAt(this.index++);if(r=this.char,r==="e"||r==="E"){for(e+=this.expr.charAt(this.index++),r=this.char,(r==="+"||r==="-")&&(e+=this.expr.charAt(this.index++));i.isDecimalDigit(this.code);)e+=this.expr.charAt(this.index++);i.isDecimalDigit(this.expr.charCodeAt(this.index-1))||this.throwError("Expected exponent ("+e+this.char+")")}return t=this.code,i.isIdentifierStart(t)?this.throwError("Variable names cannot start with a number ("+e+this.char+")"):(t===i.PERIOD_CODE||e.length===1&&e.charCodeAt(0)===i.PERIOD_CODE)&&this.throwError("Unexpected period"),{type:i.LITERAL,value:parseFloat(e),raw:e}}gobbleStringLiteral(){let e="",r=this.index,t=this.expr.charAt(this.index++),n=!1;for(;this.index<this.expr.length;){let o=this.expr.charAt(this.index++);if(o===t){n=!0;break}else if(o==="\\")switch(o=this.expr.charAt(this.index++),o){case"n":e+=` 40`;break;case"r":e+="\r";break;case"t":e+=" ";break;case"b":e+="\b";break;case"f":e+="\f";break;case"v":e+="\v";break;default:e+=o}else e+=o}return n||this.throwError('Unclosed quote after "'+e+'"'),{type:i.LITERAL,value:e,raw:this.expr.substring(r,this.index)}}gobbleIdentifier(){let e=this.code,r=this.index;for(i.isIdentifierStart(e)?this.index++:this.throwError("Unexpected "+this.char);this.index<this.expr.length&&(e=this.code,i.isIdentifierPart(e));)this.index++;return{type:i.IDENTIFIER,name:this.expr.slice(r,this.index)}}gobbleArguments(e){let r=[],t=!1,n=0;for(;this.index<this.expr.length;){this.gobbleSpaces();let o=this.code;if(o===e){t=!0,this.index++,e===i.CPAREN_CODE&&n&&n>=r.length&&this.throwError("Unexpected token "+String.fromCharCode(e));break}else if(o===i.COMMA_CODE){if(this.index++,n++,n!==r.length){if(e===i.CPAREN_CODE)this.throwError("Unexpected token ,");else if(e===i.CBRACK_CODE)for(let s=r.length;s<n;s++)r.push(null)}}else if(r.length!==n&&n!==0)this.throwError("Expected comma");else{let s=this.gobbleExpression();(!s||s.type===i.COMPOUND)&&this.throwError("Expected comma"),r.push(s)}}return t||this.throwError("Expected "+String.fromCharCode(e)),r}gobbleGroup(){this.index++;let e=this.gobbleExpressions(i.CPAREN_CODE);if(this.code===i.CPAREN_CODE)return this.index++,e.length===1?e[0]:e.length?{type:i.SEQUENCE_EXP,expressions:e}:!1;this.throwError("Unclosed (")}gobbleArray(){return this.index++,{type:i.ARRAY_EXP,elements:this.gobbleArguments(i.CBRACK_CODE)}}},s1=new Qc;Object.assign(Ft,{hooks:s1,plugins:new Yc(Ft),COMPOUND:"Compound",SEQUENCE_EXP:"SequenceExpression",IDENTIFIER:"Identifier",MEMBER_EXP:"MemberExpression",LITERAL:"Literal",THIS_EXP:"ThisExpression",CALL_EXP:"CallExpression",UNARY_EXP:"UnaryExpression",BINARY_EXP:"BinaryExpression",ARRAY_EXP:"ArrayExpression",TAB_CODE:9,LF_CODE:10,CR_CODE:13,SPACE_CODE:32,PERIOD_CODE:46,COMMA_CODE:44,SQUOTE_CODE:39,DQUOTE_CODE:34,OPAREN_CODE:40,CPAREN_CODE:41,OBRACK_CODE:91,CBRACK_CODE:93,QUMARK_CODE:63,SEMCOL_CODE:59,COLON_CODE:58,unary_ops:{"-":1,"!":1,"~":1,"+":1},binary_ops:{"||":1,"??":1,"&&":2,"|":3,"^":4,"&":5,"==":6,"!=":6,"===":6,"!==":6,"<":7,">":7,"<=":7,">=":7,"<<":8,">>":8,">>>":8,"+":9,"-":9,"*":10,"/":10,"%":10,"**":11},right_associative:new Set(["**"]),additional_identifier_chars:new Set(["$","_"]),literals:{true:!0,false:!1,null:null},this_str:"this"});Ft.max_unop_len=Ft.getMaxKeyLen(Ft.unary_ops);Ft.max_binop_len=Ft.getMaxKeyLen(Ft.binary_ops);var wi=i=>new Ft(i).parse(),a1=Object.getOwnPropertyNames(class{});Object.getOwnPropertyNames(Ft).filter(i=>
40!a1.includes(i)&&wi[i]===void 0).forEach(i=>{wi[i]=Ft[i]});wi.Jsep=Ft;var c1="ConditionalExpression",p1={name:"ternary",init(i){i.hooks.add("after-expression",function(r){if(r.node&&this.code===i.QUMARK_CODE){this.index++;let t=r.node,n=this.gobbleExpression();if(n||this.throwError("Expected expression"),this.gobbleSpaces(),this.code===i.COLON_CODE){this.index++;let o=this.gobbleExpression();if(o||this.throwError("Expected expression"),r.node={type:c1,test:t,consequent:n,alternate:o},t.operator&&i.binary_ops[t.operator]<=.9){let s=t;for(;s.right.operator&&i.binary_ops[s.right.operator]<=.9;)s=s.right;r.node.test=s.right,s.right=r.node,r.node=t}}else this.throwError("Expected :")}})}};wi.plugins.register(p1);var s_=47,l1=92,d1={name:"regex",init(i){i.hooks.add("gobble-token",function(r){if(this.code===s_){let t=++this.index,n=!1;for(;this.index<this.expr.length;){if(this.code===s_&&!n){let o=this.expr.slice(t,this.index),s="";for(;++this.index<this.expr.length;){let c=this.code;if(c>=97&&c<=122||c>=65&&c<=90||c>=48&&c<=57)s+=this.char;else break}let a;try{a=new RegExp(o,s)}catch(c){this.throwError(c.message)}return r.node={type:i.LITERAL,value:a,raw:this.expr.slice(t-1,this.index)},r.node=this.gobbleTokenProperty(r.node),r.node}this.code===i.OBRACK_CODE?n=!0:n&&this.code===i.CBRACK_CODE&&(n=!1),this.index+=this.code===l1?2:1}this.throwError("Unclosed Regex")}})}},Kc=43,m1=45,fr={name:"assignment",assignmentOperators:new Set(["=","*=","**=","/=","%=","+=","-=","<<=",">>=",">>>=","&=","^=","|=","||=","&&=","??="]),updateOperators:[Kc,m1],assignmentPrecedence:.9,init(i){let e=[i.IDENTIFIER,i.MEMBER_EXP];fr.assignmentOperators.forEach(t=>i.addBinaryOp(t,fr.assignmentPrecedence,!0)),i.hooks.add("gobble-token",function(n){let o=this.code;fr.updateOperators.some(s=>s===o&&s===this.expr.charCodeAt(this.index+1))&&(this.index+=2,n.node={type:"UpdateExpression",operator:o===Kc?"++":"--",argument:this.gobbleTokenProperty(this.gobbleIdentifier()),prefix:!0},(!n.node.argument||!e.includes(n.node.argument.type))&&this.throwError(`Unexpected ${n.node.operator}`))}),i.hooks.add("after-token",function(n){if(n.node){let o=this.code;fr.updateOperators.some(s=>s===o&&s===this.expr.charCodeAt(this.index+1))&&(e.includes(n.node.type)||this.throwError(`Unexpected ${n.node.operator}`),this.index+=2,n.node={type:"UpdateExpression",operator:o===Kc?"++":"--",argument:n.node,prefix:!1})}}),i.hooks.add("after-expression",function(n){n.node&&r(n.node)});function r(t){fr.assignmentOperators.has(t.operator)?(t.type="AssignmentExpression",r(t.left),r(t.right)):t.operator||Object.values(t).forEach(n=>{n&&typeof n=="object"&&r(n)})}}};wi.plugins.register(d1,fr);wi.addUnaryOp("typeof");wi.addLiteral("null",null);wi.addLiteral("undefined",void 0);var u1=new Set(["constructor","__proto__","__defineGetter__","__defineSetter__"]),we={evalAst(i,e){switch(i.type){case"BinaryExpression":case"LogicalExpression":return we.evalBinaryExpression(i,e);case"Compound":return we.evalCompound(i,e);case"ConditionalExpression":return we.evalConditionalExpression(i,e);case"Identifier":return we.evalIdentifier(i,e);case"Literal":return we.evalLiteral(i,e);case"MemberExpression":return we.evalMemberExpression(i,e);case"UnaryExpression":return we.evalUnaryExpression(i,e);case"ArrayExpression":return we.evalArrayExpression(i,e);case"CallExpression":return we.evalCallExpression(i,e);case"AssignmentExpression":return we.evalAssignmentExpression(i,e);default:throw SyntaxError("Unexpected expression",i)}},evalBinaryExpression(i,e){return{"||":(t,n)=>t||n(),"&&":(t,n)=>t&&n(),"|":(t,n)=>t|n(),"^":(t,n)=>t^n(),"&":(t,n)=>t&n(),"==":(t,n)=>t==n(),"!=":(t,n)=>t!=n(),"===":(t,n)=>t===n(),"!==":(t,n)=>t!==n(),"<":(t,n)=>t<n(),">
40":(t,n)=>t>n(),"<=":(t,n)=>t<=n(),">=":(t,n)=>t>=n(),"<<":(t,n)=>t<<n(),">>":(t,n)=>t>>n(),">>>":(t,n)=>t>>>n(),"+":(t,n)=>t+n(),"-":(t,n)=>t-n(),"*":(t,n)=>t*n(),"/":(t,n)=>t/n(),"%":(t,n)=>t%n()}[i.operator](we.evalAst(i.left,e),()=>we.evalAst(i.right,e))},evalCompound(i,e){let r;for(let t=0;t<i.body.length;t++){i.body[t].type==="Identifier"&&["var","let","const"].includes(i.body[t].name)&&i.body[t+1]&&i.body[t+1].type==="AssignmentExpression"&&(t+=1);let n=i.body[t];r=we.evalAst(n,e)}return r},evalConditionalExpression(i,e){return we.evalAst(i.test,e)?we.evalAst(i.consequent,e):we.evalAst(i.alternate,e)},evalIdentifier(i,e){if(Object.hasOwn(e,i.name))return e[i.name];throw ReferenceError(`${i.name} is not defined`)},evalLiteral(i){return i.value},evalMemberExpression(i,e){let r=String(i.computed?we.evalAst(i.property):i.property.name),t=we.evalAst(i.object,e);if(t==null)throw TypeError(`Cannot read properties of ${t} (reading '${r}')`);if(!Object.hasOwn(t,r)&&u1.has(r))throw TypeError(`Cannot read properties of ${t} (reading '${r}')`);let n=t[r];return typeof n=="function"?n.bind(t):n},evalUnaryExpression(i,e){return{"-":t=>-we.evalAst(t,e),"!":t=>!we.evalAst(t,e),"~":t=>~we.evalAst(t,e),"+":t=>+we.evalAst(t,e),typeof:t=>typeof we.evalAst(t,e)}[i.operator](i.argument)},evalArrayExpression(i,e){return i.elements.map(r=>we.evalAst(r,e))},evalCallExpression(i,e){let r=i.arguments.map(n=>we.evalAst(n,e));return we.evalAst(i.callee,e)(...r)},evalAssignmentExpression(i,e){if(i.left.type!=="Identifier")throw SyntaxError("Invalid left-hand side in assignment");let r=i.left.name,t=we.evalAst(i.right,e);return e[r]=t,e[r]}},Zc=class{constructor(e){this.code=e,this.ast=wi(this.code)}runInNewContext(e){let r=Object.assign(Object.create(null),e);return we.evalAst(this.ast,r)}};function en(i,e){return i=i.slice(),i.push(e),i}function Xc(i,e){return e=e.slice(),e.unshift(i),e}var Jc=class extends Error{constructor(e){super('JSONPath should not be called with "new" (it prevents return of (unwrapped) scalar values)'),this.avoidNew=!0,this.value=e,this.name="NewError"}};function he(i,e,r,t,n){if(!(this instanceof he))try{return new he(i,e,r,t,n)}catch(s){if(!s.avoidNew)throw s;return s.value}typeof i=="string"&&(n=t,t=r,r=e,e=i,i=null);let o=i&&typeof i=="object";if(i=i||{},this.json=i.json||r,this.path=i.path||e,this.resultType=i.resultType||"value",this.flatten=i.flatten||!1,this.wrap=Object.hasOwn(i,"wrap")?i.wrap:!0,this.sandbox=i.sandbox||{},this.eval=i.eval===void 0?"safe":i.eval,this.ignoreEvalErrors=typeof i.ignoreEvalErrors>"u"?!1:i.ignoreEvalErrors,this.parent=i.parent||null,this.parentProperty=i.parentProperty||null,this.callback=i.callback||t||null,this.otherTypeCallback=i.otherTypeCallback||n||function(){throw new TypeError("You must supply an otherTypeCallback callback option with the @other() operator.")},i.autostart!==!1){let s={path:o?i.path:e};o?"json"in i&&(s.json=i.json):s.json=r;let a=this.evaluate(s);if(!a||typeof a!="object")throw new Jc(a);return a}}he.prototype.evaluate=function(i,e,r,t){let n=this.parent,o=this.parentProperty,{flatten:s,wrap:a}=this;if(this.currResultType=this.resultType,this.currEval=this.eval,this.currSandbox=this.sandbox,r=r||this.callback,this.currOtherTypeCallback=t||this.otherTypeCallback,e=e||this.json,i=i||this.path,i&&typeof i=="object"&&!Array.isArray(i)){if(!i.path&&i.path!=="")throw new TypeError('You must supply a "path" property when providing an object argument to JSONPath.evaluate().');if(!Object.hasOwn(i,"json"))throw new TypeError('You must supply a "json" property when providing an object argument to JSONPath.evaluate().');({json:e}=i),s=Object.hasOwn(i,"flatten")?i.flatten:s,this.currResultType=Object.hasOwn(i,"resultType")?i.resultType:this.currResultType,this.currSandbox=Object.hasOwn(i,"sandbox")?i.sandbox:this.currSandbox,a=Object.hasOwn(i,"wrap")?i.wrap:a,this.currEval=Object.hasOwn(i,"eval")?i.eval:this.currEval,r=Object.hasOwn(i,"callback")?i.callback:r,this.currOtherTypeCallback=Object.hasOwn(i,"otherTypeCallback")?i.otherTypeCallback:this.currOtherTypeCallback,n=Object.hasOwn(i,"parent")?i.parent:n,o=Object.hasOwn(i,"parentProperty")?i.parentProperty:o,i=i.path}if(n=n||null,o=o||null,Array.isArray(i)&&(i=he.toPathString(i)),!i&&i!==""||!e)return;let c=he.toPathArray(i);c[0]==="$"&&c.length>1&&c.shift(),this._hasParentSelector=null;let p=this._trace(c,e,["$"],n,o,r).filter(function(m){return m&&!m.isParentSelector});return p.length?!a&&p.length===1&&!p[0].hasArrExpr?this._getPreferredOutput(p[0]):p.reduce((m,_)=>{let y=this._getPreferredOutput(_);return s&&Array.isArray(y)?m=m.concat(y):m.push(y),m},[]):a?[]:void 0};he.prototype._getPreferredOutput=function(i){let e=this.currResultType;switch(e){case"all":{let r=Array.isArray(i.path)?i.path:he.toPathArray(i.path);return i.pointer=he.toPointer(r),i.path=typeof i.path=="string"?i.path:he.toPathString(i.path),i}case"value":case"parent":case"parentProperty":return i[e];case"path":return he.toPathString(i[e]);case"pointer":return he.toPointer(i.path);default:throw new TypeError("Unknown result type")}};he.prototype._handleCallback=function(i,e,r){if(e){let t=this._getPreferredOutput(i);i.path=typeof i.path=="string"?i.path:he.toPathString(i.path),e(t,r,i)}};he.prototype._trace=function(i,e,r,t,n,o,s,a){let c;if(!i.length)return c={path:r,value:e,parent:t,parentProperty:n,hasArrExpr:s},this._handleCallback(c,o,"value"),c;let p=i[0],m=i.slice(1),_=[];
40function y(E){Array.isArray(E)?E.forEach(k=>{_.push(k)}):_.push(E)}if((typeof p!="string"||a)&&e&&Object.hasOwn(e,p))y(this._trace(m,e[p],en(r,p),e,p,o,s));else if(p==="*")this._walk(e,E=>{y(this._trace(m,e[E],en(r,E),e,E,o,!0,!0))});else if(p==="..")y(this._trace(m,e,r,t,n,o,s)),this._walk(e,E=>{typeof e[E]=="object"&&y(this._trace(i.slice(),e[E],en(r,E),e,E,o,!0))});else{if(p==="^")return this._hasParentSelector=!0,{path:r.slice(0,-1),expr:m,isParentSelector:!0};if(p==="~")return c={path:en(r,p),value:n,parent:t,parentProperty:null},this._handleCallback(c,o,"property"),c;if(p==="$")y(this._trace(m,e,r,null,null,o,s));else if(/^(-?\d*):(-?\d*):?(\d*)$/u.test(p))y(this._slice(p,m,e,r,t,n,o));else if(p.indexOf("?(")===0){if(this.currEval===!1)throw new Error("Eval [?(expr)] prevented in JSONPath expression.");let E=p.replace(/^\?\((.*?)\)$/u,"$1"),k=/@.?([^?]*)[['](\??\(.*?\))(?!.\)\])[\]']/gu.exec(E);k?this._walk(e,N=>{let Q=[k[2]],_e=k[1]?e[N][k[1]]:e[N];this._trace(Q,_e,r,t,n,o,!0).length>0&&y(this._trace(m,e[N],en(r,N),e,N,o,!0))}):this._walk(e,N=>{this._eval(E,e[N],N,r,t,n)&&y(this._trace(m,e[N],en(r,N),e,N,o,!0))})}else if(p[0]==="("){if(this.currEval===!1)throw new Error("Eval [(expr)] prevented in JSONPath expression.");y(this._trace(Xc(this._eval(p,e,r.at(-1),r.slice(0,-1),t,n),m),e,r,t,n,o,s))}else if(p[0]==="@"){let E=!1,k=p.slice(1,-2);switch(k){case"scalar":(!e||!["object","function"].includes(typeof e))&&(E=!0);break;case"boolean":case"string":case"undefined":case"function":typeof e===k&&(E=!0);break;case"integer":Number.isFinite(e)&&!(e%1)&&(E=!0);break;case"number":Number.isFinite(e)&&(E=!0);break;case"nonFinite":typeof e=="number"&&!Number.isFinite(e)&&(E=!0);break;case"object":e&&typeof e===k&&(E=!0);break;case"array":Array.isArray(e)&&(E=!0);break;case"other":E=this.currOtherTypeCallback(e,r,t,n);break;case"null":e===null&&(E=!0);break;default:throw new TypeError("Unknown value type "+k)}if(E)return c={path:r,value:e,parent:t,parentProperty:n},this._handleCallback(c,o,"value"),c}else if(p[0]==="`"&&e&&Object.hasOwn(e,p.slice(1))){let E=p.slice(1);y(this._trace(m,e[E],en(r,E),e,E,o,s,!0))}else if(p.includes(",")){let E=p.split(",");for(let k of E)y(this._trace(Xc(k,m),e,r,t,n,o,!0))}else!a&&e&&Object.hasOwn(e,p)&&y(this._trace(m,e[p],en(r,p),e,p,o,s,!0))}if(this._hasParentSelector)for(let E=0;E<_.length;E++){let k=_[E];if(k&&k.isParentSelector){let N=this._trace(k.expr,e,k.path,t,n,o,s);if(Array.isArray(N)){_[E]=N[0];let Q=N.length;for(let _e=1;_e<Q;_e++)E++,_.splice(E,0,N[_e])}else _[E]=N}}return _};he.prototype._walk=function(i,e){if(Array.isArray(i)){let r=i.length;for(let t=0;t<r;t++)e(t)}
40else i&&typeof i=="object"&&Object.keys(i).forEach(r=>{e(r)})};he.prototype._slice=function(i,e,r,t,n,o,s){if(!Array.isArray(r))return;let a=r.length,c=i.split(":"),p=c[2]&&Number.parseInt(c[2])||1,m=c[0]&&Number.parseInt(c[0])||0,_=c[1]&&Number.parseInt(c[1])||a;m=m<0?Math.max(0,m+a):Math.min(a,m),_=_<0?Math.max(0,_+a):Math.min(a,_);let y=[];for(let E=m;E<_;E+=p)this._trace(Xc(E,e),r,t,n,o,s,!0).forEach(N=>{y.push(N)});return y};he.prototype._eval=function(i,e,r,t,n,o){this.currSandbox._$_parentProperty=o,this.currSandbox._$_parent=n,this.currSandbox._$_property=r,this.currSandbox._$_root=this.json,this.currSandbox._$_v=e;let s=i.includes("@path");s&&(this.currSandbox._$_path=he.toPathString(t.concat([r])));let a=this.currEval+"Script:"+i;if(!he.cache[a]){let c=i.replaceAll("@parentProperty","_$_parentProperty").replaceAll("@parent","_$_parent").replaceAll("@property","_$_property").replaceAll("@root","_$_root").replaceAll(/@([.\s)[])/gu,"_$_v$1");if(s&&(c=c.replaceAll("@path","_$_path")),this.currEval==="safe"||this.currEval===!0||this.currEval===void 0)he.cache[a]=new this.safeVm.Script(c);else if(this.currEval==="native")he.cache[a]=new this.vm.Script(c);else if(typeof this.currEval=="function"&&this.currEval.prototype&&Object.hasOwn(this.currEval.prototype,"runInNewContext")){let p=this.currEval;he.cache[a]=new p(c)}else if(typeof this.currEval=="function")he.cache[a]={runInNewContext:p=>this.currEval(c,p)};else throw new TypeError(`Unknown "eval" property "${this.currEval}"`)}try{return he.cache[a].runInNewContext(this.currSandbox)}catch(c){if(this.ignoreEvalErrors)return!1;throw new Error("jsonPath: "+c.message+": "+i)}};he.cache={};he.toPathString=function(i){let e=i,r=e.length,t="$";for(let n=1;n<r;n++)/^(~|\^|@.*?\(\))$/u.test(e[n])||(t+=/^[0-9*]+$/u.test(e[n])?"["+e[n]+"]":"['"+e[n]+"']");return t};he.toPointer=function(i){let e=i,r=e.length,t="";for(let n=1;n<r;n++)/^(~|\^|@.*?\(\))$/u.test(e[n])||(t+="/"+e[n].toString().replaceAll("~","~0").replaceAll("/","~1"));return t};he.toPathArray=function(i){let{cache:e}=he;if(e[i])return e[i].concat();let r=[],n=i.replaceAll(/@(?:null|boolean|number|string|integer|undefined|nonFinite|scalar|array|object|function|other)\(\)/gu,";$&;").replaceAll(/[['](\??\(.*?\))[\]'](?!.\])/gu,function(o,s){return"[#"+(r.push(s)-1)+"]"}).replaceAll(/\[['"]([^'\]]*)['"]\]/gu,function(o,s){return"['"+s.replaceAll(".","%@%").replaceAll("~","%%@@%%")+"']"}).replaceAll("~",";~;").replaceAll(/['"]?\.['"]?(?![^[]*\])|\[['"]?/gu,";").replaceAll("%@%",".").replaceAll("%%@@%%","~").replaceAll(/(?:;)?(\^+)(?:;)?/gu,function(o,s){return";"+s.split("").join(";")+";"}).replaceAll(/;;;|;;/gu,";..;").replaceAll(/;$|'?\]|'$/gu,"").split(";").map(function(o){let s=o.match(/#(\d+)/u);return!s||!s[1]?o:r[s[1]]});return e[i]=n,e[i].concat()};he.prototype.safeVm={Script:Zc};var f1=function(i,e,r){let t=i.length;for(let n=0;n<t;n++){let o=i[n];r(o)&&e.push(i.splice(n--,1)[0])}},ep=class{constructor(e){this.code=e}runInNewContext(e){let r=this.code,t=Object.keys(e),n=[];f1(t,n,p=>typeof e[p]=="function");let o=t.map(p=>e[p]);r=n.reduce((p,m)=>{let _=e[m].toString();return/function/u.test(_)||(_="function "+_),"var "+m+"="+_+";"+p},"")+r,!/(['"])use strict\1/u.test(r)&&!t.includes("arguments")&&(r="var arguments = undefined;"+r),r=r.replace(/;\s*$/u,"");let a=r.lastIndexOf(";"),c=a!==-1?r.slice(0,a+1)+" return "+r.slice(a+1):" return "+r;return new Function(...t,c)(...o)}};he.prototype.vm={Script:ep};var ca=class extends ur{constructor({urlPattern:e,jsonPathExpression:r}){super(e),this.jsonPathExpression=r}isError(e,r){return this.urlMatches(e)&&this.jsonMissing(r.body)}jsonMissing(e){return he({path:this.jsonPathExpression,json:e}).length===0}};var h1="[45]0[0-9]",pa=class extends ur{constructor({urlPattern:e,errorStatusCodes:r}){super(e),this.statusCodeRegEx=RegExp(r===void 0?h1:r)}isError(e,r){return this.urlMatches(e)&&this.isInvalidStatus(r.status)}isInvalidStatus(e){return this.statusCodeRegEx.test(String(e))}};var a_=[{urlPattern:"/oauth/whoami"},{urlPattern:`${se.occPrefix}rest/v2/${se.basesites?"basesites":"basesite"}`},{urlPattern:".*?/cms/pages",errorStatusCodes:"40[0-9]"},{urlPattern:`${se.occPrefix}.*?/currentsite`}],c_=[{urlPattern:`${se.occPrefix}.*?/currentsite`,jsonPathExpression:"$.uid"}];var g1=["NG0306"],p_=(()=>{let e=class e extends ro{constructor(t){super(),this.renderError=t}handleError(t){lo()&&!g1.some(n=>typeof t=="string"&&t.includes(n)||(t.message??"").includes(n))&&console.error(t),typeof t!="string"&&this.renderError&&!t.message?.startsWith("Error retrieving icon")&&(this.renderError.error=t)}};e.\u0275fac=function(n){return new(n||e)(u("RENDER_ERROR",8))},e.\u0275prov=I({token:e,factory:e.\u0275fac});let i=e;return i})();var l_=new St("errorStatusHandlerConfig"),d_=new St("jsonPathHandlerConfig");function _1(i){let e=[];
40return i.forEach(r=>{e.push(new pa(r))}),e}function C1(i){let e=[];return i.forEach(r=>{e.push(new ca(r))}),e}var m_=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({providers:[{provide:Et,useClass:es,multi:!0},{provide:l_,useValue:a_},{provide:d_,useValue:c_},{provide:ku,useFactory:_1,deps:[l_]},{provide:Ru,useFactory:C1,deps:[d_]},{provide:ro,useClass:p_}]});let i=e;return i})();var u_=(()=>{let e=class e{constructor(t,n){this.actions$=t,this.productService=n,this.searchProductsFail$=jt(()=>this.actions$.pipe($t(Ed.SEARCH_PRODUCTS_FAIL),Ot(()=>{this.productService.clearAllProducts()})),{dispatch:!1})}};e.\u0275fac=function(n){return new(n||e)(u(Ni),u(Ui))},e.\u0275prov=I({token:e,factory:e.\u0275fac});let i=e;return i})();var y1=[{provide:An,useExisting:du},{provide:Ao,useExisting:Ui},{provide:Ro,useExisting:Bi},{provide:xd,useExisting:Tm},{provide:Pd,useExisting:Rm}],la=(()=>{let e=class e{static forRoot(){return{ngModule:e,providers:[...y1]}}};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({imports:[Td.forRoot(),di.forFeature([u_])]});let i=e;return i})();var f_=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({imports:[$,pt]});let i=e;return i})();function v1(i){return()=>{lo()||i.get(At).init()}}var h_=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({providers:[{provide:Xe,useFactory:v1,deps:[si],multi:!0}]});let i=e;return i})();var S1={details:{entities:{}},search:{results:{},suggestions:[],auxResults:{}},reviews:{productCode:"",list:[]},references:{productCode:"",list:[]}};function b1(i){let e=R({},i?.product?.search);return e.results=ie(R({},e.results),{products:[],facets:[]}),ie(R({},S1),{search:e})}function g_(i){return(e,r)=>(r.type===xm&&(e=ie(R({},e),{product:b1(e)})),i(e,r))}var x1=new St("SSR_TRANSFER"),__=(i,e)=>{let r;pi(i)?r=e.get(x1):r=window?.process?.env?.SSR_TRANSFER;let t=r&&Object.prototype.hasOwnProperty.call(r,vo)?r[vo]?Aa.TRANSFER_STATE:void 0:Aa.TRANSFER_STATE;return{state:{ssrTransfer:{keys:{[md]:void 0,[Md]:void 0,[vo]:t,[zo]:se.basesites?t:void 0,[bo]:void 0}}}}},C_=(()=>{let e=class e{static forRoot(){return{ngModule:e,providers:[{provide:qt,useExisting:Ls}]}}};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({imports:[$l.forRoot()]});let i=e;return i})();var y_=(()=>{let e=class e{constructor(){this.LOG_LEVEL_ERROR="error",this.MAX_BUFFER_SIZE=100,this.logServiceURI="/storefront-logs",this.logBuffer=[],this.logLevels=[this.LOG_LEVEL_ERROR],this.emailRegEx=/([a-zA-Z0-9._-]+@[a-zA-Z0-9._-]+\.[a-zA-Z0-9._-]+)/gm,this.numberRegEx=/(\d{4}[\s\-.]?){4}(\d{2})?/gm,this.alphanumericRegEx=/[a-zA-Z0-9\-_]/g}
40init(){se.production&&(this.logLevels.forEach(this.wrapConsoleFunction.bind(this)),typeof window<"u"&&(window.onerror=(...t)=>{console.error(...t)}),this.bindPushDataOnPageVisibility(),this.showLogs=!0)}wrapConsoleFunction(t){let n=console[t];console[t]=(...o)=>{let s=o.filter(a=>!!a).map(a=>this.replacePatternsInLogs(a.stack||a.toString()));s?.length>0&&(this.logBuffer.push({severity:t.toUpperCase(),source:"headless-storefront",content:s,timestamp:Date.now()}),this.logBuffer.length>this.MAX_BUFFER_SIZE&&this.pushLogs(),t===this.LOG_LEVEL_ERROR&&this.schedulePushLogs(),this.showLogs&&n.apply(this,o))}}pushLogs(){let t=this.logBuffer;this.logBuffer=[],t.length&&fetch(this.logServiceURI,{method:"POST",body:JSON.stringify(t),headers:{"Content-Type":"application/json"}})}schedulePushLogs(){clearTimeout(this.pushLogTimeout),this.pushLogTimeout=setTimeout(()=>{this.pushLogs()},200)}bindPushDataOnPageVisibility(){document.addEventListener("visibilitychange",()=>{this.pushLogs()})}replacePatternsInLogs(t){let n=t;return n=n.replace(this.numberRegEx," (Credit Card information hidden) "),n=n.replace(this.emailRegEx,this.maskString.bind(this)),n}maskString(t){return t.replace(this.alphanumericRegEx,"*")}};e.\u0275fac=function(n){return new(n||e)},e.\u0275prov=I({token:e,factory:e.\u0275fac,providedIn:"root"});let i=e;return i})();var v_=(()=>{let e=class e extends et{constructor(t){super(),this.cookieService=t,this.uuid=this.getUUID()}getUUID(){let t=this.cookieService.get(La);return t||(t=this.generateUUID(),this.cookieService.set(La,t)),t}};e.\u0275fac=function(n){return new(n||e)(u(ei))},e.\u0275prov=I({token:e,factory:e.\u0275fac});let i=e;return i})();var S_=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({providers:[ei,{provide:Xe,useFactory:(t,n)=>()=>{ct(n)&&t.init()},deps:[y_,Ne],multi:!0},{provide:et,useFactory:(t,n)=>t||new v_(n),deps:[[new Gp,nm],ei]}]});let i=e;return i})();var b_=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({imports:[$]});let i=e;return i})();var x_=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({providers:[{provide:At,useExisting:qn}]});let i=e;return i})();var M_=(()=>{let e=class e extends _s{constructor(t,n,o,s,a,c,p,m){super(t,n,o,s,a,c,p),this.config=p,this.router=m,this.sub=new Ee,this.init()}init(){let t=this.cmsService.getCurrentPage().pipe(j(n=>n!==void 0),z(1)).subscribe(n=>{let o=n.label||n.pageId;o=n.label==="homepage"?"/":o,o=o.startsWith("/")?o:`/${o}`,setTimeout(()=>{this.router.navigateByUrl(o)})});this.sub.add(t)}ngOnDestroy(){this.sub.unsubscribe()}};e.\u0275fac=function(n){return new(n||e)(u(kn),u(mi),u(So),u(Zt),u(K),u(so),u(gs),u(re))},e.\u0275prov=I({token:e,factory:e.\u0275fac,providedIn:"root"});let i=e;return i})();var E_=(()=>{let e=class e extends Jn{constructor(t,n,o,s,a,c){super(t,n,o),this.winRef=s,this.activatedRoute=a,this.cookiesService=c,this.CMS_TICKET_ID="cmsTicketId",this.sub=new Ee,this.init()}load(){this.winRef.isBrowser()&&this.isLaunchedInSmartEdit()&&this.scriptLoader.embedScript({src:"/_ui/addons/smarteditaddon/shared/common/js/webApplicationInjector.js",params:void 0,attributes:{id:"smartedit-injector","data-smartedit-allow-origin":this.config.smartEdit.allowOrigin}})}init(){if(!this.winRef.isBrowser())return;let t=this.activatedRoute.queryParams.pipe(rt(this.CMS_TICKET_ID),j(n=>!!n),X()).subscribe(n=>{this.cookiesService.put(this.CMS_TICKET_ID,n,{path:"/",secure:!0})});this.sub.add(t)}ngOnDestroy(){this.sub.unsubscribe()}};e.\u0275fac=function(n){return new(n||e)(u(gs),u(mo),u(ko),u(K),u(In),u($n))},e.\u0275prov=I({token:e,factory:e.\u0275fac,providedIn:"root"});let i=e;return i})();var I_=(()=>{let e=class e{constructor(t){this.service=t}intercept(t,n){let o=se.basesites?"basesites":"basesite";return!t.url.includes("/"+o)&&this.service.cmsTicketId&&(t=t.clone({setParams:{cmsTicketId:this.service.cmsTicketId}})),n.handle(t)}};e.\u0275fac=function(n){return new(n||e)(u(Jn))},e.\u0275prov=I({token:e,factory:e.\u0275fac,providedIn:"root"});let i=e;return i})();function P1(){return{smartEdit:{storefrontPreviewRoute:"cx-preview",allowOrigin:se.production?"*.costco.co.uk:443,*.costco.com.mx:443,*.
40costco.fr:443,*.costco.com.tw:443,*.costco.co.kr:443,*.costco.co.jp:443,*.costco.es:443,*.costco.com.au:443,*.costco.is:443,*.sipint.net:443":"localhost:9002,costco.uk.local:9002,costco.mexico.local:9002,costco.australia.local:9002,costco.japan.local:9002,costco.france.local:9002,costco.spain.local:9002,costco.iceland.local:9002,costco.taiwan.local:9002,costco.korea.local:9002"}}}var da=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({providers:[M({featureModules:{[dh]:{module:()=>import("./chunk-UMQGCPNM.js").then(t=>t.SmartEditModule)}}}),ho(P1),{provide:_s,useExisting:M_},{provide:Jn,useExisting:E_},{provide:Et,useExisting:I_,multi:!0}],imports:[mh]});let i=e;return i})();var O_=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({});let i=e;return i})();var w_=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({imports:[O_]});let i=e;return i})();var T_=(()=>{let e=class e{getColorOptionQualifier(t){return t.variantOptionQualifiers.find(n=>n.qualifier==="colour")}hasAnyColorOptions(t){return t&&t.find(n=>this.getColorOptionQualifier(n))}getColorVariantOptions(t){if(!t)return[];let n=t.find(o=>o.options.find(s=>this.getColorOptionQualifier(s)));return n?n.options:[]}convert(t,n){if(n===void 0&&(n=R({},t)),t.variantColours||!t.variantOptions&&!t.baseOptions)return n;let o=[],s=this.hasAnyColorOptions(t.variantOptions)?t.variantOptions:this.getColorVariantOptions(t.baseOptions);for(let a of s){if(!a.variantOptionQualifiers)continue;let c=this.getColorOptionQualifier(a);if(!c)continue;let p={};p.code=c.value,p.hexcode=c.colorHex,p.url=a.url,p.name=c.value,p.imageUrl=c.image?.url,o.push(p)}return n.variantColours=o,n}};e.\u0275fac=function(n){return new(n||e)},e.\u0275prov=I({token:e,factory:e.\u0275fac,providedIn:"root"});let i=e;return i})();var k_=(()=>{let e=class e{constructor(t){this.converterService=t}convert(t,n){return n===void 0&&(n=R({},t)),t.addOnServices&&(n.addOnServices=t.addOnServices.map(o=>o.displayOnProductPDP?this.converterService.convert(o,Zo):o)),n.addToCartFromPLPCategories=Gs(t.addToCartFromPLPCategories),n.decalData=t.decalData,t.multiProduct&&(t.defaultProduct&&t.defaultProduct.product&&(n.defaultProduct.product=this.converterService.convert(t.defaultProduct.product,Bt)),t.associateProducts&&t.associateProducts.length>0&&t.associateProducts.forEach(o=>{n.associateProducts.find(s=>s.code===o.code).product=this.converterService.convert(o.product,Bt)})),n.pdpMessages=mg(t.pdpMessages),typeof t.discountStartDate=="string"&&(n.discountStartDate=new Date(t.discountStartDate)),typeof t.discountEndDate=="string"&&(n.discountEndDate=new Date(t.discountEndDate)),n.couponDiscount&&n.couponDiscount.discountValue>0&&!n.couponDiscount.discountStartDate&&n.discountStartDate&&(n.couponDiscount.discountStartDate=n.discountStartDate,n.couponDiscount.discountEndDate=n.discountEndDate,n.couponDiscount.discountDateMessage=n.discountMessage),n}};e.\u0275fac=function(n){return new(n||e)(u(Rt))},e.\u0275prov=I({token:e,factory:e.\u0275fac,providedIn:"root"});let i=e;return i})();var R_=(()=>{let e=class e{constructor(t){this.converterService=t,this.DEFAULT_TOP_VALUES=6}convert(t,n={}){return n=R(R({},n),t),t.categoryLandingPage||(this.normalizeFacets(n),t.products&&(n.products=t.products.map(o=>this.converterService.convert(o,Bt)))),n}normalizeFacets(t){t.facets&&(this.normalizeFacetValues(t),this.normalizeUselessFacets(t))}normalizeUselessFacets(t){t.facets=t.facets.filter(n=>!t.pagination||!t.pagination.totalResults||(!Object.prototype.hasOwnProperty.call(n,"visible")||n.visible)&&n.values&&n.values.find(o=>o.selected||o.count<t.pagination.totalResults))}normalizeFacetValues(t){t.facets=t.facets.map(n=>{let o=R({},n),{topValues:s}=o;return o.topValueCount=s?s.length:this.DEFAULT_TOP_VALUES,o})}};e.\u0275fac=function(n){return new(n||e)(u(Rt))},e.\u0275prov=I({token:e,factory:e.\u0275fac,providedIn:"root"});let i=e;return i})();var A_=(()=>{let e=class e extends Oo{constructor(t){super(t),this._converter=t}convert(t,n=[]){if(n===void 0&&(n=R({},t)),t&&t.references)return n=t.references.filter(o=>o.target).map(o=>ie(R({},o),{target:ie(R({},this._converter.convert(o.target,Bt)),{attributionToken:o.attributionToken})})),n}};e.\u0275fac=function(n){return new(n||e)(u(Rt))},e.\u0275prov=I({token:e,factory:e.\u0275fac,providedIn:"root"});let i=e;return i})();var hr="DEFAULT,references(target(DEFAULT))",N_={backend:{occ:{endpoints:{product:{default:"products/${productC
40ode}/?fields=DEFAULT",list:"products/${productCode}/?fields=DEFAULT",details:"products/${productCode}/?fields=FULL"},productReviews:"products/${productCode}/reviews",productReferences:"products/${productCode}/references?fields="+hr,productIngredients:"products/ingredients/${storeName}/?fields=DEFAULT",productReferencesMultiple:"products/productReferences?currentPage=${currentPage}&fields="+hr,productReferencesByProductCodes:"products/productReferences/product/${productCodes}/?currentPage=${currentPage}&fields="+hr,productReferencesByReferenceType:"products/productReferences/reference/${referenceType}/?currentPage=${currentPage}&fields="+hr,productReferencesByProductCodesAndReferenceType:"products/productReferences/product/${productCodes}/reference/${referenceType}/?currentPage=${currentPage}&fields="+hr,productReferencesMany:"products/references?fields="+hr,productSearch:"products/search?fields=FULL",tireSearch:"tires/search?fields=FULL",batterySearch:"products/results?fields=FULL",productSuggestions:"products/suggestions",productInterests:"users/${userId}/stocknotification",getProductInterests:"users/${userId}/stocknotification?fields=sorts,pagination,results(productInterestEntry,product(code))",productEarliestEstimatedDeliveryDate:"products/${productCode}/earliestEstimatedDeliveryDate?fields=FULL",products:"products/search/export",pointsOfService:"stores/pos?productCode=${productCode}&deliveryMode=${deliveryMode}&fields=${fields}",productMaxQuantityPerMode:"users/${userId}/max-quantity?productCode=${productCode}"}},loadingScopes:{product:{details:{include:[],reloadOn:[ah,ch]}}}}};var D_=(()=>{let e=class e{constructor(){this.http=L(We),this.siteService=L(be),this.languageService=L(Rr),this.converter=L(Rt),this.externalSearchUtils=L(Hn)}search(t,n){return this._buildExternalSearchConfig(t,n).pipe(A(o=>this.externalSearchUtils.buildSearchServiceUrl("/search",R({},o))),A(o=>this.http.get(o).pipe(this.converter.pipeable(Da))))}loadSuggestions(t,n){return this._buildExternalSearchConfig().pipe(A(o=>this.externalSearchUtils.buildSearchServiceUrl("/search/suggestions",R({term:t,max:n},o))),A(o=>this.http.get(o).pipe(x(s=>s.suggestions??[]),this.converter.pipeableMany(Jl))))}fetchProductsByCode(t,n){return this._buildExternalSearchConfig().pipe(A(o=>this.externalSearchUtils.buildSearchServiceUrl("/search",R(R({productCodes:t},o),n))),A(o=>this.http.get(o).pipe(this.converter.pipeable(Da))))}_buildExternalSearchConfig(t,n={}){return ae([this.siteService.getSite(),this.languageService.getActive()]).pipe(x(([o,s])=>ie(R({},n),{query:t,curr:o?.baseStore?.defaultCurrency?.isocode,locale:s})))}};e.\u0275fac=function(n){return new(n||e)},e.\u0275prov=I({token:e,factory:e.\u0275fac,providedIn:"root"});let i=e;return i})();var tp=(()=>{let e=class e{constructor(){this.occAdapter=L(uu),this.occProductAdapter=L(Go),this.externalAdapter=L(D_),this.switchingTiresAdapter=L(Ou),this.searchEnablementService=L(mu)}search(t,n){return n.fitmentType||n.isBatteriesSearch?this.switchingTiresAdapter.search(t,n):this.adapterSwitch().pipe(A(o=>o.search(t,n)))}loadSuggestions(t,n){return this.adapterSwitch().pipe(A(o=>o.loadSuggestions(t,n)))}fetchProductsByCode(t,n){return this.externalSearchServiceEnabled().pipe(A(o=>o?this.externalAdapter.fetchProductsByCode(t,n):this.productsOccFetch(t,n)))}productsOccFetch(t,n){return this.occProductAdapter.fetch(t,n).pipe(x(o=>({products:o})))}adapterSwitch(){return this.externalSearchServiceEnabled().pipe(x(t=>t?this.externalAdapter:this.occAdapter),_t(1))}externalSearchServiceEnabled(){return this.searchEnablementService.productSearchEnabled()}};e.\u0275fac=function(n){return new(n||e)},e.\u0275prov=I({token:e,factory:e.\u0275fac,providedIn:"root"});let i=e;return i})();var F_=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({providers:[M(N_),{provide:Bt,useExisting:k_,multi:!0},{provide:ed,useExisting:Go},{provide:Xl,useExisting:R_},{provide:Yl,useExisting:qa},{provide:Bt,useExisting:T_,multi:!0},{provide:td,useExisting:tp},{provide:km,useExisting:tp},{provide:Bt,useClass:Zl,multi:!0},{provide:Oo,useClass:A_},{provide:Zo,useClass:qa,multi:!0}],imports:[id]});let i=e;return i})();var L_={backend:{occ:{endpoints:{membership:"users/${userId}/membership",canCancelMembership:"users/${userId}/canCancelMembership",membershipUpgrade:"users/${userId}/membership/upgrade?fields=FULL",addMembershipUpgradeToCart:"users/${userId}/carts/${cartId}/membership/upgrade",membershipAutoRenew:"users/${userId}/autoRenewToggle"}}}};var j_=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({providers:[M(L_),th]});let i=e;return i})();var $_={backend:{occ:{endpoints:{receipts:"users/${userId}/receipts",receiptDetail:"users/${userId}/receipts/details?enhanced=true"}}}};var B_=new St("OccReceiptsNormalizer");var U_=(()=>{let e=class e{convert(t,n){return n=t.map(o=>ie(R({},o),{transactionDateTime:new Date(o.transactionDateTime)})),n}};e.\u0275fac=function(n){return new(n||e)},e.\u0275prov=I({token:e,factory:e.\u0275fac,providedIn:"root"});let i=e;return i})();var z_=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({providers:[M($_),{provide:B_,useExisting:U_,multi:!0}]});let i=e;return i})();var G_={backend:{occ:{endpoints:{cartGroupAddressEntryMap:"users/${userId}/carts/${cartId}/delivery-map?fields=FULL",validateCartGroupAddress:"users/${userId}/carts/${cartId}/cartgroup/${cartGroupId}/address/delivery/validate/${addressId}",validateCartEntryAddress:"users/${userId}/carts/${cartId}/entry/${entryNumber}/address/delivery/validate/${addressId}",saveDeliveryAddresses:"users/${userId}/carts/${cartId}/address/delivery/save?fields=FULL",address:"users/${userId}/carts/${cartId}/entry/${entryNumber}/addresses/delivery/${addressId}?fields=FULL",splitAll:"users/${userId}/carts/${cartId}/entry/${entryNumber}/split-all?fields=FULL",splitEntry:"users/${userId}/carts/${cartId}/entry/${entryNumber}/split/${entryNewQuantity}
40?fields=FULL",cancelSplit:"users/${userId}/carts/${cartId}/cancel-split"}}}};var H_=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({providers:[M(G_),{provide:Xf,useExisting:Jf,multi:!0}]});let i=e;return i})();var V_={backend:{occ:{endpoints:{reorder:"users/${userId}/carts/${cartId}/reorder/",orders:"users/${userId}/orders",order:"/users/${userId}/orders/${orderId}",ordersPlace3ds2:"users/${userId}/orders/place3ds2",ordersPlace3ds2BypassPayment:"users/${userId}/orders/place3ds2/bypass-payment",ordersBypassPayment:"users/${userId}/orders/bypass-payment",ordersPlacePreorder:"users/${userId}/orders/placePreorder",consents:"users/${userId}/consents/custom",bulkTemplate:"users/${userId}/orders/bulk/template",bulkValidate:"users/${userId}/orders/bulk/validate",bulkSubmit:"users/${userId}/orders/bulk/submit",generateInvoice:"users/${userId}/orders/${code}/generateInvoice",invoiceEligibility:"users/${userId}/orders/${code}/invoice-eligibility",downloadInvoice:"users/${userId}/orders/${code}/downloadInvoice",dropOffLabel:"users/${userId}/orders/${code}/returns/${rmaNumber}/dropoff-label-download",dropOffLabelConsignment:"users/${userId}/orders/${code}/returns/${rmaNumber}/consignment/${consignmentCode}/dropoff-label-download",cancelOrder:"users/${userId}/orders/cancel",orderUpdate:"/users/${userId}/orders/update",editOrder:"/users/${userId}/orders/${code}/edit",allowedAttributesForOrderEdit:"orders/${code}/edit/allowedAttributes",entryDetailsForReturn:"users/${userId}/orders/${code}/returns/details?fields=FULL",deliveryOptionsForReturn:"users/${userId}/orders/${code}/returns/delivery-options",returnOrder:"users/${userId}/orders/${code}/returns?fields=FULL",reviewReturnOrder:"users/${userId}/orders/${code}/returns/${rmaNumber}/review?fields=FULL",sendDigitalProductConfirmationEmail:"/users/${userId}/orders/${code}/digital-product/sendConfirmation",entryDetailsForCancellation:"users/${userId}/orders/${code}/cancellations/details?fields=FULL",orderCancellations:"users/${userId}/orders/${code}/cancellations",orderCancellationEntries:"users/${userId}/orders/${code}/cancellations/entries?fields=FULL",trackingDetails:"users/${userId}/tracking-details?fields=FULL"}}}};var q_=(()=>{let e=class e{intercept(t,n){return t.url.includes("/reorder")&&t.method.match("POST")&&(t=t.clone({body:{orderEntries:this.sanitizeOrderEntries(t.body.orderEntries)}})),n.handle(t)}sanitizeOrderEntries(t){return t.map((n,o)=>{let s={};return s.entryNumber=n.entryNumber,s.quantity=n.quantity===0?n.product.minOrderQuantity:n.quantity,s.orderCode=n.orderCode,s.restrictedForDelivery=n.restrictedForDelivery,s.deliveryAddress=n.deliveryAddress,s.addOnServices=n.addOnServices?this.sanitizeAddonsForReorder(n.addOnServices):{},s.product=n.product?this.sanitizeProductForReorder(n.product):{},s})}sanitizeAddonsForReorder(t){return t.map((n,o)=>{let s={};return s.code=n.code,s.quantity=n.quantity,s.optional=n.optional,s.selected=n.selected,s})}sanitizeProductForReorder(t){let n={};return n.code=t.code,n.productType=t.productType,n.purchasable=t.purchasable,n.availableForPreorder=t.availableForPreorder,n.isExternalVendorProduct=t.isExternalVendorProduct,n.isExternalVendorVariantProduct=t.isExternalVendorVariantProduct,n.cartGroup={},n.cartGroup.groupId=t.cartGroup?.groupId,n}};e.\u0275fac=function(n){return new(n||e)},e.\u0275prov=I({token:e,factory:e.\u0275fac,providedIn:"root"});let i=e;return i})();var W_=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({providers:[M(V_),{provide:Wu,useExisting:uh},{provide:$f,useClass:Hf},{provide:Et,useExisting:q_,multi:!0},{provide:zf,useExisting:Gf,multi:!0}]});let i=e;return i})();var K_=(()=>{let e=class e extends os{constructor(){super(...arguments),this.sipGlobalMessageService=L(Nt)}logoutCustomerSupportAgent(){return J(this,null,function*(){this.authStorageService.clearEmulatedUserToken(),vr(e.prototype,this,"logoutCustomerSupportAgent").call(this)})}startCustomerEmulationSession(t){this.store.dispatch(new Er.Logout),this.userIdService.setUserId(t),this.store.dispatch(new Er.Login)}authorizeCustomerSupportAgent(t,n){return J(this,null,function*(){yield vr(e.prototype,this,"authorizeCustomerSupportAgent").call(this,t,n);let o;this.authStorageService.getToken().subscribe(s=>o=s).unsubscribe(),o&&o.access_token?(this.sipGlobalMessageService.removeAllMessages(),this.authStorageService.setEmulatedUserToken(o),this.authStorageService.switchTokenTargetToCSAgent()):(this.sipGlobalMessageService.removeAllMessages(),this.sipGlobalMessageService.addMessage({key:"login.error.account"},je.MSG_TYPE_ERROR))})}};e.\u0275fac=(()=>{let t;return function(o){return(t||(t=Le(e)))(o||e)}})(),e.\u0275prov=I({token:e,factory:e.\u0275fac,providedIn:"root"});let i=e;return i})();var Q_=(()=>{let e=class e extends ps{constructor(t,n,o,s){super(t,n,o),this.statePersistenceService=t,this.store=n,this.authStorageService=o,this.userIdService=s}getAsmState(){return ae([this.store.pipe(j(t=>!!t.asm),Pl(Ju.getAsmUi)),this.authStorageService.getTokenTarget(),this.userIdService.getUserId()]).pipe(x(([t,n,o])=>{let s=this.authStorageService.getEmulatedUserToken(),a=s;return a&&(a=R({},s),delete a.refresh_token),{ui:t,userId:o,emulatedUserToken:a,tokenTarget:n}}))}onRead(t){t&&(t.ui&&this.store.dispatch(new Xu.AsmUiUpdate(t.ui)),t.emulatedUserToken&&(this.authStorageService.setEmulatedUserToken(t.emulatedUserToken),this.authStorageService.setToken(t.emulatedUserToken)),t.userId&&this.userIdService.setUserId(t.userId),t.tokenTarget&&this.authStorageService.setTokenTarget(t.tokenTarget))}};e.\u0275fac=function(n){return new(n||e)(u(wn),u(Mn),u(Uu),u(Gn))},e.\u0275prov=I({token:e,factory:e.\u0275fac,providedIn:"root"});let i=e;return i})();var Y_=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({providers:[{provide:Di,useExisting:wu},{provide:os,useExisting:K_},{provide:ps,useExisting:Q_},M({featureModules:{[Zu]:{module:()=>import("./chunk-BJ7ID65F.js").then(t=>t.SipAsmModule)}}}),M({asm:{userIdHttpHeader:{enable:!0},agentSessionTimer:{startingDelayInSeconds:600},customerSearch:{maxResults:20}}})],imports:[Gu]});let i=e;return i})();var Z_={backend:{occ:{endpoints:{store:"/stores/${storeId}?fields=FULL",stores:"/stores?fields=FULL"}}}};var X_=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({providers:[M(Z_),{provide:Cu,useExisting:Iu},{provide:gu,useExisting:bu},{provide:hu,useExisting:Su}],imports:[vu]});let i=e;return i})();var J_=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({providers:[M({featureModules:{[_u]:{module:()=>import("./chunk-KNSLAS22.js").then(t=>
40t.SipStoreFinderModule),cmsComponents:["StoreFinderComponent"]}}}),M({googleMaps:{apiUrl:"https://maps.google.com/maps/api/js",scale:1,selectedMarkerScale:13,radius:3e6}})],imports:[fu,X_,yu]});let i=e;return i})();var eC=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({providers:[M({featureModules:{myRewards:{cmsComponents:["MyRewardsComponent"]}}})]});let i=e;return i})();var tC=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({providers:[M({featureModules:{myRewards:{module:()=>import("./chunk-L6SCASRQ.js").then(t=>t.SipMyRewardsModule)}}})],imports:[eC]});let i=e;return i})();var iC=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({providers:[M({featureModules:{myReceipts:{cmsComponents:["MyReceiptsComponent"]}}})]});let i=e;return i})();var nC=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({providers:[M({featureModules:{myReceipts:{module:()=>import("./chunk-YIOQT7ED.js").then(t=>t.SipMyReceiptsModule)}}})],imports:[iC]});let i=e;return i})();var rC=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({providers:[M({featureModules:{reorderDetails:{cmsComponents:["ReorderDetailsComponent"]}}})]});let i=e;return i})();var oC=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({providers:[M({featureModules:{reorderDetails:{module:()=>import("./chunk-QVDVGY2H.js").then(t=>t.SipReorderDetailsModule),dependencies:[vi]}}})],imports:[rC]});let i=e;return i})();var sC=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({providers:[M({featureModules:{upgradeMembership:{cmsComponents:["MyUpgradeMembershipComponent"]}}})]});let i=e;return i})();var aC=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({providers:[M({featureModules:{upgradeMembership:{module:()=>import("./chunk-F65WKR7F.js").then(t=>t.SipMyUpgradeMembershipModule)}}})],imports:[sC]});let i=e;return i})();var cC=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({providers:[M({featureModules:{wishlist:{cmsComponents:["AccountWishlistComponent"]}}})]});let i=e;return i})();var pC=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({providers:[M({featureModules:{wishlist:{module:()=>import("./chunk-JYJH2QCZ.js").then(t=>t.SipWishListModule)}}})],imports:[cC]});let i=e;return i})();var lC=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({providers:[M({featureModules:{splitAddress:{cmsComponents:["SplitAddressComponent"]}}})]});let i=e;return i})();var dC=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({providers:[M({featureModules:{splitAddress:{module:()=>import("./chunk-EGZ3Y44W.js").then(t=>t.SipSplitAddressModule)}}})],imports:[lC]});let i=e;return i})();var mC=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({providers:[M({featureModules:{cartTotals:{cmsComponents:["CartTotalsComponent"]}}})]});let i=e;return i})();var uC=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({providers:[M({featureModules:{cartTotals:{module:()=>import("./chunk-VI4WCHEG.js").then(t=>t.SipCartTotalsModule)}}})],imports:[mC]});let i=e;return i})();var fC=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({providers:[M({featureModules:{cartDetails:{cmsComponents:["CheckoutComponent","CartComponent","EmptyCartParagraphComponent"]}}})]});let i=e;return i})();var hC=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({providers:[M({featureModules:{cartDetails:{module:()=>import("./chunk-PWRTPANN.js").then(t=>t.SipCartDetailsModule)}}})],imports:[fC]});let i=e;return i})();var gC=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({providers:[M({featureModules:{cartPromotions:{cmsComponents:["PotentialPromotionsComponent","PromotionsComponent"]}}})]});let i=e;return i})();var _C=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({providers:[M({featureModules:{cartPromotions:{module:()=>import("./chunk-CJ3RLYYN.js").then(t=>t.SipCartPromotionsModule)}}})],imports:[gC]});let i=e;return i})();
40var CC=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({providers:[M({featureModules:{saveForLater:{cmsComponents:["SaveForLaterCMSComponent"]}}})]});let i=e;return i})();var yC=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({providers:[M({featureModules:{saveForLater:{module:()=>import("./chunk-NILZC66D.js").then(t=>t.SipSaveForLaterModule)}}})],imports:[CC]});let i=e;return i})();var vC=(()=>{let e=class e extends Wo{unregister(t,n){return this.userProfileAdapter.unregister(t,n)}};e.\u0275fac=(()=>{let t;return function(o){return(t||(t=Le(e)))(o||e)}})(),e.\u0275prov=I({token:e,factory:e.\u0275fac,providedIn:"root"});let i=e;return i})();var SC=(()=>{let e=class e extends fh{unregister(t,n=""){let o=this.occEndpoints.buildUrl("unregister",{urlParams:{userId:t}});return this.http.post(o,{currentPassword:n})}};e.\u0275fac=(()=>{let t;return function(o){return(t||(t=Le(e)))(o||e)}})(),e.\u0275prov=I({token:e,factory:e.\u0275fac,providedIn:"root"});let i=e;return i})();var bC=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({providers:[M({featureModules:{[Dm]:{module:()=>import("./chunk-TSOWQ6EC.js").then(t=>t.SipUserAccountModule)},[Km]:{module:()=>import("./chunk-EX7GRNON.js").then(t=>t.UserProfileModule)}}}),{provide:Zm,useExisting:Xm},{provide:Wo,useExisting:vC},{provide:Ym,useExisting:SC}],imports:[Fm,Qm]});let i=e;return i})();var xC=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({providers:[M({featureModules:{cancelMembership:{module:()=>import("./chunk-T7E7CZY6.js").then(t=>t.SipCancelMembershipModule),cmsComponents:["AccountCancelMembershipComponent"]},contactUs:{module:()=>import("./chunk-LUSO6M4A.js").then(t=>t.SipContactUsModule),cmsComponents:["AccountContactUsComponent"]},unregisterAccount:{module:()=>import("./chunk-OQTOS4GX.js").then(t=>t.SipAccountUnregisterModule),cmsComponents:["AccountUnregisterComponent"]},updatePassword:{module:()=>import("./chunk-VXOR7QWL.js").then(t=>t.SipUpdatePasswordModule),cmsComponents:["UpdatePasswordComponent"]},updateProfile:{module:()=>import("./chunk-2AENZBAF.js").then(t=>
40t.SipUpdateProfileModule),cmsComponents:["UpdateProfileComponent"]},accountPreferences:{module:()=>import("./chunk-4S7RKDEO.js").then(t=>t.SipAccountPreferencesModule),cmsComponents:["AccountPreferencesComponent"]},addressBook:{module:()=>import("./chunk-QKTM332O.js").then(t=>t.SipAddressBookModule),cmsComponents:["AccountAddressBookComponent"]},addAddress:{module:()=>import("./chunk-Y24HHDBM.js").then(t=>t.SipAddressAddEditModule),cmsComponents:["AccountAddEditAddressComponent"]},bulkOrders:{module:()=>import("./chunk-3O7W4HLA.js").then(t=>t.SipBulkOrdersModule),cmsComponents:["AccountBulkOrdersComponent"]},bulkOrdersValidationResults:{module:()=>import("./chunk-DVJ6O3IA.js").then(t=>t.SipBulkOrdersValidationModule),cmsComponents:["AccountBulkOrdersValidationComponent"]},mySubscriptions:{module:()=>import("./chunk-JILZIXVX.js").then(t=>t.SipMySubscriptionsModule),cmsComponents:["MySubscriptionsComponent"]},paymentMethods:{module:()=>import("./chunk-ITFW5JWA.js").then(t=>t.SipPaymentMethodsModule),cmsComponents:["AccountPaymentMethodsComponent"],dependencies:[as]},carrierInvoice:{module:()=>import("./chunk-JBAZCSKE.js").then(t=>t.SipCarrierInvoiceModule),cmsComponents:["UpdateEinvoiceComponent"]},consignmentTracking:{module:()=>import("./chunk-EOJ4WEXB.js").then(t=>t.SipAccountTrackingModule),cmsComponents:["AccountTrackAndTraceComponent"],dependencies:[ss]}}})],imports:[$]});let i=e;return i})();var PC=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({providers:[M({featureModules:{[Nr]:{cmsComponents:["AccountOrderHistoryComponent","AccountOrderDetailComponent"]},[ss]:Nr}})]});let i=e;return i})();var MC=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({providers:[M({featureModules:{[Nr]:{module:()=>import("./chunk-MNQBJQTN.js").then(t=>t.SipOrderModule)}}})],imports:[PC]});let i=e;return i})();function E1(i){return()=>{i.resolveFeature(Ga)}}var EC=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({providers:[M({featureModules:{[ln]:{module:()=>import("./chunk-RRW223I3.js").then(t=>t.SipCartBaseModule)},[Ga]:ln}}),{provide:Xe,useFactory:E1,deps:[hi],multi:!0}],imports:[iu,hh]});let i=e;return i})();var IC=(()=>{let e=class e extends nd{constructor(t,n,o,s){super(t,n,o),this.http=t,this.occEndpointsService=n,this.converterService=o,this.siteService=s}loadLanguages(){return this.siteService.getSite().pipe(j(t=>!!t),x(t=>t.stores?.length?t.stores[0].languages:[]),_t(1))}};e.\u0275fac=function(n){return new(n||e)(u(We),u(Je),u(Rt),u(be))},e.\u0275prov=I({token:e,factory:e.\u0275fac,providedIn:"root"});let i=e;return i})();var OC=(()=>{let e=class e{constructor(t,n,o,s){this.languageService=t,this.currencyService=n,this.occEndpoints=o,this.config=s,this.isLocal=!se.production,this.activeLang=Ra(this.config,yo),this.activeCurr=Ra(this.config,Dl),this.languageService.getActive().subscribe(a=>this.activeLang=a),this.currencyService.getActive().subscribe(a=>{this.activeCurr=a})}intercept(t,n){let o=this.isLocal&&t.url.includes("/live-preview?")?se.bffBaseUrl+t.url:t.url;t=t.clone({url:o,setParams:{lang:this.activeLang??"",curr:this.activeCurr??""}});let s=o.split("/").pop().split("?").shift();if(["basesite","basesites"].includes(s)){let a=t.params.delete("lang").delete("curr");t=t.clone({params:a})}return n.handle(t)}};e.\u0275fac=function(n){return new(n||e)(u(fi),u(od),u(Je),u(kl))},e.\u0275prov=I({token:e,factory:e.\u0275fac,providedIn:"root"});let i=e;return i})();var wC=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({providers:[{provide:rd,useClass:IC},{provide:Et,useClass:OC,multi:!0}],imports:[$]});let i=e;return i})();var TC="Load Product Interests Success",I1="[LOADER] SUCCESS";function O1(i){return{entityType:i,loader:{success:!0}}}var ip=class{constructor(e){this.type=I1,this.meta=O1(e)}},np=class extends ip{constructor(e){super(ql),this.payload=e,this.type=TC}},ma=class extends np{constructor(e){super(e),this.payload=e,this.type=TC}};var kC=(()=>{let e=class e{constructor(t,n,o,s){this.http=t,this.occEndpoints=n,this.config=o,this.converter=s}
40addInterest(t,n,o){let s=new Mr().set("productCode",n);return this.http.post(this.occEndpoints.buildUrl("productInterests",{urlParams:{userId:t}}),o,{params:s}).pipe(Ge(a=>sn(a)))}removeInterest(t,n,o){let s=new Mr().set("productCode",n).set("removeFromWishlist",String(o));return this.http.delete(this.occEndpoints.buildUrl("productInterests",{urlParams:{userId:t}}),{params:s}).pipe(Ge(a=>sn(a)))}};e.\u0275fac=function(n){return new(n||e)(u(We),u(Je),u(Rl),u(Rt))},e.\u0275prov=I({token:e,factory:e.\u0275fac,providedIn:"root"});let i=e;return i})();var RC=(()=>{let e=class e{constructor(t){this.adapter=t}addInterest(t,n,o){return this.adapter.addInterest(t,n,o)}removeInterest(t,n,o){return this.adapter.removeInterest(t,n,o)}};e.\u0275fac=function(n){return new(n||e)(u(kC))},e.\u0275prov=I({token:e,factory:e.\u0275fac,providedIn:"root"});let i=e;return i})();var AC=(()=>{let e=class e{constructor(t,n,o,s,a){this.actions$=t,this.productInterestsConnector=n,this.userInterestsConnector=o,this.sipProductInterestsService=s,this.loggerFactory=a,this.logger=this.loggerFactory.getLogger("SipProductInterestsEffect"),this.loadProductInteres$=jt(()=>this.actions$.pipe($t(Af),x(c=>c.payload),Op(c=>this.userInterestsConnector.getInterests(c.userId,c.pageSize,c.currentPage,c.sort,c.productC
40ode,c.notificationType).pipe(x(p=>{let m=ie(R({},p),{productCode:c.productCode});return new ma(m)}),Ge(p=>D(new Fi.LoadProductInterestsFail(Bl(p,this.logger)))))))),this.addProductInterest$=jt(()=>this.actions$.pipe($t(kf),x(c=>c.payload),A(c=>this.productInterestsConnector.addInterest(c.userId,c.productCode,c.notificationPreferences).pipe(A(p=>[new Xa({userId:c.userId,productCode:c.productCode}),new Fi.AddProductInterestSuccess(p)]),Ge(p=>D(new Fi.AddProductInterestFail(Tr(p)))))))),this.removeProductInterest$=jt(()=>this.actions$.pipe($t(Rf),x(c=>c.payload),A(c=>this.productInterestsConnector.removeInterest(c.userId,c.productCode,c.removeFromWishlist).pipe(A(()=>[new Xa({userId:c.userId,productCode:c.productCode}),new Fi.RemoveProductInterestSuccess(c)]),Ge(p=>D(new Fi.RemoveProductInterestFail(Tr(p)))))))),this.addProductInterestLinkWithWishlist$=jt(()=>this.actions$.pipe($t(Fi.ADD_PRODUCT_INTEREST_SUCCESS),x(()=>{this.sipProductInterestsService.emitAddedToWishlistFromProductInterest(!0)})),{dispatch:!1}),this.removeProductInterestLinkWithWishlist$=jt(()=>this.actions$.pipe($t(Fi.REMOVE_PRODUCT_INTEREST_SUCCESS),x(c=>{this.sipProductInterestsService.emitRemovedFromWishlistFromProductInterest(!!c.payload?.removeFromWishlist)})),{dispatch:!1})}};e.\u0275fac=function(n){return new(n||e)(u(Ni),u(RC),u(Rd),u(fs),u(et))},e.\u0275prov=I({token:e,factory:e.\u0275fac});let i=e;return i})();var NC=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({providers:[{provide:Ad,useExisting:fs}],imports:[di.forFeature([AC])]});let i=e;return i})();var DC={backend:{occ:{endpoints:{cities:"countries/${country}/cities?fields=FULL",districtsAndPostcodesForCity:"countries/${country}/${city}?fields=FULL",addresses:"users/${userId}/addresses?fields=FULL",addressesPaginated:"users/${userId}/addresses/page?fields=FULL",geoinverse:"users/${userId}/addresses/mydataq/geoinverse",autoComplete:"users/${userId}/addresses/mydataq/autoComplete",getStateByPostalCode:"users/${userId}/addresses/mydataq/state",checkAddress:"users/${userId}/addresses/checkAddress",verification:"users/${userId}/addresses/verification",linkedPaymentInfos:"users/${userId}/addresses/${addressId}/paymentInfos"}}}};var FC=new St("OccAddressNormalizer");var LC=(()=>{let e=class e{convert(t,n){return t}};e.\u0275fac=function(n){return new(n||e)},e.\u0275prov=I({token:e,factory:e.\u0275fac,providedIn:"root"});let i=e;return i})();var jC=(()=>{let e=class e extends ad{geoInverseLocation(t,n,o){let s=this.occEndpoints.buildUrl("geoinverse",{urlParams:{userId:t},queryParams:{latitude:n,longitude:o}}),a=new an({});return t===Jt&&(a=Or.createHeader(Ir,!0,a)),this.http.get(s,{headers:a}).pipe(x(c=>this.converter.convert(c.suggestedAddresses??[],Qa)))}checkAddress(t,n){let o=this.occEndpoints.buildUrl("checkAddress",{urlParams:{userId:t},queryParams:{useSiteConfig:!0}}),s=new an({});return t===Jt&&(s=Or.createHeader(Ir,!0,s)),this.http.post(o,n,{headers:s}).pipe(x(a=>this.converter.convert(a.suggestedAddresses??[],Qa)))}update(t,n,o,s){let a=this.occEndpoints.buildUrl("addressDetail",{urlParams:{userId:t,addressId:n},queryParams:{addressType:s}});return o=this.converter.convert(o,sd),this.http.patch(a,o)}verifyAddress(t,n){let o=this.occEndpoints.buildUrl("verification",{urlParams:{userId:t}});return this.http.post(o,n).pipe(A(s=>s.decision==="REJECT"?sn(s.errors):D(s.address)))}getAutocompleteAddress(t,n,o){let s=this.occEndpoints.buildUrl("autoComplete",{urlParams:{userId:t},queryParams:R({dataToComplete:n},o)}),a=new an({});return t===Jt&&(a=Or.createHeader(Ir,!0,a)),this.http.get(s,{headers:a})}getStateByPostalCode(t,n,o){let s=this.occEndpoints.buildUrl("getStateByPostalCode",{urlParams:{userId:t},queryParams:{countryCode:n,postalCode:o}}),a=new an({});return t===Jt&&(a=Or.createHeader(Ir,!0,a)),this.http.get(s,{headers:a})}getCountries(){let t=this.occEndpoints.buildUrl("countries");return this.http.get(t).pipe(x(n=>n.countries))}getBillingCountries(){let t=this.occEndpoints.buildUrl("countries?type=BILLING");return this.http.get(t).pipe(x(n=>n.countries))}getShippingCountries(){let t=this.occEndpoints.buildUrl("countries?type=SHIPPING");return this.http.get(t).pipe(x(n=>n.countries))}getRegions(t){let n=this.occEndpoints.buildUrl("regions",{urlParam
40s:{isoCode:t}});return this.http.get(n).pipe(x(o=>o.regions))}getCities(t){let n=this.occEndpoints.buildUrl("cities",{urlParams:{country:t}});return this.http.get(n).pipe(x(o=>o.sortedCities))}getPostalCodesForCity(t,n){let o=this.occEndpoints.buildUrl("districtsAndPostcodesForCity",{urlParams:{country:t,city:n}});return this.http.get(o).pipe(x(s=>s.districtAndPostCodes))}loadAll(t,n,o){let s=this.occEndpoints.buildUrl("addresses",{urlParams:{userId:t},queryParams:{fields:n,addressType:o}});return this.http.get(s).pipe(x(a=>a.addresses||[]))}get(t,n,o,s=Jm.FULL){let a=this.occEndpoints.buildUrl("addressDetail",{urlParams:{userId:t,addressId:n},queryParams:{addressType:o,fields:s}});return this.http.get(a)}getLinkedPaymentInfos(t,n){let o={userId:t,addressId:n},s=this.occEndpoints.buildUrl("linkedPaymentInfos",{urlParams:o});return this.http.get(s)}getAddressesForPage(t,n,o){let s={userId:t},a=this.occEndpoints.buildUrl("addressesPaginated",{urlParams:s,queryParams:{page:n,addressType:o}});return this.http.get(a)}};e.\u0275fac=(()=>{let t;return function(o){return(t||(t=Le(e)))(o||e)}})(),e.\u0275prov=I({token:e,factory:e.\u0275fac,providedIn:"root"});let i=e;return i})();var $C=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({providers:[M(DC),{provide:kd,useClass:eh},{provide:cd,useClass:jC},{provide:FC,useExisting:LC,multi:!0}]});let i=e;return i})();var BC={backend:{occ:{endpoints:{navigationMenu:"/cms/navigationMenu"}}}};var UC=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({providers:[M(BC),nf]});let i=e;return i})();var zC=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({providers:[M({featureModules:{orderDetails:{cmsComponents:["AccountOrderDetailComponent"]}}}),M({featureModules:{orderDetails:{module:()=>import("./chunk-GC75T4LW.js").then(t=>t.SipOrderDetailsModule),dependencies:[vi]}}})]});let i=e;return i})();var GC=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({providers:[M({featureModules:{[Ka]:{module:()=>import("./chunk-EVCK2WXM.js").then(t=>t.SipCheckoutModule),dependencies:[ln]},[as]:Ka}})]});let i=e;return i})();var gr={TOP_BANNER:"top_banner",TOP_STRIP:"top_strip",BOTTOM_STRIP:"bottom_strip",BOTTOM_BANNER:"bottom_banner"};function R1(i,e){i&1&&He(0)}function A1(i,e){if(i&1){let r=Ve();B(0),S(1,"a",10),w(2,"async"),Ce("click",function(){ke(r);let n=C(2).ngIf,o=C();return Re((n==null||n.ga_ref==null?null:n.ga_ref[0])&&o.onClick(n.ga_ref[0]))}),v(3,R1,1,0,"ng-container",11),b(),U()}if(i&2){let r;C();let t=Y(6),n=C().ngIf,o=C();d(),l("ngClass",!(n==null||n.image==null)&&n.image.url?"":(r=n.ad_type)!==null&&r!==void 0?r:"full"),yt("href",o.showMobileImage&&(n!=null&&n.mobile_url)&&T(2,5,o.screenSizeService.isMobile$)?n==null?null:n.mobile_url:n==null||n.costco_url==null?null:n.costco_url.url,Ct)("title",n==null||n.costco_url==null?null:n.costco_url.title)("aria-describedby",o.describedByIds),d(2),l("ngTemplateOutlet",t)}}function N1(i,e){i&1&&He(0)}function D1(i,e){if(i&1&&(S(0,"div",12),v(1,N1,1,0,"ng-container",11),b()),i&2){let r;C();let t=Y(6),n=C().ngIf,o=C();l("ngClass",!(n==null||n.image==null)&&n.image.url?"":(r=n.ad_type)!==null&&r!==void 0?r:"full"),yt("aria-describedby",o.describedByIds),d(),l("ngTemplateOutlet",t)}}function F1(i,e){if(i&1&&P(0,"sip-cs-dynamic-component",18),i&2){let r=C().$implicit;l("componentInfo",r)}}function L1(i,e){if(i&1&&(B(0),v(1,F1,1,1,"sip-cs-dynamic-component",17),U()),i&2){let r=e.$implicit,t=C(4);d(),l("ngIf",r.add_text_banner.text_banner_type===t.TextBannerType.TOP_BANNER)}}function j1(i,e){if(i&1&&P(0,"sip-cs-dynamic-component",18),i&2){let r=C().$implicit;l("componentInfo",r)}}function $1(i,e){if(i&1&&(B(0),v(1,j1,1,1,"sip-cs-dynamic-component",17),U()),i&2){let r=e.$implicit,t=C(5);d(),l("ngIf",r.strip.strip_type===t.TextBannerType.TOP_STRIP)}}function B1(i,e){if(i&1&&P(0,"sip-image",27),i&2){let r=C(7).ngIf,t=C();l("ngClass",t.borderRadius)("src",r==null||r.image==null?null:r.
40image.url)("alt",r==null?null:r.image_alt_text)("fetchPriority",r==null?null:r.fetch_priority)}}function U1(i,e){if(i&1&&P(0,"sip-image",27),i&2){let r=C(7).ngIf,t=C();l("ngClass",t.borderRadius)("src",r==null||r.mobile_image==null?null:r.mobile_image.url)("alt",(r==null?null:r.use_mobile_image_alt_text)===!0?r==null?null:r.mobile_image_alt_text:"")("fetchPriority",r==null?null:r.fetch_priority)}}function z1(i,e){if(i&1&&(S(0,"video",28),P(1,"source",29),b()),i&2){let r=C(7).ngIf;co("title",r==null?null:r.image_alt_text),d(),co("src",r==null||r.image==null?null:r.image.url,Ct),co("type",r==null||r.image==null?null:r.image.content_type)}}function G1(i,e){if(i&1&&(S(0,"div",24),v(1,B1,1,4,"sip-image",25),w(2,"async"),v(3,U1,1,4,"sip-image",25),w(4,"async"),v(5,z1,2,3,"video",26),b()),i&2){let r=C(6).ngIf,t=C();d(),l("ngIf",(r==null||r.image==null?null:r.image.content_type.includes("image"))&&(t.showMobileImage?!T(2,3,t.screenSizeService.isMobile$):!0)),d(2),l("ngIf",(r==null?null:r.enable_mobile_image_variation)&&(r==null||r.mobile_image==null?null:r.mobile_image.url)&&T(4,5,t.screenSizeService.isMobile$)),d(2),l("ngIf",r==null||r.image==null?null:r.image.content_type.includes("video"))}}function H1(i,e){if(i&1&&(B(0),v(1,G1,6,7,"div",22),U()),i&2){let r=C(5).ngIf;d(),l("ngIf",(r==null||r.image==null?null:r.image.url)||(r==null||r.mobile_image==null?null:r.mobile_image.url))}}function V1(i,e){if(i&1&&(B(0),P(1,"sip-cs-dynamic-component",18),U()),i&2){let r=e.$implicit;d(),l("componentInfo",r)}}function q1(i,e){if(i&1&&(S(0,"div",24),v(1,V1,2,1,"ng-container",15),b()),i&2){let r=C(5).ngIf;d(),l("ngForOf",r==null?null:r.online_image_video)}}function W1(i,e){if(i&1&&(S(0,"div",38),H(1),b()),i&2){let r=C(2).$implicit;d(),le(" ",r.prices_and_percentages==null?null:r.prices_and_percentages.prepend_text," ")}}function K1(i,e){if(i&1&&(S(0,"div",39),H(1),b()),i&2){let r=C(2).$implicit;d(),le(" ",r.prices_and_percentages.value[0]," ")}}function Q1(i,e){if(i&1&&(S(0,"div",40),H(1),b()),i&2){let r=C(2).$implicit;d(),le(" ",r.prices_and_percentages==null?null:r.prices_and_percentages.append_text," ")}}function Y1(i,e){if(i&1&&(S(0,"div",34),v(1,W1,2,1,"div",35)(2,K1,2,1,"div",36)(3,Q1,2,1,"div",37),b()),i&2){let r=C().$implicit;Tt("color",r==null?null:r.prices_and_percentages.text_color),d(),l("ngIf",r.prices_and_percentages==null?null:r.prices_and_percentages.prepend_text),d(),l("ngIf",(r.prices_and_percentages==null?null:r.prices_and_percentages.value.length)>0),d(),l("ngIf",r.prices_and_percentages==null?null:r.prices_and_percentages.append_text)}}function Z1(i,e){if(i&1&&(S(0,"div",13),H(1),b()),i&2){let r=C().$implicit;Tt("color",r==null||r.content==null?null:r.content.text_color),l("ngClass",r==null||r.content==null?null:r.content.content_type),d(),le(" ",r==null||r.content==null?null:r.content.text," ")}}function X1(i,e){if(i&1&&(S(0,"div",41),H(1),b()),i&2){let r=C().$implicit;Tt("color",r==null||r.content==null?null:r.content.text_color),d(),le(" ",r==null||r.content==null?null:r.content.text," ")}}function J1(i,e){if(i&1&&(S(0,"div")(1,"button",42),H(2),b()()),i&2){let r=C().$implicit;d(),Tt("color",r==null||r.content==null?null:r.content.text_color),d(),le(" ",r==null||r.content==null?null:r.content.text," ")}}function eP(i,e){if(i&1&&(B(0),v(1,Y1,4,5,"div",31)(2,Z1,2,4,"div",32)(3,X1,2,3,"div",33)(4,J1,3,3,"div",4),U()),i&2){let r=e.$implicit;d(),l("ngIf",r==null||r.prices_and_percentages==null?null:r.prices_and_percentages.add_currency),d(),l("ngIf",(r==null||r.content==null?null:r.content.content_type)==="title"||(r==null||r.content==null?null:r.content.content_type)==="subtitle"),d(),l("ngIf",(r==null||r.content==null?null:r.content.content_type)==="url"),d(),l("ngIf",(r==null||r.content==null?null:r.content.content_type)==="button")}}function tP(i,e){if(i&1&&(S(0,"div",30),v(1,eP,5,4,"ng-container",15),b()),i&2){let r=C(5).ngIf,t=C();l("ngStyle",t.alignContent(r)),d(),l("ngForOf",r.text_content)}}function iP(i,e){if(i&1&&(S(0,"div",21),v(1,H1,2,1,"ng-container",4)(2,q1,2,1,"div",22)(3,tP,2,2,"div",23),b()),i&2){let r=C(4).ngIf,t=C();
40l("ngClass",t.bgClass(r)),d(),l("ngIf",r==null?null:r.is_image_video_from_assets),d(),l("ngIf",!(r!=null&&r.is_image_video_from_assets)),d(),l("ngIf",(r==null?null:r.text_content_placement)&&r.enable_text_content)}}function nP(i,e){if(i&1&&P(0,"sip-cs-dynamic-component",18),i&2){let r=C().$implicit;l("componentInfo",r)}}function rP(i,e){if(i&1&&(B(0),v(1,nP,1,1,"sip-cs-dynamic-component",17),U()),i&2){let r=e.$implicit,t=C(5);d(),l("ngIf",r.strip.strip_type===t.TextBannerType.BOTTOM_STRIP)}}function oP(i,e){if(i&1&&(S(0,"div",19),v(1,$1,2,1,"ng-container",15)(2,iP,4,4,"div",20)(3,rP,2,1,"ng-container",15),b()),i&2){let r=C(3).ngIf;d(),l("ngForOf",r.top_and_bottom_strip),d(),l("ngIf",(r==null?null:r.is_image_video_from_assets)&&(r==null||r.image==null?null:r.image.url)||(r==null||r.mobile_image==null?null:r.mobile_image.url)||!(r!=null&&r.is_image_video_from_assets)&&(r==null||r.online_image_video==null?null:r.online_image_video.length)>0||(r==null?null:r.text_content_placement)&&r.enable_text_content),d(),l("ngForOf",r.top_and_bottom_strip)}}function sP(i,e){if(i&1&&P(0,"sip-cs-dynamic-component",18),i&2){let r=C().$implicit;l("componentInfo",r)}}function aP(i,e){if(i&1&&(B(0),v(1,sP,1,1,"sip-cs-dynamic-component",17),U()),i&2){let r=e.$implicit,t=C(4);d(),l("ngIf",r.add_text_banner.text_banner_type===t.TextBannerType.BOTTOM_BANNER)}}function cP(i,e){if(i&1&&(S(0,"div",13)(1,"div",14),v(2,L1,2,1,"ng-container",15)(3,oP,4,3,"div",16)(4,aP,2,1,"ng-container",15),b()()),i&2){let r,t=C(2).ngIf;l("ngClass",(r=t.ad_type)!==null&&r!==void 0?r:"full"),d(2),l("ngForOf",t.top_and_bottom_text_banner),d(),l("ngIf",(t==null||t.top_and_bottom_strip==null?null:t.top_and_bottom_strip.length)>0||(t==null?null:t.is_image_video_from_assets)&&((t==null||t.image==null?null:t.image.url)||(t==null||t.mobile_image==null?null:t.mobile_image.url))||(t==null||t.online_image_video==null?null:t.online_image_video.length)>0||(t==null?null:t.text_content_placement)&&t.enable_text_content),d(),l("ngForOf",t.top_and_bottom_text_banner)}}function pP(i,e){if(i&1&&(S(0,"div",43),H(1),b()),i&2){let r=C(2).ngIf;l("id","disclaimer-tag-"+(r==null?null:r.uid)),d(),le(" ",r==null?null:r.disclaimer," ")}}function lP(i,e){if(i&1&&(S(0,"div",44),H(1),b()),i&2){let r,t=C(2).ngIf;d(),le(" ",(r=t==null?null:t.sponsored)!==null&&r!==void 0?r:"Sponsored"," ")}}function dP(i,e){if(i&1&&(P(0,"div",45),w(1,"safeHtml")),i&2){let r=C(2).ngIf;l("id","caption-tag-"+(r==null?null:r.uid))("innerHtml",T(1,2,r.caption),ye)}}function mP(i,e){if(i&1&&(B(0),v(1,A1,4,7,"ng-container",5),w(2,"async"),v(3,D1,2,3,"ng-template",null,0,ne)(5,cP,5,4,"ng-template",null,1,ne),S(7,"div",6),v(8,pP,2,2,"div",7)(9,lP,2,1,"div",8),b(),v(10,dP,2,4,"div",9),U()),i&2){let r=Y(4),t=C().ngIf,n=C();d(),l("ngIf",n.showMobileImage&&(t==null?null:t.mobile_url)&&T(2,5,n.screenSizeService.isMobile$)||(t==null||t.costco_url==null?null:t.costco_url.url))("ngIfElse",r),d(7),l("ngIf",t==null?null:t.enable_disclaimer),d(),l("ngIf",t==null?null:t.enable_sponsored),d(),l("ngIf",t.enable_caption)}}function uP(i,e){if(i&1&&(S(0,"div",3),v(1,mP,11,7,"ng-container",4),b()),i&2){let r=C();l("sipObserve",r.handleComponentVisible.bind(r)),d(),l("ngIf",r.showExpiryAdBuilder)}}var HC=(()=>{let e=class e{constructor(t,n,o,s,a,c){this.component=t,this.cd=n,this.elemRef=o,this.screenSizeService=s,this.sipGtmService=a,this.cookieService=c,this.subscriptions=new Ee,this.TextBannerType=gr,this.describedByIds="",this.borderRadius="",this.showExpiryAdBuilder=!0}handleComponentVisible(){this.subscriptions.add(this.component.data$.pipe(j(t=>!!t?.ga_ref?.[0]?.promotion_id),X()).subscribe(t=>{this.saveGtmEvent(t?.ga_ref[0],Kt.PROMOTION_IMPRESSIONS_VIEW)}))}saveGtmEvent(t,n){if(t?.promotion_id&&t?.promotion_enabled){let o={id:t.promotion_id,name:t.promotion_name,creative:t.promotion_creative,position:t.promotion_position,urlTarget:t.link_url};this.sipGtmService.pushPromotionImpressionEvent(o,n),this.sipGtmService.pushGA4ViewPromotionEvent(o)}}onClick(t){if(t?.promotion_id&&t?.promotion_enabled){let n={id:t.promotion_id,name:t.promotion_name,creative:t.promotion_creative,position:t.promotion_position,urlTarget:t.link_url};this.sipGtmService.pushGA4SelectPromotionEvent(n)}}ngOnInit(){this.component.data$.pipe(z(1),x(t=>{let n={};if(t?.enable_custom_background){let o=t?.background_group;t.background_group?.background_gradient_style!=="no-background"&&(n={bgColor:o?.background_color?.hex||"",color1:o?.background_gradient_color?.color1?.hex||"",color2:o?.background_gradient_color?.color2?.hex||""})}return t?.enable_mobile_image_variation&&(this.showMobileImage=!0),t?.enable_disclaimer&&(this.describedByIds+="disclaimer-tag-"+t?.uid),t?.enable_sponsored&&(this.describedByIds+=" sponsored-tag"),t?.enable_caption&&(this.describedByIds+=" caption-tag-"+t?.uid),(t?.image?.url||t?.mobile_image?.url)&&(this.borderRadius=this.applyBorderRadius(t)),t?.content_restriction?.length&&t.content_restriction[0]?.membership_expiry_fields?.enable_membership_expiry&&this.cookieService.get("dismissExpiryBanner")&&(this.showExpiryAdBuilder=!1),{colorValues:n}})).subscribe(t=>
40{this.colorValues=t.colorValues})}ngAfterViewInit(){this.colorValues?.bgColor?Bo(this.elemRef.nativeElement,"--bgColor",this.colorValues?.bgColor):this.colorValues?.color1&&this.colorValues?.color2&&(Bo(this.elemRef.nativeElement,"--color1",this.colorValues?.color1),Bo(this.elemRef.nativeElement,"--color2",this.colorValues?.color2)),this.cd.detectChanges()}alignContent(t){let n={};if(t?.text_content_overlay_styles.length>0){let o=t.text_content_overlay_styles[0];switch(o.overlay_style.text_alignment){case"bottom":n["justify-content"]="flex-end";break;case"middle":n["justify-content"]="center";break;case"center":n["align-items"]="center";break}switch(o.overlay_style.overlay_position){case"bottom":n["justify-content"]="flex-end";break;case"center":n["align-items"]="center";break;case"right":n["align-items"]="flex-end";break}}return n}bgClass(t){return t?.enable_custom_background&&!t?.image?.url?`has-bg ${t?.background_group?.background_gradient_style}`:""}applyBorderRadius(t){let n="all-rounded";if(Array.isArray(t?.top_and_bottom_strip)){let o=t?.top_and_bottom_strip.some(a=>a?.strip?.strip_type===gr.TOP_STRIP),s=t?.top_and_bottom_strip.some(a=>a?.strip?.strip_type===gr.BOTTOM_STRIP);o&&s?n="":o?n="bottom-rounded":s&&(n="top-rounded")}return"image "+n}ngOnDestroy(){this.subscriptions.unsubscribe()}};e.\u0275fac=function(n){return new(n||e)(O(ee),O(Ai),O(wt),O(tf),O(At),O(ei))},e.\u0275cmp=F({type:e,selectors:[["sip-ad-builder"]],decls:2,vars:3,consts:[["noLink",""],["adBuilderContent",""],["class","ad-builder",3,"sipObserve",4,"ngIf"],[1,"ad-builder",3,"sipObserve"],[4,"ngIf"],[4,"ngIf","ngIfElse"],[1,"bottom-container"],["class","disclaimer",3,"id",4,"ngIf"],["class","sponsored","id","sponsored-tag",4,"ngIf"],["class","caption",3,"id","innerHtml",4,"ngIf"],[1,"link",3,"click","ngClass"],[4,"ngTemplateOutlet"],[1,"link",3,"ngClass"],[3,"ngClass"],[1,"ad-builder-container"],[4,"ngFor","ngForOf"],["class","inner-container",4,"ngIf"],[3,"componentInfo",4,"ngIf"],[3,"componentInfo"],[1,"inner-container"],["class","ad-builder-section",3,"ngClass",4,"ngIf"],[1,"ad-builder-section",3,"ngClass"],["class","image-section",4,"ngIf"],["class","overlay-section",3,"ngStyle",4,"ngIf"],[1,"image-section"],[3,"ngClass","src","alt","fetchPriority",4,"ngIf"],["controls","","class","video-section",3,"title",4,"ngIf"],[3,"ngClass","src","alt","fetchPriority"],["controls","",1,"video-section",3,"title"],[3,"src","type"],[1,"overlay-section",3,"ngStyle"],["class","price",3,"color",4,"ngIf"],[3,"ngClass","color",4,"ngIf"],["class","btn-link",3,"color",4,"ngIf"],[1,"price"],["class","prepend",4,"ngIf"],["class","price-value",4,"ngIf"],["class","append",4,"ngIf"],[1,"prepend"],[1,"price-value"],[1,"append"],[1,"btn-link"],[1,"btn-overlay"],[1,"disclaimer",3,"id"],["id","sponsored-tag",1,"sponsored"],[1,"caption",3,"id","innerHtml"]],template:function(n,o){n&1&&(v(0,uP,2,2,"div",2),w(1,"async")),n&2&&l("ngIf",T(1,1,o.component.data$))},dependencies:[Ie,qe,W,ci,Vt,Dn,cs,Wi,q,ut],styles:[".ad-builder[_ngcontent-%COMP%]{display:flex;flex-direction:column}.ad-builder[_ngcontent-%COMP%] a.link[_ngcontent-%COMP%], .ad-builder[_ngcontent-%COMP%] a.link[_ngcontent-%COMP%]:hover, .ad-builder[_ngcontent-%COMP%] a.link[_ngcontent-%COMP%]:visited{text-decoration:none}.ad-builder[_ngcontent-%COMP%] .ad-builder-section[_ngcontent-%COMP%]{display:grid;grid-template-columns:1fr;width:100%;grid-area:1 / 1;position:relative;flex:1 1 0%}.ad-builder[_ngcontent-%COMP%] .ad-builder-section.has-bg[_ngcontent-%COMP%]{min-height:343px}.ad-builder[_ngcontent-%COMP%] .ad-builder-section.linear[_ngcontent-%COMP%]{background-color:var(--color2);background:-webkit-gradient(linear,left top,left bottom,from(var(--color1)),to(var(--color2)));background:-webkit-linear-gradient(var(--color1),var(--color2));background:-moz-linear-gradient(var(--color1),var(--color2));background:-o-linear-gradient(var(--color1),var(--color2));background:-ms-linear-gradient(var(--color1),var(--color2));background:linear-gradient(var(--color1),var(--color2))}.ad-builder[_ngcontent-%COMP%] .ad-builder-section.radial[_ngcontent-%COMP%]{background-color:var(--color2);background:-webkit-gradient(radial,left top,left bottom,from(var(--color1)),to(var(--color2)));background:-webkit-radial-gradient(var(--color1),var(--color2));background:-moz-radial-gradient(var(--color1),var(--color2));background:-o-radial-gradient(var(--color1),var(--color2));background:-ms-radial-gradient(var(--color1),var(--color2));background:radial-gradient(var(--color1),var(--color2))}.ad-builder[_ngcontent-%COMP%] .ad-builder-section.solid[_ngcontent-%COMP%]{background-color:var(--bgColor)}.ad-builder[_ngcontent-%COMP%] .ad-builder-section[_ngcontent-%COMP%] .image-section[_ngcontent-%COMP%], .ad-builder[_ngcontent-%COMP%] .ad-builder-section[_ngcontent-%COMP%] .video-section[_ngcontent-%COMP%]{grid-area:1 / 1;height:auto;width:100%}.ad-builder[_ngcontent-%COMP%] .ad-builder-section[_ngcontent-%COMP%] .overlay-section[_ngcontent-%COMP%]{position:relative;display:flex;grid-area:1 / 1;height:auto;width:100%;flex:0 1 0%;flex-direction:column;justify-content:flex-start;align-items:flex-start;opacity:1;padding-top:16px;padding-left:16px}.ad-builder[_ngcontent-%COMP%] .ad-builder-section[_ngcontent-%COMP%] .overlay-section[_ngcontent-%COMP%] .price[_ngcontent-%COMP%]{padding:8px 0;font-weight:700;display:flex;align-items:flex-start}.ad-builder[_ngcontent-%COMP%] .ad-builder-section[_ngcontent-%COMP%] .overlay-section[_ngcontent-%COMP%] .price[_ngcontent-%COMP%] .prepend[_ngcontent-%COMP%], .ad-builder[_ngcontent-%COMP%] .ad-builder-section[_ngcontent-%COMP%] .overlay-section[_ngcontent-%COMP%] .price[_ngcontent-%COMP%] .append[_ngcontent-%COMP%]{font-size:18px;line-height:16px;vertical-align:top}.ad-builder[_ngcontent-%COMP%] .ad-builder-section[_ngcontent-%COMP%] .overlay-section[_ngcontent-%COMP%] .price[_ngcontent-%COMP%] .price-value[_ngcontent-%COMP%]{font-size:28px;line-height:22px}.ad-builder[_ngcontent-%COMP%] .ad-builder-section[_ngcontent-%COMP%] .overlay-section[_ngcontent-%COMP%] .title[_ngcontent-%COMP%]{font-weight:400;font-size:24px;line-height:28px;padding:4px 0}.ad-builder[_ngcontent-%COMP%] .ad-builder-section[_ngcontent-%COMP%] .overlay-section[_ngcontent-%COMP%] .subtitle[_ngcontent-%COMP%]{font-weight:400;font-size:14px;line-height:1.5}.ad-builder[_ngcontent-%COMP%] .ad-builder-section[_ngcontent-%COMP%] .overlay-section[_ngcontent-%COMP%] .btn-link[_ngcontent-%COMP%]{margin-top:8px;font-weight:400;text-decoration-line:underline;padding:10px 0;font-size:14px;line-height:1.3}.ad-builder[_ngcontent-%COMP%] .ad-builder-section[_ngcontent-%COMP%] .overlay-section[_ngcontent-%COMP%] .btn-overlay[_ngcontent-%COMP%]{margin-top:8px;padding:3px 16px 5px;border-radius:3px;font-weight:500;font-size:12px!important;line-height:1.3!important;letter-spacing:.2px;min-height:auto!important;height:auto;background:#005dab;outline:none;border:none}@media screen and (min-width: 768px) and (max-width: 1023px){.ad-builder[_ngcontent-%COMP%] .ad-builder-section[_ngcontent-%COMP%] .overlay-section.has-bg[_ngcontent-%COMP%]{min-height:736px}.ad-builder[_ngcontent-%COMP%] .ad-builder-section[_ngcontent-%COMP%] .overlay-section[_ngcontent-%COMP%] .title[_ngcontent-%COMP%]{margin-bottom:8px}}@media screen and (min-width: 1024px){.ad-builder[_ngcontent-%COMP%] .ad-builder-section[_ngcontent-%COMP%] .overlay-section[_ngcontent-%COMP%]{padding:32px 48px}.ad-builder[_ngcontent-%COMP%] .ad-builder-section[_ngcontent-%COMP%] .overlay-section.has-bg[_ngcontent-%COMP%]{min-height:249px}.ad-builder[_ngcontent-%COMP%] .ad-builder-section[_ngcontent-%COMP%] .overlay-section[_ngcontent-%COMP%] .price[_ngcontent-%COMP%] .price-value[_ngcontent-%COMP%]{font-size:40px;line-height:32px}.ad-builder[_ngcontent-%COMP%] .ad-builder-section[_ngcontent-%COMP%] .overlay-section[_ngcontent-%COMP%] .title[_ngcontent-%COMP%]{font-size:42px;line-height:1.3;margin-bottom:12px}.ad-builder[_ngcontent-%COMP%] .ad-builder-section[_ngcontent-%COMP%] .overlay-section[_ngcontent-%COMP%] .subtitle[_ngcontent-%COMP%]{font-size:22px;line-height:1.3}.ad-builder[_ngcontent-%COMP%] .ad-builder-section[_ngcontent-%COMP%] .overlay-section[_ngcontent-%COMP%] .btn-link[_ngcontent-%COMP%]{font-size:16px}.ad-builder[_ngcontent-%COMP%] .ad-builder-section[_ngcontent-%COMP%] .overlay-section[_ngcontent-%COMP%] .btn-overlay[_ngcontent-%COMP%]{margin-top:12px;padding:10px 16px;font-size:16px!important;line-height:1.3!important;min-height:40px!important;letter-spacing:0px}}.ad-builder[_ngcontent-%COMP%] .image[_ngcontent-%COMP%]{object-fit:contain;grid-area:1 / 1;height:auto;width:100%;display:block}.ad-builder[_ngcontent-%COMP%] .image.all-rounded[_ngcontent-%COMP%] img{border-radius:10px}.ad-builder[_ngcontent-%COMP%] .image.top-rounded[_ngcontent-%COMP%] img{border-top-right-radius:10px;border-top-left-radius:10px}.ad-builder[_ngcontent-%COMP%] .image.bottom-rounded[_ngcontent-%COMP%] img{border-bottom-left-radius:10px;border-bottom-right-radius:10px}.ad-builder[_ngcontent-%COMP%] .image[_ngcontent-%COMP%] img{object-fit:contain;grid-area:1 / 1;height:auto;width:100%;display:block}.ad-builder[_ngcontent-%COMP%] .ad-builder-container[_ngcontent-%COMP%]{position:relative;gap:16px;display:flex;flex-direction:column}.ad-builder[_ngcontent-%COMP%] .bottom-container[_ngcontent-%COMP%]{align-items:flex-start;align-self:stretch;display:flex;gap:16px;justify-content:space-between;padding:0 16px}.ad-builder[_ngcontent-%COMP%] .bottom-container[_ngcontent-%COMP%] .disclaimer[_ngcontent-%COMP%], .ad-builder[_ngcontent-%COMP%] .bottom-container[_ngcontent-%COMP%] .sponsored[_ngcontent-%COMP%]{font-size:12px;line-height:18px;font-weight:400}.ad-builder[_ngcontent-%COMP%] .bottom-container[_ngcontent-%COMP%] .disclaimer[_ngcontent-%COMP%]{word-break:break-word}.ad-builder[_ngcontent-%COMP%] .full[_ngcontent-%COMP%]{flex-grow:1}.ad-builder[_ngcontent-%COMP%] .half[_ngcontent-%COMP%]{flex:1 1 calc(50% - 24px)}.ad-builder[_ngcontent-%COMP%] .one_third[_ngcontent-%COMP%]{flex:1 1 calc(25% - 24px)}.ad-builder[_ngcontent-%COMP%] .one_fourth[_ngcontent-%COMP%]{flex:1 1 calc(75% - 24px)}@media screen and (min-width: 768px) and (max-width: 1023px){.ad-builder[_ngcontent-%COMP%] .full[_ngcontent-%COMP%]{flex-grow:1}.ad-builder[_ngcontent-%COMP%] .half[_ngcontent-%COMP%], .ad-builder[_ngcontent-%COMP%] .one_third[_ngcontent-%COMP%], .ad-builder[_ngcontent-%COMP%] .one_fourth[_ngcontent-%COMP%]{flex-grow:0}}@media screen and (min-width: 1024px){.ad-builder[_ngcontent-%COMP%] .full[_ngcontent-%COMP%]{flex-grow:1}.ad-builder[_ngcontent-%COMP%] .half[_ngcontent-%COMP%], .ad-builder[_ngcontent-%COMP%] .one_third[_ngcontent-%COMP%], .ad-builder[_ngcontent-%COMP%] .one_fourth[_ngcontent-%COMP%]{flex-grow:0}}"],changeDetection:0});let i=e;return i})();var VC=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({providers:[M({cmsComponents:{SipAdBuilderComponent:{component:HC}}})],imports:[$,Fn,Ae,ms,Ki]});let i=e;return i})();var gP=(i,e)=>({border:i,"border-color":e}),_P=i=>({"left-align":i}),CP=(i,e)=>({background:i,"background-color":e}),yP=(i,e,r,t)=>
40({"category-content-multi-row":i,"category-content-four-corner":e,"tablet-4 mobile-3":r,"tablet-8 mobile-4":t}),vP=(i,e)=>({"grid-template-columns":i,"background-color":e});function SP(i,e){if(i&1&&(S(0,"a",5),H(1," See All "),S(2,"div",6),P(3,"mat-icon",7),b()()),i&2){let r=C();l("href",r.data$==null||r.data$.ad_set_heading_and_costco_url==null?null:r.data$.ad_set_heading_and_costco_url.url,Ct),d(3),l("fontIcon",r.SipCostcoIcon.CHEVRON_RIGHT)}}function bP(i,e){if(i&1&&(S(0,"div",8),P(1,"sip-category",9),b()),i&2){let r=e.$implicit,t=C();d(),l("data$",r)("backgroundColor",t.data$.category_content.background_color)("imageFormFactor",t.data$.category_content.image_form_factor)}}var ua=(()=>{let e=class e{constructor(t,n){this.component=t,this.colorUtils=n,this.StaticDisplayStyle=tc,this.categoriesPerRow=5,this.displayStyle=tc.MULTI_ROW,this.categoryFourSquareBackgroundColorDefault="#EEEEEE",this.SipCostcoIcon=zn}ngOnInit(){this.data$?.static_options?.maximum_number_of_tiles_per_row&&(this.categoriesPerRow=this.data$.static_options.maximum_number_of_tiles_per_row),this.data$?.static_options?.display_style&&(this.displayStyle=this.data$.static_options.display_style),this.headerTransparentValue=parseFloat(this.data$.ad_set_background.title_background_transparency),this.bodyTransparentValue=parseFloat(this.data$.ad_set_background.body_background_transparency),this.data$.custom_background?(this.rgbaHeaderColor=this.colorUtils.hexToRgba(this.data$.ad_set_background.title_background_color.toString(),this.headerTransparentValue),this.rgbaBodyColor=this.colorUtils.hexToRgba(this.data$.ad_set_background.body_background_color.toString(),this.bodyTransparentValue),this.rgbaBodyBorderColor=this.colorUtils.hexToRgba(this.data$.ad_set_background.body_background_color.toString(),this.bodyTransparentValue)):(this.rgbaHeaderColor=this.colorUtils.hexToRgba("#EEEEEE",this.headerTransparentValue),this.rgbaBodyColor=this.colorUtils.hexToRgba("#FAFAFA",this.bodyTransparentValue),this.rgbaBodyBorderColor=this.colorUtils.hexToRgba("#EEEEEE",this.bodyTransparentValue))}};e.\u0275fac=function(n){return new(n||e)(O(ee),O(Cs))},e.\u0275cmp=F({type:e,selectors:[["sip-category-multi-row-or-four-square"]],inputs:{data$:"data$"},decls:7,vars:24,consts:[[1,"category-content-container",3,"ngStyle"],[1,"header",3,"ngClass","ngStyle"],["class","see-all",3,"href",4,"ngIf"],[1,"category-content",3,"ngClass","ngStyle"],["class","item",4,"ngFor","ngForOf"],[1,"see-all",3,"href"],[1,"chevron"],["aria-hidden","true","aria-label","see all swipe",3,"fontIcon"],[1,"item"],[3,"data$","backgroundColor","imageFormFactor"]],template:function(n,o){n&1&&(S(0,"div",0)(1,"div",1)(2,"p"),H(3),b(),v(4,SP,4,2,"a",2),b(),S(5,"div",3),v(6,bP,2,3,"div",4),b()()),n&2&&(l("ngStyle",xn(8,gP,o.displayStyle===o.StaticDisplayStyle.FOUR_CORNER?"1px solid "+o.categoryFourSquareBackgroun
40dColorDefault:"",o.rgbaBodyBorderColor)),d(),l("ngClass",ve(11,_P,(o.data$==null?null:o.data$.category_content.category_set_title_alignment)==="left"))("ngStyle",xn(13,CP,o.displayStyle===o.StaticDisplayStyle.FOUR_CORNER?o.categoryFourSquareBackgroundColorDefault:"",o.rgbaHeaderColor)),d(2),Be(o.data$==null||o.data$.ad_set_heading_and_costco_url==null?null:o.data$.ad_set_heading_and_costco_url.title),d(),l("ngIf",o.displayStyle===o.StaticDisplayStyle.FOUR_CORNER&&(o.data$==null?null:o.data$.category_content.category_set_title_alignment)==="left"),d(),l("ngClass",po(16,yP,o.displayStyle===o.StaticDisplayStyle.MULTI_ROW,o.displayStyle===o.StaticDisplayStyle.FOUR_CORNER,o.displayStyle===o.StaticDisplayStyle.MULTI_ROW&&o.categoriesPerRow<=5,o.displayStyle===o.StaticDisplayStyle.MULTI_ROW&&o.categoriesPerRow>5))("ngStyle",xn(21,vP,o.displayStyle===o.StaticDisplayStyle.MULTI_ROW?"repeat("+o.categoriesPerRow+", 1fr)":"",o.rgbaBodyColor)),d(),l("ngForOf",o.data$.category_content.category_items))},dependencies:[Ie,qe,W,Vt,ys,zi],styles:[".category-content-container[_ngcontent-%COMP%]{width:100%;min-width:175px;height:auto;border-radius:10px;box-sizing:border-box;overflow:hidden;gap:16px}.category-content-container[_ngcontent-%COMP%] .header[_ngcontent-%COMP%]{display:flex;justify-content:center;padding:8px 16px;text-align:center}.category-content-container[_ngcontent-%COMP%] .header.left-align[_ngcontent-%COMP%]{justify-content:space-between}.category-content-container[_ngcontent-%COMP%] .header[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{font-size:24px;font-weight:700;color:#000}.category-content-container[_ngcontent-%COMP%] .header[_ngcontent-%COMP%] .see-all[_ngcontent-%COMP%]{color:#000;text-decoration:none;display:flex;align-items:center}.category-content-container[_ngcontent-%COMP%] .header[_ngcontent-%COMP%] .see-all[_ngcontent-%COMP%]:hover{text-decoration:underline}.category-content-container[_ngcontent-%COMP%] .header[_ngcontent-%COMP%] .see-all[_ngcontent-%COMP%] .chevron[_ngcontent-%COMP%]{margin-left:8px;display:flex;align-items:center}.category-content-container[_ngcontent-%COMP%] .category-content[_ngcontent-%COMP%]{display:grid;grid-auto-rows:1fr;padding-top:16px;gap:16px 16px;margin:0;padding-bottom:16px}.category-content-container[_ngcontent-%COMP%] .category-content-multi-row[_ngcontent-%COMP%]{grid-template-columns:repeat(5,1fr)}@media screen and (min-width: 768px) and (max-width: 1023px){.category-content-container[_ngcontent-%COMP%] .category-content-multi-row.tablet-4[_ngcontent-%COMP%]{grid-template-columns:repeat(4,1fr)!important}.category-content-container[_ngcontent-%COMP%] .category-content-multi-row.tablet-8[_ngcontent-%COMP%]{grid-template-columns:repeat(8,1fr)!important}}@media screen and (max-width: 767px){.category-content-container[_ngcontent-%COMP%] .category-content-multi-row.mobile-3[_ngcontent-%COMP%]{grid-template-columns:repeat(3,1fr)!important}.category-content-container[_ngcontent-%COMP%] .category-content-multi-row.mobile-4[_ngcontent-%COMP%]{grid-template-columns:repeat(4,1fr)!important}}.category-content-container[_ngcontent-%COMP%] .category-content-four-corner[_ngcontent-%COMP%]{grid-template-columns:repeat(2,1fr)}.category-content-container[_ngcontent-%COMP%] .category-content[_ngcontent-%COMP%] .item[_ngcontent-%COMP%]{display:flex;flex-direction:column;align-items:center;justify-content:flex-start;margin:0;border:none}.category-content-container[_ngcontent-%COMP%] .category-content-multi-row[_ngcontent-%COMP%] .item[_ngcontent-%COMP%]{min-width:0}.category-content-container[_ngcontent-%COMP%] .category-content-multi-row[_ngcontent-%COMP%] .item[_ngcontent-%COMP%] sip-category[_ngcontent-%COMP%]{width:100%}"],changeDetection:0});let i=e;return i})();var PP=i=>({"left-align":i}),WC=i=>({"background-color":i}),MP=i=>({"background-color":i,"padding-top":"16px"}),EP=i=>({"two-row":i});function IP(i,e){if(i&1&&(S(0,"a",7),H(1," See All "),S(2,"div",8),P(3,"mat-icon",9),b()()),i&2){let r=C();l("href",r.data$==null||r.data$.ad_set_heading_and_costco_url==null?null:r.data$.ad_set_heading_and_costco_url.url,Ct),d(3),l("fontIcon",r.SipCostcoIcon.CHEVRON_RIGHT)}}function OP(i,e){if(i&1&&P(0,"sip-category",14),i&2){let r=C(2).index,t=C(2);l("data$",t.data$.category_content.category_items[r*2])("backgroundColor",t.data$.category_content.background_color)("imageFormFactor",t.data$.category_content.image_form_factor)}}function wP(i,e){if(i&1&&P(0,"sip-category",14),i&2){let r=C(2).index,t=C(2);l("data$",t.data$.category_content.category_items[r*2+1])("backgroundColor",t.data$.category_content.background_color)("imageFormFactor",t.data$.category_content.image_form_factor)}}function TP(i,e){if(i&1&&(S(0,"div")(1,"div",12),v(2,OP,1,3,"sip-category",13)(3,wP,1,3,"sip-category",13),b()()),i&2){let r=C().index,t=C(2);d(2),l("ngIf",r*2<t.data$.category_content.category_items.length),d(),l("ngIf",r*2+1<t.data$.category_content.category_items.length)}}function kP(i,e){if(i&1&&(S(0,"div",12),P(1,"sip-category",14),b()),i&2){let r=C().item,t=C(2);d(),l("data$",r)("backgroundColor",t.data$.category_content.background_color)("imageFormFactor",t.data$.category_content.image_form_factor)}}function RP(i,e){if(i&1&&v(0,TP,4,2,"div",6)(1,kP,2,3,"ng-template",null,2,ne),i&2){let r=Y(2),t=C(2);l("ngIf",t.data$.rotating_options.enable_two_row_display)("ngIfElse",r)}}function AP(i,e){if(i&1&&(B(0),S(1,"div",10),P(2,"sip-carousel",11),v(3,RP,3,2,"ng-template",null,1,ne),b(),U()),i&2){let r=Y(4),t=C();d(),l("ngStyle",ve(4,MP,t.rgbaBodyColor)),d(),l("items",t.data$.rotating_options.enable_two_row_display?t.data$.category_content.category_items.slice(0,t.data$.category_content.category_items.length/2):t.data$.category_content.category_items)("template",r)("options",t.options)}}function NP(i,e){if(i&1&&(S(0,"div",12),P(1,"sip-category",14),b()),i&2){let r=e.$implicit,t=C(2);d(),l("data$",r)("backgroundColor",t.data$.category_content.background_color)("imageFormFactor",t.data$.category_content.image_form_factor)}}function DP(i,e){if(i&1&&(S(0,"div",15),v(1,NP,2,3,"div",16),b()),i&2){let r=C();l("ngClass",ve(3,EP,r.data$.rotating_options.enable_two_row_display))("ngStyle",ve(5,WC,r.rgbaBodyColor)),d(),l("ngForOf",r.data$.category_content.category_items)}}var fa=(()=>{let e=class e{constructor(t,n,o,s,a){this.component=t,this.renderer=n,this.cdr=o,this.colorUtils=s,this.document=a,this.options={loop:!1,rewind:!0,autoplay:!1,navSpeed:200,autoplaySpeed:500,autoplayTimeout:4e3,dots:!0,responsive:{[ot.sm]:{items:3,slideBy:"page"},[ot.md-48]:{items:4,slideBy:"page"},[ot.lg-48]:{items:5,slideBy:"page"}},showPausePlayButtons:!1,showMatIcons:!0},this.breakpoints={sm:{min:ot.sm,max:ot.md-1,threshold:3},md:{min:ot.md,max:ot.lg-1,threshold:4},lg:{min:ot.lg,threshold:5}},this.SipCostcoIcon=zn}ngOnInit(){this.setCurrentBreakpoint(),this.resizeListener=this.renderer.listen("window","resize",this.setCurrentBreakpoint.bind(this)),this.headerTransparentValue=parseFloat(this.data$.ad_set_background.title_background_transparency),this.bodyTransparentValue=parseFloat(this.data$.ad_set_background.title_background_transparency),this.data$.custom_background?(this.rgbaHeaderColor=this.colorUtils.hexToRgba(this.data$.ad_set_background.title_background_color.toString(),this.headerTransparentValue),this.rgbaBodyColor=this.colorUtils.hexToRgba(this.data$.ad_set_background.body_background_color.toString(),this.bodyTransparentValue)):(this.rgbaHeaderColor=this.colorUtils.hexToRgba("#FFFFFF",this.headerTransparentValue),this.rgbaBodyColor=this.colorUtils.hexToRgba("#FFFFFF",this.bodyTransparentValue)),this.options.autoplay=this.data$.rotating_options.enable_autoplay,this.options.showPausePlayButtons=this.data$.rotating_options.enable_autoplay;let t=this.data$.rotating_options.multi_item_carousel?"page":1;this.options.slideBy=t,this.options.responsive={[ot.sm]:{items:3,slideBy:t},[ot.md-48]:{items:4,slideBy:t},[ot.lg-48]:{items:5,slideBy:t}}}ngOnDestroy(){this.resizeListener&&this.resizeListener()}setCurrentBreakpoint(){let t=this.document.documentElement.clientWidth;for(let[n,o]of Object.entries(this.breakpoints))if((o.min===void 0||t>=o.min)&&(!("max"in o)||t<=o.max)){this.currentBreakpoint=n;break}this.cdr.markForCheck()}getThreshold(){let t=this.breakpoints[this.currentBreakpoint]?.threshold||0;return this.data$.rotating_options.enable_two_row_display?t*2:t}};e.\u0275fac=function(n){return new(n||e)(O(ee),O(bn),O(Ai),O(Cs),O(bt))},e.\u0275cmp=F({type:e,selectors:[["sip-category-set"]],inputs:{data$:"data$"},decls:8,vars:10,consts:[["normalView",""],["categoryTpl",""],["singleItem",""],[1,"category-content-container"],[1,"header",3,"ngClass","ngStyle"],["class","see-all",3,"href",4,"ngIf"],[4,"ngIf","ngIfElse"],[1,"see-all",3,"href"],[1,"chevron"],["aria-hidden","true","aria-label","see all swipe",3,"fontIcon"],[1,"mat-carousel",3,"ngStyle"],[3,"items","template","options"],[1,"item"],[3,"data$","backgroundColor","imageFormFactor",4,"ngIf"],[3,"data$","backgroundColor","imageFormFactor"],[1,"category-content-set",3,"ngClass","ngStyle"],["class","item",4,"ngFor","ngForOf"]],template:function(n,o){if(n&1&&(S(0,"div",3)(1,"div",4)(2,"p"),H(3),b(),v(4,IP,4,2,"a",5),b(),v(5,AP,5,6,"ng-container",6)(6,DP,2,7,"ng-template",null,0,ne),b()),n&2){let s=Y(7);d(),l("ngClass",ve(6,PP,(o.data$==null?null:o.data$.category_content.category_set_title_alignment)==="left"))("ngStyle",ve(8,WC,o.rgbaHeaderColor)),d(2),Be(o.data$==null||o.data$.ad_set_heading_and_costco_url==null?null:o.data$.ad_set_heading_and_costco_url.title),d(),l("ngIf",(o.data$==null?null:o.data$.category_content.category_set_title_alignment)==="left"),d(),l("ngIf",o.data$.category_content.category_items.length>o.getThreshold())("ngIfElse",s)}},dependencies:[Ie,qe,W,Vt,ys,Zn,zi],styles:[".category-content-container[_ngcontent-%COMP%]{width:100%;min-width:175px;height:auto;border-radius:10px;gap:16px}.category-content-container[_ngcontent-%COMP%] .header[_ngcontent-%COMP%]{display:flex;justify-content:center;background:#fff;padding:8px 16px;text-align:center}.category-content-container[_ngcontent-%COMP%] .header.left-align[_ngcontent-%COMP%]{justify-content:space-between}.category-content-container[_ngcontent-%COMP%] .header[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{font-size:24px;font-weight:700;color:#000}.category-content-container[_ngcontent-%COMP%] .header[_ngcontent-%COMP%] .see-all[_ng
40content-%COMP%]{color:#000;text-decoration:none;display:flex;align-items:center}.category-content-container[_ngcontent-%COMP%] .header[_ngcontent-%COMP%] .see-all[_ngcontent-%COMP%]:hover{text-decoration:underline}.category-content-container[_ngcontent-%COMP%] .header[_ngcontent-%COMP%] .see-all[_ngcontent-%COMP%] .chevron[_ngcontent-%COMP%]{margin-left:8px;display:flex;align-items:center}.category-content-container[_ngcontent-%COMP%] .category-content-set[_ngcontent-%COMP%]{display:grid;gap:16px;grid-template-columns:repeat(3,1fr);padding-top:16px}.category-content-container[_ngcontent-%COMP%] .category-content-set.two-row[_ngcontent-%COMP%]{grid-template-rows:repeat(2,1fr)}@media screen and (min-width: 767px){.category-content-container[_ngcontent-%COMP%] .category-content-set[_ngcontent-%COMP%]{grid-template-columns:repeat(3,1fr)}}@media screen and (min-width: 768px) and (max-width: 1023px){.category-content-container[_ngcontent-%COMP%] .category-content-set[_ngcontent-%COMP%]{grid-template-columns:repeat(4,1fr)}}@media screen and (min-width: 1024px){.category-content-container[_ngcontent-%COMP%] .category-content-set[_ngcontent-%COMP%]{grid-template-columns:repeat(5,1fr)}}"],changeDetection:0});let i=e;return i})();var LP=(i,e,r,t)=>({"background-color":i,"background-image":e,"background-position":r,"border-radius":t}),jP=i=>({"horizontal-alignment":i}),tn=i=>({data:i}),$P=(i,e)=>({data:i,layout:e});function BP(i,e){if(i&1&&(S(0,"div",22),H(1),b()),i&2){let r=C().$implicit;Tt("color",r==null||r.content==null?null:r.content.text_color),l("ngClass",r==null||r.content==null?null:r.content.content_type),d(),le(" ",r==null||r.content==null?null:r.content.text," ")}}function UP(i,e){if(i&1&&(B(0),v(1,BP,2,4,"div",21),U()),i&2){let r=e.$implicit;d(),l("ngIf",(r==null||r.content==null?null:r.content.content_type)==="title"||(r==null||r.content==null?null:r.content.content_type)==="subtitle")}}function zP(i,e){if(i&1){let r=Ve();S(0,"div")(1,"button",24),Ce("click",function(){ke(r);let n=C(2).ngIf,o=C(2);return Re(o.backgroundButtonClick(n==null||n.background_banner_reference==null||n.background_banner_reference[0]==null||n.background_banner_reference[0].costco_url==null?null:n.background_banner_reference[0].costco_url.url))}),H(2),b()()}if(i&2){let r=C().$implicit,t=C().ngIf;d(),Tt("color",r==null||r.content==null?null:r.content.text_color),yt("aria-label",(r==null||r.content==null?null:r.content.text)+(!(t==null||t.background_banner_reference==null||t.background_banner_reference[0]==null||t.background_banner_reference[0].costco_url==null)&&t.background_banner_reference[0].costco_url.url?", link":"")),d(),le(" ",r==null||r.content==null?null:r.content.text," ")}}function GP(i,e){if(i&1&&(B(0),v(1,zP,3,4,"div",23),U()),i&2){let r=e.$implicit;d(),l("ngIf",(r==null||r.content==null?null:r.content.content_type)==="button")}}function HP(i,e){if(i&1&&P(0,"sip-cs-dynamic-component",26),i&2){let r=C().$implicit;l("componentInfo",r)}}function VP(i,e){if(i&1&&(B(0),v(1,HP,1,1,"sip-cs-dynamic-component",25),U()),i&2){let r=e.$implicit;d(),l("ngIf",r)}}function qP(i,e){i&1&&He(0)}function WP(i,e){if(i&1&&P(0,"sip-cs-dynamic-component",28),i&2){let r=C().$implicit;l("componentInfo",r)}}function KP(i,e){if(i&1&&(B(0),v(1,WP,1,1,"sip-cs-dynamic-component",27),U()),i&2){let r=e.$implicit,t=C(3);d(),l("ngIf",r.strip.strip_type===t.TextBannerType.BOTTOM_STRIP)}}function QP(i,e){if(i&1&&(B(0),S(1,"div",14),w(2,"optimizedImage"),S(3,"div",15)(4,"div",16),v(5,UP,2,1,"ng-container",17),b(),S(6,"div",18),v(7,GP,2,1,"ng-container",17),b()(),S(8,"div",19),v(9,VP,2,1,"ng-container",17),b(),v(10,qP,1,0,"ng-container",20),b(),v(11,KP,2,1,"ng-container",17),U()),i&2){let r=e.ngIf;C();let t=Y(4),n=C();d(),l("ngStyle",po(9,LP,n.computeBackgroundColor(r==null||r.background_banner_reference==null||r.background_banner_reference[0]==null?null:r.background_banner_reference[0].background_group),!(r==null||r.background_banner_reference==null||r.background_banner_reference[0]==null||r.background_banner_reference[0].image==null)&&r.background_banner_reference[0].image.url?"url("+T(2,7,r==null||r.background_banner_reference==null||r.background_banner_reference[0]==null||r.background_banner_reference[0].image==null?null:r.background_banner_reference[0].image.url)+")":"none",n.getBackgroun
40dPosition(r==null?null:r.background_banner_image_alignment),n.getBorderRadius(r==null||r.background_banner_reference==null||r.background_banner_reference[0]==null?null:r.background_banner_reference[0].top_and_bottom_strip))),d(2),l("ngClass",ve(14,jP,(r==null?null:r.background_banner_button_alignment)==="Horizontal")),d(2),l("ngForOf",r==null||r.background_banner_reference==null||r.background_banner_reference[0]==null?null:r.background_banner_reference[0].text_content),d(2),l("ngForOf",r==null||r.background_banner_reference==null||r.background_banner_reference[0]==null?null:r.background_banner_reference[0].text_content),d(2),l("ngForOf",r.foreground_banner_group),d(),l("ngTemplateOutlet",t),d(),l("ngForOf",r==null||r.background_banner_reference==null||r.background_banner_reference[0]==null?null:r.background_banner_reference[0].top_and_bottom_strip)}}function YP(i,e){i&1&&He(0)}function ZP(i,e){i&1&&He(0)}function XP(i,e){if(i&1&&(B(0),v(1,YP,1,0,"ng-container",29)(2,ZP,1,0,"ng-container",29),w(3,"async"),U()),i&2){let r=C(2).ngIf,t=C(),n=Y(3),o=Y(15);d(),l("ngTemplateOutlet",o)("ngTemplateOutletContext",ve(6,tn,r)),d(),l("ngTemplateOutlet",n)("ngTemplateOutletContext",xn(8,$P,r.ad_content,T(3,4,t.layoutClass$)))}}function JP(i,e){i&1&&He(0)}function eM(i,e){i&1&&He(0)}function tM(i,e){if(i&1&&(B(0),v(1,JP,1,0,"ng-container",29)(2,eM,1,0,"ng-container",29),U()),i&2){let r=C(2).ngIf,t=C(),n=Y(5),o=Y(15);d(),l("ngTemplateOutlet",o)("ngTemplateOutletContext",ve(4,tn,r)),d(),l("ngTemplateOutlet",n)("ngTemplateOutletContext",ve(6,tn,t.withFetchPriority(r.ad_content)))}}function iM(i,e){i&1&&He(0)}function nM(i,e){if(i&1&&(B(0),v(1,iM,1,0,"ng-container",29),U()),i&2){let r=C(2).ngIf;C();let t=Y(7);d(),l("ngTemplateOutlet",t)("ngTemplateOutletContext",ve(2,tn,r))}}function rM(i,e){i&1&&He(0)}function oM(i,e){if(i&1&&(B(0),v(1,rM,1,0,"ng-container",29),U()),i&2){let r=C(2).ngIf;C();let t=Y(9);d(),l("ngTemplateOutlet",t)("ngTemplateOutletContext",ve(2,tn,r))}}function sM(i,e){i&1&&He(0)}function aM(i,e){if(i&1&&(B(0),v(1,sM,1,0,"ng-container",29),U()),i&2){let r=C(3).ngIf,t=C(),n=Y(11);d(),l("ngTemplateOutlet",n)("ngTemplateOutletContext",ve(2,tn,t.normalizeCarouselComponentData(r)))}}function cM(i,e){i&1&&He(0)}function pM(i,e){if(i&1&&(B(0),v(1,cM,1,0,"ng-container",29),U()),i&2){let r=C(4).ngIf,t=C(),n=Y(11);d(),l("ngTemplateOutlet",n)("ngTemplateOutletContext",ve(2,tn,t.normalizeCarouselComponentData(r)))}}function lM(i,e){i&1&&He(0)}function dM(i,e){if(i&1&&v(0,lM,1,0,"ng-container",29),i&2){let r=C(4).ngIf,t=C(),n=Y(13);l("ngTemplateOutlet",n)("ngTemplateOutletContext",ve(2,tn,t.normalizeRecommendationCarouselComponentData(r)))}}function mM(i,e){if(i&1&&(B(0),v(1,pM,2,4,"ng-container",13)(2,dM,1,4,"ng-template",null,8,ne),U()),i&2){let r=Y(3),t=C(3).ngIf;d(),l("ngIf",t.product_content.third_party_recommendation_types==="TOP_SELLER")("ngIfElse",r)}}function uM(i,e){if(i&1&&(B(0),v(1,aM,2,4,"ng-container",23),w(2,"async"),v(3,mM,4,2,"ng-container",23),w(4,"async"),U()),i&2){let r=C(3);d(),l("ngIf",T(2,2,r.showMarketProduct$)),d(2),l("ngIf",T(4,4,r.showThirdPartyProduct$))}}function fM(i,e){if(i&1&&(v(0,XP,4,11,"ng-container",23),w(1,"async"),v(2,tM,3,8,"ng-container",23),w(3,"async"),v(4,nM,2,4,"ng-container",23),w(5,"async"),v(6,oM,2,4,"ng-container",23),w(7,"async"),v(8,uM,5,6,"ng-container",23)),i&2){let r=C().ngIf,t=C();l("ngIf",T(1,5,t.showStaticBanner$)),d(2),l("ngIf",T(3,7,t.showRotatingBanner$)),d(2),l("ngIf",T(5,9,t.showCategoryMultiRowOrFourSquare$)),d(2),l("ngIf",T(7,11,t.showCategorySet$)),d(2),l("ngIf",r.product_recommendation)}}function hM(i,e){if(i&1&&(S(0,"div",12),v(1,QP,12,16,"ng-container",13),w(2,"async"),v(3,fM,9,13,"ng-template",null,7,ne),b()),i&2){let r=Y(4),t=C();l("sipObserve",t.handleComponentVisible.bind(t)),d(),l("ngIf",T(2,3,t.backgroundForegroundData$))("ngIfElse",r)}}function gM(i,e){if(i&1&&P(0,"sip-cs-dynamic-component",28),i&2){let r=C().$implicit;l("componentInfo",r)}}function _M(i,e){if(i&1&&(S(0,"div",31),v(1,gM,1,1,"sip-cs-dynamic-component",27),b()),i&2){let r=e.$implicit;d(),l("ngIf",r)}}function CM(i,e){if(i&1&&(B(0),v(1,_M,2,1,"div",30),U()),i&2){let r=C().data;d(),l("ngForOf",r)}}function yM(i,e){if(i&1&&P(0,"sip-cs-dynamic-component",28),i&2){let r=C().$implicit;l("componentInfo",r)}}function vM(i,e){if(i&1&&(S(0,"div"),v(1,yM,1,1,"sip-cs-dynamic-component",27),b()),i&2){let r=e.$implicit;d(),l("ngIf",r)}}function SM(i,e){if(i&1&&P(0,"sip-cs-dynamic-component",28),i&2){let r=C().$implicit;l("componentInfo",r)}}function bM(i,e){if(i&1&&(S(0,"div"),v(1,SM,1,1,"sip-cs-dynamic-component",27),b()),i&2){let r=e.$implicit;d(),l("ngIf",r)}}function xM(i,e){if(i&1&&(S(0,"div",31),v(1,vM,2,1,"div",17),b(),S(2,"div",31),v(3,bM,2,1,"div",17),b()),i&2){let r=C().data,t=C();d(),l("ngForOf",t.getItems(r,0,1)),d(2),l("ngForOf",t.getItems(r,1))}}function PM(i,e){if(i&1&&(S(0,"div",22),w(1,"async"),v(2,CM,2,1,"ng-container",13)(3,xM,4,2,"ng-template",null,9,ne),b()),i&2){let r=e.layout,t=Y(4),n=C();l("ngClass",T(1,3,n.layoutClass$)),d(2),l("ngIf",r!==n.AdType.OneFourthMix)("ngIfElse",t)}}function MM(i,e){if(i&1&&P(0,"sip-cs-dynamic-component",28),i&2){let r=C().item;l("componentInfo",r)}}function EM(i,e){if(i&1&&v(0,MM,1,1,"sip-cs-dynamic-component",27),i&2){let r=e.item;l("ngIf",r)}}function IM(i,e){if(i&1&&(B(0),S(1,"div",32),P(2,"sip-carousel",33),v(3,EM,1,1,"ng-template",null,10,ne),b(),U()),i&2){let r=e.data,t=Y(4),n=C();d(2),l("items",r)("template",t)("options",n.options)}}function OM(i,e){if(i&1&&P(0,"sip-category-multi-row-or-four-square",34),i&2){let r=e.data;l("data$",r)}}function wM(i,e){if(i&1&&P(0,"sip-category-set",34),i&2){let r=e.data;l("data$",r)}}function TM(i,e){if(i&1&&P(0,"sip-cs-dynamic-component",28),i&2){let r=e.data;l("componentInfo",r)}}function kM(i,e){if(i&1&&P(0,"sip-cs-dynamic-component",28),i&2){let r=e.data;l("componentInfo",r)}}function RM(i,e){if(i&1&&(S(0,"h2"),H(1),b()),i&2){let r=C(2).ngIf;d(),le(" ",r.title," ")}}function AM(i,e){if(i&1&&(S(0,"a",38),H(1," See All "),S(2,"div",39),P(3,"mat-icon",40),b()()),i&2){let r=C(2).ngIf;l("href",r.url,Ct)}}function NM(i,e){if(i&1&&(S(0,"section",36),v(1,RM,2,1,"h2",23)(2,AM,4,1,"a",37),b()),i&2){let r=C().ngIf;d(),l("ngIf",r.title),d(),l("ngIf",r.url)}}function DM(i,e){if(i&1&&(B(0),v(1,NM,3,2,"section",35),U()),i&2){let r=e.ngIf;d(),l("ngIf",r.title||r.url)}}function FM(i,e){if(i&1&&v(0,DM,2,1,"ng-container",23),i&2){let r=e.data;l("ngIf",r==null?null:r.ad_set_heading_and_costco_url)}}var KC=(()=>{let e=class e{constructor(t,n,o,s){this.component=t,this.sipGtmService=n,this.router=o,this.windowRef=s,this.subscriptions=new Ee,this.AdType=um,this.TextBannerType=gr,this.options={loop:!1,rewind:!0,autoplay:!1,navSpeed:500,autoplaySpeed:500,autoplayTimeout:4e3,dots:!0,items:1,slideBy:1,responsive:{0:{items:1,slideBy:1}},showPausePlayButtons:!1,showMatIcons:!0},this.showStaticBanner$=this.component.data$.pipe(z(1),x(a=>
40{if(a.item_type===Mi.AD&&a.ad_set_style===Dr.STATIC)return!0}),X()),this.showRotatingBanner$=this.component.data$.pipe(z(1),x(a=>{if(a.item_type===Mi.AD&&a.ad_set_style===Dr.ROTATING){if(this.options.autoplay=a.rotating_options?.enable_autoplay,this.options.showPausePlayButtons=a.rotating_options?.enable_autoplay,a.rotating_options?.multi_item_carousel){if(this.windowRef.nativeWindow){let c=this.windowRef?.nativeWindow?.screen?.width;c<ot.md?this.options.showMatIcons=!1:c>=ot.md&&c<ot.lg?this.options.showMatIcons=a.ad_content.length>3:c>=ot.lg&&(this.options.showMatIcons=a.ad_content.length>5)}this.options.responsive={0:{items:2,slideBy:"page"},[ot.md-56]:{items:3,slideBy:"page"},[ot.lg-48]:{items:5,slideBy:"page"}}}return!0}}),X()),this.showCategoryMultiRowOrFourSquare$=this.component.data$.pipe(z(1),x(a=>{if(a.item_type===Mi.CATEGORY&&a.ad_set_style===Dr.STATIC)return!0}),X()),this.showCategorySet$=this.component.data$.pipe(z(1),x(a=>{if(a.item_type===Mi.CATEGORY&&a.ad_set_style===Dr.ROTATING)return!0})),this.showMarketProduct$=this.component.data$.pipe(z(1),x(a=>{if(a.item_type===Mi.PRODUCT&&a.product_recommendation_types===ec.Market)return!0}),X()),this.showThirdPartyProduct$=this.component.data$.pipe(z(1),x(a=>{if(a.item_type===Mi.PRODUCT&&a.product_recommendation_types===ec.ThirdParty)return!0}),X()),this.layoutClass$=this.component.data$.pipe(z(1),rt("ad_content"),x((a,c)=>{let p=a[0]?.ad_builder_block?.ad_builder_ref[0].ad_type===void 0?"":a[0]?.ad_builder_block?.ad_builder_ref[0].ad_type;return a.map((m,_)=>{if(m?.ad_builder_block?.ad_builder_ref){let y=m?.ad_builder_block?.ad_builder_ref[0].ad_type===void 0?"":m?.ad_builder_block?.ad_builder_ref[0].ad_type;p=p===y?p:"one_fourth_mix"}}),p}),X()),this.backgroundForegroundData$=this.component.data$.pipe(z(1),x(a=>(a.item_type===Mi.AD||a.item_type===Mi.PRODUCT)&&a.enable_background_foreground_banner?ie(R({},a.background_foreground_banner_group),{foreground_banner_group:a.background_foreground_banner_group.foreground_banner_group?.map(c=>({ad_builder_block:c}))??[]}):!1),X())}handleComponentVisible(){this.subscriptions.add(this.component.data$.pipe(j(t=>!!t?.ga_ref?.[0]?.promotion_id),X()).subscribe(t=>{this.saveGtmEvent(t?.ga_ref[0],Kt.PROMOTION_IMPRESSIONS_VIEW)}))}saveGtmEvent(t,n){if(t?.promotion_id&&t?.promotion_enabled){let o={id:t.promotion_id,name:t.promotion_name,creative:t.promotion_creative,position:t.promotion_position,urlTarget:t.link_url};this.sipGtmService.pushPromotionImpressionEvent(o,n),this.sipGtmService.pushGA4ViewPromotionEvent(o)}}onClick(t){if(t?.promotion_id&&t?.promotion_enabled){let n={id:t.promotion_id,name:t.promotion_name,creative:t.promotion_creative,position:t.promotion_position,urlTarget:t.link_url};this.sipGtmService.pushGA4SelectPromotionEvent(n)}}computeBackgroundColor(t){let n=t?.background_gradient_style,o=t?.background_color?.hex,s=t?.background_gradient_color?.color1?.hex,a=t?.background_gradient_color?.color2?.hex;switch(n){case"solid":return o;case"linear":if(s&&a)return`linear-gradient(to right, ${s}, ${a})`;break;case"radial":if(s&&a)return`radial-gradient(circle, ${s}, ${a})`;break;case"no-background":return"none";default:return""}}getBackgroundPosition(t){switch(t){case"Top":return"top";case"Middle":return"center";case"Bottom":return"bottom";default:return"center"}}getBorderRadius(t){return t?.some(o=>o.strip?.strip_type==="bottom_strip")?"16px 16px 0 0":"16px"}backgroundButtonClick(t){this.router.navigateByUrl(t)}getItems(t,n,o){let s=[...t];return s.splice(n,o??s.length)}withFetchPriority(t){if(this.fetchPriorityInput===t)return this.fetchPriorityOutput;let n=t[0],o=n?.ad_builder_block?.ad_builder_ref?.[0],s=t;return o&&(s=[ie(R({},n),{ad_builder_block:ie(R({},n.ad_builder_block),{ad_builder_ref:[ie(R({},o),{fetch_priority:"high"}),...n.ad_builder_block.ad_builder_ref.slice(1)]})}),...t.slice(1)]),this.fetchPriorityInput=t,this.fetchPriorityOutput=s,s}normalizeCarouselComponentData(t){return{marketing_product_slider_block:{title:this.formatAdSetTitle(t?.ad_set_heading_and_costco_url?.title,t?.ad_set_heading_and_costco_url?.url),useSolrSearch:t.product_display_style.use_solr,productC
40odes:t.product_content.product_codes.replace(","," "),addToCart:t.product_display_style.add_to_cart,lazyLoad:t.product_display_style.lazy_load,lazyLoadEager:t.product_display_style.lazy_load_eager,doStockCheck:t?.product_display_style?.inventory_aware_listings}}}normalizeRecommendationCarouselComponentData(t){let n=t?.product_content?.third_party_recommendation_types,o=this.buildBaseCarouselFields(t);return n===oh.RECENTLY_VIEWED?{recently_viewed_product_slider_block:ie(R({},o),{scroll:t?.product_display_style?.scroll_type,popup:t?.product_display_style?.popup_view_enabled})}:{third_party_recommendation_product_slider_block:R({},o)}}buildBaseCarouselFields(t){return{title:this.formatAdSetTitle(t?.ad_set_heading_and_costco_url?.title,t?.ad_set_heading_and_costco_url?.url),displayProductTitles:t?.product_display_style?.display_product_titles,productReferenceTypes:t?.product_content?.third_party_recommendation_types,addToCart:t?.product_display_style?.add_to_cart,lazyLoad:t?.product_display_style?.lazy_load,lazyLoadEager:t?.product_display_style?.lazy_load_eager,doStockCheck:t?.product_display_style?.inventory_aware_listings,displayProductPrices:t?.product_display_style?.display_product_prices,maximumNumberProducts:t?.product_display_style?.maximum_number_of_products}}formatAdSetTitle(t,n){return t?n?`<a href="${n}" target='_self'>${t}</a>`:t:""}ngOnDestroy(){this.subscriptions.unsubscribe()}};e.\u0275fac=function(n){return new(n||e)(O(ee),O(At),O(re),O(K))},e.\u0275cmp=F({type:e,selectors:[["sip-ad-set"]],decls:16,vars:3,consts:[["singleBanner",""],["rotatingBanner",""],["categoryMultiRowOrFourSquare",""],["categorySet",""],["marketingProductCarouselContent",""],["thirdPartyProductRecommendationCarouselContent",""],["titleAndUrl",""],["adSetContent",""],["thirdPartyRecommendationTemplate",""],["oneFourthTmp",""],["itemTpl",""],["class","ad-set",3,"sipObserve",4,"ngIf"],[1,"ad-set",3,"sipObserve"],[4,"ngIf","ngIfElse"],[1,"background-banner-group",3,"ngStyle"],[1,"background-text-content",3,"ngClass"],[1,"background-text-content-title-subtitle"],[4,"ngFor","ngForOf"],[1,"background-text-content-button"],[1,"foreground-banner-group"],[4,"ngTemplateOutlet"],[3,"ngClass","color",4,"ngIf"],[3,"ngClass"],[4,"ngIf"],[1,"bg-btn",3,"click"],["class","foreground-banner",3,"componentInfo",4,"ngIf"],[1,"foreground-banner",3,"componentInfo"],[3,"componentInfo",4,"ngIf"],[3,"componentInfo"],[4,"ngTemplateOutlet","ngTemplateOutletContext"],["class","ad-type",4,"ngFor","ngForOf"],[1,"ad-type"],[1,"mat-carousel","rotating-banner-carousel"],[3,"items","template","options"],[3,"data$"],["class","header",4,"ngIf"],[1,"header"],["class","see-all",3,"href",4,"ngIf"],[1,"see-all",3,"href"],[1,"chevron"],["svgIcon","chevron-right","aria-hidden","true"]],template:function(n,o){n&1&&(v(0,hM,5,5,"div",11),w(1,"async"),v(2,PM,5,5,"ng-template",null,0,ne)(4,IM,5,3,"ng-template",null,1,ne)(6,OM,1,1,"ng-template",null,2,ne)(8,wM,1,1,"ng-template",null,3,ne)(10,TM,1,1,"ng-template",null,4,ne)(12,kM,1,1,"ng-template",null,5,ne)(14,FM,1,1,"ng-template",null,6,ne)),n&2&&l("ngIf",T(1,1,o.component.data$))},dependencies:[Ie,qe,W,ci,Vt,Dn,Zn,ua,fa,zi,Wi,q,gh],styles:[".mat-carousel{position:relative} .mat-carousel .mat-arrows.owl-nav{display:flex;justify-content:space-between;width:100%;position:absolute;bottom:0%;z-index:1;transform:translateY(1rem);pointer-events:none}@media screen and (min-width: 768px) and (max-width: 1023px){ .mat-carousel .mat-arrows.owl-nav{bottom:50%;transform:translateY(0)}}@media screen and (min-width: 1024px){ .mat-carousel .mat-arrows.owl-nav{bottom:50%;transform:translateY(0)}} .mat-carousel .mat-arrows.owl-nav .owl-prev, .mat-carousel .mat-arrows.owl-nav .owl-next{display:flex;padding:8px;justify-content:center;align-items:center;background-color:#fff;border-radius:100px;box-shadow:0 0 5px #0000004d;pointer-events:auto} .mat-carousel .mat-arrows.owl-nav .owl-prev:focus, .mat-carousel .mat-arrows.owl-nav .owl-next:focus{outline:0px!important} .mat-carousel .mat-arrows.owl-nav .owl-next{margin-right:-.5rem}@media screen and (min-width: 1024px){ .mat-carousel .mat-arrows.owl-nav .owl-next{margin-right:-1.8rem}} .mat-carousel .mat-arrows.owl-nav .owl-prev{margin-left:-.8rem}@media screen and (min-width: 1024px){ .mat-carousel .mat-arrows.owl-nav .owl-prev{margin-left:-1.8rem}} .mat-carousel owl-carousel-o.owl-mat-icons .owl-dots{display:none} .mat-carousel owl-carousel-o.owl-mat-icons .owl-nav{display:none} .mat-carousel .mat-dots .carousel-button{padding:0;vertical-align:top;background:transparent;border:none;cursor:pointer} .mat-carousel .mat-dots .carousel-button .mat-pause-play-icon{font-size:18px;width:20px;height:20px;line-height:20px;margin:5px 0} .mat-carousel .mat-dots{text-align:center;-webkit-tap-highlight-color:transparent;margin-top:10px} .mat-carousel .mat-dots .owl-dot{display:inline-block;zoom:1;border:none;background:transparent;padding:0;cursor:pointer} .mat-carousel .mat-dots .owl-dot:focus{outline:none} .mat-carousel .mat-dots .owl-dot mat-icon{margin:5px 7px}.ad-set[_ngcontent-%COMP%] .half[_ngcontent-%COMP%]{display:grid;grid-template-columns:repeat(1,1fr);gap:16px}.ad-set[_ngcontent-%COMP%] .half[_ngcontent-%COMP%] .ad-builder{flex-flow:column}.ad-set[_ngcontent-%COMP%] .one_third[_ngcontent-%COMP%]{display:grid;grid-template-columns:repeat(1,1fr);gap:16px}.ad-set[_ngcontent-%COMP%] .one_third[_ngcontent-%COMP%] .ad-builder{flex-flow:column}.ad-set[_ngcontent-%COMP%] .one_fourth[_ngcontent-%COMP%]{display:grid;grid-template-columns:repeat(2,1fr);gap:16px}.ad-set[_ngcontent-%COMP%] .one_fourth[_ngcontent-%COMP%] .ad-builder{flex-flow:column}.ad-set[_ngcontent-%COMP%] .one_fourth_mix[_ngcontent-%COMP%]{display:grid;grid-template-columns:repeat(1,1fr);gap:16px}.ad-set[_ngcontent-%COMP%] .one_fourth_mix[_ngcontent-%COMP%] .ad-builder{flex-flow:column}.ad-set[_ngcontent-%COMP%] .one_fourth_mix[_ngcontent-%COMP%] .ad-type[_ngcontent-%COMP%]{display:flex;flex-wrap:wrap;gap:16px}.ad-set[_ngcontent-%COMP%] .one_fourth_mix[_ngcontent-%COMP%] .ad-type[_ngcontent-%COMP%] > div[_ngcontent-%COMP%]{flex:1 1 calc(50% - 16px)}.ad-set[_ngcontent-%COMP%] .header[_ngcontent-%COMP%]{display:flex;justify-content:space-between;padding:8px 0}.ad-set[_ngcontent-%COMP%] .header[_ngcontent-%COMP%] h2[_ngcontent-%COMP%]{font-size:24px;font-weight:700;color:#333}.ad-set[_ngcontent-%COMP%] .header[_ngcontent-%COMP%] .see-all[_ng
40content-%COMP%]{color:#333;text-decoration:none;display:flex;align-items:center}.ad-set[_ngcontent-%COMP%] .header[_ngcontent-%COMP%] .see-all[_ngcontent-%COMP%]:hover{text-decoration:underline}.ad-set[_ngcontent-%COMP%] .header[_ngcontent-%COMP%] .see-all[_ngcontent-%COMP%] .chevron[_ngcontent-%COMP%]{margin-left:8px;display:flex;align-items:center;width:14px;height:14px}.ad-set[_ngcontent-%COMP%] .header[_ngcontent-%COMP%]:empty{padding:0}.ad-set[_ngcontent-%COMP%] .background-banner-group[_ngcontent-%COMP%]{padding:16px;background-repeat:no-repeat}.ad-set[_ngcontent-%COMP%] .background-banner-group[_ngcontent-%COMP%] owl-carousel-o .owl-carousel{display:block!important}.ad-set[_ngcontent-%COMP%] .background-banner-group[_ngcontent-%COMP%] .horizontal-alignment[_ngcontent-%COMP%]{width:100%;justify-content:space-between;display:flex}.ad-set[_ngcontent-%COMP%] .background-banner-group[_ngcontent-%COMP%] .background-text-content[_ngcontent-%COMP%]{padding-bottom:24px}.ad-set[_ngcontent-%COMP%] .background-banner-group[_ngcontent-%COMP%] .background-text-content[_ngcontent-%COMP%] .title[_ngcontent-%COMP%]{font-weight:400;font-size:24px;line-height:28px;padding:4px 0}.ad-set[_ngcontent-%COMP%] .background-banner-group[_ngcontent-%COMP%] .background-text-content[_ngcontent-%COMP%] .subtitle[_ngcontent-%COMP%]{font-weight:400;font-size:14px;line-height:1.5}.ad-set[_ngcontent-%COMP%] .background-banner-group[_ngcontent-%COMP%] .background-text-content[_ngcontent-%COMP%] .bg-btn[_ngcontent-%COMP%]{margin-top:8px;padding:3px 16px 5px;border-radius:3px;font-weight:500;font-size:12px!important;line-height:1.3!important;letter-spacing:.2px;min-height:auto!important;height:auto;background:#005dab;outline:none;border:none}@media screen and (min-width: 768px) and (max-width: 1023px){.ad-set[_ngcontent-%COMP%] .background-banner-group[_ngcontent-%COMP%] .background-text-content.has-bg[_ngcontent-%COMP%]{min-height:736px}.ad-set[_ngcontent-%COMP%] .background-banner-group[_ngcontent-%COMP%] .background-text-content[_ngcontent-%COMP%] .title[_ngcontent-%COMP%]{margin-bottom:8px}}@media screen and (min-width: 1024px){.ad-set[_ngcontent-%COMP%] .background-banner-group[_ngcontent-%COMP%] .background-text-content.has-bg[_ngcontent-%COMP%]{min-height:249px}.ad-set[_ngcontent-%COMP%] .background-banner-group[_ngcontent-%COMP%] .background-text-content[_ngcontent-%COMP%] .title[_ngcontent-%COMP%]{font-size:42px;line-height:1.3}.ad-set[_ngcontent-%COMP%] .background-banner-group[_ngcontent-%COMP%] .background-text-content[_ngcontent-%COMP%] .subtitle[_ngcontent-%COMP%]{font-size:22px;line-height:1.3}.ad-set[_ngcontent-%COMP%] .background-banner-group[_ngcontent-%COMP%] .background-text-content[_ngcontent-%COMP%] .bg-btn[_ngcontent-%COMP%]{margin-top:12px;padding:10px 16px;font-size:16px!important;line-height:1.3!important;min-height:40px!important;letter-spacing:0px}}.ad-set[_ngcontent-%COMP%] .background-banner-group[_ngcontent-%COMP%] .foreground-banner-group[_ngcontent-%COMP%]{display:flex;box-sizing:border-box;gap:16px;margin-bottom:16px}.ad-set[_ngcontent-%COMP%] .background-banner-group[_ngcontent-%COMP%] .foreground-banner-group[_ngcontent-%COMP%] .foreground-banner[_ngcontent-%COMP%]{flex:1 1 100%;min-width:0}.ad-set[_ngcontent-%COMP%] .background-banner-group[_ngcontent-%COMP%] .costco-carousel-component{margin:10px 0 0}.ad-set[_ngcontent-%COMP%] .background-banner-group[_ngcontent-%COMP%] .costco-carousel-component-border-top{border-top:none}.ad-set[_ngcontent-%COMP%] .background-banner-group[_ngcontent-%COMP%] sip-product-carousel-base .item.product-item{background-color:#fff;border-radius:8px;margin:0 8px}.ad-set[_ngcontent-%COMP%] .background-banner-group[_ngcontent-%COMP%] owl-carousel-o:not(.owl-mat-icons) .owl-dots{bottom:unset!important;left:unset;right:unset;background-color:#fffc;display:flex;justify-content:center;padding:4px;justify-self:center;border-radius:16px}.ad-set[_ngcontent-%COMP%] .background-banner-group[_ngcontent-%COMP%] owl-carousel-o:not(.owl-mat-icons) .owl-dots .owl-dot{width:unset}.ad-set[_ngcontent-%COMP%] .rotating-banner-carousel .embla-slide{padding:0 5px}@media screen and (max-width: 480px){ .ad-set .carousel-component{margin-left:0!important;margin-right:0!important}}@media screen and (min-width: 768px) and (max-width: 1023px){.ad-set[_ngcontent-%COMP%] .half[_ngcontent-%COMP%]{grid-template-columns:repeat(2,1fr);gap:24px}.ad-set[_ngcontent-%COMP%] .one_third[_ngcontent-%COMP%]{grid-template-columns:repeat(3,minmax(0,1fr));gap:24px}.ad-set[_ngcontent-%COMP%] .one_fourth[_ngcontent-%COMP%]{grid-template-columns:repeat(2,1fr);gap:24px}.ad-set[_ngcontent-%COMP%] .one_fourth_mix[_ngcontent-%COMP%]{grid-template-columns:repeat(1,1fr);gap:24px}.ad-set[_ngcontent-%COMP%] .one_fourth_mix[_ngcontent-%COMP%] .ad-type[_ngcontent-%COMP%]{display:flex;flex-wrap:wrap;gap:24px}.ad-set[_ngcontent-%COMP%] .one_fourth_mix[_ngcontent-%COMP%] .ad-type[_ngcontent-%COMP%] > div[_ngcontent-%COMP%]{flex:1 1 calc(50% - 24px)}}@media screen and (min-width: 1024px){.ad-set[_ngcontent-%COMP%] .half[_ngcontent-%COMP%]{grid-template-columns:repeat(2,1fr);gap:24px}.ad-set[_ngcontent-%COMP%] .one_third[_ngcontent-%COMP%]{grid-template-columns:repeat(3,1fr);gap:24px}.ad-set[_ngcontent-%COMP%] .one_fourth[_ngcontent-%COMP%]{grid-template-columns:repeat(4,1fr);gap:24px}.ad-set[_ngcontent-%COMP%] .one_fourth_mix[_ngcontent-%COMP%]{grid-template-columns:repeat(2,1fr);gap:24px}.ad-set[_ngcontent-%COMP%] .one_fourth_mix[_ngcontent-%COMP%] .ad-type[_ngcontent-%COMP%]{display:flex;flex-wrap:wrap;gap:24px}.ad-set[_ngcontent-%COMP%] .one_fourth_mix[_ngcontent-%COMP%] .ad-type[_ngcontent-%COMP%] > div[_ngcontent-%COMP%]{flex:1 1 calc(50% - 24px)}} .ad-set .costco-carousel-component{margin-top:0!important} .ad-set .costco-carousel-component.clearfix:before, .ad-set .costco-carousel-component.clearfix:after{content:none;display:initial} .ad-set .costco-carousel-component .carousel{margin-bottom:20px!important}@media screen and (min-width: 768px) and (max-width: 1023px){ .ad-set .costco-carousel-component .carousel{margin-bottom:24px!important}}@media screen and (min-width: 1024px){ .ad-set .costco-carousel-component .carousel{margin-bottom:30px!important}} .ad-set .costco-carousel-component .carousel .owl-dots{bottom:-8px!important}"],changeDetection:0});let i=e;return i})();var ha=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({providers:[M({cmsComponents:{SipCategoryContentComponent:{component:ua}}})],imports:[$,Ae,vs,Gi]});let i=e;return i})();var ga=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({providers:[M({cmsComponents:{SipCategoryContentComponent:{component:fa}}})],imports:[$,Ae,vs,Xn,Gi]});let i=e;return i})();var QC=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({providers:[M({cmsComponents:{SipAdSetComponent:{component:KC}}})],imports:[$,Fn,Xn,Ae,ha,ga,Gi,Ki]});let i=e;return i})();function LM(i,e){if(i&1&&(B(0),S(1,"div"),P(2,"h2",7),w(3,"safeHtml"),b(),U()),i&2){let r=C().ngIf;d(2),l("innerHTML",T(3,1,r),ye)}}function jM(i,e){if(i&1&&(P(0,"div",7),w(1,"safeHtml")),i&2){let r=C().ngIf;l("innerHTML",T(1,1,r),ye)}}
40function $M(i,e){if(i&1&&(B(0),v(1,LM,4,3,"ng-container",6)(2,jM,2,3,"ng-template",null,0,ne),U()),i&2){let r=Y(3),t=C(3);d(),l("ngIf",t.includeH2Tag)("ngIfElse",r)}}function BM(i,e){if(i&1&&(S(0,"div",3),v(1,$M,4,2,"ng-container",1),w(2,"async"),S(3,"div",4),P(4,"sip-carousel",5),b()()),i&2){let r=C().ngIf,t=C();l("ngClass",t.isContentStackPage?"costco-carousel-component-border-top":""),d(),l("ngIf",T(2,5,t.title)),d(3),l("items",r)("template",t.template)("options",t.options)}}function UM(i,e){if(i&1&&(B(0),v(1,BM,5,7,"div",2),U()),i&2){let r=e.ngIf;d(),l("ngIf",r.length>0)}}var _r=(()=>{let e=class e{constructor(t){this.contentStackConfigService=t}ngOnInit(){this.contentStackConfigService.getContentStackPage().subscribe(t=>{this.isContentStackPage=t})}};e.\u0275fac=function(n){return new(n||e)(O(Pt))},e.\u0275cmp=F({type:e,selectors:[["sip-product-carousel-base"]],inputs:{title:"title",items:"items",options:"options",template:"template",includeH2Tag:"includeH2Tag"},decls:2,vars:3,consts:[["divContent",""],[4,"ngIf"],["class","carousel-component costco-carousel-component clearfix",3,"ngClass",4,"ngIf"],[1,"carousel-component","costco-carousel-component","clearfix",3,"ngClass"],[1,"carousel"],[3,"items","template","options"],[4,"ngIf","ngIfElse"],[1,"headline",3,"innerHTML"]],template:function(n,o){n&1&&(v(0,UM,2,1,"ng-container",1),w(1,"async")),n&2&&l("ngIf",T(1,1,o.items))},dependencies:[Ie,W,Zn,q,ut],styles:["[_nghost-%COMP%] .costco-carousel-component-border-top[_ngcontent-%COMP%]{border-top:1px solid #cccccc}[_nghost-%COMP%] .costco-carousel-component[_ngcontent-%COMP%]{margin:10px 10px 0}[_nghost-%COMP%] .costco-carousel-component[_ngcontent-%COMP%] .headline[_ngcontent-%COMP%]{margin:20px 0 10px;text-align:left;font-size:20px;padding:0 10px}@media screen and (min-width: 768px) and (max-width: 1024px){[_nghost-%COMP%] .costco-carousel-component[_ngcontent-%COMP%] .headline[_ngcontent-%COMP%]{font-size:22px}}@media screen and (min-width: 1024px){[_nghost-%COMP%] .costco-carousel-component[_ngcontent-%COMP%] .headline[_ngcontent-%COMP%]{font-size:30px}}[_nghost-%COMP%] .costco-carousel-component[_ngcontent-%COMP%] .carousel[_ngcontent-%COMP%]{text-align:left;margin-bottom:40px}@media screen and (min-width: 1024px){[_nghost-%COMP%] .costco-carousel-component[_ngcontent-%COMP%] .carousel[_ngcontent-%COMP%]{margin-bottom:60px}}[_nghost-%COMP%] .costco-carousel-component[_ngcontent-%COMP%] .owl-dots{bottom:-20px;position:absolute;text-align:center;left:0;right:0}[_nghost-%COMP%] .costco-carousel-component[_ngcontent-%COMP%] .owl-nav .owl-prev, [_nghost-%COMP%] .costco-carousel-component[_ngcontent-%COMP%] .owl-nav .owl-next{transform:translateY(-100%);height:38px;width:38px;line-height:80px;vertical-align:middle;padding:4px;border-radius:100%;opacity:1;border:1px solid #cacaca;box-shadow:0 0 5px #0000004d}[_nghost-%COMP%] .costco-carousel-component[_ngcontent-%COMP%] .owl-nav .owl-next:active, [_nghost-%COMP%] .costco-carousel-component[_ngcontent-%COMP%] .owl-nav .owl-next:focus{border:1px solid black}[_nghost-%COMP%] .costco-carousel-component[_ngcontent-%COMP%] .owl-nav .carousel-nav-icon:before{color:#333;text-shadow:none;font-size:20px;position:absolute;left:50%;top:50%;transform:translate(-50%,-50%);opacity:1}@media screen and (min-width: 1024px){[_nghost-%COMP%] .costco-carousel-component[_ngcontent-%COMP%] {max-width:1360px}[_nghost-%COMP%] .costco-carousel-component[_ngcontent-%COMP%] .owl-item{max-width:340px}}"],changeDetection:0});let i=e;return i})();function zM(i,e){if(i&1&&P(0,"sip-age-restriction-overlay",15),i&2){let r=C(2);l("customClass","overlay-carousel")("minimumRequiredAge",r.product.minimumVerificationAge)}}function GM(i,e){if(i&1&&P(0,"sip-media",16),i&2){let r=C(2);l("container",r.mediaContainer)("loading",r.ImageLoadingStrategy.LAZY)}}function HM(i,e){if(i&1&&(P(0,"img",17),w(1,"cxTranslate")),i&2){let r=C(2);l("src",T(1,2,"img.missingProductImage.carousel"),Ct)("alt",r.product.name)}}function VM(i,e){if(i&1&&(S(0,"div",18),H(1),b()),i&2){let r=C(2);d(),le(" ",r.product.deliveryName," ")}}function qM(i,e){if(i&1&&(S(0,"span",19),H(1),b()),i&2){let r=C(2);d(),Be(r.product.shippingPurchaseMethodExceptionMessage)}}function WM(i,e){i&1&&(B(0),P(1,"i",20),S(2,"span"),H(3),w(4,"cxTranslate"),b(),U()),i&2&&(d(3),Be(T(4,1,"product.membership.restrictions.apply")||"Membership Restrictions Apply"))}function KM(i,e){i&1&&(B(0),P(1,"i",20),S(2,"span"),H(3),w(4,"cxTranslate"),b(),U()),i&2&&(d(3),Be(T(4,1,"product.shipping.restrictions.apply")||"Shipping Restrictions"))}
40function QM(i,e){i&1&&(B(0),P(1,"i",23),S(2,"span"),H(3),w(4,"cxTranslate"),b(),U()),i&2&&(d(3),Be(T(4,1,"text.product.loginToCheckPrices")||"Member Only Item"))}function YM(i,e){if(i&1&&P(0,"sip-product-price-panel",24),i&2){let r=C(3);l("product",r.product)("isDetailPage",!1)}}function ZM(i,e){if(i&1&&(S(0,"div",21),v(1,QM,5,3,"ng-container",11)(2,YM,1,2,"sip-product-price-panel",22),w(3,"async"),w(4,"sipSiteConfig"),b()),i&2){let r=C(2);d(),l("ngIf",r.shouldShowSignIn&&r.isMemberOnly),d(),l("ngIf",T(3,2,r.showPrice$)||ai(4,4,"product.memberonly.show.as400.discount.to.anonymous.enabled","boolean"))}}function XM(i,e){if(i&1){let r=Ve();S(0,"div",27)(1,"a",6),Ce("click",function(){ke(r);let n=C(3);return Re(n.trackRecommendation())}),H(2),b()()}if(i&2){let r=C(3);d(),l("routerLink",r.product.url),d(),Be(r.product.englishName)}}function JM(i,e){if(i&1){let r=Ve();S(0,"span")(1,"div",25)(2,"a",6),Ce("click",function(){ke(r);let n=C(2);return Re(n.trackRecommendation())}),H(3),b()(),v(4,XM,3,2,"div",26),w(5,"sipSiteConfig"),b()}if(i&2){let r=C(2);d(2),l("routerLink",r.product.url),d(),Be(r.product.name),d(),l("ngIf",r.product.englishName&&ai(5,3,r.CONFIG_DISPLAY_ENGLISH_TITLE,"boolean"))}}function eE(i,e){i&1&&(B(0),P(1,"i",23),S(2,"span"),H(3),w(4,"cxTranslate"),b(),U()),i&2&&(d(3),Be(T(4,1,"text.product.loginToCheckPrices")||"Member Only Item"))}function tE(i,e){if(i&1&&P(0,"sip-product-price-panel",24),i&2){let r=C(3);l("product",r.product)("isDetailPage",!1)}}function iE(i,e){if(i&1&&(S(0,"div",21),v(1,eE,5,3,"ng-container",11)(2,tE,1,2,"sip-product-price-panel",22),w(3,"async"),w(4,"sipSiteConfig"),b()),i&2){let r=C(2);d(),l("ngIf",r.shouldShowSignIn&&r.isMemberOnly),d(),l("ngIf",T(3,2,r.showPrice$)||ai(4,4,"product.memberonly.show.as400.discount.to.anonymous.enabled","boolean"))}}function nE(i,e){if(i&1&&P(0,"sip-inline-ratings-bazaarvoice",28),i&2){let r=C(2);l("product",r.product)}}function rE(i,e){if(i&1&&P(0,"sip-product-min-qty-msg",32),i&2){let r=C(3);l("route",r.SIP_PAGE_TYPE.PRODUCT_LIST_PAGE)("product",r.product)}}function oE(i,e){if(i&1&&(S(0,"div"),v(1,rE,1,2,"sip-product-min-qty-msg",29),S(2,"div",30),P(3,"sip-add-to-cart-panel",31),b()()),i&2){let r=C(2);d(),l("ngIf",r.routeType!==r.SIP_PAGE_TYPE.PRODUCT_DETAILS_PAGE),d(2),l("product",r.product)("route",r.routeType)("addToCartUrl",r.ADD_TO_CART_URL)("addToCartFeature",!0)("addToCartFromWishList",!1)}}function sE(i,e){if(i&1){let r=Ve();S(0,"button",34),Ce("click",function(){ke(r);let n=C(3);return Re(n.displayPostalCodeModal())}),H(1),w(2,"cxTranslate"),b()}if(i&2){let r=C(3);d(),le(" ",T(2,1,r.baseStore.inputDeliveryByAddress?"basket.add.to.basket.set.delivery.address":"basket.add.to.basket.set.postal.code")," ")}}function aE(i,e){if(i&1&&(v(0,sE,3,3,"button",33),w(1,"async"),w(2,"async")),i&2){let r=C(2);l("ngIf",r.product.inRestrictedZone&&!(T(1,1,!r.baseStore.inputDeliveryByAddress&&r.postalCode$)||T(2,3,r.baseStore.inputDeliveryByAddress&&r.deliveryAddress$)))}}function cE(i,e){if(i&1){let r=Ve();S(0,"div",3)(1,"div",4),v(2,zM,1,2,"sip-age-restriction-overlay",5),w(3,"async"),S(4,"a",6),Ce("click",function(){ke(r);let n=C();return Re(n.trackRecommendation())}),v(5,GM,1,2,"sip-media",7)(6,HM,2,4,"ng-template",null,0,ne),b(),P(8,"sip-decals",8),b(),v(9,VM,2,1,"div",9)(10,qM,2,1,"span",10)(11,WM,5,3,"ng-container",11)(12,KM,5,3,"ng-container",11)(13,ZM,5,7,"div",12)(14,JM,6,6,"span",11)(15,iE,5,7,"div",12)(16,nE,1,1,"sip-inline-ratings-bazaarvoice",13)(17,oE,4,6,"div",14),w(18,"async"),w(19,"async"),w(20,"async"),v(21,aE,3,5,"ng-template",null,1,ne),b()}if(i&2){let r=Y(7),t=Y(22),n=C();d(2),l("ngIf",T(3,15,n.showOverlay$)),d(2),l("routerLink",n.product.url),d(),l("ngIf",n.mediaContainer)("ngIfElse",r),d(3),l("decalData",n.product.decalData),d(),l("ngIf",n.product.deliveryName),d(),l("ngIf",n.baseStore.shippingPurchaseMethodExceptionMessagingEnabled&&n.product.shippingPurchaseMethodExceptionMessage),d(),l("ngIf",n.product.membershipRestrictionApplied),d(),l("ngIf",!n.product.membershipRestrictionApplied&&n.product.shippingRestrictionApplied),d(),l("ngIf",n.showPriceOnTop&&n.displayProductPrices),d(),l("ngIf",n.displayProductTitles),d(),l("ngIf",n.displayProductPrices&&!n.showPriceOnTop),d(),l("ngIf",n.product),d(),l("ngIf",n.addToCart&&n.product.addableToCartFromCarousel&&n.product.purchasable&&!n.product.tire&&T(18,17,n.showPrice$)&&(!n.product.inRestrictedZ
40one||T(19,19,!n.baseStore.inputDeliveryByAddress&&n.postalCode$)||T(20,21,n.baseStore.inputDeliveryByAddress&&n.deliveryAddress$)))("ngIfElse",t)}}var Cr=(()=>{let e=class e{constructor(t,n,o,s,a){this.googleRetailService=t,this.userService=n,this.deliveryService=o,this.baseStoreService=s,this.memberVerificationService=a,this.CONFIG_DISPLAY_ENGLISH_TITLE="product.display.english.title",this.CAROUSEL_IMAGE_FORMAT="carousel",this.ADD_TO_CART_URL=tt.ADD_TO_CART,this.SIP_PAGE_TYPE=Am,this.showPriceOnTop=!0,this.displayProductTitles=!0,this.displayProductPrices=!0,this.addToCart=!1,this.routeType=this.SIP_PAGE_TYPE.CAROUSEL_PAGE,this.ImageLoadingStrategy=Nn}ngOnInit(){this.hasAnonymousRole$=this.userService.hasAnonymousRole(),this.baseStoreService.getCurrentBaseStore().pipe(z(1)).subscribe(t=>this.baseStore=t),this.showPrice$=this.hasAnonymousRole$.pipe(x(t=>au.shouldShowPrice(this.product,t)&&!!this.product.price)),this.isMemberOnly=this.product?.hidePriceValue,this.shouldShowSignIn=!(this.product?.hidePriceValue&&this.product?.warehouseHidePriceValue),this.mediaContainer=this.getMediaContainer(this.product),this.addToCart=String(this.addToCart)==="true",this.postalCode$=this.deliveryService.getServiceablePostalCode(),this.deliveryAddress$=this.deliveryService.getServiceableAddress(),this.product.idVerificationEnabled&&this.product.minimumVerificationAge>=0&&(this.isMemberVerified$=this.userService.isMemberVerified(),this.memberHasMinimumAge$=this.memberVerificationService.memberHasMinimumAge(this.product),this.showOverlay$=this.memberVerificationService.showOverlay(this.product))}displayPostalCodeModal(){this.baseStore.inputDeliveryByAddress?this.deliveryService.triggerLocationModal(Qu,null,!0,this.baseStore):this.deliveryService.triggerLocationModal(qu)}buildFallbackCarouselImage(t){let n=this.CAROUSEL_IMAGE_FORMAT,o=`${this.CAROUSEL_IMAGE_FORMAT}-webp`,s=t[n],a=t[o];return{[n]:{url:s},[o]:{url:a}}}getMediaContainer(t){let n=t.images||{},o=t.thumbnailImage,s=go.GALLERY in n?go.GALLERY:go.PRIMARY;if(!n[s]&&!o)return null;o&&(n[s]=this.buildFallbackCarouselImage(o));let a=n[s];if(Array.isArray(a)){for(let c in a)if(a[c]&&Object.prototype.hasOwnProperty.call(a[c],this.CAROUSEL_IMAGE_FORMAT))return a[c]}return a}trackRecommendation(){this.product.attributionToken&&this.googleRetailService.trackProduct(this.product)}};e.\u0275fac=function(n){return new(n||e)(O(qn),O(Ci),O(Vu),O(Ho),O(qm))},e.\u0275cmp=F({type:e,selectors:[["sip-product-carousel-item"]],inputs:{product:"product",showPriceOnTop:"showPriceOnTop",displayProductTitles:"displayProductTitles",displayProductPrices:"displayProductPrices",bvContainerPrefix:"bvContainerPrefix",addToCart:"addToCart",routeType:"routeType"},decls:1,vars:1,consts:[["missingImageTpl",""],["setPostalCodeButton",""],["class","item product-item","tabindex","0",4,"ngIf"],["tabindex","0",1,"item","product-item"],[1,"thumb"],[3,"customClass","minimumRequiredAge",4,"ngIf"],["tabindex","0",3,"click","routerLink"],["format","carousel",3,"container","loading",4,"ngIf","ngIfElse"],[3,"decalData"],["class","product-title-delivery",4,"ngIf"],["class","shipping-purchase-method-exception-message",4,"ngIf"],[4,"ngIf"],["class","item-price",4,"ngIf"],[3,"product",4,"ngIf"],[4,"ngIf","ngIfElse"],[3,"customClass","minimumRequiredAge"],["format","carousel",3,"container","loading"],[3,"src","alt"],[1,"product-title-delivery"],[1,"shipping-purchase-method-exception-message"],[1,"costco-icons","costco-icon-membership-restrictions"],[1,"item-price"],[3,"product","isDetailPage",4,"ngIf"],[1,"costco-icons","costco-icon-member-only"],[3,"product","isDetailPage"],[1,"item-name","notranslate"],["class","item-name en-name notranslate",4,"ngIf"],[1,"item-name","en-name","notranslate"],[3,"product"],[3,"route","product",4,"ngIf"],[1,"add-to-cart-wrapper"],[3,"product","route","addToCartUrl","addToCartFeature","addToCartFromWishList"],[3,"route","product"],["class","btn btn-primary btn-set-postal-code",3,"click",4,"ngIf"],[1,"btn","btn-primary","btn-set-postal-code",3,"click"]],template:function(n,o){n&1&&v(0,cE,23,23,"div",2),n&2&&l("ngIf",o.product)},dependencies:[W,Df,If,Nf,Ef,On,ft,Pf,Vm,q,xt,Ku],styles:['.costco-icon-member-only[_ngcontent-%COMP%]{color:#e51937;font-size:16px}.costco-icon-member-only[_ngcontent-%COMP%] + span[_ngcontent-%COMP%]{font-size:16px;margin-left:4px}.costco-icon-membership-restrictions[_ngcontent-%COMP%]{color:#e51937;font-size:16px}.costco-icon-membership-restrictions[_ngcontent-%COMP%] + span[_ngcontent-%COMP%]{font-size:16px;margin-left:4px}.costco-icon-shipping-restrictions[_ngcontent-%COMP%]{color:#e51937;font-size:16px}.costco-icon-shipping-restrictions[_ngcontent-%COMP%] + span[_ngcontent-%COMP%]{font-size:16px;margin-left:4px}[_nghost-%COMP%] .price-panel{float:none;display:block;text-align:left;clear:none}[_nghost-%COMP%] .lister-name, [_nghost-%COMP%] .lister-name-en{color:inherit;display:block;max-height:54px;line-height:18px;display:-webkit-box;overflow:hidden;text-overflow:ellipsis;-webkit-box-orient:vertical;-webkit-line-clamp:3}[_nghost-%COMP%] .add-to-cart{display:-webkit-flex;-webkit-flex-flow:row wrap;display:flex;flex-flow:row wrap;margin-top:10px}[_nghost-%COMP%] .add-to-cart__qty, [_nghost-%COMP%] .add-to-cart__btn, [_nghost-%COMP%] .add-to-cart__qty .input-group{width:100%}[_nghost-%COMP%] .add-to-cart .button-wrapper{width:100%;margin-top:8px}[_nghost-%COMP%] .add-to-cart .input-plp{width:100%}@media screen and (min-width: 1400px){[_nghost-%COMP%] .add-to-cart{justify-content:space-between}[_nghost-%COMP%] .add-to-cart .input-plp{width:50%}[_nghost-%COMP%] .add-to-cart .button-wrapper{width:calc(50% - 20px);margin-top:0}[_nghost-%COMP%] .add-to-cart__btn{float:right;font-size:16px}}[_nghost-%COMP%] .add-to-cart__minus, [_nghost-%COMP%] .add-to-cart__plus{font-size:16px;padding:0;margin-top:-1px;border:1px solid #cccccc}[_nghost-%COMP%] .add-to-cart__input{font-size:16px;border:1px solid #cccccc;width:100%}@media screen and (min-width: 1400px){[_nghost-%COMP%] .add-to-cart__input{width:40px}}[_nghost-%COMP%] .items-in-cart, [_nghost-%COMP%] .qty-status, [_nghost-%COMP%] .min-qty-status{text-align:left;font-size:16px;color:green;padding:0 0 10px}[_nghost-%COMP%] .items-in-cart, [_nghost-%COMP%] .qty-status, [_nghost-%COMP%] .max-qty-status{text-align:left;font-size:16px;color:green;padding:0 0 10px}[_nghost-%COMP%] .items-in-cart{width:100%;text-align:center}@media screen and (min-width: 1400px){[_nghost-%COMP%] .items-in-cart{clear:both}}[_nghost-%COMP%] .qty-selector{width:100%}@media screen and (min-width: 1400px){[_nghost-%COMP%] .qty-selector{width:50%;float:left}}[_nghost-%COMP%] .qty-selector .qty-selector__input{width:100%}@media screen and (min-width: 1400px){[_nghost-%COMP%] .qty-selector .qty-selector__input{min-width:40px}}[_nghost-%COMP%] .qty-selector .form-control{text-align:center}@media screen and (max-width: 1024px){[_nghost-%COMP%] .qty{width:100px}}[_nghost-%COMP%] .product-list-item--grid .add-to-cart__qty.in-cart{width:100%}[_nghost-%COMP%] .product-list-item--grid .price-panel{float:none;display:block;text-align:left;clear:none;margin:0;max-width:100%;line-height:1.4}[_nghost-%COMP%] .product-list-item--grid .product-listing .price-panel{text-align:left}[_nghost-%COMP%] .product-list-item--grid .warning-in-cart, [_nghost-%COMP%] .product-list-item--grid .qty-warning-in-cart{text-align:center;font-size:16px;color:#e51937;padding:0 0 10px}[_nghost-%COMP%] .product-list-item--grid .product-price .original-price{font-size:24px;color:#333}@media screen and (min-width: 768px) and (max-width: 1024px),screen and (max-width: 767px){[_nghost-%COMP%] .product-list-item--grid .product-price .original-price{font-size:20px}}[_nghost-%COMP%] .product-list-item--grid .product-price .incvat-price .from-price{padding-right:5px}[_nghost-%COMP%] .product-list-item--grid .product-price .free-shipping{font-size:16px;color:#707070;line-height:20px;padding-bottom:5px;font-weight:400}@media screen and (min-width: 768px) and (max-width: 1024px),screen and (max-width: 767px){[_nghost-%COMP%] .product-list-item--grid .product-price .free-shipping{font-size:14px}}@media screen and (min-width: 1024px){[_nghost-%COMP%] .product-list-item--list .add-to-cart{justify-content:flex-start}[_nghost-%COMP%] .product-list-item--list .add-to-cart__qty{width:120px;margin-right:12px}[_nghost-%COMP%] .product-list-item--list .add-to-cart__qty.in-cart{width:225px}[_nghost-%COMP%] .product-list-item--list .add-to-cart .qty-selector{float:left}[_nghost-%COMP%] .product-list-item--list .add-to-cart__btn{width:initial;min-width:90px}[_nghost-%COMP%] .product-list-item--list .add-to-cart .items-in-cart__text{display:block;width:225px}}.product-list-details[_ngcontent-%COMP%]{width:100%;display:block;text-align:left;font-size:16px;color:#0060a9;line-height:20px;padding-bottom:8px}.product-list-details[_ngcontent-%COMP%] .name[_ngcontent-%COMP%], .product-list-details[_ngcontent-%COMP%] .name_en[_ngcontent-%COMP%]{margin-left:0}@media screen and (max-width: 767px){.product-list-details[_ngcontent-%COMP%] .name_en[_ngcontent-%COMP%]{display:none}}.product-image[_ngcontent-%COMP%]{position:relative;min-height:150px}.out-of-stock[_ngcontent-%COMP%] .product-image[_ngcontent-%COMP%]{position:relative}.out-of-stock[_ngcontent-%COMP%] .product-image[_ngcontent-%COMP%] a[_ngcontent-%COMP%]{opacity:.3}.out-of-stock[_ngcontent-%COMP%] .product-image[_ngcontent-%COMP%] .stock-status[_ngcontent-%COMP%]{position:absolute;top:calc(50% - 24px);width:100%;left:0;font-size:21px;background:#eaeaea;opacity:.7;z-index:1800;height:48px}.out-of-stock[_ngcontent-%COMP%] .product-image[_ngcontent-%COMP%] .stock-status[_ngcontent-%COMP%] .out-of-stock-message[_ngcontent-%COMP%]{color:#5f5f5f;padding-top:8px;text-align:center}.price-panel-login[_ngcontent-%COMP%]{display:block;float:none;clear:none;margin:0;text-align:left;line-height:20px;padding-bottom:5px;color:#707070;text-transform:capitalize;font-size:16px}.price-panel-login[_ngcontent-%COMP%] .costco-icon-member-only[_ngcontent-%COMP%]{color:#e51937;font-size:12px}.price-panel-login[_ngcontent-%COMP%] .costco-icon-member-only[_ngcontent-%COMP%] + span[_ngcontent-%COMP%]{vertical-align:text-top}.price-panel-login[_ngcontent-%COMP%] .costco-icon-membership-restrictions[_ngcontent-%COMP%]{color:#e51937;font-size:12px}.price-panel-login[_ngcontent-%COMP%] .costco-icon-membership-restrictions[_ngcontent-%COMP%] + span[_ngcontent-%COMP%]{vertical-align:text-top}.price-panel-login[_ngcontent-%COMP%] .costco-icon-shipping-restrictions[_ngcontent-%COMP%]{color:#e51937;font-size:12px}.price-panel-login[_ngcontent-%COMP%] .costco-icon-shipping-restrictions[_ngcontent-%COMP%] + span[_ngcontent-%COMP%]{vertical-align:text-top}.product-summary-container[_ngcontent-%COMP%]{display:none}[_nghost-%COMP%] .tire-product-summary-container{display:block}[_nghost-%COMP%] .tire-product-summary-container .tire-summary__wide{columns:2;-webkit-columns:2;-moz-columns:2}[_nghost-%COMP%] .tire-product-summary-container .result-info--column{width:100%;float:left;padding-right:40px;margin:0;line-height:normal;font-size:16px}[_nghost-%COMP%] .tire-product-summary-container .result-info--column .list-value{display:contents;font-weight:700}[_nghost-%COMP%] .tire-product-summary-container .result-info--column .list-value:after{content:"";display:table;clear:both}[_nghost-%COMP%] .tire-product-summary-container .result-info--column .list-title{font-weight:400;display:inline-block;margin:0 3px 6px 0}@media screen and (min-width: 768px) and (max-width: 1023px){[_nghost-%COMP%] .tire-product-summary-container .result-info--column{padding-right:5px;font-size:14px}[_nghost-%COMP%] .tire-product-summary-container .result-info--column .list-head{margin:0 3px 0 0}}@media screen and (max-width: 767px){[_nghost-%COMP%] .tire-product-summary-container .result-info--column{padding-right:0;font-size:14px}}[_nghost-%COMP%] .tire-product-summary-container:after{display:block;clear:both;content:""}@supports (-ms-ime-align: auto){[_nghost-%COMP%] .tire-product-summary-container .result-info--column .list-value{display:inline}}[_nghost-%COMP%] .tire-product-summary-container{display:block;color:#333;margin-top:16px;margin-bottom:8px;font-size:16px}[_nghost-%COMP%] .product-list-item--grid .tire-product-summary-container{display:none}.product-price[_ngcontent-%COMP%] .discount-info[_ngcontent-%COMP%], .promo[_ngcontent-%COMP%]{font-size:14px;font-weight:700;color:green;line-height:20px;padding-bottom:5px;margin-bottom:8px}@media screen and (min-width: 768px) and (max-width: 1024px),screen and (max-width: 767px){.product-price[_ngcontent-%COMP%] .discount-info[_ngcontent-%COMP%], .promo[_ngcontent-%COMP%]{font-size:14px}}.product-list-item[_ngcontent-%COMP%] .product-image--wrapper[_ngcontent-%COMP%]{display:block;margin-bottom:16px}.product-list-item[_ngcontent-%COMP%] .btn-set-postal-code[_ngcontent-%COMP%]{font-size:16px}.product-list-item--list[_ngcontent-%COMP%] .product-image[_ngcontent-%COMP%]{display:inline-block;width:calc(100% / 3);margin-right:20px}.product-list-item--list[_ngcontent-%COMP%] .product-image[_ngcontent-%COMP%] .product-image--wrapper[_ngcontent-%COMP%]{display:block;float:none;clear:none;margin:0 auto}.product-list-item--list[_ngcontent-%COMP%] .product-image[_ngcontent-%COMP%] .product-image--wrapper[_ngcontent-%COMP%] img[_ngcontent-%COMP%]{max-height:200px}.product-list-item--list[_ngcontent-%COMP%] .product-info-wrapper[_ngcontent-%COMP%]{display:inline-block;vertical-align:top;width:calc(100% * 2/3 - 20px)}.product-list-item--list[_ngcontent-%COMP%] .product-info-wrapper[_ngcontent-%COMP%] .price-panel[_ngcontent-%COMP%], .product-list-item--list[_ngcontent-%COMP%] .product-info-wrapper[_ngcontent-%COMP%] .price-panel-login[_ngcontent-%COMP%]{text-align:left;float:none;clear:both;line-height:inherit;margin-left:inherit}.product-list-item--list[_ngcontent-%COMP%] .product-list-warehouse-only[_ngcontent-%COMP%], .product-list-item--list[_ngcontent-%COMP%] .product-list-details[_ngcontent-%COMP%]{display:inline-block}.product-list-item--list[_ngcontent-%COMP%] .shipping-include[_ngcontent-%COMP%]{clear:both;float:right;color:#025ea9}.product-list-item--list[_ngcontent-%COMP%] .product-summary-container[_ngcontent-%COMP%]{display:inline-block;color:#333;margin-bottom:8px;font-size:16px}@media screen and (min-width: 1024px){.product-list-item--list[_ngcontent-%COMP%] .product-image[_ngcontent-%COMP%]{width:30%}.product-list-item--list[_ngcontent-%COMP%] .product-info-wrapper[_ngcontent-%COMP%]{width:calc(70% - 20px);padding:0}.product-list-item--list[_ngcontent-%COMP%] .product-image--wrapper[_ngcontent-%COMP%]{width:200
40px}.product-list-item--list[_ngcontent-%COMP%] .product-image--wrapper[_ngcontent-%COMP%] img[_ngcontent-%COMP%]{display:inherit;margin:0 auto;max-height:200px}}sip-age-restriction-overlay[_ngcontent-%COMP%]{position:absolute;z-index:1;top:50%;left:50%;transform:translate(-50%,-50%);width:100%;height:100%}.shipping-purchase-method-exception-message[_ngcontent-%COMP%]{color:green;font-weight:700;display:block}[_nghost-%COMP%] .product-item[_ngcontent-%COMP%] .product-price[_ngcontent-%COMP%] .original-price[_ngcontent-%COMP%]{font-size:24px;color:#333}[_nghost-%COMP%] .product-item.item[_ngcontent-%COMP%]{padding:10px 8px}[_nghost-%COMP%] .product-item[_ngcontent-%COMP%] .product-price[_ngcontent-%COMP%] .free-shipping[_ngcontent-%COMP%]{font-size:16px;color:#707070;line-height:20px;padding-bottom:5px;font-weight:400}[_nghost-%COMP%] .product-title-delivery[_ngcontent-%COMP%]{color:#005dab;margin-bottom:5px;font-weight:700;font-size:large}[_nghost-%COMP%] .item-price[_ngcontent-%COMP%]{margin:0}[_nghost-%COMP%] .costco-carousel-component[_ngcontent-%COMP%]{margin:10px 10px 0;border-top:1px solid #cccccc}[_nghost-%COMP%] .thumb[_ngcontent-%COMP%]{max-width:300px;justify-self:center}[_nghost-%COMP%] .item-name[_ngcontent-%COMP%]{margin:0;text-transform:capitalize;height:auto;font-weight:400;text-align:left}[_nghost-%COMP%] .item-name[_ngcontent-%COMP%] a[_ngcontent-%COMP%]{color:#005dab;line-height:20px;font-size:16px} .button-wrapper{width:100%} .input-plp{width:100%}@media screen and (min-width: 1400px){ .button-wrapper{width:calc(50% - 20px)} .input-plp{width:50%}} .carousel__item .add-to-cart__btn{float:right} .carousel__item .qty-selector .qty-selector__input{width:100%} .carousel__item .add-to-cart{display:-webkit-flex;-webkit-flex-flow:row wrap;display:flex;flex-flow:row wrap;margin-top:10px} .carousel__item .add-to-cart__qty, .carousel__item .add-to-cart__btn, .carousel__item .add-to-cart__qty .input-group{width:100%}@media screen and (min-width: 1400px){ .carousel__item .add-to-cart{justify-content:space-between} .carousel__item .add-to-cart__qty{width:50%} .carousel__item .add-to-cart__btn{float:right}} .carousel__item .add-to-cart__minus, .carousel__item .add-to-cart__plus{font-size:16px;padding:0;margin-top:-1px;border:1px solid #cccccc} .carousel__item .add-to-cart__input{font-size:16px;border:1px solid #cccccc;width:100%}@media screen and (min-width: 1400px){ .carousel__item .add-to-cart__input{width:40px}} .carousel__item .items-in-cart{color:green;font-size:16px;padding:10px 0;flex-flow:row wrap} .overlay-carousel{position:absolute}'],changeDetection:0});let i=e;return i})();function pE(i,e){if(i&1&&P(0,"sip-product-carousel-item",4),i&2){let r=e.ngIf,t=C().ngIf;l("product",t)("addToCart",r.addToCart)}}function lE(i,e){if(i&1&&(B(0),v(1,pE,1,2,"sip-product-carousel-item",3),w(2,"async"),U()),i&2){let r=C(2);d(),l("ngIf",T(2,1,r.data$))}}function dE(i,e){if(i&1&&(v(0,lE,3,3,"ng-container",2),w(1,"async")),i&2){let r=e.item;l("ngIf",T(1,1,r))}}var ap=(()=>{let e=class e extends im{constructor(t,n,o,s,a,c){super(n,o),this.translationService=t,this.componentData=n,this.productService=o,this.sipRoutingService=s,this.postalCodeService=a,this.platformId=c,this.hidden=!1,this.hasTitle=!0,this.includeH2Tag=!1,this.isPLPPage=new RegExp("(/c/(?!.*/p/))"),this.data$=this.componentData.data$.pipe(j(Boolean),x(p=>e.normalizeComponentData(p))),this.title$=this.data$.pipe(A(p=>{let m=p.typeCode==="CostcoTopSellerCarouselComponent";return this.sipRoutingService.currentUrl$.pipe(A(_=>{let y=this.isPLPPage.test(_);return this.includeH2Tag=m&&y,(m?this.translationService.translate("topseller.carousel.title",{0:p.title||""}):D(p.title)).pipe(Ot(k=>{this.hasTitle=!!k}))}))})),this.items$=ae([this.data$,this.postalCodeService.getCookiePostalCodeForCurrentPage().pipe(X())]).pipe(A(([p])=>{if(p.products?.length)return D(p.products.map(m=>D(m)));{let m=p.productCodes?p.productCodes.trim().split(" "):[];if(m.length===0)return D([]).pipe(Ot(y=>{this.hidden=!0}));let _;return"useSolrSearch"in p?_=this.productService.fetch(m,{useSolrSearch:p.typeCode==="CostcoTopSellerCarouselComponent"||p.useSolrSearch,doStockCheck:p.doStockCheck||!1}):_=Tp(m.map(y=>this.productService.get(y,this.PRODUCT_SCOPE)).map(y=>y.pipe(j(E=>!!E),Ip(7e3),z(1),Ge(E=>(this.hidden=!0,Sn))))),_.pipe(Ge(y=>(this.hidden=!0,D([]))),x((y=[])=>y.map(E=>D(E))))}})),this.serverMode=pi(this.platformId),this.options$=this.componentData.data$.pipe(j(p=>!!p),x(p=>({lazyLoad:!this.serverMode&&String(p.lazyLoad)==="true",lazyLoadEager:parseInt(String(p.lazyLoadEager),10)})))}static normalizeComponentData(t){let n=R({},t);
40return"useSolrSearch"in n&&(n.useSolrSearch=String(t.useSolrSearch)==="true"),n.addToCart=String(t.addToCart)==="true",n.doStockCheck=String(t.doStockCheck)==="true",n}};e.\u0275fac=function(n){return new(n||e)(O(Rn),O(ee),O(Ui),O(lt),O(Bn),O(Ne))},e.\u0275cmp=F({type:e,selectors:[["sip-product-carousel"]],hostVars:4,hostBindings:function(n,o){n&2&&Xt("hidden",o.hidden)("has-title",o.hasTitle)},features:[ao],decls:4,vars:7,consts:[["carouselItem",""],[3,"title","items","template","options","includeH2Tag"],[4,"ngIf"],[3,"product","addToCart",4,"ngIf"],[3,"product","addToCart"]],template:function(n,o){if(n&1&&(P(0,"sip-product-carousel-base",1),w(1,"async"),v(2,dE,2,3,"ng-template",null,0,ne)),n&2){let s=Y(3);l("title",o.title$)("items",o.items$)("template",s)("options",T(1,5,o.options$))("includeH2Tag",o.includeH2Tag)}},dependencies:[W,_r,Cr,q],styles:["[_nghost-%COMP%]{display:block}"],changeDetection:0});let i=e;return i})();function uE(i,e){if(i&1&&P(0,"sip-product-carousel-item",4),i&2){let r=e.ngIf,t=C().ngIf;l("product",t)("displayProductPrices",r.displayProductPrices)("displayProductTitles",r.displayProductTitles)("addToCart",r.addToCart)}}function fE(i,e){if(i&1&&(B(0),v(1,uE,1,4,"sip-product-carousel-item",3),w(2,"async"),U()),i&2){let r=C(2);d(),l("ngIf",T(2,1,r.componentData$))}}function hE(i,e){if(i&1&&(v(0,fE,3,3,"ng-container",2),w(1,"async")),i&2){let r=e.item;l("ngIf",T(1,1,r))}}var _a=(()=>{let e=class e{constructor(t,n,o,s,a,c,p){this.component=t,this.current=n,this.referenceService=o,this.cms=s,this.activeCartService=a,this.postalCodeService=c,this.platformId=p,this.currentPageId$=this.cms.getCurrentPage().pipe(x(m=>m.pageId)),this.componentData$=this.component.data$,this.title$=this.componentData$.pipe(x(m=>m.title),j(Boolean),_t(1)),this.serverMode=pi(this.platformId),this.options$=this.component.data$.pipe(j(m=>!!m),x(m=>({lazyLoad:!this.serverMode&&String(m.lazyLoad)==="true",lazyLoadEager:parseInt(String(m.lazyLoadEager),10)}))),this.currentProductCodes$=this.currentPageId$.pipe(A(m=>{switch(m){case jo.CART_PAGE:return this.activeCartService.getEntries().pipe(j(_=>_.length>0),x(_=>_.map(y=>y.product.code)));case dt.PDP_TIRES:case dt.PDP:return this.current.getProduct().pipe(j(Boolean),x(_=>[_.code]));default:return D([])}}),X()),this.items$=ae([this.currentProductCodes$.pipe(X((m,_)=>jf.sameMembers(m,_))),this.componentData$.pipe(X((m,_)=>m.productReferenceTypes===_.productReferenceTypes&&m.maximumNumberProducts===_.maximumNumberProducts)),this.currentPageId$.pipe(X()),this.postalCodeService.getCookiePostalCodeForCurrentPage().pipe(X())]).pipe(A(([m,_,y])=>this.getProducts(m,_.productReferenceTypes,_.maximumNumberProducts,y)))}getProducts(t,n,o,s){return this.getProductReferences(t,n,o,s).pipe(j(Boolean),X(),x(a=>a.map(c=>D(c.target))),_t(1))}getProductReferences(t,n,o,s){return this.referenceService.get(t,n,o,s)}};e.\u0275fac=function(n){return new(n||e)(O(ee),O(An),O(us),O(xe),O(Qt),O(Bn),O(Ne))},e.\u0275cmp=F({type:e,selectors:[["sip-product-references"]],decls:4,vars:6,consts:[["carouselItem",""],[3,"title","items","template","options"],[4,"ngIf"],[3,"product","displayProductPrices","displayProductTitles","addToCart",4,"ngIf"],[3,"product","displayProductPrices","displayProductTitles","addToCart"]],template:function(n,o){if(n&1&&(P(0,"sip-product-carousel-base",1),w(1,"async"),v(2,hE,2,3,"ng-template",null,0,ne)),n&2){let s=Y(3);l("title",o.title$)("items",o.items$)("template",s)("options",T(1,4,o.options$))}},dependencies:[W,_r,Cr,q],encapsulation:2,changeDetection:0});let i=e;return i})();function gE(i,e){if(i&1&&P(0,"sip-product-carousel-item",4),i&2){let r=e.ngIf,t=C().ngIf;l("product",t)("showPriceOnTop",!1)("displayProductPrices",r.displayProductPrices)("displayProductTitles",r.displayProductTitles)}}function _E(i,e){if(i&1&&(B(0),v(1,gE,1,4,"sip-product-carousel-item",3),w(2,"async"),U()),i&2){let r=C(2);d(),l("ngIf",T(2,1,r.componentData$))}}function CE(i,e){if(i&1&&(v(0,_E,3,3,"ng-container",2),w(1,"async")),i&2){let r=e.item;l("ngIf",T(1,1,r))}}var ZC=(()=>{let e=class e extends _a{constructor(t,n,o,s,a,c,p,m,_,y){super(t,n,o,c,p,_,y),this.component=t,this.current=n,this.referenceService=o,this.recentlyViewedProductService=s,this.route=a,this.cms=c,this.activeCartService=p,this.routingService=m,this.postalCodeService=_,this.platformId=y,this.componentData$=this.component.data$.pipe(x(E=>e.normalizeComponentData(E))),this.recentlyViewedProductCodes$=ae([this.componentData$.pipe(j(E=>!!E),rt("maximumNumberProducts")),this.routingService.getRouterState().pipe(x(E=>
40E.state.params.productCode),X())]).pipe(x(([E,k])=>this.recentlyViewedProductService.getProductList(E,[k]).join("/")),_t(1),X()),this.items$=ae([this.recentlyViewedProductCodes$,this.componentData$.pipe(X((E,k)=>E.productReferenceTypes===k.productReferenceTypes&&E.maximumNumberProducts===k.maximumNumberProducts))]).pipe(j(([E,k])=>!!E),A(([E,k])=>this.getProducts([E],k.productReferenceTypes,k.maximumNumberProducts)))}static normalizeComponentData(t){return ie(R({},t),{displayProductTitles:String(t.displayProductTitles)==="true",displayProductPrices:String(t.displayProductPrices)==="true",popup:String(t.popup)==="true"})}getProductReferences(t,n,o,s){return this.referenceService.getMany(t[0],n,o)}};e.\u0275fac=function(n){return new(n||e)(O(ee),O(An),O(us),O(lu),O(In),O(xe),O(Qt),O(mi),O(Bn),O(Ne))},e.\u0275cmp=F({type:e,selectors:[["sip-recently-viewed-carousel-references"]],features:[ao],decls:4,vars:6,consts:[["carouselItem",""],[3,"title","items","template","options"],[4,"ngIf"],[3,"product","showPriceOnTop","displayProductPrices","displayProductTitles",4,"ngIf"],[3,"product","showPriceOnTop","displayProductPrices","displayProductTitles"]],template:function(n,o){if(n&1&&(P(0,"sip-product-carousel-base",1),w(1,"async"),v(2,CE,2,3,"ng-template",null,0,ne)),n&2){let s=Y(3);l("title",o.title$)("items",o.items$)("template",s)("options",T(1,4,o.options$))}},dependencies:[W,_r,Cr,q],encapsulation:2,changeDetection:0});let i=e;return i})();function yE(i,e){i&1&&(S(0,"li",3),P(1,"sip-skeleton",4)(2,"sip-skeleton",5),b())}var Hr=(()=>{let e=class e{constructor(){this.productCount=Array(4).fill(0).map(()=>0)}};e.\u0275fac=function(n){return new(n||e)},e.\u0275cmp=F({type:e,selectors:[["sip-product-carousel-skeleton"]],decls:3,vars:1,consts:[[1,"product-carousel-skeleton__title"],[1,"product-carousel-skeleton__container"],["class","product-carousel-skeleton__product",4,"ngFor","ngForOf"],[1,"product-carousel-skeleton__product"],[1,"product-carousel-skeleton__product-image"],[1,"product-carousel-skeleton__description"]],template:function(n,o){n&1&&(P(0,"sip-skeleton",0),S(1,"ul",1),v(2,yE,3,0,"li",2),b()),n&2&&(d(2),l("ngForOf",o.productCount))},dependencies:[qe,Dt],styles:[".product-carousel-skeleton__title[_ngcontent-%COMP%]{margin-top:15px;width:25%}@media screen and (min-width: 1024px){.product-carousel-skeleton__title[_ngcontent-%COMP%]{height:50px}}@media screen and (max-width: 767px){.product-carousel-skeleton__title[_ngcontent-%COMP%]{height:20px}}.product-carousel-skeleton__container[_ngcontent-%COMP%]{width:100%;display:flex;flex-wrap:wrap}.product-carousel-skeleton__product[_ngcontent-%COMP%]{width:25%}@media screen and (min-width: 1024px){.product-carousel-skeleton__product-image[_ngcontent-%COMP%]{margin:15px;height:170px}}@media screen and (max-width: 767px){.product-carousel-skeleton__product-image[_ngcontent-%COMP%]{margin:10px;height:150px}}@media screen and (min-width: 1024px){.product-carousel-skeleton__description[_ngcontent-%COMP%]{margin:15px;height:100px}}@media screen and (max-width: 767px){.product-carousel-skeleton__description[_ngcontent-%COMP%]{margin:10px;height:50px}}"],changeDetection:0});let i=e;return i})();var XC=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({providers:[M({cmsComponents:{ProductCarouselComponent:{component:ap,skeletonComponent:Hr,disableSSR:!1},CostcoTopSellerCarouselComponent:{component:ap,skeletonComponent:Hr,disableSSR:!1},ProductReferencesComponent:{component:_a,skeletonComponent:Hr,disableSSR:!1},RecentlyViewedCarouselComponent:{component:ZC,skeletonComponent:Hr,disableSSR:!1}}})],imports:[$,Xn,Lf,Ff,pt,G,Mf,ht,Ae,gt,lf]});let i=e;return i})();function lp(){return{async:!1,breaks:!1,extensions:null,gfm:!0,hooks:null,pedantic:!1,renderer:null,silent:!1,tokenizer:null,walkTokens:null}}var yn=lp();function ry(i){yn=i}var oy=/[&<>"']/,vE=new RegExp(oy.source,"g"),sy=/[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/,SE=new RegExp(sy.source,"g"),bE={"&":"&","<":"<",">":">",'"':""","'":"'"},JC=i=>bE[i];function Gt(i,e){if(e){if(oy.test(i))return i.replace(vE,JC)}else if(sy.test(i))return i.replace(SE,JC);return i}var xE=/&(#(?:\d+)|(?:#x[0-9A-Fa-f]+)|(?:\w+));?/ig;function PE(i){return i.replace(xE,(e,r)=>(r=r.toLowerCase(),r==="colon"?":":r.charAt(0)==="#"?r.charAt(1)==="x"?String.fromCharCode(parseInt(r.substring(2),16)):String.fromCharCode(+r.substring(1)):""))}var ME=/(^|[^\[])\^/g;function Te(i,e){let r=typeof i=="string"?i:i.source;e=e||"";let t={replace:(n,o)=>
vendor: 8,739 bytes, lines 40-54
40{let s=typeof o=="string"?o:o.source;return s=s.replace(ME,"$1"),r=r.replace(n,s),t},getRegex:()=>new RegExp(r,e)};return t}function ey(i){try{i=encodeURI(i).replace(/%25/g,"%")}catch{return null}return i}var qr={exec:()=>null};function ty(i,e){let r=i.replace(/\|/g,(o,s,a)=>{let c=!1,p=s;for(;--p>=0&&a[p]==="\\";)c=!c;return c?"|":" |"}),t=r.split(/ \|/),n=0;if(t[0].trim()||t.shift(),t.length>0&&!t[t.length-1].trim()&&t.pop(),e)if(t.length>e)t.splice(e);else for(;t.length<e;)t.push("");for(;n<t.length;n++)t[n]=t[n].trim().replace(/\\\|/g,"|");return t}function Ca(i,e,r){let t=i.length;if(t===0)return"";let n=0;for(;n<t;){let o=i.charAt(t-n-1);if(o===e&&!r)n++;else if(o!==e&&r)n++;else break}return i.slice(0,t-n)}function EE(i,e){if(i.indexOf(e[1])===-1)return-1;let r=0;for(let t=0;t<i.length;t++)if(i[t]==="\\")t++;else if(i[t]===e[0])r++;else if(i[t]===e[1]&&(r--,r<0))return t;return-1}function iy(i,e,r,t){let n=e.href,o=e.title?Gt(e.title):null,s=i[1].replace(/\\([\[\]])/g,"$1");if(i[0].charAt(0)!=="!"){t.state.inLink=!0;let a={type:"link",raw:r,href:n,title:o,text:s,tokens:t.inlineTokens(s)};return t.state.inLink=!1,a}return{type:"image",raw:r,href:n,title:o,text:Gt(s)}}function IE(i,e){let r=i.match(/^(\s+)(?:```)/);if(r===null)return e;let t=r[1];return e.split(` 41`).map(n=>{let o=n.match(/^\s+/);if(o===null)return n;let[s]=o;return s.length>=t.length?n.slice(t.length):n}).join(` 42`)}var yr=class{constructor(e){Fe(this,"options");Fe(this,"rules");Fe(this,"lexer");this.options=e||yn}space(e){let r=this.rules.block.newline.exec(e);if(r&&r[0].length>0)return{type:"space",raw:r[0]}}code(e){let r=this.rules.block.code.exec(e);if(r){let t=r[0].replace(/^ {1,4}/gm,"");return{type:"code",raw:r[0],codeBlockStyle:"indented",text:this.options.pedantic?t:Ca(t,` 43`)}}}fences(e){let r=this.rules.block.fences.exec(e);if(r){let t=r[0],n=IE(t,r[3]||"");return{type:"code",raw:t,lang:r[2]?r[2].trim().replace(this.rules.inline.anyPunctuation,"$1"):r[2],text:n}}}heading(e){let r=this.rules.block.heading.exec(e);if(r){let t=r[2].trim();if(/#$/.test(t)){let n=Ca(t,"#");(this.options.pedantic||!n||/ $/.test(n))&&(t=n.trim())}return{type:"heading",raw:r[0],depth:r[1].length,text:t,tokens:this.lexer.inline(t)}}}hr(e){let r=this.rules.block.hr.exec(e);if(r)return{type:"hr",raw:r[0]}}blockquote(e){let r=this.rules.block.blockquote.exec(e);if(r){let t=r[0].replace(/\n {0,3}((?:=+|-+) *)(?=\n|$)/g,` 44 $1`);t=Ca(t.replace(/^ *>[ \t]?/gm,""),` 45`);let n=this.lexer.state.top;this.lexer.state.top=!0;let o=this.lexer.blockTokens(t);return this.lexer.state.top=n,{type:"blockquote",raw:r[0],tokens:o,text:t}}}list(e){let r=this.rules.block.list.exec(e);if(r){let t=r[1].trim(),n=t.length>1,o={type:"list",raw:"",ordered:n,start:n?+t.slice(0,-1):"",loose:!1,items:[]};t=n?`\\d{1,9}\\${t.slice(-1)}`:`\\${t}`,this.options.pedantic&&(t=n?t:"[*+-]");let s=new RegExp(`^( {0,3}${t})((?:[ ][^\\n]*)?(?:\\n|$))`),a="",c="",p=!1;for(;e;){let m=!1;if(!(r=s.exec(e))||this.rules.block.hr.test(e))break;a=r[0],e=e.substring(a.length);let _=r[2].split(` 46`,1)[0].replace(/^\t+/,_e=>" ".repeat(3*_e.length)),y=e.split(` 47`,1)[0],E=0;this.options.pedantic?(E=2,c=_.trimStart()):(E=r[2].search(/[^ ]/),E=E>4?1:E,c=_.slice(E),E+=r[1].length);let k=!1;if(!_&&/^ *$/.test(y)&&(a+=y+` 48`,e=e.substring(y.length+1),m=!0),!m){let _e=new RegExp(`^ {0,${Math.min(3,E-1)}}(?:[*+-]|\\d{1,9}[.)])((?:[ ][^\\n]*)?(?:\\n|$))`),ze=new RegExp(`^ {0,${Math.min(3,E-1)}}((?:- *){3,}|(?:_ *){3,}|(?:\\* *){3,})(?:\\n+|$)`),st=new RegExp(`^ {0,${Math.min(3,E-1)}}(?:\`\`\`|~~~)`),Ze=new RegExp(`^ {0,${Math.min(3,E-1)}}#`);for(;e;){let ni=e.split(` 49`,1)[0];if(y=ni,this.options.pedantic&&(y=y.replace(/^ {1,4}(?=( {4})*[^ ])/g," ")),st.test(y)||Ze.test(y)||_e.test(y)||ze.test(e))break;if(y.search(/[^ ]/)>=E||!y.trim())c+=` 50`+y.slice(E);else{if(k||_.search(/[^ ]/)>=4||st.test(_)||Ze.test(_)||ze.test(_))break;c+=` 51`+y}!k&&!y.trim()&&(k=!0),a+=ni+` 52`,e=e.substring(ni.length+1),_=y.slice(E)}}o.loose||(p?o.loose=!0:/\n *\n *$/.test(a)&&(p=!0));let N=null,Q;this.options.gfm&&(N=/^\[[ xX]\] /.exec(c),N&&(Q=N[0]!=="[ ] ",c=c.replace(/^\[[ xX]\] +/,""))),o.items.push({type:"list_item",raw:a,task:!!N,checked:Q,loose:!1,text:c,tokens:[]}),o.raw+=a}o.items[o.items.length-1].raw=a.trimEnd(),o.items[o.items.length-1].text=c.trimEnd(),o.raw=o.raw.trimEnd();for(let m=0;m<o.items.length;m++)if(this.lexer.state.top=!1,o.items[m].tokens=this.lexer.blockTokens(o.items[m].text,[]),!o.loose){let _=o.items[m].tokens.filter(E=>E.type==="space"),y=_.length>0&&_.some(E=>/\n.*\n/.test(E.raw));o.loose=y}if(o.loose)for(let m=0;m<o.items.length;m++)o.items[m].loose=!0;return o}}html(e){let r=this.rules.block.html.exec(e);if(r)return{type:"html",block:!0,raw:r[0],pre:r[1]==="pre"||r[1]==="script"||r[1]==="style",text:r[0]}}def(e){let r=this.rules.block.def.exec(e);if(r){let t=r[1].toLowerCase().replace(/\s+/g," "),n=r[2]?r[2].replace(/^<(.*)>$/,"$1").replace(this.rules.inline.anyPunctuation,"$1"):"",o=r[3]?r[3].substring(1,r[3].length-1).replace(this.rules.inline.anyPunctuation,"$1"):r[3];return{type:"def",tag:t,raw:r[0],href:n,title:o}}}table(e){let r=this.rules.block.table.exec(e);if(!r||!/[:|]/.test(r[2]))return;let t=ty(r[1]),n=r[2].replace(/^\||\| *$/g,"").split("|"),o=r[3]&&r[3].trim()?r[3].replace(/\n[ \t]*$/,"").split(` 53`):[],s={type:"table",raw:r[0],header:[],align:[],rows:[]};if(t.length===n.length){for(let a of n)/^ *-+: *$/.test(a)?s.align.push("right"):/^ *:-+: *$/.test(a)?s.align.push("center"):/^ *:-+ *$/.test(a)?s.align.push("left"):s.align.push(null);for(let a of t)s.header.push({text:a,tokens:this.lexer.inline(a)});for(let a of o)s.rows.push(ty(a,s.header.length).map(c=>({text:c,tokens:this.lexer.inline(c)})));return s}}lheading(e){let r=this.rules.block.lheading.exec(e);if(r)return{type:"heading",raw:r[0],depth:r[2].charAt(0)==="="?1:2,text:r[1],tokens:this.lexer.inline(r[1])}}paragraph(e){let r=this.rules.block.paragraph.exec(e);if(r){let t=r[1].charAt(r[1].length-1)===` 54`?r[1].slice(0,-1):r[1];return{type:"paragraph",raw:r[0],text:t,tokens:this.lexer.inline(t)}}}text(e){let r=this.rules.block.text.exec(e);if(r)return{type:"text",raw:r[0],text:r[0],tokens:this.lexer.inline(r[0])}}escape(e){let r=this.rules.inline.escape.exec(e);if(r)return{type:"escape",raw:r[0],text:Gt(r[1])}}tag(e){let r=this.rules.inline.tag.exec(e);if(r)return!this.lexer.state.inLink&&/^<a /i.test(r[0])?this.lexer.state.inLink=!0:this.lexer.state.inLink&&/^<\/a>/i.test(r[0])&&(this.lexer.state.inLink=!1),!this.lexer.state.inRawBlock&&/^<(pre|code|kbd|script)(\s|>)/i.test(r[0])?this.lexer.state.inRawBlock=!0:this.lexer.state.inRawBlock&&/^<\/(pre|code|kbd|script)(\s|>)/i.test(r[0])&&(this.lexer.state.inRawBlock=!1),{type:"html",raw:r[0],inLink:this.lexer.state.inLink,inRawBlock:this.lexer.state.inRawBlock,block:!1,text:r[0]}}link(e){let r=this.rules.inline.link.exec(e);if(r){let t=r[2].trim();if(!this.options.pedantic&&/^</.test(t)){if(!/>$/.test(t))return;let s=Ca(t.slice(0,-1),"\\");if((t.length-s.length)%2===0)return}else{let s=EE(r[2],"()");if(s>-1){let c=(r[0].indexOf("!")===0?5:4)+r[1].length+s;r[2]=r[2].substring(0,s),r[0]=r[0].substring(0,c).trim(),r[3]=""}}let n=r[2],o="";if(this.options.pedantic){let s=/^([^'"]*[^\s])\s+(['"])(.*)\2/.exec(n);s&&(n=s[1],o=s[3])}else o=r[3]?r[3].slice(1,-1):"";return n=n.trim(),/^</.test(n)&&(this.options.pedantic&&!/>$/.test(t)?n=n.slice(1):n=n.slice(1,-1)),iy(r,{href:n&&n.replace(this.rules.inline.anyPunctuation,"$1"),title:o&&o.replace(this.rules.inline.anyPunctuation,"$1")},r[0],this.lexer)}}reflink(e,r){let t;if((t=this.rules.inline.reflink.exec(e))||(t=this.rules.inline.nolink.exec(e))){let n=(t[2]||t[1]).replace(/\s+/g," "),o=r[n.toLowerCase()];if(!o){let s=t[0].charAt(0);return{type:"text",raw:s,text:s}}return iy(t,o,t[0],this.lexer)}}emStrong(e,r,t=""){let n=this.rules.inline.emStrongLDelim.exec(e);if(!n||n[3]&&t.match(/[\p{L}\p{N}]/u))return;if(!(n[1]||n[2]||"")||!t||this.rules.inline.punctuation.exec(t)){let s=[...n[0]].length-1,a,c,p=s,m=0,_=n[0][0]==="*"?this.rules.inline.emStrongRDelimAst:this.rules.inline.emStrongRDelimUnd;for(_.lastIndex=0,r=r.slice(-1*e.length+s);(n=_.exec(r))!=null;){if(a=n[1]||n[2]||n[3]||n[4]||n[5]||n[6],!a)continue;if(c=[...a].length,n[3]||n[4]){p+=c;continue}else if((n[5]||n[6])&&s%3&&!((s+c)%3)){m+=c;continue}if(p-=c,p>0)continue;c=Math.min(c,c+p+m);let y=[...n[0]][0].length,E=e.slice(0,s+n.index+y+c);if(Math.min(s,c)%2){let N=E.slice(1,-1);return{type:"em",raw:E,text:N,tokens:this.lexer.inlineTokens(N)}}let k=E.slice(2,-2);return{type:"strong",raw:E,text:k,tokens:this.lexer.inlineTokens(k)}}}}codespan(e){let r=this.rules.inline.code.exec(e);if(r){let t=r[2].replace(/\n/g," "),n=/[^ ]/.test(t),o=/^ /.test(t)&&/ $/.test(t);
vendor: 6,412 bytes, lines 54-55
54return n&&o&&(t=t.substring(1,t.length-1)),t=Gt(t,!0),{type:"codespan",raw:r[0],text:t}}}br(e){let r=this.rules.inline.br.exec(e);if(r)return{type:"br",raw:r[0]}}del(e){let r=this.rules.inline.del.exec(e);if(r)return{type:"del",raw:r[0],text:r[2],tokens:this.lexer.inlineTokens(r[2])}}autolink(e){let r=this.rules.inline.autolink.exec(e);if(r){let t,n;return r[2]==="@"?(t=Gt(r[1]),n="mailto:"+t):(t=Gt(r[1]),n=t),{type:"link",raw:r[0],text:t,href:n,tokens:[{type:"text",raw:t,text:t}]}}}url(e){let r;if(r=this.rules.inline.url.exec(e)){let t,n;if(r[2]==="@")t=Gt(r[0]),n="mailto:"+t;else{let o;do o=r[0],r[0]=this.rules.inline._backpedal.exec(r[0])?.[0]??"";while(o!==r[0]);t=Gt(r[0]),r[1]==="www."?n="http://"+r[0]:n=r[0]}return{type:"link",raw:r[0],text:t,href:n,tokens:[{type:"text",raw:t,text:t}]}}}inlineText(e){let r=this.rules.inline.text.exec(e);if(r){let t;return this.lexer.state.inRawBlock?t=r[0]:t=Gt(r[0]),{type:"text",raw:r[0],text:t}}}},OE=/^(?: *(?:\n|$))+/,wE=/^( {4}[^\n]+(?:\n(?: *(?:\n|$))*)?)+/,TE=/^ {0,3}(`{3,}(?=[^`\n]*(?:\n|$))|~{3,})([^\n]*)(?:\n|$)(?:|([\s\S]*?)(?:\n|$))(?: {0,3}\1[~`]* *(?=\n|$)|$)/,Kr=/^ {0,3}((?:-[\t ]*){3,}|(?:_[ \t]*){3,}|(?:\*[ \t]*){3,})(?:\n+|$)/,kE=/^ {0,3}(#{1,6})(?=\s|$)(.*)(?:\n+|$)/,ay=/(?:[*+-]|\d{1,9}[.)])/,cy=Te(/^(?!bull |blockCode|fences|blockquote|heading|html)((?:.|\n(?!\s*?\n|bull |blockCode|fences|blockquote|heading|html))+?)\n {0,3}(=+|-+) *(?:\n+|$)/).replace(/bull/g,ay).replace(/blockCode/g,/ {4}/).replace(/fences/g,/ {0,3}(?:`{3,}|~{3,})/).replace(/blockquote/g,/ {0,3}>/).replace(/heading/g,/ {0,3}#{1,6}/).replace(/html/g,/ {0,3}<[^\n>]+>\n/).getRegex(),dp=/^([^\n]+(?:\n(?!hr|heading|lheading|blockquote|fences|list|html|table| +\n)[^\n]+)*)/,RE=/^[^\n]+/,mp=/(?!\s*\])(?:\\.|[^\[\]\\])+/,AE=Te(/^ {0,3}\[(label)\]: *(?:\n *)?([^<\s][^\s]*|<.*?>)(?:(?: +(?:\n *)?| *\n *)(title))? *(?:\n+|$)/).replace("label",mp).replace("title",/(?:"(?:\\"?|[^"\\])*"|'[^'\n]*(?:\n[^'\n]+)*\n?'|\([^()]*\))/).getRegex(),NE=Te(/^( {0,3}bull)([ \t][^\n]+?)?(?:\n|$)/).replace(/bull/g,ay).getRegex(),Sa="address|article|aside|base|basefont|blockquote|body|caption|center|col|colgroup|dd|details|dialog|dir|div|dl|dt|fieldset|figcaption|figure|footer|form|frame|frameset|h[1-6]|head|header|hr|html|iframe|legend|li|link|main|menu|menuitem|meta|nav|noframes|ol|optgroup|option|p|param|search|section|summary|table|tbody|td|tfoot|th|thead|title|tr|track|ul",up=/<!--(?:-?>|[\s\S]*?(?:-->|$))/,DE=Te("^ {0,3}(?:<(script|pre|style|textarea)[\\s>][\\s\\S]*?(?:</\\1>[^\\n]*\\n+|$)|comment[^\\n]*(\\n+|$)|<\\?[\\s\\S]*?(?:\\?>\\n*|$)|<![A-Z][\\s\\S]*?(?:>\\n*|$)|<!\\[CDATA\\[[\\s\\S]*?(?:\\]\\]>\\n*|$)|</?(tag)(?: +|\\n|/?>)[\\s\\S]*?(?:(?:\\n *)+\\n|$)|<(?!script|pre|style|textarea)([a-z][\\w-]*)(?:attribute)*? */?>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n *)+\\n|$)|</(?!script|pre|style|textarea)[a-z][\\w-]*\\s*>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n *)+\\n|$))","i").replace("comment",up).replace("tag",Sa).replace("attribute",/ +[a-zA-Z:_][\w.:-]*(?: *= *"[^"\n]*"| *= *'[^'\n]*'| *= *[^\s"'=<>`]+)?/).getRegex(),py=Te(dp).replace("hr",Kr).replace("heading"," {0,3}#{1,6}(?:\\s|$)").replace("|lheading","").replace("|table","").replace("blockquote"," {0,3}>").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html","</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag",Sa).getRegex(),FE=Te(/^( {0,3}> ?(paragraph|[^\n]*)(?:\n|$))+/).replace("paragraph",py).getRegex(),fp={blockquote:FE,code:wE,def:AE,fences:TE,heading:kE,hr:Kr,html:DE,lheading:cy,list:NE,newline:OE,paragraph:py,table:qr,text:RE},ny=Te("^ *([^\\n ].*)\\n {0,3}((?:\\| *)?:?-+:? *(?:\\| *:?-+:? *)*(?:\\| *)?)(?:\\n((?:(?! *\\n|hr|heading|blockquote|code|fences|list|html).*(?:\\n|$))*)\\n*|$)").replace("hr",Kr).replace("heading"," {0,3}#{1,6}(?:\\s|$)").replace("blockquote"," {0,3}>").replace("code"," {4}[^\\n]").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html","</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag",Sa).getRegex(),LE=ie(R({},fp),{table:ny,paragraph:Te(dp).replace("hr",Kr).replace("heading"," {0,3}#{1,6}(?:\\s|$)").replace("|lheading","").replace("table",ny).replace("blockquote"," {0,3}>").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html","</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag",Sa).getRegex()}),jE=ie(R({},fp),{html:Te(`^ *(?:comment *(?:\\n|\\s*$)|<(tag)[\\s\\S]+?</\\1> *(?:\\n{2,}|\\s*$)|<tag(?:"[^"]*"|'[^']*'|\\s[^'"/>\\s]*)*?/?> *(?:\\n{2,}|\\s*$))`).replace("comment",up).replace(/tag/g,"(?!(?:a|em|strong|small|s|cite|q|dfn|abbr|data|time|code|var|samp|kbd|sub|sup|i|b|u|mark|ruby|rt|rp|bdi|bdo|span|br|wbr|ins|del|img)\\b)\\w+(?!:|[^\\w\\s@]*@)\\b").getRegex(),def:/^ *\[([^\]]+)\]: *<?([^\s>]+)>?(?: +(["(][^\n]+[")]))? *(?:\n+|$)/,heading:/^(#{1,6})(.*)(?:\n+|$)/,fences:qr,lheading:/^(.+?)\n {0,3}(=+|-+) *(?:\n+|$)/,paragraph:Te(dp).replace("hr",Kr).replace("heading",` *#{1,6} *[^ 55]`).replace("lheading",cy).replace("|table","").replace("blockquote"," {0,3}>").replace("|fences","").replace("|list","").replace("|html","").replace("|tag","").getRegex()}),ly=/^\\([!"#$%&'()*+,\-./:;<=>?@\[\]\\^_`{|}~])/,$E=/^(`+)([^`]|[^`][\s\S]*?[^`])\1(?!`)/,dy=/^( {2,}|\\)\n(?!\s*$)/,BE=/^(`+|[^`])(?:(?= {2,}\n)|[\s\S]*?(?:(?=[\\<!\[`*_]|\b_|$)|[^ ](?= {2,}\n)))/,Qr="\\p{P}\\p{S}",UE=Te(/^((?![*_])[\spunctuation])/,"u").replace(/punctuation/g,Qr).getRegex(),zE=/\[[^[\]]*?\]\([^\(\)]*?\)|`[^`]*?`|<[^<>]*?>/g,GE=Te(/^(?:\*+(?:((?!\*)[punct])|[^\s*]))|^_+(?:((?!_)[punct])|([^\s_]))/,"u").replace(/punct/g,Qr).getRegex(),HE=Te("^[^_*]*?__[^_*]*?\\*[^_*]*?(?=__)|[^*]+(?=[^*])|(?!\\*)[punct](\\*+)(?=[\\s]|$)|[^punct\\s](\\*+)(?!\\*)(?=[punct\\s]|$)|(?!\\*)[punct\\s](\\*+)(?=[^punct\\s])|[\\s](\\*+)(?!\\*)(?=[punct])|(?!\\*)[punct](\\*+)(?!\\*)(?=[punct])|[^punct\\s](\\*+)(?=[^punct\\s])","gu").replace(/punct/g,Qr).getRegex(),VE=Te("^[^_*]*?\\*\\*[^_*]*?_[^_*]*?(?=\\*\\*)|[^_]+(?=[^_])|(?!_)[punct](_+)(?=[\\s]|$)|[^punct\\s](_+)(?!_)(?=[punct\\s]|$)|(?!_)[punct\\s](_+)(?=[^punct\\s])|[\\s](_+)(?!_)(?=[punct])|(?!_)[punct](_+)(?!_)(?=[punct])","gu").replace(/punct/g,Qr).getRegex(),qE=Te(/\\([punct])/,"gu").replace(/punct/g,Qr).getRegex(),WE=Te(
vendor: 16,384 bytes, lines 55-84
55/^<(scheme:[^\s\x00-\x1f<>]*|email)>/).replace("scheme",/[a-zA-Z][a-zA-Z0-9+.-]{1,31}/).replace("email",/[a-zA-Z0-9.!#$%&'*+/=?^_`{|}~-]+(@)[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)+(?![-_])/).getRegex(),KE=Te(up).replace("(?:-->|$)","-->").getRegex(),QE=Te("^comment|^</[a-zA-Z][\\w:-]*\\s*>|^<[a-zA-Z][\\w-]*(?:attribute)*?\\s*/?>|^<\\?[\\s\\S]*?\\?>|^<![a-zA-Z]+\\s[\\s\\S]*?>|^<!\\[CDATA\\[[\\s\\S]*?\\]\\]>").replace("comment",KE).replace("attribute",/\s+[a-zA-Z:_][\w.:-]*(?:\s*=\s*"[^"]*"|\s*=\s*'[^']*'|\s*=\s*[^\s"'=<>`]+)?/).getRegex(),va=/(?:\[(?:\\.|[^\[\]\\])*\]|\\.|`[^`]*`|[^\[\]\\`])*?/,YE=Te(/^!?\[(label)\]\(\s*(href)(?:\s+(title))?\s*\)/).replace("label",va).replace("href",/<(?:\\.|[^\n<>\\])+>|[^\s\x00-\x1f]*/).replace("title",/"(?:\\"?|[^"\\])*"|'(?:\\'?|[^'\\])*'|\((?:\\\)?|[^)\\])*\)/).getRegex(),my=Te(/^!?\[(label)\]\[(ref)\]/).replace("label",va).replace("ref",mp).getRegex(),uy=Te(/^!?\[(ref)\](?:\[\])?/).replace("ref",mp).getRegex(),ZE=Te("reflink|nolink(?!\\()","g").replace("reflink",my).replace("nolink",uy).getRegex(),hp={_backpedal:qr,anyPunctuation:qE,autolink:WE,blockSkip:zE,br:dy,code:$E,del:qr,emStrongLDelim:GE,emStrongRDelimAst:HE,emStrongRDelimUnd:VE,escape:ly,link:YE,nolink:uy,punctuation:UE,reflink:my,reflinkSearch:ZE,tag:QE,text:BE,url:qr},XE=ie(R({},hp),{link:Te(/^!?\[(label)\]\((.*?)\)/).replace("label",va).getRegex(),reflink:Te(/^!?\[(label)\]\s*\[([^\]]*)\]/).replace("label",va).getRegex()}),cp=ie(R({},hp),{escape:Te(ly).replace("])","~|])").getRegex(),url:Te(/^((?:ftp|https?):\/\/|www\.)(?:[a-zA-Z0-9\-]+\.?)+[^\s<]*|^email/,"i").replace("email",/[A-Za-z0-9._+-]+(@)[a-zA-Z0-9-_]+(?:\.[a-zA-Z0-9-_]*[a-zA-Z0-9])+(?![-_])/).getRegex(),_backpedal:/(?:[^?!.,:;*_'"~()&]+|\([^)]*\)|&(?![a-zA-Z0-9]+;$)|[?!.,:;*_'"~)]+(?!$))+/,del:/^(~~?)(?=[^\s~])([\s\S]*?[^\s~])\1(?=[^~]|$)/,text:/^([`~]+|[^`~])(?:(?= {2,}\n)|(?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)|[\s\S]*?(?:(?=[\\<!\[`*~_]|\b_|https?:\/\/|ftp:\/\/|www\.|$)|[^ ](?= {2,}\n)|[^a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-](?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)))/}),JE=ie(R({},cp),{br:Te(dy).replace("{2,}","*").getRegex(),text:Te(cp.text).replace("\\b_","\\b_| {2,}\\n").replace(/\{2,\}/g,"*").getRegex()}),ya={normal:fp,gfm:LE,pedantic:jE},Vr={normal:hp,gfm:cp,breaks:JE,pedantic:XE},Ti=class i{constructor(e){Fe(this,"tokens");Fe(this,"options");Fe(this,"state");Fe(this,"tokenizer");Fe(this,"inlineQueue");this.tokens=[],this.tokens.links=Object.create(null),this.options=e||yn,this.options.tokenizer=this.options.tokenizer||new yr,this.tokenizer=this.options.tokenizer,this.tokenizer.options=this.options,this.tokenizer.lexer=this,this.inlineQueue=[],this.state={inLink:!1,inRawBlock:!1,top:!0};let r={block:ya.normal,inline:Vr.normal};this.options.pedantic?(r.block=ya.pedantic,r.inline=Vr.pedantic):this.options.gfm&&(r.block=ya.gfm,this.options.breaks?r.inline=Vr.breaks:r.inline=Vr.gfm),this.tokenizer.rules=r}static get rules(){return{block:ya,inline:Vr}}static lex(e,r){return new i(r).lex(e)}static lexInline(e,r){return new i(r).inlineTokens(e)}lex(e){e=e.replace(/\r\n|\r/g,` 56`),this.blockTokens(e,this.tokens);for(let r=0;r<this.inlineQueue.length;r++){let t=this.inlineQueue[r];this.inlineTokens(t.src,t.tokens)}return this.inlineQueue=[],this.tokens}blockTokens(e,r=[]){this.options.pedantic?e=e.replace(/\t/g," ").replace(/^ +$/gm,""):e=e.replace(/^( *)(\t+)/gm,(a,c,p)=>c+" ".repeat(p.length));let t,n,o,s;for(;e;)if(!(this.options.extensions&&this.options.extensions.block&&this.options.extensions.block.some(a=>(t=a.call({lexer:this},e,r))?(e=e.substring(t.raw.length),r.push(t),!0):!1))){if(t=this.tokenizer.space(e)){e=e.substring(t.raw.length),t.raw.length===1&&r.length>0?r[r.length-1].raw+=` 57`:r.push(t);continue}if(t=this.tokenizer.code(e)){e=e.substring(t.raw.length),n=r[r.length-1],n&&(n.type==="paragraph"||n.type==="text")?(n.raw+=` 58`+t.raw,n.text+=` 59`+t.text,this.inlineQueue[this.inlineQueue.length-1].src=n.text):r.push(t);continue}if(t=this.tokenizer.fences(e)){e=e.substring(t.raw.length),r.push(t);continue}if(t=this.tokenizer.heading(e)){e=e.substring(t.raw.length),r.push(t);continue}if(t=this.tokenizer.hr(e)){e=e.substring(t.raw.length),r.push(t);continue}if(t=this.tokenizer.blockquote(e)){e=e.substring(t.raw.length),r.push(t);continue}if(t=this.tokenizer.list(e)){e=e.substring(t.raw.length),r.push(t);continue}if(t=this.tokenizer.html(e)){e=e.substring(t.raw.length),r.push(t);continue}if(t=this.tokenizer.def(e)){e=e.substring(t.raw.length),n=r[r.length-1],n&&(n.type==="paragraph"||n.type==="text")?(n.raw+=` 60`+t.raw,n.text+=` 61`+t.raw,this.inlineQueue[this.inlineQueue.length-1].src=n.text):this.tokens.links[t.tag]||(this.tokens.links[t.tag]={href:t.href,title:t.title});continue}if(t=this.tokenizer.table(e)){e=e.substring(t.raw.length),r.push(t);continue}if(t=this.tokenizer.lheading(e)){e=e.substring(t.raw.length),r.push(t);continue}if(o=e,this.options.extensions&&this.options.extensions.startBlock){let a=1/0,c=e.slice(1),p;this.options.extensions.startBlock.forEach(m=>{p=m.call({lexer:this},c),typeof p=="number"&&p>=0&&(a=Math.min(a,p))}),a<1/0&&a>=0&&(o=e.substring(0,a+1))}if(this.state.top&&(t=this.tokenizer.paragraph(o))){n=r[r.length-1],s&&n.type==="paragraph"?(n.raw+=` 62`+t.raw,n.text+=` 63`+t.text,this.inlineQueue.pop(),this.inlineQueue[this.inlineQueue.length-1].src=n.text):r.push(t),s=o.length!==e.length,e=e.substring(t.raw.length);continue}if(t=this.tokenizer.text(e)){e=e.substring(t.raw.length),n=r[r.length-1],n&&n.type==="text"?(n.raw+=` 64`+t.raw,n.text+=` 65`+t.text,this.inlineQueue.pop(),this.inlineQueue[this.inlineQueue.length-1].src=n.text):r.push(t);continue}if(e){let a="Infinite loop on byte: "+e.charCodeAt(0);if(this.options.silent){console.error(a);break}else throw new Error(a)}}return this.state.top=!0,r}inline(e,r=[]){return this.inlineQueue.push({src:e,tokens:r}),r}inlineTokens(e,r=[]){let t,n,o,s=e,a,c,p;if(this.tokens.links){let m=Object.keys(this.tokens.links);if(m.length>0)for(;(a=this.tokenizer.rules.inline.reflinkSearch.exec(s))!=null;)m.includes(a[0].slice(a[0].lastIndexOf("[")+1,-1))&&(s=s.slice(0,a.index)+"["+"a".repeat(a[0].length-2)+"]"+s.slice(this.tokenizer.rules.inline.reflinkSearch.lastIndex))}for(;(a=this.tokenizer.rules.inline.blockSkip.exec(s))!=null;)s=s.slice(0,a.index)+"["+"a".repeat(a[0].length-2)+"]"+s.slice(this.tokenizer.rules.inline.blockSkip.lastIndex);for(;(a=this.tokenizer.rules.inline.anyPunctuation.exec(s))!=null;)s=s.slice(0,a.index)+"++"+s.slice(this.tokenizer.rules.inline.anyPunctuation.lastIndex);for(;e;)if(c||(p=""),c=!1,!(this.options.extensions&&this.options.extensions.inline&&this.options.extensions.inline.some(m=>(t=m.call({lexer:this},e,r))?(e=e.substring(t.raw.length),r.push(t),!0):!1))){if(t=this.tokenizer.escape(e)){e=e.substring(t.raw.length),r.push(t);continue}if(t=this.tokenizer.tag(e)){e=e.substring(t.raw.length),n=r[r.length-1],n&&t.type==="text"&&n.type==="text"?(n.raw+=t.raw,n.text+=t.text):r.push(t);continue}if(t=this.tokenizer.link(e)){e=e.substring(t.raw.length),r.push(t);continue}if(t=this.tokenizer.reflink(e,this.tokens.links)){e=e.substring(t.raw.length),n=r[r.length-1],n&&t.type==="text"&&n.type==="text"?(n.raw+=t.raw,n.text+=t.text):r.push(t);continue}if(t=this.tokenizer.emStrong(e,s,p)){e=e.substring(t.raw.length),r.push(t);continue}if(t=this.tokenizer.codespan(e)){e=e.substring(t.raw.length),r.push(t);continue}if(t=this.tokenizer.br(e)){e=e.substring(t.raw.length),r.push(t);continue}if(t=this.tokenizer.del(e)){e=e.substring(t.raw.length),r.push(t);continue}if(t=this.tokenizer.autolink(e)){e=e.substring(t.raw.length),r.push(t);continue}if(!this.state.inLink&&(t=this.tokenizer.url(e))){e=e.substring(t.raw.length),r.push(t);continue}if(o=e,this.options.extensions&&this.options.extensions.startInline){let m=1/0,_=e.slice(1),y;this.options.extensions.startInline.forEach(E=>{y=E.call({lexer:this},_),typeof y=="number"&&y>=0&&(m=Math.min(m,y))}),m<1/0&&m>=0&&(o=e.substring(0,m+1))}if(t=this.tokenizer.inlineText(o)){e=e.substring(t.raw.length),t.raw.slice(-1)!=="_"&&(p=t.raw.slice(-1)),c=!0,n=r[r.length-1],n&&n.type==="text"?(n.raw+=t.raw,n.text+=t.text):r.push(t);continue}if(e){let m="Infinite loop on byte: "+e.charCodeAt(0);if(this.options.silent){console.error(m);break}else throw new Error(m)}}return r}},xi=class{constructor(e){Fe(this,"options");this.options=e||yn}code(e,r,t){let n=(r||"").match(/^\S*/)?.[0];return e=e.replace(/\n$/,"")+` 66`,n?'<pre><code class="language-'+Gt(n)+'">'+(t?e:Gt(e,!0))+`</code></pre> 67`:"<pre><code>"+(t?e:Gt(e,!0))+`</code></pre> 68`}blockquote(e){return`<blockquote> 69${e}</blockquote> 70`}html(e,r){return e}heading(e,r,t){return`<h${r}>${e}</h${r}> 71`}hr(){return`<hr> 72`}list(e,r,t){let n=r?"ol":"ul",o=r&&t!==1?' start="'+t+'"':"";return"<"+n+o+`> 73`+e+"</"+n+`> 74`}listitem(e,r,t){return`<li>${e}</li> 75`}checkbox(e){return"<input "+(e?'checked="" ':"")+'disabled="" type="checkbox">'}paragraph(e){return`<p>${e}</p> 76`}table(e,r){return r&&(r=`<tbody>${r}</tbody>`),`<table> 77<thead> 78`+e+`</thead> 79`+r+`</table> 80`}tablerow(e){return`<tr> 81${e}</tr> 82`}tablecell(e,r){let t=r.header?"th":"td";return(r.align?`<${t} align="${r.align}">`:`<${t}>`)+e+`</${t}> 83`}strong(e){return`<strong>${e}</strong>`}em(e){return`<em>${e}</em>`}codespan(e){return`<code>${e}</code>`}br(){return"<br>"}del(e){return`<del>${e}</del>`}link(e,r,t){let n=ey(e);if(n===null)return t;e=n;let o='<a href="'+e+'"';return r&&(o+=' title="'+r+'"'),o+=">"+t+"</a>",o}image(e,r,t){let n=ey(e);if(n===null)return t;e=n;let o=`<img src="${e}" alt="${t}"`;return r&&(o+=` title="${r}"`),o+=">",o}text(e){return e}},Wr=class{strong(e){return e}em(e){return e}codespan(e){return e}del(e){return e}html(e){return e}text(e){return e}link(e,r,t){return""+t}image(e,r,t){return""+t}br(){return""}},ki=class i{constructor(e){Fe(this,"options");Fe(this,"renderer");Fe(this,"textRenderer");this.options=e||yn,this.options.renderer=this.options.renderer||new xi,this.renderer=this.options.renderer,this.renderer.options=this.options,this.textRenderer=new Wr}static parse(e,r){return new i(r).parse(e)}static parseInline(e,r){return new i(r).parseInline(e)}parse(e,r=!0){let t="";for(let n=0;n<e.length;n++){let o=e[n];if(this.options.extensions&&this.options.extensions.renderers&&this.options.extensions.renderers[o.type]){let s=o,a=this.options.extensions.renderers[s.type].call({parser:this},s);if(a!==!1||!["space","hr","heading","code","table","blockquote","list","html","paragraph","text"].includes(s.type)){t+=a||"";continue}}switch(o.type){case"space":continue;case"hr":{t+=this.renderer.hr();continue}case"heading":{let s=o;t+=this.renderer.heading(this.parseInline(s.tokens),s.depth,PE(this.parseInline(s.tokens,this.textRenderer)));continue}case"code":{let s=o;t+=this.renderer.code(s.text,s.lang,!!s.escaped);continue}case"table":{let s=o,a="",c="";for(let m=0;m<s.header.length;m++)c+=this.renderer.tablecell(this.parseInline(s.header[m].tokens),{header:!0,align:s.align[m]});a+=this.renderer.tablerow(c);let p="";for(let m=0;m<s.rows.length;m++){let _=s.rows[m];c="";for(let y=0;y<_.length;y++)c+=this.renderer.tablecell(this.parseInline(_[y].tokens),{header:!1,align:s.align[y]});p+=this.renderer.tablerow(c)}t+=this.renderer.table(a,p);continue}case"blockquote":{let s=o,a=this.parse(s.tokens);t+=this.renderer.blockquote(a);continue}case"list":{let s=o,a=s.ordered,c=s.start,p=s.loose,m="";for(let _=0;_<s.items.length;_++){let y=s.items[_],E=y.checked,k=y.task,N="";if(y.task){let Q=this.renderer.checkbox(!!E);p?y.tokens.length>0&&y.tokens[0].type==="paragraph"?(y.tokens[0].text=Q+" "+y.tokens[0].text,y.tokens[0].tokens&&y.tokens[0].tokens.length>0&&y.tokens[0].tokens[0].type==="text"&&(y.tokens[0].tokens[0].text=Q+" "+y.tokens[0].tokens[0].text)):y.tokens.unshift({type:"text",text:Q+" "}):N+=Q+" "}N+=this.parse(y.tokens,p),m+=this.renderer.listitem(N,k,!!E)}t+=this.renderer.list(m,a,c);continue}case"html":{let s=o;t+=this.renderer.html(s.text,s.block);continue}case"paragraph":{let s=o;t+=this.renderer.paragraph(this.parseInline(s.tokens));continue}case"text":{let s=o,a=s.tokens?this.parseInline(s.tokens):s.text;for(;n+1<e.length&&e[n+1].type==="text";)s=e[++n],a+=` 84`+(s.tokens?this.parseInline(s.tokens):s.text);t+=r?this.renderer.paragraph(a):a;continue}default:{let s='Token with "'+o.type+'" type was not found.';if(this.options.silent)return console.error(s),"";throw new Error(s)}}}return t}parseInline(e,r){r=r||this.renderer;let t="";for(let n=0;n<e.length;n++){let o=e[n];if(this.options.extensions&&this.options.extensions.renderers&&this.options.extensions.renderers[o.type]){let s=this.options.extensions.renderers[o.type].call({parser:this},o);if(s!==!1||!["escape","html","link","image","strong","em","codespan","br","del","text"].includes(o.type)){t+=s||"";continue}}switch(o.type){case"escape":{let s=o;t+=r.text(s.text);break}case"html":{let s=o;t+=r.html(s.text);break}case"link":{let s=o;t+=r.link(s.href,s.title,this.parseInline(s.tokens,r));break}case"image":{let s=o;t+=r.image(s.href,s.title,s.text);break}case"strong":{let s=o;t+=r.strong(this.parseInline(s.tokens,r));break}case"em":{let s=o;t+=r.em(this.parseInline(s.tokens,r));break}case"codespan":{let s=o;t+=r.codespan(s.text);break}case"br":{t+=r.br();break}case"del":{let s=o;t+=r.del(this.parseInline(s.tokens,r));break}case"text":{let s=o;t+=r.text(s.text);break}default:{let s='Token with "'+o.type+'" type was not found.';if(this.options.silent)return console.error(s),"";throw new Error(s)}}}return t}},_n=class{constructor(e){Fe(this,"options");this.options=e||yn}preprocess(e){return e}postprocess(e){return e}processAllTokens(e){return e}};Fe(_n,"passThroughHooks",new Set(["preprocess","postprocess","processAllTokens"]));var pp=class{constructor(...e){Fe(this,"defaults",lp());Fe(this,"options",this.setOptions);Fe(this,"parse",this.#e(Ti.lex,ki.parse));Fe(this,"parseInline",this.#e(Ti.lexInline,ki.parseInline));Fe(this,"Parser",ki);Fe(this,"Renderer",xi);Fe(this,"TextRenderer",Wr);Fe(this,"Lexer",Ti);Fe(this,"Tokenizer",yr);Fe(this,"Hooks",_n);this.use(...e)}walkTokens(e,r){let t=[];for(let n of e)switch(t=t.concat(r.call(this,n)),n.type){case"table":{let o=n;for(let s of o.header)t=t.concat(this.walkTokens(s.tokens,r));for(let s of o.rows)for(let a of s)t=t.concat(this.walkTokens(a.tokens,r));break}case"list":{let o=n;t=t.concat(this.walkTokens(o.items,r));break}default:{let o=n;this.defaults.extensions?.childTokens?.[o.type]?this.defaults.extensions.childTokens[o.type].forEach(s=>{let a=o[s].flat(1/0);t=t.concat(this.walkTokens(a,r))}):o.tokens&&(t=t.concat(this.walkTokens(o.tokens,r)))}}return t}use(...e){let r=this.defaults.extensions||{renderers:{},childTokens:{}};return e.forEach(t=>{let n=R({},t);if(n.async=this.defaults.async||n.async||!1,t.extensions&&(t.extensions.forEach(o=>{if(!o.name)throw new Error("extension name required");if("renderer"in o){let s=r.renderers[o.name];s?r.renderers[o.name]=function(...a){let c=o.renderer.apply(this,a);return c===!1&&(c=s.apply(this,a)),c}:r.renderers[o.name]=o.renderer}if("tokenizer"in o){if(!o.level||o.level!=="block"&&o.level!=="inline")throw new Error("extension level must be 'block' or 'inline'");let s=r[o.level];s?s.unshift(o.tokenizer):r[o.level]=[o.tokenizer],o.start&&(o.level==="block"?r.startBlock?r.startBlock.push(o.start):r.startBlock=[o.start]:o.level==="inline"&&(r.startInline?r.startInline.push(o.start):r.startInline=[o.start]))}"childTokens"in o&&o.childTokens&&(r.childTokens[o.name]=o.childTokens)}),n.extensions=r),t.renderer){let o=this.defaults.renderer||new xi(this.defaults);for(let s in t.renderer){if(!(s in o))throw new Error(`renderer '${s}' does not exist`);if(s==="options")continue;let a=s,c=t.renderer[a],p=o[a];o[a]=(...m)=>{let _=c.apply(o,m);return _===!1&&(_=p.apply(o,m)),_||""}}n.renderer=o}if(t.tokenizer){let o=this.defaults.tokenizer||new yr(this.defaults);for(let s in t.tokenizer){if(!(s in o))throw new Error(`tokenizer '${s}' does not exist`);if(["options","rules","lexer"].includes(s))continue;let a=s,c=t.tokenizer[a],p=o[a];o[a]=(...m)=>{let _=c.apply(o,m);return _===!1&&(_=p.apply(o,m)),_}}n.tokenizer=o}if(t.hooks){let o=this.defaults.hooks||new _n;for(let s in t.hooks){if(!(s in o))throw new Error(`hook '${s}' does not exist`);if(s==="options")continue;let a=s,c=t.hooks[a],p=o[a];_n.passThroughHook
84s.has(s)?o[a]=m=>{if(this.defaults.async)return Promise.resolve(c.call(o,m)).then(y=>p.call(o,y));let _=c.call(o,m);return p.call(o,_)}:o[a]=(...m)=>{let _=c.apply(o,m);return _===!1&&(_=p.apply(o,m)),_}}n.hooks=o}if(t.walkTokens){let o=this.defaults.walkTokens,s=t.walkTokens;n.walkTokens=function(a){let c=[];return c.push(s.call(this,a)),o&&(c=c.concat(o.call(this,a))),c}}this.defaults=R(R({},this.defaults),n)}),this}setOptions(e){return this.defaults=R(R({},this.defaults),e),this}lexer(e,r){return Ti.lex(e,r??this.defaults)}parser(e,r){return ki.parse(e,r??this.defaults)}#e(e,r){return(t,n)=>{let o=R({},n),s=R(R({},this.defaults),o);this.defaults.async===!0&&o.async===!1&&(s.silent||console.warn("marked(): The async option was set to true by an extension. The async: false option sent to parse will be ignored."),s.async=!0);let a=this.#t(!!s.silent,!!s.async);if(typeof t>"u"||t===null)return a(new Error("marked(): input parameter is undefined or null"));if(typeof t!="string")return a(new Error("marked(): input parameter is of type "+Object.prototype.toString.call(t)+", string expected"));if(s.hooks&&(s.hooks.options=s),s.async)return Promise.resolve(s.hooks?s.hooks.preprocess(t):t).then(c=>e(c,s)).then(c=>s.hooks?s.hooks.processAllTokens(c):c).then(c=>s.walkTokens?Promise.all(this.walkTokens(c,s.walkTokens)).then(()=>c):c).then(c=>r(c,s)).then(c=>s.hooks?s.hooks.postprocess(c):c).catch(a);try{s.hooks&&(t=s.hooks.preprocess(t));let c=e(t,s);s.hooks&&(c=s.hooks.processAllTokens(c)),s.walkTokens&&this.walkTokens(c,s.walkTokens);let p=r(c,s);return s.hooks&&(p=s.hooks.postprocess(p)),p}catch(c){return a(c)}}}#t(e,r){return t=>{if(t.message+=` 85Please report this to https://github.com/markedjs/marked.`,e){let n="<p>An error occurred:</p><pre>"+Gt(t.message+"",!0)+"</pre>";return r?Promise.resolve(n):n}if(r)return Promise.reject(t);throw t}}},Cn=new pp;function ge(i,e){return Cn.parse(i,e)}ge.options=ge.setOptions=function(i){return Cn.setOptions(i),ge.defaults=Cn.defaults,ry(ge.defaults),ge};ge.getDefaults=lp;ge.defaults=yn;ge.use=function(...i){return Cn.use(...i),ge.defaults=Cn.defaults,ry(ge.defaults),ge};ge.walkTokens=function(i,e){return Cn.walkTokens(i,e)};ge.parseInline=Cn.parseInline;ge.Parser=ki;ge.parser=ki.parse;ge.Renderer=xi;ge.TextRenderer=Wr;ge.Lexer=Ti;ge.lexer=Ti.lex;ge.Tokenizer=yr;ge.Hooks=_n;ge.parse=ge;var T8=ge.options,k8=ge.setOptions,R8=ge.use,A8=ge.walkTokens,N8=ge.parseInline;var D8=ki.parse,F8=Ti.lex;var eI=["*"],tI="Copy",iI="Copied",nI=(()=>{let e=class e{constructor(){this._buttonClick$=new Zr,this.copied$=this._buttonClick$.pipe(A(()=>Jr(D(!0),Rp(3e3).pipe(Fp(!1)))),X(),_t(1)),this.copiedText$=this.copied$.pipe(Sr(!1),x(t=>t?iI:tI))}onCopyToClipboardClick(){this._buttonClick$.next()}};e.\u0275fac=function(n){return new(n||e)},e.\u0275cmp=F({type:e,selectors:[["markdown-clipboard"]],standalone:!0,features:[Ia],decls:4,vars:7,consts:[[1,"markdown-clipboard-button",3,"click"]],template:function(n,o){n&1&&(S(0,"button",0),w(1,"async"),Ce("click",function(){return o.onCopyToClipboardClick()}),H(2),w(3,"async"),b()),n&2&&(Xt("copied",T(1,3,o.copied$)),d(2),Be(T(3,5,o.copiedText$)))},dependencies:[q],encapsulation:2,changeDetection:0});let i=e;return i})(),rI=new St("CLIPBOARD_OPTIONS");var gp=function(i){return i.CommandLine="command-line",i.LineHighlight="line-highlight",i.LineNumbers="line-numbers",i}(gp||{}),hy=new St("MARKED_EXTENSIONS"),_p=new St("MARKED_OPTIONS"),oI="[ngx-markdown] When using the `emoji` attribute you *have to* include Emoji-Toolkit files to `angular.json` or use imports. See README for more information",sI="[ngx-markdown] When using the `katex` attribute you *have to* include KaTeX files to `angular.json` or use imports. See README for more information",aI="[ngx-markdown] When using the `mermaid` attribute you *have to* include Mermaid files to `angular.json` or use imports. See README for more information",cI="[ngx-markdown] When using the `clipboard` attribute you *have to* include Clipboard files to `angular.json` or use imports. See README for more information",pI="[ngx-markdown] When using the `clipboard` attribute you *have to* provide the `viewContainerRef` parameter to `MarkdownService.render()` function",lI="[ngx-markdown] When using the `src` attribute you *have to* pass the `HttpClient` as a parameter of the `forRoot` method. See README for more information",gy=new St("SECURITY_CONTEXT");var _y=(()=>{let e=class e{get options(){return this._options}set options(t){this._options=R(R({},this.DEFAULT_MARKED_OPTIONS),t)}get renderer(){return this.options.renderer}set renderer(t){this.options.renderer=t}constructor(t,n,o,s,a,c,p){this.clipboardOptions=t,this.extensions=n,this.platform=s,this.securityContext=a,this.http=c,this.sanitizer=p,this.DEFAULT_MARKED_OPTIONS={renderer:new xi},this.DEFAULT_KATEX_OPTIONS={delimiters:[{left:"$$",right:"$$",display:!0},{left:"$",right:"$",display:!1},{left:"\\(",right:"\\)",display:!1},{left:"\\begin{equation}",right:"\\end{equation}",display:!0},{left:"\\begin{align}",right:"\\end{align}",display:!0},{left:"\\begin{alignat}",right:"\\end{alignat}",display:!0},{left:"\\begin{gather}",right:"\\end{gather}",display:!0},{left:"\\begin{CD}",right:"\\end{CD}",display:!0},{left:"\\[",right:"\\]",display:!0}]},this.DEFAULT_MERMAID_OPTIONS={startOnLoad:!1},this.DEFAULT_CLIPBOARD_OPTIONS={buttonComponent:void 0},this.DEFAULT_PARSE_OPTIONS={decodeHtml:!1,inline:!1,emoji:!1,mermaid:!1,markedOptions:void 0,disableSanitizer:!1},this.DEFAULT_RENDER_OPTIONS={clipboard:!1,clipboardOptions:void 0,katex:!1,katexOptions:void 0,mermaid:!1,mermaidOptions:void 0},this._reload$=new Zr,this.reload$=this._reload$.asObservable(),this.options=o}parse(t,n=this.DEFAULT_PARSE_OPTIONS){let{decodeHtml:o,inline:s,emoji:a,mermaid:c,disableSanitizer:p}=n,m=R(R({},this.options),n.markedOptions),_=m.renderer||this.renderer||new xi;this.extensions&&(this.renderer=this.extendsRendererForExtensions(_)),c&&(this.renderer=this.extendsRendererForMermaid(_));let y=this.trimIndentation(t),E=o?this.decodeHtml(y):y,k=a?this.parseEmoji(E):E,N=this.parseMarked(k,m,s);return(p?N:this.sanitizer.sanitize(this.securityContext,N))||""}render(t,n=this.DEFAULT_RENDER_OPTIONS,o){let{clipboard:s,clipboardOptions:a,katex:c,katexOptions:p,mermaid:m,mermaidOptions:_}=n;c&&this.renderKatex(t,R(R({},this.DEFAULT_KATEX_OPTIONS),p)),m&&this.renderMermaid(t,R(R({},this.DEFAULT_MERMAID_OPTIONS),_)),s&&this.renderClipboard(t,o,R(R(R({},this.DEFAULT_CLIPBOARD_OPTIONS),this.clipboardOptions),a)),this.highlight(t)}reload(){this._reload$.next()}getSource(t){if(!this.http)throw new Error(lI);return this.http.get(t,{responseType:"text"}).pipe(x(n=>this.handleExtension(t,n)))}highlight(t){if(!ct(this.platform)||typeof Prism>"u"||typeof Prism.highlightAllUnder>"u")return;t||(t=document);let n=t.querySelectorAll('pre code:not([class*="language-"])');Array.prototype.forEach.call(n,o=>o.classList.add("language-none")),Prism.highlightAllUnder(t)}decodeHtml(t){if(!ct(this.platform))return t;let n=document.createElement("textarea");return n.innerHTML=t,n.value}extendsRendererForExtensions(t){let n=t;return n.\u0275NgxMarkdownRendererExtendedForExtensions===!0||(this.extensions?.length>0&&ge.use(...this.extensions),n.\u0275NgxMarkdownRendererExtendedForExtensions=!0),t}extendsRendererForMermaid(t){let n=t;if(n.\u0275NgxMarkdownRendererExtendedForMermaid===!0)return t;let o=t.code;return t.code=function(s,a,c){return a==="mermaid"?`<div class="mermaid">${s}</div>`:o.call(this,s,a,c)},n.\u0275NgxMarkdownRendererExtendedForMermaid=!0,t}handleExtension(t,n){let o=t.lastIndexOf("://"),s=o>-1?t.substring(o+4):t,a=s.lastIndexOf("/"),c=a>-1?s.substring(a+1).split("?")[0]:"",p=c.lastIndexOf("."),m=p>-1?c.substring(p+1):"";return m&&m!=="md"?"```"+m+`
86`+n+"\n```":n}parseMarked(t,n,o=!1){if(n.renderer){let s=R({},n.renderer);delete s.\u0275NgxMarkdownRendererExtendedForExtensions,delete s.\u0275NgxMarkdownRendererExtendedForMermaid,delete n.renderer,ge.use({renderer:s})}return o?ge.parseInline(t,n):ge.parse(t,n)}parseEmoji(t){if(!ct(this.platform))return t;if(typeof joypixels>"u"||typeof joypixels.shortnameToUnicode>"u")throw new Error(oI);return joypixels.shortnameToUnicode(t)}renderKatex(t,n){if(ct(this.platform)){if(typeof katex>"u"||typeof renderMathInElement>"u")throw new Error(sI);renderMathInElement(t,n)}}renderClipboard(t,n,o){if(!ct(this.platform))return;if(typeof ClipboardJS>"u")throw new Error(cI);if(!n)throw new Error(pI);let{buttonComponent:s,buttonTemplate:a}=o,c=t.querySelectorAll("pre");for(let p=0;p<c.length;p++){let m=c.item(p),_=document.createElement("div");_.style.position="relative",m.parentNode.insertBefore(_,m),_.appendChild(m);let y=document.createElement("div");y.style.position="absolute",y.style.top=".5em",y.style.right=".5em",y.style.opacity="0",y.style.transition="opacity 250ms ease-out",y.style.zIndex="1",_.insertAdjacentElement("beforeend",y),m.onmouseover=()=>y.style.opacity="1",m.onmouseout=()=>y.style.opacity="0";let E;if(s){let N=n.createComponent(s);E=N.hostView,N.changeDetectorRef.markForCheck()}else if(a)E=n.createEmbeddedView(a);else{let N=n.createComponent(nI);E=N.hostView,N.changeDetectorRef.markForCheck()}let k;E.rootNodes.forEach(N=>{N.onmouseover=()=>y.style.opacity="1",y.appendChild(N),k=new ClipboardJS(N,{text:()=>m.innerText})}),E.onDestroy(()=>k.destroy())}}renderMermaid(t,n=this.DEFAULT_MERMAID_OPTIONS){if(!ct(this.platform))return;if(typeof mermaid>"u"||typeof mermaid.initialize>"u")throw new Error(aI);let o=t.querySelectorAll(".mermaid");o.length!==0&&(mermaid.initialize(n),mermaid.run({nodes:o}))}trimIndentation(t){if(!t)return"";let n;return t.split(` 87`).map(o=>{let s=n;return o.length>0&&(s=isNaN(s)?o.search(/\S|$/):Math.min(o.search(/\S|$/),s)),isNaN(n)&&(n=s),s?o.substring(s):o}).join(` 88`)}};e.\u0275fac=function(n){return new(n||e)(u(rI,8),u(hy,8),u(_p,8),u(Ne),u(gy),u(We,8),u(vl))},e.\u0275prov=I({token:e,factory:e.\u0275fac});let i=e;return i})(),Cy=(()=>{let e=class e{get disableSanitizer(){return this._disableSanitizer}set disableSanitizer(t){this._disableSanitizer=this.coerceBooleanProperty(t)}get inline(){return this._inline}set inline(t){this._inline=this.coerceBooleanProperty(t)}get clipboard(){return this._clipboard}set clipboard(t){this._clipboard=this.coerceBooleanProperty(t)}get emoji(){return this._emoji}set emoji(t){this._emoji=this.coerceBooleanProperty(t)}get katex(){return this._katex}set katex(t){this._katex=this.coerceBooleanProperty(t)}get mermaid(){return this._mermaid}set mermaid(t){this._mermaid=this.coerceBooleanProperty(t)}get lineHighlight(){return this._lineHighlight}set lineHighlight(t){this._lineHighlight=this.coerceBooleanProperty(t)}get lineNumbers(){return this._lineNumbers}set lineNumbers(t){this._lineNumbers=this.coerceBooleanProperty(t)}get commandLine(){return this._commandLine}set commandLine(t){this._commandLine=this.coerceBooleanProperty(t)}constructor(t,n,o){this.element=t,this.markdownService=n,this.viewContainerRef=o,this.error=new oo,this.load=new oo,this.ready=new oo,this._clipboard=!1,this._commandLine=!1,this._disableSanitizer=!1,this._emoji=!1,this._inline=!1,this._katex=!1,this._lineHighlight=!1,this._lineNumbers=!1,this._mermaid=!1,this.destroyed$=new Zr}ngOnChanges(){this.loadContent()}loadContent(){if(this.data!=null){this.handleData();return}if(this.src!=null){this.handleSrc();return}}ngAfterViewInit(){!this.data&&!this.src&&this.handleTransclusion(),this.markdownService.reload$.pipe(Up(this.destroyed$)).subscribe(()=>this.loadContent())}ngOnDestroy(){this.destroyed$.next(),this.destroyed$.complete()}render(t,n=!1){return J(this,null,function*(){let o={decodeHtml:n,inline:this.inline,emoji:this.emoji,mermaid:this.mermaid,disableSanitizer:this.disableSanitizer},s={clipboard:this.clipboard,clipboardOptions:{buttonComponent:this.clipboardButtonComponent,buttonTemplate:this.clipboardButtonTemplate},katex:this.katex,katexOptions:this.katexOptions,mermaid:this.mermaid,mermaidOptions:this.mermaidOptions},a=yield this.markdownService.parse(t,o);this.element.nativeElement.innerHTML=a,this.handlePlugins(),this.markdownService.render(this.element.nativeElement,s,this.viewContainerRef),this.ready.emit()})}coerceBooleanProperty(t){return t!=null&&`${String(t)}`!="false"}handleData(){this.render(this.data)}handleSrc(){this.markdownService.getSource(this.src).subscribe({next:t=>{this.render(t).then(()=>{this.load.emit(t)})},error:t=>this.error.emit(t)})}handleTransclusion(){this.render(this.element.nativeElement.innerHTML,!0)}handlePlugins(){this.commandLine&&(this.setPluginClass(this.element.nativeElement,gp.CommandLine),this.setPluginOptions(this.element.nativeElement,{dataFilterOutput:this.filterOutput,dataHost:this.host,dataPrompt:this.prompt,dataOutput:this.output,dataUser:this.user})),this.lineHighlight&&this.setPluginOptions(this.element.nativeElement,{dataLine:this.line,dataLineOffset:this.lineOffset}),this.lineNumbers&&(this.setPluginClass(this.element.nativeElement,gp.LineNumbers),this.setPluginOptions(this.element.nativeElement,{dataStart:this.start}))}setPluginClass(t,n){let o=t.querySelectorAll("pre");for(let s=0;s<o.length;s++){let a=n instanceof Array?n:[n];o.item(s).classList.add(...a)}}setPluginOptions(t,n){let o=t.querySelectorAll("pre");for(let s=0;s<o.length;
88s++)Object.keys(n).forEach(a=>{let c=n[a];if(c){let p=this.toLispCase(a);o.item(s).setAttribute(p,c.toString())}})}toLispCase(t){let n=t.match(/([A-Z])/g);if(!n)return t;let o=t.toString();for(let s=0,a=n.length;s<a;s++)o=o.replace(new RegExp(n[s]),"-"+n[s].toLowerCase());return o.slice(0,1)==="-"&&(o=o.slice(1)),o}};e.\u0275fac=function(n){return new(n||e)(O(wt),O(_y),O(Qp))},e.\u0275cmp=F({type:e,selectors:[["markdown"],["","markdown",""]],inputs:{data:"data",src:"src",disableSanitizer:"disableSanitizer",inline:"inline",clipboard:"clipboard",clipboardButtonComponent:"clipboardButtonComponent",clipboardButtonTemplate:"clipboardButtonTemplate",emoji:"emoji",katex:"katex",katexOptions:"katexOptions",mermaid:"mermaid",mermaidOptions:"mermaidOptions",lineHighlight:"lineHighlight",line:"line",lineOffset:"lineOffset",lineNumbers:"lineNumbers",start:"start",commandLine:"commandLine",filterOutput:"filterOutput",host:"host",prompt:"prompt",output:"output",user:"user"},outputs:{error:"error",load:"load",ready:"ready"},standalone:!0,features:[Hp,Ia],ngContentSelectors:eI,decls:1,vars:0,template:function(n,o){n&1&&(Xp(),Jp(0))},encapsulation:2});let i=e;return i})();function dI(i){return[_y,i?.loader??[],i?.clipboardOptions??[],i?.markedOptions??[],{provide:hy,useValue:i?.markedExtensions??[]},{provide:gy,useValue:i?.sanitize??qp.HTML}]}var ba=(()=>{let e=class e{static forRoot(t){return{ngModule:e,providers:[dI(t)]}}static forChild(){return{ngModule:e}}};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({imports:[$]});let i=e;return i})(),fy;(function(i){let e;(function(n){n.Strict="strict",n.Loose="loose",n.Antiscript="antiscript",n.Sandbox="sandbox"})(e=i.SecurityLevel||(i.SecurityLevel={}));let r;(function(n){n.Base="base",n.Forest="forest",n.Dark="dark",n.Default="default",n.Neutral="neutral"})(r=i.Theme||(i.Theme={}));let t;(function(n){n[n.Debug=1]="Debug",n[n.Info=2]="Info",n[n.Warn=3]="Warn",n[n.Error=4]="Error",n[n.Fatal=5]="Fatal"})(t=i.LogLevel||(i.LogLevel={}))})(fy||(fy={}));var uI=i=>({"pointer-events":i}),fI=(i,e,r)=>[i,e,r];function hI(i,e){if(i&1&&(S(0,"div",9),P(1,"sip-image",10),b()),i&2){let r=C().$implicit;d(),l("tabindex",!(r==null||r.text_section_icon==null)&&r.text_section_icon.icon_alt_text?0:-1)("src",r==null||r.text_section_icon==null||r.text_section_icon.icon_image==null?null:r.text_section_icon.icon_image.url)("alt",r==null||r.text_section_icon==null?null:r.text_section_icon.icon_alt_text)("ngStyle",ve(4,uI,!(r==null||r.text_section_icon==null)&&r.text_section_icon.icon_alt_text?"auto":"none"))}}function gI(i,e){if(i&1&&(S(0,"div")(1,"div",11),P(2,"markdown",12),b()()),i&2){let r=e.$implicit,t=C().index,n=C(2);d(),Tt("color",r==null?null:r.color),Xt("clamp",!(n.isExpanded!=null&&n.isExpanded[t])&&n.truncate&&(n.ifLinesExceed==null?null:n.ifLinesExceed[t])),l("ngClass",il(6,fI,"group-"+t,"text-align-"+((r==null?null:r.text_alignment)||""),"group-"+((r==null?null:r.select_text_type)||""))),d(),l("data",n.getFormattedMarkdown(r==null?null:r.markdown_text))}}function _I(i,e){if(i&1){let r=Ve();S(0,"button",13),Ce("click",function(){ke(r);let n=C().index,o=C(2);return Re(o.toggleExpand(n))}),H(1),P(2,"mat-icon",14),b()}if(i&2){let r=C().index,t=C().ngIf,n=C();Tt("color",n.bodyTextColor),yt("aria-expanded",n.isExpanded==null?null:n.isExpanded[r]),d(),le(" ",n.isExpanded!=null&&n.isExpanded[r]?t==null?null:t.text_section_config.see_less_label:t==null?null:t.text_section_config.see_more_label," "),d(),l("fontIcon",n.isExpanded!=null&&n.isExpanded[r]?n.SipCostcoIcon.CHEVRON_UP:n.SipCostcoIcon.CHEVRON_DOWN)}}function CI(i,e){if(i&1&&(S(0,"div",3)(1,"div",4),v(2,hI,2,6,"div",5),S(3,"div",6),v(4,gI,3,10,"div",7)(5,_I,3,5,"button",8),b()()()),i&2){let r=e.$implicit,t=e.index,n=C().ngIf,o=C();d(),Tt("background",o.getBackgroundCss(r==null?null:r.color_config)),l("ngClass","text-align-"+((n==null?null:n.text_section_config.text_section_alignment)||"left")),d(),l("ngIf",r==null||r.text_section_icon==null||r.text_section_icon.icon_image==null?null:r.text_section_icon.icon_image.url),d(2),l("ngForOf",r==null?null:r.text_section_content),d(),l("ngIf",(o.ifLinesExceed==null?null:o.ifLinesExceed[t])&&o.truncate)}}function yI(i,e){if(i&1&&(S(0,"div",1),v(1,CI,6,6,"div",2),b()),i&2){let r=e.ngIf;Pi(r==null||r.text_section_config==null?null:r.text_section_config.text_section_type),d(),l("ngForOf",r==null?null:r.multiple_text_section_group)}}var yy=(()=>{let e=class e{constructor(t,n,o,s){this.component=t,this.cd=n,this.elemRef=o,this.platformId=s,this.isExpanded=[],this.ifLinesExceed=[],this.DEFAULT_BACKGROUND="#FAFAFA",this.SipCostcoIcon=zn}ngOnInit(){this.component.data$.pipe(z(1),x(t=>{let n=t,o=n?.multiple_text_section_group,s=n?.text_section_config,a=o?.length??0;this.isExpanded=Array(a).fill(!1),this.ifLinesExceed=Array(a).fill(!1),this.truncate=!!s?.see_more_see_less_capability&&s?.text_section_type==="full",this.groupAlignment=s?.text_section_alignment;let c=o?.map(m=>m.text_section_content??[]).flat().filter(m=>m.select_text_type==="body"),p=c?.[c.length-1];return this.bodyTextColor=p?.color,n})).subscribe()}ngAfterViewInit(){this.truncate&&ct(this.platformId)?setTimeout(()=>{this.ifLinesExceed=this.ifLinesExceed.map((t,n)=>{let o=this.elemRef.nativeElement.querySelectorAll(`.group-${n}`),s=0,a=0;return o.forEach(p=>{let m=window.getComputedStyle(p),_=parseInt(m.lineHeight,10),y=p.getBoundingClientRect().height;a||(a=isNaN(_)?0:_),p.className.includes("group-title")||(s+=y)}),s>=a*6}),this.cd.detectChanges()}):this.cd.detectChanges()}toggleExpand(t){this.isExpanded&&typeof this.isExpanded[t]<"u"&&(this.isExpanded[t]=!this.isExpanded[t],this.isExpanded[t]&&ct(this.platformId)&&this.elemRef.nativeElement.querySelector(`.group-body.group-${t}`)?.focus())}
88getBackgroundCss({background_gradient_style:t,background_gradient_color:n,background_color:o}){let s=n?.color1?.hex||"",a=n?.color2?.hex||"",c=o?.hex??this.DEFAULT_BACKGROUND;switch(t){case"radial":return`radial-gradient(circle, ${s}, ${a})`;case"linear":case"gradient":return`linear-gradient(to right, ${s}, ${a})`;case"solid":return c;default:return null}}getFormattedMarkdown(t){return t.replace(/\\n/g,` 89`)}};e.\u0275fac=function(n){return new(n||e)(O(ee),O(Ai),O(wt),O(Ne))},e.\u0275cmp=F({type:e,selectors:[["sip-text-builder"]],decls:2,vars:3,consts:[["class","text-builder",3,"class",4,"ngIf"],[1,"text-builder"],["class","outer-flex-items",4,"ngFor","ngForOf"],[1,"outer-flex-items"],[1,"text-group",3,"ngClass"],["class","inner-flex-first-col",4,"ngIf"],[1,"inner-flex-second-col"],[4,"ngFor","ngForOf"],["class","toggle-btn",3,"color","click",4,"ngIf"],[1,"inner-flex-first-col"],[1,"image",3,"tabindex","src","alt","ngStyle"],["tabindex","0",3,"ngClass"],["lineNumbers","","role","none",3,"data"],[1,"toggle-btn",3,"click"],["aria-hidden","true",3,"fontIcon"]],template:function(n,o){n&1&&(v(0,yI,2,3,"div",0),w(1,"async")),n&2&&l("ngIf",T(1,1,o.component.data$))},dependencies:[Ie,qe,W,Vt,Cy,cs,zi,q],styles:[".text-builder[_ngcontent-%COMP%]{gap:10px;height:100%;display:flex;flex-flow:column nowrap}.text-builder.half[_ngcontent-%COMP%], .text-builder.one_third[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:16px}.text-builder.half[_ngcontent-%COMP%] div.inner-flex-second-col[_ngcontent-%COMP%], .text-builder.one_third[_ngcontent-%COMP%] div.inner-flex-second-col[_ngcontent-%COMP%]{padding:0}.text-builder.one_fourth[_ngcontent-%COMP%]{display:flex;flex-direction:row;flex-wrap:wrap;gap:16px}.text-builder.one_fourth[_ngcontent-%COMP%] div.inner-flex-second-col[_ngcontent-%COMP%]{padding:0}.text-builder.half[_ngcontent-%COMP%] div.outer-flex-items[_ngcontent-%COMP%]{flex:1 1 45%}.text-builder.one_third[_ngcontent-%COMP%] div.outer-flex-items[_ngcontent-%COMP%]{flex:1 1 30%}.text-builder.one_fourth[_ngcontent-%COMP%] div.outer-flex-items[_ngcontent-%COMP%]{flex:1 1 calc(50% - 16px)}.text-builder.half[_ngcontent-%COMP%] .text-group[_ngcontent-%COMP%], .text-builder.one_third[_ngcontent-%COMP%] .text-group[_ngcontent-%COMP%], .text-builder.one_fourth[_ngcontent-%COMP%] .text-group[_ngcontent-%COMP%]{padding:16px}.text-builder[_ngcontent-%COMP%] a.link[_ngcontent-%COMP%], .text-builder[_ngcontent-%COMP%] a.link[_ngcontent-%COMP%]:hover, .text-builder[_ngcontent-%COMP%] a.link[_ngcontent-%COMP%]:visited{text-decoration:none}.text-builder[_ngcontent-%COMP%] .text-group[_ngcontent-%COMP%]{height:100%}.text-builder[_ngcontent-%COMP%] .text-group.text-align-left[_ngcontent-%COMP%]{gap:16px;direction:column;display:flex;text-align:left}.text-builder[_ngcontent-%COMP%] .text-group.text-align-left[_ngcontent-%COMP%] .image[_ngcontent-%COMP%]{margin-top:12px}.text-builder[_ngcontent-%COMP%] .text-group.text-align-left[_ngcontent-%COMP%] .inner-flex-first-col[_ngcontent-%COMP%]{width:fit-content}.text-builder[_ngcontent-%COMP%] .text-group.text-align-left[_ngcontent-%COMP%] .inner-flex-second-col[_ngcontent-%COMP%]{width:100%}.text-builder[_ngcontent-%COMP%] .text-group.text-align-center[_ngcontent-%COMP%]{display:block;padding:24px 0;text-align:center}.text-builder[_ngcontent-%COMP%] .text-group.text-align-center[_ngcontent-%COMP%] .image[_ngcontent-%COMP%]{margin:0 auto}.text-builder[_ngcontent-%COMP%] .text-group.text-align-center[_ngcontent-%COMP%] div.inner-flex-second-col[_ngcontent-%COMP%]{padding:16px;width:100%}.text-builder[_ngcontent-%COMP%] .text-group[_ngcontent-%COMP%] .image[_ngcontent-%COMP%]{display:block;height:56px;width:56px}.text-builder[_ngcontent-%COMP%] .text-group[_ngcontent-%COMP%] .clamp[_ngcontent-%COMP%]{display:-webkit-box;line-clamp:4;overflow:hidden;-webkit-box-orient:vertical;-webkit-line-clamp:4}.text-builder[_ngcontent-%COMP%] .text-group[_ngcontent-%COMP%] .clamp[_ngcontent-%COMP%] ol[_ngcontent-%COMP%], .text-builder[_ngcontent-%COMP%] .text-group[_ngcontent-%COMP%] .clamp[_ngcontent-%COMP%] ul[_ngcontent-%COMP%]{list-style-position:inside}.text-builder[_ngcontent-%COMP%] .text-group[_ngcontent-%COMP%] .group-title[_ngcontent-%COMP%] p{font-size:26px;word-break:break-word}.text-builder[_ngcontent-%COMP%] .text-group[_ngcontent-%COMP%] .group-subtitle[_ngcontent-%COMP%] p{font-size:18px;word-break:break-word}.text-builder[_ngcontent-%COMP%] .text-group[_ngcontent-%COMP%] .group-body[_ngcontent-%COMP%] p{font-size:16px;word-break:break-word}.text-builder[_ngcontent-%COMP%] .text-group[_ngcontent-%COMP%] .group-disclaimer[_ngcontent-%COMP%] p{font-size:12px;word-break:break-word}.text-builder[_ngcontent-%COMP%] .text-group[_ngcontent-%COMP%] markdown ul{padding-inline-start:16px}.text-builder[_ngcontent-%COMP%] .text-group[_ngcontent-%COMP%] markdown ul li{list-style:disc;list-style-position:outside}.text-builder[_ngcontent-%COMP%] .text-group[_ngcontent-%COMP%] markdown ol{padding-inline-start:16px}.text-builder[_ngcontent-%COMP%] .text-group[_ngcontent-%COMP%] markdown ol li{list-style:decimal;list-style-position:outside}.text-builder[_ngcontent-%COMP%] .text-group[_ngcontent-%COMP%] .group-body[_ngcontent-%COMP%] markdown ul, .text-builder[_ngcontent-%COMP%] .text-group[_ngcontent-%COMP%] .group-body[_ngcontent-%COMP%] markdown ol, .text-builder[_ngcontent-%COMP%] .text-group[_ngcontent-%COMP%] .group-body[_ngcontent-%COMP%] markdown li{font-size:16px;word-break:break-word}.text-builder[_ngcontent-%COMP%] button.toggle-btn[_ngcontent-%COMP%]{background-color:transparent;border:none;font-size:16px;padding:0}.text-builder[_ngcontent-%COMP%] button.toggle-btn[_ngcontent-%COMP%] mat-icon[_ngcontent-%COMP%]{font-size:18px;margin-left:2px;padding-top:1px}@media screen and (min-width: 768px) and (max-width: 1023px),screen and (min-width: 1024px){.text-builder.one_fourth[_ngcontent-%COMP%] div.outer-flex-items[_ngcontent-%COMP%]{flex:1 1 23%}.text-builder.half[_ngcontent-%COMP%], .text-builder.one_third[_ngcontent-%COMP%], .text-builder.one_fourth[_ngcontent-%COMP%]{display:flex;flex-direction:row;flex-wrap:nowrap;gap:16px}.text-builder.half[_ngcontent-%COMP%] div.inner-flex-second-col[_ngcontent-%COMP%], .text-builder.one_third[_ngcontent-%COMP%] div.inner-flex-second-col[_ngcontent-%COMP%], .text-builder.one_fourth[_ngcontent-%COMP%] div.inner-flex-second-col[_ngcontent-%COMP%]{padding:0}.text-builder[_ngcontent-%COMP%] .text-group[_ngcontent-%COMP%] .group-title[_ngcontent-%COMP%] p{font-size:42px}.text-builder[_ngcontent-%COMP%] .text-group[_ngcontent-%COMP%] .group-subtitle[_ngcontent-%COMP%] p{font-size:18px}.text-builder[_ngcontent-%COMP%] .text-group[_ngcontent-%COMP%] .image[_ngcontent-%COMP%]{height:80px;width:80px}}@media 1440px{.text-builder[_ngcontent-%COMP%] .text-group[_ngcontent-%COMP%] .group-title[_ngcontent-%COMP%] p{font-size:56px}}"],changeDetection:0});let i=e;return i})();var vy=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({providers:[M({cmsComponents:{SipTextBuilderComponent:{component:yy}}})],imports:[$,ba.forRoot({markedOptions:{provide:_p,useValue:{gfm:!0,breaks:!0}}}),ms,Gi]});let i=e;return i})();var Sy=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({providers:[{provide:ts,useExisting:is},M({featureModules:{textBanner:{module:()=>import("./chunk-UHYEOJSF.js").then(t=>
89t.SipTextBannerModule),cmsComponents:["SipTextBannerComponent"]},buttonSlider:{module:()=>import("./chunk-4VJ3UPBR.js").then(t=>t.SipButtonSliderModule),cmsComponents:["SipButtonSliderComponent"]},iconTextButton:{module:()=>import("./chunk-3IN46W7B.js").then(t=>t.SipIconTextButtonModule),cmsComponents:["SipIconTextButtonComponent"]},iframeComponent:{module:()=>import("./chunk-MI435UEK.js").then(t=>t.SipIframeComponentModule),cmsComponents:["SipIframeComponent"]},countriesFlags:{module:()=>import("./chunk-B267JM3J.js").then(t=>t.CountriesFlagsModule),cmsComponents:["CountriesFlagsComponent"]},breadcrumb:{module:()=>import("./chunk-XWHMGZBM.js").then(t=>t.SipBreadcrumbModule),cmsComponents:["BreadcrumbComponent"]},imageComponent:{module:()=>import("./chunk-EYTBBY7V.js").then(t=>t.SipImageComponentModule),cmsComponents:["SipImageComponent"]},responsiveCostcoLogo:{module:()=>import("./chunk-2AYY26JE.js").then(t=>t.SipResponsiveCostcoLogoModule),cmsComponents:["SipResponsiveCostcoLogoComponent"]},categoryComponent:{module:()=>import("./chunk-KSY5OG7U.js").then(t=>t.SipCategoryModule),cmsComponents:["SipCategoryComponent"]},categoryParagraph:{module:()=>import("./chunk-74DHNKVP.js").then(t=>t.SipCategoryParagraphModule),cmsComponents:["CategoryParagraphComponent"]},adList:{module:()=>import("./chunk-HBDOF2V4.js").then(t=>t.SipAdListModule),cmsComponents:["SipAdListComponent"]}}})],imports:[Ln,VC,QC,XC,ha,ga,Hs,vy,sh,Js]});let i=e;return i})();var by=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({providers:[M({featureModules:{orderReturns:{module:()=>import("./chunk-BCHPSOEZ.js").then(t=>t.SipOrderReturnsModule),dependencies:[vi]}}})]});let i=e;return i})();var xy=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({providers:[{provide:Bf,useExisting:Uf,multi:!0},M({featureModules:{orderCancel:{module:()=>import("./chunk-2CNMP3A3.js").then(t=>t.SipOrderCancelModule),dependencies:[vi]}}})]});let i=e;return i})();var Py=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({imports:[Hl.forRoot(),w_,wC,Xd,tm,Zd,Dd,pd,la.forRoot(),F_,j_,z_,H_,W_,$C,bC,EC,da,Y_,J_,tC,nC,oC,aC,MC,pC,NC,dC,uC,hC,_C,yC,xC,UC,zC,by,xy,GC,Sy]});let i=e;return i})();var My={backend:{occ:{endpoints:{quickCapture:"/users/${userId}/addresses/validation/quick-capture"}}}};var vI={home:{paths:["","/"]},search:{paths:["search"]},category:{paths:["c/:categoryCode"],paramsMapping:{categoryCode:"code"}},product:{paths:["p/:productCode"],paramsMapping:{productCode:"code"}},login:{paths:["login"],protected:!1},cart:{paths:["cart"]},splitAddress:{paths:["checkout/splitAddress"]},tireSearchResults:{paths:["tyres/results/:fitmentType","tiresearch/results/:fitmentType","buscar-llantas/results/:fitmentType"],paramsMapping:{fitmentType:"fitmentType"}},myRewards:{paths:["my-account/rewards"]},upgradeMembership:{paths:["my-account/membership-upgrade"]},myReceipts:{paths:["my-account/receipts"]},reorderDetails:{paths:["my-account/order/reorder/:orderCode"],paramsMapping:{orderCode:"orderCode"}},orderReturnsCompleted:{paths:["my-account/order/:orderCode/rmaNumber/:rmaNumber/return-delivery-method","my-account/order/:orderCode/rmaNumber/:rmaNumber/return-completed"],paramsMapping:{orderCode:"orderCode",rmaNumber:"rmaNumber"}},orderReturnsReview:{paths:["my-account/order/:orderCode/rmaNumber/:rmaNumber/return-review"],paramsM
89apping:{orderCode:"orderCode",rmaNumber:"rmaNumber"}},orderReturnsEditItems:{paths:["my-account/order/:orderCode/return-edit-items"],paramsMapping:{orderCode:"orderCode"}},orderReturnsSelect:{paths:["my-account/order/:orderCode/return-selected-items"],paramsMapping:{orderCode:"orderCode"}},orderCancelConfirmation:{paths:["my-account/order/:orderCode/cancel/cancel-confirmation"],paramsMapping:{orderCode:"orderCode"}},orderCancelReview:{paths:["my-account/order/:orderCode/cancel/cancel-review"],paramsMapping:{orderCode:"orderCode"}},orderCancelSelect:{paths:["my-account/order/:orderCode/cancel/cancel-selected-items"],paramsMapping:{orderCode:"orderCode"}},order:{paths:["my-account/order/:orderCode/cancel/:mode","my-account/order/:orderCode/:mode","my-account/order/:orderCode"],paramsMapping:{orderCode:"orderCode",mode:"mode"}},orders:{paths:["my-account/orders"]},subscriptions:{paths:["my-account/subscriptions"]},wishlist:{paths:["my-account/wishlist"]},updateProfile:{paths:["my-account/update-profile","my-account"]},unregisterAccount:{paths:["my-account/unregister"]},cancelMembership:{paths:["my-account/cancel-membership"]},updatePassword:{paths:["my-account/update-password"]},contactUs:{paths:["my-account/contact-us"]},paymentMethods:{paths:["my-account/payment-methods"]},carrier:{paths:["my-account/carrier"]},addressBook:{paths:["my-account/address-book/:addressType","my-account/address-book"],paramsMapping:{addressType:"addressType"}},addEditAddress:{paths:["my-account/add-address/:addressType","my-account/edit-address/:addressId/:addressType"],paramsMapping:{addressId:"addressId",addressType:"addressType"}},marketingPreferences:{paths:["my-account/marketing-preferences"]},bulkOrders:{paths:["my-account/bulk-orders"]},bulkOrdersValidationResults:{paths:["my-account/bulk-orders-validation-results"]},tireSearch:{paths:["tyres","tiresearch","buscar-llantas","automotive-search"]},tireSearchSelectSize:{paths:["tyres/:selectsize","tiresearch/:selectsize","buscar-llantas/:selectsize"],paramsMapping:{selectsize:"selectsize"}},tireSearchSkipPos:{paths:["tyres/:selectsize/:skipPos","tiresearch/:selectsize/:skipPos","buscar-llantas/:selectsize/:skipPos"],paramsMapping:{selectsize:"selectsize",ski
89pPos:"skipPos"}},automotiveSearchService:{paths:["automotive-search/:selectservice"],paramsMapping:{selectservice:"selectservice"}},batteriesSearchResults:{paths:["batteries/results"]},batteriesStoreFinder:{paths:["batteriesstore-finder/selectwarehouse"]},storeFinder:{paths:["store-finder/:storeId","store-finder"],paramsMapping:{storeId:"storeId"}},bopisStoreFinder:{paths:["pickup-in-store/store-finder/:cartEntryNumber"],paramsMapping:{cartEntryNumber:"cartEntryNumber"}},tireStoreFinder:{paths:["tirestore-finder/:result","buscar-centro-llantero/:result","tyre-store-finder/:result","tirestore-finder","buscar-centro-llantero","tyre-store-finder"]},compareProducts:{paths:["compare-products"]},onlineRegistration:{paths:["onlineregister/steps"]},onlineRegistrationConfirmation:{paths:["onlineregister/confirmation"]},membershipRegistration:{paths:["membership/registration/:membershipProductCode"]},shopCard:{paths:["costco-cash-card","costco-shop-card","costco-saldo-tarjeta-shopcard","costco-soldes-carte-achat"]},externalReturn:{paths:["external-return/:service"]},payLaterReturn:{paths:["orico/pay-later"]},checkout:{paths:["costcocheckout/single","checkout/single"]},forgotPassword:{paths:["login/pw/request"]},resetPassword:{paths:["login/pw/change"]},findLoginId:{paths:["login/id/request"]},orderConfirmation:{paths:["checkout/orderConfirmation/:orderCode","checkout/confirmation/:orderCode"],paramsMapping:{orderCode:"orderCode"}},creditCardApprovalConfirmation:{paths:["orico/:receiptNo/confirmation"],paramsMapping:{receiptNo:"receiptNo"}},trackingDetails:{paths:["tracking-details"]},accountTrackingDetails:{paths:["my-account/order/:orderCode/tracking-details/:consignmentCode"],paramsMapping:{orderCode:"orderCode",consignmentCode:"consignmentCode"}}},Ey={routing:{routes:vI,protected:!1}};var Iy={globalMessages:{[je.MSG_TYPE_CONFIRMATION]:{timeout:void 0},[je.MSG_TYPE_INFO]:{timeout:void 0},[je.MSG_TYPE_ERROR]:{timeout:void 0},[je.MSG_TYPE_ERROR_RESTRICTED_DELIVERY]:{timeout:void 0},[je.MSG_TYPE_WARNING]:{timeout:void 0},[je.MSG_TYPE_ADDTOCART]:{timeout:void 0}}};var Oy={i18n:{backend:{loadPath:`${se.occBaseUrl}${se.occPrefix}{{site}}/i18n/chunk/{{lng}}?basename={{ns}}`},debug:!1}};var wy={backend:{occ:{endpoints:{getCybersourceApiJwt:"/cybersource",getMicroformContext:"/cybersource/microform/captureContext"}}}};var Ty={backend:{occ:{endpoints:{creditCardApplication:"users/${userId}/creditCardApplication",creditCardOricoReturn:"users/${userId}/creditCardApplication/orico/return",paymentMethods:"users/${userId}/paymentdetails?fields=FULL",borgunPublicToken:"users/${userId}/carts/${cartId}/borgun-public-token"}}}};var ky={backend:{occ:{endpoints:{rewards:"users/${userId}/rewards?fields=FULL",coBrandedRewards:"users/${userId}/rewards/globalcard?fields=FULL"}}}};var Ry={backend:{occ:{endpoints:{sizeOptions:"tires/sizeOptions?fields=FULL",vehicleOptions:"tires/vehicleoptions?fields=FULL",checkVehicleCompatibility:"tires/compatibility/vehicle?fields=FULL",checkRegistrationCompatibility:"tires/compatibility/registration?fields=FULL",registrationSearch:"tires/registrationsearch?fields=FULL",vehicleSearch:"tires/vehiclesearch?fields=FULL",changeTireWarehouse:"users/${userId}/carts/${cartId}/changeTiresWarehouse",currentAppointmentId:"users/${userId}/carts/${cartId}/currentTireAppointmentStoreId",changeBatteryWarehouse:"users/${userId}/carts/${cartId}/changeBatteryWarehouse"}}}};var Ay=(()=>{let e=class e{constructor(t,n){this.converter=t,this.contentStackConfigService=n}convert(t,n={}){return hm(t)?(this.contentStackConfigService.setContentStackPage(!0),n=this.normalizeSipContentStackData(t,n)):(this.contentStackConfigService.setContentStackPage(!1),this.normalizeSipPageSlotData(t,n)),n}normalizeProductCarouselData(t={}){return Object.values(t).map(n=>{let o=n.decalData||{};return n.decalData=Object.entries(o).map(([s,a])=>({key:s,value:a})),Gm(this.converter.convert(n,Bt))})}normalizeSipPageSlotData(t,n){for(let o of t.contentSlots.contentSlot){if(o.components?.component?.length){let s=o.components.component;o.components.component=s.map(a=>(a.products&&(a.products=this.normalizeProductCarouselData(a.products)),a))}n.page.slots[o.position]=ie(R({},n.page.slots[o.position]),{slotId:o.slotId})}}normalizeSipContentStackData(t,n){if(!t)return{};let s="category_id"in t?t?.type===Ue.CONTENT_PAGE?"categoryLandingPage":"productList":t?.product_page_identifier==="product-details-page-template"?"productDetails":t?.page_id??t?.app_view_name,a=t?.seo_meta_data;return{page:{name:s,pageId:s,description:a?.meta_description??null,title:a?.meta_title??null,robots:a?.robots??null,keywords:a?.keywords??null,schemaOrgOrganization:gm(a,"seo_schemaorg_organization")??null,type:t?.type,slots:{contentStack:t}}}}};e.\u0275fac=function(n){return new(n||e)(u(Rt),u(Pt))},e.\u0275prov=I({token:e,factory:e.\u0275fac,providedIn:"root"});let i=e;return i})();var Ny={backend:{occ:{endpoints:{initMemberVerification:"/users/${userId}/toss/identityVerification",checkMemberVerification:"/users/${userId}/toss/identityVerificationInquiry",membershipValidation:"/membership/validate",verifyIdentityTrulioo:"/users/${userId}/carts/${cartId}/trulioo/workflow/url"}}}};var Dy=(()=>{let e=class e{intercept(t,n){return(t&&!t.headers||!t.headers.get("Content-Type"))&&!(t.body instanceof FormData)?n.handle(t.clone({setHeaders:{"Content-Type":"application/json"}})):n.handle(t)}};e.\u0275fac=function(n){return new(n||e)},e.\u0275prov=I({token:e,factory:e.\u0275fac});let i=e;return i})();var Fy={backend:{occ:{endpoints:{user:"users/${userId}?fields=FULL",unregister:"users/${userId}/unregister",sendOtp:"users/${userId}/sendOTP",initiateMobileNumberChange:"users/${userId}/initiateMobileNumberChange",initiateEmailChange:"users/${userId}/initiateEmailChange",verifyOtp:"users/${userId}/verifyOTP",contactUsSubjects:"users/${userId}/contactUsSubjects",contactUs:"users/${userId}/contactUs",userUpdateProfile:"users/${userId}",myAccountMenuItems:"users/${userId}/my-account-menu-items",updatePassword:"users/${userId}/password",carrier:"users/${userId}/carrier"}}}};var Ly={backend:{occ:{endpoints:{sitePreferences:"preferences?fields=FULL",userPreferences:"users/${userId}/comPrefSubscriptions",updateUserPreferences:"users/${userId}/comPrefMulti?fields=FULL",userInterests:"users/${userId}/interests?fields=DEFAULT",comPrefFlags:"users/${userId}/comPrefFlags"}}}};
89var jy={backend:{occ:{endpoints:{getSubscriptionDetails:"users/${userId}/subscription/detail?fields=FULL",skipSubscriptionNextOrder:"users/${userId}/subscription/${subscriptionId}/skip",getProductSubscriptionTerms:"users/${userId}/subscription/${productCode}/term",updateSubscriptionTerm:"users/${userId}/subscription/${subscriptionId}/term",updateSubscriptionQuantity:"users/${userId}/subscription/${subscriptionId}/quantity",cancelSubscription:"users/${userId}/subscription/${subscriptionId}",getSubscriptionPaymentDetails:"users/${userId}/subscription/paymentdetails",updateSubscriptionPaymentDetails:"users/${userId}/subscription/${subscriptionId}/payment",updateSubscriptionDeliveryAddress:"users/${userId}/subscription/${subscriptionId}/address",getSubscription:"users/${userId}/subscription/${subscriptionId}/detail?fields=FULL"}}}};var $y={backend:{occ:{endpoints:{baseSites:(se.basesites?"basesites":"basesite")+"?fields=FULL",saltEndpoint:"saltFromSite"}}}};var By={backend:{occ:{endpoints:{paymentTypes:"paymentTypes",paymentMethods:"users/${userId}/paymentmethods",paymentTypesByCart:"users/${userId}/carts/${cartId}/paymentTypes",paymentMethodsByCart:"users/${userId}/carts/${cartId}/paymentmethods",paymentDetailsId:"users/${userId}/paymentdetails/${paymentDetailsId}",paymentDetailsAll:"users/${userId}/paymentdetails",paymentDetailsMicroform:"users/${userId}/paymentdetails/microform",paymentDetailsSavePaymentAuth:"users/${userId}/paymentdetails/savePaymentAuth",paymentDetailsCartAndId:"users/${userId}/paymentdetails/${cartId}/${paymentDetailsId}",paymentInstrument:"users/${userId}/paymentdetails/testPaymentInstrument",paymentBillingAddress:"users/${userId}
89/paymentdetails/billingAddress?fields=FULL",creditCardApplicationConfig:"users/${userId}/creditCardApplicationConfig",cardInfo:"users/${userId}/paymentdetails/cardInfo",deliveryNote:"users/${userId}/carts/${cartId}/entry/${entryNumber}/note",validateAndSaveInvoice:"users/${userId}/orders/validateAndSaveInvoice"}}}};var Uy={backend:{occ:{endpoints:{registrationConfiguration:"membership/configuration",checkNationalIdBlacklist:"membership/checkNationalIdBlacklist",registrationProductImages:"membership/productimages",sendEmailRegistrationOtp:"membership/newregistration/sendOTP",verifyEmailRegistrationOtp:"membership/newregistration/verifyOTP",streamlinedRegister:"membership/onlineregistration/streamlined",newRegistration:"membership/newregistration",thirdPartyValidate:"membership/thirdparty/validate"}}}};var zy={backend:{occ:{endpoints:{requestForgotPasswordEmail:"forgottenpasswordtokens?userId=${email}",resetpassword:"resetpassword",getContactMethods:"/prc/contactMethods",sendPrcOtp:"/prc/sendOTP",verifyPrcOtp:"/prc/verifyOTP",idRequest:"login/id/request"}}}};var Gy={backend:{occ:{endpoints:{scheduleServiceConfiguration:"/cartgroups/${cartGroupId}/schedule-service-configuration"}}}};var Hy={backend:{occ:{endpoints:{appointmentSchedulerConfiguration:"/users/${userId}/carts/${cartId}/scheduleservices",appointmentSchedulerDates:"/users/${userId}/carts/${cartId}/cartgroups/${cartGroupId}/dates",appointmentSchedulerTimes:"/users/${userId}/carts/${cartId}/cartgroups/${cartGroupId}/times",appointmentSchedulerReserve:"/users/${userId}/carts/${cartId}/cartgroups/${cartGroupId}/reserveAppointment"}}}};var Vy=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({providers:[M($y),M(wy),M(Ty),M(ky),M(Ry),M(My),M(Ny),M(Fy),M(Uy),M(Ly),M(jy),M(zy),M(By),M(Gy),M(Hy),M({mediaFormats:vf({mobile:{width:0},tablet:{width:768},desktop:{width:992},widescreen:{width:1200},cartIcon:{width:0},thumbnail:{width:160},results:{width:350},carousel:{width:350},product:{width:740},zoom:{width:1200},superZoom:{width:1200}})}),M(Iy),M(Ey),M(Oy),M({view:{}}),ho(__,[Ne,si]),M({backend:{occ:{baseUrl:se.occBaseUrl,prefix:se.occPrefix,endpoints:bm},media:{baseUrl:se.occBaseUrl}},authentication:{client_id:se.clientId,client_secret:se.clientSecret,baseUrl:typeof window>"u"?"":window.location.protocol+"//"+window.location.host+"/authorizationserver"},pwa:{enabled:!1}}),{provide:Et,useClass:Dy,multi:!0},{provide:Et,useClass:Fu,multi:!0},{provide:Kl,useExisting:Ay,multi:!0},{provide:Nu,useExisting:Du,multi:!0},Ul(ld)]});let i=e;return i})();var qy=(()=>{let e=class e extends Io{getFlexTypeFromComponent(t){return t.typeCode===Na&&!t.page?.endsWith(".jsp")?Na:super.getFlexTypeFromComponent(t)}};e.\u0275fac=(()=>{let t;return function(o){return(t||(t=Le(e)))(o||e)}})(),e.\u0275prov=I({token:e,factory:e.\u0275fac,providedIn:"root"});let i=e;return i})();var Wy=(()=>{let e=class e{constructor(t,n,o){this.authService=t,this.userService=n,this.routingService=o,this.membershipData=null}intercept(t,n){let o=t.url.includes("/cms/pages")||t.url.includes("/cms/csheader")||t.url.includes("/cms/navigationMenu"),s=t.url.includes("/cms/pages")||t.url.includes("/cms/navigationMenu");return!o&&!s?n.handle(t):this.routingService.getRouterState().pipe(z(1),A(a=>{let c=t;if(s){let p=a?.nextState?.queryParams.env;p&&(c=t.clone({setHeaders:{"Cs-Environment":p}}))}return o?this.getMembershipData().pipe(z(1),x(p=>this.addMembershipHeader(c,p)),A(p=>n.handle(p))):n.handle(c)}))}getMembershipData(){return this.authService.isUserLoggedIn().pipe(z(1),A(t=>t?this.membershipData?D(this.membershipData):this.userService.isAnonymousUser().pipe(z(1),A(n=>n?(this.membershipData={membership_expiry:null,member_type:"ANONYMOUS",is_international_member:null,membership_upgrade_available:null,membership_upgrade_pending:null},D(this.membershipData)):this.userService.get().pipe(j(o=>!!o?.expiryDate),z(1),Ge(()=>D({}))))):(this.membershipData={membership_expiry:null,member_type:"ANONYMOUS",is_international_member:null,membership_upgrade_available:null,membership_upgrade_pending:null},D(this.membershipData))),x(t=>{if(this.membershipData?.member_type==="ANONYMOUS")return this.membershipData;if(t?.expiryDate){let n=new Date(t.expiryDate);this.membershipData={membership_expiry:isNaN(n.getTime())?null:n.toISOString(),member_type:t?.memberType??null,is_international_member:t?.isInternationalMember??null,membership_upgrade_available:t?.membershipUpgradeAvailable??null,membership_upgrade_pending:t?.membershipUpgradePending??null}}return this.membershipData??{membership_expiry:null,member_type:null,is_international_member:null,membership_upgrade_available:null,membership_upgrade_pending:null}}))}addMembershipHeader(t,n){let o=JSON.stringify(n);return t.clone({setHeaders:{"Membership-Data":o}})}};
89e.\u0275fac=function(n){return new(n||e)(u(Di),u(Ci),u(mi))},e.\u0275prov=I({token:e,factory:e.\u0275fac,providedIn:"root"});let i=e;return i})();var Ky=(()=>{let e=class e extends xo{constructor(){super(...arguments),this.searchServiceUtils=L(Hn)}isOccBaseUrl(t){let n=this.occEndpoints.getBaseUrl(),o=this.searchServiceUtils.getSearchServiceBaseUrl(),s=n,a=n.replace("/v2","/v3");return t.includes(s)||t.includes(a)||t.includes(o)}intercept(t,n){let o=this.isClientTokenRequest(t);return o&&(t=t.clone({headers:t.headers.delete("USE_CLIENT_TOKEN")})),this.getClientToken(o).pipe(A(s=>(s?.access_token&&this.isOccBaseUrl(t.url)&&(t=t.clone({setHeaders:{Authorization:`${s.token_type||"Bearer"} ${s.access_token}`}})),n.handle(t).pipe(Ge(a=>a instanceof dl&&a.status===401&&o&&this.isExpiredToken(a)?this.clientErrorHandlingService.handleExpiredClientToken(t,n):sn(a))))))}};e.\u0275fac=(()=>{let t;return function(o){return(t||(t=Le(e)))(o||e)}})(),e.\u0275prov=I({token:e,factory:e.\u0275fac});let i=e;return i})();var Qy=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({providers:[{provide:Wl,useExisting:ts},{provide:Io,useExisting:qy},{provide:Et,useClass:Wy,multi:!0},{provide:xo,useClass:Ky}]});let i=e;return i})();var Cp=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({imports:[Sd.forRoot(),G,Yd,Fa,$d,qd,Vd,Hd,Jd,jd,wr,_d.forRoot(),Kd.forRoot(),Fa.forRoot(),Qy,wr]});let i=e;return i})();var Yy=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({imports:[Cp,Py,Vy,Cp]});let i=e;return i})();function SI(i){return i.getLastSetLanguage().replace(/_/g,"-")}var Zy=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({providers:[{provide:rl,useFactory:SI,deps:[Rr]},{provide:fi,useExisting:Rr}],imports:[$]});let i=e;return i})();function bI(i){return()=>J(this,null,function*(){yield i.initialize()})}var Xy=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({providers:[{provide:eu,useExisting:Wa},{provide:Xe,useFactory:bI,deps:[Wa],multi:!0}],imports:[$]});let i=e;return i})();var Jy=(()=>{let e=class e{constructor(){this.scriptLoader=L(ko),this.siteConfigService=L(Ke),this.document=L(bt),this.windowRef=L(K)}injectScripts(){this.document.querySelector("#queueconfigloader")||this.scriptLoader.embedScript({src:"//static.queue-it.net/script/queueconfigloader.min.js",attributes:{id:"queueconfigloader","data-queueit-spa":"true","data-queueit-intercept-domain":this.windowRef.nativeWindow.location.hostname,"data-queueit-intercept":"true","data-queueit-c":"costcointl"}}),this.document.querySelector("#queueclient")||this.scriptLoader.embedScript({src:"//static.queue-it.net/script/queueclient.min.js",attributes:{id:"queueclient"}})}};e.\u0275fac=function(n){return new(n||e)},e.\u0275prov=I({token:e,factory:e.\u0275fac,providedIn:"root"});let i=e;return i})();var ev=(()=>{let e=class e{constructor(){this.siteConfigService=L(Ke),this.windowRef=L(K)}intercept(t,n){return n.handle(t).pipe(A(o=>this.windowRef.isBrowser()&&o.type===ll.Response&&o.headers?.get("x-queueit-redirect")?this.siteConfigService.getBooleanConfig(qo).pipe(A(s=>s?Sn:D(o))):D(o)))}};e.\u0275fac=function(n){return new(n||e)},e.\u0275prov=I({token:e,factory:e.\u0275fac,providedIn:"root"});let i=e;return i})();var tv=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({providers:[{provide:Xe,useFactory:(t,n,o)=>()=>J(e,null,function*(){(yield pe(t.getBooleanConfig(qo)))&&n.isBrowser()&&o.injectScripts()}),deps:[Ke,K,Jy],multi:!0},{provide:Et,useExisting:ev,multi:!0}]});let i=e;return i})();var iv=(()=>{let e=class e{constructor(t,n,o){this.appRef=t,this.winRef=n,this.updates=o}init(){this.winRef.nativeWindow&&this.updates.isEnabled&&(this.handleFailure(),this.monitorUpdates(),this.checkForUpdate())}handleFailure(){this.updates.unrecoverable.subscribe(t=>{console.error(`Reloading due to a fatal error: ${t.reason}`),document.location.reload()})}monitorUpdates(){se.serviceWorker.autoUpdate&&this.updates.versionUpdates.pipe(j(t=>t.type==="VERSION_READY")).subscribe(t=>{console.debug(`Current app version: ${t.currentVersion.hash}`),console.debug(`New app version ready for use: ${t.latestVersion.hash}`),this.countdownToReload(10)})}checkForUpdate(){let t=se.serviceWorker.checkInterval;if(t<1)return;let n=this.appRef.isStable.pipe(Ma(a=>a===!0)),o=Ap(t*1e3);wp(n,o).subscribe(()=>J(this,null,function*(){try{(yield this.updates.checkForUpdate())&&this.countdownToReload(10)}catch(a){console.error("Failed to check for updates:",a)}}))}countdownToReload(t){let n=t+1,o=setInterval(()=>{n==0?(clearInterval(o),document.location.reload()):console.warn(`Reloading in ${--n} seconds`)},1e3)}};e.\u0275fac=function(n){return new(n||e)(u(nl),u(K),u(Fd))},e.\u0275prov=I({token:e,factory:e.\u0275fac,providedIn:"root"});let i=e;return i})();var nv=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({providers:[{provide:Xe,multi:!0,useFactory:t=>()=>t.init(),deps:[iv]}],imports:[Ld.register("/ngsw-worker.js",{enabled:se.production,registrationStrategy:"registerImmediately"})]});let i=e;return i})();var rv=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({providers:[{provide:Tn,useFactory:xI,deps:[nh,qt,Ne],multi:!0}],imports:[rh]});let i=e;return i})();function xI(i,e,r){return{scopes:["affirm"],configFactory:()=>J(this,null,function*(){let t=yield pe(e.getStable("currentsite"));return ct(r)&&(yield pe(i.init())),t})}}var ov=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e}),e.\u0275inj=f({imports:[$,$i,Ln]});let i=e;return i})();var sv=(()=>{let e=class e{};e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=h({type:e,bootstrap:[ig]}),e.\u0275inj=f({providers:[ml(fl(),ul()),{provide:Vp,useValue:"storefront"},{provide:ol,useValue:"/"},{provide:hl,useValue:!1},ei],imports:[S_,Yh.forRoot(),W0,Yy,nv,Pm.forRoot(),En.forRoot({},{metaReducers:[g_]}),di.forRoot([]),Eu.forRoot({prefix:"",separator:"",caseSensitive:!0}),Ql.forRoot(),yd.forRoot(),ji,gt,lg,h_,x_,rv,la.forRoot(),qh,dd.forRoot(),fg,mf,Cd.forRoot(),wr,Zy,Yn,tv,Xy,xg,B0.forRoot(),G0,J0.forRoot(),da,i_,r_,o_,C_.forRoot(),m_,se.imports,b_,ph,f_,Sl,Fn,ba.forRoot(),ov]});let i=e;return i})();function PI(){try{document.cookie="cookietest=1";let i=document.cookie.indexOf("cookietest=")!==-1;return document.cookie="cookietest=1; expires=Thu, 01-Jan-1970 00:00:01 GMT",i}catch{return!1}}function av(){!PI()&&!MI()&&window.location.href.indexOf("cookies-disabled")<0&&window.location.replace("/cookies-disabled")}function MI(){return window.self!==window.top}se.production&&void 0;av();document.addEventListener("DOMContentLoaded",()=>{_l().bootstrapModule(sv).catch(i=>{console.error("DOMContentLoaded",new Error(`failed, ${i}`)),es.performErrorPageRedirect()})});
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.