@wix/stores 1.0.959 → 1.0.960
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/_sdk-exports/context-category-by-id-context-provider/runtime.d.ts +4026 -0
- package/_sdk-exports/context-category-by-id-context-provider/runtime.js +2 -0
- package/_sdk-exports/context-category-by-slug-context-provider/runtime.d.ts +4046 -0
- package/_sdk-exports/context-category-by-slug-context-provider/runtime.js +2 -0
- package/_sdk-exports/context-category-info-context-provider/runtime.d.ts +3530 -0
- package/_sdk-exports/context-category-info-context-provider/runtime.js +2 -0
- package/_sdk-exports/context-category-list-context-provider/runtime.d.ts +101 -0
- package/_sdk-exports/context-category-list-context-provider/runtime.js +2 -0
- package/_sdk-exports/context-product-by-id-context-provider/runtime.d.ts +4221 -0
- package/_sdk-exports/context-product-by-id-context-provider/runtime.js +2 -0
- package/_sdk-exports/context-product-by-slug-context-provider/runtime.d.ts +4217 -0
- package/_sdk-exports/context-product-by-slug-context-provider/runtime.js +2 -0
- package/_sdk-exports/context-product-context-provider/runtime.d.ts +4449 -0
- package/_sdk-exports/context-product-context-provider/runtime.js +2 -0
- package/_sdk-exports/context-product-item-context-provider/runtime.d.ts +4102 -0
- package/_sdk-exports/context-product-item-context-provider/runtime.js +2 -0
- package/_sdk-exports/context-product-list-context-provider/runtime.d.ts +3969 -0
- package/_sdk-exports/context-product-list-context-provider/runtime.js +2 -0
- package/_sdk-exports/context-promotion-item-context-provider/runtime.d.ts +85 -0
- package/_sdk-exports/context-promotion-item-context-provider/runtime.js +2 -0
- package/build/cjs/context-category-by-id-context-provider.d.ts +4026 -0
- package/build/cjs/context-category-by-id-context-provider.js +3572 -0
- package/build/cjs/context-category-by-id-context-provider.js.map +1 -0
- package/build/cjs/context-category-by-slug-context-provider.d.ts +4046 -0
- package/build/cjs/context-category-by-slug-context-provider.js +3674 -0
- package/build/cjs/context-category-by-slug-context-provider.js.map +1 -0
- package/build/cjs/context-category-info-context-provider.d.ts +3530 -0
- package/build/cjs/context-category-info-context-provider.js +1201 -0
- package/build/cjs/context-category-info-context-provider.js.map +1 -0
- package/build/cjs/context-category-list-context-provider.d.ts +101 -0
- package/build/cjs/context-category-list-context-provider.js +587 -0
- package/build/cjs/context-category-list-context-provider.js.map +1 -0
- package/build/cjs/context-product-by-id-context-provider.d.ts +4221 -0
- package/build/cjs/context-product-by-id-context-provider.js +3454 -0
- package/build/cjs/context-product-by-id-context-provider.js.map +1 -0
- package/build/cjs/context-product-by-slug-context-provider.d.ts +4217 -0
- package/build/cjs/context-product-by-slug-context-provider.js +3477 -0
- package/build/cjs/context-product-by-slug-context-provider.js.map +1 -0
- package/build/cjs/context-product-context-provider.d.ts +4449 -0
- package/build/cjs/context-product-context-provider.js +587 -0
- package/build/cjs/context-product-context-provider.js.map +1 -0
- package/build/cjs/context-product-item-context-provider.d.ts +4102 -0
- package/build/cjs/context-product-item-context-provider.js +4396 -0
- package/build/cjs/context-product-item-context-provider.js.map +1 -0
- package/build/cjs/context-product-list-context-provider.d.ts +3970 -0
- package/build/cjs/context-product-list-context-provider.js +587 -0
- package/build/cjs/context-product-list-context-provider.js.map +1 -0
- package/build/cjs/context-promotion-item-context-provider.d.ts +85 -0
- package/build/cjs/context-promotion-item-context-provider.js +592 -0
- package/build/cjs/context-promotion-item-context-provider.js.map +1 -0
- package/build/es/context-category-by-id-context-provider.d.mts +4026 -0
- package/build/es/context-category-by-id-context-provider.mjs +3532 -0
- package/build/es/context-category-by-id-context-provider.mjs.map +1 -0
- package/build/es/context-category-by-slug-context-provider.d.mts +4046 -0
- package/build/es/context-category-by-slug-context-provider.mjs +3634 -0
- package/build/es/context-category-by-slug-context-provider.mjs.map +1 -0
- package/build/es/context-category-info-context-provider.d.mts +3530 -0
- package/build/es/context-category-info-context-provider.mjs +1172 -0
- package/build/es/context-category-info-context-provider.mjs.map +1 -0
- package/build/es/context-category-list-context-provider.d.mts +101 -0
- package/build/es/context-category-list-context-provider.mjs +558 -0
- package/build/es/context-category-list-context-provider.mjs.map +1 -0
- package/build/es/context-product-by-id-context-provider.d.mts +4221 -0
- package/build/es/context-product-by-id-context-provider.mjs +3415 -0
- package/build/es/context-product-by-id-context-provider.mjs.map +1 -0
- package/build/es/context-product-by-slug-context-provider.d.mts +4217 -0
- package/build/es/context-product-by-slug-context-provider.mjs +3437 -0
- package/build/es/context-product-by-slug-context-provider.mjs.map +1 -0
- package/build/es/context-product-context-provider.d.mts +4449 -0
- package/build/es/context-product-context-provider.mjs +558 -0
- package/build/es/context-product-context-provider.mjs.map +1 -0
- package/build/es/context-product-item-context-provider.d.mts +4102 -0
- package/build/es/context-product-item-context-provider.mjs +4356 -0
- package/build/es/context-product-item-context-provider.mjs.map +1 -0
- package/build/es/context-product-list-context-provider.d.mts +3970 -0
- package/build/es/context-product-list-context-provider.mjs +558 -0
- package/build/es/context-product-list-context-provider.mjs.map +1 -0
- package/build/es/context-promotion-item-context-provider.d.mts +85 -0
- package/build/es/context-promotion-item-context-provider.mjs +563 -0
- package/build/es/context-promotion-item-context-provider.mjs.map +1 -0
- package/build/internal/cjs/context-category-by-id-context-provider.d.ts +4026 -0
- package/build/internal/cjs/context-category-by-slug-context-provider.d.ts +4046 -0
- package/build/internal/cjs/context-category-info-context-provider.d.ts +3530 -0
- package/build/internal/cjs/context-category-list-context-provider.d.ts +101 -0
- package/build/internal/cjs/context-product-by-id-context-provider.d.ts +4221 -0
- package/build/internal/cjs/context-product-by-slug-context-provider.d.ts +4217 -0
- package/build/internal/cjs/context-product-context-provider.d.ts +4449 -0
- package/build/internal/cjs/context-product-item-context-provider.d.ts +4102 -0
- package/build/internal/cjs/context-product-list-context-provider.d.ts +3970 -0
- package/build/internal/cjs/context-promotion-item-context-provider.d.ts +85 -0
- package/build/internal/es/context-category-by-id-context-provider.d.mts +4026 -0
- package/build/internal/es/context-category-by-slug-context-provider.d.mts +4046 -0
- package/build/internal/es/context-category-info-context-provider.d.mts +3530 -0
- package/build/internal/es/context-category-list-context-provider.d.mts +101 -0
- package/build/internal/es/context-product-by-id-context-provider.d.mts +4221 -0
- package/build/internal/es/context-product-by-slug-context-provider.d.mts +4217 -0
- package/build/internal/es/context-product-context-provider.d.mts +4449 -0
- package/build/internal/es/context-product-item-context-provider.d.mts +4102 -0
- package/build/internal/es/context-product-list-context-provider.d.mts +3970 -0
- package/build/internal/es/context-promotion-item-context-provider.d.mts +85 -0
- package/category-by-id-context-provider/package.json +3 -0
- package/category-by-slug-context-provider/package.json +3 -0
- package/category-info-context-provider/package.json +3 -0
- package/category-list-context-provider/package.json +3 -0
- package/context/category-by-id-context-provider/package.json +3 -0
- package/context/category-by-slug-context-provider/package.json +3 -0
- package/context/category-info-context-provider/package.json +3 -0
- package/context/category-list-context-provider/package.json +3 -0
- package/context/product-by-id-context-provider/package.json +3 -0
- package/context/product-by-slug-context-provider/package.json +3 -0
- package/context/product-context-provider/package.json +3 -0
- package/context/product-item-context-provider/package.json +3 -0
- package/context/product-list-context-provider/package.json +3 -0
- package/context/promotion-item-context-provider/package.json +3 -0
- package/package.json +159 -24
- package/product-by-id-context-provider/package.json +3 -0
- package/product-by-slug-context-provider/package.json +3 -0
- package/product-context-provider/package.json +3 -0
- package/product-item-context-provider/package.json +3 -0
- package/product-list-context-provider/package.json +3 -0
- package/promotion-item-context-provider/package.json +3 -0
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import{Suspense as e,useCallback as t,useMemo as n,useState as r}from"react";import i,{useProductContext as a}from"@wix/stores/product-context-provider";import{useGetService as o,useService as s}from"@wix/services-manager-react";import{jsx as c}from"react/jsx-runtime";var l=Object.create,u=Object.defineProperty,d=Object.getOwnPropertyDescriptor,f=Object.getOwnPropertyNames,p=Object.getPrototypeOf,m=Object.prototype.hasOwnProperty,h=(e,t)=>()=>(t||(e((t={exports:{}}).exports,t),e=null),t.exports),g=(e,t,n,r)=>{if(t&&typeof t==`object`||typeof t==`function`)for(var i=f(t),a=0,o=i.length,s;a<o;a++)s=i[a],!m.call(e,s)&&s!==n&&u(e,s,{get:(e=>t[e]).bind(null,s),enumerable:!(r=d(t,s))||r.enumerable});return e},_=(e,t,n)=>(n=e==null?{}:l(p(e)),g(t||!e||!e.__esModule||!m.call(e,`default`)?u(n,`default`,{value:e,enumerable:!0}):n,e)),v={};function y(e,t=!1,n=e=>e){return()=>({__type:`event-definition`,type:e,isDomainEvent:t,transformations:n})}var b=e=>{switch(e){case`get`:case`GET`:return`GET`;case`post`:case`POST`:return`POST`;case`put`:case`PUT`:return`PUT`;case`delete`:case`DELETE`:return`DELETE`;case`patch`:case`PATCH`:return`PATCH`;case`head`:case`HEAD`:return`HEAD`;case`options`:case`OPTIONS`:return`OPTIONS`;default:throw Error(`Unknown method: ${e}`)}},x=e=>t=>async n=>{let r,i=t=>{if(r=e(n)(t),r.url===void 0)throw Error(`Url was not successfully created for this request, please reach out to support channels for assistance.`);let{method:i,url:a,params:o}=r;return{...r,method:b(i),url:a,data:r.data,params:o}};try{let e=await t.request(i);if(r===void 0)throw Error(`Request options were not created for this request, please reach out to support channels for assistance.`);let n=Array.isArray(r.transformResponse)?r.transformResponse:[r.transformResponse],a=e.data;return n.forEach(t=>{t&&(a=t(e.data,e.headers))}),a}catch(e){throw typeof e==`object`&&e&&`response`in e&&typeof e.response==`object`&&e.response!==null&&`data`in e.response?e.response.data:e}},S=e=>e.__isAmbassador?!0:!!e().__isAmbassador,C=`__metadata`,w=`edge.wixapis.com`,T=class extends Error{message;response;constructor(e,t){super(e),this.message=e,this.response=t}async details(){let e=await this.response.json();return E(this.response.status,e?.message,e?.details,{requestId:this.response.headers.get(`X-Wix-Request-Id`),details:e})}},E=(e,t,n,r)=>({details:{...!n?.validationError&&{applicationError:{description:t,code:e,data:r}},...n},message:t,requestId:r?.requestId}),D=e=>e?.method&&[`post`,`put`,`patch`].includes(e.method.toLocaleLowerCase())&&e.body?{"Content-Type":`application/json`}:{},O=e=>e&&typeof e==`object`&&!Array.isArray(e),k=e=>e.__type===`host`;function ee(e,t){return e.create(t)}var te=`x-wix-bi-gateway`;function ne(e,t,n){return{[te]:re({environment:`js-sdk${n?`-${n}`:``}`,"package-name":e.packageName??t?.PACKAGE_NAME,"method-fqn":e.methodFqn,entity:e.entityFqdn})}}function re(e){return Object.entries(e).filter(([e,t])=>!!t).map(([e,t])=>`${e}=${t}`).join(`,`)}function ie(e){let t=globalThis.__wix_context__,n={client:v.client,elevatedClient:v.elevatedClient},r;globalThis.__wix_context__=void 0,v.client=void 0,v.elevatedClient=void 0,typeof $wixContext<`u`&&(r={client:$wixContext?.client,elevatedClient:$wixContext?.elevatedClient},delete $wixContext.client,delete $wixContext.elevatedClient);try{return e()}finally{globalThis.__wix_context__=t,v.client=n.client,v.elevatedClient=n.elevatedClient,typeof $wixContext<`u`&&($wixContext.client=r.client,$wixContext.elevatedClient=r.elevatedClient)}}var ae={id:`_id`,createdDate:`_createdDate`,updatedDate:`_updatedDate`};function oe(e){return de(e).map(e=>e.toLocaleUpperCase()).join(`_`)}var se=/([\p{Ll}\d])(\p{Lu})/gu,ce=/(\p{Lu})([\p{Lu}][\p{Ll}])/gu,le=`$1\0$2`,ue=/[^\p{L}\d]+/giu;function de(e){let t=e.trim();t=t.replace(se,le).replace(ce,le),t=t.replace(ue,`\0`);let n=0,r=t.length;for(;t.charAt(n)===`\0`;)n++;if(n===r)return[];for(;t.charAt(r-1)===`\0`;)r--;return t.slice(n,r).split(/\0/g)}var fe=e=>`validationError`in(e.response?.data?.details??{}),pe=e=>`applicationError`in(e.response?.data?.details??{}),me=e=>(e.response?.status??-1)>=400&&(e.response?.status??-1)<500;function he(e,t={explicitPathsToArguments:{},spreadPathsToArguments:{},singleArgumentUnchanged:!1},n=[]){if(typeof e!=`object`||!e)throw e;if(fe(e))return ge(e,t,n);if(pe(e))return ve(e);if(me(e)){let t=e.response?.status,n=e.response?.statusText??`UNKNOWN`,r=e.response?.data?.message??n,i={applicationError:{description:n,code:oe(n),data:{}},requestId:e.requestId};return _e(e,{message:JSON.stringify({message:r,details:i},null,2),extraProperties:{details:i,status:t}})}return ye(e)}var ge=(e,t,n)=>{let r=e.response?.data,i=e.requestId,{fieldViolations:a}=r.details.validationError,o=be(t,a,n)?.sort((e,t)=>e.field<t.field?-1:1),s=`INVALID_ARGUMENT: ${o?.map(({field:e,description:t})=>`"${e}" ${t}`)?.join(`, `)}`,c={validationError:{fieldViolations:o},requestId:i};return _e(e,{message:JSON.stringify({message:s,details:c},null,2),extraProperties:{details:c,status:e.response?.status,requestId:i}})},_e=(e,{message:t,extraProperties:n})=>Object.assign(e,{...n,message:t}),ve=e=>{let t=e.response?.status,n=e.response?.statusText??`UNKNOWN`,r=e.response?.data?.message??n,i=e.response?.data?.details?.applicationError?.description??n,a=e.response?.data?.details?.applicationError?.code??oe(n),o=e.response?.data?.details?.applicationError?.data??{},s=r===i?r:`${r}: ${i}`,c={applicationError:{description:i,code:a,data:o},requestId:e.requestId};return _e(e,{message:JSON.stringify({message:s,details:c},null,2),extraProperties:{details:c,status:t,requestId:e.requestId}})},ye=e=>_e(e,{message:e.requestId?`System error occurred, request-id: ${e.requestId}`:`System error occurred: ${JSON.stringify(e)}`,extraProperties:{requestId:e.requestId,status:e.response?.status,code:oe(e.response?.statusText??`UNKNOWN`),...!e.response&&{runtimeError:e}}}),be=({spreadPathsToArguments:e,explicitPathsToArguments:t,singleArgumentUnchanged:n},r,i)=>{let a={...e,...t},o=Object.keys(a);return r?.filter(e=>!r.some(t=>t.field.length>e.field.length&&t.field.startsWith(e.field)&&o.includes(t.field))).map(e=>{let r=t[e.field];if(r)return{...e,field:xe(r,i)};let s=o?.sort((e,t)=>t.length-e.length)?.find(t=>e.field.startsWith(t));if(s){let t=a[s];if(t)return{...e,field:e.field.replace(s,xe(t,i))}}return n?{...e,field:`${i[0]}.${e.field}`}:e})},xe=(e,t)=>{let n=Se(e);return n==null?e:e.replace(`$[${n}]`,t[n])},Se=e=>{let t=e.match(/\$\[(?<argIndex>\d+)\]/);return t&&t.groups&&Number(t.groups.argIndex)};function Ce(e,t,n,r,i,a,o,s,c,l,u){return ie(()=>e({request:async e=>{let i=e({host:s?.HTTPHost||`www.wixapis.com`}),a=i;a.method===`GET`&&a.fallback?.length&&(a.params?.toString().length??0)>4e3&&(a=i.fallback[0]);let o=s?.HTTPHost??`www.wixapis.com`,u=`https://${l?w:o}${a.url}`;a.params&&a.params.toString()&&(u+=`?${a.params.toString()}`);try{let e=ne(i,t,c),o={method:a.method,...a.data&&{body:JSON.stringify(a.data)},headers:{...e}},s=await n(u,o);if(s.status!==200){let e=null;try{e=await s.json()}catch{}let t=Te(s.status,e?.message??s.statusText,e?.details,{requestId:s.headers.get(`X-Wix-Request-Id`),details:e}),n=he(t);throw r?.handleError(n,{requestOptions:{url:a.url,method:a.method,entityFqdn:i.entityFqdn,methodFqn:i.methodFqn}}),t}let l=await s.json();return{data:a.migrationOptions?.optInTransformResponse&&a.transformResponse?Array.isArray(a.transformResponse)?a.transformResponse[0](l):a.transformResponse(l):l,headers:s.headers,status:s.status,statusText:s.statusText}}catch(e){throw e.message?.includes(`fetch is not defined`)&&console.error(`Node.js v18+ is required`),e}},fetchWithAuth:n,wixAPIFetch:i,getActiveToken:a,getAuthHeaders:o},{validateRequestSchema:u}))}var we=class extends Error{response;requestId;constructor(e){super(),this.response=e.response,this.requestId=e.requestId}},Te=(e,t,n,r)=>new we({response:{data:{details:{...!n?.validationError&&{applicationError:{description:t,code:e,data:r}},...n},message:t},status:e},requestId:r?.requestId}),Ee=`.`;function De(e,t,n){if(e==null)throw Error(`Cannot set value on null or undefined`);let r=Oe(t),i=e;for(let e=0;e<r.length;e++){let t=r[e];if(e===r.length-1){i[t]=n;break}let a=r[e+1];(!(t in i)||i[t]==null||typeof i[t]!=`object`||i[t]===null)&&(i[t]=typeof a==`number`?[]:{}),i=i[t]}return e}function Oe(e){return Array.isArray(e)?e:e.split(Ee).map(e=>ke(e)?Number(e):e)}function ke(e){return/^\d+$/.test(e)}function Ae(e){let t={};for(let[n,r]of Object.entries(e))je(n)||De(t,Oe(n),r);return t}function je(e){return e===`__proto__`||e===`constructor`||e===`prototype`}var Me=class{BRACKET_PATTERN=/\[(\d+)\]/g;NUMERIC_PATTERN=/^\d+$/;ESCAPED_DOT_PATTERN=/\\\./g;ESCAPED_LEFT_BRACKET_PATTERN=/\\\[/g;ESCAPED_RIGHT_BRACKET_PATTERN=/\\\]/g;SPLIT_PATTERN=/\.|\[(\d+)\]/g;DOT_BEFORE_BRACKET_PATTERN=/\.\[/g;ESCAPED_DOT_PLACEHOLDER=`__DOT__`;ESCAPED_RIGHT_BRACKET_PLACEHOLDER=`__RB__`;ESCAPED_LEFT_BRACKET_PLACEHOLDER=`__LB__`;modifiedFields;cleanedModifiedFields;constructor(e){this.modifiedFields=e}replaceEscapedCharacters(e){return e.replace(this.ESCAPED_DOT_PATTERN,this.ESCAPED_DOT_PLACEHOLDER).replace(this.ESCAPED_LEFT_BRACKET_PATTERN,this.ESCAPED_LEFT_BRACKET_PLACEHOLDER).replace(this.ESCAPED_RIGHT_BRACKET_PATTERN,this.ESCAPED_RIGHT_BRACKET_PLACEHOLDER)}restoreEscapedCharacters(e){return e.replace(this.ESCAPED_DOT_PLACEHOLDER,`\\.`).replace(this.ESCAPED_RIGHT_BRACKET_PLACEHOLDER,`\\]`).replace(this.ESCAPED_LEFT_BRACKET_PLACEHOLDER,`\\[`)}unflatten(){return this.cleanedModifiedFields=Object.fromEntries(Object.entries(this.modifiedFields).map(([e,t])=>[this.replaceEscapedCharacters(this.bracketToDotNotation(e)),t])),Ae(this.cleanedModifiedFields)}flatten(e){let t={};for(let n of Object.keys(this.cleanedModifiedFields)){let r=this.splitPath(n),i=this.navigatePath(e,r);t={...t,...i}}return Object.fromEntries(Object.entries(t).map(([e,t])=>[this.restoreEscapedCharacters(e),t]))}splitPath(e){let t=[],n=0,r=Array.from(e.matchAll(this.SPLIT_PATTERN));for(let i of r)i.index>n&&t.push(e.substring(n,i.index)),i[1]&&t.push(i[1]),n=i.index+i[0].length;return n<e.length&&t.push(e.substring(n)),t}navigatePath(e,t){let n=e,r=[],i=e=>{if(!Array.isArray(n))throw Error(`Expected array at path ${this.buildPathString(r)}, but got ${typeof n}`);r.push(`[${e}]`),n=n[parseInt(e,10)]},a=(e,t)=>{let i=e in ae?ae[e]:void 0;if(i&&i in t){r.push(i),n=t[i];return}let a=Ie(e);if(a&&a in t){r.push(a),n=t[a];return}throw Error(`Cannot find key '${e}' or its transformations at path ${this.buildPathString(r)}`)},o=(e,t)=>{r.push(e),n=t[e]};for(let e of t){if(this.NUMERIC_PATTERN.test(e)){i(e);continue}if(typeof n!=`object`||!n)throw Error(`Cannot access property '${e}' on ${typeof n} at path ${this.buildPathString(r)}`);let t=n;if(e in n){o(e,t);continue}a(e,t)}return{[this.buildPathString(r)]:n}}buildPathString(e){return e.join(`.`).replace(this.DOT_BEFORE_BRACKET_PATTERN,`[`)}bracketToDotNotation(e){return e.replace(this.BRACKET_PATTERN,(t,n,r)=>r>0&&e[r-1]===`\\`?t:`.`+n)}};function Ne(e,t){let n=e?.modifiedFields;if(!n)return null;let r=Pe(n);if(!r)return null;let{unflattenedModifiedFields:i,modifiedFieldsManipulator:a}=r;e={...e,modifiedFields:i};let o=t(e),s=o?.modifiedFields;if(!s)return null;let c=Fe(s,a);return c===null?null:(o.modifiedFields=c,o)}function Pe(e){if(typeof e==`object`&&e&&!Array.isArray(e))try{let t=new Me(e);return{unflattenedModifiedFields:t.unflatten(),modifiedFieldsManipulator:t}}catch{return null}return null}function Fe(e,t){if(typeof e==`object`&&e&&!Array.isArray(e))try{return t.flatten(e)}catch{return null}return null}function Ie(e){return e.replace(/[-_\s]+(.)?/g,(e,t)=>t?t.toUpperCase():``).replace(/^./,e=>e.toLowerCase())}function Le(){return{emit(e,...t){for(let n=0,r=this.events[e]||[],i=r.length;n<i;n++)r[n](...t)},events:{},on(e,t){return(this.events[e]||=[]).push(t),()=>{this.events[e]=this.events[e]?.filter(e=>t!==e)}}}}var Re=e=>e.__type===`event-definition`;function ze(e,t,n,r){let i;if(e.isDomainEvent){let{deletedEvent:e,actionEvent:t,createdEvent:a,updatedEvent:o,...s}=n,c={...r,...s};i=e?e?.deletedEntity?{entity:e?.deletedEntity,metadata:c}:{metadata:c}:t?{data:t.body,metadata:c}:o?{entity:o.currentEntity,metadata:c,...o.modifiedFields?{modifiedFields:o.modifiedFields}:{}}:{entity:a?.entity,metadata:c}}else i={data:n,metadata:r};let a=e.transformations??(e=>e),o=i,s=i;if(s.modifiedFields){let e=s.modifiedFields;if(typeof e==`object`&&e&&!Array.isArray(e)){o=structuredClone(i);let e=Ne(s,a);if(e)return t(e)}}return t(a(o))}function Be(e){let t=new Map,n=Le();return{initModule(e){return r=>{let i=t.get(e.type)??[];i.push({eventDefinition:e,handler:r}),t.set(e.type,i),n.emit(`registered`,e)}},client:{...n,getRegisteredEvents:()=>t,async process(e,n={expectedEvents:[]}){let{eventType:r,identity:i,instanceId:a,payload:o,accountInfo:s}=await this.parseJWT(e),c=[...n.expectedEvents,...Array.from(t.keys()).map(e=>({type:e}))];if(c.length>0&&!c.some(({type:e})=>e===r))throw Error(`Unexpected event type: ${r}. Expected one of: ${c.map(e=>e.type).join(`, `)}`);let l=t.get(r)??[];return await Promise.all(l.map(({eventDefinition:e,handler:t})=>ze(e,t,o,{instanceId:a,identity:i,accountInfo:s}))),{instanceId:a,eventType:r,payload:o,identity:i,accountInfo:s}},async processRequest(e,t){let n=await e.text();return this.process(n,t)},async parseJWT(t){let n=e();if(!n.decodeJWT)throw Error(`decodeJWT is not supported by the authentication strategy`);let{decoded:r,valid:i}=await n.decodeJWT(t);if(!i)throw Error(`JWT is not valid`);if(typeof r.data!=`string`)throw Error(`Unexpected type of JWT data: expected string, got ${typeof r.data}`);let a=JSON.parse(r.data),o=a.eventType,s=a.accountInfo,c=a.instanceId,l=a.identity?JSON.parse(a.identity):void 0;return{instanceId:c,eventType:o,payload:JSON.parse(a.data),identity:l,accountInfo:s}},async parseRequest(e){let t=await e.text();return this.parseJWT(t)},async executeHandlers(e){let n=Array.from(t.keys()).map(e=>({type:e}));if(n.length>0&&!n.some(({type:t})=>t===e.eventType))throw Error(`Unexpected event type: ${e.eventType}. Expected one of: ${n.map(e=>e.type).join(`, `)}`);let r=t.get(e.eventType)??[];await Promise.all(r.map(({eventDefinition:t,handler:n})=>ze(t,n,e.payload,{instanceId:e.instanceId,identity:e.identity})))},apps:{AppInstalled:y(`AppInstalled`)(),AppRemoved:y(`AppRemoved`)()}}}}var Ve=e=>e.__type===`service-plugin-definition`;function He(e){let t=new Map,n=Le();return{initModule(e){return r=>{let i=t.get(e.componentType.toLowerCase())??[];i.push({servicePluginDefinition:e,implementation:r}),t.set(e.componentType.toLowerCase(),i),n.emit(`registered`,e)}},client:{...n,getRegisteredServicePlugins:()=>t,async parseJWT(t){let n=e();if(!n.decodeJWT)throw Error(`decodeJWT is not supported by the authentication strategy`);let{decoded:r,valid:i}=await n.decodeJWT(t,!0);if(!i)throw Error(`JWT is not valid`);if(typeof r.data!=`object`||r.data===null||!(`metadata`in r.data)||typeof r.data.metadata!=`object`||r.data.metadata===null||!(`appExtensionType`in r.data.metadata)||typeof r.data.metadata.appExtensionType!=`string`)throw Error(`Unexpected JWT data: expected object with metadata.appExtensionType string`);return r.data},async process(e){let t=await this.parseJWT(e.body);return this.executeHandler(t,e.url)},async parseRequest(e){let t=await e.text();return this.parseJWT(t)},async processRequest(e){let t=await this.parseRequest(e);return this.processParsedRequest(t,e.url)},async processParsedRequest(e,t){try{let n=await this.executeHandler(e,t);return Response.json(n)}catch(e){if(e.errorType===`SPI`&&e.applicationCode&&e.httpCode)return Response.json({applicationError:{code:e.applicationCode,data:e.data}},{status:e.httpCode});throw e}},async executeHandler(e,n){let r=e.metadata.appExtensionType.toLowerCase(),i=t.get(r)??[];if(i.length===0)throw Error(`No service plugin implementations found for component type ${r}`);if(i.length>1)throw Error(`Multiple service plugin implementations found for component type ${r}. This is currently not supported`);let{implementation:a,servicePluginDefinition:o}=i[0],s=o.methods.find(e=>n.endsWith(e.primaryHttpMappingPath));if(!s)throw Error(`Unexpect request: request url did not match any method: `+n);let c=a[s.name];if(!c)throw Error(`Got request for service plugin method ${s.name} but no implementation was provided. Available methods: ${Object.keys(a).join(`, `)}`);return s.transformations.toREST(await c(s.transformations.fromREST(e)))}}}}var A=`X-Wix-Consistent`;function Ue(e){let t=e.headers||{Authorization:``},n={getAuthHeaders:e=>Promise.resolve({headers:{}})},r=e.auth,i=typeof r==`function`?r:()=>r??n,a=()=>i().getAuthHeaders(e.host),o=()=>e.fetch??fetch,s=async(n,r)=>{let i=o(),s=await a(),c={...r?.headers??{},...s.headers,...e.host?.essentials?.passThroughHeaders,...t[`X-Wix-Consistent`]?{[A]:t[A]}:{}},l=e.host?.getErrorHandler?.();try{if(typeof n==`string`||n instanceof URL){let e=await i(n,{...r,headers:c});l?.handleError(e,{requestOptions:{url:n.toString(),method:r?.method}});let a=We(e);return a&&(t[A]=a),e}{for(let[e,t]of Object.entries(c))typeof t==`string`&&n.headers.set(e,t);let e=await i(n,r);l?.handleError(e,{requestOptions:{url:n.url,method:r?.method}});let a=We(e);return a&&(t[A]=a),e}}catch(e){throw l?.handleError(e,{requestOptions:{url:typeof n==`string`||n instanceof URL?n.toString():n.url,method:r?.method}}),e}},{client:c,initModule:l}=He(i),{client:u,initModule:d}=Be(i),f=async(n,r)=>{let i=o(),s=await a(),c=D(r),l=await i(n,{...r,headers:{...c,...t,...s?.headers,...r?.headers,...e.host?.essentials?.passThroughHeaders,...t[`X-Wix-Consistent`]?{[A]:t[A]}:{}}}),u=We(l);return u&&(t[A]=u),l},p=(t,n)=>{if(Re(t))return d(t);if(Ve(t))return l(t);if(k(t)&&e.host)return ee(t,e.host);if(typeof t==`function`){if(`__type`in t&&t.__type===`wix_spi_error`)return t;let r=e.host?.apiBaseUrl??`www.wixapis.com`,o=e.useCDN===void 0?i().shouldUseCDN:e.useCDN;return Ce(ie(()=>S(t))?x(t):t,n??{},f,e.host?.getErrorHandler?.(),(e,t)=>{let n=new URL(e,`https://${r}`);return n.host=r,n.protocol=`https`,f(n.toString(),t)},i().getActiveToken,async()=>a(),{HTTPHost:r},e.host?.name,o,e.validateRequestSchema)}return O(t)?Object.fromEntries(Object.entries(t).map(([e,n])=>[e,p(n,t[C])])):t},m=e=>{for(let n in e)t[n]=e[n]};return{...e.modules?p(e.modules):{},get auth(){let t=i();return t.getAuthHeaders=t.getAuthHeaders.bind(void 0,e.host),t},setHeaders:m,use:p,enableContext(e,t={elevated:!1}){e===`global`?globalThis.__wix_context__==null?t.elevated?globalThis.__wix_context__={elevatedClient:this}:globalThis.__wix_context__={client:this}:t.elevated?globalThis.__wix_context__.elevatedClient=this:globalThis.__wix_context__.client=this:t.elevated?v.elevatedClient=this:v.client=this},fetch:(t,n)=>{let r=e.host?.apiBaseUrl??`www.wixapis.com`,i=new URL(t,`https://${r}`);return i.host=r,i.protocol=`https`,f(i.toString(),n)},fetchWithAuth:s,async graphql(t,n,r={apiVersion:`alpha`}){let i=e?.host?.apiBaseUrl??`www.wixapis.com`,a=await f(`https://${i}/graphql/${r.apiVersion}`,{method:`POST`,headers:{"Content-Type":`application/json`},body:JSON.stringify({query:t,variables:n})});if(a.status!==200)throw new T(`GraphQL request failed with status ${a.status}`,a);let{data:o,errors:s}=await a.json();return{data:o??{},errors:s}},webhooks:u,servicePlugins:c}}function We(e){return e.headers?.get(`X-Wix-Consistent`)??e.headers?.get(`x-wix-consistent`)}var Ge=`wix:`,Ke={_id:`id`,_createdDate:`createdDate`,_updatedDate:`updatedDate`},qe={id:`_id`,createdDate:`_createdDate`,updatedDate:`_updatedDate`},Je=`items`,Ye=`pagingMetadata`,Xe=Ke;function Ze(e,t){return e?.split(`.`).map(e=>t?.[e]??e).join(`.`)}function Qe(e,{transformSystemFields:t=!0}={}){return t?Ze(e,Xe):e}var $e=`sort.fieldName`;function et(e,t,n){return(e===$e||e.endsWith(`.${$e}`))&&typeof t==`string`?Ze(t,n):t}function tt(e,t,n){let r=e=>n.includes(e),i=(e,n)=>{if(Array.isArray(e))e.forEach(e=>{i(e,n)});else if(typeof e==`object`&&e){let a=e;Object.keys(a).forEach(e=>{let o=n===``?e:`${n}.${e}`;if(r(o))return;let s=nt(e,t);s!==e&&!(s in a)&&(a[s]=a[e],delete a[e]),a[s]=et(o,a[s],t),i(a[s],o)})}};return i(e,``),e}function nt(e,t){let n;return n=e.includes(`.`)?e.split(`.`).map(e=>t[e]??e).join(`.`):t[e]??e,n}function j(e,t=[]){return tt(e,Ke,t)}function M(e,t=[]){return tt(e,qe,t)}function rt(e){return e?.toISOString()}function N(e){return e?new Date(e):void 0}var it=new WeakMap;function at(){return{leaves:void 0,fields:void 0,mapFields:void 0,anyField:void 0}}function ot(e,t){let n=e.get(t);return n||(n=at(),e.set(t,n)),n}function st(e,t){return t===`*`?(e.anyField??=at(),e.anyField):t.endsWith(`{}`)?(e.mapFields??=new Map,ot(e.mapFields,t.slice(0,-2))):(e.fields??=new Map,ot(e.fields,t))}function ct(e){let t=at();for(let n of e){let e=n.path.split(`.`).reduce(st,t);e.leaves??=[],e.leaves.push(n)}return t}function lt(e){let t=it.get(e);return t||(t=ct(e),it.set(e,t)),t}function ut(e){return typeof e==`object`&&!!e}function dt(e,{isRepeated:t,isMap:n},r){return t?Array.isArray(e)?e.map(r):e:n?ut(e)?Object.fromEntries(Object.entries(e).map(([e,t])=>[e,r(t)])):e:r(e)}function ft(e,t,n){ut(e)&&ht(e,t,n)}function pt(e,t,n){for(let[r,i]of t){if(!(r in e))continue;if(i.leaves)for(let t of i.leaves)e[r]=dt(e[r],t,n);let t=e[r];Array.isArray(t)?t.forEach(e=>ft(e,i,n)):ft(t,i,n)}}function mt(e,t,n){for(let[r,i]of t){let t=e[r];ut(t)&&Object.values(t).forEach(e=>ft(e,i,n))}}function ht(e,{fields:t,mapFields:n,anyField:r},i){t&&pt(e,t,i),n&&mt(e,n,i),r&&Object.values(e).forEach(e=>ft(e,r,i))}function P(e,t){if(!ut(e))return e;for(let{paths:n,transformFn:r}of t)ht(e,lt(n),r);return e}function gt(e,t){let{protocol:n}=new URL(e);return n===`${t}:`?`${Ge}${e}`:e}function _t(e){return Object.fromEntries(Object.entries(e).filter(([,e])=>e!==void 0))}function vt(e){return Ct(e).map(e=>e.toLocaleUpperCase()).join(`_`)}var yt=/([\p{Ll}\d])(\p{Lu})/gu,bt=/(\p{Lu})([\p{Lu}][\p{Ll}])/gu,xt=`$1\0$2`,St=/[^\p{L}\d]+/giu;function Ct(e){let t=e.trim();t=t.replace(yt,xt).replace(bt,xt),t=t.replace(St,`\0`);let n=0,r=t.length;for(;t.charAt(n)===`\0`;)n++;if(n===r)return[];for(;t.charAt(r-1)===`\0`;)r--;return t.slice(n,r).split(/\0/g)}var wt=e=>`validationError`in(e.response?.data?.details??{}),Tt=e=>`applicationError`in(e.response?.data?.details??{}),Et=e=>(e.response?.status??-1)>=400&&(e.response?.status??-1)<500;function F(e,t={explicitPathsToArguments:{},spreadPathsToArguments:{},singleArgumentUnchanged:!1},n=[]){if(typeof e!=`object`||!e)throw e;if(wt(e))return Dt(e,t,n);if(Tt(e))return kt(e);if(Et(e)){let t=e.response?.status,n=e.response?.statusText??`UNKNOWN`,r=e.response?.data?.message??n,i={applicationError:{description:n,code:vt(n),data:{}},requestId:e.requestId};return Ot(e,{message:JSON.stringify({message:r,details:i},null,2),extraProperties:{details:i,status:t}})}return At(e)}var Dt=(e,t,n)=>{let r=e.response?.data,i=e.requestId,{fieldViolations:a}=r.details.validationError,o=jt(t,a,n)?.sort((e,t)=>e.field<t.field?-1:1),s=`INVALID_ARGUMENT: ${o?.map(({field:e,description:t})=>`"${e}" ${t}`)?.join(`, `)}`,c={validationError:{fieldViolations:o},requestId:i};return Ot(e,{message:JSON.stringify({message:s,details:c},null,2),extraProperties:{details:c,status:e.response?.status,requestId:i}})},Ot=(e,{message:t,extraProperties:n})=>Object.assign(e,{...n,message:t}),kt=e=>{let t=e.response?.status,n=e.response?.statusText??`UNKNOWN`,r=e.response?.data?.message??n,i=e.response?.data?.details?.applicationError?.description??n,a=e.response?.data?.details?.applicationError?.code??vt(n),o=e.response?.data?.details?.applicationError?.data??{},s=r===i?r:`${r}: ${i}`,c={applicationError:{description:i,code:a,data:o},requestId:e.requestId};return Ot(e,{message:JSON.stringify({message:s,details:c},null,2),extraProperties:{details:c,status:t,requestId:e.requestId}})},At=e=>Ot(e,{message:e.requestId?`System error occurred, request-id: ${e.requestId}`:`System error occurred: ${JSON.stringify(e)}`,extraProperties:{requestId:e.requestId,status:e.response?.status,code:vt(e.response?.statusText??`UNKNOWN`),...!e.response&&{runtimeError:e}}}),jt=({spreadPathsToArguments:e,explicitPathsToArguments:t,singleArgumentUnchanged:n},r,i)=>{let a={...e,...t},o=Object.keys(a);return r?.filter(e=>!r.some(t=>t.field.length>e.field.length&&t.field.startsWith(e.field)&&o.includes(t.field))).map(e=>{let r=t[e.field];if(r)return{...e,field:Mt(r,i)};let s=o?.sort((e,t)=>t.length-e.length)?.find(t=>e.field.startsWith(t));if(s){let t=a[s];if(t)return{...e,field:e.field.replace(s,Mt(t,i))}}return n?{...e,field:`${i[0]}.${e.field}`}:e})},Mt=(e,t)=>{let n=Nt(e);return n==null?e:e.replace(`$[${n}]`,t[n])},Nt=e=>{let t=e.match(/\$\[(?<argIndex>\d+)\]/);return t&&t.groups&&Number(t.groups.argIndex)};function Pt(){let e=typeof $wixContext<`u`&&$wixContext.initWixModules?$wixContext.initWixModules:globalThis.__wix_context__!==void 0&&globalThis.__wix_context__.initWixModules?globalThis.__wix_context__.initWixModules:void 0;if(e)return{initWixModules(t,n){return Ft(()=>e(t,n))},fetchWithAuth(){throw Error(`fetchWithAuth is not available in this context`)},graphql(){throw Error(`graphql is not available in this context`)}};let t=typeof $wixContext<`u`?$wixContext.client:v.client===void 0?globalThis.__wix_context__===void 0?void 0:globalThis.__wix_context__.client:v.client,n=typeof $wixContext<`u`?$wixContext.elevatedClient:v.elevatedClient===void 0?globalThis.__wix_context__===void 0?void 0:globalThis.__wix_context__.elevatedClient:v.elevatedClient;if(t||n)return{initWixModules(e,r){if(r){if(!n)throw Error(`An elevated client is required to use elevated modules. Make sure to initialize the Wix context with an elevated client before using elevated SDK modules`);return Ft(()=>n.use(e))}if(!t)throw Error(`Wix context is not available. Make sure to initialize the Wix context before using SDK modules`);return Ft(()=>t.use(e))},fetchWithAuth:(e,n)=>{if(!t)throw Error(`Wix context is not available. Make sure to initialize the Wix context before using SDK modules`);return t.fetchWithAuth(e,n)},getAuth(){if(!t)throw Error(`Wix context is not available. Make sure to initialize the Wix context before using SDK modules`);return t.auth},async graphql(e,n,r){if(!t)throw Error(`Wix context is not available. Make sure to initialize the Wix context before using SDK modules`);return t.graphql(e,n,r)}}}function Ft(e){let t=globalThis.__wix_context__,n={client:v.client,elevatedClient:v.elevatedClient},r;globalThis.__wix_context__=void 0,v.client=void 0,v.elevatedClient=void 0,typeof $wixContext<`u`&&(r={client:$wixContext?.client,elevatedClient:$wixContext?.elevatedClient},delete $wixContext.client,delete $wixContext.elevatedClient);try{return e()}finally{globalThis.__wix_context__=t,v.client=n.client,v.elevatedClient=n.elevatedClient,typeof $wixContext<`u`&&($wixContext.client=r.client,$wixContext.elevatedClient=r.elevatedClient)}}function It(e,t){return((...n)=>{let r=Pt();return r?r.initWixModules(e,t).apply(void 0,n):e.apply(void 0,n)})}function Lt(e){let t=((...t)=>{let n=Pt();return n?n.initWixModules(e).apply(void 0,t):()=>({slug:e.type})});return t.__type=e.__type,t.type=e.type,t.isDomainEvent=e.isDomainEvent,t.transformations=e.transformations,t}function I(e,t=!1){return It(e,t)}function Rt(e,t){let n=zt(e),r=Object.entries(n).some(([e,t])=>e.includes(`.`)||Array.isArray(t)&&t.some(e=>typeof e==`object`));return t&&r?new URLSearchParams({".r":Vt(JSON.stringify(e))}):Object.entries(n).reduce((e,[t,n])=>((Array.isArray(n)?n:[n]).forEach(r=>{r==null||Array.isArray(n)&&typeof r==`object`||e.append(t,r)}),e),new URLSearchParams)}function L(e){let t=en(Qt(e.host),e.domainToMappings);return un(sn(e.protoPath,e.data||{}),t)}function zt(e,t=``){let n={};return Object.entries(e).forEach(([e,r])=>{let i=typeof r==`object`&&!!r&&!Array.isArray(r),a=Bt(t,e);if(i){let e=zt(r,a);Object.assign(n,e)}else n[a]=r}),n}function Bt(e,t){return`${e}${e?`.`:``}${t}`}var Vt=e=>{let t=new TextEncoder().encode(e);return(typeof btoa<`u`?btoa(String.fromCodePoint(...t)):Buffer.from(e,`utf-8`).toString(`base64`)).replace(/=/g,``).replace(/\+/g,`-`).replace(/\//g,`_`)},Ht=[`wix.com`,`editorx.com`],Ut=`_`,Wt=`*.`,Gt=RegExp(`\\.(${Ht.join(`|`)})$`),Kt=[`42.wixprod.net`,`uw2-edt-1.wixprod.net`,`virginia-edt.wixprod.net`],qt={"payments.base44.com":`manage.wix.com`,"create.editorx.com":`editor.editorx.com`},Jt=`dev.wix-code.com`,Yt=/{(.*)}/,Xt=RegExp(`\\.(${Kt.join(`|`)})$`),Zt=RegExp(`.*\\.${Jt}$`);function Qt(e){return $t(e).replace(Gt,`._base_domain_`).replace(Xt,`._api_base_domain_`).replace(Zt,`*.dev.wix-code.com`)}function $t(e){return qt[e]??e}function en(e,t){let n=t[e];if(n)return n;let r=tn(e,t)??nn(e,t);if(!r){if(an(e)){let e=t[on];if(e)return e}let n=t[Ut];if(n)return n}return r??[]}function tn(e,t){return Object.entries(t).find(([t])=>{let[,...n]=e.split(`.`);return n.join(`.`)===t})?.[1]}function nn(e,t){let[n]=Object.entries(t).filter(([t])=>rn(e,t)).sort(([e],[t])=>t.length-e.length);if(!n)return;let[,r]=n;return r}function rn(e,t){if(!t.startsWith(Wt))return!1;let n=t.slice(1);return e.length>n.length&&e.endsWith(n)}function an(e){return!!e.match(/\._base_domain_$/)}var on=`www._base_domain_`;function sn(e,t){return e.split(`/`).map(e=>cn(e,t)).join(`/`)}function cn(e,t){let n=e.match(Yt)||[],r=n[1];return r?ln(t,r,e,e.replace(n[0],``)):e}function ln(e,t,n,r){let i=e;for(let e of t.split(`.`)){if(!i)return n;i=i[e]}return`${i}${r}`}function un(e,t){let n=t?.find(t=>e.startsWith(t.destPath));return n?n.srcPath+e.slice(n.destPath.length):e}function R(e){return Lt(e)}function dn(e){return isFinite(e)?e:e.toString()}function z(e){return e===`NaN`?NaN:e===`Infinity`?1/0:e===`-Infinity`?-1/0:e}function fn(e){return e&&_t({city:e.city,hint:e.hint,subdivision:e.subdivision,country:e.country,postalCode:e.postalCode,formattedAddress:e.formatted,geocode:e.location,addressLine:e.addressLine1,addressLine2:e.addressLine2,streetAddress:e.streetAddress&&{name:e.streetAddress.name,number:e.streetAddress.number,apt:e.streetAddress.apt,formattedAddressLine:e.streetAddress.formattedAddressLine}})}function pn(e){return e&&_t({formatted:e.formattedAddress,location:e.geocode,addressLine1:e.addressLine,addressLine2:e.addressLine2,streetAddress:e.streetAddress&&{name:e.streetAddress.name,number:e.streetAddress.number,apt:e.streetAddress.apt,formattedAddressLine:e.streetAddress.formattedAddressLine},hint:e.hint,city:e.city,subdivision:e.subdivision,country:e.country,postalCode:e.postalCode,countryFullname:e.countryFullname,subdivisionFullname:e.subdivisionFullname})}var mn=`x-wix-linguist`,hn=`00000000-0000-0000-0000-000000000000`,gn=`false`,_n=()=>{let e=bn(`language`),t=bn(`locale`);if(e)return{[mn]:[e,t||e,gn,hn].join(`|`)}};function vn(){let e=null,t=null;return{promise:new Promise((n,r)=>{e=n,t=r}),resolve:e,reject:t}}var yn=()=>(typeof window<`u`?window.commonConfig:void 0)??globalThis.commonConfig,bn=e=>yn()?.[e],xn=({createHost:e})=>({__type:`host`,create:e=>({}),host:t=>{let{applicationId:n,componentId:r}=t??{},i=typeof window<`u`?window.wixEmbedsAPI:void 0,a=e(t),o=Cn();return{...a,apiBaseUrl:o,getMonitoringClient:i?.getMonitoringClientFunction?.(n,r),essentials:{language:bn(`language`),locale:bn(`locale`),get passThroughHeaders(){return _n()}}}},auth:e=>{let t=typeof window<`u`?window.wixEmbedsAPI:void 0;!e&&Sn()&&(e=t?.getAccessTokenFunction?.());let n=!1,{resolve:r,promise:i}=vn();return{getAuthHeaders:async()=>{if(!e&&n&&(e=await i),!e)throw Error(`Failed to resolve auth token`);return{headers:{Authorization:await e()}}},getAccessTokenInjector:()=>(n=!0,e=>{r(e)})}}});function Sn(){return typeof document<`u`&&document.currentScript?.tagName===`SCRIPT`}function Cn(){let e=(typeof window<`u`?window.wixEmbedsAPI:void 0)?.getExternalBaseUrl?.();if(!e)return;let t=new URL(e);return t?.pathname&&t.pathname!==`/`?`${t.hostname}${t.pathname}`:t.hostname}var wn=({clientSdk:e,applicationId:t})=>({invoke:async({namespace:n,method:r,args:i})=>{if(!e)throw Error(`Wix Site SDK only works in a Wix site environment. Learn more: https://dev.wix.com/docs/sdk/host-modules/site/introduction`);return e.invoke({namespace:n,method:r,args:i,applicationId:t,accessToken:`accessToken`})},getAccessToken:()=>{throw Error(`Not implemented`)},observeState:()=>({disconnect:()=>{}})}),Tn=xn({createHost:function(e){let t=(typeof $wixContext<`u`?$wixContext.clientSdk:void 0)??e?.clientSdk??(typeof window<`u`?window?.clientSdk:void 0),{applicationId:n}=e||{};if(!n)throw Error(`"createHost" was called without a required field "applicationId"`);return{channel:wn({clientSdk:t,applicationId:n}),close:()=>{}}}}),En=(e,t)=>{let n=Tn.host({applicationId:e,componentId:t}),r=Tn.auth();return Ue({auth:r,host:n}).enableContext(`module`),r.getAccessTokenInjector()},Dn=e=>En(`215238eb-22a5-4c36-9e7b-e7c08025e04e`,e);function On(e){return Object.keys(e).length===1&&`$and`in e&&Array.isArray(e.$and)}function kn(e){return Object.keys(e).length===1&&`$or`in e&&Array.isArray(e.$or)}function An(e){return Object.keys(e).length===1&&`$not`in e&&typeof e.$not==`object`}function B(e,t){return e===void 0||Object.keys(e).length===0?t:t===void 0||Object.keys(t).length===0?e:{$and:[...On(e)?e.$and:[e],...On(t)?t.$and:[t]]}}function jn(e,t){return e===void 0||Object.keys(e).length===0?t:t===void 0||Object.keys(t).length===0?e:{$or:[...kn(e)?e.$or:[e],...kn(t)?t.$or:[t]]}}function Mn(e){if(e!==void 0&&Object.keys(e).length!==0)return An(e)?e.$not:{$not:e}}var Nn=class{_items;_fetchNextPage;_fetchPrevPage;_originQuery;_limit;constructor({items:e,originQuery:t,fetchNextPage:n,fetchPrevPage:r,limit:i}){this._items=e,this._fetchNextPage=n,this._fetchPrevPage=r,this._originQuery=t,this._limit=i}get items(){return this._items}get length(){return this._items.length}get pageSize(){return this._limit}get query(){return this._originQuery}async next(){if(!this.hasNext())throw Error(`No next page to fetch`);return await this._fetchNextPage()}async prev(){if(!this.hasPrev())throw Error(`No previous page to fetch`);return await this._fetchPrevPage()}},Pn=class extends Nn{_nextCursor;_prevCursor;cursors;constructor({items:e,originQuery:t,fetchNextPage:n,fetchPrevPage:r,limit:i,nextCursor:a,prevCursor:o}){super({items:e,originQuery:t,fetchNextPage:n,fetchPrevPage:r,limit:i}),this._nextCursor=a,this._prevCursor=o,this.cursors={next:a,prev:o}}hasNext(){return!!this._nextCursor}hasPrev(){return!!this._prevCursor}},Fn=class extends Nn{_totalCount;_offset;_tooManyToCount;constructor({items:e,fetchNextPage:t,fetchPrevPage:n,offset:r,originQuery:i,limit:a,totalCount:o,tooManyToCount:s}){super({items:e,fetchNextPage:t,fetchPrevPage:n,originQuery:i,limit:a}),this._totalCount=o,this._offset=r,this._tooManyToCount=s}get currentPage(){return this._limit===0?void 0:Math.floor(this._offset/this._limit)}get totalPages(){return this._tooManyToCount||this._limit===0?void 0:Math.ceil(this._totalCount/this._limit)}get totalCount(){return this._tooManyToCount?void 0:this._totalCount}hasNext(){return this._limit!==0&&this.currentPage!==void 0&&this.totalPages!==void 0&&this.currentPage<this.totalPages-1}hasPrev(){return!!(this._limit!==0&&this.currentPage&&this.currentPage>0)}};function In(e){let t=n=>({query:n,async find(){try{let r=e.requestTransformer(e.pagingMethod===`CURSOR`&&n.cursorPaging.cursor?{cursorPaging:n.cursorPaging}:n),i=await e.func(r),{[Je]:a,[Ye]:o}=e.responseTransformer(i);if(e.pagingMethod===`OFFSET`){let e=n;return new Fn({items:a??[],fetchNextPage:()=>t({...e,paging:{offset:e.paging.offset+e.paging.limit,limit:e.paging.limit}}).find(),fetchPrevPage:()=>t({...n,paging:{offset:Math.max(e.paging.offset-e.paging.limit,0),limit:e.paging.limit}}).find(),offset:e.paging.offset,limit:e.paging.limit,totalCount:o?.total,tooManyToCount:o?.tooManyToCount,originQuery:this})}let s=n.cursorPaging;return new Pn({items:a??[],limit:s.limit,originQuery:this,fetchNextPage:()=>t({...n,cursorPaging:{cursor:o?.cursors?.next??void 0,limit:s.limit}}).find(),fetchPrevPage:()=>t({...n,cursorPaging:{cursor:o?.cursors?.prev??void 0,limit:s.limit}}).find(),prevCursor:o?.cursors?.prev??void 0,nextCursor:o?.cursors?.next??void 0})}catch(t){throw e.errorTransformer(t)}},skipTo(e){return t({...n,cursorPaging:{cursor:e,limit:n.cursorPaging.limit}})},eq(r,i){let a=i===void 0?null:i,o={[V(e.transformationPaths,r)]:a};return t({...n,filter:B(n.filter,o)})},ne(r,i){let a=i===void 0?null:i,o={[V(e.transformationPaths,r)]:{$ne:a}};return t({...n,filter:B(n.filter,o)})},ge(r,i){let a={[V(e.transformationPaths,r)]:{$gte:i}};return t({...n,filter:B(n.filter,a)})},gt(r,i){let a={[V(e.transformationPaths,r)]:{$gt:i}};return t({...n,filter:B(n.filter,a)})},le(r,i){let a={[V(e.transformationPaths,r)]:{$lte:i}};return t({...n,filter:B(n.filter,a)})},lt(r,i){let a={[V(e.transformationPaths,r)]:{$lt:i}};return t({...n,filter:B(n.filter,a)})},isNotEmpty(e){return this.ne(e,null)},isEmpty(e){return this.eq(e,null)},startsWith(r,i){let a={[V(e.transformationPaths,r)]:{$startsWith:i}};return t({...n,filter:B(n.filter,a)})},endsWith(r,i){let a={[V(e.transformationPaths,r)]:{$endsWith:i}};return t({...n,filter:B(n.filter,a)})},contains(r,i){let a={[V(e.transformationPaths,r)]:{$contains:i}};return t({...n,filter:B(n.filter,a)})},hasSome(r,...i){let a={[V(e.transformationPaths,r)]:{$hasSome:Array.isArray(i[0])?i[0]:i}};return t({...n,filter:B(n.filter,a)})},hasAll(r,...i){let a={[V(e.transformationPaths,r)]:{$hasAll:Array.isArray(i[0])?i[0]:i}};return t({...n,filter:B(n.filter,a)})},between(e,t,n){return this.ge(e,t).lt(e,n)},in(r,i){let a={[V(e.transformationPaths,r)]:{$in:i}};return t({...n,filter:B(n.filter,a)})},exists(r,i=!0){let a={[V(e.transformationPaths,r)]:{$exists:i}};return t({...n,filter:B(n.filter,a)})},or(e){return t({...n,filter:jn(n.filter,e.query.filter)})},and(e){return t({...n,filter:B(n.filter,e.query.filter)})},not(e){return t({...n,filter:Mn(e.query.filter)})},ascending(...r){return t({...n,sort:[...n.sort??[],...r.map(t=>({fieldName:V(e.transformationPaths,t),order:`ASC`}))]})},descending(...r){return t({...n,sort:[...n.sort??[],...r.map(t=>({fieldName:V(e.transformationPaths,t),order:`DESC`}))]})},skip(e){return t({...n,paging:{offset:e,limit:`limit`in n.paging?n.paging.limit:50}})},limit(r){if(e.pagingMethod===`CURSOR`){let e=n;return t({...n,cursorPaging:{limit:r,cursor:`cursor`in e.cursorPaging?e.cursorPaging.cursor:void 0}})}let i=n;return t({...n,paging:{limit:r,offset:`offset`in i.paging?i.paging.offset:0}})}});return t({filter:{},...e.pagingMethod===`OFFSET`?{paging:{offset:0,limit:50}}:{cursorPaging:{limit:50}}})}function V(e,t){let n=Object.entries(e).find(([e])=>e===t||t.startsWith(`${e}.`))?.[0];return n?t.replace(n,e[n]):Ze(t,{...e,...Xe})}function Ln(e,t,n={}){let r=(r,i)=>Ln(e,t,{...n,[r]:i}),i=()=>Object.keys(n).length===0?{}:{[Qe(e,t)]:n};return{get filter(){return i()},eq:e=>r(`$eq`,e),ne:e=>r(`$ne`,e),gt:e=>r(`$gt`,e),gte:e=>r(`$gte`,e),lt:e=>r(`$lt`,e),lte:e=>r(`$lte`,e),startsWith:e=>r(`$startsWith`,e),endsWith:e=>r(`$endsWith`,e),contains:e=>r(`$contains`,e),in:e=>r(`$in`,e),nin:e=>r(`$nin`,e),hasSome:e=>r(`$hasSome`,e),hasAll:e=>r(`$hasAll`,e),exists:(e=!0)=>r(`$exists`,e),isEmpty:(e=!0)=>r(`$isEmpty`,e),isNotEmpty:()=>r(`$ne`,null)}}function Rn(e){return Object.assign(t=>Ln(t,e),{and:(...e)=>({filter:{$and:e.map(e=>e.filter)}}),or:(...e)=>({filter:{$or:e.map(e=>e.filter)}}),not:e=>({filter:{$not:e.filter}})})}function zn(e){return(t=>({asc:()=>({sort:{fieldName:Qe(t,e),order:`ASC`}}),desc:()=>({sort:{fieldName:Qe(t,e),order:`DESC`}})}))}function Bn(e){return()=>{let t={},n={withFilter(e){return t={...t,filter:e.filter},n},withFields(...r){return t={...t,fields:r.map(t=>Qe(t,e))},n},withSorting(...e){return t={...t,sort:e.map(e=>e.sort)},n},withPaging(e){return t={...t,paging:e},n},build(){return t}};return n}}function Vn(e){return{QueryBuilder:Bn(e),Filter:Rn(e),Sort:zn(e)}}var Hn=`filter`,Un=`sort`,Wn=`cursorPaging`,Gn=`paging`,Kn=[Hn,Un,Wn],qn=[Hn,Un,Gn];function Jn(e,t){return!e||typeof e!=`object`?!1:t.some(t=>e.hasOwnProperty(t))}function Yn(e){return Jn(e,Kn)}function Xn(e){return Jn(e,qn)}function Zn(e){let{hasOptionsParameter:t}=e;return function(...n){return t?$n(n,e):Qn(n,e)}}function Qn(e,t){return e.length===0?t.builderQueryFunction():t.typedQueryFunction(e[0])}function $n(e,t){switch(e.length){case 0:return t.builderQueryFunction();case 1:return Yn(e[0])||Xn(e[0])?t.typedQueryFunction(e[0]):t.builderQueryFunction(e[0]);default:return t.typedQueryFunction(e[0],e[1])}}function er(e){if(!e)return;let t=gt(e,`image`),{protocol:n,hash:r,pathname:i}=new URL(t),a=new URLSearchParams(r.replace(`#`,``)),o=a.get(`originHeight`),s=a.get(`originWidth`),[c,l]=i.replace(`image://v1/`,``).split(`/`),u=decodeURIComponent(l);if(n===`wix:`){let t={id:c,height:Number(o),width:Number(s)};return u?{...t,altText:u,filename:u,url:e}:t}return{url:e}}function H(e){if(!e)return;let t=``;return(e.filename||e.altText)&&(t=`/${encodeURIComponent(e.filename||e.altText)}`),e.id?`wix:image://v1/${e.id}${t}#originWidth=${e.width}&originHeight=${e.height}`:e.url}function tr(e){if(!e)return;let t=``;e?.filename&&(t=`/${encodeURIComponent(e.filename)}`);let n=``;if(e.posters?.length){let[t,r]=e.posters,i=r||t,a=i.id||``;if(!a&&i.url){let e=i.url.lastIndexOf(`/`);e!==-1&&(a=i.url.substring(e+1))}a&&(n=`#posterUri=${a}&posterWidth=${i.width}&posterHeight=${i.height}`)}return e.id?`wix:video://v1/${e.id}${t}${n}`:e.url}function nr(e){let t={},n={get search(){return t},expression(e){return t={...t,expression:e},n},mode(e){return t={...t,mode:e},n},fields(r){return t={...t,fields:r.map(t=>Qe(t,e))},n},fuzzy(e=!0){return t={...t,fuzzy:e},n}};return n}function rr(e){return t=>{let n=nr(e);return t===void 0?n:n.expression(t)}}function ir(e){let t={...e,type:`VALUE`,value:{...e.value}},n={get aggregation(){return t},sortBy(e,r){return t={...t,value:{...t.value,sortType:e,sortDirection:r}},n},limit(e){return t={...t,value:{...t.value,limit:e}},n},excludeMissingValues(){return t={...t,value:{...t.value,missingValues:`EXCLUDE`}},n},includeMissingValues(){return t={...t,value:{...t.value,missingValues:`INCLUDE`}},n},includeValues(e){return t={...t,value:{...t.value,includeOptions:{addToBucket:e}}},n}};return n}function ar(e){let t={...e,type:`RANGE`,range:{buckets:[]}},n={get aggregation(){return t},withBuckets(...e){return t={...t,range:{buckets:e}},n}};return n}function or(e){let t={...e,type:`DATE_HISTOGRAM`,dateHistogram:{}},n={get aggregation(){return t},interval(e){return t={...t,dateHistogram:{interval:e}},n}};return n}function sr(e){let t={...e,type:`SCALAR`,scalar:{}},n={get aggregation(){return t},type(e){return t={...t,scalar:{type:e}},n}};return n}function cr(e){let t={...e,type:`NESTED`,nested:{nestedAggregations:[]}},n={get aggregation(){return t},addNestedAggregation(e){let r=e.aggregation,i=[...t.nested?.nestedAggregations??[],r];return t={...t,nested:{nestedAggregations:i}},n}};return n}function lr(e,t){let n={name:e},r={get aggregation(){return n},ofType(e){return n={...n,type:e},r},onField(e){return n={...n,fieldPath:Qe(e,t)},r},asValueAggregation(){return ir(n)},asRangeAggregation(){return ar(n)},asDateHistogramAggregation(){return or(n)},asScalarAggregation(){return sr(n)},asNestedAggregation(){return cr(n)}};return r}function ur(e){return t=>lr(t,e)}function dr(){return()=>{let e={},t={withFilter(n){return e={...e,filter:n.filter},t},withSearchClause(n){return e={...e,search:n.search},t},withSorting(...n){return e={...e,sort:n.map(e=>e.sort)},t},withAggregation(...n){return e={...e,aggregations:n.map(e=>e.aggregation)},t},withPaging(n){return e={...e,paging:n},t},withTimeZone(n){return e={...e,timeZone:n},t},build(){return e}};return t}}function fr(e){return{SearchBuilder:dr(),Filter:Rn(e),Sort:zn(e),SearchParams:rr(e),Aggregation:ur(e)}}function pr(e){return L(Object.assign(e,{domainToMappings:{"manage._base_domain_":[{srcPath:`/inventory`,destPath:``}],"api._api_base_domain_":[{srcPath:`/inventory`,destPath:``}],_:[{srcPath:`/_api/inventory`,destPath:``}],"editor._base_domain_":[{srcPath:`/_api/inventory`,destPath:``}],"blocks._base_domain_":[{srcPath:`/_api/inventory`,destPath:``}],"create.editorx":[{srcPath:`/_api/inventory`,destPath:``}],"www.wixapis.com":[{srcPath:`/stores/v3/inventory-items`,destPath:`/v3/inventory-items`},{srcPath:`/stores/v3/bulk/inventory-items`,destPath:`/v3/bulk/inventory-items`}],"*.dev.wix-code.com":[{srcPath:`/_api/inventory`,destPath:``}],"editor.wixapps.net":[{srcPath:`/_api/inventory`,destPath:``}]}}))}var mr=`@wix/auto_sdk_stores_inventory-items-v-3`;function hr(e){function t({host:t}){return{entityFqdn:`wix.stores.catalog.v3.inventory_item`,method:`GET`,methodFqn:`com.wix.stores.catalog.inventory.api.v3.InventoryService.QueryInventoryItems`,packageName:mr,migrationOptions:{optInTransformResponse:!0},url:pr({protoPath:`/v3/inventory-items/query`,data:e,host:t}),params:Rt(e,!0),transformResponse:e=>P(e,[{transformFn:N,paths:[{path:`inventoryItems.createdDate`},{path:`inventoryItems.updatedDate`}]}]),fallback:[{method:`POST`,url:pr({protoPath:`/v3/inventory-items/query`,data:e,host:t}),data:e}]}}return t}var gr=(e=>(e.OUT_OF_STOCK=`OUT_OF_STOCK`,e.IN_STOCK=`IN_STOCK`,e.PREORDER=`PREORDER`,e))(gr||{});function _r(){let{httpClient:e,sideEffects:t}=arguments[0];return In({func:async n=>{let r=hr(n);t?.onSiteCall?.();try{let n=await e.request(r);return t?.onSuccess?.(n),n}catch(e){throw t?.onError?.(e),e}},requestTransformer:e=>{let t=[e,{}];return j({...t?.[1],query:t?.[0]})},responseTransformer:({data:e})=>{let t=M(P(e,[]));return{items:t?.inventoryItems,pagingMetadata:t?.pagingMetadata}},errorTransformer:e=>{throw F(e,{spreadPathsToArguments:{},explicitPathsToArguments:{query:`$[0]`},singleArgumentUnchanged:!1})},pagingMethod:`CURSOR`,transformationPaths:{}})}async function vr(e){let{httpClient:t,sideEffects:n}=arguments[1],r=hr(j({query:e}));n?.onSiteCall?.();try{let e=await t.request(r);return n?.onSuccess?.(e),M(e.data)}catch(e){let t=F(e,{spreadPathsToArguments:{},explicitPathsToArguments:{query:`$[0]`},singleArgumentUnchanged:!1},[`query`]);throw n?.onError?.(e),t}}({...Vn()}),{...fr()};function yr(e){return()=>_r({httpClient:e})}function br(e){return t=>vr(t,{httpClient:e})}var xr=y(`wix.stores.catalog.v3.inventory_item_created`,!0,e=>M(P(e,[{transformFn:N,paths:[{path:`entity.createdDate`},{path:`entity.updatedDate`},{path:`metadata.eventTime`}]}])))(),Sr=y(`wix.stores.catalog.v3.inventory_item_deleted`,!0,e=>M(P(e,[{transformFn:N,paths:[{path:`entity.createdDate`},{path:`entity.updatedDate`},{path:`metadata.eventTime`}]}])))(),Cr=y(`wix.stores.catalog.v3.inventory_item_stock_status_updated`,!0,e=>M(P(e,[{transformFn:N,paths:[{path:`metadata.eventTime`}]}])))(),wr=y(`wix.stores.catalog.v3.inventory_item_updated`,!0,e=>M(P(e,[{transformFn:N,paths:[{path:`entity.createdDate`},{path:`entity.updatedDate`},{path:`metadata.eventTime`},{path:`modifiedFields.createdDate`},{path:`modifiedFields.updatedDate`}]}])))(),Tr=y(`wix.stores.catalog.v3.inventory_item_updated_with_reason`,!0,e=>M(P(e,[{transformFn:N,paths:[{path:`data.currentEntity.createdDate`},{path:`data.currentEntity.updatedDate`},{path:`metadata.eventTime`}]}])))();function Er(e){let t=Zn({builderQueryFunction:()=>yr(e)(),typedQueryFunction:t=>br(e)(t),hasOptionsParameter:!1});function n(e){return t(...arguments)}return n}var Dr=I(Er);R(xr),R(Sr),R(Cr),R(wr),R(Tr);function Or(e){if(!e)return;let{pathname:t}=new URL(e);return{relativePath:t,url:e}}function U(e){if(e)return e.url}function kr(e){return L(Object.assign(e,{domainToMappings:{"api._api_base_domain_":[{srcPath:`/stores-catalog-orchestrator`,destPath:``}],"manage._base_domain_":[{srcPath:`/stores`,destPath:``}],"www.wixapis.com":[{srcPath:`/stores/v3/products`,destPath:`/v3/products`},{srcPath:`/stores/v3/bulk/products`,destPath:`/v3/bulk/products`},{srcPath:`/stores/v3/products-with-inventory`,destPath:`/v3/products-with-inventory`},{srcPath:`/stores/v3/bulk/products-with-inventory`,destPath:`/v3/bulk/products-with-inventory`},{srcPath:`/stores/v3/all-products-category`,destPath:`/v3/all-products-category`}],"www._base_domain_":[{srcPath:`/_api/stores-catalog-orchestrator`,destPath:``}],"editor._base_domain_":[{srcPath:`/_api/stores-catalog-orchestrator`,destPath:``}],"blocks._base_domain_":[{srcPath:`/_api/stores-catalog-orchestrator`,destPath:``}],"create.editorx":[{srcPath:`/_api/stores-catalog-orchestrator`,destPath:``}],"editor.wixapps.net":[{srcPath:`/_api/stores-catalog-orchestrator`,destPath:``}],"*.dev.wix-code.com":[{srcPath:`/_api/stores-catalog-orchestrator`,destPath:``}],_:[{srcPath:`/_api/stores-catalog-orchestrator`,destPath:``}]}}))}var Ar=`@wix/auto_sdk_stores_products-v-3`;function jr(e){function t({host:t}){return{entityFqdn:`wix.stores.catalog.v3.product`,method:`GET`,methodFqn:`wix.stores.catalog.v3.CatalogApi.GetProduct`,packageName:Ar,migrationOptions:{optInTransformResponse:!0},url:kr({protoPath:`/v3/products/{productId}`,data:e,host:t}),params:Rt(e),transformResponse:e=>P(e,[{transformFn:N,paths:[{path:`product.createdDate`},{path:`product.updatedDate`},{path:`product.description.metadata.createdTimestamp`},{path:`product.description.metadata.updatedTimestamp`},{path:`product.media.main.image.urlExpirationDate`},{path:`product.media.main.video.urlExpirationDate`},{path:`product.media.main.video.resolutions.urlExpirationDate`},{path:`product.media.main.video.resolutions.poster.urlExpirationDate`},{path:`product.media.main.video.posters.urlExpirationDate`},{path:`product.media.itemsInfo.items.image.urlExpirationDate`},{path:`product.media.itemsInfo.items.video.urlExpirationDate`},{path:`product.media.itemsInfo.items.video.resolutions.urlExpirationDate`},{path:`product.media.itemsInfo.items.video.resolutions.poster.urlExpirationDate`},{path:`product.media.itemsInfo.items.video.posters.urlExpirationDate`},{path:`product.options.choicesSettings.choices.image.urlExpirationDate`},{path:`product.options.choicesSettings.choices.linkedMedia.image.urlExpirationDate`},{path:`product.options.choicesSettings.choices.linkedMedia.video.urlExpirationDate`},{path:`product.options.choicesSettings.choices.linkedMedia.video.resolutions.urlExpirationDate`},{path:`product.options.choicesSettings.choices.linkedMedia.video.resolutions.poster.urlExpirationDate`},{path:`product.options.choicesSettings.choices.linkedMedia.video.posters.urlExpirationDate`},{path:`product.options.choicesSettings.choices.displayImage.urlExpirationDate`},{path:`product.modifiers.choicesSettings.choices.image.urlExpirationDate`},{path:`product.modifiers.choicesSettings.choices.linkedMedia.image.urlExpirationDate`},{path:`product.modifiers.choicesSettings.choices.linkedMedia.video.urlExpirationDate`},{path:`product.modifiers.choicesSettings.choices.linkedMedia.video.resolutions.urlExpirationDate`},{path:`product.modifiers.choicesSettings.choices.linkedMedia.video.resolutions.poster.urlExpirationDate`},{path:`product.modifiers.choicesSettings.choices.linkedMedia.video.posters.urlExpirationDate`},{path:`product.modifiers.choicesSettings.choices.displayImage.urlExpirationDate`},{path:`product.infoSections.description.metadata.createdTimestamp`},{path:`product.infoSections.description.metadata.updatedTimestamp`},{path:`product.variantsInfo.variants.media.image.urlExpirationDate`},{path:`product.variantsInfo.variants.media.video.urlExpirationDate`},{path:`product.variantsInfo.variants.media.video.resolutions.urlExpirationDate`},{path:`product.variantsInfo.variants.media.video.resolutions.poster.urlExpirationDate`},{path:`product.variantsInfo.variants.media.video.posters.urlExpirationDate`},{path:`product.variantSummary.minPriceVariant.media.image.urlExpirationDate`},{path:`product.variantSummary.minPriceVariant.media.video.urlExpirationDate`},{path:`product.variantSummary.minPriceVariant.media.video.resolutions.urlExpirationDate`},{path:`product.variantSummary.minPriceVariant.media.video.resolutions.poster.urlExpirationDate`},{path:`product.variantSummary.minPriceVariant.media.video.posters.urlExpirationDate`}]},{transformFn:z,paths:[{path:`product.physicalProperties.pricePerUnit.quantity`},{path:`product.physicalProperties.shippingWeightRange.minValue`},{path:`product.physicalProperties.shippingWeightRange.maxValue`},{path:`product.variantsInfo.variants.physicalProperties.pricePerUnit.settings.quantity`},{path:`product.variantsInfo.variants.revenueDetails.profitMargin`},{path:`product.subscriptionDetails.subscriptions.discount.percentOff`},{path:`product.variantSummary.minPriceVariant.physicalProperties.pricePerUnit.settings.quantity`},{path:`product.variantSummary.minPriceVariant.revenueDetails.profitMargin`},{path:`product.minVariantPriceInfo.pricePerUnitData.settings.quantity`},{path:`product.minVariantPriceInfo.revenueDetails.profitMargin`},{path:`product.description.nodes.buttonData.styles.background.gradient.centerX`},{path:`product.description.nodes.buttonData.styles.background.gradient.centerY`},{path:`product.description.nodes.buttonData.styles.background.gradient.stops.position`},{path:`product.description.nodes.buttonData.styles.backgroundHover.gradient.centerX`},{path:`product.description.nodes.buttonData.styles.backgroundHover.gradient.centerY`},{path:`product.description.nodes.buttonData.styles.backgroundHover.gradient.stops.position`},{path:`product.description.nodes.galleryData.items.image.media.duration`},{path:`product.description.nodes.galleryData.items.video.media.duration`},{path:`product.description.nodes.galleryData.items.video.thumbnail.duration`},{path:`product.description.nodes.galleryData.options.item.ratio`},{path:`product.description.nodes.imageData.image.duration`},{path:`product.description.nodes.imageData.crop.x`},{path:`product.description.nodes.imageData.crop.y`},{path:`product.description.nodes.imageData.crop.width`},{path:`product.description.nodes.imageData.crop.height`},{path:`product.description.nodes.mapData.mapSettings.lat`},{path:`product.description.nodes.mapData.mapSettings.lng`},{path:`product.description.nodes.pollData.poll.image.duration`},{path:`product.description.nodes.pollData.poll.options.image.duration`},{path:`product.description.nodes.pollData.design.poll.background.image.duration`},{path:`product.description.nodes.appEmbedData.image.duration`},{path:`product.description.nodes.videoData.video.duration`},{path:`product.description.nodes.videoData.thumbnail.duration`},{path:`product.description.nodes.audioData.audio.duration`},{path:`product.description.nodes.audioData.coverImage.duration`},{path:`product.description.nodes.layoutData.backgroundImage.media.duration`},{path:`product.description.nodes.layoutData.backgroundImage.overlay.gradient.centerX`},{path:`product.description.nodes.layoutData.backgroundImage.overlay.gradient.centerY`},{path:`product.description.nodes.layoutData.backgroundImage.overlay.gradient.stops.position`},{path:`product.description.nodes.layoutData.backdropImage.media.duration`},{path:`product.description.nodes.layoutData.backdropImage.overlay.gradient.centerX`},{path:`product.description.nodes.layoutData.backdropImage.overlay.gradient.centerY`},{path:`product.description.nodes.layoutData.backdropImage.overlay.gradient.stops.position`},{path:`product.description.nodes.layoutData.background.gradient.centerX`},{path:`product.description.nodes.layoutData.background.gradient.centerY`},{path:`product.description.nodes.layoutData.background.gradient.stops.position`},{path:`product.description.nodes.layoutData.backdrop.gradient.centerX`},{path:`product.description.nodes.layoutData.backdrop.gradient.centerY`},{path:`product.description.nodes.layoutData.backdrop.gradient.stops.position`},{path:`product.description.nodes.shapeData.shape.duration`},{path:`product.description.nodes.cardData.background.gradient.centerX`},{path:`product.description.nodes.cardData.background.gradient.centerY`},{path:`product.description.nodes.cardData.background.gradient.stops.position`},{path:`product.description.nodes.cardData.backgroundImage.media.duration`},{path:`product.description.nodes.cardData.backgroundImage.overlay.gradient.centerX`},{path:`product.description.nodes.cardData.backgroundImage.overlay.gradient.centerY`},{path:`product.description.nodes.cardData.backgroundImage.overlay.gradient.stops.position`},{path:`product.description.nodes.tocData.fontSize`},{path:`product.description.nodes.tocData.itemSpacing`},{path:`product.description.nodes.smartBlockCellData.shape.duration`},{path:`product.infoSections.description.nodes.buttonData.styles.background.gradient.centerX`},{path:`product.infoSections.description.nodes.buttonData.styles.background.gradient.centerY`},{path:`product.infoSections.description.nodes.buttonData.styles.background.gradient.stops.position`},{path:`product.infoSections.description.nodes.buttonData.styles.backgroundHover.gradient.centerX`},{path:`product.infoSections.description.nodes.buttonData.styles.backgroundHover.gradient.centerY`},{path:`product.infoSections.description.nodes.buttonData.styles.backgroundHover.gradient.stops.position`},{path:`product.infoSections.description.nodes.galleryData.items.image.media.duration`},{path:`product.infoSections.description.nodes.galleryData.items.video.media.duration`},{path:`product.infoSections.description.nodes.galleryData.items.video.thumbnail.duration`},{path:`product.infoSections.description.nodes.galleryData.options.item.ratio`},{path:`product.infoSections.description.nodes.imageData.image.duration`},{path:`product.infoSections.description.nodes.imageData.crop.x`},{path:`product.infoSections.description.nodes.imageData.crop.y`},{path:`product.infoSections.description.nodes.imageData.crop.width`},{path:`product.infoSections.description.nodes.imageData.crop.height`},{path:`product.infoSections.description.nodes.mapData.mapSettings.lat`},{path:`product.infoSections.description.nodes.mapData.mapSettings.lng`},{path:`product.infoSections.description.nodes.pollData.poll.image.duration`},{path:`product.infoSections.description.nodes.pollData.poll.options.image.duration`},{path:`product.infoSections.description.nodes.pollData.design.poll.background.image.duration`},{path:`product.infoSections.description.nodes.appEmbedData.image.duration`},{path:`product.infoSections.description.nodes.videoData.video.duration`},{path:`product.infoSections.description.nodes.videoData.thumbnail.duration`},{path:`product.infoSections.description.nodes.audioData.audio.duration`},{path:`product.infoSections.description.nodes.audioData.coverImage.duration`},{path:`product.infoSections.description.nodes.layoutData.backgroundImage.media.duration`},{path:`product.infoSections.description.nodes.layoutData.backgroundImage.overlay.gradient.centerX`},{path:`product.infoSections.description.nodes.layoutData.backgroundImage.overlay.gradient.centerY`},{path:`product.infoSections.description.nodes.layoutData.backgroundImage.overlay.gradient.stops.position`},{path:`product.infoSections.description.nodes.layoutData.backdropImage.media.duration`},{path:`product.infoSections.description.nodes.layoutData.backdropImage.overlay.gradient.centerX`},{path:`product.infoSections.description.nodes.layoutData.backdropImage.overlay.gradient.centerY`},{path:`product.infoSections.description.nodes.layoutData.backdropImage.overlay.gradient.stops.position`},{path:`product.infoSections.description.nodes.layoutData.background.gradient.centerX`},{path:`product.infoSections.description.nodes.layoutData.background.gradient.centerY`},{path:`product.infoSections.description.nodes.layoutData.background.gradient.stops.position`},{path:`product.infoSections.description.nodes.layoutData.backdrop.gradient.centerX`},{path:`product.infoSections.description.nodes.layoutData.backdrop.gradient.centerY`},{path:`product.infoSections.description.nodes.layoutData.backdrop.gradient.stops.position`},{path:`product.infoSections.description.nodes.shapeData.shape.duration`},{path:`product.infoSections.description.nodes.cardData.background.gradient.centerX`},{path:`product.infoSections.description.nodes.cardData.background.gradient.centerY`},{path:`product.infoSections.description.nodes.cardData.background.gradient.stops.position`},{path:`product.infoSections.description.nodes.cardData.backgroundImage.media.duration`},{path:`product.infoSections.description.nodes.cardData.backgroundImage.overlay.gradient.centerX`},{path:`product.infoSections.description.nodes.cardData.backgroundImage.overlay.gradient.centerY`},{path:`product.infoSections.description.nodes.cardData.backgroundImage.overlay.gradient.stops.position`},{path:`product.infoSections.description.nodes.tocData.fontSize`},{path:`product.infoSections.description.nodes.tocData.itemSpacing`},{path:`product.infoSections.description.nodes.smartBlockCellData.shape.duration`},{path:`product.variantsInfo.variants.physicalProperties.weight`},{path:`product.variantSummary.minPriceVariant.physicalProperties.weight`},{path:`product.minVariantPriceInfo.weight`}]}])}}return t}var Mr=(e=>(e.FREE_TEXT=`FREE_TEXT`,e.TEXT_CHOICES=`TEXT_CHOICES`,e.SWATCH_CHOICES=`SWATCH_CHOICES`,e))(Mr||{}),Nr=(e=>(e.IN_STOCK=`IN_STOCK`,e.OUT_OF_STOCK=`OUT_OF_STOCK`,e.PARTIALLY_OUT_OF_STOCK=`PARTIALLY_OUT_OF_STOCK`,e))(Nr||{}),Pr=(e=>(e.ALL_VARIANTS=`ALL_VARIANTS`,e.NO_VARIANTS=`NO_VARIANTS`,e.SOME_VARIANTS=`SOME_VARIANTS`,e))(Pr||{}),W=(e=>(e.URL=`URL`,e.CURRENCY=`CURRENCY`,e.INFO_SECTION=`INFO_SECTION`,e.MERCHANT_DATA=`MERCHANT_DATA`,e.PLAIN_DESCRIPTION=`PLAIN_DESCRIPTION`,e.INFO_SECTION_PLAIN_DESCRIPTION=`INFO_SECTION_PLAIN_DESCRIPTION`,e.SUBSCRIPTION_PRICES_INFO=`SUBSCRIPTION_PRICES_INFO`,e.BREADCRUMBS_INFO=`BREADCRUMBS_INFO`,e.WEIGHT_MEASUREMENT_UNIT_INFO=`WEIGHT_MEASUREMENT_UNIT_INFO`,e.VARIANT_OPTION_CHOICE_NAMES=`VARIANT_OPTION_CHOICE_NAMES`,e.MEDIA_ITEMS_INFO=`MEDIA_ITEMS_INFO`,e.DESCRIPTION=`DESCRIPTION`,e.DIRECT_CATEGORIES_INFO=`DIRECT_CATEGORIES_INFO`,e.ALL_CATEGORIES_INFO=`ALL_CATEGORIES_INFO`,e.INFO_SECTION_DESCRIPTION=`INFO_SECTION_DESCRIPTION`,e.THUMBNAIL=`THUMBNAIL`,e.PRODUCT_CHOICES_MEDIA_REFERENCES=`PRODUCT_CHOICES_MEDIA_REFERENCES`,e.PRODUCT_CHOICES_DISPLAY_IMAGE=`PRODUCT_CHOICES_DISPLAY_IMAGE`,e.MIN_PRICE_VARIANT=`MIN_PRICE_VARIANT`,e.DISCOUNT_INFO=`DISCOUNT_INFO`,e))(W||{});async function Fr(e,t){let{httpClient:n,sideEffects:r}=arguments[2],i=jr(j({productId:e,fields:t?.fields},[]));r?.onSiteCall?.();try{let e=await n.request(i);return r?.onSuccess?.(e),M(P(e.data,[{transformFn:U,paths:[{path:`product.url`}]},{transformFn:H,paths:[{path:`product.media.main.image`},{path:`product.media.itemsInfo.items.image`},{path:`product.options.choicesSettings.choices.image`},{path:`product.options.choicesSettings.choices.displayImage`},{path:`product.options.choicesSettings.choices.linkedMedia.image`},{path:`product.modifiers.choicesSettings.choices.image`},{path:`product.modifiers.choicesSettings.choices.displayImage`},{path:`product.modifiers.choicesSettings.choices.linkedMedia.image`},{path:`product.variantsInfo.variants.media.image`},{path:`product.variantSummary.minPriceVariant.media.image`}]},{transformFn:tr,paths:[{path:`product.media.main.video`},{path:`product.media.itemsInfo.items.video`},{path:`product.options.choicesSettings.choices.linkedMedia.video`},{path:`product.modifiers.choicesSettings.choices.linkedMedia.video`},{path:`product.variantsInfo.variants.media.video`},{path:`product.variantSummary.minPriceVariant.media.video`}]}]),[`product.description`,`product.infoSections.description`])?.product}catch(e){let t=F(e,{spreadPathsToArguments:{},explicitPathsToArguments:{productId:`$[0]`,fields:`$[1].fields`},singleArgumentUnchanged:!1},[`productId`,`options`]);throw r?.onError?.(e),t}}({...fr()}),{...Vn()};function Ir(e){return(t,n)=>Fr(t,n,{httpClient:e})}var Lr=y(`wix.stores.catalog.v3.product_created`,!0,e=>M(P(e,[{transformFn:N,paths:[{path:`entity.createdDate`},{path:`entity.updatedDate`},{path:`entity.description.metadata.createdTimestamp`},{path:`entity.description.metadata.updatedTimestamp`},{path:`entity.infoSections.description.metadata.createdTimestamp`},{path:`entity.infoSections.description.metadata.updatedTimestamp`},{path:`metadata.eventTime`}]},{transformFn:U,paths:[{path:`entity.url`}]},{transformFn:z,paths:[{path:`entity.physicalProperties.pricePerUnit.quantity`},{path:`entity.physicalProperties.shippingWeightRange.minValue`},{path:`entity.physicalProperties.shippingWeightRange.maxValue`},{path:`entity.variantsInfo.variants.physicalProperties.pricePerUnit.settings.quantity`},{path:`entity.variantsInfo.variants.revenueDetails.profitMargin`},{path:`entity.subscriptionDetails.subscriptions.discount.percentOff`},{path:`entity.variantSummary.minPriceVariant.physicalProperties.pricePerUnit.settings.quantity`},{path:`entity.variantSummary.minPriceVariant.revenueDetails.profitMargin`},{path:`entity.minVariantPriceInfo.pricePerUnitData.settings.quantity`},{path:`entity.minVariantPriceInfo.revenueDetails.profitMargin`},{path:`entity.description.nodes.buttonData.styles.background.gradient.centerX`},{path:`entity.description.nodes.buttonData.styles.background.gradient.centerY`},{path:`entity.description.nodes.buttonData.styles.background.gradient.stops.position`},{path:`entity.description.nodes.buttonData.styles.backgroundHover.gradient.centerX`},{path:`entity.description.nodes.buttonData.styles.backgroundHover.gradient.centerY`},{path:`entity.description.nodes.buttonData.styles.backgroundHover.gradient.stops.position`},{path:`entity.description.nodes.galleryData.items.image.media.duration`},{path:`entity.description.nodes.galleryData.items.video.media.duration`},{path:`entity.description.nodes.galleryData.items.video.thumbnail.duration`},{path:`entity.description.nodes.galleryData.options.item.ratio`},{path:`entity.description.nodes.imageData.image.duration`},{path:`entity.description.nodes.imageData.crop.x`},{path:`entity.description.nodes.imageData.crop.y`},{path:`entity.description.nodes.imageData.crop.width`},{path:`entity.description.nodes.imageData.crop.height`},{path:`entity.description.nodes.mapData.mapSettings.lat`},{path:`entity.description.nodes.mapData.mapSettings.lng`},{path:`entity.description.nodes.pollData.poll.image.duration`},{path:`entity.description.nodes.pollData.poll.options.image.duration`},{path:`entity.description.nodes.pollData.design.poll.background.image.duration`},{path:`entity.description.nodes.appEmbedData.image.duration`},{path:`entity.description.nodes.videoData.video.duration`},{path:`entity.description.nodes.videoData.thumbnail.duration`},{path:`entity.description.nodes.audioData.audio.duration`},{path:`entity.description.nodes.audioData.coverImage.duration`},{path:`entity.description.nodes.layoutData.backgroundImage.media.duration`},{path:`entity.description.nodes.layoutData.backgroundImage.overlay.gradient.centerX`},{path:`entity.description.nodes.layoutData.backgroundImage.overlay.gradient.centerY`},{path:`entity.description.nodes.layoutData.backgroundImage.overlay.gradient.stops.position`},{path:`entity.description.nodes.layoutData.backdropImage.media.duration`},{path:`entity.description.nodes.layoutData.backdropImage.overlay.gradient.centerX`},{path:`entity.description.nodes.layoutData.backdropImage.overlay.gradient.centerY`},{path:`entity.description.nodes.layoutData.backdropImage.overlay.gradient.stops.position`},{path:`entity.description.nodes.layoutData.background.gradient.centerX`},{path:`entity.description.nodes.layoutData.background.gradient.centerY`},{path:`entity.description.nodes.layoutData.background.gradient.stops.position`},{path:`entity.description.nodes.layoutData.backdrop.gradient.centerX`},{path:`entity.description.nodes.layoutData.backdrop.gradient.centerY`},{path:`entity.description.nodes.layoutData.backdrop.gradient.stops.position`},{path:`entity.description.nodes.shapeData.shape.duration`},{path:`entity.description.nodes.cardData.background.gradient.centerX`},{path:`entity.description.nodes.cardData.background.gradient.centerY`},{path:`entity.description.nodes.cardData.background.gradient.stops.position`},{path:`entity.description.nodes.cardData.backgroundImage.media.duration`},{path:`entity.description.nodes.cardData.backgroundImage.overlay.gradient.centerX`},{path:`entity.description.nodes.cardData.backgroundImage.overlay.gradient.centerY`},{path:`entity.description.nodes.cardData.backgroundImage.overlay.gradient.stops.position`},{path:`entity.description.nodes.tocData.fontSize`},{path:`entity.description.nodes.tocData.itemSpacing`},{path:`entity.description.nodes.smartBlockCellData.shape.duration`},{path:`entity.infoSections.description.nodes.buttonData.styles.background.gradient.centerX`},{path:`entity.infoSections.description.nodes.buttonData.styles.background.gradient.centerY`},{path:`entity.infoSections.description.nodes.buttonData.styles.background.gradient.stops.position`},{path:`entity.infoSections.description.nodes.buttonData.styles.backgroundHover.gradient.centerX`},{path:`entity.infoSections.description.nodes.buttonData.styles.backgroundHover.gradient.centerY`},{path:`entity.infoSections.description.nodes.buttonData.styles.backgroundHover.gradient.stops.position`},{path:`entity.infoSections.description.nodes.galleryData.items.image.media.duration`},{path:`entity.infoSections.description.nodes.galleryData.items.video.media.duration`},{path:`entity.infoSections.description.nodes.galleryData.items.video.thumbnail.duration`},{path:`entity.infoSections.description.nodes.galleryData.options.item.ratio`},{path:`entity.infoSections.description.nodes.imageData.image.duration`},{path:`entity.infoSections.description.nodes.imageData.crop.x`},{path:`entity.infoSections.description.nodes.imageData.crop.y`},{path:`entity.infoSections.description.nodes.imageData.crop.width`},{path:`entity.infoSections.description.nodes.imageData.crop.height`},{path:`entity.infoSections.description.nodes.mapData.mapSettings.lat`},{path:`entity.infoSections.description.nodes.mapData.mapSettings.lng`},{path:`entity.infoSections.description.nodes.pollData.poll.image.duration`},{path:`entity.infoSections.description.nodes.pollData.poll.options.image.duration`},{path:`entity.infoSections.description.nodes.pollData.design.poll.background.image.duration`},{path:`entity.infoSections.description.nodes.appEmbedData.image.duration`},{path:`entity.infoSections.description.nodes.videoData.video.duration`},{path:`entity.infoSections.description.nodes.videoData.thumbnail.duration`},{path:`entity.infoSections.description.nodes.audioData.audio.duration`},{path:`entity.infoSections.description.nodes.audioData.coverImage.duration`},{path:`entity.infoSections.description.nodes.layoutData.backgroundImage.media.duration`},{path:`entity.infoSections.description.nodes.layoutData.backgroundImage.overlay.gradient.centerX`},{path:`entity.infoSections.description.nodes.layoutData.backgroundImage.overlay.gradient.centerY`},{path:`entity.infoSections.description.nodes.layoutData.backgroundImage.overlay.gradient.stops.position`},{path:`entity.infoSections.description.nodes.layoutData.backdropImage.media.duration`},{path:`entity.infoSections.description.nodes.layoutData.backdropImage.overlay.gradient.centerX`},{path:`entity.infoSections.description.nodes.layoutData.backdropImage.overlay.gradient.centerY`},{path:`entity.infoSections.description.nodes.layoutData.backdropImage.overlay.gradient.stops.position`},{path:`entity.infoSections.description.nodes.layoutData.background.gradient.centerX`},{path:`entity.infoSections.description.nodes.layoutData.background.gradient.centerY`},{path:`entity.infoSections.description.nodes.layoutData.background.gradient.stops.position`},{path:`entity.infoSections.description.nodes.layoutData.backdrop.gradient.centerX`},{path:`entity.infoSections.description.nodes.layoutData.backdrop.gradient.centerY`},{path:`entity.infoSections.description.nodes.layoutData.backdrop.gradient.stops.position`},{path:`entity.infoSections.description.nodes.shapeData.shape.duration`},{path:`entity.infoSections.description.nodes.cardData.background.gradient.centerX`},{path:`entity.infoSections.description.nodes.cardData.background.gradient.centerY`},{path:`entity.infoSections.description.nodes.cardData.background.gradient.stops.position`},{path:`entity.infoSections.description.nodes.cardData.backgroundImage.media.duration`},{path:`entity.infoSections.description.nodes.cardData.backgroundImage.overlay.gradient.centerX`},{path:`entity.infoSections.description.nodes.cardData.backgroundImage.overlay.gradient.centerY`},{path:`entity.infoSections.description.nodes.cardData.backgroundImage.overlay.gradient.stops.position`},{path:`entity.infoSections.description.nodes.tocData.fontSize`},{path:`entity.infoSections.description.nodes.tocData.itemSpacing`},{path:`entity.infoSections.description.nodes.smartBlockCellData.shape.duration`},{path:`entity.variantsInfo.variants.physicalProperties.weight`},{path:`entity.variantSummary.minPriceVariant.physicalProperties.weight`},{path:`entity.minVariantPriceInfo.weight`}]},{transformFn:H,paths:[{path:`entity.media.main.image`},{path:`entity.media.itemsInfo.items.image`},{path:`entity.options.choicesSettings.choices.image`},{path:`entity.options.choicesSettings.choices.displayImage`},{path:`entity.options.choicesSettings.choices.linkedMedia.image`},{path:`entity.modifiers.choicesSettings.choices.image`},{path:`entity.modifiers.choicesSettings.choices.displayImage`},{path:`entity.modifiers.choicesSettings.choices.linkedMedia.image`},{path:`entity.variantsInfo.variants.media.image`},{path:`entity.variantSummary.minPriceVariant.media.image`}]},{transformFn:tr,paths:[{path:`entity.media.main.video`},{path:`entity.media.itemsInfo.items.video`},{path:`entity.options.choicesSettings.choices.linkedMedia.video`},{path:`entity.modifiers.choicesSettings.choices.linkedMedia.video`},{path:`entity.variantsInfo.variants.media.video`},{path:`entity.variantSummary.minPriceVariant.media.video`}]}])))(),Rr=y(`wix.stores.catalog.v3.product_deleted`,!0,e=>M(P(e,[{transformFn:N,paths:[{path:`entity.createdDate`},{path:`entity.updatedDate`},{path:`entity.description.metadata.createdTimestamp`},{path:`entity.description.metadata.updatedTimestamp`},{path:`entity.infoSections.description.metadata.createdTimestamp`},{path:`entity.infoSections.description.metadata.updatedTimestamp`},{path:`metadata.eventTime`}]},{transformFn:U,paths:[{path:`entity.url`}]},{transformFn:z,paths:[{path:`entity.physicalProperties.pricePerUnit.quantity`},{path:`entity.physicalProperties.shippingWeightRange.minValue`},{path:`entity.physicalProperties.shippingWeightRange.maxValue`},{path:`entity.variantsInfo.variants.physicalProperties.pricePerUnit.settings.quantity`},{path:`entity.variantsInfo.variants.revenueDetails.profitMargin`},{path:`entity.subscriptionDetails.subscriptions.discount.percentOff`},{path:`entity.variantSummary.minPriceVariant.physicalProperties.pricePerUnit.settings.quantity`},{path:`entity.variantSummary.minPriceVariant.revenueDetails.profitMargin`},{path:`entity.minVariantPriceInfo.pricePerUnitData.settings.quantity`},{path:`entity.minVariantPriceInfo.revenueDetails.profitMargin`},{path:`entity.description.nodes.buttonData.styles.background.gradient.centerX`},{path:`entity.description.nodes.buttonData.styles.background.gradient.centerY`},{path:`entity.description.nodes.buttonData.styles.background.gradient.stops.position`},{path:`entity.description.nodes.buttonData.styles.backgroundHover.gradient.centerX`},{path:`entity.description.nodes.buttonData.styles.backgroundHover.gradient.centerY`},{path:`entity.description.nodes.buttonData.styles.backgroundHover.gradient.stops.position`},{path:`entity.description.nodes.galleryData.items.image.media.duration`},{path:`entity.description.nodes.galleryData.items.video.media.duration`},{path:`entity.description.nodes.galleryData.items.video.thumbnail.duration`},{path:`entity.description.nodes.galleryData.options.item.ratio`},{path:`entity.description.nodes.imageData.image.duration`},{path:`entity.description.nodes.imageData.crop.x`},{path:`entity.description.nodes.imageData.crop.y`},{path:`entity.description.nodes.imageData.crop.width`},{path:`entity.description.nodes.imageData.crop.height`},{path:`entity.description.nodes.mapData.mapSettings.lat`},{path:`entity.description.nodes.mapData.mapSettings.lng`},{path:`entity.description.nodes.pollData.poll.image.duration`},{path:`entity.description.nodes.pollData.poll.options.image.duration`},{path:`entity.description.nodes.pollData.design.poll.background.image.duration`},{path:`entity.description.nodes.appEmbedData.image.duration`},{path:`entity.description.nodes.videoData.video.duration`},{path:`entity.description.nodes.videoData.thumbnail.duration`},{path:`entity.description.nodes.audioData.audio.duration`},{path:`entity.description.nodes.audioData.coverImage.duration`},{path:`entity.description.nodes.layoutData.backgroundImage.media.duration`},{path:`entity.description.nodes.layoutData.backgroundImage.overlay.gradient.centerX`},{path:`entity.description.nodes.layoutData.backgroundImage.overlay.gradient.centerY`},{path:`entity.description.nodes.layoutData.backgroundImage.overlay.gradient.stops.position`},{path:`entity.description.nodes.layoutData.backdropImage.media.duration`},{path:`entity.description.nodes.layoutData.backdropImage.overlay.gradient.centerX`},{path:`entity.description.nodes.layoutData.backdropImage.overlay.gradient.centerY`},{path:`entity.description.nodes.layoutData.backdropImage.overlay.gradient.stops.position`},{path:`entity.description.nodes.layoutData.background.gradient.centerX`},{path:`entity.description.nodes.layoutData.background.gradient.centerY`},{path:`entity.description.nodes.layoutData.background.gradient.stops.position`},{path:`entity.description.nodes.layoutData.backdrop.gradient.centerX`},{path:`entity.description.nodes.layoutData.backdrop.gradient.centerY`},{path:`entity.description.nodes.layoutData.backdrop.gradient.stops.position`},{path:`entity.description.nodes.shapeData.shape.duration`},{path:`entity.description.nodes.cardData.background.gradient.centerX`},{path:`entity.description.nodes.cardData.background.gradient.centerY`},{path:`entity.description.nodes.cardData.background.gradient.stops.position`},{path:`entity.description.nodes.cardData.backgroundImage.media.duration`},{path:`entity.description.nodes.cardData.backgroundImage.overlay.gradient.centerX`},{path:`entity.description.nodes.cardData.backgroundImage.overlay.gradient.centerY`},{path:`entity.description.nodes.cardData.backgroundImage.overlay.gradient.stops.position`},{path:`entity.description.nodes.tocData.fontSize`},{path:`entity.description.nodes.tocData.itemSpacing`},{path:`entity.description.nodes.smartBlockCellData.shape.duration`},{path:`entity.infoSections.description.nodes.buttonData.styles.background.gradient.centerX`},{path:`entity.infoSections.description.nodes.buttonData.styles.background.gradient.centerY`},{path:`entity.infoSections.description.nodes.buttonData.styles.background.gradient.stops.position`},{path:`entity.infoSections.description.nodes.buttonData.styles.backgroundHover.gradient.centerX`},{path:`entity.infoSections.description.nodes.buttonData.styles.backgroundHover.gradient.centerY`},{path:`entity.infoSections.description.nodes.buttonData.styles.backgroundHover.gradient.stops.position`},{path:`entity.infoSections.description.nodes.galleryData.items.image.media.duration`},{path:`entity.infoSections.description.nodes.galleryData.items.video.media.duration`},{path:`entity.infoSections.description.nodes.galleryData.items.video.thumbnail.duration`},{path:`entity.infoSections.description.nodes.galleryData.options.item.ratio`},{path:`entity.infoSections.description.nodes.imageData.image.duration`},{path:`entity.infoSections.description.nodes.imageData.crop.x`},{path:`entity.infoSections.description.nodes.imageData.crop.y`},{path:`entity.infoSections.description.nodes.imageData.crop.width`},{path:`entity.infoSections.description.nodes.imageData.crop.height`},{path:`entity.infoSections.description.nodes.mapData.mapSettings.lat`},{path:`entity.infoSections.description.nodes.mapData.mapSettings.lng`},{path:`entity.infoSections.description.nodes.pollData.poll.image.duration`},{path:`entity.infoSections.description.nodes.pollData.poll.options.image.duration`},{path:`entity.infoSections.description.nodes.pollData.design.poll.background.image.duration`},{path:`entity.infoSections.description.nodes.appEmbedData.image.duration`},{path:`entity.infoSections.description.nodes.videoData.video.duration`},{path:`entity.infoSections.description.nodes.videoData.thumbnail.duration`},{path:`entity.infoSections.description.nodes.audioData.audio.duration`},{path:`entity.infoSections.description.nodes.audioData.coverImage.duration`},{path:`entity.infoSections.description.nodes.layoutData.backgroundImage.media.duration`},{path:`entity.infoSections.description.nodes.layoutData.backgroundImage.overlay.gradient.centerX`},{path:`entity.infoSections.description.nodes.layoutData.backgroundImage.overlay.gradient.centerY`},{path:`entity.infoSections.description.nodes.layoutData.backgroundImage.overlay.gradient.stops.position`},{path:`entity.infoSections.description.nodes.layoutData.backdropImage.media.duration`},{path:`entity.infoSections.description.nodes.layoutData.backdropImage.overlay.gradient.centerX`},{path:`entity.infoSections.description.nodes.layoutData.backdropImage.overlay.gradient.centerY`},{path:`entity.infoSections.description.nodes.layoutData.backdropImage.overlay.gradient.stops.position`},{path:`entity.infoSections.description.nodes.layoutData.background.gradient.centerX`},{path:`entity.infoSections.description.nodes.layoutData.background.gradient.centerY`},{path:`entity.infoSections.description.nodes.layoutData.background.gradient.stops.position`},{path:`entity.infoSections.description.nodes.layoutData.backdrop.gradient.centerX`},{path:`entity.infoSections.description.nodes.layoutData.backdrop.gradient.centerY`},{path:`entity.infoSections.description.nodes.layoutData.backdrop.gradient.stops.position`},{path:`entity.infoSections.description.nodes.shapeData.shape.duration`},{path:`entity.infoSections.description.nodes.cardData.background.gradient.centerX`},{path:`entity.infoSections.description.nodes.cardData.background.gradient.centerY`},{path:`entity.infoSections.description.nodes.cardData.background.gradient.stops.position`},{path:`entity.infoSections.description.nodes.cardData.backgroundImage.media.duration`},{path:`entity.infoSections.description.nodes.cardData.backgroundImage.overlay.gradient.centerX`},{path:`entity.infoSections.description.nodes.cardData.backgroundImage.overlay.gradient.centerY`},{path:`entity.infoSections.description.nodes.cardData.backgroundImage.overlay.gradient.stops.position`},{path:`entity.infoSections.description.nodes.tocData.fontSize`},{path:`entity.infoSections.description.nodes.tocData.itemSpacing`},{path:`entity.infoSections.description.nodes.smartBlockCellData.shape.duration`},{path:`entity.variantsInfo.variants.physicalProperties.weight`},{path:`entity.variantSummary.minPriceVariant.physicalProperties.weight`},{path:`entity.minVariantPriceInfo.weight`}]},{transformFn:H,paths:[{path:`entity.media.main.image`},{path:`entity.media.itemsInfo.items.image`},{path:`entity.options.choicesSettings.choices.image`},{path:`entity.options.choicesSettings.choices.displayImage`},{path:`entity.options.choicesSettings.choices.linkedMedia.image`},{path:`entity.modifiers.choicesSettings.choices.image`},{path:`entity.modifiers.choicesSettings.choices.displayImage`},{path:`entity.modifiers.choicesSettings.choices.linkedMedia.image`},{path:`entity.variantsInfo.variants.media.image`},{path:`entity.variantSummary.minPriceVariant.media.image`}]},{transformFn:tr,paths:[{path:`entity.media.main.video`},{path:`entity.media.itemsInfo.items.video`},{path:`entity.options.choicesSettings.choices.linkedMedia.video`},{path:`entity.modifiers.choicesSettings.choices.linkedMedia.video`},{path:`entity.variantsInfo.variants.media.video`},{path:`entity.variantSummary.minPriceVariant.media.video`}]}])))(),zr=y(`wix.stores.catalog.v3.product_updated`,!0,e=>M(P(e,[{transformFn:N,paths:[{path:`entity.createdDate`},{path:`entity.updatedDate`},{path:`entity.description.metadata.createdTimestamp`},{path:`entity.description.metadata.updatedTimestamp`},{path:`entity.infoSections.description.metadata.createdTimestamp`},{path:`entity.infoSections.description.metadata.updatedTimestamp`},{path:`metadata.eventTime`},{path:`modifiedFields.createdDate`},{path:`modifiedFields.updatedDate`},{path:`modifiedFields.description.metadata.createdTimestamp`},{path:`modifiedFields.description.metadata.updatedTimestamp`},{path:`modifiedFields.infoSections.description.metadata.createdTimestamp`},{path:`modifiedFields.infoSections.description.metadata.updatedTimestamp`}]},{transformFn:U,paths:[{path:`entity.url`},{path:`modifiedFields.url`}]},{transformFn:z,paths:[{path:`entity.physicalProperties.pricePerUnit.quantity`},{path:`entity.physicalProperties.shippingWeightRange.minValue`},{path:`entity.physicalProperties.shippingWeightRange.maxValue`},{path:`entity.variantsInfo.variants.physicalProperties.pricePerUnit.settings.quantity`},{path:`entity.variantsInfo.variants.revenueDetails.profitMargin`},{path:`entity.subscriptionDetails.subscriptions.discount.percentOff`},{path:`entity.variantSummary.minPriceVariant.physicalProperties.pricePerUnit.settings.quantity`},{path:`entity.variantSummary.minPriceVariant.revenueDetails.profitMargin`},{path:`entity.minVariantPriceInfo.pricePerUnitData.settings.quantity`},{path:`entity.minVariantPriceInfo.revenueDetails.profitMargin`},{path:`entity.description.nodes.buttonData.styles.background.gradient.centerX`},{path:`entity.description.nodes.buttonData.styles.background.gradient.centerY`},{path:`entity.description.nodes.buttonData.styles.background.gradient.stops.position`},{path:`entity.description.nodes.buttonData.styles.backgroundHover.gradient.centerX`},{path:`entity.description.nodes.buttonData.styles.backgroundHover.gradient.centerY`},{path:`entity.description.nodes.buttonData.styles.backgroundHover.gradient.stops.position`},{path:`entity.description.nodes.galleryData.items.image.media.duration`},{path:`entity.description.nodes.galleryData.items.video.media.duration`},{path:`entity.description.nodes.galleryData.items.video.thumbnail.duration`},{path:`entity.description.nodes.galleryData.options.item.ratio`},{path:`entity.description.nodes.imageData.image.duration`},{path:`entity.description.nodes.imageData.crop.x`},{path:`entity.description.nodes.imageData.crop.y`},{path:`entity.description.nodes.imageData.crop.width`},{path:`entity.description.nodes.imageData.crop.height`},{path:`entity.description.nodes.mapData.mapSettings.lat`},{path:`entity.description.nodes.mapData.mapSettings.lng`},{path:`entity.description.nodes.pollData.poll.image.duration`},{path:`entity.description.nodes.pollData.poll.options.image.duration`},{path:`entity.description.nodes.pollData.design.poll.background.image.duration`},{path:`entity.description.nodes.appEmbedData.image.duration`},{path:`entity.description.nodes.videoData.video.duration`},{path:`entity.description.nodes.videoData.thumbnail.duration`},{path:`entity.description.nodes.audioData.audio.duration`},{path:`entity.description.nodes.audioData.coverImage.duration`},{path:`entity.description.nodes.layoutData.backgroundImage.media.duration`},{path:`entity.description.nodes.layoutData.backgroundImage.overlay.gradient.centerX`},{path:`entity.description.nodes.layoutData.backgroundImage.overlay.gradient.centerY`},{path:`entity.description.nodes.layoutData.backgroundImage.overlay.gradient.stops.position`},{path:`entity.description.nodes.layoutData.backdropImage.media.duration`},{path:`entity.description.nodes.layoutData.backdropImage.overlay.gradient.centerX`},{path:`entity.description.nodes.layoutData.backdropImage.overlay.gradient.centerY`},{path:`entity.description.nodes.layoutData.backdropImage.overlay.gradient.stops.position`},{path:`entity.description.nodes.layoutData.background.gradient.centerX`},{path:`entity.description.nodes.layoutData.background.gradient.centerY`},{path:`entity.description.nodes.layoutData.background.gradient.stops.position`},{path:`entity.description.nodes.layoutData.backdrop.gradient.centerX`},{path:`entity.description.nodes.layoutData.backdrop.gradient.centerY`},{path:`entity.description.nodes.layoutData.backdrop.gradient.stops.position`},{path:`entity.description.nodes.shapeData.shape.duration`},{path:`entity.description.nodes.cardData.background.gradient.centerX`},{path:`entity.description.nodes.cardData.background.gradient.centerY`},{path:`entity.description.nodes.cardData.background.gradient.stops.position`},{path:`entity.description.nodes.cardData.backgroundImage.media.duration`},{path:`entity.description.nodes.cardData.backgroundImage.overlay.gradient.centerX`},{path:`entity.description.nodes.cardData.backgroundImage.overlay.gradient.centerY`},{path:`entity.description.nodes.cardData.backgroundImage.overlay.gradient.stops.position`},{path:`entity.description.nodes.tocData.fontSize`},{path:`entity.description.nodes.tocData.itemSpacing`},{path:`entity.description.nodes.smartBlockCellData.shape.duration`},{path:`entity.infoSections.description.nodes.buttonData.styles.background.gradient.centerX`},{path:`entity.infoSections.description.nodes.buttonData.styles.background.gradient.centerY`},{path:`entity.infoSections.description.nodes.buttonData.styles.background.gradient.stops.position`},{path:`entity.infoSections.description.nodes.buttonData.styles.backgroundHover.gradient.centerX`},{path:`entity.infoSections.description.nodes.buttonData.styles.backgroundHover.gradient.centerY`},{path:`entity.infoSections.description.nodes.buttonData.styles.backgroundHover.gradient.stops.position`},{path:`entity.infoSections.description.nodes.galleryData.items.image.media.duration`},{path:`entity.infoSections.description.nodes.galleryData.items.video.media.duration`},{path:`entity.infoSections.description.nodes.galleryData.items.video.thumbnail.duration`},{path:`entity.infoSections.description.nodes.galleryData.options.item.ratio`},{path:`entity.infoSections.description.nodes.imageData.image.duration`},{path:`entity.infoSections.description.nodes.imageData.crop.x`},{path:`entity.infoSections.description.nodes.imageData.crop.y`},{path:`entity.infoSections.description.nodes.imageData.crop.width`},{path:`entity.infoSections.description.nodes.imageData.crop.height`},{path:`entity.infoSections.description.nodes.mapData.mapSettings.lat`},{path:`entity.infoSections.description.nodes.mapData.mapSettings.lng`},{path:`entity.infoSections.description.nodes.pollData.poll.image.duration`},{path:`entity.infoSections.description.nodes.pollData.poll.options.image.duration`},{path:`entity.infoSections.description.nodes.pollData.design.poll.background.image.duration`},{path:`entity.infoSections.description.nodes.appEmbedData.image.duration`},{path:`entity.infoSections.description.nodes.videoData.video.duration`},{path:`entity.infoSections.description.nodes.videoData.thumbnail.duration`},{path:`entity.infoSections.description.nodes.audioData.audio.duration`},{path:`entity.infoSections.description.nodes.audioData.coverImage.duration`},{path:`entity.infoSections.description.nodes.layoutData.backgroundImage.media.duration`},{path:`entity.infoSections.description.nodes.layoutData.backgroundImage.overlay.gradient.centerX`},{path:`entity.infoSections.description.nodes.layoutData.backgroundImage.overlay.gradient.centerY`},{path:`entity.infoSections.description.nodes.layoutData.backgroundImage.overlay.gradient.stops.position`},{path:`entity.infoSections.description.nodes.layoutData.backdropImage.media.duration`},{path:`entity.infoSections.description.nodes.layoutData.backdropImage.overlay.gradient.centerX`},{path:`entity.infoSections.description.nodes.layoutData.backdropImage.overlay.gradient.centerY`},{path:`entity.infoSections.description.nodes.layoutData.backdropImage.overlay.gradient.stops.position`},{path:`entity.infoSections.description.nodes.layoutData.background.gradient.centerX`},{path:`entity.infoSections.description.nodes.layoutData.background.gradient.centerY`},{path:`entity.infoSections.description.nodes.layoutData.background.gradient.stops.position`},{path:`entity.infoSections.description.nodes.layoutData.backdrop.gradient.centerX`},{path:`entity.infoSections.description.nodes.layoutData.backdrop.gradient.centerY`},{path:`entity.infoSections.description.nodes.layoutData.backdrop.gradient.stops.position`},{path:`entity.infoSections.description.nodes.shapeData.shape.duration`},{path:`entity.infoSections.description.nodes.cardData.background.gradient.centerX`},{path:`entity.infoSections.description.nodes.cardData.background.gradient.centerY`},{path:`entity.infoSections.description.nodes.cardData.background.gradient.stops.position`},{path:`entity.infoSections.description.nodes.cardData.backgroundImage.media.duration`},{path:`entity.infoSections.description.nodes.cardData.backgroundImage.overlay.gradient.centerX`},{path:`entity.infoSections.description.nodes.cardData.backgroundImage.overlay.gradient.centerY`},{path:`entity.infoSections.description.nodes.cardData.backgroundImage.overlay.gradient.stops.position`},{path:`entity.infoSections.description.nodes.tocData.fontSize`},{path:`entity.infoSections.description.nodes.tocData.itemSpacing`},{path:`entity.infoSections.description.nodes.smartBlockCellData.shape.duration`},{path:`entity.variantsInfo.variants.physicalProperties.weight`},{path:`entity.variantSummary.minPriceVariant.physicalProperties.weight`},{path:`entity.minVariantPriceInfo.weight`},{path:`modifiedFields.physicalProperties.pricePerUnit.quantity`},{path:`modifiedFields.physicalProperties.shippingWeightRange.minValue`},{path:`modifiedFields.physicalProperties.shippingWeightRange.maxValue`},{path:`modifiedFields.variantsInfo.variants.physicalProperties.pricePerUnit.settings.quantity`},{path:`modifiedFields.variantsInfo.variants.revenueDetails.profitMargin`},{path:`modifiedFields.subscriptionDetails.subscriptions.discount.percentOff`},{path:`modifiedFields.variantSummary.minPriceVariant.physicalProperties.pricePerUnit.settings.quantity`},{path:`modifiedFields.variantSummary.minPriceVariant.revenueDetails.profitMargin`},{path:`modifiedFields.minVariantPriceInfo.pricePerUnitData.settings.quantity`},{path:`modifiedFields.minVariantPriceInfo.revenueDetails.profitMargin`},{path:`modifiedFields.description.nodes.buttonData.styles.background.gradient.centerX`},{path:`modifiedFields.description.nodes.buttonData.styles.background.gradient.centerY`},{path:`modifiedFields.description.nodes.buttonData.styles.background.gradient.stops.position`},{path:`modifiedFields.description.nodes.buttonData.styles.backgroundHover.gradient.centerX`},{path:`modifiedFields.description.nodes.buttonData.styles.backgroundHover.gradient.centerY`},{path:`modifiedFields.description.nodes.buttonData.styles.backgroundHover.gradient.stops.position`},{path:`modifiedFields.description.nodes.galleryData.items.image.media.duration`},{path:`modifiedFields.description.nodes.galleryData.items.video.media.duration`},{path:`modifiedFields.description.nodes.galleryData.items.video.thumbnail.duration`},{path:`modifiedFields.description.nodes.galleryData.options.item.ratio`},{path:`modifiedFields.description.nodes.imageData.image.duration`},{path:`modifiedFields.description.nodes.imageData.crop.x`},{path:`modifiedFields.description.nodes.imageData.crop.y`},{path:`modifiedFields.description.nodes.imageData.crop.width`},{path:`modifiedFields.description.nodes.imageData.crop.height`},{path:`modifiedFields.description.nodes.mapData.mapSettings.lat`},{path:`modifiedFields.description.nodes.mapData.mapSettings.lng`},{path:`modifiedFields.description.nodes.pollData.poll.image.duration`},{path:`modifiedFields.description.nodes.pollData.poll.options.image.duration`},{path:`modifiedFields.description.nodes.pollData.design.poll.background.image.duration`},{path:`modifiedFields.description.nodes.appEmbedData.image.duration`},{path:`modifiedFields.description.nodes.videoData.video.duration`},{path:`modifiedFields.description.nodes.videoData.thumbnail.duration`},{path:`modifiedFields.description.nodes.audioData.audio.duration`},{path:`modifiedFields.description.nodes.audioData.coverImage.duration`},{path:`modifiedFields.description.nodes.layoutData.backgroundImage.media.duration`},{path:`modifiedFields.description.nodes.layoutData.backgroundImage.overlay.gradient.centerX`},{path:`modifiedFields.description.nodes.layoutData.backgroundImage.overlay.gradient.centerY`},{path:`modifiedFields.description.nodes.layoutData.backgroundImage.overlay.gradient.stops.position`},{path:`modifiedFields.description.nodes.layoutData.backdropImage.media.duration`},{path:`modifiedFields.description.nodes.layoutData.backdropImage.overlay.gradient.centerX`},{path:`modifiedFields.description.nodes.layoutData.backdropImage.overlay.gradient.centerY`},{path:`modifiedFields.description.nodes.layoutData.backdropImage.overlay.gradient.stops.position`},{path:`modifiedFields.description.nodes.layoutData.background.gradient.centerX`},{path:`modifiedFields.description.nodes.layoutData.background.gradient.centerY`},{path:`modifiedFields.description.nodes.layoutData.background.gradient.stops.position`},{path:`modifiedFields.description.nodes.layoutData.backdrop.gradient.centerX`},{path:`modifiedFields.description.nodes.layoutData.backdrop.gradient.centerY`},{path:`modifiedFields.description.nodes.layoutData.backdrop.gradient.stops.position`},{path:`modifiedFields.description.nodes.shapeData.shape.duration`},{path:`modifiedFields.description.nodes.cardData.background.gradient.centerX`},{path:`modifiedFields.description.nodes.cardData.background.gradient.centerY`},{path:`modifiedFields.description.nodes.cardData.background.gradient.stops.position`},{path:`modifiedFields.description.nodes.cardData.backgroundImage.media.duration`},{path:`modifiedFields.description.nodes.cardData.backgroundImage.overlay.gradient.centerX`},{path:`modifiedFields.description.nodes.cardData.backgroundImage.overlay.gradient.centerY`},{path:`modifiedFields.description.nodes.cardData.backgroundImage.overlay.gradient.stops.position`},{path:`modifiedFields.description.nodes.tocData.fontSize`},{path:`modifiedFields.description.nodes.tocData.itemSpacing`},{path:`modifiedFields.description.nodes.smartBlockCellData.shape.duration`},{path:`modifiedFields.infoSections.description.nodes.buttonData.styles.background.gradient.centerX`},{path:`modifiedFields.infoSections.description.nodes.buttonData.styles.background.gradient.centerY`},{path:`modifiedFields.infoSections.description.nodes.buttonData.styles.background.gradient.stops.position`},{path:`modifiedFields.infoSections.description.nodes.buttonData.styles.backgroundHover.gradient.centerX`},{path:`modifiedFields.infoSections.description.nodes.buttonData.styles.backgroundHover.gradient.centerY`},{path:`modifiedFields.infoSections.description.nodes.buttonData.styles.backgroundHover.gradient.stops.position`},{path:`modifiedFields.infoSections.description.nodes.galleryData.items.image.media.duration`},{path:`modifiedFields.infoSections.description.nodes.galleryData.items.video.media.duration`},{path:`modifiedFields.infoSections.description.nodes.galleryData.items.video.thumbnail.duration`},{path:`modifiedFields.infoSections.description.nodes.galleryData.options.item.ratio`},{path:`modifiedFields.infoSections.description.nodes.imageData.image.duration`},{path:`modifiedFields.infoSections.description.nodes.imageData.crop.x`},{path:`modifiedFields.infoSections.description.nodes.imageData.crop.y`},{path:`modifiedFields.infoSections.description.nodes.imageData.crop.width`},{path:`modifiedFields.infoSections.description.nodes.imageData.crop.height`},{path:`modifiedFields.infoSections.description.nodes.mapData.mapSettings.lat`},{path:`modifiedFields.infoSections.description.nodes.mapData.mapSettings.lng`},{path:`modifiedFields.infoSections.description.nodes.pollData.poll.image.duration`},{path:`modifiedFields.infoSections.description.nodes.pollData.poll.options.image.duration`},{path:`modifiedFields.infoSections.description.nodes.pollData.design.poll.background.image.duration`},{path:`modifiedFields.infoSections.description.nodes.appEmbedData.image.duration`},{path:`modifiedFields.infoSections.description.nodes.videoData.video.duration`},{path:`modifiedFields.infoSections.description.nodes.videoData.thumbnail.duration`},{path:`modifiedFields.infoSections.description.nodes.audioData.audio.duration`},{path:`modifiedFields.infoSections.description.nodes.audioData.coverImage.duration`},{path:`modifiedFields.infoSections.description.nodes.layoutData.backgroundImage.media.duration`},{path:`modifiedFields.infoSections.description.nodes.layoutData.backgroundImage.overlay.gradient.centerX`},{path:`modifiedFields.infoSections.description.nodes.layoutData.backgroundImage.overlay.gradient.centerY`},{path:`modifiedFields.infoSections.description.nodes.layoutData.backgroundImage.overlay.gradient.stops.position`},{path:`modifiedFields.infoSections.description.nodes.layoutData.backdropImage.media.duration`},{path:`modifiedFields.infoSections.description.nodes.layoutData.backdropImage.overlay.gradient.centerX`},{path:`modifiedFields.infoSections.description.nodes.layoutData.backdropImage.overlay.gradient.centerY`},{path:`modifiedFields.infoSections.description.nodes.layoutData.backdropImage.overlay.gradient.stops.position`},{path:`modifiedFields.infoSections.description.nodes.layoutData.background.gradient.centerX`},{path:`modifiedFields.infoSections.description.nodes.layoutData.background.gradient.centerY`},{path:`modifiedFields.infoSections.description.nodes.layoutData.background.gradient.stops.position`},{path:`modifiedFields.infoSections.description.nodes.layoutData.backdrop.gradient.centerX`},{path:`modifiedFields.infoSections.description.nodes.layoutData.backdrop.gradient.centerY`},{path:`modifiedFields.infoSections.description.nodes.layoutData.backdrop.gradient.stops.position`},{path:`modifiedFields.infoSections.description.nodes.shapeData.shape.duration`},{path:`modifiedFields.infoSections.description.nodes.cardData.background.gradient.centerX`},{path:`modifiedFields.infoSections.description.nodes.cardData.background.gradient.centerY`},{path:`modifiedFields.infoSections.description.nodes.cardData.background.gradient.stops.position`},{path:`modifiedFields.infoSections.description.nodes.cardData.backgroundImage.media.duration`},{path:`modifiedFields.infoSections.description.nodes.cardData.backgroundImage.overlay.gradient.centerX`},{path:`modifiedFields.infoSections.description.nodes.cardData.backgroundImage.overlay.gradient.centerY`},{path:`modifiedFields.infoSections.description.nodes.cardData.backgroundImage.overlay.gradient.stops.position`},{path:`modifiedFields.infoSections.description.nodes.tocData.fontSize`},{path:`modifiedFields.infoSections.description.nodes.tocData.itemSpacing`},{path:`modifiedFields.infoSections.description.nodes.smartBlockCellData.shape.duration`},{path:`modifiedFields.variantsInfo.variants.physicalProperties.weight`},{path:`modifiedFields.variantSummary.minPriceVariant.physicalProperties.weight`},{path:`modifiedFields.minVariantPriceInfo.weight`}]},{transformFn:H,paths:[{path:`entity.media.main.image`},{path:`entity.media.itemsInfo.items.image`},{path:`entity.options.choicesSettings.choices.image`},{path:`entity.options.choicesSettings.choices.displayImage`},{path:`entity.options.choicesSettings.choices.linkedMedia.image`},{path:`entity.modifiers.choicesSettings.choices.image`},{path:`entity.modifiers.choicesSettings.choices.displayImage`},{path:`entity.modifiers.choicesSettings.choices.linkedMedia.image`},{path:`entity.variantsInfo.variants.media.image`},{path:`entity.variantSummary.minPriceVariant.media.image`},{path:`modifiedFields.media.main.image`},{path:`modifiedFields.media.itemsInfo.items.image`},{path:`modifiedFields.options.choicesSettings.choices.image`},{path:`modifiedFields.options.choicesSettings.choices.displayImage`},{path:`modifiedFields.options.choicesSettings.choices.linkedMedia.image`},{path:`modifiedFields.modifiers.choicesSettings.choices.image`},{path:`modifiedFields.modifiers.choicesSettings.choices.displayImage`},{path:`modifiedFields.modifiers.choicesSettings.choices.linkedMedia.image`},{path:`modifiedFields.variantsInfo.variants.media.image`},{path:`modifiedFields.variantSummary.minPriceVariant.media.image`}]},{transformFn:tr,paths:[{path:`entity.media.main.video`},{path:`entity.media.itemsInfo.items.video`},{path:`entity.options.choicesSettings.choices.linkedMedia.video`},{path:`entity.modifiers.choicesSettings.choices.linkedMedia.video`},{path:`entity.variantsInfo.variants.media.video`},{path:`entity.variantSummary.minPriceVariant.media.video`},{path:`modifiedFields.media.main.video`},{path:`modifiedFields.media.itemsInfo.items.video`},{path:`modifiedFields.options.choicesSettings.choices.linkedMedia.video`},{path:`modifiedFields.modifiers.choicesSettings.choices.linkedMedia.video`},{path:`modifiedFields.variantsInfo.variants.media.video`},{path:`modifiedFields.variantSummary.minPriceVariant.media.video`}]}])))(),Br=I(Ir);R(Lr),R(Rr),R(zr);function Vr(e){return L(Object.assign(e,{domainToMappings:{"api._api_base_domain_":[{srcPath:`/product-group`,destPath:``}],"editor._base_domain_":[{srcPath:`/_api/product-group`,destPath:``}],"blocks._base_domain_":[{srcPath:`/_api/product-group`,destPath:``}],"create.editorx":[{srcPath:`/_api/product-group`,destPath:``}],_:[{srcPath:`/_api/product-group`,destPath:``}],"manage._base_domain_":[{srcPath:`/_api/product-group`,destPath:``}],"www.wixapis.com":[{srcPath:`/stores/v3/product-groups`,destPath:`/v3/product-groups`},{srcPath:`/stores/v3/bulk/product-groups`,destPath:`/v3/bulk/product-groups`}],"*.dev.wix-code.com":[{srcPath:`/_api/product-group`,destPath:``}]}}))}var Hr=`@wix/auto_sdk_stores_product-groups-v-3`;function Ur(e){function t({host:t}){return{entityFqdn:`wix.stores.catalog.v3.product_group`,method:`GET`,methodFqn:`wix.stores.catalog.product_group.v3.ProductGroupService.QueryProductGroups`,packageName:Hr,migrationOptions:{optInTransformResponse:!0},url:Vr({protoPath:`/v3/product-groups/query`,data:e,host:t}),params:Rt(e,!0),transformResponse:e=>P(e,[{transformFn:N,paths:[{path:`productGroups.createdDate`},{path:`productGroups.updatedDate`},{path:`productGroups.media.image.urlExpirationDate`}]}]),fallback:[{method:`POST`,url:Vr({protoPath:`/v3/product-groups/query`,data:e,host:t}),data:e}]}}return t}var Wr=(e=>(e.GROUPING_CUSTOMIZATION=`GROUPING_CUSTOMIZATION`,e.THUMBNAIL=`THUMBNAIL`,e))(Wr||{});function Gr(e){let{httpClient:t,sideEffects:n}=arguments[1];return In({func:async r=>{let i=Ur({...r,...e??{}});n?.onSiteCall?.();try{let e=await t.request(i);return n?.onSuccess?.(e),e}catch(e){throw n?.onError?.(e),e}},requestTransformer:t=>{let n=[t,e];return j({...n?.[1],query:n?.[0]})},responseTransformer:({data:e})=>{let t=M(P(e,[{transformFn:H,paths:[{path:`productGroups.media.image`}]}]));return{items:t?.productGroups,pagingMetadata:t?.pagingMetadata}},errorTransformer:e=>{throw F(e,{spreadPathsToArguments:{},explicitPathsToArguments:{query:`$[0]`},singleArgumentUnchanged:!1})},pagingMethod:`CURSOR`,transformationPaths:{}})}async function Kr(e,t){let{httpClient:n,sideEffects:r}=arguments[2],i=Ur(j({query:e,...t}));r?.onSiteCall?.();try{let e=await n.request(i);return r?.onSuccess?.(e),M(P(e.data,[{transformFn:H,paths:[{path:`productGroups.media.image`}]}]))}catch(e){let t=F(e,{spreadPathsToArguments:{},explicitPathsToArguments:{query:`$[0]`},singleArgumentUnchanged:!1},[`query`,`options`]);throw r?.onError?.(e),t}}({...Vn()}),{...fr()};function qr(e){return t=>Gr(t,{httpClient:e})}function Jr(e){return(t,n)=>Kr(t,n,{httpClient:e})}function Yr(e){let t=Zn({builderQueryFunction:t=>qr(e)(t),typedQueryFunction:(t,n)=>Jr(e)(t,n),hasOptionsParameter:!0});function n(e,n){return t(...arguments)}return n}var Xr=I(Yr);function Zr(e){return L(Object.assign(e,{domainToMappings:{"manage._base_domain_":[{srcPath:`/_api/location`,destPath:``}],_:[{srcPath:`/_api/location`,destPath:``}],"*.dev.wix-code.com":[{srcPath:`/_api/location`,destPath:``}],"www.wixapis.com":[{srcPath:`/stores/v3/locations`,destPath:`/v3/locations`}]}}))}var Qr=`@wix/auto_sdk_stores_stores-locations-v-3`;function $r(e){function t({host:t}){return{entityFqdn:`wix.stores.catalog.v3.stores_location`,method:`POST`,methodFqn:`wix.stores.catalog.location.v3.StoresLocationService.QueryStoresLocations`,packageName:Qr,migrationOptions:{optInTransformResponse:!0},url:Zr({protoPath:`/v3/locations/query`,data:e,host:t}),data:e,transformResponse:e=>P(e,[{transformFn:N,paths:[{path:`storesLocations.createdDate`},{path:`storesLocations.updatedDate`}]}])}}return t}function ei(){let{httpClient:e,sideEffects:t}=arguments[0];return In({func:async n=>{let r=$r(n);t?.onSiteCall?.();try{let n=await e.request(r);return t?.onSuccess?.(n),n}catch(e){throw t?.onError?.(e),e}},requestTransformer:e=>{let t=[e,{}];return j({...t?.[1],query:t?.[0]})},responseTransformer:({data:e})=>{let t=M(P(e,[]));return{items:t?.storesLocations,pagingMetadata:t?.pagingMetadata}},errorTransformer:e=>{throw F(e,{spreadPathsToArguments:{},explicitPathsToArguments:{query:`$[0]`},singleArgumentUnchanged:!1})},pagingMethod:`CURSOR`,transformationPaths:{}})}async function ti(e){let{httpClient:t,sideEffects:n}=arguments[1],r=$r(j({query:e}));n?.onSiteCall?.();try{let e=await t.request(r);return n?.onSuccess?.(e),M(e.data)}catch(e){let t=F(e,{spreadPathsToArguments:{},explicitPathsToArguments:{query:`$[0]`},singleArgumentUnchanged:!1},[`query`]);throw n?.onError?.(e),t}}({...Vn()});function ni(e){return()=>ei({httpClient:e})}function ri(e){return t=>ti(t,{httpClient:e})}function ii(e){let t=Zn({builderQueryFunction:()=>ni(e)(),typedQueryFunction:t=>ri(e)(t),hasOptionsParameter:!1});function n(e){return t(...arguments)}return n}var ai=I(ii),oi=`https://static.wixstatic.com/media`,si=`https://video.wixstatic.com/video`,ci=/image:\/\/v1\/([^/#]+)/,li=/^(?:wix:)?video:\/\/v1\/([^/#]+)(?:\/[^#]*)?(?:#(.*))?$/;function ui(e){let t=e?.match(li);if(!t)return null;let[,n,r]=t,i=new URLSearchParams(r??``),a=i.get(`posterUri`);return{id:n,url:`${si}/${n}/file`,...a?{poster:{uri:a,url:`${oi}/${a}`,width:Number(i.get(`posterWidth`))||0,height:Number(i.get(`posterHeight`))||0}}:{}}}function di(e){return e?e.match(ci)?.[1]??null:null}function fi(e){if(!e)return;if(/^https?:\/\//i.test(e))return e;let t=di(e);return t?`${oi}/${t}`:void 0}function pi(e){if(!e)return null;let t=e.match(/#originWidth=(\d+)&originHeight=(\d+)/);return t?{width:parseInt(t[1],10),height:parseInt(t[2],10)}:null}var mi=`one-time`;function hi(e){return e.map(e=>({id:e._id,key:e.key,name:e.name??void 0,optionRenderType:e.optionRenderType,choices:(e.choicesSettings?.choices??[]).map(e=>{let t=di(e.displayImage)??void 0;return{choiceId:e.choiceId,key:e.key,name:e.name??void 0,colorCode:e.colorCode,...t?{displayImageUri:t}:{},inStock:e.inStock,visible:e.visible??void 0,mediaIds:gi(e.media)}})}))}var gi=e=>{let t=(e?.items??[]).map(e=>e.mediaId);return t.length>0?t:void 0};function _i(e){let t=e.map(e=>{let t=e._id,n=e.modifierRenderType===Mr.FREE_TEXT;return[t,{id:t,key:e.key,name:e.name??void 0,mandatory:e.mandatory!==!1,modifierRenderType:e.modifierRenderType,freeTextSettings:n?e.freeTextSettings:void 0,choices:n?void 0:(e.choicesSettings?.choices??[]).map(e=>{let t=di(e.displayImage)??void 0;return{choiceId:e.choiceId,key:e.key,name:e.name??void 0,colorCode:e.colorCode,...t?{displayImageUri:t}:{},mediaIds:gi(e.media)}})}]});return Object.fromEntries(t)}function vi(e){return e.filter(e=>e.visible!==!1).map(yi)}var yi=e=>{let t=Object.fromEntries((e.choices??[]).map(e=>{let t=e.optionChoiceIds;return[t?.optionId,t?.choiceId]}));return{id:e._id,sku:e.sku??void 0,choices:t,price:xi(e),subscriptionPrices:Si(e)}};function bi(e){return e?.description==null?void 0:{description:e.description}}var xi=e=>{let t=e.price;return{actualPrice:Bi(t?.actualPrice),compareAtPrice:G(t?.compareAtPrice),priceAfterDiscount:G(t?.priceAfterDiscount),pricePerUnit:bi(e.physicalProperties?.pricePerUnit)}},Si=e=>(e.subscriptionPricesInfo?.subscriptionPrices??[]).map(e=>({subscriptionId:e.subscriptionId,price:Bi(e.price)})),Ci={nodes:[]},wi=`@stores/product-groups`;function Ti(e){let t=hi(e.options??[]),n=_i(e.modifiers??[]),r=ki(e.subscriptionDetails?.subscriptions??[]),i=vi(e.variantsInfo?.variants??[]),a={subscriptions:r,allowOneTimePurchases:e.subscriptionDetails?.allowOneTimePurchases??!1},o=e.additionalRibbons??[],s={primary:e.ribbon?.name??void 0,additional:o.map(e=>e.name??void 0).filter(e=>!!e)},c=e.description?Ai(e.description):Ci,l=e.discountInfo?.discountRuleNames,u=Di(e);return{id:e._id,slug:e.slug??void 0,url:e.url?{href:e.url}:void 0,name:e.name,description:c,media:zi(e),mainMedia:Ri(e.media?.main),ribbons:s,breadcrumbs:ji(e),mainCategoryId:e.mainCategoryId??void 0,categories:Mi(e),infoSections:Ei(e),currency:e.currency,options:t,modifiers:n,variants:i,minPriceVariant:Ii(e),priceRange:Li(e),subscriptionDetails:a,inventory:{availabilityStatus:e.inventory?.availabilityStatus,preorderAvailability:e.inventory?.preorderAvailability},discountRuleNames:l,productGroupId:u}}function Ei(e){return(e.infoSections??[]).map(e=>({_id:e.uniqueName??e._id,name:e.title,body:e.description?Ai(e.description):void 0}))}function Di(e){let t=e.extendedFields?.namespaces?.[wi]?.productGroupId;return typeof t==`string`?t:void 0}function Oi(e){return e===`WEEK`||e===`MONTH`||e===`YEAR`?e:void 0}function ki(e){return e.filter(e=>e.visible!==!1).map(e=>({id:e._id,name:e.title,description:e.description??void 0,frequency:Oi(e.frequency),interval:e.interval,billingCycles:e.billingCycles??void 0}))}function Ai(e){return{...e,nodes:e.nodes??[]}}function ji(e){return(e.breadcrumbsInfo?.breadcrumbs??[]).map(e=>({id:e.categoryId,name:e.categoryName,slug:e.categorySlug}))}function Mi(e){return(e.directCategoriesInfo?.categories??[]).flatMap(e=>e._id?[{id:e._id}]:[])}function Ni(e){return{...e.displayName?{title:e.displayName}:{},...e.altText?{alt:e.altText}:{}}}function Pi(e,t){let n=e.image??e.url;if(!n)return;let r=pi(e.image),{title:i,alt:a}=Ni(e);return{id:di(e.image)??e._id??t,media:{type:`image`,src:n,...r?{width:r.width,height:r.height}:{},...i?{title:i}:{},...a?{parameters:{alt:a}}:{}}}}function Fi(e,t){let n=ui(e.video),r=n?.url??e.url;if(!r)return;let i=n?.poster?.url,a=n?.poster?.width,o=n?.poster?.height,{title:s,alt:c}=Ni(e);return{id:n?.id??e._id??t,media:{type:`video`,src:r,...a===void 0?{}:{width:a},...o===void 0?{}:{height:o},...s?{title:s}:{},...c||i?{parameters:{...c?{alt:c}:{},...i?{thumbnail:i}:{}}}:{}}}}function Ii(e){let t=e.variantSummary?.minPriceVariant;return t?vi([t])[0]:void 0}function Li(e){return{minActualPrice:G(e.actualPriceRange?.minValue),maxActualPrice:G(e.actualPriceRange?.maxValue),minCompareAtPrice:G(e.compareAtPriceRange?.minValue),maxCompareAtPrice:G(e.compareAtPriceRange?.maxValue)}}function Ri(e){if(!e)return;let{title:t,alt:n}=Ni(e);if(e.mediaType===`VIDEO`){let r=ui(e.video)?.poster;return r?{...r,name:t,alt:n}:void 0}let r=e.image??e.url;if(!r)return;let i=pi(e.image);return{uri:di(e.image)??void 0,url:r,width:i?.width,height:i?.height,name:t,alt:n}}function zi(e){return(e.media?.itemsInfo?.items??(e.media?.main?[e.media.main]:[])).flatMap((e,t)=>{let n=e.mediaType===`VIDEO`?Fi(e,String(t)):Pi(e,String(t));return n?[n]:[]})}var Bi=e=>Number.parseFloat(e?.amount),G=e=>e?.amount==null?void 0:Bi(e),Vi=[W.URL,W.DESCRIPTION,W.PLAIN_DESCRIPTION,W.MEDIA_ITEMS_INFO,W.INFO_SECTION,W.INFO_SECTION_DESCRIPTION,W.CURRENCY,W.DISCOUNT_INFO,W.SUBSCRIPTION_PRICES_INFO,W.BREADCRUMBS_INFO,W.DIRECT_CATEGORIES_INFO,W.PRODUCT_CHOICES_MEDIA_REFERENCES,W.PRODUCT_CHOICES_DISPLAY_IMAGE];async function Hi(e){return{product:Ti(await Br(e,{fields:Vi}))}}function Ui(e){if(e.status===`fulfilled`)return e.value;throw e.status===`rejected`?e.reason:e.status===`pending`?e:(e.status=`pending`,e.then(t=>{e.status=`fulfilled`,e.value=t},t=>{e.status=`rejected`,e.reason=t}),e)}function Wi(e){return L(Object.assign(e,{domainToMappings:{"bo._base_domain_":[{srcPath:`/back-in-stock-service`,destPath:``}],"wixbo.ai":[{srcPath:`/back-in-stock-service`,destPath:``}],"wix-bo.com":[{srcPath:`/back-in-stock-service`,destPath:``}],"www.wixapis.com":[{srcPath:`/back-in-stock-service`,destPath:``}],_:[{srcPath:`/v1/back-in-stock-notification-requests`,destPath:`/v1/back-in-stock-notification-requests`}],"*.dev.wix-code.com":[{srcPath:`/v1/back-in-stock-notification-requests`,destPath:`/v1/back-in-stock-notification-requests`}]}}))}var Gi=`@wix/auto_sdk_ecom_back-in-stock-notifications`;function Ki(e){function t({host:t}){let n=P(e,[{transformFn:rt,paths:[{path:`request.createdDate`},{path:`itemDetails.image.urlExpirationDate`}]},{transformFn:dn,paths:[{path:`itemDetails.image.focalPoint.x`},{path:`itemDetails.image.focalPoint.y`}]}]);return{entityFqdn:`wix.ecom.v1.back_in_stock_notification_request`,method:`POST`,methodFqn:`com.wixpress.ecom.back.in.stock.BackInStockNotificationRequestService.CreateBackInStockNotificationRequest`,packageName:Gi,migrationOptions:{optInTransformResponse:!0},url:Wi({protoPath:`/v1/back-in-stock-notification-requests`,data:n,host:t}),data:n,transformResponse:e=>P(e,[{transformFn:N,paths:[{path:`request.createdDate`}]}])}}return t}async function qi(e,t){let{httpClient:n,sideEffects:r}=arguments[2],i=Ki(P(j({request:e,itemDetails:t}),[{transformFn:er,paths:[{path:`itemDetails.image`}]}]));r?.onSiteCall?.();try{let e=await n.request(i);return r?.onSuccess?.(e),M(e.data)?.request}catch(e){let t=F(e,{spreadPathsToArguments:{},explicitPathsToArguments:{request:`$[0]`,itemDetails:`$[1]`},singleArgumentUnchanged:!1},[`request`,`itemDetails`]);throw r?.onError?.(e),t}}({...Vn()});function Ji(e){return(t,n)=>qi(t,n,{httpClient:e})}var Yi=y(`wix.ecom.v1.back_in_stock_notification_request_created`,!0,e=>M(P(e,[{transformFn:N,paths:[{path:`entity.createdDate`},{path:`metadata.eventTime`}]}])))(),Xi=y(`wix.ecom.v1.back_in_stock_notification_request_deleted`,!0,e=>M(P(e,[{transformFn:N,paths:[{path:`undefined.createdDate`},{path:`metadata.eventTime`}]}])))(),Zi=y(`wix.ecom.v1.back_in_stock_notification_request_updated`,!0,e=>M(P(e,[{transformFn:N,paths:[{path:`entity.createdDate`},{path:`metadata.eventTime`}]}])))(),Qi=I(Ji);R(Yi),R(Xi),R(Zi);function $i(e){return L(Object.assign(e,{domainToMappings:{"bo._base_domain_":[{srcPath:`/back-in-stock-service`,destPath:``}],"wixbo.ai":[{srcPath:`/back-in-stock-service`,destPath:``}],"wix-bo.com":[{srcPath:`/back-in-stock-service`,destPath:``}],"www.wixapis.com":[{srcPath:`/back-in-stock-service`,destPath:``}],_:[{srcPath:`/v1/back-in-stock-notification-requests`,destPath:`/v1/back-in-stock-notification-requests`}],"*.dev.wix-code.com":[{srcPath:`/v1/back-in-stock-notification-requests`,destPath:`/v1/back-in-stock-notification-requests`}]}}))}var ea=`@wix/auto_sdk_ecom_back-in-stock-settings`;function ta(e){function t({host:t}){return{entityFqdn:`wix.ecom.v1.back_in_stock_settings`,method:`PUT`,methodFqn:`com.wixpress.ecom.back.in.stock.BackInStockSettingsService.GetSettings`,packageName:ea,migrationOptions:{optInTransformResponse:!0},url:$i({protoPath:`/v1/back-in-stock-notification-requests/settings`,data:e,host:t}),data:e}}return t}async function na(){let{httpClient:e,sideEffects:t}=arguments[0],n=ta(j({}));t?.onSiteCall?.();try{let r=await e.request(n);return t?.onSuccess?.(r),M(r.data)}catch(e){let n=F(e,{spreadPathsToArguments:{},explicitPathsToArguments:{},singleArgumentUnchanged:!1},[]);throw t?.onError?.(e),n}}function ra(e){return()=>na({httpClient:e})}var ia=I(ra);function aa(e){return L(Object.assign(e,{domainToMappings:{"api._api_base_domain_":[{srcPath:`/cart-v2`,destPath:``}],_:[{srcPath:`/_api/cart-v2`,destPath:``}],"*.dev.wix-code.com":[{srcPath:`/_api/cart-v2`,destPath:``}],"www._base_domain_":[{srcPath:`/_api/cart-v2`,destPath:``}],"editor._base_domain_":[{srcPath:`/_api/cart-v2`,destPath:``}],"blocks._base_domain_":[{srcPath:`/_api/cart-v2`,destPath:``}],"create.editorx":[{srcPath:`/_api/cart-v2`,destPath:``}],"apps._base_domain_":[{srcPath:`/_api/cart-v2`,destPath:``}],"manage._base_domain_":[{srcPath:`/_api/cart-v2`,destPath:``}],"bo._base_domain_":[{srcPath:`/_api/cart-v2`,destPath:``}],"wixbo.ai":[{srcPath:`/_api/cart-v2`,destPath:``}],"wix-bo.com":[{srcPath:`/_api/cart-v2`,destPath:``}],"www.wixapis.com":[{srcPath:`/ecom/v2/carts`,destPath:`/v2/carts`}],"editor.wixapps.net":[{srcPath:`/_api/cart-v2`,destPath:``}]}}))}var oa=`@wix/auto_sdk_ecom_cart-v-2`;function sa(e){function t({host:t}){let n=P(e,[{transformFn:rt,paths:[{path:`cart.createdDate`},{path:`cart.updatedDate`},{path:`cart.lineItems.source.catalogOverrideFields.image.urlExpirationDate`},{path:`cart.lineItems.attributes.image.urlExpirationDate`},{path:`cart.lineItems.attributes.subscriptionInfo.subscriptionSettings.startDate`},{path:`cart.lineItems.attributes.serviceProperties.scheduledDate`},{path:`cart.lineItems.attributes.serviceProperties.endDate`},{path:`catalogItems.catalogOverrideFields.image.urlExpirationDate`},{path:`customItems.attributes.image.urlExpirationDate`},{path:`customItems.attributes.serviceProperties.scheduledDate`},{path:`customItems.attributes.serviceProperties.endDate`},{path:`customItems.attributes.subscriptionInfo.subscriptionSettings.startDate`}]},{transformFn:dn,paths:[{path:`cart.lineItems.source.catalogOverrideFields.physicalProperties.weight`},{path:`cart.lineItems.attributes.physicalProperties.weight`},{path:`cart.deliveryInfo.address.geocode.latitude`},{path:`cart.deliveryInfo.address.geocode.longitude`},{path:`cart.paymentInfo.billingAddress.geocode.latitude`},{path:`cart.paymentInfo.billingAddress.geocode.longitude`},{path:`cart.legacyFields.discounts.merchantDiscount.percentage`},{path:`cart.tcAppliedDiscounts.merchantDiscount.percentage`},{path:`catalogItems.catalogOverrideFields.physicalProperties.weight`},{path:`customItems.attributes.physicalProperties.weight`}]}]);return{entityFqdn:`wix.ecom.v2.cart`,method:`POST`,methodFqn:`wix.ecom.cart.v2.CartService.CreateCart`,packageName:oa,migrationOptions:{optInTransformResponse:!0},url:aa({protoPath:`/v2/carts`,data:n,host:t}),data:n,transformResponse:e=>P(e,[{transformFn:N,paths:[{path:`cart.createdDate`},{path:`cart.updatedDate`},{path:`cart.lineItems.source.catalogOverrideFields.image.urlExpirationDate`},{path:`cart.lineItems.attributes.image.urlExpirationDate`},{path:`cart.lineItems.attributes.subscriptionInfo.subscriptionSettings.startDate`},{path:`cart.lineItems.attributes.serviceProperties.scheduledDate`},{path:`cart.lineItems.attributes.serviceProperties.endDate`}]},{transformFn:z,paths:[{path:`cart.lineItems.source.catalogOverrideFields.physicalProperties.weight`},{path:`cart.lineItems.attributes.physicalProperties.weight`},{path:`cart.deliveryInfo.address.geocode.latitude`},{path:`cart.deliveryInfo.address.geocode.longitude`},{path:`cart.paymentInfo.billingAddress.geocode.latitude`},{path:`cart.paymentInfo.billingAddress.geocode.longitude`},{path:`cart.legacyFields.discounts.merchantDiscount.percentage`},{path:`cart.tcAppliedDiscounts.merchantDiscount.percentage`}]}])}}return t}var ca=(e=>(e.UNSPECIFIED=`UNSPECIFIED`,e.WEB=`WEB`,e.POS=`POS`,e.EBAY=`EBAY`,e.AMAZON=`AMAZON`,e.OTHER_PLATFORM=`OTHER_PLATFORM`,e.WIX_APP_STORE=`WIX_APP_STORE`,e.WIX_INVOICES=`WIX_INVOICES`,e.BACKOFFICE_MERCHANT=`BACKOFFICE_MERCHANT`,e.WISH=`WISH`,e.CLASS_PASS=`CLASS_PASS`,e.GLOBAL_E=`GLOBAL_E`,e.FACEBOOK=`FACEBOOK`,e.ETSY=`ETSY`,e.TIKTOK=`TIKTOK`,e.FAIRE_COM=`FAIRE_COM`,e.PAYPAL_AGENTIC_CHECKOUT=`PAYPAL_AGENTIC_CHECKOUT`,e.STRIPE_AGENTIC_CHECKOUT=`STRIPE_AGENTIC_CHECKOUT`,e.WIX_INVOICES_PLATFORM=`WIX_INVOICES_PLATFORM`,e.UCP_AGENTIC_CHECKOUT=`UCP_AGENTIC_CHECKOUT`,e))(ca||{});async function la(e){let{httpClient:t,sideEffects:n}=arguments[1],r=sa(P(j({cart:e?.cart,catalogItems:e?.catalogItems,customItems:e?.customItems,coupons:e?.coupons,deliveryMethod:e?.deliveryMethod,giftCards:e?.giftCards}),[{transformFn:er,paths:[{path:`cart.lineItems.source.catalogOverrideFields.image`},{path:`cart.lineItems.attributes.image`},{path:`catalogItems.catalogOverrideFields.image`},{path:`customItems.attributes.image`}]},{transformFn:Or,paths:[{path:`cart.lineItems.attributes.url`},{path:`customItems.attributes.url`}]},{transformFn:fn,paths:[{path:`cart.deliveryInfo.address`},{path:`cart.paymentInfo.billingAddress`}]}]));n?.onSiteCall?.();try{let e=await t.request(r);return n?.onSuccess?.(e),M(P(e.data,[{transformFn:H,paths:[{path:`cart.lineItems.source.catalogOverrideFields.image`},{path:`cart.lineItems.attributes.image`}]},{transformFn:U,paths:[{path:`cart.lineItems.attributes.url`}]},{transformFn:pn,paths:[{path:`cart.deliveryInfo.address`},{path:`cart.paymentInfo.billingAddress`}]}]))?.cart}catch(e){let t=F(e,{spreadPathsToArguments:{},explicitPathsToArguments:{cart:`$[0].cart`,catalogItems:`$[0].catalogItems`,customItems:`$[0].customItems`,coupons:`$[0].coupons`,deliveryMethod:`$[0].deliveryMethod`,giftCards:`$[0].giftCards`},singleArgumentUnchanged:!1},[`options`]);throw n?.onError?.(e),t}}function ua(e){return t=>la(t,{httpClient:e})}var da=I(ua);function fa(e){return L(Object.assign(e,{domainToMappings:{"api._api_base_domain_":[{srcPath:`/cart-v2`,destPath:``}],_:[{srcPath:`/_api/cart-v2`,destPath:``}],"*.dev.wix-code.com":[{srcPath:`/_api/cart-v2`,destPath:``}],"www._base_domain_":[{srcPath:`/_api/cart-v2`,destPath:``}],"editor._base_domain_":[{srcPath:`/_api/cart-v2`,destPath:``}],"blocks._base_domain_":[{srcPath:`/_api/cart-v2`,destPath:``}],"create.editorx":[{srcPath:`/_api/cart-v2`,destPath:``}],"apps._base_domain_":[{srcPath:`/_api/cart-v2`,destPath:``}],"manage._base_domain_":[{srcPath:`/_api/cart-v2`,destPath:``}],"bo._base_domain_":[{srcPath:`/_api/cart-v2`,destPath:``}],"wixbo.ai":[{srcPath:`/_api/cart-v2`,destPath:``}],"wix-bo.com":[{srcPath:`/_api/cart-v2`,destPath:``}],"www.wixapis.com":[{srcPath:`/ecom/v2/carts`,destPath:`/v2/carts`}],"editor.wixapps.net":[{srcPath:`/_api/cart-v2`,destPath:``}]}}))}var pa=`@wix/auto_sdk_ecom_current-cart-v-2`;function ma(e){function t({host:t}){let n=P(e,[{transformFn:dn,paths:[{path:`catalogItems.catalogOverrideFields.physicalProperties.weight`},{path:`customItems.attributes.physicalProperties.weight`}]},{transformFn:rt,paths:[{path:`catalogItems.catalogOverrideFields.image.urlExpirationDate`},{path:`customItems.attributes.image.urlExpirationDate`},{path:`customItems.attributes.serviceProperties.scheduledDate`},{path:`customItems.attributes.serviceProperties.endDate`},{path:`customItems.attributes.subscriptionInfo.subscriptionSettings.startDate`}]}]);return{entityFqdn:`wix.ecom.v2.cart`,method:`POST`,methodFqn:`wix.ecom.cart.v2.CurrentCartService.AddLineItemsToCurrentCart`,packageName:pa,migrationOptions:{optInTransformResponse:!0},url:fa({protoPath:`/v2/carts/current/add-line-items`,data:n,host:t}),data:n,transformResponse:e=>P(e,[{transformFn:N,paths:[{path:`cart.createdDate`},{path:`cart.updatedDate`},{path:`cart.lineItems.source.catalogOverrideFields.image.urlExpirationDate`},{path:`cart.lineItems.attributes.image.urlExpirationDate`},{path:`cart.lineItems.attributes.subscriptionInfo.subscriptionSettings.startDate`},{path:`cart.lineItems.attributes.serviceProperties.scheduledDate`},{path:`cart.lineItems.attributes.serviceProperties.endDate`}]},{transformFn:z,paths:[{path:`cart.lineItems.source.catalogOverrideFields.physicalProperties.weight`},{path:`cart.lineItems.attributes.physicalProperties.weight`},{path:`cart.deliveryInfo.address.geocode.latitude`},{path:`cart.deliveryInfo.address.geocode.longitude`},{path:`cart.paymentInfo.billingAddress.geocode.latitude`},{path:`cart.paymentInfo.billingAddress.geocode.longitude`},{path:`cart.legacyFields.discounts.merchantDiscount.percentage`},{path:`cart.tcAppliedDiscounts.merchantDiscount.percentage`}]}])}}return t}async function ha(e){let{httpClient:t,sideEffects:n}=arguments[1],r=ma(P(j({catalogItems:e?.catalogItems,customItems:e?.customItems}),[{transformFn:er,paths:[{path:`catalogItems.catalogOverrideFields.image`},{path:`customItems.attributes.image`}]},{transformFn:Or,paths:[{path:`customItems.attributes.url`}]}]));n?.onSiteCall?.();try{let e=await t.request(r);return n?.onSuccess?.(e),M(P(e.data,[{transformFn:H,paths:[{path:`cart.lineItems.source.catalogOverrideFields.image`},{path:`cart.lineItems.attributes.image`}]},{transformFn:U,paths:[{path:`cart.lineItems.attributes.url`}]},{transformFn:pn,paths:[{path:`cart.deliveryInfo.address`},{path:`cart.paymentInfo.billingAddress`}]}]))}catch(e){let t=F(e,{spreadPathsToArguments:{},explicitPathsToArguments:{catalogItems:`$[0].catalogItems`,customItems:`$[0].customItems`},singleArgumentUnchanged:!1},[`options`]);throw n?.onError?.(e),t}}function ga(e){return t=>ha(t,{httpClient:e})}var _a=I(ga);async function va(e){await _a({catalogItems:[e]})}var ya={type:`invalid-purchase`,message:`This item can't be purchased.`};function ba(e){let t=e;return{type:`cart`,message:t?.message,details:t?.details}}function K(e){return e}var xa=K(`@wix/site-service-public-api-caller`),Sa=`215238eb-22a5-4c36-9e7b-e7c08025e04e`,Ca=`1380b703-ce81-ff05-f115-39571d94dfcd`;`${Sa}`,`${Sa}`;var q=function(e){return e.SIDE_CART=`ecom_side_cart`,e.CART=`shopping_cart`,e.CHECKOUT=`checkout`,e.PRODUCT_PAGE=`product-page-builder`,e.CATEGORY_PAGE=`category-page-builder`,e}({}),wa=()=>{let e=o();return{reloadCart:t(async()=>{if(typeof window<`u`)try{await e(xa).callPublicApi(Ca,`cart.reloadCart`,[])}catch{}},[e])}},Ta=K(`@wix/viewer-service-router`),Ea=K(`@wix/site-service-url`),Da=K(`@wix/site-service-editor-context`),Oa=K(`@wix/site-service-pages`),ka=()=>{let e=s(Ea),n=t((t,n)=>{let r=e.appSectionRelativeUrl(Sa,t,!0);if(r)return`./${r.replace(/^\//,``).replace(/\/$/,``)}/${encodeURIComponent(n)}`},[e]);return{getPageRelativeUrl:n,getPageAbsoluteUrl:t((t,r)=>{let i=n(t,r);if(i)return new URL(i,`${e.siteUrl.replace(/\/$/,``)}/`).href},[n,e])}},Aa=e=>{if(!e)return``;let t=new URLSearchParams(e).toString();return t?`?${t}`:``},ja=(e,t,n)=>{let r=`./${e.replace(/^\//,``)}`;return n?r:new URL(r,`${t.replace(/\/$/,``)}/`).href},Ma=()=>{let e=s(Ta),n=s(Ea),r=s(Da),i=s(Oa),{getPageRelativeUrl:a,getPageAbsoluteUrl:o}=ka();return{navigateToPage:t(async(t,i)=>{try{let a=n.appSectionRelativeUrl(Ca,t);if(!a)return!1;let o=`${a}${Aa(i)}`;return await e.navigateTo({href:ja(o,n.siteUrl,r.previewMode)}),!0}catch{return!1}},[e,n,r]),navigateToProductPage:t(async t=>{try{let n=r.previewMode?a(q.PRODUCT_PAGE,t):o(q.PRODUCT_PAGE,t);if(!n)throw Error(`Failed to resolve app section relative URL for the product page`);await e.navigateTo({href:n})}catch(e){console.error(`navigateToProductPage: failed to navigate to product "${t}"`,e)}},[e,r,a,o]),openLightbox:t(async t=>{try{let n=Object.entries(i.pages).find(([,e])=>e.popup&&e.appPageId===t)?.[0];return n?(await e.navigateTo({linkPopupId:n}),!0):!1}catch{return!1}},[e,i])}},J=function(e){return e.IDLE=`idle`,e.IN_PROGRESS=`in-progress`,e.SUCCESS=`success`,e}({}),Na=function(e){return e.NONE=`none`,e.NAVIGATE_TO_CART=`navigate-to-cart`,e.OPEN_SIDE_CART=`open-side-cart`,e}({}),Pa=()=>{let[e,n]=r(J.IDLE),{navigateToPage:i,openLightbox:a}=Ma(),{reloadCart:o}=wa(),s=t(async e=>{switch(e){case Na.NAVIGATE_TO_CART:await i(q.CART);return;case Na.OPEN_SIDE_CART:await a(q.SIDE_CART);return;case Na.NONE:default:return}},[i,a]);return{addToCart:t(async(e,t)=>{n(J.IN_PROGRESS);try{await va(e)}catch(e){return n(J.IDLE),{ok:!1,error:ba(e)}}try{await o(),n(J.SUCCESS),await s(t),setTimeout(()=>n(J.IDLE),2e3)}catch{n(J.IDLE)}return{ok:!0}},[o,s]),addToCartState:e,reloadCart:o}};async function Fa(e){let t=await da({cart:{source:{channelType:ca.WEB}},catalogItems:[e]});if(!t._id)throw Error(`missing checkout id`);return t._id}var Ia=function(e){return e.IDLE=`idle`,e.IN_PROGRESS=`in-progress`,e}({}),La=()=>{let{navigateToPage:e}=Ma(),[n,i]=r(Ia.IDLE);return{buyNowState:n,buyNow:t(async t=>{i(Ia.IN_PROGRESS);try{let n=await Fa(t);return await e(q.CHECKOUT,{checkoutId:n})?{ok:!0}:{ok:!1,error:ba(Error(`Failed to navigate to checkout`))}}catch(e){return{ok:!1,error:ba(e)}}finally{i(Ia.IDLE)}},[e])}};function Ra(e){let{product:t,selectedVariant:n,userSelections:r,isPreOrder:i}=e;return{catalogReference:{appId:Sa,catalogItemId:t.id,options:za({product:t,selectedVariant:n,userSelections:r,isPreOrder:i})},quantity:r.quantity}}var za=({product:e,selectedVariant:t,userSelections:n,isPreOrder:r})=>{let i=Ba(e,t.choices),{choiceBasedModifiers:a,customTextFields:o}=Va(e,n.selectedModifiers),s={...i,...a},{selectedSubscriptionPlanId:c}=n,l={variantId:t.id,options:s};return Object.keys(o).length>0&&(l.customTextFields=o),Ha(c)&&(l.subscriptionOptionId=c),r&&(l.preOrderRequested=!0),l},Ba=(e,t)=>{let n={};for(let[r,i]of Object.entries(t)){let t=e.options.find(e=>e.id===r),a=t?.choices.find(e=>e.choiceId===i);t&&a&&(n[t.key]=a.key)}return n},Va=(e,t)=>{let n={},r={};for(let i of Object.values(e.modifiers))if(i.modifierRenderType===Mr.FREE_TEXT){let e=i.freeTextSettings?.key;e&&(r[e]=t[i.id]??``)}else{let e=t[i.id],r=i.choices?.find(t=>t.choiceId===e);r&&(n[i.key]=r.key)}return{choiceBasedModifiers:n,customTextFields:r}},Ha=e=>e!==void 0&&e!==`one-time`;function Ua(e,r,i){let{selectedVariant:a,selectedModifiers:o,selectedSubscriptionPlanId:s,quantity:c,isSelectionValid:l,setHasAttemptedSubmit:u}=r,{addToCart:d,addToCartState:f}=Pa(),{buyNow:p,buyNowState:m}=La(),h=i.isPreOrderState||i.isInStock,g=t(async t=>!h||(u(!0),!l||!a)?{ok:!1,error:ya}:d(Ra({product:e,selectedVariant:a,userSelections:{selectedModifiers:o,selectedSubscriptionPlanId:s,quantity:c},isPreOrder:i.isPreOrderState}),t??Na.NONE),[h,i.isPreOrderState,l,u,e,a,o,s,c,d]),_=t(async()=>!h||(u(!0),!l||!a)?{ok:!1,error:ya}:p(Ra({product:e,selectedVariant:a,userSelections:{selectedModifiers:o,selectedSubscriptionPlanId:s,quantity:c},isPreOrder:i.isPreOrderState})),[h,i.isPreOrderState,l,u,e,a,o,s,c,p]);return n(()=>({addToCartState:f,buyNowState:m,handleAddToCart:g,handleBuyNow:_}),[f,m,g,_])}function Wa(e){return Ka(e)??99999}function Ga(e,t){return Math.min(e,Math.max(t,1))}function Ka(e){if(!e||!e.trackQuantity)return;let{availabilityStatus:t,inventoryQuantity:n,preorderInfo:r}=e,i=t===`PREORDER`?r?.quantity:n;if(i!=null)return Math.max(0,i)}function qa(e){let{availabilityStatus:t,preorderAvailability:n}=e??{},r=t!==Nr.OUT_OF_STOCK;return{isInStock:r,isPreOrderState:n===Pr.ALL_VARIANTS||n===Pr.SOME_VARIANTS&&!r}}function Ja(e,t){return t?{isInStock:t.availabilityStatus===gr.IN_STOCK,isPreOrderState:t.availabilityStatus===gr.PREORDER}:qa(e.inventory)}function Ya(e,t){return n(()=>{let{isInStock:n,isPreOrderState:r}=Ja(e,t);return{isInStock:n,isPreOrderState:r,preOrderMessage:r?t?.preorderInfo?.message:void 0,remainingItemCount:Ka(t)}},[e.inventory,t])}var Xa=h(((e,t)=>{t.exports=typeof window==`object`&&window&&window.Object===Object&&window})),Y=h(((e,t)=>{var n=Xa(),r=typeof self==`object`&&self&&self.Object===Object&&self;t.exports=n||r||Function(`return this`)()})),Za=h(((e,t)=>{t.exports=Y().Symbol})),Qa=h(((e,t)=>{var n=Za(),r=Object.prototype,i=r.hasOwnProperty,a=r.toString,o=n?n.toStringTag:void 0;function s(e){var t=i.call(e,o),n=e[o];try{e[o]=void 0;var r=!0}catch{}var s=a.call(e);return r&&(t?e[o]=n:delete e[o]),s}t.exports=s})),$a=h(((e,t)=>{var n=Object.prototype.toString;function r(e){return n.call(e)}t.exports=r})),eo=h(((e,t)=>{var n=Za(),r=Qa(),i=$a(),a=`[object Null]`,o=`[object Undefined]`,s=n?n.toStringTag:void 0;function c(e){return e==null?e===void 0?o:a:s&&s in Object(e)?r(e):i(e)}t.exports=c})),to=h(((e,t)=>{function n(e){return typeof e==`object`&&!!e}t.exports=n})),no=h(((e,t)=>{var n=eo(),r=to(),i=`[object Symbol]`;function a(e){return typeof e==`symbol`||r(e)&&n(e)==i}t.exports=a})),ro=h(((e,t)=>{var n=no();function r(e,t,r){for(var i=-1,a=e.length;++i<a;){var o=e[i],s=t(o);if(s!=null&&(c===void 0?s===s&&!n(s):r(s,c)))var c=s,l=o}return l}t.exports=r})),io=h(((e,t)=>{function n(e,t){return e>t}t.exports=n})),ao=h(((e,t)=>{function n(e){return e}t.exports=n})),oo=h(((e,t)=>{var n=ro(),r=io(),i=ao();function a(e){return e&&e.length?n(e,i,r):void 0}t.exports=a})),so=h(((e,t)=>{function n(){this.__data__=[],this.size=0}t.exports=n})),co=h(((e,t)=>{function n(e,t){return e===t||e!==e&&t!==t}t.exports=n})),lo=h(((e,t)=>{var n=co();function r(e,t){for(var r=e.length;r--;)if(n(e[r][0],t))return r;return-1}t.exports=r})),uo=h(((e,t)=>{var n=lo(),r=Array.prototype.splice;function i(e){var t=this.__data__,i=n(t,e);return i<0?!1:(i==t.length-1?t.pop():r.call(t,i,1),--this.size,!0)}t.exports=i})),fo=h(((e,t)=>{var n=lo();function r(e){var t=this.__data__,r=n(t,e);return r<0?void 0:t[r][1]}t.exports=r})),po=h(((e,t)=>{var n=lo();function r(e){return n(this.__data__,e)>-1}t.exports=r})),mo=h(((e,t)=>{var n=lo();function r(e,t){var r=this.__data__,i=n(r,e);return i<0?(++this.size,r.push([e,t])):r[i][1]=t,this}t.exports=r})),ho=h(((e,t)=>{var n=so(),r=uo(),i=fo(),a=po(),o=mo();function s(e){var t=-1,n=e==null?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}s.prototype.clear=n,s.prototype.delete=r,s.prototype.get=i,s.prototype.has=a,s.prototype.set=o,t.exports=s})),go=h(((e,t)=>{var n=ho();function r(){this.__data__=new n,this.size=0}t.exports=r})),_o=h(((e,t)=>{function n(e){var t=this.__data__,n=t.delete(e);return this.size=t.size,n}t.exports=n})),vo=h(((e,t)=>{function n(e){return this.__data__.get(e)}t.exports=n})),yo=h(((e,t)=>{function n(e){return this.__data__.has(e)}t.exports=n})),bo=h(((e,t)=>{function n(e){var t=typeof e;return e!=null&&(t==`object`||t==`function`)}t.exports=n})),xo=h(((e,t)=>{var n=eo(),r=bo(),i=`[object AsyncFunction]`,a=`[object Function]`,o=`[object GeneratorFunction]`,s=`[object Proxy]`;function c(e){if(!r(e))return!1;var t=n(e);return t==a||t==o||t==i||t==s}t.exports=c})),So=h(((e,t)=>{t.exports=Y()[`__core-js_shared__`]})),Co=h(((e,t)=>{var n=So(),r=function(){var e=/[^.]+$/.exec(n&&n.keys&&n.keys.IE_PROTO||``);return e?`Symbol(src)_1.`+e:``}();function i(e){return!!r&&r in e}t.exports=i})),wo=h(((e,t)=>{var n=Function.prototype.toString;function r(e){if(e!=null){try{return n.call(e)}catch{}try{return e+``}catch{}}return``}t.exports=r})),To=h(((e,t)=>{var n=xo(),r=Co(),i=bo(),a=wo(),o=/[\\^$.*+?()[\]{}|]/g,s=/^\[object .+?Constructor\]$/,c=Function.prototype,l=Object.prototype,u=c.toString,d=l.hasOwnProperty,f=RegExp(`^`+u.call(d).replace(o,`\\$&`).replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,`$1.*?`)+`$`);function p(e){return!i(e)||r(e)?!1:(n(e)?f:s).test(a(e))}t.exports=p})),Eo=h(((e,t)=>{function n(e,t){return e?.[t]}t.exports=n})),X=h(((e,t)=>{var n=To(),r=Eo();function i(e,t){var i=r(e,t);return n(i)?i:void 0}t.exports=i})),Do=h(((e,t)=>{t.exports=X()(Y(),`Map`)})),Oo=h(((e,t)=>{t.exports=X()(Object,`create`)})),ko=h(((e,t)=>{var n=Oo();function r(){this.__data__=n?n(null):{},this.size=0}t.exports=r})),Ao=h(((e,t)=>{function n(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=+!!t,t}t.exports=n})),jo=h(((e,t)=>{var n=Oo(),r=`__lodash_hash_undefined__`,i=Object.prototype.hasOwnProperty;function a(e){var t=this.__data__;if(n){var a=t[e];return a===r?void 0:a}return i.call(t,e)?t[e]:void 0}t.exports=a})),Mo=h(((e,t)=>{var n=Oo(),r=Object.prototype.hasOwnProperty;function i(e){var t=this.__data__;return n?t[e]!==void 0:r.call(t,e)}t.exports=i})),No=h(((e,t)=>{var n=Oo(),r=`__lodash_hash_undefined__`;function i(e,t){var i=this.__data__;return this.size+=+!this.has(e),i[e]=n&&t===void 0?r:t,this}t.exports=i})),Po=h(((e,t)=>{var n=ko(),r=Ao(),i=jo(),a=Mo(),o=No();function s(e){var t=-1,n=e==null?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}s.prototype.clear=n,s.prototype.delete=r,s.prototype.get=i,s.prototype.has=a,s.prototype.set=o,t.exports=s})),Fo=h(((e,t)=>{var n=Po(),r=ho(),i=Do();function a(){this.size=0,this.__data__={hash:new n,map:new(i||r),string:new n}}t.exports=a})),Io=h(((e,t)=>{function n(e){var t=typeof e;return t==`string`||t==`number`||t==`symbol`||t==`boolean`?e!==`__proto__`:e===null}t.exports=n})),Lo=h(((e,t)=>{var n=Io();function r(e,t){var r=e.__data__;return n(t)?r[typeof t==`string`?`string`:`hash`]:r.map}t.exports=r})),Ro=h(((e,t)=>{var n=Lo();function r(e){var t=n(this,e).delete(e);return this.size-=+!!t,t}t.exports=r})),zo=h(((e,t)=>{var n=Lo();function r(e){return n(this,e).get(e)}t.exports=r})),Bo=h(((e,t)=>{var n=Lo();function r(e){return n(this,e).has(e)}t.exports=r})),Vo=h(((e,t)=>{var n=Lo();function r(e,t){var r=n(this,e),i=r.size;return r.set(e,t),this.size+=r.size==i?0:1,this}t.exports=r})),Ho=h(((e,t)=>{var n=Fo(),r=Ro(),i=zo(),a=Bo(),o=Vo();function s(e){var t=-1,n=e==null?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}s.prototype.clear=n,s.prototype.delete=r,s.prototype.get=i,s.prototype.has=a,s.prototype.set=o,t.exports=s})),Uo=h(((e,t)=>{var n=ho(),r=Do(),i=Ho(),a=200;function o(e,t){var o=this.__data__;if(o instanceof n){var s=o.__data__;if(!r||s.length<a-1)return s.push([e,t]),this.size=++o.size,this;o=this.__data__=new i(s)}return o.set(e,t),this.size=o.size,this}t.exports=o})),Wo=h(((e,t)=>{var n=ho(),r=go(),i=_o(),a=vo(),o=yo(),s=Uo();function c(e){var t=this.__data__=new n(e);this.size=t.size}c.prototype.clear=r,c.prototype.delete=i,c.prototype.get=a,c.prototype.has=o,c.prototype.set=s,t.exports=c})),Go=h(((e,t)=>{function n(e){return this.__data__.set(e,`__lodash_hash_undefined__`),this}t.exports=n})),Ko=h(((e,t)=>{function n(e){return this.__data__.has(e)}t.exports=n})),qo=h(((e,t)=>{var n=Ho(),r=Go(),i=Ko();function a(e){var t=-1,r=e==null?0:e.length;for(this.__data__=new n;++t<r;)this.add(e[t])}a.prototype.add=a.prototype.push=r,a.prototype.has=i,t.exports=a})),Jo=h(((e,t)=>{function n(e,t){for(var n=-1,r=e==null?0:e.length;++n<r;)if(t(e[n],n,e))return!0;return!1}t.exports=n})),Yo=h(((e,t)=>{function n(e,t){return e.has(t)}t.exports=n})),Xo=h(((e,t)=>{var n=qo(),r=Jo(),i=Yo(),a=1,o=2;function s(e,t,s,c,l,u){var d=s&a,f=e.length,p=t.length;if(f!=p&&!(d&&p>f))return!1;var m=u.get(e),h=u.get(t);if(m&&h)return m==t&&h==e;var g=-1,_=!0,v=s&o?new n:void 0;for(u.set(e,t),u.set(t,e);++g<f;){var y=e[g],b=t[g];if(c)var x=d?c(b,y,g,t,e,u):c(y,b,g,e,t,u);if(x!==void 0){if(x)continue;_=!1;break}if(v){if(!r(t,function(e,t){if(!i(v,t)&&(y===e||l(y,e,s,c,u)))return v.push(t)})){_=!1;break}}else if(!(y===b||l(y,b,s,c,u))){_=!1;break}}return u.delete(e),u.delete(t),_}t.exports=s})),Zo=h(((e,t)=>{t.exports=Y().Uint8Array})),Qo=h(((e,t)=>{function n(e){var t=-1,n=Array(e.size);return e.forEach(function(e,r){n[++t]=[r,e]}),n}t.exports=n})),$o=h(((e,t)=>{function n(e){var t=-1,n=Array(e.size);return e.forEach(function(e){n[++t]=e}),n}t.exports=n})),es=h(((e,t)=>{var n=Za(),r=Zo(),i=co(),a=Xo(),o=Qo(),s=$o(),c=1,l=2,u=`[object Boolean]`,d=`[object Date]`,f=`[object Error]`,p=`[object Map]`,m=`[object Number]`,h=`[object RegExp]`,g=`[object Set]`,_=`[object String]`,v=`[object Symbol]`,y=`[object ArrayBuffer]`,b=`[object DataView]`,x=n?n.prototype:void 0,S=x?x.valueOf:void 0;function C(e,t,n,x,C,w,T){switch(n){case b:if(e.byteLength!=t.byteLength||e.byteOffset!=t.byteOffset)return!1;e=e.buffer,t=t.buffer;case y:return!(e.byteLength!=t.byteLength||!w(new r(e),new r(t)));case u:case d:case m:return i(+e,+t);case f:return e.name==t.name&&e.message==t.message;case h:case _:return e==t+``;case p:var E=o;case g:var D=x&c;if(E||=s,e.size!=t.size&&!D)return!1;var O=T.get(e);if(O)return O==t;x|=l,T.set(e,t);var k=a(E(e),E(t),x,C,w,T);return T.delete(e),k;case v:if(S)return S.call(e)==S.call(t)}return!1}t.exports=C})),ts=h(((e,t)=>{function n(e,t){for(var n=-1,r=t.length,i=e.length;++n<r;)e[i+n]=t[n];return e}t.exports=n})),Z=h(((e,t)=>{t.exports=Array.isArray})),ns=h(((e,t)=>{var n=ts(),r=Z();function i(e,t,i){var a=t(e);return r(e)?a:n(a,i(e))}t.exports=i})),rs=h(((e,t)=>{function n(e,t){for(var n=-1,r=e==null?0:e.length,i=0,a=[];++n<r;){var o=e[n];t(o,n,e)&&(a[i++]=o)}return a}t.exports=n})),is=h(((e,t)=>{function n(){return[]}t.exports=n})),as=h(((e,t)=>{var n=rs(),r=is(),i=Object.prototype.propertyIsEnumerable,a=Object.getOwnPropertySymbols;t.exports=a?function(e){return e==null?[]:(e=Object(e),n(a(e),function(t){return i.call(e,t)}))}:r})),os=h(((e,t)=>{function n(e,t){for(var n=-1,r=Array(e);++n<e;)r[n]=t(n);return r}t.exports=n})),ss=h(((e,t)=>{var n=eo(),r=to(),i=`[object Arguments]`;function a(e){return r(e)&&n(e)==i}t.exports=a})),cs=h(((e,t)=>{var n=ss(),r=to(),i=Object.prototype,a=i.hasOwnProperty,o=i.propertyIsEnumerable;t.exports=n(function(){return arguments}())?n:function(e){return r(e)&&a.call(e,`callee`)&&!o.call(e,`callee`)}})),ls=h(((e,t)=>{function n(){return!1}t.exports=n})),us=h(((e,t)=>{var n=Y(),r=ls(),i=typeof e==`object`&&e&&!e.nodeType&&e,a=i&&typeof t==`object`&&t&&!t.nodeType&&t,o=a&&a.exports===i?n.Buffer:void 0;t.exports=(o?o.isBuffer:void 0)||r})),ds=h(((e,t)=>{var n=/^(?:0|[1-9]\d*)$/;function r(e,t){var r=typeof e;return t??=9007199254740991,!!t&&(r==`number`||r!=`symbol`&&n.test(e))&&e>-1&&e%1==0&&e<t}t.exports=r})),fs=h(((e,t)=>{function n(e){return typeof e==`number`&&e>-1&&e%1==0&&e<=9007199254740991}t.exports=n})),ps=h(((e,t)=>{var n=eo(),r=fs(),i=to(),a=`[object Arguments]`,o=`[object Array]`,s=`[object Boolean]`,c=`[object Date]`,l=`[object Error]`,u=`[object Function]`,d=`[object Map]`,f=`[object Number]`,p=`[object Object]`,m=`[object RegExp]`,h=`[object Set]`,g=`[object String]`,_=`[object WeakMap]`,v=`[object ArrayBuffer]`,y=`[object DataView]`,b=`[object Float32Array]`,x=`[object Float64Array]`,S=`[object Int8Array]`,C=`[object Int16Array]`,w=`[object Int32Array]`,T=`[object Uint8Array]`,E=`[object Uint8ClampedArray]`,D=`[object Uint16Array]`,O=`[object Uint32Array]`,k={};k[b]=k[x]=k[S]=k[C]=k[w]=k[T]=k[E]=k[D]=k[O]=!0,k[a]=k[o]=k[v]=k[s]=k[y]=k[c]=k[l]=k[u]=k[d]=k[f]=k[p]=k[m]=k[h]=k[g]=k[_]=!1;function ee(e){return i(e)&&r(e.length)&&!!k[n(e)]}t.exports=ee})),ms=h(((e,t)=>{function n(e){return function(t){return e(t)}}t.exports=n})),hs=h(((e,t)=>{var n=Xa(),r=typeof e==`object`&&e&&!e.nodeType&&e,i=r&&typeof t==`object`&&t&&!t.nodeType&&t,a=i&&i.exports===r&&n.process;t.exports=function(){try{return i&&i.require&&i.require(`util`).types||a&&a.binding&&a.binding(`util`)}catch{}}()})),gs=h(((e,t)=>{var n=ps(),r=ms(),i=hs(),a=i&&i.isTypedArray;t.exports=a?r(a):n})),_s=h(((e,t)=>{var n=os(),r=cs(),i=Z(),a=us(),o=ds(),s=gs(),c=Object.prototype.hasOwnProperty;function l(e,t){var l=i(e),u=!l&&r(e),d=!l&&!u&&a(e),f=!l&&!u&&!d&&s(e),p=l||u||d||f,m=p?n(e.length,String):[],h=m.length;for(var g in e)(t||c.call(e,g))&&!(p&&(g==`length`||d&&(g==`offset`||g==`parent`)||f&&(g==`buffer`||g==`byteLength`||g==`byteOffset`)||o(g,h)))&&m.push(g);return m}t.exports=l})),vs=h(((e,t)=>{var n=Object.prototype;function r(e){var t=e&&e.constructor;return e===(typeof t==`function`&&t.prototype||n)}t.exports=r})),ys=h(((e,t)=>{function n(e,t){return function(n){return e(t(n))}}t.exports=n})),bs=h(((e,t)=>{t.exports=ys()(Object.keys,Object)})),xs=h(((e,t)=>{var n=vs(),r=bs(),i=Object.prototype.hasOwnProperty;function a(e){if(!n(e))return r(e);var t=[];for(var a in Object(e))i.call(e,a)&&a!=`constructor`&&t.push(a);return t}t.exports=a})),Ss=h(((e,t)=>{var n=xo(),r=fs();function i(e){return e!=null&&r(e.length)&&!n(e)}t.exports=i})),Cs=h(((e,t)=>{var n=_s(),r=xs(),i=Ss();function a(e){return i(e)?n(e):r(e)}t.exports=a})),ws=h(((e,t)=>{var n=ns(),r=as(),i=Cs();function a(e){return n(e,i,r)}t.exports=a})),Ts=h(((e,t)=>{var n=ws(),r=1,i=Object.prototype.hasOwnProperty;function a(e,t,a,o,s,c){var l=a&r,u=n(e),d=u.length;if(d!=n(t).length&&!l)return!1;for(var f=d;f--;){var p=u[f];if(!(l?p in t:i.call(t,p)))return!1}var m=c.get(e),h=c.get(t);if(m&&h)return m==t&&h==e;var g=!0;c.set(e,t),c.set(t,e);for(var _=l;++f<d;){p=u[f];var v=e[p],y=t[p];if(o)var b=l?o(y,v,p,t,e,c):o(v,y,p,e,t,c);if(!(b===void 0?v===y||s(v,y,a,o,c):b)){g=!1;break}_||=p==`constructor`}if(g&&!_){var x=e.constructor,S=t.constructor;x!=S&&`constructor`in e&&`constructor`in t&&!(typeof x==`function`&&x instanceof x&&typeof S==`function`&&S instanceof S)&&(g=!1)}return c.delete(e),c.delete(t),g}t.exports=a})),Es=h(((e,t)=>{t.exports=X()(Y(),`DataView`)})),Ds=h(((e,t)=>{t.exports=X()(Y(),`Promise`)})),Os=h(((e,t)=>{t.exports=X()(Y(),`Set`)})),ks=h(((e,t)=>{t.exports=X()(Y(),`WeakMap`)})),As=h(((e,t)=>{var n=Es(),r=Do(),i=Ds(),a=Os(),o=ks(),s=eo(),c=wo(),l=`[object Map]`,u=`[object Object]`,d=`[object Promise]`,f=`[object Set]`,p=`[object WeakMap]`,m=`[object DataView]`,h=c(n),g=c(r),_=c(i),v=c(a),y=c(o),b=s;(n&&b(new n(new ArrayBuffer(1)))!=m||r&&b(new r)!=l||i&&b(i.resolve())!=d||a&&b(new a)!=f||o&&b(new o)!=p)&&(b=function(e){var t=s(e),n=t==u?e.constructor:void 0,r=n?c(n):``;if(r)switch(r){case h:return m;case g:return l;case _:return d;case v:return f;case y:return p}return t}),t.exports=b})),js=h(((e,t)=>{var n=Wo(),r=Xo(),i=es(),a=Ts(),o=As(),s=Z(),c=us(),l=gs(),u=1,d=`[object Arguments]`,f=`[object Array]`,p=`[object Object]`,m=Object.prototype.hasOwnProperty;function h(e,t,h,g,_,v){var y=s(e),b=s(t),x=y?f:o(e),S=b?f:o(t);x=x==d?p:x,S=S==d?p:S;var C=x==p,w=S==p,T=x==S;if(T&&c(e)){if(!c(t))return!1;y=!0,C=!1}if(T&&!C)return v||=new n,y||l(e)?r(e,t,h,g,_,v):i(e,t,x,h,g,_,v);if(!(h&u)){var E=C&&m.call(e,`__wrapped__`),D=w&&m.call(t,`__wrapped__`);if(E||D){var O=E?e.value():e,k=D?t.value():t;return v||=new n,_(O,k,h,g,v)}}return T?(v||=new n,a(e,t,h,g,_,v)):!1}t.exports=h})),Ms=h(((e,t)=>{var n=js(),r=to();function i(e,t,a,o,s){return e===t?!0:e==null||t==null||!r(e)&&!r(t)?e!==e&&t!==t:n(e,t,a,o,i,s)}t.exports=i})),Ns=h(((e,t)=>{var n=Wo(),r=Ms(),i=1,a=2;function o(e,t,o,s){var c=o.length,l=c,u=!s;if(e==null)return!l;for(e=Object(e);c--;){var d=o[c];if(u&&d[2]?d[1]!==e[d[0]]:!(d[0]in e))return!1}for(;++c<l;){d=o[c];var f=d[0],p=e[f],m=d[1];if(u&&d[2]){if(p===void 0&&!(f in e))return!1}else{var h=new n;if(s)var g=s(p,m,f,e,t,h);if(!(g===void 0?r(m,p,i|a,s,h):g))return!1}}return!0}t.exports=o})),Ps=h(((e,t)=>{var n=bo();function r(e){return e===e&&!n(e)}t.exports=r})),Fs=h(((e,t)=>{var n=Ps(),r=Cs();function i(e){for(var t=r(e),i=t.length;i--;){var a=t[i],o=e[a];t[i]=[a,o,n(o)]}return t}t.exports=i})),Is=h(((e,t)=>{function n(e,t){return function(n){return n!=null&&n[e]===t&&(t!==void 0||e in Object(n))}}t.exports=n})),Ls=h(((e,t)=>{var n=Ns(),r=Fs(),i=Is();function a(e){var t=r(e);return t.length==1&&t[0][2]?i(t[0][0],t[0][1]):function(r){return r===e||n(r,e,t)}}t.exports=a})),Rs=h(((e,t)=>{var n=Z(),r=no(),i=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,a=/^\w*$/;function o(e,t){if(n(e))return!1;var o=typeof e;return o==`number`||o==`symbol`||o==`boolean`||e==null||r(e)?!0:a.test(e)||!i.test(e)||t!=null&&e in Object(t)}t.exports=o})),zs=h(((e,t)=>{var n=Ho(),r=`Expected a function`;function i(e,t){if(typeof e!=`function`||t!=null&&typeof t!=`function`)throw TypeError(r);var a=function(){var n=arguments,r=t?t.apply(this,n):n[0],i=a.cache;if(i.has(r))return i.get(r);var o=e.apply(this,n);return a.cache=i.set(r,o)||i,o};return a.cache=new(i.Cache||n),a}i.Cache=n,t.exports=i})),Bs=h(((e,t)=>{var n=zs(),r=500;function i(e){var t=n(e,function(e){return i.size===r&&i.clear(),e}),i=t.cache;return t}t.exports=i})),Vs=h(((e,t)=>{var n=Bs(),r=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,i=/\\(\\)?/g;t.exports=n(function(e){var t=[];return e.charCodeAt(0)===46&&t.push(``),e.replace(r,function(e,n,r,a){t.push(r?a.replace(i,`$1`):n||e)}),t})})),Hs=h(((e,t)=>{function n(e,t){for(var n=-1,r=e==null?0:e.length,i=Array(r);++n<r;)i[n]=t(e[n],n,e);return i}t.exports=n})),Us=h(((e,t)=>{var n=Za(),r=Hs(),i=Z(),a=no(),o=1/0,s=n?n.prototype:void 0,c=s?s.toString:void 0;function l(e){if(typeof e==`string`)return e;if(i(e))return r(e,l)+``;if(a(e))return c?c.call(e):``;var t=e+``;return t==`0`&&1/e==-o?`-0`:t}t.exports=l})),Ws=h(((e,t)=>{var n=Us();function r(e){return e==null?``:n(e)}t.exports=r})),Gs=h(((e,t)=>{var n=Z(),r=Rs(),i=Vs(),a=Ws();function o(e,t){return n(e)?e:r(e,t)?[e]:i(a(e))}t.exports=o})),Ks=h(((e,t)=>{var n=no(),r=1/0;function i(e){if(typeof e==`string`||n(e))return e;var t=e+``;return t==`0`&&1/e==-r?`-0`:t}t.exports=i})),qs=h(((e,t)=>{var n=Gs(),r=Ks();function i(e,t){t=n(t,e);for(var i=0,a=t.length;e!=null&&i<a;)e=e[r(t[i++])];return i&&i==a?e:void 0}t.exports=i})),Js=h(((e,t)=>{var n=qs();function r(e,t,r){var i=e==null?void 0:n(e,t);return i===void 0?r:i}t.exports=r})),Ys=h(((e,t)=>{function n(e,t){return e!=null&&t in Object(e)}t.exports=n})),Xs=h(((e,t)=>{var n=Gs(),r=cs(),i=Z(),a=ds(),o=fs(),s=Ks();function c(e,t,c){t=n(t,e);for(var l=-1,u=t.length,d=!1;++l<u;){var f=s(t[l]);if(!(d=e!=null&&c(e,f)))break;e=e[f]}return d||++l!=u?d:(u=e==null?0:e.length,!!u&&o(u)&&a(f,u)&&(i(e)||r(e)))}t.exports=c})),Zs=h(((e,t)=>{var n=Ys(),r=Xs();function i(e,t){return e!=null&&r(e,t,n)}t.exports=i})),Qs=h(((e,t)=>{var n=Ms(),r=Js(),i=Zs(),a=Rs(),o=Ps(),s=Is(),c=Ks(),l=1,u=2;function d(e,t){return a(e)&&o(t)?s(c(e),t):function(a){var o=r(a,e);return o===void 0&&o===t?i(a,e):n(t,o,l|u)}}t.exports=d})),$s=h(((e,t)=>{function n(e){return function(t){return t?.[e]}}t.exports=n})),ec=h(((e,t)=>{var n=qs();function r(e){return function(t){return n(t,e)}}t.exports=r})),tc=h(((e,t)=>{var n=$s(),r=ec(),i=Rs(),a=Ks();function o(e){return i(e)?n(a(e)):r(e)}t.exports=o})),nc=h(((e,t)=>{var n=Ls(),r=Qs(),i=ao(),a=Z(),o=tc();function s(e){return typeof e==`function`?e:e==null?i:typeof e==`object`?a(e)?r(e[0],e[1]):n(e):o(e)}t.exports=s})),rc=h(((e,t)=>{var n=ro(),r=io(),i=nc();function a(e,t){return e&&e.length?n(e,i(t,2),r):void 0}t.exports=a})),ic=h(((e,t)=>{function n(e,t){return e<t}t.exports=n})),ac=h(((e,t)=>{var n=ro(),r=ic(),i=ao();function a(e){return e&&e.length?n(e,i,r):void 0}t.exports=a})),oc=h(((e,t)=>{var n=ro(),r=nc(),i=ic();function a(e,t){return e&&e.length?n(e,r(t,2),i):void 0}t.exports=a})),sc=_(oo(),1),cc=_(rc(),1),lc=_(ac(),1),uc=_(oc(),1),dc=({price:e})=>e.actualPrice;function fc(e){return e.priceAfterDiscount===void 0?{currentSellingPrice:e.actualPrice,priceBeforeDiscount:e.compareAtPrice,pricePerUnit:e.pricePerUnit}:{currentSellingPrice:e.priceAfterDiscount,priceBeforeDiscount:e.actualPrice,pricePerUnit:e.pricePerUnit}}function pc(e,t){let n=e.subscriptionPrices.find(e=>e.subscriptionId===t);if(!n)throw Error(`Missing subscription price for plan ${t} on variant ${e.id}`);let r=n.price;return{currentSellingPrice:r,priceBeforeDiscount:r<e.price.actualPrice?e.price.actualPrice:void 0}}function mc(e){let t=(0,uc.default)(e,dc),n=(0,cc.default)(e,dc),r=e.map(({price:e})=>fc(e)),i=fc(t.price),a=fc(n.price),o=r.flatMap(({priceBeforeDiscount:e})=>e===void 0?[]:[e]);return{minCurrentSellingPrice:i.currentSellingPrice,maxCurrentSellingPrice:a.currentSellingPrice,minPriceBeforeDiscount:(0,lc.default)(o),maxPriceBeforeDiscount:(0,sc.default)(o),minPricePerUnit:i.pricePerUnit,maxPricePerUnit:a.pricePerUnit}}function hc(e,t){return e.subscriptionDetails.subscriptions.map(e=>({subscription:e,price:pc(t,e.id)}))}function gc(e){return{productPrice:{currentSellingPrice:void 0},subscriptionPlanPrices:e.subscriptionDetails.subscriptions.map(e=>({subscription:e,price:{currentSellingPrice:void 0}})),productPriceRange:{minCurrentSellingPrice:void 0,maxCurrentSellingPrice:void 0}}}function _c(e){if(!e.minPriceVariant)return gc(e);let t=fc(e.minPriceVariant.price),n=e.minPriceVariant.price.priceAfterDiscount!==void 0;return{productPrice:t,subscriptionPlanPrices:e.subscriptionDetails.subscriptions.map(e=>({subscription:e,price:{}})),productPriceRange:{minCurrentSellingPrice:t.currentSellingPrice,maxCurrentSellingPrice:n?void 0:e.priceRange.maxActualPrice,minPriceBeforeDiscount:t.priceBeforeDiscount,maxPriceBeforeDiscount:n?e.priceRange.maxActualPrice:e.priceRange.maxCompareAtPrice,minPricePerUnit:t.pricePerUnit}}}function vc(e,t,n){if(!n)return _c(e);let r=(0,uc.default)(e.variants,dc),i=t??r;return i?{productPrice:fc(i.price),subscriptionPlanPrices:hc(e,i),productPriceRange:mc(e.variants)}:gc(e)}function yc(e,t){let n=e.subscriptionPlanPrices.find(({subscription:e})=>e.id===t);return n?{currentSellingPrice:n.price.currentSellingPrice,priceBeforeDiscount:n.price.priceBeforeDiscount,pricePerUnit:e.productPrice.pricePerUnit}:e.productPrice}function bc(e){return fc(e.price).currentSellingPrice}var xc=`BACK_IN_STOCK_NOTIFICATION_REQUEST_ALREADY_EXISTS`;function Sc(e){return e?.details?.applicationError?.code??`UNKNOWN`}function Cc(e){return{code:Sc(e),message:e?.message}}async function wc(e){let{productId:t,variantId:n,email:r,name:i,price:a,imageUrl:o}=e;try{return await Qi({catalogReference:{catalogItemId:t,appId:Sa,...n?{options:{variantId:n}}:{}},email:r},{name:i,price:String(a),...o?{image:o}:{}}),`created`}catch(e){if(Sc(e)===xc)return`already-subscribed`;throw Cc(e)}}var Tc=e=>e.media.type===`image`;function Ec(e,t){let n=t.choices[e.id];return e.choices.find(e=>e.choiceId===n)}function Dc(e,t){let n=e.options.map(e=>Ec(e,t)?.mediaIds).filter(e=>!!(e&&e.length>0));if(n.length===0)return;let r=n.reduce((e,t)=>e.filter(e=>t.includes(e))),i=r.length>0?r:n.flat(),a=new Map;for(let t of e.media??[])Tc(t)&&a.set(t.id,t);for(let e of i){let t=a.get(e)?.media.src;if(t)return t}}function Oc(e,t){let n=[t?Dc(e,t):void 0,e.media?.find(Tc)?.media.src];for(let e of n){let t=fi(e);if(t)return t}}function kc(e,r){let i=t(t=>r?wc({productId:e.id,variantId:r.id,email:t,name:e.name??``,price:bc(r),imageUrl:Oc(e,r)}):Promise.reject(Error(`Cannot create a back-in-stock notification without a selected variant`)),[e,r]);return n(()=>({handleNotifyMe:i}),[i])}function Ac(e,t){return n(()=>({id:e.id,name:e.name,description:e.description,ribbons:e.ribbons,breadcrumbs:e.breadcrumbs,mainCategoryId:e.mainCategoryId,categories:e.categories,infoSections:e.infoSections,sku:t?.sku,discountRules:e.discountRuleNames?.map(e=>({name:e}))}),[e,t])}function jc(e){return{type:`image`,src:e.url,width:e.width,height:e.height,...e.name===void 0?{}:{title:e.name},...e.alt===void 0?{}:{parameters:{alt:e.alt}}}}var Mc=`11062b_7b9f1e3756b64285ad5cf5e244b4ae77~mv2.png`,Nc={uri:Mc,url:`https://static.wixstatic.com/media/${Mc}`,width:460,height:460},Pc=[jc(Nc)];function Fc(e,t,n){let r=Rc(e,Ic(e,t,n));return r.length>0?r:e.media??[]}function Ic(e,t,n){let r=e.options.flatMap(e=>Lc(e.choices,t[e.id])),i=Object.values(e.modifiers).flatMap(e=>Lc(e.choices,n[e.id]));return[...new Set([...r,...i])]}function Lc(e,t){return e?.find(e=>e.choiceId===t)?.mediaIds??[]}function Rc(e,t){let n=new Map((e.media??[]).map(e=>[e.id,e]));return t.flatMap(e=>{let t=n.get(e);return t?[t]:[]})}function zc(e){return e.map(e=>e.id).join(`|`)}function Bc(e){return e.length>0?e.map(e=>e.media):Pc}function Vc({product:e,selectedOptions:i,selectedModifiers:a}){let o=n(()=>Bc(e.media??[]),[e.media]),s=e.mainMedia??Nc,c=n(()=>Fc(e,i,a),[e,i,a]),l=n(()=>Bc(c),[c]),u=zc(c),[d,f]=r(u),[p,m]=r(0);d!==u&&(f(u),m(0));let h=t(e=>m(e),[]);return n(()=>({allMedia:o,mainMedia:s,media:l,selectedMediaIndex:p,selectMedia:h}),[o,s,l,p,h])}function Hc(e){return Object.entries(e).map(([e,t])=>({optionId:e,choiceId:t}))}function Uc(e){return Object.entries(e).map(([e,t])=>({modifierId:e,value:t}))}function Wc(e,t,r,i=!1){let{selectedVariant:a}=t,o=Ac(e,a),s=Ya(e,a),c=Vc({product:e,selectedOptions:t.selectedOptions,selectedModifiers:t.selectedModifiers}),l=kc(e,a),{getPageAbsoluteUrl:u}=ka(),d=n(()=>{if(!e.slug)return;let t=u(q.PRODUCT_PAGE,e.slug);return t?{href:t}:void 0},[e.slug,u]);return n(()=>{let{selectedVariant:e,setHasAttemptedSubmit:n,isSelectionValid:a,selectedOptions:u,selectedModifiers:f,selectedSubscriptionPlanId:p,quantity:m,...h}=t;return{...o,link:d,...r,...h,buyerSelections:{options:Hc(u),modifiers:Uc(f),subscriptionPlanId:p,quantity:m},...s,...c,...l,isBackInStockEnabled:i}},[o,d,r,t,s,c,l,i])}var Gc=K(`@wix/viewer-service-environment`);function Kc(){return s(Gc).language}var qc=e=>{let t=e?.maximumFractionDigits??2;return(e=>e?.toFixed(t))},Jc=(e,t,n)=>{let r=new Intl.NumberFormat(t,{style:`currency`,currency:e,...n});return(e=>{if(e!=null)return r.format(e)})};function Yc(e,t,n){return e?Jc(e,t,n):qc(n)}function Xc(e,t){let r=Kc();return n(()=>Yc(e,r,t),[e,r,t])}function Q(e,t){return e===void 0?void 0:{amount:e,formattedAmount:t(e)}}function Zc(e,t,n){return{id:e.id,name:e.name,isOneTimePurchase:!1,description:e.description,currentPrice:Q(t.currentSellingPrice,n),originalPrice:Q(t.priceBeforeDiscount,n),frequency:e.frequency,interval:e.interval,duration:e.billingCycles}}function Qc(e){return e===void 0?void 0:{description:e.description}}function $c(e,t){return{currentSellingPrice:Q(e.currentSellingPrice,t),priceBeforeDiscount:Q(e.priceBeforeDiscount,t),pricePerUnit:Qc(e.pricePerUnit)}}function el(e,t){return{minCurrentSellingPrice:Q(e.minCurrentSellingPrice,t),maxCurrentSellingPrice:Q(e.maxCurrentSellingPrice,t),minPriceBeforeDiscount:Q(e.minPriceBeforeDiscount,t),maxPriceBeforeDiscount:Q(e.maxPriceBeforeDiscount,t),minPricePerUnit:Qc(e.minPricePerUnit),maxPricePerUnit:Qc(e.maxPricePerUnit)}}function tl(e,t,n,r){if(e.length===0)return[];let i=e.map(({subscription:e,price:t})=>Zc(e,t,r));return t?[{id:mi,name:`One-time purchase`,isOneTimePurchase:!0,currentPrice:Q(n.currentSellingPrice,r)},...i]:i}function nl({product:e,userInputs:t,hasLoadedVariants:r}){let{selectedVariant:i,selectedSubscriptionPlanId:a}=t,o=Xc(e.currency);return n(()=>{let t=vc(e,i,r),n={...$c(yc(t,a),o),...el(t.productPriceRange,o)},s=tl(t.subscriptionPlanPrices,e.subscriptionDetails.allowOneTimePurchases,t.productPrice,o);return{currency:e.currency,pricing:n,subscriptionPlans:s}},[e,i,a,r,o])}function rl(e){return Object.values(e).toSorted().join(`_`)}function il(e){let t=new Map;for(let n of e)t.set(rl(n.choices),n);return t}function al(e,t,n){let r=Object.keys(n).length>0,i={};for(let a of e){i[a.id]={};for(let e of a.choices){if(!r){i[a.id][e.choiceId]={isInStock:e.inStock??!0,isVisible:e.visible??!0};continue}if(e.inStock===!1&&e.visible===!1){i[a.id][e.choiceId]={isInStock:!1,isVisible:!1};continue}let{isInStock:o,isVisible:s}=ol({...n,[a.id]:e.choiceId},t);i[a.id][e.choiceId]={isInStock:o,isVisible:s}}}return i}function ol(e,t){let n=!1,r=!1;for(let i of t.values())if(Object.entries(e).every(([e,t])=>i.choices[e]===t)&&(r=!0,(i.availabilityStatus===gr.IN_STOCK||i.availabilityStatus===gr.PREORDER)&&(n=!0),n))break;return{isInStock:n,isVisible:r}}function sl(e,t){let n=new Map;for(let e of t)n.set(e.variantId,e);return e.map(e=>{let t=n.get(e.id);return{...e,availabilityStatus:t?.availabilityStatus,preorderInfo:t?.preorderInfo,inventoryQuantity:t?.quantity,trackQuantity:t?.trackQuantity}})}var cl=(e,t)=>e.modifierRenderType===Mr.FREE_TEXT?!!t:e.choices?.some(e=>e.choiceId===t);function ll({product:e,selections:t,selectedVariant:n}){let r={options:ul(e.options,t.selectedOptions,n),modifiers:fl(e.modifiers,t.selectedModifiers),quantity:dl(t.quantity,n),subscriptionPlanId:pl(e.subscriptionDetails,t.selectedSubscriptionPlanId)};return{valid:Object.values(r.options).length===0&&Object.values(r.modifiers).length===0&&!r.quantity&&!r.subscriptionPlanId,fields:r}}function ul(e,t,n){if(n!==null)return{};let r={};for(let n of e)t[n.id]||(r[n.id]=`missing`);return r}function dl(e,t){if(e<1)return`below-min`;if(e>Wa(t))return`above-max`}function fl(e,t){let n=Object.values(e).filter(e=>e.mandatory&&!cl(e,t[e.id]));return Object.fromEntries(n.map(e=>[e.id,`missing`]))}function pl(e,t){if(e.subscriptions.length!==0)return t?t===`one-time`?e.allowOneTimePurchases?void 0:`missing`:ml(e,t)?void 0:`missing`:`missing`}function ml(e,t){return e.subscriptions.some(e=>e.id===t)}var $=function(e){return e.PRODUCT_OPTION=`PRODUCT_OPTION`,e.MODIFIER=`MODIFIER`,e}({});function hl(e){if(e===`IN_STOCK`||e===`OUT_OF_STOCK`||e===`PARTIALLY_OUT_OF_STOCK`)return e}function gl(e){if(!(!e||e.customizationRenderType!==`TEXT_CHOICES`&&e.customizationRenderType!==`SWATCH_CHOICES`)){if(e.customizationType===`PRODUCT_OPTION`)return`PRODUCT_OPTION`;if(e.customizationType===`MODIFIER`)return`MODIFIER`}}function _l(e){return!e._id||!e.key?null:{choiceId:e._id,key:e.key,name:e.name,colorCode:e.colorCode}}function vl(e){if(e.status!==`ACTIVE`||!e.productId||!e.slug||!e.choice)return null;let t=_l(e.choice);return t?{productId:e.productId,choice:t,slug:e.slug,inventoryAvailabilityStatus:hl(e.inventoryAvailabilityStatus)}:null}function yl(e){let t=e.groupingCustomizationId,n=gl(e.groupingCustomization);if(!t||!n)return;let r=(e.members??[]).map(e=>vl(e)).filter(e=>e!==null);if(r.length!==0)return{groupingCustomizationId:t,customizationType:n,members:r}}async function bl(e){if(e)try{let t=await Xr({fields:[Wr.GROUPING_CUSTOMIZATION]}).eq(`_id`,e).limit(1).find();return t.items[0]?yl(t.items[0]):void 0}catch{return}}function xl(e,t){if(!t)return;let n=t.members.find(t=>t.productId===e.id);if(!n)return;let r={groupingCustomizationId:t.groupingCustomizationId,currentProductChoiceId:n.choice.choiceId,members:t.members};if(t.customizationType===$.PRODUCT_OPTION)return e.options.find(({id:e})=>e===t.groupingCustomizationId)?{...r,customizationType:$.PRODUCT_OPTION}:void 0;if(e.modifiers[t.groupingCustomizationId])return{...r,customizationType:$.MODIFIER}}function Sl(e,t){return e.members.find(e=>e.choice.choiceId===t)}function Cl(e,t,n){return!!e&&t===e.groupingCustomizationId&&n!==e.currentProductChoiceId}function wl(e,t){if(!t)return;if(t.customizationType===$.PRODUCT_OPTION){let n=e.options.find(({id:e})=>e===t.groupingCustomizationId);if(!n)return;let r=Tl(n,t);return{options:e.options.map(e=>e.id===n.id?r:e)}}let n=e.modifiers[t.groupingCustomizationId];if(!n)return;let r=El(n,t);return{modifiers:{...e.modifiers,[t.groupingCustomizationId]:r}}}function Tl(e,t){return{...e,isGroupedOption:!0,choices:t.members.map(e=>({...e.choice,inStock:e.inventoryAvailabilityStatus!==`OUT_OF_STOCK`}))}}function El(e,t){return{...e,choices:t.members.map(({choice:e})=>e)}}function Dl(e,t){if(!t||t.customizationType!==$.PRODUCT_OPTION)return e;let n=Object.fromEntries(t.members.map(e=>[e.choice.choiceId,{isInStock:e.inventoryAvailabilityStatus!==`OUT_OF_STOCK`,isVisible:!0}]));return{...e,[t.groupingCustomizationId]:{...n,...e[t.groupingCustomizationId]}}}function Ol(e,r){let{navigateToProductPage:i}=Ma(),a=n(()=>xl(e,r),[e,r]);return{productGrouping:a,selectGroupSiblingChoice:t(e=>{if(!a)return;let t=Sl(a,e);t&&i(t.slug)},[a,i]),productCustomizations:n(()=>wl(e,a),[e,a]),addGroupChoicesAvailability:t(e=>Dl(e,a),[a]),initialSelection:n(()=>{if(!a)return{options:{},modifiers:{}};let{customizationType:t,groupingCustomizationId:n,currentProductChoiceId:r}=a;if(t===$.MODIFIER&&e.modifiers[n].mandatory===!1)return{options:{},modifiers:{}};let i={[n]:r};return t===$.PRODUCT_OPTION?{options:i,modifiers:{}}:{options:{},modifiers:i}},[a,e.modifiers])}}function kl(e,i,a){let o=Ol(e,a),{productGrouping:s,selectGroupSiblingChoice:c,addGroupChoicesAvailability:l}=o,[u,d]=r(()=>o.initialSelection.options),[f,p]=r(()=>o.initialSelection.modifiers),[m,h]=r(void 0),[g,_]=r(1),[v,y]=r(!1),b=n(()=>il(sl(e.variants,i)),[e.variants,i]),x=n(()=>{let t=new Map;return n=>{let r=rl(n),i=t.get(r);if(i)return i;let a=l(al(e.options,b,n));return t.set(r,a),a}},[b,e.options,l]),S=n(()=>x(u),[x,u]),C=n(()=>Object.keys(u).length===e.options.length?b.get(rl(u))??null:null,[b,u,e.options.length]),w=t((e,t)=>{if(u[e]!==t){if(Cl(s,e,t)){c(t);return}d(n=>({...n,[e]:t})),_(1)}},[u,s,c]),T=t((e,t)=>{if(Cl(s,e,t)){c(t);return}p(n=>n[e]===t?n:{...n,[e]:t})},[s,c]),E=t(e=>{p(t=>{if(!(e in t))return t;let{[e]:n,...r}=t;return r})},[]),D=t(e=>{h(e)},[]),O=n(()=>Wa(C),[C]),k=n(()=>Ga(g,O),[g,O]),ee=t(e=>{_(e)},[]),te=n(()=>ll({product:e,selections:{selectedOptions:u,selectedModifiers:f,selectedSubscriptionPlanId:m,quantity:k},selectedVariant:C}),[e,u,f,m,k,C]),ne=o.productCustomizations?.options??e.options,re=o.productCustomizations?.modifiers??e.modifiers;return n(()=>({options:ne,modifiers:re,quantity:k,selectedOptions:u,selectedModifiers:f,selectedSubscriptionPlanId:m,selectedVariant:C,selectedVariantId:C?.id??null,selectionsAvailability:S,maxPurchasableQuantity:O,isSelectionValid:te.valid,selectionValidationErrors:te.fields,hasAttemptedSubmit:v,setHasAttemptedSubmit:y,selectOption:w,selectModifier:T,clearModifierSelection:E,selectSubscriptionPlan:D,selectQuantity:ee}),[ne,re,k,u,f,m,C,S,O,te,v,w,T,E,D,ee])}function Al({product:e,productGroup:t,inventoryItems:r,isBackInStockEnabled:i,source:a}){let o=kl(e,r,t),s=Ua(e,o,Ya(e,o.selectedVariant)),c=Wc(e,o,nl({product:e,userInputs:o,hasLoadedVariants:!0}),i);return n(()=>({...c,...s,source:a}),[c,s,a])}function jl({productPromise:e,source:t,children:n}){let{product:r,productGroup:a,inventoryItems:o,isBackInStockEnabled:s}=Ui(e),l=Al({product:r,productGroup:a,inventoryItems:o,isBackInStockEnabled:s,source:t});return c(i,{value:l,children:n})}function Ml(t){return c(e,{fallback:null,children:c(jl,{...t})})}Ml.displayName=`StandaloneProductContextProvider`;var Nl=K(`@wix/site-service-warmup-data`);async function Pl(e,t,n){let r=typeof window>`u`;if(!r&&e)try{let n=await e.get(t);if(n!==null)return n}catch{}let i=await n();if(r&&e)try{e.set(t,i)}catch{}return i}function Fl(e,t){let n=o(),[i]=r(()=>{let r;try{r=n(Nl)}catch{r=null}return Pl(r,e,t)});return i}async function Il(){return(await ai().eq(`defaultLocation`,!0).find()).items?.[0]?._id??void 0}async function Ll(){try{return(await ia()).settings?.collectionStates?.some(e=>e.appId===`215238eb-22a5-4c36-9e7b-e7c08025e04e`&&e.collectingRequests)??!1}catch{return!1}}function Rl(e){return e.map(e=>({variantId:e.variantId??``,availabilityStatus:e.availabilityStatus,quantity:e.quantity??void 0,trackQuantity:e.trackQuantity??!1,preorderInfo:e.preorderInfo?{message:e.preorderInfo.message??void 0,quantity:e.preorderInfo.quantity??void 0}:void 0}))}async function zl(e,t){return Rl((await Dr().eq(`productId`,e).eq(`locationId`,t).find()).items??[])}async function Bl(e){let[t,n,r]=await Promise.all([e(),Il(),Ll()]),{product:i}=t;if(!n)throw Error(`Location not found`);let[a,o]=await Promise.all([zl(i.id,n),i.productGroupId?bl(i.productGroupId):void 0]);return{...t,productGroup:o,inventoryItems:a,isBackInStockEnabled:r}}function Vl(e,t){return Fl(`wixstores-storefront-builder:product-data:${e}`,()=>Bl(t))}var Hl=function(e){return e.PRODUCT_BY_SLUG=`product-by-slug`,e.PRODUCT_BY_ID=`product-by-id`,e.PRODUCT_ITEM=`product-item`,e}({});function Ul(){return a()}function Wl({productId:e,children:t}){let n=Vl(`id:${e}`,()=>Hi(e));return c(Ml,{productPromise:n,source:Hl.PRODUCT_BY_ID,children:t})}function Gl({productId:e,children:t}){return e?c(Wl,{productId:e,children:t},e):null}var Kl=Dn(`213f32a8-6f88-4024-a54b-f1264433e878`);export{Gl as default,Kl as injectAccessTokenGetter,Ul as useProductByIdContext};
|
|
2
|
+
//# sourceMappingURL=context-provider-213f32a8-6f88-4024-a54b-f1264433e878-C7SWBL-t.js.map
|