"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[78370],{1487:(e,t,l)=>{l.d(t,{m:()=>i});var i=function(e){return e.SIDETREAD="sidetread",e.SIDEWALL="sidewall",e.TREADFULL="treadfull",e.TREADONLY="treadonly",e}({})},4061:(e,t,l)=>{l.d(t,{A:()=>a,G:()=>r});var i=l(14232),n=l(1487);function r(e){let t={[n.m.SIDETREAD]:-1,[n.m.SIDEWALL]:-1,[n.m.TREADFULL]:-1,[n.m.TREADONLY]:-1};return(e.forEach((e,l)=>{t[e.productImageType]=l}),t[n.m.SIDETREAD]>=0)?e[t[n.m.SIDETREAD]].image:t[n.m.TREADFULL]>=0?e[t[n.m.TREADFULL]].image:t[n.m.SIDEWALL]>=0?e[t[n.m.SIDEWALL]].image:e.length>0?e[0].image:{src:"https://images.simpletire.com/image/upload/v1617286846/steer/common/s-tire-skeleton.svg",altText:"No Product Image"}}function a(e){return(0,i.useMemo)(()=>r(e),[e])}},7080:(e,t,l)=>{l.d(t,{A:()=>n});var i=l(14232);function n(e,t,l){let n=(0,i.useRef)(!1);(0,i.useEffect)(()=>{!n.current&&l(t)&&(e(),n.current=!0)},[t])}},15501:(e,t,l)=>{l.d(t,{JW:()=>u,s9:()=>d});var i=l(29747),n=l(14232),r=l(52980),a=l(36307);let o=(0,a.q6)();function d(e){let{children:t}=e,l=function(){let[e,t]=(0,n.useState)(!1);return{isGTMScriptLoaded:e,onGTMScriptLoad:(0,n.useCallback)(()=>{r.A.initialize(),r.A.onScriptLoaded(),t(!0)},[])}}();return(0,i.Y)(o.Provider,{value:l,"data-element":"unknown","data-component":"GTMScriptContextProvider",children:t})}let u=(e,t)=>(0,a.i7)(o,e,t)},66541:(e,t,l)=>{l.d(t,{R8:()=>T,u2:()=>P,tf:()=>g});var i=l(29747),n=l(42486),r=l(14e3),a=l(14232),o=l(88772),d=l(72747),u=l(86089);async function s(e){let{query:t,signal:l}=e;return await (0,u.q$)({endpoint:"/users/recent-search",includeAuthorization:!0,includeUserRegion:!0,includeUserSSOUid:!0,includeUserTime:!0,includeUserZip:!0,method:"get",query:t,signal:l})}async function c(e){let{query:t,signal:l}=e;return await (0,u.q$)({endpoint:"/users/recent-search",includeAuthorization:!0,includeUserRegion:!0,includeUserSSOUid:!0,includeUserTime:!0,includeUserZip:!0,method:"post",query:t,signal:l})}var v=l(79478),m=l(938),p=l(36307),f=l(91066),S=l(84473),P=function(e){return e.CATALOG="catalog",e.HOME="home",e.OTHER="",e.PDP="pdp",e}({});let y=(0,p.q6)();function T(e){let{children:t}=e,l=function(){let[e,t]=(0,a.useState)(),l=(0,r.usePathname)(),i=(0,r.useParams)(),u=(0,d.A)(),p=(0,o.J)(e=>{var t,l,i;return null!==(i=null===(l=e.userPersonalizationData)||void 0===l?void 0:null===(t=l.userLocation)||void 0===t?void 0:t.zip)&&void 0!==i?i:""}),P=(0,a.useCallback)(async e=>{if(p){let l=await s({query:e});l.isSuccess&&t(l.data)}},[p]),y=(0,a.useCallback)(async(e,l)=>{let i=await c({query:{dateOfVisit:(0,n.GP)(new Date,"yyyy-MM-dd"),itemId:e,source:l||""}});i.isSuccess&&t(i.data)},[]);return(0,a.useEffect)(()=>{let e=(0,m.j)(),t=window.location.hash.split("#").pop(),n=(0,f.Tv)(null!=l?l:"")===v.ph[v.bw.HOME],r=(null==e?void 0:e.get("itemId"))||(null==t?void 0:t.includes("itemId")),a=u===v.ph[v.bw.VEHICLE_CATALOG],o=u===v.ph[v.bw.TIRE_SIZE_CATALOG_OR_CATEGORY];if(n)P({source:"home"});else if(r)P({source:"pdp"});else if(a){let t=null==i?void 0:i.make,l=null==i?void 0:i.model,n=null==i?void 0:i.year,r=null==e?void 0:e.get("oem"),a=null==e?void 0:e.get("trim");"string"==typeof t&&"string"==typeof l&&"string"==typeof n&&"string"==typeof r&&"string"==typeof a&&P({make:(0,S.kM)(t),model:l,oem:r,source:"catalog",trim:a,year:n})}else if(o){let e=null==i?void 0:i.size;"string"==typeof e&&P({source:"catalog",size:e})}},[l,i,u,P]),{createRecentTire:y,recentlyViewedTires:e,setRecentlyViewedTires:t,fetchRecentTires:P}}();return(0,i.Y)(y.Provider,{value:l,"data-element":"unknown","data-component":"RecentlyViewedTiresProvider",children:t})}let g=(e,t)=>(0,p.i7)(y,e,t)},78370:(e,t,l)=>{l.r(t),l.d(t,{default:()=>er});var i=l(29747),n=l(96866),r=l(14232),a=l(62122),o=l(70441),d=l(78096),u=l(29215),s=l(20027);function c(){let{isLoading:e,isProductApiCalledFromClient:t,productId:l}=(0,u.i)(e=>({isLoading:e.isLoading,isProductApiCalledFromClient:e.isProductApiCalledFromClient,productId:e.productId})),i=(0,s.T2)(),n=(0,r.useCallback)(async e=>{let t=await (0,o.LA)({detailLabel:null,itemId:e,label:"",link:null,type:"paid"});t.isSuccess||d.A.error(t.error.message)},[]);return(0,r.useEffect)(()=>{t&&!1===e&&l&&i&&n(l)},[n,e,i,t,l]),null}c.displayName="AddPaidPdpParamsToPastSearchEffect";let v=(0,a.A)(c);var m=l(72480),p=l(7080),f=l(20721);function S(){let e=(0,m.n)(e=>e.isFirstLoadedPage),t=(0,s.T2)(),{deliveryDay:l,isLoading:i,isProductApiCalledFromClient:n,queryParams:r}=(0,u.i)(e=>{var t;return{deliveryDay:null===(t=e.productInfo.siteProduct.siteProductInsights)||void 0===t?void 0:t.deliveryDay,isLoading:e.isLoading,isProductApiCalledFromClient:e.isProductApiCalledFromClient,queryParams:e.queryParams}});return(0,p.A)(()=>{e&&n&&!1===i&&t&&l&&r.delivery!==l&&(0,f.CG)("delivery",l)},{isFirstLoadedPage:e,isProductApiCalledFromClient:n,isLoading:i},e=>{let{isFirstLoadedPage:t,isProductApiCalledFromClient:l,isLoading:i}=e;return t&&l&&!1===i}),null}S.displayName="AppendQueryParamEffect";let P=(0,a.A)(S);var y=l(88772),T=l(86990);function g(){let{autoScrollToInstallation:e,currentSizeIndex:t,setAutoScrollToInstallation:l,isLoading:i}=(0,u.i)(e=>({autoScrollToInstallation:e.autoScrollToInstallation,currentSizeIndex:e.currentSizeIndex,setAutoScrollToInstallation:e.setAutoScrollToInstallation,isLoading:e.isLoading})),n=(0,y.J)(e=>{var t,l;return!!(null===(l=e.userPersonalizationData)||void 0===l?void 0:null===(t=l.userLocation)||void 0===t?void 0:t.zip)});return(0,r.useEffect)(()=>{if(!i&&-1!==t&&n&&e){let e=document.querySelector("#".concat(T.Z.INSTALLATION_ANCHOR));e&&e.scrollIntoView({behavior:"smooth",block:"start",inline:"nearest"}),l(!1)}},[t,i,e,n,l]),null}g.displayName="AutoScrollToInstallationEffect";let I=(0,a.A)(g);var E=l(92418);function b(){let{currentSizeIndex:e,minQuantityAllowedForCart:t,rearSize:l,setCurrentSizeIndex:i,setQuantity:n,setShowSelectError:a,siteProductLineSizeDetailInvalid:o}=(0,u.i)(e=>({currentSizeIndex:e.currentSizeIndex,minQuantityAllowedForCart:e.minQuantityAllowedForCart,rearSize:e.queryParams.rearSize,setCurrentSizeIndex:e.setCurrentSizeIndex,setQuantity:e.setQuantity,setShowSelectError:e.setShowSelectError,siteProductLineSizeDetailInvalid:!e.productInfo.siteProduct.siteProductLineSizeDetail}));return(0,r.useEffect)(()=>{-1!=e&&n((0,E.Xv)(l,t))},[e,n,l,t]),(0,r.useEffect)(()=>{o&&-1!==e&&i(-1)},[e,i,o]),(0,r.useEffect)(()=>{e>-1&&a(!1)},[e,a]),null}b.displayName="CurrentSizeIndexEffect";let D=(0,a.A)(b);var _=l(82562);function A(){let e=(0,r.useCallback)(()=>{window.scrollTo({top:0})},[]);return(0,r.useEffect)(()=>(_.o.hashChangeComplete.on(e),()=>{_.o.hashChangeComplete.off(e)}),[e]),null}A.displayName="HashChangeAutoScrollEffect";let L=(0,a.A)(A);var h=l(96040),w=l(15501),C=l(84473),O=l(31369),R=l(4061);let N={ABANDON_SITE:"pe2624449_abandon_site"};function U(){let{prodImageUrl:e,productName:t,brandLabel:l,productSize:i,recirculation:n}=(0,u.i)(e=>{let t=e.assetList.find(e=>e.type===h.uq.SiteCatalogProductImage&&e.productImageType!==h.w7.Unavailable);return{brandLabel:e.productInfo.brand.label,prodImageUrl:(null==t?void 0:t.type)===h.uq.SiteCatalogProductImage?t.image.src:void 0,productName:e.productInfo.productName,productSize:e.productInfo.size,recirculation:e.recirculation}}),{isHubspotScriptLoaded:a,trackEvent:o}=function(){let e=(0,w.JW)(e=>e.isGTMScriptLoaded),{hubspotIdentity:t}=function(){let e=(0,y.J)(e=>{var t;return null===(t=e.userDetail)||void 0===t?void 0:t.username}),t=(0,O.A)(),l=(0,r.useMemo)(()=>(0,C.TV)("email",t)||null,[t]);return{hubspotIdentity:(0,r.useMemo)(()=>null!=e?e:l,[e,l])}}(),[l,i]=(0,r.useState)(!1),n=(0,r.useRef)(void 0),a=(0,r.useRef)(void 0),o=(0,r.useCallback)(e=>{let{name:l,properties:i}=e;n.current&&(t&&(n.current.push(["identify",{email:t,...i}]),n.current.push(["trackPageView"])),n.current.push(["trackCustomBehavioralEvent",{name:l,properties:i}]))},[t]);return(0,r.useEffect)(()=>{if(e){let e=()=>{a.current=setTimeout(()=>{let t=window._hsq;t?(n.current=t,i(!0)):e()},100)};return e(),()=>{clearTimeout(a.current)}}},[e]),{isHubspotScriptLoaded:l,trackEvent:o}}();return(0,r.useEffect)(()=>{if(a&&i){let a={},d=(0,E.Sq)(window.location.href);if(!d)return;l&&(a.pdp_browse_prod_brand=l),e&&(a.pdp_browse_prod_img=e),a.pdp_browse_prod_line=t,a.pdp_browse_prod_size=i,a.pdp_browse_prod_url=d;let u=null==n?void 0:n.find(e=>"top-picks"===e.id);if(u)for(let e=0;e{let e=J.ds.getItem(z.W[z.y.SOURCE_PLP]),t=J.ds.getItem(z.W[z.y.SOURCE_CATEGORY]),r=J.ds.getItem(z.W[z.y.SOURCE_PDP]),a=e?JSON.parse(e):void 0,o=t?JSON.parse(t):void 0,d=r?JSON.parse(r):void 0,c="Category"==l.siteProductSpecs[0].name,v=l&&c?l.siteProductSpecs[0].values.toString():"",m=l&&c?l.siteProductSpecs[1].values.toString():l.siteProductSpecs[0].values.toString();if(null==i?void 0:i.match(Y.aX[Y.bw.PRODUCT_DETAIL_PLA]))J.ds.setItem(z.W[z.y.PRODUCT_DETAILS],JSON.stringify({brand:u,brandDateTime:(0,k.GP)(new Date,s),brandSource:"PAID_PDP",brandTier:l.siteProductLine.brandTier,brandTierDateTime:(0,k.GP)(new Date,s),brandTierSource:"PAID_PDP",category:v&&v||(null==a?void 0:a.category)||(null==o?void 0:o.category)||(null==d?void 0:d.category)||"",categoryDateTime:v&&(0,k.GP)(new Date,s)||(null==a?void 0:a.dateTime)||(null==o?void 0:o.dateTime)||(null==d?void 0:d.dateTime)||"",categorySource:v&&"PAID_PDP"||(null==a?void 0:a.source)||(null==o?void 0:o.source)||(null==d?void 0:d.source)||"",subtype:m,subtypeDateTime:(0,k.GP)(new Date,s),subtypeSource:"PAID_PDP"})),J.ds.setItem(z.W[z.y.SOURCE_PAID_PDP],JSON.stringify({brand:u,brandTier:l.siteProductLine.brandTier,category:v,dateTime:(0,k.GP)(new Date,s),source:"PAID_PDP",subtype:m}));else if(n.includes("#")){let e=J.ds.getItem(z.W[z.y.SOURCE_PAID_PDP]),t=J.ds.getItem(z.W[z.y.SOURCE_PLP]),i=J.ds.getItem(z.W[z.y.SOURCE_BRAND]),n=J.ds.getItem(z.W[z.y.SOURCE_CATEGORY]),r=J.ds.getItem(z.W[z.y.SOURCE_SUBTYPE]),a=e?JSON.parse(e):void 0,o=t?JSON.parse(t):void 0,d=i?JSON.parse(i):void 0,c=n?JSON.parse(n):void 0,p=r?JSON.parse(r):void 0,f=null==a?void 0:a.category;J.ds.setItem(z.W[z.y.PRODUCT_DETAILS],JSON.stringify({brand:(null==a?void 0:a.brand)||(null==o?void 0:o.brand)||(null==d?void 0:d.brand)||u,brandDateTime:(null==a?void 0:a.dateTime)||(null==o?void 0:o.dateTime)||(null==d?void 0:d.dateTime)||(0,k.GP)(new Date,s),brandSource:(null==a?void 0:a.source)||(null==o?void 0:o.source)||(null==d?void 0:d.source)||"PDP",brandTier:(null==a?void 0:a.brandTier)||(null==o?void 0:o.brandTier)||(null==d?void 0:d.brandTier)||l.siteProductLine.brandTier,brandTierDateTime:(null==a?void 0:a.dateTime)||(null==o?void 0:o.dateTime)||(null==d?void 0:d.dateTime)||(0,k.GP)(new Date,s),brandTierSource:(null==a?void 0:a.source)||(null==o?void 0:o.source)||(null==d?void 0:d.source)||"PDP",category:(null==a?void 0:a.category)||(null==o?void 0:o.category)||(null==c?void 0:c.category)||v,categoryDateTime:f&&(null==a?void 0:a.dateTime)||(null==o?void 0:o.dateTime)||(null==c?void 0:c.dateTime)||(0,k.GP)(new Date,s),categorySource:f&&(null==a?void 0:a.source)||(null==o?void 0:o.source)||(null==c?void 0:c.source)||"PDP",subtype:(null==a?void 0:a.subtype)||(null==o?void 0:o.subtype)||(null==p?void 0:p.subtype)||m,subtypeDateTime:(null==a?void 0:a.dateTime)||(null==o?void 0:o.dateTime)||(null==p?void 0:p.dateTime)||(0,k.GP)(new Date,s),subtypeSource:(null==a?void 0:a.source)||(null==o?void 0:o.source)||(null==p?void 0:p.source)||"PDP"})),J.ds.setItem(z.W[z.y.SOURCE_PDP],JSON.stringify({brand:u,brandTier:l.siteProductLine.brandTier,category:v,dateTime:(0,k.GP)(new Date,s),source:"PDP",subtype:m}))}else{let e=J.ds.getItem(z.W[z.y.SOURCE_PAID_PDP]),t=J.ds.getItem(z.W[z.y.SOURCE_CATEGORY]),i=e?JSON.parse(e):void 0,n=t?JSON.parse(t):void 0,r=null==i?void 0:i.category;J.ds.setItem(z.W[z.y.PRODUCT_DETAILS],JSON.stringify({brand:(null==i?void 0:i.brand)||u,brandDateTime:(null==i?void 0:i.dateTime)||(0,k.GP)(new Date,s),brandSource:(null==i?void 0:i.source)||"PLP",brandTier:(null==i?void 0:i.brandTier)||l.siteProductLine.brandTier,brandTierDateTime:(null==i?void 0:i.dateTime)||(0,k.GP)(new Date,s),brandTierSource:(null==i?void 0:i.source)||"PLP",category:(null==i?void 0:i.category)||v,categoryDateTime:r&&(null==i?void 0:i.dateTime)||(0,k.GP)(new Date,s),categorySource:r&&(null==i?void 0:i.source)||(null==n?void 0:n.source)||"PLP",subtype:(null==i?void 0:i.subtype)||m,subtypeDateTime:(null==i?void 0:i.dateTime)||(0,k.GP)(new Date,s),subtypeSource:(null==i?void 0:i.source)||"PLP"})),J.ds.setItem(z.W[z.y.SOURCE_PLP],JSON.stringify({brand:u,brandTier:l.siteProductLine.brandTier,category:v,dateTime:(0,k.GP)(new Date,s),source:"PLP",subtype:m}))}},[n,u,i,l]),null}q.displayName="LocalStorageDataEffect";let M=(0,a.A)(q);var V=l(72219);function F(){let e=(0,V.a)(e=>e.addPastSearch),t=(0,s.T2)(),{brandURL:l,brandLabel:i,category:n}=(0,u.i)(e=>{var t,l,i,n,r,a;return{brandURL:e.productInfo.brandURL,brandLabel:e.productInfo.brand.label,category:null!==(a=null===(i=(null!==(r=null===(n=e.technicalSpecs)||void 0===n?void 0:n.specs)&&void 0!==r?r:[]).filter(e=>"Category"===e.label))||void 0===i?void 0:null===(l=i[0])||void 0===l?void 0:null===(t=l.value)||void 0===t?void 0:t[0])&&void 0!==a?a:null}});return(0,r.useEffect)(()=>{if(t&&(e({action:{link:{href:l,isExternal:!1},type:"SiteSearchResultActionLink"},detailLabel:null,label:null!=i?i:null,labelSegments:[],type:"SiteSearchResultTextItem",typeName:"brand"}),n)){let t=(0,C.Yv)(n);e({action:{link:{href:"categories/".concat(t),isExternal:!1},type:"SiteSearchResultActionLink"},detailLabel:null,label:null!=n?n:null,labelSegments:[],type:"SiteSearchResultTextItem",typeName:"category"})}},[e,n,t,i,l]),null}F.displayName="PastSearchEffect";let x=(0,a.A)(F);var H=l(66541);function B(){let e=(0,H.tf)(e=>e.createRecentTire),t=(0,u.i)(e=>e.productId);return(0,r.useEffect)(()=>{t&&e(t,H.u2.PDP)},[e,t]),null}B.displayName="RecentTireEffect";let Q=(0,a.A)(B);function Z(){let e=e=>{let{persisted:t}=e;t&&window.location.reload()};return(0,r.useEffect)(()=>(window.addEventListener("pageshow",e),()=>{window.removeEventListener("pageshow",e)}),[]),null}Z.displayName="ReloadPageIfPersistedEffect";let j=(0,a.A)(Z);function K(){let e=(0,G.usePathname)(),t=(0,G.useSearchParams)(),l=(0,s.T2)();return(0,p.A)(()=>{let t=window.location.search.split("?").pop();window.history.replaceState(null,"","".concat(e,"#").concat(t))},{isPLA:l,searchParams:t},e=>{let{isPLA:t,searchParams:l}=e;return!t&&!!l&&l.toString().length>0}),null}K.displayName="RerouteQueryParametersToHashEffect";let X=(0,a.A)(K);var $=l(55005),ee=l(45882);function et(){let{category:e,prodImageUrl:t,productName:l,brandLabel:i,productSize:n,productId:a,startingPrice:o,hasVideo:d}=(0,u.i)(e=>{var t,l,i,n,r,a;let o=e.assetList.find(e=>e.type===h.uq.SiteCatalogProductImage&&e.productImageType!==h.w7.Unavailable),d=e.assetList.find(e=>e.type===h.L0.SiteYouTubeVideo);return{brandLabel:e.productInfo.brand.label,category:null!==(a=null===(i=(null!==(r=null===(n=e.technicalSpecs)||void 0===n?void 0:n.specs)&&void 0!==r?r:[]).filter(e=>"Category"===e.label))||void 0===i?void 0:null===(l=i[0])||void 0===l?void 0:null===(t=l.value)||void 0===t?void 0:t[0])&&void 0!==a?a:null,hasVideo:d,prodImageUrl:(null==o?void 0:o.type)===h.uq.SiteCatalogProductImage?o.image.src:void 0,productId:e.productId,productName:e.productInfo.productName,productSize:e.productInfo.size,startingPrice:e.productInfo.startingPrice}}),s=(0,r.useRef)(!1),c=(0,r.useCallback)((r,u)=>{(0,$.uj)(u,{brand:null!=i?i:"",category:null!=e?e:"",currency:"USD",has_video:d?"yes":"no",image_url:null!=t?t:"",name:null!=l?l:"",price:null!=o?o:"",product_id:a,quantity:4,sku:null!=r?r:"",url:r||"",variant:null!=n?n:""})},[i,e,d,t,l,o,a,n]);return(0,r.useEffect)(()=>{let n=(0,E.Sq)(window.location.href);if(a&&!s.current){if(!n)return;s.current=!0,c(n,ee.B.PRODUCT_VIEWED),window.VWO=window.VWO||[],window.VWO.event=window.VWO.event||function(){window.VWO.push(["event"].concat([].slice.call(arguments)))},window.VWO.event("rudder.PRODUCT_VIEWED",{brand:i,category:e,currency:"USD",has_video:d?"yes":"no",image_url:null!=t?t:"",name:null!=l?l:"",price:null!=o?o:"",product_id:a,quantity:4,sku:null!=n?n:""})}let r=()=>c(null!=n?n:window.location.href,ee.B.VIDEO_CLICKED);return _.o.videoEvent.on(r),()=>{_.o.videoEvent.off(r)}},[i,e,d,t,a,l,o,c]),null}et.displayName="RudderstackEffect";let el=(0,a.A)(et);function ei(){let e=(0,O.A)();return(0,r.useEffect)(()=>{J.ds.setItem(z.W[z.y.LAST_PDP_PATH],JSON.stringify(e))},[e]),null}ei.displayName="SetLastPdpPathEffect";let en=(0,a.A)(ei),er=function(e){let{serverData:t}=e;return(0,i.FD)(i.FK,{children:[(0,i.Y)(M,{siteProduct:t.siteProduct,"data-element":"LocalStorageDataEffect"}),(0,i.Y)(n.F,{"data-element":"WidgetAppConfigEffect"}),(0,i.Y)(L,{"data-element":"HashChangeAutoScrollEffect"}),(0,i.Y)(en,{"data-element":"SetLastPdpPathEffect"}),(0,i.Y)(j,{"data-element":"ReloadPageIfPersistedEffect"}),(0,i.Y)(Q,{"data-element":"RecentTireEffect"}),(0,i.Y)(x,{"data-element":"PastSearchEffect"}),(0,i.Y)(W,{"data-element":"HubspotEffect"}),(0,i.Y)(el,{"data-element":"RudderstackEffect"}),(0,i.Y)(I,{"data-element":"AutoScrollToInstallationEffect"}),(0,i.Y)(D,{"data-element":"CurrentSizeIndexEffect"}),(0,i.Y)(v,{"data-element":"AddPaidPdpParamsToPastSearchEffect"}),(0,i.Y)(P,{"data-element":"AppendQueryParamEffect"}),(0,i.Y)(X,{"data-element":"RerouteQueryParametersToHashEffect"})]})}},96866:(e,t,l)=>{l.d(t,{F:()=>m});var i=l(37393),n=l(14232),r=l(1613),a=l(84859),o=l(88772),d=l(75482),u=l(53303),s=l(3297),c=l(32384),v=l(30903);function m(){let{isSimpleShop:e}=(0,a._)(e=>({isSimpleShop:Number(e.isSimpleShop)})),t=(0,o.J)(e=>e.updateLocation),l=(0,n.useCallback)(async()=>{let l=await (0,d.s)({query:{identifier:"simpleshop",subDomain:(0,v.tm)()?window.location.origin:"https://steer-simpleshop-opt-2482-alt-simpletire.vercel.app"}});if(l.isSuccess){var n,a,o,m,p,f;let d=l.data.orderSubSourceId,v=null===(n=l.data)||void 0===n?void 0:n.zip;v&&t({userLocationZip:v});let S=null===(a=l.data)||void 0===a?void 0:a.installerId,P=null===(o=l.data)||void 0===o?void 0:o.isMobileInstaller,y=null===(m=l.data)||void 0===m?void 0:m.id.toString(),T=null===(p=l.data)||void 0===p?void 0:p.name,g=null===(f=l.data)||void 0===f?void 0:f.orderSubSourceId.toString();!c._v.getItem(s.v.INSTALLER_IDS)&&S&&c._v.setItem(s.v.INSTALLER_IDS,S),!c._v.getItem(s.v.IS_MOBILE_INSTALL)&&P&&c._v.setItem(s.v.IS_MOBILE_INSTALL,P+""),!c._v.getItem(s.v.WIDGET_SOURCE_ID)&&y&&c._v.setItem(s.v.WIDGET_SOURCE_ID,y),!c._v.getItem(s.v.SUB_SOURCE)&&g&&c._v.setItem(s.v.SUB_SOURCE,String(d)),e&&(0,i.TV)(null,u.A.SIMPLE_SHOP_ID,T,r.v)}},[e,t]);return(0,n.useEffect)(()=>{e&&l()},[e,l]),null}}}]);