@homepages/concrete 6.2.0 → 8.0.0
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/CHANGELOG.md +152 -0
- package/codemods/manifest.json +19 -0
- package/codemods/object-form-only.mjs +39 -0
- package/codemods/steps/list-object-form.mjs +688 -0
- package/codemods/steps/select-object-form.mjs +210 -0
- package/dist/artifact/playground/client/assets/index-Dn_xT16-.js +1101 -0
- package/dist/artifact/playground/client/index.html +1 -1
- package/dist/artifact/playground/host.mjs +14 -14
- package/dist/asset-modules.d.ts +2 -1
- package/dist/cli/check/stages/render.js +1 -1
- package/dist/cli/check/stages/sections.js +1 -1
- package/dist/fixtures/canonical.d.ts +2 -5
- package/dist/fixtures/media.js +11 -25
- package/dist/fixtures/property.js +28 -16
- package/dist/fixtures/resolve.js +31 -17
- package/dist/fixtures/rows.js +3 -83
- package/dist/fixtures.d.ts +17 -9
- package/dist/index.d.ts +9 -9
- package/dist/packages/external/concrete/package.js +1 -1
- package/dist/packages/internal/fill-bake/dist/bake-property-ref.js +32 -10
- package/dist/packages/internal/fill-bake/dist/derive-source.js +15 -4
- package/dist/packages/internal/fill-bake/dist/index.js +2 -2
- package/dist/packages/internal/fill-vocabulary/dist/origination.js +6 -61
- package/dist/packages/internal/fill-vocabulary/dist/row-reads.js +15 -0
- package/dist/packages/internal/property-facts/dist/index.js +1 -1
- package/dist/packages/internal/property-facts/dist/{property-facts-5pxZnlkh.js → property-facts-Cy7-O4p0.js} +2 -5
- package/dist/packages/internal/section-contracts/dist/catalog.js +2 -22
- package/dist/packages/internal/section-contracts/dist/fill-spec-view.js +6 -1
- package/dist/packages/internal/section-contracts/dist/group-contract.js +1 -3
- package/dist/packages/internal/section-contracts/dist/index.js +0 -5
- package/dist/packages/internal/section-contracts/dist/list-fill-contract.js +16 -7
- package/dist/packages/internal/section-contracts/dist/list-scalar-contract.js +1 -5
- package/dist/packages/internal/section-contracts/dist/row-fill-contract.js +14 -0
- package/dist/packages/internal/section-contracts/dist/runners.js +3 -28
- package/dist/packages/internal/section-contracts/dist/source-contract.js +93 -20
- package/dist/packages/internal/section-contracts/dist/writer-reads-fact-contract.js +19 -9
- package/dist/packages/internal/source-resolution/dist/index.js +48 -57
- package/dist/packages/internal/template-contracts/dist/facts-view.d.ts +6 -17
- package/dist/packages/internal/template-contracts/dist/facts-view.js +4 -23
- package/dist/packages/internal/template-contracts/dist/row-sources.js +20 -0
- package/dist/packages/internal/template-contracts/dist/slot-catalog.d.ts +362 -380
- package/dist/packages/internal/template-contracts/dist/slot-catalog.js +289 -293
- package/dist/primitives/slot-bindings.d.ts +7 -40
- package/dist/primitives/slot-bindings.js +10 -12
- package/dist/schema/define-schema.d.ts +1 -1
- package/dist/schema/define-schema.js +13 -1
- package/dist/schema/extract-fill-spec.js +14 -17
- package/dist/schema/fact.d.ts +2 -19
- package/dist/schema/fill-builders.d.ts +4 -3
- package/dist/schema/fill-spec.js +18 -1
- package/dist/schema/layout.d.ts +6 -8
- package/dist/schema/layout.js +3 -9
- package/dist/schema/property-facts.d.ts +17 -47
- package/dist/schema/row-fields.js +88 -0
- package/dist/schema/row-ref.d.ts +59 -0
- package/dist/schema/row-ref.js +28 -0
- package/dist/schema/runtime-values.d.ts +8 -13
- package/dist/schema/section-props.d.ts +19 -26
- package/dist/schema/section-schema.d.ts +6 -6
- package/dist/schema/section-schema.js +2 -2
- package/dist/schema/slot-builders.d.ts +247 -122
- package/dist/schema/slot-builders.js +57 -28
- package/dist/schema/slot-ref.d.ts +18 -2
- package/dist/schema/slot-ref.js +11 -3
- package/dist/schema/slot-types.d.ts +7 -7
- package/dist/schema/slot-types.js +55 -19
- package/dist/section/declare.d.ts +1 -1
- package/dist/section/section.d.ts +3 -3
- package/dist/template/logic-shim.d.ts +1 -1
- package/guide/reference/cli/INDEX.md +2 -2
- package/guide/reference/cli/build.md +1 -1
- package/guide/reference/cli/check.md +1 -1
- package/guide/reference/cli/dev.md +1 -1
- package/guide/reference/cli/property-add.md +1 -1
- package/guide/reference/cli/property-list.md +1 -1
- package/guide/reference/cli/publish.md +1 -1
- package/guide/reference/cli/upgrade.md +1 -1
- package/guide/reference/rules/INDEX.md +3 -8
- package/package.json +1 -1
- package/tsconfig.base.json +1 -0
- package/dist/artifact/playground/client/assets/index-Cqz-jjVw.js +0 -1101
- package/dist/packages/internal/section-contracts/dist/choose-select-contract.js +0 -20
- package/dist/packages/internal/section-contracts/dist/name-title-contract.js +0 -20
- package/dist/packages/internal/section-contracts/dist/pooling-field-contract.js +0 -20
- package/dist/packages/internal/section-contracts/dist/row-contract.js +0 -37
- package/dist/packages/internal/section-contracts/dist/source-filter-contract.js +0 -15
- package/dist/packages/internal/template-contracts/dist/layout.js +0 -10
|
@@ -0,0 +1,1101 @@
|
|
|
1
|
+
var vg=n=>{throw TypeError(n)};var Cd=(n,l,s)=>l.has(n)||vg("Cannot "+s);var S=(n,l,s)=>(Cd(n,l,"read from private field"),s?s.call(n):l.get(n)),be=(n,l,s)=>l.has(n)?vg("Cannot add the same private member more than once"):l instanceof WeakSet?l.add(n):l.set(n,s),fe=(n,l,s,o)=>(Cd(n,l,"write to private field"),o?o.call(n,s):l.set(n,s),s),je=(n,l,s)=>(Cd(n,l,"access private method"),s);var Ir=(n,l,s,o)=>({set _(u){fe(n,l,u,s)},get _(){return S(n,l,o)}});(function(){const l=document.createElement("link").relList;if(l&&l.supports&&l.supports("modulepreload"))return;for(const u of document.querySelectorAll('link[rel="modulepreload"]'))o(u);new MutationObserver(u=>{for(const d of u)if(d.type==="childList")for(const h of d.addedNodes)h.tagName==="LINK"&&h.rel==="modulepreload"&&o(h)}).observe(document,{childList:!0,subtree:!0});function s(u){const d={};return u.integrity&&(d.integrity=u.integrity),u.referrerPolicy&&(d.referrerPolicy=u.referrerPolicy),u.crossOrigin==="use-credentials"?d.credentials="include":u.crossOrigin==="anonymous"?d.credentials="omit":d.credentials="same-origin",d}function o(u){if(u.ep)return;u.ep=!0;const d=s(u);fetch(u.href,d)}})();function __(n){return n&&n.__esModule&&Object.prototype.hasOwnProperty.call(n,"default")?n.default:n}var Ad={exports:{}},to={};/**
|
|
2
|
+
* @license React
|
|
3
|
+
* react-jsx-runtime.production.js
|
|
4
|
+
*
|
|
5
|
+
* Copyright (c) Meta Platforms, Inc. and affiliates.
|
|
6
|
+
*
|
|
7
|
+
* This source code is licensed under the MIT license found in the
|
|
8
|
+
* LICENSE file in the root directory of this source tree.
|
|
9
|
+
*/var xg;function w_(){if(xg)return to;xg=1;var n=Symbol.for("react.transitional.element"),l=Symbol.for("react.fragment");function s(o,u,d){var h=null;if(d!==void 0&&(h=""+d),u.key!==void 0&&(h=""+u.key),"key"in u){d={};for(var p in u)p!=="key"&&(d[p]=u[p])}else d=u;return u=d.ref,{$$typeof:n,type:o,key:h,ref:u!==void 0?u:null,props:d}}return to.Fragment=l,to.jsx=s,to.jsxs=s,to}var _g;function S_(){return _g||(_g=1,Ad.exports=w_()),Ad.exports}var f=S_(),Nd={exports:{}},Ne={};/**
|
|
10
|
+
* @license React
|
|
11
|
+
* react.production.js
|
|
12
|
+
*
|
|
13
|
+
* Copyright (c) Meta Platforms, Inc. and affiliates.
|
|
14
|
+
*
|
|
15
|
+
* This source code is licensed under the MIT license found in the
|
|
16
|
+
* LICENSE file in the root directory of this source tree.
|
|
17
|
+
*/var wg;function k_(){if(wg)return Ne;wg=1;var n=Symbol.for("react.transitional.element"),l=Symbol.for("react.portal"),s=Symbol.for("react.fragment"),o=Symbol.for("react.strict_mode"),u=Symbol.for("react.profiler"),d=Symbol.for("react.consumer"),h=Symbol.for("react.context"),p=Symbol.for("react.forward_ref"),y=Symbol.for("react.suspense"),g=Symbol.for("react.memo"),x=Symbol.for("react.lazy"),v=Symbol.for("react.activity"),E=Symbol.iterator;function M(k){return k===null||typeof k!="object"?null:(k=E&&k[E]||k["@@iterator"],typeof k=="function"?k:null)}var N={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},A=Object.assign,j={};function O(k,I,$){this.props=k,this.context=I,this.refs=j,this.updater=$||N}O.prototype.isReactComponent={},O.prototype.setState=function(k,I){if(typeof k!="object"&&typeof k!="function"&&k!=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,k,I,"setState")},O.prototype.forceUpdate=function(k){this.updater.enqueueForceUpdate(this,k,"forceUpdate")};function z(){}z.prototype=O.prototype;function D(k,I,$){this.props=k,this.context=I,this.refs=j,this.updater=$||N}var Y=D.prototype=new z;Y.constructor=D,A(Y,O.prototype),Y.isPureReactComponent=!0;var W=Array.isArray;function ee(){}var ae={H:null,A:null,T:null,S:null},U=Object.prototype.hasOwnProperty;function re(k,I,$){var T=$.ref;return{$$typeof:n,type:k,key:I,ref:T!==void 0?T:null,props:$}}function de(k,I){return re(k.type,I,k.props)}function ce(k){return typeof k=="object"&&k!==null&&k.$$typeof===n}function ie(k){var I={"=":"=0",":":"=2"};return"$"+k.replace(/[=:]/g,function($){return I[$]})}var L=/\/+/g;function G(k,I){return typeof k=="object"&&k!==null&&k.key!=null?ie(""+k.key):I.toString(36)}function F(k){switch(k.status){case"fulfilled":return k.value;case"rejected":throw k.reason;default:switch(typeof k.status=="string"?k.then(ee,ee):(k.status="pending",k.then(function(I){k.status==="pending"&&(k.status="fulfilled",k.value=I)},function(I){k.status==="pending"&&(k.status="rejected",k.reason=I)})),k.status){case"fulfilled":return k.value;case"rejected":throw k.reason}}throw k}function w(k,I,$,T,B){var q=typeof k;(q==="undefined"||q==="boolean")&&(k=null);var V=!1;if(k===null)V=!0;else switch(q){case"bigint":case"string":case"number":V=!0;break;case"object":switch(k.$$typeof){case n:case l:V=!0;break;case x:return V=k._init,w(V(k._payload),I,$,T,B)}}if(V)return B=B(k),V=T===""?"."+G(k,0):T,W(B)?($="",V!=null&&($=V.replace(L,"$&/")+"/"),w(B,I,$,"",function(ke){return ke})):B!=null&&(ce(B)&&(B=de(B,$+(B.key==null||k&&k.key===B.key?"":(""+B.key).replace(L,"$&/")+"/")+V)),I.push(B)),1;V=0;var me=T===""?".":T+":";if(W(k))for(var he=0;he<k.length;he++)T=k[he],q=me+G(T,he),V+=w(T,I,$,q,B);else if(he=M(k),typeof he=="function")for(k=he.call(k),he=0;!(T=k.next()).done;)T=T.value,q=me+G(T,he++),V+=w(T,I,$,q,B);else if(q==="object"){if(typeof k.then=="function")return w(F(k),I,$,T,B);throw I=String(k),Error("Objects are not valid as a React child (found: "+(I==="[object Object]"?"object with keys {"+Object.keys(k).join(", ")+"}":I)+"). If you meant to render a collection of children, use an array instead.")}return V}function Z(k,I,$){if(k==null)return k;var T=[],B=0;return w(k,T,"","",function(q){return I.call($,q,B++)}),T}function ue(k){if(k._status===-1){var I=k._result;I=I(),I.then(function($){(k._status===0||k._status===-1)&&(k._status=1,k._result=$)},function($){(k._status===0||k._status===-1)&&(k._status=2,k._result=$)}),k._status===-1&&(k._status=0,k._result=I)}if(k._status===1)return k._result.default;throw k._result}var te=typeof reportError=="function"?reportError:function(k){if(typeof window=="object"&&typeof window.ErrorEvent=="function"){var I=new window.ErrorEvent("error",{bubbles:!0,cancelable:!0,message:typeof k=="object"&&k!==null&&typeof k.message=="string"?String(k.message):String(k),error:k});if(!window.dispatchEvent(I))return}else if(typeof process=="object"&&typeof process.emit=="function"){process.emit("uncaughtException",k);return}console.error(k)},P={map:Z,forEach:function(k,I,$){Z(k,function(){I.apply(this,arguments)},$)},count:function(k){var I=0;return Z(k,function(){I++}),I},toArray:function(k){return Z(k,function(I){return I})||[]},only:function(k){if(!ce(k))throw Error("React.Children.only expected to receive a single React element child.");return k}};return Ne.Activity=v,Ne.Children=P,Ne.Component=O,Ne.Fragment=s,Ne.Profiler=u,Ne.PureComponent=D,Ne.StrictMode=o,Ne.Suspense=y,Ne.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=ae,Ne.__COMPILER_RUNTIME={__proto__:null,c:function(k){return ae.H.useMemoCache(k)}},Ne.cache=function(k){return function(){return k.apply(null,arguments)}},Ne.cacheSignal=function(){return null},Ne.cloneElement=function(k,I,$){if(k==null)throw Error("The argument must be a React element, but you passed "+k+".");var T=A({},k.props),B=k.key;if(I!=null)for(q in I.key!==void 0&&(B=""+I.key),I)!U.call(I,q)||q==="key"||q==="__self"||q==="__source"||q==="ref"&&I.ref===void 0||(T[q]=I[q]);var q=arguments.length-2;if(q===1)T.children=$;else if(1<q){for(var V=Array(q),me=0;me<q;me++)V[me]=arguments[me+2];T.children=V}return re(k.type,B,T)},Ne.createContext=function(k){return k={$$typeof:h,_currentValue:k,_currentValue2:k,_threadCount:0,Provider:null,Consumer:null},k.Provider=k,k.Consumer={$$typeof:d,_context:k},k},Ne.createElement=function(k,I,$){var T,B={},q=null;if(I!=null)for(T in I.key!==void 0&&(q=""+I.key),I)U.call(I,T)&&T!=="key"&&T!=="__self"&&T!=="__source"&&(B[T]=I[T]);var V=arguments.length-2;if(V===1)B.children=$;else if(1<V){for(var me=Array(V),he=0;he<V;he++)me[he]=arguments[he+2];B.children=me}if(k&&k.defaultProps)for(T in V=k.defaultProps,V)B[T]===void 0&&(B[T]=V[T]);return re(k,q,B)},Ne.createRef=function(){return{current:null}},Ne.forwardRef=function(k){return{$$typeof:p,render:k}},Ne.isValidElement=ce,Ne.lazy=function(k){return{$$typeof:x,_payload:{_status:-1,_result:k},_init:ue}},Ne.memo=function(k,I){return{$$typeof:g,type:k,compare:I===void 0?null:I}},Ne.startTransition=function(k){var I=ae.T,$={};ae.T=$;try{var T=k(),B=ae.S;B!==null&&B($,T),typeof T=="object"&&T!==null&&typeof T.then=="function"&&T.then(ee,te)}catch(q){te(q)}finally{I!==null&&$.types!==null&&(I.types=$.types),ae.T=I}},Ne.unstable_useCacheRefresh=function(){return ae.H.useCacheRefresh()},Ne.use=function(k){return ae.H.use(k)},Ne.useActionState=function(k,I,$){return ae.H.useActionState(k,I,$)},Ne.useCallback=function(k,I){return ae.H.useCallback(k,I)},Ne.useContext=function(k){return ae.H.useContext(k)},Ne.useDebugValue=function(){},Ne.useDeferredValue=function(k,I){return ae.H.useDeferredValue(k,I)},Ne.useEffect=function(k,I){return ae.H.useEffect(k,I)},Ne.useEffectEvent=function(k){return ae.H.useEffectEvent(k)},Ne.useId=function(){return ae.H.useId()},Ne.useImperativeHandle=function(k,I,$){return ae.H.useImperativeHandle(k,I,$)},Ne.useInsertionEffect=function(k,I){return ae.H.useInsertionEffect(k,I)},Ne.useLayoutEffect=function(k,I){return ae.H.useLayoutEffect(k,I)},Ne.useMemo=function(k,I){return ae.H.useMemo(k,I)},Ne.useOptimistic=function(k,I){return ae.H.useOptimistic(k,I)},Ne.useReducer=function(k,I,$){return ae.H.useReducer(k,I,$)},Ne.useRef=function(k){return ae.H.useRef(k)},Ne.useState=function(k){return ae.H.useState(k)},Ne.useSyncExternalStore=function(k,I,$){return ae.H.useSyncExternalStore(k,I,$)},Ne.useTransition=function(){return ae.H.useTransition()},Ne.version="19.2.6",Ne}var Sg;function qf(){return Sg||(Sg=1,Nd.exports=k_()),Nd.exports}var _=qf();const Qr=__(_);var Td={exports:{}},no={},Od={exports:{}},Rd={};/**
|
|
18
|
+
* @license React
|
|
19
|
+
* scheduler.production.js
|
|
20
|
+
*
|
|
21
|
+
* Copyright (c) Meta Platforms, Inc. and affiliates.
|
|
22
|
+
*
|
|
23
|
+
* This source code is licensed under the MIT license found in the
|
|
24
|
+
* LICENSE file in the root directory of this source tree.
|
|
25
|
+
*/var kg;function E_(){return kg||(kg=1,(function(n){function l(w,Z){var ue=w.length;w.push(Z);e:for(;0<ue;){var te=ue-1>>>1,P=w[te];if(0<u(P,Z))w[te]=Z,w[ue]=P,ue=te;else break e}}function s(w){return w.length===0?null:w[0]}function o(w){if(w.length===0)return null;var Z=w[0],ue=w.pop();if(ue!==Z){w[0]=ue;e:for(var te=0,P=w.length,k=P>>>1;te<k;){var I=2*(te+1)-1,$=w[I],T=I+1,B=w[T];if(0>u($,ue))T<P&&0>u(B,$)?(w[te]=B,w[T]=ue,te=T):(w[te]=$,w[I]=ue,te=I);else if(T<P&&0>u(B,ue))w[te]=B,w[T]=ue,te=T;else break e}}return Z}function u(w,Z){var ue=w.sortIndex-Z.sortIndex;return ue!==0?ue:w.id-Z.id}if(n.unstable_now=void 0,typeof performance=="object"&&typeof performance.now=="function"){var d=performance;n.unstable_now=function(){return d.now()}}else{var h=Date,p=h.now();n.unstable_now=function(){return h.now()-p}}var y=[],g=[],x=1,v=null,E=3,M=!1,N=!1,A=!1,j=!1,O=typeof setTimeout=="function"?setTimeout:null,z=typeof clearTimeout=="function"?clearTimeout:null,D=typeof setImmediate<"u"?setImmediate:null;function Y(w){for(var Z=s(g);Z!==null;){if(Z.callback===null)o(g);else if(Z.startTime<=w)o(g),Z.sortIndex=Z.expirationTime,l(y,Z);else break;Z=s(g)}}function W(w){if(A=!1,Y(w),!N)if(s(y)!==null)N=!0,ee||(ee=!0,ie());else{var Z=s(g);Z!==null&&F(W,Z.startTime-w)}}var ee=!1,ae=-1,U=5,re=-1;function de(){return j?!0:!(n.unstable_now()-re<U)}function ce(){if(j=!1,ee){var w=n.unstable_now();re=w;var Z=!0;try{e:{N=!1,A&&(A=!1,z(ae),ae=-1),M=!0;var ue=E;try{t:{for(Y(w),v=s(y);v!==null&&!(v.expirationTime>w&&de());){var te=v.callback;if(typeof te=="function"){v.callback=null,E=v.priorityLevel;var P=te(v.expirationTime<=w);if(w=n.unstable_now(),typeof P=="function"){v.callback=P,Y(w),Z=!0;break t}v===s(y)&&o(y),Y(w)}else o(y);v=s(y)}if(v!==null)Z=!0;else{var k=s(g);k!==null&&F(W,k.startTime-w),Z=!1}}break e}finally{v=null,E=ue,M=!1}Z=void 0}}finally{Z?ie():ee=!1}}}var ie;if(typeof D=="function")ie=function(){D(ce)};else if(typeof MessageChannel<"u"){var L=new MessageChannel,G=L.port2;L.port1.onmessage=ce,ie=function(){G.postMessage(null)}}else ie=function(){O(ce,0)};function F(w,Z){ae=O(function(){w(n.unstable_now())},Z)}n.unstable_IdlePriority=5,n.unstable_ImmediatePriority=1,n.unstable_LowPriority=4,n.unstable_NormalPriority=3,n.unstable_Profiling=null,n.unstable_UserBlockingPriority=2,n.unstable_cancelCallback=function(w){w.callback=null},n.unstable_forceFrameRate=function(w){0>w||125<w?console.error("forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported"):U=0<w?Math.floor(1e3/w):5},n.unstable_getCurrentPriorityLevel=function(){return E},n.unstable_next=function(w){switch(E){case 1:case 2:case 3:var Z=3;break;default:Z=E}var ue=E;E=Z;try{return w()}finally{E=ue}},n.unstable_requestPaint=function(){j=!0},n.unstable_runWithPriority=function(w,Z){switch(w){case 1:case 2:case 3:case 4:case 5:break;default:w=3}var ue=E;E=w;try{return Z()}finally{E=ue}},n.unstable_scheduleCallback=function(w,Z,ue){var te=n.unstable_now();switch(typeof ue=="object"&&ue!==null?(ue=ue.delay,ue=typeof ue=="number"&&0<ue?te+ue:te):ue=te,w){case 1:var P=-1;break;case 2:P=250;break;case 5:P=1073741823;break;case 4:P=1e4;break;default:P=5e3}return P=ue+P,w={id:x++,callback:Z,priorityLevel:w,startTime:ue,expirationTime:P,sortIndex:-1},ue>te?(w.sortIndex=ue,l(g,w),s(y)===null&&w===s(g)&&(A?(z(ae),ae=-1):A=!0,F(W,ue-te))):(w.sortIndex=P,l(y,w),N||M||(N=!0,ee||(ee=!0,ie()))),w},n.unstable_shouldYield=de,n.unstable_wrapCallback=function(w){var Z=E;return function(){var ue=E;E=Z;try{return w.apply(this,arguments)}finally{E=ue}}}})(Rd)),Rd}var Eg;function j_(){return Eg||(Eg=1,Od.exports=E_()),Od.exports}var zd={exports:{}},Bt={};/**
|
|
26
|
+
* @license React
|
|
27
|
+
* react-dom.production.js
|
|
28
|
+
*
|
|
29
|
+
* Copyright (c) Meta Platforms, Inc. and affiliates.
|
|
30
|
+
*
|
|
31
|
+
* This source code is licensed under the MIT license found in the
|
|
32
|
+
* LICENSE file in the root directory of this source tree.
|
|
33
|
+
*/var jg;function M_(){if(jg)return Bt;jg=1;var n=qf();function l(y){var g="https://react.dev/errors/"+y;if(1<arguments.length){g+="?args[]="+encodeURIComponent(arguments[1]);for(var x=2;x<arguments.length;x++)g+="&args[]="+encodeURIComponent(arguments[x])}return"Minified React error #"+y+"; visit "+g+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}function s(){}var o={d:{f:s,r:function(){throw Error(l(522))},D:s,C:s,L:s,m:s,X:s,S:s,M:s},p:0,findDOMNode:null},u=Symbol.for("react.portal");function d(y,g,x){var v=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:u,key:v==null?null:""+v,children:y,containerInfo:g,implementation:x}}var h=n.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE;function p(y,g){if(y==="font")return"";if(typeof g=="string")return g==="use-credentials"?g:""}return Bt.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=o,Bt.createPortal=function(y,g){var x=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!g||g.nodeType!==1&&g.nodeType!==9&&g.nodeType!==11)throw Error(l(299));return d(y,g,null,x)},Bt.flushSync=function(y){var g=h.T,x=o.p;try{if(h.T=null,o.p=2,y)return y()}finally{h.T=g,o.p=x,o.d.f()}},Bt.preconnect=function(y,g){typeof y=="string"&&(g?(g=g.crossOrigin,g=typeof g=="string"?g==="use-credentials"?g:"":void 0):g=null,o.d.C(y,g))},Bt.prefetchDNS=function(y){typeof y=="string"&&o.d.D(y)},Bt.preinit=function(y,g){if(typeof y=="string"&&g&&typeof g.as=="string"){var x=g.as,v=p(x,g.crossOrigin),E=typeof g.integrity=="string"?g.integrity:void 0,M=typeof g.fetchPriority=="string"?g.fetchPriority:void 0;x==="style"?o.d.S(y,typeof g.precedence=="string"?g.precedence:void 0,{crossOrigin:v,integrity:E,fetchPriority:M}):x==="script"&&o.d.X(y,{crossOrigin:v,integrity:E,fetchPriority:M,nonce:typeof g.nonce=="string"?g.nonce:void 0})}},Bt.preinitModule=function(y,g){if(typeof y=="string")if(typeof g=="object"&&g!==null){if(g.as==null||g.as==="script"){var x=p(g.as,g.crossOrigin);o.d.M(y,{crossOrigin:x,integrity:typeof g.integrity=="string"?g.integrity:void 0,nonce:typeof g.nonce=="string"?g.nonce:void 0})}}else g==null&&o.d.M(y)},Bt.preload=function(y,g){if(typeof y=="string"&&typeof g=="object"&&g!==null&&typeof g.as=="string"){var x=g.as,v=p(x,g.crossOrigin);o.d.L(y,x,{crossOrigin:v,integrity:typeof g.integrity=="string"?g.integrity:void 0,nonce:typeof g.nonce=="string"?g.nonce:void 0,type:typeof g.type=="string"?g.type:void 0,fetchPriority:typeof g.fetchPriority=="string"?g.fetchPriority:void 0,referrerPolicy:typeof g.referrerPolicy=="string"?g.referrerPolicy:void 0,imageSrcSet:typeof g.imageSrcSet=="string"?g.imageSrcSet:void 0,imageSizes:typeof g.imageSizes=="string"?g.imageSizes:void 0,media:typeof g.media=="string"?g.media:void 0})}},Bt.preloadModule=function(y,g){if(typeof y=="string")if(g){var x=p(g.as,g.crossOrigin);o.d.m(y,{as:typeof g.as=="string"&&g.as!=="script"?g.as:void 0,crossOrigin:x,integrity:typeof g.integrity=="string"?g.integrity:void 0})}else o.d.m(y)},Bt.requestFormReset=function(y){o.d.r(y)},Bt.unstable_batchedUpdates=function(y,g){return y(g)},Bt.useFormState=function(y,g,x){return h.H.useFormState(y,g,x)},Bt.useFormStatus=function(){return h.H.useHostTransitionStatus()},Bt.version="19.2.6",Bt}var Mg;function x0(){if(Mg)return zd.exports;Mg=1;function n(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(n)}catch(l){console.error(l)}}return n(),zd.exports=M_(),zd.exports}/**
|
|
34
|
+
* @license React
|
|
35
|
+
* react-dom-client.production.js
|
|
36
|
+
*
|
|
37
|
+
* Copyright (c) Meta Platforms, Inc. and affiliates.
|
|
38
|
+
*
|
|
39
|
+
* This source code is licensed under the MIT license found in the
|
|
40
|
+
* LICENSE file in the root directory of this source tree.
|
|
41
|
+
*/var Cg;function C_(){if(Cg)return no;Cg=1;var n=j_(),l=qf(),s=x0();function o(e){var t="https://react.dev/errors/"+e;if(1<arguments.length){t+="?args[]="+encodeURIComponent(arguments[1]);for(var a=2;a<arguments.length;a++)t+="&args[]="+encodeURIComponent(arguments[a])}return"Minified React error #"+e+"; visit "+t+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}function u(e){return!(!e||e.nodeType!==1&&e.nodeType!==9&&e.nodeType!==11)}function d(e){var t=e,a=e;if(e.alternate)for(;t.return;)t=t.return;else{e=t;do t=e,(t.flags&4098)!==0&&(a=t.return),e=t.return;while(e)}return t.tag===3?a:null}function h(e){if(e.tag===13){var t=e.memoizedState;if(t===null&&(e=e.alternate,e!==null&&(t=e.memoizedState)),t!==null)return t.dehydrated}return null}function p(e){if(e.tag===31){var t=e.memoizedState;if(t===null&&(e=e.alternate,e!==null&&(t=e.memoizedState)),t!==null)return t.dehydrated}return null}function y(e){if(d(e)!==e)throw Error(o(188))}function g(e){var t=e.alternate;if(!t){if(t=d(e),t===null)throw Error(o(188));return t!==e?null:e}for(var a=e,i=t;;){var r=a.return;if(r===null)break;var c=r.alternate;if(c===null){if(i=r.return,i!==null){a=i;continue}break}if(r.child===c.child){for(c=r.child;c;){if(c===a)return y(r),e;if(c===i)return y(r),t;c=c.sibling}throw Error(o(188))}if(a.return!==i.return)a=r,i=c;else{for(var m=!1,b=r.child;b;){if(b===a){m=!0,a=r,i=c;break}if(b===i){m=!0,i=r,a=c;break}b=b.sibling}if(!m){for(b=c.child;b;){if(b===a){m=!0,a=c,i=r;break}if(b===i){m=!0,i=c,a=r;break}b=b.sibling}if(!m)throw Error(o(189))}}if(a.alternate!==i)throw Error(o(190))}if(a.tag!==3)throw Error(o(188));return a.stateNode.current===a?e:t}function x(e){var t=e.tag;if(t===5||t===26||t===27||t===6)return e;for(e=e.child;e!==null;){if(t=x(e),t!==null)return t;e=e.sibling}return null}var v=Object.assign,E=Symbol.for("react.element"),M=Symbol.for("react.transitional.element"),N=Symbol.for("react.portal"),A=Symbol.for("react.fragment"),j=Symbol.for("react.strict_mode"),O=Symbol.for("react.profiler"),z=Symbol.for("react.consumer"),D=Symbol.for("react.context"),Y=Symbol.for("react.forward_ref"),W=Symbol.for("react.suspense"),ee=Symbol.for("react.suspense_list"),ae=Symbol.for("react.memo"),U=Symbol.for("react.lazy"),re=Symbol.for("react.activity"),de=Symbol.for("react.memo_cache_sentinel"),ce=Symbol.iterator;function ie(e){return e===null||typeof e!="object"?null:(e=ce&&e[ce]||e["@@iterator"],typeof e=="function"?e:null)}var L=Symbol.for("react.client.reference");function G(e){if(e==null)return null;if(typeof e=="function")return e.$$typeof===L?null:e.displayName||e.name||null;if(typeof e=="string")return e;switch(e){case A:return"Fragment";case O:return"Profiler";case j:return"StrictMode";case W:return"Suspense";case ee:return"SuspenseList";case re:return"Activity"}if(typeof e=="object")switch(e.$$typeof){case N:return"Portal";case D:return e.displayName||"Context";case z:return(e._context.displayName||"Context")+".Consumer";case Y:var t=e.render;return e=e.displayName,e||(e=t.displayName||t.name||"",e=e!==""?"ForwardRef("+e+")":"ForwardRef"),e;case ae:return t=e.displayName||null,t!==null?t:G(e.type)||"Memo";case U:t=e._payload,e=e._init;try{return G(e(t))}catch{}}return null}var F=Array.isArray,w=l.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,Z=s.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,ue={pending:!1,data:null,method:null,action:null},te=[],P=-1;function k(e){return{current:e}}function I(e){0>P||(e.current=te[P],te[P]=null,P--)}function $(e,t){P++,te[P]=e.current,e.current=t}var T=k(null),B=k(null),q=k(null),V=k(null);function me(e,t){switch($(q,t),$(B,e),$(T,null),t.nodeType){case 9:case 11:e=(e=t.documentElement)&&(e=e.namespaceURI)?Iy(e):0;break;default:if(e=t.tagName,t=t.namespaceURI)t=Iy(t),e=Qy(t,e);else switch(e){case"svg":e=1;break;case"math":e=2;break;default:e=0}}I(T),$(T,e)}function he(){I(T),I(B),I(q)}function ke(e){e.memoizedState!==null&&$(V,e);var t=T.current,a=Qy(t,e.type);t!==a&&($(B,e),$(T,a))}function Ae(e){B.current===e&&(I(T),I(B)),V.current===e&&(I(V),Ps._currentValue=ue)}var Ue,nt;function Ve(e){if(Ue===void 0)try{throw Error()}catch(a){var t=a.stack.trim().match(/\n( *(at )?)/);Ue=t&&t[1]||"",nt=-1<a.stack.indexOf(`
|
|
42
|
+
at`)?" (<anonymous>)":-1<a.stack.indexOf("@")?"@unknown:0:0":""}return`
|
|
43
|
+
`+Ue+e+nt}var Oe=!1;function hn(e,t){if(!e||Oe)return"";Oe=!0;var a=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{var i={DetermineComponentFrameRoot:function(){try{if(t){var oe=function(){throw Error()};if(Object.defineProperty(oe.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(oe,[])}catch(J){var X=J}Reflect.construct(e,[],oe)}else{try{oe.call()}catch(J){X=J}e.call(oe.prototype)}}else{try{throw Error()}catch(J){X=J}(oe=e())&&typeof oe.catch=="function"&&oe.catch(function(){})}}catch(J){if(J&&X&&typeof J.stack=="string")return[J.stack,X.stack]}return[null,null]}};i.DetermineComponentFrameRoot.displayName="DetermineComponentFrameRoot";var r=Object.getOwnPropertyDescriptor(i.DetermineComponentFrameRoot,"name");r&&r.configurable&&Object.defineProperty(i.DetermineComponentFrameRoot,"name",{value:"DetermineComponentFrameRoot"});var c=i.DetermineComponentFrameRoot(),m=c[0],b=c[1];if(m&&b){var C=m.split(`
|
|
44
|
+
`),K=b.split(`
|
|
45
|
+
`);for(r=i=0;i<C.length&&!C[i].includes("DetermineComponentFrameRoot");)i++;for(;r<K.length&&!K[r].includes("DetermineComponentFrameRoot");)r++;if(i===C.length||r===K.length)for(i=C.length-1,r=K.length-1;1<=i&&0<=r&&C[i]!==K[r];)r--;for(;1<=i&&0<=r;i--,r--)if(C[i]!==K[r]){if(i!==1||r!==1)do if(i--,r--,0>r||C[i]!==K[r]){var le=`
|
|
46
|
+
`+C[i].replace(" at new "," at ");return e.displayName&&le.includes("<anonymous>")&&(le=le.replace("<anonymous>",e.displayName)),le}while(1<=i&&0<=r);break}}}finally{Oe=!1,Error.prepareStackTrace=a}return(a=e?e.displayName||e.name:"")?Ve(a):""}function Eo(e,t){switch(e.tag){case 26:case 27:case 5:return Ve(e.type);case 16:return Ve("Lazy");case 13:return e.child!==t&&t!==null?Ve("Suspense Fallback"):Ve("Suspense");case 19:return Ve("SuspenseList");case 0:case 15:return hn(e.type,!1);case 11:return hn(e.type.render,!1);case 1:return hn(e.type,!0);case 31:return Ve("Activity");default:return""}}function jo(e){try{var t="",a=null;do t+=Eo(e,a),a=e,e=e.return;while(e);return t}catch(i){return`
|
|
47
|
+
Error generating stack: `+i.message+`
|
|
48
|
+
`+i.stack}}var ti=Object.prototype.hasOwnProperty,ni=n.unstable_scheduleCallback,ai=n.unstable_cancelCallback,dl=n.unstable_shouldYield,On=n.unstable_requestPaint,rt=n.unstable_now,Mo=n.unstable_getCurrentPriorityLevel,ds=n.unstable_ImmediatePriority,li=n.unstable_UserBlockingPriority,fl=n.unstable_NormalPriority,ii=n.unstable_LowPriority,it=n.unstable_IdlePriority,hl=n.log,Co=n.unstable_setDisableYieldValue,xa=null,zt=null;function ne(e){if(typeof hl=="function"&&Co(e),zt&&typeof zt.setStrictMode=="function")try{zt.setStrictMode(xa,e)}catch{}}var pe=Math.clz32?Math.clz32:Be,Se=Math.log,Me=Math.LN2;function Be(e){return e>>>=0,e===0?32:31-(Se(e)/Me|0)|0}var Te=256,pt=262144,mt=4194304;function ct(e){var t=e&42;if(t!==0)return t;switch(e&-e){case 1:return 1;case 2:return 2;case 4:return 4;case 8:return 8;case 16:return 16;case 32:return 32;case 64:return 64;case 128:return 128;case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:return e&261888;case 262144:case 524288:case 1048576:case 2097152:return e&3932160;case 4194304:case 8388608:case 16777216:case 33554432:return e&62914560;case 67108864:return 67108864;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 0;default:return e}}function Dt(e,t,a){var i=e.pendingLanes;if(i===0)return 0;var r=0,c=e.suspendedLanes,m=e.pingedLanes;e=e.warmLanes;var b=i&134217727;return b!==0?(i=b&~c,i!==0?r=ct(i):(m&=b,m!==0?r=ct(m):a||(a=b&~e,a!==0&&(r=ct(a))))):(b=i&~c,b!==0?r=ct(b):m!==0?r=ct(m):a||(a=i&~e,a!==0&&(r=ct(a)))),r===0?0:t!==0&&t!==r&&(t&c)===0&&(c=r&-r,a=t&-t,c>=a||c===32&&(a&4194048)!==0)?t:r}function Ut(e,t){return(e.pendingLanes&~(e.suspendedLanes&~e.pingedLanes)&t)===0}function Lt(e,t){switch(e){case 1:case 2:case 4:case 8:case 64:return t+250;case 16:case 32:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return t+5e3;case 4194304:case 8388608:case 16777216:case 33554432:return-1;case 67108864:case 134217728:case 268435456:case 536870912:case 1073741824:return-1;default:return-1}}function jn(){var e=mt;return mt<<=1,(mt&62914560)===0&&(mt=4194304),e}function pl(e){for(var t=[],a=0;31>a;a++)t.push(e);return t}function _a(e,t){e.pendingLanes|=t,t!==268435456&&(e.suspendedLanes=0,e.pingedLanes=0,e.warmLanes=0)}function wa(e,t,a,i,r,c){var m=e.pendingLanes;e.pendingLanes=a,e.suspendedLanes=0,e.pingedLanes=0,e.warmLanes=0,e.expiredLanes&=a,e.entangledLanes&=a,e.errorRecoveryDisabledLanes&=a,e.shellSuspendCounter=0;var b=e.entanglements,C=e.expirationTimes,K=e.hiddenUpdates;for(a=m&~a;0<a;){var le=31-pe(a),oe=1<<le;b[le]=0,C[le]=-1;var X=K[le];if(X!==null)for(K[le]=null,le=0;le<X.length;le++){var J=X[le];J!==null&&(J.lane&=-536870913)}a&=~oe}i!==0&&Ao(e,i,0),c!==0&&r===0&&e.tag!==0&&(e.suspendedLanes|=c&~(m&~t))}function Ao(e,t,a){e.pendingLanes|=t,e.suspendedLanes&=~t;var i=31-pe(t);e.entangledLanes|=t,e.entanglements[i]=e.entanglements[i]|1073741824|a&261930}function Eh(e,t){var a=e.entangledLanes|=t;for(e=e.entanglements;a;){var i=31-pe(a),r=1<<i;r&t|e[i]&t&&(e[i]|=t),a&=~r}}function jh(e,t){var a=t&-t;return a=(a&42)!==0?1:gc(a),(a&(e.suspendedLanes|t))!==0?0:a}function gc(e){switch(e){case 2:e=1;break;case 8:e=4;break;case 32:e=16;break;case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:case 4194304:case 8388608:case 16777216:case 33554432:e=128;break;case 268435456:e=134217728;break;default:e=0}return e}function bc(e){return e&=-e,2<e?8<e?(e&134217727)!==0?32:268435456:8:2}function Mh(){var e=Z.p;return e!==0?e:(e=window.event,e===void 0?32:fg(e.type))}function Ch(e,t){var a=Z.p;try{return Z.p=e,t()}finally{Z.p=a}}var Sa=Math.random().toString(36).slice(2),Ct="__reactFiber$"+Sa,Kt="__reactProps$"+Sa,si="__reactContainer$"+Sa,vc="__reactEvents$"+Sa,ux="__reactListeners$"+Sa,dx="__reactHandles$"+Sa,Ah="__reactResources$"+Sa,fs="__reactMarker$"+Sa;function xc(e){delete e[Ct],delete e[Kt],delete e[vc],delete e[ux],delete e[dx]}function oi(e){var t=e[Ct];if(t)return t;for(var a=e.parentNode;a;){if(t=a[si]||a[Ct]){if(a=t.alternate,t.child!==null||a!==null&&a.child!==null)for(e=Zy(e);e!==null;){if(a=e[Ct])return a;e=Zy(e)}return t}e=a,a=e.parentNode}return null}function ri(e){if(e=e[Ct]||e[si]){var t=e.tag;if(t===5||t===6||t===13||t===31||t===26||t===27||t===3)return e}return null}function hs(e){var t=e.tag;if(t===5||t===26||t===27||t===6)return e.stateNode;throw Error(o(33))}function ci(e){var t=e[Ah];return t||(t=e[Ah]={hoistableStyles:new Map,hoistableScripts:new Map}),t}function Et(e){e[fs]=!0}var Nh=new Set,Th={};function ml(e,t){ui(e,t),ui(e+"Capture",t)}function ui(e,t){for(Th[e]=t,e=0;e<t.length;e++)Nh.add(t[e])}var fx=RegExp("^[:A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD][:A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD\\-.0-9\\u00B7\\u0300-\\u036F\\u203F-\\u2040]*$"),Oh={},Rh={};function hx(e){return ti.call(Rh,e)?!0:ti.call(Oh,e)?!1:fx.test(e)?Rh[e]=!0:(Oh[e]=!0,!1)}function No(e,t,a){if(hx(t))if(a===null)e.removeAttribute(t);else{switch(typeof a){case"undefined":case"function":case"symbol":e.removeAttribute(t);return;case"boolean":var i=t.toLowerCase().slice(0,5);if(i!=="data-"&&i!=="aria-"){e.removeAttribute(t);return}}e.setAttribute(t,""+a)}}function To(e,t,a){if(a===null)e.removeAttribute(t);else{switch(typeof a){case"undefined":case"function":case"symbol":case"boolean":e.removeAttribute(t);return}e.setAttribute(t,""+a)}}function Yn(e,t,a,i){if(i===null)e.removeAttribute(a);else{switch(typeof i){case"undefined":case"function":case"symbol":case"boolean":e.removeAttribute(a);return}e.setAttributeNS(t,a,""+i)}}function pn(e){switch(typeof e){case"bigint":case"boolean":case"number":case"string":case"undefined":return e;case"object":return e;default:return""}}function zh(e){var t=e.type;return(e=e.nodeName)&&e.toLowerCase()==="input"&&(t==="checkbox"||t==="radio")}function px(e,t,a){var i=Object.getOwnPropertyDescriptor(e.constructor.prototype,t);if(!e.hasOwnProperty(t)&&typeof i<"u"&&typeof i.get=="function"&&typeof i.set=="function"){var r=i.get,c=i.set;return Object.defineProperty(e,t,{configurable:!0,get:function(){return r.call(this)},set:function(m){a=""+m,c.call(this,m)}}),Object.defineProperty(e,t,{enumerable:i.enumerable}),{getValue:function(){return a},setValue:function(m){a=""+m},stopTracking:function(){e._valueTracker=null,delete e[t]}}}}function _c(e){if(!e._valueTracker){var t=zh(e)?"checked":"value";e._valueTracker=px(e,t,""+e[t])}}function Dh(e){if(!e)return!1;var t=e._valueTracker;if(!t)return!0;var a=t.getValue(),i="";return e&&(i=zh(e)?e.checked?"true":"false":e.value),e=i,e!==a?(t.setValue(e),!0):!1}function Oo(e){if(e=e||(typeof document<"u"?document:void 0),typeof e>"u")return null;try{return e.activeElement||e.body}catch{return e.body}}var mx=/[\n"\\]/g;function mn(e){return e.replace(mx,function(t){return"\\"+t.charCodeAt(0).toString(16)+" "})}function wc(e,t,a,i,r,c,m,b){e.name="",m!=null&&typeof m!="function"&&typeof m!="symbol"&&typeof m!="boolean"?e.type=m:e.removeAttribute("type"),t!=null?m==="number"?(t===0&&e.value===""||e.value!=t)&&(e.value=""+pn(t)):e.value!==""+pn(t)&&(e.value=""+pn(t)):m!=="submit"&&m!=="reset"||e.removeAttribute("value"),t!=null?Sc(e,m,pn(t)):a!=null?Sc(e,m,pn(a)):i!=null&&e.removeAttribute("value"),r==null&&c!=null&&(e.defaultChecked=!!c),r!=null&&(e.checked=r&&typeof r!="function"&&typeof r!="symbol"),b!=null&&typeof b!="function"&&typeof b!="symbol"&&typeof b!="boolean"?e.name=""+pn(b):e.removeAttribute("name")}function Uh(e,t,a,i,r,c,m,b){if(c!=null&&typeof c!="function"&&typeof c!="symbol"&&typeof c!="boolean"&&(e.type=c),t!=null||a!=null){if(!(c!=="submit"&&c!=="reset"||t!=null)){_c(e);return}a=a!=null?""+pn(a):"",t=t!=null?""+pn(t):a,b||t===e.value||(e.value=t),e.defaultValue=t}i=i??r,i=typeof i!="function"&&typeof i!="symbol"&&!!i,e.checked=b?e.checked:!!i,e.defaultChecked=!!i,m!=null&&typeof m!="function"&&typeof m!="symbol"&&typeof m!="boolean"&&(e.name=m),_c(e)}function Sc(e,t,a){t==="number"&&Oo(e.ownerDocument)===e||e.defaultValue===""+a||(e.defaultValue=""+a)}function di(e,t,a,i){if(e=e.options,t){t={};for(var r=0;r<a.length;r++)t["$"+a[r]]=!0;for(a=0;a<e.length;a++)r=t.hasOwnProperty("$"+e[a].value),e[a].selected!==r&&(e[a].selected=r),r&&i&&(e[a].defaultSelected=!0)}else{for(a=""+pn(a),t=null,r=0;r<e.length;r++){if(e[r].value===a){e[r].selected=!0,i&&(e[r].defaultSelected=!0);return}t!==null||e[r].disabled||(t=e[r])}t!==null&&(t.selected=!0)}}function Lh(e,t,a){if(t!=null&&(t=""+pn(t),t!==e.value&&(e.value=t),a==null)){e.defaultValue!==t&&(e.defaultValue=t);return}e.defaultValue=a!=null?""+pn(a):""}function Bh(e,t,a,i){if(t==null){if(i!=null){if(a!=null)throw Error(o(92));if(F(i)){if(1<i.length)throw Error(o(93));i=i[0]}a=i}a==null&&(a=""),t=a}a=pn(t),e.defaultValue=a,i=e.textContent,i===a&&i!==""&&i!==null&&(e.value=i),_c(e)}function fi(e,t){if(t){var a=e.firstChild;if(a&&a===e.lastChild&&a.nodeType===3){a.nodeValue=t;return}}e.textContent=t}var yx=new Set("animationIterationCount aspectRatio borderImageOutset borderImageSlice borderImageWidth boxFlex boxFlexGroup boxOrdinalGroup columnCount columns flex flexGrow flexPositive flexShrink flexNegative flexOrder gridArea gridRow gridRowEnd gridRowSpan gridRowStart gridColumn gridColumnEnd gridColumnSpan gridColumnStart fontWeight lineClamp lineHeight opacity order orphans scale tabSize widows zIndex zoom fillOpacity floodOpacity stopOpacity strokeDasharray strokeDashoffset strokeMiterlimit strokeOpacity strokeWidth MozAnimationIterationCount MozBoxFlex MozBoxFlexGroup MozLineClamp msAnimationIterationCount msFlex msZoom msFlexGrow msFlexNegative msFlexOrder msFlexPositive msFlexShrink msGridColumn msGridColumnSpan msGridRow msGridRowSpan WebkitAnimationIterationCount WebkitBoxFlex WebKitBoxFlexGroup WebkitBoxOrdinalGroup WebkitColumnCount WebkitColumns WebkitFlex WebkitFlexGrow WebkitFlexPositive WebkitFlexShrink WebkitLineClamp".split(" "));function Hh(e,t,a){var i=t.indexOf("--")===0;a==null||typeof a=="boolean"||a===""?i?e.setProperty(t,""):t==="float"?e.cssFloat="":e[t]="":i?e.setProperty(t,a):typeof a!="number"||a===0||yx.has(t)?t==="float"?e.cssFloat=a:e[t]=(""+a).trim():e[t]=a+"px"}function qh(e,t,a){if(t!=null&&typeof t!="object")throw Error(o(62));if(e=e.style,a!=null){for(var i in a)!a.hasOwnProperty(i)||t!=null&&t.hasOwnProperty(i)||(i.indexOf("--")===0?e.setProperty(i,""):i==="float"?e.cssFloat="":e[i]="");for(var r in t)i=t[r],t.hasOwnProperty(r)&&a[r]!==i&&Hh(e,r,i)}else for(var c in t)t.hasOwnProperty(c)&&Hh(e,c,t[c])}function kc(e){if(e.indexOf("-")===-1)return!1;switch(e){case"annotation-xml":case"color-profile":case"font-face":case"font-face-src":case"font-face-uri":case"font-face-format":case"font-face-name":case"missing-glyph":return!1;default:return!0}}var gx=new Map([["acceptCharset","accept-charset"],["htmlFor","for"],["httpEquiv","http-equiv"],["crossOrigin","crossorigin"],["accentHeight","accent-height"],["alignmentBaseline","alignment-baseline"],["arabicForm","arabic-form"],["baselineShift","baseline-shift"],["capHeight","cap-height"],["clipPath","clip-path"],["clipRule","clip-rule"],["colorInterpolation","color-interpolation"],["colorInterpolationFilters","color-interpolation-filters"],["colorProfile","color-profile"],["colorRendering","color-rendering"],["dominantBaseline","dominant-baseline"],["enableBackground","enable-background"],["fillOpacity","fill-opacity"],["fillRule","fill-rule"],["floodColor","flood-color"],["floodOpacity","flood-opacity"],["fontFamily","font-family"],["fontSize","font-size"],["fontSizeAdjust","font-size-adjust"],["fontStretch","font-stretch"],["fontStyle","font-style"],["fontVariant","font-variant"],["fontWeight","font-weight"],["glyphName","glyph-name"],["glyphOrientationHorizontal","glyph-orientation-horizontal"],["glyphOrientationVertical","glyph-orientation-vertical"],["horizAdvX","horiz-adv-x"],["horizOriginX","horiz-origin-x"],["imageRendering","image-rendering"],["letterSpacing","letter-spacing"],["lightingColor","lighting-color"],["markerEnd","marker-end"],["markerMid","marker-mid"],["markerStart","marker-start"],["overlinePosition","overline-position"],["overlineThickness","overline-thickness"],["paintOrder","paint-order"],["panose-1","panose-1"],["pointerEvents","pointer-events"],["renderingIntent","rendering-intent"],["shapeRendering","shape-rendering"],["stopColor","stop-color"],["stopOpacity","stop-opacity"],["strikethroughPosition","strikethrough-position"],["strikethroughThickness","strikethrough-thickness"],["strokeDasharray","stroke-dasharray"],["strokeDashoffset","stroke-dashoffset"],["strokeLinecap","stroke-linecap"],["strokeLinejoin","stroke-linejoin"],["strokeMiterlimit","stroke-miterlimit"],["strokeOpacity","stroke-opacity"],["strokeWidth","stroke-width"],["textAnchor","text-anchor"],["textDecoration","text-decoration"],["textRendering","text-rendering"],["transformOrigin","transform-origin"],["underlinePosition","underline-position"],["underlineThickness","underline-thickness"],["unicodeBidi","unicode-bidi"],["unicodeRange","unicode-range"],["unitsPerEm","units-per-em"],["vAlphabetic","v-alphabetic"],["vHanging","v-hanging"],["vIdeographic","v-ideographic"],["vMathematical","v-mathematical"],["vectorEffect","vector-effect"],["vertAdvY","vert-adv-y"],["vertOriginX","vert-origin-x"],["vertOriginY","vert-origin-y"],["wordSpacing","word-spacing"],["writingMode","writing-mode"],["xmlnsXlink","xmlns:xlink"],["xHeight","x-height"]]),bx=/^[\u0000-\u001F ]*j[\r\n\t]*a[\r\n\t]*v[\r\n\t]*a[\r\n\t]*s[\r\n\t]*c[\r\n\t]*r[\r\n\t]*i[\r\n\t]*p[\r\n\t]*t[\r\n\t]*:/i;function Ro(e){return bx.test(""+e)?"javascript:throw new Error('React has blocked a javascript: URL as a security precaution.')":e}function $n(){}var Ec=null;function jc(e){return e=e.target||e.srcElement||window,e.correspondingUseElement&&(e=e.correspondingUseElement),e.nodeType===3?e.parentNode:e}var hi=null,pi=null;function Gh(e){var t=ri(e);if(t&&(e=t.stateNode)){var a=e[Kt]||null;e:switch(e=t.stateNode,t.type){case"input":if(wc(e,a.value,a.defaultValue,a.defaultValue,a.checked,a.defaultChecked,a.type,a.name),t=a.name,a.type==="radio"&&t!=null){for(a=e;a.parentNode;)a=a.parentNode;for(a=a.querySelectorAll('input[name="'+mn(""+t)+'"][type="radio"]'),t=0;t<a.length;t++){var i=a[t];if(i!==e&&i.form===e.form){var r=i[Kt]||null;if(!r)throw Error(o(90));wc(i,r.value,r.defaultValue,r.defaultValue,r.checked,r.defaultChecked,r.type,r.name)}}for(t=0;t<a.length;t++)i=a[t],i.form===e.form&&Dh(i)}break e;case"textarea":Lh(e,a.value,a.defaultValue);break e;case"select":t=a.value,t!=null&&di(e,!!a.multiple,t,!1)}}}var Mc=!1;function Ih(e,t,a){if(Mc)return e(t,a);Mc=!0;try{var i=e(t);return i}finally{if(Mc=!1,(hi!==null||pi!==null)&&(xr(),hi&&(t=hi,e=pi,pi=hi=null,Gh(t),e)))for(t=0;t<e.length;t++)Gh(e[t])}}function ps(e,t){var a=e.stateNode;if(a===null)return null;var i=a[Kt]||null;if(i===null)return null;a=i[t];e:switch(t){case"onClick":case"onClickCapture":case"onDoubleClick":case"onDoubleClickCapture":case"onMouseDown":case"onMouseDownCapture":case"onMouseMove":case"onMouseMoveCapture":case"onMouseUp":case"onMouseUpCapture":case"onMouseEnter":(i=!i.disabled)||(e=e.type,i=!(e==="button"||e==="input"||e==="select"||e==="textarea")),e=!i;break e;default:e=!1}if(e)return null;if(a&&typeof a!="function")throw Error(o(231,t,typeof a));return a}var Fn=!(typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),Cc=!1;if(Fn)try{var ms={};Object.defineProperty(ms,"passive",{get:function(){Cc=!0}}),window.addEventListener("test",ms,ms),window.removeEventListener("test",ms,ms)}catch{Cc=!1}var ka=null,Ac=null,zo=null;function Qh(){if(zo)return zo;var e,t=Ac,a=t.length,i,r="value"in ka?ka.value:ka.textContent,c=r.length;for(e=0;e<a&&t[e]===r[e];e++);var m=a-e;for(i=1;i<=m&&t[a-i]===r[c-i];i++);return zo=r.slice(e,1<i?1-i:void 0)}function Do(e){var t=e.keyCode;return"charCode"in e?(e=e.charCode,e===0&&t===13&&(e=13)):e=t,e===10&&(e=13),32<=e||e===13?e:0}function Uo(){return!0}function Kh(){return!1}function Vt(e){function t(a,i,r,c,m){this._reactName=a,this._targetInst=r,this.type=i,this.nativeEvent=c,this.target=m,this.currentTarget=null;for(var b in e)e.hasOwnProperty(b)&&(a=e[b],this[b]=a?a(c):c[b]);return this.isDefaultPrevented=(c.defaultPrevented!=null?c.defaultPrevented:c.returnValue===!1)?Uo:Kh,this.isPropagationStopped=Kh,this}return v(t.prototype,{preventDefault:function(){this.defaultPrevented=!0;var a=this.nativeEvent;a&&(a.preventDefault?a.preventDefault():typeof a.returnValue!="unknown"&&(a.returnValue=!1),this.isDefaultPrevented=Uo)},stopPropagation:function(){var a=this.nativeEvent;a&&(a.stopPropagation?a.stopPropagation():typeof a.cancelBubble!="unknown"&&(a.cancelBubble=!0),this.isPropagationStopped=Uo)},persist:function(){},isPersistent:Uo}),t}var yl={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(e){return e.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},Lo=Vt(yl),ys=v({},yl,{view:0,detail:0}),vx=Vt(ys),Nc,Tc,gs,Bo=v({},ys,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:Rc,button:0,buttons:0,relatedTarget:function(e){return e.relatedTarget===void 0?e.fromElement===e.srcElement?e.toElement:e.fromElement:e.relatedTarget},movementX:function(e){return"movementX"in e?e.movementX:(e!==gs&&(gs&&e.type==="mousemove"?(Nc=e.screenX-gs.screenX,Tc=e.screenY-gs.screenY):Tc=Nc=0,gs=e),Nc)},movementY:function(e){return"movementY"in e?e.movementY:Tc}}),Vh=Vt(Bo),xx=v({},Bo,{dataTransfer:0}),_x=Vt(xx),wx=v({},ys,{relatedTarget:0}),Oc=Vt(wx),Sx=v({},yl,{animationName:0,elapsedTime:0,pseudoElement:0}),kx=Vt(Sx),Ex=v({},yl,{clipboardData:function(e){return"clipboardData"in e?e.clipboardData:window.clipboardData}}),jx=Vt(Ex),Mx=v({},yl,{data:0}),Yh=Vt(Mx),Cx={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},Ax={8:"Backspace",9:"Tab",12:"Clear",13:"Enter",16:"Shift",17:"Control",18:"Alt",19:"Pause",20:"CapsLock",27:"Escape",32:" ",33:"PageUp",34:"PageDown",35:"End",36:"Home",37:"ArrowLeft",38:"ArrowUp",39:"ArrowRight",40:"ArrowDown",45:"Insert",46:"Delete",112:"F1",113:"F2",114:"F3",115:"F4",116:"F5",117:"F6",118:"F7",119:"F8",120:"F9",121:"F10",122:"F11",123:"F12",144:"NumLock",145:"ScrollLock",224:"Meta"},Nx={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function Tx(e){var t=this.nativeEvent;return t.getModifierState?t.getModifierState(e):(e=Nx[e])?!!t[e]:!1}function Rc(){return Tx}var Ox=v({},ys,{key:function(e){if(e.key){var t=Cx[e.key]||e.key;if(t!=="Unidentified")return t}return e.type==="keypress"?(e=Do(e),e===13?"Enter":String.fromCharCode(e)):e.type==="keydown"||e.type==="keyup"?Ax[e.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:Rc,charCode:function(e){return e.type==="keypress"?Do(e):0},keyCode:function(e){return e.type==="keydown"||e.type==="keyup"?e.keyCode:0},which:function(e){return e.type==="keypress"?Do(e):e.type==="keydown"||e.type==="keyup"?e.keyCode:0}}),Rx=Vt(Ox),zx=v({},Bo,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0}),$h=Vt(zx),Dx=v({},ys,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:Rc}),Ux=Vt(Dx),Lx=v({},yl,{propertyName:0,elapsedTime:0,pseudoElement:0}),Bx=Vt(Lx),Hx=v({},Bo,{deltaX:function(e){return"deltaX"in e?e.deltaX:"wheelDeltaX"in e?-e.wheelDeltaX:0},deltaY:function(e){return"deltaY"in e?e.deltaY:"wheelDeltaY"in e?-e.wheelDeltaY:"wheelDelta"in e?-e.wheelDelta:0},deltaZ:0,deltaMode:0}),qx=Vt(Hx),Gx=v({},yl,{newState:0,oldState:0}),Ix=Vt(Gx),Qx=[9,13,27,32],zc=Fn&&"CompositionEvent"in window,bs=null;Fn&&"documentMode"in document&&(bs=document.documentMode);var Kx=Fn&&"TextEvent"in window&&!bs,Fh=Fn&&(!zc||bs&&8<bs&&11>=bs),Xh=" ",Zh=!1;function Ph(e,t){switch(e){case"keyup":return Qx.indexOf(t.keyCode)!==-1;case"keydown":return t.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function Jh(e){return e=e.detail,typeof e=="object"&&"data"in e?e.data:null}var mi=!1;function Vx(e,t){switch(e){case"compositionend":return Jh(t);case"keypress":return t.which!==32?null:(Zh=!0,Xh);case"textInput":return e=t.data,e===Xh&&Zh?null:e;default:return null}}function Yx(e,t){if(mi)return e==="compositionend"||!zc&&Ph(e,t)?(e=Qh(),zo=Ac=ka=null,mi=!1,e):null;switch(e){case"paste":return null;case"keypress":if(!(t.ctrlKey||t.altKey||t.metaKey)||t.ctrlKey&&t.altKey){if(t.char&&1<t.char.length)return t.char;if(t.which)return String.fromCharCode(t.which)}return null;case"compositionend":return Fh&&t.locale!=="ko"?null:t.data;default:return null}}var $x={color:!0,date:!0,datetime:!0,"datetime-local":!0,email:!0,month:!0,number:!0,password:!0,range:!0,search:!0,tel:!0,text:!0,time:!0,url:!0,week:!0};function Wh(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t==="input"?!!$x[e.type]:t==="textarea"}function ep(e,t,a,i){hi?pi?pi.push(i):pi=[i]:hi=i,t=Mr(t,"onChange"),0<t.length&&(a=new Lo("onChange","change",null,a,i),e.push({event:a,listeners:t}))}var vs=null,xs=null;function Fx(e){Uy(e,0)}function Ho(e){var t=hs(e);if(Dh(t))return e}function tp(e,t){if(e==="change")return t}var np=!1;if(Fn){var Dc;if(Fn){var Uc="oninput"in document;if(!Uc){var ap=document.createElement("div");ap.setAttribute("oninput","return;"),Uc=typeof ap.oninput=="function"}Dc=Uc}else Dc=!1;np=Dc&&(!document.documentMode||9<document.documentMode)}function lp(){vs&&(vs.detachEvent("onpropertychange",ip),xs=vs=null)}function ip(e){if(e.propertyName==="value"&&Ho(xs)){var t=[];ep(t,xs,e,jc(e)),Ih(Fx,t)}}function Xx(e,t,a){e==="focusin"?(lp(),vs=t,xs=a,vs.attachEvent("onpropertychange",ip)):e==="focusout"&&lp()}function Zx(e){if(e==="selectionchange"||e==="keyup"||e==="keydown")return Ho(xs)}function Px(e,t){if(e==="click")return Ho(t)}function Jx(e,t){if(e==="input"||e==="change")return Ho(t)}function Wx(e,t){return e===t&&(e!==0||1/e===1/t)||e!==e&&t!==t}var tn=typeof Object.is=="function"?Object.is:Wx;function _s(e,t){if(tn(e,t))return!0;if(typeof e!="object"||e===null||typeof t!="object"||t===null)return!1;var a=Object.keys(e),i=Object.keys(t);if(a.length!==i.length)return!1;for(i=0;i<a.length;i++){var r=a[i];if(!ti.call(t,r)||!tn(e[r],t[r]))return!1}return!0}function sp(e){for(;e&&e.firstChild;)e=e.firstChild;return e}function op(e,t){var a=sp(e);e=0;for(var i;a;){if(a.nodeType===3){if(i=e+a.textContent.length,e<=t&&i>=t)return{node:a,offset:t-e};e=i}e:{for(;a;){if(a.nextSibling){a=a.nextSibling;break e}a=a.parentNode}a=void 0}a=sp(a)}}function rp(e,t){return e&&t?e===t?!0:e&&e.nodeType===3?!1:t&&t.nodeType===3?rp(e,t.parentNode):"contains"in e?e.contains(t):e.compareDocumentPosition?!!(e.compareDocumentPosition(t)&16):!1:!1}function cp(e){e=e!=null&&e.ownerDocument!=null&&e.ownerDocument.defaultView!=null?e.ownerDocument.defaultView:window;for(var t=Oo(e.document);t instanceof e.HTMLIFrameElement;){try{var a=typeof t.contentWindow.location.href=="string"}catch{a=!1}if(a)e=t.contentWindow;else break;t=Oo(e.document)}return t}function Lc(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t&&(t==="input"&&(e.type==="text"||e.type==="search"||e.type==="tel"||e.type==="url"||e.type==="password")||t==="textarea"||e.contentEditable==="true")}var e2=Fn&&"documentMode"in document&&11>=document.documentMode,yi=null,Bc=null,ws=null,Hc=!1;function up(e,t,a){var i=a.window===a?a.document:a.nodeType===9?a:a.ownerDocument;Hc||yi==null||yi!==Oo(i)||(i=yi,"selectionStart"in i&&Lc(i)?i={start:i.selectionStart,end:i.selectionEnd}:(i=(i.ownerDocument&&i.ownerDocument.defaultView||window).getSelection(),i={anchorNode:i.anchorNode,anchorOffset:i.anchorOffset,focusNode:i.focusNode,focusOffset:i.focusOffset}),ws&&_s(ws,i)||(ws=i,i=Mr(Bc,"onSelect"),0<i.length&&(t=new Lo("onSelect","select",null,t,a),e.push({event:t,listeners:i}),t.target=yi)))}function gl(e,t){var a={};return a[e.toLowerCase()]=t.toLowerCase(),a["Webkit"+e]="webkit"+t,a["Moz"+e]="moz"+t,a}var gi={animationend:gl("Animation","AnimationEnd"),animationiteration:gl("Animation","AnimationIteration"),animationstart:gl("Animation","AnimationStart"),transitionrun:gl("Transition","TransitionRun"),transitionstart:gl("Transition","TransitionStart"),transitioncancel:gl("Transition","TransitionCancel"),transitionend:gl("Transition","TransitionEnd")},qc={},dp={};Fn&&(dp=document.createElement("div").style,"AnimationEvent"in window||(delete gi.animationend.animation,delete gi.animationiteration.animation,delete gi.animationstart.animation),"TransitionEvent"in window||delete gi.transitionend.transition);function bl(e){if(qc[e])return qc[e];if(!gi[e])return e;var t=gi[e],a;for(a in t)if(t.hasOwnProperty(a)&&a in dp)return qc[e]=t[a];return e}var fp=bl("animationend"),hp=bl("animationiteration"),pp=bl("animationstart"),t2=bl("transitionrun"),n2=bl("transitionstart"),a2=bl("transitioncancel"),mp=bl("transitionend"),yp=new Map,Gc="abort auxClick beforeToggle cancel canPlay canPlayThrough click close contextMenu copy cut drag dragEnd dragEnter dragExit dragLeave dragOver dragStart drop durationChange emptied encrypted ended error gotPointerCapture input invalid keyDown keyPress keyUp load loadedData loadedMetadata loadStart lostPointerCapture mouseDown mouseMove mouseOut mouseOver mouseUp paste pause play playing pointerCancel pointerDown pointerMove pointerOut pointerOver pointerUp progress rateChange reset resize seeked seeking stalled submit suspend timeUpdate touchCancel touchEnd touchStart volumeChange scroll toggle touchMove waiting wheel".split(" ");Gc.push("scrollEnd");function Mn(e,t){yp.set(e,t),ml(t,[e])}var qo=typeof reportError=="function"?reportError:function(e){if(typeof window=="object"&&typeof window.ErrorEvent=="function"){var t=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(t))return}else if(typeof process=="object"&&typeof process.emit=="function"){process.emit("uncaughtException",e);return}console.error(e)},yn=[],bi=0,Ic=0;function Go(){for(var e=bi,t=Ic=bi=0;t<e;){var a=yn[t];yn[t++]=null;var i=yn[t];yn[t++]=null;var r=yn[t];yn[t++]=null;var c=yn[t];if(yn[t++]=null,i!==null&&r!==null){var m=i.pending;m===null?r.next=r:(r.next=m.next,m.next=r),i.pending=r}c!==0&&gp(a,r,c)}}function Io(e,t,a,i){yn[bi++]=e,yn[bi++]=t,yn[bi++]=a,yn[bi++]=i,Ic|=i,e.lanes|=i,e=e.alternate,e!==null&&(e.lanes|=i)}function Qc(e,t,a,i){return Io(e,t,a,i),Qo(e)}function vl(e,t){return Io(e,null,null,t),Qo(e)}function gp(e,t,a){e.lanes|=a;var i=e.alternate;i!==null&&(i.lanes|=a);for(var r=!1,c=e.return;c!==null;)c.childLanes|=a,i=c.alternate,i!==null&&(i.childLanes|=a),c.tag===22&&(e=c.stateNode,e===null||e._visibility&1||(r=!0)),e=c,c=c.return;return e.tag===3?(c=e.stateNode,r&&t!==null&&(r=31-pe(a),e=c.hiddenUpdates,i=e[r],i===null?e[r]=[t]:i.push(t),t.lane=a|536870912),c):null}function Qo(e){if(50<Ks)throw Ks=0,Ju=null,Error(o(185));for(var t=e.return;t!==null;)e=t,t=e.return;return e.tag===3?e.stateNode:null}var vi={};function l2(e,t,a,i){this.tag=e,this.key=a,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.refCleanup=this.ref=null,this.pendingProps=t,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=i,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function nn(e,t,a,i){return new l2(e,t,a,i)}function Kc(e){return e=e.prototype,!(!e||!e.isReactComponent)}function Xn(e,t){var a=e.alternate;return a===null?(a=nn(e.tag,t,e.key,e.mode),a.elementType=e.elementType,a.type=e.type,a.stateNode=e.stateNode,a.alternate=e,e.alternate=a):(a.pendingProps=t,a.type=e.type,a.flags=0,a.subtreeFlags=0,a.deletions=null),a.flags=e.flags&65011712,a.childLanes=e.childLanes,a.lanes=e.lanes,a.child=e.child,a.memoizedProps=e.memoizedProps,a.memoizedState=e.memoizedState,a.updateQueue=e.updateQueue,t=e.dependencies,a.dependencies=t===null?null:{lanes:t.lanes,firstContext:t.firstContext},a.sibling=e.sibling,a.index=e.index,a.ref=e.ref,a.refCleanup=e.refCleanup,a}function bp(e,t){e.flags&=65011714;var a=e.alternate;return a===null?(e.childLanes=0,e.lanes=t,e.child=null,e.subtreeFlags=0,e.memoizedProps=null,e.memoizedState=null,e.updateQueue=null,e.dependencies=null,e.stateNode=null):(e.childLanes=a.childLanes,e.lanes=a.lanes,e.child=a.child,e.subtreeFlags=0,e.deletions=null,e.memoizedProps=a.memoizedProps,e.memoizedState=a.memoizedState,e.updateQueue=a.updateQueue,e.type=a.type,t=a.dependencies,e.dependencies=t===null?null:{lanes:t.lanes,firstContext:t.firstContext}),e}function Ko(e,t,a,i,r,c){var m=0;if(i=e,typeof e=="function")Kc(e)&&(m=1);else if(typeof e=="string")m=c_(e,a,T.current)?26:e==="html"||e==="head"||e==="body"?27:5;else e:switch(e){case re:return e=nn(31,a,t,r),e.elementType=re,e.lanes=c,e;case A:return xl(a.children,r,c,t);case j:m=8,r|=24;break;case O:return e=nn(12,a,t,r|2),e.elementType=O,e.lanes=c,e;case W:return e=nn(13,a,t,r),e.elementType=W,e.lanes=c,e;case ee:return e=nn(19,a,t,r),e.elementType=ee,e.lanes=c,e;default:if(typeof e=="object"&&e!==null)switch(e.$$typeof){case D:m=10;break e;case z:m=9;break e;case Y:m=11;break e;case ae:m=14;break e;case U:m=16,i=null;break e}m=29,a=Error(o(130,e===null?"null":typeof e,"")),i=null}return t=nn(m,a,t,r),t.elementType=e,t.type=i,t.lanes=c,t}function xl(e,t,a,i){return e=nn(7,e,i,t),e.lanes=a,e}function Vc(e,t,a){return e=nn(6,e,null,t),e.lanes=a,e}function vp(e){var t=nn(18,null,null,0);return t.stateNode=e,t}function Yc(e,t,a){return t=nn(4,e.children!==null?e.children:[],e.key,t),t.lanes=a,t.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},t}var xp=new WeakMap;function gn(e,t){if(typeof e=="object"&&e!==null){var a=xp.get(e);return a!==void 0?a:(t={value:e,source:t,stack:jo(t)},xp.set(e,t),t)}return{value:e,source:t,stack:jo(t)}}var xi=[],_i=0,Vo=null,Ss=0,bn=[],vn=0,Ea=null,Rn=1,zn="";function Zn(e,t){xi[_i++]=Ss,xi[_i++]=Vo,Vo=e,Ss=t}function _p(e,t,a){bn[vn++]=Rn,bn[vn++]=zn,bn[vn++]=Ea,Ea=e;var i=Rn;e=zn;var r=32-pe(i)-1;i&=~(1<<r),a+=1;var c=32-pe(t)+r;if(30<c){var m=r-r%5;c=(i&(1<<m)-1).toString(32),i>>=m,r-=m,Rn=1<<32-pe(t)+r|a<<r|i,zn=c+e}else Rn=1<<c|a<<r|i,zn=e}function $c(e){e.return!==null&&(Zn(e,1),_p(e,1,0))}function Fc(e){for(;e===Vo;)Vo=xi[--_i],xi[_i]=null,Ss=xi[--_i],xi[_i]=null;for(;e===Ea;)Ea=bn[--vn],bn[vn]=null,zn=bn[--vn],bn[vn]=null,Rn=bn[--vn],bn[vn]=null}function wp(e,t){bn[vn++]=Rn,bn[vn++]=zn,bn[vn++]=Ea,Rn=t.id,zn=t.overflow,Ea=e}var At=null,at=null,Qe=!1,ja=null,xn=!1,Xc=Error(o(519));function Ma(e){var t=Error(o(418,1<arguments.length&&arguments[1]!==void 0&&arguments[1]?"text":"HTML",""));throw ks(gn(t,e)),Xc}function Sp(e){var t=e.stateNode,a=e.type,i=e.memoizedProps;switch(t[Ct]=e,t[Kt]=i,a){case"dialog":qe("cancel",t),qe("close",t);break;case"iframe":case"object":case"embed":qe("load",t);break;case"video":case"audio":for(a=0;a<Ys.length;a++)qe(Ys[a],t);break;case"source":qe("error",t);break;case"img":case"image":case"link":qe("error",t),qe("load",t);break;case"details":qe("toggle",t);break;case"input":qe("invalid",t),Uh(t,i.value,i.defaultValue,i.checked,i.defaultChecked,i.type,i.name,!0);break;case"select":qe("invalid",t);break;case"textarea":qe("invalid",t),Bh(t,i.value,i.defaultValue,i.children)}a=i.children,typeof a!="string"&&typeof a!="number"&&typeof a!="bigint"||t.textContent===""+a||i.suppressHydrationWarning===!0||qy(t.textContent,a)?(i.popover!=null&&(qe("beforetoggle",t),qe("toggle",t)),i.onScroll!=null&&qe("scroll",t),i.onScrollEnd!=null&&qe("scrollend",t),i.onClick!=null&&(t.onclick=$n),t=!0):t=!1,t||Ma(e,!0)}function kp(e){for(At=e.return;At;)switch(At.tag){case 5:case 31:case 13:xn=!1;return;case 27:case 3:xn=!0;return;default:At=At.return}}function wi(e){if(e!==At)return!1;if(!Qe)return kp(e),Qe=!0,!1;var t=e.tag,a;if((a=t!==3&&t!==27)&&((a=t===5)&&(a=e.type,a=!(a!=="form"&&a!=="button")||hd(e.type,e.memoizedProps)),a=!a),a&&at&&Ma(e),kp(e),t===13){if(e=e.memoizedState,e=e!==null?e.dehydrated:null,!e)throw Error(o(317));at=Xy(e)}else if(t===31){if(e=e.memoizedState,e=e!==null?e.dehydrated:null,!e)throw Error(o(317));at=Xy(e)}else t===27?(t=at,Ga(e.type)?(e=bd,bd=null,at=e):at=t):at=At?wn(e.stateNode.nextSibling):null;return!0}function _l(){at=At=null,Qe=!1}function Zc(){var e=ja;return e!==null&&(Xt===null?Xt=e:Xt.push.apply(Xt,e),ja=null),e}function ks(e){ja===null?ja=[e]:ja.push(e)}var Pc=k(null),wl=null,Pn=null;function Ca(e,t,a){$(Pc,t._currentValue),t._currentValue=a}function Jn(e){e._currentValue=Pc.current,I(Pc)}function Jc(e,t,a){for(;e!==null;){var i=e.alternate;if((e.childLanes&t)!==t?(e.childLanes|=t,i!==null&&(i.childLanes|=t)):i!==null&&(i.childLanes&t)!==t&&(i.childLanes|=t),e===a)break;e=e.return}}function Wc(e,t,a,i){var r=e.child;for(r!==null&&(r.return=e);r!==null;){var c=r.dependencies;if(c!==null){var m=r.child;c=c.firstContext;e:for(;c!==null;){var b=c;c=r;for(var C=0;C<t.length;C++)if(b.context===t[C]){c.lanes|=a,b=c.alternate,b!==null&&(b.lanes|=a),Jc(c.return,a,e),i||(m=null);break e}c=b.next}}else if(r.tag===18){if(m=r.return,m===null)throw Error(o(341));m.lanes|=a,c=m.alternate,c!==null&&(c.lanes|=a),Jc(m,a,e),m=null}else m=r.child;if(m!==null)m.return=r;else for(m=r;m!==null;){if(m===e){m=null;break}if(r=m.sibling,r!==null){r.return=m.return,m=r;break}m=m.return}r=m}}function Si(e,t,a,i){e=null;for(var r=t,c=!1;r!==null;){if(!c){if((r.flags&524288)!==0)c=!0;else if((r.flags&262144)!==0)break}if(r.tag===10){var m=r.alternate;if(m===null)throw Error(o(387));if(m=m.memoizedProps,m!==null){var b=r.type;tn(r.pendingProps.value,m.value)||(e!==null?e.push(b):e=[b])}}else if(r===V.current){if(m=r.alternate,m===null)throw Error(o(387));m.memoizedState.memoizedState!==r.memoizedState.memoizedState&&(e!==null?e.push(Ps):e=[Ps])}r=r.return}e!==null&&Wc(t,e,a,i),t.flags|=262144}function Yo(e){for(e=e.firstContext;e!==null;){if(!tn(e.context._currentValue,e.memoizedValue))return!0;e=e.next}return!1}function Sl(e){wl=e,Pn=null,e=e.dependencies,e!==null&&(e.firstContext=null)}function Nt(e){return Ep(wl,e)}function $o(e,t){return wl===null&&Sl(e),Ep(e,t)}function Ep(e,t){var a=t._currentValue;if(t={context:t,memoizedValue:a,next:null},Pn===null){if(e===null)throw Error(o(308));Pn=t,e.dependencies={lanes:0,firstContext:t},e.flags|=524288}else Pn=Pn.next=t;return a}var i2=typeof AbortController<"u"?AbortController:function(){var e=[],t=this.signal={aborted:!1,addEventListener:function(a,i){e.push(i)}};this.abort=function(){t.aborted=!0,e.forEach(function(a){return a()})}},s2=n.unstable_scheduleCallback,o2=n.unstable_NormalPriority,bt={$$typeof:D,Consumer:null,Provider:null,_currentValue:null,_currentValue2:null,_threadCount:0};function eu(){return{controller:new i2,data:new Map,refCount:0}}function Es(e){e.refCount--,e.refCount===0&&s2(o2,function(){e.controller.abort()})}var js=null,tu=0,ki=0,Ei=null;function r2(e,t){if(js===null){var a=js=[];tu=0,ki=ld(),Ei={status:"pending",value:void 0,then:function(i){a.push(i)}}}return tu++,t.then(jp,jp),t}function jp(){if(--tu===0&&js!==null){Ei!==null&&(Ei.status="fulfilled");var e=js;js=null,ki=0,Ei=null;for(var t=0;t<e.length;t++)(0,e[t])()}}function c2(e,t){var a=[],i={status:"pending",value:null,reason:null,then:function(r){a.push(r)}};return e.then(function(){i.status="fulfilled",i.value=t;for(var r=0;r<a.length;r++)(0,a[r])(t)},function(r){for(i.status="rejected",i.reason=r,r=0;r<a.length;r++)(0,a[r])(void 0)}),i}var Mp=w.S;w.S=function(e,t){uy=rt(),typeof t=="object"&&t!==null&&typeof t.then=="function"&&r2(e,t),Mp!==null&&Mp(e,t)};var kl=k(null);function nu(){var e=kl.current;return e!==null?e:tt.pooledCache}function Fo(e,t){t===null?$(kl,kl.current):$(kl,t.pool)}function Cp(){var e=nu();return e===null?null:{parent:bt._currentValue,pool:e}}var ji=Error(o(460)),au=Error(o(474)),Xo=Error(o(542)),Zo={then:function(){}};function Ap(e){return e=e.status,e==="fulfilled"||e==="rejected"}function Np(e,t,a){switch(a=e[a],a===void 0?e.push(t):a!==t&&(t.then($n,$n),t=a),t.status){case"fulfilled":return t.value;case"rejected":throw e=t.reason,Op(e),e;default:if(typeof t.status=="string")t.then($n,$n);else{if(e=tt,e!==null&&100<e.shellSuspendCounter)throw Error(o(482));e=t,e.status="pending",e.then(function(i){if(t.status==="pending"){var r=t;r.status="fulfilled",r.value=i}},function(i){if(t.status==="pending"){var r=t;r.status="rejected",r.reason=i}})}switch(t.status){case"fulfilled":return t.value;case"rejected":throw e=t.reason,Op(e),e}throw jl=t,ji}}function El(e){try{var t=e._init;return t(e._payload)}catch(a){throw a!==null&&typeof a=="object"&&typeof a.then=="function"?(jl=a,ji):a}}var jl=null;function Tp(){if(jl===null)throw Error(o(459));var e=jl;return jl=null,e}function Op(e){if(e===ji||e===Xo)throw Error(o(483))}var Mi=null,Ms=0;function Po(e){var t=Ms;return Ms+=1,Mi===null&&(Mi=[]),Np(Mi,e,t)}function Cs(e,t){t=t.props.ref,e.ref=t!==void 0?t:null}function Jo(e,t){throw t.$$typeof===E?Error(o(525)):(e=Object.prototype.toString.call(t),Error(o(31,e==="[object Object]"?"object with keys {"+Object.keys(t).join(", ")+"}":e)))}function Rp(e){function t(H,R){if(e){var Q=H.deletions;Q===null?(H.deletions=[R],H.flags|=16):Q.push(R)}}function a(H,R){if(!e)return null;for(;R!==null;)t(H,R),R=R.sibling;return null}function i(H){for(var R=new Map;H!==null;)H.key!==null?R.set(H.key,H):R.set(H.index,H),H=H.sibling;return R}function r(H,R){return H=Xn(H,R),H.index=0,H.sibling=null,H}function c(H,R,Q){return H.index=Q,e?(Q=H.alternate,Q!==null?(Q=Q.index,Q<R?(H.flags|=67108866,R):Q):(H.flags|=67108866,R)):(H.flags|=1048576,R)}function m(H){return e&&H.alternate===null&&(H.flags|=67108866),H}function b(H,R,Q,se){return R===null||R.tag!==6?(R=Vc(Q,H.mode,se),R.return=H,R):(R=r(R,Q),R.return=H,R)}function C(H,R,Q,se){var Ee=Q.type;return Ee===A?le(H,R,Q.props.children,se,Q.key):R!==null&&(R.elementType===Ee||typeof Ee=="object"&&Ee!==null&&Ee.$$typeof===U&&El(Ee)===R.type)?(R=r(R,Q.props),Cs(R,Q),R.return=H,R):(R=Ko(Q.type,Q.key,Q.props,null,H.mode,se),Cs(R,Q),R.return=H,R)}function K(H,R,Q,se){return R===null||R.tag!==4||R.stateNode.containerInfo!==Q.containerInfo||R.stateNode.implementation!==Q.implementation?(R=Yc(Q,H.mode,se),R.return=H,R):(R=r(R,Q.children||[]),R.return=H,R)}function le(H,R,Q,se,Ee){return R===null||R.tag!==7?(R=xl(Q,H.mode,se,Ee),R.return=H,R):(R=r(R,Q),R.return=H,R)}function oe(H,R,Q){if(typeof R=="string"&&R!==""||typeof R=="number"||typeof R=="bigint")return R=Vc(""+R,H.mode,Q),R.return=H,R;if(typeof R=="object"&&R!==null){switch(R.$$typeof){case M:return Q=Ko(R.type,R.key,R.props,null,H.mode,Q),Cs(Q,R),Q.return=H,Q;case N:return R=Yc(R,H.mode,Q),R.return=H,R;case U:return R=El(R),oe(H,R,Q)}if(F(R)||ie(R))return R=xl(R,H.mode,Q,null),R.return=H,R;if(typeof R.then=="function")return oe(H,Po(R),Q);if(R.$$typeof===D)return oe(H,$o(H,R),Q);Jo(H,R)}return null}function X(H,R,Q,se){var Ee=R!==null?R.key:null;if(typeof Q=="string"&&Q!==""||typeof Q=="number"||typeof Q=="bigint")return Ee!==null?null:b(H,R,""+Q,se);if(typeof Q=="object"&&Q!==null){switch(Q.$$typeof){case M:return Q.key===Ee?C(H,R,Q,se):null;case N:return Q.key===Ee?K(H,R,Q,se):null;case U:return Q=El(Q),X(H,R,Q,se)}if(F(Q)||ie(Q))return Ee!==null?null:le(H,R,Q,se,null);if(typeof Q.then=="function")return X(H,R,Po(Q),se);if(Q.$$typeof===D)return X(H,R,$o(H,Q),se);Jo(H,Q)}return null}function J(H,R,Q,se,Ee){if(typeof se=="string"&&se!==""||typeof se=="number"||typeof se=="bigint")return H=H.get(Q)||null,b(R,H,""+se,Ee);if(typeof se=="object"&&se!==null){switch(se.$$typeof){case M:return H=H.get(se.key===null?Q:se.key)||null,C(R,H,se,Ee);case N:return H=H.get(se.key===null?Q:se.key)||null,K(R,H,se,Ee);case U:return se=El(se),J(H,R,Q,se,Ee)}if(F(se)||ie(se))return H=H.get(Q)||null,le(R,H,se,Ee,null);if(typeof se.then=="function")return J(H,R,Q,Po(se),Ee);if(se.$$typeof===D)return J(H,R,Q,$o(R,se),Ee);Jo(R,se)}return null}function _e(H,R,Q,se){for(var Ee=null,Ye=null,we=R,De=R=0,Ie=null;we!==null&&De<Q.length;De++){we.index>De?(Ie=we,we=null):Ie=we.sibling;var $e=X(H,we,Q[De],se);if($e===null){we===null&&(we=Ie);break}e&&we&&$e.alternate===null&&t(H,we),R=c($e,R,De),Ye===null?Ee=$e:Ye.sibling=$e,Ye=$e,we=Ie}if(De===Q.length)return a(H,we),Qe&&Zn(H,De),Ee;if(we===null){for(;De<Q.length;De++)we=oe(H,Q[De],se),we!==null&&(R=c(we,R,De),Ye===null?Ee=we:Ye.sibling=we,Ye=we);return Qe&&Zn(H,De),Ee}for(we=i(we);De<Q.length;De++)Ie=J(we,H,De,Q[De],se),Ie!==null&&(e&&Ie.alternate!==null&&we.delete(Ie.key===null?De:Ie.key),R=c(Ie,R,De),Ye===null?Ee=Ie:Ye.sibling=Ie,Ye=Ie);return e&&we.forEach(function(Ya){return t(H,Ya)}),Qe&&Zn(H,De),Ee}function Ce(H,R,Q,se){if(Q==null)throw Error(o(151));for(var Ee=null,Ye=null,we=R,De=R=0,Ie=null,$e=Q.next();we!==null&&!$e.done;De++,$e=Q.next()){we.index>De?(Ie=we,we=null):Ie=we.sibling;var Ya=X(H,we,$e.value,se);if(Ya===null){we===null&&(we=Ie);break}e&&we&&Ya.alternate===null&&t(H,we),R=c(Ya,R,De),Ye===null?Ee=Ya:Ye.sibling=Ya,Ye=Ya,we=Ie}if($e.done)return a(H,we),Qe&&Zn(H,De),Ee;if(we===null){for(;!$e.done;De++,$e=Q.next())$e=oe(H,$e.value,se),$e!==null&&(R=c($e,R,De),Ye===null?Ee=$e:Ye.sibling=$e,Ye=$e);return Qe&&Zn(H,De),Ee}for(we=i(we);!$e.done;De++,$e=Q.next())$e=J(we,H,De,$e.value,se),$e!==null&&(e&&$e.alternate!==null&&we.delete($e.key===null?De:$e.key),R=c($e,R,De),Ye===null?Ee=$e:Ye.sibling=$e,Ye=$e);return e&&we.forEach(function(x_){return t(H,x_)}),Qe&&Zn(H,De),Ee}function et(H,R,Q,se){if(typeof Q=="object"&&Q!==null&&Q.type===A&&Q.key===null&&(Q=Q.props.children),typeof Q=="object"&&Q!==null){switch(Q.$$typeof){case M:e:{for(var Ee=Q.key;R!==null;){if(R.key===Ee){if(Ee=Q.type,Ee===A){if(R.tag===7){a(H,R.sibling),se=r(R,Q.props.children),se.return=H,H=se;break e}}else if(R.elementType===Ee||typeof Ee=="object"&&Ee!==null&&Ee.$$typeof===U&&El(Ee)===R.type){a(H,R.sibling),se=r(R,Q.props),Cs(se,Q),se.return=H,H=se;break e}a(H,R);break}else t(H,R);R=R.sibling}Q.type===A?(se=xl(Q.props.children,H.mode,se,Q.key),se.return=H,H=se):(se=Ko(Q.type,Q.key,Q.props,null,H.mode,se),Cs(se,Q),se.return=H,H=se)}return m(H);case N:e:{for(Ee=Q.key;R!==null;){if(R.key===Ee)if(R.tag===4&&R.stateNode.containerInfo===Q.containerInfo&&R.stateNode.implementation===Q.implementation){a(H,R.sibling),se=r(R,Q.children||[]),se.return=H,H=se;break e}else{a(H,R);break}else t(H,R);R=R.sibling}se=Yc(Q,H.mode,se),se.return=H,H=se}return m(H);case U:return Q=El(Q),et(H,R,Q,se)}if(F(Q))return _e(H,R,Q,se);if(ie(Q)){if(Ee=ie(Q),typeof Ee!="function")throw Error(o(150));return Q=Ee.call(Q),Ce(H,R,Q,se)}if(typeof Q.then=="function")return et(H,R,Po(Q),se);if(Q.$$typeof===D)return et(H,R,$o(H,Q),se);Jo(H,Q)}return typeof Q=="string"&&Q!==""||typeof Q=="number"||typeof Q=="bigint"?(Q=""+Q,R!==null&&R.tag===6?(a(H,R.sibling),se=r(R,Q),se.return=H,H=se):(a(H,R),se=Vc(Q,H.mode,se),se.return=H,H=se),m(H)):a(H,R)}return function(H,R,Q,se){try{Ms=0;var Ee=et(H,R,Q,se);return Mi=null,Ee}catch(we){if(we===ji||we===Xo)throw we;var Ye=nn(29,we,null,H.mode);return Ye.lanes=se,Ye.return=H,Ye}finally{}}}var Ml=Rp(!0),zp=Rp(!1),Aa=!1;function lu(e){e.updateQueue={baseState:e.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,lanes:0,hiddenCallbacks:null},callbacks:null}}function iu(e,t){e=e.updateQueue,t.updateQueue===e&&(t.updateQueue={baseState:e.baseState,firstBaseUpdate:e.firstBaseUpdate,lastBaseUpdate:e.lastBaseUpdate,shared:e.shared,callbacks:null})}function Na(e){return{lane:e,tag:0,payload:null,callback:null,next:null}}function Ta(e,t,a){var i=e.updateQueue;if(i===null)return null;if(i=i.shared,(Fe&2)!==0){var r=i.pending;return r===null?t.next=t:(t.next=r.next,r.next=t),i.pending=t,t=Qo(e),gp(e,null,a),t}return Io(e,i,t,a),Qo(e)}function As(e,t,a){if(t=t.updateQueue,t!==null&&(t=t.shared,(a&4194048)!==0)){var i=t.lanes;i&=e.pendingLanes,a|=i,t.lanes=a,Eh(e,a)}}function su(e,t){var a=e.updateQueue,i=e.alternate;if(i!==null&&(i=i.updateQueue,a===i)){var r=null,c=null;if(a=a.firstBaseUpdate,a!==null){do{var m={lane:a.lane,tag:a.tag,payload:a.payload,callback:null,next:null};c===null?r=c=m:c=c.next=m,a=a.next}while(a!==null);c===null?r=c=t:c=c.next=t}else r=c=t;a={baseState:i.baseState,firstBaseUpdate:r,lastBaseUpdate:c,shared:i.shared,callbacks:i.callbacks},e.updateQueue=a;return}e=a.lastBaseUpdate,e===null?a.firstBaseUpdate=t:e.next=t,a.lastBaseUpdate=t}var ou=!1;function Ns(){if(ou){var e=Ei;if(e!==null)throw e}}function Ts(e,t,a,i){ou=!1;var r=e.updateQueue;Aa=!1;var c=r.firstBaseUpdate,m=r.lastBaseUpdate,b=r.shared.pending;if(b!==null){r.shared.pending=null;var C=b,K=C.next;C.next=null,m===null?c=K:m.next=K,m=C;var le=e.alternate;le!==null&&(le=le.updateQueue,b=le.lastBaseUpdate,b!==m&&(b===null?le.firstBaseUpdate=K:b.next=K,le.lastBaseUpdate=C))}if(c!==null){var oe=r.baseState;m=0,le=K=C=null,b=c;do{var X=b.lane&-536870913,J=X!==b.lane;if(J?(Ge&X)===X:(i&X)===X){X!==0&&X===ki&&(ou=!0),le!==null&&(le=le.next={lane:0,tag:b.tag,payload:b.payload,callback:null,next:null});e:{var _e=e,Ce=b;X=t;var et=a;switch(Ce.tag){case 1:if(_e=Ce.payload,typeof _e=="function"){oe=_e.call(et,oe,X);break e}oe=_e;break e;case 3:_e.flags=_e.flags&-65537|128;case 0:if(_e=Ce.payload,X=typeof _e=="function"?_e.call(et,oe,X):_e,X==null)break e;oe=v({},oe,X);break e;case 2:Aa=!0}}X=b.callback,X!==null&&(e.flags|=64,J&&(e.flags|=8192),J=r.callbacks,J===null?r.callbacks=[X]:J.push(X))}else J={lane:X,tag:b.tag,payload:b.payload,callback:b.callback,next:null},le===null?(K=le=J,C=oe):le=le.next=J,m|=X;if(b=b.next,b===null){if(b=r.shared.pending,b===null)break;J=b,b=J.next,J.next=null,r.lastBaseUpdate=J,r.shared.pending=null}}while(!0);le===null&&(C=oe),r.baseState=C,r.firstBaseUpdate=K,r.lastBaseUpdate=le,c===null&&(r.shared.lanes=0),Ua|=m,e.lanes=m,e.memoizedState=oe}}function Dp(e,t){if(typeof e!="function")throw Error(o(191,e));e.call(t)}function Up(e,t){var a=e.callbacks;if(a!==null)for(e.callbacks=null,e=0;e<a.length;e++)Dp(a[e],t)}var Ci=k(null),Wo=k(0);function Lp(e,t){e=oa,$(Wo,e),$(Ci,t),oa=e|t.baseLanes}function ru(){$(Wo,oa),$(Ci,Ci.current)}function cu(){oa=Wo.current,I(Ci),I(Wo)}var an=k(null),_n=null;function Oa(e){var t=e.alternate;$(yt,yt.current&1),$(an,e),_n===null&&(t===null||Ci.current!==null||t.memoizedState!==null)&&(_n=e)}function uu(e){$(yt,yt.current),$(an,e),_n===null&&(_n=e)}function Bp(e){e.tag===22?($(yt,yt.current),$(an,e),_n===null&&(_n=e)):Ra()}function Ra(){$(yt,yt.current),$(an,an.current)}function ln(e){I(an),_n===e&&(_n=null),I(yt)}var yt=k(0);function er(e){for(var t=e;t!==null;){if(t.tag===13){var a=t.memoizedState;if(a!==null&&(a=a.dehydrated,a===null||yd(a)||gd(a)))return t}else if(t.tag===19&&(t.memoizedProps.revealOrder==="forwards"||t.memoizedProps.revealOrder==="backwards"||t.memoizedProps.revealOrder==="unstable_legacy-backwards"||t.memoizedProps.revealOrder==="together")){if((t.flags&128)!==0)return t}else if(t.child!==null){t.child.return=t,t=t.child;continue}if(t===e)break;for(;t.sibling===null;){if(t.return===null||t.return===e)return null;t=t.return}t.sibling.return=t.return,t=t.sibling}return null}var Wn=0,Re=null,Je=null,vt=null,tr=!1,Ai=!1,Cl=!1,nr=0,Os=0,Ni=null,u2=0;function ut(){throw Error(o(321))}function du(e,t){if(t===null)return!1;for(var a=0;a<t.length&&a<e.length;a++)if(!tn(e[a],t[a]))return!1;return!0}function fu(e,t,a,i,r,c){return Wn=c,Re=t,t.memoizedState=null,t.updateQueue=null,t.lanes=0,w.H=e===null||e.memoizedState===null?_m:Mu,Cl=!1,c=a(i,r),Cl=!1,Ai&&(c=qp(t,a,i,r)),Hp(e),c}function Hp(e){w.H=Ds;var t=Je!==null&&Je.next!==null;if(Wn=0,vt=Je=Re=null,tr=!1,Os=0,Ni=null,t)throw Error(o(300));e===null||xt||(e=e.dependencies,e!==null&&Yo(e)&&(xt=!0))}function qp(e,t,a,i){Re=e;var r=0;do{if(Ai&&(Ni=null),Os=0,Ai=!1,25<=r)throw Error(o(301));if(r+=1,vt=Je=null,e.updateQueue!=null){var c=e.updateQueue;c.lastEffect=null,c.events=null,c.stores=null,c.memoCache!=null&&(c.memoCache.index=0)}w.H=wm,c=t(a,i)}while(Ai);return c}function d2(){var e=w.H,t=e.useState()[0];return t=typeof t.then=="function"?Rs(t):t,e=e.useState()[0],(Je!==null?Je.memoizedState:null)!==e&&(Re.flags|=1024),t}function hu(){var e=nr!==0;return nr=0,e}function pu(e,t,a){t.updateQueue=e.updateQueue,t.flags&=-2053,e.lanes&=~a}function mu(e){if(tr){for(e=e.memoizedState;e!==null;){var t=e.queue;t!==null&&(t.pending=null),e=e.next}tr=!1}Wn=0,vt=Je=Re=null,Ai=!1,Os=nr=0,Ni=null}function Gt(){var e={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return vt===null?Re.memoizedState=vt=e:vt=vt.next=e,vt}function gt(){if(Je===null){var e=Re.alternate;e=e!==null?e.memoizedState:null}else e=Je.next;var t=vt===null?Re.memoizedState:vt.next;if(t!==null)vt=t,Je=e;else{if(e===null)throw Re.alternate===null?Error(o(467)):Error(o(310));Je=e,e={memoizedState:Je.memoizedState,baseState:Je.baseState,baseQueue:Je.baseQueue,queue:Je.queue,next:null},vt===null?Re.memoizedState=vt=e:vt=vt.next=e}return vt}function ar(){return{lastEffect:null,events:null,stores:null,memoCache:null}}function Rs(e){var t=Os;return Os+=1,Ni===null&&(Ni=[]),e=Np(Ni,e,t),t=Re,(vt===null?t.memoizedState:vt.next)===null&&(t=t.alternate,w.H=t===null||t.memoizedState===null?_m:Mu),e}function lr(e){if(e!==null&&typeof e=="object"){if(typeof e.then=="function")return Rs(e);if(e.$$typeof===D)return Nt(e)}throw Error(o(438,String(e)))}function yu(e){var t=null,a=Re.updateQueue;if(a!==null&&(t=a.memoCache),t==null){var i=Re.alternate;i!==null&&(i=i.updateQueue,i!==null&&(i=i.memoCache,i!=null&&(t={data:i.data.map(function(r){return r.slice()}),index:0})))}if(t==null&&(t={data:[],index:0}),a===null&&(a=ar(),Re.updateQueue=a),a.memoCache=t,a=t.data[t.index],a===void 0)for(a=t.data[t.index]=Array(e),i=0;i<e;i++)a[i]=de;return t.index++,a}function ea(e,t){return typeof t=="function"?t(e):t}function ir(e){var t=gt();return gu(t,Je,e)}function gu(e,t,a){var i=e.queue;if(i===null)throw Error(o(311));i.lastRenderedReducer=a;var r=e.baseQueue,c=i.pending;if(c!==null){if(r!==null){var m=r.next;r.next=c.next,c.next=m}t.baseQueue=r=c,i.pending=null}if(c=e.baseState,r===null)e.memoizedState=c;else{t=r.next;var b=m=null,C=null,K=t,le=!1;do{var oe=K.lane&-536870913;if(oe!==K.lane?(Ge&oe)===oe:(Wn&oe)===oe){var X=K.revertLane;if(X===0)C!==null&&(C=C.next={lane:0,revertLane:0,gesture:null,action:K.action,hasEagerState:K.hasEagerState,eagerState:K.eagerState,next:null}),oe===ki&&(le=!0);else if((Wn&X)===X){K=K.next,X===ki&&(le=!0);continue}else oe={lane:0,revertLane:K.revertLane,gesture:null,action:K.action,hasEagerState:K.hasEagerState,eagerState:K.eagerState,next:null},C===null?(b=C=oe,m=c):C=C.next=oe,Re.lanes|=X,Ua|=X;oe=K.action,Cl&&a(c,oe),c=K.hasEagerState?K.eagerState:a(c,oe)}else X={lane:oe,revertLane:K.revertLane,gesture:K.gesture,action:K.action,hasEagerState:K.hasEagerState,eagerState:K.eagerState,next:null},C===null?(b=C=X,m=c):C=C.next=X,Re.lanes|=oe,Ua|=oe;K=K.next}while(K!==null&&K!==t);if(C===null?m=c:C.next=b,!tn(c,e.memoizedState)&&(xt=!0,le&&(a=Ei,a!==null)))throw a;e.memoizedState=c,e.baseState=m,e.baseQueue=C,i.lastRenderedState=c}return r===null&&(i.lanes=0),[e.memoizedState,i.dispatch]}function bu(e){var t=gt(),a=t.queue;if(a===null)throw Error(o(311));a.lastRenderedReducer=e;var i=a.dispatch,r=a.pending,c=t.memoizedState;if(r!==null){a.pending=null;var m=r=r.next;do c=e(c,m.action),m=m.next;while(m!==r);tn(c,t.memoizedState)||(xt=!0),t.memoizedState=c,t.baseQueue===null&&(t.baseState=c),a.lastRenderedState=c}return[c,i]}function Gp(e,t,a){var i=Re,r=gt(),c=Qe;if(c){if(a===void 0)throw Error(o(407));a=a()}else a=t();var m=!tn((Je||r).memoizedState,a);if(m&&(r.memoizedState=a,xt=!0),r=r.queue,_u(Kp.bind(null,i,r,e),[e]),r.getSnapshot!==t||m||vt!==null&&vt.memoizedState.tag&1){if(i.flags|=2048,Ti(9,{destroy:void 0},Qp.bind(null,i,r,a,t),null),tt===null)throw Error(o(349));c||(Wn&127)!==0||Ip(i,t,a)}return a}function Ip(e,t,a){e.flags|=16384,e={getSnapshot:t,value:a},t=Re.updateQueue,t===null?(t=ar(),Re.updateQueue=t,t.stores=[e]):(a=t.stores,a===null?t.stores=[e]:a.push(e))}function Qp(e,t,a,i){t.value=a,t.getSnapshot=i,Vp(t)&&Yp(e)}function Kp(e,t,a){return a(function(){Vp(t)&&Yp(e)})}function Vp(e){var t=e.getSnapshot;e=e.value;try{var a=t();return!tn(e,a)}catch{return!0}}function Yp(e){var t=vl(e,2);t!==null&&Zt(t,e,2)}function vu(e){var t=Gt();if(typeof e=="function"){var a=e;if(e=a(),Cl){ne(!0);try{a()}finally{ne(!1)}}}return t.memoizedState=t.baseState=e,t.queue={pending:null,lanes:0,dispatch:null,lastRenderedReducer:ea,lastRenderedState:e},t}function $p(e,t,a,i){return e.baseState=a,gu(e,Je,typeof i=="function"?i:ea)}function f2(e,t,a,i,r){if(rr(e))throw Error(o(485));if(e=t.action,e!==null){var c={payload:r,action:e,next:null,isTransition:!0,status:"pending",value:null,reason:null,listeners:[],then:function(m){c.listeners.push(m)}};w.T!==null?a(!0):c.isTransition=!1,i(c),a=t.pending,a===null?(c.next=t.pending=c,Fp(t,c)):(c.next=a.next,t.pending=a.next=c)}}function Fp(e,t){var a=t.action,i=t.payload,r=e.state;if(t.isTransition){var c=w.T,m={};w.T=m;try{var b=a(r,i),C=w.S;C!==null&&C(m,b),Xp(e,t,b)}catch(K){xu(e,t,K)}finally{c!==null&&m.types!==null&&(c.types=m.types),w.T=c}}else try{c=a(r,i),Xp(e,t,c)}catch(K){xu(e,t,K)}}function Xp(e,t,a){a!==null&&typeof a=="object"&&typeof a.then=="function"?a.then(function(i){Zp(e,t,i)},function(i){return xu(e,t,i)}):Zp(e,t,a)}function Zp(e,t,a){t.status="fulfilled",t.value=a,Pp(t),e.state=a,t=e.pending,t!==null&&(a=t.next,a===t?e.pending=null:(a=a.next,t.next=a,Fp(e,a)))}function xu(e,t,a){var i=e.pending;if(e.pending=null,i!==null){i=i.next;do t.status="rejected",t.reason=a,Pp(t),t=t.next;while(t!==i)}e.action=null}function Pp(e){e=e.listeners;for(var t=0;t<e.length;t++)(0,e[t])()}function Jp(e,t){return t}function Wp(e,t){if(Qe){var a=tt.formState;if(a!==null){e:{var i=Re;if(Qe){if(at){t:{for(var r=at,c=xn;r.nodeType!==8;){if(!c){r=null;break t}if(r=wn(r.nextSibling),r===null){r=null;break t}}c=r.data,r=c==="F!"||c==="F"?r:null}if(r){at=wn(r.nextSibling),i=r.data==="F!";break e}}Ma(i)}i=!1}i&&(t=a[0])}}return a=Gt(),a.memoizedState=a.baseState=t,i={pending:null,lanes:0,dispatch:null,lastRenderedReducer:Jp,lastRenderedState:t},a.queue=i,a=bm.bind(null,Re,i),i.dispatch=a,i=vu(!1),c=ju.bind(null,Re,!1,i.queue),i=Gt(),r={state:t,dispatch:null,action:e,pending:null},i.queue=r,a=f2.bind(null,Re,r,c,a),r.dispatch=a,i.memoizedState=e,[t,a,!1]}function em(e){var t=gt();return tm(t,Je,e)}function tm(e,t,a){if(t=gu(e,t,Jp)[0],e=ir(ea)[0],typeof t=="object"&&t!==null&&typeof t.then=="function")try{var i=Rs(t)}catch(m){throw m===ji?Xo:m}else i=t;t=gt();var r=t.queue,c=r.dispatch;return a!==t.memoizedState&&(Re.flags|=2048,Ti(9,{destroy:void 0},h2.bind(null,r,a),null)),[i,c,e]}function h2(e,t){e.action=t}function nm(e){var t=gt(),a=Je;if(a!==null)return tm(t,a,e);gt(),t=t.memoizedState,a=gt();var i=a.queue.dispatch;return a.memoizedState=e,[t,i,!1]}function Ti(e,t,a,i){return e={tag:e,create:a,deps:i,inst:t,next:null},t=Re.updateQueue,t===null&&(t=ar(),Re.updateQueue=t),a=t.lastEffect,a===null?t.lastEffect=e.next=e:(i=a.next,a.next=e,e.next=i,t.lastEffect=e),e}function am(){return gt().memoizedState}function sr(e,t,a,i){var r=Gt();Re.flags|=e,r.memoizedState=Ti(1|t,{destroy:void 0},a,i===void 0?null:i)}function or(e,t,a,i){var r=gt();i=i===void 0?null:i;var c=r.memoizedState.inst;Je!==null&&i!==null&&du(i,Je.memoizedState.deps)?r.memoizedState=Ti(t,c,a,i):(Re.flags|=e,r.memoizedState=Ti(1|t,c,a,i))}function lm(e,t){sr(8390656,8,e,t)}function _u(e,t){or(2048,8,e,t)}function p2(e){Re.flags|=4;var t=Re.updateQueue;if(t===null)t=ar(),Re.updateQueue=t,t.events=[e];else{var a=t.events;a===null?t.events=[e]:a.push(e)}}function im(e){var t=gt().memoizedState;return p2({ref:t,nextImpl:e}),function(){if((Fe&2)!==0)throw Error(o(440));return t.impl.apply(void 0,arguments)}}function sm(e,t){return or(4,2,e,t)}function om(e,t){return or(4,4,e,t)}function rm(e,t){if(typeof t=="function"){e=e();var a=t(e);return function(){typeof a=="function"?a():t(null)}}if(t!=null)return e=e(),t.current=e,function(){t.current=null}}function cm(e,t,a){a=a!=null?a.concat([e]):null,or(4,4,rm.bind(null,t,e),a)}function wu(){}function um(e,t){var a=gt();t=t===void 0?null:t;var i=a.memoizedState;return t!==null&&du(t,i[1])?i[0]:(a.memoizedState=[e,t],e)}function dm(e,t){var a=gt();t=t===void 0?null:t;var i=a.memoizedState;if(t!==null&&du(t,i[1]))return i[0];if(i=e(),Cl){ne(!0);try{e()}finally{ne(!1)}}return a.memoizedState=[i,t],i}function Su(e,t,a){return a===void 0||(Wn&1073741824)!==0&&(Ge&261930)===0?e.memoizedState=t:(e.memoizedState=a,e=fy(),Re.lanes|=e,Ua|=e,a)}function fm(e,t,a,i){return tn(a,t)?a:Ci.current!==null?(e=Su(e,a,i),tn(e,t)||(xt=!0),e):(Wn&42)===0||(Wn&1073741824)!==0&&(Ge&261930)===0?(xt=!0,e.memoizedState=a):(e=fy(),Re.lanes|=e,Ua|=e,t)}function hm(e,t,a,i,r){var c=Z.p;Z.p=c!==0&&8>c?c:8;var m=w.T,b={};w.T=b,ju(e,!1,t,a);try{var C=r(),K=w.S;if(K!==null&&K(b,C),C!==null&&typeof C=="object"&&typeof C.then=="function"){var le=c2(C,i);zs(e,t,le,rn(e))}else zs(e,t,i,rn(e))}catch(oe){zs(e,t,{then:function(){},status:"rejected",reason:oe},rn())}finally{Z.p=c,m!==null&&b.types!==null&&(m.types=b.types),w.T=m}}function m2(){}function ku(e,t,a,i){if(e.tag!==5)throw Error(o(476));var r=pm(e).queue;hm(e,r,t,ue,a===null?m2:function(){return mm(e),a(i)})}function pm(e){var t=e.memoizedState;if(t!==null)return t;t={memoizedState:ue,baseState:ue,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:ea,lastRenderedState:ue},next:null};var a={};return t.next={memoizedState:a,baseState:a,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:ea,lastRenderedState:a},next:null},e.memoizedState=t,e=e.alternate,e!==null&&(e.memoizedState=t),t}function mm(e){var t=pm(e);t.next===null&&(t=e.alternate.memoizedState),zs(e,t.next.queue,{},rn())}function Eu(){return Nt(Ps)}function ym(){return gt().memoizedState}function gm(){return gt().memoizedState}function y2(e){for(var t=e.return;t!==null;){switch(t.tag){case 24:case 3:var a=rn();e=Na(a);var i=Ta(t,e,a);i!==null&&(Zt(i,t,a),As(i,t,a)),t={cache:eu()},e.payload=t;return}t=t.return}}function g2(e,t,a){var i=rn();a={lane:i,revertLane:0,gesture:null,action:a,hasEagerState:!1,eagerState:null,next:null},rr(e)?vm(t,a):(a=Qc(e,t,a,i),a!==null&&(Zt(a,e,i),xm(a,t,i)))}function bm(e,t,a){var i=rn();zs(e,t,a,i)}function zs(e,t,a,i){var r={lane:i,revertLane:0,gesture:null,action:a,hasEagerState:!1,eagerState:null,next:null};if(rr(e))vm(t,r);else{var c=e.alternate;if(e.lanes===0&&(c===null||c.lanes===0)&&(c=t.lastRenderedReducer,c!==null))try{var m=t.lastRenderedState,b=c(m,a);if(r.hasEagerState=!0,r.eagerState=b,tn(b,m))return Io(e,t,r,0),tt===null&&Go(),!1}catch{}finally{}if(a=Qc(e,t,r,i),a!==null)return Zt(a,e,i),xm(a,t,i),!0}return!1}function ju(e,t,a,i){if(i={lane:2,revertLane:ld(),gesture:null,action:i,hasEagerState:!1,eagerState:null,next:null},rr(e)){if(t)throw Error(o(479))}else t=Qc(e,a,i,2),t!==null&&Zt(t,e,2)}function rr(e){var t=e.alternate;return e===Re||t!==null&&t===Re}function vm(e,t){Ai=tr=!0;var a=e.pending;a===null?t.next=t:(t.next=a.next,a.next=t),e.pending=t}function xm(e,t,a){if((a&4194048)!==0){var i=t.lanes;i&=e.pendingLanes,a|=i,t.lanes=a,Eh(e,a)}}var Ds={readContext:Nt,use:lr,useCallback:ut,useContext:ut,useEffect:ut,useImperativeHandle:ut,useLayoutEffect:ut,useInsertionEffect:ut,useMemo:ut,useReducer:ut,useRef:ut,useState:ut,useDebugValue:ut,useDeferredValue:ut,useTransition:ut,useSyncExternalStore:ut,useId:ut,useHostTransitionStatus:ut,useFormState:ut,useActionState:ut,useOptimistic:ut,useMemoCache:ut,useCacheRefresh:ut};Ds.useEffectEvent=ut;var _m={readContext:Nt,use:lr,useCallback:function(e,t){return Gt().memoizedState=[e,t===void 0?null:t],e},useContext:Nt,useEffect:lm,useImperativeHandle:function(e,t,a){a=a!=null?a.concat([e]):null,sr(4194308,4,rm.bind(null,t,e),a)},useLayoutEffect:function(e,t){return sr(4194308,4,e,t)},useInsertionEffect:function(e,t){sr(4,2,e,t)},useMemo:function(e,t){var a=Gt();t=t===void 0?null:t;var i=e();if(Cl){ne(!0);try{e()}finally{ne(!1)}}return a.memoizedState=[i,t],i},useReducer:function(e,t,a){var i=Gt();if(a!==void 0){var r=a(t);if(Cl){ne(!0);try{a(t)}finally{ne(!1)}}}else r=t;return i.memoizedState=i.baseState=r,e={pending:null,lanes:0,dispatch:null,lastRenderedReducer:e,lastRenderedState:r},i.queue=e,e=e.dispatch=g2.bind(null,Re,e),[i.memoizedState,e]},useRef:function(e){var t=Gt();return e={current:e},t.memoizedState=e},useState:function(e){e=vu(e);var t=e.queue,a=bm.bind(null,Re,t);return t.dispatch=a,[e.memoizedState,a]},useDebugValue:wu,useDeferredValue:function(e,t){var a=Gt();return Su(a,e,t)},useTransition:function(){var e=vu(!1);return e=hm.bind(null,Re,e.queue,!0,!1),Gt().memoizedState=e,[!1,e]},useSyncExternalStore:function(e,t,a){var i=Re,r=Gt();if(Qe){if(a===void 0)throw Error(o(407));a=a()}else{if(a=t(),tt===null)throw Error(o(349));(Ge&127)!==0||Ip(i,t,a)}r.memoizedState=a;var c={value:a,getSnapshot:t};return r.queue=c,lm(Kp.bind(null,i,c,e),[e]),i.flags|=2048,Ti(9,{destroy:void 0},Qp.bind(null,i,c,a,t),null),a},useId:function(){var e=Gt(),t=tt.identifierPrefix;if(Qe){var a=zn,i=Rn;a=(i&~(1<<32-pe(i)-1)).toString(32)+a,t="_"+t+"R_"+a,a=nr++,0<a&&(t+="H"+a.toString(32)),t+="_"}else a=u2++,t="_"+t+"r_"+a.toString(32)+"_";return e.memoizedState=t},useHostTransitionStatus:Eu,useFormState:Wp,useActionState:Wp,useOptimistic:function(e){var t=Gt();t.memoizedState=t.baseState=e;var a={pending:null,lanes:0,dispatch:null,lastRenderedReducer:null,lastRenderedState:null};return t.queue=a,t=ju.bind(null,Re,!0,a),a.dispatch=t,[e,t]},useMemoCache:yu,useCacheRefresh:function(){return Gt().memoizedState=y2.bind(null,Re)},useEffectEvent:function(e){var t=Gt(),a={impl:e};return t.memoizedState=a,function(){if((Fe&2)!==0)throw Error(o(440));return a.impl.apply(void 0,arguments)}}},Mu={readContext:Nt,use:lr,useCallback:um,useContext:Nt,useEffect:_u,useImperativeHandle:cm,useInsertionEffect:sm,useLayoutEffect:om,useMemo:dm,useReducer:ir,useRef:am,useState:function(){return ir(ea)},useDebugValue:wu,useDeferredValue:function(e,t){var a=gt();return fm(a,Je.memoizedState,e,t)},useTransition:function(){var e=ir(ea)[0],t=gt().memoizedState;return[typeof e=="boolean"?e:Rs(e),t]},useSyncExternalStore:Gp,useId:ym,useHostTransitionStatus:Eu,useFormState:em,useActionState:em,useOptimistic:function(e,t){var a=gt();return $p(a,Je,e,t)},useMemoCache:yu,useCacheRefresh:gm};Mu.useEffectEvent=im;var wm={readContext:Nt,use:lr,useCallback:um,useContext:Nt,useEffect:_u,useImperativeHandle:cm,useInsertionEffect:sm,useLayoutEffect:om,useMemo:dm,useReducer:bu,useRef:am,useState:function(){return bu(ea)},useDebugValue:wu,useDeferredValue:function(e,t){var a=gt();return Je===null?Su(a,e,t):fm(a,Je.memoizedState,e,t)},useTransition:function(){var e=bu(ea)[0],t=gt().memoizedState;return[typeof e=="boolean"?e:Rs(e),t]},useSyncExternalStore:Gp,useId:ym,useHostTransitionStatus:Eu,useFormState:nm,useActionState:nm,useOptimistic:function(e,t){var a=gt();return Je!==null?$p(a,Je,e,t):(a.baseState=e,[e,a.queue.dispatch])},useMemoCache:yu,useCacheRefresh:gm};wm.useEffectEvent=im;function Cu(e,t,a,i){t=e.memoizedState,a=a(i,t),a=a==null?t:v({},t,a),e.memoizedState=a,e.lanes===0&&(e.updateQueue.baseState=a)}var Au={enqueueSetState:function(e,t,a){e=e._reactInternals;var i=rn(),r=Na(i);r.payload=t,a!=null&&(r.callback=a),t=Ta(e,r,i),t!==null&&(Zt(t,e,i),As(t,e,i))},enqueueReplaceState:function(e,t,a){e=e._reactInternals;var i=rn(),r=Na(i);r.tag=1,r.payload=t,a!=null&&(r.callback=a),t=Ta(e,r,i),t!==null&&(Zt(t,e,i),As(t,e,i))},enqueueForceUpdate:function(e,t){e=e._reactInternals;var a=rn(),i=Na(a);i.tag=2,t!=null&&(i.callback=t),t=Ta(e,i,a),t!==null&&(Zt(t,e,a),As(t,e,a))}};function Sm(e,t,a,i,r,c,m){return e=e.stateNode,typeof e.shouldComponentUpdate=="function"?e.shouldComponentUpdate(i,c,m):t.prototype&&t.prototype.isPureReactComponent?!_s(a,i)||!_s(r,c):!0}function km(e,t,a,i){e=t.state,typeof t.componentWillReceiveProps=="function"&&t.componentWillReceiveProps(a,i),typeof t.UNSAFE_componentWillReceiveProps=="function"&&t.UNSAFE_componentWillReceiveProps(a,i),t.state!==e&&Au.enqueueReplaceState(t,t.state,null)}function Al(e,t){var a=t;if("ref"in t){a={};for(var i in t)i!=="ref"&&(a[i]=t[i])}if(e=e.defaultProps){a===t&&(a=v({},a));for(var r in e)a[r]===void 0&&(a[r]=e[r])}return a}function Em(e){qo(e)}function jm(e){console.error(e)}function Mm(e){qo(e)}function cr(e,t){try{var a=e.onUncaughtError;a(t.value,{componentStack:t.stack})}catch(i){setTimeout(function(){throw i})}}function Cm(e,t,a){try{var i=e.onCaughtError;i(a.value,{componentStack:a.stack,errorBoundary:t.tag===1?t.stateNode:null})}catch(r){setTimeout(function(){throw r})}}function Nu(e,t,a){return a=Na(a),a.tag=3,a.payload={element:null},a.callback=function(){cr(e,t)},a}function Am(e){return e=Na(e),e.tag=3,e}function Nm(e,t,a,i){var r=a.type.getDerivedStateFromError;if(typeof r=="function"){var c=i.value;e.payload=function(){return r(c)},e.callback=function(){Cm(t,a,i)}}var m=a.stateNode;m!==null&&typeof m.componentDidCatch=="function"&&(e.callback=function(){Cm(t,a,i),typeof r!="function"&&(La===null?La=new Set([this]):La.add(this));var b=i.stack;this.componentDidCatch(i.value,{componentStack:b!==null?b:""})})}function b2(e,t,a,i,r){if(a.flags|=32768,i!==null&&typeof i=="object"&&typeof i.then=="function"){if(t=a.alternate,t!==null&&Si(t,a,r,!0),a=an.current,a!==null){switch(a.tag){case 31:case 13:return _n===null?_r():a.alternate===null&&dt===0&&(dt=3),a.flags&=-257,a.flags|=65536,a.lanes=r,i===Zo?a.flags|=16384:(t=a.updateQueue,t===null?a.updateQueue=new Set([i]):t.add(i),td(e,i,r)),!1;case 22:return a.flags|=65536,i===Zo?a.flags|=16384:(t=a.updateQueue,t===null?(t={transitions:null,markerInstances:null,retryQueue:new Set([i])},a.updateQueue=t):(a=t.retryQueue,a===null?t.retryQueue=new Set([i]):a.add(i)),td(e,i,r)),!1}throw Error(o(435,a.tag))}return td(e,i,r),_r(),!1}if(Qe)return t=an.current,t!==null?((t.flags&65536)===0&&(t.flags|=256),t.flags|=65536,t.lanes=r,i!==Xc&&(e=Error(o(422),{cause:i}),ks(gn(e,a)))):(i!==Xc&&(t=Error(o(423),{cause:i}),ks(gn(t,a))),e=e.current.alternate,e.flags|=65536,r&=-r,e.lanes|=r,i=gn(i,a),r=Nu(e.stateNode,i,r),su(e,r),dt!==4&&(dt=2)),!1;var c=Error(o(520),{cause:i});if(c=gn(c,a),Qs===null?Qs=[c]:Qs.push(c),dt!==4&&(dt=2),t===null)return!0;i=gn(i,a),a=t;do{switch(a.tag){case 3:return a.flags|=65536,e=r&-r,a.lanes|=e,e=Nu(a.stateNode,i,e),su(a,e),!1;case 1:if(t=a.type,c=a.stateNode,(a.flags&128)===0&&(typeof t.getDerivedStateFromError=="function"||c!==null&&typeof c.componentDidCatch=="function"&&(La===null||!La.has(c))))return a.flags|=65536,r&=-r,a.lanes|=r,r=Am(r),Nm(r,e,a,i),su(a,r),!1}a=a.return}while(a!==null);return!1}var Tu=Error(o(461)),xt=!1;function Tt(e,t,a,i){t.child=e===null?zp(t,null,a,i):Ml(t,e.child,a,i)}function Tm(e,t,a,i,r){a=a.render;var c=t.ref;if("ref"in i){var m={};for(var b in i)b!=="ref"&&(m[b]=i[b])}else m=i;return Sl(t),i=fu(e,t,a,m,c,r),b=hu(),e!==null&&!xt?(pu(e,t,r),ta(e,t,r)):(Qe&&b&&$c(t),t.flags|=1,Tt(e,t,i,r),t.child)}function Om(e,t,a,i,r){if(e===null){var c=a.type;return typeof c=="function"&&!Kc(c)&&c.defaultProps===void 0&&a.compare===null?(t.tag=15,t.type=c,Rm(e,t,c,i,r)):(e=Ko(a.type,null,i,t,t.mode,r),e.ref=t.ref,e.return=t,t.child=e)}if(c=e.child,!Hu(e,r)){var m=c.memoizedProps;if(a=a.compare,a=a!==null?a:_s,a(m,i)&&e.ref===t.ref)return ta(e,t,r)}return t.flags|=1,e=Xn(c,i),e.ref=t.ref,e.return=t,t.child=e}function Rm(e,t,a,i,r){if(e!==null){var c=e.memoizedProps;if(_s(c,i)&&e.ref===t.ref)if(xt=!1,t.pendingProps=i=c,Hu(e,r))(e.flags&131072)!==0&&(xt=!0);else return t.lanes=e.lanes,ta(e,t,r)}return Ou(e,t,a,i,r)}function zm(e,t,a,i){var r=i.children,c=e!==null?e.memoizedState:null;if(e===null&&t.stateNode===null&&(t.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null}),i.mode==="hidden"){if((t.flags&128)!==0){if(c=c!==null?c.baseLanes|a:a,e!==null){for(i=t.child=e.child,r=0;i!==null;)r=r|i.lanes|i.childLanes,i=i.sibling;i=r&~c}else i=0,t.child=null;return Dm(e,t,c,a,i)}if((a&536870912)!==0)t.memoizedState={baseLanes:0,cachePool:null},e!==null&&Fo(t,c!==null?c.cachePool:null),c!==null?Lp(t,c):ru(),Bp(t);else return i=t.lanes=536870912,Dm(e,t,c!==null?c.baseLanes|a:a,a,i)}else c!==null?(Fo(t,c.cachePool),Lp(t,c),Ra(),t.memoizedState=null):(e!==null&&Fo(t,null),ru(),Ra());return Tt(e,t,r,a),t.child}function Us(e,t){return e!==null&&e.tag===22||t.stateNode!==null||(t.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null}),t.sibling}function Dm(e,t,a,i,r){var c=nu();return c=c===null?null:{parent:bt._currentValue,pool:c},t.memoizedState={baseLanes:a,cachePool:c},e!==null&&Fo(t,null),ru(),Bp(t),e!==null&&Si(e,t,i,!0),t.childLanes=r,null}function ur(e,t){return t=fr({mode:t.mode,children:t.children},e.mode),t.ref=e.ref,e.child=t,t.return=e,t}function Um(e,t,a){return Ml(t,e.child,null,a),e=ur(t,t.pendingProps),e.flags|=2,ln(t),t.memoizedState=null,e}function v2(e,t,a){var i=t.pendingProps,r=(t.flags&128)!==0;if(t.flags&=-129,e===null){if(Qe){if(i.mode==="hidden")return e=ur(t,i),t.lanes=536870912,Us(null,e);if(uu(t),(e=at)?(e=Fy(e,xn),e=e!==null&&e.data==="&"?e:null,e!==null&&(t.memoizedState={dehydrated:e,treeContext:Ea!==null?{id:Rn,overflow:zn}:null,retryLane:536870912,hydrationErrors:null},a=vp(e),a.return=t,t.child=a,At=t,at=null)):e=null,e===null)throw Ma(t);return t.lanes=536870912,null}return ur(t,i)}var c=e.memoizedState;if(c!==null){var m=c.dehydrated;if(uu(t),r)if(t.flags&256)t.flags&=-257,t=Um(e,t,a);else if(t.memoizedState!==null)t.child=e.child,t.flags|=128,t=null;else throw Error(o(558));else if(xt||Si(e,t,a,!1),r=(a&e.childLanes)!==0,xt||r){if(i=tt,i!==null&&(m=jh(i,a),m!==0&&m!==c.retryLane))throw c.retryLane=m,vl(e,m),Zt(i,e,m),Tu;_r(),t=Um(e,t,a)}else e=c.treeContext,at=wn(m.nextSibling),At=t,Qe=!0,ja=null,xn=!1,e!==null&&wp(t,e),t=ur(t,i),t.flags|=4096;return t}return e=Xn(e.child,{mode:i.mode,children:i.children}),e.ref=t.ref,t.child=e,e.return=t,e}function dr(e,t){var a=t.ref;if(a===null)e!==null&&e.ref!==null&&(t.flags|=4194816);else{if(typeof a!="function"&&typeof a!="object")throw Error(o(284));(e===null||e.ref!==a)&&(t.flags|=4194816)}}function Ou(e,t,a,i,r){return Sl(t),a=fu(e,t,a,i,void 0,r),i=hu(),e!==null&&!xt?(pu(e,t,r),ta(e,t,r)):(Qe&&i&&$c(t),t.flags|=1,Tt(e,t,a,r),t.child)}function Lm(e,t,a,i,r,c){return Sl(t),t.updateQueue=null,a=qp(t,i,a,r),Hp(e),i=hu(),e!==null&&!xt?(pu(e,t,c),ta(e,t,c)):(Qe&&i&&$c(t),t.flags|=1,Tt(e,t,a,c),t.child)}function Bm(e,t,a,i,r){if(Sl(t),t.stateNode===null){var c=vi,m=a.contextType;typeof m=="object"&&m!==null&&(c=Nt(m)),c=new a(i,c),t.memoizedState=c.state!==null&&c.state!==void 0?c.state:null,c.updater=Au,t.stateNode=c,c._reactInternals=t,c=t.stateNode,c.props=i,c.state=t.memoizedState,c.refs={},lu(t),m=a.contextType,c.context=typeof m=="object"&&m!==null?Nt(m):vi,c.state=t.memoizedState,m=a.getDerivedStateFromProps,typeof m=="function"&&(Cu(t,a,m,i),c.state=t.memoizedState),typeof a.getDerivedStateFromProps=="function"||typeof c.getSnapshotBeforeUpdate=="function"||typeof c.UNSAFE_componentWillMount!="function"&&typeof c.componentWillMount!="function"||(m=c.state,typeof c.componentWillMount=="function"&&c.componentWillMount(),typeof c.UNSAFE_componentWillMount=="function"&&c.UNSAFE_componentWillMount(),m!==c.state&&Au.enqueueReplaceState(c,c.state,null),Ts(t,i,c,r),Ns(),c.state=t.memoizedState),typeof c.componentDidMount=="function"&&(t.flags|=4194308),i=!0}else if(e===null){c=t.stateNode;var b=t.memoizedProps,C=Al(a,b);c.props=C;var K=c.context,le=a.contextType;m=vi,typeof le=="object"&&le!==null&&(m=Nt(le));var oe=a.getDerivedStateFromProps;le=typeof oe=="function"||typeof c.getSnapshotBeforeUpdate=="function",b=t.pendingProps!==b,le||typeof c.UNSAFE_componentWillReceiveProps!="function"&&typeof c.componentWillReceiveProps!="function"||(b||K!==m)&&km(t,c,i,m),Aa=!1;var X=t.memoizedState;c.state=X,Ts(t,i,c,r),Ns(),K=t.memoizedState,b||X!==K||Aa?(typeof oe=="function"&&(Cu(t,a,oe,i),K=t.memoizedState),(C=Aa||Sm(t,a,C,i,X,K,m))?(le||typeof c.UNSAFE_componentWillMount!="function"&&typeof c.componentWillMount!="function"||(typeof c.componentWillMount=="function"&&c.componentWillMount(),typeof c.UNSAFE_componentWillMount=="function"&&c.UNSAFE_componentWillMount()),typeof c.componentDidMount=="function"&&(t.flags|=4194308)):(typeof c.componentDidMount=="function"&&(t.flags|=4194308),t.memoizedProps=i,t.memoizedState=K),c.props=i,c.state=K,c.context=m,i=C):(typeof c.componentDidMount=="function"&&(t.flags|=4194308),i=!1)}else{c=t.stateNode,iu(e,t),m=t.memoizedProps,le=Al(a,m),c.props=le,oe=t.pendingProps,X=c.context,K=a.contextType,C=vi,typeof K=="object"&&K!==null&&(C=Nt(K)),b=a.getDerivedStateFromProps,(K=typeof b=="function"||typeof c.getSnapshotBeforeUpdate=="function")||typeof c.UNSAFE_componentWillReceiveProps!="function"&&typeof c.componentWillReceiveProps!="function"||(m!==oe||X!==C)&&km(t,c,i,C),Aa=!1,X=t.memoizedState,c.state=X,Ts(t,i,c,r),Ns();var J=t.memoizedState;m!==oe||X!==J||Aa||e!==null&&e.dependencies!==null&&Yo(e.dependencies)?(typeof b=="function"&&(Cu(t,a,b,i),J=t.memoizedState),(le=Aa||Sm(t,a,le,i,X,J,C)||e!==null&&e.dependencies!==null&&Yo(e.dependencies))?(K||typeof c.UNSAFE_componentWillUpdate!="function"&&typeof c.componentWillUpdate!="function"||(typeof c.componentWillUpdate=="function"&&c.componentWillUpdate(i,J,C),typeof c.UNSAFE_componentWillUpdate=="function"&&c.UNSAFE_componentWillUpdate(i,J,C)),typeof c.componentDidUpdate=="function"&&(t.flags|=4),typeof c.getSnapshotBeforeUpdate=="function"&&(t.flags|=1024)):(typeof c.componentDidUpdate!="function"||m===e.memoizedProps&&X===e.memoizedState||(t.flags|=4),typeof c.getSnapshotBeforeUpdate!="function"||m===e.memoizedProps&&X===e.memoizedState||(t.flags|=1024),t.memoizedProps=i,t.memoizedState=J),c.props=i,c.state=J,c.context=C,i=le):(typeof c.componentDidUpdate!="function"||m===e.memoizedProps&&X===e.memoizedState||(t.flags|=4),typeof c.getSnapshotBeforeUpdate!="function"||m===e.memoizedProps&&X===e.memoizedState||(t.flags|=1024),i=!1)}return c=i,dr(e,t),i=(t.flags&128)!==0,c||i?(c=t.stateNode,a=i&&typeof a.getDerivedStateFromError!="function"?null:c.render(),t.flags|=1,e!==null&&i?(t.child=Ml(t,e.child,null,r),t.child=Ml(t,null,a,r)):Tt(e,t,a,r),t.memoizedState=c.state,e=t.child):e=ta(e,t,r),e}function Hm(e,t,a,i){return _l(),t.flags|=256,Tt(e,t,a,i),t.child}var Ru={dehydrated:null,treeContext:null,retryLane:0,hydrationErrors:null};function zu(e){return{baseLanes:e,cachePool:Cp()}}function Du(e,t,a){return e=e!==null?e.childLanes&~a:0,t&&(e|=on),e}function qm(e,t,a){var i=t.pendingProps,r=!1,c=(t.flags&128)!==0,m;if((m=c)||(m=e!==null&&e.memoizedState===null?!1:(yt.current&2)!==0),m&&(r=!0,t.flags&=-129),m=(t.flags&32)!==0,t.flags&=-33,e===null){if(Qe){if(r?Oa(t):Ra(),(e=at)?(e=Fy(e,xn),e=e!==null&&e.data!=="&"?e:null,e!==null&&(t.memoizedState={dehydrated:e,treeContext:Ea!==null?{id:Rn,overflow:zn}:null,retryLane:536870912,hydrationErrors:null},a=vp(e),a.return=t,t.child=a,At=t,at=null)):e=null,e===null)throw Ma(t);return gd(e)?t.lanes=32:t.lanes=536870912,null}var b=i.children;return i=i.fallback,r?(Ra(),r=t.mode,b=fr({mode:"hidden",children:b},r),i=xl(i,r,a,null),b.return=t,i.return=t,b.sibling=i,t.child=b,i=t.child,i.memoizedState=zu(a),i.childLanes=Du(e,m,a),t.memoizedState=Ru,Us(null,i)):(Oa(t),Uu(t,b))}var C=e.memoizedState;if(C!==null&&(b=C.dehydrated,b!==null)){if(c)t.flags&256?(Oa(t),t.flags&=-257,t=Lu(e,t,a)):t.memoizedState!==null?(Ra(),t.child=e.child,t.flags|=128,t=null):(Ra(),b=i.fallback,r=t.mode,i=fr({mode:"visible",children:i.children},r),b=xl(b,r,a,null),b.flags|=2,i.return=t,b.return=t,i.sibling=b,t.child=i,Ml(t,e.child,null,a),i=t.child,i.memoizedState=zu(a),i.childLanes=Du(e,m,a),t.memoizedState=Ru,t=Us(null,i));else if(Oa(t),gd(b)){if(m=b.nextSibling&&b.nextSibling.dataset,m)var K=m.dgst;m=K,i=Error(o(419)),i.stack="",i.digest=m,ks({value:i,source:null,stack:null}),t=Lu(e,t,a)}else if(xt||Si(e,t,a,!1),m=(a&e.childLanes)!==0,xt||m){if(m=tt,m!==null&&(i=jh(m,a),i!==0&&i!==C.retryLane))throw C.retryLane=i,vl(e,i),Zt(m,e,i),Tu;yd(b)||_r(),t=Lu(e,t,a)}else yd(b)?(t.flags|=192,t.child=e.child,t=null):(e=C.treeContext,at=wn(b.nextSibling),At=t,Qe=!0,ja=null,xn=!1,e!==null&&wp(t,e),t=Uu(t,i.children),t.flags|=4096);return t}return r?(Ra(),b=i.fallback,r=t.mode,C=e.child,K=C.sibling,i=Xn(C,{mode:"hidden",children:i.children}),i.subtreeFlags=C.subtreeFlags&65011712,K!==null?b=Xn(K,b):(b=xl(b,r,a,null),b.flags|=2),b.return=t,i.return=t,i.sibling=b,t.child=i,Us(null,i),i=t.child,b=e.child.memoizedState,b===null?b=zu(a):(r=b.cachePool,r!==null?(C=bt._currentValue,r=r.parent!==C?{parent:C,pool:C}:r):r=Cp(),b={baseLanes:b.baseLanes|a,cachePool:r}),i.memoizedState=b,i.childLanes=Du(e,m,a),t.memoizedState=Ru,Us(e.child,i)):(Oa(t),a=e.child,e=a.sibling,a=Xn(a,{mode:"visible",children:i.children}),a.return=t,a.sibling=null,e!==null&&(m=t.deletions,m===null?(t.deletions=[e],t.flags|=16):m.push(e)),t.child=a,t.memoizedState=null,a)}function Uu(e,t){return t=fr({mode:"visible",children:t},e.mode),t.return=e,e.child=t}function fr(e,t){return e=nn(22,e,null,t),e.lanes=0,e}function Lu(e,t,a){return Ml(t,e.child,null,a),e=Uu(t,t.pendingProps.children),e.flags|=2,t.memoizedState=null,e}function Gm(e,t,a){e.lanes|=t;var i=e.alternate;i!==null&&(i.lanes|=t),Jc(e.return,t,a)}function Bu(e,t,a,i,r,c){var m=e.memoizedState;m===null?e.memoizedState={isBackwards:t,rendering:null,renderingStartTime:0,last:i,tail:a,tailMode:r,treeForkCount:c}:(m.isBackwards=t,m.rendering=null,m.renderingStartTime=0,m.last=i,m.tail=a,m.tailMode=r,m.treeForkCount=c)}function Im(e,t,a){var i=t.pendingProps,r=i.revealOrder,c=i.tail;i=i.children;var m=yt.current,b=(m&2)!==0;if(b?(m=m&1|2,t.flags|=128):m&=1,$(yt,m),Tt(e,t,i,a),i=Qe?Ss:0,!b&&e!==null&&(e.flags&128)!==0)e:for(e=t.child;e!==null;){if(e.tag===13)e.memoizedState!==null&&Gm(e,a,t);else if(e.tag===19)Gm(e,a,t);else if(e.child!==null){e.child.return=e,e=e.child;continue}if(e===t)break e;for(;e.sibling===null;){if(e.return===null||e.return===t)break e;e=e.return}e.sibling.return=e.return,e=e.sibling}switch(r){case"forwards":for(a=t.child,r=null;a!==null;)e=a.alternate,e!==null&&er(e)===null&&(r=a),a=a.sibling;a=r,a===null?(r=t.child,t.child=null):(r=a.sibling,a.sibling=null),Bu(t,!1,r,a,c,i);break;case"backwards":case"unstable_legacy-backwards":for(a=null,r=t.child,t.child=null;r!==null;){if(e=r.alternate,e!==null&&er(e)===null){t.child=r;break}e=r.sibling,r.sibling=a,a=r,r=e}Bu(t,!0,a,null,c,i);break;case"together":Bu(t,!1,null,null,void 0,i);break;default:t.memoizedState=null}return t.child}function ta(e,t,a){if(e!==null&&(t.dependencies=e.dependencies),Ua|=t.lanes,(a&t.childLanes)===0)if(e!==null){if(Si(e,t,a,!1),(a&t.childLanes)===0)return null}else return null;if(e!==null&&t.child!==e.child)throw Error(o(153));if(t.child!==null){for(e=t.child,a=Xn(e,e.pendingProps),t.child=a,a.return=t;e.sibling!==null;)e=e.sibling,a=a.sibling=Xn(e,e.pendingProps),a.return=t;a.sibling=null}return t.child}function Hu(e,t){return(e.lanes&t)!==0?!0:(e=e.dependencies,!!(e!==null&&Yo(e)))}function x2(e,t,a){switch(t.tag){case 3:me(t,t.stateNode.containerInfo),Ca(t,bt,e.memoizedState.cache),_l();break;case 27:case 5:ke(t);break;case 4:me(t,t.stateNode.containerInfo);break;case 10:Ca(t,t.type,t.memoizedProps.value);break;case 31:if(t.memoizedState!==null)return t.flags|=128,uu(t),null;break;case 13:var i=t.memoizedState;if(i!==null)return i.dehydrated!==null?(Oa(t),t.flags|=128,null):(a&t.child.childLanes)!==0?qm(e,t,a):(Oa(t),e=ta(e,t,a),e!==null?e.sibling:null);Oa(t);break;case 19:var r=(e.flags&128)!==0;if(i=(a&t.childLanes)!==0,i||(Si(e,t,a,!1),i=(a&t.childLanes)!==0),r){if(i)return Im(e,t,a);t.flags|=128}if(r=t.memoizedState,r!==null&&(r.rendering=null,r.tail=null,r.lastEffect=null),$(yt,yt.current),i)break;return null;case 22:return t.lanes=0,zm(e,t,a,t.pendingProps);case 24:Ca(t,bt,e.memoizedState.cache)}return ta(e,t,a)}function Qm(e,t,a){if(e!==null)if(e.memoizedProps!==t.pendingProps)xt=!0;else{if(!Hu(e,a)&&(t.flags&128)===0)return xt=!1,x2(e,t,a);xt=(e.flags&131072)!==0}else xt=!1,Qe&&(t.flags&1048576)!==0&&_p(t,Ss,t.index);switch(t.lanes=0,t.tag){case 16:e:{var i=t.pendingProps;if(e=El(t.elementType),t.type=e,typeof e=="function")Kc(e)?(i=Al(e,i),t.tag=1,t=Bm(null,t,e,i,a)):(t.tag=0,t=Ou(null,t,e,i,a));else{if(e!=null){var r=e.$$typeof;if(r===Y){t.tag=11,t=Tm(null,t,e,i,a);break e}else if(r===ae){t.tag=14,t=Om(null,t,e,i,a);break e}}throw t=G(e)||e,Error(o(306,t,""))}}return t;case 0:return Ou(e,t,t.type,t.pendingProps,a);case 1:return i=t.type,r=Al(i,t.pendingProps),Bm(e,t,i,r,a);case 3:e:{if(me(t,t.stateNode.containerInfo),e===null)throw Error(o(387));i=t.pendingProps;var c=t.memoizedState;r=c.element,iu(e,t),Ts(t,i,null,a);var m=t.memoizedState;if(i=m.cache,Ca(t,bt,i),i!==c.cache&&Wc(t,[bt],a,!0),Ns(),i=m.element,c.isDehydrated)if(c={element:i,isDehydrated:!1,cache:m.cache},t.updateQueue.baseState=c,t.memoizedState=c,t.flags&256){t=Hm(e,t,i,a);break e}else if(i!==r){r=gn(Error(o(424)),t),ks(r),t=Hm(e,t,i,a);break e}else{switch(e=t.stateNode.containerInfo,e.nodeType){case 9:e=e.body;break;default:e=e.nodeName==="HTML"?e.ownerDocument.body:e}for(at=wn(e.firstChild),At=t,Qe=!0,ja=null,xn=!0,a=zp(t,null,i,a),t.child=a;a;)a.flags=a.flags&-3|4096,a=a.sibling}else{if(_l(),i===r){t=ta(e,t,a);break e}Tt(e,t,i,a)}t=t.child}return t;case 26:return dr(e,t),e===null?(a=eg(t.type,null,t.pendingProps,null))?t.memoizedState=a:Qe||(a=t.type,e=t.pendingProps,i=Cr(q.current).createElement(a),i[Ct]=t,i[Kt]=e,Ot(i,a,e),Et(i),t.stateNode=i):t.memoizedState=eg(t.type,e.memoizedProps,t.pendingProps,e.memoizedState),null;case 27:return ke(t),e===null&&Qe&&(i=t.stateNode=Py(t.type,t.pendingProps,q.current),At=t,xn=!0,r=at,Ga(t.type)?(bd=r,at=wn(i.firstChild)):at=r),Tt(e,t,t.pendingProps.children,a),dr(e,t),e===null&&(t.flags|=4194304),t.child;case 5:return e===null&&Qe&&((r=i=at)&&(i=Z2(i,t.type,t.pendingProps,xn),i!==null?(t.stateNode=i,At=t,at=wn(i.firstChild),xn=!1,r=!0):r=!1),r||Ma(t)),ke(t),r=t.type,c=t.pendingProps,m=e!==null?e.memoizedProps:null,i=c.children,hd(r,c)?i=null:m!==null&&hd(r,m)&&(t.flags|=32),t.memoizedState!==null&&(r=fu(e,t,d2,null,null,a),Ps._currentValue=r),dr(e,t),Tt(e,t,i,a),t.child;case 6:return e===null&&Qe&&((e=a=at)&&(a=P2(a,t.pendingProps,xn),a!==null?(t.stateNode=a,At=t,at=null,e=!0):e=!1),e||Ma(t)),null;case 13:return qm(e,t,a);case 4:return me(t,t.stateNode.containerInfo),i=t.pendingProps,e===null?t.child=Ml(t,null,i,a):Tt(e,t,i,a),t.child;case 11:return Tm(e,t,t.type,t.pendingProps,a);case 7:return Tt(e,t,t.pendingProps,a),t.child;case 8:return Tt(e,t,t.pendingProps.children,a),t.child;case 12:return Tt(e,t,t.pendingProps.children,a),t.child;case 10:return i=t.pendingProps,Ca(t,t.type,i.value),Tt(e,t,i.children,a),t.child;case 9:return r=t.type._context,i=t.pendingProps.children,Sl(t),r=Nt(r),i=i(r),t.flags|=1,Tt(e,t,i,a),t.child;case 14:return Om(e,t,t.type,t.pendingProps,a);case 15:return Rm(e,t,t.type,t.pendingProps,a);case 19:return Im(e,t,a);case 31:return v2(e,t,a);case 22:return zm(e,t,a,t.pendingProps);case 24:return Sl(t),i=Nt(bt),e===null?(r=nu(),r===null&&(r=tt,c=eu(),r.pooledCache=c,c.refCount++,c!==null&&(r.pooledCacheLanes|=a),r=c),t.memoizedState={parent:i,cache:r},lu(t),Ca(t,bt,r)):((e.lanes&a)!==0&&(iu(e,t),Ts(t,null,null,a),Ns()),r=e.memoizedState,c=t.memoizedState,r.parent!==i?(r={parent:i,cache:i},t.memoizedState=r,t.lanes===0&&(t.memoizedState=t.updateQueue.baseState=r),Ca(t,bt,i)):(i=c.cache,Ca(t,bt,i),i!==r.cache&&Wc(t,[bt],a,!0))),Tt(e,t,t.pendingProps.children,a),t.child;case 29:throw t.pendingProps}throw Error(o(156,t.tag))}function na(e){e.flags|=4}function qu(e,t,a,i,r){if((t=(e.mode&32)!==0)&&(t=!1),t){if(e.flags|=16777216,(r&335544128)===r)if(e.stateNode.complete)e.flags|=8192;else if(yy())e.flags|=8192;else throw jl=Zo,au}else e.flags&=-16777217}function Km(e,t){if(t.type!=="stylesheet"||(t.state.loading&4)!==0)e.flags&=-16777217;else if(e.flags|=16777216,!ig(t))if(yy())e.flags|=8192;else throw jl=Zo,au}function hr(e,t){t!==null&&(e.flags|=4),e.flags&16384&&(t=e.tag!==22?jn():536870912,e.lanes|=t,Di|=t)}function Ls(e,t){if(!Qe)switch(e.tailMode){case"hidden":t=e.tail;for(var a=null;t!==null;)t.alternate!==null&&(a=t),t=t.sibling;a===null?e.tail=null:a.sibling=null;break;case"collapsed":a=e.tail;for(var i=null;a!==null;)a.alternate!==null&&(i=a),a=a.sibling;i===null?t||e.tail===null?e.tail=null:e.tail.sibling=null:i.sibling=null}}function lt(e){var t=e.alternate!==null&&e.alternate.child===e.child,a=0,i=0;if(t)for(var r=e.child;r!==null;)a|=r.lanes|r.childLanes,i|=r.subtreeFlags&65011712,i|=r.flags&65011712,r.return=e,r=r.sibling;else for(r=e.child;r!==null;)a|=r.lanes|r.childLanes,i|=r.subtreeFlags,i|=r.flags,r.return=e,r=r.sibling;return e.subtreeFlags|=i,e.childLanes=a,t}function _2(e,t,a){var i=t.pendingProps;switch(Fc(t),t.tag){case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return lt(t),null;case 1:return lt(t),null;case 3:return a=t.stateNode,i=null,e!==null&&(i=e.memoizedState.cache),t.memoizedState.cache!==i&&(t.flags|=2048),Jn(bt),he(),a.pendingContext&&(a.context=a.pendingContext,a.pendingContext=null),(e===null||e.child===null)&&(wi(t)?na(t):e===null||e.memoizedState.isDehydrated&&(t.flags&256)===0||(t.flags|=1024,Zc())),lt(t),null;case 26:var r=t.type,c=t.memoizedState;return e===null?(na(t),c!==null?(lt(t),Km(t,c)):(lt(t),qu(t,r,null,i,a))):c?c!==e.memoizedState?(na(t),lt(t),Km(t,c)):(lt(t),t.flags&=-16777217):(e=e.memoizedProps,e!==i&&na(t),lt(t),qu(t,r,e,i,a)),null;case 27:if(Ae(t),a=q.current,r=t.type,e!==null&&t.stateNode!=null)e.memoizedProps!==i&&na(t);else{if(!i){if(t.stateNode===null)throw Error(o(166));return lt(t),null}e=T.current,wi(t)?Sp(t):(e=Py(r,i,a),t.stateNode=e,na(t))}return lt(t),null;case 5:if(Ae(t),r=t.type,e!==null&&t.stateNode!=null)e.memoizedProps!==i&&na(t);else{if(!i){if(t.stateNode===null)throw Error(o(166));return lt(t),null}if(c=T.current,wi(t))Sp(t);else{var m=Cr(q.current);switch(c){case 1:c=m.createElementNS("http://www.w3.org/2000/svg",r);break;case 2:c=m.createElementNS("http://www.w3.org/1998/Math/MathML",r);break;default:switch(r){case"svg":c=m.createElementNS("http://www.w3.org/2000/svg",r);break;case"math":c=m.createElementNS("http://www.w3.org/1998/Math/MathML",r);break;case"script":c=m.createElement("div"),c.innerHTML="<script><\/script>",c=c.removeChild(c.firstChild);break;case"select":c=typeof i.is=="string"?m.createElement("select",{is:i.is}):m.createElement("select"),i.multiple?c.multiple=!0:i.size&&(c.size=i.size);break;default:c=typeof i.is=="string"?m.createElement(r,{is:i.is}):m.createElement(r)}}c[Ct]=t,c[Kt]=i;e:for(m=t.child;m!==null;){if(m.tag===5||m.tag===6)c.appendChild(m.stateNode);else if(m.tag!==4&&m.tag!==27&&m.child!==null){m.child.return=m,m=m.child;continue}if(m===t)break e;for(;m.sibling===null;){if(m.return===null||m.return===t)break e;m=m.return}m.sibling.return=m.return,m=m.sibling}t.stateNode=c;e:switch(Ot(c,r,i),r){case"button":case"input":case"select":case"textarea":i=!!i.autoFocus;break e;case"img":i=!0;break e;default:i=!1}i&&na(t)}}return lt(t),qu(t,t.type,e===null?null:e.memoizedProps,t.pendingProps,a),null;case 6:if(e&&t.stateNode!=null)e.memoizedProps!==i&&na(t);else{if(typeof i!="string"&&t.stateNode===null)throw Error(o(166));if(e=q.current,wi(t)){if(e=t.stateNode,a=t.memoizedProps,i=null,r=At,r!==null)switch(r.tag){case 27:case 5:i=r.memoizedProps}e[Ct]=t,e=!!(e.nodeValue===a||i!==null&&i.suppressHydrationWarning===!0||qy(e.nodeValue,a)),e||Ma(t,!0)}else e=Cr(e).createTextNode(i),e[Ct]=t,t.stateNode=e}return lt(t),null;case 31:if(a=t.memoizedState,e===null||e.memoizedState!==null){if(i=wi(t),a!==null){if(e===null){if(!i)throw Error(o(318));if(e=t.memoizedState,e=e!==null?e.dehydrated:null,!e)throw Error(o(557));e[Ct]=t}else _l(),(t.flags&128)===0&&(t.memoizedState=null),t.flags|=4;lt(t),e=!1}else a=Zc(),e!==null&&e.memoizedState!==null&&(e.memoizedState.hydrationErrors=a),e=!0;if(!e)return t.flags&256?(ln(t),t):(ln(t),null);if((t.flags&128)!==0)throw Error(o(558))}return lt(t),null;case 13:if(i=t.memoizedState,e===null||e.memoizedState!==null&&e.memoizedState.dehydrated!==null){if(r=wi(t),i!==null&&i.dehydrated!==null){if(e===null){if(!r)throw Error(o(318));if(r=t.memoizedState,r=r!==null?r.dehydrated:null,!r)throw Error(o(317));r[Ct]=t}else _l(),(t.flags&128)===0&&(t.memoizedState=null),t.flags|=4;lt(t),r=!1}else r=Zc(),e!==null&&e.memoizedState!==null&&(e.memoizedState.hydrationErrors=r),r=!0;if(!r)return t.flags&256?(ln(t),t):(ln(t),null)}return ln(t),(t.flags&128)!==0?(t.lanes=a,t):(a=i!==null,e=e!==null&&e.memoizedState!==null,a&&(i=t.child,r=null,i.alternate!==null&&i.alternate.memoizedState!==null&&i.alternate.memoizedState.cachePool!==null&&(r=i.alternate.memoizedState.cachePool.pool),c=null,i.memoizedState!==null&&i.memoizedState.cachePool!==null&&(c=i.memoizedState.cachePool.pool),c!==r&&(i.flags|=2048)),a!==e&&a&&(t.child.flags|=8192),hr(t,t.updateQueue),lt(t),null);case 4:return he(),e===null&&rd(t.stateNode.containerInfo),lt(t),null;case 10:return Jn(t.type),lt(t),null;case 19:if(I(yt),i=t.memoizedState,i===null)return lt(t),null;if(r=(t.flags&128)!==0,c=i.rendering,c===null)if(r)Ls(i,!1);else{if(dt!==0||e!==null&&(e.flags&128)!==0)for(e=t.child;e!==null;){if(c=er(e),c!==null){for(t.flags|=128,Ls(i,!1),e=c.updateQueue,t.updateQueue=e,hr(t,e),t.subtreeFlags=0,e=a,a=t.child;a!==null;)bp(a,e),a=a.sibling;return $(yt,yt.current&1|2),Qe&&Zn(t,i.treeForkCount),t.child}e=e.sibling}i.tail!==null&&rt()>br&&(t.flags|=128,r=!0,Ls(i,!1),t.lanes=4194304)}else{if(!r)if(e=er(c),e!==null){if(t.flags|=128,r=!0,e=e.updateQueue,t.updateQueue=e,hr(t,e),Ls(i,!0),i.tail===null&&i.tailMode==="hidden"&&!c.alternate&&!Qe)return lt(t),null}else 2*rt()-i.renderingStartTime>br&&a!==536870912&&(t.flags|=128,r=!0,Ls(i,!1),t.lanes=4194304);i.isBackwards?(c.sibling=t.child,t.child=c):(e=i.last,e!==null?e.sibling=c:t.child=c,i.last=c)}return i.tail!==null?(e=i.tail,i.rendering=e,i.tail=e.sibling,i.renderingStartTime=rt(),e.sibling=null,a=yt.current,$(yt,r?a&1|2:a&1),Qe&&Zn(t,i.treeForkCount),e):(lt(t),null);case 22:case 23:return ln(t),cu(),i=t.memoizedState!==null,e!==null?e.memoizedState!==null!==i&&(t.flags|=8192):i&&(t.flags|=8192),i?(a&536870912)!==0&&(t.flags&128)===0&&(lt(t),t.subtreeFlags&6&&(t.flags|=8192)):lt(t),a=t.updateQueue,a!==null&&hr(t,a.retryQueue),a=null,e!==null&&e.memoizedState!==null&&e.memoizedState.cachePool!==null&&(a=e.memoizedState.cachePool.pool),i=null,t.memoizedState!==null&&t.memoizedState.cachePool!==null&&(i=t.memoizedState.cachePool.pool),i!==a&&(t.flags|=2048),e!==null&&I(kl),null;case 24:return a=null,e!==null&&(a=e.memoizedState.cache),t.memoizedState.cache!==a&&(t.flags|=2048),Jn(bt),lt(t),null;case 25:return null;case 30:return null}throw Error(o(156,t.tag))}function w2(e,t){switch(Fc(t),t.tag){case 1:return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 3:return Jn(bt),he(),e=t.flags,(e&65536)!==0&&(e&128)===0?(t.flags=e&-65537|128,t):null;case 26:case 27:case 5:return Ae(t),null;case 31:if(t.memoizedState!==null){if(ln(t),t.alternate===null)throw Error(o(340));_l()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 13:if(ln(t),e=t.memoizedState,e!==null&&e.dehydrated!==null){if(t.alternate===null)throw Error(o(340));_l()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 19:return I(yt),null;case 4:return he(),null;case 10:return Jn(t.type),null;case 22:case 23:return ln(t),cu(),e!==null&&I(kl),e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 24:return Jn(bt),null;case 25:return null;default:return null}}function Vm(e,t){switch(Fc(t),t.tag){case 3:Jn(bt),he();break;case 26:case 27:case 5:Ae(t);break;case 4:he();break;case 31:t.memoizedState!==null&&ln(t);break;case 13:ln(t);break;case 19:I(yt);break;case 10:Jn(t.type);break;case 22:case 23:ln(t),cu(),e!==null&&I(kl);break;case 24:Jn(bt)}}function Bs(e,t){try{var a=t.updateQueue,i=a!==null?a.lastEffect:null;if(i!==null){var r=i.next;a=r;do{if((a.tag&e)===e){i=void 0;var c=a.create,m=a.inst;i=c(),m.destroy=i}a=a.next}while(a!==r)}}catch(b){Pe(t,t.return,b)}}function za(e,t,a){try{var i=t.updateQueue,r=i!==null?i.lastEffect:null;if(r!==null){var c=r.next;i=c;do{if((i.tag&e)===e){var m=i.inst,b=m.destroy;if(b!==void 0){m.destroy=void 0,r=t;var C=a,K=b;try{K()}catch(le){Pe(r,C,le)}}}i=i.next}while(i!==c)}}catch(le){Pe(t,t.return,le)}}function Ym(e){var t=e.updateQueue;if(t!==null){var a=e.stateNode;try{Up(t,a)}catch(i){Pe(e,e.return,i)}}}function $m(e,t,a){a.props=Al(e.type,e.memoizedProps),a.state=e.memoizedState;try{a.componentWillUnmount()}catch(i){Pe(e,t,i)}}function Hs(e,t){try{var a=e.ref;if(a!==null){switch(e.tag){case 26:case 27:case 5:var i=e.stateNode;break;case 30:i=e.stateNode;break;default:i=e.stateNode}typeof a=="function"?e.refCleanup=a(i):a.current=i}}catch(r){Pe(e,t,r)}}function Dn(e,t){var a=e.ref,i=e.refCleanup;if(a!==null)if(typeof i=="function")try{i()}catch(r){Pe(e,t,r)}finally{e.refCleanup=null,e=e.alternate,e!=null&&(e.refCleanup=null)}else if(typeof a=="function")try{a(null)}catch(r){Pe(e,t,r)}else a.current=null}function Fm(e){var t=e.type,a=e.memoizedProps,i=e.stateNode;try{e:switch(t){case"button":case"input":case"select":case"textarea":a.autoFocus&&i.focus();break e;case"img":a.src?i.src=a.src:a.srcSet&&(i.srcset=a.srcSet)}}catch(r){Pe(e,e.return,r)}}function Gu(e,t,a){try{var i=e.stateNode;K2(i,e.type,a,t),i[Kt]=t}catch(r){Pe(e,e.return,r)}}function Xm(e){return e.tag===5||e.tag===3||e.tag===26||e.tag===27&&Ga(e.type)||e.tag===4}function Iu(e){e:for(;;){for(;e.sibling===null;){if(e.return===null||Xm(e.return))return null;e=e.return}for(e.sibling.return=e.return,e=e.sibling;e.tag!==5&&e.tag!==6&&e.tag!==18;){if(e.tag===27&&Ga(e.type)||e.flags&2||e.child===null||e.tag===4)continue e;e.child.return=e,e=e.child}if(!(e.flags&2))return e.stateNode}}function Qu(e,t,a){var i=e.tag;if(i===5||i===6)e=e.stateNode,t?(a.nodeType===9?a.body:a.nodeName==="HTML"?a.ownerDocument.body:a).insertBefore(e,t):(t=a.nodeType===9?a.body:a.nodeName==="HTML"?a.ownerDocument.body:a,t.appendChild(e),a=a._reactRootContainer,a!=null||t.onclick!==null||(t.onclick=$n));else if(i!==4&&(i===27&&Ga(e.type)&&(a=e.stateNode,t=null),e=e.child,e!==null))for(Qu(e,t,a),e=e.sibling;e!==null;)Qu(e,t,a),e=e.sibling}function pr(e,t,a){var i=e.tag;if(i===5||i===6)e=e.stateNode,t?a.insertBefore(e,t):a.appendChild(e);else if(i!==4&&(i===27&&Ga(e.type)&&(a=e.stateNode),e=e.child,e!==null))for(pr(e,t,a),e=e.sibling;e!==null;)pr(e,t,a),e=e.sibling}function Zm(e){var t=e.stateNode,a=e.memoizedProps;try{for(var i=e.type,r=t.attributes;r.length;)t.removeAttributeNode(r[0]);Ot(t,i,a),t[Ct]=e,t[Kt]=a}catch(c){Pe(e,e.return,c)}}var aa=!1,_t=!1,Ku=!1,Pm=typeof WeakSet=="function"?WeakSet:Set,jt=null;function S2(e,t){if(e=e.containerInfo,dd=Dr,e=cp(e),Lc(e)){if("selectionStart"in e)var a={start:e.selectionStart,end:e.selectionEnd};else e:{a=(a=e.ownerDocument)&&a.defaultView||window;var i=a.getSelection&&a.getSelection();if(i&&i.rangeCount!==0){a=i.anchorNode;var r=i.anchorOffset,c=i.focusNode;i=i.focusOffset;try{a.nodeType,c.nodeType}catch{a=null;break e}var m=0,b=-1,C=-1,K=0,le=0,oe=e,X=null;t:for(;;){for(var J;oe!==a||r!==0&&oe.nodeType!==3||(b=m+r),oe!==c||i!==0&&oe.nodeType!==3||(C=m+i),oe.nodeType===3&&(m+=oe.nodeValue.length),(J=oe.firstChild)!==null;)X=oe,oe=J;for(;;){if(oe===e)break t;if(X===a&&++K===r&&(b=m),X===c&&++le===i&&(C=m),(J=oe.nextSibling)!==null)break;oe=X,X=oe.parentNode}oe=J}a=b===-1||C===-1?null:{start:b,end:C}}else a=null}a=a||{start:0,end:0}}else a=null;for(fd={focusedElem:e,selectionRange:a},Dr=!1,jt=t;jt!==null;)if(t=jt,e=t.child,(t.subtreeFlags&1028)!==0&&e!==null)e.return=t,jt=e;else for(;jt!==null;){switch(t=jt,c=t.alternate,e=t.flags,t.tag){case 0:if((e&4)!==0&&(e=t.updateQueue,e=e!==null?e.events:null,e!==null))for(a=0;a<e.length;a++)r=e[a],r.ref.impl=r.nextImpl;break;case 11:case 15:break;case 1:if((e&1024)!==0&&c!==null){e=void 0,a=t,r=c.memoizedProps,c=c.memoizedState,i=a.stateNode;try{var _e=Al(a.type,r);e=i.getSnapshotBeforeUpdate(_e,c),i.__reactInternalSnapshotBeforeUpdate=e}catch(Ce){Pe(a,a.return,Ce)}}break;case 3:if((e&1024)!==0){if(e=t.stateNode.containerInfo,a=e.nodeType,a===9)md(e);else if(a===1)switch(e.nodeName){case"HEAD":case"HTML":case"BODY":md(e);break;default:e.textContent=""}}break;case 5:case 26:case 27:case 6:case 4:case 17:break;default:if((e&1024)!==0)throw Error(o(163))}if(e=t.sibling,e!==null){e.return=t.return,jt=e;break}jt=t.return}}function Jm(e,t,a){var i=a.flags;switch(a.tag){case 0:case 11:case 15:ia(e,a),i&4&&Bs(5,a);break;case 1:if(ia(e,a),i&4)if(e=a.stateNode,t===null)try{e.componentDidMount()}catch(m){Pe(a,a.return,m)}else{var r=Al(a.type,t.memoizedProps);t=t.memoizedState;try{e.componentDidUpdate(r,t,e.__reactInternalSnapshotBeforeUpdate)}catch(m){Pe(a,a.return,m)}}i&64&&Ym(a),i&512&&Hs(a,a.return);break;case 3:if(ia(e,a),i&64&&(e=a.updateQueue,e!==null)){if(t=null,a.child!==null)switch(a.child.tag){case 27:case 5:t=a.child.stateNode;break;case 1:t=a.child.stateNode}try{Up(e,t)}catch(m){Pe(a,a.return,m)}}break;case 27:t===null&&i&4&&Zm(a);case 26:case 5:ia(e,a),t===null&&i&4&&Fm(a),i&512&&Hs(a,a.return);break;case 12:ia(e,a);break;case 31:ia(e,a),i&4&&ty(e,a);break;case 13:ia(e,a),i&4&&ny(e,a),i&64&&(e=a.memoizedState,e!==null&&(e=e.dehydrated,e!==null&&(a=O2.bind(null,a),J2(e,a))));break;case 22:if(i=a.memoizedState!==null||aa,!i){t=t!==null&&t.memoizedState!==null||_t,r=aa;var c=_t;aa=i,(_t=t)&&!c?sa(e,a,(a.subtreeFlags&8772)!==0):ia(e,a),aa=r,_t=c}break;case 30:break;default:ia(e,a)}}function Wm(e){var t=e.alternate;t!==null&&(e.alternate=null,Wm(t)),e.child=null,e.deletions=null,e.sibling=null,e.tag===5&&(t=e.stateNode,t!==null&&xc(t)),e.stateNode=null,e.return=null,e.dependencies=null,e.memoizedProps=null,e.memoizedState=null,e.pendingProps=null,e.stateNode=null,e.updateQueue=null}var st=null,Yt=!1;function la(e,t,a){for(a=a.child;a!==null;)ey(e,t,a),a=a.sibling}function ey(e,t,a){if(zt&&typeof zt.onCommitFiberUnmount=="function")try{zt.onCommitFiberUnmount(xa,a)}catch{}switch(a.tag){case 26:_t||Dn(a,t),la(e,t,a),a.memoizedState?a.memoizedState.count--:a.stateNode&&(a=a.stateNode,a.parentNode.removeChild(a));break;case 27:_t||Dn(a,t);var i=st,r=Yt;Ga(a.type)&&(st=a.stateNode,Yt=!1),la(e,t,a),Fs(a.stateNode),st=i,Yt=r;break;case 5:_t||Dn(a,t);case 6:if(i=st,r=Yt,st=null,la(e,t,a),st=i,Yt=r,st!==null)if(Yt)try{(st.nodeType===9?st.body:st.nodeName==="HTML"?st.ownerDocument.body:st).removeChild(a.stateNode)}catch(c){Pe(a,t,c)}else try{st.removeChild(a.stateNode)}catch(c){Pe(a,t,c)}break;case 18:st!==null&&(Yt?(e=st,Yy(e.nodeType===9?e.body:e.nodeName==="HTML"?e.ownerDocument.body:e,a.stateNode),Qi(e)):Yy(st,a.stateNode));break;case 4:i=st,r=Yt,st=a.stateNode.containerInfo,Yt=!0,la(e,t,a),st=i,Yt=r;break;case 0:case 11:case 14:case 15:za(2,a,t),_t||za(4,a,t),la(e,t,a);break;case 1:_t||(Dn(a,t),i=a.stateNode,typeof i.componentWillUnmount=="function"&&$m(a,t,i)),la(e,t,a);break;case 21:la(e,t,a);break;case 22:_t=(i=_t)||a.memoizedState!==null,la(e,t,a),_t=i;break;default:la(e,t,a)}}function ty(e,t){if(t.memoizedState===null&&(e=t.alternate,e!==null&&(e=e.memoizedState,e!==null))){e=e.dehydrated;try{Qi(e)}catch(a){Pe(t,t.return,a)}}}function ny(e,t){if(t.memoizedState===null&&(e=t.alternate,e!==null&&(e=e.memoizedState,e!==null&&(e=e.dehydrated,e!==null))))try{Qi(e)}catch(a){Pe(t,t.return,a)}}function k2(e){switch(e.tag){case 31:case 13:case 19:var t=e.stateNode;return t===null&&(t=e.stateNode=new Pm),t;case 22:return e=e.stateNode,t=e._retryCache,t===null&&(t=e._retryCache=new Pm),t;default:throw Error(o(435,e.tag))}}function mr(e,t){var a=k2(e);t.forEach(function(i){if(!a.has(i)){a.add(i);var r=R2.bind(null,e,i);i.then(r,r)}})}function $t(e,t){var a=t.deletions;if(a!==null)for(var i=0;i<a.length;i++){var r=a[i],c=e,m=t,b=m;e:for(;b!==null;){switch(b.tag){case 27:if(Ga(b.type)){st=b.stateNode,Yt=!1;break e}break;case 5:st=b.stateNode,Yt=!1;break e;case 3:case 4:st=b.stateNode.containerInfo,Yt=!0;break e}b=b.return}if(st===null)throw Error(o(160));ey(c,m,r),st=null,Yt=!1,c=r.alternate,c!==null&&(c.return=null),r.return=null}if(t.subtreeFlags&13886)for(t=t.child;t!==null;)ay(t,e),t=t.sibling}var Cn=null;function ay(e,t){var a=e.alternate,i=e.flags;switch(e.tag){case 0:case 11:case 14:case 15:$t(t,e),Ft(e),i&4&&(za(3,e,e.return),Bs(3,e),za(5,e,e.return));break;case 1:$t(t,e),Ft(e),i&512&&(_t||a===null||Dn(a,a.return)),i&64&&aa&&(e=e.updateQueue,e!==null&&(i=e.callbacks,i!==null&&(a=e.shared.hiddenCallbacks,e.shared.hiddenCallbacks=a===null?i:a.concat(i))));break;case 26:var r=Cn;if($t(t,e),Ft(e),i&512&&(_t||a===null||Dn(a,a.return)),i&4){var c=a!==null?a.memoizedState:null;if(i=e.memoizedState,a===null)if(i===null)if(e.stateNode===null){e:{i=e.type,a=e.memoizedProps,r=r.ownerDocument||r;t:switch(i){case"title":c=r.getElementsByTagName("title")[0],(!c||c[fs]||c[Ct]||c.namespaceURI==="http://www.w3.org/2000/svg"||c.hasAttribute("itemprop"))&&(c=r.createElement(i),r.head.insertBefore(c,r.querySelector("head > title"))),Ot(c,i,a),c[Ct]=e,Et(c),i=c;break e;case"link":var m=ag("link","href",r).get(i+(a.href||""));if(m){for(var b=0;b<m.length;b++)if(c=m[b],c.getAttribute("href")===(a.href==null||a.href===""?null:a.href)&&c.getAttribute("rel")===(a.rel==null?null:a.rel)&&c.getAttribute("title")===(a.title==null?null:a.title)&&c.getAttribute("crossorigin")===(a.crossOrigin==null?null:a.crossOrigin)){m.splice(b,1);break t}}c=r.createElement(i),Ot(c,i,a),r.head.appendChild(c);break;case"meta":if(m=ag("meta","content",r).get(i+(a.content||""))){for(b=0;b<m.length;b++)if(c=m[b],c.getAttribute("content")===(a.content==null?null:""+a.content)&&c.getAttribute("name")===(a.name==null?null:a.name)&&c.getAttribute("property")===(a.property==null?null:a.property)&&c.getAttribute("http-equiv")===(a.httpEquiv==null?null:a.httpEquiv)&&c.getAttribute("charset")===(a.charSet==null?null:a.charSet)){m.splice(b,1);break t}}c=r.createElement(i),Ot(c,i,a),r.head.appendChild(c);break;default:throw Error(o(468,i))}c[Ct]=e,Et(c),i=c}e.stateNode=i}else lg(r,e.type,e.stateNode);else e.stateNode=ng(r,i,e.memoizedProps);else c!==i?(c===null?a.stateNode!==null&&(a=a.stateNode,a.parentNode.removeChild(a)):c.count--,i===null?lg(r,e.type,e.stateNode):ng(r,i,e.memoizedProps)):i===null&&e.stateNode!==null&&Gu(e,e.memoizedProps,a.memoizedProps)}break;case 27:$t(t,e),Ft(e),i&512&&(_t||a===null||Dn(a,a.return)),a!==null&&i&4&&Gu(e,e.memoizedProps,a.memoizedProps);break;case 5:if($t(t,e),Ft(e),i&512&&(_t||a===null||Dn(a,a.return)),e.flags&32){r=e.stateNode;try{fi(r,"")}catch(_e){Pe(e,e.return,_e)}}i&4&&e.stateNode!=null&&(r=e.memoizedProps,Gu(e,r,a!==null?a.memoizedProps:r)),i&1024&&(Ku=!0);break;case 6:if($t(t,e),Ft(e),i&4){if(e.stateNode===null)throw Error(o(162));i=e.memoizedProps,a=e.stateNode;try{a.nodeValue=i}catch(_e){Pe(e,e.return,_e)}}break;case 3:if(Tr=null,r=Cn,Cn=Ar(t.containerInfo),$t(t,e),Cn=r,Ft(e),i&4&&a!==null&&a.memoizedState.isDehydrated)try{Qi(t.containerInfo)}catch(_e){Pe(e,e.return,_e)}Ku&&(Ku=!1,ly(e));break;case 4:i=Cn,Cn=Ar(e.stateNode.containerInfo),$t(t,e),Ft(e),Cn=i;break;case 12:$t(t,e),Ft(e);break;case 31:$t(t,e),Ft(e),i&4&&(i=e.updateQueue,i!==null&&(e.updateQueue=null,mr(e,i)));break;case 13:$t(t,e),Ft(e),e.child.flags&8192&&e.memoizedState!==null!=(a!==null&&a.memoizedState!==null)&&(gr=rt()),i&4&&(i=e.updateQueue,i!==null&&(e.updateQueue=null,mr(e,i)));break;case 22:r=e.memoizedState!==null;var C=a!==null&&a.memoizedState!==null,K=aa,le=_t;if(aa=K||r,_t=le||C,$t(t,e),_t=le,aa=K,Ft(e),i&8192)e:for(t=e.stateNode,t._visibility=r?t._visibility&-2:t._visibility|1,r&&(a===null||C||aa||_t||Nl(e)),a=null,t=e;;){if(t.tag===5||t.tag===26){if(a===null){C=a=t;try{if(c=C.stateNode,r)m=c.style,typeof m.setProperty=="function"?m.setProperty("display","none","important"):m.display="none";else{b=C.stateNode;var oe=C.memoizedProps.style,X=oe!=null&&oe.hasOwnProperty("display")?oe.display:null;b.style.display=X==null||typeof X=="boolean"?"":(""+X).trim()}}catch(_e){Pe(C,C.return,_e)}}}else if(t.tag===6){if(a===null){C=t;try{C.stateNode.nodeValue=r?"":C.memoizedProps}catch(_e){Pe(C,C.return,_e)}}}else if(t.tag===18){if(a===null){C=t;try{var J=C.stateNode;r?$y(J,!0):$y(C.stateNode,!1)}catch(_e){Pe(C,C.return,_e)}}}else if((t.tag!==22&&t.tag!==23||t.memoizedState===null||t===e)&&t.child!==null){t.child.return=t,t=t.child;continue}if(t===e)break e;for(;t.sibling===null;){if(t.return===null||t.return===e)break e;a===t&&(a=null),t=t.return}a===t&&(a=null),t.sibling.return=t.return,t=t.sibling}i&4&&(i=e.updateQueue,i!==null&&(a=i.retryQueue,a!==null&&(i.retryQueue=null,mr(e,a))));break;case 19:$t(t,e),Ft(e),i&4&&(i=e.updateQueue,i!==null&&(e.updateQueue=null,mr(e,i)));break;case 30:break;case 21:break;default:$t(t,e),Ft(e)}}function Ft(e){var t=e.flags;if(t&2){try{for(var a,i=e.return;i!==null;){if(Xm(i)){a=i;break}i=i.return}if(a==null)throw Error(o(160));switch(a.tag){case 27:var r=a.stateNode,c=Iu(e);pr(e,c,r);break;case 5:var m=a.stateNode;a.flags&32&&(fi(m,""),a.flags&=-33);var b=Iu(e);pr(e,b,m);break;case 3:case 4:var C=a.stateNode.containerInfo,K=Iu(e);Qu(e,K,C);break;default:throw Error(o(161))}}catch(le){Pe(e,e.return,le)}e.flags&=-3}t&4096&&(e.flags&=-4097)}function ly(e){if(e.subtreeFlags&1024)for(e=e.child;e!==null;){var t=e;ly(t),t.tag===5&&t.flags&1024&&t.stateNode.reset(),e=e.sibling}}function ia(e,t){if(t.subtreeFlags&8772)for(t=t.child;t!==null;)Jm(e,t.alternate,t),t=t.sibling}function Nl(e){for(e=e.child;e!==null;){var t=e;switch(t.tag){case 0:case 11:case 14:case 15:za(4,t,t.return),Nl(t);break;case 1:Dn(t,t.return);var a=t.stateNode;typeof a.componentWillUnmount=="function"&&$m(t,t.return,a),Nl(t);break;case 27:Fs(t.stateNode);case 26:case 5:Dn(t,t.return),Nl(t);break;case 22:t.memoizedState===null&&Nl(t);break;case 30:Nl(t);break;default:Nl(t)}e=e.sibling}}function sa(e,t,a){for(a=a&&(t.subtreeFlags&8772)!==0,t=t.child;t!==null;){var i=t.alternate,r=e,c=t,m=c.flags;switch(c.tag){case 0:case 11:case 15:sa(r,c,a),Bs(4,c);break;case 1:if(sa(r,c,a),i=c,r=i.stateNode,typeof r.componentDidMount=="function")try{r.componentDidMount()}catch(K){Pe(i,i.return,K)}if(i=c,r=i.updateQueue,r!==null){var b=i.stateNode;try{var C=r.shared.hiddenCallbacks;if(C!==null)for(r.shared.hiddenCallbacks=null,r=0;r<C.length;r++)Dp(C[r],b)}catch(K){Pe(i,i.return,K)}}a&&m&64&&Ym(c),Hs(c,c.return);break;case 27:Zm(c);case 26:case 5:sa(r,c,a),a&&i===null&&m&4&&Fm(c),Hs(c,c.return);break;case 12:sa(r,c,a);break;case 31:sa(r,c,a),a&&m&4&&ty(r,c);break;case 13:sa(r,c,a),a&&m&4&&ny(r,c);break;case 22:c.memoizedState===null&&sa(r,c,a),Hs(c,c.return);break;case 30:break;default:sa(r,c,a)}t=t.sibling}}function Vu(e,t){var a=null;e!==null&&e.memoizedState!==null&&e.memoizedState.cachePool!==null&&(a=e.memoizedState.cachePool.pool),e=null,t.memoizedState!==null&&t.memoizedState.cachePool!==null&&(e=t.memoizedState.cachePool.pool),e!==a&&(e!=null&&e.refCount++,a!=null&&Es(a))}function Yu(e,t){e=null,t.alternate!==null&&(e=t.alternate.memoizedState.cache),t=t.memoizedState.cache,t!==e&&(t.refCount++,e!=null&&Es(e))}function An(e,t,a,i){if(t.subtreeFlags&10256)for(t=t.child;t!==null;)iy(e,t,a,i),t=t.sibling}function iy(e,t,a,i){var r=t.flags;switch(t.tag){case 0:case 11:case 15:An(e,t,a,i),r&2048&&Bs(9,t);break;case 1:An(e,t,a,i);break;case 3:An(e,t,a,i),r&2048&&(e=null,t.alternate!==null&&(e=t.alternate.memoizedState.cache),t=t.memoizedState.cache,t!==e&&(t.refCount++,e!=null&&Es(e)));break;case 12:if(r&2048){An(e,t,a,i),e=t.stateNode;try{var c=t.memoizedProps,m=c.id,b=c.onPostCommit;typeof b=="function"&&b(m,t.alternate===null?"mount":"update",e.passiveEffectDuration,-0)}catch(C){Pe(t,t.return,C)}}else An(e,t,a,i);break;case 31:An(e,t,a,i);break;case 13:An(e,t,a,i);break;case 23:break;case 22:c=t.stateNode,m=t.alternate,t.memoizedState!==null?c._visibility&2?An(e,t,a,i):qs(e,t):c._visibility&2?An(e,t,a,i):(c._visibility|=2,Oi(e,t,a,i,(t.subtreeFlags&10256)!==0||!1)),r&2048&&Vu(m,t);break;case 24:An(e,t,a,i),r&2048&&Yu(t.alternate,t);break;default:An(e,t,a,i)}}function Oi(e,t,a,i,r){for(r=r&&((t.subtreeFlags&10256)!==0||!1),t=t.child;t!==null;){var c=e,m=t,b=a,C=i,K=m.flags;switch(m.tag){case 0:case 11:case 15:Oi(c,m,b,C,r),Bs(8,m);break;case 23:break;case 22:var le=m.stateNode;m.memoizedState!==null?le._visibility&2?Oi(c,m,b,C,r):qs(c,m):(le._visibility|=2,Oi(c,m,b,C,r)),r&&K&2048&&Vu(m.alternate,m);break;case 24:Oi(c,m,b,C,r),r&&K&2048&&Yu(m.alternate,m);break;default:Oi(c,m,b,C,r)}t=t.sibling}}function qs(e,t){if(t.subtreeFlags&10256)for(t=t.child;t!==null;){var a=e,i=t,r=i.flags;switch(i.tag){case 22:qs(a,i),r&2048&&Vu(i.alternate,i);break;case 24:qs(a,i),r&2048&&Yu(i.alternate,i);break;default:qs(a,i)}t=t.sibling}}var Gs=8192;function Ri(e,t,a){if(e.subtreeFlags&Gs)for(e=e.child;e!==null;)sy(e,t,a),e=e.sibling}function sy(e,t,a){switch(e.tag){case 26:Ri(e,t,a),e.flags&Gs&&e.memoizedState!==null&&u_(a,Cn,e.memoizedState,e.memoizedProps);break;case 5:Ri(e,t,a);break;case 3:case 4:var i=Cn;Cn=Ar(e.stateNode.containerInfo),Ri(e,t,a),Cn=i;break;case 22:e.memoizedState===null&&(i=e.alternate,i!==null&&i.memoizedState!==null?(i=Gs,Gs=16777216,Ri(e,t,a),Gs=i):Ri(e,t,a));break;default:Ri(e,t,a)}}function oy(e){var t=e.alternate;if(t!==null&&(e=t.child,e!==null)){t.child=null;do t=e.sibling,e.sibling=null,e=t;while(e!==null)}}function Is(e){var t=e.deletions;if((e.flags&16)!==0){if(t!==null)for(var a=0;a<t.length;a++){var i=t[a];jt=i,cy(i,e)}oy(e)}if(e.subtreeFlags&10256)for(e=e.child;e!==null;)ry(e),e=e.sibling}function ry(e){switch(e.tag){case 0:case 11:case 15:Is(e),e.flags&2048&&za(9,e,e.return);break;case 3:Is(e);break;case 12:Is(e);break;case 22:var t=e.stateNode;e.memoizedState!==null&&t._visibility&2&&(e.return===null||e.return.tag!==13)?(t._visibility&=-3,yr(e)):Is(e);break;default:Is(e)}}function yr(e){var t=e.deletions;if((e.flags&16)!==0){if(t!==null)for(var a=0;a<t.length;a++){var i=t[a];jt=i,cy(i,e)}oy(e)}for(e=e.child;e!==null;){switch(t=e,t.tag){case 0:case 11:case 15:za(8,t,t.return),yr(t);break;case 22:a=t.stateNode,a._visibility&2&&(a._visibility&=-3,yr(t));break;default:yr(t)}e=e.sibling}}function cy(e,t){for(;jt!==null;){var a=jt;switch(a.tag){case 0:case 11:case 15:za(8,a,t);break;case 23:case 22:if(a.memoizedState!==null&&a.memoizedState.cachePool!==null){var i=a.memoizedState.cachePool.pool;i!=null&&i.refCount++}break;case 24:Es(a.memoizedState.cache)}if(i=a.child,i!==null)i.return=a,jt=i;else e:for(a=e;jt!==null;){i=jt;var r=i.sibling,c=i.return;if(Wm(i),i===a){jt=null;break e}if(r!==null){r.return=c,jt=r;break e}jt=c}}}var E2={getCacheForType:function(e){var t=Nt(bt),a=t.data.get(e);return a===void 0&&(a=e(),t.data.set(e,a)),a},cacheSignal:function(){return Nt(bt).controller.signal}},j2=typeof WeakMap=="function"?WeakMap:Map,Fe=0,tt=null,He=null,Ge=0,Ze=0,sn=null,Da=!1,zi=!1,$u=!1,oa=0,dt=0,Ua=0,Tl=0,Fu=0,on=0,Di=0,Qs=null,Xt=null,Xu=!1,gr=0,uy=0,br=1/0,vr=null,La=null,wt=0,Ba=null,Ui=null,ra=0,Zu=0,Pu=null,dy=null,Ks=0,Ju=null;function rn(){return(Fe&2)!==0&&Ge!==0?Ge&-Ge:w.T!==null?ld():Mh()}function fy(){if(on===0)if((Ge&536870912)===0||Qe){var e=pt;pt<<=1,(pt&3932160)===0&&(pt=262144),on=e}else on=536870912;return e=an.current,e!==null&&(e.flags|=32),on}function Zt(e,t,a){(e===tt&&(Ze===2||Ze===9)||e.cancelPendingCommit!==null)&&(Li(e,0),Ha(e,Ge,on,!1)),_a(e,a),((Fe&2)===0||e!==tt)&&(e===tt&&((Fe&2)===0&&(Tl|=a),dt===4&&Ha(e,Ge,on,!1)),Un(e))}function hy(e,t,a){if((Fe&6)!==0)throw Error(o(327));var i=!a&&(t&127)===0&&(t&e.expiredLanes)===0||Ut(e,t),r=i?A2(e,t):ed(e,t,!0),c=i;do{if(r===0){zi&&!i&&Ha(e,t,0,!1);break}else{if(a=e.current.alternate,c&&!M2(a)){r=ed(e,t,!1),c=!1;continue}if(r===2){if(c=t,e.errorRecoveryDisabledLanes&c)var m=0;else m=e.pendingLanes&-536870913,m=m!==0?m:m&536870912?536870912:0;if(m!==0){t=m;e:{var b=e;r=Qs;var C=b.current.memoizedState.isDehydrated;if(C&&(Li(b,m).flags|=256),m=ed(b,m,!1),m!==2){if($u&&!C){b.errorRecoveryDisabledLanes|=c,Tl|=c,r=4;break e}c=Xt,Xt=r,c!==null&&(Xt===null?Xt=c:Xt.push.apply(Xt,c))}r=m}if(c=!1,r!==2)continue}}if(r===1){Li(e,0),Ha(e,t,0,!0);break}e:{switch(i=e,c=r,c){case 0:case 1:throw Error(o(345));case 4:if((t&4194048)!==t)break;case 6:Ha(i,t,on,!Da);break e;case 2:Xt=null;break;case 3:case 5:break;default:throw Error(o(329))}if((t&62914560)===t&&(r=gr+300-rt(),10<r)){if(Ha(i,t,on,!Da),Dt(i,0,!0)!==0)break e;ra=t,i.timeoutHandle=Ky(py.bind(null,i,a,Xt,vr,Xu,t,on,Tl,Di,Da,c,"Throttled",-0,0),r);break e}py(i,a,Xt,vr,Xu,t,on,Tl,Di,Da,c,null,-0,0)}}break}while(!0);Un(e)}function py(e,t,a,i,r,c,m,b,C,K,le,oe,X,J){if(e.timeoutHandle=-1,oe=t.subtreeFlags,oe&8192||(oe&16785408)===16785408){oe={stylesheets:null,count:0,imgCount:0,imgBytes:0,suspenseyImages:[],waitingForImages:!0,waitingForViewTransition:!1,unsuspend:$n},sy(t,c,oe);var _e=(c&62914560)===c?gr-rt():(c&4194048)===c?uy-rt():0;if(_e=d_(oe,_e),_e!==null){ra=c,e.cancelPendingCommit=_e(wy.bind(null,e,t,c,a,i,r,m,b,C,le,oe,null,X,J)),Ha(e,c,m,!K);return}}wy(e,t,c,a,i,r,m,b,C)}function M2(e){for(var t=e;;){var a=t.tag;if((a===0||a===11||a===15)&&t.flags&16384&&(a=t.updateQueue,a!==null&&(a=a.stores,a!==null)))for(var i=0;i<a.length;i++){var r=a[i],c=r.getSnapshot;r=r.value;try{if(!tn(c(),r))return!1}catch{return!1}}if(a=t.child,t.subtreeFlags&16384&&a!==null)a.return=t,t=a;else{if(t===e)break;for(;t.sibling===null;){if(t.return===null||t.return===e)return!0;t=t.return}t.sibling.return=t.return,t=t.sibling}}return!0}function Ha(e,t,a,i){t&=~Fu,t&=~Tl,e.suspendedLanes|=t,e.pingedLanes&=~t,i&&(e.warmLanes|=t),i=e.expirationTimes;for(var r=t;0<r;){var c=31-pe(r),m=1<<c;i[c]=-1,r&=~m}a!==0&&Ao(e,a,t)}function xr(){return(Fe&6)===0?(Vs(0),!1):!0}function Wu(){if(He!==null){if(Ze===0)var e=He.return;else e=He,Pn=wl=null,mu(e),Mi=null,Ms=0,e=He;for(;e!==null;)Vm(e.alternate,e),e=e.return;He=null}}function Li(e,t){var a=e.timeoutHandle;a!==-1&&(e.timeoutHandle=-1,$2(a)),a=e.cancelPendingCommit,a!==null&&(e.cancelPendingCommit=null,a()),ra=0,Wu(),tt=e,He=a=Xn(e.current,null),Ge=t,Ze=0,sn=null,Da=!1,zi=Ut(e,t),$u=!1,Di=on=Fu=Tl=Ua=dt=0,Xt=Qs=null,Xu=!1,(t&8)!==0&&(t|=t&32);var i=e.entangledLanes;if(i!==0)for(e=e.entanglements,i&=t;0<i;){var r=31-pe(i),c=1<<r;t|=e[r],i&=~c}return oa=t,Go(),a}function my(e,t){Re=null,w.H=Ds,t===ji||t===Xo?(t=Tp(),Ze=3):t===au?(t=Tp(),Ze=4):Ze=t===Tu?8:t!==null&&typeof t=="object"&&typeof t.then=="function"?6:1,sn=t,He===null&&(dt=1,cr(e,gn(t,e.current)))}function yy(){var e=an.current;return e===null?!0:(Ge&4194048)===Ge?_n===null:(Ge&62914560)===Ge||(Ge&536870912)!==0?e===_n:!1}function gy(){var e=w.H;return w.H=Ds,e===null?Ds:e}function by(){var e=w.A;return w.A=E2,e}function _r(){dt=4,Da||(Ge&4194048)!==Ge&&an.current!==null||(zi=!0),(Ua&134217727)===0&&(Tl&134217727)===0||tt===null||Ha(tt,Ge,on,!1)}function ed(e,t,a){var i=Fe;Fe|=2;var r=gy(),c=by();(tt!==e||Ge!==t)&&(vr=null,Li(e,t)),t=!1;var m=dt;e:do try{if(Ze!==0&&He!==null){var b=He,C=sn;switch(Ze){case 8:Wu(),m=6;break e;case 3:case 2:case 9:case 6:an.current===null&&(t=!0);var K=Ze;if(Ze=0,sn=null,Bi(e,b,C,K),a&&zi){m=0;break e}break;default:K=Ze,Ze=0,sn=null,Bi(e,b,C,K)}}C2(),m=dt;break}catch(le){my(e,le)}while(!0);return t&&e.shellSuspendCounter++,Pn=wl=null,Fe=i,w.H=r,w.A=c,He===null&&(tt=null,Ge=0,Go()),m}function C2(){for(;He!==null;)vy(He)}function A2(e,t){var a=Fe;Fe|=2;var i=gy(),r=by();tt!==e||Ge!==t?(vr=null,br=rt()+500,Li(e,t)):zi=Ut(e,t);e:do try{if(Ze!==0&&He!==null){t=He;var c=sn;t:switch(Ze){case 1:Ze=0,sn=null,Bi(e,t,c,1);break;case 2:case 9:if(Ap(c)){Ze=0,sn=null,xy(t);break}t=function(){Ze!==2&&Ze!==9||tt!==e||(Ze=7),Un(e)},c.then(t,t);break e;case 3:Ze=7;break e;case 4:Ze=5;break e;case 7:Ap(c)?(Ze=0,sn=null,xy(t)):(Ze=0,sn=null,Bi(e,t,c,7));break;case 5:var m=null;switch(He.tag){case 26:m=He.memoizedState;case 5:case 27:var b=He;if(m?ig(m):b.stateNode.complete){Ze=0,sn=null;var C=b.sibling;if(C!==null)He=C;else{var K=b.return;K!==null?(He=K,wr(K)):He=null}break t}}Ze=0,sn=null,Bi(e,t,c,5);break;case 6:Ze=0,sn=null,Bi(e,t,c,6);break;case 8:Wu(),dt=6;break e;default:throw Error(o(462))}}N2();break}catch(le){my(e,le)}while(!0);return Pn=wl=null,w.H=i,w.A=r,Fe=a,He!==null?0:(tt=null,Ge=0,Go(),dt)}function N2(){for(;He!==null&&!dl();)vy(He)}function vy(e){var t=Qm(e.alternate,e,oa);e.memoizedProps=e.pendingProps,t===null?wr(e):He=t}function xy(e){var t=e,a=t.alternate;switch(t.tag){case 15:case 0:t=Lm(a,t,t.pendingProps,t.type,void 0,Ge);break;case 11:t=Lm(a,t,t.pendingProps,t.type.render,t.ref,Ge);break;case 5:mu(t);default:Vm(a,t),t=He=bp(t,oa),t=Qm(a,t,oa)}e.memoizedProps=e.pendingProps,t===null?wr(e):He=t}function Bi(e,t,a,i){Pn=wl=null,mu(t),Mi=null,Ms=0;var r=t.return;try{if(b2(e,r,t,a,Ge)){dt=1,cr(e,gn(a,e.current)),He=null;return}}catch(c){if(r!==null)throw He=r,c;dt=1,cr(e,gn(a,e.current)),He=null;return}t.flags&32768?(Qe||i===1?e=!0:zi||(Ge&536870912)!==0?e=!1:(Da=e=!0,(i===2||i===9||i===3||i===6)&&(i=an.current,i!==null&&i.tag===13&&(i.flags|=16384))),_y(t,e)):wr(t)}function wr(e){var t=e;do{if((t.flags&32768)!==0){_y(t,Da);return}e=t.return;var a=_2(t.alternate,t,oa);if(a!==null){He=a;return}if(t=t.sibling,t!==null){He=t;return}He=t=e}while(t!==null);dt===0&&(dt=5)}function _y(e,t){do{var a=w2(e.alternate,e);if(a!==null){a.flags&=32767,He=a;return}if(a=e.return,a!==null&&(a.flags|=32768,a.subtreeFlags=0,a.deletions=null),!t&&(e=e.sibling,e!==null)){He=e;return}He=e=a}while(e!==null);dt=6,He=null}function wy(e,t,a,i,r,c,m,b,C){e.cancelPendingCommit=null;do Sr();while(wt!==0);if((Fe&6)!==0)throw Error(o(327));if(t!==null){if(t===e.current)throw Error(o(177));if(c=t.lanes|t.childLanes,c|=Ic,wa(e,a,c,m,b,C),e===tt&&(He=tt=null,Ge=0),Ui=t,Ba=e,ra=a,Zu=c,Pu=r,dy=i,(t.subtreeFlags&10256)!==0||(t.flags&10256)!==0?(e.callbackNode=null,e.callbackPriority=0,z2(fl,function(){return My(),null})):(e.callbackNode=null,e.callbackPriority=0),i=(t.flags&13878)!==0,(t.subtreeFlags&13878)!==0||i){i=w.T,w.T=null,r=Z.p,Z.p=2,m=Fe,Fe|=4;try{S2(e,t,a)}finally{Fe=m,Z.p=r,w.T=i}}wt=1,Sy(),ky(),Ey()}}function Sy(){if(wt===1){wt=0;var e=Ba,t=Ui,a=(t.flags&13878)!==0;if((t.subtreeFlags&13878)!==0||a){a=w.T,w.T=null;var i=Z.p;Z.p=2;var r=Fe;Fe|=4;try{ay(t,e);var c=fd,m=cp(e.containerInfo),b=c.focusedElem,C=c.selectionRange;if(m!==b&&b&&b.ownerDocument&&rp(b.ownerDocument.documentElement,b)){if(C!==null&&Lc(b)){var K=C.start,le=C.end;if(le===void 0&&(le=K),"selectionStart"in b)b.selectionStart=K,b.selectionEnd=Math.min(le,b.value.length);else{var oe=b.ownerDocument||document,X=oe&&oe.defaultView||window;if(X.getSelection){var J=X.getSelection(),_e=b.textContent.length,Ce=Math.min(C.start,_e),et=C.end===void 0?Ce:Math.min(C.end,_e);!J.extend&&Ce>et&&(m=et,et=Ce,Ce=m);var H=op(b,Ce),R=op(b,et);if(H&&R&&(J.rangeCount!==1||J.anchorNode!==H.node||J.anchorOffset!==H.offset||J.focusNode!==R.node||J.focusOffset!==R.offset)){var Q=oe.createRange();Q.setStart(H.node,H.offset),J.removeAllRanges(),Ce>et?(J.addRange(Q),J.extend(R.node,R.offset)):(Q.setEnd(R.node,R.offset),J.addRange(Q))}}}}for(oe=[],J=b;J=J.parentNode;)J.nodeType===1&&oe.push({element:J,left:J.scrollLeft,top:J.scrollTop});for(typeof b.focus=="function"&&b.focus(),b=0;b<oe.length;b++){var se=oe[b];se.element.scrollLeft=se.left,se.element.scrollTop=se.top}}Dr=!!dd,fd=dd=null}finally{Fe=r,Z.p=i,w.T=a}}e.current=t,wt=2}}function ky(){if(wt===2){wt=0;var e=Ba,t=Ui,a=(t.flags&8772)!==0;if((t.subtreeFlags&8772)!==0||a){a=w.T,w.T=null;var i=Z.p;Z.p=2;var r=Fe;Fe|=4;try{Jm(e,t.alternate,t)}finally{Fe=r,Z.p=i,w.T=a}}wt=3}}function Ey(){if(wt===4||wt===3){wt=0,On();var e=Ba,t=Ui,a=ra,i=dy;(t.subtreeFlags&10256)!==0||(t.flags&10256)!==0?wt=5:(wt=0,Ui=Ba=null,jy(e,e.pendingLanes));var r=e.pendingLanes;if(r===0&&(La=null),bc(a),t=t.stateNode,zt&&typeof zt.onCommitFiberRoot=="function")try{zt.onCommitFiberRoot(xa,t,void 0,(t.current.flags&128)===128)}catch{}if(i!==null){t=w.T,r=Z.p,Z.p=2,w.T=null;try{for(var c=e.onRecoverableError,m=0;m<i.length;m++){var b=i[m];c(b.value,{componentStack:b.stack})}}finally{w.T=t,Z.p=r}}(ra&3)!==0&&Sr(),Un(e),r=e.pendingLanes,(a&261930)!==0&&(r&42)!==0?e===Ju?Ks++:(Ks=0,Ju=e):Ks=0,Vs(0)}}function jy(e,t){(e.pooledCacheLanes&=t)===0&&(t=e.pooledCache,t!=null&&(e.pooledCache=null,Es(t)))}function Sr(){return Sy(),ky(),Ey(),My()}function My(){if(wt!==5)return!1;var e=Ba,t=Zu;Zu=0;var a=bc(ra),i=w.T,r=Z.p;try{Z.p=32>a?32:a,w.T=null,a=Pu,Pu=null;var c=Ba,m=ra;if(wt=0,Ui=Ba=null,ra=0,(Fe&6)!==0)throw Error(o(331));var b=Fe;if(Fe|=4,ry(c.current),iy(c,c.current,m,a),Fe=b,Vs(0,!1),zt&&typeof zt.onPostCommitFiberRoot=="function")try{zt.onPostCommitFiberRoot(xa,c)}catch{}return!0}finally{Z.p=r,w.T=i,jy(e,t)}}function Cy(e,t,a){t=gn(a,t),t=Nu(e.stateNode,t,2),e=Ta(e,t,2),e!==null&&(_a(e,2),Un(e))}function Pe(e,t,a){if(e.tag===3)Cy(e,e,a);else for(;t!==null;){if(t.tag===3){Cy(t,e,a);break}else if(t.tag===1){var i=t.stateNode;if(typeof t.type.getDerivedStateFromError=="function"||typeof i.componentDidCatch=="function"&&(La===null||!La.has(i))){e=gn(a,e),a=Am(2),i=Ta(t,a,2),i!==null&&(Nm(a,i,t,e),_a(i,2),Un(i));break}}t=t.return}}function td(e,t,a){var i=e.pingCache;if(i===null){i=e.pingCache=new j2;var r=new Set;i.set(t,r)}else r=i.get(t),r===void 0&&(r=new Set,i.set(t,r));r.has(a)||($u=!0,r.add(a),e=T2.bind(null,e,t,a),t.then(e,e))}function T2(e,t,a){var i=e.pingCache;i!==null&&i.delete(t),e.pingedLanes|=e.suspendedLanes&a,e.warmLanes&=~a,tt===e&&(Ge&a)===a&&(dt===4||dt===3&&(Ge&62914560)===Ge&&300>rt()-gr?(Fe&2)===0&&Li(e,0):Fu|=a,Di===Ge&&(Di=0)),Un(e)}function Ay(e,t){t===0&&(t=jn()),e=vl(e,t),e!==null&&(_a(e,t),Un(e))}function O2(e){var t=e.memoizedState,a=0;t!==null&&(a=t.retryLane),Ay(e,a)}function R2(e,t){var a=0;switch(e.tag){case 31:case 13:var i=e.stateNode,r=e.memoizedState;r!==null&&(a=r.retryLane);break;case 19:i=e.stateNode;break;case 22:i=e.stateNode._retryCache;break;default:throw Error(o(314))}i!==null&&i.delete(t),Ay(e,a)}function z2(e,t){return ni(e,t)}var kr=null,Hi=null,nd=!1,Er=!1,ad=!1,qa=0;function Un(e){e!==Hi&&e.next===null&&(Hi===null?kr=Hi=e:Hi=Hi.next=e),Er=!0,nd||(nd=!0,U2())}function Vs(e,t){if(!ad&&Er){ad=!0;do for(var a=!1,i=kr;i!==null;){if(e!==0){var r=i.pendingLanes;if(r===0)var c=0;else{var m=i.suspendedLanes,b=i.pingedLanes;c=(1<<31-pe(42|e)+1)-1,c&=r&~(m&~b),c=c&201326741?c&201326741|1:c?c|2:0}c!==0&&(a=!0,Ry(i,c))}else c=Ge,c=Dt(i,i===tt?c:0,i.cancelPendingCommit!==null||i.timeoutHandle!==-1),(c&3)===0||Ut(i,c)||(a=!0,Ry(i,c));i=i.next}while(a);ad=!1}}function D2(){Ny()}function Ny(){Er=nd=!1;var e=0;qa!==0&&Y2()&&(e=qa);for(var t=rt(),a=null,i=kr;i!==null;){var r=i.next,c=Ty(i,t);c===0?(i.next=null,a===null?kr=r:a.next=r,r===null&&(Hi=a)):(a=i,(e!==0||(c&3)!==0)&&(Er=!0)),i=r}wt!==0&&wt!==5||Vs(e),qa!==0&&(qa=0)}function Ty(e,t){for(var a=e.suspendedLanes,i=e.pingedLanes,r=e.expirationTimes,c=e.pendingLanes&-62914561;0<c;){var m=31-pe(c),b=1<<m,C=r[m];C===-1?((b&a)===0||(b&i)!==0)&&(r[m]=Lt(b,t)):C<=t&&(e.expiredLanes|=b),c&=~b}if(t=tt,a=Ge,a=Dt(e,e===t?a:0,e.cancelPendingCommit!==null||e.timeoutHandle!==-1),i=e.callbackNode,a===0||e===t&&(Ze===2||Ze===9)||e.cancelPendingCommit!==null)return i!==null&&i!==null&&ai(i),e.callbackNode=null,e.callbackPriority=0;if((a&3)===0||Ut(e,a)){if(t=a&-a,t===e.callbackPriority)return t;switch(i!==null&&ai(i),bc(a)){case 2:case 8:a=li;break;case 32:a=fl;break;case 268435456:a=it;break;default:a=fl}return i=Oy.bind(null,e),a=ni(a,i),e.callbackPriority=t,e.callbackNode=a,t}return i!==null&&i!==null&&ai(i),e.callbackPriority=2,e.callbackNode=null,2}function Oy(e,t){if(wt!==0&&wt!==5)return e.callbackNode=null,e.callbackPriority=0,null;var a=e.callbackNode;if(Sr()&&e.callbackNode!==a)return null;var i=Ge;return i=Dt(e,e===tt?i:0,e.cancelPendingCommit!==null||e.timeoutHandle!==-1),i===0?null:(hy(e,i,t),Ty(e,rt()),e.callbackNode!=null&&e.callbackNode===a?Oy.bind(null,e):null)}function Ry(e,t){if(Sr())return null;hy(e,t,!0)}function U2(){F2(function(){(Fe&6)!==0?ni(ds,D2):Ny()})}function ld(){if(qa===0){var e=ki;e===0&&(e=Te,Te<<=1,(Te&261888)===0&&(Te=256)),qa=e}return qa}function zy(e){return e==null||typeof e=="symbol"||typeof e=="boolean"?null:typeof e=="function"?e:Ro(""+e)}function Dy(e,t){var a=t.ownerDocument.createElement("input");return a.name=t.name,a.value=t.value,e.id&&a.setAttribute("form",e.id),t.parentNode.insertBefore(a,t),e=new FormData(e),a.parentNode.removeChild(a),e}function L2(e,t,a,i,r){if(t==="submit"&&a&&a.stateNode===r){var c=zy((r[Kt]||null).action),m=i.submitter;m&&(t=(t=m[Kt]||null)?zy(t.formAction):m.getAttribute("formAction"),t!==null&&(c=t,m=null));var b=new Lo("action","action",null,i,r);e.push({event:b,listeners:[{instance:null,listener:function(){if(i.defaultPrevented){if(qa!==0){var C=m?Dy(r,m):new FormData(r);ku(a,{pending:!0,data:C,method:r.method,action:c},null,C)}}else typeof c=="function"&&(b.preventDefault(),C=m?Dy(r,m):new FormData(r),ku(a,{pending:!0,data:C,method:r.method,action:c},c,C))},currentTarget:r}]})}}for(var id=0;id<Gc.length;id++){var sd=Gc[id],B2=sd.toLowerCase(),H2=sd[0].toUpperCase()+sd.slice(1);Mn(B2,"on"+H2)}Mn(fp,"onAnimationEnd"),Mn(hp,"onAnimationIteration"),Mn(pp,"onAnimationStart"),Mn("dblclick","onDoubleClick"),Mn("focusin","onFocus"),Mn("focusout","onBlur"),Mn(t2,"onTransitionRun"),Mn(n2,"onTransitionStart"),Mn(a2,"onTransitionCancel"),Mn(mp,"onTransitionEnd"),ui("onMouseEnter",["mouseout","mouseover"]),ui("onMouseLeave",["mouseout","mouseover"]),ui("onPointerEnter",["pointerout","pointerover"]),ui("onPointerLeave",["pointerout","pointerover"]),ml("onChange","change click focusin focusout input keydown keyup selectionchange".split(" ")),ml("onSelect","focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange".split(" ")),ml("onBeforeInput",["compositionend","keypress","textInput","paste"]),ml("onCompositionEnd","compositionend focusout keydown keypress keyup mousedown".split(" ")),ml("onCompositionStart","compositionstart focusout keydown keypress keyup mousedown".split(" ")),ml("onCompositionUpdate","compositionupdate focusout keydown keypress keyup mousedown".split(" "));var Ys="abort canplay canplaythrough durationchange emptied encrypted ended error loadeddata loadedmetadata loadstart pause play playing progress ratechange resize seeked seeking stalled suspend timeupdate volumechange waiting".split(" "),q2=new Set("beforetoggle cancel close invalid load scroll scrollend toggle".split(" ").concat(Ys));function Uy(e,t){t=(t&4)!==0;for(var a=0;a<e.length;a++){var i=e[a],r=i.event;i=i.listeners;e:{var c=void 0;if(t)for(var m=i.length-1;0<=m;m--){var b=i[m],C=b.instance,K=b.currentTarget;if(b=b.listener,C!==c&&r.isPropagationStopped())break e;c=b,r.currentTarget=K;try{c(r)}catch(le){qo(le)}r.currentTarget=null,c=C}else for(m=0;m<i.length;m++){if(b=i[m],C=b.instance,K=b.currentTarget,b=b.listener,C!==c&&r.isPropagationStopped())break e;c=b,r.currentTarget=K;try{c(r)}catch(le){qo(le)}r.currentTarget=null,c=C}}}}function qe(e,t){var a=t[vc];a===void 0&&(a=t[vc]=new Set);var i=e+"__bubble";a.has(i)||(Ly(t,e,2,!1),a.add(i))}function od(e,t,a){var i=0;t&&(i|=4),Ly(a,e,i,t)}var jr="_reactListening"+Math.random().toString(36).slice(2);function rd(e){if(!e[jr]){e[jr]=!0,Nh.forEach(function(a){a!=="selectionchange"&&(q2.has(a)||od(a,!1,e),od(a,!0,e))});var t=e.nodeType===9?e:e.ownerDocument;t===null||t[jr]||(t[jr]=!0,od("selectionchange",!1,t))}}function Ly(e,t,a,i){switch(fg(t)){case 2:var r=p_;break;case 8:r=m_;break;default:r=Sd}a=r.bind(null,t,a,e),r=void 0,!Cc||t!=="touchstart"&&t!=="touchmove"&&t!=="wheel"||(r=!0),i?r!==void 0?e.addEventListener(t,a,{capture:!0,passive:r}):e.addEventListener(t,a,!0):r!==void 0?e.addEventListener(t,a,{passive:r}):e.addEventListener(t,a,!1)}function cd(e,t,a,i,r){var c=i;if((t&1)===0&&(t&2)===0&&i!==null)e:for(;;){if(i===null)return;var m=i.tag;if(m===3||m===4){var b=i.stateNode.containerInfo;if(b===r)break;if(m===4)for(m=i.return;m!==null;){var C=m.tag;if((C===3||C===4)&&m.stateNode.containerInfo===r)return;m=m.return}for(;b!==null;){if(m=oi(b),m===null)return;if(C=m.tag,C===5||C===6||C===26||C===27){i=c=m;continue e}b=b.parentNode}}i=i.return}Ih(function(){var K=c,le=jc(a),oe=[];e:{var X=yp.get(e);if(X!==void 0){var J=Lo,_e=e;switch(e){case"keypress":if(Do(a)===0)break e;case"keydown":case"keyup":J=Rx;break;case"focusin":_e="focus",J=Oc;break;case"focusout":_e="blur",J=Oc;break;case"beforeblur":case"afterblur":J=Oc;break;case"click":if(a.button===2)break e;case"auxclick":case"dblclick":case"mousedown":case"mousemove":case"mouseup":case"mouseout":case"mouseover":case"contextmenu":J=Vh;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":J=_x;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":J=Ux;break;case fp:case hp:case pp:J=kx;break;case mp:J=Bx;break;case"scroll":case"scrollend":J=vx;break;case"wheel":J=qx;break;case"copy":case"cut":case"paste":J=jx;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":J=$h;break;case"toggle":case"beforetoggle":J=Ix}var Ce=(t&4)!==0,et=!Ce&&(e==="scroll"||e==="scrollend"),H=Ce?X!==null?X+"Capture":null:X;Ce=[];for(var R=K,Q;R!==null;){var se=R;if(Q=se.stateNode,se=se.tag,se!==5&&se!==26&&se!==27||Q===null||H===null||(se=ps(R,H),se!=null&&Ce.push($s(R,se,Q))),et)break;R=R.return}0<Ce.length&&(X=new J(X,_e,null,a,le),oe.push({event:X,listeners:Ce}))}}if((t&7)===0){e:{if(X=e==="mouseover"||e==="pointerover",J=e==="mouseout"||e==="pointerout",X&&a!==Ec&&(_e=a.relatedTarget||a.fromElement)&&(oi(_e)||_e[si]))break e;if((J||X)&&(X=le.window===le?le:(X=le.ownerDocument)?X.defaultView||X.parentWindow:window,J?(_e=a.relatedTarget||a.toElement,J=K,_e=_e?oi(_e):null,_e!==null&&(et=d(_e),Ce=_e.tag,_e!==et||Ce!==5&&Ce!==27&&Ce!==6)&&(_e=null)):(J=null,_e=K),J!==_e)){if(Ce=Vh,se="onMouseLeave",H="onMouseEnter",R="mouse",(e==="pointerout"||e==="pointerover")&&(Ce=$h,se="onPointerLeave",H="onPointerEnter",R="pointer"),et=J==null?X:hs(J),Q=_e==null?X:hs(_e),X=new Ce(se,R+"leave",J,a,le),X.target=et,X.relatedTarget=Q,se=null,oi(le)===K&&(Ce=new Ce(H,R+"enter",_e,a,le),Ce.target=Q,Ce.relatedTarget=et,se=Ce),et=se,J&&_e)t:{for(Ce=G2,H=J,R=_e,Q=0,se=H;se;se=Ce(se))Q++;se=0;for(var Ee=R;Ee;Ee=Ce(Ee))se++;for(;0<Q-se;)H=Ce(H),Q--;for(;0<se-Q;)R=Ce(R),se--;for(;Q--;){if(H===R||R!==null&&H===R.alternate){Ce=H;break t}H=Ce(H),R=Ce(R)}Ce=null}else Ce=null;J!==null&&By(oe,X,J,Ce,!1),_e!==null&&et!==null&&By(oe,et,_e,Ce,!0)}}e:{if(X=K?hs(K):window,J=X.nodeName&&X.nodeName.toLowerCase(),J==="select"||J==="input"&&X.type==="file")var Ye=tp;else if(Wh(X))if(np)Ye=Jx;else{Ye=Zx;var we=Xx}else J=X.nodeName,!J||J.toLowerCase()!=="input"||X.type!=="checkbox"&&X.type!=="radio"?K&&kc(K.elementType)&&(Ye=tp):Ye=Px;if(Ye&&(Ye=Ye(e,K))){ep(oe,Ye,a,le);break e}we&&we(e,X,K),e==="focusout"&&K&&X.type==="number"&&K.memoizedProps.value!=null&&Sc(X,"number",X.value)}switch(we=K?hs(K):window,e){case"focusin":(Wh(we)||we.contentEditable==="true")&&(yi=we,Bc=K,ws=null);break;case"focusout":ws=Bc=yi=null;break;case"mousedown":Hc=!0;break;case"contextmenu":case"mouseup":case"dragend":Hc=!1,up(oe,a,le);break;case"selectionchange":if(e2)break;case"keydown":case"keyup":up(oe,a,le)}var De;if(zc)e:{switch(e){case"compositionstart":var Ie="onCompositionStart";break e;case"compositionend":Ie="onCompositionEnd";break e;case"compositionupdate":Ie="onCompositionUpdate";break e}Ie=void 0}else mi?Ph(e,a)&&(Ie="onCompositionEnd"):e==="keydown"&&a.keyCode===229&&(Ie="onCompositionStart");Ie&&(Fh&&a.locale!=="ko"&&(mi||Ie!=="onCompositionStart"?Ie==="onCompositionEnd"&&mi&&(De=Qh()):(ka=le,Ac="value"in ka?ka.value:ka.textContent,mi=!0)),we=Mr(K,Ie),0<we.length&&(Ie=new Yh(Ie,e,null,a,le),oe.push({event:Ie,listeners:we}),De?Ie.data=De:(De=Jh(a),De!==null&&(Ie.data=De)))),(De=Kx?Vx(e,a):Yx(e,a))&&(Ie=Mr(K,"onBeforeInput"),0<Ie.length&&(we=new Yh("onBeforeInput","beforeinput",null,a,le),oe.push({event:we,listeners:Ie}),we.data=De)),L2(oe,e,K,a,le)}Uy(oe,t)})}function $s(e,t,a){return{instance:e,listener:t,currentTarget:a}}function Mr(e,t){for(var a=t+"Capture",i=[];e!==null;){var r=e,c=r.stateNode;if(r=r.tag,r!==5&&r!==26&&r!==27||c===null||(r=ps(e,a),r!=null&&i.unshift($s(e,r,c)),r=ps(e,t),r!=null&&i.push($s(e,r,c))),e.tag===3)return i;e=e.return}return[]}function G2(e){if(e===null)return null;do e=e.return;while(e&&e.tag!==5&&e.tag!==27);return e||null}function By(e,t,a,i,r){for(var c=t._reactName,m=[];a!==null&&a!==i;){var b=a,C=b.alternate,K=b.stateNode;if(b=b.tag,C!==null&&C===i)break;b!==5&&b!==26&&b!==27||K===null||(C=K,r?(K=ps(a,c),K!=null&&m.unshift($s(a,K,C))):r||(K=ps(a,c),K!=null&&m.push($s(a,K,C)))),a=a.return}m.length!==0&&e.push({event:t,listeners:m})}var I2=/\r\n?/g,Q2=/\u0000|\uFFFD/g;function Hy(e){return(typeof e=="string"?e:""+e).replace(I2,`
|
|
49
|
+
`).replace(Q2,"")}function qy(e,t){return t=Hy(t),Hy(e)===t}function We(e,t,a,i,r,c){switch(a){case"children":typeof i=="string"?t==="body"||t==="textarea"&&i===""||fi(e,i):(typeof i=="number"||typeof i=="bigint")&&t!=="body"&&fi(e,""+i);break;case"className":To(e,"class",i);break;case"tabIndex":To(e,"tabindex",i);break;case"dir":case"role":case"viewBox":case"width":case"height":To(e,a,i);break;case"style":qh(e,i,c);break;case"data":if(t!=="object"){To(e,"data",i);break}case"src":case"href":if(i===""&&(t!=="a"||a!=="href")){e.removeAttribute(a);break}if(i==null||typeof i=="function"||typeof i=="symbol"||typeof i=="boolean"){e.removeAttribute(a);break}i=Ro(""+i),e.setAttribute(a,i);break;case"action":case"formAction":if(typeof i=="function"){e.setAttribute(a,"javascript:throw new Error('A React form was unexpectedly submitted. If you called form.submit() manually, consider using form.requestSubmit() instead. If you\\'re trying to use event.stopPropagation() in a submit event handler, consider also calling event.preventDefault().')");break}else typeof c=="function"&&(a==="formAction"?(t!=="input"&&We(e,t,"name",r.name,r,null),We(e,t,"formEncType",r.formEncType,r,null),We(e,t,"formMethod",r.formMethod,r,null),We(e,t,"formTarget",r.formTarget,r,null)):(We(e,t,"encType",r.encType,r,null),We(e,t,"method",r.method,r,null),We(e,t,"target",r.target,r,null)));if(i==null||typeof i=="symbol"||typeof i=="boolean"){e.removeAttribute(a);break}i=Ro(""+i),e.setAttribute(a,i);break;case"onClick":i!=null&&(e.onclick=$n);break;case"onScroll":i!=null&&qe("scroll",e);break;case"onScrollEnd":i!=null&&qe("scrollend",e);break;case"dangerouslySetInnerHTML":if(i!=null){if(typeof i!="object"||!("__html"in i))throw Error(o(61));if(a=i.__html,a!=null){if(r.children!=null)throw Error(o(60));e.innerHTML=a}}break;case"multiple":e.multiple=i&&typeof i!="function"&&typeof i!="symbol";break;case"muted":e.muted=i&&typeof i!="function"&&typeof i!="symbol";break;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"defaultValue":case"defaultChecked":case"innerHTML":case"ref":break;case"autoFocus":break;case"xlinkHref":if(i==null||typeof i=="function"||typeof i=="boolean"||typeof i=="symbol"){e.removeAttribute("xlink:href");break}a=Ro(""+i),e.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",a);break;case"contentEditable":case"spellCheck":case"draggable":case"value":case"autoReverse":case"externalResourcesRequired":case"focusable":case"preserveAlpha":i!=null&&typeof i!="function"&&typeof i!="symbol"?e.setAttribute(a,""+i):e.removeAttribute(a);break;case"inert":case"allowFullScreen":case"async":case"autoPlay":case"controls":case"default":case"defer":case"disabled":case"disablePictureInPicture":case"disableRemotePlayback":case"formNoValidate":case"hidden":case"loop":case"noModule":case"noValidate":case"open":case"playsInline":case"readOnly":case"required":case"reversed":case"scoped":case"seamless":case"itemScope":i&&typeof i!="function"&&typeof i!="symbol"?e.setAttribute(a,""):e.removeAttribute(a);break;case"capture":case"download":i===!0?e.setAttribute(a,""):i!==!1&&i!=null&&typeof i!="function"&&typeof i!="symbol"?e.setAttribute(a,i):e.removeAttribute(a);break;case"cols":case"rows":case"size":case"span":i!=null&&typeof i!="function"&&typeof i!="symbol"&&!isNaN(i)&&1<=i?e.setAttribute(a,i):e.removeAttribute(a);break;case"rowSpan":case"start":i==null||typeof i=="function"||typeof i=="symbol"||isNaN(i)?e.removeAttribute(a):e.setAttribute(a,i);break;case"popover":qe("beforetoggle",e),qe("toggle",e),No(e,"popover",i);break;case"xlinkActuate":Yn(e,"http://www.w3.org/1999/xlink","xlink:actuate",i);break;case"xlinkArcrole":Yn(e,"http://www.w3.org/1999/xlink","xlink:arcrole",i);break;case"xlinkRole":Yn(e,"http://www.w3.org/1999/xlink","xlink:role",i);break;case"xlinkShow":Yn(e,"http://www.w3.org/1999/xlink","xlink:show",i);break;case"xlinkTitle":Yn(e,"http://www.w3.org/1999/xlink","xlink:title",i);break;case"xlinkType":Yn(e,"http://www.w3.org/1999/xlink","xlink:type",i);break;case"xmlBase":Yn(e,"http://www.w3.org/XML/1998/namespace","xml:base",i);break;case"xmlLang":Yn(e,"http://www.w3.org/XML/1998/namespace","xml:lang",i);break;case"xmlSpace":Yn(e,"http://www.w3.org/XML/1998/namespace","xml:space",i);break;case"is":No(e,"is",i);break;case"innerText":case"textContent":break;default:(!(2<a.length)||a[0]!=="o"&&a[0]!=="O"||a[1]!=="n"&&a[1]!=="N")&&(a=gx.get(a)||a,No(e,a,i))}}function ud(e,t,a,i,r,c){switch(a){case"style":qh(e,i,c);break;case"dangerouslySetInnerHTML":if(i!=null){if(typeof i!="object"||!("__html"in i))throw Error(o(61));if(a=i.__html,a!=null){if(r.children!=null)throw Error(o(60));e.innerHTML=a}}break;case"children":typeof i=="string"?fi(e,i):(typeof i=="number"||typeof i=="bigint")&&fi(e,""+i);break;case"onScroll":i!=null&&qe("scroll",e);break;case"onScrollEnd":i!=null&&qe("scrollend",e);break;case"onClick":i!=null&&(e.onclick=$n);break;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"innerHTML":case"ref":break;case"innerText":case"textContent":break;default:if(!Th.hasOwnProperty(a))e:{if(a[0]==="o"&&a[1]==="n"&&(r=a.endsWith("Capture"),t=a.slice(2,r?a.length-7:void 0),c=e[Kt]||null,c=c!=null?c[a]:null,typeof c=="function"&&e.removeEventListener(t,c,r),typeof i=="function")){typeof c!="function"&&c!==null&&(a in e?e[a]=null:e.hasAttribute(a)&&e.removeAttribute(a)),e.addEventListener(t,i,r);break e}a in e?e[a]=i:i===!0?e.setAttribute(a,""):No(e,a,i)}}}function Ot(e,t,a){switch(t){case"div":case"span":case"svg":case"path":case"a":case"g":case"p":case"li":break;case"img":qe("error",e),qe("load",e);var i=!1,r=!1,c;for(c in a)if(a.hasOwnProperty(c)){var m=a[c];if(m!=null)switch(c){case"src":i=!0;break;case"srcSet":r=!0;break;case"children":case"dangerouslySetInnerHTML":throw Error(o(137,t));default:We(e,t,c,m,a,null)}}r&&We(e,t,"srcSet",a.srcSet,a,null),i&&We(e,t,"src",a.src,a,null);return;case"input":qe("invalid",e);var b=c=m=r=null,C=null,K=null;for(i in a)if(a.hasOwnProperty(i)){var le=a[i];if(le!=null)switch(i){case"name":r=le;break;case"type":m=le;break;case"checked":C=le;break;case"defaultChecked":K=le;break;case"value":c=le;break;case"defaultValue":b=le;break;case"children":case"dangerouslySetInnerHTML":if(le!=null)throw Error(o(137,t));break;default:We(e,t,i,le,a,null)}}Uh(e,c,b,C,K,m,r,!1);return;case"select":qe("invalid",e),i=m=c=null;for(r in a)if(a.hasOwnProperty(r)&&(b=a[r],b!=null))switch(r){case"value":c=b;break;case"defaultValue":m=b;break;case"multiple":i=b;default:We(e,t,r,b,a,null)}t=c,a=m,e.multiple=!!i,t!=null?di(e,!!i,t,!1):a!=null&&di(e,!!i,a,!0);return;case"textarea":qe("invalid",e),c=r=i=null;for(m in a)if(a.hasOwnProperty(m)&&(b=a[m],b!=null))switch(m){case"value":i=b;break;case"defaultValue":r=b;break;case"children":c=b;break;case"dangerouslySetInnerHTML":if(b!=null)throw Error(o(91));break;default:We(e,t,m,b,a,null)}Bh(e,i,r,c);return;case"option":for(C in a)if(a.hasOwnProperty(C)&&(i=a[C],i!=null))switch(C){case"selected":e.selected=i&&typeof i!="function"&&typeof i!="symbol";break;default:We(e,t,C,i,a,null)}return;case"dialog":qe("beforetoggle",e),qe("toggle",e),qe("cancel",e),qe("close",e);break;case"iframe":case"object":qe("load",e);break;case"video":case"audio":for(i=0;i<Ys.length;i++)qe(Ys[i],e);break;case"image":qe("error",e),qe("load",e);break;case"details":qe("toggle",e);break;case"embed":case"source":case"link":qe("error",e),qe("load",e);case"area":case"base":case"br":case"col":case"hr":case"keygen":case"meta":case"param":case"track":case"wbr":case"menuitem":for(K in a)if(a.hasOwnProperty(K)&&(i=a[K],i!=null))switch(K){case"children":case"dangerouslySetInnerHTML":throw Error(o(137,t));default:We(e,t,K,i,a,null)}return;default:if(kc(t)){for(le in a)a.hasOwnProperty(le)&&(i=a[le],i!==void 0&&ud(e,t,le,i,a,void 0));return}}for(b in a)a.hasOwnProperty(b)&&(i=a[b],i!=null&&We(e,t,b,i,a,null))}function K2(e,t,a,i){switch(t){case"div":case"span":case"svg":case"path":case"a":case"g":case"p":case"li":break;case"input":var r=null,c=null,m=null,b=null,C=null,K=null,le=null;for(J in a){var oe=a[J];if(a.hasOwnProperty(J)&&oe!=null)switch(J){case"checked":break;case"value":break;case"defaultValue":C=oe;default:i.hasOwnProperty(J)||We(e,t,J,null,i,oe)}}for(var X in i){var J=i[X];if(oe=a[X],i.hasOwnProperty(X)&&(J!=null||oe!=null))switch(X){case"type":c=J;break;case"name":r=J;break;case"checked":K=J;break;case"defaultChecked":le=J;break;case"value":m=J;break;case"defaultValue":b=J;break;case"children":case"dangerouslySetInnerHTML":if(J!=null)throw Error(o(137,t));break;default:J!==oe&&We(e,t,X,J,i,oe)}}wc(e,m,b,C,K,le,c,r);return;case"select":J=m=b=X=null;for(c in a)if(C=a[c],a.hasOwnProperty(c)&&C!=null)switch(c){case"value":break;case"multiple":J=C;default:i.hasOwnProperty(c)||We(e,t,c,null,i,C)}for(r in i)if(c=i[r],C=a[r],i.hasOwnProperty(r)&&(c!=null||C!=null))switch(r){case"value":X=c;break;case"defaultValue":b=c;break;case"multiple":m=c;default:c!==C&&We(e,t,r,c,i,C)}t=b,a=m,i=J,X!=null?di(e,!!a,X,!1):!!i!=!!a&&(t!=null?di(e,!!a,t,!0):di(e,!!a,a?[]:"",!1));return;case"textarea":J=X=null;for(b in a)if(r=a[b],a.hasOwnProperty(b)&&r!=null&&!i.hasOwnProperty(b))switch(b){case"value":break;case"children":break;default:We(e,t,b,null,i,r)}for(m in i)if(r=i[m],c=a[m],i.hasOwnProperty(m)&&(r!=null||c!=null))switch(m){case"value":X=r;break;case"defaultValue":J=r;break;case"children":break;case"dangerouslySetInnerHTML":if(r!=null)throw Error(o(91));break;default:r!==c&&We(e,t,m,r,i,c)}Lh(e,X,J);return;case"option":for(var _e in a)if(X=a[_e],a.hasOwnProperty(_e)&&X!=null&&!i.hasOwnProperty(_e))switch(_e){case"selected":e.selected=!1;break;default:We(e,t,_e,null,i,X)}for(C in i)if(X=i[C],J=a[C],i.hasOwnProperty(C)&&X!==J&&(X!=null||J!=null))switch(C){case"selected":e.selected=X&&typeof X!="function"&&typeof X!="symbol";break;default:We(e,t,C,X,i,J)}return;case"img":case"link":case"area":case"base":case"br":case"col":case"embed":case"hr":case"keygen":case"meta":case"param":case"source":case"track":case"wbr":case"menuitem":for(var Ce in a)X=a[Ce],a.hasOwnProperty(Ce)&&X!=null&&!i.hasOwnProperty(Ce)&&We(e,t,Ce,null,i,X);for(K in i)if(X=i[K],J=a[K],i.hasOwnProperty(K)&&X!==J&&(X!=null||J!=null))switch(K){case"children":case"dangerouslySetInnerHTML":if(X!=null)throw Error(o(137,t));break;default:We(e,t,K,X,i,J)}return;default:if(kc(t)){for(var et in a)X=a[et],a.hasOwnProperty(et)&&X!==void 0&&!i.hasOwnProperty(et)&&ud(e,t,et,void 0,i,X);for(le in i)X=i[le],J=a[le],!i.hasOwnProperty(le)||X===J||X===void 0&&J===void 0||ud(e,t,le,X,i,J);return}}for(var H in a)X=a[H],a.hasOwnProperty(H)&&X!=null&&!i.hasOwnProperty(H)&&We(e,t,H,null,i,X);for(oe in i)X=i[oe],J=a[oe],!i.hasOwnProperty(oe)||X===J||X==null&&J==null||We(e,t,oe,X,i,J)}function Gy(e){switch(e){case"css":case"script":case"font":case"img":case"image":case"input":case"link":return!0;default:return!1}}function V2(){if(typeof performance.getEntriesByType=="function"){for(var e=0,t=0,a=performance.getEntriesByType("resource"),i=0;i<a.length;i++){var r=a[i],c=r.transferSize,m=r.initiatorType,b=r.duration;if(c&&b&&Gy(m)){for(m=0,b=r.responseEnd,i+=1;i<a.length;i++){var C=a[i],K=C.startTime;if(K>b)break;var le=C.transferSize,oe=C.initiatorType;le&&Gy(oe)&&(C=C.responseEnd,m+=le*(C<b?1:(b-K)/(C-K)))}if(--i,t+=8*(c+m)/(r.duration/1e3),e++,10<e)break}}if(0<e)return t/e/1e6}return navigator.connection&&(e=navigator.connection.downlink,typeof e=="number")?e:5}var dd=null,fd=null;function Cr(e){return e.nodeType===9?e:e.ownerDocument}function Iy(e){switch(e){case"http://www.w3.org/2000/svg":return 1;case"http://www.w3.org/1998/Math/MathML":return 2;default:return 0}}function Qy(e,t){if(e===0)switch(t){case"svg":return 1;case"math":return 2;default:return 0}return e===1&&t==="foreignObject"?0:e}function hd(e,t){return e==="textarea"||e==="noscript"||typeof t.children=="string"||typeof t.children=="number"||typeof t.children=="bigint"||typeof t.dangerouslySetInnerHTML=="object"&&t.dangerouslySetInnerHTML!==null&&t.dangerouslySetInnerHTML.__html!=null}var pd=null;function Y2(){var e=window.event;return e&&e.type==="popstate"?e===pd?!1:(pd=e,!0):(pd=null,!1)}var Ky=typeof setTimeout=="function"?setTimeout:void 0,$2=typeof clearTimeout=="function"?clearTimeout:void 0,Vy=typeof Promise=="function"?Promise:void 0,F2=typeof queueMicrotask=="function"?queueMicrotask:typeof Vy<"u"?function(e){return Vy.resolve(null).then(e).catch(X2)}:Ky;function X2(e){setTimeout(function(){throw e})}function Ga(e){return e==="head"}function Yy(e,t){var a=t,i=0;do{var r=a.nextSibling;if(e.removeChild(a),r&&r.nodeType===8)if(a=r.data,a==="/$"||a==="/&"){if(i===0){e.removeChild(r),Qi(t);return}i--}else if(a==="$"||a==="$?"||a==="$~"||a==="$!"||a==="&")i++;else if(a==="html")Fs(e.ownerDocument.documentElement);else if(a==="head"){a=e.ownerDocument.head,Fs(a);for(var c=a.firstChild;c;){var m=c.nextSibling,b=c.nodeName;c[fs]||b==="SCRIPT"||b==="STYLE"||b==="LINK"&&c.rel.toLowerCase()==="stylesheet"||a.removeChild(c),c=m}}else a==="body"&&Fs(e.ownerDocument.body);a=r}while(a);Qi(t)}function $y(e,t){var a=e;e=0;do{var i=a.nextSibling;if(a.nodeType===1?t?(a._stashedDisplay=a.style.display,a.style.display="none"):(a.style.display=a._stashedDisplay||"",a.getAttribute("style")===""&&a.removeAttribute("style")):a.nodeType===3&&(t?(a._stashedText=a.nodeValue,a.nodeValue=""):a.nodeValue=a._stashedText||""),i&&i.nodeType===8)if(a=i.data,a==="/$"){if(e===0)break;e--}else a!=="$"&&a!=="$?"&&a!=="$~"&&a!=="$!"||e++;a=i}while(a)}function md(e){var t=e.firstChild;for(t&&t.nodeType===10&&(t=t.nextSibling);t;){var a=t;switch(t=t.nextSibling,a.nodeName){case"HTML":case"HEAD":case"BODY":md(a),xc(a);continue;case"SCRIPT":case"STYLE":continue;case"LINK":if(a.rel.toLowerCase()==="stylesheet")continue}e.removeChild(a)}}function Z2(e,t,a,i){for(;e.nodeType===1;){var r=a;if(e.nodeName.toLowerCase()!==t.toLowerCase()){if(!i&&(e.nodeName!=="INPUT"||e.type!=="hidden"))break}else if(i){if(!e[fs])switch(t){case"meta":if(!e.hasAttribute("itemprop"))break;return e;case"link":if(c=e.getAttribute("rel"),c==="stylesheet"&&e.hasAttribute("data-precedence"))break;if(c!==r.rel||e.getAttribute("href")!==(r.href==null||r.href===""?null:r.href)||e.getAttribute("crossorigin")!==(r.crossOrigin==null?null:r.crossOrigin)||e.getAttribute("title")!==(r.title==null?null:r.title))break;return e;case"style":if(e.hasAttribute("data-precedence"))break;return e;case"script":if(c=e.getAttribute("src"),(c!==(r.src==null?null:r.src)||e.getAttribute("type")!==(r.type==null?null:r.type)||e.getAttribute("crossorigin")!==(r.crossOrigin==null?null:r.crossOrigin))&&c&&e.hasAttribute("async")&&!e.hasAttribute("itemprop"))break;return e;default:return e}}else if(t==="input"&&e.type==="hidden"){var c=r.name==null?null:""+r.name;if(r.type==="hidden"&&e.getAttribute("name")===c)return e}else return e;if(e=wn(e.nextSibling),e===null)break}return null}function P2(e,t,a){if(t==="")return null;for(;e.nodeType!==3;)if((e.nodeType!==1||e.nodeName!=="INPUT"||e.type!=="hidden")&&!a||(e=wn(e.nextSibling),e===null))return null;return e}function Fy(e,t){for(;e.nodeType!==8;)if((e.nodeType!==1||e.nodeName!=="INPUT"||e.type!=="hidden")&&!t||(e=wn(e.nextSibling),e===null))return null;return e}function yd(e){return e.data==="$?"||e.data==="$~"}function gd(e){return e.data==="$!"||e.data==="$?"&&e.ownerDocument.readyState!=="loading"}function J2(e,t){var a=e.ownerDocument;if(e.data==="$~")e._reactRetry=t;else if(e.data!=="$?"||a.readyState!=="loading")t();else{var i=function(){t(),a.removeEventListener("DOMContentLoaded",i)};a.addEventListener("DOMContentLoaded",i),e._reactRetry=i}}function wn(e){for(;e!=null;e=e.nextSibling){var t=e.nodeType;if(t===1||t===3)break;if(t===8){if(t=e.data,t==="$"||t==="$!"||t==="$?"||t==="$~"||t==="&"||t==="F!"||t==="F")break;if(t==="/$"||t==="/&")return null}}return e}var bd=null;function Xy(e){e=e.nextSibling;for(var t=0;e;){if(e.nodeType===8){var a=e.data;if(a==="/$"||a==="/&"){if(t===0)return wn(e.nextSibling);t--}else a!=="$"&&a!=="$!"&&a!=="$?"&&a!=="$~"&&a!=="&"||t++}e=e.nextSibling}return null}function Zy(e){e=e.previousSibling;for(var t=0;e;){if(e.nodeType===8){var a=e.data;if(a==="$"||a==="$!"||a==="$?"||a==="$~"||a==="&"){if(t===0)return e;t--}else a!=="/$"&&a!=="/&"||t++}e=e.previousSibling}return null}function Py(e,t,a){switch(t=Cr(a),e){case"html":if(e=t.documentElement,!e)throw Error(o(452));return e;case"head":if(e=t.head,!e)throw Error(o(453));return e;case"body":if(e=t.body,!e)throw Error(o(454));return e;default:throw Error(o(451))}}function Fs(e){for(var t=e.attributes;t.length;)e.removeAttributeNode(t[0]);xc(e)}var Sn=new Map,Jy=new Set;function Ar(e){return typeof e.getRootNode=="function"?e.getRootNode():e.nodeType===9?e:e.ownerDocument}var ca=Z.d;Z.d={f:W2,r:e_,D:t_,C:n_,L:a_,m:l_,X:s_,S:i_,M:o_};function W2(){var e=ca.f(),t=xr();return e||t}function e_(e){var t=ri(e);t!==null&&t.tag===5&&t.type==="form"?mm(t):ca.r(e)}var qi=typeof document>"u"?null:document;function Wy(e,t,a){var i=qi;if(i&&typeof t=="string"&&t){var r=mn(t);r='link[rel="'+e+'"][href="'+r+'"]',typeof a=="string"&&(r+='[crossorigin="'+a+'"]'),Jy.has(r)||(Jy.add(r),e={rel:e,crossOrigin:a,href:t},i.querySelector(r)===null&&(t=i.createElement("link"),Ot(t,"link",e),Et(t),i.head.appendChild(t)))}}function t_(e){ca.D(e),Wy("dns-prefetch",e,null)}function n_(e,t){ca.C(e,t),Wy("preconnect",e,t)}function a_(e,t,a){ca.L(e,t,a);var i=qi;if(i&&e&&t){var r='link[rel="preload"][as="'+mn(t)+'"]';t==="image"&&a&&a.imageSrcSet?(r+='[imagesrcset="'+mn(a.imageSrcSet)+'"]',typeof a.imageSizes=="string"&&(r+='[imagesizes="'+mn(a.imageSizes)+'"]')):r+='[href="'+mn(e)+'"]';var c=r;switch(t){case"style":c=Gi(e);break;case"script":c=Ii(e)}Sn.has(c)||(e=v({rel:"preload",href:t==="image"&&a&&a.imageSrcSet?void 0:e,as:t},a),Sn.set(c,e),i.querySelector(r)!==null||t==="style"&&i.querySelector(Xs(c))||t==="script"&&i.querySelector(Zs(c))||(t=i.createElement("link"),Ot(t,"link",e),Et(t),i.head.appendChild(t)))}}function l_(e,t){ca.m(e,t);var a=qi;if(a&&e){var i=t&&typeof t.as=="string"?t.as:"script",r='link[rel="modulepreload"][as="'+mn(i)+'"][href="'+mn(e)+'"]',c=r;switch(i){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":c=Ii(e)}if(!Sn.has(c)&&(e=v({rel:"modulepreload",href:e},t),Sn.set(c,e),a.querySelector(r)===null)){switch(i){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":if(a.querySelector(Zs(c)))return}i=a.createElement("link"),Ot(i,"link",e),Et(i),a.head.appendChild(i)}}}function i_(e,t,a){ca.S(e,t,a);var i=qi;if(i&&e){var r=ci(i).hoistableStyles,c=Gi(e);t=t||"default";var m=r.get(c);if(!m){var b={loading:0,preload:null};if(m=i.querySelector(Xs(c)))b.loading=5;else{e=v({rel:"stylesheet",href:e,"data-precedence":t},a),(a=Sn.get(c))&&vd(e,a);var C=m=i.createElement("link");Et(C),Ot(C,"link",e),C._p=new Promise(function(K,le){C.onload=K,C.onerror=le}),C.addEventListener("load",function(){b.loading|=1}),C.addEventListener("error",function(){b.loading|=2}),b.loading|=4,Nr(m,t,i)}m={type:"stylesheet",instance:m,count:1,state:b},r.set(c,m)}}}function s_(e,t){ca.X(e,t);var a=qi;if(a&&e){var i=ci(a).hoistableScripts,r=Ii(e),c=i.get(r);c||(c=a.querySelector(Zs(r)),c||(e=v({src:e,async:!0},t),(t=Sn.get(r))&&xd(e,t),c=a.createElement("script"),Et(c),Ot(c,"link",e),a.head.appendChild(c)),c={type:"script",instance:c,count:1,state:null},i.set(r,c))}}function o_(e,t){ca.M(e,t);var a=qi;if(a&&e){var i=ci(a).hoistableScripts,r=Ii(e),c=i.get(r);c||(c=a.querySelector(Zs(r)),c||(e=v({src:e,async:!0,type:"module"},t),(t=Sn.get(r))&&xd(e,t),c=a.createElement("script"),Et(c),Ot(c,"link",e),a.head.appendChild(c)),c={type:"script",instance:c,count:1,state:null},i.set(r,c))}}function eg(e,t,a,i){var r=(r=q.current)?Ar(r):null;if(!r)throw Error(o(446));switch(e){case"meta":case"title":return null;case"style":return typeof a.precedence=="string"&&typeof a.href=="string"?(t=Gi(a.href),a=ci(r).hoistableStyles,i=a.get(t),i||(i={type:"style",instance:null,count:0,state:null},a.set(t,i)),i):{type:"void",instance:null,count:0,state:null};case"link":if(a.rel==="stylesheet"&&typeof a.href=="string"&&typeof a.precedence=="string"){e=Gi(a.href);var c=ci(r).hoistableStyles,m=c.get(e);if(m||(r=r.ownerDocument||r,m={type:"stylesheet",instance:null,count:0,state:{loading:0,preload:null}},c.set(e,m),(c=r.querySelector(Xs(e)))&&!c._p&&(m.instance=c,m.state.loading=5),Sn.has(e)||(a={rel:"preload",as:"style",href:a.href,crossOrigin:a.crossOrigin,integrity:a.integrity,media:a.media,hrefLang:a.hrefLang,referrerPolicy:a.referrerPolicy},Sn.set(e,a),c||r_(r,e,a,m.state))),t&&i===null)throw Error(o(528,""));return m}if(t&&i!==null)throw Error(o(529,""));return null;case"script":return t=a.async,a=a.src,typeof a=="string"&&t&&typeof t!="function"&&typeof t!="symbol"?(t=Ii(a),a=ci(r).hoistableScripts,i=a.get(t),i||(i={type:"script",instance:null,count:0,state:null},a.set(t,i)),i):{type:"void",instance:null,count:0,state:null};default:throw Error(o(444,e))}}function Gi(e){return'href="'+mn(e)+'"'}function Xs(e){return'link[rel="stylesheet"]['+e+"]"}function tg(e){return v({},e,{"data-precedence":e.precedence,precedence:null})}function r_(e,t,a,i){e.querySelector('link[rel="preload"][as="style"]['+t+"]")?i.loading=1:(t=e.createElement("link"),i.preload=t,t.addEventListener("load",function(){return i.loading|=1}),t.addEventListener("error",function(){return i.loading|=2}),Ot(t,"link",a),Et(t),e.head.appendChild(t))}function Ii(e){return'[src="'+mn(e)+'"]'}function Zs(e){return"script[async]"+e}function ng(e,t,a){if(t.count++,t.instance===null)switch(t.type){case"style":var i=e.querySelector('style[data-href~="'+mn(a.href)+'"]');if(i)return t.instance=i,Et(i),i;var r=v({},a,{"data-href":a.href,"data-precedence":a.precedence,href:null,precedence:null});return i=(e.ownerDocument||e).createElement("style"),Et(i),Ot(i,"style",r),Nr(i,a.precedence,e),t.instance=i;case"stylesheet":r=Gi(a.href);var c=e.querySelector(Xs(r));if(c)return t.state.loading|=4,t.instance=c,Et(c),c;i=tg(a),(r=Sn.get(r))&&vd(i,r),c=(e.ownerDocument||e).createElement("link"),Et(c);var m=c;return m._p=new Promise(function(b,C){m.onload=b,m.onerror=C}),Ot(c,"link",i),t.state.loading|=4,Nr(c,a.precedence,e),t.instance=c;case"script":return c=Ii(a.src),(r=e.querySelector(Zs(c)))?(t.instance=r,Et(r),r):(i=a,(r=Sn.get(c))&&(i=v({},a),xd(i,r)),e=e.ownerDocument||e,r=e.createElement("script"),Et(r),Ot(r,"link",i),e.head.appendChild(r),t.instance=r);case"void":return null;default:throw Error(o(443,t.type))}else t.type==="stylesheet"&&(t.state.loading&4)===0&&(i=t.instance,t.state.loading|=4,Nr(i,a.precedence,e));return t.instance}function Nr(e,t,a){for(var i=a.querySelectorAll('link[rel="stylesheet"][data-precedence],style[data-precedence]'),r=i.length?i[i.length-1]:null,c=r,m=0;m<i.length;m++){var b=i[m];if(b.dataset.precedence===t)c=b;else if(c!==r)break}c?c.parentNode.insertBefore(e,c.nextSibling):(t=a.nodeType===9?a.head:a,t.insertBefore(e,t.firstChild))}function vd(e,t){e.crossOrigin==null&&(e.crossOrigin=t.crossOrigin),e.referrerPolicy==null&&(e.referrerPolicy=t.referrerPolicy),e.title==null&&(e.title=t.title)}function xd(e,t){e.crossOrigin==null&&(e.crossOrigin=t.crossOrigin),e.referrerPolicy==null&&(e.referrerPolicy=t.referrerPolicy),e.integrity==null&&(e.integrity=t.integrity)}var Tr=null;function ag(e,t,a){if(Tr===null){var i=new Map,r=Tr=new Map;r.set(a,i)}else r=Tr,i=r.get(a),i||(i=new Map,r.set(a,i));if(i.has(e))return i;for(i.set(e,null),a=a.getElementsByTagName(e),r=0;r<a.length;r++){var c=a[r];if(!(c[fs]||c[Ct]||e==="link"&&c.getAttribute("rel")==="stylesheet")&&c.namespaceURI!=="http://www.w3.org/2000/svg"){var m=c.getAttribute(t)||"";m=e+m;var b=i.get(m);b?b.push(c):i.set(m,[c])}}return i}function lg(e,t,a){e=e.ownerDocument||e,e.head.insertBefore(a,t==="title"?e.querySelector("head > title"):null)}function c_(e,t,a){if(a===1||t.itemProp!=null)return!1;switch(e){case"meta":case"title":return!0;case"style":if(typeof t.precedence!="string"||typeof t.href!="string"||t.href==="")break;return!0;case"link":if(typeof t.rel!="string"||typeof t.href!="string"||t.href===""||t.onLoad||t.onError)break;switch(t.rel){case"stylesheet":return e=t.disabled,typeof t.precedence=="string"&&e==null;default:return!0}case"script":if(t.async&&typeof t.async!="function"&&typeof t.async!="symbol"&&!t.onLoad&&!t.onError&&t.src&&typeof t.src=="string")return!0}return!1}function ig(e){return!(e.type==="stylesheet"&&(e.state.loading&3)===0)}function u_(e,t,a,i){if(a.type==="stylesheet"&&(typeof i.media!="string"||matchMedia(i.media).matches!==!1)&&(a.state.loading&4)===0){if(a.instance===null){var r=Gi(i.href),c=t.querySelector(Xs(r));if(c){t=c._p,t!==null&&typeof t=="object"&&typeof t.then=="function"&&(e.count++,e=Or.bind(e),t.then(e,e)),a.state.loading|=4,a.instance=c,Et(c);return}c=t.ownerDocument||t,i=tg(i),(r=Sn.get(r))&&vd(i,r),c=c.createElement("link"),Et(c);var m=c;m._p=new Promise(function(b,C){m.onload=b,m.onerror=C}),Ot(c,"link",i),a.instance=c}e.stylesheets===null&&(e.stylesheets=new Map),e.stylesheets.set(a,t),(t=a.state.preload)&&(a.state.loading&3)===0&&(e.count++,a=Or.bind(e),t.addEventListener("load",a),t.addEventListener("error",a))}}var _d=0;function d_(e,t){return e.stylesheets&&e.count===0&&zr(e,e.stylesheets),0<e.count||0<e.imgCount?function(a){var i=setTimeout(function(){if(e.stylesheets&&zr(e,e.stylesheets),e.unsuspend){var c=e.unsuspend;e.unsuspend=null,c()}},6e4+t);0<e.imgBytes&&_d===0&&(_d=62500*V2());var r=setTimeout(function(){if(e.waitingForImages=!1,e.count===0&&(e.stylesheets&&zr(e,e.stylesheets),e.unsuspend)){var c=e.unsuspend;e.unsuspend=null,c()}},(e.imgBytes>_d?50:800)+t);return e.unsuspend=a,function(){e.unsuspend=null,clearTimeout(i),clearTimeout(r)}}:null}function Or(){if(this.count--,this.count===0&&(this.imgCount===0||!this.waitingForImages)){if(this.stylesheets)zr(this,this.stylesheets);else if(this.unsuspend){var e=this.unsuspend;this.unsuspend=null,e()}}}var Rr=null;function zr(e,t){e.stylesheets=null,e.unsuspend!==null&&(e.count++,Rr=new Map,t.forEach(f_,e),Rr=null,Or.call(e))}function f_(e,t){if(!(t.state.loading&4)){var a=Rr.get(e);if(a)var i=a.get(null);else{a=new Map,Rr.set(e,a);for(var r=e.querySelectorAll("link[data-precedence],style[data-precedence]"),c=0;c<r.length;c++){var m=r[c];(m.nodeName==="LINK"||m.getAttribute("media")!=="not all")&&(a.set(m.dataset.precedence,m),i=m)}i&&a.set(null,i)}r=t.instance,m=r.getAttribute("data-precedence"),c=a.get(m)||i,c===i&&a.set(null,r),a.set(m,r),this.count++,i=Or.bind(this),r.addEventListener("load",i),r.addEventListener("error",i),c?c.parentNode.insertBefore(r,c.nextSibling):(e=e.nodeType===9?e.head:e,e.insertBefore(r,e.firstChild)),t.state.loading|=4}}var Ps={$$typeof:D,Provider:null,Consumer:null,_currentValue:ue,_currentValue2:ue,_threadCount:0};function h_(e,t,a,i,r,c,m,b,C){this.tag=1,this.containerInfo=e,this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.next=this.pendingContext=this.context=this.cancelPendingCommit=null,this.callbackPriority=0,this.expirationTimes=pl(-1),this.entangledLanes=this.shellSuspendCounter=this.errorRecoveryDisabledLanes=this.expiredLanes=this.warmLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=pl(0),this.hiddenUpdates=pl(null),this.identifierPrefix=i,this.onUncaughtError=r,this.onCaughtError=c,this.onRecoverableError=m,this.pooledCache=null,this.pooledCacheLanes=0,this.formState=C,this.incompleteTransitions=new Map}function sg(e,t,a,i,r,c,m,b,C,K,le,oe){return e=new h_(e,t,a,m,C,K,le,oe,b),t=1,c===!0&&(t|=24),c=nn(3,null,null,t),e.current=c,c.stateNode=e,t=eu(),t.refCount++,e.pooledCache=t,t.refCount++,c.memoizedState={element:i,isDehydrated:a,cache:t},lu(c),e}function og(e){return e?(e=vi,e):vi}function rg(e,t,a,i,r,c){r=og(r),i.context===null?i.context=r:i.pendingContext=r,i=Na(t),i.payload={element:a},c=c===void 0?null:c,c!==null&&(i.callback=c),a=Ta(e,i,t),a!==null&&(Zt(a,e,t),As(a,e,t))}function cg(e,t){if(e=e.memoizedState,e!==null&&e.dehydrated!==null){var a=e.retryLane;e.retryLane=a!==0&&a<t?a:t}}function wd(e,t){cg(e,t),(e=e.alternate)&&cg(e,t)}function ug(e){if(e.tag===13||e.tag===31){var t=vl(e,67108864);t!==null&&Zt(t,e,67108864),wd(e,67108864)}}function dg(e){if(e.tag===13||e.tag===31){var t=rn();t=gc(t);var a=vl(e,t);a!==null&&Zt(a,e,t),wd(e,t)}}var Dr=!0;function p_(e,t,a,i){var r=w.T;w.T=null;var c=Z.p;try{Z.p=2,Sd(e,t,a,i)}finally{Z.p=c,w.T=r}}function m_(e,t,a,i){var r=w.T;w.T=null;var c=Z.p;try{Z.p=8,Sd(e,t,a,i)}finally{Z.p=c,w.T=r}}function Sd(e,t,a,i){if(Dr){var r=kd(i);if(r===null)cd(e,t,i,Ur,a),hg(e,i);else if(g_(r,e,t,a,i))i.stopPropagation();else if(hg(e,i),t&4&&-1<y_.indexOf(e)){for(;r!==null;){var c=ri(r);if(c!==null)switch(c.tag){case 3:if(c=c.stateNode,c.current.memoizedState.isDehydrated){var m=ct(c.pendingLanes);if(m!==0){var b=c;for(b.pendingLanes|=2,b.entangledLanes|=2;m;){var C=1<<31-pe(m);b.entanglements[1]|=C,m&=~C}Un(c),(Fe&6)===0&&(br=rt()+500,Vs(0))}}break;case 31:case 13:b=vl(c,2),b!==null&&Zt(b,c,2),xr(),wd(c,2)}if(c=kd(i),c===null&&cd(e,t,i,Ur,a),c===r)break;r=c}r!==null&&i.stopPropagation()}else cd(e,t,i,null,a)}}function kd(e){return e=jc(e),Ed(e)}var Ur=null;function Ed(e){if(Ur=null,e=oi(e),e!==null){var t=d(e);if(t===null)e=null;else{var a=t.tag;if(a===13){if(e=h(t),e!==null)return e;e=null}else if(a===31){if(e=p(t),e!==null)return e;e=null}else if(a===3){if(t.stateNode.current.memoizedState.isDehydrated)return t.tag===3?t.stateNode.containerInfo:null;e=null}else t!==e&&(e=null)}}return Ur=e,null}function fg(e){switch(e){case"beforetoggle":case"cancel":case"click":case"close":case"contextmenu":case"copy":case"cut":case"auxclick":case"dblclick":case"dragend":case"dragstart":case"drop":case"focusin":case"focusout":case"input":case"invalid":case"keydown":case"keypress":case"keyup":case"mousedown":case"mouseup":case"paste":case"pause":case"play":case"pointercancel":case"pointerdown":case"pointerup":case"ratechange":case"reset":case"resize":case"seeked":case"submit":case"toggle":case"touchcancel":case"touchend":case"touchstart":case"volumechange":case"change":case"selectionchange":case"textInput":case"compositionstart":case"compositionend":case"compositionupdate":case"beforeblur":case"afterblur":case"beforeinput":case"blur":case"fullscreenchange":case"focus":case"hashchange":case"popstate":case"select":case"selectstart":return 2;case"drag":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"mousemove":case"mouseout":case"mouseover":case"pointermove":case"pointerout":case"pointerover":case"scroll":case"touchmove":case"wheel":case"mouseenter":case"mouseleave":case"pointerenter":case"pointerleave":return 8;case"message":switch(Mo()){case ds:return 2;case li:return 8;case fl:case ii:return 32;case it:return 268435456;default:return 32}default:return 32}}var jd=!1,Ia=null,Qa=null,Ka=null,Js=new Map,Ws=new Map,Va=[],y_="mousedown mouseup touchcancel touchend touchstart auxclick dblclick pointercancel pointerdown pointerup dragend dragstart drop compositionend compositionstart keydown keypress keyup input textInput copy cut paste click change contextmenu reset".split(" ");function hg(e,t){switch(e){case"focusin":case"focusout":Ia=null;break;case"dragenter":case"dragleave":Qa=null;break;case"mouseover":case"mouseout":Ka=null;break;case"pointerover":case"pointerout":Js.delete(t.pointerId);break;case"gotpointercapture":case"lostpointercapture":Ws.delete(t.pointerId)}}function eo(e,t,a,i,r,c){return e===null||e.nativeEvent!==c?(e={blockedOn:t,domEventName:a,eventSystemFlags:i,nativeEvent:c,targetContainers:[r]},t!==null&&(t=ri(t),t!==null&&ug(t)),e):(e.eventSystemFlags|=i,t=e.targetContainers,r!==null&&t.indexOf(r)===-1&&t.push(r),e)}function g_(e,t,a,i,r){switch(t){case"focusin":return Ia=eo(Ia,e,t,a,i,r),!0;case"dragenter":return Qa=eo(Qa,e,t,a,i,r),!0;case"mouseover":return Ka=eo(Ka,e,t,a,i,r),!0;case"pointerover":var c=r.pointerId;return Js.set(c,eo(Js.get(c)||null,e,t,a,i,r)),!0;case"gotpointercapture":return c=r.pointerId,Ws.set(c,eo(Ws.get(c)||null,e,t,a,i,r)),!0}return!1}function pg(e){var t=oi(e.target);if(t!==null){var a=d(t);if(a!==null){if(t=a.tag,t===13){if(t=h(a),t!==null){e.blockedOn=t,Ch(e.priority,function(){dg(a)});return}}else if(t===31){if(t=p(a),t!==null){e.blockedOn=t,Ch(e.priority,function(){dg(a)});return}}else if(t===3&&a.stateNode.current.memoizedState.isDehydrated){e.blockedOn=a.tag===3?a.stateNode.containerInfo:null;return}}}e.blockedOn=null}function Lr(e){if(e.blockedOn!==null)return!1;for(var t=e.targetContainers;0<t.length;){var a=kd(e.nativeEvent);if(a===null){a=e.nativeEvent;var i=new a.constructor(a.type,a);Ec=i,a.target.dispatchEvent(i),Ec=null}else return t=ri(a),t!==null&&ug(t),e.blockedOn=a,!1;t.shift()}return!0}function mg(e,t,a){Lr(e)&&a.delete(t)}function b_(){jd=!1,Ia!==null&&Lr(Ia)&&(Ia=null),Qa!==null&&Lr(Qa)&&(Qa=null),Ka!==null&&Lr(Ka)&&(Ka=null),Js.forEach(mg),Ws.forEach(mg)}function Br(e,t){e.blockedOn===t&&(e.blockedOn=null,jd||(jd=!0,n.unstable_scheduleCallback(n.unstable_NormalPriority,b_)))}var Hr=null;function yg(e){Hr!==e&&(Hr=e,n.unstable_scheduleCallback(n.unstable_NormalPriority,function(){Hr===e&&(Hr=null);for(var t=0;t<e.length;t+=3){var a=e[t],i=e[t+1],r=e[t+2];if(typeof i!="function"){if(Ed(i||a)===null)continue;break}var c=ri(a);c!==null&&(e.splice(t,3),t-=3,ku(c,{pending:!0,data:r,method:a.method,action:i},i,r))}}))}function Qi(e){function t(C){return Br(C,e)}Ia!==null&&Br(Ia,e),Qa!==null&&Br(Qa,e),Ka!==null&&Br(Ka,e),Js.forEach(t),Ws.forEach(t);for(var a=0;a<Va.length;a++){var i=Va[a];i.blockedOn===e&&(i.blockedOn=null)}for(;0<Va.length&&(a=Va[0],a.blockedOn===null);)pg(a),a.blockedOn===null&&Va.shift();if(a=(e.ownerDocument||e).$$reactFormReplay,a!=null)for(i=0;i<a.length;i+=3){var r=a[i],c=a[i+1],m=r[Kt]||null;if(typeof c=="function")m||yg(a);else if(m){var b=null;if(c&&c.hasAttribute("formAction")){if(r=c,m=c[Kt]||null)b=m.formAction;else if(Ed(r)!==null)continue}else b=m.action;typeof b=="function"?a[i+1]=b:(a.splice(i,3),i-=3),yg(a)}}}function gg(){function e(c){c.canIntercept&&c.info==="react-transition"&&c.intercept({handler:function(){return new Promise(function(m){return r=m})},focusReset:"manual",scroll:"manual"})}function t(){r!==null&&(r(),r=null),i||setTimeout(a,20)}function a(){if(!i&&!navigation.transition){var c=navigation.currentEntry;c&&c.url!=null&&navigation.navigate(c.url,{state:c.getState(),info:"react-transition",history:"replace"})}}if(typeof navigation=="object"){var i=!1,r=null;return navigation.addEventListener("navigate",e),navigation.addEventListener("navigatesuccess",t),navigation.addEventListener("navigateerror",t),setTimeout(a,100),function(){i=!0,navigation.removeEventListener("navigate",e),navigation.removeEventListener("navigatesuccess",t),navigation.removeEventListener("navigateerror",t),r!==null&&(r(),r=null)}}}function Md(e){this._internalRoot=e}qr.prototype.render=Md.prototype.render=function(e){var t=this._internalRoot;if(t===null)throw Error(o(409));var a=t.current,i=rn();rg(a,i,e,t,null,null)},qr.prototype.unmount=Md.prototype.unmount=function(){var e=this._internalRoot;if(e!==null){this._internalRoot=null;var t=e.containerInfo;rg(e.current,2,null,e,null,null),xr(),t[si]=null}};function qr(e){this._internalRoot=e}qr.prototype.unstable_scheduleHydration=function(e){if(e){var t=Mh();e={blockedOn:null,target:e,priority:t};for(var a=0;a<Va.length&&t!==0&&t<Va[a].priority;a++);Va.splice(a,0,e),a===0&&pg(e)}};var bg=l.version;if(bg!=="19.2.6")throw Error(o(527,bg,"19.2.6"));Z.findDOMNode=function(e){var t=e._reactInternals;if(t===void 0)throw typeof e.render=="function"?Error(o(188)):(e=Object.keys(e).join(","),Error(o(268,e)));return e=g(t),e=e!==null?x(e):null,e=e===null?null:e.stateNode,e};var v_={bundleType:0,version:"19.2.6",rendererPackageName:"react-dom",currentDispatcherRef:w,reconcilerVersion:"19.2.6"};if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"){var Gr=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!Gr.isDisabled&&Gr.supportsFiber)try{xa=Gr.inject(v_),zt=Gr}catch{}}return no.createRoot=function(e,t){if(!u(e))throw Error(o(299));var a=!1,i="",r=Em,c=jm,m=Mm;return t!=null&&(t.unstable_strictMode===!0&&(a=!0),t.identifierPrefix!==void 0&&(i=t.identifierPrefix),t.onUncaughtError!==void 0&&(r=t.onUncaughtError),t.onCaughtError!==void 0&&(c=t.onCaughtError),t.onRecoverableError!==void 0&&(m=t.onRecoverableError)),t=sg(e,1,!1,null,null,a,i,null,r,c,m,gg),e[si]=t.current,rd(e),new Md(t)},no.hydrateRoot=function(e,t,a){if(!u(e))throw Error(o(299));var i=!1,r="",c=Em,m=jm,b=Mm,C=null;return a!=null&&(a.unstable_strictMode===!0&&(i=!0),a.identifierPrefix!==void 0&&(r=a.identifierPrefix),a.onUncaughtError!==void 0&&(c=a.onUncaughtError),a.onCaughtError!==void 0&&(m=a.onCaughtError),a.onRecoverableError!==void 0&&(b=a.onRecoverableError),a.formState!==void 0&&(C=a.formState)),t=sg(e,1,!0,t,a??null,i,r,C,c,m,b,gg),t.context=og(null),a=t.current,i=rn(),i=gc(i),r=Na(i),r.callback=null,Ta(a,r,i),a=i,t.current.lanes=a,_a(t,a),Un(t),e[si]=t.current,rd(e),new qr(t)},no.version="19.2.6",no}var Ag;function A_(){if(Ag)return Td.exports;Ag=1;function n(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(n)}catch(l){console.error(l)}}return n(),Td.exports=C_(),Td.exports}var N_=A_();function T_(n){if(!n)return null;const l=n.split("~"),s=l[0];if(!s)return null;if(l.length===1)return{kind:"section",instanceId:s};const o=l[1];if(!o)return null;const u=l[2],d=u!==void 0?Number(u):NaN;return{kind:"slot",instanceId:s,slotId:o,...Number.isInteger(d)?{itemIndex:d}:{}}}function O_(n){if(!n)return null;if(n.kind==="section")return n.instanceId;const l=`${n.instanceId}~${n.slotId}`;return n.itemIndex!==void 0?`${l}~${n.itemIndex}`:l}function R_(n,l){const s=new URL(l).pathname,o=s.endsWith("/")?s:`${s}/`;return`${n}/`===o?"":n.startsWith(o)?n.slice(o.length):null}function z_(n,l){const[s,o,u,d,...h]=n.split("/").filter(Boolean);if(s!=="fixtures"||!o||u!=="canvas"||h.length>0)return null;const p=new URLSearchParams(l);return{fixture:decodeURIComponent(o),canvasId:d?decodeURIComponent(d):null,format:p.get("format"),selection:T_(p.get("sel"))}}function D_(n){var s;const l=n.fixtures[0];return l===void 0?null:{fixture:l.id,canvasId:((s=n.template.canvases[0])==null?void 0:s.id)??null,format:null,selection:null}}function Ng(n){const l=n.canvasId===null?"canvas":`canvas/${encodeURIComponent(n.canvasId)}`,s=`fixtures/${encodeURIComponent(n.fixture)}/${l}`,o=new URLSearchParams;n.format!==null&&o.set("format",n.format);const u=O_(n.selection);u&&o.set("sel",u);const d=o.toString();return d?`${s}?${d}`:s}function _0(n,l){var s;return((s=n.parentElement)==null?void 0:s.closest(`[${l.slotId}],[${l.slotField}]`))??null}function ga(n,l){return!n.hasAttribute(l.slotUnselectable)}function w0(n,l,s,o){const u=[];for(const d of Array.from(n.querySelectorAll(l)))_0(d,o)===s&&u.push(d);return u}function Gf(n,l,s){return w0(n,`[${s.slotItem}="${String(l)}"]`,n,s)}function Tg(n,l,s,o){var d;let u=n.closest(`[${l}]`);for(;u&&s.contains(u);){if(ga(u,o)&&_0(u,o)===s)return u;u=((d=u.parentElement)==null?void 0:d.closest(`[${l}]`))??null}return null}const Dd=1,U_=12;function L_(n,l){return{"--we-r-top":`${n.top}px`,"--we-r-left":`${n.left}px`,"--we-r-w":`${n.width}px`,"--we-r-h":`${n.height}px`,"--we-r-off":`${l}px`}}function B_(n){const l=uc(n);return l.width<=0||l.height<=0?!1:!H_(n,l)}function Og(n){return n==="hidden"||n==="scroll"||n==="auto"||n==="clip"}function H_(n,l){const s=n.ownerDocument.defaultView;if(!s)return!1;let o=-1/0,u=-1/0,d=1/0,h=1/0;for(let g=n.parentElement;g;g=g.parentElement){const x=s.getComputedStyle(g),v=Og(x.overflowX||x.overflow),E=Og(x.overflowY||x.overflow);if(!v&&!E)continue;const M=g.getBoundingClientRect();v&&(u=Math.max(u,M.left),d=Math.min(d,M.right)),E&&(o=Math.max(o,M.top),h=Math.min(h,M.bottom))}const p=l.left+l.width<=u||l.left>=d,y=l.top+l.height<=o||l.top>=h;return p||y}function uc(n){const l=n.getBoundingClientRect();if(l.width>0&&l.height>0)return l;let s=1/0,o=1/0,u=-1/0,d=-1/0,h=!1;for(const p of Array.from(n.children)){const y=uc(p);y.width<=0||y.height<=0||(h=!0,s=Math.min(s,y.top),o=Math.min(o,y.left),u=Math.max(u,y.right),d=Math.max(d,y.bottom))}return h?new DOMRect(o,s,u-o,d-s):l}function S0(n,l,s,o){if(!n)return;if(!l){Zr(n);return}const u=L_(uc(l),s);for(const[d,h]of Object.entries(u))n.style.setProperty(d,h);o&&n.setAttribute("data-kind",o),n.setAttribute("data-active","true")}function Zr(n){n&&(n.removeAttribute("data-active"),n.removeAttribute("data-kind"))}function Rg(n,l,s,o){if(!n)return[];const u=n.ownerDocument,d=Array.from(n.querySelectorAll(".we-chrome-ring--selection")),h=n.querySelector(":scope > .we-chrome-label");for(;d.length<l.length;){const p=u.createElement("div");p.className="we-chrome-ring we-chrome-ring--selection",n.insertBefore(p,h),d.push(p)}d.forEach((p,y)=>S0(p,l[y]??null,s,o));for(const p of d.slice(Math.max(l.length,1)))p.remove();return d.slice(0,l.length)}function q_(n,l,s){if(!n)return;if(!l||!s){Jd(n);return}const o=uc(l),u=n.getAttribute("data-active")==="true",d=n.textContent!==s;n.textContent=s,n.style.setProperty("--we-l-top",`${o.top}px`),n.style.setProperty("--we-l-left",`${o.left}px`),n.style.setProperty("--we-l-indent",`${U_}px`),u&&d&&(n.removeAttribute("data-active"),n.offsetWidth),n.setAttribute("data-active","true")}function Jd(n){n&&(n.removeAttribute("data-active"),n.textContent="")}function Fl(n){return typeof CSS<"u"&&CSS.escape?CSS.escape(n):n.replace(/[^a-zA-Z0-9_-]/g,l=>`\\${l}`)}function If(n){const l=n.filter(s=>B_(s));return l.length>0?l:n.slice(0,1)}function k0(n,l,s){const o=Array.from(n.querySelectorAll(`[${s.slotId}="${Fl(l)}"]`)).filter(u=>ga(u,s));return If(o)}function G_(n,l,s){if(!l||l.kind!=="slot"||l.item_index==null)return[];const o=[];for(const u of n)o.push(...Gf(u,l.item_index,s).filter(d=>ga(d,s)));return If(o)}function E0(n,l,s){if(!l)return[];const o=n.querySelector(`[${s.sectionInstanceId}="${Fl(l.instance_id)}"]`);if(!o)return[];if(l.kind==="section")return[o];const u=k0(o,l.slot_id,s);if(u.length===0)return[];if(l.item_index!=null||l.field_name){const d=l.field_name?`[${s.slotField}="${Fl(l.field_name)}"]`:null,h=[];for(const p of u){let y=[p];if(!(l.item_index!=null&&(y=Gf(p,l.item_index,s).filter(g=>ga(g,s)),y.length===0)))for(const g of y)if(d){const x=w0(g,d,p,s).filter(v=>ga(v,s));if(x.length>0){h.push(...x);continue}g!==p&&h.push(g)}else h.push(g)}if(h.length>0)return If(h)}return u.map(d=>{const h=d.closest(`[${s.slotGroup}]`);return h&&ga(h,s)?h:d})}function I_(n,l,s){return E0(n,l,s)[0]??null}const zg="we-enh-shield",Q_="we-enh-shield--item",Ki="data-we-live";function K_(n,l,s){if(!l||l.kind!=="slot"||l.item_index==null)return[];const o=[];for(const u of j0(n,l,s))o.push(...Gf(u,l.item_index,s).filter(d=>ga(d,s)));return o}function j0(n,l,s){if(!l||l.kind!=="slot")return[];const o=n.querySelector(`[${s.sectionInstanceId}="${Fl(l.instance_id)}"]`);return o?Array.from(o.querySelectorAll(`[${s.slotId}="${Fl(l.slot_id)}"]`)):[]}function V_(n,l,s){if(n.querySelectorAll(`[${Ki}]`).forEach(u=>u.removeAttribute(Ki)),!l)return;const o=n.querySelector(`[${s.sectionInstanceId}="${Fl(l.instance_id)}"]`);if(o)if(l.kind==="section")o.setAttribute(Ki,"true");else{const u=K_(n,l,s),d=u.length>0?u:j0(n,l,s).filter(h=>ga(h,s));for(const h of d)h.setAttribute(Ki,"true")}}const Yl=1440,Dg=Math.round(Yl*9/16),M0=14,Qf="we-frame-defaults";function Y_(n){return`
|
|
50
|
+
/* Section wrapper -- structure only. No selection chrome here;
|
|
51
|
+
rings are painted by the host's overlay. Zero margin
|
|
52
|
+
+ padding means sections butt edge-to-edge, matching publisher. */
|
|
53
|
+
[${n}] {
|
|
54
|
+
position: relative;
|
|
55
|
+
margin: 0;
|
|
56
|
+
padding: 0;
|
|
57
|
+
cursor: pointer;
|
|
58
|
+
display: grid;
|
|
59
|
+
grid-template-rows: 1fr;
|
|
60
|
+
/* Reveal transition — governs the hidden→visible direction because
|
|
61
|
+
CSS uses the destination state's transition property. Spring easing
|
|
62
|
+
gives a snappy entrance. */
|
|
63
|
+
transition:
|
|
64
|
+
grid-template-rows 200ms cubic-bezier(0.16, 1, 0.3, 1),
|
|
65
|
+
opacity 180ms cubic-bezier(0.16, 1, 0.3, 1);
|
|
66
|
+
}
|
|
67
|
+
|
|
68
|
+
/* Hidden state -- collapse the section out of the page so it reflows shut.
|
|
69
|
+
The 0-height wrapper stays in flow as the anchor for the section's
|
|
70
|
+
floating edge tab (built by the host in its own document). */
|
|
71
|
+
[${n}][data-hidden="true"] {
|
|
72
|
+
grid-template-rows: 0fr;
|
|
73
|
+
opacity: 0;
|
|
74
|
+
pointer-events: none;
|
|
75
|
+
/* Collapse transition — governs the visible→hidden direction.
|
|
76
|
+
Faster + accelerating so the hide feels decisive. */
|
|
77
|
+
transition:
|
|
78
|
+
grid-template-rows 150ms cubic-bezier(0.4, 0, 1, 1),
|
|
79
|
+
opacity 120ms cubic-bezier(0.4, 0, 1, 1);
|
|
80
|
+
}
|
|
81
|
+
|
|
82
|
+
/* Per-section body holds the API HTML.
|
|
83
|
+
1. position:relative gives the body a positioning context for any
|
|
84
|
+
body-scoped chrome or future body-only effects.
|
|
85
|
+
2. isolation:isolate SEALS the section's z-index hierarchy
|
|
86
|
+
inside this stacking context. Without it, any positioned
|
|
87
|
+
descendant with z-index > 0 (the header's sticky+z-50, a
|
|
88
|
+
dropdown's z-40, a sticky CTA) creates a stacking context
|
|
89
|
+
that escapes upward. Sections never need to know the
|
|
90
|
+
editor chrome exists -- internal z-index is unconstrained. */
|
|
91
|
+
/* overflow:hidden clips section content as the grid row collapses;
|
|
92
|
+
min-height:0 lets the grid child shrink below its content size.
|
|
93
|
+
Constraint: overflow:hidden is permanent (not just during animation), so
|
|
94
|
+
section content must not overflow its section-body boundary — sticky
|
|
95
|
+
elements, absolutely-positioned dropdowns, or shadows that bleed outside
|
|
96
|
+
the section edge will be silently clipped. Template sections are
|
|
97
|
+
self-contained blocks; this is safe in practice. */
|
|
98
|
+
.we-section-body { position: relative; isolation: isolate; overflow: hidden; min-height: 0; }`}function $_(n){return`
|
|
99
|
+
[${n}] {
|
|
100
|
+
display: contents;
|
|
101
|
+
/* Computed even while boxless, so the collapse below has a 1fr start
|
|
102
|
+
value to animate from the instant the hidden box appears. */
|
|
103
|
+
grid-template-rows: 1fr;
|
|
104
|
+
cursor: pointer;
|
|
105
|
+
}
|
|
106
|
+
[${n}] > .we-section-body { display: contents; }
|
|
107
|
+
|
|
108
|
+
/* Hidden state -- the wrapper takes a real box again: a zero-height grid
|
|
109
|
+
item in the frame column, collapsing the section out of the page while
|
|
110
|
+
staying in flow as the anchor for its edge tab. display is not
|
|
111
|
+
transitioned, so the box appears at 1fr immediately and the collapse
|
|
112
|
+
animates its full run; the reveal returns to display:contents at once —
|
|
113
|
+
a boxless wrapper has nothing to animate, so re-entry is instant by
|
|
114
|
+
design. */
|
|
115
|
+
[${n}][data-hidden="true"] {
|
|
116
|
+
display: grid;
|
|
117
|
+
grid-template-rows: 0fr;
|
|
118
|
+
opacity: 0;
|
|
119
|
+
pointer-events: none;
|
|
120
|
+
transition:
|
|
121
|
+
grid-template-rows 150ms cubic-bezier(0.4, 0, 1, 1),
|
|
122
|
+
opacity 120ms cubic-bezier(0.4, 0, 1, 1);
|
|
123
|
+
}
|
|
124
|
+
[${n}][data-hidden="true"] > .we-section-body {
|
|
125
|
+
display: block;
|
|
126
|
+
overflow: hidden;
|
|
127
|
+
min-height: 0;
|
|
128
|
+
}
|
|
129
|
+
|
|
130
|
+
/* The frame stylesheet imposes flex-shrink:0 on the column's items from
|
|
131
|
+
outside the section; with the wrapper boxless the section IS that item,
|
|
132
|
+
so the same imposition lands here. Layered so an author utility on the
|
|
133
|
+
section root still wins, exactly as it does against the stylesheet's own
|
|
134
|
+
copy of this rule. */
|
|
135
|
+
@layer ${Qf} {
|
|
136
|
+
[${n}] > .we-section-body > * { flex-shrink: 0; }
|
|
137
|
+
}`}function F_(n,l){const s=l?`#we-page {
|
|
138
|
+
padding: 0;
|
|
139
|
+
}`:`#we-page {
|
|
140
|
+
width: ${Yl}px;
|
|
141
|
+
min-height: ${Dg}px;
|
|
142
|
+
overflow: hidden;
|
|
143
|
+
border-radius: ${M0}px;
|
|
144
|
+
background: #f5f3ee;
|
|
145
|
+
padding: 0;
|
|
146
|
+
}
|
|
147
|
+
/* The window this card stands for. The card's WIDTH is a real viewport, so
|
|
148
|
+
vw units and width queries need nothing from us; its HEIGHT is the page's
|
|
149
|
+
own measurement, which makes 100svh circular here — a section sized from it
|
|
150
|
+
asks for a window its own height is what produced, and climbs on every
|
|
151
|
+
pass. The window-height token is the seam that ends it: a section writes
|
|
152
|
+
the token instead of the unit, and here it is the screen this card is cut
|
|
153
|
+
from (the floor above), a constant that settles in one pass. Declared
|
|
154
|
+
UNLAYERED, unlike the document defaults: this is not a fallback a template
|
|
155
|
+
may better, it is what the window IS on this surface, and Concrete's own
|
|
156
|
+
declaration of the token is unlayered too. A page box takes none of this —
|
|
157
|
+
a frame document is given the window its format declares, so 100svh there
|
|
158
|
+
is already the truth. */
|
|
159
|
+
:root {
|
|
160
|
+
--concrete-window-h: ${Dg}px;
|
|
161
|
+
}`;return`
|
|
162
|
+
html, body {
|
|
163
|
+
margin: 0;
|
|
164
|
+
/* The host owns the scroll container; this document never scrolls —
|
|
165
|
+
not even programmatically (overflow: clip pins scrollTop to 0), so a
|
|
166
|
+
transient gap while the host syncs the iframe's height to the page
|
|
167
|
+
can never flash a scrollbar or shift a measured rect. */
|
|
168
|
+
overflow: clip;
|
|
169
|
+
}
|
|
170
|
+
/* Document defaults, NOT document truth: the theme's own body mapping is
|
|
171
|
+
what the published page renders with, so it must win here too — fonts and
|
|
172
|
+
wraps in the frame diverge from capture otherwise. The layer (pre-declared
|
|
173
|
+
by the srcdoc, see FRAME_DEFAULTS_LAYER) is what makes these lose to any
|
|
174
|
+
template declaration. */
|
|
175
|
+
@layer ${Qf} {
|
|
176
|
+
html, body {
|
|
177
|
+
background: transparent;
|
|
178
|
+
}
|
|
179
|
+
body {
|
|
180
|
+
color: #14180F;
|
|
181
|
+
font-family: ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
|
|
182
|
+
}
|
|
183
|
+
}
|
|
184
|
+
${s}
|
|
185
|
+
${l?$_(n.sectionInstanceId):Y_(n.sectionInstanceId)}
|
|
186
|
+
|
|
187
|
+
/* Slot wrapper -- structure only. No outline here; the host's overlay
|
|
188
|
+
ring handles slot hover + selection too. */
|
|
189
|
+
[${n.slotId}] {
|
|
190
|
+
cursor: pointer;
|
|
191
|
+
}
|
|
192
|
+
|
|
193
|
+
/* Slot-group container -- the gaps between grouped members (dividers,
|
|
194
|
+
padding) carry no slot id, so give the group container itself
|
|
195
|
+
the pointer cursor: the whole group reads as one clickable unit, and
|
|
196
|
+
the overlay ring outlines this container. */
|
|
197
|
+
[${n.slotGroup}],
|
|
198
|
+
[${n.slotItem}] {
|
|
199
|
+
cursor: pointer;
|
|
200
|
+
}
|
|
201
|
+
|
|
202
|
+
/* Deliberately NO position default on the marker elements: published pages
|
|
203
|
+
and captured artifacts set no position on them, so an unpositioned slot
|
|
204
|
+
must compute static here too — a relative default (even layered, losing
|
|
205
|
+
to author utilities) re-anchored an author's absolutely positioned
|
|
206
|
+
descendant to the slot on this surface while the published page anchored
|
|
207
|
+
it farther up, and could shift stacking the same way. Nothing in the
|
|
208
|
+
chrome needs it: rings measure client rects from the host overlay, and
|
|
209
|
+
everything that mounts absolute chrome inside the frame (island shields,
|
|
210
|
+
the crop spinner) checks the surface's computed position and forces an
|
|
211
|
+
inline relative itself. */
|
|
212
|
+
|
|
213
|
+
@media (prefers-reduced-motion: reduce) {
|
|
214
|
+
[${n.sectionInstanceId}] {
|
|
215
|
+
transition: none !important;
|
|
216
|
+
}
|
|
217
|
+
}
|
|
218
|
+
|
|
219
|
+
/* Render-error placeholder ------------------------------------- */
|
|
220
|
+
.we-render-error {
|
|
221
|
+
margin: 8px 0;
|
|
222
|
+
padding: 24px 16px;
|
|
223
|
+
border-radius: 6px;
|
|
224
|
+
border: 1px dashed #ebebe6;
|
|
225
|
+
background: #ffffff;
|
|
226
|
+
color: #8a877e;
|
|
227
|
+
font-size: 12.5px;
|
|
228
|
+
}
|
|
229
|
+
.we-render-error__title {
|
|
230
|
+
margin: 0;
|
|
231
|
+
color: #4a4842;
|
|
232
|
+
font-weight: 500;
|
|
233
|
+
}
|
|
234
|
+
.we-render-error__detail {
|
|
235
|
+
margin: 4px 0 0 0;
|
|
236
|
+
color: #b9b6ab;
|
|
237
|
+
font-size: 11.5px;
|
|
238
|
+
}
|
|
239
|
+
|
|
240
|
+
/* Island interaction shield: a transparent click layer derived from a live
|
|
241
|
+
island's own markup (island-shields.ts) — a base shield per island root box,
|
|
242
|
+
an item shield per rendered collection-item copy. Present until the shield's
|
|
243
|
+
owner carries the live-owner stamp; a click on a shield falls through to the
|
|
244
|
+
editor's resolver, which selects the nearest marked ancestor. Base z-index 1
|
|
245
|
+
sits on the island content's plane but below floating content that must stay
|
|
246
|
+
clickable at z-index 2 (e.g. the neighborhood card over the map canvas). Item
|
|
247
|
+
shields ride one plane above the base, so a click over an item copy hits the
|
|
248
|
+
ITEM's shield and one click selects that item. */
|
|
249
|
+
.${zg} {
|
|
250
|
+
position: absolute;
|
|
251
|
+
inset: 0;
|
|
252
|
+
z-index: 1;
|
|
253
|
+
cursor: pointer;
|
|
254
|
+
background: transparent;
|
|
255
|
+
}
|
|
256
|
+
.${Q_} { z-index: 2; }
|
|
257
|
+
[${Ki}] .${zg} { display: none; }
|
|
258
|
+
|
|
259
|
+
/* Image slider: until the slider's \`images\` slot is the live selection, its
|
|
260
|
+
z-index:2 nav arrows would paint above the z-index:1 shield and stay
|
|
261
|
+
clickable, escaping the select-first gate. Disable them so the shield
|
|
262
|
+
catches the first click; restored once .tr-slider carries data-we-live.
|
|
263
|
+
Editor-only — deliberately not in published tokens.css. */
|
|
264
|
+
.tr-slider:not([${Ki}]) .tr-slider__nav { pointer-events: none; }
|
|
265
|
+
`}function X_(n,l){const o=n/Yl,u=Number.POSITIVE_INFINITY;return Math.max(.05,Math.min(.9,.72*o,.1926*o+.54,u))}const Z_=420,Ug=.92;function P_(n,l,s){if(!s)return n;const o=Math.max(n,Z_/s.width),u=Math.min(.9,n*Yl/s.width,Ug*l.availableWidthPx/s.width,Ug*l.availableHeightPx/s.height);return Math.max(.05,Math.min(o,u))}function Lg(n,l,s){var u;let o=n.closest(`[${l}]`);for(;o&&!ga(o,s);)o=((u=o.parentElement)==null?void 0:u.closest(`[${l}]`))??null;return o}function J_(n,l,s){for(const o of Array.from(n.querySelectorAll(`[${s.markers.slotId}]`))){if(o.closest(`[${s.markers.slotGroup}]`)!==n)continue;const u=o.getAttribute(s.markers.slotId);if(u&&s.isSlotEditable(l,u))return u}return null}function W_(n,l,s){if(!n)return null;const o=n.closest(`[${s.markers.sectionInstanceId}]`),u=o==null?void 0:o.getAttribute(s.markers.sectionInstanceId);if(!o||!u)return null;const d=l.find(j=>j.instance_id===u),h={selection:{kind:"section",instance_id:u},element:o};if(!d)return h;const p=Lg(n,s.markers.slotGroup,s.markers);if(p&&o.contains(p)){const j=J_(p,u,s);return j?{selection:{kind:"slot",instance_id:u,slot_id:j},element:p}:h}const y=Lg(n,s.markers.slotId,s.markers),g=y==null?void 0:y.getAttribute(s.markers.slotId);if(!y||!g||!s.isSlotEditable(u,g))return h;const x=Tg(n,s.markers.slotItem,y,s.markers),v=x?Number(x.getAttribute(s.markers.slotItem)):NaN,E=Number.isInteger(v)?v:void 0,M=Tg(n,s.markers.slotField,y,s.markers),N=(M==null?void 0:M.getAttribute(s.markers.slotField))??null,A=N&&s.isSlotEditable(u,g,N)?N:null;return{selection:{kind:"slot",instance_id:u,slot_id:g,...E!==void 0?{item_index:E}:{},...A?{field_name:A}:{}},element:(A?M:null)??x??y}}function Wd(n){return n.section_display_name?n.section_display_name:n.section_key.split("-").map(l=>l&&l[0].toUpperCase()+l.slice(1)).join(" ")}function ew(n){if(!n)return"null";let l=2166136261;for(let s=0;s<n.length;s++)l^=n.charCodeAt(s),l=Math.imul(l,16777619);return(l>>>0).toString(16)}function C0(n,l){var d;const s=l.createElement("div");s.className="we-render-error";const o=l.createElement("p");o.className="we-render-error__title",o.textContent="Couldn’t render this section.";const u=l.createElement("p");return u.className="we-render-error__detail",u.textContent=((d=n.render_error)==null?void 0:d.message)??"Unknown render error.",s.appendChild(o),s.appendChild(u),s}function tw(n,l,s,o){const u=l.createElement("div");u.setAttribute(s.sectionInstanceId,n.instance_id),u.setAttribute("data-section-label",Wd(n)),u.dataset.svId=n.section_version_id,u.dataset.htmlHash=ew(n.html);const d=l.createElement("div");return d.className="we-section-body",n.render_error||n.html===null?d.appendChild(C0(n,l)):d.innerHTML=o(n.html),u.appendChild(d),u}function Bg(n){return JSON.stringify(n).replace(/</g,"\\u003c").replace(/>/g,"\\u003e").replace(/&/g,"\\u0026")}const nw="concrete-frame";function Ud(n){return n.replace(/&/g,"&").replace(/</g,"<").replace(/>/g,">").replace(/"/g,""").replace(/'/g,"'")}function aw(n,l){const s=Object.entries(l).map(([o,u])=>`${o}:${u}`).join(";");return{class:nw,dataFormat:n,style:s}}function lw(n){if(!n)return"";const l=aw(n.formatId,n.tokens);return` class="${Ud(l.class)}" data-format="${Ud(l.dataFormat)}" style="${Ud(l.style)}"`}function iw(n){if(Object.keys(n.islandMap).length===0)return"";if(Object.keys(n.importMap).length===0&&!n.hostResolvesOwnImports)return console.error("canvas: this template version has islands but no import map, so nothing can resolve their React — sections render statically. Republish the template to emit the vendor."),"";const l=n.hostScriptSrc?`
|
|
266
|
+
<script id="tr-island-host" type="module" src="${n.hostScriptSrc}"><\/script>`:"";return`${Object.keys(n.importMap).length===0?"":`
|
|
267
|
+
<script type="importmap">${Bg({imports:n.importMap})}<\/script>`}
|
|
268
|
+
<script>window.__TR_ISLAND_MAP=${Bg(n.islandMap)};<\/script>
|
|
269
|
+
<!-- id is the contract the host's readiness gate keys off — it waits on THIS
|
|
270
|
+
element's load event, not a timeout, so a slow cold first load still
|
|
271
|
+
activates without a refresh. -->${l}`}function sw(n,l){return n.replaceAll("/section-assets/",`${l}runtime/section-asset/`)}function ow(n,l,s){const o=n.stylesheets.map(u=>`<link rel="stylesheet" href="${u}">`).join("");return`<!doctype html>
|
|
272
|
+
<html>
|
|
273
|
+
<head>
|
|
274
|
+
<meta charset="utf-8">
|
|
275
|
+
<base href="${n.basePath}">
|
|
276
|
+
<!-- Cascade-layer order is fixed by FIRST declaration, document-wide. The
|
|
277
|
+
kernel's document defaults must lose to everything a template declares,
|
|
278
|
+
so their layer is pre-declared here, before any template stylesheet,
|
|
279
|
+
pinning it below every layer those go on to declare. -->
|
|
280
|
+
<style>@layer ${Qf};</style>
|
|
281
|
+
${o}${iw(n)}
|
|
282
|
+
<style>${F_(l,s)}</style>
|
|
283
|
+
</head>
|
|
284
|
+
<body>
|
|
285
|
+
<div id="we-page"${lw(s)}></div>
|
|
286
|
+
</body>
|
|
287
|
+
</html>`}function rw(n){return!!(n!=null&&n.getElementById("we-page"))}function Hg(n){const l=s=>sw(s,n.assets.basePath);return{srcdoc:()=>ow(n.assets,n.markers,n.pageBox),buildSectionWrapper:(s,o)=>tw(s,o,n.markers,l),buildErrorPlaceholder:C0,resolveTarget:(s,o)=>W_(s,o,n),localizeSectionAssets:l,resolveSelectionEl:(s,o)=>I_(s,o,n.markers),resolveSelectionEls:(s,o)=>E0(s,o,n.markers),resolveVisibleSlotEls:(s,o)=>k0(s,o,n.markers),resolveItemEls:(s,o)=>G_(s,o,n.markers),setLiveOwner:(s,o)=>V_(s,o,n.markers)}}const A0=(n,l)=>`<svg class="${n}" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="1.8" stroke-linecap="round" stroke-linejoin="round" aria-hidden="true">${l}</svg>`;function cw(n){return A0(n,'<path d="M10.733 5.076a10.744 10.744 0 0 1 11.205 6.575 1 1 0 0 1 0 .696 10.747 10.747 0 0 1-1.444 2.49"/><path d="M14.084 14.158a3 3 0 0 1-4.242-4.242"/><path d="M17.479 17.499a10.75 10.75 0 0 1-15.417-5.151 1 1 0 0 1 0-.696 10.75 10.75 0 0 1 4.446-5.143"/><path d="m2 2 20 20"/>')}function uw(n){return A0(n,'<path d="M2.062 12.348a1 1 0 0 1 0-.696 10.75 10.75 0 0 1 19.876 0 1 1 0 0 1 0 .696 10.75 10.75 0 0 1-19.876 0"/><circle cx="12" cy="12" r="3"/>')}const dw=42,N0=16;function fw(n,l){const s=[];for(const u of n)for(s.push({sum:u.y,n:1,items:[u]});s.length>1;){const d=s[s.length-1],h=s[s.length-2];if(!d||!h)break;const p=d.sum/d.n-(d.n-1)/2*l,y=h.sum/h.n+(h.n-1)/2*l;if(p-y<l)s.splice(s.length-2,2,{sum:h.sum+d.sum,n:h.n+d.n,items:h.items.concat(d.items)});else break}const o={};for(const u of s){const d=u.sum/u.n-(u.n-1)/2*l;u.items.forEach((h,p)=>{o[h.idx]=d+p*l})}return o}const hw=cw("we-htab-eye-off"),pw=uw("we-htab-eye-on"),ef=new WeakMap;function mw(n,l,s,o){const u=n.createElement("button");u.type="button",u.className="we-htab",u.dataset.hiddenTab=l,u.title=`Show ${s}`,u.setAttribute("aria-label",`Show ${s}`),u.innerHTML=`<span class="we-htab-eye">${hw}${pw}</span><span class="we-htab-name"></span>`;const d=u.querySelector(".we-htab-name");return d&&(d.textContent=s),ef.set(u,o),u.addEventListener("click",h=>{var p;h.stopPropagation(),(p=ef.get(u))==null||p()}),u}function yw(n,l,s,o){const u=new Map;n.querySelectorAll(".we-htab").forEach(p=>{const y=p.dataset.hiddenTab;y&&u.set(y,p)});const d=new Set,h=[];for(const p of s){let y=u.get(p.instanceId);if(!y)y=mw(l,p.instanceId,p.label,()=>o(p.instanceId)),n.appendChild(y);else{const g=y.querySelector(".we-htab-name");g&&g.textContent!==p.label&&(g.textContent=p.label),y.title=`Show ${p.label}`,y.setAttribute("aria-label",`Show ${p.label}`),ef.set(y,()=>o(p.instanceId))}d.add(p.instanceId),h.push(y)}return u.forEach((p,y)=>{d.has(y)||p.remove()}),h}function gw(n,l,s){const o=n.map((d,h)=>{const p=l(d.dataset.hiddenTab??""),y=p?p.getBoundingClientRect().top*s:0;return{idx:h,y}}),u=fw(o,dw);n.forEach((d,h)=>{d.style.top=`${u[h]}px`,d.style.left=`${N0-d.offsetWidth}px`})}const bw=48,vw=30,xw=`
|
|
288
|
+
@property --we-scale {
|
|
289
|
+
syntax: "<number>";
|
|
290
|
+
inherits: true;
|
|
291
|
+
initial-value: 1;
|
|
292
|
+
}
|
|
293
|
+
|
|
294
|
+
/* The scroll container + dotted canvas surface. The host lays this element
|
|
295
|
+
out — position and size are the host's (it must both bound the height and
|
|
296
|
+
be positioned, so the frame wrapper's offset parent is the stage);
|
|
297
|
+
everything inside is kernel-defined. Declaring position here would win
|
|
298
|
+
the cascade over a host's own positioning utility classes (this sheet
|
|
299
|
+
loads after theirs), which is how the app's absolutely-positioned stage
|
|
300
|
+
once silently became in-flow and unscrollable.
|
|
301
|
+
background-attachment: local makes the grid scroll together with
|
|
302
|
+
the page card so the canvas + website read as one scene being panned, not
|
|
303
|
+
a card sliding over a fixed grid. Padding aligns the page card with the
|
|
304
|
+
floating panel: top/bottom/left 20px; the right constant (40px) covers the
|
|
305
|
+
panel's right inset (20px) plus an equal 20px gap. Fallback 436px matches
|
|
306
|
+
the panel's base CSS width.
|
|
307
|
+
The top padding also carries the label lane: a page-title row is drawn
|
|
308
|
+
ABOVE its frame's box, so the topmost frame's row would otherwise sit in
|
|
309
|
+
the 20px margin. --we-frame-label-lane is set by the stage reconciler only
|
|
310
|
+
when some frame is labeled, so a canvas whose pages declare no label keeps
|
|
311
|
+
the original 20px exactly. */
|
|
312
|
+
.we-canvas-stage {
|
|
313
|
+
overflow: auto;
|
|
314
|
+
padding: calc(20px + var(--we-frame-label-lane, 0px))
|
|
315
|
+
calc(var(--we-panel-w, 436px) + 40px) 20px 20px;
|
|
316
|
+
transition: --we-scale 150ms cubic-bezier(0.4, 0, 0.2, 1);
|
|
317
|
+
background-image: radial-gradient(rgba(20, 18, 13, 0.13) 1px, transparent 1.2px);
|
|
318
|
+
background-size: 20px 20px;
|
|
319
|
+
background-position: 10px 10px;
|
|
320
|
+
background-attachment: local;
|
|
321
|
+
scrollbar-width: none;
|
|
322
|
+
-ms-overflow-style: none;
|
|
323
|
+
}
|
|
324
|
+
.we-canvas-stage::-webkit-scrollbar { width: 0; height: 0; display: none; }
|
|
325
|
+
|
|
326
|
+
/* The scaled page card's layout box: exactly the iframe's visual footprint,
|
|
327
|
+
so the stage scrolls and centers the card correctly. Auto inline margins
|
|
328
|
+
rather than flex centering: they collapse to 0 when the card overflows the
|
|
329
|
+
stage, keeping the left edge reachable by scroll at high zoom.
|
|
330
|
+
|
|
331
|
+
isolation:isolate SEALS the canvas's own stacking hierarchy (tab layer,
|
|
332
|
+
page card, chrome overlay) into this element, so those z-indexes are
|
|
333
|
+
ordered only against each other and the whole card paints at the stage's
|
|
334
|
+
position in the HOST's DOM order. Without it the overlay competed
|
|
335
|
+
directly with the host's floating chrome -- a panel, a zoom toolbar, a
|
|
336
|
+
notice banner -- and a hover outline drew straight over the controls.
|
|
337
|
+
Same reasoning as the section wrappers' isolate in the frame document. */
|
|
338
|
+
.we-canvas-frame {
|
|
339
|
+
position: relative;
|
|
340
|
+
width: calc(var(--we-page-w, ${Yl}px) * var(--we-scale, 1));
|
|
341
|
+
height: calc(var(--we-page-h, 0px) * var(--we-scale, 1));
|
|
342
|
+
margin-inline: auto;
|
|
343
|
+
isolation: isolate;
|
|
344
|
+
}
|
|
345
|
+
|
|
346
|
+
/* The multi-frame stack: one frame per row, in the canvas's page order, each
|
|
347
|
+
centered on the same axis a lone page card already used (the auto inline
|
|
348
|
+
margins above), separated by a constant host-px gap plus whatever lane the
|
|
349
|
+
label chips need. Expressed as an adjacent-sibling rule so a single-frame
|
|
350
|
+
canvas matches no selector at all and lays out byte-identically to what it
|
|
351
|
+
did before frames could stack. The gap does NOT ride --we-scale: it is
|
|
352
|
+
chrome between two artifacts, not a part of either, so it stays the same
|
|
353
|
+
distance at any zoom. */
|
|
354
|
+
.we-canvas-frame + .we-canvas-frame {
|
|
355
|
+
margin-top: calc(${bw}px + var(--we-frame-label-lane, 0px));
|
|
356
|
+
}
|
|
357
|
+
|
|
358
|
+
/* Page-title row -- "Front", "Back": which page of the canvas this frame
|
|
359
|
+
is, with the visibility toggle seated directly beside the name it acts
|
|
360
|
+
on (one group, never split across the page's corners). Drawn ABOVE the
|
|
361
|
+
frame's box (bottom: 100%, in the lane the stage padding and the
|
|
362
|
+
inter-frame gap reserve) so it never covers artwork, and sized in
|
|
363
|
+
--we-content like the edge tabs: constant visual size at any zoom,
|
|
364
|
+
because it names the page rather than belonging to it.
|
|
365
|
+
pointer-events:none at the row so the lane's empty run stays stage
|
|
366
|
+
surface (a deselect click must fall through); the toggle re-enables its
|
|
367
|
+
own. */
|
|
368
|
+
.we-frame-titlebar {
|
|
369
|
+
position: absolute;
|
|
370
|
+
bottom: 100%;
|
|
371
|
+
left: 0;
|
|
372
|
+
right: 0;
|
|
373
|
+
margin-bottom: calc(4 * var(--we-content, 1px));
|
|
374
|
+
display: flex;
|
|
375
|
+
align-items: center;
|
|
376
|
+
gap: calc(6 * var(--we-content, 1px));
|
|
377
|
+
pointer-events: none;
|
|
378
|
+
}
|
|
379
|
+
/* Quiet by design: the row annotates the artwork below it, so it reads in
|
|
380
|
+
a light gray that cedes attention to the page — the ink weights are
|
|
381
|
+
reserved for the states that earn them (hover, the engaged toggle). */
|
|
382
|
+
.we-canvas-frame-label {
|
|
383
|
+
min-width: 0;
|
|
384
|
+
overflow: hidden;
|
|
385
|
+
text-overflow: ellipsis;
|
|
386
|
+
white-space: nowrap;
|
|
387
|
+
color: #a09d94;
|
|
388
|
+
font-size: calc(13 * var(--we-content, 1px));
|
|
389
|
+
font-weight: 500;
|
|
390
|
+
letter-spacing: -0.01em;
|
|
391
|
+
line-height: 1;
|
|
392
|
+
}
|
|
393
|
+
|
|
394
|
+
/* Page-visibility toggle -- the eye beside the page title, resting in the
|
|
395
|
+
title's own gray so the row reads as one quiet group. Rendered only
|
|
396
|
+
for pages the composition marks optional (frame-visibility.ts). */
|
|
397
|
+
.we-frame-toggle {
|
|
398
|
+
flex: 0 0 auto;
|
|
399
|
+
display: grid;
|
|
400
|
+
place-items: center;
|
|
401
|
+
width: calc(24 * var(--we-content, 1px));
|
|
402
|
+
height: calc(22 * var(--we-content, 1px));
|
|
403
|
+
padding: 0;
|
|
404
|
+
border: 0;
|
|
405
|
+
border-radius: calc(6 * var(--we-content, 1px));
|
|
406
|
+
background: transparent;
|
|
407
|
+
color: #a09d94;
|
|
408
|
+
cursor: pointer;
|
|
409
|
+
pointer-events: auto;
|
|
410
|
+
transition: background-color 0.15s, color 0.15s;
|
|
411
|
+
}
|
|
412
|
+
.we-frame-toggle svg {
|
|
413
|
+
width: calc(14 * var(--we-content, 1px));
|
|
414
|
+
height: calc(14 * var(--we-content, 1px));
|
|
415
|
+
}
|
|
416
|
+
.we-frame-toggle:hover {
|
|
417
|
+
background: rgba(20, 18, 13, 0.06);
|
|
418
|
+
color: #14180F;
|
|
419
|
+
}
|
|
420
|
+
.we-frame-toggle:focus-visible {
|
|
421
|
+
outline: none;
|
|
422
|
+
background: rgba(20, 18, 13, 0.06);
|
|
423
|
+
color: #14180F;
|
|
424
|
+
box-shadow: 0 0 0 2px rgba(15, 42, 34, 0.5);
|
|
425
|
+
}
|
|
426
|
+
/* Hidden state reads as an engaged control (the section eye's hidden
|
|
427
|
+
treatment): filled box, full-ink glyph. */
|
|
428
|
+
.we-frame-toggle[data-page-visibility="hidden"] {
|
|
429
|
+
background: rgba(20, 18, 13, 0.06);
|
|
430
|
+
color: #14180F;
|
|
431
|
+
box-shadow: inset 0 0 0 1px #ebebe6;
|
|
432
|
+
}
|
|
433
|
+
/* Hidden page -- tinted to a clear deactivated state, in place and at full
|
|
434
|
+
footprint (a page never collapses the way a hidden section does), still
|
|
435
|
+
fully interactive: the tint says "excluded from the artifact", not
|
|
436
|
+
"locked". The title strikes through and lightens, the same reading as a
|
|
437
|
+
fully-hidden canvas's bar tab. The stamp is written by
|
|
438
|
+
frame-visibility.ts. */
|
|
439
|
+
.we-canvas-frame[data-page-hidden="true"] > iframe {
|
|
440
|
+
filter: grayscale(1) opacity(0.55);
|
|
441
|
+
}
|
|
442
|
+
.we-canvas-frame[data-page-hidden="true"] > .we-frame-titlebar > .we-canvas-frame-label {
|
|
443
|
+
text-decoration: line-through;
|
|
444
|
+
color: #b6b3aa;
|
|
445
|
+
}
|
|
446
|
+
|
|
447
|
+
/* The frame document: unscaled ${Yl}px layout, scaled here as an
|
|
448
|
+
element. The border-radius matches #we-page inside, so the card shadow
|
|
449
|
+
follows the content's silhouette; both radius and shadow ride the
|
|
450
|
+
transform, exactly as they rode the old in-document scaling. z-index 2
|
|
451
|
+
stacks the card above the edge tabs (z-index 1) so the shadow falls over a
|
|
452
|
+
tab's tucked-under inner edge, nestling it against the page. */
|
|
453
|
+
.we-canvas-frame > iframe {
|
|
454
|
+
display: block;
|
|
455
|
+
border: 0;
|
|
456
|
+
background: transparent;
|
|
457
|
+
width: var(--we-page-w, ${Yl}px);
|
|
458
|
+
height: var(--we-page-h, 0px);
|
|
459
|
+
border-radius: var(--we-page-radius, ${M0}px);
|
|
460
|
+
box-shadow:
|
|
461
|
+
0 1px 0 rgba(20,18,13,0.06),
|
|
462
|
+
0 2px 6px -2px rgba(20,18,13,0.10),
|
|
463
|
+
0 12px 28px -8px rgba(20,18,13,0.18),
|
|
464
|
+
0 32px 64px -20px rgba(20,18,13,0.28);
|
|
465
|
+
transform: scale(var(--we-scale, 1));
|
|
466
|
+
transform-origin: 0 0;
|
|
467
|
+
position: relative;
|
|
468
|
+
z-index: 2;
|
|
469
|
+
transition: filter 0.2s ease;
|
|
470
|
+
}
|
|
471
|
+
|
|
472
|
+
/* Chrome overlay -- sized to the frame wrapper, i.e. the scaled page card,
|
|
473
|
+
so x=0/y=0 is the page's top-left corner. overflow stays visible: a ring
|
|
474
|
+
at the page boundary or a label straddling the top border extends past
|
|
475
|
+
the card and must not clip. pointer-events:none so clicks pass through to
|
|
476
|
+
the iframe underneath.
|
|
477
|
+
|
|
478
|
+
Positioning contract: chrome.ts measures a target in the FRAME document
|
|
479
|
+
(layout truth — that document never scales or scrolls) and writes the
|
|
480
|
+
rect as custom properties on the ring/label; the formulas here scale it
|
|
481
|
+
into host space. Keeping the formula in the stylesheet and the data in
|
|
482
|
+
properties is what lets a transitioned --we-scale move every ring in
|
|
483
|
+
lockstep with the iframe's own animated transform. The ring's offset
|
|
484
|
+
(its inflation past the target's edge) stays OUTSIDE the multiplication:
|
|
485
|
+
constant host px at any zoom.
|
|
486
|
+
|
|
487
|
+
z-index 3 -- one step above the page card, and nothing more: the frame's
|
|
488
|
+
isolate is what keeps the chrome under the host's own UI, so a large
|
|
489
|
+
value here would buy nothing and read as an escape hatch.
|
|
490
|
+
|
|
491
|
+
A CLASS, not an id: every frame on the stage carries one of these, and the
|
|
492
|
+
chrome functions are handed the overlay rather than resolving it by
|
|
493
|
+
document-global id. */
|
|
494
|
+
.we-chrome-overlay {
|
|
495
|
+
position: absolute;
|
|
496
|
+
inset: 0;
|
|
497
|
+
pointer-events: none;
|
|
498
|
+
z-index: 3;
|
|
499
|
+
}
|
|
500
|
+
.we-chrome-ring {
|
|
501
|
+
position: absolute;
|
|
502
|
+
pointer-events: none;
|
|
503
|
+
border: 2px solid transparent;
|
|
504
|
+
border-radius: 6px;
|
|
505
|
+
opacity: 0;
|
|
506
|
+
box-sizing: border-box;
|
|
507
|
+
top: calc(var(--we-r-top, 0px) * var(--we-scale, 1) - var(--we-r-off, 0px));
|
|
508
|
+
left: calc(var(--we-r-left, 0px) * var(--we-scale, 1) - var(--we-r-off, 0px));
|
|
509
|
+
width: calc(var(--we-r-w, 0px) * var(--we-scale, 1) + 2 * var(--we-r-off, 0px));
|
|
510
|
+
height: calc(var(--we-r-h, 0px) * var(--we-scale, 1) + 2 * var(--we-r-off, 0px));
|
|
511
|
+
}
|
|
512
|
+
/* Hover ring -- instant on cursor arrival, fades out on leave.
|
|
513
|
+
Position updates instantly (no top/left transition) so dragging
|
|
514
|
+
across elements never flickers. Ink stroke + white drop-shadow
|
|
515
|
+
halo keeps the ring readable on both light sections and dark ones. */
|
|
516
|
+
.we-chrome-ring--hover {
|
|
517
|
+
border-color: rgba(15,42,34,0.85);
|
|
518
|
+
filter: drop-shadow(0 0 1px rgba(255,255,255,0.95));
|
|
519
|
+
transition: opacity 70ms ease-in;
|
|
520
|
+
}
|
|
521
|
+
.we-chrome-ring--hover[data-active="true"] {
|
|
522
|
+
opacity: 1;
|
|
523
|
+
transition: opacity 100ms cubic-bezier(0.16, 1, 0.3, 1);
|
|
524
|
+
}
|
|
525
|
+
/* Selection ring -- appears instantly (continuous with hover),
|
|
526
|
+
then morphs ink → gold. No position transition so resize
|
|
527
|
+
tracking stays tight. Same ink + white halo as hover. */
|
|
528
|
+
.we-chrome-ring--selection {
|
|
529
|
+
border-color: rgba(15,42,34,0.85);
|
|
530
|
+
filter: drop-shadow(0 0 1px rgba(255,255,255,0.95));
|
|
531
|
+
transform: scale(1);
|
|
532
|
+
box-shadow: none;
|
|
533
|
+
transition:
|
|
534
|
+
opacity 50ms ease-in,
|
|
535
|
+
border-color 160ms cubic-bezier(0.2, 0, 0, 1),
|
|
536
|
+
box-shadow 160ms cubic-bezier(0.2, 0, 0, 1);
|
|
537
|
+
}
|
|
538
|
+
.we-chrome-ring--selection[data-active="true"] {
|
|
539
|
+
opacity: 1;
|
|
540
|
+
/* Instant show on select; only border + glow animate */
|
|
541
|
+
transition:
|
|
542
|
+
opacity 0ms,
|
|
543
|
+
border-color 180ms cubic-bezier(0.2, 0, 0, 1),
|
|
544
|
+
box-shadow 180ms cubic-bezier(0.2, 0, 0, 1);
|
|
545
|
+
}
|
|
546
|
+
.we-chrome-ring--selection[data-kind="section"],
|
|
547
|
+
.we-chrome-ring--selection[data-kind="slot"] {
|
|
548
|
+
border-color: #E5B832;
|
|
549
|
+
filter: drop-shadow(0 0 1px rgba(255,255,255,0.95));
|
|
550
|
+
box-shadow: 0 0 0 1px rgba(229,184,50,0.25), 0 8px 24px -10px rgba(229,184,50,0.35);
|
|
551
|
+
}
|
|
552
|
+
|
|
553
|
+
/* Geometry guides -- the trim line and the bleed region for a rendered-class
|
|
554
|
+
page. The overlay is the page (bleed) box exactly, so insetting all four
|
|
555
|
+
sides by the declared bleed gives the trim box with no arithmetic: the
|
|
556
|
+
border draws the trim line and the shadow's spread fills the band between
|
|
557
|
+
trim and page edge. Data/formula split as for the rings — guides.ts writes
|
|
558
|
+
--we-g-bleed in frame space, the multiplication happens here, so a
|
|
559
|
+
transitioned zoom moves the guides with the card. The 1px line itself
|
|
560
|
+
stays OUTSIDE the multiplication: constant host px at any zoom, like the
|
|
561
|
+
ring's offset.
|
|
562
|
+
|
|
563
|
+
Magenta rather than the chrome's ink/gold: a guide is an instrument about
|
|
564
|
+
the artifact, never a selection, and the print convention reads instantly.
|
|
565
|
+
The inset white hairline keeps the line legible over dark artwork, the
|
|
566
|
+
role the rings' drop-shadow halo plays for them. First child of the
|
|
567
|
+
overlay, so rings and the title pill paint above it. */
|
|
568
|
+
.we-guide {
|
|
569
|
+
position: absolute;
|
|
570
|
+
box-sizing: border-box;
|
|
571
|
+
pointer-events: none;
|
|
572
|
+
opacity: 0;
|
|
573
|
+
top: calc(var(--we-g-bleed, 0px) * var(--we-scale, 1));
|
|
574
|
+
right: calc(var(--we-g-bleed, 0px) * var(--we-scale, 1));
|
|
575
|
+
bottom: calc(var(--we-g-bleed, 0px) * var(--we-scale, 1));
|
|
576
|
+
left: calc(var(--we-g-bleed, 0px) * var(--we-scale, 1));
|
|
577
|
+
border: 1px solid rgba(214,32,140,0.9);
|
|
578
|
+
box-shadow:
|
|
579
|
+
inset 0 0 0 1px rgba(255,255,255,0.55),
|
|
580
|
+
0 0 0 calc(var(--we-g-bleed, 0px) * var(--we-scale, 1)) rgba(214,32,140,0.16);
|
|
581
|
+
transition: opacity 90ms ease-in;
|
|
582
|
+
}
|
|
583
|
+
.we-guide[data-active="true"] { opacity: 1; }
|
|
584
|
+
|
|
585
|
+
/* Section title pill -- straddles the selection's top border; geometry set
|
|
586
|
+
by chrome.ts as custom properties, same contract as the rings. The left
|
|
587
|
+
indent is constant host px. Sections only; slots get the outline ring but
|
|
588
|
+
no on-canvas label. */
|
|
589
|
+
.we-chrome-label {
|
|
590
|
+
position: absolute;
|
|
591
|
+
top: calc(var(--we-l-top, 0px) * var(--we-scale, 1));
|
|
592
|
+
left: calc(var(--we-l-left, 0px) * var(--we-scale, 1) + var(--we-l-indent, 0px));
|
|
593
|
+
pointer-events: none;
|
|
594
|
+
z-index: 1;
|
|
595
|
+
background: rgba(229,184,50,0.95);
|
|
596
|
+
color: #282c32;
|
|
597
|
+
padding: 3px 8px;
|
|
598
|
+
border-radius: 4px;
|
|
599
|
+
font-size: 10.5px;
|
|
600
|
+
font-weight: 600;
|
|
601
|
+
line-height: 1;
|
|
602
|
+
white-space: nowrap;
|
|
603
|
+
opacity: 0;
|
|
604
|
+
transform: translateY(calc(-50% - 4px)) scale(0.96);
|
|
605
|
+
transition:
|
|
606
|
+
opacity 60ms ease-in,
|
|
607
|
+
transform 60ms ease-in;
|
|
608
|
+
}
|
|
609
|
+
.we-chrome-label[data-active="true"] {
|
|
610
|
+
opacity: 1;
|
|
611
|
+
transform: translateY(-50%) scale(1);
|
|
612
|
+
transition:
|
|
613
|
+
opacity 130ms cubic-bezier(0.16, 1, 0.3, 1) 50ms,
|
|
614
|
+
transform 130ms cubic-bezier(0.16, 1, 0.3, 1) 50ms;
|
|
615
|
+
}
|
|
616
|
+
|
|
617
|
+
/* Hidden-section edge tabs -------------------------------------
|
|
618
|
+
One dim chip-tab per hidden section, pinned to the page card's left edge
|
|
619
|
+
at the collapsed wrapper's reflow seam. Built + positioned by the host
|
|
620
|
+
orchestrator; de-collided via placeTabs. Constant visual size at any zoom
|
|
621
|
+
— the layer sits outside the scaled iframe. --we-content is the host's
|
|
622
|
+
interior scaling unit (its large-screen chrome scale); a host without one
|
|
623
|
+
leaves the 1px fallback in force. A class for the same reason the overlay
|
|
624
|
+
is one: one tab layer per frame, addressed through that frame's handle. */
|
|
625
|
+
.we-htabs {
|
|
626
|
+
position: absolute;
|
|
627
|
+
inset: 0;
|
|
628
|
+
pointer-events: none;
|
|
629
|
+
z-index: 1;
|
|
630
|
+
}
|
|
631
|
+
.we-htab {
|
|
632
|
+
position: absolute;
|
|
633
|
+
transform: translateY(-50%);
|
|
634
|
+
display: flex;
|
|
635
|
+
align-items: center;
|
|
636
|
+
gap: calc(9 * var(--we-content, 1px));
|
|
637
|
+
height: calc(34 * var(--we-content, 1px));
|
|
638
|
+
padding: 0 calc(${12+N0} * var(--we-content, 1px)) 0 calc(13 * var(--we-content, 1px));
|
|
639
|
+
background: #ffffff;
|
|
640
|
+
border: 1px solid #ebebe6;
|
|
641
|
+
border-radius: calc(9 * var(--we-content, 1px)) 0 0 calc(9 * var(--we-content, 1px));
|
|
642
|
+
box-shadow: 0 10px 24px -12px rgba(20,18,13,0.34);
|
|
643
|
+
color: #4a4842;
|
|
644
|
+
font: inherit;
|
|
645
|
+
cursor: pointer;
|
|
646
|
+
opacity: 1;
|
|
647
|
+
pointer-events: auto;
|
|
648
|
+
transition: transform 0.2s cubic-bezier(0.2,0.7,0.3,1),
|
|
649
|
+
border-color 0.18s, box-shadow 0.18s;
|
|
650
|
+
}
|
|
651
|
+
.we-htab-eye {
|
|
652
|
+
display: grid;
|
|
653
|
+
place-items: center;
|
|
654
|
+
flex: 0 0 auto;
|
|
655
|
+
color: #8a877e;
|
|
656
|
+
transition: color 0.18s;
|
|
657
|
+
}
|
|
658
|
+
.we-htab-eye svg { width: calc(14 * var(--we-content, 1px)); height: calc(14 * var(--we-content, 1px)); }
|
|
659
|
+
.we-htab-name {
|
|
660
|
+
font-size: calc(13 * var(--we-content, 1px));
|
|
661
|
+
font-weight: 600;
|
|
662
|
+
letter-spacing: -0.01em;
|
|
663
|
+
color: #14180F;
|
|
664
|
+
white-space: nowrap;
|
|
665
|
+
}
|
|
666
|
+
.we-htab:hover {
|
|
667
|
+
transform: translateY(-50%) scale(1.07);
|
|
668
|
+
border-color: rgba(15,42,34,0.5);
|
|
669
|
+
box-shadow: 0 13px 30px -12px rgba(15,42,34,0.45);
|
|
670
|
+
}
|
|
671
|
+
.we-htab:hover .we-htab-eye { color: #0F2A22; }
|
|
672
|
+
.we-htab:focus-visible {
|
|
673
|
+
outline: none;
|
|
674
|
+
transform: translateY(-50%) scale(1.07);
|
|
675
|
+
border-color: #0F2A22;
|
|
676
|
+
box-shadow: 0 0 0 3px #F3F6EF, 0 13px 30px -12px rgba(15,42,34,0.45);
|
|
677
|
+
}
|
|
678
|
+
/* Hover/focus swaps the eye-off glyph to the eye glyph in place — no width
|
|
679
|
+
change, no sliding label. Only one glyph is in flow at a time, so the eye
|
|
680
|
+
slot's grid keeps the shown glyph centered. */
|
|
681
|
+
.we-htab-eye-on { display: none; }
|
|
682
|
+
.we-htab:hover .we-htab-eye-off,
|
|
683
|
+
.we-htab:focus-visible .we-htab-eye-off { display: none; }
|
|
684
|
+
.we-htab:hover .we-htab-eye-on,
|
|
685
|
+
.we-htab:focus-visible .we-htab-eye-on { display: block; }
|
|
686
|
+
|
|
687
|
+
@media (prefers-reduced-motion: reduce) {
|
|
688
|
+
.we-canvas-stage,
|
|
689
|
+
.we-canvas-frame > iframe,
|
|
690
|
+
.we-chrome-ring,
|
|
691
|
+
.we-chrome-label,
|
|
692
|
+
.we-guide,
|
|
693
|
+
.we-htab,
|
|
694
|
+
.we-frame-toggle {
|
|
695
|
+
transition: none !important;
|
|
696
|
+
}
|
|
697
|
+
}
|
|
698
|
+
`,_w='<div class="we-guide"></div><div class="we-chrome-ring we-chrome-ring--hover"></div><div class="we-chrome-ring we-chrome-ring--selection"></div><div class="we-chrome-label"></div>',tc="we-canvas-frame",qg="we-frame-titlebar",Gg="we-canvas-frame-label",Ig="we-htabs",Qg="we-chrome-overlay";function Ld(n,l,s){const o=n.querySelector(l);if(o)return o;const u=s();return n.appendChild(u),u}function ww(n,l){const s=n.querySelector(`:scope > .${qg}`);if(s)return s;const o=l.createElement("div");return o.className=qg,n.insertBefore(o,n.firstChild),o}function Sw(n){for(let l=n.nextElementSibling;l;l=l.nextElementSibling)if(l.classList.contains(tc))return l;return null}function kw(n,l){const s=n.ownerDocument,o=ww(n,s),u=l.label??"",d=o.querySelector(`:scope > .${Gg}`);if(u==="")d==null||d.remove();else{const x=d??o.insertBefore(s.createElement("div"),o.firstChild);x.className=Gg,x.textContent!==u&&(x.textContent=u)}const h=Ld(n,":scope > iframe",()=>s.createElement("iframe"));l.title!==void 0&&h.title!==l.title&&(h.title=l.title),l.sandbox!==void 0&&h.getAttribute("sandbox")!==l.sandbox&&h.setAttribute("sandbox",l.sandbox),h.getAttribute("srcdoc")!==l.srcdoc&&h.setAttribute("srcdoc",l.srcdoc);const p=Ld(n,`:scope > .${Ig}`,()=>{const x=s.createElement("div");return x.className=Ig,x}),y=Ld(n,`:scope > .${Qg}`,()=>{const x=s.createElement("div");return x.className=Qg,x.setAttribute("aria-hidden","true"),x});y.childElementCount===0&&(y.innerHTML=_w);const g=l.pageBox;return g?(n.style.setProperty("--we-page-w",`${g.width}px`),n.style.setProperty("--we-page-h",`${g.height}px`),n.style.setProperty("--we-page-radius","0px")):(n.style.removeProperty("--we-page-w"),n.style.removeProperty("--we-page-radius")),{iframe:h,overlay:y,tabLayer:p}}function Ew(n,l,s){const{iframe:o}=s;return{key:l,wrapper:n,iframe:o,overlay:s.overlay,tabLayer:s.tabLayer,get doc(){return o.contentDocument},setPageHeight(u){n.style.setProperty("--we-page-h",`${u}px`)}}}function jw(n,l){const s=n.ownerDocument,o=new Map;for(const y of Array.from(n.querySelectorAll(`:scope > .${tc}`))){const g=y.dataset.frameKey;g!==void 0&&o.set(g,y)}const u=[],d=[],h=new Set;for(const y of l){let g=o.get(y.key);g||(g=s.createElement("div"),g.className=tc,g.dataset.frameKey=y.key);const x=kw(g,y);u.push(g),h.add(y.key),d.push(Ew(g,y.key,x))}let p=null;for(let y=u.length-1;y>=0;y--){const g=u[y];g&&((g.parentNode!==n||Sw(g)!==p)&&n.insertBefore(g,p),p=g)}return o.forEach((y,g)=>{h.has(g)||y.remove()}),l.some(y=>(y.label??"")!=="")?n.style.setProperty("--we-frame-label-lane",`${vw}px`):n.style.removeProperty("--we-frame-label-lane"),d}function Mw(n,l,s){const o=[];for(const u of n){const d=u.doc;if(!d)continue;const h=l.resolveSelectionEls(d,s);h.length>0&&o.push({handle:u,els:h})}return o}function Cw(n,l){const s=n==null?void 0:n.querySelector(":scope > .we-guide");if(s){if(l===null){s.removeAttribute("data-active");return}s.style.setProperty("--we-g-bleed",`${l}px`),s.setAttribute("data-active","true")}}const Aw=24;function Nw(n,l,s,o){if(n.height+2*o<=l)return n.top>=o&&n.bottom<=l-o?null:n.top<o?Math.max(0,s+n.top-o):Math.max(0,s+n.bottom-(l-o));const d=Math.max(0,s+n.top-o);return Math.abs(d-s)<1?null:d}function Tw(n,l,s,o){const u=l+n.top*s-o,d=n.height*s;return{top:u,bottom:u+d,height:d}}const Kg="__trEditorBridge",Ow=1,T0=new WeakMap;function Rw(n){return n?n.kind==="section"?{kind:"section",instanceId:n.instance_id}:{kind:"slot",instanceId:n.instance_id,slotId:n.slot_id,...n.item_index!==void 0?{itemIndex:n.item_index}:{},...n.field_name!==void 0?{fieldName:n.field_name}:{}}:null}function zw(n){const l=n[Kg];if(l)return l;const s=new Set,o={protocol:Ow,selection:null,subscribe(u){return s.add(u),()=>{s.delete(u)}}};return T0.set(o,s),n[Kg]=o,o}function Dw(n,l,s){if(!n||!l)return;const u=zw(n);u.selection=Rw(s);for(const d of[...T0.get(u)??[]])d()}function O0(n){var l,s,o="";if(typeof n=="string"||typeof n=="number")o+=n;else if(typeof n=="object")if(Array.isArray(n)){var u=n.length;for(l=0;l<u;l++)n[l]&&(s=O0(n[l]))&&(o&&(o+=" "),o+=s)}else for(s in n)n[s]&&(o&&(o+=" "),o+=s);return o}function Kf(){for(var n,l,s=0,o="",u=arguments.length;s<u;s++)(n=arguments[s])&&(l=O0(n))&&(o&&(o+=" "),o+=l);return o}const Uw=(n,l)=>{const s=new Array(n.length+l.length);for(let o=0;o<n.length;o++)s[o]=n[o];for(let o=0;o<l.length;o++)s[n.length+o]=l[o];return s},Lw=(n,l)=>({classGroupId:n,validator:l}),R0=(n=new Map,l=null,s)=>({nextPart:n,validators:l,classGroupId:s}),nc="-",Vg=[],Bw="arbitrary..",Hw=n=>{const l=Gw(n),{conflictingClassGroups:s,conflictingClassGroupModifiers:o}=n;return{getClassGroupId:h=>{if(h.startsWith("[")&&h.endsWith("]"))return qw(h);const p=h.split(nc),y=p[0]===""&&p.length>1?1:0;return z0(p,y,l)},getConflictingClassGroupIds:(h,p)=>{if(p){const y=o[h],g=s[h];return y?g?Uw(g,y):y:g||Vg}return s[h]||Vg}}},z0=(n,l,s)=>{if(n.length-l===0)return s.classGroupId;const u=n[l],d=s.nextPart.get(u);if(d){const g=z0(n,l+1,d);if(g)return g}const h=s.validators;if(h===null)return;const p=l===0?n.join(nc):n.slice(l).join(nc),y=h.length;for(let g=0;g<y;g++){const x=h[g];if(x.validator(p))return x.classGroupId}},qw=n=>n.slice(1,-1).indexOf(":")===-1?void 0:(()=>{const l=n.slice(1,-1),s=l.indexOf(":"),o=l.slice(0,s);return o?Bw+o:void 0})(),Gw=n=>{const{theme:l,classGroups:s}=n;return Iw(s,l)},Iw=(n,l)=>{const s=R0();for(const o in n){const u=n[o];Vf(u,s,o,l)}return s},Vf=(n,l,s,o)=>{const u=n.length;for(let d=0;d<u;d++){const h=n[d];Qw(h,l,s,o)}},Qw=(n,l,s,o)=>{if(typeof n=="string"){Kw(n,l,s);return}if(typeof n=="function"){Vw(n,l,s,o);return}Yw(n,l,s,o)},Kw=(n,l,s)=>{const o=n===""?l:D0(l,n);o.classGroupId=s},Vw=(n,l,s,o)=>{if($w(n)){Vf(n(o),l,s,o);return}l.validators===null&&(l.validators=[]),l.validators.push(Lw(s,n))},Yw=(n,l,s,o)=>{const u=Object.entries(n),d=u.length;for(let h=0;h<d;h++){const[p,y]=u[h];Vf(y,D0(l,p),s,o)}},D0=(n,l)=>{let s=n;const o=l.split(nc),u=o.length;for(let d=0;d<u;d++){const h=o[d];let p=s.nextPart.get(h);p||(p=R0(),s.nextPart.set(h,p)),s=p}return s},$w=n=>"isThemeGetter"in n&&n.isThemeGetter===!0,Fw=n=>{if(n<1)return{get:()=>{},set:()=>{}};let l=0,s=Object.create(null),o=Object.create(null);const u=(d,h)=>{s[d]=h,l++,l>n&&(l=0,o=s,s=Object.create(null))};return{get(d){let h=s[d];if(h!==void 0)return h;if((h=o[d])!==void 0)return u(d,h),h},set(d,h){d in s?s[d]=h:u(d,h)}}},tf="!",Yg=":",Xw=[],$g=(n,l,s,o,u)=>({modifiers:n,hasImportantModifier:l,baseClassName:s,maybePostfixModifierPosition:o,isExternal:u}),Zw=n=>{const{prefix:l,experimentalParseClassName:s}=n;let o=u=>{const d=[];let h=0,p=0,y=0,g;const x=u.length;for(let A=0;A<x;A++){const j=u[A];if(h===0&&p===0){if(j===Yg){d.push(u.slice(y,A)),y=A+1;continue}if(j==="/"){g=A;continue}}j==="["?h++:j==="]"?h--:j==="("?p++:j===")"&&p--}const v=d.length===0?u:u.slice(y);let E=v,M=!1;v.endsWith(tf)?(E=v.slice(0,-1),M=!0):v.startsWith(tf)&&(E=v.slice(1),M=!0);const N=g&&g>y?g-y:void 0;return $g(d,M,E,N)};if(l){const u=l+Yg,d=o;o=h=>h.startsWith(u)?d(h.slice(u.length)):$g(Xw,!1,h,void 0,!0)}if(s){const u=o;o=d=>s({className:d,parseClassName:u})}return o},Pw=n=>{const l=new Map;return n.orderSensitiveModifiers.forEach((s,o)=>{l.set(s,1e6+o)}),s=>{const o=[];let u=[];for(let d=0;d<s.length;d++){const h=s[d],p=h[0]==="[",y=l.has(h);p||y?(u.length>0&&(u.sort(),o.push(...u),u=[]),o.push(h)):u.push(h)}return u.length>0&&(u.sort(),o.push(...u)),o}},Jw=n=>({cache:Fw(n.cacheSize),parseClassName:Zw(n),sortModifiers:Pw(n),postfixLookupClassGroupIds:Ww(n),...Hw(n)}),Ww=n=>{const l=Object.create(null),s=n.postfixLookupClassGroups;if(s)for(let o=0;o<s.length;o++)l[s[o]]=!0;return l},eS=/\s+/,tS=(n,l)=>{const{parseClassName:s,getClassGroupId:o,getConflictingClassGroupIds:u,sortModifiers:d,postfixLookupClassGroupIds:h}=l,p=[],y=n.trim().split(eS);let g="";for(let x=y.length-1;x>=0;x-=1){const v=y[x],{isExternal:E,modifiers:M,hasImportantModifier:N,baseClassName:A,maybePostfixModifierPosition:j}=s(v);if(E){g=v+(g.length>0?" "+g:g);continue}let O=!!j,z;if(O){const ae=A.substring(0,j);z=o(ae);const U=z&&h[z]?o(A):void 0;U&&U!==z&&(z=U,O=!1)}else z=o(A);if(!z){if(!O){g=v+(g.length>0?" "+g:g);continue}if(z=o(A),!z){g=v+(g.length>0?" "+g:g);continue}O=!1}const D=M.length===0?"":M.length===1?M[0]:d(M).join(":"),Y=N?D+tf:D,W=Y+z;if(p.indexOf(W)>-1)continue;p.push(W);const ee=u(z,O);for(let ae=0;ae<ee.length;++ae){const U=ee[ae];p.push(Y+U)}g=v+(g.length>0?" "+g:g)}return g},nS=(...n)=>{let l=0,s,o,u="";for(;l<n.length;)(s=n[l++])&&(o=U0(s))&&(u&&(u+=" "),u+=o);return u},U0=n=>{if(typeof n=="string")return n;let l,s="";for(let o=0;o<n.length;o++)n[o]&&(l=U0(n[o]))&&(s&&(s+=" "),s+=l);return s},aS=(n,...l)=>{let s,o,u,d;const h=y=>{const g=l.reduce((x,v)=>v(x),n());return s=Jw(g),o=s.cache.get,u=s.cache.set,d=p,p(y)},p=y=>{const g=o(y);if(g)return g;const x=tS(y,s);return u(y,x),x};return d=h,(...y)=>d(nS(...y))},lS=[],St=n=>{const l=s=>s[n]||lS;return l.isThemeGetter=!0,l},L0=/^\[(?:(\w[\w-]*):)?(.+)\]$/i,B0=/^\((?:(\w[\w-]*):)?(.+)\)$/i,iS=/^\d+(?:\.\d+)?\/\d+(?:\.\d+)?$/,sS=/^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/,oS=/\d+(%|px|r?em|[sdl]?v([hwib]|min|max)|pt|pc|in|cm|mm|cap|ch|ex|r?lh|cq(w|h|i|b|min|max))|\b(calc|min|max|clamp)\(.+\)|^0$/,rS=/^(rgba?|hsla?|hwb|(ok)?(lab|lch)|color-mix)\(.+\)$/,cS=/^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/,uS=/^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/,$a=n=>iS.test(n),Le=n=>!!n&&!Number.isNaN(Number(n)),Ln=n=>!!n&&Number.isInteger(Number(n)),Bd=n=>n.endsWith("%")&&Le(n.slice(0,-1)),ua=n=>sS.test(n),H0=()=>!0,dS=n=>oS.test(n)&&!rS.test(n),Yf=()=>!1,fS=n=>cS.test(n),hS=n=>uS.test(n),pS=n=>!ve(n)&&!xe(n),mS=n=>n.startsWith("@container")&&(n[10]==="/"&&n[11]!==void 0||n[11]==="s"&&n[16]!==void 0&&n.startsWith("-size/",10)||n[11]==="n"&&n[18]!==void 0&&n.startsWith("-normal/",10)),yS=n=>rl(n,I0,Yf),ve=n=>L0.test(n),Ol=n=>rl(n,Q0,dS),Fg=n=>rl(n,kS,Le),gS=n=>rl(n,V0,H0),bS=n=>rl(n,K0,Yf),Xg=n=>rl(n,q0,Yf),vS=n=>rl(n,G0,hS),Kr=n=>rl(n,Y0,fS),xe=n=>B0.test(n),ao=n=>Jl(n,Q0),xS=n=>Jl(n,K0),Zg=n=>Jl(n,q0),_S=n=>Jl(n,I0),wS=n=>Jl(n,G0),Vr=n=>Jl(n,Y0,!0),SS=n=>Jl(n,V0,!0),rl=(n,l,s)=>{const o=L0.exec(n);return o?o[1]?l(o[1]):s(o[2]):!1},Jl=(n,l,s=!1)=>{const o=B0.exec(n);return o?o[1]?l(o[1]):s:!1},q0=n=>n==="position"||n==="percentage",G0=n=>n==="image"||n==="url",I0=n=>n==="length"||n==="size"||n==="bg-size",Q0=n=>n==="length",kS=n=>n==="number",K0=n=>n==="family-name",V0=n=>n==="number"||n==="weight",Y0=n=>n==="shadow",ES=()=>{const n=St("color"),l=St("font"),s=St("text"),o=St("font-weight"),u=St("tracking"),d=St("leading"),h=St("breakpoint"),p=St("container"),y=St("spacing"),g=St("radius"),x=St("shadow"),v=St("inset-shadow"),E=St("text-shadow"),M=St("drop-shadow"),N=St("blur"),A=St("perspective"),j=St("aspect"),O=St("ease"),z=St("animate"),D=()=>["auto","avoid","all","avoid-page","page","left","right","column"],Y=()=>["center","top","bottom","left","right","top-left","left-top","top-right","right-top","bottom-right","right-bottom","bottom-left","left-bottom"],W=()=>[...Y(),xe,ve],ee=()=>["auto","hidden","clip","visible","scroll"],ae=()=>["auto","contain","none"],U=()=>[xe,ve,y],re=()=>[$a,"full","auto",...U()],de=()=>[Ln,"none","subgrid",xe,ve],ce=()=>["auto",{span:["full",Ln,xe,ve]},Ln,xe,ve],ie=()=>[Ln,"auto",xe,ve],L=()=>["auto","min","max","fr",xe,ve],G=()=>["start","end","center","between","around","evenly","stretch","baseline","center-safe","end-safe"],F=()=>["start","end","center","stretch","center-safe","end-safe"],w=()=>["auto",...U()],Z=()=>[$a,"auto","full","dvw","dvh","lvw","lvh","svw","svh","min","max","fit",...U()],ue=()=>[$a,"screen","full","dvw","lvw","svw","min","max","fit",...U()],te=()=>[$a,"screen","full","lh","dvh","lvh","svh","min","max","fit",...U()],P=()=>[n,xe,ve],k=()=>[...Y(),Zg,Xg,{position:[xe,ve]}],I=()=>["no-repeat",{repeat:["","x","y","space","round"]}],$=()=>["auto","cover","contain",_S,yS,{size:[xe,ve]}],T=()=>[Bd,ao,Ol],B=()=>["","none","full",g,xe,ve],q=()=>["",Le,ao,Ol],V=()=>["solid","dashed","dotted","double"],me=()=>["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","hard-light","soft-light","difference","exclusion","hue","saturation","color","luminosity"],he=()=>[Le,Bd,Zg,Xg],ke=()=>["","none",N,xe,ve],Ae=()=>["none",Le,xe,ve],Ue=()=>["none",Le,xe,ve],nt=()=>[Le,xe,ve],Ve=()=>[$a,"full",...U()];return{cacheSize:500,theme:{animate:["spin","ping","pulse","bounce"],aspect:["video"],blur:[ua],breakpoint:[ua],color:[H0],container:[ua],"drop-shadow":[ua],ease:["in","out","in-out"],font:[pS],"font-weight":["thin","extralight","light","normal","medium","semibold","bold","extrabold","black"],"inset-shadow":[ua],leading:["none","tight","snug","normal","relaxed","loose"],perspective:["dramatic","near","normal","midrange","distant","none"],radius:[ua],shadow:[ua],spacing:["px",Le],text:[ua],"text-shadow":[ua],tracking:["tighter","tight","normal","wide","wider","widest"]},classGroups:{aspect:[{aspect:["auto","square",$a,ve,xe,j]}],container:["container"],"container-type":[{"@container":["","normal","size",xe,ve]}],"container-named":[mS],columns:[{columns:[Le,ve,xe,p]}],"break-after":[{"break-after":D()}],"break-before":[{"break-before":D()}],"break-inside":[{"break-inside":["auto","avoid","avoid-page","avoid-column"]}],"box-decoration":[{"box-decoration":["slice","clone"]}],box:[{box:["border","content"]}],display:["block","inline-block","inline","flex","inline-flex","table","inline-table","table-caption","table-cell","table-column","table-column-group","table-footer-group","table-header-group","table-row-group","table-row","flow-root","grid","inline-grid","contents","list-item","hidden"],sr:["sr-only","not-sr-only"],float:[{float:["right","left","none","start","end"]}],clear:[{clear:["left","right","both","none","start","end"]}],isolation:["isolate","isolation-auto"],"object-fit":[{object:["contain","cover","fill","none","scale-down"]}],"object-position":[{object:W()}],overflow:[{overflow:ee()}],"overflow-x":[{"overflow-x":ee()}],"overflow-y":[{"overflow-y":ee()}],overscroll:[{overscroll:ae()}],"overscroll-x":[{"overscroll-x":ae()}],"overscroll-y":[{"overscroll-y":ae()}],position:["static","fixed","absolute","relative","sticky"],inset:[{inset:re()}],"inset-x":[{"inset-x":re()}],"inset-y":[{"inset-y":re()}],start:[{"inset-s":re(),start:re()}],end:[{"inset-e":re(),end:re()}],"inset-bs":[{"inset-bs":re()}],"inset-be":[{"inset-be":re()}],top:[{top:re()}],right:[{right:re()}],bottom:[{bottom:re()}],left:[{left:re()}],visibility:["visible","invisible","collapse"],z:[{z:[Ln,"auto",xe,ve]}],basis:[{basis:[$a,"full","auto",p,...U()]}],"flex-direction":[{flex:["row","row-reverse","col","col-reverse"]}],"flex-wrap":[{flex:["nowrap","wrap","wrap-reverse"]}],flex:[{flex:[Le,$a,"auto","initial","none",ve]}],grow:[{grow:["",Le,xe,ve]}],shrink:[{shrink:["",Le,xe,ve]}],order:[{order:[Ln,"first","last","none",xe,ve]}],"grid-cols":[{"grid-cols":de()}],"col-start-end":[{col:ce()}],"col-start":[{"col-start":ie()}],"col-end":[{"col-end":ie()}],"grid-rows":[{"grid-rows":de()}],"row-start-end":[{row:ce()}],"row-start":[{"row-start":ie()}],"row-end":[{"row-end":ie()}],"grid-flow":[{"grid-flow":["row","col","dense","row-dense","col-dense"]}],"auto-cols":[{"auto-cols":L()}],"auto-rows":[{"auto-rows":L()}],gap:[{gap:U()}],"gap-x":[{"gap-x":U()}],"gap-y":[{"gap-y":U()}],"justify-content":[{justify:[...G(),"normal"]}],"justify-items":[{"justify-items":[...F(),"normal"]}],"justify-self":[{"justify-self":["auto",...F()]}],"align-content":[{content:["normal",...G()]}],"align-items":[{items:[...F(),{baseline:["","last"]}]}],"align-self":[{self:["auto",...F(),{baseline:["","last"]}]}],"place-content":[{"place-content":G()}],"place-items":[{"place-items":[...F(),"baseline"]}],"place-self":[{"place-self":["auto",...F()]}],p:[{p:U()}],px:[{px:U()}],py:[{py:U()}],ps:[{ps:U()}],pe:[{pe:U()}],pbs:[{pbs:U()}],pbe:[{pbe:U()}],pt:[{pt:U()}],pr:[{pr:U()}],pb:[{pb:U()}],pl:[{pl:U()}],m:[{m:w()}],mx:[{mx:w()}],my:[{my:w()}],ms:[{ms:w()}],me:[{me:w()}],mbs:[{mbs:w()}],mbe:[{mbe:w()}],mt:[{mt:w()}],mr:[{mr:w()}],mb:[{mb:w()}],ml:[{ml:w()}],"space-x":[{"space-x":U()}],"space-x-reverse":["space-x-reverse"],"space-y":[{"space-y":U()}],"space-y-reverse":["space-y-reverse"],size:[{size:Z()}],"inline-size":[{inline:["auto",...ue()]}],"min-inline-size":[{"min-inline":["auto",...ue()]}],"max-inline-size":[{"max-inline":["none",...ue()]}],"block-size":[{block:["auto",...te()]}],"min-block-size":[{"min-block":["auto",...te()]}],"max-block-size":[{"max-block":["none",...te()]}],w:[{w:[p,"screen",...Z()]}],"min-w":[{"min-w":[p,"screen","none",...Z()]}],"max-w":[{"max-w":[p,"screen","none","prose",{screen:[h]},...Z()]}],h:[{h:["screen","lh",...Z()]}],"min-h":[{"min-h":["screen","lh","none",...Z()]}],"max-h":[{"max-h":["screen","lh",...Z()]}],"font-size":[{text:["base",s,ao,Ol]}],"font-smoothing":["antialiased","subpixel-antialiased"],"font-style":["italic","not-italic"],"font-weight":[{font:[o,SS,gS]}],"font-stretch":[{"font-stretch":["ultra-condensed","extra-condensed","condensed","semi-condensed","normal","semi-expanded","expanded","extra-expanded","ultra-expanded",Bd,ve]}],"font-family":[{font:[xS,bS,l]}],"font-features":[{"font-features":[ve]}],"fvn-normal":["normal-nums"],"fvn-ordinal":["ordinal"],"fvn-slashed-zero":["slashed-zero"],"fvn-figure":["lining-nums","oldstyle-nums"],"fvn-spacing":["proportional-nums","tabular-nums"],"fvn-fraction":["diagonal-fractions","stacked-fractions"],tracking:[{tracking:[u,xe,ve]}],"line-clamp":[{"line-clamp":[Le,"none",xe,Fg]}],leading:[{leading:[d,...U()]}],"list-image":[{"list-image":["none",xe,ve]}],"list-style-position":[{list:["inside","outside"]}],"list-style-type":[{list:["disc","decimal","none",xe,ve]}],"text-alignment":[{text:["left","center","right","justify","start","end"]}],"placeholder-color":[{placeholder:P()}],"text-color":[{text:P()}],"text-decoration":["underline","overline","line-through","no-underline"],"text-decoration-style":[{decoration:[...V(),"wavy"]}],"text-decoration-thickness":[{decoration:[Le,"from-font","auto",xe,Ol]}],"text-decoration-color":[{decoration:P()}],"underline-offset":[{"underline-offset":[Le,"auto",xe,ve]}],"text-transform":["uppercase","lowercase","capitalize","normal-case"],"text-overflow":["truncate","text-ellipsis","text-clip"],"text-wrap":[{text:["wrap","nowrap","balance","pretty"]}],indent:[{indent:U()}],"tab-size":[{tab:[Ln,xe,ve]}],"vertical-align":[{align:["baseline","top","middle","bottom","text-top","text-bottom","sub","super",xe,ve]}],whitespace:[{whitespace:["normal","nowrap","pre","pre-line","pre-wrap","break-spaces"]}],break:[{break:["normal","words","all","keep"]}],wrap:[{wrap:["break-word","anywhere","normal"]}],hyphens:[{hyphens:["none","manual","auto"]}],content:[{content:["none",xe,ve]}],"bg-attachment":[{bg:["fixed","local","scroll"]}],"bg-clip":[{"bg-clip":["border","padding","content","text"]}],"bg-origin":[{"bg-origin":["border","padding","content"]}],"bg-position":[{bg:k()}],"bg-repeat":[{bg:I()}],"bg-size":[{bg:$()}],"bg-image":[{bg:["none",{linear:[{to:["t","tr","r","br","b","bl","l","tl"]},Ln,xe,ve],radial:["",xe,ve],conic:[Ln,xe,ve]},wS,vS]}],"bg-color":[{bg:P()}],"gradient-from-pos":[{from:T()}],"gradient-via-pos":[{via:T()}],"gradient-to-pos":[{to:T()}],"gradient-from":[{from:P()}],"gradient-via":[{via:P()}],"gradient-to":[{to:P()}],rounded:[{rounded:B()}],"rounded-s":[{"rounded-s":B()}],"rounded-e":[{"rounded-e":B()}],"rounded-t":[{"rounded-t":B()}],"rounded-r":[{"rounded-r":B()}],"rounded-b":[{"rounded-b":B()}],"rounded-l":[{"rounded-l":B()}],"rounded-ss":[{"rounded-ss":B()}],"rounded-se":[{"rounded-se":B()}],"rounded-ee":[{"rounded-ee":B()}],"rounded-es":[{"rounded-es":B()}],"rounded-tl":[{"rounded-tl":B()}],"rounded-tr":[{"rounded-tr":B()}],"rounded-br":[{"rounded-br":B()}],"rounded-bl":[{"rounded-bl":B()}],"border-w":[{border:q()}],"border-w-x":[{"border-x":q()}],"border-w-y":[{"border-y":q()}],"border-w-s":[{"border-s":q()}],"border-w-e":[{"border-e":q()}],"border-w-bs":[{"border-bs":q()}],"border-w-be":[{"border-be":q()}],"border-w-t":[{"border-t":q()}],"border-w-r":[{"border-r":q()}],"border-w-b":[{"border-b":q()}],"border-w-l":[{"border-l":q()}],"divide-x":[{"divide-x":q()}],"divide-x-reverse":["divide-x-reverse"],"divide-y":[{"divide-y":q()}],"divide-y-reverse":["divide-y-reverse"],"border-style":[{border:[...V(),"hidden","none"]}],"divide-style":[{divide:[...V(),"hidden","none"]}],"border-color":[{border:P()}],"border-color-x":[{"border-x":P()}],"border-color-y":[{"border-y":P()}],"border-color-s":[{"border-s":P()}],"border-color-e":[{"border-e":P()}],"border-color-bs":[{"border-bs":P()}],"border-color-be":[{"border-be":P()}],"border-color-t":[{"border-t":P()}],"border-color-r":[{"border-r":P()}],"border-color-b":[{"border-b":P()}],"border-color-l":[{"border-l":P()}],"divide-color":[{divide:P()}],"outline-style":[{outline:[...V(),"none","hidden"]}],"outline-offset":[{"outline-offset":[Le,xe,ve]}],"outline-w":[{outline:["",Le,ao,Ol]}],"outline-color":[{outline:P()}],shadow:[{shadow:["","none",x,Vr,Kr]}],"shadow-color":[{shadow:P()}],"inset-shadow":[{"inset-shadow":["none",v,Vr,Kr]}],"inset-shadow-color":[{"inset-shadow":P()}],"ring-w":[{ring:q()}],"ring-w-inset":["ring-inset"],"ring-color":[{ring:P()}],"ring-offset-w":[{"ring-offset":[Le,Ol]}],"ring-offset-color":[{"ring-offset":P()}],"inset-ring-w":[{"inset-ring":q()}],"inset-ring-color":[{"inset-ring":P()}],"text-shadow":[{"text-shadow":["none",E,Vr,Kr]}],"text-shadow-color":[{"text-shadow":P()}],opacity:[{opacity:[Le,xe,ve]}],"mix-blend":[{"mix-blend":[...me(),"plus-darker","plus-lighter"]}],"bg-blend":[{"bg-blend":me()}],"mask-clip":[{"mask-clip":["border","padding","content","fill","stroke","view"]},"mask-no-clip"],"mask-composite":[{mask:["add","subtract","intersect","exclude"]}],"mask-image-linear-pos":[{"mask-linear":[Le]}],"mask-image-linear-from-pos":[{"mask-linear-from":he()}],"mask-image-linear-to-pos":[{"mask-linear-to":he()}],"mask-image-linear-from-color":[{"mask-linear-from":P()}],"mask-image-linear-to-color":[{"mask-linear-to":P()}],"mask-image-t-from-pos":[{"mask-t-from":he()}],"mask-image-t-to-pos":[{"mask-t-to":he()}],"mask-image-t-from-color":[{"mask-t-from":P()}],"mask-image-t-to-color":[{"mask-t-to":P()}],"mask-image-r-from-pos":[{"mask-r-from":he()}],"mask-image-r-to-pos":[{"mask-r-to":he()}],"mask-image-r-from-color":[{"mask-r-from":P()}],"mask-image-r-to-color":[{"mask-r-to":P()}],"mask-image-b-from-pos":[{"mask-b-from":he()}],"mask-image-b-to-pos":[{"mask-b-to":he()}],"mask-image-b-from-color":[{"mask-b-from":P()}],"mask-image-b-to-color":[{"mask-b-to":P()}],"mask-image-l-from-pos":[{"mask-l-from":he()}],"mask-image-l-to-pos":[{"mask-l-to":he()}],"mask-image-l-from-color":[{"mask-l-from":P()}],"mask-image-l-to-color":[{"mask-l-to":P()}],"mask-image-x-from-pos":[{"mask-x-from":he()}],"mask-image-x-to-pos":[{"mask-x-to":he()}],"mask-image-x-from-color":[{"mask-x-from":P()}],"mask-image-x-to-color":[{"mask-x-to":P()}],"mask-image-y-from-pos":[{"mask-y-from":he()}],"mask-image-y-to-pos":[{"mask-y-to":he()}],"mask-image-y-from-color":[{"mask-y-from":P()}],"mask-image-y-to-color":[{"mask-y-to":P()}],"mask-image-radial":[{"mask-radial":[xe,ve]}],"mask-image-radial-from-pos":[{"mask-radial-from":he()}],"mask-image-radial-to-pos":[{"mask-radial-to":he()}],"mask-image-radial-from-color":[{"mask-radial-from":P()}],"mask-image-radial-to-color":[{"mask-radial-to":P()}],"mask-image-radial-shape":[{"mask-radial":["circle","ellipse"]}],"mask-image-radial-size":[{"mask-radial":[{closest:["side","corner"],farthest:["side","corner"]}]}],"mask-image-radial-pos":[{"mask-radial-at":Y()}],"mask-image-conic-pos":[{"mask-conic":[Le]}],"mask-image-conic-from-pos":[{"mask-conic-from":he()}],"mask-image-conic-to-pos":[{"mask-conic-to":he()}],"mask-image-conic-from-color":[{"mask-conic-from":P()}],"mask-image-conic-to-color":[{"mask-conic-to":P()}],"mask-mode":[{mask:["alpha","luminance","match"]}],"mask-origin":[{"mask-origin":["border","padding","content","fill","stroke","view"]}],"mask-position":[{mask:k()}],"mask-repeat":[{mask:I()}],"mask-size":[{mask:$()}],"mask-type":[{"mask-type":["alpha","luminance"]}],"mask-image":[{mask:["none",xe,ve]}],filter:[{filter:["","none",xe,ve]}],blur:[{blur:ke()}],brightness:[{brightness:[Le,xe,ve]}],contrast:[{contrast:[Le,xe,ve]}],"drop-shadow":[{"drop-shadow":["","none",M,Vr,Kr]}],"drop-shadow-color":[{"drop-shadow":P()}],grayscale:[{grayscale:["",Le,xe,ve]}],"hue-rotate":[{"hue-rotate":[Le,xe,ve]}],invert:[{invert:["",Le,xe,ve]}],saturate:[{saturate:[Le,xe,ve]}],sepia:[{sepia:["",Le,xe,ve]}],"backdrop-filter":[{"backdrop-filter":["","none",xe,ve]}],"backdrop-blur":[{"backdrop-blur":ke()}],"backdrop-brightness":[{"backdrop-brightness":[Le,xe,ve]}],"backdrop-contrast":[{"backdrop-contrast":[Le,xe,ve]}],"backdrop-grayscale":[{"backdrop-grayscale":["",Le,xe,ve]}],"backdrop-hue-rotate":[{"backdrop-hue-rotate":[Le,xe,ve]}],"backdrop-invert":[{"backdrop-invert":["",Le,xe,ve]}],"backdrop-opacity":[{"backdrop-opacity":[Le,xe,ve]}],"backdrop-saturate":[{"backdrop-saturate":[Le,xe,ve]}],"backdrop-sepia":[{"backdrop-sepia":["",Le,xe,ve]}],"border-collapse":[{border:["collapse","separate"]}],"border-spacing":[{"border-spacing":U()}],"border-spacing-x":[{"border-spacing-x":U()}],"border-spacing-y":[{"border-spacing-y":U()}],"table-layout":[{table:["auto","fixed"]}],caption:[{caption:["top","bottom"]}],transition:[{transition:["","all","colors","opacity","shadow","transform","none",xe,ve]}],"transition-behavior":[{transition:["normal","discrete"]}],duration:[{duration:[Le,"initial",xe,ve]}],ease:[{ease:["linear","initial",O,xe,ve]}],delay:[{delay:[Le,xe,ve]}],animate:[{animate:["none",z,xe,ve]}],backface:[{backface:["hidden","visible"]}],perspective:[{perspective:[A,xe,ve]}],"perspective-origin":[{"perspective-origin":W()}],rotate:[{rotate:Ae()}],"rotate-x":[{"rotate-x":Ae()}],"rotate-y":[{"rotate-y":Ae()}],"rotate-z":[{"rotate-z":Ae()}],scale:[{scale:Ue()}],"scale-x":[{"scale-x":Ue()}],"scale-y":[{"scale-y":Ue()}],"scale-z":[{"scale-z":Ue()}],"scale-3d":["scale-3d"],skew:[{skew:nt()}],"skew-x":[{"skew-x":nt()}],"skew-y":[{"skew-y":nt()}],transform:[{transform:[xe,ve,"","none","gpu","cpu"]}],"transform-origin":[{origin:W()}],"transform-style":[{transform:["3d","flat"]}],translate:[{translate:Ve()}],"translate-x":[{"translate-x":Ve()}],"translate-y":[{"translate-y":Ve()}],"translate-z":[{"translate-z":Ve()}],"translate-none":["translate-none"],zoom:[{zoom:[Ln,xe,ve]}],accent:[{accent:P()}],appearance:[{appearance:["none","auto"]}],"caret-color":[{caret:P()}],"color-scheme":[{scheme:["normal","dark","light","light-dark","only-dark","only-light"]}],cursor:[{cursor:["auto","default","pointer","wait","text","move","help","not-allowed","none","context-menu","progress","cell","crosshair","vertical-text","alias","copy","no-drop","grab","grabbing","all-scroll","col-resize","row-resize","n-resize","e-resize","s-resize","w-resize","ne-resize","nw-resize","se-resize","sw-resize","ew-resize","ns-resize","nesw-resize","nwse-resize","zoom-in","zoom-out",xe,ve]}],"field-sizing":[{"field-sizing":["fixed","content"]}],"pointer-events":[{"pointer-events":["auto","none"]}],resize:[{resize:["none","","y","x"]}],"scroll-behavior":[{scroll:["auto","smooth"]}],"scrollbar-thumb-color":[{"scrollbar-thumb":P()}],"scrollbar-track-color":[{"scrollbar-track":P()}],"scrollbar-gutter":[{"scrollbar-gutter":["auto","stable","both"]}],"scrollbar-w":[{scrollbar:["auto","thin","none"]}],"scroll-m":[{"scroll-m":U()}],"scroll-mx":[{"scroll-mx":U()}],"scroll-my":[{"scroll-my":U()}],"scroll-ms":[{"scroll-ms":U()}],"scroll-me":[{"scroll-me":U()}],"scroll-mbs":[{"scroll-mbs":U()}],"scroll-mbe":[{"scroll-mbe":U()}],"scroll-mt":[{"scroll-mt":U()}],"scroll-mr":[{"scroll-mr":U()}],"scroll-mb":[{"scroll-mb":U()}],"scroll-ml":[{"scroll-ml":U()}],"scroll-p":[{"scroll-p":U()}],"scroll-px":[{"scroll-px":U()}],"scroll-py":[{"scroll-py":U()}],"scroll-ps":[{"scroll-ps":U()}],"scroll-pe":[{"scroll-pe":U()}],"scroll-pbs":[{"scroll-pbs":U()}],"scroll-pbe":[{"scroll-pbe":U()}],"scroll-pt":[{"scroll-pt":U()}],"scroll-pr":[{"scroll-pr":U()}],"scroll-pb":[{"scroll-pb":U()}],"scroll-pl":[{"scroll-pl":U()}],"snap-align":[{snap:["start","end","center","align-none"]}],"snap-stop":[{snap:["normal","always"]}],"snap-type":[{snap:["none","x","y","both"]}],"snap-strictness":[{snap:["mandatory","proximity"]}],touch:[{touch:["auto","none","manipulation"]}],"touch-x":[{"touch-pan":["x","left","right"]}],"touch-y":[{"touch-pan":["y","up","down"]}],"touch-pz":["touch-pinch-zoom"],select:[{select:["none","text","all","auto"]}],"will-change":[{"will-change":["auto","scroll","contents","transform",xe,ve]}],fill:[{fill:["none",...P()]}],"stroke-w":[{stroke:[Le,ao,Ol,Fg]}],stroke:[{stroke:["none",...P()]}],"forced-color-adjust":[{"forced-color-adjust":["auto","none"]}]},conflictingClassGroups:{"container-named":["container-type"],overflow:["overflow-x","overflow-y"],overscroll:["overscroll-x","overscroll-y"],inset:["inset-x","inset-y","inset-bs","inset-be","start","end","top","right","bottom","left"],"inset-x":["right","left"],"inset-y":["top","bottom"],flex:["basis","grow","shrink"],gap:["gap-x","gap-y"],p:["px","py","ps","pe","pbs","pbe","pt","pr","pb","pl"],px:["pr","pl"],py:["pt","pb"],m:["mx","my","ms","me","mbs","mbe","mt","mr","mb","ml"],mx:["mr","ml"],my:["mt","mb"],size:["w","h"],"font-size":["leading"],"fvn-normal":["fvn-ordinal","fvn-slashed-zero","fvn-figure","fvn-spacing","fvn-fraction"],"fvn-ordinal":["fvn-normal"],"fvn-slashed-zero":["fvn-normal"],"fvn-figure":["fvn-normal"],"fvn-spacing":["fvn-normal"],"fvn-fraction":["fvn-normal"],"line-clamp":["display","overflow"],rounded:["rounded-s","rounded-e","rounded-t","rounded-r","rounded-b","rounded-l","rounded-ss","rounded-se","rounded-ee","rounded-es","rounded-tl","rounded-tr","rounded-br","rounded-bl"],"rounded-s":["rounded-ss","rounded-es"],"rounded-e":["rounded-se","rounded-ee"],"rounded-t":["rounded-tl","rounded-tr"],"rounded-r":["rounded-tr","rounded-br"],"rounded-b":["rounded-br","rounded-bl"],"rounded-l":["rounded-tl","rounded-bl"],"border-spacing":["border-spacing-x","border-spacing-y"],"border-w":["border-w-x","border-w-y","border-w-s","border-w-e","border-w-bs","border-w-be","border-w-t","border-w-r","border-w-b","border-w-l"],"border-w-x":["border-w-r","border-w-l"],"border-w-y":["border-w-t","border-w-b"],"border-color":["border-color-x","border-color-y","border-color-s","border-color-e","border-color-bs","border-color-be","border-color-t","border-color-r","border-color-b","border-color-l"],"border-color-x":["border-color-r","border-color-l"],"border-color-y":["border-color-t","border-color-b"],translate:["translate-x","translate-y","translate-none"],"translate-none":["translate","translate-x","translate-y","translate-z"],"scroll-m":["scroll-mx","scroll-my","scroll-ms","scroll-me","scroll-mbs","scroll-mbe","scroll-mt","scroll-mr","scroll-mb","scroll-ml"],"scroll-mx":["scroll-mr","scroll-ml"],"scroll-my":["scroll-mt","scroll-mb"],"scroll-p":["scroll-px","scroll-py","scroll-ps","scroll-pe","scroll-pbs","scroll-pbe","scroll-pt","scroll-pr","scroll-pb","scroll-pl"],"scroll-px":["scroll-pr","scroll-pl"],"scroll-py":["scroll-pt","scroll-pb"],touch:["touch-x","touch-y","touch-pz"],"touch-x":["touch"],"touch-y":["touch"],"touch-pz":["touch"]},conflictingClassGroupModifiers:{"font-size":["leading"]},postfixLookupClassGroups:["container-type"],orderSensitiveModifiers:["*","**","after","backdrop","before","details-content","file","first-letter","first-line","marker","placeholder","selection"]}},$f=aS(ES);function ye(...n){return $f(Kf(n))}const jS={property:{latitude:"lat",longitude:"lon"},contact:{address:"contact_address"}},MS={address:{role:"bindable",path:"address",container:"property",value_type:"text",input_group:"address",strength:"blocking",fields:{display:{value_type:"text"},street:{value_type:"text"},street_no_type:{value_type:"text"},city:{value_type:"text"},state:{value_type:"text"},postal:{value_type:"text"},unit:{value_type:"text"}}},address_street:{role:"bindable",path:"address.street",container:"property",value_type:"text",input_group:"address",strength:"blocking"},address_unit:{role:"bindable",path:"address.unit",container:"property",value_type:"text",input_group:"address",strength:"optional"},address_city:{role:"bindable",path:"address.city",container:"property",value_type:"text",input_group:"address",strength:"blocking"},address_state:{role:"bindable",path:"address.state",container:"property",value_type:"text",input_group:"address",strength:"blocking"},address_postal:{role:"bindable",path:"address.postal",container:"property",value_type:"text",input_group:"address",strength:"blocking"},listing_intent:{role:"bindable",path:"listing_intent",container:"property",value_type:"text",input_group:"intent",strength:"blocking",writeback:{kind:"property",column:"listing_intent"}},property_type:{role:"bindable",path:"property_type",container:"property",value_type:"text",input_group:"type",strength:"blocking"},lat:{role:"bindable",path:"lat",container:"property",value_type:"number",input_group:"address",strength:"blocking"},lon:{role:"bindable",path:"lon",container:"property",value_type:"number",input_group:"address",strength:"blocking"}},$0={units:{role:"bindable",path:"units",container:"property",value_type:"unit_list",input_group:"units",strength:"blocking",row:{unit_id:{path:"unit_id",value_type:"text"},position:{path:"position",value_type:"number"},floor_plans:{path:"floor_plans",value_type:"image_list",pool:"floor_plans",row:{id:{value_type:"text"},floor_label:{value_type:"text"},position:{value_type:"number"}}},unit_label:{path:"unit_label",value_type:"text",strength:"optional",writeback:{column:"unit_label"}},beds:{path:"beds",value_type:"number",strength:"blocking",writeback:{column:"beds"}},baths:{path:"baths",value_type:"number",strength:"blocking",writeback:{column:"baths"}},sqft:{path:"sqft",value_type:"number",strength:"blocking",writeback:{column:"sqft"}},price:{path:"price",value_type:"text",strength:"blocking",writeback:{column:"price"}}}},comparables:{role:"bindable",path:"comparables",container:"property",value_type:"comparable_list",input_group:"comparables",strength:"blocking",row:{id:{path:"id",value_type:"text"},address_street:{path:"address_street",value_type:"text",required:!0},address_city:{path:"address_city",value_type:"text"},address_state:{path:"address_state",value_type:"text"},address_postal:{path:"address_postal",value_type:"text"},address:{path:"address",value_type:"text"},lat:{path:"lat",value_type:"number",required:!0},lng:{path:"lng",value_type:"number",required:!0},distance_m:{path:"distance_m",value_type:"number"},status:{path:"status",value_type:"text"},price:{path:"price",value_type:"number",required:!0,writeback:{column:"price"}},price_period:{path:"price_period",value_type:"text"},sale_date:{path:"sale_date",value_type:"text",writeback:{column:"sale_date"}},beds:{path:"beds",value_type:"number",required:!0,writeback:{column:"beds"}},baths:{path:"baths",value_type:"number",required:!0,writeback:{column:"baths"}},sqft:{path:"sqft",value_type:"number",required:!0,writeback:{column:"sqft"}},photo:{path:"photo_upload_id",value_type:"image"},year_built:{path:"year_built",value_type:"number"},lot_sqft:{path:"lot_sqft",value_type:"number"},stories:{path:"stories",value_type:"number"},units:{path:"units",value_type:"number"},hoa_monthly:{path:"hoa_monthly",value_type:"number"},list_price:{path:"list_price",value_type:"number"},listed_date:{path:"listed_date",value_type:"text"},mls_number:{path:"mls_number",value_type:"text"},description:{path:"description",value_type:"text"},property_type:{path:"property_type",value_type:"text"}}},contacts:{role:"bindable",path:"contacts",container:"property",value_type:"contact_list",input_group:"contacts",strength:"blocking",row:{id:{path:"id",value_type:"text"},primary:{path:"primary",value_type:"boolean"},name:{path:"name",value_type:"text",strength:"optional",writeback:{column:"name"}},title:{path:"title",value_type:"text",strength:"optional",writeback:{column:"title"}},org_name:{path:"org_name",value_type:"text",strength:"optional",writeback:{column:"org_name"}},bio:{path:"bio",value_type:"text",strength:"optional",writeback:{column:"bio"}},address:{path:"address",value_type:"text",strength:"optional",writeback:{column:"address"}},email:{path:"email",value_type:"text",strength:"optional",writeback:{column:"email"}},phone:{path:"phone",value_type:"text",strength:"optional",writeback:{column:"phone"}},website:{path:"website_url",value_type:"text",strength:"optional",writeback:{column:"website"}},instagram:{path:"instagram_url",value_type:"text",strength:"optional",writeback:{column:"socials.instagram"}},linkedin:{path:"linkedin_url",value_type:"text",strength:"optional",writeback:{column:"socials.linkedin"}},x:{path:"x_url",value_type:"text",strength:"optional",writeback:{column:"socials.x"}},facebook:{path:"facebook_url",value_type:"text",strength:"optional",writeback:{column:"socials.facebook"}},headshot:{path:"avatar_upload_id",value_type:"image",strength:"optional",pool:"library"},logo_dark:{path:"logo_dark_upload_id",value_type:"image",strength:"optional",pool:"library"},logo_light:{path:"logo_light_upload_id",value_type:"image",strength:"optional",pool:"library"}}}},F0={description:{role:"readable",path:"narrative.description",value_type:"text",input_group:"describe",strength:"optional"},photos:{role:"readable",path:"photos",value_type:"row_list",input_group:"uploads",strength:"optional",row:{id:{value_type:"text"},tags:{value_type:"text_list"},caption:{value_type:"text"}}},videos:{role:"readable",path:"videos",value_type:"row_list",input_group:"uploads",strength:"optional",row:{id:{value_type:"text"},source:{value_type:"text"},tags:{value_type:"text_list"},caption:{value_type:"text"},description:{value_type:"text"},duration_ms:{value_type:"number"},url:{value_type:"text"},provider:{value_type:"text"}}},tours:{role:"readable",path:"tours",value_type:"row_list",input_group:"uploads",strength:"optional",row:{id:{value_type:"text"},url:{value_type:"text"},provider:{value_type:"text"}}},floor_plans:{role:"readable",path:"floor_plans",value_type:"row_list",input_group:"uploads",strength:"optional",row:{id:{value_type:"text"},unit_assignments:{value_type:"row_list",row:{unit_label:{value_type:"text"},floor_label:{value_type:"text"},position:{value_type:"number"}}}}},documents:{role:"readable",path:"documents",value_type:"row_list",input_group:"uploads",strength:"optional",row:{id:{value_type:"text"},filename:{value_type:"text"},mime:{value_type:"text"},notes:{value_type:"text"}}},document_notes:{role:"readable",path:"document_notes",value_type:"row_list",input_group:"uploads",strength:"optional",row:{upload_id:{value_type:"text"},notes:{value_type:"text"}}},unit:{role:"readable",path:"units",value_type:"row",primary_of:"units"},contact:{role:"readable",path:"contacts",value_type:"row",primary_of:"contacts"}};function Pg(n){const l=$0[F0[n].primary_of],s=jS[n]??{},o={};for(const[u,d]of Object.entries(l.row)){if(d.strength===void 0)continue;const h={role:"bindable",path:`${l.path}[].${d.path}`,container:n,value_type:d.value_type,input_group:l.input_group,strength:d.strength};d.value_type==="image"&&(h.image=!0),d.writeback!==void 0&&(h.writeback=n==="unit"?{kind:"unit",column:d.writeback.column}:{kind:"contact",field:d.writeback.column}),o[s[u]??u]=h}return o}function CS(){return{...MS,...Pg("unit"),...$0,...Pg("contact"),...F0}}const AS=CS(),X0={units:{idKey:"unit_id",ownership:"property"},contacts:{idKey:"id",cap:12,min:1,ownership:"library"},comparables:{idKey:"id",ownership:"property"}};function Z0(n){var s;if(((s=n.source)==null?void 0:s.kind)!=="direct")return null;const l=n.source.field;return l!==void 0&&Object.hasOwn(X0,l)?l:null}function Ff(n,l){const s=AS[n].row;return Object.hasOwn(s,l)?s[l]??null:null}function Xf(n,l){const s=l.source;return(s==null?void 0:s.kind)!=="row"||typeof s.field!="string"?null:Ff(n,s.field)!==null?s.field:null}const NS=["tour","video","social","listing","file","map"],Xl={matterport:{kind:"tour",label:"Matterport",pattern:/(^|\.)matterport\.com$/i,strategy:"api"},biganto:{kind:"tour",label:"Biganto",pattern:/(^|\.)biganto\.com$/i,strategy:"opengraph"},youtube:{kind:"video",label:"YouTube",pattern:/(^|\.)(youtube\.com|youtu\.be)$/i,strategy:"oembed"},vimeo:{kind:"video",label:"Vimeo",pattern:/(^|\.)vimeo\.com$/i,strategy:"oembed"},zillow:{kind:"listing",label:"Zillow",pattern:/(^|\.)zillow\.com$/i,strategy:"none"},redfin:{kind:"listing",label:"Redfin",pattern:/(^|\.)redfin\.com$/i,strategy:"none"},dropbox:{kind:"file",label:"Dropbox",pattern:/(^|\.)dropbox\.com$/i,strategy:"none"},drive:{kind:"file",label:"Google Drive",pattern:/^drive\.google\.com$/i,strategy:"none"},maps:{kind:"map",label:"Google Maps",pattern:/(^|\.)google\.com$/i,path:/^\/maps(\/|$)/i,strategy:"none"}};function P0(n){let l;try{l=new URL(n)}catch{return null}if(l.protocol!=="http:"&&l.protocol!=="https:")return null;for(const[s,o]of Object.entries(Xl))if(o.pattern.test(l.hostname)&&!(o.path&&!o.path.test(l.pathname)))return s;return null}function nf(n,l){const s=P0(l);return s===null?!1:s===n?!0:NS.includes(n)&&Xl[s].kind===n}function TS(n,l){if(n!=="comparables")return!1;const s=Xf(n,l);if(s===null)return!1;const o=Ff(n,s);return(o==null?void 0:o.value_type)==="image"&&o.pool===void 0}function J0(n){return n==="logo_dark"?{kind:"logo",variant:"dark"}:n==="logo_light"?{kind:"logo",variant:"light"}:n==="headshot"?{kind:"headshot"}:null}function OS(n){return(n==null?void 0:n.kind)!=="direct"?null:J0(n.field)}function RS(n,l){return n==="contacts"?J0(Xf("contacts",l)):null}function zS(n){return n.kind==="headshot"?"headshot":n.variant==="dark"?"logo_dark":"logo_light"}function af(n){if(typeof n!="object"||n===null)return null;const l=n,s=typeof l.photo_id=="string"&&l.photo_id.length>0?l.photo_id:null;return s||(typeof l.asset_id=="string"&&l.asset_id.length>0?l.asset_id:null)}/**
|
|
699
|
+
* @license lucide-react v1.28.0 - ISC
|
|
700
|
+
*
|
|
701
|
+
* This source code is licensed under the ISC license.
|
|
702
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
703
|
+
*/const W0=(...n)=>n.filter((l,s,o)=>!!l&&l.trim()!==""&&o.indexOf(l)===s).join(" ").trim();/**
|
|
704
|
+
* @license lucide-react v1.28.0 - ISC
|
|
705
|
+
*
|
|
706
|
+
* This source code is licensed under the ISC license.
|
|
707
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
708
|
+
*/const DS=n=>n.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase();/**
|
|
709
|
+
* @license lucide-react v1.28.0 - ISC
|
|
710
|
+
*
|
|
711
|
+
* This source code is licensed under the ISC license.
|
|
712
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
713
|
+
*/const US=n=>n.replace(/^([A-Z])|[\s-_]+(\w)/g,(l,s,o)=>o?o.toUpperCase():s.toLowerCase());/**
|
|
714
|
+
* @license lucide-react v1.28.0 - ISC
|
|
715
|
+
*
|
|
716
|
+
* This source code is licensed under the ISC license.
|
|
717
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
718
|
+
*/const Jg=n=>{const l=US(n);return l.charAt(0).toUpperCase()+l.slice(1)};/**
|
|
719
|
+
* @license lucide-react v1.28.0 - ISC
|
|
720
|
+
*
|
|
721
|
+
* This source code is licensed under the ISC license.
|
|
722
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
723
|
+
*/var Hd={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"};/**
|
|
724
|
+
* @license lucide-react v1.28.0 - ISC
|
|
725
|
+
*
|
|
726
|
+
* This source code is licensed under the ISC license.
|
|
727
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
728
|
+
*/const LS=n=>{for(const l in n)if(l.startsWith("aria-")||l==="role"||l==="title")return!0;return!1},BS=_.createContext({}),HS=()=>_.useContext(BS),qS=_.forwardRef(({color:n,size:l,strokeWidth:s,absoluteStrokeWidth:o,className:u="",children:d,iconNode:h,...p},y)=>{const{size:g=24,strokeWidth:x=2,absoluteStrokeWidth:v=!1,color:E="currentColor",className:M=""}=HS()??{},N=o??v?Number(s??x)*24/Number(l??g):s??x;return _.createElement("svg",{ref:y,...Hd,width:l??g??Hd.width,height:l??g??Hd.height,stroke:n??E,strokeWidth:N,className:W0("lucide",M,u),...!d&&!LS(p)&&{"aria-hidden":"true"},...p},[...h.map(([A,j])=>_.createElement(A,j)),...Array.isArray(d)?d:[d]])});/**
|
|
729
|
+
* @license lucide-react v1.28.0 - ISC
|
|
730
|
+
*
|
|
731
|
+
* This source code is licensed under the ISC license.
|
|
732
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
733
|
+
*/const ge=(n,l)=>{const s=_.forwardRef(({className:o,...u},d)=>_.createElement(qS,{ref:d,iconNode:l,className:W0(`lucide-${DS(Jg(n))}`,`lucide-${n}`,o),...u}));return s.displayName=Jg(n),s};/**
|
|
734
|
+
* @license lucide-react v1.28.0 - ISC
|
|
735
|
+
*
|
|
736
|
+
* This source code is licensed under the ISC license.
|
|
737
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
738
|
+
*/const GS=[["path",{d:"M22 12h-2.48a2 2 0 0 0-1.93 1.46l-2.35 8.36a.25.25 0 0 1-.48 0L9.24 2.18a.25.25 0 0 0-.48 0l-2.35 8.36A2 2 0 0 1 4.49 12H2",key:"169zse"}]],IS=ge("activity",GS);/**
|
|
739
|
+
* @license lucide-react v1.28.0 - ISC
|
|
740
|
+
*
|
|
741
|
+
* This source code is licensed under the ISC license.
|
|
742
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
743
|
+
*/const QS=[["rect",{width:"20",height:"5",x:"2",y:"3",rx:"1",key:"1wp1u1"}],["path",{d:"M4 8v11a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V8",key:"1s80jp"}],["path",{d:"M10 12h4",key:"a56b0p"}]],KS=ge("archive",QS);/**
|
|
744
|
+
* @license lucide-react v1.28.0 - ISC
|
|
745
|
+
*
|
|
746
|
+
* This source code is licensed under the ISC license.
|
|
747
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
748
|
+
*/const VS=[["path",{d:"M12 5v14",key:"s699le"}],["path",{d:"m19 12-7 7-7-7",key:"1idqje"}]],YS=ge("arrow-down",VS);/**
|
|
749
|
+
* @license lucide-react v1.28.0 - ISC
|
|
750
|
+
*
|
|
751
|
+
* This source code is licensed under the ISC license.
|
|
752
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
753
|
+
*/const $S=[["path",{d:"M8 3 4 7l4 4",key:"9rb6wj"}],["path",{d:"M4 7h16",key:"6tx8e3"}],["path",{d:"m16 21 4-4-4-4",key:"siv7j2"}],["path",{d:"M20 17H4",key:"h6l3hr"}]],FS=ge("arrow-left-right",$S);/**
|
|
754
|
+
* @license lucide-react v1.28.0 - ISC
|
|
755
|
+
*
|
|
756
|
+
* This source code is licensed under the ISC license.
|
|
757
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
758
|
+
*/const XS=[["path",{d:"m12 19-7-7 7-7",key:"1l729n"}],["path",{d:"M19 12H5",key:"x3x0zl"}]],ZS=ge("arrow-left",XS);/**
|
|
759
|
+
* @license lucide-react v1.28.0 - ISC
|
|
760
|
+
*
|
|
761
|
+
* This source code is licensed under the ISC license.
|
|
762
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
763
|
+
*/const PS=[["path",{d:"M5 12h14",key:"1ays0h"}],["path",{d:"m12 5 7 7-7 7",key:"xquz4c"}]],JS=ge("arrow-right",PS);/**
|
|
764
|
+
* @license lucide-react v1.28.0 - ISC
|
|
765
|
+
*
|
|
766
|
+
* This source code is licensed under the ISC license.
|
|
767
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
768
|
+
*/const WS=[["path",{d:"m5 12 7-7 7 7",key:"hav0vg"}],["path",{d:"M12 19V5",key:"x0mq9r"}]],ek=ge("arrow-up",WS);/**
|
|
769
|
+
* @license lucide-react v1.28.0 - ISC
|
|
770
|
+
*
|
|
771
|
+
* This source code is licensed under the ISC license.
|
|
772
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
773
|
+
*/const tk=[["path",{d:"M12 5v16",key:"1f6ucr"}],["path",{d:"M20.001 19A2 2 0 0022 17V5a2 2 0 00-1.999-2L16 3.002A5 5 0 0012 5a5 5 0 00-4-2H4a2 2 0 00-2 2v12a2 2 0 001.999 2H8a5 5 0 014 2 5 5 0 014-2z",key:"1fyvmf"}]],nk=ge("book-open",tk);/**
|
|
774
|
+
* @license lucide-react v1.28.0 - ISC
|
|
775
|
+
*
|
|
776
|
+
* This source code is licensed under the ISC license.
|
|
777
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
778
|
+
*/const ak=[["path",{d:"M21 8a2 2 0 0 0-1-1.73l-7-4a2 2 0 0 0-2 0l-7 4A2 2 0 0 0 3 8v8a2 2 0 0 0 1 1.73l7 4a2 2 0 0 0 2 0l7-4A2 2 0 0 0 21 16Z",key:"hh9hay"}],["path",{d:"m3.3 7 8.7 5 8.7-5",key:"g66t2b"}],["path",{d:"M12 22V12",key:"d0xqtd"}]],Zf=ge("box",ak);/**
|
|
779
|
+
* @license lucide-react v1.28.0 - ISC
|
|
780
|
+
*
|
|
781
|
+
* This source code is licensed under the ISC license.
|
|
782
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
783
|
+
*/const lk=[["path",{d:"M10 12h4",key:"a56b0p"}],["path",{d:"M10 8h4",key:"1sr2af"}],["path",{d:"M14 21v-3a2 2 0 0 0-4 0v3",key:"1rgiei"}],["path",{d:"M6 10H4a2 2 0 0 0-2 2v7a2 2 0 0 0 2 2h16a2 2 0 0 0 2-2V9a2 2 0 0 0-2-2h-2",key:"secmi2"}],["path",{d:"M6 21V5a2 2 0 0 1 2-2h8a2 2 0 0 1 2 2v16",key:"16ra0t"}]],ik=ge("building-2",lk);/**
|
|
784
|
+
* @license lucide-react v1.28.0 - ISC
|
|
785
|
+
*
|
|
786
|
+
* This source code is licensed under the ISC license.
|
|
787
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
788
|
+
*/const sk=[["path",{d:"M8 2v3",key:"1ioesn"}],["path",{d:"M16 2v3",key:"otl347"}],["rect",{x:"3",y:"3",width:"18",height:"18",rx:"2",key:"h1oib"}],["path",{d:"M3 9h18",key:"1pudct"}]],ok=ge("calendar",sk);/**
|
|
789
|
+
* @license lucide-react v1.28.0 - ISC
|
|
790
|
+
*
|
|
791
|
+
* This source code is licensed under the ISC license.
|
|
792
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
793
|
+
*/const rk=[["path",{d:"M3 3v16a2 2 0 0 0 2 2h16",key:"c24i48"}],["path",{d:"m19 9-5 5-4-4-3 3",key:"2osh9i"}]],ck=ge("chart-line",rk);/**
|
|
794
|
+
* @license lucide-react v1.28.0 - ISC
|
|
795
|
+
*
|
|
796
|
+
* This source code is licensed under the ISC license.
|
|
797
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
798
|
+
*/const uk=[["path",{d:"M20 6 9 17l-5-5",key:"1gmf2c"}]],ev=ge("check",uk);/**
|
|
799
|
+
* @license lucide-react v1.28.0 - ISC
|
|
800
|
+
*
|
|
801
|
+
* This source code is licensed under the ISC license.
|
|
802
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
803
|
+
*/const dk=[["path",{d:"m6 9 6 6 6-6",key:"qrunsl"}]],fk=ge("chevron-down",dk);/**
|
|
804
|
+
* @license lucide-react v1.28.0 - ISC
|
|
805
|
+
*
|
|
806
|
+
* This source code is licensed under the ISC license.
|
|
807
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
808
|
+
*/const hk=[["path",{d:"m9 18 6-6-6-6",key:"mthhwq"}]],pk=ge("chevron-right",hk);/**
|
|
809
|
+
* @license lucide-react v1.28.0 - ISC
|
|
810
|
+
*
|
|
811
|
+
* This source code is licensed under the ISC license.
|
|
812
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
813
|
+
*/const mk=[["path",{d:"m7 15 5 5 5-5",key:"1hf1tw"}],["path",{d:"m7 9 5-5 5 5",key:"sgt6xg"}]],yk=ge("chevrons-up-down",mk);/**
|
|
814
|
+
* @license lucide-react v1.28.0 - ISC
|
|
815
|
+
*
|
|
816
|
+
* This source code is licensed under the ISC license.
|
|
817
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
818
|
+
*/const gk=[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M9.09 9a3 3 0 0 1 5.83 1c0 2-3 3-3 3",key:"1u773s"}],["path",{d:"M12 17h.01",key:"p32p05"}]],bk=ge("circle-question-mark",gk);/**
|
|
819
|
+
* @license lucide-react v1.28.0 - ISC
|
|
820
|
+
*
|
|
821
|
+
* This source code is licensed under the ISC license.
|
|
822
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
823
|
+
*/const vk=[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M12 6v6l4 2",key:"mmk7yg"}]],xk=ge("clock",vk);/**
|
|
824
|
+
* @license lucide-react v1.28.0 - ISC
|
|
825
|
+
*
|
|
826
|
+
* This source code is licensed under the ISC license.
|
|
827
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
828
|
+
*/const _k=[["rect",{width:"14",height:"14",x:"8",y:"8",rx:"2",ry:"2",key:"17jyea"}],["path",{d:"M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2",key:"zix9uf"}]],wk=ge("copy",_k);/**
|
|
829
|
+
* @license lucide-react v1.28.0 - ISC
|
|
830
|
+
*
|
|
831
|
+
* This source code is licensed under the ISC license.
|
|
832
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
833
|
+
*/const Sk=[["rect",{width:"20",height:"14",x:"2",y:"5",rx:"2",key:"ynyp8z"}],["line",{x1:"2",x2:"22",y1:"10",y2:"10",key:"1b3vmo"}]],kk=ge("credit-card",Sk);/**
|
|
834
|
+
* @license lucide-react v1.28.0 - ISC
|
|
835
|
+
*
|
|
836
|
+
* This source code is licensed under the ISC license.
|
|
837
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
838
|
+
*/const Ek=[["path",{d:"M6 2v14a2 2 0 0 0 2 2h14",key:"ron5a4"}],["path",{d:"M18 22V8a2 2 0 0 0-2-2H2",key:"7s9ehn"}]],jk=ge("crop",Ek);/**
|
|
839
|
+
* @license lucide-react v1.28.0 - ISC
|
|
840
|
+
*
|
|
841
|
+
* This source code is licensed under the ISC license.
|
|
842
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
843
|
+
*/const Mk=[["path",{d:"M12 15V3",key:"m9g1x1"}],["path",{d:"M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4",key:"ih7n3h"}],["path",{d:"m7 10 5 5 5-5",key:"brsn70"}]],Ck=ge("download",Mk);/**
|
|
844
|
+
* @license lucide-react v1.28.0 - ISC
|
|
845
|
+
*
|
|
846
|
+
* This source code is licensed under the ISC license.
|
|
847
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
848
|
+
*/const Ak=[["circle",{cx:"12",cy:"12",r:"1",key:"41hilf"}],["circle",{cx:"19",cy:"12",r:"1",key:"1wjl8i"}],["circle",{cx:"5",cy:"12",r:"1",key:"1pcz8c"}]],Nk=ge("ellipsis",Ak);/**
|
|
849
|
+
* @license lucide-react v1.28.0 - ISC
|
|
850
|
+
*
|
|
851
|
+
* This source code is licensed under the ISC license.
|
|
852
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
853
|
+
*/const Tk=[["path",{d:"M15 3h6v6",key:"1q9fwt"}],["path",{d:"M10 14 21 3",key:"gplh6r"}],["path",{d:"M18 13v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h6",key:"a6xqqp"}]],tv=ge("external-link",Tk);/**
|
|
854
|
+
* @license lucide-react v1.28.0 - ISC
|
|
855
|
+
*
|
|
856
|
+
* This source code is licensed under the ISC license.
|
|
857
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
858
|
+
*/const Ok=[["path",{d:"M10.733 5.076a10.744 10.744 0 0 1 11.205 6.575 1 1 0 0 1 0 .696 10.747 10.747 0 0 1-1.444 2.49",key:"ct8e1f"}],["path",{d:"M14.084 14.158a3 3 0 0 1-4.242-4.242",key:"151rxh"}],["path",{d:"M17.479 17.499a10.75 10.75 0 0 1-15.417-5.151 1 1 0 0 1 0-.696 10.75 10.75 0 0 1 4.446-5.143",key:"13bj9a"}],["path",{d:"m2 2 20 20",key:"1ooewy"}]],nv=ge("eye-off",Ok);/**
|
|
859
|
+
* @license lucide-react v1.28.0 - ISC
|
|
860
|
+
*
|
|
861
|
+
* This source code is licensed under the ISC license.
|
|
862
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
863
|
+
*/const Rk=[["path",{d:"M2.062 12.348a1 1 0 0 1 0-.696 10.75 10.75 0 0 1 19.876 0 1 1 0 0 1 0 .696 10.75 10.75 0 0 1-19.876 0",key:"1nclc0"}],["circle",{cx:"12",cy:"12",r:"3",key:"1v7zrd"}]],av=ge("eye",Rk);/**
|
|
864
|
+
* @license lucide-react v1.28.0 - ISC
|
|
865
|
+
*
|
|
866
|
+
* This source code is licensed under the ISC license.
|
|
867
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
868
|
+
*/const zk=[["path",{d:"M14.364 13.634a2 2 0 0 0-.506.854l-.837 2.87a.5.5 0 0 0 .62.62l2.87-.837a2 2 0 0 0 .854-.506l4.013-4.009a1 1 0 0 0-3.004-3.004z",key:"ukzhwg"}],["path",{d:"M14.487 7.858A1 1 0 0 1 14 7V2",key:"1klhew"}],["path",{d:"M20 19.645V20a2 2 0 0 1-2 2H6a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h8a2.4 2.4 0 0 1 1.704.706l2.516 2.516",key:"rxaxab"}],["path",{d:"M8 18h1",key:"13wk12"}]],Dk=ge("file-pen-line",zk);/**
|
|
869
|
+
* @license lucide-react v1.28.0 - ISC
|
|
870
|
+
*
|
|
871
|
+
* This source code is licensed under the ISC license.
|
|
872
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
873
|
+
*/const Uk=[["path",{d:"M6 22a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h8a2.4 2.4 0 0 1 1.704.706l3.588 3.588A2.4 2.4 0 0 1 20 8v12a2 2 0 0 1-2 2z",key:"1oefj6"}],["path",{d:"M14 2v5a1 1 0 0 0 1 1h5",key:"wfsgrz"}],["path",{d:"M8 13h2",key:"yr2amv"}],["path",{d:"M14 13h2",key:"un5t4a"}],["path",{d:"M8 17h2",key:"2yhykz"}],["path",{d:"M14 17h2",key:"10kma7"}]],Lk=ge("file-spreadsheet",Uk);/**
|
|
874
|
+
* @license lucide-react v1.28.0 - ISC
|
|
875
|
+
*
|
|
876
|
+
* This source code is licensed under the ISC license.
|
|
877
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
878
|
+
*/const Bk=[["path",{d:"M6 22a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h8a2.4 2.4 0 0 1 1.704.706l3.588 3.588A2.4 2.4 0 0 1 20 8v12a2 2 0 0 1-2 2z",key:"1oefj6"}],["path",{d:"M14 2v5a1 1 0 0 0 1 1h5",key:"wfsgrz"}],["path",{d:"M10 9H8",key:"b1mrlr"}],["path",{d:"M16 13H8",key:"t4e002"}],["path",{d:"M16 17H8",key:"z1uh3a"}]],Pf=ge("file-text",Bk);/**
|
|
879
|
+
* @license lucide-react v1.28.0 - ISC
|
|
880
|
+
*
|
|
881
|
+
* This source code is licensed under the ISC license.
|
|
882
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
883
|
+
*/const Hk=[["path",{d:"M15 2h-4a2 2 0 0 0-2 2v11a2 2 0 0 0 2 2h8a2 2 0 0 0 2-2V8",key:"14sh0y"}],["path",{d:"M16.706 2.706A2.4 2.4 0 0 0 15 2v5a1 1 0 0 0 1 1h5a2.4 2.4 0 0 0-.706-1.706z",key:"1970lx"}],["path",{d:"M5 7a2 2 0 0 0-2 2v11a2 2 0 0 0 2 2h8a2 2 0 0 0 1.732-1",key:"l4dndm"}]],qk=ge("files",Hk);/**
|
|
884
|
+
* @license lucide-react v1.28.0 - ISC
|
|
885
|
+
*
|
|
886
|
+
* This source code is licensed under the ISC license.
|
|
887
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
888
|
+
*/const Gk=[["rect",{width:"18",height:"18",x:"3",y:"3",rx:"2",key:"afitv7"}],["path",{d:"M7 3v18",key:"bbkbws"}],["path",{d:"M3 7.5h4",key:"zfgn84"}],["path",{d:"M3 12h18",key:"1i2n21"}],["path",{d:"M3 16.5h4",key:"1230mu"}],["path",{d:"M17 3v18",key:"in4fa5"}],["path",{d:"M17 7.5h4",key:"myr1c1"}],["path",{d:"M17 16.5h4",key:"go4c1d"}]],Ik=ge("film",Gk);/**
|
|
889
|
+
* @license lucide-react v1.28.0 - ISC
|
|
890
|
+
*
|
|
891
|
+
* This source code is licensed under the ISC license.
|
|
892
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
893
|
+
*/const Qk=[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M12 2a14.5 14.5 0 0 0 0 20 14.5 14.5 0 0 0 0-20",key:"13o1zl"}],["path",{d:"M2 12h20",key:"9i4pu4"}]],Kk=ge("globe",Qk);/**
|
|
894
|
+
* @license lucide-react v1.28.0 - ISC
|
|
895
|
+
*
|
|
896
|
+
* This source code is licensed under the ISC license.
|
|
897
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
898
|
+
*/const Vk=[["circle",{cx:"9",cy:"12",r:"1",key:"1vctgf"}],["circle",{cx:"9",cy:"5",r:"1",key:"hp0tcf"}],["circle",{cx:"9",cy:"19",r:"1",key:"fkjjf6"}],["circle",{cx:"15",cy:"12",r:"1",key:"1tmaij"}],["circle",{cx:"15",cy:"5",r:"1",key:"19l28e"}],["circle",{cx:"15",cy:"19",r:"1",key:"f4zoj3"}]],lv=ge("grip-vertical",Vk);/**
|
|
899
|
+
* @license lucide-react v1.28.0 - ISC
|
|
900
|
+
*
|
|
901
|
+
* This source code is licensed under the ISC license.
|
|
902
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
903
|
+
*/const Yk=[["path",{d:"M15 21v-8a1 1 0 0 0-1-1h-4a1 1 0 0 0-1 1v8",key:"5wwlr5"}],["path",{d:"M3 10a2 2 0 0 1 .709-1.528l7-6a2 2 0 0 1 2.582 0l7 6A2 2 0 0 1 21 10v9a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2z",key:"r6nss1"}]],$k=ge("house",Yk);/**
|
|
904
|
+
* @license lucide-react v1.28.0 - ISC
|
|
905
|
+
*
|
|
906
|
+
* This source code is licensed under the ISC license.
|
|
907
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
908
|
+
*/const Fk=[["rect",{width:"18",height:"18",x:"3",y:"3",rx:"2",ry:"2",key:"1m3agn"}],["circle",{cx:"9",cy:"9",r:"2",key:"af1f0g"}],["path",{d:"m21 15-3.086-3.086a2 2 0 0 0-2.828 0L6 21",key:"1xmnt7"}]],Jf=ge("image",Fk);/**
|
|
909
|
+
* @license lucide-react v1.28.0 - ISC
|
|
910
|
+
*
|
|
911
|
+
* This source code is licensed under the ISC license.
|
|
912
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
913
|
+
*/const Xk=[["path",{d:"m22 11-1.296-1.296a2.4 2.4 0 0 0-3.408 0L11 16",key:"9kzy35"}],["path",{d:"M4 8a2 2 0 0 0-2 2v10a2 2 0 0 0 2 2h10a2 2 0 0 0 2-2",key:"1t0f0t"}],["circle",{cx:"13",cy:"7",r:"1",fill:"currentColor",key:"1obus6"}],["rect",{x:"8",y:"2",width:"14",height:"14",rx:"2",key:"1gvhby"}]],Zk=ge("images",Xk);/**
|
|
914
|
+
* @license lucide-react v1.28.0 - ISC
|
|
915
|
+
*
|
|
916
|
+
* This source code is licensed under the ISC license.
|
|
917
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
918
|
+
*/const Pk=[["rect",{width:"7",height:"7",x:"3",y:"3",rx:"1",key:"1g98yp"}],["rect",{width:"7",height:"7",x:"14",y:"3",rx:"1",key:"6d4xhi"}],["rect",{width:"7",height:"7",x:"14",y:"14",rx:"1",key:"nxv5o0"}],["rect",{width:"7",height:"7",x:"3",y:"14",rx:"1",key:"1bb6yr"}]],Jk=ge("layout-grid",Pk);/**
|
|
919
|
+
* @license lucide-react v1.28.0 - ISC
|
|
920
|
+
*
|
|
921
|
+
* This source code is licensed under the ISC license.
|
|
922
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
923
|
+
*/const Wk=[["rect",{width:"18",height:"7",x:"3",y:"3",rx:"1",key:"f1a2em"}],["rect",{width:"9",height:"7",x:"3",y:"14",rx:"1",key:"jqznyg"}],["rect",{width:"5",height:"7",x:"16",y:"14",rx:"1",key:"q5h2i8"}]],e5=ge("layout-template",Wk);/**
|
|
924
|
+
* @license lucide-react v1.28.0 - ISC
|
|
925
|
+
*
|
|
926
|
+
* This source code is licensed under the ISC license.
|
|
927
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
928
|
+
*/const t5=[["rect",{width:"8",height:"18",x:"3",y:"3",rx:"1",key:"oynpb5"}],["path",{d:"M7 3v18",key:"bbkbws"}],["path",{d:"M20.4 18.9c.2.5-.1 1.1-.6 1.3l-1.9.7c-.5.2-1.1-.1-1.3-.6L11.1 5.1c-.2-.5.1-1.1.6-1.3l1.9-.7c.5-.2 1.1.1 1.3.6Z",key:"1qboyk"}]],n5=ge("library-big",t5);/**
|
|
929
|
+
* @license lucide-react v1.28.0 - ISC
|
|
930
|
+
*
|
|
931
|
+
* This source code is licensed under the ISC license.
|
|
932
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
933
|
+
*/const a5=[["path",{d:"M9 17H7A5 5 0 0 1 7 7h2",key:"8i5ue5"}],["path",{d:"M15 7h2a5 5 0 1 1 0 10h-2",key:"1b9ql8"}],["line",{x1:"8",x2:"16",y1:"12",y2:"12",key:"1jonct"}]],l5=ge("link-2",a5);/**
|
|
934
|
+
* @license lucide-react v1.28.0 - ISC
|
|
935
|
+
*
|
|
936
|
+
* This source code is licensed under the ISC license.
|
|
937
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
938
|
+
*/const i5=[["path",{d:"M10 13a5 5 0 0 0 7.54.54l3-3a5 5 0 0 0-7.07-7.07l-1.72 1.71",key:"1cjeqo"}],["path",{d:"M14 11a5 5 0 0 0-7.54-.54l-3 3a5 5 0 0 0 7.07 7.07l1.71-1.71",key:"19qd67"}]],s5=ge("link",i5);/**
|
|
939
|
+
* @license lucide-react v1.28.0 - ISC
|
|
940
|
+
*
|
|
941
|
+
* This source code is licensed under the ISC license.
|
|
942
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
943
|
+
*/const o5=[["path",{d:"M3 5h.01",key:"18ugdj"}],["path",{d:"M3 12h.01",key:"nlz23k"}],["path",{d:"M3 19h.01",key:"noohij"}],["path",{d:"M8 5h13",key:"1pao27"}],["path",{d:"M8 12h13",key:"1za7za"}],["path",{d:"M8 19h13",key:"m83p4d"}]],r5=ge("list",o5);/**
|
|
944
|
+
* @license lucide-react v1.28.0 - ISC
|
|
945
|
+
*
|
|
946
|
+
* This source code is licensed under the ISC license.
|
|
947
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
948
|
+
*/const c5=[["rect",{width:"18",height:"11",x:"3",y:"11",rx:"2",ry:"2",key:"1w4ew1"}],["path",{d:"M7 11V7a5 5 0 0 1 10 0v4",key:"fwvmzm"}]],u5=ge("lock",c5);/**
|
|
949
|
+
* @license lucide-react v1.28.0 - ISC
|
|
950
|
+
*
|
|
951
|
+
* This source code is licensed under the ISC license.
|
|
952
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
953
|
+
*/const d5=[["path",{d:"m16 17 5-5-5-5",key:"1bji2h"}],["path",{d:"M21 12H9",key:"dn1m92"}],["path",{d:"M9 21H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h4",key:"1uf3rs"}]],f5=ge("log-out",d5);/**
|
|
954
|
+
* @license lucide-react v1.28.0 - ISC
|
|
955
|
+
*
|
|
956
|
+
* This source code is licensed under the ISC license.
|
|
957
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
958
|
+
*/const h5=[["path",{d:"m22 7-8.991 5.727a2 2 0 0 1-2.009 0L2 7",key:"132q7q"}],["rect",{x:"2",y:"4",width:"20",height:"16",rx:"2",key:"izxlao"}]],p5=ge("mail",h5);/**
|
|
959
|
+
* @license lucide-react v1.28.0 - ISC
|
|
960
|
+
*
|
|
961
|
+
* This source code is licensed under the ISC license.
|
|
962
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
963
|
+
*/const m5=[["path",{d:"M20 10c0 4.993-5.539 10.193-7.399 11.799a1 1 0 0 1-1.202 0C9.539 20.193 4 14.993 4 10a8 8 0 0 1 16 0",key:"1r0f0z"}],["circle",{cx:"12",cy:"10",r:"3",key:"ilqhr7"}]],iv=ge("map-pin",m5);/**
|
|
964
|
+
* @license lucide-react v1.28.0 - ISC
|
|
965
|
+
*
|
|
966
|
+
* This source code is licensed under the ISC license.
|
|
967
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
968
|
+
*/const y5=[["path",{d:"M18 8c0 3.613-3.869 7.429-5.393 8.795a1 1 0 0 1-1.214 0C9.87 15.429 6 11.613 6 8a6 6 0 0 1 12 0",key:"11u0oz"}],["circle",{cx:"12",cy:"8",r:"2",key:"1822b1"}],["path",{d:"M8.714 14h-3.71a1 1 0 0 0-.948.683l-2.004 6A1 1 0 0 0 3 22h18a1 1 0 0 0 .948-1.316l-2-6a1 1 0 0 0-.949-.684h-3.712",key:"q8zwxj"}]],g5=ge("map-pinned",y5);/**
|
|
969
|
+
* @license lucide-react v1.28.0 - ISC
|
|
970
|
+
*
|
|
971
|
+
* This source code is licensed under the ISC license.
|
|
972
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
973
|
+
*/const b5=[["path",{d:"M5 12h14",key:"1ays0h"}]],v5=ge("minus",b5);/**
|
|
974
|
+
* @license lucide-react v1.28.0 - ISC
|
|
975
|
+
*
|
|
976
|
+
* This source code is licensed under the ISC license.
|
|
977
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
978
|
+
*/const x5=[["path",{d:"M14 4.1 12 6",key:"ita8i4"}],["path",{d:"m5.1 8-2.9-.8",key:"1go3kf"}],["path",{d:"m6 12-1.9 2",key:"mnht97"}],["path",{d:"M7.2 2.2 8 5.1",key:"1cfko1"}],["path",{d:"M9.037 9.69a.498.498 0 0 1 .653-.653l11 4.5a.5.5 0 0 1-.074.949l-4.349 1.041a1 1 0 0 0-.74.739l-1.04 4.35a.5.5 0 0 1-.95.074z",key:"s0h3yz"}]],_5=ge("mouse-pointer-click",x5);/**
|
|
979
|
+
* @license lucide-react v1.28.0 - ISC
|
|
980
|
+
*
|
|
981
|
+
* This source code is licensed under the ISC license.
|
|
982
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
983
|
+
*/const w5=[["path",{d:"M15 18h-5",key:"95g1m2"}],["path",{d:"M18 14h-8",key:"sponae"}],["path",{d:"M4 22h16a2 2 0 0 0 2-2V4a2 2 0 0 0-2-2H8a2 2 0 0 0-2 2v16a2 2 0 0 1-4 0v-9a2 2 0 0 1 2-2h2",key:"39pd36"}],["rect",{width:"8",height:"4",x:"10",y:"6",rx:"1",key:"aywv1n"}]],S5=ge("newspaper",w5);/**
|
|
984
|
+
* @license lucide-react v1.28.0 - ISC
|
|
985
|
+
*
|
|
986
|
+
* This source code is licensed under the ISC license.
|
|
987
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
988
|
+
*/const k5=[["path",{d:"M12 22a1 1 0 0 1 0-20 10 9 0 0 1 10 9 5 5 0 0 1-5 5h-2.25a1.75 1.75 0 0 0-1.4 2.8l.3.4a1.75 1.75 0 0 1-1.4 2.8z",key:"e79jfc"}],["circle",{cx:"13.5",cy:"6.5",r:".5",fill:"currentColor",key:"1okk4w"}],["circle",{cx:"17.5",cy:"10.5",r:".5",fill:"currentColor",key:"f64h9f"}],["circle",{cx:"6.5",cy:"12.5",r:".5",fill:"currentColor",key:"qy21gx"}],["circle",{cx:"8.5",cy:"7.5",r:".5",fill:"currentColor",key:"fotxhn"}]],E5=ge("palette",k5);/**
|
|
989
|
+
* @license lucide-react v1.28.0 - ISC
|
|
990
|
+
*
|
|
991
|
+
* This source code is licensed under the ISC license.
|
|
992
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
993
|
+
*/const j5=[["path",{d:"M21.174 6.812a1 1 0 0 0-3.986-3.987L3.842 16.174a2 2 0 0 0-.5.83l-1.321 4.352a.5.5 0 0 0 .623.622l4.353-1.32a2 2 0 0 0 .83-.497z",key:"1a8usu"}],["path",{d:"m15 5 4 4",key:"1mk7zo"}]],M5=ge("pencil",j5);/**
|
|
994
|
+
* @license lucide-react v1.28.0 - ISC
|
|
995
|
+
*
|
|
996
|
+
* This source code is licensed under the ISC license.
|
|
997
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
998
|
+
*/const C5=[["path",{d:"M13.832 16.568a1 1 0 0 0 1.213-.303l.355-.465A2 2 0 0 1 17 15h3a2 2 0 0 1 2 2v3a2 2 0 0 1-2 2A18 18 0 0 1 2 4a2 2 0 0 1 2-2h3a2 2 0 0 1 2 2v3a2 2 0 0 1-.8 1.6l-.468.351a1 1 0 0 0-.292 1.233 14 14 0 0 0 6.392 6.384",key:"9njp5v"}]],A5=ge("phone",C5);/**
|
|
999
|
+
* @license lucide-react v1.28.0 - ISC
|
|
1000
|
+
*
|
|
1001
|
+
* This source code is licensed under the ISC license.
|
|
1002
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
1003
|
+
*/const N5=[["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"}]],T5=ge("play",N5);/**
|
|
1004
|
+
* @license lucide-react v1.28.0 - ISC
|
|
1005
|
+
*
|
|
1006
|
+
* This source code is licensed under the ISC license.
|
|
1007
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
1008
|
+
*/const O5=[["path",{d:"M12 22v-5",key:"1ega77"}],["path",{d:"M15 8V2",key:"18g5xt"}],["path",{d:"M17 8a1 1 0 0 1 1 1v4a4 4 0 0 1-4 4h-4a4 4 0 0 1-4-4V9a1 1 0 0 1 1-1z",key:"1xoxul"}],["path",{d:"M9 8V2",key:"14iosj"}]],R5=ge("plug",O5);/**
|
|
1009
|
+
* @license lucide-react v1.28.0 - ISC
|
|
1010
|
+
*
|
|
1011
|
+
* This source code is licensed under the ISC license.
|
|
1012
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
1013
|
+
*/const z5=[["path",{d:"M5 12h14",key:"1ays0h"}],["path",{d:"M12 5v14",key:"s699le"}]],sv=ge("plus",z5);/**
|
|
1014
|
+
* @license lucide-react v1.28.0 - ISC
|
|
1015
|
+
*
|
|
1016
|
+
* This source code is licensed under the ISC license.
|
|
1017
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
1018
|
+
*/const D5=[["path",{d:"M12 2v10",key:"mnfbl"}],["path",{d:"M18.4 6.6a9 9 0 1 1-12.77.04",key:"obofu9"}]],U5=ge("power",D5);/**
|
|
1019
|
+
* @license lucide-react v1.28.0 - ISC
|
|
1020
|
+
*
|
|
1021
|
+
* This source code is licensed under the ISC license.
|
|
1022
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
1023
|
+
*/const L5=[["path",{d:"M2 3h20",key:"91anmk"}],["path",{d:"M21 3v11a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V3",key:"2k9sn8"}],["path",{d:"m7 21 5-5 5 5",key:"bip4we"}]],ov=ge("presentation",L5);/**
|
|
1024
|
+
* @license lucide-react v1.28.0 - ISC
|
|
1025
|
+
*
|
|
1026
|
+
* This source code is licensed under the ISC license.
|
|
1027
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
1028
|
+
*/const B5=[["path",{d:"m15 14 5-5-5-5",key:"12vg1m"}],["path",{d:"M20 9H9.5A5.5 5.5 0 0 0 4 14.5A5.5 5.5 0 0 0 9.5 20H13",key:"6uklza"}]],H5=ge("redo-2",B5);/**
|
|
1029
|
+
* @license lucide-react v1.28.0 - ISC
|
|
1030
|
+
*
|
|
1031
|
+
* This source code is licensed under the ISC license.
|
|
1032
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
1033
|
+
*/const q5=[["path",{d:"m15.194 13.707 3.814 1.86-1.86 3.814",key:"16shm9"}],["path",{d:"M16.47214 7.52786 A 5 10 0 1 0 13 21.79796",key:"1245p8"}],["path",{d:"M21.79796 11 A 10 5 0 1 0 19 15.57071",key:"1i40ks"}]],Wf=ge("rotate-3d",q5);/**
|
|
1034
|
+
* @license lucide-react v1.28.0 - ISC
|
|
1035
|
+
*
|
|
1036
|
+
* This source code is licensed under the ISC license.
|
|
1037
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
1038
|
+
*/const G5=[["path",{d:"m21 21-4.34-4.34",key:"14j7rj"}],["circle",{cx:"11",cy:"11",r:"8",key:"4ej97u"}]],rv=ge("search",G5);/**
|
|
1039
|
+
* @license lucide-react v1.28.0 - ISC
|
|
1040
|
+
*
|
|
1041
|
+
* This source code is licensed under the ISC license.
|
|
1042
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
1043
|
+
*/const I5=[["path",{d:"M9.671 4.136a2.34 2.34 0 0 1 4.659 0 2.34 2.34 0 0 0 3.319 1.915 2.34 2.34 0 0 1 2.33 4.033 2.34 2.34 0 0 0 0 3.831 2.34 2.34 0 0 1-2.33 4.033 2.34 2.34 0 0 0-3.319 1.915 2.34 2.34 0 0 1-4.659 0 2.34 2.34 0 0 0-3.32-1.915 2.34 2.34 0 0 1-2.33-4.033 2.34 2.34 0 0 0 0-3.831A2.34 2.34 0 0 1 6.35 6.051a2.34 2.34 0 0 0 3.319-1.915",key:"1i5ecw"}],["circle",{cx:"12",cy:"12",r:"3",key:"1v7zrd"}]],Q5=ge("settings",I5);/**
|
|
1044
|
+
* @license lucide-react v1.28.0 - ISC
|
|
1045
|
+
*
|
|
1046
|
+
* This source code is licensed under the ISC license.
|
|
1047
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
1048
|
+
*/const K5=[["path",{d:"M12 2v13",key:"1km8f5"}],["path",{d:"m16 6-4-4-4 4",key:"13yo43"}],["path",{d:"M4 12v8a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2v-8",key:"1b2hhj"}]],V5=ge("share",K5);/**
|
|
1049
|
+
* @license lucide-react v1.28.0 - ISC
|
|
1050
|
+
*
|
|
1051
|
+
* This source code is licensed under the ISC license.
|
|
1052
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
1053
|
+
*/const Y5=[["path",{d:"M11.017 2.814a1 1 0 0 1 1.966 0l1.051 5.558a2 2 0 0 0 1.594 1.594l5.558 1.051a1 1 0 0 1 0 1.966l-5.558 1.051a2 2 0 0 0-1.594 1.594l-1.051 5.558a1 1 0 0 1-1.966 0l-1.051-5.558a2 2 0 0 0-1.594-1.594l-5.558-1.051a1 1 0 0 1 0-1.966l5.558-1.051a2 2 0 0 0 1.594-1.594z",key:"1s2grr"}],["path",{d:"M20 2v4",key:"1rf3ol"}],["path",{d:"M22 4h-4",key:"gwowj6"}],["circle",{cx:"4",cy:"20",r:"2",key:"6kqj1y"}]],$5=ge("sparkles",Y5);/**
|
|
1054
|
+
* @license lucide-react v1.28.0 - ISC
|
|
1055
|
+
*
|
|
1056
|
+
* This source code is licensed under the ISC license.
|
|
1057
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
1058
|
+
*/const F5=[["path",{d:"M10 11v6",key:"nco0om"}],["path",{d:"M14 11v6",key:"outv1u"}],["path",{d:"M19 6v14a2 2 0 0 1-2 2H7a2 2 0 0 1-2-2V6",key:"miytrc"}],["path",{d:"M3 6h18",key:"d0wm0j"}],["path",{d:"M8 6V4a2 2 0 0 1 2-2h4a2 2 0 0 1 2 2v2",key:"e791ji"}]],cv=ge("trash-2",F5);/**
|
|
1059
|
+
* @license lucide-react v1.28.0 - ISC
|
|
1060
|
+
*
|
|
1061
|
+
* This source code is licensed under the ISC license.
|
|
1062
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
1063
|
+
*/const X5=[["path",{d:"M12 4v16",key:"1654pz"}],["path",{d:"M4 7V5a1 1 0 0 1 1-1h14a1 1 0 0 1 1 1v2",key:"e0r10z"}],["path",{d:"M9 20h6",key:"s66wpe"}]],Z5=ge("type",X5);/**
|
|
1064
|
+
* @license lucide-react v1.28.0 - ISC
|
|
1065
|
+
*
|
|
1066
|
+
* This source code is licensed under the ISC license.
|
|
1067
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
1068
|
+
*/const P5=[["path",{d:"M9 14 4 9l5-5",key:"102s5s"}],["path",{d:"M4 9h10.5a5.5 5.5 0 0 1 5.5 5.5a5.5 5.5 0 0 1-5.5 5.5H11",key:"f3b9sd"}]],J5=ge("undo-2",P5);/**
|
|
1069
|
+
* @license lucide-react v1.28.0 - ISC
|
|
1070
|
+
*
|
|
1071
|
+
* This source code is licensed under the ISC license.
|
|
1072
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
1073
|
+
*/const W5=[["path",{d:"M12 3v12",key:"1x0j5s"}],["path",{d:"m17 8-5-5-5 5",key:"7q97r8"}],["path",{d:"M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4",key:"ih7n3h"}]],uv=ge("upload",W5);/**
|
|
1074
|
+
* @license lucide-react v1.28.0 - ISC
|
|
1075
|
+
*
|
|
1076
|
+
* This source code is licensed under the ISC license.
|
|
1077
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
1078
|
+
*/const e4=[["path",{d:"M16 21v-2a4 4 0 0 0-4-4H6a4 4 0 0 0-4 4v2",key:"1yyitq"}],["circle",{cx:"9",cy:"7",r:"4",key:"nufk8"}],["line",{x1:"19",x2:"19",y1:"8",y2:"14",key:"1bvyxn"}],["line",{x1:"22",x2:"16",y1:"11",y2:"11",key:"1shjgl"}]],t4=ge("user-plus",e4);/**
|
|
1079
|
+
* @license lucide-react v1.28.0 - ISC
|
|
1080
|
+
*
|
|
1081
|
+
* This source code is licensed under the ISC license.
|
|
1082
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
1083
|
+
*/const n4=[["path",{d:"M19 21v-2a4 4 0 0 0-4-4H9a4 4 0 0 0-4 4v2",key:"975kel"}],["circle",{cx:"12",cy:"7",r:"4",key:"17ys0d"}]],a4=ge("user",n4);/**
|
|
1084
|
+
* @license lucide-react v1.28.0 - ISC
|
|
1085
|
+
*
|
|
1086
|
+
* This source code is licensed under the ISC license.
|
|
1087
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
1088
|
+
*/const l4=[["path",{d:"M16 21v-2a4 4 0 0 0-4-4H6a4 4 0 0 0-4 4v2",key:"1yyitq"}],["path",{d:"M16 3.128a4 4 0 0 1 0 7.744",key:"16gr8j"}],["path",{d:"M22 21v-2a4 4 0 0 0-3-3.87",key:"kshegd"}],["circle",{cx:"9",cy:"7",r:"4",key:"nufk8"}]],i4=ge("users",l4);/**
|
|
1089
|
+
* @license lucide-react v1.28.0 - ISC
|
|
1090
|
+
*
|
|
1091
|
+
* This source code is licensed under the ISC license.
|
|
1092
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
1093
|
+
*/const s4=[["path",{d:"m16 13 5.223 3.482a.5.5 0 0 0 .777-.416V7.87a.5.5 0 0 0-.752-.432L16 10.5",key:"ftymec"}],["rect",{x:"2",y:"6",width:"14",height:"12",rx:"2",key:"158x01"}]],dv=ge("video",s4);/**
|
|
1094
|
+
* @license lucide-react v1.28.0 - ISC
|
|
1095
|
+
*
|
|
1096
|
+
* This source code is licensed under the ISC license.
|
|
1097
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
1098
|
+
*/const o4=[["path",{d:"M18 6 6 18",key:"1bl5f8"}],["path",{d:"m6 6 12 12",key:"d8bk6v"}]],fv=ge("x",o4),eh="flex flex-col gap-3.5 pt-1",Qn="flex flex-col gap-1",r4="flex items-center justify-between gap-2.5",va="text-[length:calc(11*var(--content))] font-medium text-ink-4 pl-0.5",th="m-0 text-caption leading-[1.4] text-danger",dc="bg-[repeating-linear-gradient(135deg,rgba(20,18,13,0.05)_0_1px,transparent_1px_9px)]",ot="appearance-none cursor-pointer border-0 bg-transparent p-0 m-0 outline-none",_o="flex w-full items-stretch rounded-[calc(8*var(--content))] border border-line bg-white transition-[border-color,box-shadow] duration-[120ms] focus-within:border-accent focus-within:shadow-[0_0_0_3px_rgba(15,42,34,0.07)]",ss="min-w-0 flex-1 appearance-none border-0 bg-transparent px-2.75 py-2.25 text-[length:calc(13.5*var(--content))] text-ink outline-none placeholder:text-ink-4",lf="flex items-center text-[length:calc(12.5*var(--content))] text-ink-4",c4=ye(ot,"min-w-0 flex-1 bg-transparent text-ink outline-none placeholder:text-ink-4");function wo(n,l="Item"){const s=(n??"").trim().split(/\s+/).filter(Boolean),o=s.length>0?s[s.length-1]:l,u=u4(o);return u.charAt(0).toUpperCase()+u.slice(1)}function u4(n){return/[^aeiou]ies$/i.test(n)?n.slice(0,-3)+"y":/(?:s|x|z|ch|sh)es$/i.test(n)?n.slice(0,-2):/[^s]s$/i.test(n)?n.slice(0,-1):n}function d4(n,l){const s="font-mono text-[length:calc(10.5*var(--content))] text-ink-4 [font-feature-settings:'tnum'] shrink-0";return l==null?s:n>l?ye(s,"text-danger"):n>=l*.9?ye(s,"text-[#7a5a14]"):s}function hv({label:n,count:l,max:s,right:o,revealed:u=!0}){return f.jsxs("div",{className:r4,children:[f.jsx("span",{className:va,children:n}),f.jsx("div",{className:"flex items-center gap-1.5",children:o??(s!=null&&l!=null&&f.jsxs("span",{"aria-hidden":!u,className:ye(d4(l,s),"transition-[opacity,transform] duration-150 ease-out motion-reduce:transition-none",u?"opacity-100 translate-y-0":"opacity-0 translate-y-1"),children:[l," / ",s]}))})]})}function nh({children:n}){return f.jsx("span",{className:va,children:n})}function Pr({value:n,onChange:l,label:s,max:o,count:u,headerRight:d,placeholder:h,multiline:p=!1,rows:y=3,inputMode:g,maxLength:x,spellCheck:v,bare:E=!1,className:M,ariaLabel:N,id:A}){const[j,O]=_.useState(!1),z=ee=>l(ee.target.value),D=()=>O(!0),Y=()=>O(!1);if(E)return f.jsx("input",{id:A,className:ye(c4,M),value:n,placeholder:h,inputMode:g,maxLength:x,spellCheck:v,"aria-label":N,onChange:z});const W=s!=null||d!=null||o!=null;return f.jsxs("div",{className:Qn,children:[W&&f.jsx(hv,{label:s??"",count:u??n.length,max:o,right:d,revealed:j}),f.jsx("div",{className:_o,children:p?f.jsx("textarea",{id:A,className:ye(ss,"min-h-[calc(76*var(--content))] resize-none leading-[1.5]",M),rows:y,value:n,placeholder:h,maxLength:x,spellCheck:v,"aria-label":N,onChange:z,onFocus:D,onBlur:Y}):f.jsx("input",{id:A,className:ye(ss,M),value:n,placeholder:h,inputMode:g,maxLength:x,spellCheck:v,"aria-label":N,onChange:z,onFocus:D,onBlur:Y})})]})}function It(n,l,s=1.5){const o=n;return function({size:d=l}={}){return f.jsx(o,{size:d,strokeWidth:s,style:{width:`calc(${d} * var(--content))`,height:`calc(${d} * var(--content))`}})}}const ze={swap:It(FS,13),crop:It(jk,13),eye:It(av,13),eyeOff:It(nv,13),trash:It(cv,11),plus:It(sv,14),up:It(uv,15),link:It(s5,13),play:({size:n=20}={})=>f.jsx(T5,{size:n,strokeWidth:0,fill:"currentColor",style:{width:`calc(${n} * var(--content))`,height:`calc(${n} * var(--content))`}}),tour:It(Wf,18),search:It(rv,14),x:It(fv,15),check:It(ev,13),minus:It(v5,16),external:It(tv,11),grip:It(lv,13,1.8)},f4="flex max-h-full w-full flex-col overflow-hidden rounded-[14px] bg-canvas shadow-[0_24px_70px_-24px_rgba(20,18,13,0.5),0_2px_0_rgba(20,18,13,0.04)]",pv="flex flex-shrink-0 items-center gap-[14px] border-b border-line-soft px-[18px] py-4",mv="mr-auto flex min-w-0 flex-col gap-0.5",yv="m-0 text-[16px] font-semibold tracking-[-0.01em]",h4="text-[12px] text-ink-3",gv=ye(ot,"grid size-8 flex-shrink-0 place-items-center rounded-[8px] text-ink-3 hover:bg-[#f1f0ea] hover:text-ink"),bv="flex flex-shrink-0 items-center justify-between gap-3 border-t border-line-soft px-[18px] py-[13px]",vv="ml-auto flex gap-2",xv=ye(ot,"inline-flex h-9 items-center gap-1.5 rounded-[9px] border border-transparent px-4 text-[13px] font-semibold"),_v=ye(xv,"border-line bg-white text-ink hover:bg-[#faf9f6]"),ah=ye(xv,"border-honey-2 bg-honey text-honey-ink hover:bg-honey-2 disabled:cursor-default disabled:opacity-45"),p4=ye(ot,"inline-flex h-9 items-center px-1 font-medium text-ink-2 hover:text-ink"),Wg="flex flex-shrink-0 gap-2.5 px-[18px] pb-3 pt-[14px]",eb="flex h-[38px] flex-1 items-center gap-2 rounded-[9px] border border-line bg-white px-3 transition-[border-color] duration-[120ms] focus-within:border-accent",tb="grid flex-shrink-0 place-items-center text-ink-3",nb="flex-1 border-0 bg-transparent text-[13.5px] text-ink",m4="min-h-0 flex-1 overflow-y-auto px-[18px] pb-[18px] pt-0.5",y4="grid grid-cols-4 gap-x-3 gap-y-[14px]",g4="col-span-full py-12 text-center text-[13px] text-ink-3",b4=ye(ot,"group/cell flex flex-col gap-1.5 text-left"),v4="flex h-[120px] items-center justify-center",x4="relative mx-auto w-fit max-w-full overflow-hidden rounded-[9px] border border-line transition-[box-shadow,border-color] duration-[120ms] group-hover/cell:border-ink-4 group-data-[selected]/cell:border-accent group-data-[selected]/cell:shadow-[0_0_0_3px_rgba(15,42,34,0.18)]",ab="block h-auto max-h-[120px] w-auto max-w-full",_4="absolute right-1.5 top-1.5 grid size-[22px] place-items-center rounded-full bg-accent text-white shadow-[0_2px_6px_rgba(0,0,0,0.25)]",w4="relative grid h-[120px] w-[160px] place-items-center bg-[#e6e3da] text-ink-3",S4="block w-full truncate text-center text-[11.5px] leading-[1.35] text-ink-2",k4="absolute bottom-1.5 left-1.5 rounded-full bg-[rgba(15,18,9,0.72)] px-1.5 py-0.5 text-[10.5px] font-semibold tabular-nums text-white",E4=ye(ot,"group/up flex h-[120px] w-full flex-col items-center justify-center gap-[7px] self-start rounded-[9px] border-[1.5px] border-dashed border-ink-4 bg-[#fafaf8] text-ink-3 hover:border-accent hover:bg-white hover:text-accent"),j4="grid size-[38px] place-items-center rounded-full border border-line bg-white group-hover/up:border-accent",M4="text-[12px] font-semibold",C4="flex flex-shrink-0 gap-0.5 rounded-[9px] bg-[#f1f0ea] p-[3px]",A4=ye(ot,"inline-flex h-8 items-center rounded-[7px] px-[13px] text-[12.5px] font-semibold text-ink-3");function N4(n,l=!1){return ye(A4,n&&"bg-white text-ink shadow-[0_1px_3px_rgba(20,18,13,0.1)]",l&&"opacity-40 cursor-not-allowed")}var lh=x0();function T4(...n){return $f(Kf(n))}const wv=1e3;let O4=0;const ol=[];let Sv="",kv="";function R4(){if(ol.length!==1||typeof document>"u")return;const n=document.body;Sv=n.style.overflow,kv=n.style.paddingRight;const l=window.innerWidth-document.documentElement.clientWidth;n.style.overflow="hidden",l>0&&(n.style.paddingRight=`${l}px`)}function z4(){ol.length===0&&(typeof document>"u"||(document.body.style.overflow=Sv,document.body.style.paddingRight=kv))}function D4(){const n=++O4;return ol.push(n),R4(),n}function lb(n){const l=ol.indexOf(n);l!==-1&&ol.splice(l,1),z4()}function U4(n){const l=ol.indexOf(n);return wv+(l===-1?0:l)*10}function ib(n){return ol[ol.length-1]===n}const L4="(prefers-reduced-motion: reduce)";function B4(){const[n,l]=_.useState(!1);return _.useEffect(()=>{if(typeof window>"u"||!window.matchMedia)return;const s=window.matchMedia(L4);l(s.matches);const o=u=>l(u.matches);return s.addEventListener("change",o),()=>s.removeEventListener("change",o)},[]),n}const H4={sm:"max-w-[calc(420*var(--frame))]",md:"max-w-[calc(520*var(--frame))]",lg:"max-w-[calc(800*var(--frame))]",xl:"max-w-[calc(1240*var(--frame))]",full:"max-w-[calc(100vw-80px)]"},q4='a[href],button:not([disabled]),textarea:not([disabled]),input:not([disabled]),select:not([disabled]),[tabindex]:not([tabindex="-1"])';function G4({open:n,onClose:l,className:s,size:o,closeOnBackdrop:u=!0,closeOnEsc:d=!0,labelledBy:h,ariaLabel:p,children:y}){const[g,x]=_.useState("closed"),v=_.useRef(null),E=_.useRef(null),M=_.useRef(null),[N,A]=_.useState(1e3),j=B4(),[O,z]=_.useState(y);n&&O!==y&&z(y),_.useEffect(()=>{n&&g==="closed"?x("open"):!n&&g==="open"&&x(j?"closed":"closing")},[n,g,j]),_.useEffect(()=>{var W;if(g==="open"&&v.current===null){M.current=document.activeElement??null;const ee=D4();v.current=ee,A(U4(ee)),(W=E.current)==null||W.focus()}},[g]),_.useEffect(()=>{var W,ee;g==="closed"&&v.current!==null&&(lb(v.current),v.current=null,(ee=(W=M.current)==null?void 0:W.focus)==null||ee.call(W),M.current=null)},[g]),_.useEffect(()=>()=>{v.current!==null&&(lb(v.current),v.current=null)},[]),_.useEffect(()=>{if(g!=="closing")return;const W=setTimeout(()=>x("closed"),400);return()=>clearTimeout(W)},[g]),_.useEffect(()=>{if(g!=="open"||!d)return;const W=ee=>{ee.key==="Escape"&&(v.current===null||!ib(v.current)||(ee.stopPropagation(),l()))};return document.addEventListener("keydown",W,!0),()=>document.removeEventListener("keydown",W,!0)},[g,d,l]),_.useEffect(()=>{if(g!=="open")return;const W=ee=>{if(ee.key!=="Tab"||v.current===null||!ib(v.current))return;const ae=E.current;if(!ae)return;const U=ae.querySelectorAll(q4);if(U.length===0){ee.preventDefault();return}const re=U[0],de=U[U.length-1];ee.shiftKey&&document.activeElement===re?(ee.preventDefault(),de==null||de.focus()):!ee.shiftKey&&document.activeElement===de&&(ee.preventDefault(),re==null||re.focus())};return document.addEventListener("keydown",W,!0),()=>document.removeEventListener("keydown",W,!0)},[g]);const D=_.useCallback(W=>{W.target===W.currentTarget&&g==="closing"&&x("closed")},[g]);if(g==="closed"||typeof document>"u")return null;const Y=g==="closing"?"closing":"open";return lh.createPortal(f.jsx("div",{className:"hp-modal-backdrop","data-state":Y,inert:Y==="closing",style:{zIndex:N},onMouseDown:u?l:void 0,children:f.jsx("div",{ref:E,className:T4("hp-modal-panel",o?H4[o]:void 0,s),"data-state":Y,role:"dialog","aria-modal":"true","aria-labelledby":h,"aria-label":p,tabIndex:-1,onMouseDown:W=>W.stopPropagation(),onAnimationEnd:D,children:n?y:O})}),document.body)}const I4={page:"max-w-[920px]",pick:"max-w-[700px]",crop:"max-w-[680px]"};function Ev({open:n=!0,variant:l,onClose:s,children:o}){return f.jsx(G4,{open:n,onClose:s,className:ye(f4,I4[l]),children:o})}const cn={Shell:Ev,head:pv,titles:mv,title:yv,subtitle:h4,close:gv,CloseIcon:ze.x,foot:bv,actions:vv,buttonGhost:_v,buttonPrimary:ah,buttonLink:p4,ZoomOutIcon:ze.minus,ZoomInIcon:ze.plus},Q4=new Set(["text","number","select","url"]);function sb(n){return Q4.has(n.type)?n.type!=="text"||n.size===void 0||n.size==="short":!1}function jv(n){const l=[];for(let s=0;s<n.length;s++){const o=n[s+1];sb(n[s])&&o!==void 0&&sb(o)?(l.push({kind:"pair",indices:[s,s+1]}),s++):l.push({kind:"single",index:s})}return l}function Mv({items:n,rows:l}){return f.jsx("div",{className:eh,children:l.map(s=>s.kind==="pair"?f.jsxs("div",{className:"grid grid-cols-2 gap-2",children:[n[s.indices[0]],n[s.indices[1]]]},`p${s.indices[0]}`):f.jsx("div",{children:n[s.index]},`s${s.index}`))})}function Jr(n){var d;const l=n.crop,s=l!=null&&l.aspect&&l.aspect>0?l.aspect:16/10,o=(d=l==null?void 0:l.mobile)==null?void 0:d.aspect,u=o&&o>0&&Math.abs(o-s)>1e-4?o:void 0;return{mode:(l==null?void 0:l.mode)==="free"?"free":"locked",aspect:s,aspectLabel:l==null?void 0:l.aspectLabel,mobileAspect:u}}function K4(n,l){if(!n||!l)return{nx:0,ny:0,nw:1,nh:1};const s=Math.min(1,l/n),o=Math.min(1,n/l);return{nx:(1-s)/2,ny:(1-o)/2,nw:s,nh:o}}function Cv(n,l,s){return n==="free"?{nx:0,ny:0,nw:1,nh:1}:K4(l,s)}function ob(n,l,s){const o=n.nx+n.nw/2,u=n.ny+n.nh/2;if(!l||!s)return{...n};const d=l/s;let h=n.nw,p=h/d;return p>n.nh&&(p=n.nh,h=p*d),{nx:o-h/2,ny:u-p/2,nw:h,nh:p}}function Av(n){const l=s=>Math.round(s*1e4)/1e4;return l(n.nx)===0&&l(n.ny)===0&&l(n.nw)===1&&l(n.nh)===1}function V4(n,l,s,o){const u=n==null?void 0:n.rect;return u&&u.nw&&u.nh?{nx:u.nx,ny:u.ny,nw:u.nw,nh:u.nh}:Cv(l,s,o)}const Xa=52,Y4=1,$4=6,F4=.94,Rt=(n,l,s)=>s<l?l:Math.max(l,Math.min(s,n));function Yr(n,l,s,o,u,d,h){n=Math.max(Xa,n);const p=u>0?h.r-s:s-h.l;n=Math.min(n,p);let y=n/l;const g=d>0?h.b-o:o-h.t;return y>g&&(y=g,n=y*l),{w:Math.max(Xa,n),h:Math.max(Xa,n/l)}}function X4({src:n,mode:l,aspect:s,seed:o}){const u=_.useRef(null),[,d]=_.useReducer(L=>L+1,0),h=_.useRef(null),p=_.useRef({w:0,h:0}),y=_.useRef({z:1,icx:0,icy:0}),g=_.useRef({x:0,y:0,w:0,h:0}),x=_.useRef(!1),v=_.useRef(o??null),[E,M]=_.useState(null),N=()=>{const L=h.current,G=p.current;if(!L||!G.w)return{w:0,h:0};const F=Math.min(G.w/L.w,G.h/L.h)*F4;return{w:L.w*F,h:L.h*F}},A=()=>{const L=N(),G=y.current,F=L.w*G.z,w=L.h*G.z;return{l:G.icx-F/2,t:G.icy-w/2,r:G.icx+F/2,b:G.icy+w/2,w:F,h:w}},j=()=>{const L=A(),G=p.current;return{l:Math.max(L.l,0),t:Math.max(L.t,0),r:Math.min(L.r,G.w),b:Math.min(L.b,G.h)}},O=()=>{const L=A(),G=g.current,F=y.current,w=L.w/2,Z=L.h/2;L.w>=G.w&&(F.icx=Rt(F.icx,G.x+G.w-w,G.x+w)),L.h>=G.h&&(F.icy=Rt(F.icy,G.y+G.h-Z,G.y+Z))},z=()=>{const L=g.current,G=j(),F=G.r-G.l,w=G.b-G.t;if(l==="locked"){let Z=Math.min(L.w,F),ue=Z/s;ue>w&&(ue=w,Z=ue*s),L.w=Z,L.h=ue}else L.w=Math.min(L.w,F),L.h=Math.min(L.h,w);L.x=Rt(L.x,G.l,G.r-L.w),L.y=Rt(L.y,G.t,G.b-L.h)},D=()=>{z(),O(),z()},Y=L=>{const G=p.current;if(!G.w||!h.current)return;y.current={z:1,icx:G.w/2,icy:G.h/2};const F=A(),w=h.current.w/h.current.h,Z=L?V4(v.current,l,w,s):Cv(l,w,s);g.current={x:F.l+Z.nx*F.w,y:F.t+Z.ny*F.h,w:Z.nw*F.w,h:Z.nh*F.h},D(),x.current=!0,d()};_.useEffect(()=>{x.current=!1,h.current=null,d();const L=new Image;L.onload=()=>{h.current={w:L.naturalWidth||1,h:L.naturalHeight||1},Y(!0)},L.src=n},[n]),_.useEffect(()=>{v.current=o??null},[o]),_.useEffect(()=>{h.current&&Y(!1)},[l,s]),_.useLayoutEffect(()=>{const L=u.current;if(!L)return;const G=()=>{const w=L.getBoundingClientRect(),Z=p.current.w;p.current={w:w.width,h:w.height},!Z&&h.current?Y(!0):Z&&(D(),d())};G();const F=new ResizeObserver(G);return F.observe(L),()=>F.disconnect()},[]);const W=L=>{const G=u.current.getBoundingClientRect();return{x:L.clientX-G.left,y:L.clientY-G.top}},ee=L=>{var ue,te;if(L.button)return;L.stopPropagation(),(te=(ue=L.currentTarget).setPointerCapture)==null||te.call(ue,L.pointerId),M("move");const G=W(L),F={...g.current},w=P=>{const k=W(P),I=j(),$=g.current;$.x=Rt(F.x+(k.x-G.x),I.l,I.r-$.w),$.y=Rt(F.y+(k.y-G.y),I.t,I.b-$.h),d()},Z=()=>{window.removeEventListener("pointermove",w),window.removeEventListener("pointerup",Z),window.removeEventListener("pointercancel",Z),M(null)};window.addEventListener("pointermove",w),window.addEventListener("pointerup",Z),window.addEventListener("pointercancel",Z)},ae=L=>G=>{var P,k;if(G.button)return;G.stopPropagation(),(k=(P=G.currentTarget).setPointerCapture)==null||k.call(P,G.pointerId),M(L);const F=g.current,w={l:F.x,t:F.y,r:F.x+F.w,b:F.y+F.h},Z=W(G),ue=I=>{const $=W(I),T=j(),B=$.x-Z.x,q=$.y-Z.y;let V=w.l,me=w.t,he=w.r,ke=w.b;if(l==="free")L.includes("w")&&(V=Rt(w.l+B,T.l,he-Xa)),L.includes("e")&&(he=Rt(w.r+B,V+Xa,T.r)),L.includes("n")&&(me=Rt(w.t+q,T.t,ke-Xa)),L.includes("s")&&(ke=Rt(w.b+q,me+Xa,T.b));else{const Ae=s;if(L==="se"){const Ue=Yr(w.r+B-w.l,Ae,w.l,w.t,1,1,T);V=w.l,me=w.t,he=V+Ue.w,ke=me+Ue.h}else if(L==="nw"){const Ue=Yr(w.r-(w.l+B),Ae,w.r,w.b,-1,-1,T);he=w.r,ke=w.b,V=he-Ue.w,me=ke-Ue.h}else if(L==="ne"){const Ue=Yr(w.r+B-w.l,Ae,w.l,w.b,1,-1,T);V=w.l,ke=w.b,he=V+Ue.w,me=ke-Ue.h}else if(L==="sw"){const Ue=Yr(w.r-(w.l+B),Ae,w.r,w.t,-1,1,T);he=w.r,me=w.t,V=he-Ue.w,ke=me+Ue.h}else{const Ue=(w.l+w.r)/2,nt=(w.t+w.b)/2;let Ve=F.w,Oe=F.h;L==="e"?Ve=(w.r+B-Ue)*2:L==="w"?Ve=(Ue-(w.l+B))*2:L==="s"?(Oe=(w.b+q-nt)*2,Ve=Oe*Ae):L==="n"&&(Oe=(nt-(w.t+q))*2,Ve=Oe*Ae),Ve=Math.max(Xa,Ve),Oe=Ve/Ae,Ve=Math.min(Ve,T.r-T.l),Oe=Ve/Ae,Oe>T.b-T.t&&(Oe=T.b-T.t,Ve=Oe*Ae),V=Rt(Ue-Ve/2,T.l,T.r-Ve),me=Rt(nt-Oe/2,T.t,T.b-Oe),he=V+Ve,ke=me+Oe}}g.current={x:V,y:me,w:he-V,h:ke-me},d()},te=()=>{window.removeEventListener("pointermove",ue),window.removeEventListener("pointerup",te),window.removeEventListener("pointercancel",te),M(null)};window.addEventListener("pointermove",ue),window.addEventListener("pointerup",te),window.addEventListener("pointercancel",te)},U=(L,G,F)=>{const w=y.current;L=Rt(L,Y4,$4);const Z=L/w.z;w.icx=G+(w.icx-G)*Z,w.icy=F+(w.icy-F)*Z,w.z=L,D(),d()},re=L=>{const G=p.current;U(y.current.z*L,G.w/2,G.h/2)},de=_.useRef(()=>{});de.current=L=>{L.preventDefault();const G=p.current,F=Math.exp(-L.deltaY*.0015*(L.ctrlKey?2.6:1));U(y.current.z*F,G.w/2,G.h/2)},_.useEffect(()=>{const L=u.current;if(!L)return;const G=F=>de.current(F);return L.addEventListener("wheel",G,{passive:!1}),()=>L.removeEventListener("wheel",G)},[]);const ce=()=>Y(!1),ie=()=>{const L=A(),G=g.current;return L.w?{nx:Rt((G.x-L.l)/L.w,0,1),ny:Rt((G.y-L.t)/L.h,0,1),nw:Rt(G.w/L.w,0,1),nh:Rt(G.h/L.h,0,1)}:{nx:0,ny:0,nw:1,nh:1}};return{stageRef:u,ready:x.current,activeHandle:E,imgRect:A,box:g.current,view:y.current,onBoxDown:ee,onHandleDown:ae,zoomBy:re,reset:ce,cropValue:ie,natAspect:h.current?h.current.w/h.current.h:null}}function Z4({chrome:n,pct:l,onZoomOut:s,onZoomIn:o,resetSlot:u,children:d}){return f.jsxs("div",{className:n.foot,children:[f.jsxs("div",{className:"flex items-center gap-3",children:[u,f.jsxs("div",{className:"flex h-9 items-center overflow-hidden rounded-[9px] border border-line",children:[f.jsx("button",{type:"button",className:"grid size-9 place-items-center text-ink-2 hover:bg-[#f1f0ea] hover:text-ink",onClick:s,"aria-label":"Zoom out",children:f.jsx(n.ZoomOutIcon,{})}),f.jsx("span",{className:"grid h-9 min-w-[54px] place-items-center border-x border-line font-mono text-[12px] text-ink-2",children:l}),f.jsx("button",{type:"button",className:"grid size-9 place-items-center text-ink-2 hover:bg-[#f1f0ea] hover:text-ink",onClick:o,"aria-label":"Zoom in",children:f.jsx(n.ZoomInIcon,{})})]})]}),f.jsx("div",{className:n.actions,children:d})]})}const P4=["n","s","e","w"],J4=["nw","ne","sw","se"];function W4({cr:n,mode:l,src:s,stageClassName:o}){const u=n.imgRect(),d=n.box,h=n.activeHandle!==null;return f.jsx("div",{className:`we-cs-stage ${o}`,ref:n.stageRef,children:n.ready&&f.jsxs(f.Fragment,{children:[f.jsx("img",{className:"we-cs-img",src:s,alt:"",draggable:!1,style:{left:u.l,top:u.t,width:u.w,height:u.h}}),f.jsxs("div",{className:`we-cs-box${h?" live":""}`,"data-mode":l,"data-crop-box":!0,style:{left:d.x,top:d.y,width:d.w,height:d.h},onPointerDown:n.onBoxDown,children:[f.jsx("div",{className:"we-cs-ring"}),f.jsxs("div",{className:"we-cs-thirds",children:[f.jsx("i",{}),f.jsx("i",{}),f.jsx("i",{}),f.jsx("i",{})]}),P4.map(p=>f.jsx("div",{"data-crop-handle":p,className:`we-cs-h edge ${p}`,onPointerDown:n.onHandleDown(p)},p)),J4.map(p=>f.jsx("div",{"data-crop-handle":p,className:`we-cs-h corner ${p}`,onPointerDown:n.onHandleDown(p)},p))]})]})})}const eE=_.forwardRef(function({chrome:l,src:s,mode:o,aspect:u,seed:d,stageClassName:h="h-[412px]",footerActions:p,onUserEdit:y},g){const x=X4({src:s,mode:o,aspect:u,seed:d});_.useImperativeHandle(g,()=>({cropValue:()=>x.cropValue(),natAspect:()=>x.natAspect}),[x]);const v=Math.round(x.view.z*100)+"%",E=_.useRef(!1),M=_.useRef(!1),N=()=>{M.current=!0},A=()=>{M.current&&!E.current&&(E.current=!0,y==null||y())},j=()=>{M.current=!1};return f.jsxs(f.Fragment,{children:[f.jsx("div",{onPointerDownCapture:N,onPointerMoveCapture:A,onPointerUpCapture:j,children:f.jsx(W4,{cr:x,mode:o,src:s,stageClassName:h})}),f.jsx(Z4,{chrome:l,pct:v,onZoomOut:()=>x.zoomBy(1/1.25),onZoomIn:()=>x.zoomBy(1.25),resetSlot:f.jsx("button",{type:"button",className:l.buttonLink,onClick:x.reset,children:"Reset"}),children:p})]})});function rb(...n){return $f(Kf(n))}function tE({view:n,onChange:l,className:s}){const o=(u,d,h)=>f.jsx("button",{type:"button","aria-label":d,"aria-pressed":n===u,onClick:()=>l(u),className:rb("flex h-7 w-8 items-center justify-center rounded-[6px] transition-[background,color] duration-[120ms]",n===u?"bg-white text-ink shadow-sm":"text-white/85 hover:text-white"),children:f.jsx("svg",{viewBox:"0 0 24 24",className:"h-4 w-4",fill:"none",stroke:"currentColor",strokeWidth:"1.8",children:f.jsx("path",{d:h})})});return f.jsxs("div",{className:rb("inline-flex gap-0.5 rounded-[8px] bg-[rgba(15,18,9,0.55)] p-0.5 backdrop-blur",s),children:[o("desktop","Desktop crop","M3 5h18v11H3zM8 20h8M12 16v4"),o("mobile","Mobile crop","M8 3h8a1 1 0 0 1 1 1v16a1 1 0 0 1-1 1H8a1 1 0 0 1-1-1V4a1 1 0 0 1 1-1zM11 18h2")]})}function ih({chrome:n,open:l=!0,src:s,mode:o,aspect:u,mobileAspect:d,seed:h,mobileSeed:p,onApply:y,onClose:g,title:x="Crop photo",subtitle:v,variant:E="crop",stageClassName:M="h-[412px]"}){const[N]=_.useState(s),A=d!=null&&Math.abs(d-u)>1e-4,[j,O]=_.useState("desktop"),[z,D]=_.useState({desktop:(h==null?void 0:h.rect)??null,mobile:(p==null?void 0:p.rect)??null}),Y=_.useRef(!(p!=null&&p.rect)),W=_.useRef(null),ee=L=>L==="mobile"?d??u:u,ae=()=>{var L;return((L=W.current)==null?void 0:L.natAspect())??u},U=L=>L==="desktop"?{rect:z.desktop}:{rect:z.mobile??z.desktop},re=()=>{var L;return((L=W.current)==null?void 0:L.cropValue())??null},de=L=>{if(L===j)return;const G=re();D(F=>{const w={...F,[j]:G??F[j]};if(j==="desktop"&&Y.current){const Z=w.desktop??G;Z&&(w.mobile=ob(Z,d??u,ae()))}return w}),O(L)},ce=()=>{j==="mobile"&&(Y.current=!1)},ie=()=>{const L=re(),G=ae(),F=(j==="desktop"?L:z.desktop)??L??{nx:0,ny:0,nw:1,nh:1};let w={rect:F,ar:G};if(A){let Z=j==="mobile"?L:z.mobile;Z||(Z=ob(F,d??u,G)),w={...w,mobile:{rect:Z,derived:Y.current}}}y(w)};return f.jsxs(n.Shell,{open:l,variant:E,onClose:g,children:[f.jsxs("div",{className:n.head,children:[f.jsxs("div",{className:n.titles,children:[f.jsx("h2",{className:n.title,children:x}),v?f.jsx("span",{className:n.subtitle,children:v}):null]}),f.jsx("button",{className:n.close,onClick:g,"aria-label":"Close",children:f.jsx(n.CloseIcon,{})})]}),f.jsxs("div",{className:"relative",children:[A&&f.jsx(tE,{view:j,onChange:de,className:"absolute right-3 top-3 z-10"}),f.jsx(eE,{ref:W,chrome:n,src:N,mode:o,aspect:ee(j),seed:U(j),stageClassName:M,onUserEdit:ce,footerActions:f.jsxs(f.Fragment,{children:[f.jsx("button",{className:n.buttonGhost,onClick:g,children:"Cancel"}),f.jsx("button",{className:n.buttonPrimary,onClick:ie,children:"Apply crop"})]})},j)]})]})}function nE(n,l,s){return{nx:n.x/l,ny:n.y/s,nw:n.w/l,nh:n.h/s}}function aE(n,l,s){return{x:n.nx*l,y:n.ny*s,w:n.nw*l,h:n.nh*s}}function lE(n,l,s,o){const u=Math.max(o,Math.min(n.w,l)),d=Math.max(o,Math.min(n.h,s)),h=Math.max(0,Math.min(n.x,l-u)),p=Math.max(0,Math.min(n.y,s-d));return{x:h,y:p,w:u,h:d}}function iE(n,l,s,o){return lE(aE(n,l,s),l,s,o)}var Wl=class{constructor(){this.listeners=new Set,this.subscribe=this.subscribe.bind(this)}subscribe(n){return this.listeners.add(n),this.onSubscribe(),()=>{this.listeners.delete(n),this.onUnsubscribe()}}hasListeners(){return this.listeners.size>0}onSubscribe(){}onUnsubscribe(){}},Ul,Za,Vi,r0,sE=(r0=class extends Wl{constructor(){super();be(this,Ul);be(this,Za);be(this,Vi);fe(this,Vi,l=>{if(typeof window<"u"&&window.addEventListener){const s=()=>l();return window.addEventListener("visibilitychange",s,!1),()=>{window.removeEventListener("visibilitychange",s)}}})}onSubscribe(){S(this,Za)||this.setEventListener(S(this,Vi))}onUnsubscribe(){var l;this.hasListeners()||((l=S(this,Za))==null||l.call(this),fe(this,Za,void 0))}setEventListener(l){var s;fe(this,Vi,l),(s=S(this,Za))==null||s.call(this),fe(this,Za,l(o=>{typeof o=="boolean"?this.setFocused(o):this.onFocus()}))}setFocused(l){S(this,Ul)!==l&&(fe(this,Ul,l),this.onFocus())}onFocus(){const l=this.isFocused();this.listeners.forEach(s=>{s(l)})}isFocused(){var l;return typeof S(this,Ul)=="boolean"?S(this,Ul):((l=globalThis.document)==null?void 0:l.visibilityState)!=="hidden"}},Ul=new WeakMap,Za=new WeakMap,Vi=new WeakMap,r0),sh=new sE,oE={setTimeout:(n,l)=>setTimeout(n,l),clearTimeout:n=>clearTimeout(n),setInterval:(n,l)=>setInterval(n,l),clearInterval:n=>clearInterval(n)},Pa,Hf,c0,rE=(c0=class{constructor(){be(this,Pa,oE);be(this,Hf,!1)}setTimeoutProvider(n){fe(this,Pa,n)}setTimeout(n,l){return S(this,Pa).setTimeout(n,l)}clearTimeout(n){S(this,Pa).clearTimeout(n)}setInterval(n,l){return S(this,Pa).setInterval(n,l)}clearInterval(n){S(this,Pa).clearInterval(n)}},Pa=new WeakMap,Hf=new WeakMap,c0),zl=new rE;function cE(n){setTimeout(n,0)}var uE=typeof window>"u"||"Deno"in globalThis;function qt(){}function dE(n,l){return typeof n=="function"?n(l):n}function sf(n){return typeof n=="number"&&n>=0&&n!==1/0}function Nv(n,l){return Math.max(n+(l||0)-Date.now(),0)}function sl(n,l){return typeof n=="function"?n(l):n}function fn(n,l){return typeof n=="function"?n(l):n}function cb(n,l){const{type:s="all",exact:o,fetchStatus:u,predicate:d,queryKey:h,stale:p}=n;if(h){if(o){if(l.queryHash!==oh(h,l.options))return!1}else if(!os(l.queryKey,h))return!1}if(s!=="all"){const y=l.isActive();if(s==="active"&&!y||s==="inactive"&&y)return!1}return!(typeof p=="boolean"&&l.isStale()!==p||u&&u!==l.state.fetchStatus||d&&!d(l))}function ub(n,l){const{exact:s,status:o,predicate:u,mutationKey:d}=n;if(d){if(!l.options.mutationKey)return!1;if(s){if(Zl(l.options.mutationKey)!==Zl(d))return!1}else if(!os(l.options.mutationKey,d))return!1}return!(o&&l.state.status!==o||u&&!u(l))}function oh(n,l){return((l==null?void 0:l.queryKeyHashFn)||Zl)(n)}function Zl(n){return JSON.stringify(n,(l,s)=>of(s)?Object.keys(s).sort().reduce((o,u)=>(o[u]=s[u],o),{}):s)}function os(n,l){if(n===l)return!0;if(typeof n!=typeof l)return!1;if(n&&l&&typeof n=="object"&&typeof l=="object"){if(Array.isArray(n)&&Array.isArray(l)){for(let o=0;o<l.length;o++)if(!os(n[o],l[o]))return!1;return!0}const s=Object.keys(l);for(const o of s)if(!os(n[o],l[o]))return!1;return!0}return!1}var fE=Object.prototype.hasOwnProperty;function rh(n,l,s=0){if(n===l)return n;if(s>500)return l;const o=db(n)&&db(l);if(!o&&!(of(n)&&of(l)))return l;const d=(o?n:Object.keys(n)).length,h=o?l:Object.keys(l),p=h.length,y=o?new Array(p):{};let g=0;for(let x=0;x<p;x++){const v=o?x:h[x],E=n[v],M=l[v];if(E===M){y[v]=E,(o?x<d:fE.call(n,v))&&g++;continue}if(E===null||M===null||typeof E!="object"||typeof M!="object"){y[v]=M;continue}const N=rh(E,M,s+1);y[v]=N,N===E&&g++}return d===p&&g===d?n:y}function co(n,l){if(!l||Object.keys(n).length!==Object.keys(l).length)return!1;for(const s in n)if(n[s]!==l[s])return!1;return!0}function db(n){return Array.isArray(n)&&n.length===Object.keys(n).length}function of(n){if(!fb(n))return!1;const l=n.constructor;if(l===void 0)return!0;const s=l.prototype;return!(!fb(s)||!s.hasOwnProperty("isPrototypeOf")||Object.getPrototypeOf(n)!==Object.prototype)}function fb(n){return Object.prototype.toString.call(n)==="[object Object]"}function hE(n){return new Promise(l=>{zl.setTimeout(l,n)})}function rf(n,l,s){return typeof s.structuralSharing=="function"?s.structuralSharing(n,l):s.structuralSharing!==!1?rh(n,l):l}function pE(n,l,s=0){const o=[...n,l];return s&&o.length>s?o.slice(1):o}function mE(n,l,s=0){const o=[l,...n];return s&&o.length>s?o.slice(0,-1):o}var ch=Symbol();function Tv(n,l){return!n.queryFn&&(l!=null&&l.initialPromise)?()=>l.initialPromise:!n.queryFn||n.queryFn===ch?()=>Promise.reject(new Error(`Missing queryFn: '${n.queryHash}'`)):n.queryFn}function uh(n,l){return typeof n=="function"?n(...l):!!n}function yE(n,l,s){let o=!1,u;return Object.defineProperty(n,"signal",{enumerable:!0,get:()=>(u??(u=l()),o||(o=!0,u.aborted?s():u.addEventListener("abort",s,{once:!0})),u)}),n}var uo=(()=>{let n=()=>uE;return{isServer(){return n()},setIsServer(l){n=l}}})();function cf(){let n,l;const s=new Promise((u,d)=>{n=u,l=d});s.status="pending",s.catch(()=>{});function o(u){Object.assign(s,u),delete s.resolve,delete s.reject}return s.resolve=u=>{o({status:"fulfilled",value:u}),n(u)},s.reject=u=>{o({status:"rejected",reason:u}),l(u)},s}var gE=cE;function bE(){let n=[],l=0,s=p=>{p()},o=p=>{p()},u=gE;const d=p=>{l?n.push(p):u(()=>{s(p)})},h=()=>{const p=n;n=[],p.length&&u(()=>{o(()=>{p.forEach(y=>{s(y)})})})};return{batch:p=>{let y;l++;try{y=p()}finally{l--,l||h()}return y},batchCalls:p=>(...y)=>{d(()=>{p(...y)})},schedule:d,setNotifyFunction:p=>{s=p},setBatchNotifyFunction:p=>{o=p},setScheduler:p=>{u=p}}}var ht=bE(),Yi,Ja,$i,u0,vE=(u0=class extends Wl{constructor(){super();be(this,Yi,!0);be(this,Ja);be(this,$i);fe(this,$i,l=>{if(typeof window<"u"&&window.addEventListener){const s=()=>l(!0),o=()=>l(!1);return window.addEventListener("online",s,!1),window.addEventListener("offline",o,!1),()=>{window.removeEventListener("online",s),window.removeEventListener("offline",o)}}})}onSubscribe(){S(this,Ja)||this.setEventListener(S(this,$i))}onUnsubscribe(){var l;this.hasListeners()||((l=S(this,Ja))==null||l.call(this),fe(this,Ja,void 0))}setEventListener(l){var s;fe(this,$i,l),(s=S(this,Ja))==null||s.call(this),fe(this,Ja,l(this.setOnline.bind(this)))}setOnline(l){S(this,Yi)!==l&&(fe(this,Yi,l),this.listeners.forEach(o=>{o(l)}))}isOnline(){return S(this,Yi)}},Yi=new WeakMap,Ja=new WeakMap,$i=new WeakMap,u0),ac=new vE;function xE(n){return Math.min(1e3*2**n,3e4)}function Ov(n){return(n??"online")==="online"?ac.isOnline():!0}var uf=class extends Error{constructor(n){super("CancelledError"),this.revert=n==null?void 0:n.revert,this.silent=n==null?void 0:n.silent}};function Rv(n){let l=!1,s=0,o;const u=cf(),d=()=>u.status!=="pending",h=A=>{var j;if(!d()){const O=new uf(A);E(O),(j=n.onCancel)==null||j.call(n,O)}},p=()=>{l=!0},y=()=>{l=!1},g=()=>sh.isFocused()&&(n.networkMode==="always"||ac.isOnline())&&n.canRun(),x=()=>Ov(n.networkMode)&&n.canRun(),v=A=>{d()||(o==null||o(),u.resolve(A))},E=A=>{d()||(o==null||o(),u.reject(A))},M=()=>new Promise(A=>{var j;o=O=>{(d()||g())&&A(O)},(j=n.onPause)==null||j.call(n)}).then(()=>{var A;o=void 0,d()||(A=n.onContinue)==null||A.call(n)}),N=()=>{if(d())return;let A;const j=s===0?n.initialPromise:void 0;try{A=j??n.fn()}catch(O){A=Promise.reject(O)}Promise.resolve(A).then(v).catch(O=>{var ee;if(d())return;const z=n.retry??(uo.isServer()?0:3),D=n.retryDelay??xE,Y=typeof D=="function"?D(s,O):D,W=z===!0||typeof z=="number"&&s<z||typeof z=="function"&&z(s,O);if(l||!W){E(O);return}s++,(ee=n.onFail)==null||ee.call(n,s,O),hE(Y).then(()=>g()?void 0:M()).then(()=>{l?E(O):N()})})};return{promise:u,status:()=>u.status,cancel:h,continue:()=>(o==null||o(),u),cancelRetry:p,continueRetry:y,canStart:x,start:()=>(x()?N():M().then(N),u)}}var Ll,d0,zv=(d0=class{constructor(){be(this,Ll)}destroy(){this.clearGcTimeout()}scheduleGc(){this.clearGcTimeout(),sf(this.gcTime)&&fe(this,Ll,zl.setTimeout(()=>{this.optionalRemove()},this.gcTime))}updateGcTime(n){this.gcTime=Math.max(this.gcTime||0,n??(uo.isServer()?1/0:300*1e3))}clearGcTimeout(){S(this,Ll)!==void 0&&(zl.clearTimeout(S(this,Ll)),fe(this,Ll,void 0))}},Ll=new WeakMap,d0);function _E(n){return{onFetch:(l,s)=>{var x,v,E,M,N;const o=l.options,u=(E=(v=(x=l.fetchOptions)==null?void 0:x.meta)==null?void 0:v.fetchMore)==null?void 0:E.direction,d=((M=l.state.data)==null?void 0:M.pages)||[],h=((N=l.state.data)==null?void 0:N.pageParams)||[];let p={pages:[],pageParams:[]},y=0;const g=async()=>{let A=!1;const j=D=>{yE(D,()=>l.signal,()=>A=!0)},O=Tv(l.options,l.fetchOptions),z=async(D,Y,W)=>{if(A)return Promise.reject(l.signal.reason);if(Y==null&&D.pages.length)return Promise.resolve(D);const ae=(()=>{const ce={client:l.client,queryKey:l.queryKey,pageParam:Y,direction:W?"backward":"forward",meta:l.options.meta};return j(ce),ce})(),U=await O(ae),{maxPages:re}=l.options,de=W?mE:pE;return{pages:de(D.pages,U,re),pageParams:de(D.pageParams,Y,re)}};if(u&&d.length){const D=u==="backward",Y=D?wE:hb,W={pages:d,pageParams:h},ee=Y(o,W);p=await z(W,ee,D)}else{const D=n??d.length;do{const Y=y===0?h[0]??o.initialPageParam:hb(o,p);if(y>0&&Y==null)break;p=await z(p,Y),y++}while(y<D)}return p};l.options.persister?l.fetchFn=()=>{var A,j;return(j=(A=l.options).persister)==null?void 0:j.call(A,g,{client:l.client,queryKey:l.queryKey,meta:l.options.meta,signal:l.signal},s)}:l.fetchFn=g}}}function hb(n,{pages:l,pageParams:s}){const o=l.length-1;return l.length>0?n.getNextPageParam(l[o],l,s[o],s):void 0}function wE(n,{pages:l,pageParams:s}){var o;return l.length>0?(o=n.getPreviousPageParam)==null?void 0:o.call(n,l[0],l,s[0],s):void 0}var Fi,Bl,Xi,kn,Hl,Mt,fo,ql,dn,Dv,fa,f0,SE=(f0=class extends zv{constructor(l){super();be(this,dn);be(this,Fi);be(this,Bl);be(this,Xi);be(this,kn);be(this,Hl);be(this,Mt);be(this,fo);be(this,ql);fe(this,ql,!1),fe(this,fo,l.defaultOptions),this.setOptions(l.options),this.observers=[],fe(this,Hl,l.client),fe(this,kn,S(this,Hl).getQueryCache()),this.queryKey=l.queryKey,this.queryHash=l.queryHash,fe(this,Bl,mb(this.options)),this.state=l.state??S(this,Bl),this.scheduleGc()}get meta(){return this.options.meta}get queryType(){return S(this,Fi)}get promise(){var l;return(l=S(this,Mt))==null?void 0:l.promise}setOptions(l){if(this.options={...S(this,fo),...l},l!=null&&l._type&&fe(this,Fi,l._type),this.updateGcTime(this.options.gcTime),this.state&&this.state.data===void 0){const s=mb(this.options);s.data!==void 0&&(this.setState(pb(s.data,s.dataUpdatedAt)),fe(this,Bl,s))}}optionalRemove(){!this.observers.length&&this.state.fetchStatus==="idle"&&S(this,kn).remove(this)}setData(l,s){const o=rf(this.state.data,l,this.options);return je(this,dn,fa).call(this,{data:o,type:"success",dataUpdatedAt:s==null?void 0:s.updatedAt,manual:s==null?void 0:s.manual}),o}setState(l){je(this,dn,fa).call(this,{type:"setState",state:l})}cancel(l){var o,u;const s=(o=S(this,Mt))==null?void 0:o.promise;return(u=S(this,Mt))==null||u.cancel(l),s?s.then(qt).catch(qt):Promise.resolve()}destroy(){super.destroy(),this.cancel({silent:!0})}get resetState(){return S(this,Bl)}reset(){this.destroy(),this.setState(this.resetState)}isActive(){return this.observers.some(l=>fn(l.options.enabled,this)!==!1)}isDisabled(){return this.getObserversCount()>0?!this.isActive():this.options.queryFn===ch||!this.isFetched()}isFetched(){return this.state.dataUpdateCount+this.state.errorUpdateCount>0}isStatic(){return this.getObserversCount()>0?this.observers.some(l=>sl(l.options.staleTime,this)==="static"):!1}isStale(){return this.getObserversCount()>0?this.observers.some(l=>l.getCurrentResult().isStale):this.state.data===void 0||this.state.isInvalidated}isStaleByTime(l=0){return this.state.data===void 0?!0:l==="static"?!1:this.state.isInvalidated?!0:!Nv(this.state.dataUpdatedAt,l)}onFocus(){var s;const l=this.observers.find(o=>o.shouldFetchOnWindowFocus());l==null||l.refetch({cancelRefetch:!1}),(s=S(this,Mt))==null||s.continue()}onOnline(){var s;const l=this.observers.find(o=>o.shouldFetchOnReconnect());l==null||l.refetch({cancelRefetch:!1}),(s=S(this,Mt))==null||s.continue()}addObserver(l){this.observers.includes(l)||(this.observers.push(l),this.clearGcTimeout(),S(this,kn).notify({type:"observerAdded",query:this,observer:l}))}removeObserver(l){this.observers.includes(l)&&(this.observers=this.observers.filter(s=>s!==l),this.observers.length||(S(this,Mt)&&(S(this,ql)||je(this,dn,Dv).call(this)?S(this,Mt).cancel({revert:!0}):S(this,Mt).cancelRetry()),this.scheduleGc()),S(this,kn).notify({type:"observerRemoved",query:this,observer:l}))}getObserversCount(){return this.observers.length}invalidate(){this.state.isInvalidated||je(this,dn,fa).call(this,{type:"invalidate"})}async fetch(l,s){var g,x,v,E,M,N,A,j,O,z,D;if(this.state.fetchStatus!=="idle"&&((g=S(this,Mt))==null?void 0:g.status())!=="rejected"){if(this.state.data!==void 0&&(s!=null&&s.cancelRefetch))this.cancel({silent:!0});else if(S(this,Mt))return S(this,Mt).continueRetry(),S(this,Mt).promise}if(l&&this.setOptions(l),!this.options.queryFn){const Y=this.observers.find(W=>W.options.queryFn);Y&&this.setOptions(Y.options)}const o=new AbortController,u=Y=>{Object.defineProperty(Y,"signal",{enumerable:!0,get:()=>(fe(this,ql,!0),o.signal)})},d=()=>{const Y=Tv(this.options,s),ee=(()=>{const ae={client:S(this,Hl),queryKey:this.queryKey,meta:this.meta};return u(ae),ae})();return fe(this,ql,!1),this.options.persister?this.options.persister(Y,ee,this):Y(ee)},p=(()=>{const Y={fetchOptions:s,options:this.options,queryKey:this.queryKey,client:S(this,Hl),state:this.state,fetchFn:d};return u(Y),Y})(),y=S(this,Fi)==="infinite"?_E(this.options.pages):this.options.behavior;y==null||y.onFetch(p,this),fe(this,Xi,this.state),(this.state.fetchStatus==="idle"||this.state.fetchMeta!==((x=p.fetchOptions)==null?void 0:x.meta))&&je(this,dn,fa).call(this,{type:"fetch",meta:(v=p.fetchOptions)==null?void 0:v.meta}),fe(this,Mt,Rv({initialPromise:s==null?void 0:s.initialPromise,fn:p.fetchFn,onCancel:Y=>{Y instanceof uf&&Y.revert&&this.setState({...S(this,Xi),fetchStatus:"idle"}),o.abort()},onFail:(Y,W)=>{je(this,dn,fa).call(this,{type:"failed",failureCount:Y,error:W})},onPause:()=>{je(this,dn,fa).call(this,{type:"pause"})},onContinue:()=>{je(this,dn,fa).call(this,{type:"continue"})},retry:p.options.retry,retryDelay:p.options.retryDelay,networkMode:p.options.networkMode,canRun:()=>!0}));try{const Y=await S(this,Mt).start();if(Y===void 0)throw new Error(`${this.queryHash} data is undefined`);return this.setData(Y),(M=(E=S(this,kn).config).onSuccess)==null||M.call(E,Y,this),(A=(N=S(this,kn).config).onSettled)==null||A.call(N,Y,this.state.error,this),Y}catch(Y){if(Y instanceof uf){if(Y.silent)return S(this,Mt).promise;if(Y.revert){if(this.state.data===void 0)throw Y;return this.state.data}}throw je(this,dn,fa).call(this,{type:"error",error:Y}),(O=(j=S(this,kn).config).onError)==null||O.call(j,Y,this),(D=(z=S(this,kn).config).onSettled)==null||D.call(z,this.state.data,Y,this),Y}finally{this.scheduleGc()}}},Fi=new WeakMap,Bl=new WeakMap,Xi=new WeakMap,kn=new WeakMap,Hl=new WeakMap,Mt=new WeakMap,fo=new WeakMap,ql=new WeakMap,dn=new WeakSet,Dv=function(){return this.state.fetchStatus==="paused"&&this.state.status==="pending"},fa=function(l){const s=o=>{switch(l.type){case"failed":return{...o,fetchFailureCount:l.failureCount,fetchFailureReason:l.error};case"pause":return{...o,fetchStatus:"paused"};case"continue":return{...o,fetchStatus:"fetching"};case"fetch":return{...o,...Uv(o.data,this.options),fetchMeta:l.meta??null};case"success":const u={...o,...pb(l.data,l.dataUpdatedAt),dataUpdateCount:o.dataUpdateCount+1,...!l.manual&&{fetchStatus:"idle",fetchFailureCount:0,fetchFailureReason:null}};return fe(this,Xi,l.manual?u:void 0),u;case"error":const d=l.error;return{...o,error:d,errorUpdateCount:o.errorUpdateCount+1,errorUpdatedAt:Date.now(),fetchFailureCount:o.fetchFailureCount+1,fetchFailureReason:d,fetchStatus:"idle",status:"error",isInvalidated:!0};case"invalidate":return{...o,isInvalidated:!0};case"setState":return{...o,...l.state}}};this.state=s(this.state),ht.batch(()=>{this.observers.forEach(o=>{o.onQueryUpdate()}),S(this,kn).notify({query:this,type:"updated",action:l})})},f0);function Uv(n,l){return{fetchFailureCount:0,fetchFailureReason:null,fetchStatus:Ov(l.networkMode)?"fetching":"paused",...n===void 0&&{error:null,status:"pending"}}}function pb(n,l){return{data:n,dataUpdatedAt:l??Date.now(),error:null,isInvalidated:!1,status:"success"}}function mb(n){const l=typeof n.initialData=="function"?n.initialData():n.initialData,s=l!==void 0,o=s?typeof n.initialDataUpdatedAt=="function"?n.initialDataUpdatedAt():n.initialDataUpdatedAt:0;return{data:l,dataUpdateCount:0,dataUpdatedAt:s?o??Date.now():0,error:null,errorUpdateCount:0,errorUpdatedAt:0,fetchFailureCount:0,fetchFailureReason:null,fetchMeta:null,isInvalidated:!1,status:s?"success":"pending",fetchStatus:"idle"}}var Pt,Ke,ho,Qt,Gl,Zi,ha,Wa,po,Pi,Ji,Il,Ql,el,Wi,Xe,ro,df,ff,hf,pf,mf,yf,gf,Lv,h0,dh=(h0=class extends Wl{constructor(l,s){super();be(this,Xe);be(this,Pt);be(this,Ke);be(this,ho);be(this,Qt);be(this,Gl);be(this,Zi);be(this,ha);be(this,Wa);be(this,po);be(this,Pi);be(this,Ji);be(this,Il);be(this,Ql);be(this,el);be(this,Wi,new Set);this.options=s,fe(this,Pt,l),fe(this,Wa,null),fe(this,ha,cf()),this.bindMethods(),this.setOptions(s)}bindMethods(){this.refetch=this.refetch.bind(this)}onSubscribe(){this.listeners.size===1&&(S(this,Ke).addObserver(this),yb(S(this,Ke),this.options)?je(this,Xe,ro).call(this):this.updateResult(),je(this,Xe,pf).call(this))}onUnsubscribe(){this.hasListeners()||this.destroy()}shouldFetchOnReconnect(){return bf(S(this,Ke),this.options,this.options.refetchOnReconnect)}shouldFetchOnWindowFocus(){return bf(S(this,Ke),this.options,this.options.refetchOnWindowFocus)}destroy(){this.listeners=new Set,je(this,Xe,mf).call(this),je(this,Xe,yf).call(this),S(this,Ke).removeObserver(this)}setOptions(l){const s=this.options,o=S(this,Ke);if(this.options=S(this,Pt).defaultQueryOptions(l),this.options.enabled!==void 0&&typeof this.options.enabled!="boolean"&&typeof this.options.enabled!="function"&&typeof fn(this.options.enabled,S(this,Ke))!="boolean")throw new Error("Expected enabled to be a boolean or a callback that returns a boolean");je(this,Xe,gf).call(this),S(this,Ke).setOptions(this.options),s._defaulted&&!co(this.options,s)&&S(this,Pt).getQueryCache().notify({type:"observerOptionsUpdated",query:S(this,Ke),observer:this});const u=this.hasListeners();u&&gb(S(this,Ke),o,this.options,s)&&je(this,Xe,ro).call(this),this.updateResult(),u&&(S(this,Ke)!==o||fn(this.options.enabled,S(this,Ke))!==fn(s.enabled,S(this,Ke))||sl(this.options.staleTime,S(this,Ke))!==sl(s.staleTime,S(this,Ke)))&&je(this,Xe,df).call(this);const d=je(this,Xe,ff).call(this);u&&(S(this,Ke)!==o||fn(this.options.enabled,S(this,Ke))!==fn(s.enabled,S(this,Ke))||d!==S(this,el))&&je(this,Xe,hf).call(this,d)}getOptimisticResult(l){const s=S(this,Pt).getQueryCache().build(S(this,Pt),l),o=this.createResult(s,l);return EE(this,o)&&(fe(this,Qt,o),fe(this,Zi,this.options),fe(this,Gl,S(this,Ke).state)),o}getCurrentResult(){return S(this,Qt)}trackResult(l,s){return new Proxy(l,{get:(o,u)=>(this.trackProp(u),s==null||s(u),u==="promise"&&(this.trackProp("data"),!this.options.experimental_prefetchInRender&&S(this,ha).status==="pending"&&S(this,ha).reject(new Error("experimental_prefetchInRender feature flag is not enabled"))),Reflect.get(o,u))})}trackProp(l){S(this,Wi).add(l)}getCurrentQuery(){return S(this,Ke)}refetch({...l}={}){return this.fetch({...l})}fetchOptimistic(l){const s=S(this,Pt).defaultQueryOptions(l),o=S(this,Pt).getQueryCache().build(S(this,Pt),s);return o.fetch().then(()=>this.createResult(o,s))}fetch(l){return je(this,Xe,ro).call(this,{...l,cancelRefetch:l.cancelRefetch??!0}).then(()=>(this.updateResult(),S(this,Qt)))}createResult(l,s){var re;const o=S(this,Ke),u=this.options,d=S(this,Qt),h=S(this,Gl),p=S(this,Zi),g=l!==o?l.state:S(this,ho),{state:x}=l;let v={...x},E=!1,M;if(s._optimisticResults){const de=this.hasListeners(),ce=!de&&yb(l,s),ie=de&&gb(l,o,s,u);(ce||ie)&&(v={...v,...Uv(x.data,l.options)}),s._optimisticResults==="isRestoring"&&(v.fetchStatus="idle")}let{error:N,errorUpdatedAt:A,status:j}=v;M=v.data;let O=!1;if(s.placeholderData!==void 0&&M===void 0&&j==="pending"){let de;d!=null&&d.isPlaceholderData&&s.placeholderData===(p==null?void 0:p.placeholderData)?(de=d.data,O=!0):de=typeof s.placeholderData=="function"?s.placeholderData((re=S(this,Ji))==null?void 0:re.state.data,S(this,Ji)):s.placeholderData,de!==void 0&&(j="success",M=rf(d==null?void 0:d.data,de,s),E=!0)}if(s.select&&M!==void 0&&!O)if(d&&M===(h==null?void 0:h.data)&&s.select===S(this,po))M=S(this,Pi);else try{fe(this,po,s.select),M=s.select(M),M=rf(d==null?void 0:d.data,M,s),fe(this,Pi,M),fe(this,Wa,null)}catch(de){fe(this,Wa,de)}S(this,Wa)&&(N=S(this,Wa),M=S(this,Pi),A=Date.now(),j="error");const z=v.fetchStatus==="fetching",D=j==="pending",Y=j==="error",W=D&&z,ee=M!==void 0,U={status:j,fetchStatus:v.fetchStatus,isPending:D,isSuccess:j==="success",isError:Y,isInitialLoading:W,isLoading:W,data:M,dataUpdatedAt:v.dataUpdatedAt,error:N,errorUpdatedAt:A,failureCount:v.fetchFailureCount,failureReason:v.fetchFailureReason,errorUpdateCount:v.errorUpdateCount,isFetched:l.isFetched(),isFetchedAfterMount:v.dataUpdateCount>g.dataUpdateCount||v.errorUpdateCount>g.errorUpdateCount,isFetching:z,isRefetching:z&&!D,isLoadingError:Y&&!ee,isPaused:v.fetchStatus==="paused",isPlaceholderData:E,isRefetchError:Y&&ee,isStale:fh(l,s),refetch:this.refetch,promise:S(this,ha),isEnabled:fn(s.enabled,l)!==!1};if(this.options.experimental_prefetchInRender){const de=U.data!==void 0,ce=U.status==="error"&&!de,ie=F=>{ce?F.reject(U.error):de&&F.resolve(U.data)},L=()=>{const F=fe(this,ha,U.promise=cf());ie(F)},G=S(this,ha);switch(G.status){case"pending":l.queryHash===o.queryHash&&ie(G);break;case"fulfilled":(ce||U.data!==G.value)&&L();break;case"rejected":(!ce||U.error!==G.reason)&&L();break}}return U}updateResult(){const l=S(this,Qt),s=this.createResult(S(this,Ke),this.options);if(fe(this,Gl,S(this,Ke).state),fe(this,Zi,this.options),S(this,Gl).data!==void 0&&fe(this,Ji,S(this,Ke)),co(s,l))return;fe(this,Qt,s);const o=()=>{if(!l)return!0;const{notifyOnChangeProps:u}=this.options,d=typeof u=="function"?u():u;if(d==="all"||!d&&!S(this,Wi).size)return!0;const h=new Set(d??S(this,Wi));return this.options.throwOnError&&h.add("error"),Object.keys(S(this,Qt)).some(p=>{const y=p;return S(this,Qt)[y]!==l[y]&&h.has(y)})};je(this,Xe,Lv).call(this,{listeners:o()})}onQueryUpdate(){this.updateResult(),this.hasListeners()&&je(this,Xe,pf).call(this)}},Pt=new WeakMap,Ke=new WeakMap,ho=new WeakMap,Qt=new WeakMap,Gl=new WeakMap,Zi=new WeakMap,ha=new WeakMap,Wa=new WeakMap,po=new WeakMap,Pi=new WeakMap,Ji=new WeakMap,Il=new WeakMap,Ql=new WeakMap,el=new WeakMap,Wi=new WeakMap,Xe=new WeakSet,ro=function(l){je(this,Xe,gf).call(this);let s=S(this,Ke).fetch(this.options,l);return l!=null&&l.throwOnError||(s=s.catch(qt)),s},df=function(){je(this,Xe,mf).call(this);const l=sl(this.options.staleTime,S(this,Ke));if(uo.isServer()||S(this,Qt).isStale||!sf(l))return;const o=Nv(S(this,Qt).dataUpdatedAt,l)+1;fe(this,Il,zl.setTimeout(()=>{S(this,Qt).isStale||this.updateResult()},o))},ff=function(){return(typeof this.options.refetchInterval=="function"?this.options.refetchInterval(S(this,Ke)):this.options.refetchInterval)??!1},hf=function(l){je(this,Xe,yf).call(this),fe(this,el,l),!(uo.isServer()||fn(this.options.enabled,S(this,Ke))===!1||!sf(S(this,el))||S(this,el)===0)&&fe(this,Ql,zl.setInterval(()=>{(this.options.refetchIntervalInBackground||sh.isFocused())&&je(this,Xe,ro).call(this)},S(this,el)))},pf=function(){je(this,Xe,df).call(this),je(this,Xe,hf).call(this,je(this,Xe,ff).call(this))},mf=function(){S(this,Il)!==void 0&&(zl.clearTimeout(S(this,Il)),fe(this,Il,void 0))},yf=function(){S(this,Ql)!==void 0&&(zl.clearInterval(S(this,Ql)),fe(this,Ql,void 0))},gf=function(){const l=S(this,Pt).getQueryCache().build(S(this,Pt),this.options);if(l===S(this,Ke))return;const s=S(this,Ke);fe(this,Ke,l),fe(this,ho,l.state),this.hasListeners()&&(s==null||s.removeObserver(this),l.addObserver(this))},Lv=function(l){ht.batch(()=>{l.listeners&&this.listeners.forEach(s=>{s(S(this,Qt))}),S(this,Pt).getQueryCache().notify({query:S(this,Ke),type:"observerResultsUpdated"})})},h0);function kE(n,l){return fn(l.enabled,n)!==!1&&n.state.data===void 0&&!(n.state.status==="error"&&fn(l.retryOnMount,n)===!1)}function yb(n,l){return kE(n,l)||n.state.data!==void 0&&bf(n,l,l.refetchOnMount)}function bf(n,l,s){if(fn(l.enabled,n)!==!1&&sl(l.staleTime,n)!=="static"){const o=typeof s=="function"?s(n):s;return o==="always"||o!==!1&&fh(n,l)}return!1}function gb(n,l,s,o){return(n!==l||fn(o.enabled,n)===!1)&&(!s.suspense||n.state.status!=="error")&&fh(n,s)}function fh(n,l){return fn(l.enabled,n)!==!1&&n.isStaleByTime(sl(l.staleTime,n))}function EE(n,l){return!co(n.getCurrentResult(),l)}var mo,qn,Ht,Kl,Gn,Fa,p0,jE=(p0=class extends zv{constructor(l){super();be(this,Gn);be(this,mo);be(this,qn);be(this,Ht);be(this,Kl);fe(this,mo,l.client),this.mutationId=l.mutationId,fe(this,Ht,l.mutationCache),fe(this,qn,[]),this.state=l.state||Bv(),this.setOptions(l.options),this.scheduleGc()}setOptions(l){this.options=l,this.updateGcTime(this.options.gcTime)}get meta(){return this.options.meta}addObserver(l){S(this,qn).includes(l)||(S(this,qn).push(l),this.clearGcTimeout(),S(this,Ht).notify({type:"observerAdded",mutation:this,observer:l}))}removeObserver(l){fe(this,qn,S(this,qn).filter(s=>s!==l)),this.scheduleGc(),S(this,Ht).notify({type:"observerRemoved",mutation:this,observer:l})}optionalRemove(){S(this,qn).length||(this.state.status==="pending"?this.scheduleGc():S(this,Ht).remove(this))}continue(){var l;return((l=S(this,Kl))==null?void 0:l.continue())??this.execute(this.state.variables)}async execute(l){var h,p,y,g,x,v,E,M,N,A,j,O,z,D,Y,W,ee,ae;const s=()=>{je(this,Gn,Fa).call(this,{type:"continue"})},o={client:S(this,mo),meta:this.options.meta,mutationKey:this.options.mutationKey};fe(this,Kl,Rv({fn:()=>this.options.mutationFn?this.options.mutationFn(l,o):Promise.reject(new Error("No mutationFn found")),onFail:(U,re)=>{je(this,Gn,Fa).call(this,{type:"failed",failureCount:U,error:re})},onPause:()=>{je(this,Gn,Fa).call(this,{type:"pause"})},onContinue:s,retry:this.options.retry??0,retryDelay:this.options.retryDelay,networkMode:this.options.networkMode,canRun:()=>S(this,Ht).canRun(this)}));const u=this.state.status==="pending",d=!S(this,Kl).canStart();try{if(u)s();else{je(this,Gn,Fa).call(this,{type:"pending",variables:l,isPaused:d}),S(this,Ht).config.onMutate&&await S(this,Ht).config.onMutate(l,this,o);const re=await((p=(h=this.options).onMutate)==null?void 0:p.call(h,l,o));re!==this.state.context&&je(this,Gn,Fa).call(this,{type:"pending",context:re,variables:l,isPaused:d})}const U=await S(this,Kl).start();return await((g=(y=S(this,Ht).config).onSuccess)==null?void 0:g.call(y,U,l,this.state.context,this,o)),await((v=(x=this.options).onSuccess)==null?void 0:v.call(x,U,l,this.state.context,o)),await((M=(E=S(this,Ht).config).onSettled)==null?void 0:M.call(E,U,null,this.state.variables,this.state.context,this,o)),await((A=(N=this.options).onSettled)==null?void 0:A.call(N,U,null,l,this.state.context,o)),je(this,Gn,Fa).call(this,{type:"success",data:U}),U}catch(U){try{await((O=(j=S(this,Ht).config).onError)==null?void 0:O.call(j,U,l,this.state.context,this,o))}catch(re){Promise.reject(re)}try{await((D=(z=this.options).onError)==null?void 0:D.call(z,U,l,this.state.context,o))}catch(re){Promise.reject(re)}try{await((W=(Y=S(this,Ht).config).onSettled)==null?void 0:W.call(Y,void 0,U,this.state.variables,this.state.context,this,o))}catch(re){Promise.reject(re)}try{await((ae=(ee=this.options).onSettled)==null?void 0:ae.call(ee,void 0,U,l,this.state.context,o))}catch(re){Promise.reject(re)}throw je(this,Gn,Fa).call(this,{type:"error",error:U}),U}finally{S(this,Ht).runNext(this)}}},mo=new WeakMap,qn=new WeakMap,Ht=new WeakMap,Kl=new WeakMap,Gn=new WeakSet,Fa=function(l){const s=o=>{switch(l.type){case"failed":return{...o,failureCount:l.failureCount,failureReason:l.error};case"pause":return{...o,isPaused:!0};case"continue":return{...o,isPaused:!1};case"pending":return{...o,context:l.context,data:void 0,failureCount:0,failureReason:null,error:null,isPaused:l.isPaused,status:"pending",variables:l.variables,submittedAt:Date.now()};case"success":return{...o,data:l.data,failureCount:0,failureReason:null,error:null,status:"success",isPaused:!1};case"error":return{...o,data:void 0,error:l.error,failureCount:o.failureCount+1,failureReason:l.error,isPaused:!1,status:"error"}}};this.state=s(this.state),ht.batch(()=>{S(this,qn).forEach(o=>{o.onMutationUpdate(l)}),S(this,Ht).notify({mutation:this,type:"updated",action:l})})},p0);function Bv(){return{context:void 0,data:void 0,error:null,failureCount:0,failureReason:null,isPaused:!1,status:"idle",variables:void 0,submittedAt:0}}var pa,Nn,yo,m0,ME=(m0=class extends Wl{constructor(l={}){super();be(this,pa);be(this,Nn);be(this,yo);this.config=l,fe(this,pa,new Set),fe(this,Nn,new Map),fe(this,yo,0)}build(l,s,o){const u=new jE({client:l,mutationCache:this,mutationId:++Ir(this,yo)._,options:l.defaultMutationOptions(s),state:o});return this.add(u),u}add(l){S(this,pa).add(l);const s=$r(l);if(typeof s=="string"){const o=S(this,Nn).get(s);o?o.push(l):S(this,Nn).set(s,[l])}this.notify({type:"added",mutation:l})}remove(l){if(S(this,pa).delete(l)){const s=$r(l);if(typeof s=="string"){const o=S(this,Nn).get(s);if(o)if(o.length>1){const u=o.indexOf(l);u!==-1&&o.splice(u,1)}else o[0]===l&&S(this,Nn).delete(s)}}this.notify({type:"removed",mutation:l})}canRun(l){const s=$r(l);if(typeof s=="string"){const o=S(this,Nn).get(s),u=o==null?void 0:o.find(d=>d.state.status==="pending");return!u||u===l}else return!0}runNext(l){var o;const s=$r(l);if(typeof s=="string"){const u=(o=S(this,Nn).get(s))==null?void 0:o.find(d=>d!==l&&d.state.isPaused);return(u==null?void 0:u.continue())??Promise.resolve()}else return Promise.resolve()}clear(){ht.batch(()=>{S(this,pa).forEach(l=>{this.notify({type:"removed",mutation:l})}),S(this,pa).clear(),S(this,Nn).clear()})}getAll(){return Array.from(S(this,pa))}find(l){const s={exact:!0,...l};return this.getAll().find(o=>ub(s,o))}findAll(l={}){return this.getAll().filter(s=>ub(l,s))}notify(l){ht.batch(()=>{this.listeners.forEach(s=>{s(l)})})}resumePausedMutations(){const l=this.getAll().filter(s=>s.state.isPaused);return ht.batch(()=>Promise.all(l.map(s=>s.continue().catch(qt))))}},pa=new WeakMap,Nn=new WeakMap,yo=new WeakMap,m0);function $r(n){var l;return(l=n.options.scope)==null?void 0:l.id}var ma,tl,Jt,ya,ba,Wr,vf,y0,CE=(y0=class extends Wl{constructor(s,o){super();be(this,ba);be(this,ma);be(this,tl);be(this,Jt);be(this,ya);fe(this,ma,s),this.setOptions(o),this.bindMethods(),je(this,ba,Wr).call(this)}bindMethods(){this.mutate=this.mutate.bind(this),this.reset=this.reset.bind(this)}setOptions(s){var u;const o=this.options;this.options=S(this,ma).defaultMutationOptions(s),co(this.options,o)||S(this,ma).getMutationCache().notify({type:"observerOptionsUpdated",mutation:S(this,Jt),observer:this}),o!=null&&o.mutationKey&&this.options.mutationKey&&Zl(o.mutationKey)!==Zl(this.options.mutationKey)?this.reset():((u=S(this,Jt))==null?void 0:u.state.status)==="pending"&&S(this,Jt).setOptions(this.options)}onUnsubscribe(){var s;this.hasListeners()||(s=S(this,Jt))==null||s.removeObserver(this)}onMutationUpdate(s){je(this,ba,Wr).call(this),je(this,ba,vf).call(this,s)}getCurrentResult(){return S(this,tl)}reset(){var s;(s=S(this,Jt))==null||s.removeObserver(this),fe(this,Jt,void 0),je(this,ba,Wr).call(this),je(this,ba,vf).call(this)}mutate(s,o){var u;return fe(this,ya,o),(u=S(this,Jt))==null||u.removeObserver(this),fe(this,Jt,S(this,ma).getMutationCache().build(S(this,ma),this.options)),S(this,Jt).addObserver(this),S(this,Jt).execute(s)}},ma=new WeakMap,tl=new WeakMap,Jt=new WeakMap,ya=new WeakMap,ba=new WeakSet,Wr=function(){var o;const s=((o=S(this,Jt))==null?void 0:o.state)??Bv();fe(this,tl,{...s,isPending:s.status==="pending",isSuccess:s.status==="success",isError:s.status==="error",isIdle:s.status==="idle",mutate:this.mutate,reset:this.reset})},vf=function(s){ht.batch(()=>{var o,u,d,h,p,y,g,x;if(S(this,ya)&&this.hasListeners()){const v=S(this,tl).variables,E=S(this,tl).context,M={client:S(this,ma),meta:this.options.meta,mutationKey:this.options.mutationKey};if((s==null?void 0:s.type)==="success"){try{(u=(o=S(this,ya)).onSuccess)==null||u.call(o,s.data,v,E,M)}catch(N){Promise.reject(N)}try{(h=(d=S(this,ya)).onSettled)==null||h.call(d,s.data,null,v,E,M)}catch(N){Promise.reject(N)}}else if((s==null?void 0:s.type)==="error"){try{(y=(p=S(this,ya)).onError)==null||y.call(p,s.error,v,E,M)}catch(N){Promise.reject(N)}try{(x=(g=S(this,ya)).onSettled)==null||x.call(g,void 0,s.error,v,E,M)}catch(N){Promise.reject(N)}}}this.listeners.forEach(v=>{v(S(this,tl))})})},y0);function bb(n,l){const s=new Set(l);return n.filter(o=>!s.has(o))}function AE(n,l,s){const o=n.slice(0);return o[l]=s,o}var es,Wt,ts,Vl,un,nl,go,bo,vo,xo,kt,xf,_f,Hv,wf,Sf,kf,g0,NE=(g0=class extends Wl{constructor(l,s,o){super();be(this,kt);be(this,es);be(this,Wt);be(this,ts);be(this,Vl);be(this,un);be(this,nl);be(this,go);be(this,bo);be(this,vo);be(this,xo,[]);fe(this,es,l),fe(this,Vl,o),fe(this,ts,[]),fe(this,un,[]),fe(this,Wt,[]),this.setQueries(s)}onSubscribe(){this.listeners.size===1&&S(this,un).forEach(l=>{l.subscribe(s=>{je(this,kt,Sf).call(this,l,s)})})}onUnsubscribe(){this.listeners.size||this.destroy()}destroy(){this.listeners=new Set,S(this,un).forEach(l=>{l.destroy()})}setQueries(l,s){fe(this,ts,l),fe(this,Vl,s),ht.batch(()=>{const o=S(this,un),u=je(this,kt,wf).call(this,S(this,ts));u.forEach(v=>v.observer.setOptions(v.defaultedQueryOptions));const d=u.map(v=>v.observer),h=d.map(v=>v.getCurrentResult()),p=o.length!==d.length,y=d.some((v,E)=>v!==o[E]),g=p||y,x=g?!0:h.some((v,E)=>{const M=S(this,Wt)[E];return!M||!co(v,M)});!g&&!x||(g&&(fe(this,xo,u),fe(this,un,d)),fe(this,Wt,h),this.hasListeners()&&(g&&(bb(o,d).forEach(v=>{v.destroy()}),bb(d,o).forEach(v=>{v.subscribe(E=>{je(this,kt,Sf).call(this,v,E)})})),je(this,kt,kf).call(this)))})}getCurrentResult(){return S(this,Wt)}getQueries(){return S(this,un).map(l=>l.getCurrentQuery())}getObservers(){return S(this,un)}getOptimisticResult(l,s){const o=je(this,kt,wf).call(this,l),u=o.map(h=>h.observer.getOptimisticResult(h.defaultedQueryOptions)),d=o.map(h=>h.defaultedQueryOptions.queryHash);return[u,h=>je(this,kt,_f).call(this,h??u,s,d),()=>je(this,kt,xf).call(this,u,o)]}},es=new WeakMap,Wt=new WeakMap,ts=new WeakMap,Vl=new WeakMap,un=new WeakMap,nl=new WeakMap,go=new WeakMap,bo=new WeakMap,vo=new WeakMap,xo=new WeakMap,kt=new WeakSet,xf=function(l,s){return s.map((o,u)=>{const d=l[u];return o.defaultedQueryOptions.notifyOnChangeProps?d:o.observer.trackResult(d,h=>{s.forEach(p=>{p.observer.trackProp(h)})})})},_f=function(l,s,o){if(s){const u=S(this,vo),d=o!==void 0&&u!==void 0&&(u.length!==o.length||o.some((h,p)=>h!==u[p]));return(!S(this,nl)||S(this,Wt)!==S(this,bo)||d||s!==S(this,go))&&(fe(this,go,s),fe(this,bo,S(this,Wt)),o!==void 0&&fe(this,vo,o),fe(this,nl,rh(S(this,nl),s(l)))),S(this,nl)}return l},Hv=function(){var l;return((l=S(this,Vl))==null?void 0:l.combine)!==void 0&&S(this,un).some((s,o)=>{var u;return s.options.suspense&&((u=S(this,Wt)[o])==null?void 0:u.data)===void 0})},wf=function(l){const s=new Map;S(this,un).forEach(u=>{const d=u.options.queryHash;if(!d)return;const h=s.get(d);h?h.push(u):s.set(d,[u])});const o=[];return l.forEach(u=>{var y;const d=S(this,es).defaultQueryOptions(u),p=((y=s.get(d.queryHash))==null?void 0:y.shift())??new dh(S(this,es),d);o.push({defaultedQueryOptions:d,observer:p})}),o},Sf=function(l,s){const o=S(this,un).indexOf(l);o!==-1&&(fe(this,Wt,AE(S(this,Wt),o,s)),je(this,kt,kf).call(this))},kf=function(){var l;if(this.hasListeners()){const s=je(this,kt,xf).call(this,S(this,Wt),S(this,xo)),o=je(this,kt,Hv).call(this),u=S(this,nl),d=o?u:je(this,kt,_f).call(this,s,(l=S(this,Vl))==null?void 0:l.combine);(o||u!==d)&&ht.batch(()=>{this.listeners.forEach(h=>{h(S(this,Wt))})})}},g0),In,b0,TE=(b0=class extends Wl{constructor(l={}){super();be(this,In);this.config=l,fe(this,In,new Map)}build(l,s,o){const u=s.queryKey,d=s.queryHash??oh(u,s);let h=this.get(d);return h||(h=new SE({client:l,queryKey:u,queryHash:d,options:l.defaultQueryOptions(s),state:o,defaultOptions:l.getQueryDefaults(u)}),this.add(h)),h}add(l){S(this,In).has(l.queryHash)||(S(this,In).set(l.queryHash,l),this.notify({type:"added",query:l}))}remove(l){const s=S(this,In).get(l.queryHash);s&&(l.destroy(),s===l&&S(this,In).delete(l.queryHash),this.notify({type:"removed",query:l}))}clear(){ht.batch(()=>{this.getAll().forEach(l=>{this.remove(l)})})}get(l){return S(this,In).get(l)}getAll(){return[...S(this,In).values()]}find(l){const s={exact:!0,...l};return this.getAll().find(o=>cb(s,o))}findAll(l={}){const s=this.getAll();return Object.keys(l).length>0?s.filter(o=>cb(l,o)):s}notify(l){ht.batch(()=>{this.listeners.forEach(s=>{s(l)})})}onFocus(){ht.batch(()=>{this.getAll().forEach(l=>{l.onFocus()})})}onOnline(){ht.batch(()=>{this.getAll().forEach(l=>{l.onOnline()})})}},In=new WeakMap,b0),ft,al,ll,ns,as,il,ls,is,v0,OE=(v0=class{constructor(n={}){be(this,ft);be(this,al);be(this,ll);be(this,ns);be(this,as);be(this,il);be(this,ls);be(this,is);fe(this,ft,n.queryCache||new TE),fe(this,al,n.mutationCache||new ME),fe(this,ll,n.defaultOptions||{}),fe(this,ns,new Map),fe(this,as,new Map),fe(this,il,0)}mount(){Ir(this,il)._++,S(this,il)===1&&(fe(this,ls,sh.subscribe(async n=>{n&&(await this.resumePausedMutations(),S(this,ft).onFocus())})),fe(this,is,ac.subscribe(async n=>{n&&(await this.resumePausedMutations(),S(this,ft).onOnline())})))}unmount(){var n,l;Ir(this,il)._--,S(this,il)===0&&((n=S(this,ls))==null||n.call(this),fe(this,ls,void 0),(l=S(this,is))==null||l.call(this),fe(this,is,void 0))}isFetching(n){return S(this,ft).findAll({...n,fetchStatus:"fetching"}).length}isMutating(n){return S(this,al).findAll({...n,status:"pending"}).length}getQueryData(n){var s;const l=this.defaultQueryOptions({queryKey:n});return(s=S(this,ft).get(l.queryHash))==null?void 0:s.state.data}ensureQueryData(n){const l=this.defaultQueryOptions(n),s=S(this,ft).build(this,l),o=s.state.data;return o===void 0?this.fetchQuery(n):(n.revalidateIfStale&&s.isStaleByTime(sl(l.staleTime,s))&&this.prefetchQuery(l),Promise.resolve(o))}getQueriesData(n){return S(this,ft).findAll(n).map(({queryKey:l,state:s})=>{const o=s.data;return[l,o]})}setQueryData(n,l,s){const o=this.defaultQueryOptions({queryKey:n}),u=S(this,ft).get(o.queryHash),d=u==null?void 0:u.state.data,h=dE(l,d);if(h!==void 0)return S(this,ft).build(this,o).setData(h,{...s,manual:!0})}setQueriesData(n,l,s){return ht.batch(()=>S(this,ft).findAll(n).map(({queryKey:o})=>[o,this.setQueryData(o,l,s)]))}getQueryState(n){var s;const l=this.defaultQueryOptions({queryKey:n});return(s=S(this,ft).get(l.queryHash))==null?void 0:s.state}removeQueries(n){const l=S(this,ft);ht.batch(()=>{l.findAll(n).forEach(s=>{l.remove(s)})})}resetQueries(n,l){const s=S(this,ft);return ht.batch(()=>(s.findAll(n).forEach(o=>{o.reset()}),this.refetchQueries({type:"active",...n},l)))}cancelQueries(n,l={}){const s={revert:!0,...l},o=ht.batch(()=>S(this,ft).findAll(n).map(u=>u.cancel(s)));return Promise.all(o).then(qt).catch(qt)}invalidateQueries(n,l={}){return ht.batch(()=>(S(this,ft).findAll(n).forEach(s=>{s.invalidate()}),(n==null?void 0:n.refetchType)==="none"?Promise.resolve():this.refetchQueries({...n,type:(n==null?void 0:n.refetchType)??(n==null?void 0:n.type)??"active"},l)))}refetchQueries(n,l={}){const s={...l,cancelRefetch:l.cancelRefetch??!0},o=ht.batch(()=>S(this,ft).findAll(n).filter(u=>!u.isDisabled()&&!u.isStatic()).map(u=>{let d=u.fetch(void 0,s);return s.throwOnError||(d=d.catch(qt)),u.state.fetchStatus==="paused"?Promise.resolve():d}));return Promise.all(o).then(qt)}fetchQuery(n){const l=this.defaultQueryOptions(n);l.retry===void 0&&(l.retry=!1);const s=S(this,ft).build(this,l);return s.isStaleByTime(sl(l.staleTime,s))?s.fetch(l):Promise.resolve(s.state.data)}prefetchQuery(n){return this.fetchQuery(n).then(qt).catch(qt)}fetchInfiniteQuery(n){return n._type="infinite",this.fetchQuery(n)}prefetchInfiniteQuery(n){return this.fetchInfiniteQuery(n).then(qt).catch(qt)}ensureInfiniteQueryData(n){return n._type="infinite",this.ensureQueryData(n)}resumePausedMutations(){return ac.isOnline()?S(this,al).resumePausedMutations():Promise.resolve()}getQueryCache(){return S(this,ft)}getMutationCache(){return S(this,al)}getDefaultOptions(){return S(this,ll)}setDefaultOptions(n){fe(this,ll,n)}setQueryDefaults(n,l){S(this,ns).set(Zl(n),{queryKey:n,defaultOptions:l})}getQueryDefaults(n){const l=[...S(this,ns).values()],s={};return l.forEach(o=>{os(n,o.queryKey)&&Object.assign(s,o.defaultOptions)}),s}setMutationDefaults(n,l){S(this,as).set(Zl(n),{mutationKey:n,defaultOptions:l})}getMutationDefaults(n){const l=[...S(this,as).values()],s={};return l.forEach(o=>{os(n,o.mutationKey)&&Object.assign(s,o.defaultOptions)}),s}defaultQueryOptions(n){if(n._defaulted)return n;const l={...S(this,ll).queries,...this.getQueryDefaults(n.queryKey),...n,_defaulted:!0};return l.queryHash||(l.queryHash=oh(l.queryKey,l)),l.refetchOnReconnect===void 0&&(l.refetchOnReconnect=l.networkMode!=="always"),l.throwOnError===void 0&&(l.throwOnError=!!l.suspense),!l.networkMode&&l.persister&&(l.networkMode="offlineFirst"),l.queryFn===ch&&(l.enabled=!1),l}defaultMutationOptions(n){return n!=null&&n._defaulted?n:{...S(this,ll).mutations,...(n==null?void 0:n.mutationKey)&&this.getMutationDefaults(n.mutationKey),...n,_defaulted:!0}}clear(){S(this,ft).clear(),S(this,al).clear()}},ft=new WeakMap,al=new WeakMap,ll=new WeakMap,ns=new WeakMap,as=new WeakMap,il=new WeakMap,ls=new WeakMap,is=new WeakMap,v0),qv=_.createContext(void 0),cs=n=>{const l=_.useContext(qv);if(!l)throw new Error("No QueryClient set, use QueryClientProvider to set one");return l},RE=({client:n,children:l})=>(_.useEffect(()=>(n.mount(),()=>{n.unmount()}),[n]),f.jsx(qv.Provider,{value:n,children:l})),Gv=_.createContext(!1),Iv=()=>_.useContext(Gv);Gv.Provider;function zE(){let n=!1;return{clearReset:()=>{n=!1},reset:()=>{n=!0},isReset:()=>n}}var DE=_.createContext(zE()),Qv=()=>_.useContext(DE),Kv=(n,l,s)=>{const o=s!=null&&s.state.error&&typeof n.throwOnError=="function"?uh(n.throwOnError,[s.state.error,s]):n.throwOnError;(n.suspense||n.experimental_prefetchInRender||o)&&(l.isReset()||(n.retryOnMount=!1))},Vv=n=>{_.useEffect(()=>{n.clearReset()},[n])},Yv=({result:n,errorResetBoundary:l,throwOnError:s,query:o,suspense:u})=>n.isError&&!l.isReset()&&!n.isFetching&&o&&(u&&n.data===void 0||uh(s,[n.error,o])),$v=n=>{if(n.suspense){const s=u=>u==="static"?u:Math.max(u??1e3,1e3),o=n.staleTime;n.staleTime=typeof o=="function"?(...u)=>s(o(...u)):s(o),typeof n.gcTime=="number"&&(n.gcTime=Math.max(n.gcTime,1e3))}},UE=(n,l)=>n.isLoading&&n.isFetching&&!l,Ef=(n,l)=>(n==null?void 0:n.suspense)&&l.isPending,jf=(n,l,s)=>l.fetchOptimistic(n).catch(()=>{s.clearReset()});function LE({queries:n,...l},s){const o=cs(),u=Iv(),d=Qv(),h=_.useMemo(()=>n.map(A=>{const j=o.defaultQueryOptions(A);return j._optimisticResults=u?"isRestoring":"optimistic",j}),[n,o,u]);h.forEach(A=>{$v(A);const j=o.getQueryCache().get(A.queryHash);Kv(A,d,j)}),Vv(d);const[p]=_.useState(()=>new NE(o,h,l)),[y,g,x]=p.getOptimisticResult(h,l.combine),v=!u&&l.subscribed!==!1;_.useSyncExternalStore(_.useCallback(A=>v?p.subscribe(ht.batchCalls(A)):qt,[p,v]),()=>p.getCurrentResult(),()=>p.getCurrentResult()),_.useEffect(()=>{p.setQueries(h,l)},[h,l,p]);const M=y.some((A,j)=>Ef(h[j],A))?y.flatMap((A,j)=>{const O=h[j];if(O&&Ef(O,A)){const z=new dh(o,O);return jf(O,z,d)}return[]}):[];if(M.length>0)throw Promise.all(M);const N=y.find((A,j)=>{const O=h[j];return O&&Yv({result:A,errorResetBoundary:d,throwOnError:O.throwOnError,query:o.getQueryCache().get(O.queryHash),suspense:O.suspense})});if(N!=null&&N.error)throw N.error;return g(x())}function BE(n,l,s){var M,N,A,j;const o=Iv(),u=Qv(),d=cs(),h=d.defaultQueryOptions(n);(N=(M=d.getDefaultOptions().queries)==null?void 0:M._experimental_beforeQuery)==null||N.call(M,h);const p=d.getQueryCache().get(h.queryHash),y=n.subscribed!==!1;h._optimisticResults=o?"isRestoring":y?"optimistic":void 0,$v(h),Kv(h,u,p),Vv(u);const g=!d.getQueryCache().get(h.queryHash),[x]=_.useState(()=>new l(d,h)),v=x.getOptimisticResult(h),E=!o&&y;if(_.useSyncExternalStore(_.useCallback(O=>{const z=E?x.subscribe(ht.batchCalls(O)):qt;return x.updateResult(),z},[x,E]),()=>x.getCurrentResult(),()=>x.getCurrentResult()),_.useEffect(()=>{x.setOptions(h)},[h,x]),Ef(h,v))throw jf(h,x,u);if(Yv({result:v,errorResetBoundary:u,throwOnError:h.throwOnError,query:p,suspense:h.suspense}))throw v.error;if((j=(A=d.getDefaultOptions().queries)==null?void 0:A._experimental_afterQuery)==null||j.call(A,h,v),h.experimental_prefetchInRender&&!uo.isServer()&&UE(v,o)){const O=g?jf(h,x,u):p==null?void 0:p.promise;O==null||O.catch(qt).finally(()=>{x.updateResult()})}return h.notifyOnChangeProps?v:x.trackResult(v)}function en(n,l){return BE(n,dh)}function HE(n,l){const s=cs(),[o]=_.useState(()=>new CE(s,n));_.useEffect(()=>{o.setOptions(n)},[o,n]);const u=_.useSyncExternalStore(_.useCallback(h=>o.subscribe(ht.batchCalls(h)),[o]),()=>o.getCurrentResult(),()=>o.getCurrentResult()),d=_.useCallback((h,p)=>{o.mutate(h,p).catch(qt)},[o]);if(u.error&&uh(o.options.throwOnError,[u.error]))throw u.error;return{...u,mutate:d,mutateAsync:u.mutate}}const vb=n=>{let l;const s=new Set,o=(g,x)=>{const v=typeof g=="function"?g(l):g;if(!Object.is(v,l)){const E=l;l=x??(typeof v!="object"||v===null)?v:Object.assign({},l,v),s.forEach(M=>M(l,E))}},u=()=>l,p={setState:o,getState:u,getInitialState:()=>y,subscribe:g=>(s.add(g),()=>s.delete(g))},y=l=n(o,u,p);return p},qE=(n=>n?vb(n):vb),GE=n=>n;function IE(n,l=GE){const s=Qr.useSyncExternalStore(n.subscribe,Qr.useCallback(()=>l(n.getState()),[n,l]),Qr.useCallback(()=>l(n.getInitialState()),[n,l]));return Qr.useDebugValue(s),s}const xb=n=>{const l=qE(n),s=o=>IE(l,o);return Object.assign(s,l),s},Fv=(n=>n?xb(n):xb),En=Fv(n=>({byKey:{},noticeByKey:{},watchedByKey:{},start:(l,s)=>n(o=>({byKey:{...o.byKey,[l]:s},noticeByKey:_b(o.noticeByKey,l),watchedByKey:{...o.watchedByKey,[l]:s.cropKey}})),finish:l=>n(s=>{if(!(l in s.byKey))return s;const o={...s.byKey};return delete o[l],{byKey:o}}),notice:(l,s)=>n(o=>o.noticeByKey[l]===s?o:{noticeByKey:{...o.noticeByKey,[l]:s}}),clearNotice:l=>n(s=>l in s.noticeByKey?{noticeByKey:_b(s.noticeByKey,l)}:s)}));function _b(n,l){if(!(l in n))return n;const s={...n};return delete s[l],s}function QE(n){return En(l=>l.noticeByKey[n])}const wb=1e3,KE=6e4;function VE({getJobStatus:n}){const l=En(s=>s.byKey);return f.jsx(f.Fragment,{children:Object.entries(l).map(([s,o])=>f.jsx(YE,{entryKey:s,entry:o,getJobStatus:n},o.jobId))})}function YE({entryKey:n,entry:l,getJobStatus:s}){var j,O;const o=En(z=>z.finish),u=En(z=>z.notice),{jobId:d,propertyId:h,cropKey:p,mobileJobId:y,mobileCropKey:g,apply:x,revert:v}=l,E=en({queryKey:["image-crop-job",h,d],queryFn:()=>s(h,d),refetchInterval:z=>{var Y;const D=(Y=z.state.data)==null?void 0:Y.status;return D==="succeeded"||D==="failed"?!1:wb}}),M=en({queryKey:["image-crop-job",h,y],queryFn:()=>s(h,y),enabled:!!y,refetchInterval:z=>{var Y;const D=(Y=z.state.data)==null?void 0:Y.status;return D==="succeeded"||D==="failed"?!1:wb}}),N=(j=E.data)==null?void 0:j.status,A=y?(O=M.data)==null?void 0:O.status:void 0;return _.useEffect(()=>{!(N==="succeeded"||N==="failed")||!(!y||A==="succeeded"||A==="failed")||(N==="failed"||A==="failed"?(v(),u(n,"failed"),o(n)):(x(p,y?g:void 0),o(n)))},[N,A,y,n,p,g,x,v,u,o]),_.useEffect(()=>{const z=setTimeout(()=>{u(n,"slow"),o(n)},KE);return()=>clearTimeout(z)},[n,u,o]),null}function $E(n){if(!n||typeof n!="object")return null;const l=n;return typeof l.job_id!="string"||typeof l.crop_key!="string"||!l.rect||typeof l.rect!="object"||typeof l.ar!="number"?null:l}function Xv(n,l){_.useEffect(()=>{var s,o;for(const u of n){const d=En.getState();if(u.key in d.byKey||d.watchedByKey[u.key]===u.pending.crop_key)continue;const h=l(u);d.start(u.key,{jobId:u.pending.job_id,propertyId:u.propertyId,cropKey:u.pending.crop_key,mobileJobId:(s=u.pending.mobile)==null?void 0:s.job_id,mobileCropKey:(o=u.pending.mobile)==null?void 0:o.crop_key,instanceId:u.instanceId,slotId:u.slotId,itemIndex:u.itemIndex,apply:h.apply,revert:h.revert})}})}const ec={dimOpacity:.35,grayscale:.4,transitionMs:120,spinner:{diameter:28,stroke:3,trackColor:"rgba(20,18,13,.18)",headColor:"rgba(20,18,13,.6)",spinDurationMs:800}},FE={opacity:ec.dimOpacity,filter:`grayscale(${ec.grayscale})`,transition:`opacity ${ec.transitionMs}ms`};function XE(){if(typeof document>"u"||document.getElementById("recrop-spin-kf"))return;const n=document.createElement("style");n.id="recrop-spin-kf",n.textContent="@keyframes recrop-spin{to{transform:rotate(360deg)}}",document.head.appendChild(n)}function Zv(){XE();const n=ec.spinner;return f.jsx("div",{"data-recrop-loading":!0,role:"status","aria-label":"Re-cropping…",className:"pointer-events-none absolute inset-0 z-[5] grid place-items-center",children:f.jsx("span",{"aria-hidden":!0,style:{width:n.diameter,height:n.diameter,border:`${n.stroke}px solid ${n.trackColor}`,borderTopColor:n.headColor,borderRadius:"50%",animation:`recrop-spin ${n.spinDurationMs}ms linear infinite`}})})}function Pv(n,l,s){const o=_.useMemo(()=>[...new Set(l.filter(d=>!!d))],[l]),u=LE({queries:o.map(d=>({queryKey:["crop-url",n,d],queryFn:()=>s(n,d),enabled:!!n,staleTime:600*1e3}))});return _.useMemo(()=>{const d=new Map;return o.forEach((h,p)=>{var g;const y=(g=u[p])==null?void 0:g.data;typeof y=="string"&&d.set(h,y)}),d},[o,u])}const Jv=_.createContext(null);function ZE({api:n,children:l}){return f.jsx(Jv.Provider,{value:n,children:l})}function Kn(){const n=_.useContext(Jv);if(!n)throw new Error("useMediaLibraryApi: missing MediaLibraryApiProvider");return n}const lc=[{extension:".pdf",mimeTypes:["application/pdf"],family:"pdf"},{extension:".csv",mimeTypes:["text/csv","application/vnd.ms-excel"],family:"spreadsheet"},{extension:".xlsx",mimeTypes:["application/vnd.openxmlformats-officedocument.spreadsheetml.sheet"],family:"spreadsheet"},{extension:".docx",mimeTypes:["application/vnd.openxmlformats-officedocument.wordprocessingml.document"],family:"text-document"},{extension:".doc",mimeTypes:["application/msword"],family:"text-document"},{extension:".txt",mimeTypes:["text/plain"],family:"text-document"},{extension:".pptx",mimeTypes:["application/vnd.openxmlformats-officedocument.presentationml.presentation"],family:"presentation"}],Wv=new Set(lc.map(n=>n.extension)),e1=new Set(lc.flatMap(n=>n.mimeTypes));function fc(n){const l=n.indexOf(";");return(l===-1?n:n.slice(0,l)).trim().toLowerCase()}function hh(n){const l=Math.max(n.lastIndexOf("/"),n.lastIndexOf("\\")),s=n.slice(l+1),o=s.lastIndexOf(".");return o<=0?"":s.slice(o).toLowerCase()}function PE(n){return fc(n).startsWith("image/")}function JE(n){return fc(n).startsWith("video/")}function t1(n,l){return Wv.has(hh(n))&&e1.has(fc(l))}function WE(n,l){return PE(l)||JE(l)||t1(n,l)}function e3(n,l){const s=hh(n),o=lc.find(h=>h.extension===s);if(o)return o.family;const u=fc(l),d=lc.find(h=>h.mimeTypes.includes(u));return d?d.family:null}const t3=[...e1,...Wv].join(","),n3="an image, a video, or a document (PDF, Word, Excel .xlsx, PowerPoint .pptx, CSV, or text)";function a3(n){switch(n){case"pdf":return{glyph:"doc",typeNoun:"PDF"};case"spreadsheet":return{glyph:"spreadsheet",typeNoun:"Spreadsheet"};case"text-document":return{glyph:"doc",typeNoun:"Document"};case"presentation":return{glyph:"presentation",typeNoun:"Presentation"}}}function l3(n,l){const s=e3(n,l),{glyph:o,typeNoun:u}=s===null?{glyph:"doc",typeNoun:"File"}:a3(s);return{glyph:o,typeNoun:u,extension:hh(n).replace(".","").toUpperCase()}}const Tn={items:[],subs:new Set};function ph(){Tn.subs.forEach(n=>n())}function i3(n){Tn.items=[n,...Tn.items],ph()}function da(n,l){Tn.items=Tn.items.map(s=>s.id===n?{...s,...l}:s),ph()}function Sb(n){Tn.items=Tn.items.filter(l=>l.id!==n),ph()}function kb(){return Tn.items}function s3(){const[,n]=_.useReducer(l=>l+1,0);return _.useEffect(()=>(Tn.subs.add(n),()=>{Tn.subs.delete(n)}),[]),Tn.items}function n1(n){return n<1024?`${n} B`:n<1048576?`${(n/1024).toFixed(0)} KB`:`${(n/1048576).toFixed(1)} MB`}const o3=Fv(n=>({byPlan:{},start:(l,s,o)=>n(u=>({byPlan:{...u.byPlan,[l]:{jobId:s,propertyId:o}}})),advance:(l,s)=>n(o=>{const u=o.byPlan[l];return!u||u.jobId===s?o:{byPlan:{...o.byPlan,[l]:{...u,jobId:s}}}}),finish:l=>n(s=>{if(!(l in s.byPlan))return s;const o={...s.byPlan};return delete o[l],{byPlan:o}})})),r3=5,Eb=500*1024*1024;function jb(n){return`${Math.round(n/(1024*1024))} MB`}function a1(n){return n.size>Eb?{ok:!1,message:`This file is ${jb(n.size)}. The maximum upload size is ${jb(Eb)}.`}:WE(n.name,n.type)?{ok:!0}:{ok:!1,message:`This file type (${n.type||"unknown"}) isn't supported. Upload ${n3}.`}}function c3(n){const l=a1(n);return l.ok?n.type.startsWith("image/")?{ok:!0}:{ok:!1,message:`A floor plan has to be an image. This file is ${n.type||"of an unknown type"}.`}:l}function u3(n){return n.committedUploadId?{kind:"replace",uploadId:n.committedUploadId}:n.attempt?{kind:"resume",attempt:n.attempt}:{kind:"fresh"}}function d3(n){return{id:n.id,kind:"document",name:n.name,size:n.size_bytes>0?n1(n.size_bytes):"",src:n.preview_url,mime:n.mime}}function l1(n){var o;const{getDocuments:l}=Kn(),s=en({queryKey:["documents",n],queryFn:()=>l(n),enabled:!!n});return{items:(((o=s.data)==null?void 0:o.documents)??[]).map(d3),isLoading:s.isLoading}}function f3(n){var s;const l=new Map;for(const o of n){const u=((s=o.source)==null?void 0:s.upload_id)??o.id;l.has(u)||l.set(u,o)}return[...l.entries()].map(([o,u])=>({id:o,kind:"plan",name:u.display_label||"Floor plan",size:"",src:u.thumbnail_url}))}function h3(n){var o;const{getFloorplans:l}=Kn(),s=en({queryKey:["floorplan-library",n],queryFn:()=>l(n),enabled:!!n});return{items:f3(((o=s.data)==null?void 0:o.floorplans)??[]),isLoading:s.isLoading}}async function p3(n,l,s){let o=0;const u=Math.max(1,Math.min(l,n.length)),d=Array.from({length:u},async()=>{for(;o<n.length;){const h=o++;try{await s(n[h],h)}catch{}}});await Promise.all(d)}function m3(n){return{id:n.id,kind:"plan",name:n.display_label,size:"",src:n.thumbnail_url,caption:null,ready:n.ready}}function i1(n){var o;const{getFloorplans:l}=Kn(),s=en({queryKey:["floorplan-library",n],queryFn:()=>l(n),enabled:!!n});return{items:(((o=s.data)==null?void 0:o.floorplans)??[]).map(m3),isLoading:s.isLoading}}function y3(n){var o;const{getFloorplans:l}=Kn();return((o=en({queryKey:["floorplan-library",n],queryFn:()=>l(n),enabled:!!n}).data)==null?void 0:o.floorplans)??[]}function g3(n,l){n.invalidateQueries({queryKey:["floorplan-library",l]}),n.invalidateQueries({queryKey:["floorplans",l]})}function s1(n){return n.type.startsWith("video/")?"video":t1(n.name,n.type)?"document":"photo"}function b3(n){switch(n){case"photo":case"video":case"document":return n;case"floor_plan":case"link":case null:return null}}function v3(n,l){return[`${n}s`,l]}function x3(n){const{deleteUpload:l,getUploads:s,postUploadWithProgress:o}=Kn(),u=cs(),d=s3(),h=_.useCallback((v,E,M)=>(da(v,{status:"uploading",error:void 0}),o(n,E,()=>{},{...M,onAttempt:N=>da(v,{attempt:N??void 0})}).then(N=>{da(v,{id:N.id,status:"classifying",committedUploadId:N.id})}).catch(N=>{da(v,{status:"failed",error:N instanceof Error?N.message:"Upload failed"})})),[n,o]),p=_.useCallback((v,E)=>{const M=v?Array.from(v):[],N=(E==null?void 0:E.declaredType)==="floor_plan",A=[];for(const j of M){const O=crypto.randomUUID(),z=N?c3(j):a1(j),D=N?"plan":s1(j);i3({id:O,kind:D,name:j.name,size:n1(j.size),src:D==="photo"||D==="plan"?URL.createObjectURL(j):"",status:z.ok?"uploading":"failed",error:z.ok?void 0:z.message,file:j}),z.ok&&A.push({tempId:O,file:j})}p3(A,r3,async j=>{await h(j.tempId,j.file,E)})},[h]),y=_.useCallback(v=>{const E=kb().find(A=>A.id===v);if(!E)return;const M=E.kind==="plan"?{declaredType:"floor_plan"}:void 0,N=u3(E);if(N.kind==="resume"){h(v,E.file,{...M,attempt:N.attempt});return}if(N.kind==="fresh"){h(v,E.file,M);return}da(v,{status:"uploading",error:void 0}),l(n,N.uploadId).then(()=>(da(v,{attempt:void 0,committedUploadId:void 0}),h(v,E.file,M))).catch(A=>{da(v,{status:"failed",error:A instanceof Error?A.message:"Upload failed"})})},[h,l,n]),g=d.some(v=>v.status==="classifying"),x=en({queryKey:["editor-upload-status",n],queryFn:()=>s(n),enabled:g,refetchInterval:g?1500:!1});return _.useEffect(()=>{var A;const v=(A=x.data)==null?void 0:A.uploads;if(!v)return;const E=new Map(v.map(j=>[j.id,j])),M=new Set;let N=!1;for(const j of kb()){if(j.status!=="classifying")continue;const O=E.get(j.id);if(!O)continue;if(O.status==="failed"){da(j.id,{status:"failed",error:"Processing failed"});continue}if(j.kind==="plan"){Sb(j.id),N=!0;continue}if(O.status!=="ready")continue;const z=b3(O.type);if(z===null){da(j.id,{status:"not_photo",error:`Classified as ${O.type??"non-photo"}`});continue}Sb(j.id),M.add(z)}for(const j of M)u.invalidateQueries({queryKey:v3(j,n)});N&&g3(u,n)},[x.data,n,u]),{items:d,addFiles:p,retry:y}}function Fr(n){return typeof n=="string"&&n.length>0?n:null}function _3(n){var s,o,u,d;const l=[];for(const h of n){const p=Fr((s=h.fields)==null?void 0:s.name),y=Fr((o=h.fields)==null?void 0:o.avatar_upload_id);y&&h.avatar_url&&l.push({id:y,kind:"library",name:p?`${p} — headshot`:"Headshot",size:"",src:h.avatar_url,caption:null});const g=Fr((u=h.fields)==null?void 0:u.logo_dark_upload_id);g&&h.logo_dark_url&&l.push({id:g,kind:"library",name:p?`${p} — logo (dark)`:"Logo (dark)",size:"",src:h.logo_dark_url,caption:null});const x=Fr((d=h.fields)==null?void 0:d.logo_light_upload_id);x&&h.logo_light_url&&l.push({id:x,kind:"library",name:p?`${p} — logo (light)`:"Logo (light)",size:"",src:h.logo_light_url,caption:null})}return l}const w3=["library-items","contact"];function o1(){var s;const{listLibraryItems:n}=Kn(),l=en({queryKey:w3,queryFn:()=>n("contact")});return{items:_3(((s=l.data)==null?void 0:s.items)??[]),isLoading:l.isLoading}}function S3(n){return{id:n.id,kind:"video",name:n.name,size:"",src:n.poster_url,caption:n.caption??null,ready:n.ready,durationMs:n.duration_ms,videoSource:n.source,...n.provider!==null?{provider:n.provider}:{}}}function So(n){var o;const{getVideos:l}=Kn(),s=en({queryKey:["videos",n],queryFn:()=>l(n),enabled:!!n});return{items:(((o=s.data)==null?void 0:o.videos)??[]).map(S3),isLoading:s.isLoading}}function r1(n){if(n==null||!Number.isFinite(n)||n<0)return"";const l=Math.round(n/1e3),s=Math.floor(l/60),o=l%60;return`${s}:${String(o).padStart(2,"0")}`}function k3(n){return{id:n.id,kind:"photo",name:n.name,size:"",src:n.thumbnail_url,caption:n.caption??null}}function mh(n){var o;const{getPhotos:l}=Kn(),s=en({queryKey:["photos",n],queryFn:()=>l(n),enabled:!!n});return{items:(((o=s.data)==null?void 0:o.photos)??[]).map(k3),isLoading:s.isLoading}}function hc(n){const{items:l}=mh(n),{items:s}=i1(n),{items:o}=o1(),{items:u}=So(n);return _.useMemo(()=>{const d=new Map;for(const h of[...l,...s,...o,...u])h.src&&d.set(h.id,h.src);return d},[l,s,o,u])}const Mf=(n,l)=>["floorplan-source-page",n,l];function E3(n){const{recropFloorplan:l}=Kn(),s=o3(u=>u.start),o=cs();return HE({mutationFn:({planId:u,bbox:d})=>l(n,u,d),onMutate:async({planId:u,bbox:d})=>{const h=Mf(n,u);await o.cancelQueries({queryKey:h});const p=o.getQueryData(h);return o.setQueryData(h,y=>y&&{...y,source_bbox:d}),{prev:p,planId:u}},onError:(u,d,h)=>{h!=null&&h.prev&&o.setQueryData(Mf(n,h.planId),h.prev)},onSuccess:(u,d)=>s(d.planId,u.job_id,n)})}function j3(n){return{id:n.id,kind:"tour",name:n.name,size:"",src:n.poster_url,caption:n.caption??null,ready:n.ready,provider:n.provider}}function yh(n){var o;const{getTours:l}=Kn(),s=en({queryKey:["tours",n],queryFn:()=>l(n),enabled:!!n});return{items:(((o=s.data)==null?void 0:o.tours)??[]).map(j3),isLoading:s.isLoading}}function M3(n,l,s){return n&&l?{w:n,h:l}:s?{w:s.w,h:s.h}:null}function C3(n){const[l,s]=_.useState(0),[o,u]=_.useState(null);_.useEffect(()=>{if(!n)return;let p=!0;const y=new Image;return y.onload=()=>{p&&u({src:n,attempt:l,size:{w:y.naturalWidth||1,h:y.naturalHeight||1}})},y.onerror=()=>{p&&u({src:n,attempt:l,size:null})},y.src=n,()=>{p=!1}},[n,l]);const d=_.useCallback(()=>{s(p=>p+1)},[]),h=o&&o.src===n&&o.attempt===l?o:null;return{size:(h==null?void 0:h.size)??null,failed:h!==null&&h.size===null,retry:d}}const A3=16,c1="Crop floor plan",N3="Loading floor plan…",T3="Couldn't load this floor plan's source page.";function Mb({tone:n,message:l,stageClassName:s,onClose:o,onRetry:u}){return f.jsxs(cn.Shell,{open:!0,variant:"page",onClose:o,children:[f.jsxs("div",{className:cn.head,children:[f.jsx("div",{className:cn.titles,children:f.jsx("h2",{className:cn.title,children:c1})}),f.jsx("button",{type:"button",className:cn.close,onClick:o,"aria-label":"Close",children:f.jsx(cn.CloseIcon,{})})]}),f.jsxs("div",{role:n==="failed"?"alert":"status",className:ye(s,"flex flex-col items-center justify-center gap-3 px-6 text-center"),children:[n==="pending"&&f.jsx("span",{"aria-hidden":!0,className:"size-5 animate-spin rounded-full border-2 border-line border-t-accent [animation-duration:0.7s]"}),f.jsx("p",{className:"m-0 text-[13px] text-ink-2",children:l})]}),f.jsx("div",{className:cn.foot,children:f.jsxs("div",{className:cn.actions,children:[f.jsx("button",{type:"button",className:cn.buttonGhost,onClick:o,children:"Cancel"}),u?f.jsx("button",{type:"button",className:cn.buttonPrimary,onClick:u,children:"Try again"}):null]})})]})}function O3({propertyId:n,planId:l,getSourcePage:s,onClose:o,stageClassName:u="h-[60vh] max-h-[620px]"}){const d=en({queryKey:Mf(n,l),queryFn:()=>s(n,l)}),h=d.data,p=C3(h&&!(h.source_width&&h.source_height)?h.source_url:null),y=M3(h==null?void 0:h.source_width,h==null?void 0:h.source_height,p.size),g=E3(n);if(!d.isFetching&&(d.isError||p.failed))return f.jsx(Mb,{tone:"failed",message:T3,stageClassName:u,onClose:o,onRetry:()=>{p.retry(),d.refetch()}});if(!h||!y)return f.jsx(Mb,{tone:"pending",message:N3,stageClassName:u,onClose:o});const x=h.source_bbox?nE(h.source_bbox,y.w,y.h):{nx:0,ny:0,nw:1,nh:1};return f.jsx(ih,{chrome:cn,src:h.source_url,mode:"free",aspect:y.w/y.h,variant:"page",stageClassName:u,title:c1,seed:{rect:x},onClose:o,onApply:v=>{o(),g.mutate({planId:l,bbox:iE(v.rect,y.w,y.h,A3)})}})}const R3=["Basement","Ground","1st floor","2nd floor","3rd floor","4th floor","Penthouse"],z3="fixed overflow-y-auto rounded-[calc(8*var(--content))] border border-line bg-white py-1 shadow-[0_16px_38px_-12px_rgba(20,18,13,0.4)]",qd=240,u1=ye(ot,"flex w-full items-center rounded-none px-2.5 py-2 text-left text-body text-ink hover:bg-accent-soft data-[active=true]:bg-accent-soft"),D3=ye(u1,"text-accent"),lo=4,Cb=140,io=8,U3="flex w-full items-stretch rounded-[calc(5*var(--content))] border border-transparent bg-[#f3f1ea] transition-[background,border-color,box-shadow] duration-[120ms] hover:bg-[#ece9df] focus-within:border-ink-3 focus-within:bg-white focus-within:shadow-[0_0_0_3px_rgba(20,18,13,0.05)]",L3="min-w-0 flex-1 appearance-none border-0 bg-transparent px-1.75 py-1 text-[length:calc(11.5*var(--content))] font-semibold text-ink-2 placeholder:font-medium placeholder:text-ink-4";function B3({value:n,onChange:l,presets:s,label:o,placeholder:u="Label…",ariaLabel:d,compact:h=!1}){const[p,y]=_.useState(!1),[g,x]=_.useState(""),[v,E]=_.useState(0),[M,N]=_.useState(null),A=_.useId(),j=_.useRef(null),O=_.useRef(null),z=g.trim().toLowerCase(),D=p&&z?s.filter(F=>F.toLowerCase().includes(z)):s,Y=s.some(F=>F.toLowerCase()===z),W=g.trim().length>0&&!Y,ee=D.length+(W?1:0),ae=_.useCallback(()=>{if(!O.current)return;const F=O.current.getBoundingClientRect(),w=window.innerHeight-F.bottom-lo-io;N({rect:F,above:w<qd})},[]);function U(){ae(),y(!0)}function re(F){l(F.trim()),de()}function de(){y(!1),x(""),E(0)}function ce(F){if(!p&&(F.key==="ArrowDown"||F.key==="Enter")){U();return}if(F.key==="Escape"){de();return}F.key==="ArrowDown"?(F.preventDefault(),E(w=>Math.min(ee-1,w+1))):F.key==="ArrowUp"?(F.preventDefault(),E(w=>Math.max(0,w-1))):F.key==="Enter"&&(F.preventDefault(),v<D.length?re(D[v]):W&&re(g))}function ie(F){var te,P;const w=F.relatedTarget,Z=(te=j.current)==null?void 0:te.contains(w),ue=(P=document.getElementById(A))==null?void 0:P.contains(w);!Z&&!ue&&de()}_.useEffect(()=>{if(p)return window.addEventListener("scroll",ae,!0),window.addEventListener("resize",ae),()=>{window.removeEventListener("scroll",ae,!0),window.removeEventListener("resize",ae)}},[p,ae]);const L=h?U3:ye(_o,p&&"border-accent"),G=h?L3:ss;return f.jsxs("div",{className:ye(!h&&Qn),ref:j,onBlurCapture:ie,children:[o&&!h&&f.jsx("span",{className:va,children:o}),f.jsx("div",{className:L,ref:O,children:f.jsx("input",{className:G,value:p?g:n,placeholder:n||u,onFocus:U,onChange:F=>{x(F.target.value),p||U(),E(0)},onKeyDown:ce,"aria-label":d??o??"Label","aria-expanded":p,"aria-controls":A,role:"combobox"})}),p&&ee>0&&M&&lh.createPortal(f.jsxs("div",{className:z3,id:A,role:"listbox",style:{left:Math.max(io,Math.min(M.rect.left,window.innerWidth-Math.max(M.rect.width,Cb)-io)),...M.above?{bottom:window.innerHeight-M.rect.top+lo,maxHeight:Math.min(M.rect.top-lo-io,qd)}:{top:M.rect.bottom+lo,maxHeight:Math.min(window.innerHeight-M.rect.bottom-lo-io,qd)},minWidth:Math.max(M.rect.width,Cb),zIndex:wv+200},children:[D.map((F,w)=>f.jsx("button",{type:"button",role:"option","aria-selected":w===v,"data-active":w===v,className:u1,onMouseEnter:()=>E(w),onMouseDown:Z=>Z.preventDefault(),onClick:()=>re(F),children:f.jsx("span",{className:"truncate",children:F})},F)),W&&f.jsx("button",{type:"button",role:"option","aria-selected":v===D.length,"data-active":v===D.length,className:D3,onMouseEnter:()=>E(D.length),onMouseDown:F=>F.preventDefault(),onClick:()=>re(g),children:f.jsxs("span",{className:"truncate",children:["Use “",g.trim(),"”"]})})]}),document.body)]})}const H3="group/card relative flex flex-col overflow-hidden rounded-[8px] border border-line bg-canvas transition-[border-color] duration-[120ms] hover:border-ink-4",q3="relative aspect-[4/3] touch-none select-none bg-[#fafaf6]",G3="absolute inset-0 block size-full object-contain",I3=ye("absolute inset-0 grid place-items-center font-mono text-[12px] text-ink-3",dc),Q3="absolute right-[5px] top-[5px] z-[4] flex gap-[3px] transition-opacity duration-[120ms]",K3="opacity-0 group-hover/card:opacity-100",Gd=ye(ot,"we-no-drag grid size-5 place-items-center rounded-[4px] bg-white text-ink-2 shadow-[0_1px_2px_rgba(20,18,13,0.18)] transition-[background,color] duration-[120ms] hover:bg-[#f3f1ea] hover:text-ink"),V3="hover:bg-[#fbe6e2] hover:text-[#8e2c1e]",Y3="border-t border-line-soft px-[7px] py-[6px]",$3="pointer-events-none absolute bottom-[6px] right-[6px] z-[3] grid size-[22px] place-items-center rounded-full bg-[rgba(255,255,255,0.94)] text-[11px] font-bold text-ink shadow-[0_1px_3px_rgba(20,18,13,0.25)]";function F3({src:n,alt:l="",floor:s,onFloorChange:o,onCrop:u,cropTitle:d="Crop floor plan",onRemove:h,removeTitle:p="Remove from unit",include:y,badge:g,drag:x}){const v=y?!y.on:!1,E=ye(Q3,v?"opacity-100":K3);return f.jsxs("div",{className:ye(H3,v&&"opacity-60",(x==null?void 0:x.active)&&"opacity-[0.28]"),"data-dragid":x==null?void 0:x.dataDragId,children:[f.jsxs("div",{className:ye(q3,x&&"cursor-grab",(x==null?void 0:x.active)&&"cursor-grabbing"),onPointerDown:x==null?void 0:x.onPointerDown,children:[n?f.jsx("img",{className:ye(G3,v&&"grayscale"),src:n,alt:l,draggable:!1}):f.jsx("div",{className:I3}),f.jsxs("span",{className:E,children:[u&&f.jsx("button",{type:"button",className:Gd,title:d,onClick:u,children:f.jsx(ze.crop,{})}),h&&f.jsx("button",{type:"button",className:ye(Gd,V3),title:p,onClick:h,children:f.jsx(ze.trash,{})}),y&&f.jsx("button",{type:"button",className:Gd,title:y.on?"Hide from site":"Show on site","aria-pressed":y.on,onClick:y.onToggle,children:y.on?f.jsx(ze.eye,{}):f.jsx(ze.eyeOff,{})})]}),g!=null&&f.jsx("span",{className:$3,children:g})]}),f.jsx("div",{className:Y3,children:f.jsx(B3,{value:s,onChange:o,presets:R3,placeholder:"Floor",ariaLabel:"Floor label",compact:!0})})]})}const X3=24,Z3=14;function P3(n){return n.length<=X3?n:`${n.slice(0,Z3)}…${n.slice(-9)}`}function J3(n,l,s){return n?`${P3(n)}`:`Floor plan ${l}`}function W3(n){var s;if(n.fields!=null)return"row-editor";const l=(s=n.element)==null?void 0:s.type;return l==="image"||l==="video"||l==="tour"?"gallery":l==="poi"?"poi-curation":l==="document"?"document-list":"scalar-list"}function gh(n){const l=W3(n);return{editor:l,granularity:l==="row-editor"?"item":"unit"}}function d1(n){if(n!==null&&typeof n=="object"&&!Array.isArray(n)){const l=n;if(typeof l.asset_id=="string")return{asset_id:l.asset_id}}return{asset_id:""}}function ej(n){return n.map(d1).filter(l=>l.asset_id!=="")}function pc(n){switch(n.kind){case"document":return l3(n.name,n.mime??"");case"video":return{glyph:"video",typeNoun:"Video",extension:""};case"photo":case"plan":case"library":return{glyph:"image",typeNoun:"Image",extension:""};case"tour":return{glyph:"video",typeNoun:"3D tour",extension:""}}}function tj(n){return[pc(n).typeNoun,n.size].filter(Boolean).join(" · ")}function nj(n){const l=new Map;for(const s of n)for(const o of s)l.set(o.id,o);return l}function f1(n){const{items:l}=l1(n),{items:s}=mh(n),{items:o}=h3(n),{items:u}=So(n),d=nj([s,o,u,l]);return h=>d.get(h)}const aj="group/row relative flex min-h-12 items-center gap-2.5 rounded-[calc(8*var(--content))] border border-line bg-white px-2.5 py-2 [transition:border-color_.14s,box-shadow_.14s,background_.3s]",lj="flex min-w-0 flex-1 flex-col gap-px",ij="truncate text-[length:calc(13.5*var(--content))] text-ink",sj="truncate text-caption text-ink-3",oj="flex flex-col items-center gap-2 rounded-[calc(8*var(--content))] border border-dashed border-line px-3 py-4 text-center text-[length:calc(12.5*var(--content))] text-ink-4",rj="we-no-drag flex flex-shrink-0 items-center gap-0.75",cj="flex items-center gap-0.75 opacity-0 transition-opacity duration-[120ms] group-hover/row:opacity-100",h1="grid size-6 cursor-pointer place-items-center rounded-md border-0 bg-transparent p-0 text-ink-3 outline-none hover:bg-[#f1f0ea] hover:text-ink-2",p1="relative grid size-[calc(34*var(--content))] flex-shrink-0 place-items-center overflow-hidden rounded-[calc(6*var(--content))] border border-line bg-[#f4f3ee] text-ink-3",uj="size-full object-cover",dj="absolute bottom-0 inset-x-0 truncate bg-[rgba(15,18,9,0.55)] px-0.5 text-center text-[length:calc(7.5*var(--content))] font-bold leading-[1.5] tracking-[0.02em] text-white",fj={doc:Pf,spreadsheet:Lk,presentation:ov,image:Jf,video:dv};function ko({glyph:n,extension:l,size:s=16,className:o}){const u=fj[n];return f.jsxs(f.Fragment,{children:[f.jsx(u,{size:s,strokeWidth:1.5,className:o,style:{width:`calc(${s} * var(--content))`,height:`calc(${s} * var(--content))`}}),l&&f.jsx("span",{className:dj,children:l})]})}function hj({entry:n}){const{glyph:l,extension:s}=pc(n);return f.jsx("span",{className:p1,children:n.src?f.jsx("img",{className:uj,src:n.src,alt:"",draggable:!1}):f.jsx(ko,{glyph:l,extension:s})})}function m1({entry:n,trailing:l,onRemove:s,dragProps:o,dragging:u}){return f.jsxs("div",{...o,className:ye(aj,o&&"cursor-grab hover:border-[#d9d5c9]",u&&"cursor-grabbing border-transparent bg-accent-soft [&>*]:opacity-[0.25]"),children:[n?f.jsx(hj,{entry:n}):f.jsx("span",{className:p1,children:f.jsx(ko,{glyph:"doc",extension:""})}),f.jsxs("div",{className:lj,children:[f.jsx("span",{className:ij,title:n==null?void 0:n.name,children:(n==null?void 0:n.name)??"Document unavailable"}),f.jsx("span",{className:sj,children:n?tj(n):"This file is no longer on the property"})]}),(l!==void 0||s!==void 0)&&f.jsx("div",{className:rj,children:f.jsxs("span",{className:cj,children:[l,s&&f.jsx("button",{type:"button",className:ye(h1,"hover:bg-[#fbecea] hover:text-danger"),title:"Remove",onClick:s,children:f.jsx(ze.trash,{})})]})})]})}function pj({label:n,onAdd:l}){return f.jsxs("div",{className:oj,children:[f.jsx("span",{className:"text-ink-4",children:f.jsx(ko,{glyph:"doc",extension:"",size:22})}),f.jsx("span",{children:"No document yet"}),f.jsxs("button",{type:"button",className:"inline-flex h-6.5 cursor-pointer items-center gap-1.25 rounded-full border-0 bg-accent pl-2.25 pr-2.75 text-[length:calc(11.5*var(--content))] font-semibold text-white transition-[background] duration-[120ms] hover:bg-accent-ink",onClick:l,children:[f.jsx(ze.plus,{})," ",n]})]})}const y1=_.createContext(null);function mj({ports:n,children:l}){return f.jsx(y1.Provider,{value:n,children:l})}function Vn(){const n=_.useContext(y1);if(!n)throw new Error("useSlotEditorPorts: missing SlotEditorPortsProvider");return n}function Dl(n){return Vn().useEditorStore(n)}function yj(){return Vn().api}function g1(){return Vn()}function Cf(n){var l;return n===void 0?"Link":((l=Xl[n])==null?void 0:l.label)??"Link"}function ic(n){return n.kind==="tour"?Cf(n.provider):n.kind!=="video"?"":n.videoSource==="link"?Cf(n.provider):n.ready===!1?"Processing…":r1(n.durationMs)||"Video"}function bh({kind:n,size:l}){return n==="tour"?f.jsx(ze.tour,{size:l}):f.jsx(ze.play,{size:l})}const gj=ye(ot,"inline-flex items-center gap-1.25 rounded-sm bg-[rgba(255,255,255,0.94)] px-2.5 py-1.5 text-[length:calc(11.5*var(--content))] font-semibold text-ink transition-[background] duration-[120ms] hover:bg-white"),bj="flex items-center justify-between gap-2 px-0.5 text-caption text-ink-3",vj="text-caption font-medium text-ink-4",xj="16 / 9",_j="relative block w-full overflow-hidden rounded-[calc(9*var(--content))] bg-[#e6e3da]",b1="block size-full object-cover",wj="pointer-events-none absolute bottom-1.25 left-1.25 z-[3] rounded-full bg-[rgba(15,18,9,0.72)] px-1.5 py-0.5 text-[10.5px] font-semibold tabular-nums text-white group-data-[ghost]/tile:hidden";function v1({kind:n,label:l,poster:s,hasSelection:o,addLabel:u,onPick:d,status:h,metaName:p,metaDetail:y,emptyText:g,noPosterText:x,children:v}){return f.jsxs("div",{className:eh,children:[f.jsxs("div",{className:Qn,children:[f.jsx(nh,{children:l}),f.jsxs("div",{className:"relative h-72.5 overflow-hidden rounded-[calc(9*var(--content))] bg-[#e6e3da]",children:[s?f.jsx("img",{className:"size-full object-cover",src:s,alt:""}):f.jsxs("div",{className:ye("flex size-full flex-col items-center justify-center gap-1.5 text-small text-ink-3",dc),children:[o?f.jsx(bh,{kind:n,size:22}):f.jsx(ze.up,{}),f.jsx("span",{children:o?x:g})]}),f.jsxs("div",{className:"absolute inset-x-0 bottom-0 flex items-center justify-between bg-[linear-gradient(to_top,rgba(15,18,9,0.55),transparent)] p-2.5",children:[f.jsx("button",{type:"button",className:gj,onClick:d,children:o?f.jsxs(f.Fragment,{children:[f.jsx(ze.swap,{})," Replace"]}):f.jsxs(f.Fragment,{children:[f.jsx(ze.up,{})," ",u]})}),h&&f.jsx("span",{className:vj,children:h})]})]})]}),p!==void 0&&f.jsxs("div",{className:bj,children:[f.jsx("span",{className:"truncate",children:p}),y&&f.jsx("span",{className:"shrink-0 tabular-nums",children:y})]}),v]})}function x1({kind:n,poster:l,index:s,ghost:o,badge:u,overlays:d,placeholderClassName:h}){return f.jsxs("span",{className:ye(_j,o&&"opacity-[0.28]"),style:{aspectRatio:xj},children:[l?f.jsx("img",{className:b1,src:l,alt:"",draggable:!1}):f.jsxs("span",{className:ye(h,"relative"),children:[f.jsx("span",{className:"absolute inset-0 grid place-items-center text-ink-3 opacity-40",children:f.jsx(bh,{kind:n,size:22})}),f.jsx("span",{className:"relative",children:s+1})]}),d,u&&f.jsx("span",{className:wj,children:u})]})}function _1({poster:n,index:l,placeholderClassName:s}){return n?f.jsx("img",{className:b1,src:n,alt:"",draggable:!1}):f.jsx("div",{className:s,children:l+1})}function Af(n){if(n===void 0)return"Not a valid URL";const l=Object.entries(Xl).find(([o])=>o===n);if(l)return`Needs a ${l[1].label} link`;const s=w1(n);return s.length>0?`Needs a ${n} link (${s.join(", ")})`:`Needs a ${n} link`}function w1(n){return Object.values(Xl).filter(l=>l.kind===n).map(l=>l.label)}function Sj(n){try{return new URL(n)}catch{return null}}function Nf(n){const l=n.trim();return l&&(/^https?:\/\//i.test(l)?l:`https://${l}`)}function Tf(n){const l=Sj(n);if(l===null||l.protocol!=="http:"&&l.protocol!=="https:")return!1;const s=l.hostname;return s.includes(".")&&!s.startsWith(".")&&!s.endsWith(".")}const kj={photo:"photos",plan:"floor plans",library:"library images",video:"videos",tour:"tours",document:"documents"},Ej={photo:"Photos",plan:"Floor plans",library:"Library",video:"Videos",tour:"Tours",document:"Documents"},jj={video:"video",tour:"tour"},Mj=["photo","plan","video","document"];function Cj(n){return n==="video"?"video/*":n==="document"?t3:"image/*"}function Id(n){return n.kind==="plan"&&n.ready===!1||n.kind==="tour"&&n.ready===!1?!1:!n.status||n.status==="classifying"}function Aj(n,l){const s=new Set(n);return s.has(l)?s.delete(l):s.add(l),s}function S1(n){const{items:l,addFiles:s,retry:o}=x3(n),{items:u}=mh(n),{items:d}=i1(n),{items:h}=o1(),{items:p}=So(n),{items:y}=yh(n),{items:g}=l1(n),x=new Set([...u.map(E=>E.id),...d.map(E=>E.id),...p.map(E=>E.id),...y.map(E=>E.id),...g.map(E=>E.id)]);return{items:[...l.filter(E=>!x.has(E.id)),...u,...d,...h,...p,...y,...g],addFiles:s,retry:o}}function Nj({entry:n}){if(n.kind==="document"){const{glyph:l,extension:s}=pc(n);return f.jsx(ko,{glyph:l,extension:s,size:30})}return f.jsx(bh,{kind:n.kind==="tour"?"tour":"video",size:18})}function Tj(n){switch(n){case"uploading":return"Uploading…";case"classifying":return"Processing…";case"failed":return"Failed — retry";case"not_photo":return"Not a photo"}}function Ab({primaryLabel:n,primaryDisabled:l,onPrimary:s,onClose:o}){return f.jsx("div",{className:bv,children:f.jsxs("div",{className:vv,children:[f.jsx("button",{className:_v,onClick:o,children:"Cancel"}),f.jsx("button",{className:ah,disabled:l,onClick:s,children:n})]})})}function Oj({open:n,title:l,propertyId:s,onClose:o,footer:u,selectedIds:d,onCellClick:h,onCellDoubleClick:p,initialFilter:y,kinds:g,disabledKinds:x,videoSources:v,onPickOne:E}){const{items:M,addFiles:N,retry:A}=S1(s),j=cs(),{api:O,capabilities:z}=g1(),D=g??["photo","plan","library","video"],[Y,W]=_.useState(""),ee=x??[],ae=D.find(T=>!ee.includes(T))??D[0]??"photo",[U,re]=_.useState(D.includes(y)&&!ee.includes(y)?y:ae),de=_.useRef(null),ce=(v==null?void 0:v.includes("link"))??!1,ie=U==="video"&&!ce?null:jj[U]??null,L=Y.trim().toLowerCase(),G=M.filter(T=>T.kind===U&&T.name.toLowerCase().includes(L)&&(ce||T.videoSource!=="link")),[F,w]=_.useState(""),[Z,ue]=_.useState(null),[te,P]=_.useState(!1),k=async()=>{const T=F.trim();if(!T||te||ie===null)return;const B=Nf(T);if(!Tf(B)||!nf(ie,B)){ue(Af(ie));return}const q=P0(B);if(q===null){ue(Af(ie));return}ue(null),P(!0);try{const V=await O.postLink(s,B);await j.invalidateQueries({queryKey:[ie==="tour"?"tours":"videos",s]}),w(""),E==null||E(ie==="tour"?{id:V.id,kind:"tour",name:Xl[q].label,size:"",src:"",caption:null,ready:!0,provider:q}:{id:V.id,kind:"video",name:Xl[q].label,size:"",src:"",caption:null,ready:!0,durationMs:null,videoSource:"link",provider:q})}catch{ue("Could not add that link. Try again.")}finally{P(!1)}},I=T=>{const B=T.target.files,q=U==="plan";if(N(B,q?{declaredType:"floor_plan"}:void 0),!q){const V=B==null?void 0:B[0],me=V?s1(V):"photo";D.includes(me)&&!ee.includes(me)&&re(me)}T.target.value=""},$=T=>{if(T.status==="failed"){A(T.id);return}Id(T)&&h(T)};return f.jsxs(Ev,{open:n,variant:"pick",onClose:o,children:[f.jsxs("div",{className:pv,children:[f.jsx("div",{className:mv,children:f.jsx("h2",{className:yv,children:l})}),f.jsx("button",{className:gv,onClick:o,"aria-label":"Close",children:f.jsx(ze.x,{})})]}),f.jsxs("div",{className:Wg,children:[f.jsxs("div",{className:eb,children:[f.jsx("span",{className:tb,children:f.jsx(ze.search,{})}),f.jsx("input",{className:nb,autoFocus:!0,placeholder:"Search file names…",value:Y,onChange:T=>W(T.target.value)})]}),D.length>1&&f.jsx("div",{className:C4,children:D.map(T=>{const B=ee.includes(T);return f.jsx("button",{type:"button",className:N4(U===T,B),disabled:B,"aria-disabled":B||void 0,onClick:()=>!B&&re(T),children:Ej[T]},T)})})]}),ie!==null&&f.jsxs("div",{className:Wg,children:[f.jsxs("div",{className:eb,children:[f.jsx("span",{className:tb,children:f.jsx(ze.link,{})}),f.jsx("input",{className:nb,placeholder:`Paste a ${ie} link (${w1(ie).join(" or ")})…`,value:F,disabled:te,onChange:T=>{w(T.target.value),ue(null)},onKeyDown:T=>{T.key==="Enter"&&k()}})]}),f.jsx("button",{type:"button",className:ah,disabled:te||F.trim().length===0,onClick:()=>void k(),children:te?"Adding…":"Add link"})]}),Z&&f.jsx("div",{className:"px-4 pb-1 text-[11.5px] font-medium text-[#b4342b]",role:"alert",children:Z}),f.jsx("div",{className:m4,children:f.jsxs("div",{className:y4,children:[z.upload&&Mj.includes(U)&&f.jsxs("button",{className:E4,onClick:()=>{var T;return(T=de.current)==null?void 0:T.click()},children:[f.jsx("span",{className:j4,children:f.jsx(ze.up,{})}),f.jsx("span",{className:M4,children:"Upload"})]}),G.length===0?f.jsxs("div",{className:g4,children:["No ",kj[U]," match"," ",L?`”${Y}”`:"your search","."]}):G.map(T=>f.jsxs("button",{className:b4,"data-selected":d.has(T.id)?"":void 0,"aria-disabled":!Id(T)&&T.status!=="failed",onClick:()=>$(T),onDoubleClick:p&&Id(T)?()=>p(T):void 0,children:[f.jsx("span",{className:v4,children:f.jsxs("span",{className:x4,children:[T.src?f.jsx("img",{className:T.kind==="plan"&&T.ready===!1?`${ab} opacity-40`:ab,src:T.src,alt:""}):f.jsx("span",{className:w4,children:f.jsx(Nj,{entry:T})}),d.has(T.id)&&f.jsx("span",{className:_4,children:f.jsx(ze.check,{})}),!T.status&&ic(T)&&f.jsx("span",{className:k4,children:ic(T)}),T.status&&f.jsx("span",{className:"absolute inset-x-0 bottom-0 bg-[rgba(15,18,9,0.6)] px-1.5 py-1 text-[10.5px] font-semibold text-white",title:T.error??void 0,children:Tj(T.status)}),T.kind==="tour"&&T.ready===!1&&f.jsx("span",{className:"absolute inset-x-0 bottom-0 bg-[rgba(15,18,9,0.6)] px-1.5 py-1 text-[10.5px] font-semibold text-white",role:"status",children:"Not embeddable"}),T.kind==="plan"&&T.ready===!1&&f.jsx("span",{className:"absolute inset-x-0 bottom-0 bg-[rgba(15,18,9,0.6)] px-1.5 py-1 text-[10.5px] font-semibold text-white",role:"status",children:"Processing…"})]})}),(T.kind==="document"||T.kind==="tour")&&f.jsx("span",{className:S4,title:T.name,children:T.name})]},T.id))]})}),u,z.upload&&f.jsx("input",{ref:de,type:"file",accept:Cj(U),multiple:!0,hidden:!0,onChange:I})]})}function cl(n){var j,O;const{propertyId:l,onClose:s}=n,{items:o}=S1(l),u=((j=n.kinds)==null?void 0:j.length)===1?n.kinds[0]:void 0,d=n.noun??(u==="video"||u==="tour"?u:"photo"),[h,p]=_.useState(n.mode==="single"?n.currentId??null:null),[y,g]=_.useState(()=>n.mode==="multi"?new Set(n.selectedIds.filter(Boolean)):new Set),x=z=>{n.mode==="single"?p(z.id):g(D=>Aj(D,z.id))};let v,E,M,N,A;if(n.mode==="single"){const{onPick:z,currentId:D}=n,Y=o.find(W=>W.id===h)??null;v=new Set(h?[h]:[]),E=W=>z(W),M=f.jsx(Ab,{primaryLabel:`Use ${d}`,primaryDisabled:!Y,onPrimary:()=>Y&&z(Y),onClose:s}),N=`Choose a ${d}`,A=((O=o.find(W=>W.id===D))==null?void 0:O.kind)??"photo"}else{const{onApply:z}=n;v=y,E=void 0,M=f.jsx(Ab,{primaryLabel:"Save selection",onPrimary:()=>z(o.filter(D=>y.has(D.id))),onClose:s}),N=`Choose ${d}s`,A="photo"}return f.jsx(Oj,{open:n.open,title:n.title??N,propertyId:l,onClose:s,initialFilter:n.initialFilter??A,kinds:n.kinds,disabledKinds:n.disabledKinds,videoSources:n.videoSources,onPickOne:n.mode==="single"?n.onPick:void 0,selectedIds:v,onCellClick:x,onCellDoubleClick:E,footer:M})}function Rj({slot:n,value:l,onChange:s,propertyId:o}){const[u,d]=_.useState(!1),h=(l==null?void 0:l.asset_id)??"",p=f1(o),y=h?p(h):void 0;return f.jsxs("div",{className:Qn,children:[f.jsx(nh,{children:n.label}),h?f.jsx(m1,{entry:y,trailing:f.jsx("button",{type:"button",className:h1,title:"Replace",onClick:()=>d(!0),children:f.jsx(ze.swap,{})}),onRemove:()=>s(null)}):f.jsx(pj,{label:`Add ${wo(n.label,"Document")}`,onAdd:()=>d(!0)}),u&&f.jsx(cl,{mode:"single",propertyId:o,noun:"document",kinds:["document","photo","video"],initialFilter:h?void 0:"document",currentId:h||void 0,onClose:()=>d(!1),onPick:g=>{d(!1),s({asset_id:g.id})}})]})}const zj={PanelUI:Rj,applyOptimistic:null,coerce:d1},Dj={failed:"Crop failed — the image is unchanged. Try cropping again.",slow:"This crop is still processing. It will appear as soon as it finishes."},Uj="m-0 text-caption leading-[1.4] text-ink-4";function k1({storeKey:n}){const l=QE(n),s=En(o=>o.clearNotice);return l?f.jsxs("p",{role:"alert","data-crop-notice":l,className:ye(l==="failed"?th:Uj,"flex items-center justify-between gap-2"),children:[f.jsx("span",{children:Dj[l]}),f.jsx("button",{type:"button",className:ye(ot,"shrink-0 underline"),onClick:()=>s(n),children:"Dismiss"})]}):null}const Lj=360,Bj="relative overflow-hidden rounded-[calc(9*var(--content))]";function E1({src:n,derivativeUrl:l,mode:s,slotAspect:o,sizing:u,ar:d,dimmed:h,children:p}){const y=l??n,g=s==="locked"?"cover":"contain",x=_.useRef(null),[v,E]=_.useState(null);_.useLayoutEffect(()=>{if(s!=="free")return;const z=x.current;z!=null&&z.complete&&z.naturalWidth>0&&z.naturalHeight>0&&E({src:y,aspect:z.naturalWidth/z.naturalHeight})},[y,s]);const M=z=>{if(s!=="free")return;const D=z.currentTarget;D.naturalWidth>0&&D.naturalHeight>0&&E({src:y,aspect:D.naturalWidth/D.naturalHeight})},N=v&&v.src===y?v.aspect:typeof d=="number"&&d>0?d:o,A=s==="locked"?o:N,j=h?FE:void 0,O=u==="single"?{aspectRatio:String(A),width:"100%",maxWidth:`${Lj*A}px`,marginInline:"auto"}:{aspectRatio:String(A),width:"100%"};return f.jsxs("div",{className:Bj,style:O,children:[f.jsx("img",{ref:x,className:`block size-full object-center ${g==="cover"?"object-cover":"object-contain"}`,src:y,alt:"",draggable:!1,onLoad:M,style:j}),p]})}function Hj(n){var u,d;const l=yj(),o=(u=en({queryKey:["property",n],queryFn:()=>l.fetchProperty(n)}).data)==null?void 0:u.contacts;return((d=(o==null?void 0:o.find(h=>h.is_primary))??(o==null?void 0:o[0]))==null?void 0:d.library_item_id)??null}const so=ye(ot,"inline-flex items-center gap-1.25 rounded-sm bg-[rgba(255,255,255,0.94)] px-2.5 py-1.5 text-[length:calc(11.5*var(--content))] font-semibold text-ink transition-[background] duration-[120ms] hover:bg-white");function Nb(n,l,s,o){const u=()=>{const d=n.current;return d.photo_id!==o?!0:!!(d.pending_crop&&d.pending_crop.crop_key!==s.crop_key)};return{apply:(d,h)=>{u()||l({...n.current,rect:s.rect,ar:s.ar,crop_key:d,mobile:s.mobile?{rect:s.mobile.rect,crop_key:h??null,derived:s.mobile.derived}:n.current.mobile??void 0,pending_crop:null})},revert:()=>{u()||l({...n.current,pending_crop:null})}}}function Qd({value:n,onChange:l,propertyId:s,cropKey:o,cropCfg:u,contactImage:d,comparablePhoto:h=null,displayName:p}){var T;const{api:y}=Vn(),[g,x]=_.useState(null),v=hc(s),E=Pv(s,[n.crop_key],y.getCropDerivativeUrl),M=n.crop_key?E.get(n.crop_key):void 0,N=En(B=>o in B.byKey),A=o.startsWith(`${s}:`)?o.slice(s.length+1):o,[j="",O=""]=A.split(":"),z=Hj(s),D=(d==null?void 0:d.itemId)??z,Y=_.useRef(null),[W,ee]=_.useState(!1),ae=d!==null&&D!==null,U=(h==null?void 0:h.comparableId)??null,re=h?U===null?null:{stage:B=>y.stageComparablePhoto(s,U,B),discard:B=>y.deleteStagedComparablePhoto(s,U,B)}:ae?{stage:B=>y.stageLibraryItemImage(D,B,zS(d.kind==="headshot"?{kind:"headshot"}:{kind:"logo",variant:d.variant})),discard:B=>y.deleteStagedLibraryItemImage(D,B)}:null,de=h===null,ce=af(n),ie=ce?v.has(ce):!1,L=en(h?{queryKey:["comparable-photo-url",U,ce],queryFn:()=>y.presignComparablePhoto(s,U,ce),enabled:!!U&&!!ce&&!ie}:{queryKey:["staged-upload-url",D,ce],queryFn:()=>y.presignLibraryItemUpload(D,ce),enabled:!!D&&!!ce&&!ie}),G=(ce?v.get(ce):void 0)??L.data??n.url??void 0,F=_.useRef(null),w=async B=>{if(re){ee(!0);try{const{upload_id:q,url:V}=await re.stage(B),me=F.current;F.current=q,l({...n,photo_id:q,url:V,rect:null,ar:null,crop_key:null,mobile:null,pending_crop:null}),me&&me!==q&&re.discard(me).catch(()=>{})}catch(q){console.error("[editor] image stage failed",{contactId:D,comparableId:U,err:q})}finally{ee(!1)}}},Z=B=>{var V;const q=(V=B.target.files)==null?void 0:V[0];B.target.value="",q&&w(q)},ue=()=>{const B=F.current;F.current=null,l({...n,photo_id:"",url:"",rect:null,ar:null,crop_key:null,mobile:null,pending_crop:null}),B&&re&&re.discard(B).catch(()=>{})},te=f.jsxs("button",{type:"button",className:so,disabled:W,onClick:()=>{var B;return(B=Y.current)==null?void 0:B.click()},children:[f.jsx(ze.up,{})," ",W?"Saving…":"Upload"]}),P=_.useRef(n);_.useEffect(()=>{P.current=n},[n]);const k=n.pending_crop??null,I=_.useCallback(B=>Nb(P,l,B.pending,P.current.photo_id),[l]);Xv(k?[{key:o,pending:k,propertyId:s,instanceId:j,slotId:O}]:[],I);const $=async B=>{var q,V,me;if(x(null),!!n.photo_id){if(Av(B.rect)){(n.rect||n.crop_key||n.mobile||n.pending_crop)&&l({...n,rect:null,ar:null,crop_key:null,mobile:null,pending_crop:null});return}try{const he=await y.cropImage(s,n.photo_id,B.rect,((q=B.mobile)==null?void 0:q.rect)??null),ke={job_id:he.job_id,crop_key:he.crop_key,rect:B.rect,ar:B.ar,mobile:B.mobile&&he.mobile?{job_id:he.mobile.job_id,crop_key:he.mobile.crop_key,rect:B.mobile.rect,derived:B.mobile.derived}:null};l({...P.current,pending_crop:ke});const Ae=Nb(P,l,ke,n.photo_id);En.getState().start(o,{jobId:he.job_id,propertyId:s,cropKey:he.crop_key,mobileJobId:(V=he.mobile)==null?void 0:V.job_id,mobileCropKey:(me=he.mobile)==null?void 0:me.crop_key,instanceId:j,slotId:O,apply:Ae.apply,revert:Ae.revert})}catch(he){En.getState().notice(o,"failed"),console.error("[editor] image crop failed",{instanceId:j,slotId:O,err:he})}}};return f.jsxs("div",{className:eh,children:[f.jsxs("div",{className:Qn,children:[f.jsx(nh,{children:p??"Image"}),G?f.jsxs(E1,{src:G,derivativeUrl:M,ar:n.ar,mode:u.mode,slotAspect:u.aspect,sizing:"single",dimmed:N,children:[N&&f.jsx(Zv,{}),f.jsx("div",{className:"absolute inset-x-0 bottom-0 flex items-center justify-between bg-[linear-gradient(to_top,rgba(15,18,9,0.55),transparent)] p-2.5",children:f.jsxs("div",{className:"flex items-center gap-1.5",children:[re?te:de?f.jsxs("button",{type:"button",className:so,onClick:()=>x("pick"),children:[f.jsx(ze.swap,{})," Replace"]}):null,f.jsxs("button",{type:"button",className:so,onClick:()=>x("crop"),children:[f.jsx(ze.crop,{})," Crop"]}),h&&f.jsxs("button",{type:"button",className:so,onClick:ue,children:[f.jsx(ze.trash,{})," Remove"]})]})})]}):f.jsxs("div",{className:"relative h-72.5 overflow-hidden rounded-[calc(9*var(--content))] bg-[#e6e3da]",children:[f.jsxs("div",{className:ye("flex size-full flex-col items-center justify-center gap-1.5 text-small text-ink-3",dc),children:[f.jsx(ze.up,{}),f.jsx("span",{children:"No image yet"})]}),f.jsx("div",{className:"absolute inset-x-0 bottom-0 flex items-center justify-between bg-[linear-gradient(to_top,rgba(15,18,9,0.55),transparent)] p-2.5",children:re?te:de?f.jsxs("button",{type:"button",className:so,onClick:()=>x("pick"),children:[f.jsx(ze.up,{})," Add image"]}):null})]}),f.jsx(k1,{storeKey:o})]}),re&&f.jsx("input",{ref:Y,type:"file",accept:"image/*",hidden:!0,onChange:Z}),g==="pick"&&de&&f.jsx(cl,{mode:"single",propertyId:s,currentId:n.photo_id||void 0,onClose:()=>x(null),onPick:B=>{if(B.id===n.photo_id){l({...n,url:B.src}),x(null);return}l({...n,photo_id:B.id,url:B.src,alt:n.alt||B.caption||"",rect:null,ar:null,crop_key:null,pending_crop:null}),x(null)}}),g==="crop"&&G&&f.jsx(ih,{chrome:cn,src:G,mode:u.mode,aspect:u.aspect,aspectLabel:u.aspectLabel,mobileAspect:u.mobileAspect,seed:{rect:n.rect??null},mobileSeed:{rect:((T=n.mobile)==null?void 0:T.rect)??null},onClose:()=>x(null),onApply:B=>{$(B)}})]})}function qj(){return`tmp_${globalThis.crypto.randomUUID()}`}function j1(n){return typeof n=="string"&&n.startsWith("tmp_")}function Gj({slot:n,instanceId:l,slotId:s,value:o,onChange:u,propertyId:d,recordContext:h}){if(h){if(d!=null&&l!=null&&s!=null){if(TS(h.collection,n)){const v=h.itemId;return f.jsx(Qd,{value:o,onChange:u,propertyId:d,cropKey:`${d}:${l}:${s}:${h.fieldKey}`,cropCfg:Jr(n),displayName:n.label,contactImage:null,comparablePhoto:{comparableId:v!=null&&!j1(v)?v:null}})}const x=RS(h.collection,n);return f.jsx(Qd,{value:o,onChange:u,propertyId:d,cropKey:`${d}:${l}:${s}:${h.fieldKey}`,cropCfg:Jr(n),displayName:n.label,contactImage:x?{...x,instanceId:l,slotId:s,itemId:h.itemId}:null})}return null}const p=Jr(n),y=`${d}:${l}:${s}`,g=OS(n.source);return f.jsx(Qd,{value:o,onChange:u,propertyId:d,cropKey:y,cropCfg:p,contactImage:g?{...g,instanceId:l,slotId:s}:null,displayName:n.label})}function Ij(n,l){const s=n.querySelector("img");if(s){l.url&&s.setAttribute("src",l.url),s.setAttribute("alt",l.alt??""),s.style.transform="",s.style.transformOrigin="",s.style.objectPosition="";return}const o=n.querySelector("video");o&&(l.url?o.setAttribute("poster",l.url):o.removeAttribute("poster"))}function M1(n){if(n&&typeof n=="object"){const l=n;return{photo_id:typeof l.photo_id=="string"&&l.photo_id.length>0?l.photo_id:typeof l.asset_id=="string"?l.asset_id:"",url:typeof l.url=="string"?l.url:"",alt:typeof l.alt=="string"?l.alt:"",rect:l.rect&&typeof l.rect=="object"?l.rect:void 0,ar:typeof l.ar=="number"?l.ar:void 0,crop_key:typeof l.crop_key=="string"?l.crop_key:void 0,mobile:l.mobile&&typeof l.mobile=="object"&&l.mobile.rect?l.mobile:void 0,pending_crop:$E(l.pending_crop)??void 0}}return{photo_id:"",url:"",alt:""}}const Qj={PanelUI:Gj,applyOptimistic:Ij,coerce:M1};function Kj(n,l,s){if(l===s||l<0||s<0)return n;const o=n.slice(),[u]=o.splice(l,1);return o.splice(s,0,u),o}const C1="data-drag-scope";function Kd(n){return Array.from(n.querySelectorAll("[data-dragid]")).filter(l=>l.closest(`[${C1}]`)===n)}function A1({items:n,getKey:l,onReorder:s,onDrop:o,axis:u="xy",threshold:d=4,ignoreSelector:h=".we-no-drag"}){const[p,y]=_.useState(null),[g,x]=_.useState({w:0,h:0}),v=_.useRef(null),E=_.useRef(null),M=_.useRef({}),N=_.useRef({grabX:0,grabY:0,scale:1}),A=_.useRef({x:0,y:0}),j=_.useRef(null),O=_.useRef(null),z=_.useRef(n),D=_.useRef(l),Y=_.useRef({onReorder:s,onDrop:o});_.useLayoutEffect(()=>{Y.current={onReorder:s,onDrop:o}});function W(){const ce=E.current,ie=v.current;if(!ce||!ie)return;const L=ie.getBoundingClientRect(),G=N.current.scale||1,F=(A.current.x-L.left)/G-N.current.grabX,w=(A.current.y-L.top)/G-N.current.grabY;u!=="y"&&(ce.style.left=`${F}px`),ce.style.top=`${w}px`}function ee(){const ce=v.current,ie=ce.getBoundingClientRect(),L=N.current.scale||1,G=(A.current.x-ie.left)/L,F=(A.current.y-ie.top)/L,w=z.current;let Z=0,ue=1/0;return Kd(ce).forEach(te=>{const P=w.findIndex(T=>D.current(T)===te.dataset.dragid);if(P<0)return;const k=te.offsetLeft+te.offsetWidth/2,I=te.offsetTop+te.offsetHeight/2,$=(G-k)**2+(F-I)**2;$<ue&&(ue=$,Z=P)}),Math.max(0,Math.min(w.length-1,Z))}_.useLayoutEffect(()=>{const ce=v.current;if(!ce)return;ce.setAttribute(C1,"");const ie=M.current,L={};Kd(ce).forEach(G=>{const F=G.dataset.dragid,w={left:G.offsetLeft,top:G.offsetTop};L[F]=w;const Z=ie[F];if(Z&&F!==O.current){const ue=Z.left-w.left,te=Z.top-w.top;(ue||te)&&G.animate([{transform:`translate(${ue}px,${te}px)`},{transform:"none"}],{duration:190,easing:"cubic-bezier(.2,.7,.3,1)"})}}),M.current=L,O.current&&W()});function ae(ce,ie){var Z,ue,te,P,k;const L=v.current,G=Kd(L).find(I=>I.dataset.dragid===ce)??null;if(!G)return;const F=G.getBoundingClientRect(),w=L.getBoundingClientRect().width/L.offsetWidth||1;N.current={grabX:(ie.clientX-F.left)/w,grabY:(ie.clientY-F.top)/w,scale:w},(ue=(Z=document.activeElement)==null?void 0:Z.blur)==null||ue.call(Z),(k=(P=(te=window.getSelection)==null?void 0:te.call(window))==null?void 0:P.removeAllRanges)==null||k.call(P),A.current={x:ie.clientX,y:ie.clientY},z.current=n,D.current=l,O.current=ce,x({w:G.offsetWidth,h:G.offsetHeight}),y(ce)}function U(ce,ie){ce.button===0&&(ce.target.closest(h)||(j.current={key:ie,x:ce.clientX,y:ce.clientY},window.addEventListener("pointermove",re),window.addEventListener("pointerup",de)))}function re(ce){const ie=j.current;if(!ie)return;if(!O.current){if(Math.hypot(ce.clientX-ie.x,ce.clientY-ie.y)<d)return;ae(ie.key,ce)}A.current={x:ce.clientX,y:ce.clientY},W();const L=ee(),G=z.current,F=G.findIndex(Z=>D.current(Z)===O.current);if(F<0||F===L)return;const w=Kj(G,F,L);z.current=w,Y.current.onReorder(w)}function de(){window.removeEventListener("pointermove",re),window.removeEventListener("pointerup",de),j.current=null,O.current&&(O.current=null,y(null),Y.current.onDrop(z.current))}return{containerRef:v,cloneRef:E,getItemProps:ce=>({"data-dragid":ce,onPointerDown:ie=>U(ie,ce)}),draggingKey:p,cloneBox:g}}const Vj="flex min-h-6.5 items-center justify-between gap-2.5",Yj=ye(ot,"inline-flex h-6.5 items-center gap-1.25 rounded-full bg-accent pl-2.25 pr-2.75 text-[length:calc(11.5*var(--content))] font-semibold text-white transition-[background] duration-[120ms] hover:bg-accent-ink"),$j="relative grid grid-cols-2 gap-2",Fj="[grid-column:1/-1] py-4.5 text-center text-small text-ink-3",Xj="pointer-events-none absolute z-[60] cursor-grabbing overflow-hidden rounded-[8px] bg-canvas shadow-[0_16px_38px_-8px_rgba(20,18,13,0.5)] after:absolute after:inset-0 after:rounded-[8px] after:border-2 after:border-dashed after:border-[#111] after:content-['']",Zj="relative aspect-[4/3] bg-[#fafaf6]",Pj="absolute inset-0 block size-full object-contain";function Tb(n){return Array.isArray(n)?n.map(l=>{if(typeof l!="object"||l===null)return null;const s=l;return typeof s.key=="string"?s:{key:T1(),id:typeof s.asset_id=="string"?s.asset_id:"",url:"",alt:"",floor:typeof s.floor_label=="string"?s.floor_label:""}}).filter(l=>l!==null):[]}function Jj(n){return n.map(l=>{const s=l.floor.trim();return{asset_id:l.id,floor_label:s||null}})}function Wj(n,l){var u;const{collection:s}=l;if(s==null)return!1;const o=Xf(s,n);return o!==null&&((u=Ff(s,o))==null?void 0:u.pool)==="floor_plans"}function eM({value:n,propertyId:l,recordContext:s,onChange:o}){var y;const{fieldKey:u,titleKey:d,itemIndex:h}=s,p=(s.siblingRecords??[]).map(g=>{const x=d!=null?g[d]:void 0;return{label:typeof x=="string"?x:"",plans:Tb(u!=null?g[u]:void 0)}});return f.jsx(aM,{plans:Tb(n),propertyId:l,unitLabel:h!=null&&((y=p[h])==null?void 0:y.label)||void 0,unitIndex:h,siblingUnits:p,onChange:g=>o(Jj(g))})}function N1(n){return n.map(l=>({planId:l.id,label:l.floor}))}let Ob=0;function T1(){return Ob+=1,`pl-${Ob}`}function Vd(n){return JSON.stringify(n.map(l=>[l.id,l.floor]))}function tM(n,l,s){const o=new Map(l.map(u=>[u.id,u]));return n.map(u=>{const d=o.get(u.planId);return d?{...d,floor:u.label}:{key:T1(),id:u.planId,url:s.get(u.planId)??"",alt:"",floor:u.label}})}function nM(n){return{_key:"fp-sibling",label:n.label,beds:"",baths:"",sqft:"",price:"",plans:N1(n.plans),planExclusions:[],planFloors:{}}}function aM({plans:n,propertyId:l,unitLabel:s,siblingUnits:o,unitIndex:u,onChange:d}){const{UnitPlanPicker:h,api:p}=g1(),[y,g]=_.useState(!1),[x,v]=_.useState(null),E=y3(l),M=_.useMemo(()=>{const G=new Map;for(const F of E)G.set(F.id,F.thumbnail_url);return G},[E]),N=G=>G.url||M.get(G.id)||"",[A,j]=_.useState(n),[O,z]=_.useState(()=>Vd(n)),D=G=>{j(G),z(Vd(G)),d(G)},{containerRef:Y,cloneRef:W,getItemProps:ee,draggingKey:ae,cloneBox:U}=A1({items:A,getKey:G=>G.key,onReorder:j,onDrop:D,axis:"xy"});if(!ae){const G=Vd(n);G!==O&&(z(G),j(n))}const re=(G,F)=>D(A.map(w=>w.key===G?{...w,floor:F}:w)),de=G=>D(A.filter(F=>F.key!==G)),ce=o==null?void 0:o.map(nM),ie=ae?A.find(G=>G.key===ae):null,L=ie?N(ie):"";return f.jsxs("div",{className:"flex flex-col gap-2.25",children:[f.jsxs("div",{className:Vj,children:[f.jsxs("span",{className:va,children:[A.length," floor plan",A.length===1?"":"s"]}),f.jsx("div",{className:"flex items-center gap-1.5",children:f.jsxs("button",{type:"button",className:Yj,onClick:()=>g(!0),children:[f.jsx(ze.plus,{})," Add"]})})]}),f.jsxs("div",{className:$j,ref:Y,children:[A.length===0&&f.jsx("div",{className:Fj,children:"No floor plans yet — use Add to choose plans."}),A.map((G,F)=>f.jsx(F3,{src:N(G)||null,floor:G.floor,onFloorChange:w=>re(G.key,w),onCrop:()=>v(G.id),onRemove:()=>de(G.key),removeTitle:"Remove from unit",badge:F+1,drag:{dataDragId:G.key,onPointerDown:ee(G.key).onPointerDown,active:ae===G.key}},G.key)),ie&&f.jsx("div",{ref:W,className:Xj,style:{width:U.w,height:U.h,left:0,top:0},children:f.jsx("div",{className:Zj,children:L&&f.jsx("img",{className:Pj,src:L,alt:"",draggable:!1})})})]}),y&&f.jsx(h,{open:!0,propertyId:l,unit:{_key:"fp-preview",label:s??"",beds:"",baths:"",sqft:"",price:"",plans:N1(A),planExclusions:[],planFloors:{}},units:ce,unitIndex:u,library:E,onClose:()=>g(!1),onUnitPatch:G=>{G.plans&&D(tM(G.plans,A,M))},onCrop:v}),x&&f.jsx(O3,{propertyId:l,planId:x,getSourcePage:p.getFloorplanSourcePage,onClose:()=>v(null)})]})}const lM=ye(ot,"inline-flex h-6.5 items-center gap-1.25 rounded-full bg-accent pl-2.25 pr-2.75 text-[length:calc(11.5*var(--content))] font-semibold text-white transition-[background] duration-[120ms] hover:bg-accent-ink"),iM="group/tile relative cursor-grab touch-none select-none",rs=ye("grid size-full place-items-center font-mono text-small text-ink-3",dc),sM="absolute right-1.25 top-1.25 z-[4] flex gap-0.75 opacity-0 transition-opacity duration-[120ms] group-hover/tile:opacity-100 group-data-[ghost]/tile:hidden",O1=ye(ot,"we-no-drag grid size-5 place-items-center rounded-[calc(4*var(--content))] bg-white text-ink-2 shadow-[0_1px_2px_rgba(20,18,13,0.18)] transition-[background,color] duration-[120ms] hover:bg-[#f3f1ea] hover:text-ink"),Rb="pointer-events-none absolute bottom-1.25 right-1.25 z-[3] grid size-5.5 place-items-center rounded-full bg-[rgba(255,255,255,0.94)] text-caption font-bold text-ink shadow-[0_1px_3px_rgba(20,18,13,0.25)] group-data-[ghost]/tile:hidden",oM="pointer-events-none absolute z-[60] cursor-grabbing overflow-hidden rounded-[calc(9*var(--content))] shadow-[0_16px_38px_-8px_rgba(20,18,13,0.5)] after:absolute after:inset-0 after:rounded-[calc(9*var(--content))] after:border-2 after:border-dashed after:border-[#111] after:content-['']";function mc(n,l,s,o,u){const d=new Set(l.map(g=>g.id)),h=n.filter(g=>d.has(s(g.value))),p=new Set(h.map(g=>s(g.value))),y=l.filter(g=>!p.has(g.id)).map(g=>u(o(g)));return[...h,...y]}function vh({engine:n,noun:l,max:s,emptyText:o,onAdd:u,renderTile:d,renderClone:h,tileActions:p,children:y}){const{rows:g,atMax:x,canRemove:v}=n,{containerRef:E,cloneRef:M,getItemProps:N,draggingKey:A,cloneBox:j}=n.drag,O=A?n.indexOf(A):-1,z=O>=0?g[O]:null;return f.jsxs("div",{className:Qn,children:[f.jsxs("div",{className:"flex min-h-6.5 items-center justify-between gap-2.5",children:[f.jsxs("span",{className:va,children:[g.length," ",l,g.length===1?"":"s"]}),f.jsxs("button",{type:"button",className:lM,onClick:u,disabled:x,title:x?`Maximum ${s} ${l}s`:`Add ${l}s`,style:x?{opacity:.5,cursor:"default"}:void 0,children:[f.jsx(ze.plus,{})," Add"]})]}),f.jsxs("div",{className:"relative grid grid-cols-2 gap-2",ref:E,children:[g.length===0&&f.jsx("div",{className:"[grid-column:1/-1] py-4.5 text-center text-small text-ink-3",children:o}),g.map((D,Y)=>{const W=f.jsxs(f.Fragment,{children:[f.jsxs("span",{className:sM,children:[p==null?void 0:p(D),v&&f.jsx("button",{type:"button",className:ye(O1,"hover:bg-[#FBE6E2] hover:text-[#8E2C1E]"),title:"Remove",onClick:()=>n.remove(D.key),children:f.jsx(ze.trash,{})})]}),f.jsx("span",{className:Rb,children:Y+1})]});return f.jsx("div",{...N(D.key),"data-ghost":A===D.key?"":void 0,className:ye(iM,A===D.key&&"cursor-grabbing"),children:d(D,Y,W)},D.key)}),z&&f.jsxs("div",{ref:M,className:oM,style:{width:j.w,height:j.h,left:0,top:0},children:[h(z,O),f.jsx("span",{className:Rb,children:O+1})]})]}),y]})}let rM=0;function cM(){return typeof crypto<"u"&&"randomUUID"in crypto?crypto.randomUUID():`li-${(rM++).toString(36)}`}function Of(n,l){return{key:(l==null?void 0:l(n))??cM(),value:n}}function zb(n,l){return n.map(s=>Of(s,l))}function Yd(n){return JSON.stringify(n)}function ei({items:n,identityOf:l,min:s=0,max:o=1/0,axis:u="y",commit:d,onCommitted:h}){const[p,y]=_.useState(()=>zb(n,l)),[g,x]=_.useState(()=>Yd(n)),v=_.useRef(p);_.useEffect(()=>{v.current=p},[p]);function E(j){v.current=j,y(j)}function M(j,O){E(j),x(Yd(j.map(z=>z.value))),d(j,O),h==null||h(j,O)}const N=A1({items:p,getKey:j=>j.key,onReorder:E,onDrop:j=>M(j,"reorder"),axis:u,threshold:5});if(!N.draggingKey){const j=Yd(n);j!==g&&(x(j),y(zb(n,l)))}function A(j,O){const z=v.current;z.some(D=>D.key===j)&&M(z.map(D=>D.key===j?{...D,value:O(D.value)}:D),"edit")}return{rows:p,drag:N,atMax:p.length>=o,canRemove:p.length>s,add:j=>{const O=v.current;O.length>=o||M([...O,Of(j,l)],"add")},remove:j=>{const O=v.current;O.length<=s||M(O.filter(z=>z.key!==j),"remove")},setValue:(j,O)=>A(j,()=>O),updateValue:A,replace:j=>M(j.slice(0,o),"replace"),mint:j=>Of(j,l),indexOf:j=>p.findIndex(O=>O.key===j),keyAt:j=>{var O;return((O=p[j])==null?void 0:O.key)??null},latestRows:()=>v.current}}const uM="block h-auto max-h-35 w-auto max-w-full group-data-[ghost]/tile:opacity-[0.28]";function dM(n){return n.map(M1)}function fM({itemSlot:n,min:l,max:s,instanceId:o,slotId:u,value:d,propertyId:h,selectedItemIndex:p,commit:y}){var ue;const{api:g}=Vn(),x=Jr(n),v=hc(h),E=En(te=>te.byKey),M=te=>`${h}:${o}:${u}:${te}`,N=te=>(te.photo_id?v.get(te.photo_id):void 0)??te.url,A=_.useMemo(()=>dM(d),[d]),[j,O]=_.useState(!1),[z,D]=_.useState(null),Y=ei({items:A,min:l,max:s,axis:"xy",commit:y}),{rows:W}=Y,ee=Pv(h,W.map(te=>te.value.crop_key),g.getCropDerivativeUrl),[ae,U]=_.useState(null),re=p??null;if(!Y.drag.draggingKey&&re!==ae&&(U(re),re!=null)){const te=Y.keyAt(re);te&&D(te)}const de=(te,P,k)=>{const I=$=>$.photo_id!==k||!!($.pending_crop&&$.pending_crop.crop_key!==P.crop_key);return{apply:($,T)=>Y.updateValue(te,B=>I(B)?B:{...B,rect:P.rect,ar:P.ar,crop_key:$,mobile:P.mobile?{rect:P.mobile.rect,crop_key:T??null,derived:P.mobile.derived}:B.mobile,pending_crop:null}),revert:()=>Y.updateValue(te,$=>I($)?$:{...$,pending_crop:null})}};Xv(W.flatMap(te=>{const P=te.value.pending_crop;return P?[{key:M(te.key),pending:P,propertyId:h,instanceId:o,slotId:u,itemIndex:Y.indexOf(te.key),rowKey:te.key,photoId:te.value.photo_id}]:[]}),te=>de(te.rowKey,te.pending,te.photoId));const ce=async te=>{var $,T,B;const P=z;if(D(null),!P)return;const k=W.find(q=>q.key===P);if(!k||!k.value.photo_id)return;if(Av(te.rect)){(k.value.rect||k.value.crop_key||k.value.mobile||k.value.pending_crop)&&Y.updateValue(P,q=>({...q,rect:null,ar:null,crop_key:null,mobile:null,pending_crop:null}));return}const I=Y.indexOf(P);try{const q=await g.cropImage(h,k.value.photo_id,te.rect,(($=te.mobile)==null?void 0:$.rect)??null),V={job_id:q.job_id,crop_key:q.crop_key,rect:te.rect,ar:te.ar,mobile:te.mobile&&q.mobile?{job_id:q.mobile.job_id,crop_key:q.mobile.crop_key,rect:te.mobile.rect,derived:te.mobile.derived}:null};Y.updateValue(P,he=>({...he,pending_crop:V}));const me=de(P,V,k.value.photo_id);En.getState().start(M(P),{jobId:q.job_id,propertyId:h,cropKey:q.crop_key,mobileJobId:(T=q.mobile)==null?void 0:T.job_id,mobileCropKey:(B=q.mobile)==null?void 0:B.crop_key,instanceId:o,slotId:u,itemIndex:I,apply:me.apply,revert:me.revert})}catch(q){En.getState().notice(M(P),"failed"),console.error("[editor] image crop failed",{instanceId:o,slotId:u,key:P,err:q})}},ie=te=>{Y.replace(mc(W,te,P=>P.photo_id,P=>({photo_id:P.id,url:P.src,alt:P.caption??""}),Y.mint)),O(!1)},L=z?W.find(te=>te.key===z):null,G=L?N(L.value):"";function F(te,P,k){const I=N(te.value),$=Y.drag.draggingKey===te.key;return I?f.jsxs("span",{"data-thumb":!0,className:ye("block w-full",$&&"opacity-[0.28]"),children:[f.jsxs(E1,{src:I,derivativeUrl:te.value.crop_key?ee.get(te.value.crop_key):void 0,ar:te.value.ar,mode:x.mode,slotAspect:x.aspect,sizing:"tile",dimmed:M(te.key)in E,children:[M(te.key)in E&&f.jsx(Zv,{}),k]}),f.jsx(k1,{storeKey:M(te.key)})]}):f.jsxs("div",{className:ye(rs,"relative w-full"),style:{aspectRatio:String(x.aspect)},children:[P+1,k]})}function w(te,P){const k=N(te.value);return k?f.jsx("img",{className:uM,src:k,alt:"",draggable:!1}):f.jsx("div",{className:rs,children:P+1})}function Z(te){return f.jsx("button",{type:"button",className:O1,title:"Crop",onClick:()=>D(te.key),children:f.jsx(ze.crop,{})})}return f.jsxs(vh,{engine:Y,noun:"image",max:s,emptyText:"No images yet — use Add to choose photos.",onAdd:()=>O(!0),renderTile:F,renderClone:w,tileActions:Z,children:[j&&f.jsx(cl,{mode:"multi",title:"Add photos",propertyId:h,selectedIds:W.map(te=>te.value.photo_id),onApply:ie,onClose:()=>O(!1)}),L&&G&&f.jsx(ih,{chrome:cn,src:G,mode:x.mode,aspect:x.aspect,aspectLabel:x.aspectLabel,mobileAspect:x.mobileAspect,seed:{rect:L.value.rect??null},mobileSeed:{rect:((ue=L.value.mobile)==null?void 0:ue.rect)??null},onApply:te=>{ce(te)},onClose:()=>D(null)})]})}function hM({slot:n,value:l,onChange:s,propertyId:o}){const[u,d]=_.useState(!1),{items:h}=yh(o),p=l.tour_id?h.find(g=>g.id===l.tour_id):void 0,y=(p==null?void 0:p.src)||l.poster;return f.jsx(v1,{kind:"tour",label:n.label,poster:y,hasSelection:!!l.tour_id,addLabel:"Add tour",onPick:()=>d(!0),metaName:p==null?void 0:p.name,metaDetail:Cf((p==null?void 0:p.provider)??l.provider),emptyText:"No tour yet",noPosterText:"No thumbnail from this provider",children:u&&f.jsx(cl,{mode:"single",title:"Choose a tour",propertyId:o,kinds:["tour"],initialFilter:"tour",noun:"tour",currentId:l.tour_id||void 0,onClose:()=>d(!1),onPick:g=>{d(!1),g.id!==l.tour_id&&s({...l,tour_id:g.id,url:"",poster:g.src,alt:l.alt||g.caption||"",...g.provider?{provider:g.provider}:{provider:void 0}})}})})}function pM(n,l){const s=n.matches("img")?n:n.querySelector("img");s&&l.poster&&s.setAttribute("src",l.poster)}function R1(n){if(n&&typeof n=="object"){const l=n;return{tour_id:typeof l.tour_id=="string"&&l.tour_id.length>0?l.tour_id:typeof l.asset_id=="string"?l.asset_id:"",url:typeof l.url=="string"?l.url:"",poster:typeof l.poster=="string"?l.poster:"",alt:typeof l.alt=="string"?l.alt:"",...typeof l.provider=="string"&&l.provider?{provider:l.provider}:{}}}return{tour_id:"",url:"",poster:"",alt:""}}const mM={PanelUI:hM,applyOptimistic:pM,coerce:R1};function yM(n){return n.map(R1)}function gM({min:n,max:l,value:s,propertyId:o,commit:u}){const{items:d}=yh(o),h=j=>d.find(O=>O.id===j),p=j=>{var O;return(j.tour_id?(O=h(j.tour_id))==null?void 0:O.src:void 0)||j.poster},y=_.useMemo(()=>yM(s),[s]),[g,x]=_.useState(!1),v=ei({items:y,min:n,max:l,axis:"xy",commit:u}),{rows:E}=v,M=j=>{v.replace(mc(E,j,O=>O.tour_id,O=>({tour_id:O.id,url:"",poster:O.src,alt:O.caption??"",...O.provider?{provider:O.provider}:{}}),v.mint)),x(!1)};function N(j,O,z){const D=h(j.value.tour_id);return f.jsx(x1,{kind:"tour",poster:p(j.value),index:O,ghost:v.drag.draggingKey===j.key,badge:ic(D??{kind:"tour",provider:j.value.provider}),overlays:z,placeholderClassName:rs})}function A(j,O){return f.jsx(_1,{poster:p(j.value),index:O,placeholderClassName:rs})}return f.jsx(vh,{engine:v,noun:"tour",max:l,emptyText:"No tours yet — use Add to choose tours.",onAdd:()=>x(!0),renderTile:N,renderClone:A,children:g&&f.jsx(cl,{mode:"multi",title:"Add tours",propertyId:o,kinds:["tour"],initialFilter:"tour",noun:"tour",selectedIds:E.map(j=>j.value.tour_id),onApply:M,onClose:()=>x(!1)})})}function bM({slot:n,value:l,onChange:s,propertyId:o}){const[u,d]=_.useState(!1),h=hc(o),{items:p}=So(o),y=l.video_id?p.find(E=>E.id===l.video_id):void 0,g=(l.video_id?h.get(l.video_id):void 0)??l.poster,x=(y==null?void 0:y.ready)===!1,v=r1(y==null?void 0:y.durationMs);return f.jsx(v1,{kind:"video",label:n.label,poster:g,hasSelection:!!l.video_id,addLabel:"Add video",onPick:()=>d(!0),status:x?"Processing…":null,metaName:y==null?void 0:y.name,metaDetail:v,emptyText:"No video yet",noPosterText:"Preparing poster…",children:u&&f.jsx(cl,{mode:"single",title:"Choose a video",propertyId:o,kinds:["video"],initialFilter:"video",videoSources:n.sources,currentId:l.video_id||void 0,onClose:()=>d(!1),onPick:E=>{d(!1),E.id!==l.video_id&&s({...l,video_id:E.id,url:"",poster:E.src,alt:l.alt||E.caption||"",...E.videoSource==="link"?{source:"link",...E.provider?{provider:E.provider}:{}}:{source:void 0,provider:void 0}})}})})}function Db(n,l){return n.matches(l)?n:n.querySelector(l)}function vM(n,l){const s=Db(n,"video");if(s){l.poster&&s.setAttribute("poster",l.poster),l.url&&s.setAttribute("src",l.url),l.alt&&s.setAttribute("aria-label",l.alt);return}const o=Db(n,"img");o&&l.poster&&o.setAttribute("src",l.poster)}function z1(n){if(n&&typeof n=="object"){const l=n;return{video_id:typeof l.video_id=="string"&&l.video_id.length>0?l.video_id:typeof l.asset_id=="string"?l.asset_id:"",url:typeof l.url=="string"?l.url:"",poster:typeof l.poster=="string"?l.poster:"",alt:typeof l.alt=="string"?l.alt:"",width:typeof l.width=="number"?l.width:void 0,height:typeof l.height=="number"?l.height:void 0,...l.source==="link"?{source:"link"}:{},...typeof l.provider=="string"&&l.provider?{provider:l.provider}:{}}}return{video_id:"",url:"",poster:"",alt:""}}const xM={PanelUI:bM,applyOptimistic:vM,coerce:z1};function _M(n){return n.map(z1)}function wM({itemSlot:n,min:l,max:s,value:o,propertyId:u,commit:d}){const h=hc(u),{items:p}=So(u),y=z=>p.find(D=>D.id===z),g=z=>(z.video_id?h.get(z.video_id):void 0)??z.poster,x=_.useMemo(()=>_M(o),[o]),[v,E]=_.useState(!1),M=ei({items:x,min:l,max:s,axis:"xy",commit:d}),{rows:N}=M,A=z=>{M.replace(mc(N,z,D=>D.video_id,D=>({video_id:D.id,url:"",poster:D.src,alt:D.caption??"",...D.videoSource==="link"?{source:"link",...D.provider?{provider:D.provider}:{}}:{}}),M.mint)),E(!1)};function j(z,D,Y){const W=y(z.value.video_id);return f.jsx(x1,{kind:"video",poster:g(z.value),index:D,ghost:M.drag.draggingKey===z.key,badge:W?ic(W):"",overlays:Y,placeholderClassName:rs})}function O(z,D){return f.jsx(_1,{poster:g(z.value),index:D,placeholderClassName:rs})}return f.jsx(vh,{engine:M,noun:"video",max:s,emptyText:"No videos yet — use Add to choose videos.",onAdd:()=>E(!0),renderTile:j,renderClone:O,children:v&&f.jsx(cl,{mode:"multi",title:"Add videos",propertyId:u,kinds:["video"],initialFilter:"video",videoSources:n.sources,selectedIds:N.map(z=>z.value.video_id),onApply:A,onClose:()=>E(!1)})})}function SM(n){const l=n.fields;if(!l)return[];const s=n.item_order;if(!s||s.length===0)return Object.entries(l);const o=new Set,u=[];for(const d of s)d in l&&!o.has(d)&&(o.add(d),u.push([d,l[d]]));for(const[d,h]of Object.entries(l))o.has(d)||u.push([d,h]);return u}function kM(n){switch(n.type){case"text":case"select":case"url":return"";case"number":case"image":case"video":case"tour":case"poi":case"document":return null;case"list":return[]}}function Ub(n){const l={};for(const[s,o]of n)l[s]=kM(o);return l}function Lb(n,l,s,o){var y;const u=s.title;if(!u)return`Item ${o+1}`;const d=n[u],h=typeof d=="string"?d.trim():"";if(!h)return"Untitled";const p=(y=l.find(([g])=>g===u))==null?void 0:y[1];if((p==null?void 0:p.type)!=="select")return h;for(const g of p.values??[])if(typeof g!="string"&&g.value===h)return g.label;return h}function EM(n){const{editor:l,granularity:s}=gh(n),o=l==="row-editor"?{kind:"record",entries:SM(n)}:{kind:"single",slot:n.element??{type:"text",label:n.label}};return{editor:l,granularity:s,itemContent:o,min:typeof n.min=="number"?n.min:0,max:typeof n.max=="number"?n.max:1/0,axis:l==="gallery"?"xy":"y"}}const jM="flex flex-col gap-2.75",MM="flex items-center justify-between gap-2.5",CM="relative flex flex-col gap-1.75",AM="rounded-[calc(8*var(--content))] border border-dashed border-line px-3 py-3.5 text-center text-[length:calc(12.5*var(--content))] text-ink-4",NM=ye(ot,"flex h-8.5 w-full items-center justify-start gap-1.5 rounded-[calc(8*var(--content))] px-2.5 text-[length:calc(12.5*var(--content))] font-medium text-ink-3 transition-colors duration-[120ms] hover:bg-line-soft hover:text-ink disabled:cursor-default disabled:opacity-45 disabled:hover:bg-transparent"),TM="pointer-events-none absolute z-[30] flex items-center gap-2.5 rounded-[calc(8*var(--content))] border border-accent bg-white px-2.5 py-1.75 shadow-[0_14px_30px_-10px_rgba(20,18,13,0.35)]",OM="truncate text-[length:calc(13.5*var(--content))] text-ink";function RM({entry:n}){const l=n?pc(n):void 0;return f.jsx(ko,{glyph:(l==null?void 0:l.glyph)??"doc",extension:""})}function zM({slot:n,min:l,max:s,value:o,propertyId:u,commit:d}){var Y;const h=_.useMemo(()=>ej(o),[o]),[p,y]=_.useState(!1),g=f1(u),x=ei({items:h,min:l,max:s,axis:"y",commit:d}),{rows:v}=x,E=W=>{x.replace(mc(v,W,ee=>ee.asset_id,ee=>({asset_id:ee.id}),x.mint)),y(!1)},{containerRef:M,cloneRef:N,getItemProps:A,draggingKey:j,cloneBox:O}=x.drag,z=j?v.find(W=>W.key===j):null,D=`Add ${wo(n.label,"Document")}`;return f.jsxs("div",{className:jM,children:[f.jsx("div",{className:MM,children:f.jsx("span",{className:va,children:n.label})}),f.jsxs("div",{className:ye(CM,j&&"select-none [&_*]:select-none"),ref:M,children:[v.length===0&&f.jsx("div",{className:AM,children:"No documents yet — use Add to choose one."}),v.map(W=>f.jsx(m1,{entry:g(W.value.asset_id),onRemove:x.canRemove?()=>x.remove(W.key):void 0,dragProps:A(W.key),dragging:j===W.key},W.key)),z&&f.jsxs("div",{ref:N,className:TM,style:{width:O.w,height:O.h,left:0,top:0},children:[f.jsx(RM,{entry:g(z.value.asset_id)}),f.jsx("span",{className:OM,children:((Y=g(z.value.asset_id))==null?void 0:Y.name)??"Document unavailable"})]})]}),f.jsxs("button",{type:"button",className:NM,disabled:x.atMax,title:x.atMax?`Maximum ${s} documents`:void 0,onClick:()=>y(!0),children:[f.jsx(ze.plus,{})," ",D]}),p&&f.jsx(cl,{mode:"multi",propertyId:u,noun:"document",kinds:["document","photo","video"],initialFilter:"document",selectedIds:v.map(W=>W.value.asset_id),onApply:E,onClose:()=>y(!1)})]})}function DM(n,l){const s=af(n),o=af(l);return s!=null||o!=null?s===o:n===l?!0:n==null||l==null?!1:String(n)===String(l)}function UM(n,l,s,o,u){const d=Dl(p=>p.markSlotOverridden),h=!u&&Z0(n)===null;return function(y,g){h&&d(l,s,{kind:"scalar"}),o(y.map(x=>x.value))}}async function LM(n,l,s){const o=await n(`/properties/${l}/poi/search`,{method:"POST",json:{query:s}});return Array.isArray(o==null?void 0:o.results)?o.results:[]}async function D1(n,l,s){return n(`/properties/${l}/poi/${encodeURIComponent(s)}`)}async function BM(n,l,s){if(s.length===0)return{};const o=await n(`/properties/${l}/poi/photo-urls`,{method:"POST",json:{place_ids:s}});return(o==null?void 0:o.urls)??{}}function U1(n){if(n==null||!Number.isFinite(n))return null;const l=n/1609.344;return l<.1?"< 0.1 mi":`${l.toFixed(1)} mi`}let HM=0;function qM(){return`poi${++HM}${Math.random().toString(36).slice(2,6)}`}const sc=n=>typeof n=="number"&&Number.isFinite(n)?n:void 0,oo=n=>typeof n=="string"&&n!==""?n:void 0;function GM(n){const l={},s=sc(n.rating);s!==void 0&&(l.rating=s);const o=sc(n.review_count);o!==void 0&&(l.review_count=o);const u=oo(n.type_label);u!==void 0&&(l.type_label=u);const d=oo(n.price_level);d!==void 0&&(l.price_level=d);const h=oo(n.website_uri);h!==void 0&&(l.website_uri=h);const p=oo(n.google_maps_uri);p!==void 0&&(l.google_maps_uri=p);const y=oo(n.summary);y!==void 0&&(l.summary=y);const g=IM(n.photo);return g!==void 0&&(l.photo=g),l}function IM(n){if(!n||typeof n!="object")return;const l=n,s=sc(l.width),o=sc(l.height),u=l.attribution;if(!(s===void 0||o===void 0||typeof u!="string"))return{width:s,height:o,attribution:u}}function L1(n){if(!n||typeof n!="object")return null;const l=n;return typeof l.place_id!="string"||typeof l.name!="string"||typeof l.lat!="number"||typeof l.lng!="number"?null:{id:typeof l.id=="string"?l.id:qM(),place_id:l.place_id,name:l.name,address:typeof l.address=="string"?l.address:null,lat:l.lat,lng:l.lng,distance_m:typeof l.distance_m=="number"?l.distance_m:null,...GM(l)}}function QM(n){return n.map(L1).filter(l=>l!==null)}function KM(n){return[n.rating===void 0?null:`★ ${n.rating.toFixed(1)}${n.review_count===void 0?"":` (${n.review_count.toLocaleString()})`}`,n.type_label,U1(n.distance_m),n.address].filter(Boolean).join(" · ")}const xh="group/row relative flex min-h-10.5 items-center gap-2.5 rounded-[calc(8*var(--content))] border border-line bg-white px-2.5 py-1.75 [transition:border-color_.14s,box-shadow_.14s,background_.3s]",oc="grid w-5 flex-shrink-0 place-items-center text-ink-4",_h="flex min-w-0 flex-1 flex-col gap-px",rc="truncate text-[length:calc(13.5*var(--content))] text-ink",wh="truncate text-caption text-ink-3",B1="rounded-[calc(8*var(--content))] border border-dashed border-line px-3 py-3.5 text-center text-[length:calc(12.5*var(--content))] text-ink-4",H1="text-caption text-danger",q1="opacity-70",G1="size-[calc(14*var(--content))] flex-shrink-0 animate-[we-ml-spin_.7s_linear_infinite] rounded-full border-2 border-[#d9d5c9] border-t-accent",VM="size-[calc(26*var(--content))] flex-shrink-0 rounded-[calc(5*var(--content))] object-cover bg-[#f1f0ea]",YM="we-no-drag flex flex-shrink-0 items-center gap-0.75",$M="flex items-center gap-0.75 opacity-0 transition-opacity duration-[120ms] group-hover/row:opacity-100",FM="grid size-6 cursor-pointer place-items-center rounded-md border-0 bg-transparent p-0 text-ink-3 outline-none hover:bg-[#f1f0ea] hover:text-ink-2",I1=()=>f.jsxs("svg",{viewBox:"0 0 16 16",width:"14",height:"14",className:"w-[calc(14*var(--content))] h-[calc(14*var(--content))]",fill:"none",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round",children:[f.jsx("path",{d:"M8 14s4.5-4 4.5-7.5a4.5 4.5 0 0 0-9 0C3.5 10 8 14 8 14Z"}),f.jsx("circle",{cx:"8",cy:"6.4",r:"1.7"})]});function Q1(n,l){const{apiFetch:s}=Vn().api,[o,u]=_.useState({}),d=l.filter(p=>p.photo).map(p=>p.place_id).sort().join(","),h=_.useRef(new Set);return _.useEffect(()=>{const y=(d===""?[]:d.split(",")).filter(g=>!h.current.has(g));y.length!==0&&(y.forEach(g=>h.current.add(g)),BM(s,n,y).then(g=>{u(x=>({...x,...g}))}).catch(()=>{y.forEach(g=>h.current.delete(g))}))},[d,n,s]),{urls:o,dropUrl:p=>u(y=>{if(!(p in y))return y;const g={...y};return delete g[p],g})}}function K1({row:n,photoUrl:l,onPhotoError:s,onRemove:o,dragProps:u,dragging:d,flashNew:h}){const p=KM(n);return f.jsxs("div",{...u,className:ye(xh,u&&"cursor-grab hover:border-[#d9d5c9]",d&&"cursor-grabbing border-transparent bg-accent-soft [&>*]:opacity-[0.25]",h&&"animate-[we-ml-rowin_.26s_cubic-bezier(.2,.7,.3,1)_both]"),children:[l?f.jsx("img",{className:VM,src:l,alt:"",draggable:!1,onError:s}):f.jsx("span",{className:oc,children:f.jsx(I1,{})}),f.jsxs("div",{className:_h,children:[f.jsx("span",{className:rc,children:n.name}),p&&f.jsx("span",{className:wh,children:p})]}),o&&f.jsx("div",{className:YM,children:f.jsx("span",{className:$M,children:f.jsx("button",{type:"button",className:ye(FM,"hover:bg-[#fbecea] hover:text-danger"),title:"Remove",onClick:o,children:f.jsx(ze.trash,{})})})})]})}const XM="relative flex flex-col",ZM="flex min-w-0 items-center gap-2 rounded-[calc(8*var(--content))] border border-line bg-white px-2.5 transition-[border-color,box-shadow] duration-[120ms] focus-within:border-accent focus-within:shadow-[0_0_0_3px_rgba(15,42,34,0.07)]",PM="grid flex-shrink-0 place-items-center text-ink-4",JM="min-w-0 flex-1 appearance-none border-0 bg-transparent py-2.25 text-[length:calc(13.5*var(--content))] text-ink placeholder:text-ink-4",WM="size-[calc(15*var(--content))] flex-shrink-0 animate-[we-ml-spin_.7s_linear_infinite] rounded-full border-2 border-[#d9d5c9] border-t-accent",eC="absolute left-0 right-0 top-[calc(100%+4*var(--content))] z-[40] overflow-hidden rounded-[calc(8*var(--content))] border border-line bg-white shadow-[0_14px_30px_-12px_rgba(20,18,13,0.28)]",tC="m-0 max-h-[calc(264*var(--content))] list-none overflow-y-auto p-1",nC=ye(ot,"flex w-full flex-col gap-px rounded-md px-2 py-1.75 text-left"),aC="bg-accent-soft",lC="cursor-default opacity-55",iC="flex items-center gap-1.5 truncate text-[length:calc(13.5*var(--content))] text-ink",sC="truncate text-caption text-ink-3",$d="px-3 py-3 text-center text-[length:calc(12.5*var(--content))] text-ink-4",oC="inline-flex flex-shrink-0 items-center gap-1 text-good",rC=2,cC=300;function V1({propertyId:n,placeholder:l,addedIds:s,disabled:o=!1,disabledHint:u,onSelect:d}){const{apiFetch:h}=Vn().api,[p,y]=_.useState(""),[g,x]=_.useState([]),[v,E]=_.useState("idle"),[M,N]=_.useState(0),[A,j]=_.useState(0),O=_.useRef(0),z=_.useId();_.useEffect(()=>{const ee=p.trim();if(ee.length<rC){++O.current,E("idle"),x([]);return}const ae=++O.current;E("loading");const U=setTimeout(()=>{LM(h,n,ee).then(re=>{ae===O.current&&(x(re),N(0),E(re.length?"results":"empty"))}).catch(()=>{ae===O.current&&E("error")})},cC);return()=>clearTimeout(U)},[p,n,A,h]);function D(ee){s.has(ee.place_id)||(d(ee),y(""),x([]),E("idle"))}function Y(ee){if(ee.key==="Escape"){E("idle"),x([]);return}if(v==="results"){if(ee.key==="ArrowDown")ee.preventDefault(),N(ae=>Math.min(g.length-1,ae+1));else if(ee.key==="ArrowUp")ee.preventDefault(),N(ae=>Math.max(0,ae-1));else if(ee.key==="Enter"){ee.preventDefault();const ae=g[M];ae&&D(ae)}}}const W=v!=="idle";return f.jsxs("div",{className:XM,onBlur:ee=>{ee.currentTarget.contains(ee.relatedTarget)||E("idle")},children:[f.jsxs("div",{className:ye(ZM,o&&"opacity-55"),role:"combobox","aria-expanded":W,"aria-haspopup":"listbox","aria-controls":z,children:[f.jsx("span",{className:PM,children:f.jsx(ze.search,{})}),f.jsx("input",{className:JM,value:p,placeholder:l,disabled:o,title:o?u:void 0,onChange:ee=>y(ee.target.value),onKeyDown:Y,"aria-label":l,"aria-autocomplete":"list","aria-activedescendant":v==="results"?`${z}-${M}`:void 0}),v==="loading"&&f.jsx("span",{className:WM})]}),W&&f.jsxs("div",{className:eC,children:[v==="loading"&&f.jsx("div",{className:$d,children:"Searching…"}),v==="empty"&&f.jsxs("div",{className:$d,children:["No places found for “",p.trim(),"”."]}),v==="error"&&f.jsxs("div",{className:$d,children:["Couldn't reach search."," ",f.jsx("button",{type:"button",className:"font-semibold text-accent-ink underline",onClick:()=>j(ee=>ee+1),children:"Retry"})]}),v==="results"&&f.jsx("ul",{className:tC,role:"listbox",id:z,children:g.map((ee,ae)=>{const U=s.has(ee.place_id),re=[U1(ee.distance_m),ee.address].filter(Boolean).join(" · ");return f.jsx("li",{id:`${z}-${ae}`,role:"option","aria-selected":ae===M,children:f.jsxs("button",{type:"button",disabled:U,className:ye(nC,ae===M&&!U&&aC,U&&lC),onMouseEnter:()=>N(ae),onClick:()=>D(ee),children:[f.jsxs("span",{className:iC,children:[U&&f.jsxs("span",{className:oC,children:[f.jsx(ze.check,{size:12})," Added ·"]}),f.jsx("span",{className:"truncate",children:ee.name})]}),re&&f.jsx("span",{className:sC,children:re})]})},ee.place_id)})})]})]})}const uC="flex flex-col gap-2.75",dC="flex items-center justify-between gap-2.5 text-[length:calc(10.5*var(--content))] font-medium text-ink-4",fC="relative flex flex-col gap-1.75",hC="pointer-events-none absolute z-[30] flex items-center gap-2.5 rounded-[calc(8*var(--content))] border border-accent bg-white px-2.5 py-1.75 shadow-[0_14px_30px_-10px_rgba(20,18,13,0.35)]",pC=400;function mC({slot:n,min:l,max:s,value:o,propertyId:u,commit:d}){const{apiFetch:h}=Vn().api,p=_.useMemo(()=>QM(o),[o]),[y,g]=_.useState(null),[x,v]=_.useState(null),[E,M]=_.useState({}),N=_.useRef({});_.useEffect(()=>()=>{Object.values(N.current).forEach(clearTimeout)},[]);const A=ei({items:p,identityOf:ie=>ie.id,min:l,max:s,axis:"y",commit:d}),{rows:j}=A,{urls:O,dropUrl:z}=Q1(u,p);function D(ie){M(L=>({...L,[ie]:!0})),clearTimeout(N.current[ie]),N.current[ie]=setTimeout(()=>M(L=>{const G={...L};return delete G[ie],G}),pC)}async function Y(ie){if(g(null),!A.atMax&&!A.latestRows().some(L=>L.value.place_id===ie.place_id)){v(ie);try{let L;try{L=await D1(h,u,ie.place_id)}catch{g("Couldn't add that place — try again.");return}if(A.latestRows().some(G=>G.value.place_id===L.place_id))return;A.add(L),D(L.id)}finally{v(null)}}}const{containerRef:W,cloneRef:ee,getItemProps:ae,draggingKey:U,cloneBox:re}=A.drag,de=U?j.find(ie=>ie.key===U):null,ce=new Set(j.map(ie=>ie.value.place_id));return f.jsxs("div",{className:uC,children:[f.jsx("div",{className:dC,children:f.jsx("span",{children:n.label})}),f.jsx(V1,{propertyId:u,placeholder:n.placeholder??"Search nearby…",addedIds:ce,disabled:A.atMax,disabledHint:`Maximum ${s} places`,onSelect:ie=>void Y(ie)}),y&&f.jsx("span",{className:H1,children:y}),f.jsxs("div",{className:ye(fC,U&&"select-none [&_*]:select-none"),ref:W,children:[j.length===0&&!x&&f.jsx("div",{className:B1,children:"No places yet — search above to add one."}),j.map(ie=>f.jsx(K1,{row:ie.value,photoUrl:O[ie.value.place_id],onPhotoError:()=>z(ie.value.place_id),onRemove:A.canRemove?()=>A.remove(ie.key):void 0,dragProps:ae(ie.key),dragging:U===ie.key,flashNew:E[ie.value.id]===!0},ie.key)),x&&f.jsxs("div",{className:ye(xh,q1),"aria-live":"polite",children:[f.jsx("span",{className:oc,children:f.jsx("span",{className:G1})}),f.jsxs("div",{className:_h,children:[f.jsx("span",{className:rc,children:x.name}),f.jsx("span",{className:wh,children:"Adding…"})]})]}),de&&f.jsxs("div",{ref:ee,className:hC,style:{width:re.w,height:re.h,left:0,top:0},children:[f.jsx("span",{className:oc,children:f.jsx(I1,{})}),f.jsx("span",{className:rc,children:de.value.name})]})]})]})}const yC='input, textarea, select, button, [tabindex]:not([tabindex="-1"]), [contenteditable="true"]',Rf="data-field-name";function gC(n,l){var o;const s=Array.from(n.querySelectorAll(`[${Rf}]`)).find(u=>u.getAttribute(Rf)===l);s&&(s.scrollIntoView({block:"nearest"}),(o=s.querySelector(yC))==null||o.focus({preventScroll:!0}))}function zf({slot:n,instanceId:l,slotId:s,value:o,propertyId:u,onChange:d,overridden:h,selectedItemIndex:p,selectedFieldName:y,itemBaseline:g,recordContext:x}){const v=J1(n.type);if(!v)return null;const E=v.coerce(o),{PanelUI:M}=v;return f.jsx(M,{slot:n,instanceId:l,slotId:s,value:E,onChange:d,propertyId:u,selectedItemIndex:p,selectedFieldName:y,overridden:h,itemBaseline:g,recordContext:x})}function bC(n){var l,s;switch(gh(n).editor){case"gallery":return((l=n.element)==null?void 0:l.type)==="video"?Ik:((s=n.element)==null?void 0:s.type)==="tour"?Wf:Zk;case"poi-curation":return g5;case"document-list":return qk;case"row-editor":return Zf;case"scalar-list":return r5}}function vC(n){switch(n.type){case"text":return Z5;case"url":return l5;case"image":return Jf;case"video":return dv;case"tour":return Wf;case"poi":return iv;case"document":return Pf;case"select":return _5;case"list":return bC(n);default:return Zf}}function Y1(n){const l=new Set(n.map(vC));return l.size===1?[...l][0]:Zf}const xC=ye(ot,"flex w-full items-center justify-start gap-2 rounded-lg p-2.75 text-body font-semibold text-ink-3 transition-colors duration-[120ms] hover:bg-line-soft hover:text-ink"),_C=ye(ot,"inline-flex items-center gap-1.75 self-start h-9 px-3 rounded-lg text-body font-medium text-danger transition-[background,color] duration-[120ms] hover:bg-danger/15 focus-visible:bg-danger/15 focus-visible:ring-2 focus-visible:ring-danger/25"),wC="relative flex flex-col gap-3",SC="data-[ghost]:opacity-40",kC="pointer-events-none absolute left-0 top-0 z-50 flex items-center gap-2.5 overflow-hidden rounded border border-line bg-canvas pl-2 pr-3.5 shadow-[0_16px_38px_-8px_rgba(20,18,13,0.5)]";function Fd(n,l){return l&&typeof n[l]=="string"?{key:l,value:n[l]}:null}function EC({slot:n,entries:l,min:s,max:o,instanceId:u,slotId:d,value:h,commit:p,selectedItemIndex:y,selectedFieldName:g,itemBaseline:x}){const{Accordion:v,AccordionHeader:E}=Vn(),M=l.filter(([,V])=>W1(V)),N=jv(M.map(([,V])=>V)),A=Y1(l.map(([,V])=>V)),j=Dl(V=>V.session.property_id),O=Dl(V=>V.select),z=Dl(V=>V.markSlotOverridden),D=Dl(V=>V.relinkSlot),Y=Z0(n),W=Y?X0[Y].idKey:null;function ee(V){O({kind:"slot",instance_id:u,slot_id:d,item_index:V})}const ae=_.useRef(null),U=ei({items:h,identityOf:V=>{var me;return((me=Fd(V,W))==null?void 0:me.value)??null},min:s,max:o,axis:"y",commit:p,onCommitted:(V,me)=>{const he=ae.current;if(me!=="reorder"||he==null)return;const ke=V.findIndex(Ae=>Ae.key===he);ke>=0&&ee(ke)}}),{rows:re}=U,de=y??null,ce=de!=null?U.keyAt(de):null;_.useEffect(()=>{ae.current=ce},[ce]);const ie=_.useRef(null);_.useEffect(()=>{ce==null||!g||!ie.current||gC(ie.current,g)},[ce,g]);function L(){O({kind:"slot",instance_id:u,slot_id:d})}function G(V){if(ce===V)return L();const me=U.indexOf(V);me<0||ee(me)}function F(){if(U.atMax)return;const V=Y?{...Ub(l),[W]:qj()}:Ub(l);U.add(V),ee(re.length)}function w(V){if(!U.canRemove)return;const me=re.find(Ae=>Ae.key===V),he=me==null?void 0:me.value[W??""];Y!==null&&me!=null&&typeof he=="string"&&!j1(he)&&z(u,d,{kind:"item_removed",item_id:he});const ke=U.indexOf(V);U.remove(V),ce===V?L():de!=null&&ke>=0&&ke<de&&ee(de-1)}function Z(V,me){const he=re.find(Ae=>Ae.key===V);if(he==null)return;const ke=Fd(he.value,W);if(ke!=null){const Ae=x==null?void 0:x.find(Ue=>Ue[ke.key]===ke.value);for(const Ue of Object.keys(me))if(Ue!==ke.key){const nt=Ae==null?void 0:Ae[Ue];Ae!=null&&DM(me[Ue],nt)?D(u,d,{kind:"item",item_id:ke.value,field:Ue}):z(u,d,{kind:"item",item_id:ke.value,field:Ue})}}U.setValue(V,{...he.value,...me})}const{containerRef:ue,cloneRef:te,getItemProps:P,draggingKey:k,cloneBox:I}=U.drag,$=k?re.find(V=>V.key===k):null,T=$?re.indexOf($):-1,B=$?Lb($.value,l,n,T):"";function q(){return f.jsx("div",{ref:te,className:kC,style:{width:I.w,height:I.h},children:f.jsx(E,{icon:f.jsx(A,{size:14}),title:B,showGrip:!0,showChevron:!1})})}return f.jsxs("div",{className:"flex flex-col gap-3",children:[f.jsxs("div",{ref:ue,className:ye(wC,k&&"select-none [&_*]:select-none"),children:[re.map((V,me)=>{const he=Lb(V.value,l,n,me);return f.jsx("div",{"data-ghost":k===V.key?"":void 0,className:SC,children:f.jsx(v,{open:k==null&&ce===V.key,onToggle:()=>G(V.key),icon:f.jsx(A,{size:14}),title:he,scrollKey:V.key,dragId:V.key,dragHandleProps:{onPointerDown:P(V.key).onPointerDown},children:f.jsxs("div",{className:"flex flex-col gap-4",ref:ce===V.key?ie:void 0,children:[f.jsx(Mv,{rows:N,items:M.map(([ke,Ae])=>{var Ue;return f.jsx("div",{[Rf]:ke,children:f.jsx(zf,{slot:Ae,instanceId:u,slotId:d,value:V.value[ke],propertyId:j,onChange:nt=>Z(V.key,{[ke]:nt}),recordContext:{itemId:(Ue=Fd(V.value,W))==null?void 0:Ue.value,itemIndex:me,siblingRecords:re.map(nt=>nt.value),fieldKey:ke,collection:Y,titleKey:n.title}})},ke)})}),ce===V.key&&U.canRemove&&f.jsxs("button",{type:"button",className:ye(_C,"max-w-full"),onClick:()=>w(V.key),children:[f.jsx("span",{className:"inline-flex shrink-0",children:f.jsx(ze.trash,{size:13})}),f.jsxs("span",{className:"min-w-0 truncate",children:["Delete ",he]})]})]})})},V.key)}),$?q():null]}),!U.atMax&&f.jsxs("button",{type:"button",className:xC,onClick:F,children:[f.jsx(ze.plus,{})," Add ",wo(n.label)]})]})}const Xd={listing_intent:n=>[{value:"for_sale",label:"For Sale"},{value:"for_rent",label:"For Rent"}]};function jC(n){return typeof n=="string"?{value:n,label:n}:{value:n.value,label:n.label}}function $1(n,l){var o,u;if(n.values)return n.values.map(jC);const s=(o=n.options)==null?void 0:o.source;return s!==void 0&&s!==""?((u=Xd[s])==null?void 0:u.call(Xd,l))??[]:[]}function MC(n){return n.trim().toLowerCase().replace(/\s+/g,"-")}const CC="fixed z-[120] max-h-[calc(240*var(--content))] overflow-y-auto rounded-[calc(8*var(--content))] border border-line bg-white shadow-[0_16px_38px_-12px_rgba(20,18,13,0.4)]",F1=ye(ot,"flex w-full items-center justify-between gap-2 rounded-none px-2.5 py-2 text-left text-body text-ink hover:bg-accent-soft data-[active=true]:bg-accent-soft"),AC=ye(F1,"text-accent"),NC=4,Bb=160,Hb=8,TC=ye(ot,"min-w-0 flex-1 cursor-text bg-transparent py-2.25 text-left text-[length:calc(13.5*var(--content))] text-ink outline-none placeholder:text-ink-4");function qb({open:n,className:l,onMouseDown:s}){return f.jsx("span",{className:ye("flex flex-shrink-0 items-center text-ink-4 transition-transform duration-[120ms]",n&&"rotate-180",l),onMouseDown:s,"aria-hidden":"true",children:f.jsx("svg",{width:"11",height:"11",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round",children:f.jsx("path",{d:"m6 9 6 6 6-6"})})})}function OC(){return f.jsx("svg",{className:"flex-shrink-0 text-ink-2",width:"13",height:"13",viewBox:"0 0 16 16",fill:"none",stroke:"currentColor",strokeWidth:"2.2",strokeLinecap:"round",strokeLinejoin:"round","aria-hidden":"true",children:f.jsx("path",{d:"M3.5 8.5l3 3 6-6.5"})})}function RC(n,l){const s=l.toLowerCase().trim();return s?n.filter(o=>o.label.toLowerCase().includes(s)):n}function zC(n,l){const s=l.toLowerCase().trim();return n.some(o=>o.label.toLowerCase()===s)}function Df({label:n,value:l,options:s,onChange:o,placeholder:u,bare:d=!1,autoOpen:h=!1,onDismiss:p,id:y,creatable:g=!1,canCreate:x}){const[v,E]=_.useState(h),[M,N]=_.useState(0),[A,j]=_.useState(null),[O,z]=_.useState(""),D=_.useId(),Y=_.useRef(null),W=_.useRef(null),ee=_.useRef(null),ae=s.findIndex(q=>q.value===l),U=ae>=0?s[ae]:void 0,re=RC(s,v?O:""),de=MC(O),ce=v&&de.length>0?s.find(q=>q.value===de):void 0,ie=ce&&!re.some(q=>q.value===ce.value)?[...re,ce]:re,L=g&&de.length>0&&!zC(s,O)&&!ce&&((x==null?void 0:x(de))??!0),G=ie.length+(L?1:0);function F(){ee.current&&j(ee.current.getBoundingClientRect()),N(Math.max(0,ae)),E(!0)}const w=_.useCallback(()=>{E(!1),z(""),p==null||p()},[p]);function Z(q){var V;q.value!==l&&o(q.value),E(!1),z(""),(V=W.current)==null||V.focus()}function ue(q){var V;o(q),E(!1),z(""),(V=W.current)==null||V.focus()}function te(q){var V;if(!v){(q.key==="ArrowDown"||q.key==="Enter"||q.key===" ")&&(q.preventDefault(),F());return}if(q.key==="Escape")q.preventDefault(),(V=W.current)==null||V.focus(),w();else if(q.key==="ArrowDown")q.preventDefault(),N(me=>Math.min(G-1,me+1));else if(q.key==="ArrowUp")q.preventDefault(),N(me=>Math.max(0,me-1));else if(q.key==="Enter")if(q.preventDefault(),M<ie.length){const me=ie[M];me&&Z(me)}else L&&ue(de)}const P=_.useCallback(q=>{var he,ke;const V=(he=Y.current)==null?void 0:he.contains(q),me=(ke=document.getElementById(D))==null?void 0:ke.contains(q);return!V&&!me},[D]);function k(q){v&&P(q.relatedTarget)&&w()}_.useEffect(()=>{var q;h&&((q=W.current)==null||q.focus())},[h]),_.useEffect(()=>{if(!v)return;const q=()=>{ee.current&&j(ee.current.getBoundingClientRect())};return q(),window.addEventListener("scroll",q,!0),window.addEventListener("resize",q),()=>{window.removeEventListener("scroll",q,!0),window.removeEventListener("resize",q)}},[v]),_.useEffect(()=>{if(!v)return;const q=V=>{P(V.target)&&w()};return document.addEventListener("mousedown",q),()=>document.removeEventListener("mousedown",q)},[v,P,w]);const I=q=>{q.preventDefault(),v||F()},$=f.jsx("input",{ref:W,id:y,className:d?TC:ye(ss,"cursor-text"),value:v?O:(U==null?void 0:U.label)??l,placeholder:u??"",role:"combobox","aria-haspopup":"listbox","aria-expanded":v,"aria-controls":D,"aria-label":n,onFocus:F,onClick:()=>{v||F()},onChange:q=>{z(q.target.value),v||F(),N(0)},onKeyDown:te}),T=d?f.jsxs(f.Fragment,{children:[$,f.jsx(qb,{open:v,className:"pl-2",onMouseDown:I})]}):f.jsxs(f.Fragment,{children:[$,f.jsx(qb,{open:v,className:"pl-1 pr-2.75",onMouseDown:I})]}),B=v&&A&&G>0?lh.createPortal(f.jsxs("div",{className:CC,id:D,role:"listbox",style:{left:Math.max(Hb,Math.min(A.left,window.innerWidth-Math.max(A.width,Bb)-Hb)),top:A.bottom+NC,minWidth:Math.max(A.width,Bb)},children:[ie.map((q,V)=>f.jsxs("button",{type:"button",role:"option","aria-selected":q.value===l,"data-active":V===M,className:F1,onMouseEnter:()=>N(V),onMouseDown:me=>me.preventDefault(),onClick:()=>Z(q),children:[f.jsx("span",{className:"truncate",children:q.label}),q.value===l&&f.jsx(OC,{})]},q.value)),L&&f.jsx("button",{type:"button",role:"option","aria-selected":M===ie.length,"data-active":M===ie.length,className:AC,onMouseEnter:()=>N(ie.length),onMouseDown:q=>q.preventDefault(),onClick:()=>ue(de),children:f.jsxs("span",{className:"truncate",children:["Create “",de,"”"]})})]}),document.body):null;return d?f.jsxs("div",{className:"flex min-w-0 flex-1 items-center",ref:q=>{Y.current=q,ee.current=q},onBlurCapture:k,children:[T,B]}):f.jsxs("div",{className:Qn,ref:Y,onBlurCapture:k,children:[f.jsx("span",{className:va,children:n}),f.jsx("div",{className:ye(_o,v&&"border-accent"),ref:ee,children:T}),B]})}const DC="relative flex flex-col gap-2",UC="group/li flex cursor-text touch-none items-center gap-2 rounded-[calc(8*var(--content))] border border-line bg-white px-2.75 transition-[border-color,box-shadow] duration-[120ms] hover:border-[#d9d5c9] focus-within:border-accent",LC=ye(ot,"we-no-drag grid size-5.5 flex-shrink-0 place-items-center rounded-[calc(5*var(--content))] text-ink-3 transition-[background,color] duration-[120ms] hover:bg-[#FBE6E2] hover:text-[#8E2C1E]"),BC="pointer-events-none absolute z-[60] flex cursor-grabbing items-center gap-2 overflow-hidden rounded-[calc(8*var(--content))] bg-white px-2.75 text-[length:calc(13.5*var(--content))] text-ink shadow-[0_16px_38px_-8px_rgba(20,18,13,0.5)] after:absolute after:inset-0 after:rounded-[calc(9*var(--content))] after:border after:border-solid after:border-[#d9d5c9] after:content-['']",HC=ye(ot,"flex h-8.5 w-full items-center justify-start gap-1.5 rounded-[calc(8*var(--content))] px-2.5 text-[length:calc(12.5*var(--content))] font-medium text-ink-3 transition-colors duration-[120ms] hover:bg-line-soft hover:text-ink");function qC(n){const l=n.currentTarget.control;if(!l||n.target===l||n.target.closest("button")||(n.preventDefault(),l.focus(),!(l instanceof HTMLInputElement)))return;const o=n.clientX<l.getBoundingClientRect().left?0:l.value.length;l.setSelectionRange(o,o)}function X1({engine:n,label:l,addLabel:s=`Add ${wo(l)}`,renderControl:o,cloneText:u,onAdd:d,renderAdd:h,addDisabled:p=!1}){const{rows:y,drag:g}=n,{containerRef:x,cloneRef:v,getItemProps:E,draggingKey:M,cloneBox:N}=g,A=M?y.find(O=>O.key===M):null,j=h==null?void 0:h(n.add);return f.jsxs("div",{className:Qn,children:[f.jsx("span",{className:va,children:l}),f.jsxs("div",{className:"flex flex-col gap-2",children:[f.jsxs("div",{className:ye(DC,M&&"select-none [&_*]:select-none"),ref:x,children:[y.map(O=>f.jsxs("label",{htmlFor:O.key,onClick:qC,...E(O.key),"data-ghost":M===O.key?"":void 0,className:ye(UC,M===O.key&&"cursor-grabbing border-transparent bg-accent-soft"),children:[f.jsx("span",{"aria-hidden":"true",className:"flex flex-shrink-0 cursor-grab items-center text-ink-4 transition-colors duration-[120ms] hover:text-ink-2 group-data-[ghost]/li:opacity-[0.25]",children:f.jsx(ze.grip,{})}),o({id:O.key,value:O.value,onChange:z=>n.setValue(O.key,z)}),n.canRemove&&f.jsx("button",{type:"button",className:LC,title:"Remove",onClick:()=>n.remove(O.key),children:f.jsx(ze.trash,{})})]},O.key)),A&&f.jsxs("div",{ref:v,className:BC,style:{width:N.w,height:N.h,left:0,top:0,position:"absolute"},children:[f.jsx("span",{"aria-hidden":"true",className:"flex flex-shrink-0 items-center text-ink-4",children:f.jsx(ze.grip,{})}),f.jsx("span",{className:"min-w-0 flex-1 truncate py-2.25",children:u(A.value)})]})]}),j??(!n.atMax&&!p&&f.jsxs("button",{type:"button",className:HC,onClick:()=>d(n.add),children:[f.jsx(ze.plus,{})," ",s]}))]})]})}function GC({engine:n,label:l,placeholder:s="List item",addLabel:o,maxLength:u}){return f.jsx(X1,{engine:n,label:l,addLabel:o,cloneText:d=>d,renderControl:({id:d,value:h,onChange:p})=>f.jsx(Pr,{bare:!0,id:d,value:h,onChange:p,placeholder:s,ariaLabel:s,maxLength:u,className:"cursor-[inherit] py-2.25 text-[length:calc(13.5*var(--content))] group-data-[ghost]/li:opacity-[0.25]"}),onAdd:d=>d("")})}function IC({engine:n,label:l,options:s,unique:o=!1,creatable:u=!1}){const[d,h]=_.useState(!1),p=n.rows.map(E=>E.value),y=E=>o?s.filter(M=>M.value===E||!p.includes(M.value)):s,g=y(null),x=E=>{var M;return((M=s.find(N=>N.value===E))==null?void 0:M.label)??E},v=E=>!o||!p.includes(E);return f.jsx(X1,{engine:n,label:l,addDisabled:!u&&g.length===0,cloneText:E=>x(E),renderControl:({id:E,value:M,onChange:N})=>f.jsx(Df,{bare:!0,id:E,label:l,value:M,options:y(M),onChange:N,creatable:u,canCreate:v}),onAdd:()=>h(!0),renderAdd:E=>d?f.jsx(Df,{bare:!0,autoOpen:!0,label:`Add ${wo(l)}`,value:"",placeholder:"Choose one",options:g,onDismiss:()=>h(!1),onChange:M=>{h(!1),E(M)},creatable:u,canCreate:v}):null})}function QC({slot:n,itemSlot:l,min:s,max:o,value:u,commit:d}){const h=Dl(y=>y.session.listing_intent),p=ei({items:u,min:s,max:o,axis:"y",commit:d});return l.type==="select"?f.jsx(IC,{engine:p,label:n.label,options:$1(l,{listingIntent:h}),creatable:l.creatable===!0,unique:n.unique===!0}):f.jsx(GC,{engine:p,label:n.label,maxLength:l.cap})}function KC(n){const{slot:l,instanceId:s,slotId:o,value:u,onChange:d,recordContext:h}=n,p=EM(l),y=UM(l,s,o,d,h!=null);if(h&&Wj(l,h))return f.jsx(eM,{value:u,propertyId:n.propertyId,recordContext:h,onChange:x=>d(x)});if(p.itemContent.kind==="record")return f.jsx(EC,{slot:l,entries:p.itemContent.entries,min:p.min,max:p.max,instanceId:s,slotId:o,value:u,commit:y,selectedItemIndex:n.selectedItemIndex,selectedFieldName:n.selectedFieldName,itemBaseline:n.itemBaseline});const g=p.itemContent.slot;return p.editor==="gallery"?g.type==="tour"?f.jsx(gM,{min:p.min,max:p.max,value:u,propertyId:n.propertyId,commit:y}):g.type==="video"?f.jsx(wM,{itemSlot:g,min:p.min,max:p.max,value:u,propertyId:n.propertyId,commit:y}):f.jsx(fM,{itemSlot:g,min:p.min,max:p.max,instanceId:s,slotId:o,value:u,propertyId:n.propertyId,selectedItemIndex:n.selectedItemIndex,commit:y}):p.editor==="document-list"?f.jsx(zM,{slot:l,min:p.min,max:p.max,value:u,propertyId:n.propertyId,commit:y}):p.editor==="poi-curation"?f.jsx(mC,{slot:l,min:p.min,max:p.max,value:u,propertyId:n.propertyId,commit:y}):f.jsx(QC,{slot:l,itemSlot:g,min:p.min,max:p.max,value:u,commit:y})}const VC={PanelUI:KC,applyOptimistic:null,coerce:n=>Array.isArray(n)?n:[]};function YC(n,l){const s=String(n??"").replace(/[^\d.]/g,"");if(s==="")return"";const[o,u]=s.split("."),d=Number((o||"0").replace(/[^\d]/g,"")||0).toLocaleString("en-US");return u!=null?`${d}.${u}`:d}function $C(n,l){let s=n.replace(l!=null&&l.decimals?/[^\d.]/g:/[^\d]/g,"");if(l!=null&&l.decimals){const u=s.indexOf(".");u>=0&&(s=s.slice(0,u+1)+s.slice(u+1).replace(/\./g,""))}const o=s.replace(/[^\d]/g,"");return(l==null?void 0:l.maxDigits)!=null&&o.length>l.maxDigits?null:s}function FC({label:n,value:l,onChange:s,prefix:o,suffix:u,group:d,decimals:h,maxDigits:p,placeholder:y,errorText:g}){const x=d?YC(l):l;return f.jsxs("div",{className:Qn,children:[f.jsx("span",{className:va,children:n}),f.jsxs("div",{className:ye(_o,g&&"border-danger"),children:[o&&f.jsx("span",{className:ye(lf,"pl-2.75"),children:o}),f.jsx("input",{className:ye(ss,"[font-variant-numeric:tabular-nums]",o&&"pl-1"),inputMode:h?"decimal":"numeric",value:x,placeholder:y??"0",onChange:v=>{const E=$C(v.target.value,{decimals:h,maxDigits:p});E!=null&&s(E)}}),u&&f.jsx("span",{className:ye(lf,"pr-2.75"),children:u})]}),g&&f.jsx("p",{className:th,children:g})]})}function XC(n){return n==null?"":String(n)}function Z1(n){const l=n.trim();if(l==="")return null;const s=Number(l);return Number.isFinite(s)?s:null}function ZC({slot:n,value:l,onChange:s}){return f.jsx(FC,{label:n.label,value:XC(l),onChange:o=>s(Z1(o)),prefix:n.prefix,suffix:n.suffix,group:n.thousandsSep,decimals:n.decimals,maxDigits:n.maxDigits,placeholder:n.placeholder})}const PC={PanelUI:ZC,applyOptimistic:null,coerce:n=>typeof n=="number"?n:Z1(typeof n=="string"?n:"")},JC="flex flex-col gap-2";function WC({slot:n,value:l,onChange:s,propertyId:o}){const{apiFetch:u}=Vn().api,[d,h]=_.useState(null),[p,y]=_.useState(null),g=_.useMemo(()=>l?[l]:[],[l]),{urls:x,dropUrl:v}=Q1(o,g);async function E(M){if(h(null),(l==null?void 0:l.place_id)!==M.place_id){y(M);try{const N=await D1(u,o,M.place_id);s(N)}catch{h("Couldn't add that place — try again.")}finally{y(null)}}}return f.jsxs("div",{className:JC,children:[f.jsx(V1,{propertyId:o,placeholder:n.placeholder??"Search nearby…",addedIds:l?new Set([l.place_id]):new Set,onSelect:M=>void E(M)}),d&&f.jsx("span",{className:H1,children:d}),p?f.jsxs("div",{className:ye(xh,q1),"aria-live":"polite",children:[f.jsx("span",{className:oc,children:f.jsx("span",{className:G1})}),f.jsxs("div",{className:_h,children:[f.jsx("span",{className:rc,children:p.name}),f.jsx("span",{className:wh,children:"Adding…"})]})]}):l?f.jsx(K1,{row:l,photoUrl:x[l.place_id],onPhotoError:()=>v(l.place_id),onRemove:()=>s(null)}):f.jsx("div",{className:B1,children:"No place yet — search above to choose one."})]})}const eA={PanelUI:WC,applyOptimistic:null,coerce:L1};function tA({slot:n,value:l,onChange:s}){const o=Dl(d=>d.session.listing_intent),u=$1(n,{listingIntent:o});return f.jsx(Df,{label:n.label,value:l??"",options:u,creatable:n.creatable??!1,placeholder:"Choose one",onChange:s})}const nA={PanelUI:tA,applyOptimistic:null,coerce:n=>typeof n=="string"?n:null},aA="data-slot-id",Gb="data-slot-text-leaf",lA="data-slot-group",iA="data-slot-item",sA="data-slot-field",oA="data-slot-unselectable",yc="data-section-instance-id";function rA(n,l){const s=[];n.hasAttribute(Gb)&&s.push(n),s.push(...Array.from(n.querySelectorAll(`[${Gb}]`))),s.length!==0&&s.forEach(o=>{cA(o,l)})}function cA(n,l){const s=n.ownerDocument,o=[];l.split(`
|
|
1099
|
+
`).forEach((u,d)=>{d>0&&o.push(s.createElement("br")),o.push(s.createTextNode(u))}),n.replaceChildren(...o)}function P1(n){return typeof n=="string"?n:n==null?"":typeof n=="number"||typeof n=="boolean"?String(n):""}const uA={short:120,medium:240,long:2e3};function dA(n){return uA[n]}function fA({slot:n,value:l,onChange:s}){const o=l??"",u=n.size??"short",d=typeof n.cap=="number"?n.cap:dA(u);return u==="long"?f.jsx(Pr,{value:o,onChange:s,label:n.label,max:d,maxLength:d,placeholder:n.placeholder,multiline:!0,rows:5}):u==="medium"?f.jsx(Pr,{value:o,onChange:s,label:n.label,max:d,maxLength:d,placeholder:n.placeholder,multiline:!0,rows:2}):f.jsx(Pr,{value:o,onChange:s,label:n.label,max:d,maxLength:d,placeholder:n.placeholder??""})}const hA={PanelUI:fA,applyOptimistic:rA,coerce:P1};function pA({slot:n,value:l,onChange:s}){const o=l??"",[u,d]=_.useState(o),[h,p]=_.useState(o);o!==h&&(p(o),d(o));const y=Nf(u),g=Tf(y),x=n.accepts,v=x===void 0||y===""||nf(x,y),E=y!==""&&(!g||!v),M=N=>{const A=Nf(N);A!==""&&!Tf(A)||A!==""&&x!==void 0&&!nf(x,A)||(d(A),A!==o&&s(A))};return f.jsxs("div",{className:Qn,children:[f.jsx(hv,{label:n.label}),f.jsxs("div",{className:_o,children:[f.jsx("input",{className:ss,type:"text",inputMode:"url",value:u,placeholder:n.placeholder??"https://",spellCheck:!1,onChange:N=>d(N.target.value),onBlur:N=>M(N.target.value)}),f.jsx("span",{className:ye(lf,"pr-2.75"),children:g?f.jsx("a",{href:y,target:"_blank",rel:"noopener noreferrer",className:ye(ot,"flex items-center text-ink-4 hover:text-accent transition-colors duration-[120ms]"),"aria-label":"Open URL in new tab",children:f.jsx(ze.external,{})}):f.jsx("span",{className:"flex items-center text-ink-4 opacity-30",children:f.jsx(ze.external,{})})})]}),E&&f.jsx("p",{className:th,children:g?Af(x):"Not a valid URL"})]})}const mA={PanelUI:pA,applyOptimistic:null,coerce:P1};let Ib=null;function yA(){return Ib??(Ib={text:hA,number:PC,select:nA,image:Qj,list:VC,poi:eA,url:mA,video:xM,tour:mM,document:zj}),Ib}function J1(n){const s=yA()[n];return s===void 0?null:s}function W1(n){const l=J1(n.type);return l?l.isEditable?l.isEditable(n):n.locked!==!0:!1}function gA(n,l){const s=n.variant;return!s||l==null?!0:s.cases.includes(l)}function bA(n){const l=Object.keys(n.slots),s=n.slot_order;if(!s||s.length===0)return l;const o=new Set,u=[];for(const d of s)d in n.slots&&!o.has(d)&&(o.add(d),u.push(d));for(const d of l)o.has(d)||u.push(d);return u}function ex(n,l){const s=[],o=new Map,u=new Map;for(const d of n.groups??[])for(const h of d.members.flat())u.set(h,{id:d.id,label:d.label});for(const d of bA(n)){const h=n.slots[d];if(!W1(h)||!gA(h,l))continue;const p=u.get(d);if(p){let y=o.get(p.id);y||(y={kind:"group",key:p.id,label:p.label,Icon:null,items:[],rows:[]},o.set(p.id,y),s.push(y)),y.items.push({slotId:d,slot:h})}else gh(h).editor==="row-editor"?s.push({kind:"record",key:d,label:h.label,Icon:null,slotId:d,slot:h}):s.push({kind:"group",key:d,label:h.label,Icon:null,items:[{slotId:d,slot:h}],rows:[]})}for(const d of s)d.kind==="group"&&(d.rows=jv(d.items.map(h=>h.slot)),d.Icon=Y1(d.items.map(h=>h.slot)));return s}function vA(n){return n==null?!0:typeof n=="string"?n.trim()==="":Array.isArray(n)?n.length===0:typeof n=="object"?Object.keys(n).length===0:!1}function xA(n,l,s){const o=[];for(const u of ex(n,l)){const d=u.kind==="group"?u.items:[{slotId:u.slotId,slot:u.slot}];for(const{slotId:h,slot:p}of d)p.variant&&vA(s(h))&&o.push(h)}return o}const _A=ge("Instagram",[["rect",{width:"20",height:"20",x:"2",y:"2",rx:"5",ry:"5",key:"ig-frame"}],["path",{d:"M16 11.37A4 4 0 1 1 12.63 8 4 4 0 0 1 16 11.37z",key:"ig-lens"}],["line",{x1:"17.5",x2:"17.51",y1:"6.5",y2:"6.5",key:"ig-flash"}]]),wA=ge("Facebook",[["path",{d:"M18 2h-3a5 5 0 0 0-5 5v3H7v4h3v8h4v-8h3l1-4h-4V7a1 1 0 0 1 1-1h3z",key:"fb-f"}]]),SA=ge("Linkedin",[["path",{d:"M16 8a6 6 0 0 1 6 6v7h-4v-7a2 2 0 0 0-2-2 2 2 0 0 0-2 2v7h-4v-7a6 6 0 0 1 6-6z",key:"li-arm"}],["rect",{width:"4",height:"12",x:"2",y:"9",key:"li-stem"}],["circle",{cx:"4",cy:"4",r:"2",key:"li-dot"}]]),kA=ge("XLogo",[["path",{d:"M18.901 1.153h3.68l-8.04 9.19L24 22.846h-7.406l-5.8-7.584-6.638 7.584H.474l8.6-9.83L0 1.154h7.594l5.243 6.932ZM17.61 20.644h2.039L6.486 3.24H4.298Z",transform:"translate(2 2) scale(0.8333)",fill:"currentColor",stroke:"none",key:"x-mark"}]]),EA={home:$k,building:ik,template:e5,palette:E5,filePen:Dk,library:n5,plug:R5,helpCircle:bk,lock:u5,creditCard:kk,settings:Q5,power:U5,user:a4,plus:sv,globe:Kk,image:Jf,fileText:Pf,users:i4,eye:av,eyeOff:nv,pulse:IS,search:rv,chart:ck,layout:Jk,chevDown:fk,chevRight:pk,chevSelector:yk,pencil:M5,dots:Nk,grip:lv,external:tv,copy:wk,trash:cv,archive:KS,sparkle:$5,arrowUp:ek,arrowDown:YS,arrowLeft:ZS,arrowRight:JS,undo:J5,redo:H5,logout:f5,check:ev,x:fv,clock:xk,calendar:ok,mapPin:iv,userPlus:t4,mail:p5,phone:A5,share:V5,upload:uv,bookOpen:nk,newspaper:S5,presentation:ov,instagram:_A,facebook:wA,linkedin:SA,xLogo:kA};function Pl({name:n,size:l=18,stroke:s=2,fill:o,color:u,className:d,style:h}){const p=EA[n];return f.jsx(p,{size:l,strokeWidth:s,fill:o??"none",color:u,className:d,style:{flexShrink:0,width:`calc(${l} * var(--content))`,height:`calc(${l} * var(--content))`,color:u??"currentColor",...h},"aria-hidden":"true"})}function jA(){return f.jsxs("div",{className:"hp-rest-in flex min-h-0 flex-1 flex-col items-center justify-center px-8 pb-10 text-center",children:[f.jsx("span",{className:"text-ink-4","aria-hidden":"true",children:f.jsx(Pl,{name:"pencil",size:22,stroke:1.6})}),f.jsx("p",{className:"m-0 mt-3 text-body-lg font-medium text-ink-2",children:"Nothing selected"}),f.jsx("p",{className:"m-0 mt-1 max-w-[calc(220*var(--content))] text-body leading-[1.45] text-ink-4",children:"Click anything on the canvas to edit it"})]})}const Qb=1;function Kb(n){const l=new URLSearchParams;for(const[o,u]of Object.entries(n))u!=null&&u!==""&&l.set(o,u);const s=l.toString();return s===""?"":`?${s}`}const Rl={catalog:"api/catalog",render:"api/render",media:n=>`api/media${Kb({fixture:n})}`,capture:(n,l)=>`api/capture/${n}${Kb({fixture:l.fixture,format:l.format,page:l.page,canvas:l.canvas})}`,live:(n,l)=>`fixtures/${encodeURIComponent(n)}/live${l==="/"?"/":`${l}/`}`,hmr:"__hmr"},MA={source:"source:changed",stylesheet:"stylesheet:changed",fixtures:"fixtures:changed"};async function Vb(n,l){const s=(await l.text().catch(()=>"")).trim();return new Error(s===""?`${n}: HTTP ${l.status}`:s)}function CA(n,l=(s,o)=>fetch(s,o)){const s=u=>new URL(u,n).href,o=async u=>{const d=await l(s(u));if(!d.ok)throw await Vb(u,d);return await d.json()};return{base:n,async catalog(){const u=await o(Rl.catalog);if(u.wire!==Qb)throw new Error(`This playground speaks wire ${Qb}, and its host answered with wire ${String(u.wire)}.`);return u},async render(u){const d=await l(s(Rl.render),{method:"POST",headers:{"content-type":"application/json"},body:JSON.stringify(u)});if(!d.ok)throw await Vb(Rl.render,d);return await d.json()},media:u=>o(Rl.media(u)),captureHref:(u,d)=>s(Rl.capture(u,d)),liveHref:(u,d)=>s(Rl.live(u,d)),subscribe(u){let d;try{d=new EventSource(s(Rl.hmr))}catch{return()=>{}}const h=Object.entries(u).map(([p,y])=>{const g=MA[p],x=()=>y();return d.addEventListener(g,x),()=>d.removeEventListener(g,x)});return()=>{for(const p of h)p();d.close()}}}}let Uf=null;function AA(n){Uf=n}function NA(){if(Uf===null)throw new Error("The playground's host is not installed yet.");return Uf}let tx=null;function TA(n){tx=n}function OA(){return tx}function Yb(n,l){return`${n} ${l}${n===1?"":"s"}`}function RA(n){const l=[n.propertyType,n.listingIntent].filter(o=>o!==null).map(o=>o.replaceAll("_"," "));l.push(Yb(n.units,"unit"),Yb(n.photos,"photo"));const s=l.join(", ");return s.charAt(0).toUpperCase()+s.slice(1)}function zA(n){return`${n.label} (${RA(n.summary)})`}function DA(n,l){return`${n}${n.includes("?")?"&":"?"}v=${encodeURIComponent(l)}`}function UA(n){return{basePath:n.basePath,stylesheets:n.stylesheets.map(l=>DA(l,n.cssRev)),importMap:n.importMap,islandMap:n.islands,hostScriptSrc:n.hostScript,hostResolvesOwnImports:Object.keys(n.importMap).length===0}}function $b(n){const l=n.sectionSchemaByInstance??{};return{markers:{sectionInstanceId:yc,slotId:aA,slotGroup:lA,slotItem:iA,slotField:sA,slotUnselectable:oA},assets:UA(n),...n.pageBox===void 0?{}:{pageBox:n.pageBox},isSlotEditable:(s,o,u)=>{var h,p,y;const d=(h=l[s])==null?void 0:h.slots[o];return d===void 0||d.locked===!0?!1:u===void 0||((y=(p=d.fields)==null?void 0:p[u])==null?void 0:y.locked)!==!0}}}const LA=/^\/properties\/[^/]+\/poi\/search$/,BA=/^\/properties\/[^/]+\/poi\/([^/]+)$/,Lf=[{place_id:"pg-coffee",name:"Bluebird Coffee",address:"88 Market St",lat:40.798,lng:-73.972,distance_m:210,rating:4.6,review_count:312,type_label:"Coffee shop",price_level:"PRICE_LEVEL_INEXPENSIVE"},{place_id:"pg-park",name:"Riverside Park",address:"500 Riverside Dr",lat:40.8,lng:-73.97,distance_m:320,type_label:"Park"},{place_id:"pg-grocer",name:"Corner Grocery",address:"45 Vine Ave",lat:40.796,lng:-73.968,distance_m:480,rating:4.1,review_count:88,type_label:"Grocery store"},{place_id:"pg-school",name:"Lincoln Elementary School",address:"12 School St",lat:40.803,lng:-73.965,distance_m:640,type_label:"Elementary school"},{place_id:"pg-transit",name:"Metro Station — 5th & Main",address:null,lat:40.799,lng:-73.975,distance_m:750,type_label:"Transit station"},{place_id:"pg-gym",name:"Eastside Fitness",address:"300 Water St",lat:40.805,lng:-73.961,distance_m:1100,rating:3.9,review_count:174,type_label:"Gym",summary:"A neighborhood gym with a lap pool and early hours."}];function HA(n){const l=typeof n=="object"&&n!==null?n.query:void 0,s=typeof l=="string"?l.trim().toLowerCase():"";return s?{results:Lf.filter(o=>{var u;return o.name.toLowerCase().includes(s)||(((u=o.address)==null?void 0:u.toLowerCase().includes(s))??!1)})}:{results:Lf}}let qA=0;function GA(n,l={}){const s=(l.method??"GET").toUpperCase();if(s==="POST"&&LA.test(n))return Promise.resolve(HA(l.json));const o=s==="GET"?BA.exec(n):null;if(o){const u=decodeURIComponent(o[1]),d=Lf.find(h=>h.place_id===u);if(d)return Promise.resolve({...d,id:`pg-row-${++qA}`})}return Promise.reject(new Error(`No API backend in the playground: ${l.method??"GET"} ${n}. This capability is served by the host application; supply a provider to use it here.`))}function IA(n,l,s){const o=Math.min(Math.max(Math.round(n.nx*l),0),Math.max(l-1,0)),u=Math.min(Math.max(Math.round(n.ny*s),0),Math.max(s-1,0)),d=Math.max(Math.min(Math.round(n.nw*l),l-o),1),h=Math.max(Math.min(Math.round(n.nh*s),s-u),1);return{sx:o,sy:u,sw:d,sh:h}}function QA(n,l){return new Promise((s,o)=>{const u=l.createElement("img");u.onload=()=>s(u),u.onerror=()=>o(new Error(`Could not load ${n} to crop it.`)),u.src=n})}async function KA(n,l,s=document){const o=await QA(n,s),{sx:u,sy:d,sw:h,sh:p}=IA(l,o.naturalWidth,o.naturalHeight),y=s.createElement("canvas");y.width=h,y.height=p;const g=y.getContext("2d");if(!g)throw new Error("No 2d canvas context; cannot crop.");g.drawImage(o,u,d,h,p,0,0,h,p);const x=await new Promise(v=>y.toBlob(v));if(!x)throw new Error("Canvas produced no blob; cannot crop.");return URL.createObjectURL(x)}const $l="2026-01-01T00:00:00.000Z",Fb=new Map;function ul(n){let l=Fb.get(n);return l===void 0&&(l=NA().media(n).then(s=>s.items).catch(()=>[]),Fb.set(n,l)),l}function VA(n,l){return l.filter(s=>s.kind==="photo").map(s=>({id:s.id,property_id:n,name:s.name,thumbnail_url:s.src,uploaded_at:$l,caption:s.caption??null}))}function YA(n,l){return l.filter(s=>s.kind==="video").map(s=>({id:s.id,property_id:n,name:s.name,poster_url:s.src,ready:s.ready??!0,duration_ms:s.durationMs??null,width:null,height:null,uploaded_at:$l,caption:s.caption??null,source:s.provider===void 0?"upload":"link",provider:s.provider??null}))}function $A(n){return n.filter(l=>l.kind==="tour").map(l=>({id:l.id,name:l.name,provider:l.provider??"",poster_url:l.src,caption:l.caption??null,ready:l.ready??!0}))}function FA(n,l){return l.filter(s=>s.kind==="document").map(s=>({id:s.id,property_id:n,name:s.name,mime:s.mime??"",size_bytes:s.sizeBytes??0,preview_url:s.src,uploaded_at:$l}))}function nx(n,l){return{floorplans:l.filter(o=>o.kind==="plan").map(o=>({id:o.id,property_id:n,source:null,thumbnail_url:o.src,ready:!0,uploaded_at:$l,display_label:J3(o.name,1)}))}}function us(n){return Promise.reject(new Error(`${n} is served by the host application and has no playground equivalent. A fixture's media is read-only.`))}async function XA(n){return{photos:VA(n,await ul(n))}}async function ZA(n){return{videos:YA(n,await ul(n))}}async function PA(n){return{tours:$A(await ul(n))}}async function JA(n){return{documents:FA(n,await ul(n))}}async function WA(n){return nx(n,await ul(n))}async function eN(n,l){const{floorplans:s}=nx(n,await ul(n)),o=s.find(u=>u.id===l);if(!o)throw new Error(`The fixture's property has no floor plan ${l}.`);return{source_url:o.thumbnail_url,source_bbox:null,ai_bbox:null,source_width:null,source_height:null}}function tN(n){return us("Upload status")}function nN(n,l,s){return us("Re-cropping a floor plan")}function aN(n,l,s){return us("Pasting a link")}function lN(n,l,s){return us("Uploading a comparable's photo")}function iN(n,l,s){return us("A comparable's photo")}function sN(n,l,s){return us("Uploading a comparable's photo")}const Bf=new Map;let Xb=0;async function oN(n,l,s,o){const d=(await ul(n)).find(y=>y.id===l);if(!(d!=null&&d.src))throw new Error(`The fixture's property has no asset ${l} to crop.`);const h=`dev-crop-${++Xb}`;Bf.set(h,{sourceUrl:d.src,rect:s});const p={status:"processing",job_id:h,crop_key:h};if(o){const y=`dev-crop-${++Xb}`;Bf.set(y,{sourceUrl:d.src,rect:o}),p.mobile={job_id:y,crop_key:y}}return p}function rN(n,l){return Promise.resolve({id:l,kind:"image_crop",status:"succeeded",enqueued_at:$l,started_at:$l,completed_at:$l})}const Zb=new Map;function cN(n,l){const s=Bf.get(l);if(!s)return Promise.reject(new Error(`Unknown crop ${l}.`));let o=Zb.get(l);return o||(o=KA(s.sourceUrl,s.rect),Zb.set(l,o)),o}const Pb="2026-01-01T00:00:00.000Z";function uN(n){return n.endsWith("logo (dark)")?"logo_dark":n.endsWith("logo (light)")?"logo_light":"headshot"}function dN(n,l){if(l)return l;const[s]=n.split(" — ");return s??n}function fN(n){const l=new Map;for(const s of n){if(s.kind!=="library")continue;const o=dN(s.name,s.caption);let u=l.get(o);switch(u||(u={id:`dev-contact-${o.toLowerCase().replace(/[^a-z0-9]+/g,"-").replace(/^-|-$/g,"")}`,category:"contact",fields:{name:o},created_at:Pb,updated_at:Pb},l.set(o,u)),uN(s.name)){case"headshot":u.fields.avatar_upload_id=s.id,u.avatar_url=s.src;break;case"logo_dark":u.fields.logo_dark_upload_id=s.id,u.logo_dark_url=s.src;break;case"logo_light":u.fields.logo_light_upload_id=s.id,u.logo_light_url=s.src;break}}return[...l.values()]}async function hN(n="contact"){const l=OA();return{items:l===null?[]:fN(await ul(l))}}function Sh(){return Promise.reject(new Error("Library uploads are served by the host application. The dev media pack is read-only."))}function pN(n,l){return Sh()}function mN(n,l,s){return Sh()}function yN(n,l){return Sh()}function gN(n){return Promise.reject(new Error("There is no property in the playground: the canvas renders a template, not a listing."))}const bN=12;function vN(n,l,s,o){if(n.top>=o&&n.bottom<=l-o)return null;const d=Math.max(0,s+n.top-o);return Math.abs(d-s)<1?null:d}function ax({icon:n,title:l,subtitle:s,showGrip:o=!1,showChevron:u=!0,open:d}){return f.jsxs(f.Fragment,{children:[o?f.jsx("span",{"aria-hidden":"true",className:"-mr-1 flex flex-shrink-0 cursor-grab items-center text-ink-4 transition-colors duration-[120ms] hover:text-ink-2 active:cursor-grabbing",children:f.jsx(Pl,{name:"grip",size:14,stroke:1.8})}):null,f.jsx("span",{className:"grid size-6.5 flex-shrink-0 place-items-center rounded-md bg-accent-soft text-accent-ink","aria-hidden":"true",children:n}),s?f.jsxs("span",{className:"flex min-w-0 flex-1 flex-col gap-px",children:[f.jsx("span",{className:"truncate text-[length:calc(13.5*var(--content))] font-medium text-ink-2",children:l}),f.jsx("span",{className:"truncate text-[length:calc(11.5*var(--content))] text-ink-3 [font-variant-numeric:tabular-nums]",children:s})]}):f.jsx("span",{className:"min-w-0 flex-1 truncate text-left text-[length:calc(13.5*var(--content))] font-medium text-ink-2",children:l}),u?f.jsx("span",{"data-acc-open":d,className:"grid flex-shrink-0 place-items-center text-ink-3 transition-transform duration-150 ease-[ease] data-[acc-open=true]:rotate-180","aria-hidden":"true",children:f.jsx(Pl,{name:"chevDown",size:14,stroke:1.8})}):null]})}function lx({open:n,onToggle:l,icon:s,title:o,subtitle:u,scrollKey:d,dragId:h,dragHandleProps:p,children:y}){const g=_.useRef(null);return _.useEffect(()=>{if(!n)return;const x=g.current,v=x==null?void 0:x.closest(".hp-sb-scroll");if(!x||!v)return;const E=window.matchMedia("(prefers-reduced-motion: reduce)").matches,M=()=>{const O=x.getBoundingClientRect(),z=v.getBoundingClientRect(),D=vN({top:O.top-z.top,bottom:O.bottom-z.top,height:O.height},v.clientHeight,v.scrollTop,bN);D!=null&&v.scrollTo({top:D,behavior:E?"auto":"smooth"})};if(E){const O=requestAnimationFrame(M);return()=>cancelAnimationFrame(O)}const N=new AbortController,A=()=>{N.abort(),window.clearTimeout(j),M()};x.addEventListener("transitionend",O=>{O.propertyName==="grid-template-rows"&&O.target instanceof Node&&O.target.parentNode===x&&A()},{signal:N.signal});const j=window.setTimeout(A,280);return()=>{N.abort(),window.clearTimeout(j)}},[n,d]),f.jsxs("div",{ref:g,"data-open":n,"data-dragid":h,className:ye("we-acc flex-shrink-0 overflow-hidden rounded border border-line bg-canvas","origin-center [transform:scale(var(--gx,1),var(--gy,1))] [will-change:transform]","[transition:transform_.18s_cubic-bezier(.34,1.56,.64,1),box-shadow_.18s_ease,border-color_.16s_ease]","has-[>.we-acc-head:hover]:shadow-[0_4px_14px_-6px_rgba(20,24,15,0.18)]","has-[>.we-acc-head:active]:[transition-duration:.08s]","motion-reduce:[transform:none] motion-reduce:[transition:box-shadow_.18s_ease,border-color_.16s_ease]"),children:[f.jsx("button",{type:"button",className:ye("we-acc-head flex w-full cursor-pointer appearance-none items-center gap-2.5 border-0 bg-transparent pr-3.5 py-3 text-left outline-none",p?"pl-2":"pl-3.5",p&&"touch-none"),onClick:l,onPointerDown:p==null?void 0:p.onPointerDown,"aria-expanded":n,children:f.jsx(ax,{icon:s,title:o,subtitle:u,showGrip:p!=null,open:n})}),f.jsx("div",{"data-acc-open":n,className:"grid grid-rows-[0fr] transition-[grid-template-rows] duration-200 ease-out data-[acc-open=true]:grid-rows-[1fr] motion-reduce:transition-none","aria-hidden":!n,children:f.jsx("div",{className:"min-h-0 overflow-hidden",children:f.jsx("div",{"data-acc-open":n,className:"bg-white px-3.5 pb-4 pt-2 opacity-0 transition-opacity duration-200 ease-out data-[acc-open=true]:opacity-100 motion-reduce:transition-none",children:y})})})]})}function xN(n,l,s){return Promise.reject(new Error("Uploading is served by the host application; the playground has no upload backend."))}function _N(n,l){return Promise.reject(new Error("Uploading is served by the host application; the playground has no upload backend."))}const wN={getPhotos:XA,getVideos:ZA,getTours:PA,getDocuments:JA,getFloorplans:WA,getUploads:tN,recropFloorplan:nN,listLibraryItems:hN,postUploadWithProgress:xN,deleteUpload:_N};function SN({open:n,onClose:l}){return n?f.jsxs("div",{className:"rounded-md border border-dashed border-ink-4 bg-accent-soft px-3 py-2.5","data-testid":"unit-plan-picker-stub",role:"dialog","aria-label":"Floor-plan assignment",children:[f.jsx("p",{className:"text-caption font-medium text-ink-2",children:"Floor-plan assignment lives in the app"}),f.jsx("p",{className:"mt-1 text-caption text-ink-3",children:"Assigning a floor plan to a unit is a property-editing act, done against a real property. The playground has no property, so this picker is inert here."}),f.jsx("button",{type:"button",className:"mt-2 rounded-md border border-ink-4 px-2 py-1 text-caption text-ink-2",onClick:l,children:"Close"})]}):null}function cc(n){return n===null||typeof n!="object"?JSON.stringify(n)??"undefined":Array.isArray(n)?`[${n.map(cc).join(",")}]`:`{${Object.keys(n).sort().map(l=>`${JSON.stringify(l)}:${cc(n[l])}`).join(",")}}`}function kN(n,l,s,o){if(l===null||l.fixtureId!==s)return[];const u=[];for(const[d,h]of Object.entries(n.slots)){const p=cc(h);if(p===cc(l.slots[d]))continue;const y=o.slots[d];y!==void 0&&u.push({id:`${d}:scalar::@${p}`,kind:"scalar",label:y.label,slotId:d})}return u}const EN={fact:"border-accent/40 text-accent",computed:"border-accent/40 text-accent",authored:"border-line text-ink-2",empty:"border-dashed border-line text-ink-4",edited:"border-honey-2 bg-honey/20 text-honey-ink"};function ix(n){return f.jsx("span",{className:"inline-flex flex-shrink-0 items-center gap-1","data-testid":"provenance-chips",children:n.chips.map(l=>f.jsx("span",{"data-testid":"provenance-chip","data-provenance":l.kind,"data-slots":l.slots.map(s=>s.id).join(" "),title:`${l.kind}: ${l.slots.map(s=>s.ref===null?s.id:`${s.id} ← ${s.ref}`).join(", ")}`,className:`pointer-events-auto inline-flex h-[18px] cursor-help items-center rounded-full border bg-canvas px-1.5 font-mono text-[10px] font-normal normal-case leading-none tracking-[0.02em] ${EN[l.kind]}`,children:l.kind},l.kind))})}function jN(n){return f.jsxs("div",{className:"relative",children:[n.children,f.jsx("div",{className:"pointer-events-none absolute right-10 top-[15px]",children:f.jsx(ix,{chips:n.chips})})]})}function MN(n,l){const s=!l,o=n.required&&!s;return{hidden:s,locked:o,title:o?"Required section — cannot hide":s?"Hidden from live page":"Visible on live page"}}function sx(n){const{variant:l}=n;return l===null||l.locked||l.cases.length<2?null:l.cases}function CN(n,l){return l||(n==null?void 0:n.kind)==="session"?{kind:"edited",ref:null}:n===void 0?{kind:"empty",ref:null}:n.kind==="fact"||n.kind==="computed"?{kind:n.kind,ref:n.ref}:{kind:n.kind,ref:null}}function AN(n,l,s){const o=new Map;for(const u of n){const{kind:d,ref:h}=CN(l==null?void 0:l[u],s(u));o.set(d,[...o.get(d)??[],{id:u,ref:h}])}return[...o].map(([u,d])=>({kind:u,slots:d}))}const Jb="grid h-8 w-8 cursor-pointer place-items-center rounded-md border-0 p-0 transition-colors";function NN(n){const l=MN(n.display,n.enabled);return f.jsxs("header",{className:"flex min-h-[calc(56*var(--content))] flex-shrink-0 items-center justify-between gap-3 px-5 pb-2 pt-4","data-testid":"section-header",children:[f.jsx("div",{className:"flex min-w-0 flex-1 items-center",children:f.jsx("h2",{className:"m-0 truncate text-body-lg font-semibold tracking-[-0.005em] text-ink",children:n.label})}),f.jsxs("div",{className:"inline-flex flex-shrink-0 items-center gap-0.5",children:[f.jsx("button",{type:"button","data-testid":"section-eye","aria-pressed":l.hidden,"aria-label":l.title,onClick:()=>!l.locked&&n.onSetEnabled(l.hidden),disabled:l.locked,title:l.title,className:`${Jb} disabled:cursor-not-allowed disabled:text-ink-4 disabled:opacity-100 ${l.hidden?"bg-[rgba(20,18,13,0.06)] text-ink [box-shadow:inset_0_0_0_1px_var(--color-line)]":"bg-transparent text-ink-2 hover:bg-[rgba(20,18,13,0.06)] hover:text-ink disabled:hover:bg-transparent disabled:hover:text-ink-4"}`,children:f.jsx(Pl,{name:l.hidden?"eyeOff":"eye",size:15,stroke:1.8})}),sx(n.display)?f.jsx("button",{type:"button","data-testid":"section-gear",onClick:n.onOpenSettings,title:"Section settings","aria-label":"Section settings",className:`${Jb} bg-transparent text-ink-2 hover:bg-[rgba(20,18,13,0.06)] hover:text-ink`,children:f.jsx(Pl,{name:"settings",size:15,stroke:1.8})}):null]})]})}const TN=ye("group/case flex cursor-pointer items-center gap-2.5 rounded border border-line bg-canvas px-3 py-2.5","transition-[border-color,background-color] hover:border-[var(--color-ink-4)]","has-[:focus-visible]:border-accent","data-[selected=true]:border-accent data-[selected=true]:bg-accent-soft");function ON(n){const l=sx(n.display),s=xA(n.sectionSchema,n.variant,n.slotValue).length;return f.jsxs(f.Fragment,{children:[f.jsx("header",{className:"flex min-h-[calc(56*var(--content))] flex-shrink-0 items-center justify-between gap-3 px-5 pb-2 pt-4",children:f.jsxs("nav",{className:"inline-flex min-w-0 items-center gap-1.5 text-body-lg tracking-[-0.005em]","aria-label":"Breadcrumbs",children:[f.jsx("button",{type:"button","data-testid":"settings-back",onClick:n.onBack,className:"max-w-[calc(220*var(--content))] cursor-pointer truncate border-0 bg-transparent p-0 font-medium text-ink-3 hover:bg-transparent transition-colors hover:text-ink hover:underline hover:underline-offset-[3px]",children:n.label}),f.jsx("span",{className:"inline-grid place-items-center leading-none text-ink-4","aria-hidden":"true",children:f.jsx(Pl,{name:"chevRight",size:12,stroke:1.8})}),f.jsx("span",{className:"max-w-[calc(220*var(--content))] truncate font-semibold text-ink",children:"Settings"})]})}),f.jsx("div",{className:"hp-sb-scroll min-h-0 flex-1 overflow-y-auto px-4 pb-6 pt-2","data-testid":"section-settings",children:l?f.jsxs("section",{"aria-label":"Variation",className:"flex flex-col gap-2.5",children:[f.jsx("h3",{className:"px-1 text-[length:calc(11.5*var(--content))] font-medium uppercase tracking-[0.04em] text-ink-3",children:"Variation"}),f.jsx("div",{className:"flex flex-col gap-2",children:l.map(o=>f.jsxs("label",{"data-selected":o.value===n.variant,className:TN,children:[f.jsx("input",{type:"radio",className:"sr-only",name:`variation-${n.instanceId}`,value:o.value,checked:o.value===n.variant,onChange:()=>n.onSetVariant(o.value)}),f.jsx("span",{"aria-hidden":"true",className:"grid size-4 flex-shrink-0 place-items-center rounded-full border-[1.5px] border-ink-4 transition-colors group-data-[selected=true]/case:border-accent",children:f.jsx("span",{className:"size-2 rounded-full bg-accent opacity-0 transition-opacity group-data-[selected=true]/case:opacity-100"})}),f.jsx("span",{className:"min-w-0 flex-1 truncate text-[length:calc(13.5*var(--content))] font-medium text-ink",children:o.label})]},o.value))}),s>0?f.jsx("p",{"aria-live":"polite",className:"rounded border border-line bg-accent-soft px-3 py-2 text-[length:calc(12.5*var(--content))] leading-[1.45] text-ink-2",children:s===1?"1 empty field in this variation":`${s} empty fields in this variation`}):null]}):f.jsx("p",{className:"px-1 py-3 text-[length:calc(12.5*var(--content))] text-ink-3",children:"Nothing to configure in this section."})})]})}function RN(){return typeof window<"u"&&typeof window.matchMedia=="function"&&window.matchMedia("(prefers-reduced-motion: reduce)").matches}function Wb(n){return f.jsx("svg",{viewBox:"0 0 14 14",width:"13",height:"13",fill:"none",stroke:"currentColor",strokeWidth:"1.7",strokeLinecap:"round",strokeLinejoin:"round","aria-hidden":"true",...n,children:f.jsx("path",{d:"M2.5 7h9M8 3.5 11.5 7 8 10.5"})})}function zN(n){return f.jsx("svg",{viewBox:"0 0 16 16",width:"15",height:"15",fill:"none",stroke:"currentColor",strokeWidth:"2.2",strokeLinecap:"round",strokeLinejoin:"round","aria-hidden":"true",...n,children:f.jsx("path",{d:"M3.5 8.5l3 3 6-6.5"})})}function e0(n){return f.jsx("svg",{viewBox:"0 0 14 14",width:"13",height:"13",fill:"none",stroke:"currentColor",strokeWidth:"1.7",strokeLinecap:"round","aria-hidden":"true",...n,children:f.jsx("path",{d:"M3.5 3.5l7 7M10.5 3.5l-7 7"})})}function DN({items:n,onApply:l}){const s=n??[],o=s.length,u=s.map(de=>de.id).join("|"),[d,h]=_.useState(!1),[p,y]=_.useState("idle"),[g,x]=_.useState(!1),[v,E]=_.useState(0),M=_.useRef(null),N=_.useRef(null),A=_.useRef(null),j=_.useRef(null),O=_.useRef(s),z=_.useRef(!0);_.useLayoutEffect(()=>{O.current=s});const D=_.useRef(RN()).current,Y=_.useCallback(de=>{const ce=M.current;if(D||document.hidden||ce==null||typeof ce.animate!="function"){x(!1),h(!1),y("idle"),de==null||de();return}x(!0);const ie=ce.animate([{opacity:1,transform:"none"},{opacity:0,transform:"translateY(6px)"}],{duration:240,easing:"cubic-bezier(.4,0,.2,1)",fill:"forwards"});ie.onfinish=()=>{x(!1),h(!1),y("idle"),de==null||de()}},[D]);_.useEffect(()=>(N.current!=null&&clearTimeout(N.current),o>0&&p==="idle"?u!==j.current&&!d&&(N.current=setTimeout(()=>{h(!0)},550)):o===0&&d&&!g&&p==="idle"&&Y(),()=>{N.current!=null&&clearTimeout(N.current)}),[o,u,d,p,g,Y]),_.useLayoutEffect(()=>{if(!d||p!=="idle"||D||g)return;const de=M.current;de!=null&&typeof de.animate=="function"&&!document.hidden&&de.animate([{opacity:.45,transform:"translateY(10px)"},{opacity:1,transform:"none"}],{duration:420,easing:"cubic-bezier(.18,.82,.25,1)"})},[d,p,D,g]),_.useEffect(()=>{if(p!=="applying")return;const de=ce=>{ce.preventDefault(),ce.returnValue=""};return window.addEventListener("beforeunload",de),()=>window.removeEventListener("beforeunload",de)},[p]),_.useEffect(()=>(z.current=!0,()=>{z.current=!1,N.current!=null&&clearTimeout(N.current),A.current!=null&&clearTimeout(A.current)}),[]);const W=()=>{const de=O.current;E(de.length),y("applying"),(async()=>{try{if(await l(de),!z.current)return;h(!1),y("success"),A.current!=null&&clearTimeout(A.current),A.current=setTimeout(()=>{Y(()=>{j.current=null})},1200)}catch{if(!z.current)return;y("error")}})()},ee=()=>{j.current=u,Y()};if(!d&&p!=="success"&&!g)return null;const ae=p==="applying",U=ae?v:o,re=U===1?f.jsxs(f.Fragment,{children:[f.jsx("b",{className:"font-bold text-ink",children:"1"})," change to your property details"]}):f.jsxs(f.Fragment,{children:[f.jsx("b",{className:"font-bold text-ink",children:U})," changes to your property details"]});return f.jsx("div",{className:"pointer-events-none absolute bottom-[10px] left-0 right-0 z-[6]","aria-live":"polite",children:f.jsx("div",{className:"pointer-events-none",ref:M,children:f.jsx("div",{className:"pointer-events-auto relative mx-3 rounded-[calc(11*var(--content))] border border-line bg-canvas px-[calc(13*var(--content))] pb-[calc(12*var(--content))] pt-[calc(11*var(--content))] shadow-[0_8px_22px_-8px_rgba(20,18,13,.26),0_2px_6px_rgba(20,18,13,.08)] data-[done]:border-[#cfe6d4] data-[done]:bg-[#eef6ef]","data-done":p==="success"?"":void 0,children:p==="success"?f.jsxs("div",{className:"flex items-center gap-2 text-body font-semibold text-good",children:[f.jsx("span",{className:"grid flex-shrink-0 place-items-center [animation:we-ub-pop_.34s_cubic-bezier(.2,1.3,.4,1)_both]",children:f.jsx(zN,{})}),"Updated everywhere"]}):p==="error"?f.jsxs(f.Fragment,{children:[f.jsxs("div",{className:"flex items-start gap-[calc(9*var(--content))]",children:[f.jsxs("div",{className:"min-w-0 flex-1 text-body leading-[1.4]",children:[f.jsx("div",{className:"font-semibold text-danger",children:"Couldn't update"}),f.jsx("div",{className:"mt-0.5 text-[length:calc(11.5*var(--content))] text-ink-3",children:"Something went wrong. Please try again."})]}),f.jsx("button",{type:"button",className:"-mr-0.5 -mt-0.5 grid h-[calc(20*var(--content))] w-[calc(20*var(--content))] flex-shrink-0 cursor-pointer place-items-center rounded-[calc(5*var(--content))] text-ink-4 transition-[background-color,color] duration-[120ms] hover:bg-[rgba(20,18,13,.06)] hover:text-ink-2",onClick:ee,"aria-label":"Dismiss",children:f.jsx(e0,{})})]}),f.jsxs("button",{type:"button","data-action":"retry",className:"mt-[calc(10*var(--content))] box-border inline-flex h-[calc(34*var(--content))] w-full cursor-pointer items-center justify-center gap-[calc(6*var(--content))] rounded-[calc(8*var(--content))] bg-accent text-[length:calc(12.5*var(--content))] font-semibold text-white transition-[background-color,transform] duration-[120ms] hover:bg-[#143a2f] active:translate-y-[0.5px]",onClick:W,children:["Retry ",f.jsx(Wb,{})]})]}):f.jsxs(f.Fragment,{children:[f.jsxs("div",{className:"flex items-start gap-[calc(9*var(--content))]",children:[f.jsxs("div",{className:"min-w-0 flex-1 text-body leading-[1.4] text-ink-2",children:[re,f.jsx("div",{className:"mt-0.5 text-[length:calc(11.5*var(--content))] text-ink-3",children:"Update them everywhere these details are used."})]}),f.jsx("button",{type:"button",className:"-mr-0.5 -mt-0.5 grid h-[calc(20*var(--content))] w-[calc(20*var(--content))] flex-shrink-0 cursor-pointer place-items-center rounded-[calc(5*var(--content))] text-ink-4 transition-[background-color,color] duration-[120ms] hover:bg-[rgba(20,18,13,.06)] hover:text-ink-2 disabled:cursor-default disabled:opacity-50",onClick:ee,disabled:ae,"aria-label":"Dismiss",children:f.jsx(e0,{})})]}),f.jsx("button",{type:"button","data-action":"apply",disabled:ae,className:"mt-[calc(10*var(--content))] box-border inline-flex h-[calc(34*var(--content))] w-full cursor-pointer items-center justify-center gap-[calc(6*var(--content))] rounded-[calc(8*var(--content))] bg-accent text-[length:calc(12.5*var(--content))] font-semibold text-white transition-[background-color,transform] duration-[120ms] hover:bg-[#143a2f] active:translate-y-[0.5px] disabled:cursor-default disabled:hover:bg-accent disabled:active:translate-y-0",onClick:W,children:ae?f.jsxs(f.Fragment,{children:[f.jsx("span",{className:"inline-block size-[calc(14*var(--content))] animate-spin rounded-full border-2 border-white/40 border-t-white",role:"status","aria-label":"Updating"}),"Updating…"]}):f.jsxs(f.Fragment,{children:["Update everywhere ",f.jsx(Wb,{})]})})]})})})})}const UN="Real editor chrome. The playground has no linked sources, so this cannot update anything — the flow above is a preview.",LN="Nothing was updated. In the app this writes the change to every deliverable sharing the linked source.";function BN({items:n}){const[l,s]=_.useState([]),o=n.filter(h=>!l.includes(h.id)),u=l.length>0&&o.length===0,d=_.useCallback(h=>{s(p=>[...p,...h.map(y=>y.id)])},[]);return f.jsxs("div",{className:"instance-panel__we",children:[f.jsx("div",{className:"instance-panel__we-anchor",children:f.jsx(DN,{items:o,onApply:d})}),o.length>0||u?f.jsx("p",{className:"instance-panel__we-caption","data-testid":"we-caption","data-phase":u?"applied":"preview",children:u?LN:UN}):null]})}const HN={apiFetch:GA,cropImage:oN,getCropDerivativeUrl:cN,getFloorplanSourcePage:eN,postLink:aN,stageLibraryItemImage:mN,presignLibraryItemUpload:pN,deleteStagedLibraryItemImage:yN,stageComparablePhoto:lN,presignComparablePhoto:iN,deleteStagedComparablePhoto:sN,fetchProperty:gN};function qN(n,l,s){return _.useMemo(()=>{const o={session:{property_id:n,listing_intent:null},select:u=>{if(u===null){s(null);return}if(u.kind==="section"){s({kind:"section",instanceId:u.instance_id});return}s({kind:"slot",instanceId:u.instance_id,slotId:u.slot_id,...u.item_index!==void 0?{itemIndex:u.item_index}:{}})},markSlotOverridden:()=>{},relinkSlot:()=>{}};return{useEditorStore:u=>u(o),Accordion:lx,AccordionHeader:ax,UnitPlanPicker:SN,capabilities:{upload:!1},api:HN}},[n,l,s])}function t0(n,l){const{selection:s}=n;if((s==null?void 0:s.kind)==="slot"&&!(s.instanceId!==n.instanceId||s.slotId!==l))return s.itemIndex}function n0(n,l){var s;return AN(l,(s=n.payload)==null?void 0:s.provenance,o=>n.override.slots[o]!==void 0)}function Zd(n,l){var o;const s=n.override.slots[l];return s!==void 0?s:(o=n.payload)==null?void 0:o.resolvedProps.slots[l]}function GN(n){var p;const l=qN(n.fixture,n.selection,n.onSelect),s=_.useMemo(()=>new OE,[]),o=n.displayState.variant,u=_.useMemo(()=>ex(n.sectionSchema,o),[n.sectionSchema,o]),d=_.useMemo(()=>kN(n.override,n.baseline,n.fixture,n.sectionSchema),[n.override,n.baseline,n.fixture,n.sectionSchema]),h=((p=n.selection)==null?void 0:p.kind)==="slot"&&n.selection.instanceId===n.instanceId?n.selection.slotId:null;return f.jsxs("aside",{className:"instance-panel","data-testid":"instance-panel","data-instance-id":n.instanceId,children:[n.settingsOpen?f.jsx(ON,{instanceId:n.instanceId,label:n.label,display:n.display,sectionSchema:n.sectionSchema,variant:o,slotValue:y=>Zd(n,y),onSetVariant:n.onSetVariant,onBack:n.onCloseSettings}):f.jsx(NN,{label:n.label,display:n.display,enabled:n.displayState.enabled,onSetEnabled:n.onSetEnabled,onOpenSettings:n.onOpenSettings}),n.settingsOpen?null:n.renderError?f.jsx("p",{className:"instance-panel__error","data-testid":"render-error",children:n.renderError}):null,n.settingsOpen?null:n.payload===null?f.jsx("p",{className:"instance-panel__empty","data-testid":"panel-loading",children:"Loading…"}):f.jsx(RE,{client:s,children:f.jsx(ZE,{api:wN,children:f.jsxs(mj,{ports:l,children:[f.jsx(VE,{getJobStatus:rN}),f.jsxs("div",{className:"instance-panel__dock",children:[f.jsxs("div",{className:"hp-sb-scroll instance-panel__cards","data-testid":"slot-cards","data-dirty":d.length>0?"":void 0,children:[u.map(y=>y.kind==="record"?f.jsxs("section",{"aria-label":y.label,"data-testid":"object-list-card",className:"flex flex-col gap-2.5",children:[f.jsxs("h3",{className:"flex items-center gap-1.5 px-1 text-[length:calc(11.5*var(--content))] font-medium uppercase tracking-[0.04em] text-ink-3",children:[y.Icon?f.jsx(y.Icon,{size:13}):null,y.label,f.jsx("span",{className:"ml-auto",children:f.jsx(ix,{chips:n0(n,[y.slotId])})})]}),f.jsx("div",{className:"flex flex-col gap-3",children:f.jsx(zf,{slot:y.slot,instanceId:n.instanceId,slotId:y.slotId,value:Zd(n,y.slotId),propertyId:n.fixture,onChange:g=>n.onApplySlot(y.slotId,g),selectedItemIndex:t0(n,y.slotId)})})]},y.key):f.jsx(jN,{chips:n0(n,y.items.map(g=>g.slotId)),children:f.jsx(lx,{open:h!=null&&y.items.some(g=>g.slotId===h),onToggle:()=>h!=null&&y.items.some(g=>g.slotId===h)?n.onSelect({kind:"section",instanceId:n.instanceId}):n.onSelect({kind:"slot",instanceId:n.instanceId,slotId:y.items[0].slotId}),icon:y.Icon?f.jsx(y.Icon,{size:14}):null,title:y.label,scrollKey:y.key,children:f.jsx(Mv,{items:y.items.map(({slotId:g,slot:x})=>f.jsx(zf,{slot:x,instanceId:n.instanceId,slotId:g,value:Zd(n,g),propertyId:n.fixture,onChange:v=>n.onApplySlot(g,v),selectedItemIndex:t0(n,g)},g)),rows:y.rows})})},y.key)),u.length===0?f.jsx("p",{className:"instance-panel__empty","data-testid":"no-editable-slots",children:"Nothing to edit in this section."}):null]}),f.jsx(BN,{items:d})]})]})})})]})}function IN(n,l){return n.find(s=>s.pages.includes(l))??null}function QN(n,l,s,o){const u=l.endsWith("/")?l:`${l}/`;if(!n.startsWith(u))return null;const d=n.indexOf("#"),h=d===-1?null:n.slice(d+1),p=(d===-1?n:n.slice(0,d)).slice(u.length).split("/").filter(Boolean),[y,g,x,v,...E]=p;if(y!=="fixtures"||g===void 0||x!=="live"||E.length>0)return null;const M=v===void 0?"/":`/${decodeURIComponent(v)}`,N=s.find(j=>j.path===M);if(!N)return null;const A=IN(o,N.id);return A?{pageId:N.id,canvasId:A.id,anchor:h||null}:null}const Pd="box-border inline-flex h-10 w-full items-center justify-center gap-1.75 rounded-lg border text-center text-[length:calc(13.5*var(--content))] font-semibold tracking-[-0.005em]",KN="group cursor-pointer border-line bg-canvas text-ink transition-[background-color,border-color,box-shadow,color,transform] hover:border-[var(--color-ink-4)] hover:bg-[#fafaf8] active:translate-y-[0.5px]",VN="cursor-pointer border-honey-2 bg-honey text-honey-ink transition-[background-color,border-color,box-shadow,color,transform] hover:bg-honey-2 hover:shadow-[0_2px_6px_rgba(40,44,50,0.12)] active:translate-y-[0.5px]",YN="cursor-not-allowed border-line bg-[#f3f1ea] text-ink-4";function $N({host:n,templateName:l,fixture:s,output:o,format:u,canvas:d,pagePath:h}){const p=o==="website"?{href:n.liveHref(s,h??"/"),title:`Open this page as it would publish — ${l}`}:null,y=o==="image"?{href:n.captureHref("bundle",{fixture:s,format:u,canvas:d}),title:`Download every page of this canvas as a zip — ${l}`}:o==="document"?{href:n.captureHref("print",{fixture:s,format:u}),title:`Download the PDF — ${l}`}:null;return f.jsx("footer",{className:"flex-shrink-0 border-t border-line-soft bg-canvas p-3","data-testid":"panel-footer",children:f.jsxs("div",{className:y&&!p?"w-full":"grid w-full grid-cols-2 gap-2",children:[p?f.jsxs("a",{href:p.href,target:"_blank",rel:"noopener noreferrer","data-testid":"view-live",title:p.title,className:`${Pd} ${KN}`,children:[f.jsx("span",{className:"grid place-items-center text-ink-3 transition-colors group-hover:text-ink",children:f.jsx(Pl,{name:"external",size:12,stroke:1.6})}),f.jsx("span",{"data-testid":"view-live-label",children:"View live"})]}):null,y?f.jsxs("a",{href:y.href,"data-testid":"download",title:y.title,className:`${Pd} ${VN}`,children:[f.jsx(Ck,{size:14,className:"h-[calc(14*var(--content))] w-[calc(14*var(--content))]"}),f.jsx("span",{"data-testid":"download-label",children:"Download"})]}):f.jsx("button",{type:"button",disabled:!0,"data-testid":"publish",title:"Publishing needs a property and a deliverable — preview publish states in the application",className:`${Pd} ${YN}`,children:f.jsx("span",{children:"Publish"})})]})})}function FN(n,l,s,o){const u=n.ownerDocument,d=[],h=new Map;for(const p of Array.from(n.children)){const y=p,g=y.getAttribute(yc);g&&h.set(g,y)}for(const p of l){const y=h.get(p.instance_id),g=(y==null?void 0:y.dataset.svId)!==p.section_version_id;y&&g&&(o==null||o(y),y.remove());const x=y&&!g,v=x?y:s(p,u);x||d.push(v),n.appendChild(v),h.delete(p.instance_id)}return h.forEach(p=>{o==null||o(p),p.remove()}),d}function ox(n){return n==null?void 0:n.__trCanvasIslands}function XN(n,l,s,o){const u=n==null?void 0:n.querySelector(`[${yc}="${s}"]`);if(!u)return!1;const d=u.querySelector(":scope > .we-section-body")??u,h=ox(l);return h==null||h.unmountRoot(u),d.innerHTML=o,h==null||h.hydrateRoot(u),!0}function ZN(){return{slots:{}}}function Hn(n,l,s){var o;return((o=n[l])==null?void 0:o[s])??ZN()}function kh(n,l,s,o){return{...n,[l]:{...n[l],[s]:o}}}function PN(n,l,s,o,u){const d=Hn(n,l,s);return kh(n,l,s,{...d,slots:{...d.slots,[o]:u}})}function JN(n,l,s,o){return kh(n,l,s,{...Hn(n,l,s),enabled:o})}function WN(n,l,s,o){return kh(n,l,s,{...Hn(n,l,s),variant:o})}function eT(n,l){const s=n.enabled??(l==null?void 0:l.enabled)??!0,o=n.variant??(l==null?void 0:l.variant);return o===void 0?{enabled:s}:{enabled:s,variant:o}}function tT(n){return Object.keys(n.slots).length===0?{}:{slots:n.slots}}function nT(n,l){const s={};for(const[o,u]of Object.entries(n[l]??{}))u.enabled===void 0&&u.variant===void 0||(s[o]={...u.enabled===void 0?{}:{enabled:u.enabled},...u.variant===void 0?{}:{variant:u.variant}});return s}function aT(n,l){return Object.keys(n).filter(s=>l[s]!==n[s])}function a0(n,l){if(!l.some(o=>o in n))return n;const s={...n};for(const o of l)delete s[o];return s}function l0(n,l,s,o){return{...n,[l]:{...n[l],[s]:o}}}function lT(n,l,s){const o=n[l];if(!o||!(s in o))return n;const u={...o};return delete u[s],{...n,[l]:u}}function iT(n){const{host:l,fixture:s,doc:o,resolvedDisplay:u,sessions:d,pages:h,frameFor:p}=n,{edits:y,baselines:g,setEdits:x,setBaseline:v}=d,[E,M]=_.useState({}),[N,A]=_.useState({}),j=[s,o??"",...h.map($=>$.id)].join("\0"),[O,z]=_.useState(j);O!==j&&(z(j),M({}),A({}));const D=_.useRef(E);D.current=E;const Y=_.useRef(p);Y.current=p;const W=_.useRef(h);W.current=h;const ee=_.useRef(y);ee.current=y;const ae=_.useRef(s);ae.current=s;const U=_.useRef(o);U.current=o;const re=_.useRef(new Map),de=_.useCallback($=>Hn(y,s,$),[y,s]),ce=_.useCallback($=>eT(Hn(y,s,$),u==null?void 0:u[$]),[y,s,u]),ie=_.useCallback(($,T)=>{var B;return((B=N[$])==null?void 0:B[T])??null},[N]),L=_.useCallback($=>{var T;for(const B of h){const q=(T=N[B.id])==null?void 0:T[$];if(q!==void 0)return q}return null},[N,h]),G=_.useCallback($=>{var T;for(const B of h){const q=(T=E[B.id])==null?void 0:T[$];if(q)return q}return null},[E,h]),F=_.useCallback($=>{var T;return((T=g[s])==null?void 0:T[$])??null},[g,s]),w=_.useCallback(async($,T,B,q)=>{const V=$.id,me=ae.current,he=U.current,ke=`${V}\0${T}`,Ae=(re.current.get(ke)??0)+1;re.current.set(ke,Ae);const Ue=()=>me!==ae.current||he!==U.current||re.current.get(ke)!==Ae;try{const nt=await l.render({page:V,instance:T,fixture:me,session:tT(B),display:nT(ee.current,me)});if(Ue()||(M(hn=>l0(hn,V,T,nt)),Object.keys(B.slots).length===0&&B.variant===void 0&&v(me,T,{fixtureId:me,slots:nt.resolvedProps.slots}),A(hn=>lT(hn,V,T)),!q))return;const{doc:Ve,win:Oe}=Y.current(V);XN(Ve,Oe,T,nt.html)}catch(nt){if(Ue())return;const Ve=nt instanceof Error?nt.message:String(nt);A(Oe=>l0(Oe,V,T,Ve))}},[l,v]),Z=_.useCallback(($,T)=>{var q;if((q=D.current[$])!=null&&q[T])return;const B=W.current.find(V=>V.id===$);B&&w(B,T,Hn(ee.current,ae.current,T),!1)},[w]),ue=_.useCallback(($,T)=>{var B;for(const q of W.current)((B=D.current[q.id])==null?void 0:B[$])!==void 0&&w(q,$,T,!0)},[w]),te=_.useCallback($=>{ue($,Hn(ee.current,ae.current,$))},[ue]),P=_.useCallback(($,T,B)=>{const q=PN(ee.current,ae.current,$,T,B);ee.current=q,x(q),ue($,Hn(q,ae.current,$))},[ue,x]),k=_.useCallback(($,T)=>{const B=JN(ee.current,ae.current,$,T);ee.current=B,x(B);for(const q of W.current)for(const V of Object.keys(D.current[q.id]??{}))w(q,V,Hn(B,ae.current,V),!0)},[w,x]),I=_.useCallback(($,T)=>{const B=WN(ee.current,ae.current,$,T);ee.current=B,x(B),ue($,Hn(B,ae.current,$))},[ue,x]);return _.useMemo(()=>({overrideFor:de,displayFor:ce,payloads:E,errorOn:ie,errorFor:L,payloadFor:G,baselineFor:F,ensureLoaded:Z,reload:te,applySlot:P,setEnabled:k,setVariant:I}),[de,ce,E,ie,L,G,F,Z,te,P,k,I])}const sT={slots:{},slot_order:[]},oT={required:!1,variant:null},rT=[];function i0(n){return n?n.kind==="section"?{kind:"section",instance_id:n.instanceId}:{kind:"slot",instance_id:n.instanceId,slot_id:n.slotId,...n.itemIndex!==void 0?{item_index:n.itemIndex}:{}}:null}function cT(n){return n.kind==="section"?{kind:"section",instanceId:n.instance_id}:{kind:"slot",instanceId:n.instance_id,slotId:n.slot_id,...n.item_index!==void 0?{itemIndex:n.item_index}:{}}}function uT(n,l){if(!n)return[];const s=[];for(const o of n.pages){const u=l.find(d=>d.id===o);u&&s.push(u)}return s}function Xr(n,l,s,o){var y;const u=((y=l.doc)==null?void 0:y.getElementById(n))??null;if(!u||!s)return;const d=u.getBoundingClientRect(),h=Tw({top:d.top,height:d.height},l.wrapper.offsetTop,o,s.scrollTop),p=Nw(h,s.clientHeight,s.scrollTop,Aw);p!==null&&s.scrollTo({top:p,behavior:"smooth"})}function s0(n,l){return n.querySelector(`[${yc}="${Fl(l)}"]`)}function Bn(n){const l=JSON.stringify(n);return _.useMemo(()=>n,[l])}function dT(n){var Co,xa,zt;const{host:l,catalog:s,view:o,onViewChange:u,sessions:d}=n,h=_.useRef(null),p=_.useRef([]),[y,g]=_.useState({}),[x,v]=_.useState(1),[E,M]=_.useState(0),[N,A]=_.useState(!1),[j,O]=_.useState(null),z=o.fixture,D=s.fixtures.find(ne=>ne.id===z),Y=D==null?void 0:D.doc,W=D==null?void 0:D.display,[ee,ae]=_.useState(null),U=_.useCallback(ne=>{ae(null),u(ne)},[u]);_.useEffect(()=>{TA(z)},[z]);const re=_.useMemo(()=>new URL(l.base).pathname,[l.base]),de=Bn(s.template.pages),ce=Bn(s.template.canvases),ie=Bn(s.islands.map),L=Bn(s.stylesheets),G=s.islands.hostScript,F=Bn(s.islands.importMap),w=Bn(Object.fromEntries(s.template.instances.map(ne=>[ne.instanceId,ne.sectionSchema]))),Z=Bn(Object.fromEntries(s.template.instances.map(ne=>[ne.instanceId,ne.section]))),ue=Bn(s.template.instances),te=s.template.output,P=te!=="website",k=P?s.template.formats:[],I=Bn(P?k.find(ne=>ne.id===o.format)??k[0]??null:null),$=I!==null&&I.bleed>0?I.bleed:null,T=_.useMemo(()=>I?{formatId:I.id,width:I.cssWidth,height:I.cssHeight,tokens:I.tokens}:void 0,[I]),B=ce.find(ne=>ne.id===o.canvasId)??(o.canvasId===null?ce[0]??null:null),q=ce.length>0&&B===null,V=_.useMemo(()=>B?uT(B,de):rT,[B,de]),me=_.useMemo(()=>V.map(ne=>({id:ne.id})),[V]),he={basePath:re,stylesheets:L,cssRev:String(E),islands:ie,hostScript:G,importMap:F},ke=_.useMemo(()=>Hg($b({...he,sectionSchemaByInstance:w,...T?{pageBox:T}:{}})),[re,L,E,ie,G,F,w,T]),Ae=_.useMemo(()=>Hg($b({...he,...T?{pageBox:T}:{}})).srcdoc(),[re,L,E,ie,G,F,T]),[Ue,nt]=_.useState(Ae);Ue!==Ae&&(nt(Ae),g({}));const Ve=_.useCallback(ne=>{const pe=p.current.find(Se=>Se.key===ne);return{doc:(pe==null?void 0:pe.doc)??null,win:(pe==null?void 0:pe.iframe.contentWindow)??null}},[]),Oe=iT({host:l,fixture:z,doc:Y,resolvedDisplay:W,sessions:d,pages:me,frameFor:Ve}),hn=Bn(ue.map(ne=>ne.instanceId).filter(ne=>!Oe.displayFor(ne).enabled)),[Eo,jo]=_.useState(null),ti=_.useRef(o.selection);ti.current=o.selection;const ni=_.useRef(Oe);ni.current=Oe;const ai=_.useRef(V);ai.current=V;const dl=_.useRef(x);dl.current=x;const On=_.useMemo(()=>V.map(ne=>({key:ne.id,srcdoc:Ae,label:ne.label,title:`Canvas preview — ${ne.label}`,...T?{pageBox:T}:{}})),[V,Ae,T]);_.useEffect(()=>{const ne=h.current;if(!ne)return;const pe=jw(ne,On);p.current=pe;const Se=pe.map(Me=>{const Be=()=>{rw(Me.doc)&&g(Te=>({...Te,[Me.key]:!0}))};return Me.iframe.addEventListener("load",Be),()=>Me.iframe.removeEventListener("load",Be)});return()=>{for(const Me of Se)Me()}},[On]),_.useEffect(()=>{for(const ne of p.current)Cw(ne.overlay,N?$:null)},[N,$,On]),_.useEffect(()=>{const ne=h.current;if(!ne||typeof ResizeObserver>"u")return;const pe=new ResizeObserver(Se=>{var Te;const Me=(Te=Se[0])==null?void 0:Te.contentRect;if(!(Me!=null&&Me.width))return;const Be=X_(Me.width);v(P_(Be,{availableWidthPx:Me.width,availableHeightPx:Me.height},T?{width:T.width,height:T.height}:void 0))});return pe.observe(ne),()=>pe.disconnect()},[T]),_.useEffect(()=>{var ne;(ne=h.current)==null||ne.style.setProperty("--we-scale",String(x))},[x]),_.useEffect(()=>{var pe;if(T)return;const ne=[];for(const Se of p.current){if(!y[Se.key])continue;const Me=(pe=Se.doc)==null?void 0:pe.getElementById("we-page");if(!Me)continue;const Be=()=>Se.setPageHeight(Me.getBoundingClientRect().height);if(Be(),typeof ResizeObserver>"u")continue;const Te=new ResizeObserver(Be);Te.observe(Me),ne.push(()=>Te.disconnect())}return()=>{for(const Se of ne)Se()}},[y,On,T]),_.useEffect(()=>{const ne=Eo;if(!ne)return;const pe=()=>{document.documentElement.style.setProperty("--we-panel-w",`${ne.offsetWidth}px`)};pe();const Se=typeof ResizeObserver<"u"?new ResizeObserver(pe):null;return Se==null||Se.observe(ne),()=>{Se==null||Se.disconnect(),document.documentElement.style.removeProperty("--we-panel-w")}},[Eo]),_.useEffect(()=>{for(const ne of V)for(const pe of ne.instanceIds)Oe.ensureLoaded(ne.id,pe)},[V,Oe.ensureLoaded,z,Y]);const rt=_.useMemo(()=>{const ne={};for(const pe of V){const Se=Oe.payloads[pe.id]??{};ne[pe.id]=pe.instanceIds.filter(Me=>Se[Me]??Oe.errorOn(pe.id,Me)).map(Me=>{var Te,pt;const Be=Oe.errorOn(pe.id,Me);return{instance_id:Me,section_version_id:z,section_key:Z[Me]??Me,section_display_name:((Te=ue.find(mt=>mt.instanceId===Me))==null?void 0:Te.label)??null,html:((pt=Se[Me])==null?void 0:pt.html)??null,render_error:Be?{code:"render_failed",message:Be}:null}})}return ne},[V,Oe.payloads,Oe.errorOn,Z,ue,z]);_.useEffect(()=>{let ne=!1;for(const pe of p.current){if(!y[pe.key])continue;const Se=pe.doc,Me=pe.iframe.contentWindow,Be=Se==null?void 0:Se.getElementById("we-page");if(!Be)continue;const Te=ox(Me),pt=FN(Be,rt[pe.key]??[],(mt,ct)=>ke.buildSectionWrapper(mt,ct),mt=>Te==null?void 0:Te.unmountRoot(mt));pt.length>0&&!Te&&!ne&&Object.keys(ie).length>0&&(ne=!0,console.warn("playground: no island host on a canvas frame, so nothing will hydrate and sections stay static. Expected window.__trCanvasIslands from the canvas island host script."));for(const mt of pt)Te==null||Te.hydrateRoot(mt).catch(ct=>{console.error("playground: canvas hydration pass failed:",ct)})}},[y,On,rt,ke,ie]);const Mo=_.useRef(()=>{});Mo.current=ne=>{Oe.setEnabled(ne,!0),U({...o,selection:{kind:"section",instanceId:ne}})},_.useEffect(()=>{var Se;const ne=new Set(hn),pe=[];for(const Me of p.current){if(!y[Me.key])continue;const Be=Me.doc;if(!Be)continue;const Te=rt[Me.key]??[];for(const Lt of Te)(Se=s0(Be,Lt.instance_id))==null||Se.setAttribute("data-hidden",ne.has(Lt.instance_id)?"true":"false");const pt=Te.filter(Lt=>ne.has(Lt.instance_id)).map(Lt=>({instanceId:Lt.instance_id,label:Wd(Lt)})),mt=yw(Me.tabLayer,document,pt,Lt=>Mo.current(Lt)),ct=()=>gw(mt,Lt=>s0(Be,Lt),x);ct();const Dt=Be.getElementById("we-page");if(!Dt||typeof ResizeObserver>"u")continue;const Ut=new ResizeObserver(ct);Ut.observe(Dt),pe.push(()=>Ut.disconnect())}return()=>{for(const Me of pe)Me()}},[y,On,rt,hn,x]);const ds=_.useCallback(()=>{const ne=p.current,pe=ti.current,Se=i0(pe);for(const Te of ne)Te.doc&&ke.setLiveOwner(Te.doc,Se);const Me=Mw(ne,ke,Se),Be=pe!==null&&hn.includes(pe.instanceId);for(const Te of ne){const pt=Te.overlay.querySelector(".we-chrome-label"),mt=pe&&!Be?Me.find(ct=>ct.handle.key===Te.key):void 0;if(!mt||!pe){Rg(Te.overlay,[],Dd),Jd(pt);continue}if(Rg(Te.overlay,mt.els,Dd,pe.kind),pe.kind==="section"){const ct=(rt[Te.key]??[]).find(Dt=>Dt.instance_id===pe.instanceId);q_(pt,mt.els[0]??null,ct?Wd(ct):"")}else Jd(pt)}},[ke,rt,hn]);_.useEffect(()=>{ds();for(const ne of p.current){if(!y[ne.key])continue;const pe=ne.doc,Se=ne.iframe.contentWindow;pe&&Se&&Dw(Se,pe,i0(o.selection))}},[y,On,o.selection,ds]);const li=_.useCallback((ne,pe)=>{const Se=ne.getAttribute("href")??"";if(!Se||Se==="#")return;const Me=h.current;if(Se.startsWith("#")){Xr(Se.slice(1),pe,Me,dl.current);return}const Be=QN(Se,re,de,ce);if(!Be){window.open(Se,"_blank","noopener,noreferrer");return}if(B!==null&&Be.canvasId===B.id){const Te=p.current.find(pt=>pt.key===Be.pageId);if(!Te)return;Be.anchor?Xr(Be.anchor,Te,Me,dl.current):Te!==pe&&Xr("we-page",Te,Me,dl.current);return}U({...o,canvasId:Be.canvasId,selection:null}),Be.anchor&&O({pageId:Be.pageId,anchor:Be.anchor})},[o,U,re,de,ce,B]);_.useEffect(()=>{var pe;if(!j||!y[j.pageId])return;const ne=p.current.find(Se=>Se.key===j.pageId);(pe=ne==null?void 0:ne.doc)!=null&&pe.getElementById(j.anchor)&&(Xr(j.anchor,ne,h.current,dl.current),O(null))},[j,y,rt]),_.useEffect(()=>{const ne=[];for(const pe of p.current){if(!y[pe.key])continue;const Se=pe.doc;if(!Se)continue;const Me=rt[pe.key]??[],Be=pe.overlay.querySelector(".we-chrome-ring--hover"),Te=Dt=>{var _a;const Ut=Dt.target,Lt=ke.resolveTarget(Ut,Me);Zr(Be);const jn=Lt?cT(Lt.selection):null,pl=((_a=Ut.closest)==null?void 0:_a.call(Ut,"a"))??null;if(pl){if(Dt.preventDefault(),(jn==null?void 0:jn.kind)==="slot"){const wa=o.selection,Ao=(wa==null?void 0:wa.kind)==="slot"&&wa.instanceId===jn.instanceId&&wa.slotId===jn.slotId&&wa.itemIndex===jn.itemIndex;U({...o,selection:jn}),Ao&&li(pl,pe);return}li(pl,pe);return}U({...o,selection:jn})},pt=Dt=>{const Ut=ke.resolveTarget(Dt.target,Me);Ut?S0(Be,Ut.element,Dd):Zr(Be)},mt=()=>Zr(Be),ct=Dt=>{Dt.key==="Escape"&&U({...o,selection:null})};Se.body.addEventListener("click",Te),Se.body.addEventListener("mouseover",pt),Se.body.addEventListener("mouseleave",mt),Se.body.addEventListener("keydown",ct),ne.push(()=>{Se.body.removeEventListener("click",Te),Se.body.removeEventListener("mouseover",pt),Se.body.removeEventListener("mouseleave",mt),Se.body.removeEventListener("keydown",ct)})}return()=>{for(const pe of ne)pe()}},[y,On,ke,rt,o,U,li]);const fl=s.capabilities.hmr;_.useEffect(()=>{if(!fl)return;const ne=()=>{const pe=new Set;for(const Se of ai.current)for(const Me of Se.instanceIds)pe.has(Me)||(pe.add(Me),ni.current.reload(Me))};return l.subscribe({source:ne,stylesheet:()=>M(pe=>pe+1)})},[l,fl]);const ii=o.selection,it=(ii==null?void 0:ii.instanceId)??null,hl=V.find(ne=>it!==null&&ne.instanceIds.includes(it))??V[0]??null;return _.useEffect(()=>{it&&hl&&Oe.ensureLoaded(hl.id,it)},[it,hl==null?void 0:hl.id,Oe.ensureLoaded]),q?f.jsxs("div",{className:"boot-error",children:['The template declares no canvas "',o.canvasId,'".',`
|
|
1100
|
+
`,"Declared canvases: ",ce.map(ne=>ne.id).join(", ")]}):f.jsxs("div",{className:"canvas-mirror",children:[f.jsx("style",{children:xw}),ce.length>1?f.jsx("div",{className:"canvas-bar",children:f.jsx("nav",{className:"canvas-bar__card","aria-label":"Canvases",children:ce.map(ne=>f.jsx("button",{type:"button",className:ne.id===(B==null?void 0:B.id)?"canvas-bar__tab is-current":"canvas-bar__tab","aria-current":ne.id===(B==null?void 0:B.id)?"page":void 0,onClick:()=>U({...o,canvasId:ne.id,selection:null}),children:ne.label},ne.id))})}):null,f.jsx("div",{className:"we-canvas-stage canvas-mirror__stage",ref:h,onClick:ne=>{var Se;const pe=ne.target;(pe===h.current||(Se=pe.classList)!=null&&Se.contains(tc))&&U({...o,selection:null})}}),f.jsxs("div",{className:"canvas-mirror__sidebar",ref:jo,children:[f.jsxs("div",{className:"sidebar-template",children:[f.jsxs("label",{className:"sidebar-template__field",children:["Fixture",f.jsx("select",{"data-testid":"fixture-picker",value:z,onChange:ne=>U({...o,fixture:ne.target.value,selection:null}),children:s.fixtures.map(ne=>f.jsx("option",{value:ne.id,children:zA(ne)},ne.id))})]}),P&&I&&k.length>1?f.jsxs("label",{className:"sidebar-template__field",children:["Format",f.jsx("select",{"data-testid":"format-switcher",value:I.id,onChange:ne=>u({...o,format:ne.target.value}),children:k.map(ne=>f.jsx("option",{value:ne.id,children:`${ne.id} — ${ne.pixelWidth}×${ne.pixelHeight}px${ne.physical?` (${ne.physical})`:""}`},ne.id))})]}):null,$!==null?f.jsxs("label",{className:"sidebar-template__toggle",children:[f.jsx("input",{type:"checkbox","data-testid":"guides-toggle",checked:N,onChange:ne=>A(ne.target.checked)}),"Trim & bleed guides"]}):null]}),it?f.jsx(GN,{instanceId:it,label:((Co=ue.find(ne=>ne.instanceId===it))==null?void 0:Co.label)??it,display:((xa=ue.find(ne=>ne.instanceId===it))==null?void 0:xa.display)??oT,displayState:Oe.displayFor(it),settingsOpen:ee===it,onSetEnabled:ne=>Oe.setEnabled(it,ne),onSetVariant:ne=>Oe.setVariant(it,ne),onOpenSettings:()=>ae(it),onCloseSettings:()=>ae(null),fixture:z,sectionSchema:w[it]??sT,override:Oe.overrideFor(it),payload:Oe.payloadFor(it),baseline:Oe.baselineFor(it),renderError:Oe.errorFor(it),selection:ii,onSelect:ne=>U({...o,selection:ne}),onApplySlot:(ne,pe)=>Oe.applySlot(it,ne,pe)}):f.jsx(jA,{}),s.capabilities.capture||te==="website"?f.jsx($N,{host:l,templateName:s.template.name,fixture:z,output:te,format:(I==null?void 0:I.id)??null,canvas:(B==null?void 0:B.id)??null,pagePath:((zt=V[0])==null?void 0:zt.path)??null}):null]})]})}function fT(n){const[l,s]=_.useState({}),[o,u]=_.useState({}),[d,h]=_.useState(n);if(n!==null&&n!==d){const g=d===null?[]:aT(d,n);h(n),g.length>0&&(s(x=>a0(x,g)),u(x=>a0(x,g)))}const p=_.useCallback(g=>s(g),[]),y=_.useCallback((g,x,v)=>{u(E=>({...E,[g]:{...E[g],[x]:v}}))},[]);return _.useMemo(()=>({edits:l,baselines:o,setEdits:p,setBaseline:y}),[l,o,p,y])}function o0(n){const l=R_(window.location.pathname,n.base);return l===null?null:z_(l,window.location.search)}function hT({host:n}){const[l,s]=_.useState(null),[o,u]=_.useState(null),[d,h]=_.useState(0),[p,y]=_.useState(()=>o0(n)),g=_.useMemo(()=>l===null||l.error!==void 0?null:Object.fromEntries(l.fixtures.map(N=>[N.id,N.doc])),[l]),x=fT(g);_.useEffect(()=>{let N=!0;return n.catalog().then(A=>{N&&(s(A),u(null))},A=>{N&&u(A instanceof Error?A.message:String(A))}),()=>{N=!1}},[n,d]);const v=l==null?void 0:l.template.name;_.useEffect(()=>{v&&(document.title=`${v} - Playground`)},[v]);const E=(l==null?void 0:l.capabilities.hmr)===!0;_.useEffect(()=>{if(!E)return;const N=()=>h(A=>A+1);return n.subscribe({source:N,fixtures:N})},[n,E]),_.useEffect(()=>{const N=()=>y(o0(n));return window.addEventListener("popstate",N),()=>window.removeEventListener("popstate",N)},[n]),_.useEffect(()=>{if(p!==null||l===null)return;const N=D_(l);N!==null&&(window.history.replaceState({},"",new URL(Ng(N),n.base).href),y(N))},[p,l,n]);const M=_.useCallback(N=>{window.history.replaceState({},"",new URL(Ng(N),n.base).href),y(N)},[n]);return o?f.jsxs("div",{className:"boot-error",children:["The playground could not load its catalog — ",o,`
|
|
1101
|
+
`,"Is the server still starting? Try refreshing."]}):l?l.error!==void 0?f.jsx("div",{className:"boot-error","data-testid":"catalog-error",children:l.error}):l.fixtures.length===0?f.jsx("div",{className:"empty","data-testid":"no-fixtures",children:"No fixtures to render under. Export a defineFixture() value from a module under fixtures/."}):p?l.fixtures.some(N=>N.id===p.fixture)?f.jsx(dT,{host:n,catalog:l,view:p,onViewChange:M,sessions:x}):f.jsxs("div",{className:"boot-error","data-testid":"unknown-fixture",children:['There is no fixture "',p.fixture,'" (have: ',l.fixtures.map(N=>N.id).join(", "),")."]}):f.jsx("div",{className:"empty",children:"loading canvas…"}):f.jsx("div",{className:"empty",children:"loading…"})}const rx=document.getElementById("root");if(!rx)throw new Error("playground: #root missing from index.html");const cx=CA(document.baseURI);AA(cx);N_.createRoot(rx).render(f.jsx(_.StrictMode,{children:f.jsx(hT,{host:cx})}));
|