1import{a as Oe,b as ke}from"./chunk-ROG7HYWU.js";import{a as ft,b as ht,c as St,d as xt,e as yt,f as vt,g as Pt,h as Ee,i as Tt}from"./chunk-W5IZHZNQ.js";import"./chunk-NCZEM5DJ.js";import{a as Ct}from"./chunk-UGUHB6CV.js";import{c as It,d as Mt}from"./chunk-NH76BMX5.js";import"./chunk-X6BU2E3B.js";import{a as nt,b as at}from"./chunk-ARHWKCUX.js";import{i as mt,j as gt}from"./chunk-EYYH3V35.js";import"./chunk-ILT2J4ED.js";import{a as dt}from"./chunk-3U3RUHF6.js";import{a as Re}from"./chunk-YWNKC6Z2.js";import"./chunk-DN53PZSF.js";import"./chunk-EKEZHEKC.js";import"./chunk-QNIXKBD3.js";import"./chunk-THHYQEQJ.js";import"./chunk-WIBSPPCM.js";import{b as _t}from"./chunk-KDSHL5UQ.js";import{b as ut}from"./chunk-Z5IFGQHE.js";import"./chunk-73KO2E3G.js";import"./chunk-VPNEUWRW.js";import"./chunk-HZQXAPUI.js";import"./chunk-BCGX2S3W.js";import"./chunk-FB3RXB7D.js";import"./chunk-QOIXCD7Y.js";import"./chunk-4PMMTYZN.js";import"./chunk-HV7CAB5F.js";import"./chunk-ELWJXKH4.js";import"./chunk-C66YHVQ5.js";import"./chunk-IRFZQOWH.js";import"./chunk-X5ZC6EMR.js";import{a as J}from"./chunk-6QHHSURX.js";import{a as ot}from"./chunk-PKCDE3Z4.js";import{b as pt}from"./chunk-CQWWMJD5.js";import"./chunk-UV2ZCROI.js";import"./chunk-BDVA2GPB.js";import"./chunk-MWWXCM3J.js";import"./chunk-YNCXXF72.js";import"./chunk-CBKCLXCN.js";import"./chunk-RJUS6BOZ.js";import"./chunk-SBGOI54C.js";import{a as te}from"./chunk-MJ4Y67YW.js";import"./chunk-LT2NQL6J.js";import{a as N}from"./chunk-LGSDJCGQ.js";import"./chunk-KGZUXKHN.js";import"./chunk-PA6VGBJ7.js";import"./chunk-YYPLYDEM.js";import"./chunk-X4SO7FXM.js";import"./chunk-3L62N2GX.js";import"./chunk-37MHNOLO.js";import"./chunk-MJDNH7QI.js";import"./chunk-WIIZ5XVT.js";import"./chunk-ON7NRTQG.js";import{c as Pe,d as Te,e as Ie}from"./chunk-PX2CFBUF.js";import"./chunk-TX64DUOP.js";import"./chunk-Y25CNICT.js";import{g as lt}from"./chunk-5ETMJ6VZ.js";import{a as rt,c as R}from"./chunk-HTADUWDO.js";import"./chunk-7BPK4QOM.js";import{b as X}from"./chunk-2BJPNG3N.js";import{b as it}from"./chunk-SCB6RBNV.js";import"./chunk-XUFA6U7R.js";import"./chunk-23OYWDAP.js";import"./chunk-7NFGL5VA.js";import"./chunk-EWHIIGU2.js";import"./chunk-5BYY3CUG.js";import"./chunk-L7T3VYHM.js";import"./chunk-RXO5FOGF.js";import"./chunk-MKRPQEP7.js";import"./chunk-MXAVAYRT.js";import"./chunk-TDUHGQVS.js";import"./chunk-I57Q5XCC.js";import"./chunk-SHD7ZT4O.js";import"./chunk-MNDIYD7B.js";import"./chunk-NBYIECIO.js";import"./chunk-HF6NAPYW.js";import"./chunk-3PGHLUKK.js";import"./chunk-BZRY3WX3.js";import{ib as st}from"./chunk-NGFOYMLE.js";import"./chunk-BXLI5HAL.js";import{c as D}from"./chunk-FCZ6MCLW.js";import"./chunk-RJOOTOZF.js";import"./chunk-PMDY5XFA.js";import"./chunk-QMQ54HP6.js";import"./chunk-44NWIEBJ.js";import{f as ct}from"./chunk-ABACGHJ4.js";import"./chunk-GDB2PFOH.js";import"./chunk-IXGEFSMQ.js";import"./chunk-T2C72SUQ.js";import"./chunk-EMG7GVNH.js";import"./chunk-6QDM7Q5V.js";import"./chunk-XPXABRQ4.js";import"./chunk-OGG4A2QW.js";import"./chunk-KMH4CD5X.js";import"./chunk-LIWSNI2U.js";import"./chunk-DAAXSM72.js";import"./chunk-3D57UA43.js";import"./chunk-7FE7YXZN.js";import"./chunk-OMXPTFCM.js";import"./chunk-TPDW35KC.js";import"./chunk-NZJ33BRL.js";import"./chunk-TWWRSAAI.js";import"./chunk-PF2HCEW7.js";import"./chunk-MUPHABQG.js";import"./chunk-SVYMASPC.js";import"./chunk-2TZM34WV.js";import"./chunk-OQ4Y2D57.js";import"./chunk-QSJABKNM.js";import"./chunk-6YOKE3XR.js";import"./chunk-QBKLDZGY.js";import"./chunk-XI4FVBZT.js";import"./chunk-IDGFXIUB.js";import"./chunk-BEHWAJ2I.js";import"./chunk-2EGFIPKB.js";import"./chunk-DZFR5FMO.js";import"./chunk-XKQLI5KL.js";import"./chunk-R4ARHUW6.js";import"./chunk-BNJC75RQ.js";import{hb as Ke,ib as et,la as Ze,pa as Xe,ra as Je,rb as tt}from"./chunk-BTU2RJ7F.js";import{u as ee}from"./chunk-7NUAVIFX.js";import{a as Le}from"./chunk-4MVYGVQH.js";import"./chunk-5USKAXQR.js";import{a as K}from"./chunk-HTGKFTJD.js";import"./chunk-WXHOXPNQ.js";import"./chunk-OLA7DPU5.js";import"./chunk-UVPO54ZG.js";import{a as Me}from"./chunk-WRVDYOEU.js";import"./chunk-W4LQNO54.js";import"./chunk-GUVLWF6N.js";import"./chunk-YGD5LXH5.js";import"./chunk-2L2ZYCSH.js";import"./chunk-QUDZR5CE.js";import{$a as M,$b as _e,$c as ze,Ac as _,Bc as $,Ca as w,Da as W,Ec as P,H as I,Ib as m,Jb as d,Kb as g,Kh as Qe,Lb as h,Mb as S,Me as ye,Nb as ae,R as se,Rg as Ye,Tb as s,Tg as ve,U as le,Xc as He,Yc as Se,Zc as B,_c as Ve,a as H,ac as ue,ba as me,bb as ge,bc as fe,cc as y,cd as We,ce as Y,d as pe,dc as v,dd as U,ec as re,ee as Ce,fb as a,fc as b,fe as xe,gb as f,he as Q,ja as je,kd as q,me as Ue,na as oe,p as V,pa as de,qc as A,rc as he,sc as G,ta as z,te as qe,ub as p,uh as Z,v as T,vh as
1j,w as k,wb as o,zc as l}from"./chunk-ZIECK5QA.js";import{a as F,b as ce}from"./chunk-3JMZ37NM.js";function At(e,n){e&1&&g(0,"sip-skeleton")}function jt(e,n){e&1&&(h(0),g(1,"sip-skeleton",12)(2,"sip-skeleton",13),S())}function Ht(e,n){if(e&1&&(m(0,"div"),g(1,"img",15),d()),e&2){let t=s(2).$implicit;a(),o("src",t.image.url,ge)("alt",t.image.altText)}}function Vt(e,n){if(e&1&&(m(0,"a",14),l(1,"decodeURIComponent"),p(2,Ht,2,2,"div",4),m(3,"h2")(4,"span"),v(5),d()()()),e&2){let t=s().$implicit;o("routerLink",_(1,3,t.url)),a(2),o("ngIf",t.image),a(3),re(t.name)}}function zt(e,n){if(e&1&&(m(0,"div",10),p(1,jt,3,0,"ng-container",11)(2,Vt,6,5,"ng-template",null,0,P),d()),e&2){let t=y(3),i=s();a(),o("ngIf",i.shouldRenderSkeleton)("ngIfElse",t)}}function Wt(e,n){if(e&1&&g(0,"sip-category-paragraph",16),e&2){let t=n.ngIf;o("code",t.code)}}var Lt=(()=>{let n=class n{set model(i){this._model=i,this.subcategories=i.subCategories}get model(){return this.shouldRenderSkeleton?void 0:this._model}constructor(i){this.componentService=i,this.shouldRenderSkeleton=this.componentService.shouldRenderSkeleton()}};n.\u0275fac=function(r){return new(r||n)(f(D))},n.\u0275cmp=w({type:n,selectors:[["sip-category-landing-page-component"]],inputs:{model:"model"},decls:12,vars:9,consts:[["categoryItem",""],[1,"page","page-browse-category"],[1,"list-name-container"],[1,"list-name"],[4,"ngIf"],[3,"position"],[1,"category-section-header",3,"innerHTML"],[1,"category-wrapper"],["class","category-node",4,"ngFor","ngForOf"],[3,"code",4,"ngIf"],[1,"category-node"],[4,"ngIf","ngIfElse"],[1,"sip-landing-page-category-img-skeleton"],[1,"sip-landing-page-category-name-skeleton"],[1,"category-link",3,"routerLink"],["loading","lazy",1,"category-img",3,"src","alt"],[3,"code"]],template:function(r,c){r&1&&(m(0,"section",1)(1,"div",2)(2,"h1",3),p(3,At,1,0,"sip-skeleton",4),v(4),d()(),g(5,"sip-page-slot",5)(6,"p",6),l(7,"cxTranslate"),m(8,"div",7),p(9,zt,4,2,"div",8),d(),g(10,"sip-page-slot",5),p(11,Wt,1,1,"sip-category-paragraph",9),d()),r&2&&(a(3),o("ngIf",c.shouldRenderSkeleton),a(),b(" ",(c.model==null||c.model.category==null||c.model.category.displayName==null?null:c.model.category.displayName.trim())||(c.model==null||c.model.category==null?null:c.model.category.name)," "),a(),o("position","Section1"),a(),o("innerHTML",_(7,7,"shop.by.category"),M),a(3),o("ngForOf",c.subcategories),a(),o("position","Section2"),a(),o("ngIf",c.model==null?null:c.model.category))},dependencies:[Se,B,X,xe,N,Oe,Z,Le],styles:[".page-browseCategory[_ngcontent-%COMP%] .main-wrapper[_ngcontent-%COMP%]{padding-left:0;padding-right:0}.page-browse-category[_ngcontent-%COMP%]{max-width:1400px;margin-right:auto;margin-left:auto}.banner[_ngcontent-%COMP%]{margin:9px}.banner[_ngcontent-%COMP%] img[_ngcontent-%COMP%]{width:100%}@media screen and (min-width: 1024px){.banner[_ngcontent-%COMP%] img[_ngcontent-%COMP%]{max-width:984px;max-height:200px}}.list-name-container[_ngcontent-%COMP%] h1[_ngcontent-%COMP%], .list-name-container[_ngcontent-%COMP%] h2[_ngcontent-%COMP%]{color:#333;font-size:36px;margin:12px 0;font-weight:400}@media screen and (max-width: 767px){.list-name-container[_ngcontent-%COMP%] h1[_ngcontent-%COMP%], .list-name-container[_ngcontent-%COMP%] h2[_ngcontent-%COMP%]{font-size:26px}}.sip-landing-page-category-img-skeleton[_ngcontent-%COMP%]{width:100%;height:200px}.sip-landing-page-category-name-skeleton[_ngcontent-%COMP%]{margin-top:8px;height:40px;width:100%}
1[_nghost-%COMP%] .list-name[_ngcontent-%COMP%] sip-skeleton[_ngcontent-%COMP%]{width:60%;height:40px} .category-section-header{color:#333;font-size:30px;margin:12px 0 0;font-weight:400}@media screen and (max-width: 767px){ .category-section-header{font-size:20px}} .category-wrapper{text-align:left;width:100%;border-style:none} .category-node{display:inline-block;width:45%;min-width:150px;max-width:325px;border:0px solid #707070;margin:5px;padding:5px 12px 0 0;text-align:center;vertical-align:top}@media screen and (min-width: 768px) and (max-width: 1024px){ .category-node{width:25%}}@media screen and (min-width: 1024px){ .category-node{padding-top:13px;font-size:1em;width:25%}} .category-node span, .category-node h3{display:inline-block;width:100%;text-align:left;font-size:21px;padding:5px 0}@media screen and (min-width: 768px) and (max-width: 1024px){ .category-node span, .category-node h3{font-size:19px}}@media screen and (max-width: 767px){ .category-node span, .category-node h3{font-size:18px}} .category-node span:hover, .category-node h3:hover{text-decoration:underline} .category-node a:link, .category-node a:visited, .category-node a:hover, .category-node a:active{text-decoration:none;color:#005dab;font-weight:400} .category-img{max-width:320px;max-height:220px;width:100%}"],changeDetection:0});let e=n;return e})();var Qt=["dymSpan"],Ne=e=>({results:e}),Ot=(e,n,t)=>({0:e,1:n,2:t}
1),Zt=(e,n)=>({0:e,1:n}),Xt=e=>({subcategories:e});function Jt(e,n){e&1&&ae(0)}function Kt(e,n){e&1&&(m(0,"div",15),g(1,"sip-product-facet-navigation"),d())}function ei(e,n){if(e&1&&(h(0),p(1,Kt,2,0,"div",14),S()),e&2){let t=s(2);a(),o("ngIf",(t.isCLPPage?(t.page==null?null:t.page.enable_search_filter)&&(t.model==null||t.model.facets==null?null:t.model.facets.length)>0:t.page==null?null:t.page.enable_search_filter)||t.isSRP)}}function ti(e,n){if(e&1&&(m(0,"span"),v(1),l(2,"cxTranslate"),d()),e&2){let t=s(2).ngIf,i=s(3);a(),b(" ",$(2,1,"search.page.spellCheck.autoCorrect",G(4,Ot,i.model.searchTextOriginal,i.model.pagination==null?null:i.model.pagination.totalResults,t))," ")}}function ii(e,n){if(e&1&&(g(0,"span",22,4),l(2,"async"),l(3,"cxTranslate"),l(4,"safeHtml")),e&2){let t=s(3).ngIf,i=s(3);o("innerHTML",_(4,6,$(3,3,"search.page.spellCheck.didYouMean",G(8,Ot,i.model==null||i.model.pagination==null?null:i.model.pagination.totalResults,t,_(2,1,i.suggestionLink$)))),M)}}function ni(e,n){if(e&1&&p(0,ii,5,12,"span",21),e&2){s();let t=y(5),i=s(4);o("ngIf",i.model.didYouMean)("ngIfElse",t)}}function oi(e,n){if(e&1&&(m(0,"span"),v(1),l(2,"cxTranslate"),d()),e&2){let t=s(2).ngIf,i=s(3);a(),b(" ",$(2,1,(i.model==null||i.model.pagination==null?null:i.model.pagination.totalResults)===1?"search.page.title.single-result":"search.page.title.multiple-results",he(4,Zt,i.model==null||i.model.pagination==null?null:i.model.pagination.totalResults,t))," ")}}function ai(e,n){if(e&1&&(m(0,"h1",19),p(1,ti,3,8,"span",20)(2,ni,1,2,"ng-template",null,2,P)(4,oi,3,7,"ng-template",null,3,P),d()),e&2){let t=y(3),i=s(4);a(),o("ngIf",i.model.autoSpellCheck)("ngIfElse",t)}}function ri(e,n){if(e&1&&(m(0,"div",17),p(1,ai,6,2,"h1",18),d()),e&2){let t=s(3);a(),o("ngIf",t.model==null||t.model.pagination==null?null:t.model.pagination.totalResults)}}function ci(e,n){if(e&1&&(h(0),p(1,ri,2,1,"div",16),S()),e&2){let t=s(2);a(),o("ngIf",t.model==null?null:t.model.freeTextSearch)}}function pi(e,n){if(e&1&&(m(0,"h1",23),v(1),d()),e&2){let t=s(2);a(),re(t.title)}}function si(e,n){e&1&&ae(0)}function li(e,n){e&1&&ae(0)}function mi(e,n){if(e&1&&(m(0,"div"),g(1,"p",24),l(2,"cxTranslate"),p(3,li,1,0,"ng-container",9),d()),e&2){let t=s(2),i=y(3);a(),o("innerHTML",_(2,3,"shop.by.category"),M),a(2),o("ngTemplateOutlet",i)("ngTemplateOutletContext",A(5,Xt,t.subcategories))}}function di(e,n){e&1&&(m(0,"div"),g(1,"sip-product-list"),d())}function gi(e,n){e&1&&ae(0)}function _i(e,n){e&1&&(h(0),g(1,"sip-compare-product-widget"),S())}function ui(e,n){if(e&1&&(m(0,"section",7)(1,"div",8),p(2,Jt,1,0,"ng-container",9),d(),m(3,"div",10),p(4,ei,2,1,"ng-container",11),m(5,"div",12),p(6,ci,2,1,"ng-container",11)(7,pi,2,1,"h1",13),m(8,"div",8),p(9,si,1,0,"ng-container",9),d(),p(10,mi,4,7,"div",11)(11,di,2,0,"div",11),m(12,"div",8),p(13,gi,1,0,"ng-container",9),d()()(),p(14,_i,2,0,"ng-container",11),d()),e&2){let t=s(),i=y(5);a(2),o("ngTemplateOutlet",i)("ngTemplateOutletContext",A(12,Ne,t.page==null?null:t.page.page_top_section)),a(2),o("ngIf",(t.page==null?null:t.page.enable_search)||t.isSRP),a(2),o("ngIf",t.isSRP),a(),o("ngIf",t.title&&!t.isSRP),a(2),o("ngTemplateOutlet",i)("ngTemplateOutletContext",A(14,Ne,t.page==null?null:t.page.above_search_results)),a(),o("ngIf",(t.page==null?null:t.page.enable_shop_by_category)&&(t.subcategories==null?null:t.subcategories.length)>0&&(t.model==null?null:t.model.categoryLandingPage)),a(),o("ngIf",((t.page==null?null:t.page.enable_search)||t.isSRP)&&(t.model==null||t.model.products==null?null:t.model.products.length)>0),a(2),o("ngTemplateOutlet",i)("ngTemplateOutletContext",A(16,Ne,t.page==null?null:t.page.below_search_results)),a(),o("ngIf",((t.page==null?null:t.page.enable_search)||t.isSRP)&&(t.model==null||t.model.products==null?null:t.model.products.length)>0)}}function fi(e,n){e&1&&(m(0,"section",7)(1,"div",10)(2,"div",15),g(3,"sip-product-facet-navigation-skeleton"),d(),m(4,"div",12),g(5,"sip-product-list-skeleton"),d()()())}function hi(e,n){e&1&&(h(0),g(1,"sip-skeleton",28)(2,"sip-skeleton",29),S())}function Si(e,n){if(e&1&&(m(0,"div"),g(1,"img",31),d()),e&2){let t=s(2).$implicit;a(),o("src",t.image.url,ge)("alt",t.image.altText)}}function Ci(e,n){if(e&1&&(m(0,"a",30),l(1,"decodeURIComponent"),p(2,Si,2,2,"div",11),m(3,"h2")(4,"span"),v(5),d()()()),e&2){let t=s().$implicit;
1o("routerLink",_(1,3,t.url)),a(2),o("ngIf",t.image),a(3),re(t.name)}}function xi(e,n){if(e&1&&(m(0,"div",27),p(1,hi,3,0,"ng-container",20)(2,Ci,6,5,"ng-template",null,5,P),d()),e&2){let t=y(3),i=s(2);a(),o("ngIf",i.shouldRenderSkeleton)("ngIfElse",t)}}function yi(e,n){if(e&1&&(m(0,"div",25),p(1,xi,4,2,"div",26),d()),e&2){let t=n.subcategories;a(),o("ngForOf",t)}}function vi(e,n){if(e&1&&(m(0,"div"),g(1,"sip-cs-dynamic-component",33),d()),e&2){let t=n.$implicit;a(),o("componentInfo",t)}}function Pi(e,n){if(e&1&&p(0,vi,2,1,"div",32),e&2){let t=n.results;o("ngForOf",t)}}var kt=(()=>{let n=class n{set model(i){this._model=i,this.subcategories=i.subCategories,this.isSRP&&this._model&&!this.shouldRenderSkeleton&&this.initDymLink(i)}get model(){return this.shouldRenderSkeleton?void 0:this._model}set page(i){let r=ce(F({},i),{page_top_section:this.updateTitles(i.page_top_section),above_search_results:this.updateTitles(i.above_search_results),below_search_results:this.updateTitles(i.below_search_results)});this._page=r,this.isCLPPage=i?.type==="ContentPage"}get page(){return this.shouldRenderSkeleton?void 0:this._page}set title(i){this._title=i}get title(){return this._title}constructor(i,r,c,u,x,L,E){this.router=i,this.route=r,this.sipGtmService=c,this.translation=u,this.winRef=x,this.componentService=L,this.sipGoogleRetailService=E,this.isCLPPage=!1,this.suggestionLink_=new pe("<a></a>"),this.suggestionLink$=this.suggestionLink_.asObservable(),this.shouldRenderSkeleton=this.componentService.shouldRenderSkeleton(),this.isSRP=!1,this.sub=new H}ngOnInit(){this.isSRP&&this._model&&!this.shouldRenderSkeleton&&this.initDymLink(this._model)}ngAfterViewInit(){this.isSRP&&!this.shouldRenderSkeleton&&this.pushGtmEvents()}updateTitles(i){return i?.length?i.map(r=>{let c=F({},r);return c?.ad_set_costco_block?.ad_set_costco_ref&&(c.ad_set_costco_block=F({},c.ad_set_costco_block),c.ad_set_costco_block.ad_set_costco_ref=c.ad_set_costco_block.ad_set_costco_ref.map(u=>u?.product_recommendation&&u?.product_recommendation_types===It.ThirdParty&&u?.product_content?.third_party_recommendation_types===Mt.TOP_SELLER?ce(F({},u),{ad_set_heading_and_costco_url:ce(F({},u.ad_set_heading_and_costco_url),{title:u?.ad_set_heading_and_costco_url?.title?.replace("#{category}",this.model?.category?.name)})}):F({},u))),c}):i}initDymLink(i){let r=i.spellingSuggestion?.suggestion;this.suggestionLink_.next(`<a class="dym" href="#" role="button">${r||i.searchTextOriginal||""}</a>`),this.winRef.isBrowser()&&setTimeout(()=>{if(!this.dymSpan)return;let c=this.dymSpan.nativeElement;c&&c.querySelector("a").addEventListener("click",u=>{u.preventDefault(),this.router.navigate([],{relativeTo:this.route,queryParams:{text:r||"",dymSpellCheck:!0,searchTextOriginal:i.searchTextOriginal},queryParamsHandling:"merge"})})},0)}pushGtmEvents(){let i=k([V(this._model).pipe(I(r=>!!r&&!!r.freeTextSearch)),this.translation.translate("breadcrumb.search.result.suffix").pipe(se(1))]);this.sub.add(this.sipGtmService.hasPageView$.pipe(I(Boolean),de(i)).subscribe(([r,[c,u]])=>{let x={label:u,link:`/search?text=${Me(encodeURI(u))}`};this.pushSearchResultPageGtmEvents(c,x),this.sipGtmService.hasPageView$.next(!1)}))}pushSearchResultPageGtmEvents(i,r){if(i?.products?.length===0&&this.sipGtmService.pushZeroSearchResultEvent(i.searchTextOriginal),i?.products?.length>0){this.sipGtmService.pushSearchResultEvent(r.label,i.freeTextSearch,i.pagination.totalResults,i.freeTextSearch);let c=this.sipGtmService.generateSearchGta4AttributionId();this.sipGoogleRetailService.pushRetailSearchEvent(i.products,i.freeTextSearch,c),this.sipGtmService.pushProductImpressionEvents(i.products,r,Pe.SEARCH_RESULTS),this.sipGtmService.pushGA4ViewItemListEvent(i.products,r,Te.VIEW_ITEM_LIST_NAME_PLP,c,i.pagination.totalResults)}}ngOnDestroy(){this.sub&&this.sub.unsubscribe()}};n.\u0275fac=function(r){return new(r||n)(f(Ce),f(Y),f(Ie),f(ve),f(ye),f(D),f(Re))},n.\u0275cmp=w({type:n,selectors:[["sip-generic-product-listing-page-component"]],viewQuery:function(r,c){if(r&1&&_e(Qt,5),r&2){let u;ue(u=fe())&&(c.dymSpan=u.first)}},inputs:{isSRP:"isSRP",model:"model",page:"page",title:"title"},decls:6,vars:2,consts:[["categoryTemplate",""],["componentsTemplate",""],["dym",""],["defaultResults",""],["dymSpan",""],["categoryItem",""],["class","clp-page",4,"ngIf"],[1,"clp-page"],[1,"layout-spacer"],[4,"ngTemplateOutlet","ngTemplateOutletContext"],[1,"clp-container"],[4,"ngIf"],[1,"main-section"],["class","list-name",4,"ngIf"],["class","filter-section hidden-xs",4,"ngIf"],[1,"filter-section","hidden-xs"],["class","search-page-header header-left-section",4,"ngIf"],[1,"search-page-header","header-left-section"],["class","results notranslate",4,"ngIf"],[1,"results","notranslate"],[4,"ngIf","ngIfElse"],[3,"innerHTML",4,"ngIf","ngIfElse"],[3,"innerHTML"],[1,"list-name"],[1,"category-section-header",3,"innerHTML"],[1,"category-wrapper"],["class","category-node",4,"ngFor","ngForOf"],[1,"category-node"],[1,"sip-landing-page-category-img-skeleton"],[1,"sip-landing-page-category-name-skeleton"],[1,"category-link",3,"routerLink"],["loading","lazy",1,"category-img",3,"src","alt"],[4,"ngFor","ngForOf"],[3,"componentInfo"]],template:function(r,c){r&1&&p(0,ui,15,18,"section",6)(1,fi,6,0,"section",6)(2,yi,2,1,"ng-template",null,0,P)(4,Pi,1,1,"ng-template",null,1,P),r&2&&(o("ngIf",c.page),a(),o("ngIf",c.shouldRenderSkeleton))},dependencies:[Se,B,We,xe,N,it,St,ht,vt,Pt,ft,U,Z,K,Le],styles:[".clp-container[_ngcontent-%COMP%]{display:flex;flex-direction:row;gap:20px}.clp-container[_ngcontent-%COMP%] .filter-section[_ngcontent-%COMP%]{flex:1 1 25%;
1min-width:200px}.clp-container[_ngcontent-%COMP%] .main-section[_ngcontent-%COMP%]{display:flex;flex-direction:column;justify-content:flex-start;flex:1 1 75%;min-width:250px}.clp-container[_ngcontent-%COMP%] .main-section[_ngcontent-%COMP%] .list-name[_ngcontent-%COMP%], .clp-container[_ngcontent-%COMP%] .main-section[_ngcontent-%COMP%] .layout-spacer[_ngcontent-%COMP%]{margin:8px 0}.clp-container[_ngcontent-%COMP%] .main-section[_ngcontent-%COMP%] .layout-spacer[_ngcontent-%COMP%] > div[_ngcontent-%COMP%]:not(:last-child){margin-bottom:20px}@media screen and (min-width: 768px) and (max-width: 1023px){.clp-container[_ngcontent-%COMP%] .main-section[_ngcontent-%COMP%] .layout-spacer[_ngcontent-%COMP%] > div[_ngcontent-%COMP%]:not(:last-child){margin-bottom:24px}}@media screen and (min-width: 1024px){.clp-container[_ngcontent-%COMP%] .main-section[_ngcontent-%COMP%] .layout-spacer[_ngcontent-%COMP%] > div[_ngcontent-%COMP%]:not(:last-child){margin-bottom:30px}}.clp-container[_ngcontent-%COMP%] .main-section[_ngcontent-%COMP%] .search-page-header[_ngcontent-%COMP%]{padding-top:16px}.clp-container[_ngcontent-%COMP%] .category-section-header{color:#333;font-size:28px;margin:8px 0 0;font-weight:400}@media screen and (max-width: 767px){.clp-container[_ngcontent-%COMP%] .category-section-header{font-size:18px}}.clp-container[_ngcontent-%COMP%] .category-wrapper{text-align:left;width:100%;border-style:none}.clp-container[_ngcontent-%COMP%] .category-node{display:inline-block;width:45%;min-width:150px;max-width:325px;border:0px solid #707070;margin:5px;padding:5px 12px 0 0;text-align:center;vertical-align:top}@media screen and (min-width: 768px) and (max-width: 1024px){.clp-container[_ngcontent-%COMP%] .category-node{width:25%}}@media screen and (min-width: 1024px){.clp-container[_ngcontent-%COMP%] .category-node{padding-top:13px;font-size:1em;width:25%}}.clp-container[_ngcontent-%COMP%] .category-node span, .clp-container[_ngcontent-%COMP%] .category-node h3{display:inline-block;width:100%;text-align:left;font-size:24px;padding:5px 0}@media screen and (min-width: 768px) and (max-width: 1024px){.clp-container[_ngcontent-%COMP%] .category-node span, .clp-container[_ngcontent-%COMP%] .category-node h3{font-size:18px}}@media screen and (max-width: 767px){.clp-container[_ngcontent-%COMP%] .category-node span, .clp-container[_ngcontent-%COMP%] .category-node h3{font-size:18px}}.clp-container[_ngcontent-%COMP%] .category-node span:hover, .clp-container[_ngcontent-%COMP%] .category-node h3:hover{text-decoration:underline}.clp-container[_ngcontent-%COMP%] .category-node a:link, .clp-container[_ngcontent-%COMP%] .category-node a:visited, .clp-container[_ngcontent-%COMP%] .category-node a:hover, .clp-container[_ngcontent-%COMP%] .category-node a:active{text-decoration:none;color:#005dab;font-weight:400}.clp-container[_ngcontent-%COMP%] .category-img{max-width:320px;max-height:220px;width:100%}"],changeDetection:0});let e=n;return e})();var Mi=["dymSpan"],wt=(e,n,t)=>({0:e,1:n,2:t}),Ri=(e,n)=>({0:e,1:n});function Li(e,n){e&1&&g(0,"sip-skeleton",7)}function Ei(e,n){if(e&1&&(m(0,"span"),v(1),l(2,"cxTranslate"),d()),e&2){let t=s(2).ngIf,i=s().ngIf;a(),b(" ",$(2,1,"search.page.spellCheck.autoCorrect",G(4,wt,i.searchTextOriginal,i.pagination==null?null:i.pagination.totalResults,t))," ")}}function Oi(e,n){if(e&1&&(g(0,"span",14,2),l(2,"cxTranslate"),l(3,"safeHtml")),e&2){let t=s(2).ngIf,i=s().ngIf,r=s(2);o("innerHTML",_(3,4,$(2,1,"search.page.spellCheck.didYouMean",G(6,wt,t,i,r.suggestionLink.value))),M)}}function ki(e,n){if(e&1&&p(0,Oi,4,10,"span",13),e&2){s();let t=y(5),i=s(2).ngIf;o("ngIf",i.didYouMean)("ngIfElse",t)}}function wi(e,n){if(e&1&&(m(0,"span"),v(1),l(2,"cxTranslate"),d()),e&2){let t=s().ngIf,i=s().ngIf;a(),b(" ",$(2,1,t===1?"search.page.title.single-result":"search.page.title.multiple-results",he(4,Ri,t,i))," ")}}function bi(e,n){if(e&1&&(m(0,"h1",11),p(1,Ei,3,8,"span",12)(2,ki,1,2,"ng-template",null,0,P)(4,wi,3,7,"ng-template",null,1,P),d()),e&2){let t=y(3),i=s(2).ngIf;a(),o("ngIf",i.autoSpellCheck)("ngIfElse",t)}}function Gi(e,n){if(e&1&&(m(0,"div",8),p(1,bi,6,2,"h1",9),l(2,"async"),g(3,"sip-page-slot",10),d()),e&2){let t=s(2);a(),o("ngIf",_(2,1,t.count$))}}function $i(e,n){if(e&1&&(h(0),p(1,Li,1,0,"sip-skeleton",4)(2,Gi,4,3,"div",5),g(3,"sip-page-slot",6),S()),e&2){let t=n.ngIf,i=s();a(),o("ngIf",i.shouldRenderSkeleton),a(),o("ngIf",t==null?null:t.freeTextSearch)}}var bt=(()=>{let n=class n{constructor(i,r,c,u,x,L,E,O){this.productListingService=i,this.router=r,this.route=c,this.sipGtmService=u,this.translation=x,this.winRef=L,this.cmsComponentService=E,this.sipGoogleRetailService=O,this.shouldRenderSkeleton=this.cmsComponentService.shouldRenderSkeleton(),this.searchPage$=this.shouldRenderSkeleton?V({}):this.productListingService.model$,this.count$=this.searchPage$.pipe(me("pagination","totalResults")),this.suggestionLink=new pe("<a></a>"),this.sub=new H}ngOnInit(){this.sub=this.searchPage$.pipe(I(i=>!!i&&!this.shouldRenderSkeleton),oe(i=>
1this.initDymLink(i))).subscribe()}ngAfterViewInit(){this.shouldRenderSkeleton||this.pushGtmEvents()}initDymLink(i){let r=i.spellingSuggestion?i.spellingSuggestion.suggestion:void 0;this.suggestionLink.next(`<a class="dym" href="javascript:void(0)">${r||i.searchTextOriginal||""}</a>`),this.winRef.nativeWindow&&setTimeout(()=>{if(!this.dymSpan)return;let c=this.dymSpan.nativeElement;c&&c.querySelector("a").addEventListener("click",u=>{u.preventDefault(),this.router.navigate([],{relativeTo:this.route,queryParams:{text:r||"",dymSpellCheck:!0,searchTextOriginal:i.searchTextOriginal},queryParamsHandling:"merge"})})},0)}pushGtmEvents(){let i=k([this.searchPage$.pipe(I(r=>!!r&&!!r.freeTextSearch)),this.translation.translate("breadcrumb.search.result.suffix").pipe(se(1))]);this.sub.add(this.sipGtmService.hasPageView$.pipe(I(Boolean),de(i)).subscribe(([r,[c,u]])=>{let x={label:u,link:`/search?text=${Me(encodeURI(u))}`};this.pushSearchResultPageGtmEvents(c,x),this.sipGtmService.hasPageView$.next(!1)}))}pushSearchResultPageGtmEvents(i,r){if((i?.products?.length===0||i?.searchTextOriginal)&&this.sipGtmService.pushZeroSearchResultEvent(i.searchTextOriginal),i?.products?.length>0){this.sipGtmService.pushSearchResultEvent(r.label,i.freeTextSearch,i.pagination.totalResults,i.freeTextSearch);let c=this.sipGtmService.generateSearchGta4AttributionId();this.sipGoogleRetailService.pushRetailSearchEvent(i.products,i.freeTextSearch,c),this.sipGtmService.pushProductImpressionEvents(i.products,r,Pe.SEARCH_RESULTS),this.sipGtmService.pushGA4ViewItemListEvent(i.products,r,Te.VIEW_ITEM_LIST_NAME_PLP,c,i.pagination.totalResults)}}ngOnDestroy(){this.sub&&this.sub.unsubscribe()}};n.\u0275fac=function(r){return new(r||n)(f(R),f(Ce),f(Y),f(Ie),f(ve),f(ye),f(D),f(Re))},n.\u0275cmp=w({type:n,selectors:[["sip-product-search-results"]],viewQuery:function(r,c){if(r&1&&_e(Mi,5),r&2){let u;ue(u=fe())&&(c.dymSpan=u.first)}},decls:2,vars:3,consts:[["dym",""],["defaultResults",""],["dymSpan",""],[4,"ngIf"],["class","search-page-header__skeleton",4,"ngIf"],["class","search-page-header header-left-section",4,"ngIf"],["position","SearchResultsGrid"],[1,"search-page-header__skeleton"],[1,"search-page-header","header-left-section"],["class","results notranslate",4,"ngIf"],["position","SearchResultsBanner"],[1,"results","notranslate"],[4,"ngIf","ngIfElse"],[3,"innerHTML",4,"ngIf","ngIfElse"],[3,"innerHTML"]],template:function(r,c){r&1&&(p(0,$i,4,2,"ng-container",3),l(1,"async")),r&2&&o("ngIf",_(1,1,c.searchPage$))},dependencies:[B,X,N,U,Z,K],styles:["span a.dym{text-transform:none}.search-page-header__skeleton[_ngcontent-%COMP%]{height:40px}"],changeDetection:0});let e=n;return e})();var Di=(e,n,t)=>({flexType:e,typeCode:n,uid:t}),Ni=e=>({"content-stack-search-page":e});function Fi(e,n){if(e&1&&g(0,"div",13),e&2){let t=s().ngIf;o("cxComponentWrapper",G(1,Di,t.cmsComponent.typeCode,t.cmsComponent.typeCode,t.cmsComponent.uid))}}function Ai(e,n){e&1&&g(0,"sip-skeleton")}function ji(e,n){if(e&1&&(h(0),p(1,Fi,1,5,"div",4),m(2,"div",5),g(3,"sip-page-slot",6),m(4,"div",7),g(5,"sip-page-slot",8),d(),m(6,"div",9)(7,"h1",10),l(8,"async"),l(9,"safeHtml"),p(10,Ai,1,0,"sip-skeleton",1),d(),g(11,"sip-page-slot",11)(12,"sip-category-paragraph",12),d()(),S()),e&2){let t=n.ngIf,i=s(4);a(),o("ngIf",t.cmsComponent&&t.campaign),a(6),o("innerHTML",_(9,6,_(8,4,i.categoryTitle$)),M),a(3),o("ngIf",i.shouldRenderSkeleton),a(2),o("code",t.code)}}function Hi(e,n){if(e&1&&(h(0),p(1,ji,13,8,"ng-container",1),l(2,"async"),S()),e&2){let t=s(3);a(),o("ngIf",_(2,1,t.category$))}}function Vi(e,n){if(e&1&&(h(0),g(1,"sip-generic-product-listing-page-component",14),l(2,"async"),l(3,"async"),l(4,"async"),S()),e&2){let t=s(3);a(),o("model",_(2,3,t.model$))("page",_(3,5,t.csPage$))("title",_(4,7,t.categoryTitle$))}}function zi(e,n){if(e&1&&(m(0,"div"),p(1,Hi,3,3,"ng-container",1),l(2,"async"),p(3,Vi,5,9,"ng-container",1),l(4,"async"),d()),e&2){let t=s(2);a(),o("ngIf",!_(2,2,t.isValidCSPage$)),a(2),o("ngIf",_(4,4,t.isValidCSPage$))}}function Wi(e,n){e&1&&g(0,"sip-page-slot",18)}function Ui(e,n){e&1&&g(0,"sip-tire-warehouse-selection")}
1function qi(e,n){e&1&&g(0,"sip-tire-product-tabs")}function Yi(e,n){if(e&1&&(m(0,"div")(1,"div",16),p(2,Wi,1,0,"sip-page-slot",17),l(3,"async"),p(4,Ui,1,0,"sip-tire-warehouse-selection",1),l(5,"async"),d(),p(6,qi,1,0,"sip-tire-product-tabs",1),d()),e&2){let t=s(3);a(2),o("ngIf",!_(3,3,t.isValidCSPage$)),a(2),o("ngIf",_(5,5,t.isValidCSPage$)),a(2),o("ngIf",!t.shouldRenderSkeleton)}}function Qi(e,n){e&1&&(h(0),m(1,"div",19),g(2,"sip-page-slot",8),d(),m(3,"div",20)(4,"div",5),g(5,"sip-product-search-results"),d()(),S())}function Zi(e,n){if(e&1&&(h(0),g(1,"sip-generic-product-listing-page-component",21),l(2,"async"),l(3,"async"),l(4,"async"),S()),e&2){let t=s(3);a(),o("model",_(2,4,t.model$))("page",_(3,6,t.csPage$))("title",_(4,8,t.categoryTitle$))("isSRP",!0)}}function Xi(e,n){if(e&1&&(h(0),m(1,"div",15),l(2,"async"),p(3,Yi,7,7,"div",1),l(4,"async"),l(5,"async"),p(6,Qi,6,0,"ng-container",1),l(7,"async"),p(8,Zi,5,10,"ng-container",1),l(9,"async"),d(),S()),e&2){let t=s(2);a(),o("ngClass",A(14,Ni,!!_(2,4,t.isValidCSPage$))),a(2),o("ngIf",_(4,6,t.tireFitmentType$)||_(5,8,t.batteriesPlp$)),a(3),o("ngIf",!_(7,10,t.isValidCSPage$)),a(2),o("ngIf",_(9,12,t.isValidCSPage$))}}function Ji(e,n){e&1&&(h(0),p(1,zi,5,6,"div",2)(2,Xi,10,16,"ng-container",2),g(3,"sip-page-slot",3),S()),e&2&&(a(),o("ngSwitchCase","listing"),a(),o("ngSwitchCase","search"))}function Ki(e,n){if(e&1&&(g(0,"sip-category-landing-page-component",23),l(1,"async")),e&2){let t=s(2);o("model",_(1,1,t.model$))}}function en(e,n){if(e&1&&(h(0),g(1,"sip-generic-product-listing-page-component",14),l(2,"async"),l(3,"async"),l(4,"async"),l(5,"async"),S()),e&2){let t,i=s(2);a(),o("model",_(2,3,i.model$))("page",_(3,5,i.csPage$))("title",((t=_(4,7,i.model$))==null||t.category==null?null:t.category.displayName)||((t=_(5,9,i.model$))==null||t.category==null?null:t.category.name))}}function tn(e,n){if(e&1&&(h(0),p(1,Ki,2,3,"sip-category-landing-page-component",22),l(2,"async"),p(3,en,6,11,"ng-container",1),l(4,"async"),S()),e&2){let t=s();a(),o("ngIf",!_(2,2,t.isValidCSPage$)),a(2),o("ngIf",_(4,4,t.isValidCSPage$))}}function nn(e,n){e&1&&(h(0),g(1,"sip-content-page"),S())}function on(e,n){e&1&&(h(0),g(1,"sip-search-empty-page"),S())}var ne=function(e){return e.LISTING="listing",e.CATEGORY_LANDING_PAGE="category-landing-page",e.SEARCH="search",e.INVALID_CATEGORY="invalid-category",e.NO_RESULT="no-result",e}(ne||{}),Gt=(()=>{let n=class n{constructor(i,r,c,u,x,L,E,O){this.productListingService=i,this.cmsService=r,this.siteService=c,this.activatedRoute=u,this.tireService=x,this.cmsComponentService=L,this.csConfigService=E,this.csCmsService=O,this.sub=new H,this.model$=this.productListingService.model$,this.count$=this.model$.pipe(T(C=>C?.pagination?.totalResults||0)),this.page$=this.cmsService.getCurrentPage(),this.isContentStackPage$=this.csConfigService.getContentStackPage(),this.csPage$=this.csCmsService.getContentStackPageData(),this.isValidCSPage$=k([this.isContentStackPage$,this.csPage$]).pipe(T(([C,we])=>!!C&&!!we)),this.pageToDisplay$=k([this.model$.pipe(T(C=>!!C.category),je(!1),le()),this.page$.pipe(I(C=>!!C?.type),T(C=>C.type),le()),this.count$,this.model$.pipe(le()),this.isContentStackPage$]).pipe(T(([C,we,Fe,Ae,Dt])=>{if(we===qe.CONTENT_PAGE||Dt){if(Ae?.categoryLandingPage)return ne.CATEGORY_LANDING_PAGE;if(Fe===void 0)return ne.INVALID_CATEGORY}return!Fe&&!Ae?.categoryLandingPage?ne.NO_RESULT:C?ne.LISTING:ne.SEARCH})),this.category$=this.model$.pipe(me("category")),this.categoryTitle$=this.resolveCategoryTitle(),this.shouldRenderSkeleton=this.cmsComponentService.shouldRenderSkeleton()}ngOnInit(){this.tireFitmentType$=this.activatedRoute.queryParams.pipe(oe(i=>this.tireService.updateTireSearchCriteriaValue()),T(i=>!!i.frontfilters)),this.batteriesPlp$=this.activatedRoute.queryParams.pipe(oe(i=>this.tireService.updateTireSearchCriteriaValue()),T(i=>!!i.isBatteriesSearch))}resolveCategoryTitle(){return this.cmsComponentService.shouldRenderSkeleton()?V(""):k([this.model$,this.siteService.getConfig(R.TITLE_LIMIT_PROPERTY_ID)]).pipe(T(([i,r])=>{let c=r?+r:R.DEFAULT_TITLE_MAX_LENGTH,u=i.breadcrumbs?i.breadcrumbs.slice().sort(this.productListingService.facetComparator).map(C=>C.facetValueName):[],x=i.category,L=x?.displayName?.trim()||x?.name?.trim()||"",E=L.length,O="";for(let C of u){if(O.length+C.length+E>=c)break;O+=" "+C}return E>0?(O+" "+L).trim():O.trim()}))}ngOnDestroy(){this.sub&&this.sub.unsubscribe()}};n.\u0275fac=function(r){return new(r||n)(f(R),f(Ye),f(ct),f(Y),f(st),f(D),f(pt),f(lt))},n.\u0275cmp=w({type:n,selectors:[["sip-product-listing"]],decls:7,vars:9,consts:[[3,"ngSwitch"],[4,"ngIf"],[4,"ngSwitchCase"],["position","CompareProductWidget"],[3,"cxComponentWrapper",4,"ngIf"],[1,"row"],["position","Section1"],[1,"col-sm-3","hidden-xs"],["position","ProductLeftRefinements"],[1,"col-sm-9"],[1,"category-title",3,"innerHTML"],["position","ProductList"],[3,"code"],[3,"cxComponentWrapper"],[3,"model","page","title"],[3,"ngClass"],[1,"tire-search-result-banner","search-Message","warehouse-address"],["position","TireWarehouseSection",4,"ngIf"],["position","TireWarehouseSection"],[1,"col-sm-3"],[1,"col-sm-9","search-page-container"],[3,"model","page","title","isSRP"],[3,"model",4,"ngIf"],[3,"model"]],template:function(r,c){r&1&&(h(0,0),l(1,"async"),p(2,Ji,4,2,"ng-container",1),l(3,"async"),p(4,tn,5,6,"ng-container",2)(5,nn,2,0,"ng-container",2)(6,on,2,0,"ng-container",2),S()),r&2&&(o("ngSwitch",_(1,5,c.pageToDisplay$)),a(2),o("ngIf",_(3,7,c.count$)),a(2),o("ngSwitchCase","category-landing-page"),a(),o("ngSwitchCase","invali
1d-category"),a(),o("ngSwitchCase","no-result"))},dependencies:[He,B,Ve,ze,X,Ze,nt,gt,Lt,N,mt,kt,Oe,dt,bt,U,K],styles:["@media screen and (max-width: 480px){.col-sm-3[_ngcontent-%COMP%]{display:none}}@media (max-width: 767px){.col-sm-3[_ngcontent-%COMP%]{display:none}}[_nghost-%COMP%] .category-title[_ngcontent-%COMP%] sip-skeleton[_ngcontent-%COMP%]{width:60%;height:40px}.content-stack-search-page[_ngcontent-%COMP%]{display:flex;flex-direction:column}"],changeDetection:0});let e=n;return e})();var $t=(()=>{let n=class n{};n.\u0275fac=function(r){return new(r||n)},n.\u0275mod=W({type:n}),n.\u0275inj=z({imports:[q,J,j,Q,te,ee,ke]});let e=n;return e})();var Bt=(()=>{let n=class n{};n.\u0275fac=function(r){return new(r||n)},n.\u0275mod=W({type:n}),n.\u0275inj=z({imports:[q,J,j,Q,te,ee,ot,Ee,Tt]});let e=n;return e})();var Mo=(()=>{let n=class n{};n.\u0275fac=function(r){return new(r||n)},n.\u0275mod=W({type:n}),n.\u0275inj=z({providers:[{provide:et,useExisting:R},{provide:Qe,useExisting:rt},{provide:Ke,useExisting:Ue}],imports:[q,Je,tt,Ee,J,_t,ut,j,Q.forChild([{path:"",component:Gt}]),Xe,j,ee,at,yt,$t,te,xt,Bt,ke,Ct]});let e=n;return e})();export{Mo as SipProductListingPageModule};
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.