@lockerverse/react 0.2.255 → 0.2.256

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/MIGRATIONS.md CHANGED
@@ -4,7 +4,23 @@ This file ships in both @lockerverse/sdk and @lockerverse/react. Use the copy in
4
4
  the target installed release. This is an agent-run procedure, not an install
5
5
  script. Installing a package does not edit host code or guarantee these steps ran.
6
6
 
7
- ## Unreleased — returning bidders keep their details
7
+ ## Unreleased — booking member prices
8
+
9
+ - **Affected:** `@lockerverse/sdk/bookings`. A catalog service can have
10
+ `memberPrice: {label, amountCents}`. The new `client.price(serviceVariationId,
11
+ email)` returns the price for that customer. A member price is used once per
12
+ email. Attempts with a member price have `priceLabel` and
13
+ `regularAmountCents`; `amountCents` stays the charged price.
14
+ - **Automatic:** none. Existing booking pages keep showing the regular price,
15
+ and the backend charges the member price to qualifying emails.
16
+ - **Host adoption:** booking pages that show a total before payment call
17
+ `client.price` when the email or service changes and show its `amountCents`
18
+ as the total and on the Pay button. Show `memberPrice.label` next to it.
19
+ - **Check:** on a business with a member price, enter a qualifying email and
20
+ see the member price; enter another email and see the regular price. Do not
21
+ submit a live payment for this check.
22
+
23
+ ## 0.2.255 — returning bidders keep their details
8
24
 
9
25
  - **Affected:** `LockerverseAuctionItem` bid and Buy Now checkout, in React and
10
26
  in the browser embed.
@@ -13,7 +29,7 @@ script. Installing a package does not edit host code or guarantee these steps ra
13
29
  the browser's local storage (`lockerverse:auction-bidder`). The next checkout
14
30
  on the same site fills these fields. The card is never saved; the bidder
15
31
  enters it again. Bidders can edit any filled field.
16
- - **Host adoption:** none. Script hosts update the pinned script URL to adopt.
32
+ - **Host adoption:** none. Script hosts update the pinned script URL to `@0.2.255` to adopt.
17
33
  - **Check:** place a test bid on a dev auction, return to the item, and open
18
34
  the checkout again. Email, phone and billing address are filled.
19
35
 
