PageSourceSearch

https://www.24hshop.dk/static/js/PackageProduct-PackageProduct.02491ae1.chunk.js

js 24hshop.dk collected 2026-10-04 05:52:53 UTC 23,561 bytes, 1 lines download raw bytes

1(self.__LOADABLE_LOADED_CHUNKS__=self.__LOADABLE_LOADED_CHUNKS__||[]).push([[494],{"3vSh":(e,n,i)=>{"use strict";i.r(n),i.d(n,{PackageProduct:()=>H,default:()=>W});var a=i("Lxrg"),t=i("5sAQ"),r=i("VoNp"),c=i("knst"),d=i("fl6W"),l=i("vheF"),s=i("3iM4"),o=i("/LlE"),u=i("VaYU"),m=i.n(u);function v(e){return e.product.hasVariants}function k(e){return!e.product.stockStatus.buyable}const g=(0,l.u)({id:"package",initial:"loading",context:{packageProduct:null,items:{},price:{},error:null},on:{UPDATE_ITEM:{actions:"updateItems",target:"validating",cond:e=>Object.keys(e.items).length>0}},states:{loading:{always:[{target:"validating",actions:(0,s.assign)({items:e=>p(e.packageProduct).items,price:e=>p(e.packageProduct).price}),cond:e=>!!e.packageProduct.package}],on:{LOADED:{target:"validating",actions:(0,s.assign)({items:(e,n)=>p(n.packageProduct).items,price:(e,n)=>p(n.packageProduct).price,packageProduct:(e,n)=>n.packageProduct})}}},invalid:{},validating:{always:[{target:"valid",cond:e=>"valid"===f(e.items)},{target:"invalid",cond:e=>"valid"!==f(e.items)}]},valid:{initial:"fetchingPrice",states:{fetchingPrice:{invoke:{id:"fetchPrice",src:"fetchPrice",onDone:{target:"buyable",actions:(0,s.assign)({price:(e,n)=>n.data})},onError:{target:"error",actions:(0,s.assign)({error:(e,n)=>({fromState:"fetchingPrice",messages:n.data.map((e=>e.message)).filter(Boolean)})})}}},buyable:{on:{ADD_TO_CART:"adding",ERROR:"error"}},adding:{invoke:{id:"add-to-cart",src:"addToCart",onDone:"added",onError:{target:"error",actions:(0,s.assign)({error:(e,n)=>({fromState:"adding",messages:n.data.map((e=>e.message)).filter(Boolean)})})}}},added:{invoke:{id:"added-refetch",src:()=>new Promise((e=>{setTimeout((()=>{e(400)}),800)})),onDone:{target:"#package.validating"}}},error:{on:{RETRY:"#package.validating"}}}}}},{actions:{updateItems:(0,s.assign)({items:(e,n)=>{if("UPDATE_ITEM"===n.type){const i=e.items[n.articleNumber];if(!i)throw new Error("article does not exist in package");if(n.variantArticleNumber){if(!i.variants.includes(n.variantArticleNumber))throw new Error("variant does not exist on article")}const{articleNumber:a,valid:t,variantArticleNumber:r}=n;return(0,c.jM)(e.items,(e=>{e[a]=Object.assign(Object.assign({},e[a]),{valid:t,variantArticleNumber:r})}))}}})}});function p(e){var n,i;return{items:null===(i=null===(n=null===e||void 0===e?void 0:e.package)||void 0===n?void 0:n.items)||void 0===i?void 0:i.reduce(((e,n)=>{var i;return e[n.product.articleNumber]={product:n.product,articleNumber:n.product.articleNumber,hasVariants:n.product.hasVariants,variantArticleNumber:null,variants:n.product.hasVariants?null===(i=n.product.variants)||void 0===i?void 0:i.values.map((e=>e.articleNumber)):null,valid:!v(n)&&!k(n),quantity:n.minQuantity},e}),{}),price:e.package}}function f(e){return Object.values(e).every((e=>e.valid))?"valid":"invalid"}function N(e){let{product:n,packageProductQuery:i,priceQuery:c}=e;const l=(0,d.useRef)(!1);(0,d.useEffect)((()=>{l.current=!0}),[]);const s=(0,t.m)(),{data:u}=(0,r.IT)(i,{variables:{articleNumber:n.articleNumber}}),[v,k]=(0,a.useMachine)(g,{context:{packageProduct:(null===u||void 0===u?void 0:u.product)||n},services:{fetchPrice:e=>{return i=n.articleNumber,a=e.items,(t={apolloClient:s,query:c}).apolloClient.query({query:t.query||m(),variables:{articleNumber:i,products:Object.entries(a).map((e=>{const{articleNumber:n,variantArticleNumber:i}=e[1];return{product:n,variant:i}}))}}).then((e=>{let{data:n}=e;return n.product.package}),(e=>Promise.reject(e.graphQLErrors)));var i,a,t},addToCart:(e,n)=>p(n.queries).then((e=>e.errors?Promise.reject(e.errors):e))}});(0,d.useEffect)((()=>{"loading"===v.value&&(null===u||void 0===u?void 0:u.product)&&k({type:"LOADED",packageProduct:u.product})}),[v.value,u,k]);const[p]=(0,o.g)((f=v.context.items,Object.entries(f).map((e=>{const{articleNumber:n,variantArticleNumber:i,quantity:a,product:t}=e[1];return Object.assign(Object.assign({},t),{articleNumber:i||n,quantity:a})}))));var f;const N=(0,d.useCallback)((function(e,n,i){k({type:"UPDATE_ITEM",articleNumber:e,variantArticleNumber:n,valid:i})}),[k]),S=(0,d.useMemo)((()=>{switch(!0){case v.matches({valid:"fetchingPrice"}):return"fetching_price";case v.matches({valid:"buyable"}):return"buyable";case v.matches({valid:"adding"}):return"adding";case v.matches({valid:"added"}):return"added";case v.matches({valid:"error"}):return"error";
1case v.matches("loading"):return"loading";default:return"invalid"}}),[v]),P=(0,d.useCallback)((function(){"error"===S&&k({type:"RETRY"})}),[k,S]);return{status:S,price:v.context.price,addPackageToCart:e=>{k({type:"ADD_TO_CART",queries:e})},updatePackageItem:N,packageProduct:v.context.packageProduct,error:v.context.error,retry:P}}var S=i("pObW"),P=i("QjhG");var b=i("bZ+K"),h=i("PR7K"),E=i("zN6b"),y=i("6nVI"),F=i.n(y),D=i("e/Ig"),V=i.n(D),w=i("7Wde"),T=i("3EPy"),A=i("+9dH"),O=i("9rT2"),q=i("ErDE"),x=i("ModV"),_=i("53ix"),C=i("MdNv");i("awTl");const I=(0,E.I)("div")({name:"PackageProductItemWrapper",class:"p17cadpd"});function Q(e){var n;let{item:i,updatePackageItem:a,validationEnabled:t,price:r,fetchingPrice:c}=e;const{stockStatus:l,variantHandler:s}=function(e,n){let{preselectCheapest:i}=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};var a;const{product:t}=e,r=(0,S.b)(t,{preselectCheapest:i}),c=r.validation,l=null===(a=r.selectedVariant)||void 0===a?void 0:a.articleNumber,s=(0,P.K)(r.selectedVariant||t);return(0,d.useEffect)((()=>{n(t.articleNumber,l,"valid"===c)}),[t.articleNumber,l,n,r.selectedVariant,c]),{stockStatus:s,variantHandler:r}}(i,a,{preselectCheapest:!0}),o=i.product,{selectedVariant:u}=s,m=u||1===(null===(n=s.missingOptions)||void 0===n?void 0:n.length)&&s.getVariantForSelection(s.missingOptions[0].values[0],s.missingOptions[0]),v=m&&m.images.length?m.images[0]:(null===o||void 0===o?void 0:o.images.length)&&o.images[0];return d.createElement(I,null,d.createElement(x.A,{product:o,className:"product-link"},d.createElement(O.A,{sizes:[100,200,200,300],aspect:"1:1",alt:v.alt,src:v.url})),d.createElement("div",{className:"product-detail"},d.createElement("header",null,d.createElement("h4",null,d.createElement(x.A,{product:o,className:"product-name"},o.name)),d.createElement("p",null,o.subName)),o.hasVariants&&d.createElement(C.l,{product:o,packageProduct:!0,variantHandler:s,showValidation:t,disableOutOfStock:!0}),d.createElement("div",{className:"flex"},d.createElement(_.Ay,{status:l.status,text:l.text,style:{marginTop:0}}),d.createElement("div",{className:"price-quantity-wrapper",style:{opacity:c?.3:1}},i.minQuantity>1&&"".concat(i.minQuantity," x"),d.createElement(q.g,(0,A.A)({},r,{className:"package-product-price"}))))))}i("BcEV");var R=i("w18P"),L=i.n(R),j=i("Jhkc");const M=(0,E.I)("div")({name:"PackageProductWrapper",class:"p8hbe94"}),z="tl48ky4";function U(e){let{productName:n}=e;const i=(0,b.tz)();return d.createElement("div",{className:z},d.createElement(w.h,null),d.createElement("span",null,i("{productName} has been added to the cart",{productName:n})))}function H(e){let{product:n}=e;const i=(0,d.useRef)(null),{addPackageToCart:a,status:t,price:r,error:c,retry:l,updatePackageItem:s,packageProduct:o}=N({product:n,packageProductQuery:L()}),[u,m]=d.useReducer((()=>!0),!1),v=(0,b.tz)(),k="buyable"===t;const[g]=(0,j.hN)();return(0,d.useEffect)((()=>{"added"===t&&g(d.createElement(U,{productName:n.name}))}),[g,n.name,t]),"loading"===t?d.createElement(B,null):d.createElement(M,{ref:i},d.createElement("div",{className:"package-product-items-wrapper"},o.package.items.map(((e,n)=>d.createElement(Q,{item:e,key:e.product.id,updatePackageItem:s,validationEnabled:u,price:r.items[n],fetchingPrice:"fetching_price"===t})))),d.createElement($,{data:r,fetching:"fetching_price"===t}),d.createElement(T.Ay,{className:"package-product-add-to-cart","data-testid":"package-product-add-to-cart",disabled:u&&!k,loading:"fetching_price"===t,loadingText:v("Updating price... "),onClick:k?function(){a({addMultipleToCartMutation:F(),cartQuery:V()})}:()=>{m(),window.scrollTo({top:i.current.offsetTop,behavior:"smooth"})}},v("added"===t?"Successfully added!":"invalid"===t&&u?"Select the variants":"Add to cart")),"error"===t&&d.createElement(K,{error:c,retry:l}))}function B(){const e=(0,b.tz)();return d.createElement(M,null,e("Loading package details..."))}function $(e){let{data:n,fetching:i}=e;const a=(0,b.tz)();return d.createElement("div",{className:"package-product-price-wrapper",style:{opacity:i?.3:1}},d.createElement("div",{className:"discount"},d.createElement("p",{className:"package-price-label"},a("Package Discount")),d.createElement(h.g,{negative:!0,price:n.discountValue,className:"package-price"})),d.createElement("div",{className:"total"},d.createElement("p",{className:"package-price-label"},a("Total")),d.createElement(h.g,{"data-testid":"package-price-total",price:n.price,className:"package-price"})))}function K(e){let{error:n,retry:i}=e;const a=(0,b.tz)();return d.createElement("div",{className:"error"},d.createElement("label",null,a("Something went wrong when { placeholder }
1",{placeholder:"fetchingPrice"===n.fromState?" fetching price. This item cannot be added to the cart at this time":" adding to cart"}),"."),n.messages.map((e=>d.createElement("div",null,e))),d.createElement(T.Ay,{onClick:i},a("Retry")))}const W=H;i("X5Hq")},VaYU:(e,n,i)=>{var a={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"query",name:{kind:"Name",value:"PackageValidation"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"articleNumber"}},type:{kind:"NamedType",name:{kind:"Name",value:"String"}},directives:[]},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"products"}},type:{kind:"ListType",type:{kind:"NamedType",name:{kind:"Name",value:"PackagePriceInput"}}},directives:[]}],directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"product"},arguments:[{kind:"Argument",name:{kind:"Name",value:"articleNumber"},value:{kind:"Variable",name:{kind:"Name",value:"articleNumber"}}}],directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"id"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"package"},arguments:[{kind:"Argument",name:{kind:"Name",value:"articleNumbers"},value:{kind:"Variable",name:{kind:"Name",value:"products"}}}],directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"price"},arguments:[],directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"FragmentSpread",name:{kind:"Name",value:"Price"},directives:[]}]}},{kind:"Field",name:{kind:"Name",value:"discountValue"},arguments:[],directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"FragmentSpread",name:{kind:"Name",value:"Price"},directives:[]}]}},{kind:"Field",name:{kind:"Name",value:"items"},arguments:[],directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"product"},arguments:[],directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"articleNumber"},arguments:[],directives:[]}]}},{kind:"Field",name:{kind:"Name",value:"price"},arguments:[],directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"FragmentSpread",name:{kind:"Name",value:"Price"},directives:[]}]}},{kind:"Field",name:{kind:"Name",value:"previousPrice"},arguments:[],directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"FragmentSpread",name:{kind:"Name",value:"Price"},directives:[]}]}}]}}]}}]}}]}}],loc:{start:0,end:498}};a.loc.source={body:'#import "../../data/fragments/PriceFragment.gql"\n\nquery PackageValidation(\n  $articleNumber: String\n  $products: [PackagePriceInput]\n) {\n  product(articleNumber: $articleNumber) {\n    id\n    package(articleNumbers: $products) {\n      price {\n        ...Price\n      }\n      discountValue {\n        ...Price\n      }\n      items {\n        product {\n          articleNumber\n        }\n        price {\n          ...Price\n        }\n        previousPrice {\n          ...Price\n        }\n      }\n    }\n  }\n}\n',name:"GraphQL request",locationOffset:{line:1,column:1}};var t={};function r(e,n){if("FragmentSpread"===e.kind)n.add(e.name.value);else if("VariableDefinition"===e.kind){var i=e.type;"NamedType"===i.kind&&n.add(i.name.value)}e.selectionSet&&e.selectionSet.selections.forEach((function(e){r(e,n)})),e.variableDefinitions&&e.variableDefinitions.forEach((function(e){r(e,n)})),e.definitions&&e.definitions.forEach((function(e){r(e,n)}))}a.definitions=a.definitions.concat(i("2D1U").definitions.filter((function(e){if("FragmentDefinition"!==e.kind)return!0;var n=e.name.value;return!t[n]&&(t[n]=!0,!0)})));var c={};function d(e,n){for(var i=0;i<e.definitions.length;i++){var a=e.definitions[i];if(a.name&&a.name.value==n)return a}}a.definitions.forEach((function(e){if(e.name){var n=new Set;r(e,n),c[e.name.value]=n}})),e.exports=a,e.exports.PackageValidation=function(e,n){var i={kind:e.kind,definitions:[d(e,n)]};e.hasOwnProperty("loc")&&(i.loc=e.loc);var a=c[n]||new Set,t=new Set,r=new Set;
1for(a.forEach((function(e){r.add(e)}));r.size>0;){var l=r;r=new Set,l.forEach((function(e){t.has(e)||(t.add(e),(c[e]||new Set).forEach((function(e){r.add(e)})))}))}return t.forEach((function(n){var a=d(e,n);a&&i.definitions.push(a)})),i}(a,"PackageValidation")},P2ma:(e,n,i)=>{var a={kind:"Document",definitions:[{kind:"FragmentDefinition",name:{kind:"Name",value:"PackageProductFragment"},typeCondition:{kind:"NamedType",name:{kind:"Name",value:"Product"}},directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"isPackage"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"package"},arguments:[],directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"price"},arguments:[],directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"FragmentSpread",name:{kind:"Name",value:"Price"},directives:[]}]}},{kind:"Field",name:{kind:"Name",value:"discountValue"},arguments:[],directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"FragmentSpread",name:{kind:"Name",value:"Price"},directives:[]}]}},{kind:"Field",name:{kind:"Name",value:"items"},arguments:[],directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"product"},arguments:[],directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"id"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"name"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"articleNumber"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"hasVariants"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"stockStatus"},arguments:[],directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"FragmentSpread",name:{kind:"Name",value:"StockStatus"},directives:[]}]}},{kind:"Field",name:{kind:"Name",value:"subName"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"primaryRoute"},arguments:[],directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"path"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"id"},arguments:[],directives:[]}]}},{kind:"Field",name:{kind:"Name",value:"images"},arguments:[],directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"alt"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"title"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"url"},arguments:[],directives:[]}]}},{kind:"Field",name:{kind:"Name",value:"variants"},arguments:[],directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"options"},arguments:[],directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"name"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"values"},arguments:[],directives:[]}]}},{kind:"Field",name:{kind:"Name",value:"values"},arguments:[],directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"id"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"articleNumber"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"values"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"price"},arguments:[],directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"FragmentSpread",name:{kind:"Name",value:"Price"},directives:[]}]}},{kind:"Field",name:{kind:"Name",value:"stockStatus"},arguments:[],directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"FragmentSpread",name:{kind:"Name",value:"StockStatus"},directives:[]}]}},{kind:"Field",name:{kind:"Name",value:"images"},arguments:[],directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"alt"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"title"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"url"},arguments:[],directives:[]}]}}]}}]}}]}},{kind:"Field",name:{kind:"Name",value:"minQuantity"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"discount"},arguments:[],directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"InlineFragment",typeCondition:{kind:"NamedType",name:{kind:"Name",value:"PackageDiscountPercentage"}},directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"percentage"},arguments:[],directives:[]}]}},{kind:"InlineFragment",typeCondition:{kind:"NamedType",name:{kind:"Name",value:"PackageDiscountValue"}},directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"valueExVat"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"valueIncVat"},arguments:[],directives:[]}
1,{kind:"Field",name:{kind:"Name",value:"valueVat"},arguments:[],directives:[]}]}}]}},{kind:"Field",name:{kind:"Name",value:"price"},arguments:[],directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"FragmentSpread",name:{kind:"Name",value:"Price"},directives:[]}]}},{kind:"Field",name:{kind:"Name",value:"previousPrice"},arguments:[],directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"FragmentSpread",name:{kind:"Name",value:"Price"},directives:[]}]}}]}}]}}]}}],loc:{start:0,end:1301}};a.loc.source={body:'#import "@jetshop/core/data/fragments/PriceFragment.gql"\n#import "@jetshop/core/data/fragments/StockStatusFragment.gql"\n\nfragment PackageProductFragment on Product {\n  isPackage\n  package {\n    price {\n      ...Price\n    }\n    discountValue {\n      ...Price\n    }\n    items {\n      product {\n        id\n        name\n        articleNumber\n        hasVariants\n        stockStatus {\n          ...StockStatus\n        }\n        subName\n        primaryRoute {\n          path\n          id\n        }\n        images {\n          alt\n          title\n          url\n        }\n        variants {\n          options {\n            name\n            values\n          }\n          values {\n            id\n            articleNumber\n            values\n            price {\n              ...Price\n            }\n            stockStatus {\n              ...StockStatus\n            }\n            images {\n              alt\n              title\n              url\n            }\n          }\n        }\n      }\n      minQuantity\n      discount {\n        ... on PackageDiscountPercentage {\n          percentage\n        }\n        ... on PackageDiscountValue {\n          valueExVat\n          valueIncVat\n          valueVat\n        }\n      }\n      price {\n        ...Price\n      }\n      previousPrice {\n        ...Price\n      }\n    }\n  }\n}\n',name:"GraphQL request",locationOffset:{line:1,column:1}};var t={};function r(e){return e.filter((function(e){if("FragmentDefinition"!==e.kind)return!0;var n=e.name.value;return!t[n]&&(t[n]=!0,!0)}))}function c(e,n){if("FragmentSpread"===e.kind)n.add(e.name.value);else if("VariableDefinition"===e.kind){var i=e.type;"NamedType"===i.kind&&n.add(i.name.value)}e.selectionSet&&e.selectionSet.selections.forEach((function(e){c(e,n)})),e.variableDefinitions&&e.variableDefinitions.forEach((function(e){c(e,n)})),e.definitions&&e.definitions.forEach((function(e){c(e,n)}))}a.definitions=a.definitions.concat(r(i("2D1U").definitions)),a.definitions=a.definitions.concat(r(i("emfR").definitions));var d={};function l(e,n){for(var i=0;i<e.definitions.length;i++){var a=e.definitions[i];if(a.name&&a.name.value==n)return a}}a.definitions.forEach((function(e){if(e.name){var n=new Set;c(e,n),d[e.name.value]=n}})),e.exports=a,e.exports.PackageProductFragment=function(e,n){var i={kind:e.kind,definitions:[l(e,n)]};e.hasOwnProperty("loc")&&(i.loc=e.loc);var a=d[n]||new Set,t=new Set,r=new Set;for(a.forEach((function(e){r.add(e)}));r.size>0;){var c=r;r=new Set,c.forEach((function(e){t.has(e)||(t.add(e),(d[e]||new Set).forEach((function(e){r.add(e)})))}))}return t.forEach((function(n){var a=l(e,n);a&&i.definitions.push(a)})),i}(a,"PackageProductFragment")},w18P:(e,n,i)=>{var a={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"query",name:{kind:"Name",value:"PackageProductQuery"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"articleNumber"}},type:{kind:"NamedType",name:{kind:"Name",value:"String"}},directives:[]}],directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"product"},arguments:[{kind:"Argument",name:{kind:"Name",value:"articleNumber"},value:{kind:"Variable",name:{kind:"Name",value:"articleNumber"}}}],directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"FragmentSpread",name:{kind:"Name",value:"PackageProductFragment"},directives:[]}]}}]}}],loc:{start:0,end:171}};a.loc.source={body:'#import "./PackageProductFragment.gql"\n\nquery PackageProductQuery($articleNumber: String) {\n  product(articleNumber: $articleNumber) {\n    ...PackageProductFragment\n  }\n}\n',name:"GraphQL request",locationOffset:{line:1,column:1}};var t={};function r(e,n){if("FragmentSpread"===e.kind)n.add(e.name.value);
1else if("VariableDefinition"===e.kind){var i=e.type;"NamedType"===i.kind&&n.add(i.name.value)}e.selectionSet&&e.selectionSet.selections.forEach((function(e){r(e,n)})),e.variableDefinitions&&e.variableDefinitions.forEach((function(e){r(e,n)})),e.definitions&&e.definitions.forEach((function(e){r(e,n)}))}a.definitions=a.definitions.concat(i("P2ma").definitions.filter((function(e){if("FragmentDefinition"!==e.kind)return!0;var n=e.name.value;return!t[n]&&(t[n]=!0,!0)})));var c={};function d(e,n){for(var i=0;i<e.definitions.length;i++){var a=e.definitions[i];if(a.name&&a.name.value==n)return a}}a.definitions.forEach((function(e){if(e.name){var n=new Set;r(e,n),c[e.name.value]=n}})),e.exports=a,e.exports.PackageProductQuery=function(e,n){var i={kind:e.kind,definitions:[d(e,n)]};e.hasOwnProperty("loc")&&(i.loc=e.loc);var a=c[n]||new Set,t=new Set,r=new Set;for(a.forEach((function(e){r.add(e)}));r.size>0;){var l=r;r=new Set,l.forEach((function(e){t.has(e)||(t.add(e),(c[e]||new Set).forEach((function(e){r.add(e)})))}))}return t.forEach((function(n){var a=d(e,n);a&&i.definitions.push(a)})),i}(a,"PackageProductQuery")},X5Hq:(e,n,i)=>{"use strict";i.r(n)},BcEV:(e,n,i)=>{"use strict";i.r(n)}}]);

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.