PageSourceSearch

https://secondwave.fahertybrand.com/_next/static/chunks/2383.07fb6f495eba55d7.js

js fahertybrand.com collected 2026-09-24 17:23:34 UTC 9,079 bytes, 6 lines download raw bytes

1
2!function(){try{var e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{},n=(new e.Error).stack;n&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[n]="5a219fa0-4828-53b8-947f-48262acfe8b5")}catch(e){}}();
3!function(){try{var e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{};e._posthogReleaseId=e._posthogReleaseId||"01a0d435-3096-0000-87c3-aca2d31ea39c";var n=(new e.Error).stack;n&&(e._posthogChunkIds=e._posthogChunkIds||{},e._posthogChunkIds[n]="e1158deb-d8cc-54e2-a78a-6cffbcb4d072")}catch(e){}}();"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[2383],{19341:(e,t,n)=>{n.d(t,{A:()=>s});var r=n(40897),i=n(71869);function s(){let e=(0,r.Wg)();return(0,i.A)("marketplace-sku-inventory-enabled",e)}},19432:(e,t,n)=>{n.d(t,{A:()=>f});var r=n(5776),i=n(80820),s=n(40897),o=n(57833),l=n(33568),a=n(68339),u=n(12932),d=n(43098),c=n(19341);function f(e,t,n,f){let p=(0,s.Wg)(),y=(0,c.A)(),{variantSortOrderMap:v}=(0,u.A)(),g=!y||0===e.length||0===n.length,{data:h,loading:m}=(0,o.qQz)({variables:{input:{brandId:p,itemIds:e,type:t,variantTypes:n}},skip:g}),k=(0,r.useMemo)(()=>Object.keys(f).length>0?{selectedVariants:(0,l.MX)(f)}:void 0,[f]),{data:b,loading:_}=(0,o.MEJ)({variables:{input:{brandId:p,itemIds:e,type:t,variantTypes:n,filters:k}},skip:g||!k}),A=(0,r.useMemo)(()=>h?.getMarketplaceSkuInventory.skus??[],[h]),j=(0,r.useMemo)(()=>b?.getMarketplaceListings.listingIds??[],[b]),{data:O,loading:w}=(0,o.iP6)({variables:{listingIds:j},skip:!y||j.length<1}),E=(0,a.ZC)(O,!O),S=(0,r.useMemo)(()=>(O??E)?.listings,[O,E]),L=(0,r.useMemo)(()=>{if(0===j.length)return!0;let e=new Set((O?.listings??[]).map(e=>e.id));return j.every(t=>e.has(t))},[O,j]),I=y&&(m||_||w||!g&&(0,i.d6)(k)&&(0,i.uy)(b)||j.length>0&&!L),M=(0,r.useMemo)(()=>{if(y&&0!==A.length)return Object.fromEntries(Object.entries((0,d.fQ)(A)).map(e=>{let[t,n]=e;return[t,(0,l.Ww)(n,v[t])]}))},[y,A,v]),C=(0,r.useMemo)(()=>{if(y&&0!==A.length)return Object.fromEntries(Object.entries((0,d.YK)(A,f)).map(e=>{let[t,n]=e;return[t,(0,l.Ww)(n,v[t])]}))},[y,A,f,v]);return{skuInventory:A,listingIds:j,listings:S,inventoryLoading:m,listingsLoading:_,listingsResolving:I,inventoryAvailableOptions:M,inventorySelectableOptions:C}}},33155:(e,t,n)=>{function r(e,t){return t.includes(e)?[e,...t.filter(t=>t!==e)]:t}function i(e,t){return[...e,...t.filter(t=>!e.includes(t))]}n.d(t,{a:()=>r,i:()=>i})},43098:(e,t,n)=>{n.d(t,{CR:()=>a,Fb:()=>c,Ij:()=>d,YK:()=>o,fQ:()=>s,oS:()=>l});var r=n(80820),i=n(33155);function s(e){let t={};for(let n of e)for(let e of n.variants){let n=t[e.type]??new Map;t[e.type]=n,n.has(e.id)||n.set(e.id,{id:e.id,option:e.option,content:[{display:e.display}],variant_type:{type:e.type}})}return Object.fromEntries(Object.entries(t).map(e=>{let[t,n]=e;return[t,Array.from(n.values())]}))}function o(e,t){let n={};for(let r of e)for(let e of r.variants)if(r.variants.filter(t=>t.type!==e.type).every(e=>{let n=t[e.type];return!n||n.id===e.id})){let t=n[e.type]??new Map;n[e.type]=t,t.has(e.id)||t.set(e.id,{id:e.id,option:e.option})}return Object.fromEntries(Object.entries(n).map(e=>{let[t,n]=e;return[t,Array.from(n.values())]}))}function l(e,t){return e.filter(e=>Object.entries(t).every(t=>{let[n,i]=t;return(0,r.uy)(i)||e.variants.some(e=>e.type===n&&e.id===i.id)}))}function a(e,t){return l(e,t).length>0}function u(e,t,n){let i=n=>e.some(e=>n.every(n=>e.variants.some(e=>e.type===n&&e.id===t[n]?.id))),s=n.filter(e=>(0,r.d6)(t[e]));for(;s.length>0&&!i(s);)s=s.slice(0,-1);return s}function d(e,t,n){if(0===e.length)return t;let i=u(e,t,n),s=e.find(e=>i.every(n=>e.variants.some(e=>e.type===n&&e.id===t[n]?.id)))??e[0];if((0,r.uy)(s))return t;let o={};for(let e of s.variants)o[e.type]={id:e.id,option:e.option};return o}function c(e,t,n,s,o){if(!e.some(e=>e.variants.some(e=>e.type===t&&e.id===n.id)))return s;let l={...s,[t]:n},a=u(e,l,(0,i.i)([t],o)),d=e.find(e=>a.every(t=>e.variants.some(e=>e.type===t&&e.id===l[t]?.id)))??e[0];if((0,r.uy)(d))return s;let c={};for(let e of d.variants)c[e.type]={id:e.id,option:e.option};return c}},77740:(e,t,n)=>{n.d(t,{A:()=>f});var r=n(5776),i=n(43032),s=n(80820),o=n(953),l=n(33568),a=n(12932),u=n(33155);function d(e,t,n){return t.reduce((e,t)=>
3{if((0,s.uy)(e[t])){let r=n(t,e);r&&(e[t]=(0,l.kO)(r))}return e},{...e})}function c(e,t){return t.reduce((t,n)=>{let r=e[n];return(0,s.d6)(r)&&(t[n]=r),t},{})}function f(){let{variantSortOrderMap:e}=(0,a.A)(),t=(0,i.d4)(e=>e.listing.selectedListingId);return(0,r.useCallback)(function(){let n=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],r=arguments.length>1?arguments[1]:void 0,i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},a=arguments.length>3&&void 0!==arguments[3]?arguments[3]:[];if(0===n.length||(0,s.d6)(i)&&r.every(e=>(0,s.d6)(i[e]))&&(0,o.uE)(n,i).length>0)return i;let f=n.find(e=>e.id===t);if(f&&Object.entries(i).every(e=>{let[t,n]=e,r=(0,l.ZH)(t,f.sku);return n?.id===r?.id||n?.option===r?.option}))return d(i,r,(t,r)=>{let i=(0,o.uE)(n,r);return(i.some(e=>e.id===f.id)?(0,l.ZH)(t,f.sku):void 0)??(0,o.$c)(t,i,e[t])[0]});let p=(0,u.i)(a,r).filter(e=>(0,s.d6)(i[e]));for(;p.length>0&&0===(0,o.uE)(n,c(i,p)).length;)p=p.slice(0,-1);return d(c(i,p),r,(t,r)=>(0,o.$c)(t,(0,o.uE)(n,r),e[t])[0])},[t,e])}},87750:(e,t,n)=>{n.d(t,{g:()=>u});var r=n(13812),i=n.n(r),s=n(5776),o=n(80820),l=n(57833),a=n(11833);function u(e){let{listingId:t,brandId:n,brandSlug:r,ready:u,pageKey:d}=e,[c]=(0,l.Hfy)({ignoreResults:!0}),f=(0,s.useRef)(new Set),p=(0,s.useMemo)(()=>i()((e,t)=>{f.current.has(e)||(f.current.add(e),c({variables:{input:{brand_id:t,listing_id:e,aaid:(0,a.H)()}}}).catch(()=>{}))},1e3),[c]);(0,s.useEffect)(()=>(f.current=new Set,()=>{p.flush()}),[d,p]),(0,s.useEffect)(()=>{if(u&&(0,o.uI)(t)&&(0,o.uI)(n)&&(0,o.uI)(r))return p(t,n),()=>{p.cancel()}},[u,t,n,r,p])}},89695:(e,t,n)=>{n.d(t,{Rt:()=>a,hZ:()=>u,o9:()=>l,sY:()=>d});var r=n(80820),i=n(953),s=n(33568),o=n(43098);function l(e,t){var n=(0,i.uE)(e,t);let o=new Set;for(let e of n){for(let t of e.sku?.sku_variant_type_options??[]){let e=t.variant_type_option?.variant_type?.type;(0,r.d6)(e)&&o.add(e.toLowerCase())}(0,r.d6)((0,s.ZH)(s.DB.Size,e.sku))&&o.add(s.DB.Size)}return o}function a(e,t){var n=(0,o.oS)(e,t);let r=new Set;for(let e of n)for(let t of e.variants)r.add(t.type.toLowerCase());return r}function u(e,t,n){return e.filter(e=>(0,r.uy)(t[e])&&n.has(e.toLowerCase()))}function d(e,t,n){return e.some(e=>(0,r.uy)(t[e])&&n.has(e.toLowerCase()))}},93773:(e,t,n)=>{n.d(t,{A:()=>p});var r=n(64476),i=n(60975),s=n(80805),o=n.n(s),l=n(99328),a=n(40897),u=n(953),d=n(98400),c=n(76084),f=n(12932);let p=e=>{let{product:t,listing:n,productStyle:s}=e,{domain:p,currency:y}=(0,a.qQ)(),{brandName:v}=(0,a.Gh)(),{pathname:g}=(0,l.zy)(),h=(0,d.Si)(t),{itemConditionForScore:m,productJsonLdBrandFromAttribute:k}=(0,f.A)();if(!h)return null;let b=k?((0,d.Ud)(i.jQ.BRAND,t)??(0,d.ZA)(i.jQ.BRAND,s))?.attribute_type_option:void 0,_=b?.content?.at(0)?.display??b?.option??v,{primaryImage:A}=(0,d.fD)(t),j=t.content?.at(0)?.description,O=t.style?.product_style??void 0,w="development"===c.A.ENV?"http://":"https://",E=`${w}${"development"===c.A.ENV?"localhost:3000":p}`,S=`${E}${g}`,L=!!n&&(0,u.A_)(n),I={"@context":"https://schema.org","@type":"Product",name:h,brand:_};if(A?.src&&(I.image=A.src),j&&(I.description=j),O&&(I.sku=O),n?.price){let e={"@type":"Offer",price:(n.price/100).toFixed(2),priceCurrency:y.toUpperCase(),availability:L?"https://schema.org/InStock":"https://schema.org/OutOfStock",url:S},t=m(n.condition_score);t&&(e.itemCondition=`https://schema.org/${t}`),I.offers=e}return(0,r.jsx)(o(),{"data-sentry-element":"Head","data-sentry-component":"ProductJsonLd","data-sentry-source-file":"ProductJsonLd.tsx",children:(0,r.jsx)("script",{type:"application/ld+json",dangerouslySetInnerHTML:{__html:JSON.stringify(I)}},"product-jsonld")})}},94164:(e,t,n)=>{n.d(t,{A:()=>f});var r=n(5776),i=n(43032),s=n(99328),o=n(43569),l=n(80820),a=n(57833),u=n(33568),d=n(91134),c=n(12932);let f=function(){let e=(0,i.wA)(),[t,n]=(0,s.ok)(),{selectableSkuVariants:f,skuColorVariantTypeName:p,enrichListing:y}=(0,c.A)(),v=t.get("selectedListingId"),g=(0,i.d4)(e=>e.listing.selectedListingId),{data:h,loading:m}=(0,a.tIt)({variables:{listingId:v},skip:(0,l.uy)(v)}),k=h?.listings[0]?y(h.listings[0]):void 0;return(0,r.useEffect)(()=>
3{if((0,l.uy)(v)||m||g===v)return;let r=new URLSearchParams(t);if(r.delete("selectedListingId"),k?.status===a.KXL.Listed){let t=(0,u.P3)((0,u.kr)(k.sku),f.concat(p));(0,l.uI)(t)&&r.set("selectedVariants",t),e((0,o.y)([(0,d.Z2)(0),(0,d.n2)(k.sku?.size??void 0),(0,d.DO)(v),(0,d.tl)(k.condition_score)].filter(l.d6)))}else e((0,d.DO)(v));n(r,{replace:!0})},[e,k,v,m,t,n,g,f,p]),{resolvingSelectedListing:(0,l.d6)(v)}}}}]);
4//# sourceMappingURL=2383.07fb6f495eba55d7.js.map
5//# chunkId=e1158deb-d8cc-54e2-a78a-6cffbcb4d072
6//# debugId=5a219fa0-4828-53b8-947f-48262acfe8b5

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.