@@ -1,4 +1,4 @@
1
- import{b as Re,c as $e,d as se,e as Ye,f as ze,g as Ve,h as He,i as Je,j as Te,k as Ge,l as Ie,m as Ke,n as he,o as Xe,p as Qe,q as Y}from"./chunk-U5RZWWIG.js";import{H as we,L as We,M as Le,a as me,r as fe}from"./chunk-BDPIC42C.js";import{a as ae,c as M}from"./chunk-DCANE7XH.js";var et=ae((Dn,Ze)=>{"use strict";var Qt="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED";Ze.exports=Qt});var ot=ae((Mn,rt)=>{"use strict";var Zt=et();function tt(){}function nt(){}nt.resetWarningCache=tt;rt.exports=function(){function t(r,o,a,s,c,u){if(u!==Zt){var l=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw l.name="Invariant Violation",l}}t.isRequired=t;function e(){return t}var n={array:t,bigint:t,bool:t,func:t,number:t,object:t,string:t,symbol:t,any:t,arrayOf:e,element:t,elementType:t,instanceOf:e,node:t,objectOf:e,oneOf:e,oneOfType:e,shape:e,exact:e,checkPropTypes:nt,resetWarningCache:tt};return n.PropTypes=n,n}});var at=ae((qn,it)=>{it.exports=ot()();var Bn,Un});var jt=ae(Me=>{"use strict";Object.defineProperty(Me,"__esModule",{value:!0});function le(t){"@babel/helpers - typeof";return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?le=function(e){return typeof e}:le=function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},le(t)}var It="dahlia",kn=function(e){return e===3?"v3":e},xt="https://js.stripe.com",An="".concat(xt,"/").concat(It,"/stripe.js"),wn=/^https:\/\/js\.stripe\.com\/v3\/?(\?.*)?$/,Ln=/^https:\/\/js\.stripe\.com\/(v3|[a-z]+)\/stripe\.js(\?.*)?$/,Lt="loadStripe.setLoadParameters was called but an existing Stripe.js script already exists in the document; existing script parameters will be used",Rn=function(e){return wn.test(e)||Ln.test(e)},Tn=function(){for(var e=document.querySelectorAll('script[src^="'.concat(xt,'"]')),n=0;n<e.length;n++){var r=e[n];if(Rn(r.src))return r}return null},Rt=function(e){var n=e&&!e.advancedFraudSignals?"?advancedFraudSignals=false":"",r=document.createElement("script");r.src="".concat(An).concat(n);var o=document.head||document.body;if(!o)throw new Error("Expected document.body not to be null. Stripe.js requires a <body> element.");return o.appendChild(r),r},In=function(e,n){!e||!e._registerWrapper||e._registerWrapper({name:"stripe-js",version:"9.12.1",startTime:n})},ue=null,ye=null,ge=null,xn=function(e){return function(n){e(new Error("Failed to load Stripe.js",{cause:n}))}},On=function(e,n){return function(){window.Stripe?e(window.Stripe):n(new Error("Stripe.js not available"))}},jn=function(e){return ue!==null?ue:(ue=new Promise(function(n,r){if(typeof window>"u"||typeof document>"u"){n(null);return}if(window.Stripe&&e&&console.warn(Lt),window.Stripe){n(window.Stripe);return}try{var o=Tn();if(o&&e)console.warn(Lt);else if(!o)o=Rt(e);else if(o&&ge!==null&&ye!==null){var a;o.removeEventListener("load",ge),o.removeEventListener("error",ye),(a=o.parentNode)===null||a===void 0||a.removeChild(o),o=Rt(e)}ge=On(n,r),ye=xn(r),o.addEventListener("load",ge),o.addEventListener("error",ye)}catch(s){r(s);return}}),ue.catch(function(n){return ue=null,Promise.reject(n)}))},Fn=function(e,n,r){if(e===null)return null;var o=n[0];if(typeof o!="string")throw new Error("Expected publishable key to be of type string, got type ".concat(le(o)," instead."));var a=o.match(/^pk_test/),s=kn(e.version),c=It;a&&s!==c&&console.warn("Stripe.js@".concat(s," was loaded on the page, but @stripe/stripe-js@").concat("9.12.1"," expected Stripe.js@").concat(c,". This may result in unexpected behavior. For more information, see https://docs.stripe.com/sdks/stripejs-versioning"));var u=e.apply(void 0,n);return In(u,r),u},Tt=function(e){var n=`invalid load parameters; expected object of shape
1
+ import{b as Re,c as $e,d as se,e as Ye,f as ze,g as Ve,h as He,i as Je,j as Te,k as Ge,l as Ie,m as Ke,n as he,o as Xe,p as Qe,q as Y}from"./chunk-UYL6KPUM.js";import{H as we,L as We,M as Le,a as me,r as fe}from"./chunk-ZZUMO4Y2.js";import{a as ae,c as M}from"./chunk-DCANE7XH.js";var et=ae((Dn,Ze)=>{"use strict";var Qt="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED";Ze.exports=Qt});var ot=ae((Mn,rt)=>{"use strict";var Zt=et();function tt(){}function nt(){}nt.resetWarningCache=tt;rt.exports=function(){function t(r,o,a,s,c,u){if(u!==Zt){var l=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw l.name="Invariant Violation",l}}t.isRequired=t;function e(){return t}var n={array:t,bigint:t,bool:t,func:t,number:t,object:t,string:t,symbol:t,any:t,arrayOf:e,element:t,elementType:t,instanceOf:e,node:t,objectOf:e,oneOf:e,oneOfType:e,shape:e,exact:e,checkPropTypes:nt,resetWarningCache:tt};return n.PropTypes=n,n}});var at=ae((qn,it)=>{it.exports=ot()();var Bn,Un});var jt=ae(Me=>{"use strict";Object.defineProperty(Me,"__esModule",{value:!0});function le(t){"@babel/helpers - typeof";return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?le=function(e){return typeof e}:le=function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},le(t)}var It="dahlia",kn=function(e){return e===3?"v3":e},xt="https://js.stripe.com",An="".concat(xt,"/").concat(It,"/stripe.js"),wn=/^https:\/\/js\.stripe\.com\/v3\/?(\?.*)?$/,Ln=/^https:\/\/js\.stripe\.com\/(v3|[a-z]+)\/stripe\.js(\?.*)?$/,Lt="loadStripe.setLoadParameters was called but an existing Stripe.js script already exists in the document; existing script parameters will be used",Rn=function(e){return wn.test(e)||Ln.test(e)},Tn=function(){for(var e=document.querySelectorAll('script[src^="'.concat(xt,'"]')),n=0;n<e.length;n++){var r=e[n];if(Rn(r.src))return r}return null},Rt=function(e){var n=e&&!e.advancedFraudSignals?"?advancedFraudSignals=false":"",r=document.createElement("script");r.src="".concat(An).concat(n);var o=document.head||document.body;if(!o)throw new Error("Expected document.body not to be null. Stripe.js requires a <body> element.");return o.appendChild(r),r},In=function(e,n){!e||!e._registerWrapper||e._registerWrapper({name:"stripe-js",version:"9.12.1",startTime:n})},ue=null,ye=null,ge=null,xn=function(e){return function(n){e(new Error("Failed to load Stripe.js",{cause:n}))}},On=function(e,n){return function(){window.Stripe?e(window.Stripe):n(new Error("Stripe.js not available"))}},jn=function(e){return ue!==null?ue:(ue=new Promise(function(n,r){if(typeof window>"u"||typeof document>"u"){n(null);return}if(window.Stripe&&e&&console.warn(Lt),window.Stripe){n(window.Stripe);return}try{var o=Tn();if(o&&e)console.warn(Lt);else if(!o)o=Rt(e);else if(o&&ge!==null&&ye!==null){var a;o.removeEventListener("load",ge),o.removeEventListener("error",ye),(a=o.parentNode)===null||a===void 0||a.removeChild(o),o=Rt(e)}ge=On(n,r),ye=xn(r),o.addEventListener("load",ge),o.addEventListener("error",ye)}catch(s){r(s);return}}),ue.catch(function(n){return ue=null,Promise.reject(n)}))},Fn=function(e,n,r){if(e===null)return null;var o=n[0];if(typeof o!="string")throw new Error("Expected publishable key to be of type string, got type ".concat(le(o)," instead."));var a=o.match(/^pk_test/),s=kn(e.version),c=It;a&&s!==c&&console.warn("Stripe.js@".concat(s," was loaded on the page, but @stripe/stripe-js@").concat("9.12.1"," expected Stripe.js@").concat(c,". This may result in unexpected behavior. For more information, see https://docs.stripe.com/sdks/stripejs-versioning"));var u=e.apply(void 0,n);return In(u,r),u},Tt=function(e){var n=`invalid load parameters; expected object of shape
2
2
 
3
3
  {advancedFraudSignals: boolean}
4
4
 
@@ -1,2 +1,2 @@
1
- import{a as O,r as _}from"./chunk-BDPIC42C.js";import{a as z,c as b}from"./chunk-DCANE7XH.js";var le=z(d=>{"use strict";var $e=O();function de(t){var e="https://react.dev/errors/"+t;if(1<arguments.length){e+="?args[]="+encodeURIComponent(arguments[1]);for(var r=2;r<arguments.length;r++)e+="&args[]="+encodeURIComponent(arguments[r])}return"Minified React error #"+t+"; visit "+e+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}function v(){}var f={d:{f:v,r:function(){throw Error(de(522))},D:v,C:v,L:v,m:v,X:v,S:v,M:v},p:0,findDOMNode:null},qe=Symbol.for("react.portal");function Fe(t,e,r){var n=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:qe,key:n==null?null:""+n,children:t,containerInfo:e,implementation:r}}var L=$e.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE;function x(t,e){if(t==="font")return"";if(typeof e=="string")return e==="use-credentials"?e:""}d.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=f;d.createPortal=function(t,e){var r=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!e||e.nodeType!==1&&e.nodeType!==9&&e.nodeType!==11)throw Error(de(299));return Fe(t,e,null,r)};d.flushSync=function(t){var e=L.T,r=f.p;try{if(L.T=null,f.p=2,t)return t()}finally{L.T=e,f.p=r,f.d.f()}};d.preconnect=function(t,e){typeof t=="string"&&(e?(e=e.crossOrigin,e=typeof e=="string"?e==="use-credentials"?e:"":void 0):e=null,f.d.C(t,e))};d.prefetchDNS=function(t){typeof t=="string"&&f.d.D(t)};d.preinit=function(t,e){if(typeof t=="string"&&e&&typeof e.as=="string"){var r=e.as,n=x(r,e.crossOrigin),i=typeof e.integrity=="string"?e.integrity:void 0,a=typeof e.fetchPriority=="string"?e.fetchPriority:void 0;r==="style"?f.d.S(t,typeof e.precedence=="string"?e.precedence:void 0,{crossOrigin:n,integrity:i,fetchPriority:a}):r==="script"&&f.d.X(t,{crossOrigin:n,integrity:i,fetchPriority:a,nonce:typeof e.nonce=="string"?e.nonce:void 0})}};d.preinitModule=function(t,e){if(typeof t=="string")if(typeof e=="object"&&e!==null){if(e.as==null||e.as==="script"){var r=x(e.as,e.crossOrigin);f.d.M(t,{crossOrigin:r,integrity:typeof e.integrity=="string"?e.integrity:void 0,nonce:typeof e.nonce=="string"?e.nonce:void 0})}}else e==null&&f.d.M(t)};d.preload=function(t,e){if(typeof t=="string"&&typeof e=="object"&&e!==null&&typeof e.as=="string"){var r=e.as,n=x(r,e.crossOrigin);f.d.L(t,r,{crossOrigin:n,integrity:typeof e.integrity=="string"?e.integrity:void 0,nonce:typeof e.nonce=="string"?e.nonce:void 0,type:typeof e.type=="string"?e.type:void 0,fetchPriority:typeof e.fetchPriority=="string"?e.fetchPriority:void 0,referrerPolicy:typeof e.referrerPolicy=="string"?e.referrerPolicy:void 0,imageSrcSet:typeof e.imageSrcSet=="string"?e.imageSrcSet:void 0,imageSizes:typeof e.imageSizes=="string"?e.imageSizes:void 0,media:typeof e.media=="string"?e.media:void 0})}};d.preloadModule=function(t,e){if(typeof t=="string")if(e){var r=x(e.as,e.crossOrigin);f.d.m(t,{as:typeof e.as=="string"&&e.as!=="script"?e.as:void 0,crossOrigin:r,integrity:typeof e.integrity=="string"?e.integrity:void 0})}else f.d.m(t)};d.requestFormReset=function(t){f.d.r(t)};d.unstable_batchedUpdates=function(t,e){return t(e)};d.useFormState=function(t,e,r){return L.H.useFormState(t,e,r)};d.useFormStatus=function(){return L.H.useHostTransitionStatus()};d.version="19.2.8"});var Ve=z((ct,me)=>{"use strict";function ge(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(ge)}catch(t){console.error(t)}}ge(),me.exports=le()});var he={grad:.9,turn:360,rad:360/(2*Math.PI)},p=function(t){return typeof t=="string"?t.length>0:typeof t=="number"},u=function(t,e,r){return e===void 0&&(e=0),r===void 0&&(r=Math.pow(10,e)),Math.round(r*t)/r+0},l=function(t,e,r){return e===void 0&&(e=0),r===void 0&&(r=1),t>r?r:t>e?t:e},Q=function(t){return(t=isFinite(t)?t%360:0)>0?t:t+360},B=function(t){return{r:l(t.r,0,255),g:l(t.g,0,255),b:l(t.b,0,255),a:l(t.a)}},I=function(t){return{r:u(t.r),g:u(t.g),b:u(t.b),a:u(t.a,3)}},be=/^#([0-9a-f]{3,8})$/i,R=function(t){var e=t.toString(16);return e.length<2?"0"+e:e},Z=function(t){var e=t.r,r=t.g,n=t.b,i=t.a,a=Math.max(e,r,n),o=a-Math.min(e,r,n),s=o?a===e?(r-n)/o:a===r?2+(n-e)/o:4+(e-r)/o:0;return{h:60*(s<0?s+6:s),s:a?o/a*100:0,v:a/255*100,a:i}},ee=function(t){var e=t.h,r=t.s,n=t.v,i=t.a;e=e/360*6,r/=100,n/=100;var a=Math.floor(e),o=n*(1-r),s=n*(1-(e-a)*r),c=n*(1-(1-e+a)*r),m=a%6;return{r:255*[n,s,o,o,c,n][m],g:255*[c,n,n,s,o,o][m],b:255*[o,o,c,n,n,s][m],a:i}},K=function(t){return{h:Q(t.h),s:l(t.s,0,100),l:l(t.l,0,100),a:l(t.a)}},G=function(t){return{h:u(t.h),s:u(t.s),l:u(t.l),a:u(t.a,3)}},W=function(t){return ee((r=(e=t).s,{h:e.h,s:(r*=((n=e.l)<50?n:100-n)/100)>0?2*r/(n+r)*100:0,v:n+r,a:e.a}));var e,r,n},A=function(t){return{h:(e=Z(t)).h,s:(i=(200-(r=e.s))*(n=e.v)/100)>0&&i<200?r*n/100/(i<=100?i:200-i)*100:0,l:i/2,a:e.a};var e,r,n,i},pe=/^hsla?\(\s*([+-]?\d*\.?\d+)(deg|rad|grad|turn)?\s*,\s*([+-]?\d*\.?\d+)%\s*,\s*([+-]?\d*\.?\d+)%\s*(?:,\s*([+-]?\d*\.?\d+)(%)?\s*)?\)$/i,ye=/^hsla?\(\s*([+-]?\d*\.?\d+)(deg|rad|grad|turn)?\s+([+-]?\d*\.?\d+)%\s+([+-]?\d*\.?\d+)%\s*(?:\/\s*([+-]?\d*\.?\d+)(%)?\s*)?\)$/i,ve=/^rgba?\(\s*([+-]?\d*\.?\d+)(%)?\s*,\s*([+-]?\d*\.?\d+)(%)?\s*,\s*([+-]?\d*\.?\d+)(%)?\s*(?:,\s*([+-]?\d*\.?\d+)(%)?\s*)?\)$/i,ke=/^rgba?\(\s*([+-]?\d*\.?\d+)(%)?\s+([+-]?\d*\.?\d+)(%)?\s+([+-]?\d*\.?\d+)(%)?\s*(?:\/\s*([+-]?\d*\.?\d+)(%)?\s*)?\)$/i,D={string:[[function(t){var e=be.exec(t);return e?(t=e[1]).length<=4?{r:parseInt(t[0]+t[0],16),g:parseInt(t[1]+t[1],16),b:parseInt(t[2]+t[2],16),a:t.length===4?u(parseInt(t[3]+t[3],16)/255,2):1}:t.length===6||t.length===8?{r:parseInt(t.substr(0,2),16),g:parseInt(t.substr(2,2),16),b:parseInt(t.substr(4,2),16),a:t.length===8?u(parseInt(t.substr(6,2),16)/255,2):1}:null:null},"hex"],[function(t){var e=ve.exec(t)||ke.exec(t);return e?e[2]!==e[4]||e[4]!==e[6]?null:B({r:Number(e[1])/(e[2]?100/255:1),g:Number(e[3])/(e[4]?100/255:1),b:Number(e[5])/(e[6]?100/255:1),a:e[7]===void 0?1:Number(e[7])/(e[8]?100:1)}):null},"rgb"],[function(t){var e=pe.exec(t)||ye.exec(t);if(!e)return null;var r,n,i=K({h:(r=e[1],n=e[2],n===void 0&&(n="deg"),Number(r)*(he[n]||1)),s:Number(e[3]),l:Number(e[4]),a:e[5]===void 0?1:Number(e[5])/(e[6]?100:1)});return W(i)},"hsl"]],object:[[function(t){var e=t.r,r=t.g,n=t.b,i=t.a,a=i===void 0?1:i;return p(e)&&p(r)&&p(n)?B({r:Number(e),g:Number(r),b:Number(n),a:Number(a)}):null},"rgb"],[function(t){var e=t.h,r=t.s,n=t.l,i=t.a,a=i===void 0?1:i;if(!p(e)||!p(r)||!p(n))return null;var o=K({h:Number(e),s:Number(r),l:Number(n),a:Number(a)});return W(o)},"hsl"],[function(t){var e=t.h,r=t.s,n=t.v,i=t.a,a=i===void 0?1:i;if(!p(e)||!p(r)||!p(n))return null;var o=(function(s){return{h:Q(s.h),s:l(s.s,0,100),v:l(s.v,0,100),a:l(s.a)}})({h:Number(e),s:Number(r),v:Number(n),a:Number(a)});return ee(o)},"hsv"]]},X=function(t,e){for(var r=0;r<e.length;r++){var n=e[r][0](t);if(n)return[n,e[r][1]]}return[null,void 0]},_e=function(t){return typeof t=="string"?X(t.trim(),D.string):typeof t=="object"&&t!==null?X(t,D.object):[null,void 0]};var M=function(t,e){var r=A(t);return{h:r.h,s:l(r.s+100*e,0,100),l:r.l,a:r.a}},H=function(t){return(299*t.r+587*t.g+114*t.b)/1e3/255},Y=function(t,e){var r=A(t);return{h:r.h,s:r.s,l:l(r.l+100*e,0,100),a:r.a}},P=(function(){function t(e){this.parsed=_e(e)[0],this.rgba=this.parsed||{r:0,g:0,b:0,a:1}}return t.prototype.isValid=function(){return this.parsed!==null},t.prototype.brightness=function(){return u(H(this.rgba),2)},t.prototype.isDark=function(){return H(this.rgba)<.5},t.prototype.isLight=function(){return H(this.rgba)>=.5},t.prototype.toHex=function(){return e=I(this.rgba),r=e.r,n=e.g,i=e.b,o=(a=e.a)<1?R(u(255*a)):"","#"+R(r)+R(n)+R(i)+o;var e,r,n,i,a,o},t.prototype.toRgb=function(){return I(this.rgba)},t.prototype.toRgbString=function(){return e=I(this.rgba),r=e.r,n=e.g,i=e.b,(a=e.a)<1?"rgba("+r+", "+n+", "+i+", "+a+")":"rgb("+r+", "+n+", "+i+")";var e,r,n,i,a},t.prototype.toHsl=function(){return G(A(this.rgba))},t.prototype.toHslString=function(){return e=G(A(this.rgba)),r=e.h,n=e.s,i=e.l,(a=e.a)<1?"hsla("+r+", "+n+"%, "+i+"%, "+a+")":"hsl("+r+", "+n+"%, "+i+"%)";var e,r,n,i,a},t.prototype.toHsv=function(){return e=Z(this.rgba),{h:u(e.h),s:u(e.s),v:u(e.v),a:u(e.a,3)};var e},t.prototype.invert=function(){return g({r:255-(e=this.rgba).r,g:255-e.g,b:255-e.b,a:e.a});var e},t.prototype.saturate=function(e){return e===void 0&&(e=.1),g(M(this.rgba,e))},t.prototype.desaturate=function(e){return e===void 0&&(e=.1),g(M(this.rgba,-e))},t.prototype.grayscale=function(){return g(M(this.rgba,-1))},t.prototype.lighten=function(e){return e===void 0&&(e=.1),g(Y(this.rgba,e))},t.prototype.darken=function(e){return e===void 0&&(e=.1),g(Y(this.rgba,-e))},t.prototype.rotate=function(e){return e===void 0&&(e=15),this.hue(this.hue()+e)},t.prototype.alpha=function(e){return typeof e=="number"?g({r:(r=this.rgba).r,g:r.g,b:r.b,a:e}):u(this.rgba.a,3);var r},t.prototype.hue=function(e){var r=A(this.rgba);return typeof e=="number"?g({h:e,s:r.s,l:r.l,a:r.a}):u(r.h)},t.prototype.isEqual=function(e){return this.toHex()===g(e).toHex()},t})(),g=function(t){return t instanceof P?t:new P(t)},J=[],te=function(t){t.forEach(function(e){J.indexOf(e)<0&&(e(P,D),J.push(e))})};function re(t,e){var r={white:"#ffffff",bisque:"#ffe4c4",blue:"#0000ff",cadetblue:"#5f9ea0",chartreuse:"#7fff00",chocolate:"#d2691e",coral:"#ff7f50",antiquewhite:"#faebd7",aqua:"#00ffff",azure:"#f0ffff",whitesmoke:"#f5f5f5",papayawhip:"#ffefd5",plum:"#dda0dd",blanchedalmond:"#ffebcd",black:"#000000",gold:"#ffd700",goldenrod:"#daa520",gainsboro:"#dcdcdc",cornsilk:"#fff8dc",cornflowerblue:"#6495ed",burlywood:"#deb887",aquamarine:"#7fffd4",beige:"#f5f5dc",crimson:"#dc143c",cyan:"#00ffff",darkblue:"#00008b",darkcyan:"#008b8b",darkgoldenrod:"#b8860b",darkkhaki:"#bdb76b",darkgray:"#a9a9a9",darkgreen:"#006400",darkgrey:"#a9a9a9",peachpuff:"#ffdab9",darkmagenta:"#8b008b",darkred:"#8b0000",darkorchid:"#9932cc",darkorange:"#ff8c00",darkslateblue:"#483d8b",gray:"#808080",darkslategray:"#2f4f4f",darkslategrey:"#2f4f4f",deeppink:"#ff1493",deepskyblue:"#00bfff",wheat:"#f5deb3",firebrick:"#b22222",floralwhite:"#fffaf0",ghostwhite:"#f8f8ff",darkviolet:"#9400d3",magenta:"#ff00ff",green:"#008000",dodgerblue:"#1e90ff",grey:"#808080",honeydew:"#f0fff0",hotpink:"#ff69b4",blueviolet:"#8a2be2",forestgreen:"#228b22",lawngreen:"#7cfc00",indianred:"#cd5c5c",indigo:"#4b0082",fuchsia:"#ff00ff",brown:"#a52a2a",maroon:"#800000",mediumblue:"#0000cd",lightcoral:"#f08080",darkturquoise:"#00ced1",lightcyan:"#e0ffff",ivory:"#fffff0",lightyellow:"#ffffe0",lightsalmon:"#ffa07a",lightseagreen:"#20b2aa",linen:"#faf0e6",mediumaquamarine:"#66cdaa",lemonchiffon:"#fffacd",lime:"#00ff00",khaki:"#f0e68c",mediumseagreen:"#3cb371",limegreen:"#32cd32",mediumspringgreen:"#00fa9a",lightskyblue:"#87cefa",lightblue:"#add8e6",midnightblue:"#191970",lightpink:"#ffb6c1",mistyrose:"#ffe4e1",moccasin:"#ffe4b5",mintcream:"#f5fffa",lightslategray:"#778899",lightslategrey:"#778899",navajowhite:"#ffdead",navy:"#000080",mediumvioletred:"#c71585",powderblue:"#b0e0e6",palegoldenrod:"#eee8aa",oldlace:"#fdf5e6",paleturquoise:"#afeeee",mediumturquoise:"#48d1cc",mediumorchid:"#ba55d3",rebeccapurple:"#663399",lightsteelblue:"#b0c4de",mediumslateblue:"#7b68ee",thistle:"#d8bfd8",tan:"#d2b48c",orchid:"#da70d6",mediumpurple:"#9370db",purple:"#800080",pink:"#ffc0cb",skyblue:"#87ceeb",springgreen:"#00ff7f",palegreen:"#98fb98",red:"#ff0000",yellow:"#ffff00",slateblue:"#6a5acd",lavenderblush:"#fff0f5",peru:"#cd853f",palevioletred:"#db7093",violet:"#ee82ee",teal:"#008080",slategray:"#708090",slategrey:"#708090",aliceblue:"#f0f8ff",darkseagreen:"#8fbc8f",darkolivegreen:"#556b2f",greenyellow:"#adff2f",seagreen:"#2e8b57",seashell:"#fff5ee",tomato:"#ff6347",silver:"#c0c0c0",sienna:"#a0522d",lavender:"#e6e6fa",lightgreen:"#90ee90",orange:"#ffa500",orangered:"#ff4500",steelblue:"#4682b4",royalblue:"#4169e1",turquoise:"#40e0d0",yellowgreen:"#9acd32",salmon:"#fa8072",saddlebrown:"#8b4513",sandybrown:"#f4a460",rosybrown:"#bc8f8f",darksalmon:"#e9967a",lightgoldenrodyellow:"#fafad2",snow:"#fffafa",lightgrey:"#d3d3d3",lightgray:"#d3d3d3",dimgray:"#696969",dimgrey:"#696969",olivedrab:"#6b8e23",olive:"#808000"},n={};for(var i in r)n[r[i]]=i;var a={};t.prototype.toName=function(o){if(!(this.rgba.a||this.rgba.r||this.rgba.g||this.rgba.b))return"transparent";var s,c,m=n[this.toHex()];if(m)return m;if(o?.closest){var k=this.toRgb(),y=1/0,E="black";if(!a.length)for(var T in r)a[T]=new t(r[T]).toRgb();for(var h in r){var j=(s=k,c=a[h],Math.pow(s.r-c.r,2)+Math.pow(s.g-c.g,2)+Math.pow(s.b-c.b,2));j<y&&(y=j,E=h)}return E}},e.string.push([function(o){var s=o.toLowerCase(),c=s==="transparent"?"#0000":r[s];return c?new t(c).toRgb():null},"name"])}var we=/^#([\da-f]{3}|[\da-f]{6})$/i,Se=/^([\da-f]{3}|[\da-f]{6})$/i;function U(t){let e=t.trim();return Se.test(e)?`#${e}`:e}function Ne(t){let e=we.exec(U(t));if(!e)return;let[,r]=e;if(!r)return;let n=r.length===3?Array.from(r,i=>`${i}${i}`).join(""):r;return[0,2,4].map(i=>Number.parseInt(n.slice(i,i+2),16))}function $([t,e,r]){let[n=0,i=0,a=0]=[t,e,r].map((m=0)=>{let k=m/255;return k<=.04045?k/12.92:((k+.055)/1.055)**2.4}),o=.2126*n+.7152*i+.0722*a,s=(o+.05)/.05,c=1.05/(o+.05);return s>=c?"#000":"#fff"}function Be(t){let e=Ne(t);if(e)return $(e)}te([re]);var ne="c062f2a0-f356-4fa1-bde8-3f08d42c2858",Ee="#6f8f6d";function Ae(t,e){let r=g(t);if(!r.isValid())return;let{r:n,g:i,b:a,a:o}=r.toRgb(),s=e==="dark"?5:255;return $([n,i,a].map(c=>c*o+s*(1-o)))}function Le(t,e={},r="light"){let n=t.community?.color?.trim(),i=e["--lockerverse-accent"]??(n?U(n):Ee),a={"--lockerverse-font-family":"inherit",...e,"--lockerverse-accent":i,"--lockerverse-accent-contrast":e["--lockerverse-accent-contrast"]??Ae(i,r)??"#000"};return t.id===ne&&!a["--lockerverse-auction-catalog-columns"]&&(a["--lockerverse-auction-catalog-columns"]="2"),a}function Ye(t,e={},r="light"){let n=Le(t,e,r),i={className:"lockerverse-auctions--embed",style:n},a=t.id===ne?"light":void 0;return{catalog:{className:i.className,showFilters:!1,showHeader:!1,showLineup:!1,style:n},defaultTheme:a,item:i}}var q=b(_(),1);function Qe({href:t,onBack:e,className:r,children:n,elementRef:i}){return t?(0,q.jsx)("a",{className:r,href:t,onClick:a=>{e&&a.button===0&&!a.metaKey&&!a.ctrlKey&&!a.shiftKey&&!a.altKey&&(a.preventDefault(),e())},ref:i,children:n}):e?(0,q.jsx)("button",{className:r,onClick:e,ref:i,type:"button",children:n}):null}var w=b(O(),1),ae=b(_(),1),Te=(0,w.createContext)(void 0),Oe=[96,192,320,480,640,960,1280,1920],Re=/\.(jpe?g|png|webp|avif)$/i,Ce=/\/+$/,xe=new Set(["media.lockerverse.com","dev-media.lockerverse.com"]);function Ie(t,e){if(xe.has(t.hostname)&&!t.port)return t.pathname;if(!e)return;let r=new URL(e),n=`${r.pathname.replace(Ce,"")}/`;if(!(r.username||r.password||r.search||r.hash||t.origin!==r.origin||!t.pathname.startsWith(n)))return`/${t.pathname.slice(n.length)}`}function Me(t,e){if(t)try{let r=new URL(t),n=Ie(r,e);return r.protocol!=="https:"||!n||r.username||r.password||r.search||r.hash||n.startsWith("/__image/")||n.includes("/chat-media/")||!Re.test(n)?void 0:r}catch{}}function ie(t,e){return t.searchParams.set("w",String(e)),t.searchParams.set("f","webp"),t.href}function et({alt:t,width:e,height:r,src:n,maxWidth:i,onError:a,decoding:o="async",...s}){let[c,m]=(0,w.useState)(),k=(0,w.useContext)(Te),y=c===n?void 0:Me(n,k),E=Oe.filter(h=>h<=i),T=E.at(-1)??96;return(0,ae.jsx)("img",{...s,alt:t,decoding:o,height:r,onError:h=>{y?m(n):a?.(h)},src:y?ie(y,T):n,srcSet:y?E.map(h=>`${ie(y,h)} ${h}w`).join(", "):void 0,width:e})}var C=b(O(),1),S=new Map,F,se=0,He=2147483647;function V(){clearTimeout(F),F=void 0;let t=Date.now(),e=Number.POSITIVE_INFINITY;for(let r of S.values())for(let n of r)n>t&&(e=Math.min(e,n));Number.isFinite(e)&&(F=setTimeout(ue,Math.min(e-t+1,He)))}function ue(){se+=1;for(let t of S.keys())t();V()}function oe(){document.hidden||ue()}var De=()=>se,Pe=()=>0;function rt(t,e,r=[]){let n=[t,e,...r.flatMap(a=>[a.startAt??t,a.endAt??e])].join(","),i=(0,C.useCallback)(a=>(S.size||document.addEventListener("visibilitychange",oe),S.set(a,n.split(",").map(Date.parse)),V(),()=>{S.delete(a),V(),S.size||document.removeEventListener("visibilitychange",oe)}),[n]);(0,C.useSyncExternalStore)(i,De,Pe)}var Ue=/<\/?(?:p|br|strong|em|u|s|ul|ol|li|blockquote|pre|code|hr|h[1-6]|a)(?:\s|\/?>)/i;function ce(t){return Ue.test(t)?t:t.replace(/&/g,"&amp;").replace(/</g,"&lt;").replace(/>/g,"&gt;").replace(/\r\n|\r|\n/g,"<br>")}var fe=b(_(),1);function ot({description:t,className:e,id:r}){return(0,fe.jsx)("div",{className:["lockerverse-auctions__description",e].filter(Boolean).join(" "),dangerouslySetInnerHTML:{__html:ce(t)},id:r})}var N=b(O(),1);function ft(){let t=(0,N.useRef)(null),[e,r]=(0,N.useState)(!1);return(0,N.useEffect)(()=>{let n=t.current;if(!(n&&"IntersectionObserver"in window))return;let i=!1,a=()=>r(i&&!document.hidden),o=new IntersectionObserver(([s])=>{i=!!(s?.isIntersecting&&s.intersectionRatio>0),a()});return o.observe(n),document.addEventListener("visibilitychange",a),()=>{o.disconnect(),document.removeEventListener("visibilitychange",a)}},[]),{ref:t,visible:e}}export{Ve as a,Be as b,Le as c,Ye as d,Qe as e,ot as f,Te as g,et as h,ft as i,rt as j};
2
- /*! For license information please see chunk-2Z3NXASX.js.LEGAL.txt */
1
+ import{a as O,r as _}from"./chunk-ZZUMO4Y2.js";import{a as z,c as b}from"./chunk-DCANE7XH.js";var le=z(d=>{"use strict";var $e=O();function de(t){var e="https://react.dev/errors/"+t;if(1<arguments.length){e+="?args[]="+encodeURIComponent(arguments[1]);for(var r=2;r<arguments.length;r++)e+="&args[]="+encodeURIComponent(arguments[r])}return"Minified React error #"+t+"; visit "+e+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}function v(){}var f={d:{f:v,r:function(){throw Error(de(522))},D:v,C:v,L:v,m:v,X:v,S:v,M:v},p:0,findDOMNode:null},qe=Symbol.for("react.portal");function Fe(t,e,r){var n=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:qe,key:n==null?null:""+n,children:t,containerInfo:e,implementation:r}}var L=$e.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE;function x(t,e){if(t==="font")return"";if(typeof e=="string")return e==="use-credentials"?e:""}d.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=f;d.createPortal=function(t,e){var r=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!e||e.nodeType!==1&&e.nodeType!==9&&e.nodeType!==11)throw Error(de(299));return Fe(t,e,null,r)};d.flushSync=function(t){var e=L.T,r=f.p;try{if(L.T=null,f.p=2,t)return t()}finally{L.T=e,f.p=r,f.d.f()}};d.preconnect=function(t,e){typeof t=="string"&&(e?(e=e.crossOrigin,e=typeof e=="string"?e==="use-credentials"?e:"":void 0):e=null,f.d.C(t,e))};d.prefetchDNS=function(t){typeof t=="string"&&f.d.D(t)};d.preinit=function(t,e){if(typeof t=="string"&&e&&typeof e.as=="string"){var r=e.as,n=x(r,e.crossOrigin),i=typeof e.integrity=="string"?e.integrity:void 0,a=typeof e.fetchPriority=="string"?e.fetchPriority:void 0;r==="style"?f.d.S(t,typeof e.precedence=="string"?e.precedence:void 0,{crossOrigin:n,integrity:i,fetchPriority:a}):r==="script"&&f.d.X(t,{crossOrigin:n,integrity:i,fetchPriority:a,nonce:typeof e.nonce=="string"?e.nonce:void 0})}};d.preinitModule=function(t,e){if(typeof t=="string")if(typeof e=="object"&&e!==null){if(e.as==null||e.as==="script"){var r=x(e.as,e.crossOrigin);f.d.M(t,{crossOrigin:r,integrity:typeof e.integrity=="string"?e.integrity:void 0,nonce:typeof e.nonce=="string"?e.nonce:void 0})}}else e==null&&f.d.M(t)};d.preload=function(t,e){if(typeof t=="string"&&typeof e=="object"&&e!==null&&typeof e.as=="string"){var r=e.as,n=x(r,e.crossOrigin);f.d.L(t,r,{crossOrigin:n,integrity:typeof e.integrity=="string"?e.integrity:void 0,nonce:typeof e.nonce=="string"?e.nonce:void 0,type:typeof e.type=="string"?e.type:void 0,fetchPriority:typeof e.fetchPriority=="string"?e.fetchPriority:void 0,referrerPolicy:typeof e.referrerPolicy=="string"?e.referrerPolicy:void 0,imageSrcSet:typeof e.imageSrcSet=="string"?e.imageSrcSet:void 0,imageSizes:typeof e.imageSizes=="string"?e.imageSizes:void 0,media:typeof e.media=="string"?e.media:void 0})}};d.preloadModule=function(t,e){if(typeof t=="string")if(e){var r=x(e.as,e.crossOrigin);f.d.m(t,{as:typeof e.as=="string"&&e.as!=="script"?e.as:void 0,crossOrigin:r,integrity:typeof e.integrity=="string"?e.integrity:void 0})}else f.d.m(t)};d.requestFormReset=function(t){f.d.r(t)};d.unstable_batchedUpdates=function(t,e){return t(e)};d.useFormState=function(t,e,r){return L.H.useFormState(t,e,r)};d.useFormStatus=function(){return L.H.useHostTransitionStatus()};d.version="19.2.8"});var Ve=z((ct,me)=>{"use strict";function ge(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(ge)}catch(t){console.error(t)}}ge(),me.exports=le()});var he={grad:.9,turn:360,rad:360/(2*Math.PI)},p=function(t){return typeof t=="string"?t.length>0:typeof t=="number"},u=function(t,e,r){return e===void 0&&(e=0),r===void 0&&(r=Math.pow(10,e)),Math.round(r*t)/r+0},l=function(t,e,r){return e===void 0&&(e=0),r===void 0&&(r=1),t>r?r:t>e?t:e},Q=function(t){return(t=isFinite(t)?t%360:0)>0?t:t+360},B=function(t){return{r:l(t.r,0,255),g:l(t.g,0,255),b:l(t.b,0,255),a:l(t.a)}},I=function(t){return{r:u(t.r),g:u(t.g),b:u(t.b),a:u(t.a,3)}},be=/^#([0-9a-f]{3,8})$/i,R=function(t){var e=t.toString(16);return e.length<2?"0"+e:e},Z=function(t){var e=t.r,r=t.g,n=t.b,i=t.a,a=Math.max(e,r,n),o=a-Math.min(e,r,n),s=o?a===e?(r-n)/o:a===r?2+(n-e)/o:4+(e-r)/o:0;return{h:60*(s<0?s+6:s),s:a?o/a*100:0,v:a/255*100,a:i}},ee=function(t){var e=t.h,r=t.s,n=t.v,i=t.a;e=e/360*6,r/=100,n/=100;var a=Math.floor(e),o=n*(1-r),s=n*(1-(e-a)*r),c=n*(1-(1-e+a)*r),m=a%6;return{r:255*[n,s,o,o,c,n][m],g:255*[c,n,n,s,o,o][m],b:255*[o,o,c,n,n,s][m],a:i}},K=function(t){return{h:Q(t.h),s:l(t.s,0,100),l:l(t.l,0,100),a:l(t.a)}},G=function(t){return{h:u(t.h),s:u(t.s),l:u(t.l),a:u(t.a,3)}},W=function(t){return ee((r=(e=t).s,{h:e.h,s:(r*=((n=e.l)<50?n:100-n)/100)>0?2*r/(n+r)*100:0,v:n+r,a:e.a}));var e,r,n},A=function(t){return{h:(e=Z(t)).h,s:(i=(200-(r=e.s))*(n=e.v)/100)>0&&i<200?r*n/100/(i<=100?i:200-i)*100:0,l:i/2,a:e.a};var e,r,n,i},pe=/^hsla?\(\s*([+-]?\d*\.?\d+)(deg|rad|grad|turn)?\s*,\s*([+-]?\d*\.?\d+)%\s*,\s*([+-]?\d*\.?\d+)%\s*(?:,\s*([+-]?\d*\.?\d+)(%)?\s*)?\)$/i,ye=/^hsla?\(\s*([+-]?\d*\.?\d+)(deg|rad|grad|turn)?\s+([+-]?\d*\.?\d+)%\s+([+-]?\d*\.?\d+)%\s*(?:\/\s*([+-]?\d*\.?\d+)(%)?\s*)?\)$/i,ve=/^rgba?\(\s*([+-]?\d*\.?\d+)(%)?\s*,\s*([+-]?\d*\.?\d+)(%)?\s*,\s*([+-]?\d*\.?\d+)(%)?\s*(?:,\s*([+-]?\d*\.?\d+)(%)?\s*)?\)$/i,ke=/^rgba?\(\s*([+-]?\d*\.?\d+)(%)?\s+([+-]?\d*\.?\d+)(%)?\s+([+-]?\d*\.?\d+)(%)?\s*(?:\/\s*([+-]?\d*\.?\d+)(%)?\s*)?\)$/i,D={string:[[function(t){var e=be.exec(t);return e?(t=e[1]).length<=4?{r:parseInt(t[0]+t[0],16),g:parseInt(t[1]+t[1],16),b:parseInt(t[2]+t[2],16),a:t.length===4?u(parseInt(t[3]+t[3],16)/255,2):1}:t.length===6||t.length===8?{r:parseInt(t.substr(0,2),16),g:parseInt(t.substr(2,2),16),b:parseInt(t.substr(4,2),16),a:t.length===8?u(parseInt(t.substr(6,2),16)/255,2):1}:null:null},"hex"],[function(t){var e=ve.exec(t)||ke.exec(t);return e?e[2]!==e[4]||e[4]!==e[6]?null:B({r:Number(e[1])/(e[2]?100/255:1),g:Number(e[3])/(e[4]?100/255:1),b:Number(e[5])/(e[6]?100/255:1),a:e[7]===void 0?1:Number(e[7])/(e[8]?100:1)}):null},"rgb"],[function(t){var e=pe.exec(t)||ye.exec(t);if(!e)return null;var r,n,i=K({h:(r=e[1],n=e[2],n===void 0&&(n="deg"),Number(r)*(he[n]||1)),s:Number(e[3]),l:Number(e[4]),a:e[5]===void 0?1:Number(e[5])/(e[6]?100:1)});return W(i)},"hsl"]],object:[[function(t){var e=t.r,r=t.g,n=t.b,i=t.a,a=i===void 0?1:i;return p(e)&&p(r)&&p(n)?B({r:Number(e),g:Number(r),b:Number(n),a:Number(a)}):null},"rgb"],[function(t){var e=t.h,r=t.s,n=t.l,i=t.a,a=i===void 0?1:i;if(!p(e)||!p(r)||!p(n))return null;var o=K({h:Number(e),s:Number(r),l:Number(n),a:Number(a)});return W(o)},"hsl"],[function(t){var e=t.h,r=t.s,n=t.v,i=t.a,a=i===void 0?1:i;if(!p(e)||!p(r)||!p(n))return null;var o=(function(s){return{h:Q(s.h),s:l(s.s,0,100),v:l(s.v,0,100),a:l(s.a)}})({h:Number(e),s:Number(r),v:Number(n),a:Number(a)});return ee(o)},"hsv"]]},X=function(t,e){for(var r=0;r<e.length;r++){var n=e[r][0](t);if(n)return[n,e[r][1]]}return[null,void 0]},_e=function(t){return typeof t=="string"?X(t.trim(),D.string):typeof t=="object"&&t!==null?X(t,D.object):[null,void 0]};var M=function(t,e){var r=A(t);return{h:r.h,s:l(r.s+100*e,0,100),l:r.l,a:r.a}},H=function(t){return(299*t.r+587*t.g+114*t.b)/1e3/255},Y=function(t,e){var r=A(t);return{h:r.h,s:r.s,l:l(r.l+100*e,0,100),a:r.a}},P=(function(){function t(e){this.parsed=_e(e)[0],this.rgba=this.parsed||{r:0,g:0,b:0,a:1}}return t.prototype.isValid=function(){return this.parsed!==null},t.prototype.brightness=function(){return u(H(this.rgba),2)},t.prototype.isDark=function(){return H(this.rgba)<.5},t.prototype.isLight=function(){return H(this.rgba)>=.5},t.prototype.toHex=function(){return e=I(this.rgba),r=e.r,n=e.g,i=e.b,o=(a=e.a)<1?R(u(255*a)):"","#"+R(r)+R(n)+R(i)+o;var e,r,n,i,a,o},t.prototype.toRgb=function(){return I(this.rgba)},t.prototype.toRgbString=function(){return e=I(this.rgba),r=e.r,n=e.g,i=e.b,(a=e.a)<1?"rgba("+r+", "+n+", "+i+", "+a+")":"rgb("+r+", "+n+", "+i+")";var e,r,n,i,a},t.prototype.toHsl=function(){return G(A(this.rgba))},t.prototype.toHslString=function(){return e=G(A(this.rgba)),r=e.h,n=e.s,i=e.l,(a=e.a)<1?"hsla("+r+", "+n+"%, "+i+"%, "+a+")":"hsl("+r+", "+n+"%, "+i+"%)";var e,r,n,i,a},t.prototype.toHsv=function(){return e=Z(this.rgba),{h:u(e.h),s:u(e.s),v:u(e.v),a:u(e.a,3)};var e},t.prototype.invert=function(){return g({r:255-(e=this.rgba).r,g:255-e.g,b:255-e.b,a:e.a});var e},t.prototype.saturate=function(e){return e===void 0&&(e=.1),g(M(this.rgba,e))},t.prototype.desaturate=function(e){return e===void 0&&(e=.1),g(M(this.rgba,-e))},t.prototype.grayscale=function(){return g(M(this.rgba,-1))},t.prototype.lighten=function(e){return e===void 0&&(e=.1),g(Y(this.rgba,e))},t.prototype.darken=function(e){return e===void 0&&(e=.1),g(Y(this.rgba,-e))},t.prototype.rotate=function(e){return e===void 0&&(e=15),this.hue(this.hue()+e)},t.prototype.alpha=function(e){return typeof e=="number"?g({r:(r=this.rgba).r,g:r.g,b:r.b,a:e}):u(this.rgba.a,3);var r},t.prototype.hue=function(e){var r=A(this.rgba);return typeof e=="number"?g({h:e,s:r.s,l:r.l,a:r.a}):u(r.h)},t.prototype.isEqual=function(e){return this.toHex()===g(e).toHex()},t})(),g=function(t){return t instanceof P?t:new P(t)},J=[],te=function(t){t.forEach(function(e){J.indexOf(e)<0&&(e(P,D),J.push(e))})};function re(t,e){var r={white:"#ffffff",bisque:"#ffe4c4",blue:"#0000ff",cadetblue:"#5f9ea0",chartreuse:"#7fff00",chocolate:"#d2691e",coral:"#ff7f50",antiquewhite:"#faebd7",aqua:"#00ffff",azure:"#f0ffff",whitesmoke:"#f5f5f5",papayawhip:"#ffefd5",plum:"#dda0dd",blanchedalmond:"#ffebcd",black:"#000000",gold:"#ffd700",goldenrod:"#daa520",gainsboro:"#dcdcdc",cornsilk:"#fff8dc",cornflowerblue:"#6495ed",burlywood:"#deb887",aquamarine:"#7fffd4",beige:"#f5f5dc",crimson:"#dc143c",cyan:"#00ffff",darkblue:"#00008b",darkcyan:"#008b8b",darkgoldenrod:"#b8860b",darkkhaki:"#bdb76b",darkgray:"#a9a9a9",darkgreen:"#006400",darkgrey:"#a9a9a9",peachpuff:"#ffdab9",darkmagenta:"#8b008b",darkred:"#8b0000",darkorchid:"#9932cc",darkorange:"#ff8c00",darkslateblue:"#483d8b",gray:"#808080",darkslategray:"#2f4f4f",darkslategrey:"#2f4f4f",deeppink:"#ff1493",deepskyblue:"#00bfff",wheat:"#f5deb3",firebrick:"#b22222",floralwhite:"#fffaf0",ghostwhite:"#f8f8ff",darkviolet:"#9400d3",magenta:"#ff00ff",green:"#008000",dodgerblue:"#1e90ff",grey:"#808080",honeydew:"#f0fff0",hotpink:"#ff69b4",blueviolet:"#8a2be2",forestgreen:"#228b22",lawngreen:"#7cfc00",indianred:"#cd5c5c",indigo:"#4b0082",fuchsia:"#ff00ff",brown:"#a52a2a",maroon:"#800000",mediumblue:"#0000cd",lightcoral:"#f08080",darkturquoise:"#00ced1",lightcyan:"#e0ffff",ivory:"#fffff0",lightyellow:"#ffffe0",lightsalmon:"#ffa07a",lightseagreen:"#20b2aa",linen:"#faf0e6",mediumaquamarine:"#66cdaa",lemonchiffon:"#fffacd",lime:"#00ff00",khaki:"#f0e68c",mediumseagreen:"#3cb371",limegreen:"#32cd32",mediumspringgreen:"#00fa9a",lightskyblue:"#87cefa",lightblue:"#add8e6",midnightblue:"#191970",lightpink:"#ffb6c1",mistyrose:"#ffe4e1",moccasin:"#ffe4b5",mintcream:"#f5fffa",lightslategray:"#778899",lightslategrey:"#778899",navajowhite:"#ffdead",navy:"#000080",mediumvioletred:"#c71585",powderblue:"#b0e0e6",palegoldenrod:"#eee8aa",oldlace:"#fdf5e6",paleturquoise:"#afeeee",mediumturquoise:"#48d1cc",mediumorchid:"#ba55d3",rebeccapurple:"#663399",lightsteelblue:"#b0c4de",mediumslateblue:"#7b68ee",thistle:"#d8bfd8",tan:"#d2b48c",orchid:"#da70d6",mediumpurple:"#9370db",purple:"#800080",pink:"#ffc0cb",skyblue:"#87ceeb",springgreen:"#00ff7f",palegreen:"#98fb98",red:"#ff0000",yellow:"#ffff00",slateblue:"#6a5acd",lavenderblush:"#fff0f5",peru:"#cd853f",palevioletred:"#db7093",violet:"#ee82ee",teal:"#008080",slategray:"#708090",slategrey:"#708090",aliceblue:"#f0f8ff",darkseagreen:"#8fbc8f",darkolivegreen:"#556b2f",greenyellow:"#adff2f",seagreen:"#2e8b57",seashell:"#fff5ee",tomato:"#ff6347",silver:"#c0c0c0",sienna:"#a0522d",lavender:"#e6e6fa",lightgreen:"#90ee90",orange:"#ffa500",orangered:"#ff4500",steelblue:"#4682b4",royalblue:"#4169e1",turquoise:"#40e0d0",yellowgreen:"#9acd32",salmon:"#fa8072",saddlebrown:"#8b4513",sandybrown:"#f4a460",rosybrown:"#bc8f8f",darksalmon:"#e9967a",lightgoldenrodyellow:"#fafad2",snow:"#fffafa",lightgrey:"#d3d3d3",lightgray:"#d3d3d3",dimgray:"#696969",dimgrey:"#696969",olivedrab:"#6b8e23",olive:"#808000"},n={};for(var i in r)n[r[i]]=i;var a={};t.prototype.toName=function(o){if(!(this.rgba.a||this.rgba.r||this.rgba.g||this.rgba.b))return"transparent";var s,c,m=n[this.toHex()];if(m)return m;if(o?.closest){var k=this.toRgb(),y=1/0,E="black";if(!a.length)for(var T in r)a[T]=new t(r[T]).toRgb();for(var h in r){var j=(s=k,c=a[h],Math.pow(s.r-c.r,2)+Math.pow(s.g-c.g,2)+Math.pow(s.b-c.b,2));j<y&&(y=j,E=h)}return E}},e.string.push([function(o){var s=o.toLowerCase(),c=s==="transparent"?"#0000":r[s];return c?new t(c).toRgb():null},"name"])}var we=/^#([\da-f]{3}|[\da-f]{6})$/i,Se=/^([\da-f]{3}|[\da-f]{6})$/i;function U(t){let e=t.trim();return Se.test(e)?`#${e}`:e}function Ne(t){let e=we.exec(U(t));if(!e)return;let[,r]=e;if(!r)return;let n=r.length===3?Array.from(r,i=>`${i}${i}`).join(""):r;return[0,2,4].map(i=>Number.parseInt(n.slice(i,i+2),16))}function $([t,e,r]){let[n=0,i=0,a=0]=[t,e,r].map((m=0)=>{let k=m/255;return k<=.04045?k/12.92:((k+.055)/1.055)**2.4}),o=.2126*n+.7152*i+.0722*a,s=(o+.05)/.05,c=1.05/(o+.05);return s>=c?"#000":"#fff"}function Be(t){let e=Ne(t);if(e)return $(e)}te([re]);var ne="c062f2a0-f356-4fa1-bde8-3f08d42c2858",Ee="#6f8f6d";function Ae(t,e){let r=g(t);if(!r.isValid())return;let{r:n,g:i,b:a,a:o}=r.toRgb(),s=e==="dark"?5:255;return $([n,i,a].map(c=>c*o+s*(1-o)))}function Le(t,e={},r="light"){let n=t.community?.color?.trim(),i=e["--lockerverse-accent"]??(n?U(n):Ee),a={"--lockerverse-font-family":"inherit",...e,"--lockerverse-accent":i,"--lockerverse-accent-contrast":e["--lockerverse-accent-contrast"]??Ae(i,r)??"#000"};return t.id===ne&&!a["--lockerverse-auction-catalog-columns"]&&(a["--lockerverse-auction-catalog-columns"]="2"),a}function Ye(t,e={},r="light"){let n=Le(t,e,r),i={className:"lockerverse-auctions--embed",style:n},a=t.id===ne?"light":void 0;return{catalog:{className:i.className,showFilters:!1,showHeader:!1,showLineup:!1,style:n},defaultTheme:a,item:i}}var q=b(_(),1);function Qe({href:t,onBack:e,className:r,children:n,elementRef:i}){return t?(0,q.jsx)("a",{className:r,href:t,onClick:a=>{e&&a.button===0&&!a.metaKey&&!a.ctrlKey&&!a.shiftKey&&!a.altKey&&(a.preventDefault(),e())},ref:i,children:n}):e?(0,q.jsx)("button",{className:r,onClick:e,ref:i,type:"button",children:n}):null}var w=b(O(),1),ae=b(_(),1),Te=(0,w.createContext)(void 0),Oe=[96,192,320,480,640,960,1280,1920],Re=/\.(jpe?g|png|webp|avif)$/i,Ce=/\/+$/,xe=new Set(["media.lockerverse.com","dev-media.lockerverse.com"]);function Ie(t,e){if(xe.has(t.hostname)&&!t.port)return t.pathname;if(!e)return;let r=new URL(e),n=`${r.pathname.replace(Ce,"")}/`;if(!(r.username||r.password||r.search||r.hash||t.origin!==r.origin||!t.pathname.startsWith(n)))return`/${t.pathname.slice(n.length)}`}function Me(t,e){if(t)try{let r=new URL(t),n=Ie(r,e);return r.protocol!=="https:"||!n||r.username||r.password||r.search||r.hash||n.startsWith("/__image/")||n.includes("/chat-media/")||!Re.test(n)?void 0:r}catch{}}function ie(t,e){return t.searchParams.set("w",String(e)),t.searchParams.set("f","webp"),t.href}function et({alt:t,width:e,height:r,src:n,maxWidth:i,onError:a,decoding:o="async",...s}){let[c,m]=(0,w.useState)(),k=(0,w.useContext)(Te),y=c===n?void 0:Me(n,k),E=Oe.filter(h=>h<=i),T=E.at(-1)??96;return(0,ae.jsx)("img",{...s,alt:t,decoding:o,height:r,onError:h=>{y?m(n):a?.(h)},src:y?ie(y,T):n,srcSet:y?E.map(h=>`${ie(y,h)} ${h}w`).join(", "):void 0,width:e})}var C=b(O(),1),S=new Map,F,se=0,He=2147483647;function V(){clearTimeout(F),F=void 0;let t=Date.now(),e=Number.POSITIVE_INFINITY;for(let r of S.values())for(let n of r)n>t&&(e=Math.min(e,n));Number.isFinite(e)&&(F=setTimeout(ue,Math.min(e-t+1,He)))}function ue(){se+=1;for(let t of S.keys())t();V()}function oe(){document.hidden||ue()}var De=()=>se,Pe=()=>0;function rt(t,e,r=[]){let n=[t,e,...r.flatMap(a=>[a.startAt??t,a.endAt??e])].join(","),i=(0,C.useCallback)(a=>(S.size||document.addEventListener("visibilitychange",oe),S.set(a,n.split(",").map(Date.parse)),V(),()=>{S.delete(a),V(),S.size||document.removeEventListener("visibilitychange",oe)}),[n]);(0,C.useSyncExternalStore)(i,De,Pe)}var Ue=/<\/?(?:p|br|strong|em|u|s|ul|ol|li|blockquote|pre|code|hr|h[1-6]|a)(?:\s|\/?>)/i;function ce(t){return Ue.test(t)?t:t.replace(/&/g,"&amp;").replace(/</g,"&lt;").replace(/>/g,"&gt;").replace(/\r\n|\r|\n/g,"<br>")}var fe=b(_(),1);function ot({description:t,className:e,id:r}){return(0,fe.jsx)("div",{className:["lockerverse-auctions__description",e].filter(Boolean).join(" "),dangerouslySetInnerHTML:{__html:ce(t)},id:r})}var N=b(O(),1);function ft(){let t=(0,N.useRef)(null),[e,r]=(0,N.useState)(!1);return(0,N.useEffect)(()=>{let n=t.current;if(!(n&&"IntersectionObserver"in window))return;let i=!1,a=()=>r(i&&!document.hidden),o=new IntersectionObserver(([s])=>{i=!!(s?.isIntersecting&&s.intersectionRatio>0),a()});return o.observe(n),document.addEventListener("visibilitychange",a),()=>{o.disconnect(),document.removeEventListener("visibilitychange",a)}},[]),{ref:t,visible:e}}export{Ve as a,Be as b,Le as c,Ye as d,Qe as e,ot as f,Te as g,et as h,ft as i,rt as j};
2
+ /*! For license information please see chunk-5CDI46U3.js.LEGAL.txt */
@@ -1 +1 @@
1
- import{A as P,B as $,C as I,D as b,E as D,F as U,G as N,H as _,I as q,J as l,K as y,L as V,O as H,P as G,a as ie,b as L,d as B,e as O,r as h,u as f,v as R,y as E,z as M}from"./chunk-BDPIC42C.js";import{c as p}from"./chunk-DCANE7XH.js";var Q="lockerverse:auction-bidder",W=N(_({address:_({city:l(),country:l(),line1:l(),line2:N(l()),postal_code:l(),state:l()}),name:l()})),oe=_({billing:W,email:l(),phone:l(),sameAsBilling:q(D(),!0),shipping:W,version:U(1)});function fe(){try{let e=window.localStorage.getItem(Q);if(!e)return null;let n=V(oe,JSON.parse(e));if(!n.success)return null;let{version:t,...o}=n.output;return o}catch{return null}}function z(e){if(!e?.complete)return null;let{address:n,name:t}=e.value;return{address:{city:n.city,country:n.country,line1:n.line1,line2:n.line2,postal_code:n.postal_code,state:n.state},name:t}}function be(e,n){let t={mode:e};return n&&(t.defaultValues=n),t}function ye({contact:e,billing:n,shipping:t,sameAsBilling:o,collectShippingAddress:r,previous:a}){let s=r&&!o?z(t):null;re({billing:z(n)??a?.billing??null,email:e.email,phone:e.phone,sameAsBilling:o,shipping:s??a?.shipping??null})}function re(e){try{window.localStorage.setItem(Q,JSON.stringify({...e,version:1}))}catch{}}function Y(e,n,t){let o=H(e,n.saleMode==="buy_now"?(n.buyNowPriceAmount??0)*t.quantity:t.amount,t.includeServiceFee,n.additionalCharge?n.additionalCharge.firstUnitAmountCents+n.additionalCharge.additionalUnitAmountCents*(n.saleMode==="buy_now"?t.quantity-1:0):0);return n.additionalCharge?{...o,additionalCharge:n.additionalCharge}:o}function Ee(e,n,t){if(R(e,n)!=="active")return"This item is not accepting bids or purchases.";if(t.bidType==="maximum"&&!n.supportsMaximumBids)return"Maximum bidding is not available for this item. Choose a fixed bid.";if(n.saleMode==="hybrid")return"This item type is not supported for checkout.";if(n.saleMode==="buy_now"){if(n.isSoldOut||n.availableQuantity===0)return"This item is sold out.";if(t.quantity>(n.maxQuantityPerOrder??Number.POSITIVE_INFINITY))return`You can buy up to ${n.maxQuantityPerOrder} items per order.`;if(!(n.buyNowPriceAmount&&Number.isSafeInteger(t.quantity))||t.quantity<1||n.availableQuantity!==null&&t.quantity>n.availableQuantity)return"Select an available quantity."}else if(!Number.isSafeInteger(t.amount)||t.amount%100!==0||t.amount<G(n))return"Enter a whole-dollar bid at or above the minimum bid.";return null}function ae(e,n){return e?.name===n?.name&&e?.category===n?.category&&e?.firstUnitAmountCents===n?.firstUnitAmountCents&&e?.additionalUnitAmountCents===n?.additionalUnitAmountCents}function _e(e,n,t,o,r){return e.payment?.publishableKey!==n.payment?.publishableKey||e.payment?.connectedAccountId!==n.payment?.connectedAccountId||e.serviceFeeEnabled!==n.serviceFeeEnabled||t.saleMode!==o.saleMode||!ae(t.additionalCharge,o.additionalCharge)||t.collectShippingAddress!==o.collectShippingAddress||JSON.stringify(Y(e,t,r))!==JSON.stringify(Y(n,o,r))}function Se(e){return{expectedAdditionalChargeCents:e.additionalChargeCents??0,expectedServiceFeeCents:e.serviceFeeCents,expectedSubtotalCents:e.subtotalCents,expectedTotalCents:e.totalCents}}async function Pe({stripe:e,elements:n,email:t,phone:o,billing:r,shipping:a,collectShippingAddress:s}){if(!(r?.complete&&r.value.name.trim()))throw new Error("Complete your billing name and address.");if(s&&!(a?.complete&&a.value.name.trim()))throw new Error("Complete your shipping name and address.");let v=await n.submit();if(v.error)throw new Error(v.error.message??"Check your payment details.");let m=await e.createConfirmationToken({elements:n,params:{payment_method_data:{allow_redisplay:"always",billing_details:{address:r.value.address,email:t,name:r.value.name,phone:o}},return_url:window.location.href,...s&&a?{shipping:{address:a.value.address,name:a.value.name,phone:o}}:void 0}});if(m.error||!m.confirmationToken)throw new Error(m.error?.message??"Unable to prepare payment details.");return m.confirmationToken.id}async function Ie(e,n){if(!n.requiresAction)return;if(!n.clientSecret)throw new Error("Payment confirmation is incomplete. Check its status before trying again.");let t=await e.handleNextAction({clientSecret:n.clientSecret});if(t.error)throw new Error(t.error.message??"Payment confirmation is incomplete.")}function xe(e,n){if(e)try{Promise.resolve(e(n)).catch(()=>{})}catch{}}var le="Email is required.",J="Enter a valid email address.",se="Phone is required.",x="Enter a valid phone number.",ce=/^(?:$|[^\s@]+@[^\s@]+\.[^\s@]+)$/,ue=/^\+[1-9]\d{6,14}$/;function j(e){return ue.test(e)}function g(e){return e.trim().replace(/[().\s-]/g,"")}var Te=y(l(),b(),$(ce,J)),Le=y(l(),b(),P(le),M(J)),Be=y(l(),b(),E(e=>e===""||g(e)!=="",x),I(g),E(e=>e===""||j(e),x)),Oe=y(l(),b(),P(se),I(g),E(j,x));var A=[{callingCode:"+1",label:"\u{1F1FA}\u{1F1F8} +1",value:"US"},{callingCode:"+52",label:"\u{1F1F2}\u{1F1FD} +52",value:"MX"},{callingCode:"+380",label:"\u{1F1FA}\u{1F1E6} +380",value:"UA"},{callingCode:"+48",label:"\u{1F1F5}\u{1F1F1} +48",value:"PL"},{callingCode:"+1",label:"\u{1F1E8}\u{1F1E6} +1",value:"CA"},{callingCode:"+49",label:"\u{1F1E9}\u{1F1EA} +49",value:"DE"},{callingCode:"+44",label:"\u{1F1EC}\u{1F1E7} +44",value:"GB"},{callingCode:"+46",label:"\u{1F1F8}\u{1F1EA} +46",value:"SE"},{callingCode:"+358",label:"\u{1F1EB}\u{1F1EE} +358",value:"FI"},{callingCode:"+1",label:"\u{1F1F5}\u{1F1F7} +1",value:"PR"}];function C(e){return A.find(n=>n.value===e)??A[0]}function de(e,n){let t=`${n}${n}`,o=e;for(;o.startsWith(t);)o=`${n}${o.slice(t.length)}`;return o}function $e(e,n){let t=g(e);if(!t)return"";let o=C(n),r=de(t,o.callingCode);return r.startsWith("+")?r:`${o.callingCode}${r}`}function K(e,n="US"){let t=g(e),o=C(n);return t.startsWith("+")&&!t.startsWith(o.callingCode)?A.find(r=>t.startsWith(r.callingCode))?.value??o.value:o.value}var u=p(h(),1);function me({className:e,error:n,id:t}){return n?(0,u.jsx)("span",{className:`lockerverse-form__error ${e??""}`,id:t,role:"alert",children:n}):null}function w({children:e,error:n,errorId:t,id:o,label:r}){return(0,u.jsxs)("div",{className:"lockerverse-form__field",children:[(0,u.jsx)("label",{htmlFor:o,children:r}),e,(0,u.jsx)(me,{error:n,id:t??`${o}-error`})]})}function pe({className:e,error:n,errorId:t,id:o,label:r,...a}){let s=t??`${o}-error`;return(0,u.jsx)(w,{error:n,errorId:s,id:o,label:r,children:(0,u.jsx)("input",{...a,"aria-describedby":n?s:a["aria-describedby"],"aria-invalid":n?"true":a["aria-invalid"],className:`lockerverse-form__control ${e??""}`,id:o})})}function X(e){return(0,u.jsx)(pe,{autoComplete:"email",placeholder:"name@example.com",...e,type:"email"})}function F({className:e,...n}){return(0,u.jsx)("input",{...n,className:["lockerverse-form__checkbox",e].filter(Boolean).join(" "),type:"checkbox"})}var Z=p(ie(),1);var d=p(h(),1);function ee({id:e,name:n,value:t,onChange:o,country:r,required:a,disabled:s,inputRef:v,error:m,errorId:ne,placeholder:te="(201) 555-0123"}){let T=(0,Z.useRef)(null),S=C(r);return(0,d.jsxs)("div",{className:"lockerverse-form__phone",dir:"ltr",children:[(0,d.jsxs)("div",{className:"lockerverse-form__phone-country",children:[(0,d.jsxs)("span",{"aria-hidden":"true",children:[(0,d.jsx)("span",{className:"lockerverse-form__phone-flag",children:S.label.split(" ")[0]}),S.callingCode,(0,d.jsx)(B,{"aria-hidden":"true",size:14})]}),(0,d.jsx)("select",{"aria-label":"Phone number country",disabled:s,name:"phoneCountry",onChange:c=>{let k=C(c.target.value);o({country:k.value,value:t}),T.current?.focus()},value:S.value,children:A.map(c=>(0,d.jsx)("option",{value:c.value,children:c.label},c.value))})]}),(0,d.jsx)("input",{"aria-describedby":m?ne:void 0,"aria-invalid":m?!0:void 0,autoComplete:"tel-national",disabled:s,id:e,name:n,onChange:c=>{let k=c.target.value;o({country:K(k,r),value:k})},placeholder:te,ref:c=>{T.current=c,v&&(v.current=c)},required:a,type:"tel",value:t})]})}var i=p(h(),1);function Ye(e){let{isPurchase:n,item:t,id:o}=e;return(0,i.jsxs)("form",{className:"lockerverse-auctions__checkout",noValidate:!0,onSubmit:e.onSubmit,children:[(0,i.jsx)("div",{className:"lockerverse-auctions__checkout-header",children:(0,i.jsxs)("div",{className:"lockerverse-auctions__checkout-navigation",children:[(0,i.jsx)("button",{"aria-label":"Back",className:"lockerverse-auctions__checkout-back",disabled:!e.onBack,onClick:e.onBack,type:"button",children:(0,i.jsx)(O,{"aria-hidden":"true",size:20})}),(0,i.jsx)("h2",{children:n?"Review your purchase":"Confirm your bid"}),(0,i.jsx)("p",{className:"lockerverse-auctions__checkout-eyebrow",children:"Step 2 of 2"})]})}),(0,i.jsxs)("div",{className:"lockerverse-auctions__checkout-body",children:[e.showFields&&(0,i.jsxs)("fieldset",{disabled:e.locked,children:[(0,i.jsxs)("div",{className:"lockerverse-auctions__checkout-contact",children:[(0,i.jsx)(X,{error:e.contactErrors.email,id:`${o}-email`,label:"Email",name:"email",onChange:r=>e.onEmailChange(r.target.value),required:!0,value:e.email}),(0,i.jsx)(w,{error:e.contactErrors.phone,id:`${o}-phone`,label:"Phone",children:(0,i.jsx)(ee,{country:e.phoneCountry,error:e.contactErrors.phone,errorId:`${o}-phone-error`,id:`${o}-phone`,name:"phone",onChange:e.onPhoneChange,required:!0,value:e.phone})})]}),(0,i.jsxs)("section",{"aria-label":"Payment Information",className:"lockerverse-auctions__checkout-section",children:[(0,i.jsx)("h3",{children:"Payment method"}),e.paymentFields]}),(0,i.jsxs)("section",{"aria-label":"Billing Details",className:"lockerverse-auctions__checkout-section",children:[(0,i.jsx)("h3",{children:"Billing Details"}),e.billingFields]}),t.collectShippingAddress&&(0,i.jsxs)("section",{"aria-label":"Delivery Details",className:"lockerverse-auctions__checkout-section",children:[(0,i.jsxs)("label",{className:"lockerverse-auctions__checkout-checkbox lockerverse-auctions__checkout-delivery",htmlFor:`${o}-delivery-same-as-billing`,children:[(0,i.jsx)(F,{checked:e.sameAsBilling,id:`${o}-delivery-same-as-billing`,onChange:r=>e.onSameAsBillingChange(r.target.checked)}),(0,i.jsx)("span",{children:(0,i.jsx)("strong",{children:"Use billing address for delivery"})})]}),!e.sameAsBilling&&(0,i.jsxs)(i.Fragment,{children:[(0,i.jsx)("h3",{children:"Delivery Address"}),e.shippingFields]})]}),(0,i.jsx)(he,{...e})]}),e.message&&(0,i.jsx)("p",{"aria-live":"polite",className:"lockerverse-auctions__notice",role:"status",children:e.message}),!e.isTerminal&&(0,i.jsxs)("div",{className:"lockerverse-auctions__checkout-footer",children:[(0,i.jsx)("p",{children:n?"By placing this order, you authorize this payment.":"By placing your bid, you agree to save this payment method and charge it if you win."}),(0,i.jsxs)("button",{className:"lockerverse-auctions__button lockerverse-auctions__checkout-submit",disabled:e.submitDisabled,type:"submit",children:[e.buttonText,(0,i.jsx)(L,{"aria-hidden":"true",size:16})]})]})]})]})}function he(e){let{pricing:n,isPurchase:t,isMaximumBid:o}=e,r=ge(t,o);return(0,i.jsxs)("section",{"aria-label":"Order amounts",className:"lockerverse-auctions__checkout-section lockerverse-auctions__amounts",children:[(0,i.jsxs)("p",{children:[(0,i.jsxs)("span",{children:[r.amount,t?` (\xD7${e.quantity})`:""]}),(0,i.jsx)("span",{children:f(n.subtotalCents)})]}),n.additionalCharge&&(0,i.jsxs)("p",{children:[(0,i.jsx)("span",{children:n.additionalCharge.name}),(0,i.jsx)("span",{children:f(n.additionalChargeCents??0)})]}),e.serviceFeeEnabled&&e.onIncludeServiceFeeChange&&(0,i.jsxs)("label",{className:"lockerverse-auctions__checkout-checkbox",htmlFor:`${e.id}-service-fee`,children:[(0,i.jsx)(F,{checked:e.includeServiceFee,id:`${e.id}-service-fee`,onChange:a=>e.onIncludeServiceFeeChange?.(a.target.checked)}),(0,i.jsx)("span",{children:"Cover processing fees"}),(0,i.jsx)("span",{children:f(e.serviceFeeCents)})]}),(0,i.jsxs)("p",{"aria-live":"polite",className:"lockerverse-auctions__total",children:[(0,i.jsx)("strong",{children:r.total}),(0,i.jsx)("strong",{children:f(n.totalCents)})]}),o&&(0,i.jsx)("small",{children:"Your maximum stays private. If you win, you pay the final price plus applicable fees and charges."})]})}function ge(e,n){return e?{amount:"Subtotal",fee:"Add",total:"Total"}:n?{amount:"Maximum bid",fee:"If I win, add up to",total:"Maximum total if I win"}:{amount:"Bid amount",fee:"If I win, add",total:"Total if I win"}}export{fe as a,be as b,ye as c,Y as d,Ee as e,ae as f,_e as g,Se as h,Pe as i,Ie as j,g as k,Le as l,Oe as m,$e as n,K as o,Ye as p,xe as q};
1
+ import{A as P,B as $,C as I,D as b,E as D,F as U,G as N,H as _,I as q,J as l,K as y,L as V,O as H,P as G,a as ie,b as L,d as B,e as O,r as h,u as f,v as R,y as E,z as M}from"./chunk-ZZUMO4Y2.js";import{c as p}from"./chunk-DCANE7XH.js";var Q="lockerverse:auction-bidder",W=N(_({address:_({city:l(),country:l(),line1:l(),line2:N(l()),postal_code:l(),state:l()}),name:l()})),oe=_({billing:W,email:l(),phone:l(),sameAsBilling:q(D(),!0),shipping:W,version:U(1)});function fe(){try{let e=window.localStorage.getItem(Q);if(!e)return null;let n=V(oe,JSON.parse(e));if(!n.success)return null;let{version:t,...o}=n.output;return o}catch{return null}}function z(e){if(!e?.complete)return null;let{address:n,name:t}=e.value;return{address:{city:n.city,country:n.country,line1:n.line1,line2:n.line2,postal_code:n.postal_code,state:n.state},name:t}}function be(e,n){let t={mode:e};return n&&(t.defaultValues=n),t}function ye({contact:e,billing:n,shipping:t,sameAsBilling:o,collectShippingAddress:r,previous:a}){let s=r&&!o?z(t):null;re({billing:z(n)??a?.billing??null,email:e.email,phone:e.phone,sameAsBilling:o,shipping:s??a?.shipping??null})}function re(e){try{window.localStorage.setItem(Q,JSON.stringify({...e,version:1}))}catch{}}function Y(e,n,t){let o=H(e,n.saleMode==="buy_now"?(n.buyNowPriceAmount??0)*t.quantity:t.amount,t.includeServiceFee,n.additionalCharge?n.additionalCharge.firstUnitAmountCents+n.additionalCharge.additionalUnitAmountCents*(n.saleMode==="buy_now"?t.quantity-1:0):0);return n.additionalCharge?{...o,additionalCharge:n.additionalCharge}:o}function Ee(e,n,t){if(R(e,n)!=="active")return"This item is not accepting bids or purchases.";if(t.bidType==="maximum"&&!n.supportsMaximumBids)return"Maximum bidding is not available for this item. Choose a fixed bid.";if(n.saleMode==="hybrid")return"This item type is not supported for checkout.";if(n.saleMode==="buy_now"){if(n.isSoldOut||n.availableQuantity===0)return"This item is sold out.";if(t.quantity>(n.maxQuantityPerOrder??Number.POSITIVE_INFINITY))return`You can buy up to ${n.maxQuantityPerOrder} items per order.`;if(!(n.buyNowPriceAmount&&Number.isSafeInteger(t.quantity))||t.quantity<1||n.availableQuantity!==null&&t.quantity>n.availableQuantity)return"Select an available quantity."}else if(!Number.isSafeInteger(t.amount)||t.amount%100!==0||t.amount<G(n))return"Enter a whole-dollar bid at or above the minimum bid.";return null}function ae(e,n){return e?.name===n?.name&&e?.category===n?.category&&e?.firstUnitAmountCents===n?.firstUnitAmountCents&&e?.additionalUnitAmountCents===n?.additionalUnitAmountCents}function _e(e,n,t,o,r){return e.payment?.publishableKey!==n.payment?.publishableKey||e.payment?.connectedAccountId!==n.payment?.connectedAccountId||e.serviceFeeEnabled!==n.serviceFeeEnabled||t.saleMode!==o.saleMode||!ae(t.additionalCharge,o.additionalCharge)||t.collectShippingAddress!==o.collectShippingAddress||JSON.stringify(Y(e,t,r))!==JSON.stringify(Y(n,o,r))}function Se(e){return{expectedAdditionalChargeCents:e.additionalChargeCents??0,expectedServiceFeeCents:e.serviceFeeCents,expectedSubtotalCents:e.subtotalCents,expectedTotalCents:e.totalCents}}async function Pe({stripe:e,elements:n,email:t,phone:o,billing:r,shipping:a,collectShippingAddress:s}){if(!(r?.complete&&r.value.name.trim()))throw new Error("Complete your billing name and address.");if(s&&!(a?.complete&&a.value.name.trim()))throw new Error("Complete your shipping name and address.");let v=await n.submit();if(v.error)throw new Error(v.error.message??"Check your payment details.");let m=await e.createConfirmationToken({elements:n,params:{payment_method_data:{allow_redisplay:"always",billing_details:{address:r.value.address,email:t,name:r.value.name,phone:o}},return_url:window.location.href,...s&&a?{shipping:{address:a.value.address,name:a.value.name,phone:o}}:void 0}});if(m.error||!m.confirmationToken)throw new Error(m.error?.message??"Unable to prepare payment details.");return m.confirmationToken.id}async function Ie(e,n){if(!n.requiresAction)return;if(!n.clientSecret)throw new Error("Payment confirmation is incomplete. Check its status before trying again.");let t=await e.handleNextAction({clientSecret:n.clientSecret});if(t.error)throw new Error(t.error.message??"Payment confirmation is incomplete.")}function xe(e,n){if(e)try{Promise.resolve(e(n)).catch(()=>{})}catch{}}var le="Email is required.",J="Enter a valid email address.",se="Phone is required.",x="Enter a valid phone number.",ce=/^(?:$|[^\s@]+@[^\s@]+\.[^\s@]+)$/,ue=/^\+[1-9]\d{6,14}$/;function j(e){return ue.test(e)}function g(e){return e.trim().replace(/[().\s-]/g,"")}var Te=y(l(),b(),$(ce,J)),Le=y(l(),b(),P(le),M(J)),Be=y(l(),b(),E(e=>e===""||g(e)!=="",x),I(g),E(e=>e===""||j(e),x)),Oe=y(l(),b(),P(se),I(g),E(j,x));var A=[{callingCode:"+1",label:"\u{1F1FA}\u{1F1F8} +1",value:"US"},{callingCode:"+52",label:"\u{1F1F2}\u{1F1FD} +52",value:"MX"},{callingCode:"+380",label:"\u{1F1FA}\u{1F1E6} +380",value:"UA"},{callingCode:"+48",label:"\u{1F1F5}\u{1F1F1} +48",value:"PL"},{callingCode:"+1",label:"\u{1F1E8}\u{1F1E6} +1",value:"CA"},{callingCode:"+49",label:"\u{1F1E9}\u{1F1EA} +49",value:"DE"},{callingCode:"+44",label:"\u{1F1EC}\u{1F1E7} +44",value:"GB"},{callingCode:"+46",label:"\u{1F1F8}\u{1F1EA} +46",value:"SE"},{callingCode:"+358",label:"\u{1F1EB}\u{1F1EE} +358",value:"FI"},{callingCode:"+1",label:"\u{1F1F5}\u{1F1F7} +1",value:"PR"}];function C(e){return A.find(n=>n.value===e)??A[0]}function de(e,n){let t=`${n}${n}`,o=e;for(;o.startsWith(t);)o=`${n}${o.slice(t.length)}`;return o}function $e(e,n){let t=g(e);if(!t)return"";let o=C(n),r=de(t,o.callingCode);return r.startsWith("+")?r:`${o.callingCode}${r}`}function K(e,n="US"){let t=g(e),o=C(n);return t.startsWith("+")&&!t.startsWith(o.callingCode)?A.find(r=>t.startsWith(r.callingCode))?.value??o.value:o.value}var u=p(h(),1);function me({className:e,error:n,id:t}){return n?(0,u.jsx)("span",{className:`lockerverse-form__error ${e??""}`,id:t,role:"alert",children:n}):null}function w({children:e,error:n,errorId:t,id:o,label:r}){return(0,u.jsxs)("div",{className:"lockerverse-form__field",children:[(0,u.jsx)("label",{htmlFor:o,children:r}),e,(0,u.jsx)(me,{error:n,id:t??`${o}-error`})]})}function pe({className:e,error:n,errorId:t,id:o,label:r,...a}){let s=t??`${o}-error`;return(0,u.jsx)(w,{error:n,errorId:s,id:o,label:r,children:(0,u.jsx)("input",{...a,"aria-describedby":n?s:a["aria-describedby"],"aria-invalid":n?"true":a["aria-invalid"],className:`lockerverse-form__control ${e??""}`,id:o})})}function X(e){return(0,u.jsx)(pe,{autoComplete:"email",placeholder:"name@example.com",...e,type:"email"})}function F({className:e,...n}){return(0,u.jsx)("input",{...n,className:["lockerverse-form__checkbox",e].filter(Boolean).join(" "),type:"checkbox"})}var Z=p(ie(),1);var d=p(h(),1);function ee({id:e,name:n,value:t,onChange:o,country:r,required:a,disabled:s,inputRef:v,error:m,errorId:ne,placeholder:te="(201) 555-0123"}){let T=(0,Z.useRef)(null),S=C(r);return(0,d.jsxs)("div",{className:"lockerverse-form__phone",dir:"ltr",children:[(0,d.jsxs)("div",{className:"lockerverse-form__phone-country",children:[(0,d.jsxs)("span",{"aria-hidden":"true",children:[(0,d.jsx)("span",{className:"lockerverse-form__phone-flag",children:S.label.split(" ")[0]}),S.callingCode,(0,d.jsx)(B,{"aria-hidden":"true",size:14})]}),(0,d.jsx)("select",{"aria-label":"Phone number country",disabled:s,name:"phoneCountry",onChange:c=>{let k=C(c.target.value);o({country:k.value,value:t}),T.current?.focus()},value:S.value,children:A.map(c=>(0,d.jsx)("option",{value:c.value,children:c.label},c.value))})]}),(0,d.jsx)("input",{"aria-describedby":m?ne:void 0,"aria-invalid":m?!0:void 0,autoComplete:"tel-national",disabled:s,id:e,name:n,onChange:c=>{let k=c.target.value;o({country:K(k,r),value:k})},placeholder:te,ref:c=>{T.current=c,v&&(v.current=c)},required:a,type:"tel",value:t})]})}var i=p(h(),1);function Ye(e){let{isPurchase:n,item:t,id:o}=e;return(0,i.jsxs)("form",{className:"lockerverse-auctions__checkout",noValidate:!0,onSubmit:e.onSubmit,children:[(0,i.jsx)("div",{className:"lockerverse-auctions__checkout-header",children:(0,i.jsxs)("div",{className:"lockerverse-auctions__checkout-navigation",children:[(0,i.jsx)("button",{"aria-label":"Back",className:"lockerverse-auctions__checkout-back",disabled:!e.onBack,onClick:e.onBack,type:"button",children:(0,i.jsx)(O,{"aria-hidden":"true",size:20})}),(0,i.jsx)("h2",{children:n?"Review your purchase":"Confirm your bid"}),(0,i.jsx)("p",{className:"lockerverse-auctions__checkout-eyebrow",children:"Step 2 of 2"})]})}),(0,i.jsxs)("div",{className:"lockerverse-auctions__checkout-body",children:[e.showFields&&(0,i.jsxs)("fieldset",{disabled:e.locked,children:[(0,i.jsxs)("div",{className:"lockerverse-auctions__checkout-contact",children:[(0,i.jsx)(X,{error:e.contactErrors.email,id:`${o}-email`,label:"Email",name:"email",onChange:r=>e.onEmailChange(r.target.value),required:!0,value:e.email}),(0,i.jsx)(w,{error:e.contactErrors.phone,id:`${o}-phone`,label:"Phone",children:(0,i.jsx)(ee,{country:e.phoneCountry,error:e.contactErrors.phone,errorId:`${o}-phone-error`,id:`${o}-phone`,name:"phone",onChange:e.onPhoneChange,required:!0,value:e.phone})})]}),(0,i.jsxs)("section",{"aria-label":"Payment Information",className:"lockerverse-auctions__checkout-section",children:[(0,i.jsx)("h3",{children:"Payment method"}),e.paymentFields]}),(0,i.jsxs)("section",{"aria-label":"Billing Details",className:"lockerverse-auctions__checkout-section",children:[(0,i.jsx)("h3",{children:"Billing Details"}),e.billingFields]}),t.collectShippingAddress&&(0,i.jsxs)("section",{"aria-label":"Delivery Details",className:"lockerverse-auctions__checkout-section",children:[(0,i.jsxs)("label",{className:"lockerverse-auctions__checkout-checkbox lockerverse-auctions__checkout-delivery",htmlFor:`${o}-delivery-same-as-billing`,children:[(0,i.jsx)(F,{checked:e.sameAsBilling,id:`${o}-delivery-same-as-billing`,onChange:r=>e.onSameAsBillingChange(r.target.checked)}),(0,i.jsx)("span",{children:(0,i.jsx)("strong",{children:"Use billing address for delivery"})})]}),!e.sameAsBilling&&(0,i.jsxs)(i.Fragment,{children:[(0,i.jsx)("h3",{children:"Delivery Address"}),e.shippingFields]})]}),(0,i.jsx)(he,{...e})]}),e.message&&(0,i.jsx)("p",{"aria-live":"polite",className:"lockerverse-auctions__notice",role:"status",children:e.message}),!e.isTerminal&&(0,i.jsxs)("div",{className:"lockerverse-auctions__checkout-footer",children:[(0,i.jsx)("p",{children:n?"By placing this order, you authorize this payment.":"By placing your bid, you agree to save this payment method and charge it if you win."}),(0,i.jsxs)("button",{className:"lockerverse-auctions__button lockerverse-auctions__checkout-submit",disabled:e.submitDisabled,type:"submit",children:[e.buttonText,(0,i.jsx)(L,{"aria-hidden":"true",size:16})]})]})]})]})}function he(e){let{pricing:n,isPurchase:t,isMaximumBid:o}=e,r=ge(t,o);return(0,i.jsxs)("section",{"aria-label":"Order amounts",className:"lockerverse-auctions__checkout-section lockerverse-auctions__amounts",children:[(0,i.jsxs)("p",{children:[(0,i.jsxs)("span",{children:[r.amount,t?` (\xD7${e.quantity})`:""]}),(0,i.jsx)("span",{children:f(n.subtotalCents)})]}),n.additionalCharge&&(0,i.jsxs)("p",{children:[(0,i.jsx)("span",{children:n.additionalCharge.name}),(0,i.jsx)("span",{children:f(n.additionalChargeCents??0)})]}),e.serviceFeeEnabled&&e.onIncludeServiceFeeChange&&(0,i.jsxs)("label",{className:"lockerverse-auctions__checkout-checkbox",htmlFor:`${e.id}-service-fee`,children:[(0,i.jsx)(F,{checked:e.includeServiceFee,id:`${e.id}-service-fee`,onChange:a=>e.onIncludeServiceFeeChange?.(a.target.checked)}),(0,i.jsx)("span",{children:"Cover processing fees"}),(0,i.jsx)("span",{children:f(e.serviceFeeCents)})]}),(0,i.jsxs)("p",{"aria-live":"polite",className:"lockerverse-auctions__total",children:[(0,i.jsx)("strong",{children:r.total}),(0,i.jsx)("strong",{children:f(n.totalCents)})]}),o&&(0,i.jsx)("small",{children:"Your maximum stays private. If you win, you pay the final price plus applicable fees and charges."})]})}function ge(e,n){return e?{amount:"Subtotal",fee:"Add",total:"Total"}:n?{amount:"Maximum bid",fee:"If I win, add up to",total:"Maximum total if I win"}:{amount:"Bid amount",fee:"If I win, add",total:"Total if I win"}}export{fe as a,be as b,ye as c,Y as d,Ee as e,ae as f,_e as g,Se as h,Pe as i,Ie as j,g as k,Le as l,Oe as m,$e as n,K as o,Ye as p,xe as q};
@@ -1,2 +1,2 @@
1
- import{a as ee,c as Qe}from"./chunk-DCANE7XH.js";var na=ee(i=>{"use strict";var he=Symbol.for("react.transitional.element"),Ua=Symbol.for("react.portal"),_a=Symbol.for("react.fragment"),Ha=Symbol.for("react.strict_mode"),Ga=Symbol.for("react.profiler"),Va=Symbol.for("react.consumer"),za=Symbol.for("react.context"),Wa=Symbol.for("react.forward_ref"),Na=Symbol.for("react.suspense"),Xa=Symbol.for("react.memo"),ua=Symbol.for("react.lazy"),ja=Symbol.for("react.activity"),Ye=Symbol.iterator;function $a(e){return e===null||typeof e!="object"?null:(e=Ye&&e[Ye]||e["@@iterator"],typeof e=="function"?e:null)}var ra={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},sa=Object.assign,oa={};function N(e,a,t){this.props=e,this.context=a,this.refs=oa,this.updater=t||ra}N.prototype.isReactComponent={};N.prototype.setState=function(e,a){if(typeof e!="object"&&typeof e!="function"&&e!=null)throw Error("takes an object of state variables to update or a function which returns an object of state variables.");this.updater.enqueueSetState(this,e,a,"setState")};N.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,"forceUpdate")};function la(){}la.prototype=N.prototype;function Le(e,a,t){this.props=e,this.context=a,this.refs=oa,this.updater=t||ra}var Ie=Le.prototype=new la;Ie.constructor=Le;sa(Ie,N.prototype);Ie.isPureReactComponent=!0;var ea=Array.isArray;function me(){}var x={H:null,A:null,T:null,S:null},fa=Object.prototype.hasOwnProperty;function xe(e,a,t){var u=t.ref;return{$$typeof:he,type:e,key:a,ref:u!==void 0?u:null,props:t}}function Ka(e,a){return xe(e.type,a,e.props)}function ye(e){return typeof e=="object"&&e!==null&&e.$$typeof===he}function Za(e){var a={"=":"=0",":":"=2"};return"$"+e.replace(/[=:]/g,function(t){return a[t]})}var aa=/\/+/g;function pe(e,a){return typeof e=="object"&&e!==null&&e.key!=null?Za(""+e.key):a.toString(36)}function Ja(e){switch(e.status){case"fulfilled":return e.value;case"rejected":throw e.reason;default:switch(typeof e.status=="string"?e.then(me,me):(e.status="pending",e.then(function(a){e.status==="pending"&&(e.status="fulfilled",e.value=a)},function(a){e.status==="pending"&&(e.status="rejected",e.reason=a)})),e.status){case"fulfilled":return e.value;case"rejected":throw e.reason}}throw e}function W(e,a,t,u,r){var s=typeof e;(s==="undefined"||s==="boolean")&&(e=null);var o=!1;if(e===null)o=!0;else switch(s){case"bigint":case"string":case"number":o=!0;break;case"object":switch(e.$$typeof){case he:case Ua:o=!0;break;case ua:return o=e._init,W(o(e._payload),a,t,u,r)}}if(o)return r=r(e),o=u===""?"."+pe(e,0):u,ea(r)?(t="",o!=null&&(t=o.replace(aa,"$&/")+"/"),W(r,a,t,"",function(n){return n})):r!=null&&(ye(r)&&(r=Ka(r,t+(r.key==null||e&&e.key===r.key?"":(""+r.key).replace(aa,"$&/")+"/")+o)),a.push(r)),1;o=0;var f=u===""?".":u+":";if(ea(e))for(var l=0;l<e.length;l++)u=e[l],s=f+pe(u,l),o+=W(u,a,t,s,r);else if(l=$a(e),typeof l=="function")for(e=l.call(e),l=0;!(u=e.next()).done;)u=u.value,s=f+pe(u,l++),o+=W(u,a,t,s,r);else if(s==="object"){if(typeof e.then=="function")return W(Ja(e),a,t,u,r);throw a=String(e),Error("Objects are not valid as a React child (found: "+(a==="[object Object]"?"object with keys {"+Object.keys(e).join(", ")+"}":a)+"). If you meant to render a collection of children, use an array instead.")}return o}function ae(e,a,t){if(e==null)return e;var u=[],r=0;return W(e,u,"","",function(s){return a.call(t,s,r++)}),u}function Qa(e){if(e._status===-1){var a=e._result;a=a(),a.then(function(t){(e._status===0||e._status===-1)&&(e._status=1,e._result=t)},function(t){(e._status===0||e._status===-1)&&(e._status=2,e._result=t)}),e._status===-1&&(e._status=0,e._result=a)}if(e._status===1)return e._result.default;throw e._result}var ta=typeof reportError=="function"?reportError:function(e){if(typeof window=="object"&&typeof window.ErrorEvent=="function"){var a=new window.ErrorEvent("error",{bubbles:!0,cancelable:!0,message:typeof e=="object"&&e!==null&&typeof e.message=="string"?String(e.message):String(e),error:e});if(!window.dispatchEvent(a))return}else if(typeof process=="object"&&typeof process.emit=="function"){process.emit("uncaughtException",e);return}console.error(e)},Ya={map:ae,forEach:function(e,a,t){ae(e,function(){a.apply(this,arguments)},t)},count:function(e){var a=0;return ae(e,function(){a++}),a},toArray:function(e){return ae(e,function(a){return a})||[]},only:function(e){if(!ye(e))throw Error("React.Children.only expected to receive a single React element child.");return e}};i.Activity=ja;i.Children=Ya;i.Component=N;i.Fragment=_a;i.Profiler=Ga;i.PureComponent=Le;i.StrictMode=Ha;i.Suspense=Na;i.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=x;i.__COMPILER_RUNTIME={__proto__:null,c:function(e){return x.H.useMemoCache(e)}};i.cache=function(e){return function(){return e.apply(null,arguments)}};i.cacheSignal=function(){return null};i.cloneElement=function(e,a,t){if(e==null)throw Error("The argument must be a React element, but you passed "+e+".");var u=sa({},e.props),r=e.key;if(a!=null)for(s in a.key!==void 0&&(r=""+a.key),a)!fa.call(a,s)||s==="key"||s==="__self"||s==="__source"||s==="ref"&&a.ref===void 0||(u[s]=a[s]);var s=arguments.length-2;if(s===1)u.children=t;else if(1<s){for(var o=Array(s),f=0;f<s;f++)o[f]=arguments[f+2];u.children=o}return xe(e.type,r,u)};i.createContext=function(e){return e={$$typeof:za,_currentValue:e,_currentValue2:e,_threadCount:0,Provider:null,Consumer:null},e.Provider=e,e.Consumer={$$typeof:Va,_context:e},e};i.createElement=function(e,a,t){var u,r={},s=null;if(a!=null)for(u in a.key!==void 0&&(s=""+a.key),a)fa.call(a,u)&&u!=="key"&&u!=="__self"&&u!=="__source"&&(r[u]=a[u]);var o=arguments.length-2;if(o===1)r.children=t;else if(1<o){for(var f=Array(o),l=0;l<o;l++)f[l]=arguments[l+2];r.children=f}if(e&&e.defaultProps)for(u in o=e.defaultProps,o)r[u]===void 0&&(r[u]=o[u]);return xe(e,s,r)};i.createRef=function(){return{current:null}};i.forwardRef=function(e){return{$$typeof:Wa,render:e}};i.isValidElement=ye;i.lazy=function(e){return{$$typeof:ua,_payload:{_status:-1,_result:e},_init:Qa}};i.memo=function(e,a){return{$$typeof:Xa,type:e,compare:a===void 0?null:a}};i.startTransition=function(e){var a=x.T,t={};x.T=t;try{var u=e(),r=x.S;r!==null&&r(t,u),typeof u=="object"&&u!==null&&typeof u.then=="function"&&u.then(me,ta)}catch(s){ta(s)}finally{a!==null&&t.types!==null&&(a.types=t.types),x.T=a}};i.unstable_useCacheRefresh=function(){return x.H.useCacheRefresh()};i.use=function(e){return x.H.use(e)};i.useActionState=function(e,a,t){return x.H.useActionState(e,a,t)};i.useCallback=function(e,a){return x.H.useCallback(e,a)};i.useContext=function(e){return x.H.useContext(e)};i.useDebugValue=function(){};i.useDeferredValue=function(e,a){return x.H.useDeferredValue(e,a)};i.useEffect=function(e,a){return x.H.useEffect(e,a)};i.useEffectEvent=function(e){return x.H.useEffectEvent(e)};i.useId=function(){return x.H.useId()};i.useImperativeHandle=function(e,a,t){return x.H.useImperativeHandle(e,a,t)};i.useInsertionEffect=function(e,a){return x.H.useInsertionEffect(e,a)};i.useLayoutEffect=function(e,a){return x.H.useLayoutEffect(e,a)};i.useMemo=function(e,a){return x.H.useMemo(e,a)};i.useOptimistic=function(e,a){return x.H.useOptimistic(e,a)};i.useReducer=function(e,a,t){return x.H.useReducer(e,a,t)};i.useRef=function(e){return x.H.useRef(e)};i.useState=function(e){return x.H.useState(e)};i.useSyncExternalStore=function(e,a,t){return x.H.useSyncExternalStore(e,a,t)};i.useTransition=function(){return x.H.useTransition()};i.version="19.2.8"});var ge=ee((uu,ia)=>{"use strict";ia.exports=na()});var La=ee(re=>{"use strict";var It=Symbol.for("react.transitional.element"),xt=Symbol.for("react.fragment");function ha(e,a,t){var u=null;if(t!==void 0&&(u=""+t),a.key!==void 0&&(u=""+a.key),"key"in a){t={};for(var r in a)r!=="key"&&(t[r]=a[r])}else t=a;return a=t.ref,{$$typeof:It,type:e,key:u,ref:a!==void 0?a:null,props:t}}re.Fragment=xt;re.jsx=ha;re.jsxs=ha});var yt=ee((fr,Ia)=>{"use strict";Ia.exports=La()});var ue=Qe(ge());var da=e=>e.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase(),et=e=>e.replace(/^([A-Z])|[\s-_]+(\w)/g,(a,t,u)=>u?u.toUpperCase():t.toLowerCase()),Ce=e=>{let a=et(e);return a.charAt(0).toUpperCase()+a.slice(1)},te=(...e)=>e.filter((a,t,u)=>!!a&&a.trim()!==""&&u.indexOf(a)===t).join(" ").trim(),ca=e=>{for(let a in e)if(a.startsWith("aria-")||a==="role"||a==="title")return!0};var j=Qe(ge());var pa={xmlns:"http://www.w3.org/2000/svg",width:24,height:24,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"};var ma=(0,j.forwardRef)(({color:e="currentColor",size:a=24,strokeWidth:t=2,absoluteStrokeWidth:u,className:r="",children:s,iconNode:o,...f},l)=>(0,j.createElement)("svg",{ref:l,...pa,width:a,height:a,stroke:e,strokeWidth:u?Number(t)*24/Number(a):t,className:te("lucide",r),...!s&&!ca(f)&&{"aria-hidden":"true"},...f},[...o.map(([n,d])=>(0,j.createElement)(n,d)),...Array.isArray(s)?s:[s]]));var m=(e,a)=>{let t=(0,ue.forwardRef)(({className:u,...r},s)=>(0,ue.createElement)(ma,{ref:s,iconNode:a,className:te(`lucide-${da(Ce(e))}`,`lucide-${e}`,u),...r}));return t.displayName=Ce(e),t};var at=[["path",{d:"M5 12h14",key:"1ays0h"}],["path",{d:"m12 5 7 7-7 7",key:"xquz4c"}]],Se=m("arrow-right",at);var tt=[["path",{d:"m15 18-6-6 6-6",key:"1wnfg3"}]],ve=m("chevron-left",tt);var ut=[["path",{d:"M3.85 8.62a4 4 0 0 1 4.78-4.77 4 4 0 0 1 6.74 0 4 4 0 0 1 4.78 4.78 4 4 0 0 1 0 6.74 4 4 0 0 1-4.77 4.78 4 4 0 0 1-6.75 0 4 4 0 0 1-4.78-4.77 4 4 0 0 1 0-6.76Z",key:"3c2336"}],["path",{d:"m9 12 2 2 4-4",key:"dzmm74"}]],X=m("badge-check",ut);var rt=[["path",{d:"m6 9 6 6 6-6",key:"qrunsl"}]],ke=m("chevron-down",rt);var st=[["path",{d:"m9 18 6-6-6-6",key:"mthhwq"}]],we=m("chevron-right",st);var ot=[["path",{d:"M12 6v6h4",key:"135r8i"}],["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}]],Ae=m("clock-3",ot);var lt=[["path",{d:"M15 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V7Z",key:"1rqfz7"}],["path",{d:"M14 2v4a2 2 0 0 0 2 2h4",key:"tnqrlb"}],["path",{d:"M10 9H8",key:"b1mrlr"}],["path",{d:"M16 13H8",key:"t4e002"}],["path",{d:"M16 17H8",key:"z1uh3a"}]],Pe=m("file-text",lt);var ft=[["path",{d:"m14 13-8.381 8.38a1 1 0 0 1-3.001-3l8.384-8.381",key:"pgg06f"}],["path",{d:"m16 16 6-6",key:"vzrcl6"}],["path",{d:"m21.5 10.5-8-8",key:"a17d9x"}],["path",{d:"m8 8 6-6",key:"18bi4p"}],["path",{d:"m8.5 7.5 8 8",key:"1oyaui"}]],be=m("gavel",ft);var nt=[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M12 16v-4",key:"1dtifu"}],["path",{d:"M12 8h.01",key:"e9boi3"}]],De=m("info",nt);var it=[["path",{d:"m3 17 2 2 4-4",key:"1jhpwq"}],["path",{d:"m3 7 2 2 4-4",key:"1obspn"}],["path",{d:"M13 6h8",key:"15sg57"}],["path",{d:"M13 12h8",key:"h98zly"}],["path",{d:"M13 18h8",key:"oe0vm4"}]],Me=m("list-checks",it);var dt=[["rect",{x:"14",y:"3",width:"5",height:"18",rx:"1",key:"kaeet6"}],["rect",{x:"5",y:"3",width:"5",height:"18",rx:"1",key:"1wsw3u"}]],Be=m("pause",dt);var ct=[["path",{d:"M5 5a2 2 0 0 1 3.008-1.728l11.997 6.998a2 2 0 0 1 .003 3.458l-12 7A2 2 0 0 1 5 19z",key:"10ikf1"}]],Fe=m("play",ct);var pt=[["path",{d:"M20 13c0 5-3.5 7.5-7.66 8.95a1 1 0 0 1-.67-.01C7.5 20.5 4 18 4 13V6a1 1 0 0 1 1-1c2 0 4.5-1.2 6.24-2.72a1.17 1.17 0 0 1 1.52 0C14.51 3.81 17 5 19 5a1 1 0 0 1 1 1z",key:"oel41y"}],["path",{d:"m9 12 2 2 4-4",key:"dzmm74"}]],Re=m("shield-check",pt);var mt=[["path",{d:"M16 10a4 4 0 0 1-8 0",key:"1ltviw"}],["path",{d:"M3.103 6.034h17.794",key:"awc11p"}],["path",{d:"M3.4 5.467a2 2 0 0 0-.4 1.2V20a2 2 0 0 0 2 2h14a2 2 0 0 0 2-2V6.667a2 2 0 0 0-.4-1.2l-2-2.667A2 2 0 0 0 17 2H7a2 2 0 0 0-1.6.8z",key:"o988cm"}]],Te=m("shopping-bag",mt);var ht=[["path",{d:"M10 2h4",key:"n1abiw"}],["path",{d:"M12 14v-4",key:"1evpnu"}],["path",{d:"M4 13a8 8 0 0 1 8-7 8 8 0 1 1-5.3 14L4 17.6",key:"1ts96g"}],["path",{d:"M9 17H4v5",key:"8t5av"}]],qe=m("timer-reset",ht);var Lt=[["path",{d:"M18 6 6 18",key:"1bl5f8"}],["path",{d:"m6 6 12 12",key:"d8bk6v"}]],Ee=m("x",Lt);var xa=new Map;function ya(e,a=2){let t=xa.get(a);return t||(t=new Intl.NumberFormat("en-US",{currency:"USD",maximumFractionDigits:2,minimumFractionDigits:a,style:"currency"}),xa.set(a,t)),t.format(e/100)}function dr(e,a=e.status,t){let u=a==="draft",r=t??Ct(e),s=u?r?.startAt??e.startAt:(a==="finished"?t?.finishedAt:void 0)??t?.endAt??e.endAt,o=new Date(s);if(!Number.isFinite(o.getTime()))return"";let l=(u?r?.startAt:t?.endAt)?!0:(u?e.configuration.startTimeEnabled:e.configuration.endTimeEnabled)??!0,n=new Intl.DateTimeFormat("en-US",{day:"numeric",month:"short",timeZone:"America/New_York",year:"numeric"}).format(o);if(!l)return n;let d=new Intl.DateTimeFormat("en-US",{hour:"numeric",minute:"2-digit",timeZone:"America/New_York",timeZoneName:"short"}).format(o);return`${n} at ${d}`}function cr(e){return ya(e,0)}function gt(e,a){if(e.status==="finished"||a?.status==="finished")return"finished";if(a&&!(a.startAt&&a.endAt)&&(a.status==="draft"||e.status==="draft"))return"draft";let t=Date.now();if(Date.parse(a?.endAt??e.endAt)<=t)return"finished";if(Date.parse(a?.startAt??e.startAt)>t)return"draft";if(a)return"active";if(e.items.length){let u=e.items.map(r=>gt(e,r));return u.includes("active")?"active":u.includes("draft")?"draft":"finished"}return e.status}function Ct(e){let a=Date.now();return e.items.filter(t=>t.status!=="finished"&&Date.parse(t.startAt??e.startAt)>a).sort((t,u)=>Date.parse(t.startAt??e.startAt)-Date.parse(u.startAt??e.startAt))[0]}function pr(e){return e.isSoldOut||e.saleMode==="buy_now"&&e.availableQuantity===0}var se,St={lang:void 0,message:void 0,abortEarly:void 0,abortPipeEarly:void 0};function Oe(e){return!e&&!se?St:{lang:e?.lang??se?.lang,message:e?.message,abortEarly:e?.abortEarly??se?.abortEarly,abortPipeEarly:e?.abortPipeEarly??se?.abortPipeEarly}}var vt;function kt(e){return vt?.get(e)}var wt;function At(e){return wt?.get(e)}var Pt;function bt(e,a){return Pt?.get(e)?.get(a)}function G(e){let a=typeof e;return a==="string"?`"${e}"`:a==="number"||a==="bigint"||a==="boolean"?`${e}`:a==="object"||a==="function"?(e&&Object.getPrototypeOf(e)?.constructor?.name)??"null":a}function L(e,a,t,u,r){let s=r&&"input"in r?r.input:t.value,o=r?.expected??e.expects??null,f=r?.received??G(s),l={kind:e.kind,type:e.type,input:s,expected:o,received:f,message:`Invalid ${a}: ${o?`Expected ${o} but r`:"R"}eceived ${f}`,requirement:e.requirement,path:r?.path,issues:r?.issues,lang:u.lang,abortEarly:u.abortEarly,abortPipeEarly:u.abortPipeEarly},n=e.kind==="schema",d=r?.message??e.message??bt(e.reference,l.lang)??(n?At(l.lang):null)??u.message??kt(l.lang);d!==void 0&&(l.message=typeof d=="function"?d(l):d),n&&(t.typed=!1),t.issues?t.issues.push(l):t.issues=[l]}var ga=new WeakMap;function P(e){let a=ga.get(e);return a||(a={version:1,vendor:"valibot",validate(t){return e["~run"]({value:t},Oe())}},ga.set(e,a)),a}function Dt(e,a){return Object.prototype.hasOwnProperty.call(e,a)&&a!=="__proto__"&&a!=="prototype"&&a!=="constructor"}function Ue(e,a){let t=[...new Set(e)];return t.length>1?`(${t.join(` ${a} `)})`:t[0]??"never"}var _e=class extends Error{constructor(e){super(e[0].message),this.name="ValiError",this.issues=e}};var Mt=/^[\w+-]+(?:\.[\w+-]+)*@[\da-z]+(?:[.-][\da-z]+)*\.[a-z]{2,}$/iu;var Bt=/^\d{4}-(?:0[1-9]|1[0-2])-(?:[12]\d|0[1-9]|3[01])[T ](?:0\d|1\d|2[0-3])(?::[0-5]\d){2}(?:\.\d{1,9})?(?:Z| ?[+-](?:0\d|1\d|2[0-3])(?::?[0-5]\d)?)$/u;function b(e,a){return{kind:"validation",type:"check",reference:b,async:!1,expects:null,requirement:e,message:a,"~run"(t,u){return t.typed&&!this.requirement(t.value)&&L(this,"input",t,u),t}}}function He(e){return{kind:"validation",type:"email",reference:He,expects:null,async:!1,requirement:Mt,message:e,"~run"(a,t){return a.typed&&!this.requirement.test(a.value)&&L(this,"email",a,t),a}}}function Ge(e){return{kind:"validation",type:"iso_timestamp",reference:Ge,async:!1,expects:null,requirement:Bt,message:e,"~run"(a,t){return a.typed&&!this.requirement.test(a.value)&&L(this,"timestamp",a,t),a}}}function Ve(e,a){return{kind:"validation",type:"max_value",reference:Ve,async:!1,expects:`<=${e instanceof Date?e.toJSON():G(e)}`,requirement:e,message:a,"~run"(t,u){return t.typed&&!(t.value<=this.requirement)&&L(this,"value",t,u,{received:t.value instanceof Date?t.value.toJSON():G(t.value)}),t}}}function $(e,a){return{kind:"validation",type:"min_length",reference:$,async:!1,expects:`>=${e}`,requirement:e,message:a,"~run"(t,u){return t.typed&&t.value.length<this.requirement&&L(this,"length",t,u,{received:`${t.value.length}`}),t}}}function R(e,a){return{kind:"validation",type:"min_value",reference:R,async:!1,expects:`>=${e instanceof Date?e.toJSON():G(e)}`,requirement:e,message:a,"~run"(t,u){return t.typed&&!(t.value>=this.requirement)&&L(this,"value",t,u,{received:t.value instanceof Date?t.value.toJSON():G(t.value)}),t}}}function ze(e){return{kind:"validation",type:"non_empty",reference:ze,async:!1,expects:"!0",message:e,"~run"(a,t){return a.typed&&a.value.length===0&&L(this,"length",a,t,{received:"0"}),a}}}function We(e,a){return{kind:"validation",type:"regex",reference:We,async:!1,expects:`${e}`,requirement:e,message:a,"~run"(t,u){return t.typed&&!this.requirement.test(t.value)&&L(this,"format",t,u),t}}}function K(e){return{kind:"validation",type:"safe_integer",reference:K,async:!1,expects:null,requirement:Number.isSafeInteger,message:e,"~run"(a,t){return a.typed&&!this.requirement(a.value)&&L(this,"safe integer",a,t),a}}}function Ne(e){return{kind:"transformation",type:"transform",reference:Ne,async:!1,operation:e,"~run"(a){return a.value=this.operation(a.value),a}}}function Ft(){return{kind:"transformation",type:"trim",reference:Ft,async:!1,"~run"(e){return e.value=e.value.trim(),e}}}var Sa={abortEarly:!0};function va(e,a,t){return typeof e.fallback=="function"?e.fallback(a,t):e.fallback}function oe(e,a,t){return typeof e.default=="function"?e.default(a,t):e.default}function le(e,a){return!e["~run"]({value:a},Sa).issues}function q(e,a){return{kind:"schema",type:"array",reference:q,expects:"Array",async:!1,item:e,message:a,get"~standard"(){return P(this)},"~run"(t,u){let r=t.value;if(Array.isArray(r)){t.typed=!0,t.value=[];for(let s=0;s<r.length;s++){let o=r[s],f=this.item["~run"]({value:o},u);if(f.issues){let l={type:"array",origin:"value",input:r,key:s,value:o};for(let n of f.issues)n.path?n.path.unshift(l):n.path=[l],t.issues?.push(n);if(t.issues||(t.issues=f.issues),u.abortEarly){t.typed=!1;break}}f.typed||(t.typed=!1),t.value.push(f.value)}}else L(this,"type",t,u);return t}}}function S(e){return{kind:"schema",type:"boolean",reference:S,expects:"boolean",async:!1,message:e,get"~standard"(){return P(this)},"~run"(a,t){return typeof a.value=="boolean"?a.typed=!0:L(this,"type",a,t),a}}}function fe(e,a){return{kind:"schema",type:"custom",reference:fe,expects:"unknown",async:!1,check:e,message:a,get"~standard"(){return P(this)},"~run"(t,u){return this.check(t.value)?t.typed=!0:L(this,"type",t,u),t}}}function ne(e){return{kind:"schema",type:"function",reference:ne,expects:"Function",async:!1,message:e,get"~standard"(){return P(this)},"~run"(a,t){return typeof a.value=="function"?a.typed=!0:L(this,"type",a,t),a}}}function Z(e,a){return{kind:"schema",type:"literal",reference:Z,expects:G(e),async:!1,literal:e,message:a,get"~standard"(){return P(this)},"~run"(t,u){return t.value===this.literal?t.typed=!0:L(this,"type",t,u),t}}}function J(e,a){return{kind:"schema",type:"loose_object",reference:J,expects:"Object",async:!1,entries:e,message:a,get"~standard"(){return P(this)},"~run"(t,u){let r=t.value;if(r&&typeof r=="object"){t.typed=!0,t.value={};for(let s in this.entries){let o=this.entries[s];if(s in r||(o.type==="exact_optional"||o.type==="optional"||o.type==="nullish")&&o.default!==void 0){let f=s in r?r[s]:oe(o),l=o["~run"]({value:f},u);if(l.issues){let n={type:"object",origin:"value",input:r,key:s,value:f};for(let d of l.issues)d.path?d.path.unshift(n):d.path=[n],t.issues?.push(d);if(t.issues||(t.issues=l.issues),u.abortEarly){t.typed=!1;break}}l.typed||(t.typed=!1),t.value[s]=l.value}else if(o.fallback!==void 0)t.value[s]=va(o);else if(o.type!=="exact_optional"&&o.type!=="optional"&&o.type!=="nullish"&&(L(this,"key",t,u,{input:void 0,expected:`"${s}"`,path:[{type:"object",origin:"key",input:r,key:s,value:r[s]}]}),u.abortEarly))break}if(!t.issues||!u.abortEarly)for(let s in r)Dt(r,s)&&!(s in this.entries)&&(t.value[s]=r[s])}else L(this,"type",t,u);return t}}}function h(e,a){return{kind:"schema",type:"nullable",reference:h,expects:`(${e.expects} | null)`,async:!1,wrapped:e,default:a,get"~standard"(){return P(this)},"~run"(t,u){return t.value===null&&(this.default!==void 0&&(t.value=oe(this,t,u)),t.value===null)?(t.typed=!0,t):this.wrapped["~run"](t,u)}}}function Q(e){return{kind:"schema",type:"number",reference:Q,expects:"number",async:!1,message:e,get"~standard"(){return P(this)},"~run"(a,t){return typeof a.value=="number"&&!isNaN(a.value)?a.typed=!0:L(this,"type",a,t),a}}}function g(e,a){return{kind:"schema",type:"object",reference:g,expects:"Object",async:!1,entries:e,message:a,get"~standard"(){return P(this)},"~run"(t,u){let r=t.value;if(r&&typeof r=="object"){t.typed=!0,t.value={};for(let s in this.entries){let o=this.entries[s];if(s in r||(o.type==="exact_optional"||o.type==="optional"||o.type==="nullish")&&o.default!==void 0){let f=s in r?r[s]:oe(o),l=o["~run"]({value:f},u);if(l.issues){let n={type:"object",origin:"value",input:r,key:s,value:f};for(let d of l.issues)d.path?d.path.unshift(n):d.path=[n],t.issues?.push(d);if(t.issues||(t.issues=l.issues),u.abortEarly){t.typed=!1;break}}l.typed||(t.typed=!1),t.value[s]=l.value}else if(o.fallback!==void 0)t.value[s]=va(o);else if(o.type!=="exact_optional"&&o.type!=="optional"&&o.type!=="nullish"&&(L(this,"key",t,u,{input:void 0,expected:`"${s}"`,path:[{type:"object",origin:"key",input:r,key:s,value:r[s]}]}),u.abortEarly))break}}else L(this,"type",t,u);return t}}}function c(e,a){return{kind:"schema",type:"optional",reference:c,expects:`(${e.expects} | undefined)`,async:!1,wrapped:e,default:a,get"~standard"(){return P(this)},"~run"(t,u){return t.value===void 0&&(this.default!==void 0&&(t.value=oe(this,t,u)),t.value===void 0)?(t.typed=!0,t):this.wrapped["~run"](t,u)}}}function D(e,a){return{kind:"schema",type:"picklist",reference:D,expects:Ue(e.map(G),"|"),async:!1,options:e,message:a,get"~standard"(){return P(this)},"~run"(t,u){return this.options.includes(t.value)?t.typed=!0:L(this,"type",t,u),t}}}function Xe(e,a){return{kind:"schema",type:"strict_tuple",reference:Xe,expects:"Array",async:!1,items:e,message:a,get"~standard"(){return P(this)},"~run"(t,u){let r=t.value;if(Array.isArray(r)){t.typed=!0,t.value=[];for(let s=0;s<this.items.length;s++){let o=r[s],f=this.items[s]["~run"]({value:o},u);if(f.issues){let l={type:"array",origin:"value",input:r,key:s,value:o};for(let n of f.issues)n.path?n.path.unshift(l):n.path=[l],t.issues?.push(n);if(t.issues||(t.issues=f.issues),u.abortEarly){t.typed=!1;break}}f.typed||(t.typed=!1),t.value.push(f.value)}!(t.issues&&u.abortEarly)&&this.items.length<r.length&&L(this,"type",t,u,{input:r[this.items.length],expected:"never",path:[{type:"array",origin:"value",input:r,key:this.items.length,value:r[this.items.length]}]})}else L(this,"type",t,u);return t}}}function I(e){return{kind:"schema",type:"string",reference:I,expects:"string",async:!1,message:e,get"~standard"(){return P(this)},"~run"(a,t){return typeof a.value=="string"?a.typed=!0:L(this,"type",a,t),a}}}function Ca(e){let a;if(e)for(let t of e)if(a)for(let u of t.issues)a.push(u);else a=t.issues;return a}function je(e,a){return{kind:"schema",type:"union",reference:je,expects:Ue(e.map(t=>t.expects),"|"),async:!1,options:e,message:a,get"~standard"(){return P(this)},"~run"(t,u){let r,s,o;for(let f of this.options){let l=f["~run"]({value:t.value},u);if(l.typed)if(l.issues)s?s.push(l):s=[l];else{r=l;break}else o?o.push(l):o=[l]}if(r)return r;if(s){if(s.length===1)return s[0];L(this,"type",t,u,{issues:Ca(s)}),t.typed=!0}else{if(o?.length===1)return o[0];L(this,"type",t,u,{issues:Ca(o)})}return t}}}function $e(){return{kind:"schema",type:"unknown",reference:$e,expects:"unknown",async:!1,get"~standard"(){return P(this)},"~run"(e){return e.typed=!0,e}}}function Ke(e,a,t){return{kind:"schema",type:"variant",reference:Ke,expects:"Object",async:!1,key:e,options:a,message:t,get"~standard"(){return P(this)},"~run"(u,r){let s=u.value;if(s&&typeof s=="object"){let o,f=0,l=this.key,n=[],d=(C,M)=>{for(let B of C.options){if(B.type==="variant")d(B,new Set(M).add(B.key));else{let F=!0,T=0;for(let A of M){let k=B.entries[A];if(A in s?k["~run"]({typed:!1,value:s[A]},Sa).issues:k.type!=="exact_optional"&&k.type!=="optional"&&k.type!=="nullish"){F=!1,l!==A&&(f<T||f===T&&A in s&&!(l in s))&&(f=T,l=A,n=[]),l===A&&n.push(B.entries[A].expects);break}T++}if(F){let A=B["~run"]({value:s},r);(!o||!o.typed&&A.typed)&&(o=A)}}if(o&&!o.issues)break}};if(d(this,new Set([this.key])),o)return o;L(this,"type",u,r,{input:s[l],expected:Ue(n,"|"),path:[{type:"object",origin:"value",input:s,key:l,value:s[l]}]})}else L(this,"type",u,r);return u}}}function w(e,a,t){let u=e["~run"]({value:a},Oe(t));if(u.issues)throw new _e(u.issues);return u.value}function y(...e){return{...e[0],pipe:e,get"~standard"(){return P(this)},"~run"(a,t){for(let u of e)if(u.kind!=="metadata"){if(a.issues&&(u.kind==="schema"||u.kind==="transformation")){a.typed=!1;break}(!a.issues||!t.abortEarly&&!t.abortPipeEarly)&&(a=u["~run"](a,t))}return a}}}function hr(e,a,t){let u=e["~run"]({value:a},Oe(t));return{typed:u.typed,success:!u.issues,output:u.value,issues:u.issues}}var Rt="0.2.255",_=class extends Error{failureKind;code;operation;reportable;recoveryRecommended;sdkVersion;serverCode;status;constructor({failureKind:e,code:a,message:t,operation:u,reportable:r,recoveryRecommended:s=!1,serverCode:o,status:f}){super(t),this.name="LockerverseSdkError",this.failureKind=e,this.code=a,this.operation=u,this.reportable=r,this.recoveryRecommended=s,this.sdkVersion=Rt,this.serverCode=o,this.status=f}};var V=y(I(),ze(),b(e=>e.trim().length>0)),Cr=c(h(I()),null);function wa(e){return y(Q(),K(),R(e))}var Aa=y(q($e()),Ne(e=>e.filter(a=>{let{archivedAt:t}=w(J({archivedAt:c(h(V))}),a);return!t}))),Tt=g({id:V,label:V}),ka=y(Aa,q(Tt),$(2),b(e=>new Set(e.map(({id:a})=>a)).size===e.length,"Expected unique custom field option IDs.")),ie={id:V,label:V,paymentOptionIds:c(q(V)),required:S()},qt=Ke("type",[g({...ie,type:D(["text","textarea"])}),g({...ie,type:D(["checkbox"])}),g({...ie,options:ka,type:D(["radio","select"])}),g({...ie,options:ka,type:D(["checkboxes","multi_select"])})]),Sr=y(c(Aa,[]),q(qt),b(e=>new Set(e.map(({id:a})=>a)).size===e.length,"Expected unique custom field IDs.")),vr=g({fieldId:V,value:je([S(),I(),q(I())])});function de(e){let a=new Object(e);if(a!==e||Object.isFrozen(a))return e;for(let t of Object.values(a))de(t);return Object.freeze(e)}var Pa=/\/+$/,Et=new Set(["localhost","127.0.0.1","[::1]"]),Ot={development:{sentryDsn:"https://1977371f7bc44480935a7bc9726ca296@o1338376.ingest.sentry.io/6631829"},production:{sentryDsn:"https://43d2d853c129415cf77531c914511174@o1338376.ingest.us.sentry.io/4511911476133888"}};function Ze(e,a,t="apiBaseUrl"){if(!le(I(),e))throw TypeError(`${t} must be a valid HTTP or HTTPS URL.`);let u;try{u=new URL(e)}catch{throw TypeError(`${t} must be a valid HTTP or HTTPS URL.`)}if(u.protocol!=="http:"&&u.protocol!=="https:")throw TypeError(`${t} must be a valid HTTP or HTTPS URL.`);if(u.username||u.password)throw TypeError(`${t} must not include credentials.`);if(u.search||u.hash)throw TypeError(`${t} must not include a query or fragment.`);if(u.protocol!=="https:"&&!(a==="development"&&(Et.has(u.hostname)||u.hostname.endsWith(".localhost"))))throw TypeError(`${t} must use HTTPS except for development loopback endpoints.`);return u.pathname=u.pathname.replace(Pa,""),u.toString().replace(Pa,"")}function Ut(e,a){let t="requestTimeoutMs must be a positive integer no greater than 2147483647.",u=r=>y(I(`${r} must be a non-empty string.`),b(s=>s.trim().length>0,`${r} must be a non-empty string.`));try{let r=w(J({apiBaseUrl:c(I("apiBaseUrl must be a valid HTTP or HTTPS URL.")),communitySlug:u("communitySlug"),environment:c(D(["development","production"],"environment must be either development or production.")),fetch:c(fe(s=>le(ne(),s),"fetch must be a function when provided.")),onError:c(fe(s=>le(ne(),s),"onError must be a function when provided.")),requestTimeoutMs:c(y(Q(t),K(t),R(1,t),Ve(2147483647,t))),sentryDsn:c(h(I("sentryDsn must be a string or null when provided.")))},"Expected an object."),e);return{apiBaseUrl:r.apiBaseUrl,communitySlug:r.communitySlug,environment:r.environment,fetch:r.fetch,onError:r.onError,requestTimeoutMs:r.requestTimeoutMs,resourceSlugValue:w(u(a),r[a]),sentryDsn:r.sentryDsn}}catch(r){let s=r instanceof _e?r.issues[0]?.message??"Invalid SDK options.":"Invalid SDK options.";throw TypeError(s)}}function ba(e,a){let t=Ut(e,a),u=t.environment;if(t.apiBaseUrl!==void 0&&u===void 0)throw TypeError("environment is required when apiBaseUrl is provided.");if(t.apiBaseUrl===void 0&&u==="development")throw TypeError("apiBaseUrl is required when environment is development.");let r=u===void 0?"production":u,{communitySlug:s,resourceSlugValue:o}=t,f=t.fetch??globalThis.fetch,l=t.apiBaseUrl===void 0?"https://portal.lockerverse.com/api":Ze(t.apiBaseUrl,r),n=Ot[r],d=t.sentryDsn,C=d===null?null:d??n.sentryDsn;return{apiBaseUrl:l,communitySlug:encodeURIComponent(s),communitySlugValue:s,environment:r,fetchImplementation:f,onError:t.onError,requestTimeoutMs:t.requestTimeoutMs??2e4,resourceSlug:encodeURIComponent(o),resourceSlugValue:o,sentryDsn:C}}function _t(){return globalThis.window}function Da({communitySlug:e,environment:a,getContext:t,onError:u,resourceContextName:r,sentryDsn:s}){let o=null;return function(f){try{Promise.resolve(u?.(f)).catch(()=>{})}catch{}let l=_t();if(f.reportable&&s&&l!==void 0){let n=o??import("./telemetry-6KTBIZ2M.js");o=n;let d={communitySlug:e,...t()},C=f.status===void 0?d:{...d,status:f.status};n.then(({captureSdkError:M})=>M({context:C,contextName:r,dsn:s,environment:a,error:f})).catch(()=>{o===n&&(o=null)})}return f}}function Ma(e,a,t){function u(s,o){let f=new _({code:s.code,failureKind:o,message:s.message,operation:s.operation,reportable:!0});return s.report===!1?f:a(f)}async function r(s,o,f,l,n,d){let C=new AbortController,M=o?.signal??void 0,B=()=>C.abort(M?.reason);M?.aborted?B():M?.addEventListener("abort",B,{once:!0});let F,T=new Promise((E,H)=>{F=()=>H(C.signal.reason??new DOMException("The request was aborted.","AbortError")),C.signal.aborted?F():C.signal.addEventListener("abort",F,{once:!0})}),A=!1;function k(E,H){return M?.aborted?"aborted":A?"timeout":C.signal.aborted||H instanceof Error&&H.name==="AbortError"?"aborted":E}let z=setTimeout(()=>{A=!0,C.abort(new DOMException("The request timed out.","TimeoutError"))},t);try{let E;try{E=await Promise.race([e(s,{...o,signal:C.signal}),T])}catch(Y){throw u(l,k("network",Y))}if(!E.ok)try{return{errorValue:d?await Promise.race([d(E),T]):void 0,ok:!1,response:E}}catch{throw u(l,"invalid_response")}let H;try{H=await Promise.race([E.json(),T])}catch(Y){throw u(n,k(Y instanceof TypeError?"network":"invalid_response",Y))}try{return{ok:!0,response:E,value:f(H)}}catch{throw u(n,"invalid_response")}}finally{clearTimeout(z),M?.removeEventListener("abort",B),F&&C.signal.removeEventListener("abort",F)}}return{requestJson:r}}function Ba(e,a){if(a===void 0)return e;e.mediaBaseUrl=a;let t=u=>u?.startsWith("https://media.lockerverse.com/")?`${a}/${u.slice(30)}`:u;e.configuration.image=t(e.configuration.image),e.community&&(e.community.banner=t(e.community.banner),e.community.thumbnail=t(e.community.thumbnail));for(let u of e.items)u.image=t(u.image),u.images=u.images.map(t);return e}var v=y(I(),$(1)),p=wa(0),O=y(I(),Ge()),Fa=D(["draft","active","finished"]),Ra=g({additionalUnitAmountCents:p,category:D(["shipping","handling","other"]),firstUnitAmountCents:p,name:v}),Ht=g({additionalCharge:c(h(Ra)),auctionId:v,availableQuantity:h(p),bidCount:p,bidIncrementAmount:h(p),buyNowPriceAmount:h(p),collectShippingAddress:S(),communityId:v,createdAt:O,description:h(I()),endAt:c(h(O)),finalizedBidCount:p,finishedAt:c(h(O)),id:v,image:h(I()),images:q(I()),inventoryQuantity:h(p),isSoldOut:S(),maxBidAmount:h(p),maxQuantityPerOrder:c(h(y(p,R(1)))),minBidAmount:h(p),name:I(),paidQuantity:p,path:v,position:p,reservedQuantity:p,saleMode:D(["auction","buy_now","hybrid"]),slug:v,startAt:c(h(O)),status:Fa,supportsMaximumBids:c(S()),updatedAt:O}),Ta=g({collectShippingAddress:S(),community:c(g({banner:c(h(I())),color:c(h(I())),name:c(I()),thumbnail:c(h(I()))})),communityId:v,configuration:g({collectShippingAddress:S(),endTimeEnabled:c(h(S())),image:h(I()),serviceFeeDefaultChecked:S(),serviceFeeEnabled:S(),startTimeEnabled:c(h(S()))}),createdAt:O,description:h(I()),endAt:O,id:v,items:q(Ht),name:I(),path:v,payment:c(g({connectedAccountId:h(v),currency:Z("usd"),publishableKey:v})),position:p,pricingPolicy:g({currency:Z("usd"),serviceFeeRateBasisPoints:p}),serviceFeeDefaultChecked:S(),serviceFeeEnabled:S(),slug:v,startAt:O,status:Fa,updatedAt:O}),Je={additionalCharge:c(h(Ra)),additionalChargeCents:c(p,0),serviceFeeCents:p,serviceFeeRateBasisPoints:p,subtotalCents:p,totalCents:p},ce=e=>e.totalCents===e.subtotalCents+e.serviceFeeCents+(e.additionalChargeCents??0),qa={...Je,clientSecret:h(v),requiresAction:S()},Gt=y(g(qa),b(e=>ce(e)),b(e=>!e.requiresAction||e.clientSecret!==null)),Ea=y(g({...qa,id:v,purchaseId:v,quantity:y(p,R(1)),status:D(["pending_payment","paid","payment_failed","expired","canceled","refunded"]),totalAmount:p}),b(e=>ce(e)),b(e=>e.id===e.purchaseId&&(!e.requiresAction||e.clientSecret!==null))),Vt=y(g({...Je,quantity:y(p,R(1)),totalAmount:p,unitAmount:p}),b(e=>ce(e))),Oa={confirmationToken:v,email:y(I(),He()),expectedAdditionalChargeCents:c(p),expectedServiceFeeCents:c(p),expectedSubtotalCents:c(p),expectedTotalCents:c(p),includeServiceFee:c(S()),phone:y(I(),We(/^\+[1-9]\d{1,14}$/))},zt=g({...Oa,amount:y(p,R(100)),bidType:c(D(["fixed","maximum"]))}),Wt=g({...Oa,clientRequestId:v,paymentMethodTypes:c(Xe([Z("card")])),quantity:y(p,R(1))}),Nt=e=>w(Ta,e),Xt=e=>w(q(Ta),e),jt=e=>w(Gt,e),$t=e=>w(Ea,e),Kt=e=>w(Vt,e),Zt=e=>w(zt,e),Jt=e=>w(Wt,e),Qt=e=>w(h(Ea),e),Yt=e=>w(y(g(Je),b(a=>ce(a))),e),eu=e=>w(g({includeServiceFee:c(S()),quantity:y(p,R(1))}),e);function au(e,a,t){let u=e+a.map(r=>`/${encodeURIComponent(w(v,r))}`).join("");return t===void 0?u:`${u}?${new URLSearchParams({previewItem:w(v,t)})}`}function Fr(e){let a=ba(e,"communitySlug"),t=e.mediaBaseUrl===void 0?void 0:Ze(e.mediaBaseUrl,a.environment,"mediaBaseUrl"),u=l=>Ba(Nt(l),t),r=Da({communitySlug:a.communitySlugValue,environment:a.environment,getContext:()=>({}),onError:a.onError,resourceContextName:"lockerverse_auction",sentryDsn:a.sentryDsn}),{requestJson:s}=Ma(a.fetchImplementation,r,a.requestTimeoutMs),o=`${a.apiBaseUrl}/auctions/communities/slug/${a.communitySlug}`;async function f(l,n,d,C,M,B=!1){let F=!!C&&!B,T,A;try{T=au(o,n,M),C&&(A={body:JSON.stringify(C.parse(C.value)),headers:{"content-type":"application/json"},method:"POST"})}catch{throw r(new _({...l,message:"Lockerverse auction input is invalid.",reportable:!1}))}try{let k=await s(T,A,d,{...l,report:!1},{...l,report:!1});if(!k.ok){let{status:z}=k.response;throw new _({...l,recoveryRecommended:F&&(z>=500||z===408),reportable:z>=500,status:z})}return de(k.value)}catch(k){throw k instanceof _?r(new _({...l,recoveryRecommended:k.recoveryRecommended||F&&k.status===void 0,reportable:k.reportable,...k.status===void 0?void 0:{status:k.status}})):r(new _({...l,recoveryRecommended:F,reportable:!0}))}}return{createBid:(l,n,d)=>f({code:"auction_bid_failed",message:"Unable to submit Lockerverse auction bid.",operation:"create_auction_bid"},["path",l,"items",n,"bids"],jt,{parse:Zt,value:d}),createPurchase:(l,n,d)=>f({code:"auction_purchase_failed",message:"Unable to submit Lockerverse auction purchase.",operation:"create_auction_purchase"},["path",l,"items",n,"purchases"],$t,{parse:Jt,value:d}),getPurchaseQuote:(l,n,d)=>f({code:"auction_load_failed",message:"Unable to load Lockerverse auction purchase quote.",operation:"load_auction"},["path",l,"items",n,"purchase-quote"],Yt,{parse:eu,value:d},void 0,!0),getPurchaseReceipt:(l,n,d)=>f({code:"auction_receipt_failed",message:"Unable to load Lockerverse auction purchase receipt.",operation:"get_auction_purchase_receipt"},["path",l,"items",n,"purchases",d],Kt),getPurchaseStatus:(l,n,d)=>f({code:"auction_purchase_status_failed",message:"Unable to load Lockerverse auction purchase status.",operation:"get_auction_purchase_status"},["path",l,"items",n,"purchase-status",d],Qt),list:()=>f({code:"auction_load_failed",message:"Unable to load Lockerverse auctions.",operation:"list_auctions"},[],l=>Xt(l).map(n=>Ba(n,t))),load:(l,n)=>f({code:"auction_load_failed",message:"Unable to load Lockerverse auction.",operation:"load_auction"},["path",l],u,void 0,n?.previewItemSlug)}}function U(e){if(!Number.isSafeInteger(e)||e<0)throw TypeError("Auction amounts must be non-negative safe integers.")}function Rr(e,a,t=!1,u=0){if(U(a),U(u),t&&!e.serviceFeeEnabled)throw TypeError("The service fee is not available for this auction.");let r=t?e.pricingPolicy.serviceFeeRateBasisPoints:0;U(r);let s=Math.round(a*r/1e4),o=a+s+u;U(s),U(o);let f={serviceFeeCents:s,serviceFeeRateBasisPoints:r,subtotalCents:a,totalCents:o};return u>0&&(f.additionalChargeCents=u),de(f)}function Tr(e){let a=e.minBidAmount??100,t=e.bidIncrementAmount??100;if(U(a),U(t),e.maxBidAmount===null)return a;U(e.maxBidAmount);let u=Math.max(a,e.maxBidAmount+t);return U(u),u}export{ge as a,Se as b,X as c,ke as d,ve as e,we as f,Ae as g,Pe as h,be as i,De as j,Me as k,Be as l,Fe as m,Re as n,Te as o,qe as p,Ee as q,yt as r,ya as s,dr as t,cr as u,gt as v,Ct as w,pr as x,b as y,He as z,ze as A,We as B,Ne as C,Ft as D,S as E,Z as F,h as G,g as H,c as I,I as J,y as K,hr as L,_ as M,Fr as N,Rr as O,Tr as P};
2
- /*! For license information please see chunk-BDPIC42C.js.LEGAL.txt */
1
+ import{a as ee,c as Qe}from"./chunk-DCANE7XH.js";var na=ee(i=>{"use strict";var he=Symbol.for("react.transitional.element"),Ua=Symbol.for("react.portal"),_a=Symbol.for("react.fragment"),Ha=Symbol.for("react.strict_mode"),Ga=Symbol.for("react.profiler"),Va=Symbol.for("react.consumer"),za=Symbol.for("react.context"),Wa=Symbol.for("react.forward_ref"),Na=Symbol.for("react.suspense"),Xa=Symbol.for("react.memo"),ua=Symbol.for("react.lazy"),ja=Symbol.for("react.activity"),Ye=Symbol.iterator;function $a(e){return e===null||typeof e!="object"?null:(e=Ye&&e[Ye]||e["@@iterator"],typeof e=="function"?e:null)}var ra={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},sa=Object.assign,oa={};function N(e,a,t){this.props=e,this.context=a,this.refs=oa,this.updater=t||ra}N.prototype.isReactComponent={};N.prototype.setState=function(e,a){if(typeof e!="object"&&typeof e!="function"&&e!=null)throw Error("takes an object of state variables to update or a function which returns an object of state variables.");this.updater.enqueueSetState(this,e,a,"setState")};N.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,"forceUpdate")};function la(){}la.prototype=N.prototype;function Le(e,a,t){this.props=e,this.context=a,this.refs=oa,this.updater=t||ra}var Ie=Le.prototype=new la;Ie.constructor=Le;sa(Ie,N.prototype);Ie.isPureReactComponent=!0;var ea=Array.isArray;function me(){}var x={H:null,A:null,T:null,S:null},fa=Object.prototype.hasOwnProperty;function xe(e,a,t){var u=t.ref;return{$$typeof:he,type:e,key:a,ref:u!==void 0?u:null,props:t}}function Ka(e,a){return xe(e.type,a,e.props)}function ye(e){return typeof e=="object"&&e!==null&&e.$$typeof===he}function Za(e){var a={"=":"=0",":":"=2"};return"$"+e.replace(/[=:]/g,function(t){return a[t]})}var aa=/\/+/g;function pe(e,a){return typeof e=="object"&&e!==null&&e.key!=null?Za(""+e.key):a.toString(36)}function Ja(e){switch(e.status){case"fulfilled":return e.value;case"rejected":throw e.reason;default:switch(typeof e.status=="string"?e.then(me,me):(e.status="pending",e.then(function(a){e.status==="pending"&&(e.status="fulfilled",e.value=a)},function(a){e.status==="pending"&&(e.status="rejected",e.reason=a)})),e.status){case"fulfilled":return e.value;case"rejected":throw e.reason}}throw e}function W(e,a,t,u,r){var s=typeof e;(s==="undefined"||s==="boolean")&&(e=null);var o=!1;if(e===null)o=!0;else switch(s){case"bigint":case"string":case"number":o=!0;break;case"object":switch(e.$$typeof){case he:case Ua:o=!0;break;case ua:return o=e._init,W(o(e._payload),a,t,u,r)}}if(o)return r=r(e),o=u===""?"."+pe(e,0):u,ea(r)?(t="",o!=null&&(t=o.replace(aa,"$&/")+"/"),W(r,a,t,"",function(n){return n})):r!=null&&(ye(r)&&(r=Ka(r,t+(r.key==null||e&&e.key===r.key?"":(""+r.key).replace(aa,"$&/")+"/")+o)),a.push(r)),1;o=0;var f=u===""?".":u+":";if(ea(e))for(var l=0;l<e.length;l++)u=e[l],s=f+pe(u,l),o+=W(u,a,t,s,r);else if(l=$a(e),typeof l=="function")for(e=l.call(e),l=0;!(u=e.next()).done;)u=u.value,s=f+pe(u,l++),o+=W(u,a,t,s,r);else if(s==="object"){if(typeof e.then=="function")return W(Ja(e),a,t,u,r);throw a=String(e),Error("Objects are not valid as a React child (found: "+(a==="[object Object]"?"object with keys {"+Object.keys(e).join(", ")+"}":a)+"). If you meant to render a collection of children, use an array instead.")}return o}function ae(e,a,t){if(e==null)return e;var u=[],r=0;return W(e,u,"","",function(s){return a.call(t,s,r++)}),u}function Qa(e){if(e._status===-1){var a=e._result;a=a(),a.then(function(t){(e._status===0||e._status===-1)&&(e._status=1,e._result=t)},function(t){(e._status===0||e._status===-1)&&(e._status=2,e._result=t)}),e._status===-1&&(e._status=0,e._result=a)}if(e._status===1)return e._result.default;throw e._result}var ta=typeof reportError=="function"?reportError:function(e){if(typeof window=="object"&&typeof window.ErrorEvent=="function"){var a=new window.ErrorEvent("error",{bubbles:!0,cancelable:!0,message:typeof e=="object"&&e!==null&&typeof e.message=="string"?String(e.message):String(e),error:e});if(!window.dispatchEvent(a))return}else if(typeof process=="object"&&typeof process.emit=="function"){process.emit("uncaughtException",e);return}console.error(e)},Ya={map:ae,forEach:function(e,a,t){ae(e,function(){a.apply(this,arguments)},t)},count:function(e){var a=0;return ae(e,function(){a++}),a},toArray:function(e){return ae(e,function(a){return a})||[]},only:function(e){if(!ye(e))throw Error("React.Children.only expected to receive a single React element child.");return e}};i.Activity=ja;i.Children=Ya;i.Component=N;i.Fragment=_a;i.Profiler=Ga;i.PureComponent=Le;i.StrictMode=Ha;i.Suspense=Na;i.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=x;i.__COMPILER_RUNTIME={__proto__:null,c:function(e){return x.H.useMemoCache(e)}};i.cache=function(e){return function(){return e.apply(null,arguments)}};i.cacheSignal=function(){return null};i.cloneElement=function(e,a,t){if(e==null)throw Error("The argument must be a React element, but you passed "+e+".");var u=sa({},e.props),r=e.key;if(a!=null)for(s in a.key!==void 0&&(r=""+a.key),a)!fa.call(a,s)||s==="key"||s==="__self"||s==="__source"||s==="ref"&&a.ref===void 0||(u[s]=a[s]);var s=arguments.length-2;if(s===1)u.children=t;else if(1<s){for(var o=Array(s),f=0;f<s;f++)o[f]=arguments[f+2];u.children=o}return xe(e.type,r,u)};i.createContext=function(e){return e={$$typeof:za,_currentValue:e,_currentValue2:e,_threadCount:0,Provider:null,Consumer:null},e.Provider=e,e.Consumer={$$typeof:Va,_context:e},e};i.createElement=function(e,a,t){var u,r={},s=null;if(a!=null)for(u in a.key!==void 0&&(s=""+a.key),a)fa.call(a,u)&&u!=="key"&&u!=="__self"&&u!=="__source"&&(r[u]=a[u]);var o=arguments.length-2;if(o===1)r.children=t;else if(1<o){for(var f=Array(o),l=0;l<o;l++)f[l]=arguments[l+2];r.children=f}if(e&&e.defaultProps)for(u in o=e.defaultProps,o)r[u]===void 0&&(r[u]=o[u]);return xe(e,s,r)};i.createRef=function(){return{current:null}};i.forwardRef=function(e){return{$$typeof:Wa,render:e}};i.isValidElement=ye;i.lazy=function(e){return{$$typeof:ua,_payload:{_status:-1,_result:e},_init:Qa}};i.memo=function(e,a){return{$$typeof:Xa,type:e,compare:a===void 0?null:a}};i.startTransition=function(e){var a=x.T,t={};x.T=t;try{var u=e(),r=x.S;r!==null&&r(t,u),typeof u=="object"&&u!==null&&typeof u.then=="function"&&u.then(me,ta)}catch(s){ta(s)}finally{a!==null&&t.types!==null&&(a.types=t.types),x.T=a}};i.unstable_useCacheRefresh=function(){return x.H.useCacheRefresh()};i.use=function(e){return x.H.use(e)};i.useActionState=function(e,a,t){return x.H.useActionState(e,a,t)};i.useCallback=function(e,a){return x.H.useCallback(e,a)};i.useContext=function(e){return x.H.useContext(e)};i.useDebugValue=function(){};i.useDeferredValue=function(e,a){return x.H.useDeferredValue(e,a)};i.useEffect=function(e,a){return x.H.useEffect(e,a)};i.useEffectEvent=function(e){return x.H.useEffectEvent(e)};i.useId=function(){return x.H.useId()};i.useImperativeHandle=function(e,a,t){return x.H.useImperativeHandle(e,a,t)};i.useInsertionEffect=function(e,a){return x.H.useInsertionEffect(e,a)};i.useLayoutEffect=function(e,a){return x.H.useLayoutEffect(e,a)};i.useMemo=function(e,a){return x.H.useMemo(e,a)};i.useOptimistic=function(e,a){return x.H.useOptimistic(e,a)};i.useReducer=function(e,a,t){return x.H.useReducer(e,a,t)};i.useRef=function(e){return x.H.useRef(e)};i.useState=function(e){return x.H.useState(e)};i.useSyncExternalStore=function(e,a,t){return x.H.useSyncExternalStore(e,a,t)};i.useTransition=function(){return x.H.useTransition()};i.version="19.2.8"});var ge=ee((uu,ia)=>{"use strict";ia.exports=na()});var La=ee(re=>{"use strict";var It=Symbol.for("react.transitional.element"),xt=Symbol.for("react.fragment");function ha(e,a,t){var u=null;if(t!==void 0&&(u=""+t),a.key!==void 0&&(u=""+a.key),"key"in a){t={};for(var r in a)r!=="key"&&(t[r]=a[r])}else t=a;return a=t.ref,{$$typeof:It,type:e,key:u,ref:a!==void 0?a:null,props:t}}re.Fragment=xt;re.jsx=ha;re.jsxs=ha});var yt=ee((fr,Ia)=>{"use strict";Ia.exports=La()});var ue=Qe(ge());var da=e=>e.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase(),et=e=>e.replace(/^([A-Z])|[\s-_]+(\w)/g,(a,t,u)=>u?u.toUpperCase():t.toLowerCase()),Ce=e=>{let a=et(e);return a.charAt(0).toUpperCase()+a.slice(1)},te=(...e)=>e.filter((a,t,u)=>!!a&&a.trim()!==""&&u.indexOf(a)===t).join(" ").trim(),ca=e=>{for(let a in e)if(a.startsWith("aria-")||a==="role"||a==="title")return!0};var j=Qe(ge());var pa={xmlns:"http://www.w3.org/2000/svg",width:24,height:24,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"};var ma=(0,j.forwardRef)(({color:e="currentColor",size:a=24,strokeWidth:t=2,absoluteStrokeWidth:u,className:r="",children:s,iconNode:o,...f},l)=>(0,j.createElement)("svg",{ref:l,...pa,width:a,height:a,stroke:e,strokeWidth:u?Number(t)*24/Number(a):t,className:te("lucide",r),...!s&&!ca(f)&&{"aria-hidden":"true"},...f},[...o.map(([n,d])=>(0,j.createElement)(n,d)),...Array.isArray(s)?s:[s]]));var m=(e,a)=>{let t=(0,ue.forwardRef)(({className:u,...r},s)=>(0,ue.createElement)(ma,{ref:s,iconNode:a,className:te(`lucide-${da(Ce(e))}`,`lucide-${e}`,u),...r}));return t.displayName=Ce(e),t};var at=[["path",{d:"M5 12h14",key:"1ays0h"}],["path",{d:"m12 5 7 7-7 7",key:"xquz4c"}]],Se=m("arrow-right",at);var tt=[["path",{d:"m15 18-6-6 6-6",key:"1wnfg3"}]],ve=m("chevron-left",tt);var ut=[["path",{d:"M3.85 8.62a4 4 0 0 1 4.78-4.77 4 4 0 0 1 6.74 0 4 4 0 0 1 4.78 4.78 4 4 0 0 1 0 6.74 4 4 0 0 1-4.77 4.78 4 4 0 0 1-6.75 0 4 4 0 0 1-4.78-4.77 4 4 0 0 1 0-6.76Z",key:"3c2336"}],["path",{d:"m9 12 2 2 4-4",key:"dzmm74"}]],X=m("badge-check",ut);var rt=[["path",{d:"m6 9 6 6 6-6",key:"qrunsl"}]],ke=m("chevron-down",rt);var st=[["path",{d:"m9 18 6-6-6-6",key:"mthhwq"}]],we=m("chevron-right",st);var ot=[["path",{d:"M12 6v6h4",key:"135r8i"}],["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}]],Ae=m("clock-3",ot);var lt=[["path",{d:"M15 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V7Z",key:"1rqfz7"}],["path",{d:"M14 2v4a2 2 0 0 0 2 2h4",key:"tnqrlb"}],["path",{d:"M10 9H8",key:"b1mrlr"}],["path",{d:"M16 13H8",key:"t4e002"}],["path",{d:"M16 17H8",key:"z1uh3a"}]],Pe=m("file-text",lt);var ft=[["path",{d:"m14 13-8.381 8.38a1 1 0 0 1-3.001-3l8.384-8.381",key:"pgg06f"}],["path",{d:"m16 16 6-6",key:"vzrcl6"}],["path",{d:"m21.5 10.5-8-8",key:"a17d9x"}],["path",{d:"m8 8 6-6",key:"18bi4p"}],["path",{d:"m8.5 7.5 8 8",key:"1oyaui"}]],be=m("gavel",ft);var nt=[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M12 16v-4",key:"1dtifu"}],["path",{d:"M12 8h.01",key:"e9boi3"}]],De=m("info",nt);var it=[["path",{d:"m3 17 2 2 4-4",key:"1jhpwq"}],["path",{d:"m3 7 2 2 4-4",key:"1obspn"}],["path",{d:"M13 6h8",key:"15sg57"}],["path",{d:"M13 12h8",key:"h98zly"}],["path",{d:"M13 18h8",key:"oe0vm4"}]],Me=m("list-checks",it);var dt=[["rect",{x:"14",y:"3",width:"5",height:"18",rx:"1",key:"kaeet6"}],["rect",{x:"5",y:"3",width:"5",height:"18",rx:"1",key:"1wsw3u"}]],Be=m("pause",dt);var ct=[["path",{d:"M5 5a2 2 0 0 1 3.008-1.728l11.997 6.998a2 2 0 0 1 .003 3.458l-12 7A2 2 0 0 1 5 19z",key:"10ikf1"}]],Fe=m("play",ct);var pt=[["path",{d:"M20 13c0 5-3.5 7.5-7.66 8.95a1 1 0 0 1-.67-.01C7.5 20.5 4 18 4 13V6a1 1 0 0 1 1-1c2 0 4.5-1.2 6.24-2.72a1.17 1.17 0 0 1 1.52 0C14.51 3.81 17 5 19 5a1 1 0 0 1 1 1z",key:"oel41y"}],["path",{d:"m9 12 2 2 4-4",key:"dzmm74"}]],Re=m("shield-check",pt);var mt=[["path",{d:"M16 10a4 4 0 0 1-8 0",key:"1ltviw"}],["path",{d:"M3.103 6.034h17.794",key:"awc11p"}],["path",{d:"M3.4 5.467a2 2 0 0 0-.4 1.2V20a2 2 0 0 0 2 2h14a2 2 0 0 0 2-2V6.667a2 2 0 0 0-.4-1.2l-2-2.667A2 2 0 0 0 17 2H7a2 2 0 0 0-1.6.8z",key:"o988cm"}]],Te=m("shopping-bag",mt);var ht=[["path",{d:"M10 2h4",key:"n1abiw"}],["path",{d:"M12 14v-4",key:"1evpnu"}],["path",{d:"M4 13a8 8 0 0 1 8-7 8 8 0 1 1-5.3 14L4 17.6",key:"1ts96g"}],["path",{d:"M9 17H4v5",key:"8t5av"}]],qe=m("timer-reset",ht);var Lt=[["path",{d:"M18 6 6 18",key:"1bl5f8"}],["path",{d:"m6 6 12 12",key:"d8bk6v"}]],Ee=m("x",Lt);var xa=new Map;function ya(e,a=2){let t=xa.get(a);return t||(t=new Intl.NumberFormat("en-US",{currency:"USD",maximumFractionDigits:2,minimumFractionDigits:a,style:"currency"}),xa.set(a,t)),t.format(e/100)}function dr(e,a=e.status,t){let u=a==="draft",r=t??Ct(e),s=u?r?.startAt??e.startAt:(a==="finished"?t?.finishedAt:void 0)??t?.endAt??e.endAt,o=new Date(s);if(!Number.isFinite(o.getTime()))return"";let l=(u?r?.startAt:t?.endAt)?!0:(u?e.configuration.startTimeEnabled:e.configuration.endTimeEnabled)??!0,n=new Intl.DateTimeFormat("en-US",{day:"numeric",month:"short",timeZone:"America/New_York",year:"numeric"}).format(o);if(!l)return n;let d=new Intl.DateTimeFormat("en-US",{hour:"numeric",minute:"2-digit",timeZone:"America/New_York",timeZoneName:"short"}).format(o);return`${n} at ${d}`}function cr(e){return ya(e,0)}function gt(e,a){if(e.status==="finished"||a?.status==="finished")return"finished";if(a&&!(a.startAt&&a.endAt)&&(a.status==="draft"||e.status==="draft"))return"draft";let t=Date.now();if(Date.parse(a?.endAt??e.endAt)<=t)return"finished";if(Date.parse(a?.startAt??e.startAt)>t)return"draft";if(a)return"active";if(e.items.length){let u=e.items.map(r=>gt(e,r));return u.includes("active")?"active":u.includes("draft")?"draft":"finished"}return e.status}function Ct(e){let a=Date.now();return e.items.filter(t=>t.status!=="finished"&&Date.parse(t.startAt??e.startAt)>a).sort((t,u)=>Date.parse(t.startAt??e.startAt)-Date.parse(u.startAt??e.startAt))[0]}function pr(e){return e.isSoldOut||e.saleMode==="buy_now"&&e.availableQuantity===0}var se,St={lang:void 0,message:void 0,abortEarly:void 0,abortPipeEarly:void 0};function Oe(e){return!e&&!se?St:{lang:e?.lang??se?.lang,message:e?.message,abortEarly:e?.abortEarly??se?.abortEarly,abortPipeEarly:e?.abortPipeEarly??se?.abortPipeEarly}}var vt;function kt(e){return vt?.get(e)}var wt;function At(e){return wt?.get(e)}var Pt;function bt(e,a){return Pt?.get(e)?.get(a)}function G(e){let a=typeof e;return a==="string"?`"${e}"`:a==="number"||a==="bigint"||a==="boolean"?`${e}`:a==="object"||a==="function"?(e&&Object.getPrototypeOf(e)?.constructor?.name)??"null":a}function L(e,a,t,u,r){let s=r&&"input"in r?r.input:t.value,o=r?.expected??e.expects??null,f=r?.received??G(s),l={kind:e.kind,type:e.type,input:s,expected:o,received:f,message:`Invalid ${a}: ${o?`Expected ${o} but r`:"R"}eceived ${f}`,requirement:e.requirement,path:r?.path,issues:r?.issues,lang:u.lang,abortEarly:u.abortEarly,abortPipeEarly:u.abortPipeEarly},n=e.kind==="schema",d=r?.message??e.message??bt(e.reference,l.lang)??(n?At(l.lang):null)??u.message??kt(l.lang);d!==void 0&&(l.message=typeof d=="function"?d(l):d),n&&(t.typed=!1),t.issues?t.issues.push(l):t.issues=[l]}var ga=new WeakMap;function P(e){let a=ga.get(e);return a||(a={version:1,vendor:"valibot",validate(t){return e["~run"]({value:t},Oe())}},ga.set(e,a)),a}function Dt(e,a){return Object.prototype.hasOwnProperty.call(e,a)&&a!=="__proto__"&&a!=="prototype"&&a!=="constructor"}function Ue(e,a){let t=[...new Set(e)];return t.length>1?`(${t.join(` ${a} `)})`:t[0]??"never"}var _e=class extends Error{constructor(e){super(e[0].message),this.name="ValiError",this.issues=e}};var Mt=/^[\w+-]+(?:\.[\w+-]+)*@[\da-z]+(?:[.-][\da-z]+)*\.[a-z]{2,}$/iu;var Bt=/^\d{4}-(?:0[1-9]|1[0-2])-(?:[12]\d|0[1-9]|3[01])[T ](?:0\d|1\d|2[0-3])(?::[0-5]\d){2}(?:\.\d{1,9})?(?:Z| ?[+-](?:0\d|1\d|2[0-3])(?::?[0-5]\d)?)$/u;function b(e,a){return{kind:"validation",type:"check",reference:b,async:!1,expects:null,requirement:e,message:a,"~run"(t,u){return t.typed&&!this.requirement(t.value)&&L(this,"input",t,u),t}}}function He(e){return{kind:"validation",type:"email",reference:He,expects:null,async:!1,requirement:Mt,message:e,"~run"(a,t){return a.typed&&!this.requirement.test(a.value)&&L(this,"email",a,t),a}}}function Ge(e){return{kind:"validation",type:"iso_timestamp",reference:Ge,async:!1,expects:null,requirement:Bt,message:e,"~run"(a,t){return a.typed&&!this.requirement.test(a.value)&&L(this,"timestamp",a,t),a}}}function Ve(e,a){return{kind:"validation",type:"max_value",reference:Ve,async:!1,expects:`<=${e instanceof Date?e.toJSON():G(e)}`,requirement:e,message:a,"~run"(t,u){return t.typed&&!(t.value<=this.requirement)&&L(this,"value",t,u,{received:t.value instanceof Date?t.value.toJSON():G(t.value)}),t}}}function $(e,a){return{kind:"validation",type:"min_length",reference:$,async:!1,expects:`>=${e}`,requirement:e,message:a,"~run"(t,u){return t.typed&&t.value.length<this.requirement&&L(this,"length",t,u,{received:`${t.value.length}`}),t}}}function R(e,a){return{kind:"validation",type:"min_value",reference:R,async:!1,expects:`>=${e instanceof Date?e.toJSON():G(e)}`,requirement:e,message:a,"~run"(t,u){return t.typed&&!(t.value>=this.requirement)&&L(this,"value",t,u,{received:t.value instanceof Date?t.value.toJSON():G(t.value)}),t}}}function ze(e){return{kind:"validation",type:"non_empty",reference:ze,async:!1,expects:"!0",message:e,"~run"(a,t){return a.typed&&a.value.length===0&&L(this,"length",a,t,{received:"0"}),a}}}function We(e,a){return{kind:"validation",type:"regex",reference:We,async:!1,expects:`${e}`,requirement:e,message:a,"~run"(t,u){return t.typed&&!this.requirement.test(t.value)&&L(this,"format",t,u),t}}}function K(e){return{kind:"validation",type:"safe_integer",reference:K,async:!1,expects:null,requirement:Number.isSafeInteger,message:e,"~run"(a,t){return a.typed&&!this.requirement(a.value)&&L(this,"safe integer",a,t),a}}}function Ne(e){return{kind:"transformation",type:"transform",reference:Ne,async:!1,operation:e,"~run"(a){return a.value=this.operation(a.value),a}}}function Ft(){return{kind:"transformation",type:"trim",reference:Ft,async:!1,"~run"(e){return e.value=e.value.trim(),e}}}var Sa={abortEarly:!0};function va(e,a,t){return typeof e.fallback=="function"?e.fallback(a,t):e.fallback}function oe(e,a,t){return typeof e.default=="function"?e.default(a,t):e.default}function le(e,a){return!e["~run"]({value:a},Sa).issues}function q(e,a){return{kind:"schema",type:"array",reference:q,expects:"Array",async:!1,item:e,message:a,get"~standard"(){return P(this)},"~run"(t,u){let r=t.value;if(Array.isArray(r)){t.typed=!0,t.value=[];for(let s=0;s<r.length;s++){let o=r[s],f=this.item["~run"]({value:o},u);if(f.issues){let l={type:"array",origin:"value",input:r,key:s,value:o};for(let n of f.issues)n.path?n.path.unshift(l):n.path=[l],t.issues?.push(n);if(t.issues||(t.issues=f.issues),u.abortEarly){t.typed=!1;break}}f.typed||(t.typed=!1),t.value.push(f.value)}}else L(this,"type",t,u);return t}}}function S(e){return{kind:"schema",type:"boolean",reference:S,expects:"boolean",async:!1,message:e,get"~standard"(){return P(this)},"~run"(a,t){return typeof a.value=="boolean"?a.typed=!0:L(this,"type",a,t),a}}}function fe(e,a){return{kind:"schema",type:"custom",reference:fe,expects:"unknown",async:!1,check:e,message:a,get"~standard"(){return P(this)},"~run"(t,u){return this.check(t.value)?t.typed=!0:L(this,"type",t,u),t}}}function ne(e){return{kind:"schema",type:"function",reference:ne,expects:"Function",async:!1,message:e,get"~standard"(){return P(this)},"~run"(a,t){return typeof a.value=="function"?a.typed=!0:L(this,"type",a,t),a}}}function Z(e,a){return{kind:"schema",type:"literal",reference:Z,expects:G(e),async:!1,literal:e,message:a,get"~standard"(){return P(this)},"~run"(t,u){return t.value===this.literal?t.typed=!0:L(this,"type",t,u),t}}}function J(e,a){return{kind:"schema",type:"loose_object",reference:J,expects:"Object",async:!1,entries:e,message:a,get"~standard"(){return P(this)},"~run"(t,u){let r=t.value;if(r&&typeof r=="object"){t.typed=!0,t.value={};for(let s in this.entries){let o=this.entries[s];if(s in r||(o.type==="exact_optional"||o.type==="optional"||o.type==="nullish")&&o.default!==void 0){let f=s in r?r[s]:oe(o),l=o["~run"]({value:f},u);if(l.issues){let n={type:"object",origin:"value",input:r,key:s,value:f};for(let d of l.issues)d.path?d.path.unshift(n):d.path=[n],t.issues?.push(d);if(t.issues||(t.issues=l.issues),u.abortEarly){t.typed=!1;break}}l.typed||(t.typed=!1),t.value[s]=l.value}else if(o.fallback!==void 0)t.value[s]=va(o);else if(o.type!=="exact_optional"&&o.type!=="optional"&&o.type!=="nullish"&&(L(this,"key",t,u,{input:void 0,expected:`"${s}"`,path:[{type:"object",origin:"key",input:r,key:s,value:r[s]}]}),u.abortEarly))break}if(!t.issues||!u.abortEarly)for(let s in r)Dt(r,s)&&!(s in this.entries)&&(t.value[s]=r[s])}else L(this,"type",t,u);return t}}}function h(e,a){return{kind:"schema",type:"nullable",reference:h,expects:`(${e.expects} | null)`,async:!1,wrapped:e,default:a,get"~standard"(){return P(this)},"~run"(t,u){return t.value===null&&(this.default!==void 0&&(t.value=oe(this,t,u)),t.value===null)?(t.typed=!0,t):this.wrapped["~run"](t,u)}}}function Q(e){return{kind:"schema",type:"number",reference:Q,expects:"number",async:!1,message:e,get"~standard"(){return P(this)},"~run"(a,t){return typeof a.value=="number"&&!isNaN(a.value)?a.typed=!0:L(this,"type",a,t),a}}}function g(e,a){return{kind:"schema",type:"object",reference:g,expects:"Object",async:!1,entries:e,message:a,get"~standard"(){return P(this)},"~run"(t,u){let r=t.value;if(r&&typeof r=="object"){t.typed=!0,t.value={};for(let s in this.entries){let o=this.entries[s];if(s in r||(o.type==="exact_optional"||o.type==="optional"||o.type==="nullish")&&o.default!==void 0){let f=s in r?r[s]:oe(o),l=o["~run"]({value:f},u);if(l.issues){let n={type:"object",origin:"value",input:r,key:s,value:f};for(let d of l.issues)d.path?d.path.unshift(n):d.path=[n],t.issues?.push(d);if(t.issues||(t.issues=l.issues),u.abortEarly){t.typed=!1;break}}l.typed||(t.typed=!1),t.value[s]=l.value}else if(o.fallback!==void 0)t.value[s]=va(o);else if(o.type!=="exact_optional"&&o.type!=="optional"&&o.type!=="nullish"&&(L(this,"key",t,u,{input:void 0,expected:`"${s}"`,path:[{type:"object",origin:"key",input:r,key:s,value:r[s]}]}),u.abortEarly))break}}else L(this,"type",t,u);return t}}}function c(e,a){return{kind:"schema",type:"optional",reference:c,expects:`(${e.expects} | undefined)`,async:!1,wrapped:e,default:a,get"~standard"(){return P(this)},"~run"(t,u){return t.value===void 0&&(this.default!==void 0&&(t.value=oe(this,t,u)),t.value===void 0)?(t.typed=!0,t):this.wrapped["~run"](t,u)}}}function D(e,a){return{kind:"schema",type:"picklist",reference:D,expects:Ue(e.map(G),"|"),async:!1,options:e,message:a,get"~standard"(){return P(this)},"~run"(t,u){return this.options.includes(t.value)?t.typed=!0:L(this,"type",t,u),t}}}function Xe(e,a){return{kind:"schema",type:"strict_tuple",reference:Xe,expects:"Array",async:!1,items:e,message:a,get"~standard"(){return P(this)},"~run"(t,u){let r=t.value;if(Array.isArray(r)){t.typed=!0,t.value=[];for(let s=0;s<this.items.length;s++){let o=r[s],f=this.items[s]["~run"]({value:o},u);if(f.issues){let l={type:"array",origin:"value",input:r,key:s,value:o};for(let n of f.issues)n.path?n.path.unshift(l):n.path=[l],t.issues?.push(n);if(t.issues||(t.issues=f.issues),u.abortEarly){t.typed=!1;break}}f.typed||(t.typed=!1),t.value.push(f.value)}!(t.issues&&u.abortEarly)&&this.items.length<r.length&&L(this,"type",t,u,{input:r[this.items.length],expected:"never",path:[{type:"array",origin:"value",input:r,key:this.items.length,value:r[this.items.length]}]})}else L(this,"type",t,u);return t}}}function I(e){return{kind:"schema",type:"string",reference:I,expects:"string",async:!1,message:e,get"~standard"(){return P(this)},"~run"(a,t){return typeof a.value=="string"?a.typed=!0:L(this,"type",a,t),a}}}function Ca(e){let a;if(e)for(let t of e)if(a)for(let u of t.issues)a.push(u);else a=t.issues;return a}function je(e,a){return{kind:"schema",type:"union",reference:je,expects:Ue(e.map(t=>t.expects),"|"),async:!1,options:e,message:a,get"~standard"(){return P(this)},"~run"(t,u){let r,s,o;for(let f of this.options){let l=f["~run"]({value:t.value},u);if(l.typed)if(l.issues)s?s.push(l):s=[l];else{r=l;break}else o?o.push(l):o=[l]}if(r)return r;if(s){if(s.length===1)return s[0];L(this,"type",t,u,{issues:Ca(s)}),t.typed=!0}else{if(o?.length===1)return o[0];L(this,"type",t,u,{issues:Ca(o)})}return t}}}function $e(){return{kind:"schema",type:"unknown",reference:$e,expects:"unknown",async:!1,get"~standard"(){return P(this)},"~run"(e){return e.typed=!0,e}}}function Ke(e,a,t){return{kind:"schema",type:"variant",reference:Ke,expects:"Object",async:!1,key:e,options:a,message:t,get"~standard"(){return P(this)},"~run"(u,r){let s=u.value;if(s&&typeof s=="object"){let o,f=0,l=this.key,n=[],d=(C,M)=>{for(let B of C.options){if(B.type==="variant")d(B,new Set(M).add(B.key));else{let F=!0,T=0;for(let A of M){let k=B.entries[A];if(A in s?k["~run"]({typed:!1,value:s[A]},Sa).issues:k.type!=="exact_optional"&&k.type!=="optional"&&k.type!=="nullish"){F=!1,l!==A&&(f<T||f===T&&A in s&&!(l in s))&&(f=T,l=A,n=[]),l===A&&n.push(B.entries[A].expects);break}T++}if(F){let A=B["~run"]({value:s},r);(!o||!o.typed&&A.typed)&&(o=A)}}if(o&&!o.issues)break}};if(d(this,new Set([this.key])),o)return o;L(this,"type",u,r,{input:s[l],expected:Ue(n,"|"),path:[{type:"object",origin:"value",input:s,key:l,value:s[l]}]})}else L(this,"type",u,r);return u}}}function w(e,a,t){let u=e["~run"]({value:a},Oe(t));if(u.issues)throw new _e(u.issues);return u.value}function y(...e){return{...e[0],pipe:e,get"~standard"(){return P(this)},"~run"(a,t){for(let u of e)if(u.kind!=="metadata"){if(a.issues&&(u.kind==="schema"||u.kind==="transformation")){a.typed=!1;break}(!a.issues||!t.abortEarly&&!t.abortPipeEarly)&&(a=u["~run"](a,t))}return a}}}function hr(e,a,t){let u=e["~run"]({value:a},Oe(t));return{typed:u.typed,success:!u.issues,output:u.value,issues:u.issues}}var Rt="0.2.256",_=class extends Error{failureKind;code;operation;reportable;recoveryRecommended;sdkVersion;serverCode;status;constructor({failureKind:e,code:a,message:t,operation:u,reportable:r,recoveryRecommended:s=!1,serverCode:o,status:f}){super(t),this.name="LockerverseSdkError",this.failureKind=e,this.code=a,this.operation=u,this.reportable=r,this.recoveryRecommended=s,this.sdkVersion=Rt,this.serverCode=o,this.status=f}};var V=y(I(),ze(),b(e=>e.trim().length>0)),Cr=c(h(I()),null);function wa(e){return y(Q(),K(),R(e))}var Aa=y(q($e()),Ne(e=>e.filter(a=>{let{archivedAt:t}=w(J({archivedAt:c(h(V))}),a);return!t}))),Tt=g({id:V,label:V}),ka=y(Aa,q(Tt),$(2),b(e=>new Set(e.map(({id:a})=>a)).size===e.length,"Expected unique custom field option IDs.")),ie={id:V,label:V,paymentOptionIds:c(q(V)),required:S()},qt=Ke("type",[g({...ie,type:D(["text","textarea"])}),g({...ie,type:D(["checkbox"])}),g({...ie,options:ka,type:D(["radio","select"])}),g({...ie,options:ka,type:D(["checkboxes","multi_select"])})]),Sr=y(c(Aa,[]),q(qt),b(e=>new Set(e.map(({id:a})=>a)).size===e.length,"Expected unique custom field IDs.")),vr=g({fieldId:V,value:je([S(),I(),q(I())])});function de(e){let a=new Object(e);if(a!==e||Object.isFrozen(a))return e;for(let t of Object.values(a))de(t);return Object.freeze(e)}var Pa=/\/+$/,Et=new Set(["localhost","127.0.0.1","[::1]"]),Ot={development:{sentryDsn:"https://1977371f7bc44480935a7bc9726ca296@o1338376.ingest.sentry.io/6631829"},production:{sentryDsn:"https://43d2d853c129415cf77531c914511174@o1338376.ingest.us.sentry.io/4511911476133888"}};function Ze(e,a,t="apiBaseUrl"){if(!le(I(),e))throw TypeError(`${t} must be a valid HTTP or HTTPS URL.`);let u;try{u=new URL(e)}catch{throw TypeError(`${t} must be a valid HTTP or HTTPS URL.`)}if(u.protocol!=="http:"&&u.protocol!=="https:")throw TypeError(`${t} must be a valid HTTP or HTTPS URL.`);if(u.username||u.password)throw TypeError(`${t} must not include credentials.`);if(u.search||u.hash)throw TypeError(`${t} must not include a query or fragment.`);if(u.protocol!=="https:"&&!(a==="development"&&(Et.has(u.hostname)||u.hostname.endsWith(".localhost"))))throw TypeError(`${t} must use HTTPS except for development loopback endpoints.`);return u.pathname=u.pathname.replace(Pa,""),u.toString().replace(Pa,"")}function Ut(e,a){let t="requestTimeoutMs must be a positive integer no greater than 2147483647.",u=r=>y(I(`${r} must be a non-empty string.`),b(s=>s.trim().length>0,`${r} must be a non-empty string.`));try{let r=w(J({apiBaseUrl:c(I("apiBaseUrl must be a valid HTTP or HTTPS URL.")),communitySlug:u("communitySlug"),environment:c(D(["development","production"],"environment must be either development or production.")),fetch:c(fe(s=>le(ne(),s),"fetch must be a function when provided.")),onError:c(fe(s=>le(ne(),s),"onError must be a function when provided.")),requestTimeoutMs:c(y(Q(t),K(t),R(1,t),Ve(2147483647,t))),sentryDsn:c(h(I("sentryDsn must be a string or null when provided.")))},"Expected an object."),e);return{apiBaseUrl:r.apiBaseUrl,communitySlug:r.communitySlug,environment:r.environment,fetch:r.fetch,onError:r.onError,requestTimeoutMs:r.requestTimeoutMs,resourceSlugValue:w(u(a),r[a]),sentryDsn:r.sentryDsn}}catch(r){let s=r instanceof _e?r.issues[0]?.message??"Invalid SDK options.":"Invalid SDK options.";throw TypeError(s)}}function ba(e,a){let t=Ut(e,a),u=t.environment;if(t.apiBaseUrl!==void 0&&u===void 0)throw TypeError("environment is required when apiBaseUrl is provided.");if(t.apiBaseUrl===void 0&&u==="development")throw TypeError("apiBaseUrl is required when environment is development.");let r=u===void 0?"production":u,{communitySlug:s,resourceSlugValue:o}=t,f=t.fetch??globalThis.fetch,l=t.apiBaseUrl===void 0?"https://portal.lockerverse.com/api":Ze(t.apiBaseUrl,r),n=Ot[r],d=t.sentryDsn,C=d===null?null:d??n.sentryDsn;return{apiBaseUrl:l,communitySlug:encodeURIComponent(s),communitySlugValue:s,environment:r,fetchImplementation:f,onError:t.onError,requestTimeoutMs:t.requestTimeoutMs??2e4,resourceSlug:encodeURIComponent(o),resourceSlugValue:o,sentryDsn:C}}function _t(){return globalThis.window}function Da({communitySlug:e,environment:a,getContext:t,onError:u,resourceContextName:r,sentryDsn:s}){let o=null;return function(f){try{Promise.resolve(u?.(f)).catch(()=>{})}catch{}let l=_t();if(f.reportable&&s&&l!==void 0){let n=o??import("./telemetry-6KTBIZ2M.js");o=n;let d={communitySlug:e,...t()},C=f.status===void 0?d:{...d,status:f.status};n.then(({captureSdkError:M})=>M({context:C,contextName:r,dsn:s,environment:a,error:f})).catch(()=>{o===n&&(o=null)})}return f}}function Ma(e,a,t){function u(s,o){let f=new _({code:s.code,failureKind:o,message:s.message,operation:s.operation,reportable:!0});return s.report===!1?f:a(f)}async function r(s,o,f,l,n,d){let C=new AbortController,M=o?.signal??void 0,B=()=>C.abort(M?.reason);M?.aborted?B():M?.addEventListener("abort",B,{once:!0});let F,T=new Promise((E,H)=>{F=()=>H(C.signal.reason??new DOMException("The request was aborted.","AbortError")),C.signal.aborted?F():C.signal.addEventListener("abort",F,{once:!0})}),A=!1;function k(E,H){return M?.aborted?"aborted":A?"timeout":C.signal.aborted||H instanceof Error&&H.name==="AbortError"?"aborted":E}let z=setTimeout(()=>{A=!0,C.abort(new DOMException("The request timed out.","TimeoutError"))},t);try{let E;try{E=await Promise.race([e(s,{...o,signal:C.signal}),T])}catch(Y){throw u(l,k("network",Y))}if(!E.ok)try{return{errorValue:d?await Promise.race([d(E),T]):void 0,ok:!1,response:E}}catch{throw u(l,"invalid_response")}let H;try{H=await Promise.race([E.json(),T])}catch(Y){throw u(n,k(Y instanceof TypeError?"network":"invalid_response",Y))}try{return{ok:!0,response:E,value:f(H)}}catch{throw u(n,"invalid_response")}}finally{clearTimeout(z),M?.removeEventListener("abort",B),F&&C.signal.removeEventListener("abort",F)}}return{requestJson:r}}function Ba(e,a){if(a===void 0)return e;e.mediaBaseUrl=a;let t=u=>u?.startsWith("https://media.lockerverse.com/")?`${a}/${u.slice(30)}`:u;e.configuration.image=t(e.configuration.image),e.community&&(e.community.banner=t(e.community.banner),e.community.thumbnail=t(e.community.thumbnail));for(let u of e.items)u.image=t(u.image),u.images=u.images.map(t);return e}var v=y(I(),$(1)),p=wa(0),O=y(I(),Ge()),Fa=D(["draft","active","finished"]),Ra=g({additionalUnitAmountCents:p,category:D(["shipping","handling","other"]),firstUnitAmountCents:p,name:v}),Ht=g({additionalCharge:c(h(Ra)),auctionId:v,availableQuantity:h(p),bidCount:p,bidIncrementAmount:h(p),buyNowPriceAmount:h(p),collectShippingAddress:S(),communityId:v,createdAt:O,description:h(I()),endAt:c(h(O)),finalizedBidCount:p,finishedAt:c(h(O)),id:v,image:h(I()),images:q(I()),inventoryQuantity:h(p),isSoldOut:S(),maxBidAmount:h(p),maxQuantityPerOrder:c(h(y(p,R(1)))),minBidAmount:h(p),name:I(),paidQuantity:p,path:v,position:p,reservedQuantity:p,saleMode:D(["auction","buy_now","hybrid"]),slug:v,startAt:c(h(O)),status:Fa,supportsMaximumBids:c(S()),updatedAt:O}),Ta=g({collectShippingAddress:S(),community:c(g({banner:c(h(I())),color:c(h(I())),name:c(I()),thumbnail:c(h(I()))})),communityId:v,configuration:g({collectShippingAddress:S(),endTimeEnabled:c(h(S())),image:h(I()),serviceFeeDefaultChecked:S(),serviceFeeEnabled:S(),startTimeEnabled:c(h(S()))}),createdAt:O,description:h(I()),endAt:O,id:v,items:q(Ht),name:I(),path:v,payment:c(g({connectedAccountId:h(v),currency:Z("usd"),publishableKey:v})),position:p,pricingPolicy:g({currency:Z("usd"),serviceFeeRateBasisPoints:p}),serviceFeeDefaultChecked:S(),serviceFeeEnabled:S(),slug:v,startAt:O,status:Fa,updatedAt:O}),Je={additionalCharge:c(h(Ra)),additionalChargeCents:c(p,0),serviceFeeCents:p,serviceFeeRateBasisPoints:p,subtotalCents:p,totalCents:p},ce=e=>e.totalCents===e.subtotalCents+e.serviceFeeCents+(e.additionalChargeCents??0),qa={...Je,clientSecret:h(v),requiresAction:S()},Gt=y(g(qa),b(e=>ce(e)),b(e=>!e.requiresAction||e.clientSecret!==null)),Ea=y(g({...qa,id:v,purchaseId:v,quantity:y(p,R(1)),status:D(["pending_payment","paid","payment_failed","expired","canceled","refunded"]),totalAmount:p}),b(e=>ce(e)),b(e=>e.id===e.purchaseId&&(!e.requiresAction||e.clientSecret!==null))),Vt=y(g({...Je,quantity:y(p,R(1)),totalAmount:p,unitAmount:p}),b(e=>ce(e))),Oa={confirmationToken:v,email:y(I(),He()),expectedAdditionalChargeCents:c(p),expectedServiceFeeCents:c(p),expectedSubtotalCents:c(p),expectedTotalCents:c(p),includeServiceFee:c(S()),phone:y(I(),We(/^\+[1-9]\d{1,14}$/))},zt=g({...Oa,amount:y(p,R(100)),bidType:c(D(["fixed","maximum"]))}),Wt=g({...Oa,clientRequestId:v,paymentMethodTypes:c(Xe([Z("card")])),quantity:y(p,R(1))}),Nt=e=>w(Ta,e),Xt=e=>w(q(Ta),e),jt=e=>w(Gt,e),$t=e=>w(Ea,e),Kt=e=>w(Vt,e),Zt=e=>w(zt,e),Jt=e=>w(Wt,e),Qt=e=>w(h(Ea),e),Yt=e=>w(y(g(Je),b(a=>ce(a))),e),eu=e=>w(g({includeServiceFee:c(S()),quantity:y(p,R(1))}),e);function au(e,a,t){let u=e+a.map(r=>`/${encodeURIComponent(w(v,r))}`).join("");return t===void 0?u:`${u}?${new URLSearchParams({previewItem:w(v,t)})}`}function Fr(e){let a=ba(e,"communitySlug"),t=e.mediaBaseUrl===void 0?void 0:Ze(e.mediaBaseUrl,a.environment,"mediaBaseUrl"),u=l=>Ba(Nt(l),t),r=Da({communitySlug:a.communitySlugValue,environment:a.environment,getContext:()=>({}),onError:a.onError,resourceContextName:"lockerverse_auction",sentryDsn:a.sentryDsn}),{requestJson:s}=Ma(a.fetchImplementation,r,a.requestTimeoutMs),o=`${a.apiBaseUrl}/auctions/communities/slug/${a.communitySlug}`;async function f(l,n,d,C,M,B=!1){let F=!!C&&!B,T,A;try{T=au(o,n,M),C&&(A={body:JSON.stringify(C.parse(C.value)),headers:{"content-type":"application/json"},method:"POST"})}catch{throw r(new _({...l,message:"Lockerverse auction input is invalid.",reportable:!1}))}try{let k=await s(T,A,d,{...l,report:!1},{...l,report:!1});if(!k.ok){let{status:z}=k.response;throw new _({...l,recoveryRecommended:F&&(z>=500||z===408),reportable:z>=500,status:z})}return de(k.value)}catch(k){throw k instanceof _?r(new _({...l,recoveryRecommended:k.recoveryRecommended||F&&k.status===void 0,reportable:k.reportable,...k.status===void 0?void 0:{status:k.status}})):r(new _({...l,recoveryRecommended:F,reportable:!0}))}}return{createBid:(l,n,d)=>f({code:"auction_bid_failed",message:"Unable to submit Lockerverse auction bid.",operation:"create_auction_bid"},["path",l,"items",n,"bids"],jt,{parse:Zt,value:d}),createPurchase:(l,n,d)=>f({code:"auction_purchase_failed",message:"Unable to submit Lockerverse auction purchase.",operation:"create_auction_purchase"},["path",l,"items",n,"purchases"],$t,{parse:Jt,value:d}),getPurchaseQuote:(l,n,d)=>f({code:"auction_load_failed",message:"Unable to load Lockerverse auction purchase quote.",operation:"load_auction"},["path",l,"items",n,"purchase-quote"],Yt,{parse:eu,value:d},void 0,!0),getPurchaseReceipt:(l,n,d)=>f({code:"auction_receipt_failed",message:"Unable to load Lockerverse auction purchase receipt.",operation:"get_auction_purchase_receipt"},["path",l,"items",n,"purchases",d],Kt),getPurchaseStatus:(l,n,d)=>f({code:"auction_purchase_status_failed",message:"Unable to load Lockerverse auction purchase status.",operation:"get_auction_purchase_status"},["path",l,"items",n,"purchase-status",d],Qt),list:()=>f({code:"auction_load_failed",message:"Unable to load Lockerverse auctions.",operation:"list_auctions"},[],l=>Xt(l).map(n=>Ba(n,t))),load:(l,n)=>f({code:"auction_load_failed",message:"Unable to load Lockerverse auction.",operation:"load_auction"},["path",l],u,void 0,n?.previewItemSlug)}}function U(e){if(!Number.isSafeInteger(e)||e<0)throw TypeError("Auction amounts must be non-negative safe integers.")}function Rr(e,a,t=!1,u=0){if(U(a),U(u),t&&!e.serviceFeeEnabled)throw TypeError("The service fee is not available for this auction.");let r=t?e.pricingPolicy.serviceFeeRateBasisPoints:0;U(r);let s=Math.round(a*r/1e4),o=a+s+u;U(s),U(o);let f={serviceFeeCents:s,serviceFeeRateBasisPoints:r,subtotalCents:a,totalCents:o};return u>0&&(f.additionalChargeCents=u),de(f)}function Tr(e){let a=e.minBidAmount??100,t=e.bidIncrementAmount??100;if(U(a),U(t),e.maxBidAmount===null)return a;U(e.maxBidAmount);let u=Math.max(a,e.maxBidAmount+t);return U(u),u}export{ge as a,Se as b,X as c,ke as d,ve as e,we as f,Ae as g,Pe as h,be as i,De as j,Me as k,Be as l,Fe as m,Re as n,Te as o,qe as p,Ee as q,yt as r,ya as s,dr as t,cr as u,gt as v,Ct as w,pr as x,b as y,He as z,ze as A,We as B,Ne as C,Ft as D,S as E,Z as F,h as G,g as H,c as I,I as J,y as K,hr as L,_ as M,Fr as N,Rr as O,Tr as P};
2
+ /*! For license information please see chunk-ZZUMO4Y2.js.LEGAL.txt */